feat(consultation): unify server-distributed agents without fixed roles
This commit is contained in:
@@ -23,7 +23,7 @@ export interface TeacherAccount {
|
||||
}
|
||||
export function assertTeacherAccount(account: TeacherAccount) {
|
||||
if (!isCurrentWorksSquareAccountBinding(account.binding))
|
||||
throw new TeacherError(401, 'teacher_account_changed', '登录账号已变化,请重新打开老师。');
|
||||
throw new TeacherError(401, 'teacher_account_changed', '登录账号已变化,请重新打开智能体。');
|
||||
}
|
||||
export async function teacherCloudRequest<T>(
|
||||
account: TeacherAccount,
|
||||
@@ -55,7 +55,7 @@ export async function teacherCloudRequest<T>(
|
||||
? '当前账号没有使用权限。'
|
||||
: response.status === 409
|
||||
? '草稿已变化,请在运营页面重新打开试聊。'
|
||||
: '老师配置暂不可用,请稍后重试。';
|
||||
: '智能体配置暂不可用,请稍后重试。';
|
||||
throw new TeacherError(response.status, code, message);
|
||||
}
|
||||
return (await response.json()) as T;
|
||||
|
||||
Reference in New Issue
Block a user