p4535992 / foundryvtt-inventory-plus

A Foundry VTT module to enhance the dnd5e inventory. Allows to customize your Inventory in various ways.
GNU General Public License v3.0
3 stars 3 forks source link

[BUG] Adding Item to category will add to the top category instead #27

Open KellethDregar opened 1 year ago

KellethDregar commented 1 year ago

Module Version: v0.6.22

Describe the bug When adding an item to a category it will always add it to the topmost category. For example adding items with the plus symbol button will create a new item in the Weapons category if that is at the top. I'm unable to find any conclusive bugs or errors in the console since it is functionally still creates an item just in the very first category instead of the lower ones. After disabling inventory+ the functionality works as normal.

To Reproduce Steps to reproduce the behavior:

  1. Go to a PC character sheet
  2. Click on the add item to category + button for any category, i used the loot and equipment one
  3. The item will be added to the top most category instead of the correct one you added it for, for me it was weapons

Expected behavior New item is populated to the incorrect category

Browser: Google Chrome

Foundry Version: 10.291

Game System: DND5e

Kelmey commented 1 year ago

I'm experiencing this as well.

However for me, both Inventory+ and Tidy5e Sheet has to be enabled

If only inventory+ is enabled things still are odd but I can sometimes add items to the chosen category. Sometimes I create the wrong type of item. It really like to add weapons, even when it shouldn't. =)

If I create a new category I can't add anything to it with this error in console. inventory-plus.js:1200 Uncaught (in promise) TypeError: Cannot read properties of undefined (reading 'id') [Detected 1 package: inventory-plus] at InventoryPlus._onItemCreate (inventory-plus.js:1200:30) at HTMLAnchorElement.<anonymous> (inventory-plus.js:369:22) at HTMLAnchorElement.dispatch (jquery.min.js:2:43064) at y.handle (jquery.min.js:2:41048) _onItemCreate @ inventory-plus.js:1200 (anonymous) @ inventory-plus.js:369 dispatch @ jquery.min.js:2 y.handle @ jquery.min.js:2

idiotekque commented 1 year ago

Just adding another experience here; I have the same issue as Kelmey. Whenever I have Inventory+ and Tidy5e Sheet active, any newly created items are created in the top category (as weapons, for me).

Foundry Version: 10.291, app

Game System: DND5e

p4535992 commented 1 year ago

Due to lack of free time I can't devote as much time to this module as I would like and since version 2.2.X of the system makes several changes including the integration of bags I don't know if it is worth fixing things up only to see everything destroyed again . I will definitely wait for the 2.2.0 version of the system before attempting the upgrade, my advice remains what I have already said to use the "Item Collection" module .