Merge branch 'dev' of http://47.92.113.182:3000/cq_anquan/safety-eval-service-frontend into dev
commit
ba0a5e8610
|
|
@ -529,7 +529,7 @@ export default Connect([NS_USER_CERTIFICATE], true)(Permission(List));
|
||||||
## 11. 目录结构参考
|
## 11. 目录结构参考
|
||||||
|
|
||||||
```
|
```
|
||||||
safety-eval-service-frontend/
|
safetyEval-service-frontend/
|
||||||
├── public/
|
├── public/
|
||||||
│ └── index.html # HTML 模板
|
│ └── index.html # HTML 模板
|
||||||
├── src/
|
├── src/
|
||||||
|
|
|
||||||
|
|
@ -10,9 +10,9 @@
|
||||||
|
|
||||||
| 项 | 说明 |
|
| 项 | 说明 |
|
||||||
|---|---|
|
|---|---|
|
||||||
| 前端 | `safety-eval-service-frontend`,`npm run dev` / `pnpm dev` |
|
| 前端 | `safetyEval-service-frontend`,`npm run dev` / `pnpm dev` |
|
||||||
| 后端 | `safety-eval-service`,`http://127.0.0.1:8095/safety-eval`,profile=`local` |
|
| 后端 | `safetyEval-service`,`http://127.0.0.1:8095/safetyEval`,profile=`local` |
|
||||||
| 数据库 | 执行 `safety-eval-service/docs/init-v2.sql` 及末尾测试数据段 |
|
| 数据库 | 执行 `safetyEval-service/docs/init-v2.sql` 及末尾测试数据段 |
|
||||||
| Node | `source scripts/setup-test-env.sh` 或 JetBrains Node 24.x |
|
| Node | `source scripts/setup-test-env.sh` 或 JetBrains Node 24.x |
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
@ -22,14 +22,14 @@
|
||||||
### 2.1 接口联调(细粒度)
|
### 2.1 接口联调(细粒度)
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
cd safety-eval-service-frontend
|
cd safetyEval-service-frontend
|
||||||
source scripts/setup-test-env.sh # 可选
|
source scripts/setup-test-env.sh # 可选
|
||||||
node scripts/test-enterprise-info-granular.mjs
|
node scripts/test-enterprise-info-granular.mjs
|
||||||
```
|
```
|
||||||
|
|
||||||
- 脚本:`scripts/test-enterprise-info-granular.mjs`
|
- 脚本:`scripts/test-enterprise-info-granular.mjs`
|
||||||
- 覆盖:8 模块 CRUD、分页、搜索、字段组装(`deptName`/`postName`/`account`/`auditStatusCode`)
|
- 覆盖:8 模块 CRUD、分页、搜索、字段组装(`deptName`/`postName`/`account`/`auditStatusCode`)
|
||||||
- 环境变量:`API_BASE`(默认 `http://127.0.0.1:8095/safety-eval`)
|
- 环境变量:`API_BASE`(默认 `http://127.0.0.1:8095/safetyEval`)
|
||||||
|
|
||||||
### 2.2 前端 UI 静态检查
|
### 2.2 前端 UI 静态检查
|
||||||
|
|
||||||
|
|
@ -173,7 +173,7 @@ UI 静态检查: 31 / 31 通过
|
||||||
```
|
```
|
||||||
执行人:自动化脚本
|
执行人:自动化脚本
|
||||||
执行时间:2026-06-23(后端重启后)
|
执行时间:2026-06-23(后端重启后)
|
||||||
后端:http://127.0.0.1:8095/safety-eval
|
后端:http://127.0.0.1:8095/safetyEval
|
||||||
|
|
||||||
接口测试: 58 / 58 通过
|
接口测试: 58 / 58 通过
|
||||||
UI 静态检查: 31 / 31 通过
|
UI 静态检查: 31 / 31 通过
|
||||||
|
|
@ -208,4 +208,4 @@ UI 静态检查: 31 / 31 通过
|
||||||
| API 适配 | `src/api/enterpriseInfo/adapter.js` |
|
| API 适配 | `src/api/enterpriseInfo/adapter.js` |
|
||||||
| 表单工具 | `src/utils/enterpriseForm.js` |
|
| 表单工具 | `src/utils/enterpriseForm.js` |
|
||||||
| 上传 Mock | `src/utils/mockUpload.js` |
|
| 上传 Mock | `src/utils/mockUpload.js` |
|
||||||
| 后端组装 | `safety-eval-app/.../OrgPersonnelViewEnricher.java` |
|
| 后端组装 | `safetyEval-app/.../OrgPersonnelViewEnricher.java` |
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@
|
||||||
# 企业信息管理联调测试环境变量
|
# 企业信息管理联调测试环境变量
|
||||||
# 用法: source scripts/setup-test-env.sh
|
# 用法: source scripts/setup-test-env.sh
|
||||||
|
|
||||||
export API_BASE="${API_BASE:-http://127.0.0.1:8095/safety-eval}"
|
export API_BASE="${API_BASE:-http://127.0.0.1:8095/safetyEval}"
|
||||||
export SAFETY_EVAL_API_HOST="${SAFETY_EVAL_API_HOST:-http://127.0.0.1:8095}"
|
export SAFETY_EVAL_API_HOST="${SAFETY_EVAL_API_HOST:-http://127.0.0.1:8095}"
|
||||||
|
|
||||||
# JetBrains 内置 Node(系统 PATH 无 node 时使用)
|
# JetBrains 内置 Node(系统 PATH 无 node 时使用)
|
||||||
|
|
|
||||||
|
|
@ -1,8 +1,8 @@
|
||||||
/**
|
/**
|
||||||
* 企业信息管理 - 后端接口联调冒烟测试
|
* 企业信息管理 - 后端接口联调冒烟测试
|
||||||
* 运行: API_BASE=http://127.0.0.1:8095/safety-eval node scripts/test-enterprise-info-api.mjs
|
* 运行: API_BASE=http://127.0.0.1:8095/safetyEval node scripts/test-enterprise-info-api.mjs
|
||||||
*/
|
*/
|
||||||
const API_BASE = process.env.API_BASE || "http://127.0.0.1:8095/safety-eval";
|
const API_BASE = process.env.API_BASE || "http://127.0.0.1:8095/safetyEval";
|
||||||
|
|
||||||
const results = [];
|
const results = [];
|
||||||
let passed = 0;
|
let passed = 0;
|
||||||
|
|
|
||||||
|
|
@ -5,7 +5,7 @@
|
||||||
* source scripts/setup-test-env.sh
|
* source scripts/setup-test-env.sh
|
||||||
* node scripts/test-enterprise-info-granular.mjs
|
* node scripts/test-enterprise-info-granular.mjs
|
||||||
*/
|
*/
|
||||||
const API_BASE = process.env.API_BASE || "http://127.0.0.1:8095/safety-eval";
|
const API_BASE = process.env.API_BASE || "http://127.0.0.1:8095/safetyEval";
|
||||||
const TS = Date.now();
|
const TS = Date.now();
|
||||||
|
|
||||||
const results = [];
|
const results = [];
|
||||||
|
|
|
||||||
|
|
@ -2,12 +2,12 @@
|
||||||
* 资质申请管理 — 前后端联调冒烟测试
|
* 资质申请管理 — 前后端联调冒烟测试
|
||||||
*
|
*
|
||||||
* 运行:
|
* 运行:
|
||||||
* API_BASE=http://127.0.0.1:8095/safety-eval ORG_INFO_ID=1 node docs/test-reports/测试用例/test-qual-filing-api.mjs
|
* API_BASE=http://127.0.0.1:8095/safetyEval ORG_INFO_ID=1 node docs/test-reports/测试用例/test-qual-filing-api.mjs
|
||||||
*
|
*
|
||||||
* 可选:
|
* 可选:
|
||||||
* FRONTEND_BASE=http://127.0.0.1:8081 (检测前端页面是否可访问)
|
* FRONTEND_BASE=http://127.0.0.1:8081 (检测前端页面是否可访问)
|
||||||
*/
|
*/
|
||||||
const API_BASE = process.env.API_BASE || "http://127.0.0.1:8095/safety-eval";
|
const API_BASE = process.env.API_BASE || "http://127.0.0.1:8095/safetyEval";
|
||||||
const ORG_INFO_ID = process.env.ORG_INFO_ID || "1";
|
const ORG_INFO_ID = process.env.ORG_INFO_ID || "1";
|
||||||
const FRONTEND_BASE = process.env.FRONTEND_BASE || "http://127.0.0.1:8081";
|
const FRONTEND_BASE = process.env.FRONTEND_BASE || "http://127.0.0.1:8081";
|
||||||
const DEFAULT_URL =
|
const DEFAULT_URL =
|
||||||
|
|
|
||||||
|
|
@ -2,9 +2,9 @@
|
||||||
* 资质申请管理 — 三模块审核接口 + 整体流程联调
|
* 资质申请管理 — 三模块审核接口 + 整体流程联调
|
||||||
*
|
*
|
||||||
* 运行:
|
* 运行:
|
||||||
* API_BASE=http://127.0.0.1:8095/safety-eval ORG_INFO_ID=1 node docs/test-reports/测试用例/test-qual-filing-audit-flow.mjs
|
* API_BASE=http://127.0.0.1:8095/safetyEval ORG_INFO_ID=1 node docs/test-reports/测试用例/test-qual-filing-audit-flow.mjs
|
||||||
*/
|
*/
|
||||||
const API_BASE = process.env.API_BASE || "http://127.0.0.1:8095/safety-eval";
|
const API_BASE = process.env.API_BASE || "http://127.0.0.1:8095/safetyEval";
|
||||||
const ORG_INFO_ID = process.env.ORG_INFO_ID || "1";
|
const ORG_INFO_ID = process.env.ORG_INFO_ID || "1";
|
||||||
const DEFAULT_URL =
|
const DEFAULT_URL =
|
||||||
"https://s1.aigei.com/prevfiles/6f2754563be2491bad7c957904cd7d2a.jpg?e=2051020800&token=P7S2Xpzfz11vAkASLTkfHN7Fw-oOZBecqeJaxypL:CR60zg7VKDp-jUWyYls_rdvyQMM=";
|
"https://s1.aigei.com/prevfiles/6f2754563be2491bad7c957904cd7d2a.jpg?e=2051020800&token=P7S2Xpzfz11vAkASLTkfHN7Fw-oOZBecqeJaxypL:CR60zg7VKDp-jUWyYls_rdvyQMM=";
|
||||||
|
|
|
||||||
|
|
@ -9,7 +9,7 @@ import { fileURLToPath } from "node:url";
|
||||||
const __dirname = path.dirname(fileURLToPath(import.meta.url));
|
const __dirname = path.dirname(fileURLToPath(import.meta.url));
|
||||||
const ROOT = path.resolve(__dirname, "../../..");
|
const ROOT = path.resolve(__dirname, "../../..");
|
||||||
|
|
||||||
const API_BASE = process.env.API_BASE || "http://127.0.0.1:8095/safety-eval";
|
const API_BASE = process.env.API_BASE || "http://127.0.0.1:8095/safetyEval";
|
||||||
const ORG_INFO_ID = process.env.ORG_INFO_ID || "1";
|
const ORG_INFO_ID = process.env.ORG_INFO_ID || "1";
|
||||||
const DEFAULT_URL =
|
const DEFAULT_URL =
|
||||||
"https://s1.aigei.com/prevfiles/6f2754563be2491bad7c957904cd7d2a.jpg?e=2051020800&token=P7S2Xpzfz11vAkASLTkfHN7Fw-oOZBecqeJaxypL:CR60zg7VKDp-jUWyYls_rdvyQMM=";
|
"https://s1.aigei.com/prevfiles/6f2754563be2491bad7c957904cd7d2a.jpg?e=2051020800&token=P7S2Xpzfz11vAkASLTkfHN7Fw-oOZBecqeJaxypL:CR60zg7VKDp-jUWyYls_rdvyQMM=";
|
||||||
|
|
|
||||||
|
|
@ -18,7 +18,7 @@ import { fileURLToPath } from "node:url";
|
||||||
const __dirname = path.dirname(fileURLToPath(import.meta.url));
|
const __dirname = path.dirname(fileURLToPath(import.meta.url));
|
||||||
const ROOT = path.resolve(__dirname, "../../..");
|
const ROOT = path.resolve(__dirname, "../../..");
|
||||||
|
|
||||||
const API_BASE = process.env.API_BASE || "http://127.0.0.1:8095/safety-eval";
|
const API_BASE = process.env.API_BASE || "http://127.0.0.1:8095/safetyEval";
|
||||||
const ORG_INFO_ID = process.env.ORG_INFO_ID || "1";
|
const ORG_INFO_ID = process.env.ORG_INFO_ID || "1";
|
||||||
const FRONTEND_BASE = process.env.FRONTEND_BASE || "http://127.0.0.1:8081";
|
const FRONTEND_BASE = process.env.FRONTEND_BASE || "http://127.0.0.1:8081";
|
||||||
const DEFAULT_URL =
|
const DEFAULT_URL =
|
||||||
|
|
|
||||||
|
|
@ -8,7 +8,7 @@ module.exports = {
|
||||||
development: {
|
development: {
|
||||||
// 应用后端分支名称,部署上线需要
|
// 应用后端分支名称,部署上线需要
|
||||||
javaGitBranch: "<branch-name>",
|
javaGitBranch: "<branch-name>",
|
||||||
// 本地联调 safety-eval-service(context-path: /safety-eval,默认端口 8095)
|
// 本地联调 safetyEval-service(context-path: /safetyEval,默认端口 8095)
|
||||||
// 可通过环境变量覆盖: SAFETY_EVAL_API_HOST=http://192.168.x.x:8095
|
// 可通过环境变量覆盖: SAFETY_EVAL_API_HOST=http://192.168.x.x:8095
|
||||||
API_HOST: "http://192.168.0.204",
|
API_HOST: "http://192.168.0.204",
|
||||||
},
|
},
|
||||||
|
|
@ -52,7 +52,7 @@ module.exports = {
|
||||||
host: "0.0.0.0",
|
host: "0.0.0.0",
|
||||||
// 是否自动打开浏览器
|
// 是否自动打开浏览器
|
||||||
open: false,
|
open: false,
|
||||||
|
|
||||||
},
|
},
|
||||||
// 框架
|
// 框架
|
||||||
framework: {
|
framework: {
|
||||||
|
|
|
||||||
|
|
@ -35,7 +35,7 @@ export function setOrgInfoDetailCache(detail) {
|
||||||
|
|
||||||
function fetchOrgInfoContext() {
|
function fetchOrgInfoContext() {
|
||||||
const cachedBefore = getOrgInfoId();
|
const cachedBefore = getOrgInfoId();
|
||||||
return apiGet("/safety-eval/org-info/getInfo", {}, {}, { includeOrgContext: false })
|
return apiGet("/safetyEval/org-info/getInfo", {}, {}, { includeOrgContext: false })
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
lastOrgInfoDetail = fromSingleResponse(res, toOrgInfoForm);
|
lastOrgInfoDetail = fromSingleResponse(res, toOrgInfoForm);
|
||||||
const id = lastOrgInfoDetail?.data?.id ?? res?.data?.id;
|
const id = lastOrgInfoDetail?.data?.id ?? res?.data?.id;
|
||||||
|
|
@ -86,7 +86,7 @@ export function ensureOrgContext(options = {}) {
|
||||||
export async function fetchOrgDepartmentPage(params = {}) {
|
export async function fetchOrgDepartmentPage(params = {}) {
|
||||||
await ensureOrgContext();
|
await ensureOrgContext();
|
||||||
const query = toPageQuery(params, { likeDeptName: "deptName" });
|
const query = toPageQuery(params, { likeDeptName: "deptName" });
|
||||||
const res = await apiGet("/safety-eval/org-department/page", query);
|
const res = await apiGet("/safetyEval/org-department/page", query);
|
||||||
return fromPageResponse(res, toDepartmentForm);
|
return fromPageResponse(res, toDepartmentForm);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -96,7 +96,7 @@ export async function fetchOrgPositionPage(params = {}) {
|
||||||
eqDeptId: "deptId",
|
eqDeptId: "deptId",
|
||||||
likePositionName: "positionName",
|
likePositionName: "positionName",
|
||||||
});
|
});
|
||||||
const res = await apiGet("/safety-eval/org-position/page", query);
|
const res = await apiGet("/safetyEval/org-position/page", query);
|
||||||
return fromPageResponse(res, toPositionForm);
|
return fromPageResponse(res, toPositionForm);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -19,34 +19,34 @@ export const equipInfoList = declareRequest("equipInfoLoading", safePageResult(a
|
||||||
if (query.enableFlag !== undefined && query.enableFlag !== "") {
|
if (query.enableFlag !== undefined && query.enableFlag !== "") {
|
||||||
query.enableFlag = mapEquipEnableFlag(query.enableFlag);
|
query.enableFlag = mapEquipEnableFlag(query.enableFlag);
|
||||||
}
|
}
|
||||||
const res = await apiGet("/safety-eval/org-equipment/page", query);
|
const res = await apiGet("/safetyEval/org-equipment/page", query);
|
||||||
return fromPageResponse(res, toEquipForm);
|
return fromPageResponse(res, toEquipForm);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const equipInfoGet = declareRequest("equipInfoLoading", safeAction(async (params) => {
|
export const equipInfoGet = declareRequest("equipInfoLoading", safeAction(async (params) => {
|
||||||
const res = await apiGet("/safety-eval/org-equipment/get", { id: params.id });
|
const res = await apiGet("/safetyEval/org-equipment/get", { id: params.id });
|
||||||
return fromSingleResponse(res, toEquipForm);
|
return fromSingleResponse(res, toEquipForm);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const equipInfoAdd = declareRequest("equipInfoLoading", safeAction(async (values) => {
|
export const equipInfoAdd = declareRequest("equipInfoLoading", safeAction(async (values) => {
|
||||||
const res = await apiPost("/safety-eval/org-equipment/save", fromEquipForm(values));
|
const res = await apiPost("/safetyEval/org-equipment/save", fromEquipForm(values));
|
||||||
return fromSingleResponse(res, toEquipForm);
|
return fromSingleResponse(res, toEquipForm);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const equipInfoEdit = declareRequest("equipInfoLoading", safeAction(async (values) => {
|
export const equipInfoEdit = declareRequest("equipInfoLoading", safeAction(async (values) => {
|
||||||
const res = await apiPost("/safety-eval/org-equipment/modify", fromEquipForm(values));
|
const res = await apiPost("/safetyEval/org-equipment/modify", fromEquipForm(values));
|
||||||
return fromSingleResponse(res, toEquipForm);
|
return fromSingleResponse(res, toEquipForm);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const equipInfoRemove = declareRequest("equipInfoLoading", safeAction(async ({ id }) => {
|
export const equipInfoRemove = declareRequest("equipInfoLoading", safeAction(async ({ id }) => {
|
||||||
return apiPostDelete("/safety-eval/org-equipment/delete", id);
|
return apiPostDelete("/safetyEval/org-equipment/delete", id);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const equipInfoToggleStatus = declareRequest("equipInfoLoading", safeAction(async ({ id }) => {
|
export const equipInfoToggleStatus = declareRequest("equipInfoLoading", safeAction(async ({ id }) => {
|
||||||
const res = await apiGet("/safety-eval/org-equipment/get", { id });
|
const res = await apiGet("/safetyEval/org-equipment/get", { id });
|
||||||
const data = res?.data || {};
|
const data = res?.data || {};
|
||||||
const nextFlag = Number(data.enableFlag) === 1 ? 2 : 1;
|
const nextFlag = Number(data.enableFlag) === 1 ? 2 : 1;
|
||||||
return apiPost("/safety-eval/org-equipment/modify", {
|
return apiPost("/safetyEval/org-equipment/modify", {
|
||||||
...data,
|
...data,
|
||||||
id,
|
id,
|
||||||
enableFlag: nextFlag,
|
enableFlag: nextFlag,
|
||||||
|
|
|
||||||
|
|
@ -10,12 +10,12 @@ import {
|
||||||
import { apiGet, apiPost, apiPostDelete, safeAction, safePageResult } from "../enterpriseInfo/http";
|
import { apiGet, apiPost, apiPostDelete, safeAction, safePageResult } from "../enterpriseInfo/http";
|
||||||
|
|
||||||
export const orgDepartmentGet = declareRequest("orgDepartmentLoading", safeAction(async (params) => {
|
export const orgDepartmentGet = declareRequest("orgDepartmentLoading", safeAction(async (params) => {
|
||||||
const res = await apiGet("/safety-eval/org-department/get", { id: params.id });
|
const res = await apiGet("/safetyEval/org-department/get", { id: params.id });
|
||||||
return fromSingleResponse(res, toDepartmentForm);
|
return fromSingleResponse(res, toDepartmentForm);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const orgDepartmentTree = declareRequest("orgDepartmentLoading", safeAction(async () => {
|
export const orgDepartmentTree = declareRequest("orgDepartmentLoading", safeAction(async () => {
|
||||||
const res = await apiGet("/safety-eval/org-department/page", toPageQuery({ current: 1, size: 500 }));
|
const res = await apiGet("/safetyEval/org-department/page", toPageQuery({ current: 1, size: 500 }));
|
||||||
const pageData = fromPageResponse(res, toDepartmentForm);
|
const pageData = fromPageResponse(res, toDepartmentForm);
|
||||||
return {
|
return {
|
||||||
success: true,
|
success: true,
|
||||||
|
|
@ -25,18 +25,18 @@ export const orgDepartmentTree = declareRequest("orgDepartmentLoading", safeActi
|
||||||
|
|
||||||
export const orgDepartmentList = declareRequest("orgDepartmentLoading", safePageResult(async (params) => {
|
export const orgDepartmentList = declareRequest("orgDepartmentLoading", safePageResult(async (params) => {
|
||||||
const query = toPageQuery(params, { likeDeptName: "deptName" });
|
const query = toPageQuery(params, { likeDeptName: "deptName" });
|
||||||
const res = await apiGet("/safety-eval/org-department/page", query);
|
const res = await apiGet("/safetyEval/org-department/page", query);
|
||||||
return fromPageResponse(res, toDepartmentForm);
|
return fromPageResponse(res, toDepartmentForm);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const orgDepartmentAdd = declareRequest("orgDepartmentLoading", safeAction(async (values) => {
|
export const orgDepartmentAdd = declareRequest("orgDepartmentLoading", safeAction(async (values) => {
|
||||||
return apiPost("/safety-eval/org-department/save", fromDepartmentForm(values));
|
return apiPost("/safetyEval/org-department/save", fromDepartmentForm(values));
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const orgDepartmentEdit = declareRequest("orgDepartmentLoading", safeAction(async (values) => {
|
export const orgDepartmentEdit = declareRequest("orgDepartmentLoading", safeAction(async (values) => {
|
||||||
return apiPost("/safety-eval/org-department/modify", fromDepartmentForm(values));
|
return apiPost("/safetyEval/org-department/modify", fromDepartmentForm(values));
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const orgDepartmentRemove = declareRequest("orgDepartmentLoading", safeAction(async ({ id }) => {
|
export const orgDepartmentRemove = declareRequest("orgDepartmentLoading", safeAction(async ({ id }) => {
|
||||||
return apiPostDelete("/safety-eval/org-department/delete", id);
|
return apiPostDelete("/safetyEval/org-department/delete", id);
|
||||||
}));
|
}));
|
||||||
|
|
|
||||||
|
|
@ -26,7 +26,7 @@ function buildSaveHeaders(payload) {
|
||||||
}
|
}
|
||||||
|
|
||||||
export const orgInfoGet = declareRequest("orgInfoLoading", safeAction(async () => {
|
export const orgInfoGet = declareRequest("orgInfoLoading", safeAction(async () => {
|
||||||
const res = await apiGet("/safety-eval/org-info/getInfo", {}, {}, { includeOrgContext: false });
|
const res = await apiGet("/safetyEval/org-info/getInfo", {}, {}, { includeOrgContext: false });
|
||||||
const result = fromSingleResponse(res, toOrgInfoForm);
|
const result = fromSingleResponse(res, toOrgInfoForm);
|
||||||
return persistOrgInfoId(result, res?.data);
|
return persistOrgInfoId(result, res?.data);
|
||||||
}));
|
}));
|
||||||
|
|
@ -35,8 +35,8 @@ export const orgInfoSave = declareRequest("orgInfoLoading", safeAction(async (va
|
||||||
const payload = fromOrgInfoForm(values, { isDraft: false });
|
const payload = fromOrgInfoForm(values, { isDraft: false });
|
||||||
const headers = buildSaveHeaders(payload);
|
const headers = buildSaveHeaders(payload);
|
||||||
const res = payload.id
|
const res = payload.id
|
||||||
? await apiPost("/safety-eval/org-info/modify", payload, headers)
|
? await apiPost("/safetyEval/org-info/modify", payload, headers)
|
||||||
: await apiPost("/safety-eval/org-info/save", payload, headers);
|
: await apiPost("/safetyEval/org-info/save", payload, headers);
|
||||||
const result = fromSingleResponse(res, toOrgInfoForm);
|
const result = fromSingleResponse(res, toOrgInfoForm);
|
||||||
persistOrgInfoId(result, res?.data);
|
persistOrgInfoId(result, res?.data);
|
||||||
return result;
|
return result;
|
||||||
|
|
@ -46,8 +46,8 @@ export const orgInfoDraft = declareRequest("orgInfoLoading", safeAction(async (v
|
||||||
const payload = fromOrgInfoForm(values, { isDraft: true });
|
const payload = fromOrgInfoForm(values, { isDraft: true });
|
||||||
const headers = buildSaveHeaders(payload);
|
const headers = buildSaveHeaders(payload);
|
||||||
const res = payload.id
|
const res = payload.id
|
||||||
? await apiPost("/safety-eval/org-info/modify", payload, headers)
|
? await apiPost("/safetyEval/org-info/modify", payload, headers)
|
||||||
: await apiPost("/safety-eval/org-info/save", payload, headers);
|
: await apiPost("/safetyEval/org-info/save", payload, headers);
|
||||||
const result = fromSingleResponse(res, toOrgInfoForm);
|
const result = fromSingleResponse(res, toOrgInfoForm);
|
||||||
persistOrgInfoId(result, res?.data);
|
persistOrgInfoId(result, res?.data);
|
||||||
return result;
|
return result;
|
||||||
|
|
|
||||||
|
|
@ -12,18 +12,18 @@ export const orgPositionList = declareRequest("orgPositionLoading", safePageResu
|
||||||
eqDeptId: "deptId",
|
eqDeptId: "deptId",
|
||||||
likePositionName: "positionName",
|
likePositionName: "positionName",
|
||||||
});
|
});
|
||||||
const res = await apiGet("/safety-eval/org-position/page", query);
|
const res = await apiGet("/safetyEval/org-position/page", query);
|
||||||
return fromPageResponse(res, toPositionForm);
|
return fromPageResponse(res, toPositionForm);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const orgPositionAdd = declareRequest("orgPositionLoading", safeAction(async (values) => {
|
export const orgPositionAdd = declareRequest("orgPositionLoading", safeAction(async (values) => {
|
||||||
return apiPost("/safety-eval/org-position/save", fromPositionForm(values));
|
return apiPost("/safetyEval/org-position/save", fromPositionForm(values));
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const orgPositionEdit = declareRequest("orgPositionLoading", safeAction(async (values) => {
|
export const orgPositionEdit = declareRequest("orgPositionLoading", safeAction(async (values) => {
|
||||||
return apiPost("/safety-eval/org-position/modify", fromPositionForm(values));
|
return apiPost("/safetyEval/org-position/modify", fromPositionForm(values));
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const orgPositionRemove = declareRequest("orgPositionLoading", safeAction(async ({ id }) => {
|
export const orgPositionRemove = declareRequest("orgPositionLoading", safeAction(async ({ id }) => {
|
||||||
return apiPostDelete("/safety-eval/org-position/delete", id);
|
return apiPostDelete("/safetyEval/org-position/delete", id);
|
||||||
}));
|
}));
|
||||||
|
|
|
||||||
|
|
@ -10,33 +10,33 @@ import { apiGet, apiPost, apiPostDelete, safeAction, safePageResult } from "../e
|
||||||
|
|
||||||
export const orgQualificationCertList = declareRequest("orgQualificationCertLoading", safePageResult(async (params) => {
|
export const orgQualificationCertList = declareRequest("orgQualificationCertLoading", safePageResult(async (params) => {
|
||||||
const query = toPageQuery(params, { likeCertName: "certName" });
|
const query = toPageQuery(params, { likeCertName: "certName" });
|
||||||
const res = await apiGet("/safety-eval/org-qualification/page", query);
|
const res = await apiGet("/safetyEval/org-qualification/page", query);
|
||||||
return fromPageResponse(res, toQualificationForm);
|
return fromPageResponse(res, toQualificationForm);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const orgQualificationCertInfo = declareRequest("orgQualificationCertLoading", safeAction(async (params) => {
|
export const orgQualificationCertInfo = declareRequest("orgQualificationCertLoading", safeAction(async (params) => {
|
||||||
const res = await apiGet("/safety-eval/org-qualification/get", { id: params.id });
|
const res = await apiGet("/safetyEval/org-qualification/get", { id: params.id });
|
||||||
return fromSingleResponse(res, toQualificationForm);
|
return fromSingleResponse(res, toQualificationForm);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const orgQualificationCertAdd = declareRequest("orgQualificationCertLoading", safeAction(async (values) => {
|
export const orgQualificationCertAdd = declareRequest("orgQualificationCertLoading", safeAction(async (values) => {
|
||||||
const res = await apiPost("/safety-eval/org-qualification/save", fromQualificationForm(values));
|
const res = await apiPost("/safetyEval/org-qualification/save", fromQualificationForm(values));
|
||||||
return fromSingleResponse(res, toQualificationForm);
|
return fromSingleResponse(res, toQualificationForm);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const orgQualificationCertEdit = declareRequest("orgQualificationCertLoading", safeAction(async (values) => {
|
export const orgQualificationCertEdit = declareRequest("orgQualificationCertLoading", safeAction(async (values) => {
|
||||||
const res = await apiPost("/safety-eval/org-qualification/modify", fromQualificationForm(values));
|
const res = await apiPost("/safetyEval/org-qualification/modify", fromQualificationForm(values));
|
||||||
return fromSingleResponse(res, toQualificationForm);
|
return fromSingleResponse(res, toQualificationForm);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const orgQualificationCertRemove = declareRequest("orgQualificationCertLoading", safeAction(async ({ id }) => {
|
export const orgQualificationCertRemove = declareRequest("orgQualificationCertLoading", safeAction(async ({ id }) => {
|
||||||
return apiPostDelete("/safety-eval/org-qualification/delete", id);
|
return apiPostDelete("/safetyEval/org-qualification/delete", id);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const orgQualificationCertDisable = declareRequest("orgQualificationCertLoading", safeAction(async ({ id }) => {
|
export const orgQualificationCertDisable = declareRequest("orgQualificationCertLoading", safeAction(async ({ id }) => {
|
||||||
const res = await apiGet("/safety-eval/org-qualification/get", { id });
|
const res = await apiGet("/safetyEval/org-qualification/get", { id });
|
||||||
const data = res?.data || {};
|
const data = res?.data || {};
|
||||||
return apiPost("/safety-eval/org-qualification/modify", {
|
return apiPost("/safetyEval/org-qualification/modify", {
|
||||||
...data,
|
...data,
|
||||||
id,
|
id,
|
||||||
enableFlag: 2,
|
enableFlag: 2,
|
||||||
|
|
@ -44,9 +44,9 @@ export const orgQualificationCertDisable = declareRequest("orgQualificationCertL
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const orgQualificationCertEnable = declareRequest("orgQualificationCertLoading", safeAction(async ({ id }) => {
|
export const orgQualificationCertEnable = declareRequest("orgQualificationCertLoading", safeAction(async ({ id }) => {
|
||||||
const res = await apiGet("/safety-eval/org-qualification/get", { id });
|
const res = await apiGet("/safetyEval/org-qualification/get", { id });
|
||||||
const data = res?.data || {};
|
const data = res?.data || {};
|
||||||
return apiPost("/safety-eval/org-qualification/modify", {
|
return apiPost("/safetyEval/org-qualification/modify", {
|
||||||
...data,
|
...data,
|
||||||
id,
|
id,
|
||||||
enableFlag: 1,
|
enableFlag: 1,
|
||||||
|
|
|
||||||
|
|
@ -234,12 +234,12 @@ export function toFilingPageQuery(params = {}, extra = {}) {
|
||||||
// ═══════════════════════════════════════════════════
|
// ═══════════════════════════════════════════════════
|
||||||
|
|
||||||
export async function fetchQualFilingDetail(id) {
|
export async function fetchQualFilingDetail(id) {
|
||||||
const res = await apiGet("/safety-eval/qual-filing/detail", { id: asId(id) });
|
const res = await apiGet("/safetyEval/qual-filing/detail", { id: asId(id) });
|
||||||
return fromSingleResponse(res, toFilingDetail);
|
return fromSingleResponse(res, toFilingDetail);
|
||||||
}
|
}
|
||||||
|
|
||||||
export async function fetchQualFilingChangeHistory(originFilingId) {
|
export async function fetchQualFilingChangeHistory(originFilingId) {
|
||||||
const res = await apiGet("/safety-eval/qual-filing-change/history", {
|
const res = await apiGet("/safetyEval/qual-filing-change/history", {
|
||||||
originFilingId: asId(originFilingId),
|
originFilingId: asId(originFilingId),
|
||||||
});
|
});
|
||||||
return fromSingleResponse(res, toChangeHistory);
|
return fromSingleResponse(res, toChangeHistory);
|
||||||
|
|
@ -247,76 +247,76 @@ export async function fetchQualFilingChangeHistory(originFilingId) {
|
||||||
|
|
||||||
export const qualFilingPage = declareRequest("qualFilingLoading", safePageResult(async (params) => {
|
export const qualFilingPage = declareRequest("qualFilingLoading", safePageResult(async (params) => {
|
||||||
const query = toFilingPageQuery(params, { applyTypeCode: APPLY_TYPE_APPLICATION });
|
const query = toFilingPageQuery(params, { applyTypeCode: APPLY_TYPE_APPLICATION });
|
||||||
const res = await apiGet("/safety-eval/qual-filing/page", query);
|
const res = await apiGet("/safetyEval/qual-filing/page", query);
|
||||||
return fromPageResponse(res, toFilingListRow);
|
return fromPageResponse(res, toFilingListRow);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const qualFilingFiledPage = declareRequest("qualFilingLoading", safePageResult(async (params) => {
|
export const qualFilingFiledPage = declareRequest("qualFilingLoading", safePageResult(async (params) => {
|
||||||
const query = toFilingPageQuery(params);
|
const query = toFilingPageQuery(params);
|
||||||
const res = await apiGet("/safety-eval/qual-filing/filed/page", query);
|
const res = await apiGet("/safetyEval/qual-filing/filed/page", query);
|
||||||
return fromPageResponse(res, toFilingListRow);
|
return fromPageResponse(res, toFilingListRow);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const qualFilingChangePage = declareRequest("qualFilingLoading", safePageResult(async (params) => {
|
export const qualFilingChangePage = declareRequest("qualFilingLoading", safePageResult(async (params) => {
|
||||||
const query = toFilingPageQuery(params);
|
const query = toFilingPageQuery(params);
|
||||||
const res = await apiGet("/safety-eval/qual-filing/change/page", query);
|
const res = await apiGet("/safetyEval/qual-filing/change/page", query);
|
||||||
return fromPageResponse(res, toFilingListRow);
|
return fromPageResponse(res, toFilingListRow);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const qualFilingDraft = declareRequest("qualFilingLoading", safeAction(async () => {
|
export const qualFilingDraft = declareRequest("qualFilingLoading", safeAction(async () => {
|
||||||
const res = await apiPost("/safety-eval/qual-filing/draft?applyTypeCode=1", {});
|
const res = await apiPost("/safetyEval/qual-filing/draft?applyTypeCode=1", {});
|
||||||
return fromSingleResponse(res, toFilingListRow);
|
return fromSingleResponse(res, toFilingListRow);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const qualFilingFiledDraft = declareRequest("qualFilingLoading", safeAction(async () => {
|
export const qualFilingFiledDraft = declareRequest("qualFilingLoading", safeAction(async () => {
|
||||||
const res = await apiPost("/safety-eval/qual-filing/filed/draft", {});
|
const res = await apiPost("/safetyEval/qual-filing/filed/draft", {});
|
||||||
return fromSingleResponse(res, toFilingListRow);
|
return fromSingleResponse(res, toFilingListRow);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const qualFilingSaveDraft = declareRequest("qualFilingLoading", safeAction(async (values) => {
|
export const qualFilingSaveDraft = declareRequest("qualFilingLoading", safeAction(async (values) => {
|
||||||
const res = await apiPost("/safety-eval/qual-filing/save-draft", fromFilingBasicForm(values));
|
const res = await apiPost("/safetyEval/qual-filing/save-draft", fromFilingBasicForm(values));
|
||||||
return fromSingleResponse(res, toFilingListRow);
|
return fromSingleResponse(res, toFilingListRow);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const qualFilingSubmit = declareRequest("qualFilingLoading", safeAction(async ({ id }) => {
|
export const qualFilingSubmit = declareRequest("qualFilingLoading", safeAction(async ({ id }) => {
|
||||||
const res = await apiPost(`/safety-eval/qual-filing/submit?id=${encodeURIComponent(asId(id))}`, {});
|
const res = await apiPost(`/safetyEval/qual-filing/submit?id=${encodeURIComponent(asId(id))}`, {});
|
||||||
return fromSingleResponse(res, toFilingListRow);
|
return fromSingleResponse(res, toFilingListRow);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const qualFilingDelete = declareRequest("qualFilingLoading", safeAction(async ({ id }) => {
|
export const qualFilingDelete = declareRequest("qualFilingLoading", safeAction(async ({ id }) => {
|
||||||
return apiPostDelete("/safety-eval/qual-filing/delete", id);
|
return apiPostDelete("/safetyEval/qual-filing/delete", id);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const qualFilingMaterialInitTemplate = declareRequest("qualFilingLoading", safeAction(async ({ filingId }) => {
|
export const qualFilingMaterialInitTemplate = declareRequest("qualFilingLoading", safeAction(async ({ filingId }) => {
|
||||||
return apiPost(`/safety-eval/qual-filing-material/init-template?filingId=${encodeURIComponent(asId(filingId))}`, {});
|
return apiPost(`/safetyEval/qual-filing-material/init-template?filingId=${encodeURIComponent(asId(filingId))}`, {});
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const qualFilingMaterialUpload = declareRequest("qualFilingLoading", safeAction(async ({ id, attachmentUrl, files }) => {
|
export const qualFilingMaterialUpload = declareRequest("qualFilingLoading", safeAction(async ({ id, attachmentUrl, files }) => {
|
||||||
const url = attachmentUrl || resolveUploadFileId(files);
|
const url = attachmentUrl || resolveUploadFileId(files);
|
||||||
const res = await apiPost("/safety-eval/qual-filing-material/upload", { id: asId(id), attachmentUrl: url });
|
const res = await apiPost("/safetyEval/qual-filing-material/upload", { id: asId(id), attachmentUrl: url });
|
||||||
return fromSingleResponse(res);
|
return fromSingleResponse(res);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const qualFilingUploadAttachment = declareRequest("qualFilingLoading", safeAction(async ({ id, attachmentUrl, files }) => {
|
export const qualFilingUploadAttachment = declareRequest("qualFilingLoading", safeAction(async ({ id, attachmentUrl, files }) => {
|
||||||
const url = attachmentUrl || resolveUploadFileId(files);
|
const url = attachmentUrl || resolveUploadFileId(files);
|
||||||
const res = await apiPost("/safety-eval/qual-filing/upload-attachment", { id: asId(id), attachmentUrl: url });
|
const res = await apiPost("/safetyEval/qual-filing/upload-attachment", { id: asId(id), attachmentUrl: url });
|
||||||
return fromSingleResponse(res, toFilingListRow);
|
return fromSingleResponse(res, toFilingListRow);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const qualFilingCommitmentSaveOrUpdate = declareRequest("qualFilingLoading", safeAction(async (values) => {
|
export const qualFilingCommitmentSaveOrUpdate = declareRequest("qualFilingLoading", safeAction(async (values) => {
|
||||||
const payload = fromFilingCommitmentForm(values, values.filingId);
|
const payload = fromFilingCommitmentForm(values, values.filingId);
|
||||||
const res = await apiPost("/safety-eval/qual-filing-commitment/save-or-update", payload);
|
const res = await apiPost("/safetyEval/qual-filing-commitment/save-or-update", payload);
|
||||||
return fromSingleResponse(res);
|
return fromSingleResponse(res);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const qualFilingCommitmentUploadSignature = declareRequest("qualFilingLoading", safeAction(async ({ id, attachmentUrl, files }) => {
|
export const qualFilingCommitmentUploadSignature = declareRequest("qualFilingLoading", safeAction(async ({ id, attachmentUrl, files }) => {
|
||||||
const url = attachmentUrl || resolveUploadFileId(files);
|
const url = attachmentUrl || resolveUploadFileId(files);
|
||||||
const res = await apiPost("/safety-eval/qual-filing-commitment/upload-signature", { id: asId(id), attachmentUrl: url });
|
const res = await apiPost("/safetyEval/qual-filing-commitment/upload-signature", { id: asId(id), attachmentUrl: url });
|
||||||
return fromSingleResponse(res);
|
return fromSingleResponse(res);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const qualFilingPersonnelBatchAdd = declareRequest("qualFilingLoading", safeAction(async ({ filingId, sourcePersonnelIds }) => {
|
export const qualFilingPersonnelBatchAdd = declareRequest("qualFilingLoading", safeAction(async ({ filingId, sourcePersonnelIds }) => {
|
||||||
const res = await apiPost("/safety-eval/qual-filing-personnel/batch-add-from-org", {
|
const res = await apiPost("/safetyEval/qual-filing-personnel/batch-add-from-org", {
|
||||||
filingId: asId(filingId),
|
filingId: asId(filingId),
|
||||||
sourcePersonnelIds: (sourcePersonnelIds || []).map(asId),
|
sourcePersonnelIds: (sourcePersonnelIds || []).map(asId),
|
||||||
});
|
});
|
||||||
|
|
@ -324,11 +324,11 @@ export const qualFilingPersonnelBatchAdd = declareRequest("qualFilingLoading", s
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const qualFilingPersonnelDelete = declareRequest("qualFilingLoading", safeAction(async ({ id }) => {
|
export const qualFilingPersonnelDelete = declareRequest("qualFilingLoading", safeAction(async ({ id }) => {
|
||||||
return apiPostDelete("/safety-eval/qual-filing-personnel/delete", id);
|
return apiPostDelete("/safetyEval/qual-filing-personnel/delete", id);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const qualFilingEquipmentBatchAdd = declareRequest("qualFilingLoading", safeAction(async ({ filingId, sourceEquipmentIds }) => {
|
export const qualFilingEquipmentBatchAdd = declareRequest("qualFilingLoading", safeAction(async ({ filingId, sourceEquipmentIds }) => {
|
||||||
const res = await apiPost("/safety-eval/qual-filing-equipment/batch-add-from-org", {
|
const res = await apiPost("/safetyEval/qual-filing-equipment/batch-add-from-org", {
|
||||||
filingId: asId(filingId),
|
filingId: asId(filingId),
|
||||||
sourceEquipmentIds: (sourceEquipmentIds || []).map(asId),
|
sourceEquipmentIds: (sourceEquipmentIds || []).map(asId),
|
||||||
});
|
});
|
||||||
|
|
@ -337,27 +337,27 @@ export const qualFilingEquipmentBatchAdd = declareRequest("qualFilingLoading", s
|
||||||
|
|
||||||
export const qualFilingEquipmentUploadCalibration = declareRequest("qualFilingLoading", safeAction(async ({ id, attachmentUrl, files }) => {
|
export const qualFilingEquipmentUploadCalibration = declareRequest("qualFilingLoading", safeAction(async ({ id, attachmentUrl, files }) => {
|
||||||
const url = attachmentUrl || resolveUploadFileId(files);
|
const url = attachmentUrl || resolveUploadFileId(files);
|
||||||
const res = await apiPost("/safety-eval/qual-filing-equipment/upload-calibration", { id: asId(id), attachmentUrl: url });
|
const res = await apiPost("/safetyEval/qual-filing-equipment/upload-calibration", { id: asId(id), attachmentUrl: url });
|
||||||
return fromSingleResponse(res);
|
return fromSingleResponse(res);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const qualFilingEquipmentDelete = declareRequest("qualFilingLoading", safeAction(async ({ id }) => {
|
export const qualFilingEquipmentDelete = declareRequest("qualFilingLoading", safeAction(async ({ id }) => {
|
||||||
return apiPostDelete("/safety-eval/qual-filing-equipment/delete", id);
|
return apiPostDelete("/safetyEval/qual-filing-equipment/delete", id);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const qualFilingChangeStart = declareRequest("qualFilingLoading", safeAction(async ({ originFilingId }) => {
|
export const qualFilingChangeStart = declareRequest("qualFilingLoading", safeAction(async ({ originFilingId }) => {
|
||||||
const res = await apiPost(
|
const res = await apiPost(
|
||||||
`/safety-eval/qual-filing-change/start?originFilingId=${encodeURIComponent(asId(originFilingId))}`,
|
`/safetyEval/qual-filing-change/start?originFilingId=${encodeURIComponent(asId(originFilingId))}`,
|
||||||
{},
|
{},
|
||||||
);
|
);
|
||||||
return fromSingleResponse(res, (data) => ({ draftFilingId: asId(data) }));
|
return fromSingleResponse(res, (data) => ({ draftFilingId: asId(data) }));
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const qualFilingChangeSubmit = declareRequest("qualFilingLoading", safeAction(async ({ draftFilingId }) => {
|
export const qualFilingChangeSubmit = declareRequest("qualFilingLoading", safeAction(async ({ draftFilingId }) => {
|
||||||
return apiPost("/safety-eval/qual-filing-change/submit", { draftFilingId: asId(draftFilingId) });
|
return apiPost("/safetyEval/qual-filing-change/submit", { draftFilingId: asId(draftFilingId) });
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const submitQualFiling = declareRequest(
|
export const submitQualFiling = declareRequest(
|
||||||
"qualFilingSubmitLoading",
|
"qualFilingSubmitLoading",
|
||||||
"Post > @/safety-eval/qual-filing/aggregationSaveOrEdit",
|
"Post > @/safetyEval/qual-filing/aggregationSaveOrEdit",
|
||||||
);
|
);
|
||||||
|
|
|
||||||
|
|
@ -3,6 +3,6 @@ import { apiGet } from "../enterpriseInfo/http";
|
||||||
import { asId } from "../enterpriseInfo/idUtil";
|
import { asId } from "../enterpriseInfo/idUtil";
|
||||||
|
|
||||||
export async function fetchOrgPersonnelDetail(params) {
|
export async function fetchOrgPersonnelDetail(params) {
|
||||||
const res = await apiGet("/safety-eval/org-personnel/get", { id: asId(params?.id) });
|
const res = await apiGet("/safetyEval/org-personnel/get", { id: asId(params?.id) });
|
||||||
return fromSingleResponse(res, toStaffForm);
|
return fromSingleResponse(res, toStaffForm);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ import { declareRequest } from "@cqsjjb/jjb-dva-runtime";
|
||||||
|
|
||||||
export const queryReviewList = declareRequest(
|
export const queryReviewList = declareRequest(
|
||||||
"qualReviewLoading",
|
"qualReviewLoading",
|
||||||
"Get > /safety-eval/qual-filing/page",
|
"Get > /safetyEval/qual-filing/page",
|
||||||
'qualReviewList: [] | res.data || [] & qualReviewTotal: 0 | res.total || 0'
|
'qualReviewList: [] | res.data || [] & qualReviewTotal: 0 | res.total || 0'
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -19,12 +19,12 @@ const NO_ORG_CONTEXT = { includeOrgContext: false };
|
||||||
|
|
||||||
export const orgAccountList = declareRequest("orgInfoLoading", safePageResult(async (params) => {
|
export const orgAccountList = declareRequest("orgInfoLoading", safePageResult(async (params) => {
|
||||||
const query = toRegulatorOrgAccountPageQuery(params);
|
const query = toRegulatorOrgAccountPageQuery(params);
|
||||||
const res = await apiGet("/safety-eval/org-info/page", query, {}, NO_ORG_CONTEXT);
|
const res = await apiGet("/safetyEval/org-info/page", query, {}, NO_ORG_CONTEXT);
|
||||||
return fromPageResponse(res, toOrgAccountRow);
|
return fromPageResponse(res, toOrgAccountRow);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const orgAccountGet = declareRequest("orgInfoLoading", safeAction(async ({ id }) => {
|
export const orgAccountGet = declareRequest("orgInfoLoading", safeAction(async ({ id }) => {
|
||||||
const res = await apiGet("/safety-eval/org-info/get", { id }, {}, NO_ORG_CONTEXT);
|
const res = await apiGet("/safetyEval/org-info/get", { id }, {}, NO_ORG_CONTEXT);
|
||||||
const result = fromSingleResponse(res, toOrgInfoForm);
|
const result = fromSingleResponse(res, toOrgInfoForm);
|
||||||
return {
|
return {
|
||||||
...result,
|
...result,
|
||||||
|
|
@ -35,42 +35,42 @@ export const orgAccountGet = declareRequest("orgInfoLoading", safeAction(async (
|
||||||
export const orgAccountModify = declareRequest("orgInfoLoading", safeAction(async (values) => {
|
export const orgAccountModify = declareRequest("orgInfoLoading", safeAction(async (values) => {
|
||||||
const { raw, ...formValues } = values;
|
const { raw, ...formValues } = values;
|
||||||
const payload = fromRegulatorOrgInfoModify(formValues, raw || {});
|
const payload = fromRegulatorOrgInfoModify(formValues, raw || {});
|
||||||
const res = await apiPost("/safety-eval/org-info/modify", payload, {}, NO_ORG_CONTEXT);
|
const res = await apiPost("/safetyEval/org-info/modify", payload, {}, NO_ORG_CONTEXT);
|
||||||
return fromSingleResponse(res, toOrgInfoForm);
|
return fromSingleResponse(res, toOrgInfoForm);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const orgAccountDelete = declareRequest("orgInfoLoading", safeAction(async ({ id }) => {
|
export const orgAccountDelete = declareRequest("orgInfoLoading", safeAction(async ({ id }) => {
|
||||||
return apiPostDelete("/safety-eval/org-info/delete", id, NO_ORG_CONTEXT);
|
return apiPostDelete("/safetyEval/org-info/delete", id, NO_ORG_CONTEXT);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const orgAccountUpdateState = declareRequest("orgInfoLoading", safeAction(async ({ id, state }) => {
|
export const orgAccountUpdateState = declareRequest("orgInfoLoading", safeAction(async ({ id, state }) => {
|
||||||
return apiPost("/safety-eval/org-info/update-state", { id, state }, {}, NO_ORG_CONTEXT);
|
return apiPost("/safetyEval/org-info/update-state", { id, state }, {}, NO_ORG_CONTEXT);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const orgAccountResetPassword = declareRequest("orgInfoLoading", safeAction(async ({ id }) => {
|
export const orgAccountResetPassword = declareRequest("orgInfoLoading", safeAction(async ({ id }) => {
|
||||||
const url = `/safety-eval/org-info/reset-password?id=${encodeURIComponent(id)}`;
|
const url = `/safetyEval/org-info/reset-password?id=${encodeURIComponent(id)}`;
|
||||||
return apiPost(url, {}, {}, NO_ORG_CONTEXT);
|
return apiPost(url, {}, {}, NO_ORG_CONTEXT);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const registeredOrgList = declareRequest("orgInfoLoading", safePageResult(async (params) => {
|
export const registeredOrgList = declareRequest("orgInfoLoading", safePageResult(async (params) => {
|
||||||
const query = toRegisteredOrgPageQuery(params);
|
const query = toRegisteredOrgPageQuery(params);
|
||||||
const res = await apiGet("/safety-eval/org-info/page", query, {}, NO_ORG_CONTEXT);
|
const res = await apiGet("/safetyEval/org-info/page", query, {}, NO_ORG_CONTEXT);
|
||||||
return fromPageResponse(res, toRegisteredOrgRow);
|
return fromPageResponse(res, toRegisteredOrgRow);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const registeredOrgGet = declareRequest("orgInfoLoading", safeAction(async ({ id }) => {
|
export const registeredOrgGet = declareRequest("orgInfoLoading", safeAction(async ({ id }) => {
|
||||||
const res = await apiGet("/safety-eval/org-info/get", { id }, {}, NO_ORG_CONTEXT);
|
const res = await apiGet("/safetyEval/org-info/get", { id }, {}, NO_ORG_CONTEXT);
|
||||||
return fromSingleResponse(res, toOrgInfoForm);
|
return fromSingleResponse(res, toOrgInfoForm);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
/** 详情页直调 HTTP,避免 DVA loading 与 useEffect 依赖 dispatch 函数导致反复取消 */
|
/** 详情页直调 HTTP,避免 DVA loading 与 useEffect 依赖 dispatch 函数导致反复取消 */
|
||||||
export async function fetchRegisteredOrgDetail(id) {
|
export async function fetchRegisteredOrgDetail(id) {
|
||||||
const res = await apiGet("/safety-eval/org-info/get", { id }, {}, NO_ORG_CONTEXT);
|
const res = await apiGet("/safetyEval/org-info/get", { id }, {}, NO_ORG_CONTEXT);
|
||||||
return fromSingleResponse(res, toOrgInfoForm);
|
return fromSingleResponse(res, toOrgInfoForm);
|
||||||
}
|
}
|
||||||
|
|
||||||
export async function fetchRegisteredOrgQualificationGroups(orgInfoId) {
|
export async function fetchRegisteredOrgQualificationGroups(orgInfoId) {
|
||||||
const res = await apiGet("/safety-eval/org-qualification/classGet", { id: orgInfoId }, {}, NO_ORG_CONTEXT);
|
const res = await apiGet("/safetyEval/org-qualification/classGet", { id: orgInfoId }, {}, NO_ORG_CONTEXT);
|
||||||
if (res?.success === false) {
|
if (res?.success === false) {
|
||||||
throw new Error(res?.message || "加载申请材料失败");
|
throw new Error(res?.message || "加载申请材料失败");
|
||||||
}
|
}
|
||||||
|
|
@ -78,7 +78,7 @@ export async function fetchRegisteredOrgQualificationGroups(orgInfoId) {
|
||||||
}
|
}
|
||||||
|
|
||||||
export async function fetchRegisteredOrgPersonnelList(orgInfoId) {
|
export async function fetchRegisteredOrgPersonnelList(orgInfoId) {
|
||||||
const res = await apiGet("/safety-eval/org-personnel/page", {
|
const res = await apiGet("/safetyEval/org-personnel/page", {
|
||||||
orgId: orgInfoId,
|
orgId: orgInfoId,
|
||||||
current: 1,
|
current: 1,
|
||||||
size: 999,
|
size: 999,
|
||||||
|
|
@ -88,12 +88,12 @@ export async function fetchRegisteredOrgPersonnelList(orgInfoId) {
|
||||||
}
|
}
|
||||||
|
|
||||||
export async function fetchRegisteredOrgPersonnelDetail({ id }) {
|
export async function fetchRegisteredOrgPersonnelDetail({ id }) {
|
||||||
const res = await apiGet("/safety-eval/org-personnel/get", { id }, {}, NO_ORG_CONTEXT);
|
const res = await apiGet("/safetyEval/org-personnel/get", { id }, {}, NO_ORG_CONTEXT);
|
||||||
return fromSingleResponse(res, toStaffForm);
|
return fromSingleResponse(res, toStaffForm);
|
||||||
}
|
}
|
||||||
|
|
||||||
export async function fetchRegisteredOrgPersonnelCertList(personnelId) {
|
export async function fetchRegisteredOrgPersonnelCertList(personnelId) {
|
||||||
const res = await apiGet("/safety-eval/org-personnel-cert/page", {
|
const res = await apiGet("/safetyEval/org-personnel-cert/page", {
|
||||||
personnelId,
|
personnelId,
|
||||||
current: 1,
|
current: 1,
|
||||||
size: 999,
|
size: 999,
|
||||||
|
|
@ -103,6 +103,6 @@ export async function fetchRegisteredOrgPersonnelCertList(personnelId) {
|
||||||
}
|
}
|
||||||
|
|
||||||
export async function fetchRegisteredOrgPersonnelCertDetail({ id }) {
|
export async function fetchRegisteredOrgPersonnelCertDetail({ id }) {
|
||||||
const res = await apiGet("/safety-eval/org-personnel-cert/get", { id }, {}, NO_ORG_CONTEXT);
|
const res = await apiGet("/safetyEval/org-personnel-cert/get", { id }, {}, NO_ORG_CONTEXT);
|
||||||
return fromSingleResponse(res, toStaffCertForm);
|
return fromSingleResponse(res, toStaffCertForm);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -13,27 +13,27 @@ export const staffCertificateList = declareRequest("staffCertificateLoading", sa
|
||||||
eqStaffId: "personnelId",
|
eqStaffId: "personnelId",
|
||||||
likeCertNo: "certNo",
|
likeCertNo: "certNo",
|
||||||
});
|
});
|
||||||
const res = await apiGet("/safety-eval/org-personnel-cert/page", query);
|
const res = await apiGet("/safetyEval/org-personnel-cert/page", query);
|
||||||
return fromPageResponse(res, toStaffCertForm);
|
return fromPageResponse(res, toStaffCertForm);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const staffCertificateInfo = declareRequest("staffCertificateLoading", safeAction(async (params) => {
|
export const staffCertificateInfo = declareRequest("staffCertificateLoading", safeAction(async (params) => {
|
||||||
const res = await apiGet("/safety-eval/org-personnel-cert/get", { id: params.id });
|
const res = await apiGet("/safetyEval/org-personnel-cert/get", { id: params.id });
|
||||||
return fromSingleResponse(res, toStaffCertForm);
|
return fromSingleResponse(res, toStaffCertForm);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const staffCertificateAdd = declareRequest("staffCertificateLoading", safeAction(async (values) => {
|
export const staffCertificateAdd = declareRequest("staffCertificateLoading", safeAction(async (values) => {
|
||||||
const res = await apiPost("/safety-eval/org-personnel-cert/save", fromStaffCertForm(values));
|
const res = await apiPost("/safetyEval/org-personnel-cert/save", fromStaffCertForm(values));
|
||||||
return fromSingleResponse(res, toStaffCertForm);
|
return fromSingleResponse(res, toStaffCertForm);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const staffCertificateEdit = declareRequest("staffCertificateLoading", safeAction(async (values) => {
|
export const staffCertificateEdit = declareRequest("staffCertificateLoading", safeAction(async (values) => {
|
||||||
const res = await apiPost("/safety-eval/org-personnel-cert/modify", fromStaffCertForm(values));
|
const res = await apiPost("/safetyEval/org-personnel-cert/modify", fromStaffCertForm(values));
|
||||||
return fromSingleResponse(res, toStaffCertForm);
|
return fromSingleResponse(res, toStaffCertForm);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const staffCertificateRemove = declareRequest("staffCertificateLoading", safeAction(async ({ id }) => {
|
export const staffCertificateRemove = declareRequest("staffCertificateLoading", safeAction(async ({ id }) => {
|
||||||
return apiPostDelete("/safety-eval/org-personnel-cert/delete", id);
|
return apiPostDelete("/safetyEval/org-personnel-cert/delete", id);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export async function fetchStaffCertListByPersonnelId(personnelId) {
|
export async function fetchStaffCertListByPersonnelId(personnelId) {
|
||||||
|
|
@ -44,12 +44,12 @@ export async function fetchStaffCertListByPersonnelId(personnelId) {
|
||||||
}, {
|
}, {
|
||||||
eqStaffId: "personnelId",
|
eqStaffId: "personnelId",
|
||||||
});
|
});
|
||||||
const res = await apiGet("/safety-eval/org-personnel-cert/page", query);
|
const res = await apiGet("/safetyEval/org-personnel-cert/page", query);
|
||||||
const page = fromPageResponse(res, toStaffCertForm);
|
const page = fromPageResponse(res, toStaffCertForm);
|
||||||
return page?.data || [];
|
return page?.data || [];
|
||||||
}
|
}
|
||||||
|
|
||||||
export async function fetchStaffCertDetail({ id }) {
|
export async function fetchStaffCertDetail({ id }) {
|
||||||
const res = await apiGet("/safety-eval/org-personnel-cert/get", { id });
|
const res = await apiGet("/safetyEval/org-personnel-cert/get", { id });
|
||||||
return fromSingleResponse(res, toStaffCertForm);
|
return fromSingleResponse(res, toStaffCertForm);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -17,26 +17,26 @@ export const staffChangeLogStaffList = declareRequest("staffChangeLogLoading", s
|
||||||
employmentStatus: "employmentStatusCode",
|
employmentStatus: "employmentStatusCode",
|
||||||
resignAuditStatus: "resignAuditStatus",
|
resignAuditStatus: "resignAuditStatus",
|
||||||
});
|
});
|
||||||
const res = await apiGet("/safety-eval/org-personnel/page", query);
|
const res = await apiGet("/safetyEval/org-personnel/page", query);
|
||||||
return fromPageResponse(res, toStaffChangeSummary);
|
return fromPageResponse(res, toStaffChangeSummary);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const staffChangeLogList = declareRequest("staffChangeLogLoading", safePageResult(async (params) => {
|
export const staffChangeLogList = declareRequest("staffChangeLogLoading", safePageResult(async (params) => {
|
||||||
const query = toPageQuery(params, { eqStaffId: "personnelId" });
|
const query = toPageQuery(params, { eqStaffId: "personnelId" });
|
||||||
const res = await apiGet("/safety-eval/org-personnel-change/page", query);
|
const res = await apiGet("/safetyEval/org-personnel-change/page", query);
|
||||||
return fromPageResponse(res, toChangeLogForm);
|
return fromPageResponse(res, toChangeLogForm);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const staffChangeLogRemove = declareRequest("staffChangeLogLoading", safeAction(async ({ id }) => {
|
export const staffChangeLogRemove = declareRequest("staffChangeLogLoading", safeAction(async ({ id }) => {
|
||||||
return apiPostDelete("/safety-eval/org-personnel-change/delete", id);
|
return apiPostDelete("/safetyEval/org-personnel-change/delete", id);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const staffResignationAudit = declareRequest("staffChangeLogLoading", safeAction(async (params) => {
|
export const staffResignationAudit = declareRequest("staffChangeLogLoading", safeAction(async (params) => {
|
||||||
const res = await apiPost("/safety-eval/org-resign-apply/modify", fromResignAuditForm(params));
|
const res = await apiPost("/safetyEval/org-resign-apply/modify", fromResignAuditForm(params));
|
||||||
return fromSingleResponse(res, toResignApplyForm);
|
return fromSingleResponse(res, toResignApplyForm);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const staffResignationInfo = declareRequest("staffChangeLogLoading", safeAction(async (params) => {
|
export const staffResignationInfo = declareRequest("staffChangeLogLoading", safeAction(async (params) => {
|
||||||
const res = await apiGet("/safety-eval/org-resign-apply/get", { id: params.id });
|
const res = await apiGet("/safetyEval/org-resign-apply/get", { id: params.id });
|
||||||
return fromSingleResponse(res, toResignApplyForm);
|
return fromSingleResponse(res, toResignApplyForm);
|
||||||
}));
|
}));
|
||||||
|
|
|
||||||
|
|
@ -14,30 +14,30 @@ export const staffInfoList = declareRequest("staffInfoLoading", safePageResult(a
|
||||||
eqDeptId: "deptId",
|
eqDeptId: "deptId",
|
||||||
eqPositionId: "postId",
|
eqPositionId: "postId",
|
||||||
});
|
});
|
||||||
const res = await apiGet("/safety-eval/org-personnel/page", query);
|
const res = await apiGet("/safetyEval/org-personnel/page", query);
|
||||||
return fromPageResponse(res, toStaffForm);
|
return fromPageResponse(res, toStaffForm);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const staffInfoGet = declareRequest("staffInfoLoading", safeAction(async (params) => {
|
export const staffInfoGet = declareRequest("staffInfoLoading", safeAction(async (params) => {
|
||||||
const res = await apiGet("/safety-eval/org-personnel/get", { id: params.id });
|
const res = await apiGet("/safetyEval/org-personnel/get", { id: params.id });
|
||||||
return fromSingleResponse(res, toStaffForm);
|
return fromSingleResponse(res, toStaffForm);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const staffInfoAdd = declareRequest("staffInfoLoading", safeAction(async (values) => {
|
export const staffInfoAdd = declareRequest("staffInfoLoading", safeAction(async (values) => {
|
||||||
const res = await apiPost("/safety-eval/org-personnel/save", fromStaffForm(values));
|
const res = await apiPost("/safetyEval/org-personnel/save", fromStaffForm(values));
|
||||||
return fromSingleResponse(res, toStaffForm);
|
return fromSingleResponse(res, toStaffForm);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const staffInfoEdit = declareRequest("staffInfoLoading", safeAction(async (values) => {
|
export const staffInfoEdit = declareRequest("staffInfoLoading", safeAction(async (values) => {
|
||||||
const res = await apiPost("/safety-eval/org-personnel/modify", fromStaffForm(values));
|
const res = await apiPost("/safetyEval/org-personnel/modify", fromStaffForm(values));
|
||||||
return fromSingleResponse(res, toStaffForm);
|
return fromSingleResponse(res, toStaffForm);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const staffInfoRemove = declareRequest("staffInfoLoading", safeAction(async ({ id }) => {
|
export const staffInfoRemove = declareRequest("staffInfoLoading", safeAction(async ({ id }) => {
|
||||||
return apiPostDelete("/safety-eval/org-personnel/delete", id);
|
return apiPostDelete("/safetyEval/org-personnel/delete", id);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
/** 后端暂未提供重置密码接口 */
|
/** 后端暂未提供重置密码接口 */
|
||||||
export const staffInfoResetPassword = declareRequest("staffInfoLoading", safeAction(async ({ id }) => {
|
export const staffInfoResetPassword = declareRequest("staffInfoLoading", safeAction(async ({ id }) => {
|
||||||
return apiPost(`/safety-eval/org-personnel/reset-password?id=${id}`);
|
return apiPost(`/safetyEval/org-personnel/reset-password?id=${id}`);
|
||||||
}));
|
}));
|
||||||
|
|
|
||||||
|
|
@ -13,16 +13,16 @@ export const staffResignationApplyList = declareRequest("staffResignationApplyLo
|
||||||
likeStaffName: "applicantName",
|
likeStaffName: "applicantName",
|
||||||
auditStatus: "auditStatusCode",
|
auditStatus: "auditStatusCode",
|
||||||
});
|
});
|
||||||
const res = await apiGet("/safety-eval/org-resign-apply/page", query);
|
const res = await apiGet("/safetyEval/org-resign-apply/page", query);
|
||||||
return fromPageResponse(res, toResignApplyForm);
|
return fromPageResponse(res, toResignApplyForm);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const staffResignationApplyInfo = declareRequest("staffResignationApplyLoading", safeAction(async (params) => {
|
export const staffResignationApplyInfo = declareRequest("staffResignationApplyLoading", safeAction(async (params) => {
|
||||||
const res = await apiGet("/safety-eval/org-resign-apply/get", { id: params.id });
|
const res = await apiGet("/safetyEval/org-resign-apply/get", { id: params.id });
|
||||||
return fromSingleResponse(res, toResignApplyForm);
|
return fromSingleResponse(res, toResignApplyForm);
|
||||||
}));
|
}));
|
||||||
|
|
||||||
export const staffResignationApplyAdd = declareRequest("staffResignationApplyLoading", safeAction(async (values) => {
|
export const staffResignationApplyAdd = declareRequest("staffResignationApplyLoading", safeAction(async (values) => {
|
||||||
const res = await apiPost("/safety-eval/org-resign-apply/save", fromResignApplyForm(values));
|
const res = await apiPost("/safetyEval/org-resign-apply/save", fromResignApplyForm(values));
|
||||||
return fromSingleResponse(res, toResignApplyForm);
|
return fromSingleResponse(res, toResignApplyForm);
|
||||||
}));
|
}));
|
||||||
|
|
|
||||||
|
|
@ -44,7 +44,7 @@ export default function AttachmentUpload({ name, label, disabled = false }) {
|
||||||
<Upload
|
<Upload
|
||||||
disabled={disabled}
|
disabled={disabled}
|
||||||
listType="picture-card"
|
listType="picture-card"
|
||||||
action={`${window.process.env.app.API_HOST}/safety-eval/file/upload`}
|
action={`${window.process.env.app.API_HOST}/safetyEval/file/upload`}
|
||||||
onPreview={(file) => {
|
onPreview={(file) => {
|
||||||
if (isImage(file.url || file.thumbUrl)) {
|
if (isImage(file.url || file.thumbUrl)) {
|
||||||
setPreviewImage(file.url || file.thumbUrl);
|
setPreviewImage(file.url || file.thumbUrl);
|
||||||
|
|
|
||||||
|
|
@ -25,32 +25,32 @@ import {
|
||||||
|
|
||||||
const menuItems = [
|
const menuItems = [
|
||||||
{
|
{
|
||||||
key: "/safety-eval/container/Supervision",
|
key: "/safetyEval/container/Supervision",
|
||||||
label: "监管端",
|
label: "监管端",
|
||||||
icon: <DashboardOutlined />,
|
icon: <DashboardOutlined />,
|
||||||
children: [
|
children: [
|
||||||
{
|
{
|
||||||
key: "/safety-eval/container/Supervision/BasicInfo",
|
key: "/safetyEval/container/Supervision/BasicInfo",
|
||||||
label: "基础信息管理",
|
label: "基础信息管理",
|
||||||
icon: <FileTextOutlined />,
|
icon: <FileTextOutlined />,
|
||||||
children: [
|
children: [
|
||||||
{
|
{
|
||||||
key: "/safety-eval/container/Supervision/BasicInfo/OrgAccount",
|
key: "/safetyEval/container/Supervision/BasicInfo/OrgAccount",
|
||||||
label: "机构账号管理",
|
label: "机构账号管理",
|
||||||
icon: <KeyOutlined />,
|
icon: <KeyOutlined />,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
key: "/safety-eval/container/Supervision/BasicInfo/RegisteredOrg/List",
|
key: "/safetyEval/container/Supervision/BasicInfo/RegisteredOrg/List",
|
||||||
label: "已备案机构管理",
|
label: "已备案机构管理",
|
||||||
icon: <FileProtectOutlined />,
|
icon: <FileProtectOutlined />,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
key: "/safety-eval/container/Supervision/BasicInfo/EvaluatorInfo",
|
key: "/safetyEval/container/Supervision/BasicInfo/EvaluatorInfo",
|
||||||
label: "评价师信息管理",
|
label: "评价师信息管理",
|
||||||
icon: <UserOutlined />,
|
icon: <UserOutlined />,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
key: "/safety-eval/container/Supervision/BasicInfo/EnterprisePortrait",
|
key: "/safetyEval/container/Supervision/BasicInfo/EnterprisePortrait",
|
||||||
label: "企业画像管理",
|
label: "企业画像管理",
|
||||||
icon: <BarChartOutlined />,
|
icon: <BarChartOutlined />,
|
||||||
},
|
},
|
||||||
|
|
@ -59,64 +59,64 @@ const menuItems = [
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
key: "/safety-eval/container/EnterpriseInfo",
|
key: "/safetyEval/container/EnterpriseInfo",
|
||||||
label: "企业信息管理",
|
label: "企业信息管理",
|
||||||
icon: <ShopOutlined />,
|
icon: <ShopOutlined />,
|
||||||
children: [
|
children: [
|
||||||
{
|
{
|
||||||
key: "/safety-eval/container/EnterpriseInfo/OrgInfo",
|
key: "/safetyEval/container/EnterpriseInfo/OrgInfo",
|
||||||
label: "机构信息管理",
|
label: "机构信息管理",
|
||||||
icon: <BankOutlined />,
|
icon: <BankOutlined />,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
key: "/safety-eval/container/EnterpriseInfo/QualificationCert",
|
key: "/safetyEval/container/EnterpriseInfo/QualificationCert",
|
||||||
label: "资质信息管理",
|
label: "资质信息管理",
|
||||||
icon: <SafetyCertificateOutlined />,
|
icon: <SafetyCertificateOutlined />,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
key: "/safety-eval/container/EnterpriseInfo/PersonnelChange",
|
key: "/safetyEval/container/EnterpriseInfo/PersonnelChange",
|
||||||
label: "人员变更管理",
|
label: "人员变更管理",
|
||||||
icon: <SwapOutlined />,
|
icon: <SwapOutlined />,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
key: "/safety-eval/container/EnterpriseInfo/PersonnelInfo/List",
|
key: "/safetyEval/container/EnterpriseInfo/PersonnelInfo/List",
|
||||||
label: "人员信息管理",
|
label: "人员信息管理",
|
||||||
icon: <TeamOutlined />,
|
icon: <TeamOutlined />,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
key: "/safety-eval/container/EnterpriseInfo/DepartmentPosition",
|
key: "/safetyEval/container/EnterpriseInfo/DepartmentPosition",
|
||||||
label: "部门岗位管理",
|
label: "部门岗位管理",
|
||||||
icon: <ApartmentOutlined />,
|
icon: <ApartmentOutlined />,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
key: "/safety-eval/container/EnterpriseInfo/ResignationApply",
|
key: "/safetyEval/container/EnterpriseInfo/ResignationApply",
|
||||||
label: "人员离职申请",
|
label: "人员离职申请",
|
||||||
icon: <LogoutOutlined />,
|
icon: <LogoutOutlined />,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
key: "/safety-eval/container/EnterpriseInfo/EquipInfo",
|
key: "/safetyEval/container/EnterpriseInfo/EquipInfo",
|
||||||
label: "装备信息管理",
|
label: "装备信息管理",
|
||||||
icon: <ToolOutlined />,
|
icon: <ToolOutlined />,
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
key: "/safety-eval/container/qualApplication",
|
key: "/safetyEval/container/qualApplication",
|
||||||
label: "资质申请管理",
|
label: "资质申请管理",
|
||||||
icon: <FormOutlined />,
|
icon: <FormOutlined />,
|
||||||
children: [
|
children: [
|
||||||
{
|
{
|
||||||
key: "/safety-eval/container/qualApplication/filingApplication/list",
|
key: "/safetyEval/container/qualApplication/filingApplication/list",
|
||||||
label: "资质备案申请",
|
label: "资质备案申请",
|
||||||
icon: <FormOutlined />,
|
icon: <FormOutlined />,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
key: "/safety-eval/container/qualApplication/filedManage/list",
|
key: "/safetyEval/container/qualApplication/filedManage/list",
|
||||||
label: "已备案资质管理",
|
label: "已备案资质管理",
|
||||||
icon: <CheckCircleOutlined />,
|
icon: <CheckCircleOutlined />,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
key: "/safety-eval/container/qualApplication/filingChange/list",
|
key: "/safetyEval/container/qualApplication/filingChange/list",
|
||||||
label: "备案变更管理",
|
label: "备案变更管理",
|
||||||
icon: <SyncOutlined />,
|
icon: <SyncOutlined />,
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -15,10 +15,10 @@ export default function FilingUpload({
|
||||||
<Upload
|
<Upload
|
||||||
maxCount={maxCount}
|
maxCount={maxCount}
|
||||||
accept={accept}
|
accept={accept}
|
||||||
action={`${window.process.env.app.API_HOST}/safety-eval/file/upload`}
|
action={`${window.process.env.app.API_HOST}/safetyEval/file/upload`}
|
||||||
disabled={disabled}
|
disabled={disabled}
|
||||||
fileList={fileList}
|
fileList={fileList}
|
||||||
|
|
||||||
onChange={(info) => {
|
onChange={(info) => {
|
||||||
if (disabled) return;
|
if (disabled) return;
|
||||||
onChange?.(info.fileList);
|
onChange?.(info.fileList);
|
||||||
|
|
|
||||||
|
|
@ -61,7 +61,7 @@ export default function MaterialStep({
|
||||||
!disabled && (
|
!disabled && (
|
||||||
<Upload
|
<Upload
|
||||||
showUploadList={false}
|
showUploadList={false}
|
||||||
action={`${window.process.env.app.API_HOST}/safety-eval/file/upload`}
|
action={`${window.process.env.app.API_HOST}/safetyEval/file/upload`}
|
||||||
onChange={(info) => {
|
onChange={(info) => {
|
||||||
if (info.file.status === "done") {
|
if (info.file.status === "done") {
|
||||||
const data = info.file.response?.data;
|
const data = info.file.response?.data;
|
||||||
|
|
|
||||||
|
|
@ -1,9 +1,9 @@
|
||||||
export const FILING_FORM_PATH = "/safety-eval/container/qualApplication/filingForm";
|
export const FILING_FORM_PATH = "/safetyEval/container/qualApplication/filingForm";
|
||||||
|
|
||||||
export const FILING_LIST_PATH = {
|
export const FILING_LIST_PATH = {
|
||||||
application: "/safety-eval/container/qualApplication/filingApplication/list",
|
application: "/safetyEval/container/qualApplication/filingApplication/list",
|
||||||
filed: "/safety-eval/container/qualApplication/filedManage/list",
|
filed: "/safetyEval/container/qualApplication/filedManage/list",
|
||||||
change: "/safety-eval/container/qualApplication/filingChange/list",
|
change: "/safetyEval/container/qualApplication/filingChange/list",
|
||||||
};
|
};
|
||||||
|
|
||||||
export function goFilingForm({ mode, id, originFilingId, readOnly }) {
|
export function goFilingForm({ mode, id, originFilingId, readOnly }) {
|
||||||
|
|
|
||||||
|
|
@ -9,7 +9,7 @@ import { buildCommitmentContent } from "./filingCommitment";
|
||||||
|
|
||||||
export async function fetchOrgPersonnelOptions() {
|
export async function fetchOrgPersonnelOptions() {
|
||||||
const query = toPageQuery({ current: 1, size: 500 }, { likeStaffName: "userName" });
|
const query = toPageQuery({ current: 1, size: 500 }, { likeStaffName: "userName" });
|
||||||
const res = await apiGet("/safety-eval/org-personnel/page", query);
|
const res = await apiGet("/safetyEval/org-personnel/page", query);
|
||||||
const page = fromPageResponse(res, toStaffForm);
|
const page = fromPageResponse(res, toStaffForm);
|
||||||
return (page?.data || []).map((row) => ({
|
return (page?.data || []).map((row) => ({
|
||||||
label: row.staffName,
|
label: row.staffName,
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue