| | |
| | | |
| | | export interface User { |
| | | userId: string; |
| | | loginName:string; |
| | | userName: string; |
| | | nickName: string; |
| | | email: string; |
| | | phoneNumber: string; |
| | | dept: any; |
| | | deptName:string; |
| | | resources: any; |
| | | knowledges: any; |
| | | dialogs: any; |
| | | createTime: string; |
| | | status: string; |
| | | psw:string; |
| | | role:string; |
| | | roleName:string; |
| | | } |
| | | |
| | | export interface Organization { |
| | |
| | | msg: string; |
| | | rows: T; |
| | | total: number; |
| | | } |
| | | |
| | | export interface Role { |
| | | roleId: string; |
| | | createTime: string; |
| | | updateTime: string; |
| | | roleName: string; |
| | | remark: string; |
| | | iconCls: string; |
| | | roleSort: string; |
| | | status: string; |
| | | roleKey: string; |
| | | dataScope: string; |
| | | dept: any; |
| | | resources: any; |
| | | knowledges: any; |
| | | dialogs: any; |
| | | agents: any; |
| | | } |
| | | |
| | | export function RoleList(params: Pagination) { |
| | | return axios.get<Result<Role[]>>('/base/system/role/list', { params }); |
| | | } |
| | | |
| | | export function RoleDelete(id) { |
| | | return axios.delete('/base/system/role/' + id); |
| | | } |
| | | |
| | | export function RoleEdit(role) { |
| | | return axios.put('/base/system/role', { role }); |
| | | } |
| | | |
| | | export function RoleAdd(role) { |
| | | return axios.post('/base/system/role', { role }); |
| | | } |
| | | |
| | | export function Rolestatus(roleId, status) { |
| | | return axios.put('/base/system/role/changeStatus', { |
| | | roleId: roleId, |
| | | status: status, |
| | | }); |
| | | } |
| | | |
| | | export function UserList(params: Pagination) { |
| | |
| | | } |
| | | |
| | | export function KnowledgeList() { |
| | | return axios.get<Result<Knowledge>>('/base/system/knowledge/list'); |
| | | return axios.get<Result<Knowledge>>('/api/v1/kb/list'); |
| | | } |
| | | |
| | | export function DialogList() { |
| | | return axios.get<Result<Knowledge>>('/base/system/dialog/list'); |
| | | return axios.get<Result<Knowledge>>('/api/v1/dialog/list'); |
| | | } |