diff options
| author | Lester Caine <lester@lsces.co.uk> | 2026-06-16 08:39:59 +0100 |
|---|---|---|
| committer | Lester Caine <lester@lsces.co.uk> | 2026-06-16 08:39:59 +0100 |
| commit | 894b67457d9272b3726790fa103332bf250d2a4b (patch) | |
| tree | b5bf8901693be98094bbb375e708ac1058a3771a /edit_movement.php | |
| parent | 660e448b34944e9cad136a30dbb31a081c4fc153 (diff) | |
| download | stock-894b67457d9272b3726790fa103332bf250d2a4b.tar.gz stock-894b67457d9272b3726790fa103332bf250d2a4b.tar.bz2 stock-894b67457d9272b3726790fa103332bf250d2a4b.zip | |
Fix ref_key not loading on edit; restrict movement type to ORDER/TRANS
Add ref_key (xkey) subquery to StockMovement::load() — it was present in
getList() but missing from load(), so the field always appeared blank on edit.
Filter edit_movement.php refTypes query to ORDER and TRANS only; REQN and
PBLD are created via their own dedicated entry points.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Diffstat (limited to 'edit_movement.php')
| -rw-r--r-- | edit_movement.php | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/edit_movement.php b/edit_movement.php index defc9f4..588065b 100644 --- a/edit_movement.php +++ b/edit_movement.php @@ -29,6 +29,7 @@ $refTypes = $gBitDb->getAssoc( FROM `".BIT_DB_PREFIX."liberty_xref_item` xi JOIN `".BIT_DB_PREFIX."liberty_xref_group` xg ON xg.`x_group` = xi.`x_group` AND xg.`content_type_guid` = xi.`content_type_guid` WHERE xi.`content_type_guid` = '".STOCKMOVEMENT_CONTENT_TYPE_GUID."' AND xi.`x_group` = 'reference' + AND xi.`item` IN ('ORDER','TRANS') ORDER BY xi.`item`" ); |
