diff --git a/rpg-docs/Model/Inventory/Items.js b/rpg-docs/Model/Inventory/Items.js index c316f573..b63b8eec 100644 --- a/rpg-docs/Model/Inventory/Items.js +++ b/rpg-docs/Model/Inventory/Items.js @@ -27,7 +27,7 @@ Items.helpers({ return this.weight * this.quantity; }, pluralName: function(){ - if(this.plural && this.quantity > 1){ + if(this.plural && this.quantity !== 1){ return this.plural; } else{ return this.name; diff --git a/rpg-docs/client/views/character/inventory/itemDialog/itemDialog.html b/rpg-docs/client/views/character/inventory/itemDialog/itemDialog.html index 470d3a89..00e167b0 100644 --- a/rpg-docs/client/views/character/inventory/itemDialog/itemDialog.html +++ b/rpg-docs/client/views/character/inventory/itemDialog/itemDialog.html @@ -14,7 +14,7 @@
- {{# if quantity}}{{/if}} + {{# if ne1 quantity}}{{/if}} {{# if canEquip}}
diff --git a/rpg-docs/client/views/character/inventory/itemDialog/itemDialog.js b/rpg-docs/client/views/character/inventory/itemDialog/itemDialog.js index 01254e10..b31804e6 100644 --- a/rpg-docs/client/views/character/inventory/itemDialog/itemDialog.js +++ b/rpg-docs/client/views/character/inventory/itemDialog/itemDialog.js @@ -116,5 +116,8 @@ Template.itemDialog.helpers({ }, canEquip: function(){ return this.equipmentSlot !== "none"; + }, + ne1: function(num){ + return num != 1; } -}); \ No newline at end of file +});