[breaking change] Coupon: use camelcase data (#1643)

This commit is contained in:
neverland
2018-08-17 15:20:08 +08:00
committed by GitHub
parent bf7b84fee6
commit abd4819ca1
5 changed files with 25 additions and 21 deletions
+3 -3
View File
@@ -34,7 +34,7 @@ export default create({
computed: {
validPeriod() {
return `${this.$t('valid')}${this.getDate(this.data.start_at)} - ${this.getDate(this.data.end_at)}`;
return `${this.$t('valid')}${this.getDate(this.data.startAt)} - ${this.getDate(this.data.endAt)}`;
},
faceAmount() {
@@ -46,9 +46,9 @@ export default create({
},
conditionMessage() {
let condition = this.data.origin_condition;
let condition = this.data.originCondition;
condition = condition % 100 === 0 ? Math.round(condition / 100) : (condition / 100).toFixed(2);
return this.data.origin_condition === 0 ? this.$t('unlimited') : this.$t('condition', condition);
return this.data.originCondition === 0 ? this.$t('unlimited') : this.$t('condition', condition);
}
},