From 2aa5ccf17bf90cce708c69cd64804fab929b66b0 Mon Sep 17 00:00:00 2001 From: weipengfei <2187978347@qq.com> Date: Fri, 21 Jun 2024 15:45:11 +0800 Subject: [PATCH] 1 --- .env.development | 4 +-- src/views/statistics/product/index.vue | 2 +- .../statistics/statistics_user/index.vue | 2 +- src/views/statistics/transaction/index.vue | 6 ++--- src/views/store/statistics/index.vue | 9 ++++++- src/views/store/store_product/details.vue | 26 ++++++++++++++++++- src/views/store/store_product/edit.vue | 18 ++++++++----- src/views/store/store_product/index.vue | 6 ++--- src/views/user/details.vue | 8 ++++-- src/views/user/indexList.vue | 18 ++++++++----- 10 files changed, 71 insertions(+), 28 deletions(-) diff --git a/.env.development b/.env.development index 9a547cc1..5cf9da4f 100644 --- a/.env.development +++ b/.env.development @@ -2,5 +2,5 @@ NODE_ENV = 'development' VITE_NOW_TYPE = 'dist' # Base API -VITE_APP_BASE_URL='http://192.168.1.22:8545' -# VITE_APP_BASE_URL='https://test-multi-store.lihaink.cn' +# VITE_APP_BASE_URL='http://192.168.1.22:8545' +VITE_APP_BASE_URL='https://test-multi-store.lihaink.cn' diff --git a/src/views/statistics/product/index.vue b/src/views/statistics/product/index.vue index ea3cea1f..596a0b14 100644 --- a/src/views/statistics/product/index.vue +++ b/src/views/statistics/product/index.vue @@ -230,7 +230,7 @@ const basicList = reactive([ percent: 0 } ]) -const startEndTime = ref(['', '']); +const startEndTime = ref([new Date(), new Date()]); // 获取数据 const getData = () => { let date = ''; diff --git a/src/views/statistics/statistics_user/index.vue b/src/views/statistics/statistics_user/index.vue index d2cee870..3c25cf01 100644 --- a/src/views/statistics/statistics_user/index.vue +++ b/src/views/statistics/statistics_user/index.vue @@ -200,7 +200,7 @@ const basicList = reactive([ percent: 0 } ]) -const startEndTime = ref(['', '']); +const startEndTime = ref([new Date(), new Date()]); // 获取数据 const getData = () => { let date = ''; diff --git a/src/views/statistics/transaction/index.vue b/src/views/statistics/transaction/index.vue index 4016d5dc..426ba95c 100644 --- a/src/views/statistics/transaction/index.vue +++ b/src/views/statistics/transaction/index.vue @@ -66,7 +66,7 @@
{{ item.name }}
{{ item.money }}
环比增长: {{ - item.rate / 100 }}%
+ item.rate }}% @@ -288,9 +288,9 @@ const rightOption2: any = reactive(JSON.parse(JSON.stringify(optionModel))) // 颜色 const colorList = ['#5DB1FF', '#4CD384', '#FFC46A', '#CAA5F1', '#FFC46A', '#4CD384', '#5DB1FF', '#CAA5F1'] // 商品浏览量, 商品访客数, 加购件数, 下单件数, 支付件数, 支付金额, 成本金额, 退款金额, 退款件数, 访客-支付转化率 -const iconList = ref(['RectangleCopy58', 'RectangleCopy48', 'RectangleCopy65', 'RectangleCopy62', 'RectangleCopy56', 'RectangleCopy55', 'RectangleCopy57', 'RectangleCopy65']); +const iconList = ref(['RectangleCopy58', 'RectangleCopy48', 'RectangleCopy65', 'RectangleCopy62', 'RectangleCopy56', 'RectangleCopy55', 'RectangleCopy57', 'RectangleCopy65', 'RectangleCopy61', 'RectangleCopy52', 'RectangleCopy14', 'RectangleCopy32']); -const startEndTime = ref(['', '']); +const startEndTime = ref([new Date(), new Date()]); // 获取数据 const getData = () => { let date = ''; diff --git a/src/views/store/statistics/index.vue b/src/views/store/statistics/index.vue index d4886bc0..5651a76f 100644 --- a/src/views/store/statistics/index.vue +++ b/src/views/store/statistics/index.vue @@ -246,8 +246,15 @@ const basicList = reactive([ num: 0, }, + { + name: '保证金', + type: 'deposit_amount', + icon: 'RectangleCopy32', + num: 0, + + }, ]) -const startEndTime = ref(['', '']); +const startEndTime = ref([new Date(), new Date()]); const store_id = ref(''); const formData = ref({}); const tradTypeOption = reactive( diff --git a/src/views/store/store_product/details.vue b/src/views/store/store_product/details.vue index b6a17c47..630d0c62 100644 --- a/src/views/store/store_product/details.vue +++ b/src/views/store/store_product/details.vue @@ -19,7 +19,11 @@ {{ formData.stock }} {{ formData.cost }} {{ formData.purchase }} - {{ formData.rose }} + {{ formData.rose }} + + +
{{ cMark(formData.manufacturer_information) }}
+
@@ -141,6 +145,7 @@ const formData = reactive({ cost: "", purchase: "", rose: "0", + manufacturer_information: "" }) @@ -155,6 +160,25 @@ const setFormData = async (data: Record) => { formData[key] = data[key] } } + +} + +const cMark = (str:any)=>{ + if(str){ + return str.replace(/(\d{5,})/g, (match:string) => { + let replacement; + // 判断数字长度,执行不同替换逻辑 + if (match.length >= 11) { + // 对于11位以上的连续数字,替换倒数第四到倒数第八位为星号 + replacement = match.slice(0, -8) + "****" + match.slice(-4); + } else { + // 对于5到11位的数字,替换最后四位为星号 + replacement = match.slice(0, -4) + "****"; + } + return replacement; + }); + } + return '-'; } const getDetail = async (row: Record) => { diff --git a/src/views/store/store_product/edit.vue b/src/views/store/store_product/edit.vue index 472267c7..29a28a46 100644 --- a/src/views/store/store_product/edit.vue +++ b/src/views/store/store_product/edit.vue @@ -31,21 +31,24 @@ - - - - - + + - - + + + + + + + + + 新增 + + + 删除 + -->
@@ -53,9 +53,13 @@ - + + + - +