Ensured disabled effects don't show up in skill and attribute detail boxes

This commit is contained in:
Stefan Zermatten
2015-05-13 08:46:28 +02:00
parent a71519aaa7
commit 2122e543d5
2 changed files with 12 additions and 5 deletions

View File

@@ -106,27 +106,27 @@ Template.attributeDialogView.helpers({
},
baseEffects: function(){
return Effects.find(
{charId: this.charId, stat: this.statName, operation: "base"}
{charId: this.charId, stat: this.statName, operation: "base", enabled: true}
);
},
addEffects: function(){
return Effects.find(
{charId: this.charId, stat: this.statName, operation: "add"}
{charId: this.charId, stat: this.statName, operation: "add", enabled: true}
);
},
mulEffects: function(){
return Effects.find(
{charId: this.charId, stat: this.statName, operation: "mul"}
{charId: this.charId, stat: this.statName, operation: "mul", enabled: true}
);
},
minEffects: function(){
return Effects.find(
{charId: this.charId, stat: this.statName, operation: "min"}
{charId: this.charId, stat: this.statName, operation: "min", enabled: true}
);
},
maxEffects: function(){
return Effects.find(
{charId: this.charId, stat: this.statName, operation: "max"}
{charId: this.charId, stat: this.statName, operation: "max", enabled: true}
);
},
attributeBase: function(){

View File

@@ -132,6 +132,7 @@ Template.skillDialogView.helpers({
charId: this.charId,
stat: this.skillName,
operation: "add",
enabled: true,
});
},
mulEffects: function(){
@@ -139,6 +140,7 @@ Template.skillDialogView.helpers({
charId: this.charId,
stat: this.skillName,
operation: "mul",
enabled: true,
});
},
minEffects: function(){
@@ -146,6 +148,7 @@ Template.skillDialogView.helpers({
charId: this.charId,
stat: this.skillName,
operation: "min",
enabled: true,
});
},
maxEffects: function(){
@@ -153,6 +156,7 @@ Template.skillDialogView.helpers({
charId: this.charId,
stat: this.skillName,
operation: "max",
enabled: true,
});
},
advEffects: function(){
@@ -160,6 +164,7 @@ Template.skillDialogView.helpers({
charId: this.charId,
stat: this.skillName,
operation: "advantage",
enabled: true,
});
},
dadvEffects: function(){
@@ -167,6 +172,7 @@ Template.skillDialogView.helpers({
charId: this.charId,
stat: this.skillName,
operation: "disadvantage",
enabled: true,
});
},
conditionalEffects: function(){
@@ -174,6 +180,7 @@ Template.skillDialogView.helpers({
charId: this.charId,
stat: this.skillName,
operation: "conditional",
enabled: true,
});
},
ability: function(){