Browse Source

Add a splash of color, add minimum height to widgets, improve QwikClock

tags/v1.0
Skylar Ittner 2 years ago
parent
commit
e9e23d8808

+ 1
- 0
apps/account_security.php View File

@@ -9,6 +9,7 @@ addMultiLangStrings(["en_us" => [
$APPS["account_security"]["i18n"] = TRUE;
$APPS["account_security"]["title"] = "account security";
$APPS["account_security"]["icon"] = "lock";
$APPS["account_security"]["type"] = "brown";
$content = "<p>"
. lang("manage security description", false)
. '</p> '

+ 1
- 0
apps/inventory_link.php View File

@@ -9,6 +9,7 @@ addMultiLangStrings(["en_us" => [
$APPS["inventory_link"]["i18n"] = TRUE;
$APPS["inventory_link"]["title"] = "inventory";
$APPS["inventory_link"]["icon"] = "cubes";
$APPS["inventory_link"]["type"] = "teal";
$content = "<p>" . lang("open inventory system", false) . '</p><a href="' . INVENTORY_HOME . '" class="btn btn-primary btn-block">' . lang("open app", false) . ' &nbsp;<i class="fa fa-external-link-square"></i></a>';
$APPS["inventory_link"]["content"] = $content;
?>

+ 5
- 4
apps/qwikclock_inout.php View File

@@ -10,6 +10,7 @@ addMultiLangStrings(["en_us" => [
$APPS["qwikclock_inout"]["i18n"] = TRUE;
$APPS["qwikclock_inout"]["title"] = "qwikclock";
$APPS["qwikclock_inout"]["icon"] = "clock-o";
$APPS["qwikclock_inout"]["type"] = "blue";
$content = "";
if (!is_empty($_GET['qwikclock']) && ($_GET['qwikclock'] === "punchin" || $_GET['qwikclock'] === "punchout")) {
try {
@@ -23,20 +24,20 @@ if (!is_empty($_GET['qwikclock']) && ($_GET['qwikclock'] === "punchin" || $_GET[

$resp = json_decode($response->getBody(), TRUE);
if ($resp['status'] == "OK") {
$content = "<div class=\"alert alert-success\">" . $resp['msg'] . "</div>";
$content = "<div class=\"alert alert-success alert-dismissable\"><button type=\"button\" class=\"close\">&times;</button>" . $resp['msg'] . "</div>";
} else {
$content = "<div class=\"alert alert-danger\">" . $resp['msg'] . "</div>";
$content = "<div class=\"alert alert-danger alert-dismissable\"><button type=\"button\" class=\"close\">&times;</button>" . $resp['msg'] . "</div>";
}
} catch (Exception $e) {
$content = "<div class=\"alert alert-danger\">" . lang("error loading widget", false) . " " . $e->getMessage() . "</div>";
$content = "<div class=\"alert alert-danger alert-dismissable\"><button type=\"button\" class=\"close\">&times;</button>" . lang("error loading widget", false) . " " . $e->getMessage() . "</div>";
}
}
$lang_punchin = lang("punch in", false);
$lang_punchout = lang("punch out", false);
$content .= <<<END
<a href="home.php?&qwikclock=punchin" class="btn btn-block btn-success btn-lg"><i class="fa fa-play"></i> $lang_punchin</a>
<br />
<a href="home.php?qwikclock=punchout" class="btn btn-block btn-danger btn-lg"><i class="fa fa-stop"></i> $lang_punchout</a>
END;
$content .= '<br /><a href="' . QWIKCLOCK_HOME . '" class="btn btn-primary btn-block">' . lang("open app", false) . ' &nbsp;<i class="fa fa-external-link-square"></i></a>';
$APPS["qwikclock_inout"]["content"] = $content;
?>

+ 1
- 0
apps/taskfloor_messages.php View File

@@ -9,6 +9,7 @@ addMultiLangStrings(["en_us" => [
$APPS["taskfloor_messages"]["i18n"] = TRUE;
$APPS["taskfloor_messages"]["title"] = "messages";
$APPS["taskfloor_messages"]["icon"] = "comments";
$APPS["taskfloor_messages"]["type"] = "deep-purple";
try {
$client = new GuzzleHttp\Client();


+ 1
- 0
apps/taskfloor_tasks.php View File

@@ -9,6 +9,7 @@ addMultiLangStrings(["en_us" => [
$APPS["taskfloor_tasks"]["i18n"] = TRUE;
$APPS["taskfloor_tasks"]["title"] = "tasks";
$APPS["taskfloor_tasks"]["icon"] = "tasks";
$APPS["taskfloor_tasks"]["type"] = "blue-grey";
try {
$client = new GuzzleHttp\Client();


+ 2
- 1
home.php View File

@@ -31,6 +31,7 @@ if (!is_empty($_GET['page'])) {

<link href="static/css/bootstrap.min.css" rel="stylesheet">
<link href="static/css/font-awesome.min.css" rel="stylesheet">
<link href="static/css/material-color.min.css" rel="stylesheet">
<link href="static/css/app.css" rel="stylesheet">
</head>
<body>
@@ -154,7 +155,7 @@ END;
$appcontent = $APPS[$app]['content'];
echo <<<END
<div class="col-xs-12 col-sm-6 col-md-4 col-lg-4">
<div class="panel panel-$apptype">
<div class="panel panel-$apptype apppanel">
<div class="panel-heading">
<h3 class="panel-title"><i class="$appicon"></i> $apptitle </h3>
</div>

+ 1
- 1
pages.php View File

@@ -17,8 +17,8 @@ define("PAGES", [
define("APPS", [
"home" => [
"taskfloor_tasks",
"taskfloor_messages",
"qwikclock_inout",
"taskfloor_messages",
"inventory_link",
"account_security"
],

+ 1
- 0
settings.template.php View File

@@ -63,6 +63,7 @@ define('TASKFLOOR_HOME', '/taskfloor/app.php');
define('INVENTORY_HOME', '/inventory/app.php');

define('QWIKCLOCK_API', 'http://localhost/qwikclock/api.php');
define('QWIKCLOCK_HOME', '/qwikclock/app.php');

// See lang folder for language options
define('LANGUAGE', "en_us");

+ 4
- 0
static/css/app.css View File

@@ -39,4 +39,8 @@

.navbar-inverse .navbar-link {
color: white;
}

.apppanel {
min-height: 250px;
}

+ 1951
- 0
static/css/material-color.css
File diff suppressed because it is too large
View File


+ 2
- 0
static/css/material-color.min.css
File diff suppressed because it is too large
View File


Loading…
Cancel
Save