Finish adding manufacturer field to components, add a bit of customization to /public
This commit is contained in:
parent
55c95c6a86
commit
8f9ed05e8d
@ -79,6 +79,7 @@ switch ($VARS['action']) {
|
|||||||
}
|
}
|
||||||
$component->setCapacity($VARS['capacity']);
|
$component->setCapacity($VARS['capacity']);
|
||||||
$component->setModel($VARS['model']);
|
$component->setModel($VARS['model']);
|
||||||
|
$component->setManufacturer($VARS['manufacturer']);
|
||||||
$component->setPrice($VARS['price'] * 1.0);
|
$component->setPrice($VARS['price'] * 1.0);
|
||||||
$component->setPrivateNotes($VARS['privatenotes']);
|
$component->setPrivateNotes($VARS['privatenotes']);
|
||||||
$component->setPublicNotes($VARS['publicnotes']);
|
$component->setPublicNotes($VARS['publicnotes']);
|
||||||
|
@ -147,6 +147,12 @@ $machine = new Machine($machineid);
|
|||||||
<?php
|
<?php
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!empty($c->getManufacturer())) {
|
||||||
|
?>
|
||||||
|
<b><?php $Strings->get("Manufacturer"); ?></b>: <?php echo htmlspecialchars($c->getManufacturer()); ?><br />
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
|
||||||
if (!empty($c->getTestedDate())) {
|
if (!empty($c->getTestedDate())) {
|
||||||
?>
|
?>
|
||||||
<b><?php $Strings->get("Tested On"); ?></b>: <?php echo date($SETTINGS["datetime_format"], strtotime($c->getTestedDate())); ?><br />
|
<b><?php $Strings->get("Tested On"); ?></b>: <?php echo date($SETTINGS["datetime_format"], strtotime($c->getTestedDate())); ?><br />
|
||||||
|
@ -113,7 +113,7 @@ if (isset($_GET["backgroundcolor"]) && !empty($_GET["backgroundcolor"]) && preg_
|
|||||||
</div>
|
</div>
|
||||||
<?php if (!isset($_GET["embed"])) { ?>
|
<?php if (!isset($_GET["embed"])) { ?>
|
||||||
<p>
|
<p>
|
||||||
Enter a Netsyms machine ID number, serial number, or tracking code.
|
Enter a <?php echo $SETTINGS["branding"]["machineidnumber"]; ?>, serial number, or tracking code.
|
||||||
</p>
|
</p>
|
||||||
<form method="GET">
|
<form method="GET">
|
||||||
<input type="text" name="id" class="form-control" placeholder="Number" required />
|
<input type="text" name="id" class="form-control" placeholder="Number" required />
|
||||||
@ -143,7 +143,7 @@ if (isset($_GET["backgroundcolor"]) && !empty($_GET["backgroundcolor"]) && preg_
|
|||||||
?>
|
?>
|
||||||
<?php if (!isset($_GET["embed"])) { ?>
|
<?php if (!isset($_GET["embed"])) { ?>
|
||||||
<p>
|
<p>
|
||||||
Enter a Netsyms machine ID number, serial number, or tracking code.
|
Enter a <?php echo $SETTINGS["branding"]["machineidnumber"]; ?>, serial number, or tracking code.
|
||||||
</p>
|
</p>
|
||||||
<form method="GET">
|
<form method="GET">
|
||||||
<input type="text" name="id" class="form-control" placeholder="Number" required />
|
<input type="text" name="id" class="form-control" placeholder="Number" required />
|
||||||
@ -290,6 +290,12 @@ if (isset($_GET["backgroundcolor"]) && !empty($_GET["backgroundcolor"]) && preg_
|
|||||||
<?php
|
<?php
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!empty($c->getManufacturer())) {
|
||||||
|
?>
|
||||||
|
<b><?php $Strings->get("Manufacturer"); ?></b>: <?php echo htmlspecialchars($c->getManufacturer()); ?><br />
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
|
||||||
if (!empty($c->getPublicNotes())) {
|
if (!empty($c->getPublicNotes())) {
|
||||||
?>
|
?>
|
||||||
<div>
|
<div>
|
||||||
@ -335,7 +341,7 @@ if (isset($_GET["backgroundcolor"]) && !empty($_GET["backgroundcolor"]) && preg_
|
|||||||
Look up another machine:
|
Look up another machine:
|
||||||
</p>
|
</p>
|
||||||
<form method="GET">
|
<form method="GET">
|
||||||
<input type="text" name="id" class="form-control" placeholder="Machine ID Number" required />
|
<input type="text" name="id" class="form-control" placeholder="<?php echo $SETTINGS["branding"]["shortmachineid"]; ?>" required />
|
||||||
<button type="submit" class="btn btn-primary btn-block mt-2">Get Info</button>
|
<button type="submit" class="btn btn-primary btn-block mt-2">Get Info</button>
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
|
@ -36,6 +36,9 @@ $SETTINGS = [
|
|||||||
],
|
],
|
||||||
// Name of the app.
|
// Name of the app.
|
||||||
"site_title" => "MachineManager",
|
"site_title" => "MachineManager",
|
||||||
|
"branding" => [
|
||||||
|
"machineidnumber" => "Netsyms machine ID number"
|
||||||
|
],
|
||||||
// Settings for connecting to the AccountHub server.
|
// Settings for connecting to the AccountHub server.
|
||||||
"accounthub" => [
|
"accounthub" => [
|
||||||
// URL for the API endpoint
|
// URL for the API endpoint
|
||||||
|
Loading…
x
Reference in New Issue
Block a user