812a41dc by joe

1

1 parent 0372c039
......@@ -781,11 +781,11 @@ module.exports = {
t5PaymentBank: "Bank",
t5PaymentAccount: "Payment Account",
t6Title: "Payment History",
t6PaymentPeriod: "Installment",
t6PaymentMethod: "Mode of Payment",
t6ClosingDate: "Received Date",
t6PaymentAmount: "Amount",
t6Title: "Payment Record",
t6PaymentPeriod: "Premium Payment Term",
t6PaymentMethod: "Payment Method",
t6ClosingDate: "Premium Settlement Date",
t6PaymentAmount: "Payment Amount",
showMore: "Show all policies.",
noPolicy: "You haven't bought any policy, if you have any questions please",
......
......@@ -8,7 +8,7 @@ import {
import Auth from '@components/auth/auth.vue';
import PolicyHeadList from "./policy-head-list.vue";
import { formatMoney, getInsuredPeriod, getBenefitType, getPayPeriod, getPayType, getMoneyName, getPayMode,getPolicyName } from "@/utils/biz.js";
import { formatMoney, getInsuredPeriod, getBenefitType, getPayPeriod, getPayType, getMoneyName, getPayMode, getPolicyName } from "@/utils/biz.js";
export default {
name: "InsuranceQuery",
......@@ -117,12 +117,34 @@ export default {
case "tc":
return "第" + y + "年第" + p + "期";
default:
return "Year " + y + " issue " + p;
return this.formatNumber(p) + " payment in " + this.formatNumber(y) + " year";
}
},
formatPolicyName(c, n) {
return getPolicyName(this.$i18n.locale, c, c);
},
formatNumber(p) {
let pmod = p % 4;
let pstr = p + "";
switch (pmod) {
case 0:
pstr += "th";
break;
case 1:
pstr += "st";
break;
case 2:
pstr += "nd";
break;
case 3:
pstr += "rd";
break;
default:
pstr += "th";
break;
}
return pstr;
},
userLogout() {
this.showForm = false;
},
......