From 99166ee66448ca0bc7591b50a153b9c54c285db5 Mon Sep 17 00:00:00 2001 From: dhb52 Date: Sun, 9 Apr 2023 13:41:14 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20Merge=E5=90=8E=E7=9A=84=E4=BF=AE?= =?UTF-8?q?=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/mp/autoReply/index.vue | 105 +++++++++--------- .../mp/components/wx-material-select/main.vue | 1 - src/views/mp/menu/index.vue | 7 +- 3 files changed, 56 insertions(+), 57 deletions(-) diff --git a/src/views/mp/autoReply/index.vue b/src/views/mp/autoReply/index.vue index 35fbc504..34aadbd2 100644 --- a/src/views/mp/autoReply/index.vue +++ b/src/views/mp/autoReply/index.vue @@ -3,32 +3,33 @@ - - - - - - - - 搜索 - 重置 - - - - + + + + + + + + 搜索 + 重置 + + + + + + @@ -36,7 +37,6 @@ + - + + - + @@ -211,7 +216,7 @@ import { } from '@/api/mp/autoReply' import { DICT_TYPE, getDictOptions } from '@/utils/dict' -import { formatDate } from '@/utils/formatTime' +import { dateFormatter } from '@/utils/formatTime' import { ContentWrap } from '@/components/ContentWrap' const message = useMessage() @@ -226,7 +231,7 @@ const requestMessageTypes = ['text', 'image', 'voice', 'video', 'shortvideo', 'l // 遮罩层 const loading = ref(true) // 显示搜索条件 -const showSearch = ref(true) +// const showSearch = ref(true) // 总条数 const total = ref(0) // 自动回复列表 @@ -257,14 +262,14 @@ const rules = { const hackResetWxReplySelect = ref(false) // 重置 WxReplySelect 组件,解决无法清除的问题 // 公众号账号列表 -const accounts = ref([]) +const accountList = ref([]) onMounted(() => { getSimpleAccountList().then((data) => { - accounts.value = data + accountList.value = data // 默认选中第一个 - if (accounts.value.length > 0) { - queryParams.accountId = accounts.value[0].id + if (accountList.value.length > 0) { + queryParams.accountId = accountList.value[0].id } // 加载数据 getList() @@ -303,8 +308,8 @@ const handleQuery = () => { const resetQuery = () => { queryFormRef.value?.resetFields() // 默认选中第一个 - if (accounts.value.length > 0) { - queryParams.accountId = accounts.value[0].id + if (accountList.value.length > 0) { + queryParams.accountId = accountList.value[0].id } handleQuery() } @@ -336,14 +341,14 @@ const handleUpdate = (row) => { getAutoReply(row.id).then((data) => { // 设置属性 form.value = { ...data } - delete form.value['responseMessageType'] + delete form.value['responsType'] delete form.value['responseContent'] delete form.value['responseMediaId'] delete form.value['responseMediaUrl'] delete form.value['responseDescription'] delete form.value['responseArticles'] objData.value = { - type: data.responseMessageType, + type: data.responsType, accountId: queryParams.accountId, content: data.responseContent, mediaId: data.responseMediaId, @@ -371,7 +376,7 @@ const handleSubmit = () => { // 处理回复消息 const form = { ...form.value } - form.responseMessageType = objData.value.type + form.responsType = objData.value.type form.responseContent = objData.value.content form.responseMediaId = objData.value.mediaId form.responseMediaUrl = objData.value.url diff --git a/src/views/mp/components/wx-material-select/main.vue b/src/views/mp/components/wx-material-select/main.vue index 1a8cc3df..7f565823 100644 --- a/src/views/mp/components/wx-material-select/main.vue +++ b/src/views/mp/components/wx-material-select/main.vue @@ -47,7 +47,6 @@ />