Files
FastGPT/packages/global/common/error/code/plugin.ts
Archer a259d034b8 4.8.3 (#1654)
* Milvus (#1644)

* feat: support regx

* 4.8.3 test and fix (#1648)

* perf: version tip

* feat: sandbox support log

* fix: debug component render

* fix: share page header

* fix: input guide auth

* fix: iso viewport

* remove file

* fix: route url

* feat: add debug timout

* perf: reference select support trigger

* perf: session code

* perf: theme

* perf: load milvus
2024-06-01 09:26:11 +08:00

29 lines
588 B
TypeScript

import { ErrType } from '../errorCode';
/* dataset: 508000 */
export enum PluginErrEnum {
unExist = 'pluginUnExist',
unAuth = 'pluginUnAuth'
}
const errList = [
{
statusText: PluginErrEnum.unExist,
message: '插件不存在'
},
{
statusText: PluginErrEnum.unAuth,
message: '无权操作该插件'
}
];
export default errList.reduce((acc, cur, index) => {
return {
...acc,
[cur.statusText]: {
code: 508000 + index,
statusText: cur.statusText,
message: cur.message,
data: null
}
};
}, {} as ErrType<`${PluginErrEnum}`>);