From df3b381d6fc340489b825906f1f39fe0e0687442 Mon Sep 17 00:00:00 2001 From: dhb52 Date: Wed, 12 Apr 2023 13:29:24 +0800 Subject: [PATCH 1/6] =?UTF-8?q?refactor:=20mp=E6=A8=A1=E5=9D=97ts=E9=87=8D?= =?UTF-8?q?=E6=9E=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/mp/autoReply/index.vue | 277 ++++++---- src/views/mp/components/WxMpSelect.vue | 22 +- .../mp/components/wx-editor/WxEditor.vue | 115 +---- src/views/mp/draft/index.vue | 475 +++++++++--------- src/views/mp/freePublish/index.vue | 33 +- src/views/mp/material/index.vue | 92 ++-- src/views/mp/menu/index.vue | 76 +-- src/views/mp/tag/TagForm.vue | 19 +- src/views/mp/tag/index.vue | 45 +- src/views/mp/user/index.vue | 86 +++- src/views/pay/order/orderForm.vue | 152 ++++++ src/views/pay/refund/refundForm.vue | 154 ++++++ 12 files changed, 943 insertions(+), 603 deletions(-) create mode 100644 src/views/pay/order/orderForm.vue create mode 100644 src/views/pay/refund/refundForm.vue diff --git a/src/views/mp/autoReply/index.vue b/src/views/mp/autoReply/index.vue index 9208d1e7..94fe34b3 100644 --- a/src/views/mp/autoReply/index.vue +++ b/src/views/mp/autoReply/index.vue @@ -3,13 +3,16 @@ - - + + + + + - + @@ -18,26 +21,26 @@ plain @click="handleAdd" v-hasPermi="['mp:auto-reply:create']" - v-if="type !== '1' || list.length <= 0" + v-if="msgType !== MsgType.Follow || list.length <= 0" > 新增 - + - + - + @@ -47,10 +50,20 @@ label="请求消息类型" align="center" prop="requestMessageType" - v-if="type === '2'" + v-if="msgType === MsgType.Message" /> - - + + @@ -64,7 +77,7 @@ - diff --git a/src/views/mp/components/wx-editor/WxEditor.vue b/src/views/mp/components/wx-editor/WxEditor.vue index 50c65c6e..cf384113 100644 --- a/src/views/mp/components/wx-editor/WxEditor.vue +++ b/src/views/mp/components/wx-editor/WxEditor.vue @@ -1,11 +1,11 @@ diff --git a/src/views/mp/freePublish/index.vue b/src/views/mp/freePublish/index.vue index 0d370f4a..7a15b31f 100644 --- a/src/views/mp/freePublish/index.vue +++ b/src/views/mp/freePublish/index.vue @@ -3,8 +3,17 @@ - - + + + + + @@ -39,26 +48,32 @@ - diff --git a/src/views/pay/order/orderForm.vue b/src/views/pay/order/orderForm.vue new file mode 100644 index 00000000..f9625085 --- /dev/null +++ b/src/views/pay/order/orderForm.vue @@ -0,0 +1,152 @@ + + + diff --git a/src/views/pay/refund/refundForm.vue b/src/views/pay/refund/refundForm.vue new file mode 100644 index 00000000..cc9d8726 --- /dev/null +++ b/src/views/pay/refund/refundForm.vue @@ -0,0 +1,154 @@ + + + + From fbbf4131f67706d77042744813a865b0c16e29e7 Mon Sep 17 00:00:00 2001 From: dhb52 Date: Wed, 12 Apr 2023 14:05:21 +0800 Subject: [PATCH 2/6] =?UTF-8?q?fix:=20=E5=8E=BB=E9=99=A4WxLocation?= =?UTF-8?q?=E7=BB=84=E4=BB=B6=E5=A4=9A=E4=BD=99Location=E5=9B=BE=E6=A0=87?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/mp/components/wx-location/main.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/views/mp/components/wx-location/main.vue b/src/views/mp/components/wx-location/main.vue index 47eab571..17598136 100644 --- a/src/views/mp/components/wx-location/main.vue +++ b/src/views/mp/components/wx-location/main.vue @@ -31,7 +31,6 @@ /> - {{ label }} @@ -39,6 +38,7 @@ + + diff --git a/src/views/mp/draft/index.vue b/src/views/mp/draft/index.vue index 844d01b2..d9a44076 100644 --- a/src/views/mp/draft/index.vue +++ b/src/views/mp/draft/index.vue @@ -252,7 +252,6 @@ import * as MpFreePublishApi from '@/api/mp/freePublish' import type { UploadFiles, UploadProps, UploadRawFile } from 'element-plus' // 可以用改本地数据模拟,避免API调用超限 // import drafts from './mock' - const message = useMessage() // 消息 const loading = ref(true) // 列表的加载中 @@ -362,7 +361,7 @@ const submitForm = async () => { } finally { dialogNewsVisible.value = false addMaterialLoading.value = false - getList() + await getList() } } diff --git a/src/views/mp/material/index.vue b/src/views/mp/material/index.vue index 4d4017d4..81d8fb08 100644 --- a/src/views/mp/material/index.vue +++ b/src/views/mp/material/index.vue @@ -277,14 +277,11 @@ const uploadRules: FormRules = { } // 素材类型 -type MatertialType = 'image' | 'voice' | 'video' -const type = ref('image') -// 遮罩层 -const loading = ref(false) -// 总条数 -// 数据列表 -const list = ref([]) -const total = ref(0) +type MaterialType = 'image' | 'voice' | 'video' +const type = ref('image') +const loading = ref(false) // 遮罩层 +const list = ref([]) // 总条数 +const total = ref(0) // 数据列表 // 查询参数 interface QueryParams { pageNo: number @@ -302,7 +299,7 @@ const queryParams: QueryParams = reactive({ const fileList = ref([]) interface UploadData { - type: MatertialType + type: MaterialType title: string introduction: string } @@ -346,7 +343,7 @@ const handleQuery = () => { const onTabChange = (tabName: TabPaneName) => { // 设置 type - uploadData.type = tabName as MatertialType + uploadData.type = tabName as MaterialType // 提前情况数据,避免tab切换后显示垃圾数据 list.value = [] diff --git a/src/views/mp/tag/index.vue b/src/views/mp/tag/index.vue index 6dc0d11a..125c8702 100644 --- a/src/views/mp/tag/index.vue +++ b/src/views/mp/tag/index.vue @@ -71,11 +71,10 @@ diff --git a/src/views/pay/order/orderForm.vue b/src/views/pay/order/orderForm.vue deleted file mode 100644 index f9625085..00000000 --- a/src/views/pay/order/orderForm.vue +++ /dev/null @@ -1,152 +0,0 @@ - - - diff --git a/src/views/pay/refund/refundForm.vue b/src/views/pay/refund/refundForm.vue deleted file mode 100644 index cc9d8726..00000000 --- a/src/views/pay/refund/refundForm.vue +++ /dev/null @@ -1,154 +0,0 @@ - - - -