Bug: Trade items move to wrong column after editing twice
When you edit a trade, save it, and edit it again, all items move to the left
(gain) column - even the ones that should be in the right (loss) column.
Reproduce:
- Create trade: 1x Gold (gain), 5x Silver (loss) → Save
- Edit → looks correct → Save again
- Edit again → All items are now in the gain column
Expected: Items stay in their columns
Actual: Loss items move to gain column after second edit
Root cause:
templates/local/trade/item_table_data_loss.mustache line 22 uses the wrong
template:
{{#lossitems}}
{{>block_stash/trade_add_item_detail}}
{{/lossitems}}
This renders <input name="add_item[]"> instead of <input name="lose_item[]">, so PHP saves everything as gain items.
Fix: Change line 22 to {{>block_stash/trade_loss_item_detail}}
Bug: Trade items move to wrong column after editing twice
When you edit a trade, save it, and edit it again, all items move to the left
(gain) column - even the ones that should be in the right (loss) column.
Reproduce:
Expected: Items stay in their columns
Actual: Loss items move to gain column after second edit
Root cause:
templates/local/trade/item_table_data_loss.mustacheline 22 uses the wrongtemplate:
This renders
<input name="add_item[]">instead of<input name="lose_item[]">, so PHP saves everything as gain items.Fix: Change line 22 to {{>block_stash/trade_loss_item_detail}}