diff --git a/src/assets/main.css b/src/assets/main.css index c133f9156b43080992482c4805bb9d6ad813c187..47fe76011f86338b112c9d3fdcbeb00147c13544 100644 --- a/src/assets/main.css +++ b/src/assets/main.css @@ -3,7 +3,7 @@ #app { max-width: 1280px; margin: 0 auto; - padding: 2rem; + padding: 1rem; font-weight: normal; } @@ -30,6 +30,6 @@ a, #app { display: grid; grid-template-columns: 1fr 1fr; - padding: 0 2rem; + padding: 0 1rem; } } diff --git a/src/views/VoucherNormal/assets/constant.js b/src/views/VoucherNormal/assets/constant.js index 7964eb6cbcd3c402ff33276edbbb7a7e7e511fd4..88380e4553ce084c0fb3619ee7b0d00bee438437 100644 --- a/src/views/VoucherNormal/assets/constant.js +++ b/src/views/VoucherNormal/assets/constant.js @@ -84,3 +84,18 @@ export const BANNER_JSON = { } } } + +export const getStatusFromBackEnd = (statusTag) => { + switch (statusTag) { + case CARD_STATUS_BACKEND.VALID: + return CARD_STATUS.CANUSE + case CARD_STATUS_BACKEND.USED: + return CARD_STATUS.USED + case CARD_STATUS_BACKEND.LOCKED: + case CARD_STATUS_BACKEND.NOT_VALID: + case CARD_STATUS_BACKEND.EXPIRED: + return CARD_STATUS.UNAVAILABLE + default: + return CARD_STATUS.CANUSE + } +} diff --git a/src/views/VoucherNormal/components/BannerCard.vue b/src/views/VoucherNormal/components/BannerCard.vue new file mode 100644 index 0000000000000000000000000000000000000000..a1f465675a3bd226129a922f5892bdbcc11767c1 --- /dev/null +++ b/src/views/VoucherNormal/components/BannerCard.vue @@ -0,0 +1,204 @@ + + + \ No newline at end of file diff --git a/src/views/VoucherNormal/components/BannerFlag.vue b/src/views/VoucherNormal/components/BannerFlag.vue new file mode 100644 index 0000000000000000000000000000000000000000..a6c6acfd27c2f23271b8e77e0b25e47ef1e3f5ea --- /dev/null +++ b/src/views/VoucherNormal/components/BannerFlag.vue @@ -0,0 +1,90 @@ + + + \ No newline at end of file diff --git a/src/views/VoucherNormal/components/BannerSection.vue b/src/views/VoucherNormal/components/BannerSection.vue new file mode 100644 index 0000000000000000000000000000000000000000..a45ea0dd82304840ce3935c9f186903adc64ddd4 --- /dev/null +++ b/src/views/VoucherNormal/components/BannerSection.vue @@ -0,0 +1,63 @@ + + + \ No newline at end of file diff --git a/src/views/VoucherNormal/components/StairNewUserBanner.vue b/src/views/VoucherNormal/components/StairNewUserBanner.vue index 60963540d688d60f1ec3aadaa2d80bd118f71516..a3ddbf57851048c0bf516299f7f278cee21bd540 100644 --- a/src/views/VoucherNormal/components/StairNewUserBanner.vue +++ b/src/views/VoucherNormal/components/StairNewUserBanner.vue @@ -49,6 +49,7 @@ import { onMounted, onBeforeUnmount, ref, computed } from 'vue' import { findLastIndex } from 'lodash-es' import { getTimes } from '../assets/utils' import { BANNER_JSON, SCENE, CATEGORY, TASK_STATUS } from '../assets/constant.js' +import BannerSection from './BannerSection.vue' const props = withDefaults(defineProps<{ bannerData: any }>(), { bannerData: ()=> ({}) @@ -168,6 +169,25 @@ const jumpPage = () => { \ No newline at end of file diff --git a/src/views/VoucherNormal/index.vue b/src/views/VoucherNormal/index.vue index 6e80c90c23e8511607b8c5da49d402c954f2a5f6..ee13c23da74b6f78d162e42500dea91b9c27c1d3 100644 --- a/src/views/VoucherNormal/index.vue +++ b/src/views/VoucherNormal/index.vue @@ -37,5 +37,26 @@ const onChange = (index) => {