diff --git a/public/img/agri_bg.png b/public/img/agri_bg.png deleted file mode 100644 index db09db5..0000000 Binary files a/public/img/agri_bg.png and /dev/null differ diff --git a/public/img/point.png b/public/img/point.png new file mode 100644 index 0000000..0ce389a Binary files /dev/null and b/public/img/point.png differ diff --git a/public/img/pointmall_bg.jpg b/public/img/pointmall_bg.jpg new file mode 100644 index 0000000..d0134a0 Binary files /dev/null and b/public/img/pointmall_bg.jpg differ diff --git a/src/router.js b/src/router.js index 9921492..4b8a42c 100644 --- a/src/router.js +++ b/src/router.js @@ -18,7 +18,7 @@ const routes = [ path: '/Gift', name: 'Gift', component: () => import('./views/Tabbars/Gift.vue'), - meta: { title: '礼品区', cache: true } + meta: { title: '礼包区', cache: true } }, { path: '/Mall', @@ -26,6 +26,12 @@ const routes = [ component: () => import('./views/Tabbars/Mall.vue'), meta: { title: '商城', cache: true } }, + { + path: '/PointMall', + name: 'PointMall', + component: () => import('./views/Tabbars/PointMall.vue'), + meta: { title: '积分区', cache: true } + }, { path: '/My', name: 'My', @@ -184,13 +190,13 @@ const routes = [ path: '/Business_School', name: 'Business_School', component: () => import('./views/Platform/Business_School.vue'), - meta: { title: '商学院', noLogin: true, cache: true } + meta: { title: '商学院', noLogin: true } }, { path: '/School_detail', name: 'School_detail', component: () => import('./views/Platform/School_Detail.vue'), - meta: { title: '商学院详情', noLogin: true, cache: true } + meta: { title: '商学院详情', noLogin: true, } }, { path: '/School_Category', @@ -202,13 +208,13 @@ const routes = [ path: '/Column', name: 'Column', component: () => import('./views/Platform/Column.vue'), - meta: { title: '栏目列表', noLogin: true, cache: true } + meta: { title: '栏目列表', noLogin: true } }, { path: '/ColumnDetail', name: 'ColumnDetail', component: () => import('./views/Platform/ColumnDetail.vue'), - meta: { title: '栏目详情', noLogin: true, cache: true } + meta: { title: '栏目详情', noLogin: true } }, { path: '/GoodsDetail', diff --git a/src/stores/datadic.js b/src/stores/datadic.js index 32d689a..f1ca89a 100644 --- a/src/stores/datadic.js +++ b/src/stores/datadic.js @@ -1,9 +1,10 @@ import { defineStore } from 'pinia' import { get } from '@/api/http' -// Module level cache for quick access export let dictCache = {} +const SESSION_KEY = 'dict_cache' + export const useDatadicStore = defineStore('datadic', { state: () => ({ dicts: {}, @@ -20,6 +21,18 @@ export const useDatadicStore = defineStore('datadic', { }, actions: { async init() { + // 优先从 sessionStorage 读取缓存 + const cached = sessionStorage.getItem(SESSION_KEY) + if (cached) { + try { + dictCache = JSON.parse(cached) + this.dicts = dictCache + this.loaded = true + return + } catch (e) { + sessionStorage.removeItem(SESSION_KEY) + } + } if (this.loaded) return try { const res = await get('/v1/client/CDatadicsClient') @@ -29,6 +42,7 @@ export const useDatadicStore = defineStore('datadic', { }) this.dicts = dictCache this.loaded = true + sessionStorage.setItem(SESSION_KEY, JSON.stringify(dictCache)) } } catch (e) { console.error('数据字典加载失败', e) diff --git a/src/stores/user.js b/src/stores/user.js index e69c6f9..d7bd18c 100644 --- a/src/stores/user.js +++ b/src/stores/user.js @@ -1,5 +1,5 @@ import { defineStore } from 'pinia'; -import { post } from '@/api/http'; +import { get } from '@/api/http'; export const useUserStore = defineStore('user', { state: () => ({ @@ -64,7 +64,7 @@ export const useUserStore = defineStore('user', { */ async fetchUserInfo() { try { - const res = await post('/v1/client/UserClient/info'); + const res = await get('/v1/client/DUsersClient'); if (res.status === 200 && res.data) { this.setUser(res.data); } diff --git a/src/styles/ch.less b/src/styles/ch.less index 03f47ce..f55b5f2 100644 --- a/src/styles/ch.less +++ b/src/styles/ch.less @@ -384,10 +384,17 @@ .fast_to { .box; + .box-tb; .box-pack-between; - flex-wrap: wrap; + width: 100%; gap: 2.4vw; + >div { + .box; + gap: 2.4vw; + // margin-bottom: 2.4vw; + } + img { width: 44.8vw; height: 17.33vw; @@ -2073,6 +2080,7 @@ .banner img { width: 100%; margin-top: 3.07vw; + border-radius: 2.2vw; } .label_box { @@ -2146,6 +2154,7 @@ img { margin: 3.33vw 0 1.87vw; height: 14.4vw; + border-radius: 50%; } } } @@ -2457,6 +2466,7 @@ .box; .box-pack-between; flex-wrap: wrap; + flex-direction: row; } .good { diff --git a/src/styles/public.less b/src/styles/public.less index 7a155d4..dacc388 100644 --- a/src/styles/public.less +++ b/src/styles/public.less @@ -894,6 +894,29 @@ img { padding-bottom: 2.53vw; border-bottom: 1px solid #f5f5f580; + .state { + .box; + .box-center-center; + .bs; + height: 4.67vw; + padding: 0 1.2vw; + border-radius: 1.07vw; + margin-right: 1.2vw; + } + + .state1 { + background-color: #2990f0; + } + + .state3 { + background-color: #ea4747; + + } + + .state4 { + background-color: #229427; + } + img { width: 3.2vw; height: 3.2vw; @@ -903,6 +926,7 @@ img { .goods_box { .box; + .box-align-center; margin-top: 2.8vw; img { @@ -914,9 +938,9 @@ img { .goods_info { .box; .box-tb; - .box-pack-around; + .box-pack-between; width: 100%; - height: 21.33vw; + height: 18.33vw; >div { diff --git a/src/views/Account/Login.vue b/src/views/Account/Login.vue index febd9c3..d3695ac 100644 --- a/src/views/Account/Login.vue +++ b/src/views/Account/Login.vue @@ -80,7 +80,7 @@ - + 选中即代表同意《用户协议》《隐私政策》 @@ -357,7 +357,7 @@ export default { this.formData.Recommend = inviteCode; localStorage.setItem('recommend', inviteCode); // 有邀请码时自动切换到注册模式 - this.isReg = true; + // this.isReg = true; } }, beforeUnmount() { diff --git a/src/views/Account/WxCallback.vue b/src/views/Account/WxCallback.vue index ef658be..1002fcf 100644 --- a/src/views/Account/WxCallback.vue +++ b/src/views/Account/WxCallback.vue @@ -6,12 +6,12 @@ export default { mounted() { const url = new URL(window.location.href) const code = url.searchParams.get('code') + const inviteCode = url.searchParams.get('invite') if (code) { sessionStorage.setItem('wx_callback_code', code) - sessionStorage.setItem('wx_code_processed', '1') - // 跳转到登录页,让用户完成注册/登录 - this.$router.replace('/Login') + // 带上 invite 参数一起跳转,Login mounted 时读取 + this.$router.replace('/Login' + (inviteCode ? `?invite=${inviteCode}` : '')) } else { this.$router.replace('/') } diff --git a/src/views/Cashout/CashoutAccount.vue b/src/views/Cashout/CashoutAccount.vue index 2fedfd8..4a516fc 100644 --- a/src/views/Cashout/CashoutAccount.vue +++ b/src/views/Cashout/CashoutAccount.vue @@ -11,15 +11,8 @@
- {{ i.bankspname === '支付宝' ? '支付宝账号' : i.bankspname }}({{ i.bankid === 91 ? i.bankcellphone - : i.bankcardnumber }}) + {{ i.realname }}({{ i.bankcardnumber }}) -

- 2小时内到账 -

-

- {{ i.realname }} -

@@ -100,9 +93,10 @@ :formatter="formatter" /> - + @click="showBankPicker = true" /> --> @@ -127,9 +121,9 @@ @finish="onFinish" @close="showRegion = false" /> - + @@ -142,13 +136,11 @@ export default { name: 'CashoutAccount', mounted() { this.init(); - this.getBankId() }, data() { return { showAddAliPayPopup: false, showAddPopup: false, - showBankPicker: false, tempData: {}, saving: false, checked: 0, @@ -160,7 +152,6 @@ export default { maxDate: new Date('2099/12/31'), regionName: '', region: '', - bankidGroup: {}, areaList: useCascaderAreaData(), defaultProps: { text: 'text', @@ -170,9 +161,6 @@ export default { } }, computed: { - bankColumns() { - return this.bankidGroup.map(item => ({ text: item.name, value: item.id })); - } }, methods: { init() { @@ -185,11 +173,6 @@ export default { formatter(value) { return value.replace(/\s/g, ''); }, - getBankId() { - this.$get('/v1/client/DBanksClient').then(res => { - this.bankidGroup = res.data; - }) - }, onChange({ selectedOptions }) { this.tempData.provid = selectedOptions[0]?.value || ''; }, @@ -199,14 +182,6 @@ export default { this.tempData.provid = selectedOptions[0]?.value || ''; this.tempData.areaid = selectedOptions[1]?.value || selectedOptions[0]?.value || ''; }, - onBankConfirm({ selectedValues }) { - const bank = this.bankidGroup.find(item => item.id === selectedValues[0]); - if (bank) { - this.tempData.bankid = bank.id; - this.tempData.bankname = bank.name; - } - this.showBankPicker = false; - }, onconfirm({ selectedValues }) { const date = selectedValues.join('-'); if (this.tempData.obj === 'certbegindate') { @@ -245,7 +220,7 @@ export default { "realname": this.tempData.realname, "idnumber": this.tempData.idnumber, "bankid": this.tempData.bankid || 0, - "bankname": this.tempData.bankname || '', + // "bankname": this.tempData.bankname || '', "bankcardnumber": this.tempData.bankcardnumber, "bankcellphone": this.tempData.bankcellphone, "sort": 0, diff --git a/src/views/Goods/GoodsDetail.vue b/src/views/Goods/GoodsDetail.vue index 11d7dd4..4b1bd34 100644 --- a/src/views/Goods/GoodsDetail.vue +++ b/src/views/Goods/GoodsDetail.vue @@ -1,5 +1,5 @@