mirror of
https://gitee.com/lab1024/smart-admin.git
synced 2025-11-13 22:23:48 +08:00
v3.0.0
This commit is contained in:
@@ -27,8 +27,4 @@ export const categoryApi = {
|
||||
updateCategory: (param) => {
|
||||
return postRequest('/category/update', param);
|
||||
},
|
||||
// 查询类目详情 @author 卓大
|
||||
getCategory: (categoryId) => {
|
||||
return getRequest(`/category/${categoryId}`);
|
||||
},
|
||||
};
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
* @LastEditTime: 2022-06-23
|
||||
* @LastEditors: zhuoda
|
||||
*/
|
||||
import { postRequest, getRequest } from '/@/lib/axios';
|
||||
import {postRequest, getRequest, getDownload} from '/@/lib/axios';
|
||||
|
||||
export const goodsApi = {
|
||||
// 添加商品 @author zhuoda
|
||||
@@ -28,4 +28,14 @@ export const goodsApi = {
|
||||
updateGoods: (param) => {
|
||||
return postRequest('/goods/update', param);
|
||||
},
|
||||
|
||||
// 导入 @author 卓大
|
||||
importGoods : (file) =>{
|
||||
return postRequest('/goods/importGoods',file);
|
||||
},
|
||||
|
||||
// 导出 @author 卓大
|
||||
exportGoods : () =>{
|
||||
return getDownload('/goods/exportGoods');
|
||||
}
|
||||
};
|
||||
|
||||
@@ -7,58 +7,63 @@
|
||||
* @Email: lab1024@163.com
|
||||
* @Copyright 1024创新实验室 ( https://1024lab.net ),Since 2012
|
||||
*/
|
||||
import { postRequest, getRequest } from '/@/lib/axios';
|
||||
import {postRequest, getRequest, postDownload} from '/@/lib/axios';
|
||||
|
||||
export const enterpriseApi = {
|
||||
// 新建企业 @author 开云
|
||||
create: (param) => {
|
||||
return postRequest('/oa/enterprise/create', param);
|
||||
},
|
||||
// 新建企业 @author 开云
|
||||
create: (param) => {
|
||||
return postRequest('/oa/enterprise/create', param);
|
||||
},
|
||||
|
||||
// 删除企业 @author 开云
|
||||
delete: (enterpriseId) => {
|
||||
return getRequest(`/oa/enterprise/delete/${enterpriseId}`);
|
||||
},
|
||||
// 删除企业 @author 开云
|
||||
delete: (enterpriseId) => {
|
||||
return getRequest(`/oa/enterprise/delete/${enterpriseId}`);
|
||||
},
|
||||
|
||||
// 查询企业详情 @author 开云
|
||||
detail: (enterpriseId) => {
|
||||
return getRequest(`/oa/enterprise/get/${enterpriseId}`);
|
||||
},
|
||||
// 查询企业详情 @author 开云
|
||||
detail: (enterpriseId) => {
|
||||
return getRequest(`/oa/enterprise/get/${enterpriseId}`);
|
||||
},
|
||||
|
||||
// 分页查询企业模块 @author 开云
|
||||
pageQuery: (param) => {
|
||||
return postRequest('/oa/enterprise/page/query', param);
|
||||
},
|
||||
// 分页查询企业模块 @author 开云
|
||||
pageQuery: (param) => {
|
||||
return postRequest('/oa/enterprise/page/query', param);
|
||||
},
|
||||
|
||||
//企业列表查询 含数据范围 @author 开云
|
||||
queryList: (type) => {
|
||||
let query = '';
|
||||
if (type) {
|
||||
query = `?type=${type}`;
|
||||
}
|
||||
return getRequest(`/oa/enterprise/query/list${query}`);
|
||||
},
|
||||
// 导出企业数据excel @author 卓大
|
||||
exportExcel: (param) => {
|
||||
return postDownload('/oa/enterprise/exportExcel', param);
|
||||
},
|
||||
|
||||
// 编辑企业 @author 开云
|
||||
update: (param) => {
|
||||
return postRequest('/oa/enterprise/update', param);
|
||||
},
|
||||
// 企业全部员工List @author yandy
|
||||
employeeList: (param) => {
|
||||
return postRequest('/oa/enterprise/employee/list', param);
|
||||
},
|
||||
// 分页查询企业员工List @author 卓大
|
||||
queryPageEmployeeList: (param) => {
|
||||
return postRequest('/oa/enterprise/employee/queryPage', param);
|
||||
},
|
||||
// 添加员工 @author yandy
|
||||
addEmployee: (param) => {
|
||||
return postRequest('/oa/enterprise/employee/add', param);
|
||||
},
|
||||
//企业列表查询 含数据范围 @author 开云
|
||||
queryList: (type) => {
|
||||
let query = '';
|
||||
if (type) {
|
||||
query = `?type=${type}`;
|
||||
}
|
||||
return getRequest(`/oa/enterprise/query/list${query}`);
|
||||
},
|
||||
|
||||
// 删除员工 @author yandy
|
||||
deleteEmployee: (param) => {
|
||||
return postRequest('/oa/enterprise/employee/delete', param);
|
||||
},
|
||||
// 编辑企业 @author 开云
|
||||
update: (param) => {
|
||||
return postRequest('/oa/enterprise/update', param);
|
||||
},
|
||||
// 企业全部员工List @author yandy
|
||||
employeeList: (param) => {
|
||||
return postRequest('/oa/enterprise/employee/list', param);
|
||||
},
|
||||
// 分页查询企业员工List @author 卓大
|
||||
queryPageEmployeeList: (param) => {
|
||||
return postRequest('/oa/enterprise/employee/queryPage', param);
|
||||
},
|
||||
// 添加员工 @author yandy
|
||||
addEmployee: (param) => {
|
||||
return postRequest('/oa/enterprise/employee/add', param);
|
||||
},
|
||||
|
||||
// 删除员工 @author yandy
|
||||
deleteEmployee: (param) => {
|
||||
return postRequest('/oa/enterprise/employee/delete', param);
|
||||
},
|
||||
|
||||
};
|
||||
|
||||
@@ -0,0 +1,40 @@
|
||||
/**
|
||||
* 接口:加密、解密
|
||||
*
|
||||
* @Author: 1024创新实验室-主任-卓大
|
||||
* @Date: 2023-10-17 20:02:37
|
||||
* @Copyright 1024创新实验室
|
||||
*/
|
||||
import { postRequest, postEncryptRequest } from '/src/lib/axios';
|
||||
|
||||
export const encryptApi = {
|
||||
|
||||
/**
|
||||
* 测试 请求加密 @author 1024创新实验室-主任-卓大
|
||||
*/
|
||||
testRequestEncrypt: (param) => {
|
||||
return postEncryptRequest('/support/apiEncrypt/testRequestEncrypt', param);
|
||||
},
|
||||
|
||||
/**
|
||||
* 测试 返回加密 @author 1024创新实验室-主任-卓大
|
||||
*/
|
||||
testResponseEncrypt: (param) => {
|
||||
return postRequest('/support/apiEncrypt/testResponseEncrypt', param);
|
||||
},
|
||||
|
||||
/**
|
||||
* 测试 请求参数加密和解密、返回数据加密和解密 @author 1024创新实验室-主任-卓大
|
||||
*/
|
||||
testDecryptAndEncrypt: (param) => {
|
||||
return postEncryptRequest('/support/apiEncrypt/testDecryptAndEncrypt', param);
|
||||
},
|
||||
|
||||
/**
|
||||
* 测试 数组加解密 @author 1024创新实验室-主任-卓大
|
||||
*/
|
||||
testArray : (param) => {
|
||||
return postEncryptRequest('/support/apiEncrypt/testArray', param);
|
||||
},
|
||||
|
||||
};
|
||||
@@ -7,7 +7,7 @@
|
||||
* @Email: lab1024@163.com
|
||||
* @Copyright 1024创新实验室 ( https://1024lab.net ),Since 2012
|
||||
*/
|
||||
import { postRequest, getRequest } from '/@/lib/axios';
|
||||
import {getRequest} from '/src/lib/axios';
|
||||
|
||||
export const cacheApi = {
|
||||
// 获取某个缓存的所有key @author 罗伊
|
||||
@@ -5,41 +5,41 @@
|
||||
* @Date: 2022-09-26 14:53:50
|
||||
* @Copyright 1024创新实验室
|
||||
*/
|
||||
import { postRequest, getRequest } from '/@/lib/axios';
|
||||
import { postRequest, getRequest } from '/src/lib/axios';
|
||||
|
||||
export const changeLogApi = {
|
||||
/**
|
||||
* 分页查询 @author 卓大
|
||||
*/
|
||||
queryPage : (param) => {
|
||||
return postRequest('/changeLog/queryPage', param);
|
||||
queryPage: (param) => {
|
||||
return postRequest('/support/changeLog/queryPage', param);
|
||||
},
|
||||
|
||||
/**
|
||||
* 增加 @author 卓大
|
||||
*/
|
||||
add: (param) => {
|
||||
return postRequest('/changeLog/add', param);
|
||||
return postRequest('/support/changeLog/add', param);
|
||||
},
|
||||
|
||||
/**
|
||||
* 修改 @author 卓大
|
||||
*/
|
||||
update: (param) => {
|
||||
return postRequest('/changeLog/update', param);
|
||||
return postRequest('/support/changeLog/update', param);
|
||||
},
|
||||
|
||||
/**
|
||||
* 删除 @author 卓大
|
||||
*/
|
||||
delete: (id) => {
|
||||
return getRequest(`/changeLog/delete/${id}`);
|
||||
return getRequest(`/support/changeLog/delete/${id}`);
|
||||
},
|
||||
|
||||
/**
|
||||
* 批量删除 @author 卓大
|
||||
*/
|
||||
batchDelete: (idList) => {
|
||||
return postRequest('/changeLog/batchDelete', idList);
|
||||
return postRequest('/support/changeLog/batchDelete', idList);
|
||||
},
|
||||
};
|
||||
@@ -7,7 +7,7 @@
|
||||
* @Email: lab1024@163.com
|
||||
* @Copyright 1024创新实验室 ( https://1024lab.net ),Since 2012
|
||||
*/
|
||||
import { getRequest, postRequest,download } from '/@/lib/axios';
|
||||
import { getRequest, postRequest,getDownload } from '/src/lib/axios';
|
||||
|
||||
export const codeGeneratorApi = {
|
||||
// 查询数据库的表 @author 卓大
|
||||
@@ -41,6 +41,6 @@ export const codeGeneratorApi = {
|
||||
|
||||
// 下载代码 @author 卓大
|
||||
downloadCode: (tableName) => {
|
||||
return download(`${tableName}.zip`,`/support/codeGenerator/code/download/${tableName}`);
|
||||
return getDownload(`${tableName}.zip`,`/support/codeGenerator/code/download/${tableName}`);
|
||||
},
|
||||
};
|
||||
@@ -7,7 +7,7 @@
|
||||
* @Email: lab1024@163.com
|
||||
* @Copyright 1024创新实验室 ( https://1024lab.net ),Since 2012
|
||||
*/
|
||||
import { postRequest, getRequest } from '/@/lib/axios';
|
||||
import { postRequest, getRequest } from '/src/lib/axios';
|
||||
|
||||
export const configApi = {
|
||||
// 分页查询 @author 卓大
|
||||
@@ -7,7 +7,7 @@
|
||||
* @Email: lab1024@163.com
|
||||
* @Copyright 1024创新实验室 ( https://1024lab.net ),Since 2012
|
||||
*/
|
||||
import { postRequest } from '/@/lib/axios';
|
||||
import { postRequest } from '/src/lib/axios';
|
||||
|
||||
export const dataTracerApi = {
|
||||
// 分页查询业务操作日志 - @author 卓大
|
||||
@@ -7,7 +7,7 @@
|
||||
* @Email: lab1024@163.com
|
||||
* @Copyright 1024创新实验室 ( https://1024lab.net ),Since 2012
|
||||
*/
|
||||
import { postRequest, getRequest } from '/@/lib/axios';
|
||||
import { postRequest, getRequest } from '/src/lib/axios';
|
||||
|
||||
export const dictApi = {
|
||||
// 分页查询数据字典KEY - @author 卓大
|
||||
@@ -7,7 +7,7 @@
|
||||
* @Email: lab1024@163.com
|
||||
* @Copyright 1024创新实验室 ( https://1024lab.net ),Since 2012
|
||||
*/
|
||||
import { postRequest } from '/@/lib/axios';
|
||||
import { postRequest } from '/src/lib/axios';
|
||||
|
||||
export const feedbackApi = {
|
||||
// 意见反馈-新增
|
||||
@@ -7,7 +7,7 @@
|
||||
* @Email: lab1024@163.com
|
||||
* @Copyright 1024创新实验室 ( https://1024lab.net ),Since 2012
|
||||
*/
|
||||
import { postRequest, getRequest, download } from '/@/lib/axios';
|
||||
import { postRequest, getRequest, getDownload } from '/src/lib/axios';
|
||||
|
||||
export const fileApi = {
|
||||
// 文件上传 @author 卓大
|
||||
@@ -33,6 +33,6 @@ export const fileApi = {
|
||||
* 下载文件流(根据fileKey) @author 胡克
|
||||
*/
|
||||
downLoadFile: (fileName, fileKey) => {
|
||||
return download(fileName, '/support/file/downLoad', { fileKey });
|
||||
return getDownload(fileName, '/support/file/downLoad', { fileKey });
|
||||
},
|
||||
};
|
||||
@@ -7,7 +7,7 @@
|
||||
* @Email: lab1024@163.com
|
||||
* @Copyright 1024创新实验室 ( https://1024lab.net ),Since 2012
|
||||
*/
|
||||
import { postRequest } from '/@/lib/axios';
|
||||
import { postRequest } from '/src/lib/axios';
|
||||
|
||||
export const heartBeatApi = {
|
||||
// 分页查询 @author 卓大
|
||||
@@ -7,7 +7,7 @@
|
||||
* @Email: lab1024@163.com
|
||||
* @Copyright 1024创新实验室 ( https://1024lab.net ),Since 2012
|
||||
*/
|
||||
import { postRequest, getRequest } from '/@/lib/axios';
|
||||
import { postRequest, getRequest } from '/src/lib/axios';
|
||||
|
||||
export const helpDocApi = {
|
||||
// 【管理】帮助文档-分页查询 @author zhuoda
|
||||
@@ -7,7 +7,7 @@
|
||||
* @Email: lab1024@163.com
|
||||
* @Copyright 1024创新实验室 ( https://1024lab.net ),Since 2012
|
||||
*/
|
||||
import { postRequest, getRequest } from '/@/lib/axios';
|
||||
import { postRequest, getRequest } from '/src/lib/axios';
|
||||
|
||||
export const helpDocCatalogApi = {
|
||||
//帮助文档目录-获取全部 @author zhuoda
|
||||
@@ -0,0 +1,26 @@
|
||||
/**
|
||||
* 登录锁定 api 封装
|
||||
*
|
||||
* @Author: 1024创新实验室-主任-卓大
|
||||
* @Date: 2023-10-17 18:02:37
|
||||
* @Copyright 1024创新实验室
|
||||
*/
|
||||
import { postRequest, getRequest } from '/src/lib/axios';
|
||||
|
||||
export const loginFailApi = {
|
||||
|
||||
/**
|
||||
* 分页查询 @author 1024创新实验室-主任-卓大
|
||||
*/
|
||||
queryPage : (param) => {
|
||||
return postRequest('/support/protect/loginFail/queryPage', param);
|
||||
},
|
||||
|
||||
/**
|
||||
* 批量删除 @author 1024创新实验室-主任-卓大
|
||||
*/
|
||||
batchDelete: (idList) => {
|
||||
return postRequest('/support/protect/loginFail/batchDelete', idList);
|
||||
},
|
||||
|
||||
};
|
||||
@@ -7,7 +7,7 @@
|
||||
* @Email: lab1024@163.com
|
||||
* @Copyright 1024创新实验室 ( https://1024lab.net ),Since 2012
|
||||
*/
|
||||
import { postRequest, getRequest } from '/@/lib/axios';
|
||||
import { postRequest, getRequest } from '/src/lib/axios';
|
||||
|
||||
export const loginLogApi = {
|
||||
// 分页查询 @author 卓大
|
||||
@@ -7,7 +7,7 @@
|
||||
* @Email: lab1024@163.com
|
||||
* @Copyright 1024创新实验室 ( https://1024lab.net ),Since 2012
|
||||
*/
|
||||
import { postRequest, getRequest } from '/@/lib/axios';
|
||||
import { postRequest, getRequest } from '/src/lib/axios';
|
||||
|
||||
export const operateLogApi = {
|
||||
// 分页查询 @author 卓大
|
||||
@@ -7,7 +7,7 @@
|
||||
* @Email: lab1024@163.com
|
||||
* @Copyright 1024创新实验室 ( https://1024lab.net ),Since 2012
|
||||
*/
|
||||
import { postRequest, getRequest } from '/@/lib/axios';
|
||||
import { postRequest, getRequest } from '/src/lib/axios';
|
||||
|
||||
export const reloadApi = {
|
||||
// 查询reload列表 @author 卓大
|
||||
@@ -7,7 +7,7 @@
|
||||
* @Email: lab1024@163.com
|
||||
* @Copyright 1024创新实验室 ( https://1024lab.net ),Since 2012
|
||||
*/
|
||||
import { postRequest, getRequest } from '/@/lib/axios';
|
||||
import { postRequest, getRequest } from '/src/lib/axios';
|
||||
|
||||
export const serialNumberApi = {
|
||||
// 生成单号 @author 卓大
|
||||
@@ -6,7 +6,7 @@
|
||||
* @LastEditors: zhuoda
|
||||
* @LastEditTime: 2022-08-21
|
||||
*/
|
||||
import { postRequest, getRequest } from '/@/lib/axios';
|
||||
import { postRequest, getRequest } from '/src/lib/axios';
|
||||
|
||||
export const tableColumnApi = {
|
||||
// 修改表格列 @author zhuoda
|
||||
@@ -7,47 +7,37 @@
|
||||
* @Email: lab1024@163.com
|
||||
* @Copyright 1024创新实验室 ( https://1024lab.net ),Since 2012
|
||||
*/
|
||||
import { getRequest, postRequest } from '/@/lib/axios';
|
||||
import { getRequest, postRequest } from '/src/lib/axios';
|
||||
|
||||
export const departmentApi = {
|
||||
/**
|
||||
* @description: 查询部门列表 @author 卓大
|
||||
* @param {*}
|
||||
* @return {*}
|
||||
* 查询部门列表 @author 卓大
|
||||
*/
|
||||
queryAllDepartment: () => {
|
||||
return getRequest('/department/listAll');
|
||||
},
|
||||
|
||||
/**
|
||||
* @description: 查询部门树形列表 @author 卓大
|
||||
* @param {*}
|
||||
* @return {*}
|
||||
* 查询部门树形列表 @author 卓大
|
||||
*/
|
||||
queryDepartmentTree: () => {
|
||||
queryDepartmentTree: () => {
|
||||
return getRequest('/department/treeList');
|
||||
},
|
||||
|
||||
/**
|
||||
* @description: 添加部门 @author 卓大
|
||||
* @param {*}
|
||||
* @return {*}
|
||||
* 添加部门 @author 卓大
|
||||
*/
|
||||
addDepartment: (param) => {
|
||||
return postRequest('/department/add', param);
|
||||
},
|
||||
/**
|
||||
* @description: 更新部门信息 @author 卓大
|
||||
* @param {*}
|
||||
* @return {*}
|
||||
* 更新部门信息 @author 卓大
|
||||
*/
|
||||
updateDepartment: (param) => {
|
||||
return postRequest('/department/update', param);
|
||||
},
|
||||
/**
|
||||
* @description: 获取校区列表 @author 卓大
|
||||
* @param {*}
|
||||
* @return {*}
|
||||
* 删除
|
||||
*/
|
||||
deleteDepartment: (departmentId) => {
|
||||
return getRequest(`/department/delete/${departmentId}`);
|
||||
@@ -8,90 +8,73 @@
|
||||
* @Copyright 1024创新实验室 ( https://1024lab.net ),Since 2012
|
||||
*/
|
||||
|
||||
import { getRequest, postRequest } from '/@/lib/axios';
|
||||
import { getRequest, postRequest } from '/src/lib/axios';
|
||||
|
||||
export const employeeApi = {
|
||||
/**
|
||||
* @description: 查询所有员工 @author 卓大
|
||||
* @param {*}
|
||||
* @return {*}
|
||||
* 查询所有员工 @author 卓大
|
||||
*/
|
||||
queryAll: () => {
|
||||
return getRequest('/employee/queryAll');
|
||||
},
|
||||
/**
|
||||
* @description: 员工管理查询
|
||||
* @param {*}
|
||||
* @return {*}
|
||||
* 员工管理查询
|
||||
*/
|
||||
queryEmployee: (params) => {
|
||||
return postRequest('/employee/query', params);
|
||||
},
|
||||
/**
|
||||
* @description: 添加员工
|
||||
* @param {EmployeeAddDto} params
|
||||
* @return {*}
|
||||
* 添加员工
|
||||
*/
|
||||
addEmployee: (params) => {
|
||||
return postRequest('/employee/add', params);
|
||||
},
|
||||
/**
|
||||
* @description: 更新员工信息
|
||||
* @param {EmployeeUpdateDto} params
|
||||
* @return {*}
|
||||
* 更新员工信息
|
||||
*/
|
||||
updateEmployee: (params) => {
|
||||
return postRequest('/employee/update', params);
|
||||
},
|
||||
/**
|
||||
* @description: 删除员工
|
||||
* @param {number} employeeId
|
||||
* @return {*}
|
||||
* 删除员工
|
||||
*/
|
||||
deleteEmployee: (employeeId) => {
|
||||
return getRequest(`/employee/delete/${employeeId}`);
|
||||
},
|
||||
/**
|
||||
* @description: 批量删除员工
|
||||
* @param {number} employeeIdList
|
||||
* @return {*}
|
||||
* 批量删除员工
|
||||
*/
|
||||
batchDeleteEmployee: (employeeIdList) => {
|
||||
return postRequest('/employee/update/batch/delete', employeeIdList);
|
||||
},
|
||||
/**
|
||||
* @description: 批量调整员工部门
|
||||
* @return {*}
|
||||
* 批量调整员工部门
|
||||
*/
|
||||
batchUpdateDepartmentEmployee: (updateParam) => {
|
||||
return postRequest('/employee/update/batch/department', updateParam);
|
||||
},
|
||||
/**
|
||||
* @description: 重置员工密码
|
||||
* @param {number} employeeId
|
||||
* @return {*}
|
||||
* 重置员工密码
|
||||
*/
|
||||
resetPassword: (employeeId) => {
|
||||
return getRequest(`/employee/update/password/reset/${employeeId}`);
|
||||
},
|
||||
/**
|
||||
* @description: 修改面面
|
||||
* @param {number} employeeId
|
||||
* @return {*}
|
||||
* 修改面面
|
||||
*/
|
||||
updateEmployeePassword: (param) => {
|
||||
return postRequest('/employee/update/password',param);
|
||||
return postRequest('/employee/update/password', param);
|
||||
},
|
||||
/**
|
||||
* @description: 更新员工禁用状态
|
||||
* @param {number} employeeId
|
||||
* @return {*}
|
||||
* 更新员工禁用状态
|
||||
*/
|
||||
updateDisabled: (employeeId) => {
|
||||
return getRequest(`/employee/update/disabled/${employeeId}`);
|
||||
},
|
||||
|
||||
// 查询员工-根据部门id
|
||||
/**
|
||||
* 查询员工-根据部门id
|
||||
*/
|
||||
queryEmployeeByDeptId: (departmentId) => {
|
||||
return getRequest(`/employee/query/dept/${departmentId}`);
|
||||
},
|
||||
@@ -7,21 +7,17 @@
|
||||
* @Email: lab1024@163.com
|
||||
* @Copyright 1024创新实验室 ( https://1024lab.net ),Since 2012
|
||||
*/
|
||||
import { getRequest } from '/@/lib/axios';
|
||||
import { getRequest } from '/src/lib/axios';
|
||||
|
||||
export const homeApi = {
|
||||
/**
|
||||
* @description: 首页-金额统计(业绩、收款、订单数等) @author 卓大
|
||||
* @param {*}
|
||||
* @return {*}
|
||||
*/
|
||||
homeAmountStatistics: () => {
|
||||
return getRequest('/home/amount/statistics');
|
||||
},
|
||||
/**
|
||||
* @description: 首页-待办信息 @author 卓大
|
||||
* @param {*}
|
||||
* @return {*}
|
||||
*/
|
||||
homeWaitHandle: () => {
|
||||
return getRequest('home/wait/handle');
|
||||
@@ -7,12 +7,11 @@
|
||||
* @Email: lab1024@163.com
|
||||
* @Copyright 1024创新实验室 ( https://1024lab.net ),Since 2012
|
||||
*/
|
||||
import { getRequest, postRequest } from '/@/lib/axios';
|
||||
import { getRequest, postRequest } from '/src/lib/axios';
|
||||
|
||||
export const loginApi = {
|
||||
/**
|
||||
* 登录 @author 卓大
|
||||
* @param param
|
||||
*/
|
||||
login: (param) => {
|
||||
return postRequest('/login', param);
|
||||
@@ -20,7 +19,6 @@ export const loginApi = {
|
||||
|
||||
/**
|
||||
* 退出登录 @author 卓大
|
||||
* @param param
|
||||
*/
|
||||
logout: () => {
|
||||
return getRequest('/login/logout');
|
||||
@@ -28,7 +26,6 @@ export const loginApi = {
|
||||
|
||||
/**
|
||||
* 获取验证码 @author 卓大
|
||||
* @param param
|
||||
*/
|
||||
getCaptcha: () => {
|
||||
return getRequest('/login/getCaptcha');
|
||||
@@ -36,16 +33,8 @@ export const loginApi = {
|
||||
|
||||
/**
|
||||
* 获取登录信息 @author 卓大
|
||||
* @param param
|
||||
*/
|
||||
getLoginInfo: () => {
|
||||
return getRequest('/login/getLoginInfo');
|
||||
},
|
||||
|
||||
/**
|
||||
* 刷新用户信息(包含用户基础信息、权限信息等等) @author 卓大
|
||||
*/
|
||||
refresh: () => {
|
||||
return getRequest('/login/refresh');
|
||||
},
|
||||
};
|
||||
@@ -7,7 +7,7 @@
|
||||
* @Email: lab1024@163.com
|
||||
* @Copyright 1024创新实验室 ( https://1024lab.net ),Since 2012
|
||||
*/
|
||||
import { getRequest, postRequest } from '/@/lib/axios';
|
||||
import { getRequest, postRequest } from '/src/lib/axios';
|
||||
|
||||
export const menuApi = {
|
||||
/**
|
||||
@@ -7,102 +7,77 @@
|
||||
* @Email: lab1024@163.com
|
||||
* @Copyright 1024创新实验室 ( https://1024lab.net ),Since 2012
|
||||
*/
|
||||
import { getRequest, postRequest } from '/@/lib/axios';
|
||||
import { getRequest, postRequest } from '/src/lib/axios';
|
||||
|
||||
export const roleApi = {
|
||||
/**
|
||||
* @description: 获取所有角色
|
||||
* @param {*}
|
||||
* @return {*}
|
||||
*/
|
||||
queryAll: () => {
|
||||
return getRequest('/role/getAll');
|
||||
},
|
||||
/**
|
||||
* @description:添加角色
|
||||
* @param {*}
|
||||
* @return {*}
|
||||
*/
|
||||
addRole: (data) => {
|
||||
return postRequest('/role/add', data);
|
||||
},
|
||||
/**
|
||||
* @description:更新角色
|
||||
* @param {*}
|
||||
* @return {*}
|
||||
*/
|
||||
updateRole: (data) => {
|
||||
return postRequest('/role/update', data);
|
||||
},
|
||||
/**
|
||||
* @description: 删除角色
|
||||
* @param {number} roleId
|
||||
* @return {*}
|
||||
*/
|
||||
deleteRole: (roleId) => {
|
||||
return getRequest(`/role/delete/${roleId}`);
|
||||
},
|
||||
/**
|
||||
* @description: 批量设置某角色数据范围
|
||||
* @param {DataScopeBatchSetRoleDto} data
|
||||
* @return {*}
|
||||
*/
|
||||
updateDataScope: (data) => {
|
||||
return postRequest('/role/dataScope/updateRoleDataScopeList', data);
|
||||
},
|
||||
/**
|
||||
* @description: 获取当前系统所配置的所有数据范围
|
||||
* @param {*}
|
||||
* @return {*}
|
||||
*/
|
||||
getDataScopeList: () => {
|
||||
return getRequest('/dataScope/list');
|
||||
},
|
||||
/**
|
||||
* @description: 获取某角色所设置的数据范围
|
||||
* @param {number} roleId
|
||||
* @return {*}
|
||||
*/
|
||||
getDataScopeByRoleId: (roleId) => {
|
||||
return getRequest(`/role/dataScope/getRoleDataScopeList/${roleId}`);
|
||||
},
|
||||
/**
|
||||
* @description: 获取角色成员-员工列表
|
||||
* @param {*}
|
||||
* @return {*}
|
||||
*/
|
||||
queryRoleEmployee: (params) => {
|
||||
return postRequest('/role/employee/queryEmployee', params);
|
||||
},
|
||||
/**
|
||||
* @description: 从角色成员列表中移除员工
|
||||
* @param {number} employeeId
|
||||
* @param {number} roleId
|
||||
* @return {*}
|
||||
*/
|
||||
deleteEmployeeRole: (employeeId, roleId) => {
|
||||
return getRequest('/role/employee/removeEmployee?employeeId=' + employeeId + '&roleId=' + roleId);
|
||||
},
|
||||
/**
|
||||
* @description: 从角色成员列表中批量移除员工
|
||||
* @param {RoleEmployeeBatchDto} data
|
||||
* @return {*}
|
||||
*/
|
||||
batchRemoveRoleEmployee: (data) => {
|
||||
return postRequest('/role/employee/batchRemoveRoleEmployee', data);
|
||||
},
|
||||
/**
|
||||
* @description: 根据角色id获取角色员工列表(无分页)
|
||||
* @param {*}
|
||||
* @return {*}
|
||||
*/
|
||||
getRoleAllEmployee: (roleId) => {
|
||||
return getRequest(`/role/employee/getAllEmployeeByRoleId/${roleId}`);
|
||||
},
|
||||
/**
|
||||
* @description: 角色成员列表中批量添加员工
|
||||
* @param data
|
||||
* @return {*}
|
||||
*/
|
||||
batchAddRoleEmployee: (data) => {
|
||||
return postRequest('/role/employee/batchAddRoleEmployee', data);
|
||||
@@ -7,20 +7,16 @@
|
||||
* @Email: lab1024@163.com
|
||||
* @Copyright 1024创新实验室 ( https://1024lab.net ),Since 2012
|
||||
*/
|
||||
import { getRequest, postRequest } from '/@/lib/axios';
|
||||
import { getRequest, postRequest } from '/src/lib/axios';
|
||||
export const roleMenuApi = {
|
||||
/**
|
||||
* @description: 获取角色关联菜单权限
|
||||
* @param {*}
|
||||
* @return {*}
|
||||
*/
|
||||
getRoleSelectedMenu: (roleId) => {
|
||||
return getRequest(`role/menu/getRoleSelectedMenu/${roleId}`);
|
||||
},
|
||||
/**
|
||||
* @description: 更新角色权限
|
||||
* @param {*}
|
||||
* @return {*}
|
||||
*/
|
||||
updateRoleMenu: (data) => {
|
||||
return postRequest('role/menu/updateRoleMenu', data);
|
||||
Reference in New Issue
Block a user