mirror of
https://github.com/kuaifan/dootask.git
synced 2025-12-12 19:35:50 +00:00
fix: 修复机器人发送消息接口
This commit is contained in:
parent
2fe28d2335
commit
d1f00b2d48
@ -1642,6 +1642,16 @@ class DialogController extends AbstractController
|
||||
return Base::retError('消息内容最大不能超过2000字');
|
||||
}
|
||||
//
|
||||
if (!in_array($botType, [
|
||||
'system-msg',
|
||||
'task-alert',
|
||||
'check-in',
|
||||
'approval-alert',
|
||||
'meeting-alert',
|
||||
'bot-manager',
|
||||
])) {
|
||||
return Base::retError('机器人类型错误');
|
||||
}
|
||||
$botUser = User::botGetOrCreate($botType);
|
||||
if (empty($botUser)) {
|
||||
return Base::retError('机器人不存在');
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user