From 3198688eb53ae39f76472643c8ee80db903e7ab2 Mon Sep 17 00:00:00 2001 From: owen Date: Sun, 19 Nov 2023 18:27:25 +0800 Subject: [PATCH 01/12] =?UTF-8?q?=E8=90=A5=E9=94=80=EF=BC=9A=E9=80=82?= =?UTF-8?q?=E9=85=8D=E5=95=86=E5=9F=8E=E8=A3=85=E4=BF=AE=E7=BB=84=E4=BB=B6?= =?UTF-8?q?=E3=80=90=E5=95=86=E5=93=81=E6=A0=8F=E3=80=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/mobile/ProductList/config.ts | 64 +++++++++ .../components/mobile/ProductList/index.vue | 128 ++++++++++++++++++ .../mobile/ProductList/property.vue | 99 ++++++++++++++ src/components/DiyEditor/util.ts | 2 +- .../product/spu/components/SpuShowcase.vue | 1 - 5 files changed, 292 insertions(+), 2 deletions(-) create mode 100644 src/components/DiyEditor/components/mobile/ProductList/config.ts create mode 100644 src/components/DiyEditor/components/mobile/ProductList/index.vue create mode 100644 src/components/DiyEditor/components/mobile/ProductList/property.vue diff --git a/src/components/DiyEditor/components/mobile/ProductList/config.ts b/src/components/DiyEditor/components/mobile/ProductList/config.ts new file mode 100644 index 00000000..019be74e --- /dev/null +++ b/src/components/DiyEditor/components/mobile/ProductList/config.ts @@ -0,0 +1,64 @@ +import { ComponentStyle, DiyComponent } from '@/components/DiyEditor/util' + +/** 商品卡片属性 */ +export interface ProductListProperty { + // 布局类型:双列 | 三列 | 水平滑动 + layoutType: 'twoCol' | 'threeCol' | 'horizSwiper' + // 商品字段 + fields: { + // 商品名称 + name: ProductListFieldProperty + // 商品价格 + price: ProductListFieldProperty + } + // 角标 + badge: { + // 是否显示 + show: boolean + // 角标图片 + imgUrl: string + } + // 上圆角 + borderRadiusTop: number + // 下圆角 + borderRadiusBottom: number + // 间距 + space: number + // 商品编号列表 + spuIds: number[] + // 组件样式 + style: ComponentStyle +} +// 商品字段 +export interface ProductListFieldProperty { + // 是否显示 + show: boolean + // 颜色 + color: string +} + +// 定义组件 +export const component = { + id: 'ProductList', + name: '商品栏', + icon: 'system-uicons:carousel', + property: { + layoutType: 'twoCol', + fields: { + name: { show: true, color: '#000' }, + price: { show: true, color: '#ff3000' } + }, + badge: { show: false, imgUrl: '' }, + borderRadiusTop: 8, + borderRadiusBottom: 8, + space: 8, + spuIds: [], + style: { + bgType: 'color', + bgColor: '', + marginLeft: 8, + marginRight: 8, + marginBottom: 8 + } as ComponentStyle + } +} as DiyComponent diff --git a/src/components/DiyEditor/components/mobile/ProductList/index.vue b/src/components/DiyEditor/components/mobile/ProductList/index.vue new file mode 100644 index 00000000..cf644ea1 --- /dev/null +++ b/src/components/DiyEditor/components/mobile/ProductList/index.vue @@ -0,0 +1,128 @@ + + + + diff --git a/src/components/DiyEditor/components/mobile/ProductList/property.vue b/src/components/DiyEditor/components/mobile/ProductList/property.vue new file mode 100644 index 00000000..872affc3 --- /dev/null +++ b/src/components/DiyEditor/components/mobile/ProductList/property.vue @@ -0,0 +1,99 @@ + + + + + diff --git a/src/components/DiyEditor/util.ts b/src/components/DiyEditor/util.ts index 8f8c2c0c..5dfcea9e 100644 --- a/src/components/DiyEditor/util.ts +++ b/src/components/DiyEditor/util.ts @@ -107,7 +107,7 @@ export const PAGE_LIBS = [ extended: true, components: ['ImageBar', 'Carousel', 'TitleBar', 'VideoPlayer', 'Divider', 'MagicCube'] }, - { name: '商品组件', extended: true, components: ['ProductCard'] }, + { name: '商品组件', extended: true, components: ['ProductCard', 'ProductList'] }, { name: '会员组件', extended: true, diff --git a/src/views/mall/product/spu/components/SpuShowcase.vue b/src/views/mall/product/spu/components/SpuShowcase.vue index a3f16fba..3d2caf9a 100644 --- a/src/views/mall/product/spu/components/SpuShowcase.vue +++ b/src/views/mall/product/spu/components/SpuShowcase.vue @@ -59,7 +59,6 @@ watch( productSpus.value.length === 0 || productSpus.value.some((spu) => !props.modelValue.includes(spu.id)) ) { - debugger productSpus.value = await ProductSpuApi.getSpuDetailList(props.modelValue) } }, From e0a731dd86f76292a4b6a7aef3cad1f188c1ff0c Mon Sep 17 00:00:00 2001 From: owen Date: Mon, 20 Nov 2023 10:53:02 +0800 Subject: [PATCH 02/12] =?UTF-8?q?=E5=95=86=E5=93=81=E8=AF=84=E8=AE=BA?= =?UTF-8?q?=E3=80=81=E4=BC=98=E6=83=A0=E5=88=B8=E6=A8=A1=E6=9D=BF=E5=A4=8D?= =?UTF-8?q?=E7=94=A8=E7=BB=84=E4=BB=B6=E3=80=90=E5=95=86=E5=93=81=E6=A9=B1?= =?UTF-8?q?=E7=AA=97=E3=80=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../mall/product/comment/CommentForm.vue | 31 ++-------- src/views/mall/product/comment/index.vue | 2 +- .../product/spu/components/SpuShowcase.vue | 51 ++++++++++------ .../coupon/template/CouponTemplateForm.vue | 58 +------------------ 4 files changed, 41 insertions(+), 101 deletions(-) diff --git a/src/views/mall/product/comment/CommentForm.vue b/src/views/mall/product/comment/CommentForm.vue index 284e9a61..e9913ade 100644 --- a/src/views/mall/product/comment/CommentForm.vue +++ b/src/views/mall/product/comment/CommentForm.vue @@ -8,14 +8,7 @@ v-loading="formLoading" > -
-
- -
-
- -
-
+
@@ -51,12 +44,11 @@ 取 消 - - + diff --git a/src/views/mall/promotion/coupon/template/CouponTemplateForm.vue b/src/views/mall/promotion/coupon/template/CouponTemplateForm.vue index ddf44eb3..fcb18337 100644 --- a/src/views/mall/promotion/coupon/template/CouponTemplateForm.vue +++ b/src/views/mall/promotion/coupon/template/CouponTemplateForm.vue @@ -26,15 +26,7 @@ label="商品" prop="productSpuIds" > -
-
- - -
-
- -
-
+ 取 消 - From 1bb9df7b3c6b7fd8b91195664a36afe151141f4c Mon Sep 17 00:00:00 2001 From: owen Date: Tue, 21 Nov 2023 10:27:29 +0800 Subject: [PATCH 03/12] =?UTF-8?q?=E5=95=86=E5=93=81=E4=B8=AD=E5=BF=83?= =?UTF-8?q?=EF=BC=9A=E4=BF=AE=E5=A4=8D=E5=95=86=E5=93=81=E8=A1=A8=E6=A0=BC?= =?UTF-8?q?=E9=80=89=E6=8B=A9=E5=AF=B9=E8=AF=9D=E6=A1=86=EF=BC=8C=E5=9C=A8?= =?UTF-8?q?=E5=A4=9A=E9=80=89=E6=97=B6=E8=A1=A8=E5=A4=B4=E5=86=85=E7=9A=84?= =?UTF-8?q?=E5=A4=9A=E9=80=89=E6=A1=86=E4=B8=8D=E6=98=BE=E7=A4=BA=E9=80=89?= =?UTF-8?q?=E4=B8=AD=E6=95=88=E6=9E=9C=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../product/spu/components/SpuShowcase.vue | 6 +- .../product/spu/components/SpuTableSelect.vue | 200 +++++++++++------- 2 files changed, 130 insertions(+), 76 deletions(-) diff --git a/src/views/mall/product/spu/components/SpuShowcase.vue b/src/views/mall/product/spu/components/SpuShowcase.vue index a56a3ef0..5d35238e 100644 --- a/src/views/mall/product/spu/components/SpuShowcase.vue +++ b/src/views/mall/product/spu/components/SpuShowcase.vue @@ -20,7 +20,7 @@
- + + diff --git a/src/components/DiyEditor/components/mobile/CouponCard/property.vue b/src/components/DiyEditor/components/mobile/CouponCard/property.vue new file mode 100644 index 00000000..4f32c21e --- /dev/null +++ b/src/components/DiyEditor/components/mobile/CouponCard/property.vue @@ -0,0 +1,104 @@ + + + + + diff --git a/src/components/DiyEditor/components/mobile/ProductCard/config.ts b/src/components/DiyEditor/components/mobile/ProductCard/config.ts index 49dd30d0..735b6ba0 100644 --- a/src/components/DiyEditor/components/mobile/ProductCard/config.ts +++ b/src/components/DiyEditor/components/mobile/ProductCard/config.ts @@ -62,7 +62,7 @@ export interface ProductCardFieldProperty { export const component = { id: 'ProductCard', name: '商品卡片', - icon: 'system-uicons:carousel', + icon: 'fluent:text-column-two-left-24-filled', property: { layoutType: 'oneColBigImg', fields: { diff --git a/src/components/DiyEditor/components/mobile/ProductList/config.ts b/src/components/DiyEditor/components/mobile/ProductList/config.ts index 019be74e..436de405 100644 --- a/src/components/DiyEditor/components/mobile/ProductList/config.ts +++ b/src/components/DiyEditor/components/mobile/ProductList/config.ts @@ -41,7 +41,7 @@ export interface ProductListFieldProperty { export const component = { id: 'ProductList', name: '商品栏', - icon: 'system-uicons:carousel', + icon: 'fluent:text-column-two-24-filled', property: { layoutType: 'twoCol', fields: { diff --git a/src/components/DiyEditor/components/mobile/ProductList/index.vue b/src/components/DiyEditor/components/mobile/ProductList/index.vue index cf644ea1..8a35628e 100644 --- a/src/components/DiyEditor/components/mobile/ProductList/index.vue +++ b/src/components/DiyEditor/components/mobile/ProductList/index.vue @@ -1,13 +1,13 @@ diff --git a/src/components/DiyEditor/util.ts b/src/components/DiyEditor/util.ts index 5dfcea9e..a8d0e095 100644 --- a/src/components/DiyEditor/util.ts +++ b/src/components/DiyEditor/util.ts @@ -111,7 +111,11 @@ export const PAGE_LIBS = [ { name: '会员组件', extended: true, - components: ['UserCard', 'OrderCard', 'WalletCard', 'CouponCard'] + components: ['UserCard', 'UserOrder', 'UserWallet', 'UserCoupon'] }, - { name: '营销组件', extended: true, components: ['Combination', 'Seckill', 'Point', 'Coupon'] } + { + name: '营销组件', + extended: true, + components: ['CombinationCard', 'SeckillCard', 'PointCard', 'CouponCard'] + } ] as DiyComponentLibrary[] diff --git a/src/views/mall/product/comment/CommentForm.vue b/src/views/mall/product/comment/CommentForm.vue index e9913ade..df6756a0 100644 --- a/src/views/mall/product/comment/CommentForm.vue +++ b/src/views/mall/product/comment/CommentForm.vue @@ -48,7 +48,7 @@ - + From f8b56a8c46f6d00acb807c5a5d6a464abefeb3ad Mon Sep 17 00:00:00 2001 From: puhui999 Date: Thu, 23 Nov 2023 09:35:59 +0800 Subject: [PATCH 07/12] =?UTF-8?q?crm-=E5=AE=A2=E6=88=B7=EF=BC=9A=E5=85=AC?= =?UTF-8?q?=E6=B5=B7=E6=95=B0=E6=8D=AE=E5=8C=BA=E5=88=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/crm/customer/index.vue | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/src/views/crm/customer/index.vue b/src/views/crm/customer/index.vue index 60bc8bea..210691b9 100644 --- a/src/views/crm/customer/index.vue +++ b/src/views/crm/customer/index.vue @@ -208,11 +208,12 @@ const list = ref([]) // 列表的数据 const queryParams = reactive({ pageNo: 1, pageSize: 10, - name: null, - mobile: null, - industryId: null, - level: null, - source: null + pool: false, + name: '', + mobile: '', + industryId: undefined, + level: undefined, + source: undefined }) const queryFormRef = ref() // 搜索的表单 const exportLoading = ref(false) // 导出的加载中 @@ -238,6 +239,7 @@ const handleQuery = () => { /** 重置按钮操作 */ const resetQuery = () => { queryFormRef.value.resetFields() + queryParams.pool = false handleQuery() } From 1744c6ec6fea5897ee202d42c5e6198285ba09e4 Mon Sep 17 00:00:00 2001 From: YunaiV Date: Fri, 24 Nov 2023 00:33:05 +0800 Subject: [PATCH 08/12] =?UTF-8?q?websocket=20=E9=87=8D=E6=96=B0=E5=B0=81?= =?UTF-8?q?=E8=A3=85?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .env.base | 4 +- src/api/system/notice/index.ts | 5 + src/locales/zh-CN.ts | 3 +- src/views/infra/webSocket/index.vue | 142 ++++++++++++++++++++-------- src/views/system/notice/index.vue | 14 +++ 5 files changed, 125 insertions(+), 43 deletions(-) diff --git a/.env.base b/.env.base index fdb26d85..cf433822 100644 --- a/.env.base +++ b/.env.base @@ -4,10 +4,10 @@ NODE_ENV=development VITE_DEV=true # 请求路径 -VITE_BASE_URL='http://localhost:48080' +VITE_BASE_URL='http://127.0.0.1:48080' # 上传路径 -VITE_UPLOAD_URL='http://localhost:48080/admin-api/infra/file/upload' +VITE_UPLOAD_URL='http://127.0.0.1:48080/admin-api/infra/file/upload' # 接口前缀 VITE_API_BASEPATH=/dev-api diff --git a/src/api/system/notice/index.ts b/src/api/system/notice/index.ts index 62bf5259..f6434697 100644 --- a/src/api/system/notice/index.ts +++ b/src/api/system/notice/index.ts @@ -35,3 +35,8 @@ export const updateNotice = (data: NoticeVO) => { export const deleteNotice = (id: number) => { return request.delete({ url: '/system/notice/delete?id=' + id }) } + +// 推送公告 +export const pushNotice = (id: number) => { + return request.post({ url: '/system/notice/push?id=' + id }) +} diff --git a/src/locales/zh-CN.ts b/src/locales/zh-CN.ts index 4f95852f..6346a3d3 100644 --- a/src/locales/zh-CN.ts +++ b/src/locales/zh-CN.ts @@ -437,5 +437,6 @@ export default { btn_zoom_in: '放大', btn_zoom_out: '缩小', preview: '预览' - } + }, + 'OAuth 2.0': 'OAuth 2.0' // 避免菜单名是 OAuth 2.0 时,一直 warn 报错 } diff --git a/src/views/infra/webSocket/index.vue b/src/views/infra/webSocket/index.vue index ce6db798..0f609213 100644 --- a/src/views/infra/webSocket/index.vue +++ b/src/views/infra/webSocket/index.vue @@ -1,5 +1,6 @@ @@ -168,6 +171,17 @@ const handleDelete = async (id: number) => { } catch {} } +/** 推送按钮操作 */ +const handlePush = async (id: number) => { + try { + // 推送的二次确认 + await message.confirm('是否推送所选中通知?') + // 发起推送 + await NoticeApi.pushNotice(id) + message.success(t('推送成功')) + } catch {} +} + /** 初始化 **/ onMounted(() => { getList() From c3cad3f3ee4f23e5caabea83d08d42eaf955cc1d Mon Sep 17 00:00:00 2001 From: owen Date: Fri, 24 Nov 2023 20:54:47 +0800 Subject: [PATCH 09/12] =?UTF-8?q?=E5=95=86=E5=9F=8E=EF=BC=9A=E4=BF=AE?= =?UTF-8?q?=E5=A4=8D=E4=BC=9A=E5=91=98=E7=BB=9F=E8=AE=A1=E6=97=B6=E9=97=B4?= =?UTF-8?q?=E8=8C=83=E5=9B=B4=E9=80=89=E6=8B=A9=E6=98=A8=E5=A4=A9=E6=97=B6?= =?UTF-8?q?,=20=E4=BC=9A=E5=BC=BA=E5=88=B6=E6=9F=A5=E8=AF=A2=E4=B8=A4?= =?UTF-8?q?=E5=A4=A9=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/ShortcutDateRangePicker/index.vue | 5 ----- src/utils/formatTime.ts | 5 ++++- src/views/mall/statistics/trade/index.vue | 9 +++++++++ 3 files changed, 13 insertions(+), 6 deletions(-) diff --git a/src/components/ShortcutDateRangePicker/index.vue b/src/components/ShortcutDateRangePicker/index.vue index 9f268a3f..117c079a 100644 --- a/src/components/ShortcutDateRangePicker/index.vue +++ b/src/components/ShortcutDateRangePicker/index.vue @@ -74,11 +74,6 @@ const emits = defineEmits<{ }>() /** 触发时间范围选中事件 */ const emitDateRangePicker = async () => { - // 开始与截止在同一天的, 折线图出不来, 需要延长一天 - if (DateUtil.isSameDay(times.value[0], times.value[1])) { - // 前天 - times.value[0] = DateUtil.formatDate(dayjs(times.value[0]).subtract(1, 'd')) - } emits('change', times.value) } diff --git a/src/utils/formatTime.ts b/src/utils/formatTime.ts index e2ffcadd..466f1e1f 100644 --- a/src/utils/formatTime.ts +++ b/src/utils/formatTime.ts @@ -335,5 +335,8 @@ export function getDateRange( beginDate: dayjs.ConfigType, endDate: dayjs.ConfigType ): [string, string] { - return [dayjs(beginDate).startOf('d').toString(), dayjs(endDate).endOf('d').toString()] + return [ + dayjs(beginDate).startOf('d').format('YYYY-MM-DD HH:mm:ss'), + dayjs(endDate).endOf('d').format('YYYY-MM-DD HH:mm:ss') + ] } diff --git a/src/views/mall/statistics/trade/index.vue b/src/views/mall/statistics/trade/index.vue index e89f0cc3..86deaa87 100644 --- a/src/views/mall/statistics/trade/index.vue +++ b/src/views/mall/statistics/trade/index.vue @@ -219,6 +219,8 @@ import { TradeSummaryRespVO, TradeTrendSummaryRespVO } from '@/api/mall/statisti import { calculateRelativeRate, fenToYuan } from '@/utils' import download from '@/utils/download' import { CardTitle } from '@/components/Card' +import * as DateUtil from '@/utils/formatTime' +import dayjs from 'dayjs' /** 交易统计 */ defineOptions({ name: 'TradeStatistics' }) @@ -289,6 +291,13 @@ const lineChartOptions = reactive({ /** 处理交易状况查询 */ const getTradeTrendData = async () => { trendLoading.value = true + // 1. 处理时间: 开始与截止在同一天的, 折线图出不来, 需要延长一天 + const times = shortcutDateRangePicker.value.times + if (DateUtil.isSameDay(times[0], times[1])) { + // 前天 + times[0] = DateUtil.formatDate(dayjs(times[0]).subtract(1, 'd')) + } + // 查询数据 await Promise.all([getTradeTrendSummary(), getTradeStatisticsList()]) trendLoading.value = false } From b95b8008f7356aac7c57a0548e1e7d6c605bf987 Mon Sep 17 00:00:00 2001 From: Marvin <454846659@qq.com> Date: Sat, 25 Nov 2023 03:52:59 +0800 Subject: [PATCH 10/12] =?UTF-8?q?feat:=20=E8=8F=9C=E5=8D=95=E5=8F=B3?= =?UTF-8?q?=E4=B8=8A=E8=A7=92=E5=8A=A0=E4=B8=80=E4=B8=AA=E6=90=9C=E7=B4=A2?= =?UTF-8?q?=E5=9B=BE=E6=A0=87?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/RouterSearch/index.vue | 32 ++++++++++++++++++++++++++- src/layout/components/ToolHeader.vue | 5 +++++ src/store/modules/app.ts | 2 ++ 3 files changed, 38 insertions(+), 1 deletion(-) diff --git a/src/components/RouterSearch/index.vue b/src/components/RouterSearch/index.vue index c12385af..2499dafe 100644 --- a/src/components/RouterSearch/index.vue +++ b/src/components/RouterSearch/index.vue @@ -1,5 +1,5 @@ diff --git a/src/views/crm/contact/detail/ContactDetails.vue b/src/views/crm/contact/detail/ContactDetails.vue index 9cf586b2..de31306e 100644 --- a/src/views/crm/contact/detail/ContactDetails.vue +++ b/src/views/crm/contact/detail/ContactDetails.vue @@ -1,3 +1,10 @@ + - {{ gotOwnerUser(contact.ownerUserId) }} + {{ contact.ownerUserName }} {{ contact.creatorName }} @@ -66,29 +76,9 @@ import * as ContactApi from '@/api/crm/contact' import { DICT_TYPE } from '@/utils/dict' import { formatDate } from '@/utils/formatTime' -import * as UserApi from '@/api/system/user' const { contact } = defineProps<{ contact: ContactApi.ContactVO }>() // 展示的折叠面板 const activeNames = ref(['basicInfo', 'systemInfo']) -const gotOwnerUser = (owerUserId: string) => { - let ownerName = '' - if (owerUserId !== null && owerUserId != undefined) { - owerUserId.split(',').forEach((item: string, index: number) => { - if (index != 0) { - ownerName = - ownerName + ',' + userList.value.find((user: { id: any }) => user.id == item)?.nickname - } else { - ownerName = userList.value.find((user: { id: any }) => user.id == item)?.nickname || '' - } - }) - } - return ownerName -} -const userList = ref([]) // 用户列表 -/** 初始化 **/ -onMounted(async () => { - userList.value = await UserApi.getSimpleUserList() -}) diff --git a/src/views/crm/contact/detail/index.vue b/src/views/crm/contact/detail/index.vue index 03bbb4e6..5ec47f92 100644 --- a/src/views/crm/contact/detail/index.vue +++ b/src/views/crm/contact/detail/index.vue @@ -63,33 +63,18 @@ - + - 活动 - 邮件 - 工商信息 - - - - 客户 - - - - 团队成员 - + 跟进记录 商机 - - - 合同 + 附件 + + + + 操作记录 - - - 回款 - - 回访 - 发票 diff --git a/src/views/crm/contact/index.vue b/src/views/crm/contact/index.vue index d81b0449..8de0a19a 100644 --- a/src/views/crm/contact/index.vue +++ b/src/views/crm/contact/index.vue @@ -55,9 +55,9 @@ class="!w-240px" />
- + - + - - - + - + @@ -239,13 +235,12 @@ const queryParams = reactive({ name: null, post: null, qq: null, - webchat: null, + wechat: null, sex: null, policyMakers: null }) const queryFormRef = ref() // 搜索的表单 const exportLoading = ref(false) // 导出的加载中 -const userList = ref([]) // 用户列表 /** 查询列表 */ const getList = async () => { @@ -305,35 +300,15 @@ const handleExport = async () => { } } -// TODO @zyna:这个负责人的读取,放在后端好点 -const gotOwnerUser = (owerUserId: string) => { - let ownerName = '' - if (owerUserId !== null) { - owerUserId.split(',').forEach((item: string, index: number) => { - if (index != 0) { - ownerName = - ownerName + ',' + userList.value.find((user: { id: any }) => user.id == item)?.nickname - } else { - ownerName = userList.value.find((user: { id: any }) => user.id == item)?.nickname || '' - } - }) - } - return ownerName -} - /** 打开客户详情 */ const { push } = useRouter() const openDetail = (id: number) => { push({ name: 'CrmContactDetail', params: { id } }) } -// TODO @zyna:这个上级的读取,放在后端读取,更合适;因为可能数据量比较大 -const allContactList = ref([]) //所有联系人列表 -const allCustomerList = ref([]) //客户列表 + /** 初始化 **/ onMounted(async () => { await getList() - userList.value = await UserApi.getSimpleUserList() - allContactList.value = await ContactApi.simpleAlllist() }) From 633965b07dbbf51cdfc8cb57ce54de2a8f3aa56d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Evol=E9=83=91=E5=A4=A9?= Date: Mon, 27 Nov 2023 07:07:32 +0000 Subject: [PATCH 12/12] =?UTF-8?q?=E5=90=8C=E6=AD=A5=E5=85=AC=E4=BC=97?= =?UTF-8?q?=E5=8F=B7=E7=B2=89=E4=B8=9D=E6=8E=A5=E5=8F=A3=E8=B0=83=E7=94=A8?= =?UTF-8?q?=E9=94=99=E8=AF=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Evol郑天 --- src/api/mp/user/index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/api/mp/user/index.ts b/src/api/mp/user/index.ts index d954e9eb..b89acc7d 100644 --- a/src/api/mp/user/index.ts +++ b/src/api/mp/user/index.ts @@ -26,6 +26,6 @@ export const getUserPage = (query) => { // 同步公众号粉丝 export const syncUser = (accountId) => { return request.post({ - url: '/mp/tag/sync?accountId=' + accountId + url: '/mp/user/sync?accountId=' + accountId }) }