From 75230dd3b866b89312a0a4b1c0b2e5cf33e06525 Mon Sep 17 00:00:00 2001 From: wong <106998207@qq.com> Date: Fri, 19 Sep 2025 17:00:09 +0800 Subject: [PATCH 1/4] =?UTF-8?q?=E4=BB=A3=E7=A0=81=E5=90=8C=E6=AD=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Cunkebao/.env.local | 1 + 1 file changed, 1 insertion(+) create mode 100644 Cunkebao/.env.local diff --git a/Cunkebao/.env.local b/Cunkebao/.env.local new file mode 100644 index 00000000..19e89e7e --- /dev/null +++ b/Cunkebao/.env.local @@ -0,0 +1 @@ +NEXT_PUBLIC_API_BASE_URL= http://yishi.com \ No newline at end of file From 17279390d4033a8e5008775618619d93d571a39f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=B6=85=E7=BA=A7=E8=80=81=E7=99=BD=E5=85=94?= Date: Fri, 19 Sep 2025 17:45:09 +0800 Subject: [PATCH 2/4] =?UTF-8?q?FEAT=20=3D>=20=E6=9C=AC=E6=AC=A1=E6=9B=B4?= =?UTF-8?q?=E6=96=B0=E9=A1=B9=E7=9B=AE=E4=B8=BA=EF=BC=9A?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/MessageRecord/index.tsx | 35 ++++++++----------- 1 file changed, 14 insertions(+), 21 deletions(-) diff --git a/Touchkebao/src/pages/pc/ckbox/weChat/components/ChatWindow/components/MessageRecord/index.tsx b/Touchkebao/src/pages/pc/ckbox/weChat/components/ChatWindow/components/MessageRecord/index.tsx index db925474..d989d1ac 100644 --- a/Touchkebao/src/pages/pc/ckbox/weChat/components/ChatWindow/components/MessageRecord/index.tsx +++ b/Touchkebao/src/pages/pc/ckbox/weChat/components/ChatWindow/components/MessageRecord/index.tsx @@ -687,34 +687,27 @@ const MessageRecord: React.FC = ({ contract }) => { }; const handQuote = (messageData: ChatRecord) => { - //判断如果是用户 const isGroupUser = !!currentContract?.chatroomId; + const isSend = !!messageData.isSend; + const nickname = currentContract?.nickname || ""; + const SEPARATOR = "\n----------------------------------\n"; + + const rawContent = messageData.content || ""; - const isSend = messageData.isSend; //是否为我方发送 - const nickname = currentContract.nickname; - let sendMessageText = ""; if (isGroupUser) { - const GroupNickname = messageData.sender.nickname; - const content = messageData.content.replace( - `${messageData.sender.wechatId}:\n`, + const groupNickname = messageData?.sender?.nickname || ""; + // 群消息里,非本人消息通常以 "wechatId:\n" 开头,清理前缀 + const content = rawContent.replace( + `${messageData?.sender?.wechatId}:\n`, "", ); - if (isSend) { - sendMessageText = `${messageData.content}\n----------------------------------\n`; - } else { - console.log(messageData); - sendMessageText = `@${GroupNickname}:${content}\n----------------------------------\n`; - } - } else { - if (isSend) { - sendMessageText = `${messageData.content}\n----------------------------------\n`; - } else { - sendMessageText = `@${nickname}:${messageData.content}\n----------------------------------\n`; - } - //当前用户的昵称 + const text = isSend ? rawContent : `@${groupNickname}:${content}`; + updateQuoteMessageContent(`${text}${SEPARATOR}`); + return; } - updateQuoteMessageContent(sendMessageText); + const text = isSend ? rawContent : `@${nickname}:${rawContent}`; + updateQuoteMessageContent(`${text}${SEPARATOR}`); }; const handCommad = (action: string) => { From 2bd82fc6ef12daea0af5cd144a4a0c84fe89599c Mon Sep 17 00:00:00 2001 From: wong <106998207@qq.com> Date: Fri, 19 Sep 2025 17:50:53 +0800 Subject: [PATCH 3/4] =?UTF-8?q?bug=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../plan/GetAddFriendPlanDetailV1Controller.php | 14 +++++++------- Server/application/cunkebao/validate/Workbench.php | 12 +++++------- 2 files changed, 12 insertions(+), 14 deletions(-) diff --git a/Server/application/cunkebao/controller/plan/GetAddFriendPlanDetailV1Controller.php b/Server/application/cunkebao/controller/plan/GetAddFriendPlanDetailV1Controller.php index 7ec88c07..55dfaae4 100644 --- a/Server/application/cunkebao/controller/plan/GetAddFriendPlanDetailV1Controller.php +++ b/Server/application/cunkebao/controller/plan/GetAddFriendPlanDetailV1Controller.php @@ -120,7 +120,7 @@ class GetAddFriendPlanDetailV1Controller extends Controller // 解析JSON字段 $sceneConf = json_decode($plan['sceneConf'], true) ?: []; $reqConf = json_decode($plan['reqConf'], true) ?: []; - $reqConf['deveiceGroups'] = $reqConf['device']; + $reqConf['deviceGroups'] = $reqConf['device']; $msgConf = json_decode($plan['msgConf'], true) ?: []; $tagConf = json_decode($plan['tagConf'], true) ?: []; @@ -139,8 +139,8 @@ class GetAddFriendPlanDetailV1Controller extends Controller } - if (!empty($reqConf['deveiceGroups'])){ - $deveiceGroupsOptions = DeviceModel::alias('d') + if (!empty($reqConf['deviceGroups'])){ + $deviceGroupsOptions = DeviceModel::alias('d') ->field([ 'd.id', 'd.imei', 'd.memo', 'd.alive', 'l.wechatId', @@ -149,16 +149,16 @@ class GetAddFriendPlanDetailV1Controller extends Controller ->leftJoin('device_wechat_login l', 'd.id = l.deviceId and l.alive =' . DeviceWechatLoginModel::ALIVE_WECHAT_ACTIVE . ' and l.companyId = d.companyId') ->leftJoin('wechat_account a', 'l.wechatId = a.wechatId') ->order('d.id desc') - ->whereIn('d.id',$reqConf['deveiceGroups']) + ->whereIn('d.id',$reqConf['deviceGroups']) ->select(); - foreach ($deveiceGroupsOptions as &$device) { + foreach ($deviceGroupsOptions as &$device) { $curstomer = WechatCustomerModel::field('friendShip')->where(['wechatId' => $device['wechatId']])->find(); $device['totalFriend'] = $curstomer->friendShip->totalFriend ?? 0; } unset($device); - $reqConf['deveiceGroupsOptions'] = $deveiceGroupsOptions; + $reqConf['deviceGroupsOptions'] = $deviceGroupsOptions; }else{ - $reqConf['deveiceGroupsOptions'] = []; + $reqConf['deviceGroupsOptions'] = []; } diff --git a/Server/application/cunkebao/validate/Workbench.php b/Server/application/cunkebao/validate/Workbench.php index c382cfe8..ba9cb462 100644 --- a/Server/application/cunkebao/validate/Workbench.php +++ b/Server/application/cunkebao/validate/Workbench.php @@ -55,11 +55,9 @@ class Workbench extends Validate 'distributeType' => 'requireIf:type,5|in:1,2', 'maxPerDay' => 'requireIf:type,5|number|min:1', 'timeType' => 'requireIf:type,5|in:1,2', - 'startTime' => 'requireIf:type,5|dateFormat:H:i', - 'endTime' => 'requireIf:type,5|dateFormat:H:i', 'accountGroups' => 'requireIf:type,5|array|min:1', // 通用参数 - 'deveiceGroups' => 'requireIf:type,1,2,5|array', + 'deviceGroups' => 'requireIf:type,1,2,5|array', ]; /** @@ -142,8 +140,8 @@ class Workbench extends Validate 'timeType.requireIf' => '请选择时间类型', // 通用提示 - 'deveiceGroups.require' => '请选择设备', - 'deveiceGroups.array' => '设备格式错误', + 'deviceGroups.require' => '请选择设备', + 'deviceGroups.array' => '设备格式错误', 'targetGroups.require' => '请选择目标用户组', 'targetGroups.array' => '目标用户组格式错误', 'accountGroups.requireIf' => '流量分发时必须选择分发账号', @@ -155,7 +153,7 @@ class Workbench extends Validate * 验证场景 */ protected $scene = [ - 'create' => ['name', 'type', 'autoStart', 'deveiceGroups', 'targetGroups', + 'create' => ['name', 'type', 'autoStart', 'deviceGroups', 'targetGroups', 'interval', 'maxLikes', 'startTime', 'endTime', 'contentTypes', 'syncInterval', 'syncCount', 'syncType', 'pushType', 'startTime', 'endTime', 'maxPerDay', 'pushOrder', 'isLoop', 'status', 'wechatGroups', 'contentGroups', @@ -163,7 +161,7 @@ class Workbench extends Validate 'groupNameTemplate', 'maxGroupsPerDay', 'groupSizeMin', 'groupSizeMax', ], 'update_status' => ['id', 'status'], - 'edit' => ['name', 'type', 'autoStart', 'deveiceGroups', 'targetGroups', + 'edit' => ['name', 'type', 'autoStart', 'deviceGroups', 'targetGroups', 'interval', 'maxLikes', 'startTime', 'endTime', 'contentTypes', 'syncInterval', 'syncCount', 'syncType', 'pushType', 'startTime', 'endTime', 'maxPerDay', 'pushOrder', 'isLoop', 'status', 'wechatGroups', 'contentGroups', From 69613450c78453f7971648eab190cb1e3aa6d7d4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=B6=85=E7=BA=A7=E8=80=81=E7=99=BD=E5=85=94?= Date: Mon, 22 Sep 2025 14:15:58 +0800 Subject: [PATCH 4/4] =?UTF-8?q?FEAT=20=3D>=20=E6=9C=AC=E6=AC=A1=E6=9B=B4?= =?UTF-8?q?=E6=96=B0=E9=A1=B9=E7=9B=AE=E4=B8=BA=EF=BC=9A?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Cunkebao/dist/.vite/manifest.json | 2 +- Cunkebao/dist/index.html | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Cunkebao/dist/.vite/manifest.json b/Cunkebao/dist/.vite/manifest.json index 84b25020..6b45f04e 100644 --- a/Cunkebao/dist/.vite/manifest.json +++ b/Cunkebao/dist/.vite/manifest.json @@ -33,7 +33,7 @@ "name": "vendor" }, "index.html": { - "file": "assets/index-Czxez1-3.js", + "file": "assets/index-ROCKxzay.js", "name": "index", "src": "index.html", "isEntry": true, diff --git a/Cunkebao/dist/index.html b/Cunkebao/dist/index.html index 6e11cb6c..db844bbc 100644 --- a/Cunkebao/dist/index.html +++ b/Cunkebao/dist/index.html @@ -11,7 +11,7 @@ - +