summaryrefslogtreecommitdiff
path: root/templates
diff options
context:
space:
mode:
authorLester Caine <lester@lsces.co.uk>2026-06-07 17:43:28 +0100
committerLester Caine <lester@lsces.co.uk>2026-06-07 17:43:28 +0100
commitb580057fda44dc3f57bc39e612af9461c3ebca5a (patch)
treed4d7d2494b59fbae152708bc0cb78c6f6569939e /templates
parent9f5cb5855df61554e38a6da5d036bd78d421a2a9 (diff)
downloadstock-b580057fda44dc3f57bc39e612af9461c3ebca5a.tar.gz
stock-b580057fda44dc3f57bc39e612af9461c3ebca5a.tar.bz2
stock-b580057fda44dc3f57bc39e612af9461c3ebca5a.zip
Fix xorder lost on xref edit; widen component_order Order column
All edit_xref templates were missing a hidden xorder field, causing LibertyXref::verify() to default it to 0 on every save. Added the hidden field to all four stock edit_xref templates (bom, bompck, pck, sup). component_order.tpl: Order column widened to 7em so 4-digit xorder values are not clipped. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Diffstat (limited to 'templates')
-rwxr-xr-xtemplates/component_order.tpl4
-rw-r--r--templates/stockassembly/edit_xref_bom_item.tpl1
-rw-r--r--templates/stockassembly/edit_xref_bompck_item.tpl1
-rw-r--r--templates/stockcomponent/edit_xref_pck_item.tpl1
-rw-r--r--templates/stockcomponent/edit_xref_sup_item.tpl1
5 files changed, 6 insertions, 2 deletions
diff --git a/templates/component_order.tpl b/templates/component_order.tpl
index 817c84d..d2fb2f6 100755
--- a/templates/component_order.tpl
+++ b/templates/component_order.tpl
@@ -16,7 +16,7 @@
<table class="table table-striped table-condensed">
<thead>
<tr>
- <th style="width:4em;">{tr}#{/tr}</th>
+ <th style="width:7em;">{tr}Order{/tr}</th>
<th>{tr}Component{/tr}</th>
<th>{tr}Description{/tr}</th>
<th>{tr}Qty{/tr}</th>
@@ -37,7 +37,7 @@
{/if}
<tr>
<td>
- <input type="text" class="form-control input-sm hidden-print" size="5"
+ <input type="text" class="form-control input-sm hidden-print" size="7"
name="xrefOrder[{$row.xref_id|escape}]"
value="{$row.xorder|escape}" />
<span class="visible-print-inline">{$posInGroup}</span>
diff --git a/templates/stockassembly/edit_xref_bom_item.tpl b/templates/stockassembly/edit_xref_bom_item.tpl
index 0ab5294..e01a396 100644
--- a/templates/stockassembly/edit_xref_bom_item.tpl
+++ b/templates/stockassembly/edit_xref_bom_item.tpl
@@ -9,6 +9,7 @@
<input type="hidden" name="content_id" value="{$xrefInfo.content_id|escape}" />
<input type="hidden" name="xref_id" value="{$xrefInfo.xref_id|escape}" />
<input type="hidden" name="item" value="{$xrefInfo.item|escape}" />
+ <input type="hidden" name="xorder" value="{$xrefInfo.xorder|escape}" />
<div class="form-group">
{formlabel label="Component"}
diff --git a/templates/stockassembly/edit_xref_bompck_item.tpl b/templates/stockassembly/edit_xref_bompck_item.tpl
index 72acbd2..adb401b 100644
--- a/templates/stockassembly/edit_xref_bompck_item.tpl
+++ b/templates/stockassembly/edit_xref_bompck_item.tpl
@@ -9,6 +9,7 @@
<input type="hidden" name="content_id" value="{$xrefInfo.content_id|escape}" />
<input type="hidden" name="xref_id" value="{$xrefInfo.xref_id|escape}" />
<input type="hidden" name="item" value="{$xrefInfo.item|escape}" />
+ <input type="hidden" name="xorder" value="{$xrefInfo.xorder|escape}" />
<div class="form-group">
{formlabel label="Component"}
diff --git a/templates/stockcomponent/edit_xref_pck_item.tpl b/templates/stockcomponent/edit_xref_pck_item.tpl
index 2f0ba7e..29d10ff 100644
--- a/templates/stockcomponent/edit_xref_pck_item.tpl
+++ b/templates/stockcomponent/edit_xref_pck_item.tpl
@@ -9,6 +9,7 @@
<input type="hidden" name="content_id" value="{$xrefInfo.content_id|escape}" />
<input type="hidden" name="xref_id" value="{$xrefInfo.xref_id|escape}" />
<input type="hidden" name="item" value="{$xrefInfo.item|escape}" />
+ <input type="hidden" name="xorder" value="{$xrefInfo.xorder|escape}" />
<div class="form-group">
{formlabel label="Pack Size" for="xkey"}
diff --git a/templates/stockcomponent/edit_xref_sup_item.tpl b/templates/stockcomponent/edit_xref_sup_item.tpl
index 3411efb..408bbca 100644
--- a/templates/stockcomponent/edit_xref_sup_item.tpl
+++ b/templates/stockcomponent/edit_xref_sup_item.tpl
@@ -9,6 +9,7 @@
<input type="hidden" name="content_id" value="{$xrefInfo.content_id|escape}" />
<input type="hidden" name="xref_id" value="{$xrefInfo.xref_id|escape}" />
<input type="hidden" name="item" value="{$xrefInfo.item|escape}" />
+ <input type="hidden" name="xorder" value="{$xrefInfo.xorder|escape}" />
{if $xrefInfo.xref_title}
<div class="form-group">