More improvements e.g. flags and provision target
This commit is contained in:
+10
-5
@@ -121,7 +121,7 @@ if ($action == ACT_DEFAULT):
|
||||
|
||||
page_caption_search($pagetitle);
|
||||
|
||||
$flt = db_get_filter($user->id, 201, ['cond','name','txt']);
|
||||
$flt = db_get_filter($user->id, 201, ['stor', 'cond','txt']);
|
||||
|
||||
/*
|
||||
The only way to find out whether the inventory is on the current boat is to use
|
||||
@@ -301,7 +301,7 @@ echo '<h2>', _('Add Inventory'), "</h2>\n";
|
||||
<form method="post" action="<?=$g_scriptname?>">
|
||||
<div class="mb-3">
|
||||
<label for="invname" class="form-label"><?=_('Name')?></label>
|
||||
<input type="text" class="form-control" id="invname" name="invname">
|
||||
<input type="text" class="form-control" id="invname" name="invname" autofocus>
|
||||
</div>
|
||||
<div class="mb-3">
|
||||
<label for="number" class="form-label"><?=_('Number')?></label>
|
||||
@@ -310,12 +310,14 @@ echo '<h2>', _('Add Inventory'), "</h2>\n";
|
||||
<div class="mb-3">
|
||||
<label for="conttype" class="form-label"><?=_('Container type')?></label>
|
||||
<select class="form-select" name="conttype" id="conttype">
|
||||
<option value="box"><?=_('Box')?></option>
|
||||
<option value="storage"><?=_('Storage')?></option>
|
||||
<option value="box"><?=_('Box')?></option>
|
||||
</select>
|
||||
</div>
|
||||
<?php
|
||||
form_create_select('sid', _('Storage'), $g_opt_none + $opt_storage);
|
||||
// load current filter setting for storage default setting
|
||||
$flt = db_get_filter($user->id, 201, ['stor','cond','txt']);
|
||||
form_create_select('sid', _('Storage'), $g_opt_none + $opt_storage, $flt->stor);
|
||||
form_create_select('boxid', _('Box'), $g_opt_none + $opt_box);
|
||||
?>
|
||||
<div class="container-fluid px-0 my-3">
|
||||
@@ -371,7 +373,10 @@ echo '<tr><th style="width:20%">', _('Box type'),"</th><td>", $inventory->contty
|
||||
// Container with link
|
||||
echo '<tr><th>', $inventory->conttype == 'storage' ? _('Storage') : _('Container');
|
||||
echo '</th><td>', sprintf(_('%s in %s'), $box['label'], $storagename);
|
||||
// TODO insert link
|
||||
// link to box
|
||||
if ($inventory->conttype == 'box') {
|
||||
echo '<a class="text-nowrap" title="', _('View Box'), '" href="box.php?f=view&id=', $inventory->boxid, '"><i class="bi bi-eye ms-2"></i></a>', "\n";
|
||||
}
|
||||
echo "</td></tr>\n";
|
||||
|
||||
echo "<tr><th>", _('Location ID'), "</th><td>", $inventory->locationid, "</td></tr>\n";
|
||||
|
||||
Reference in New Issue
Block a user