From 6fdd1cfcdfc95f41bbc16274775c7f4ba0c2480a Mon Sep 17 00:00:00 2001 From: j-sentinel <2724650486@qq.com> Date: Wed, 4 Oct 2023 18:32:53 +0800 Subject: [PATCH] =?UTF-8?q?[=E6=96=B0=E5=A2=9E][=E5=85=AC=E4=BC=97?= =?UTF-8?q?=E5=8F=B7]=E5=85=AC=E4=BC=97=E5=8F=B7=E6=A8=A1=E6=9D=BF?= =?UTF-8?q?=E7=AE=A1=E7=90=86=E5=90=8E=E7=AB=AF=E4=BB=A3=E7=A0=81=E6=8E=A5?= =?UTF-8?q?=E5=8F=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/mp/template/index.ts | 53 ++++++ src/api/mp/user/index.ts | 8 + src/views/mp/template/SendMessage.vue | 228 +++++++++++++++++++++++++ src/views/mp/template/TemplateForm.vue | 180 +++++++++++++++++++ src/views/mp/template/index.vue | 187 ++++++++++++++++++++ 5 files changed, 656 insertions(+) create mode 100644 src/api/mp/template/index.ts create mode 100644 src/views/mp/template/SendMessage.vue create mode 100644 src/views/mp/template/TemplateForm.vue create mode 100644 src/views/mp/template/index.vue diff --git a/src/api/mp/template/index.ts b/src/api/mp/template/index.ts new file mode 100644 index 000000000..29c186dd7 --- /dev/null +++ b/src/api/mp/template/index.ts @@ -0,0 +1,53 @@ +import request from '@/config/axios' + +// 同步公众号模板 +export const syncTemplate = (accountId) => { + return request.post({ + url: '/mp/template/sync?accountId=' + accountId + }) +} + +// 获得公众号模板分页 +export const getTemplatePage = (query) => { + return request.get({ + url: '/mp/template/page', + params: query + }) +} + +// 获得公众号模板 +export const getTemplate = (id) => { + return request.get({ + url: '/mp/template/get?id=' + id + }) +} + +// 根据id获取模板 +export const getTemplateContent = (id) => { + return request.get({ + url: '/mp/template/contentGet?id=' + id + }) +} + +// 更新公众号模板 +export const updateTemplate = (data) => { + return request.put({ + url: '/mp/template/update', + data: data + }) +} + +// 删除公众号模板 +export const deleteTemplate = (id) => { + return request.delete({ + url: '/mp/template/delete?id=' + id + }) +} + +// 批量发送公众号模板 +export const sendMsgBatchTemplate = (data) => { + return request.post({ + url: '/mp/template/sendMsgBatch', + data: data + }) +} diff --git a/src/api/mp/user/index.ts b/src/api/mp/user/index.ts index d954e9eb1..5f39697b8 100644 --- a/src/api/mp/user/index.ts +++ b/src/api/mp/user/index.ts @@ -23,6 +23,14 @@ export const getUserPage = (query) => { }) } +// 获得公众号粉丝分页 +export const getUserPageEnhance = (query) => { + return request.get({ + url: '/mp/user/pageEnhance', + params: query + }) +} + // 同步公众号粉丝 export const syncUser = (accountId) => { return request.post({ diff --git a/src/views/mp/template/SendMessage.vue b/src/views/mp/template/SendMessage.vue new file mode 100644 index 000000000..b953ddec2 --- /dev/null +++ b/src/views/mp/template/SendMessage.vue @@ -0,0 +1,228 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 筛选 + 重置 + + + + + 消息预览: + + + + 本消息将发送给: + + + + {{ item.nickname }} + + ... + 等共( {{ totalCount }} )位用户 + + + + 发 送 + 取 消 + + + + + diff --git a/src/views/mp/template/TemplateForm.vue b/src/views/mp/template/TemplateForm.vue new file mode 100644 index 000000000..12513ff23 --- /dev/null +++ b/src/views/mp/template/TemplateForm.vue @@ -0,0 +1,180 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 消息填充数据,请对照模板内容填写 + + + + + + + + + + + + + + + + + + + 确 定 + 取 消 + + + + + diff --git a/src/views/mp/template/index.vue b/src/views/mp/template/index.vue new file mode 100644 index 000000000..fdb374fea --- /dev/null +++ b/src/views/mp/template/index.vue @@ -0,0 +1,187 @@ + + + + + + + + + + + + + + + 搜索 + 重置 + + 同步公众号模板 + + + + + + + + + + + + + + + + 推送消息 + + + 配置 + + + 删除 + + + + + + + + + + + + + -- Gitee