| | |
| | | import { DeptVO } from './../dept/types'; |
| | | import {DeptTreeVO, DeptVO} from './../dept/types'; |
| | | import { RoleVO } from '@/api/system/role/types'; |
| | | import request from '@/utils/request'; |
| | | import { AxiosPromise } from 'axios'; |
| | |
| | | url: '/system/user/list', |
| | | method: 'get', |
| | | params: query |
| | | }); |
| | | }; |
| | | |
| | | /** |
| | | * 通过用户ids查询用户 |
| | | * @param userIds |
| | | */ |
| | | export const optionSelect = (userIds: (number | string)[]): AxiosPromise<UserVO[]> => { |
| | | return request({ |
| | | url: '/system/user/optionselect?userIds=' + userIds, |
| | | method: 'get' |
| | | }); |
| | | }; |
| | | |
| | |
| | | return request({ |
| | | url: '/system/user/resetPwd', |
| | | method: 'put', |
| | | headers: { |
| | | isEncrypt: true, |
| | | repeatSubmit: false |
| | | }, |
| | | data: data |
| | | }); |
| | | }; |
| | |
| | | return request({ |
| | | url: '/system/user/profile/updatePwd', |
| | | method: 'put', |
| | | params: data |
| | | headers: { |
| | | isEncrypt: true, |
| | | repeatSubmit: false |
| | | }, |
| | | data: data |
| | | }); |
| | | }; |
| | | |
| | |
| | | /** |
| | | * 查询部门下拉树结构 |
| | | */ |
| | | export const deptTreeSelect = (): AxiosPromise<DeptVO[]> => { |
| | | export const deptTreeSelect = (): AxiosPromise<DeptTreeVO[]> => { |
| | | return request({ |
| | | url: '/system/user/deptTree', |
| | | method: 'get' |
| | |
| | | export default { |
| | | listUser, |
| | | getUser, |
| | | optionSelect, |
| | | addUser, |
| | | updateUser, |
| | | delUser, |