쿠폰 관리 페이지 추가 #18

Merged
klaus merged 3 commits from test into main 2024-01-03 10:33:24 +00:00
1 changed files with 9 additions and 1 deletions
Showing only changes of commit 2ea2421f7c - Show all commits

View File

@ -202,7 +202,7 @@
</template>
<template v-slot:item.couponNumber="{ item }">
{{ item.couponNumber }}
{{ formatWithHyphens(item.couponNumber) }}
</template>
<template v-slot:item.isUsed="{ item }">
@ -431,6 +431,14 @@ export default {
this.coupon_number_count = null
},
formatWithHyphens(value) {
const chunks = [];
for (let i = 0; i < value.length; i += 4) {
chunks.push(value.substr(i, 4));
}
return chunks.join('-');
},
async getCouponList() {
this.isLoading = true
try {