2.0的js版本和后端 完成

This commit is contained in:
zhuoda
2022-10-22 20:49:25 +08:00
parent b782b953a5
commit 2621703f1f
1504 changed files with 81667 additions and 76100 deletions

View File

@@ -0,0 +1,34 @@
/*
* 类目api
*
* @Author: 卓大
* @Date: 2022-09-03 21:35:00
* @Wechat: zhuda1024
* @Email: lab1024@163.com
* @Copyright 1024创新实验室 https://1024lab.net 2012-2022
*/
import { getRequest, postRequest } from '/@/lib/axios';
export const categoryApi = {
// 添加类目 @author 卓大
addCategory: (param) => {
return postRequest('/category/add', param);
},
// GET
// 删除类目 @author 卓大
deleteCategoryById: (categoryId) => {
return getRequest(`/category/delete/${categoryId}`);
},
// 查询类目层级树 @author 卓大
queryCategoryTree: (param) => {
return postRequest('/category/tree', param);
},
// 更新类目 @author 卓大
updateCategory: (param) => {
return postRequest('/category/update', param);
},
// 查询类目详情 @author 卓大
getCategory: (categoryId) => {
return getRequest(`/category/${categoryId}`);
},
};

View File

@@ -0,0 +1,31 @@
/*
* @Description:
* @Author: zhuoda
* @Date: 2021-11-05
* @LastEditTime: 2022-06-23
* @LastEditors: zhuoda
*/
import { postRequest, getRequest } from '/@/lib/axios';
export const goodsApi = {
// 添加商品 @author zhuoda
addGoods: (param) => {
return postRequest('/goods/add', param);
},
// 删除 @author zhuoda
deleteGoods: (goodsId) => {
return getRequest(`/goods/delete/${goodsId}`);
},
// 批量 @author zhuoda
batchDelete: (goodsIdList) => {
return postRequest('/goods/batchDelete', goodsIdList);
},
// 分页查询 @author zhuoda
queryGoodsList: (param) => {
return postRequest('/goods/query', param);
},
// 更新商品 @author zhuoda
updateGoods: (param) => {
return postRequest('/goods/update', param);
},
};

View File

@@ -0,0 +1,42 @@
/*
* 银行卡
*
* @Author: 善逸
* @Date: 2022-09-03 21:42:08
* @Wechat: zhuda1024
* @Email: lab1024@163.com
* @Copyright 1024创新实验室 https://1024lab.net 2012-2022
*/
import { postRequest, getRequest } from '/@/lib/axios';
export const bankApi = {
// 新建银行信息 @author 善逸
create: (param) => {
return postRequest('/oa/bank/create', param);
},
// 删除银行信息 @author 善逸
delete: (bankId) => {
return getRequest(`/oa/bank/delete/${bankId}`);
},
// 查询银行信息详情 @author 善逸
detail: (bankId) => {
return getRequest(`/oa/bank/get/${bankId}`);
},
// 分页查询银行信息 @author 善逸
pageQuery: (param) => {
return postRequest('/oa/bank/page/query', param);
},
// 编辑银行信息 @author 善逸
update: (param) => {
return postRequest('/oa/bank/update', param);
},
// 根据企业ID查询不分页的银行列表 @author 善逸
queryList: (enterpriseId) => {
return getRequest(`/oa/bank/query/list/${enterpriseId}`);
},
};

View File

@@ -0,0 +1,64 @@
/*
* 企业信息
*
* @Author: 开云
* @Date: 2022-09-03 21:47:28
* @Wechat: zhuda1024
* @Email: lab1024@163.com
* @Copyright 1024创新实验室 https://1024lab.net 2012-2022
*/
import { postRequest, getRequest } from '/@/lib/axios';
export const enterpriseApi = {
// 新建企业 @author 开云
create: (param) => {
return postRequest('/oa/enterprise/create', param);
},
// 删除企业 @author 开云
delete: (enterpriseId) => {
return getRequest(`/oa/enterprise/delete/${enterpriseId}`);
},
// 查询企业详情 @author 开云
detail: (enterpriseId) => {
return getRequest(`/oa/enterprise/get/${enterpriseId}`);
},
// 分页查询企业模块 @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}`);
},
// 编辑企业 @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);
},
};

View File

@@ -0,0 +1,44 @@
/*
* OA发票信息
*
* @Author: 善逸
* @Date: 2022-09-03 21:48:54
* @Wechat: zhuda1024
* @Email: lab1024@163.com
* @Copyright 1024创新实验室 https://1024lab.net 2012-2022
*/
import { postRequest, getRequest } from '/@/lib/axios';
export const invoiceApi = {
// 新建发票信息 @author 善逸
create: (param) => {
return postRequest('/oa/invoice/create', param);
},
// 删除发票信息 @author 善逸
delete: (bankId) => {
return getRequest(`/oa/invoice/delete/${bankId}`);
},
// 查询发票信息详情 @author 善逸
detail: (bankId) => {
return getRequest(`//oa/invoice/get/${bankId}`);
},
// 分页查询发票信息 @author 善逸
pageQuery: (param) => {
return postRequest('/oa/invoice/page/query', param);
},
// 编辑发票信息 @author 善逸
update: (param) => {
return postRequest('/oa/invoice/update', param);
},
// 查询发票列表 @author 善逸
queryList: (enterpriseId) => {
return getRequest(`/oa/invoice/query/list/${enterpriseId}`);
},
};

View File

@@ -0,0 +1,74 @@
/*
* @Description: 公告信息、企业动态
* @version:
* @Author: zhuoda
* @Date: 2022-08-16 20:34:36
*/
import { postRequest, getRequest } from '/@/lib/axios';
export const noticeApi = {
// ---------------- 通知公告类型 -----------------------
// 通知公告类型-获取全部 @author zhuoda
getAllNoticeTypeList() {
return getRequest('/oa/noticeType/getAll');
},
// 通知公告类型-添加 @author zhuoda
addNoticeType(name) {
return getRequest(`/oa/noticeType/add/${name}`);
},
// 通知公告类型-修改 @author zhuoda
updateNoticeType(noticeTypeId, name) {
return getRequest(`/oa/noticeType/update/${noticeTypeId}/${name}`);
},
// 通知公告类型-删除 @author zhuoda
deleteNoticeType(noticeTypeId) {
return getRequest(`/oa/noticeType/delete/${noticeTypeId}`);
},
// ---------------- 通知公告管理 -----------------------
// 通知公告-分页查询 @author zhuoda
queryNotice(param) {
return postRequest('/oa/notice/query', param);
},
// 通知公告-添加 @author zhuoda
addNotice(param) {
return postRequest('/oa/notice/add', param);
},
// 通知公告-更新 @author zhuoda
updateNotice(param) {
return postRequest('/oa/notice/update', param);
},
// 通知公告-删除 @author zhuoda
deleteNotice(noticeId) {
return getRequest(`/oa/notice/delete/${noticeId}`);
},
// 通知公告-更新详情 @author zhuoda
getUpdateNoticeInfo(noticeId) {
return getRequest(`/oa/notice/getUpdateVO/${noticeId}`);
},
// --------------------- 【员工】查看 通知公告 -------------------------
// 通知公告-员工-查看详情 @author zhuoda
view(noticeId) {
return getRequest(`/oa/notice/employee/view/${noticeId}`);
},
// 通知公告-员工-查询 @author zhuoda
queryEmployeeNotice(param) {
return postRequest('/oa/notice/employee/query', param);
},
// 【员工】通知公告-查询 查看记录 @author zhuoda
queryViewRecord(param) {
return postRequest('/oa/notice/employee/queryViewRecord', param);
},
};

View File

@@ -0,0 +1,25 @@
/*
* 缓存
*
* @Author: 罗伊
* @Date: 2022-09-03 21:51:34
* @Wechat: zhuda1024
* @Email: lab1024@163.com
* @Copyright 1024创新实验室 https://1024lab.net 2012-2022
*/
import { postRequest, getRequest } from '/@/lib/axios';
export const cacheApi = {
// 获取某个缓存的所有key @author 罗伊
getKeys: (cacheName) => {
return getRequest(`/support/cache/keys/${cacheName}`);
},
// 移除某个缓存 @author 罗伊
remove: (cacheName) => {
return getRequest(`/support/cache/remove/${cacheName}`);
},
// 获取所有缓存 @author 罗伊
getAllCacheNames: () => {
return getRequest('/support/cache/names');
},
};

View File

@@ -0,0 +1,45 @@
/**
* 系统更新日志 api 封装
*
* @Author: 卓大
* @Date: 2022-09-26 14:53:50
* @Copyright 1024创新实验室
*/
import { postRequest, getRequest } from '/@/lib/axios';
export const changeLogApi = {
/**
* 分页查询 @author 卓大
*/
queryPage : (param) => {
return postRequest('/changeLog/queryPage', param);
},
/**
* 增加 @author 卓大
*/
add: (param) => {
return postRequest('/changeLog/add', param);
},
/**
* 修改 @author 卓大
*/
update: (param) => {
return postRequest('/changeLog/update', param);
},
/**
* 删除 @author 卓大
*/
delete: (id) => {
return getRequest(`/changeLog/delete/${id}`);
},
/**
* 批量删除 @author 卓大
*/
batchDelete: (idList) => {
return postRequest('/changeLog/batchDelete', idList);
},
};

View File

@@ -0,0 +1,46 @@
/*
* 代码生成器
*
* @Author: 卓大
* @Date: 2022-09-03 21:51:54
* @Wechat: zhuda1024
* @Email: lab1024@163.com
* @Copyright 1024创新实验室 https://1024lab.net 2012-2022
*/
import { getRequest, postRequest,download } from '/@/lib/axios';
export const codeGeneratorApi = {
// 查询数据库的表 @author 卓大
queryTableList: (param) => {
return postRequest('/support/codeGenerator/table/queryTableList', param);
},
// 查询表的列 @author 卓大
getTableColumns: (table) => {
return getRequest(`/support/codeGenerator/table/getTableColumns/${table}`);
},
// ------------------- 配置 -------------------
// 获取表的配置信息 @author 卓大
getConfig: (table) => {
return getRequest(`/support/codeGenerator/table/getConfig/${table}`);
},
// 更新配置信息 @author 卓大
updateConfig: (param) => {
return postRequest('/support/codeGenerator/table/updateConfig', param);
},
// ------------------- 生成 -------------------
// 预览代码 @author 卓大
preview: (param) => {
return postRequest('/support/codeGenerator/code/preview', param);
},
// 下载代码 @author 卓大
downloadCode: (tableName) => {
return download(`${tableName}.zip`,`/support/codeGenerator/code/download/${tableName}`);
},
};

View File

@@ -0,0 +1,29 @@
/*
* 配置
*
* @Author: 卓大
* @Date: 2022-09-03 21:51:54
* @Wechat: zhuda1024
* @Email: lab1024@163.com
* @Copyright 1024创新实验室 https://1024lab.net 2012-2022
*/
import { postRequest, getRequest } from '/@/lib/axios';
export const configApi = {
// 分页查询 @author 卓大
queryList: (param) => {
return postRequest('/support/config/query', param);
},
// 添加配置参数 @author 卓大
addConfig: (param) => {
return postRequest('/support/config/add', param);
},
// 修改配置参数 @author 卓大
updateConfig: (param) => {
return postRequest('/support/config/update', param);
},
// 查询配置详情 @author 卓大
queryByKey: (param) => {
return getRequest(`/support/config/queryByKey?configKey=${param}`);
},
};

View File

@@ -0,0 +1,18 @@
/*
* 数据变动
*
* @Author: 卓大
* @Date: 2022-09-03 21:51:54
* @Wechat: zhuda1024
* @Email: lab1024@163.com
* @Copyright 1024创新实验室 https://1024lab.net 2012-2022
*/
import { postRequest } from '/@/lib/axios';
export const dataTracerApi = {
// 分页查询业务操作日志 - @author 卓大
queryList: (param) => {
return postRequest('/support/dataTracer/query', param);
},
};

View File

@@ -0,0 +1,59 @@
/*
* 字典
*
* @Author: 1024创新实验室-主任:卓大
* @Date: 2022-09-03 21:55:25
* @Wechat: zhuda1024
* @Email: lab1024@163.com
* @Copyright 1024创新实验室 https://1024lab.net 2012-2022
*/
import { postRequest, getRequest } from '/@/lib/axios';
export const dictApi = {
// 分页查询数据字典KEY - @author 卓大
keyQuery: (param) => {
return postRequest('/support/dict/key/query', param);
},
// 查询全部字典key - @author 卓大
queryAllKey: () => {
return getRequest('/support/dict/key/queryAll');
},
/**
* 分页查询数据字典value - @author 卓大
*/
valueQuery: (param) => {
return postRequest('/support/dict/value/query', param);
},
// 数据字典KEY-添加- @author 卓大
keyAdd: (param) => {
return postRequest('/support/dict/key/add', param);
},
// 分页查询数据字典value - @author 卓大
valueAdd: (param) => {
return postRequest('/support/dict/value/add', param);
},
// 数据字典key-更新- @author 卓大
keyEdit: (param) => {
return postRequest('/support/dict/key/edit', param);
},
// 数据字典Value-更新- @author 卓大
valueEdit: (param) => {
return postRequest('/support/dict/value/edit', param);
},
// 数据字典key-删除- @author 卓大
keyDelete: (keyIdList) => {
return postRequest('/support/dict/key/delete', keyIdList);
},
// 数据字典Value-删除- @author 卓大
valueDelete: (valueIdList) => {
return postRequest('/support/dict/value/delete', valueIdList);
},
// 缓存刷新- @author 卓大
cacheRefresh: () => {
return getRequest('/support/dict/cache/refresh');
},
// 数据字典-值列表- @author 卓大
valueList: (keyCode) => {
return getRequest(`/support/dict/value/list/${keyCode}`);
},
};

View File

@@ -0,0 +1,21 @@
/*
* 意见反馈
*
* @Author: 1024创新实验室开云
* @Date: 2022-09-03 21:56:31
* @Wechat: zhuda1024
* @Email: lab1024@163.com
* @Copyright 1024创新实验室 https://1024lab.net 2012-2022
*/
import { postRequest } from '/@/lib/axios';
export const feedbackApi = {
// 意见反馈-新增
addFeedback: (params) => {
return postRequest('/support/feedback/add', params);
},
// 意见反馈-分页查询
queryFeedback: (params) => {
return postRequest('/support/feedback/query', params);
},
};

View File

@@ -0,0 +1,38 @@
/*
* 文件上传
*
* @Author: 1024创新实验室-主任:卓大
* @Date: 2022-09-03 21:55:25
* @Wechat: zhuda1024
* @Email: lab1024@163.com
* @Copyright 1024创新实验室 https://1024lab.net 2012-2022
*/
import { postRequest, getRequest, download } from '/@/lib/axios';
export const fileApi = {
// 文件上传 @author 卓大
uploadUrl: '/support/file/upload',
uploadFile: (param, folder) => {
return postRequest(`/support/file/upload?folder=${folder}`, param);
},
/**
* 分页查询 @author 卓大
*/
queryPage: (param) => {
return postRequest('/support/file/queryPage', param);
},
/**
* 获取文件URL根据fileKey @author 胡克
*/
getUrl: (fileKey) => {
return getRequest(`/support/file/getFileUrl?fileKey=${fileKey}`);
},
/**
* 下载文件流根据fileKey @author 胡克
*/
downLoadFile: (fileName, fileKey) => {
return download(fileName, '/support/file/downLoad', { fileKey });
},
};

View File

@@ -0,0 +1,17 @@
/*
* 心跳
*
* @Author: 1024创新实验室-主任:卓大
* @Date: 2022-09-03 21:55:47
* @Wechat: zhuda1024
* @Email: lab1024@163.com
* @Copyright 1024创新实验室 https://1024lab.net 2012-2022
*/
import { postRequest } from '/@/lib/axios';
export const heartBeatApi = {
// 分页查询 @author 卓大
queryList: (param) => {
return postRequest('/support/heartBeat/query', param);
},
};

View File

@@ -0,0 +1,59 @@
/*
* 帮助文档
*
* @Author: 1024创新实验室-主任:卓大
* @Date: 2022-09-03 21:56:31
* @Wechat: zhuda1024
* @Email: lab1024@163.com
* @Copyright 1024创新实验室 https://1024lab.net 2012-2022
*/
import { postRequest, getRequest } from '/@/lib/axios';
export const helpDocApi = {
// 【管理】帮助文档-分页查询 @author zhuoda
query: (param) => {
return postRequest('/support/helpDoc/query', param);
},
//【管理】帮助文档-更新 @author zhuoda
update: (param) => {
return postRequest('/support/helpDoc/update', param);
},
// 【管理】帮助文档-添加 @author zhuoda
add: (param) => {
return postRequest('/support/helpDoc/add', param);
},
//【管理】帮助文档-删除 @author zhuoda
delete: (helpDocId) => {
return getRequest(`/support/helpDoc/delete/${helpDocId}`);
},
//【管理】帮助文档-获取详情 @author zhuoda
getDetail: (helpDocId) => {
return getRequest(`/support/helpDoc/getDetail/${helpDocId}`);
},
//【管理】帮助文档-根据关联id查询 @author zhuoda
queryHelpDocByRelationId: (relationId) => {
return getRequest(`/support/helpDoc/queryHelpDocByRelationId/${relationId}`);
},
//----------------------- 用户相关 --------------------------------
//【用户】帮助文档-查询全部 @author zhuoda
getAllHelpDocList() {
return getRequest('/support/helpDoc/user/queryAllHelpDocList');
},
//【用户】帮助文档-查询全部 @author zhuoda
view(helpDocId) {
return getRequest(`/support/helpDoc/user/view/${helpDocId}`);
},
//【用户】帮助文档-查询 查看记录 @author zhuoda
queryViewRecord(param) {
return postRequest('/support/helpDoc/user/queryViewRecord', param);
},
};

View File

@@ -0,0 +1,32 @@
/*
* 帮助文档 目录
*
* @Author: 1024创新实验室-主任:卓大
* @Date: 2022-09-03 21:56:31
* @Wechat: zhuda1024
* @Email: lab1024@163.com
* @Copyright 1024创新实验室 https://1024lab.net 2012-2022
*/
import { postRequest, getRequest } from '/@/lib/axios';
export const helpDocCatalogApi = {
//帮助文档目录-获取全部 @author zhuoda
getAll: () => {
return getRequest('/support/helpDoc/helpDocCatalog/getAll');
},
//帮助文档目录-添加 @author zhuoda
add: (param) => {
return postRequest('/support/helpDoc/helpDocCatalog/add', param);
},
//帮助文档目录-更新 @author zhuoda
update: (param) => {
return postRequest('/support/helpDoc/helpDocCatalog/update', param);
},
//帮助文档目录-删除 @author zhuoda
delete: (helpDocCatalogId) => {
return getRequest(`/support/helpDoc/helpDocCatalog/delete/${helpDocCatalogId}`);
},
};

View File

@@ -0,0 +1,17 @@
/*
* 登录日志
*
* @Author: 1024创新实验室-主任:卓大
* @Date: 2022-09-03 21:56:31
* @Wechat: zhuda1024
* @Email: lab1024@163.com
* @Copyright 1024创新实验室 https://1024lab.net 2012-2022
*/
import { postRequest, getRequest } from '/@/lib/axios';
export const loginLogApi = {
// 分页查询 @author 卓大
queryList: (param) => {
return postRequest('/support/loginLog/page/query', param);
},
};

View File

@@ -0,0 +1,21 @@
/*
* 操作日志
*
* @Author: 1024创新实验室-主任:卓大
* @Date: 2022-09-03 21:56:45
* @Wechat: zhuda1024
* @Email: lab1024@163.com
* @Copyright 1024创新实验室 https://1024lab.net 2012-2022
*/
import { postRequest, getRequest } from '/@/lib/axios';
export const operateLogApi = {
// 分页查询 @author 卓大
queryList: (param) => {
return postRequest('/support/operateLog/page/query', param);
},
// 详情 @author 卓大
detail: (id) => {
return getRequest(`/support/operateLog/detail/${id}`);
},
};

View File

@@ -0,0 +1,25 @@
/*
* reload (内存热加载、钩子等)
*
* @Author: 1024创新实验室-主任:卓大
* @Date: 2022-09-03 21:57:19
* @Wechat: zhuda1024
* @Email: lab1024@163.com
* @Copyright 1024创新实验室 https://1024lab.net 2012-2022
*/
import { postRequest, getRequest } from '/@/lib/axios';
export const reloadApi = {
// 查询reload列表 @author 卓大
queryList: () => {
return getRequest('/support/reload/query');
},
// 获取reload result @author 卓大
queryReloadResult: (tag) => {
return getRequest(`/support/reload/result/${tag}`);
},
// 执行reload @author 卓大
reload: (reloadForm) => {
return postRequest('/support/reload/update', reloadForm);
},
};

View File

@@ -0,0 +1,25 @@
/*
* 单据序列号
*
* @Author: 1024创新实验室-主任:卓大
* @Date: 2022-09-03 21:57:52
* @Wechat: zhuda1024
* @Email: lab1024@163.com
* @Copyright 1024创新实验室 https://1024lab.net 2012-2022
*/
import { postRequest, getRequest } from '/@/lib/axios';
export const serialNumberApi = {
// 生成单号 @author 卓大
generate: (generateForm) => {
return postRequest('/support/serialNumber/generate', generateForm);
},
// 获取所有单号定义 @author 卓大
getAll: () => {
return getRequest('/support/serialNumber/all');
},
// 获取生成记录 @author 卓大
queryRecord: (form) => {
return postRequest('/support/serialNumber/queryRecord', form);
},
};

View File

@@ -0,0 +1,26 @@
/*
* @Description:表格自定义列
* @version:
* @Author: zhuoda
* @Date: 2022-08-17 23:32:36
* @LastEditors: zhuoda
* @LastEditTime: 2022-08-21
*/
import { postRequest, getRequest } from '/@/lib/axios';
export const tableColumnApi = {
// 修改表格列 @author zhuoda
updateTableColumn: (param) => {
return postRequest('/support/tableColumn/update', param);
},
// 查询表格列 @author zhuoda
getColumns: (tableId) => {
return getRequest(`/support/tableColumn/getColumns/${tableId}`);
},
// 删除表格列 @author zhuoda
deleteColumns: (tableId) => {
return getRequest(`/support/tableColumn/delete/${tableId}`);
},
};

View File

@@ -0,0 +1,55 @@
/*
* 部门
*
* @Author: 1024创新实验室-主任:卓大
* @Date: 2022-09-03 21:58:50
* @Wechat: zhuda1024
* @Email: lab1024@163.com
* @Copyright 1024创新实验室 https://1024lab.net 2012-2022
*/
import { getRequest, postRequest } from '/@/lib/axios';
export const departmentApi = {
/**
* @description: 查询部门列表 @author 卓大
* @param {*}
* @return {*}
*/
queryAllDepartment: () => {
return getRequest('/department/listAll');
},
/**
* @description: 查询部门树形列表 @author 卓大
* @param {*}
* @return {*}
*/
queryDepartmentTree: () => {
return getRequest('/department/treeList');
},
/**
* @description: 添加部门 @author 卓大
* @param {*}
* @return {*}
*/
addDepartment: (param) => {
return postRequest('/department/add', param);
},
/**
* @description: 更新部门信息 @author 卓大
* @param {*}
* @return {*}
*/
updateDepartment: (param) => {
return postRequest('/department/update', param);
},
/**
* @description: 获取校区列表 @author 卓大
* @param {*}
* @return {*}
*/
deleteDepartment: (departmentId) => {
return getRequest(`/department/delete/${departmentId}`);
},
};

View File

@@ -0,0 +1,98 @@
/*
* 员工
*
* @Author: 1024创新实验室-主任:卓大
* @Date: 2022-09-03 21:59:15
* @Wechat: zhuda1024
* @Email: lab1024@163.com
* @Copyright 1024创新实验室 https://1024lab.net 2012-2022
*/
import { getRequest, postRequest } from '/@/lib/axios';
export const employeeApi = {
/**
* @description: 查询所有员工 @author 卓大
* @param {*}
* @return {*}
*/
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);
},
/**
* @description: 更新员工禁用状态
* @param {number} employeeId
* @return {*}
*/
updateDisabled: (employeeId) => {
return getRequest(`/employee/update/disabled/${employeeId}`);
},
// 查询员工-根据部门id
queryEmployeeByDeptId: (departmentId) => {
return getRequest(`/employee/query/dept/${departmentId}`);
},
};

View File

@@ -0,0 +1,29 @@
/*
* 首页api
*
* @Author: 1024创新实验室-主任:卓大
* @Date: 2022-09-03 21:59:39
* @Wechat: zhuda1024
* @Email: lab1024@163.com
* @Copyright 1024创新实验室 https://1024lab.net 2012-2022
*/
import { getRequest } from '/@/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');
},
};

View File

@@ -0,0 +1,51 @@
/*
* 登录
*
* @Author: 1024创新实验室-主任:卓大
* @Date: 2022-09-03 21:59:58
* @Wechat: zhuda1024
* @Email: lab1024@163.com
* @Copyright 1024创新实验室 https://1024lab.net 2012-2022
*/
import { getRequest, postRequest } from '/@/lib/axios';
export const loginApi = {
/**
* 登录 @author 卓大
* @param param
*/
login: (param) => {
return postRequest('/login', param);
},
/**
* 退出登录 @author 卓大
* @param param
*/
logout: () => {
return getRequest('/login/logout');
},
/**
* 获取验证码 @author 卓大
* @param param
*/
getCaptcha: () => {
return getRequest('/login/getCaptcha');
},
/**
* 获取登录信息 @author 卓大
* @param param
*/
getLoginInfo: () => {
return getRequest('/login/getLoginInfo');
},
/**
* 刷新用户信息(包含用户基础信息、权限信息等等) @author 卓大
*/
refresh: () => {
return getRequest('/login/refresh');
},
};

View File

@@ -0,0 +1,54 @@
/*
* 菜单
*
* @Author: 1024创新实验室-主任:卓大
* @Date: 2022-09-03 22:00:32
* @Wechat: zhuda1024
* @Email: lab1024@163.com
* @Copyright 1024创新实验室 https://1024lab.net 2012-2022
*/
import { getRequest, postRequest } from '/@/lib/axios';
export const menuApi = {
/**
* 添加菜单
*/
addMenu: (param) => {
return postRequest('/menu/add', param);
},
/**
* 更新菜单
*/
updateMenu: (param) => {
return postRequest('/menu/update', param);
},
/**
* 批量删除菜单
*/
batchDeleteMenu: (menuIdList) => {
return getRequest(`/menu/batchDelete?menuIdList=${menuIdList}`);
},
/**
* 查询所有菜单列表
*/
queryMenu: () => {
return getRequest('/menu/query');
},
/**
* 查询菜单树
*/
queryMenuTree: (onlyMenu) => {
return getRequest(`/menu/tree?onlyMenu=${onlyMenu}`);
},
/**
* 获取所有请求路径
*/
getAuthUrl: () => {
return getRequest('/menu/auth/url');
},
};

View File

@@ -0,0 +1,28 @@
/*
* 角色菜单
*
* @Author: 1024创新实验室-主任:卓大
* @Date: 2022-09-03 22:00:49
* @Wechat: zhuda1024
* @Email: lab1024@163.com
* @Copyright 1024创新实验室 https://1024lab.net 2012-2022
*/
import { getRequest, postRequest } from '/@/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);
},
};

View File

@@ -0,0 +1,110 @@
/*
* 角色
*
* @Author: 1024创新实验室-主任:卓大
* @Date: 2022-09-03 22:00:41
* @Wechat: zhuda1024
* @Email: lab1024@163.com
* @Copyright 1024创新实验室 https://1024lab.net 2012-2022
*/
import { getRequest, postRequest } from '/@/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);
},
};