Merge branch 'dev' of http://47.92.113.182:3000/cq_anquan/safety-eval-service-frontend into dev
commit
c046210d80
|
|
@ -1,4 +1,7 @@
|
|||
import { declareRequest } from "@cqsjjb/jjb-dva-runtime";
|
||||
import { fromSingleResponse } from "../../utils/enterpriseInfo/adapter";
|
||||
import { apiGet, safeAction } from "../../utils/enterpriseInfo/http";
|
||||
import { asId } from "../../utils/enterpriseInfo/idUtil";
|
||||
|
||||
export const equipInfoList = declareRequest(
|
||||
"equipInfoLoading",
|
||||
|
|
@ -8,8 +11,10 @@ export const equipInfoList = declareRequest(
|
|||
|
||||
export const equipInfoGet = declareRequest(
|
||||
"equipInfoLoading",
|
||||
"Get > /safetyEval/org-equipment/get",
|
||||
"equipInfoDetail: {} | res.data || {}",
|
||||
safeAction(async (params) => {
|
||||
const res = await apiGet("/safetyEval/org-equipment/get", { id: asId(params?.id) });
|
||||
return fromSingleResponse(res);
|
||||
}),
|
||||
);
|
||||
|
||||
export const equipInfoAdd = declareRequest(
|
||||
|
|
@ -29,5 +34,5 @@ export const equipInfoRemove = declareRequest(
|
|||
|
||||
export const equipInfoToggleStatus = declareRequest(
|
||||
"equipInfoLoading",
|
||||
"Get > /safetyEval/org-equipment/modify",
|
||||
"Post > @/safetyEval/org-equipment/modify",
|
||||
);
|
||||
|
|
@ -6,8 +6,8 @@ import {
|
|||
fromSingleResponse,
|
||||
toDepartmentForm,
|
||||
toPageQuery,
|
||||
} from "../enterpriseInfo/adapter";
|
||||
import { apiGet, apiPost, apiPostDelete, safeAction, safePageResult } from "../enterpriseInfo/http";
|
||||
} from "../../utils/enterpriseInfo/adapter";
|
||||
import { apiGet, apiPost, apiPostDelete, safeAction, safePageResult } from "../../utils/enterpriseInfo/http";
|
||||
|
||||
export const orgDepartmentGet = declareRequest("orgDepartmentLoading", safeAction(async (params) => {
|
||||
const res = await apiGet("/safetyEval/org-department/get", { id: params.id });
|
||||
|
|
|
|||
|
|
@ -36,4 +36,4 @@ export {
|
|||
registeredOrgList,
|
||||
registeredOrgGet,
|
||||
fetchRegisteredOrgDetail,
|
||||
} from "../regulatorOrgInfo";
|
||||
} from "../../utils/regulatorOrgInfo";
|
||||
|
|
|
|||
|
|
@ -4,8 +4,8 @@ import {
|
|||
fromPositionForm,
|
||||
toPageQuery,
|
||||
toPositionForm,
|
||||
} from "../enterpriseInfo/adapter";
|
||||
import { apiGet, apiPost, apiPostDelete, safeAction, safePageResult } from "../enterpriseInfo/http";
|
||||
} from "../../utils/enterpriseInfo/adapter";
|
||||
import { apiGet, apiPost, apiPostDelete, safeAction, safePageResult } from "../../utils/enterpriseInfo/http";
|
||||
|
||||
export const orgPositionList = declareRequest("orgPositionLoading", safePageResult(async (params) => {
|
||||
const query = toPageQuery(params, {
|
||||
|
|
|
|||
|
|
@ -1,9 +1,9 @@
|
|||
/** 资质备案:接口定义与前后端字段适配 */
|
||||
|
||||
import { declareRequest } from "@cqsjjb/jjb-dva-runtime";
|
||||
import { fromPageResponse, fromSingleResponse, toPageQuery } from "../enterpriseInfo/adapter";
|
||||
import { apiGet, apiPost, apiPostDelete, safeAction, safePageResult } from "../enterpriseInfo/http";
|
||||
import { asId, normalizeQueryIds } from "../enterpriseInfo/idUtil";
|
||||
import { fromPageResponse, fromSingleResponse, toPageQuery } from "../../utils/enterpriseInfo/adapter";
|
||||
import { apiGet, apiPost, apiPostDelete, safeAction, safePageResult } from "../../utils/enterpriseInfo/http";
|
||||
import { asId, normalizeQueryIds } from "../../utils/enterpriseInfo/idUtil";
|
||||
import { formatDate, toApiDate, toDayjs } from "../../utils/dateFormat";
|
||||
import { parseUploadFileList, resolveUploadFileId } from "../../utils/mockUpload";
|
||||
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
import { declareRequest } from "@cqsjjb/jjb-dva-runtime";
|
||||
import { apiPostDelete, safeAction } from "../enterpriseInfo/http";
|
||||
import { apiPostDelete, safeAction } from "../../utils/enterpriseInfo/http";
|
||||
|
||||
export const staffChangeLogStaffList = declareRequest(
|
||||
"staffChangeLogLoading",
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
import { declareRequest } from "@cqsjjb/jjb-dva-runtime";
|
||||
import { apiPost, safeAction } from "../enterpriseInfo/http";
|
||||
import { asId } from "../enterpriseInfo/idUtil";
|
||||
import { apiPost, safeAction } from "../../utils/enterpriseInfo/http";
|
||||
import { asId } from "../../utils/enterpriseInfo/idUtil";
|
||||
|
||||
export const staffInfoList = declareRequest(
|
||||
"staffInfoLoading",
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ import Search from "zy-react-library/components/Search";
|
|||
import Table from "zy-react-library/components/Table";
|
||||
import useTable from "zy-react-library/hooks/useTable";
|
||||
import { NS_ORG_DEPARTMENT, NS_ORG_POSITION, NS_STAFF_INFO } from "~/enumerate/namespace";
|
||||
import { asId, sameId } from "~/api/enterpriseInfo/idUtil";
|
||||
import { asId, sameId } from "~/utils/enterpriseInfo/idUtil";
|
||||
import { safeListRequest, safeRequest } from "~/utils";
|
||||
|
||||
function findDeptNode(nodes = [], id) {
|
||||
|
|
|
|||
|
|
@ -77,6 +77,7 @@ function EquipInfoPage(props) {
|
|||
onOk: async () => {
|
||||
const nextFlag = enabled ? 2 : 1;
|
||||
const res = await props.equipInfoToggleStatus({
|
||||
...record,
|
||||
id,
|
||||
enableFlag: nextFlag,
|
||||
});
|
||||
|
|
@ -118,7 +119,7 @@ function EquipInfoPage(props) {
|
|||
allowClear
|
||||
/>
|
||||
</Form.Item>,
|
||||
<Form.Item key="instrumentTypeName" name="instrumentTypeName">
|
||||
<Form.Item key="instrumentType" name="instrumentType">
|
||||
<ControlWrapper.Select
|
||||
label="仪器类型"
|
||||
placeholder="请选择"
|
||||
|
|
@ -131,7 +132,7 @@ function EquipInfoPage(props) {
|
|||
<Select.Option value="物理仪器">物理仪器</Select.Option>
|
||||
</ControlWrapper.Select>
|
||||
</Form.Item>,
|
||||
<Form.Item key="deviceTypeName" name="deviceTypeName">
|
||||
<Form.Item key="deviceType" name="deviceType">
|
||||
<ControlWrapper.Select
|
||||
label="设备类型"
|
||||
placeholder="请选择"
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@ import { useEffect, useRef, useState } from "react";
|
|||
import FilePreviewModal, { FilePreviewContent } from "~/components/FilePreviewModal";
|
||||
import { resolvePreviewSrc } from "~/components/CertPreviewImg";
|
||||
import { fetchStaffCertDetail, fetchStaffCertListByPersonnelId } from "~/api/staffCertificate";
|
||||
import { fetchOrgPersonnelDetail } from "~/api/qualFiling/personnelHelper";
|
||||
import { fetchOrgPersonnelDetail } from "~/utils/qualFiling/personnelHelper";
|
||||
|
||||
const GENDER_MAP = { 1: "男", 2: "女" };
|
||||
const REGISTER_ENGINEER_MAP = { 1: "是", 2: "否" };
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
import { fetchQualFilingDetail } from "~/api/qualFiling";
|
||||
import { fromPageResponse, toPageQuery, toStaffForm, toEquipForm } from "~/api/enterpriseInfo/adapter";
|
||||
import { apiGet } from "~/api/enterpriseInfo/http";
|
||||
import { asId } from "~/api/enterpriseInfo/idUtil";
|
||||
import { fromPageResponse, toPageQuery, toStaffForm, toEquipForm } from "~/utils/enterpriseInfo/adapter";
|
||||
import { apiGet } from "~/utils/enterpriseInfo/http";
|
||||
import { asId } from "~/utils/enterpriseInfo/idUtil";
|
||||
import { resolveUploadFileId } from "~/utils/mockUpload";
|
||||
import { toApiDate } from "~/utils/dateFormat";
|
||||
import { FILING_FORM_MODE } from "~/enumerate/qualFilingOptions";
|
||||
|
|
|
|||
|
|
@ -69,7 +69,7 @@ const QualChange = (props) => {
|
|||
<Button type="link" size="small" onClick={() => props.history.push(`FilingDetail?id=${record.id}&mode=change`)}>
|
||||
查看
|
||||
</Button>
|
||||
{record.filingStatusCode == 2 && (
|
||||
{(record.filingStatusCode == 2 || record.filingStatusCode == 4) && (
|
||||
<Button type="link" size="small" onClick={() => props.history.push(`QualReviewForm?id=${record.id}&mode=change`)}>
|
||||
审核
|
||||
</Button>
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@ import { useEffect, useState } from "react";
|
|||
import PageLayout from "@cqsjjb/jjb-react-admin-component/PageLayout";
|
||||
import SearchForm from "@cqsjjb/jjb-react-admin-component/SearchForm";
|
||||
import ControlWrapper from "@cqsjjb/jjb-react-admin-component/ControlWrapper";
|
||||
import { isOrgAccountEnabled } from "~/api/enterpriseInfo/adapter";
|
||||
import { isOrgAccountEnabled } from "~/utils/enterpriseInfo/adapter";
|
||||
import {
|
||||
CHONGQING_DISTRICTS,
|
||||
ENTERPRISE_SCALE_OPTIONS,
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@ import {
|
|||
fetchRegisteredOrgPersonnelDetail,
|
||||
fetchRegisteredOrgPersonnelList,
|
||||
fetchRegisteredOrgQualificationGroups,
|
||||
} from "~/api/regulatorOrgInfo";
|
||||
} from "~/utils/regulatorOrgInfo";
|
||||
import { buildOrgInfoFormOptions } from "../../../../EnterpriseInfo/OrgInfo/formOptions";
|
||||
import StaffViewModal from "../../../../EnterpriseInfo/PersonnelInfo/StaffViewModal";
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue