mirror of
https://gitee.com/270580156/weiyu.git
synced 2026-05-16 04:07:51 +00:00
update
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
* @Author: jackning 270580156@qq.com
|
||||
* @Date: 2024-06-05 21:50:54
|
||||
* @LastEditors: jackning 270580156@qq.com
|
||||
* @LastEditTime: 2025-06-12 14:32:18
|
||||
* @LastEditTime: 2025-06-17 11:04:59
|
||||
* @Description: bytedesk.com https://github.com/Bytedesk/bytedesk
|
||||
* Please be aware of the BSL license restrictions before installing Bytedesk IM –
|
||||
* selling, reselling, or hosting Bytedesk IM as a service is a breach of the terms and automatically terminates your rights under the license.
|
||||
@@ -46,6 +46,7 @@ public enum MessageTypeEnum {
|
||||
TICKET_SUBMIT, // 工单提交
|
||||
TYPING, // 正在输入
|
||||
PROCESSING, // 正在处理,等待大模型回复中
|
||||
STICKER, // 贴纸
|
||||
//
|
||||
PREVIEW, // 消息预知
|
||||
RECALL, // 撤回
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* @Author: jackning 270580156@qq.com
|
||||
* @Date: 2024-04-04 17:05:48
|
||||
* @LastEditors: jackning 270580156@qq.com
|
||||
* @LastEditTime: 2025-06-16 13:33:01
|
||||
* @LastEditTime: 2025-06-17 11:05:25
|
||||
* @Description: bytedesk.com https://github.com/Bytedesk/bytedesk
|
||||
* Please be aware of the BSL license restrictions before installing Bytedesk IM –
|
||||
* selling, reselling, or hosting Bytedesk IM as a service is a breach of the terms and automatically terminates your rights under the license.
|
||||
@@ -113,6 +113,9 @@ public class VisitorRequest extends BaseRequest {
|
||||
|
||||
private String metaThreadExtra;
|
||||
|
||||
// telegram extra
|
||||
private String telegramThreadExtra;
|
||||
|
||||
public Boolean isWeChat() {
|
||||
// 忽略大小写
|
||||
return this.client.toLowerCase().contains(ClientEnum.WECHAT.name().toLowerCase());
|
||||
@@ -131,6 +134,14 @@ public class VisitorRequest extends BaseRequest {
|
||||
return this.client.toLowerCase().contains(ClientEnum.WECHAT_WORK.name().toLowerCase());
|
||||
}
|
||||
|
||||
/**
|
||||
* 判断是否为Telegram客户端
|
||||
* @return true 如果为Telegram客户端,否则为 false
|
||||
*/
|
||||
public Boolean isTelegram() {
|
||||
// 忽略大小写
|
||||
return this.client.toLowerCase().contains(ClientEnum.TELEGRAM.name().toLowerCase());
|
||||
}
|
||||
|
||||
public void setWorkgroupType() {
|
||||
this.type = String.valueOf(ThreadTypeEnum.WORKGROUP.getValue());
|
||||
|
||||
@@ -115,6 +115,8 @@ public class VisitorThreadService
|
||||
extra = visitorRequest.getWeChatThreadExtra();
|
||||
} else if (visitorRequest.isMeta()) {
|
||||
extra = visitorRequest.getMetaThreadExtra();
|
||||
} else if (visitorRequest.isTelegram()) {
|
||||
extra = visitorRequest.getTelegramThreadExtra();
|
||||
} else {
|
||||
extra = ServiceConvertUtils
|
||||
.convertToServiceSettingsResponseVisitorJSONString(workgroup.getServiceSettings());
|
||||
@@ -148,6 +150,9 @@ public class VisitorThreadService
|
||||
} else if (visitorRequest.isMeta()) {
|
||||
String metaExtra = visitorRequest.getMetaThreadExtra();
|
||||
thread.setExtra(metaExtra);
|
||||
} else if (visitorRequest.isTelegram()) {
|
||||
String telegramExtra = visitorRequest.getTelegramThreadExtra();
|
||||
thread.setExtra(telegramExtra);
|
||||
} else {
|
||||
String extra = ServiceConvertUtils
|
||||
.convertToServiceSettingsResponseVisitorJSONString(workgroup.getServiceSettings());
|
||||
|
||||
Reference in New Issue
Block a user