From e6d75c5a01abb86b3730dc646a9c886c4b4f5a89 Mon Sep 17 00:00:00 2001 From: lr Date: Mon, 17 Feb 2025 09:08:15 +0800 Subject: [PATCH 1/5] 1 --- jiuyi2/components/shop/detail/footerMenu.vue | 4 +- .../.vue-global-types/vue_99_0_0_0.d.ts | 129 ++++++++++++++++++ jiuyi2/pages.json | 6 - 3 files changed, 131 insertions(+), 8 deletions(-) create mode 100644 jiuyi2/node_modules/.vue-global-types/vue_99_0_0_0.d.ts diff --git a/jiuyi2/components/shop/detail/footerMenu.vue b/jiuyi2/components/shop/detail/footerMenu.vue index ba7139bd..689600fe 100644 --- a/jiuyi2/components/shop/detail/footerMenu.vue +++ b/jiuyi2/components/shop/detail/footerMenu.vue @@ -138,10 +138,10 @@ function toCustomer() { - + diff --git a/jiuyi2/node_modules/.vue-global-types/vue_99_0_0_0.d.ts b/jiuyi2/node_modules/.vue-global-types/vue_99_0_0_0.d.ts new file mode 100644 index 00000000..130f5375 --- /dev/null +++ b/jiuyi2/node_modules/.vue-global-types/vue_99_0_0_0.d.ts @@ -0,0 +1,129 @@ +// @ts-nocheck +export {}; + +; declare global { + const __VLS_intrinsicElements: __VLS_IntrinsicElements; + const __VLS_directiveBindingRestFields: { instance: null, oldValue: null, modifiers: any, dir: any }; + const __VLS_unref: typeof import('vue').unref; + const __VLS_placeholder: any; + + const __VLS_nativeElements = { + ...{} as SVGElementTagNameMap, + ...{} as HTMLElementTagNameMap, + }; + + type __VLS_IntrinsicElements = import('vue/jsx-runtime').JSX.IntrinsicElements; + type __VLS_Element = import('vue/jsx-runtime').JSX.Element; + type __VLS_GlobalComponents = import('vue').GlobalComponents; + type __VLS_GlobalDirectives = import('vue').GlobalDirectives; + type __VLS_IsAny = 0 extends 1 & T ? true : false; + type __VLS_PickNotAny = __VLS_IsAny extends true ? B : A; + type __VLS_unknownDirective = (arg1: unknown, arg2: unknown, arg3: unknown, arg4: unknown) => void; + type __VLS_WithComponent = + N1 extends keyof LocalComponents ? N1 extends N0 ? Pick : { [K in N0]: LocalComponents[N1] } : + N2 extends keyof LocalComponents ? N2 extends N0 ? Pick : { [K in N0]: LocalComponents[N2] } : + N3 extends keyof LocalComponents ? N3 extends N0 ? Pick : { [K in N0]: LocalComponents[N3] } : + Self extends object ? { [K in N0]: Self } : + N1 extends keyof __VLS_GlobalComponents ? N1 extends N0 ? Pick<__VLS_GlobalComponents, N0 extends keyof __VLS_GlobalComponents ? N0 : never> : { [K in N0]: __VLS_GlobalComponents[N1] } : + N2 extends keyof __VLS_GlobalComponents ? N2 extends N0 ? Pick<__VLS_GlobalComponents, N0 extends keyof __VLS_GlobalComponents ? N0 : never> : { [K in N0]: __VLS_GlobalComponents[N2] } : + N3 extends keyof __VLS_GlobalComponents ? N3 extends N0 ? Pick<__VLS_GlobalComponents, N0 extends keyof __VLS_GlobalComponents ? N0 : never> : { [K in N0]: __VLS_GlobalComponents[N3] } : + { [K in N0]: unknown }; + type __VLS_FunctionalComponentProps = + '__ctx' extends keyof __VLS_PickNotAny ? K extends { __ctx?: { props?: infer P } } ? NonNullable

: never + : T extends (props: infer P, ...args: any) => any ? P : + {}; + type __VLS_IsFunction = K extends keyof T + ? __VLS_IsAny extends false + ? unknown extends T[K] + ? false + : true + : false + : false; + type __VLS_NormalizeComponentEvent = ( + __VLS_IsFunction extends true + ? Props + : __VLS_IsFunction extends true + ? { [K in onEvent]?: Events[Event] } + : __VLS_IsFunction extends true + ? { [K in onEvent]?: Events[CamelizedEvent] } + : Props + ) & Record; + // fix https://github.com/vuejs/language-tools/issues/926 + type __VLS_UnionToIntersection = (U extends unknown ? (arg: U) => unknown : never) extends ((arg: infer P) => unknown) ? P : never; + type __VLS_OverloadUnionInner = U & T extends (...args: infer A) => infer R + ? U extends T + ? never + : __VLS_OverloadUnionInner & U & ((...args: A) => R)> | ((...args: A) => R) + : never; + type __VLS_OverloadUnion = Exclude< + __VLS_OverloadUnionInner<(() => never) & T>, + T extends () => never ? never : () => never + >; + type __VLS_ConstructorOverloads = __VLS_OverloadUnion extends infer F + ? F extends (event: infer E, ...args: infer A) => any + ? { [K in E & string]: (...args: A) => void; } + : never + : never; + type __VLS_NormalizeEmits = __VLS_PrettifyGlobal< + __VLS_UnionToIntersection< + __VLS_ConstructorOverloads & { + [K in keyof T]: T[K] extends any[] ? { (...args: T[K]): void } : never + } + > + >; + type __VLS_PrettifyGlobal = { [K in keyof T]: T[K]; } & {}; + type __VLS_PickFunctionalComponentCtx = NonNullable<__VLS_PickNotAny< + '__ctx' extends keyof __VLS_PickNotAny ? K extends { __ctx?: infer Ctx } ? Ctx : never : any + , T extends (props: any, ctx: infer Ctx) => any ? Ctx : any + >>; + type __VLS_OmitStringIndex = { + [K in keyof T as string extends K ? never : K]: T[K]; + }; + type __VLS_UseTemplateRef = Readonly>; + + function __VLS_getVForSourceType(source: number): [number, number][]; + function __VLS_getVForSourceType(source: string): [string, number][]; + function __VLS_getVForSourceType(source: T): [ + item: T[number], + index: number, + ][]; + function __VLS_getVForSourceType }>(source: T): [ + item: T extends { [Symbol.iterator](): Iterator } ? T1 : never, + index: number, + ][]; + // #3845 + function __VLS_getVForSourceType }>(source: T): [ + item: number | (Exclude extends { [Symbol.iterator](): Iterator } ? T1 : never), + index: number, + ][]; + function __VLS_getVForSourceType(source: T): [ + item: T[keyof T], + key: keyof T, + index: number, + ][]; + // @ts-ignore + function __VLS_getSlotParams(slot: T): Parameters<__VLS_PickNotAny, (...args: any[]) => any>>; + // @ts-ignore + function __VLS_getSlotParam(slot: T): Parameters<__VLS_PickNotAny, (...args: any[]) => any>>[0]; + function __VLS_asFunctionalDirective(dir: T): T extends import('vue').ObjectDirective + ? NonNullable + : T extends (...args: any) => any + ? T + : __VLS_unknownDirective; + function __VLS_withScope(ctx: T, scope: K): ctx is T & K; + function __VLS_makeOptional(t: T): { [K in keyof T]?: T[K] }; + function __VLS_asFunctionalComponent any ? InstanceType : unknown>(t: T, instance?: K): + T extends new (...args: any) => any + ? (props: (K extends { $props: infer Props } ? Props : any) & Record, ctx?: any) => __VLS_Element & { __ctx?: { + attrs?: any, + slots?: K extends { $slots: infer Slots } ? Slots : any, + emit?: K extends { $emit: infer Emit } ? Emit : any + } & { props?: (K extends { $props: infer Props } ? Props : any) & Record; expose?(exposed: K): void; } } + : T extends () => any ? (props: {}, ctx?: any) => ReturnType + : T extends (...args: any) => any ? T + : (_: {} & Record, ctx?: any) => { __ctx?: { attrs?: any, expose?: any, slots?: any, emit?: any, props?: {} & Record } }; + function __VLS_asFunctionalElement(tag: T, endTag?: T): (_: T & Record) => void; + function __VLS_functionalComponentArgsRest any>(t: T): 2 extends Parameters['length'] ? [any] : []; + function __VLS_normalizeSlot(s: S): S extends () => infer R ? (props: {}) => R : S; + function __VLS_tryAsConstant(t: T): T; +} diff --git a/jiuyi2/pages.json b/jiuyi2/pages.json index fa3e654e..774703a0 100644 --- a/jiuyi2/pages.json +++ b/jiuyi2/pages.json @@ -91,12 +91,6 @@ "navigationBarTitleText": "问答页" } }, - { - "path": "pages/news/chat/customeChat", - "style": { - "navigationBarTitleText": "客服聊天" - } - }, { "path": "pages/news/red-envelope/index", "style": { From d77e175b52ebbd995d80b9fe097cc161ec8ff862 Mon Sep 17 00:00:00 2001 From: lr Date: Tue, 18 Feb 2025 11:38:36 +0800 Subject: [PATCH 2/5] =?UTF-8?q?=E6=A6=B4=E8=8E=B2=E6=9E=9C=E9=85=8D?= =?UTF-8?q?=E7=BD=AE=20=20=E6=89=AB=E7=A0=81=E5=8A=A0=E5=A5=BD=E5=8F=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- jiuyi2/api/durian.js | 10 + jiuyi2/api/shop.js | 27 +- jiuyi2/common/js/config.js | 1 + jiuyi2/components/news/msgList.vue | 27 +- .../public/jy-commodity-information/index.vue | 16 +- jiuyi2/components/shop/detail/footerMenu.vue | 33 +- .../.vue-global-types/vue_2.6_0_0_0.d.ts | 133 +++++ jiuyi2/pages/index/durian.vue | 518 +++++++++--------- jiuyi2/pages/news/addFriend.vue | 311 ++++++----- jiuyi2/pages/news/chat/chat.vue | 4 +- jiuyi2/pages/news/chat/jy-plus.vue | 56 +- jiuyi2/pages/news/goodsList/index.vue | 118 +++- jiuyi2/pages/news/myQr.vue | 112 ++-- jiuyi2/vite.config.js | 1 + service/App.vue | 21 +- service/api/login.js | 7 +- service/common/js/config.js | 2 +- service/common/js/util.js | 47 +- service/pages/index/index.vue | 278 ++++++++-- service/vite.config.js | 2 +- 20 files changed, 1123 insertions(+), 601 deletions(-) create mode 100644 jiuyi2/node_modules/.vue-global-types/vue_2.6_0_0_0.d.ts diff --git a/jiuyi2/api/durian.js b/jiuyi2/api/durian.js index 7b6cc3ea..36bf2d11 100644 --- a/jiuyi2/api/durian.js +++ b/jiuyi2/api/durian.js @@ -72,5 +72,15 @@ export const durian = { load: true, }) }, + /** + * 榴莲果配置 + * @param {Object} param + */ + durianFruitConfig() { + return util.request({ + url: `/coreplay/durianFruitTransactionType/10`, + method: 'GET', + }) + }, } export default durian \ No newline at end of file diff --git a/jiuyi2/api/shop.js b/jiuyi2/api/shop.js index 78776834..3170fbde 100644 --- a/jiuyi2/api/shop.js +++ b/jiuyi2/api/shop.js @@ -444,7 +444,32 @@ const shop = { */ getCustomerService(param) { return util.request({ - url: `/user/MCustomerService/random`, + url: `/user/MCustomerService/random`, + method: 'GET', + query: param, + }) + }, + + + /** + * 根据店铺id查商品列表 + * @param {Object} param + */ + getShopProductList(param) { + return util.request({ + url: `/shopify/appProductionApi/getProductionList`, + method: 'GET', + query: param, + }) + }, + + /** + * 查询用户在当前商铺的订单列表 + * @param {Object} param + */ + getShopOrderList(param) { + return util.request({ + url: `/shopify/appOrder/getOrderList`, method: 'GET', query: param, }) diff --git a/jiuyi2/common/js/config.js b/jiuyi2/common/js/config.js index 4500abc9..c6bbe709 100644 --- a/jiuyi2/common/js/config.js +++ b/jiuyi2/common/js/config.js @@ -8,6 +8,7 @@ const config = { // #ifndef H5 // host: 'http://91f.xyz:8080', host: 'https://b433d23.r24.cpolar.top/', + // host: 'http://hvw2rn.natappfree.cc', // #endif // 支付方式配置 payType: { diff --git a/jiuyi2/components/news/msgList.vue b/jiuyi2/components/news/msgList.vue index 89288f74..ab9a87cf 100644 --- a/jiuyi2/components/news/msgList.vue +++ b/jiuyi2/components/news/msgList.vue @@ -110,6 +110,28 @@ function handleList(list) { if (item.groupId != null) { item.unreadCount = getGroupNoReadNum(item.groupId) } + if (item.callbackJson.callback_json.length) { + let msgType = item.callbackJson.callback_json[0].MsgType; + if (msgType == TencentCloudChat.TYPES.MSG_TEXT) { + item.chatText = item.callbackJson.callback_json[0].MsgContent.Text + } else if (msgType == TencentCloudChat.TYPES.MSG_IMAGE) { + item.chatText = '[图片]' + } else if (msgType == TencentCloudChat.TYPES.MSG_AUDIO) { + item.chatText = '[语音]' + } else if (msgType == TencentCloudChat.TYPES.MSG_VIDEO) { + item.chatText = '[视频]' + } else if (msgType == TencentCloudChat.TYPES.MSG_CUSTOM) { + if (item.callbackJson.callback_json[0].businessType == 'redPacket') { + item.chatText = `[红包] ${item.callbackJson.blessing}` + } else if (item.callbackJson.callback_json[0].businessType == '1') { + // if (item.callbackJson.callback_json[0].call_type == '1') { + // item.chatText = '[语音通话]' + // } else if (item.callbackJson.callback_json[0].call_type == '2') { + // item.chatText = '[视频通话]' + // } + } + } + } }) return list @@ -193,7 +215,7 @@ function delMsg(item) { let conversationId = item.groupId == null ? `C2C${item.fromId}` : `GROUP${item.groupId}`; - uni.$chat.deleteConversation(conversationId).then(rs => { + uni.$chat.deleteConversation(conversationId).then(rs => { getList() }) } @@ -297,8 +319,7 @@ function setRead(item) { {{ util.formatTime('MM-dd HH:mm', item.createTime) }} - {{ - item.callbackJson.callback_json[0].MsgContent.Text }} + {{ item.chatText }} diff --git a/jiuyi2/components/public/jy-commodity-information/index.vue b/jiuyi2/components/public/jy-commodity-information/index.vue index 8e45ca3f..ee0462f5 100644 --- a/jiuyi2/components/public/jy-commodity-information/index.vue +++ b/jiuyi2/components/public/jy-commodity-information/index.vue @@ -4,15 +4,15 @@