监管端增加按钮权限
parent
2a46b1361e
commit
4394bbcb10
|
|
@ -31,7 +31,7 @@
|
|||
"lodash-es": "^4.17.21",
|
||||
"react": "^18.2.0",
|
||||
"react-dom": "^18.2.0",
|
||||
"zy-react-library": "^1.2.30"
|
||||
"zy-react-library": "^1.2.32"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@antfu/eslint-config": "^5.4.1",
|
||||
|
|
|
|||
|
|
@ -33,7 +33,7 @@ function List(props) {
|
|||
|
||||
const { tableProps, getData } = useTable(props["emergencyAddressBookList"], {
|
||||
form,
|
||||
params: { corpinfoId: query.corpinfoId },
|
||||
params: { corpId: query.corpinfoId },
|
||||
usePagination: false,
|
||||
});
|
||||
|
||||
|
|
@ -86,7 +86,7 @@ function List(props) {
|
|||
fixed: "right",
|
||||
render: (_, record) => (
|
||||
<Space>
|
||||
{props.permission("qyd-enterprise-emergency-address-book-member") && (
|
||||
{(props.isRecord || props.permission("qyd-enterprise-emergency-address-book-member")) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ function List(props) {
|
|||
|
||||
const { tableProps, getData } = useTable(props["expertEmergencyRescueExpertList"], {
|
||||
form,
|
||||
params: { corpinfoId: query.corpinfoId },
|
||||
params: { corpId: query.corpinfoId },
|
||||
});
|
||||
|
||||
const onDelete = (record) => {
|
||||
|
|
@ -110,7 +110,7 @@ function List(props) {
|
|||
fixed: "right",
|
||||
render: (_, record) => (
|
||||
<Space>
|
||||
{props.permission("qyd-expert-emergency-rescue-expert-view") && (
|
||||
{(props.isRecord || props.permission("qyd-expert-emergency-rescue-expert-view")) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ function List(props) {
|
|||
|
||||
const { tableProps, getData } = useTable(props["expertEmergencyRescueExpertGroupList"], {
|
||||
form,
|
||||
params: { corpinfoId: query.corpinfoId },
|
||||
params: { corpId: query.corpinfoId },
|
||||
});
|
||||
|
||||
const onDelete = (record) => {
|
||||
|
|
@ -109,7 +109,7 @@ function List(props) {
|
|||
fixed: "right",
|
||||
render: (_, record) => (
|
||||
<Space>
|
||||
{props.permission("qyd-expert-emergency-rescue-group-view") && (
|
||||
{(props.isRecord || props.permission("qyd-expert-emergency-rescue-group-view")) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
@ -119,7 +119,7 @@ function List(props) {
|
|||
查看
|
||||
</Button>
|
||||
)}
|
||||
{props.permission("qyd-expert-emergency-rescue-group-member-manage") && (
|
||||
{(props.isRecord || props.permission("qyd-expert-emergency-rescue-group-member-manage")) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ function List(props) {
|
|||
|
||||
const { tableProps, getData } = useTable(props["expertEmergencyRescueTeamList"], {
|
||||
form,
|
||||
params: { corpinfoId: query.corpinfoId },
|
||||
params: { corpId: query.corpinfoId },
|
||||
});
|
||||
|
||||
const onDelete = (record) => {
|
||||
|
|
@ -112,7 +112,7 @@ function List(props) {
|
|||
fixed: "right",
|
||||
render: (_, record) => (
|
||||
<Space>
|
||||
{props.permission("qyd-expert-emergency-rescue-team-view") && (
|
||||
{(props.isRecord || props.permission("qyd-expert-emergency-rescue-team-view")) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
@ -122,7 +122,7 @@ function List(props) {
|
|||
查看
|
||||
</Button>
|
||||
)}
|
||||
{props.permission("qyd-expert-emergency-rescue-team-emergency-rescue-personnel") && (
|
||||
{(props.isRecord || props.permission("qyd-expert-emergency-rescue-team-emergency-rescue-personnel")) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ function List(props) {
|
|||
|
||||
const { tableProps, getData } = useTable(props["enterpriseEmergencyOrganizationList"], {
|
||||
form,
|
||||
params: { corpinfoId: query.corpinfoId },
|
||||
params: { corpId: query.corpinfoId },
|
||||
});
|
||||
|
||||
const onDelete = (record) => {
|
||||
|
|
@ -113,7 +113,7 @@ function List(props) {
|
|||
fixed: "right",
|
||||
render: (_, record) => (
|
||||
<Space>
|
||||
{props.permission("qyd-enterprise-emergency-org-personnel") && (
|
||||
{(props.isRecord || props.permission("qyd-enterprise-emergency-org-personnel")) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
@ -123,7 +123,7 @@ function List(props) {
|
|||
查看人员
|
||||
</Button>
|
||||
)}
|
||||
{props.permission("qyd-enterprise-emergency-org-view") && (
|
||||
{(props.isRecord || props.permission("qyd-enterprise-emergency-org-view")) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ function List(props) {
|
|||
|
||||
const { tableProps, getData } = useTable(props["enterpriseEmergencyPersonnelList"], {
|
||||
form,
|
||||
params: { corpinfoId: query.corpinfoId },
|
||||
params: { corpId: query.corpinfoId },
|
||||
});
|
||||
|
||||
const onDelete = (record) => {
|
||||
|
|
@ -111,7 +111,7 @@ function List(props) {
|
|||
fixed: "right",
|
||||
render: (_, record) => (
|
||||
<Space>
|
||||
{props.permission("qyd-enterprise-emergency-personnel-view") && (
|
||||
{(props.isRecord || props.permission("qyd-enterprise-emergency-personnel-view")) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ function List(props) {
|
|||
|
||||
const { tableProps, getData } = useTable(props["emergencyRescueTeamList"], {
|
||||
form,
|
||||
params: { corpinfoId: query.corpinfoId },
|
||||
params: { corpId: query.corpinfoId },
|
||||
});
|
||||
|
||||
const onDelete = (record) => {
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ function List(props) {
|
|||
|
||||
const { tableProps, getData } = useTable(props["communicationGuaranteeOrganizationList"], {
|
||||
form,
|
||||
params: { corpinfoId: query.corpinfoId },
|
||||
params: { corpId: query.corpinfoId },
|
||||
});
|
||||
|
||||
const onDelete = (record) => {
|
||||
|
|
@ -110,7 +110,7 @@ function List(props) {
|
|||
fixed: "right",
|
||||
render: (_, record) => (
|
||||
<Space>
|
||||
{props.permission("qyd-communication-guarantee-org-view") && (
|
||||
{(props.isRecord || props.permission("qyd-communication-guarantee-org-view")) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ function List(props) {
|
|||
|
||||
const { tableProps, getData } = useTable(props["medicalGuaranteeOrganizationList"], {
|
||||
form,
|
||||
params: { corpinfoId: query.corpinfoId },
|
||||
params: { corpId: query.corpinfoId },
|
||||
});
|
||||
|
||||
const onDelete = (record) => {
|
||||
|
|
@ -118,7 +118,7 @@ function List(props) {
|
|||
fixed: "right",
|
||||
render: (_, record) => (
|
||||
<Space>
|
||||
{props.permission("qyd-medical-guarantee-org-view") && (
|
||||
{(props.isRecord || props.permission("qyd-medical-guarantee-org-view")) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ function List(props) {
|
|||
|
||||
const { tableProps, getData } = useTable(props["technicalSupportGuaranteeOrganizationList"], {
|
||||
form,
|
||||
params: { corpinfoId: query.corpinfoId },
|
||||
params: { corpId: query.corpinfoId },
|
||||
});
|
||||
|
||||
const onDelete = (record) => {
|
||||
|
|
@ -116,7 +116,7 @@ function List(props) {
|
|||
fixed: "right",
|
||||
render: (_, record) => (
|
||||
<Space>
|
||||
{props.permission("qyd-technical-support-org-view") && (
|
||||
{(props.isRecord || props.permission("qyd-technical-support-org-view")) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ function List(props) {
|
|||
|
||||
const { tableProps, getData } = useTable(props["transportGuaranteeOrganizationList"], {
|
||||
form,
|
||||
params: { corpinfoId: query.corpinfoId },
|
||||
params: { corpId: query.corpinfoId },
|
||||
});
|
||||
|
||||
const onDelete = (record) => {
|
||||
|
|
@ -110,7 +110,7 @@ function List(props) {
|
|||
fixed: "right",
|
||||
render: (_, record) => (
|
||||
<Space>
|
||||
{props.permission("qyd-transport-guarantee-org-view") && (
|
||||
{(props.isRecord || props.permission("qyd-transport-guarantee-org-view")) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ function List(props) {
|
|||
|
||||
const { tableProps, getData } = useTable(props["dutyLogList"], {
|
||||
form,
|
||||
params: { corpinfoId: query.corpinfoId },
|
||||
params: { corpId: query.corpinfoId },
|
||||
});
|
||||
|
||||
const onDelete = (record) => {
|
||||
|
|
@ -113,7 +113,7 @@ function List(props) {
|
|||
fixed: "right",
|
||||
render: (_, record) => (
|
||||
<Space>
|
||||
{props.permission("qyd-duty-log-view") && (
|
||||
{(props.isRecord || props.permission("qyd-duty-log-view")) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@ function List(props) {
|
|||
const { tableProps, getData } = useTable(props["schedulingRegistrationListAll"], {
|
||||
form,
|
||||
usePagination: false,
|
||||
params: { corpinfoId: query.corpinfoId },
|
||||
params: { corpId: query.corpinfoId },
|
||||
});
|
||||
|
||||
return (
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@ function List(props) {
|
|||
|
||||
const { tableProps, getData } = useTable(props["emergencyKnowledgeLibraryList"], {
|
||||
form,
|
||||
params: { likeEmergencyCaseType: 1, corpinfoId: query.corpinfoId },
|
||||
params: { likeEmergencyCaseType: 1, corpId: query.corpinfoId },
|
||||
});
|
||||
|
||||
const onDelete = (record) => {
|
||||
|
|
@ -123,7 +123,7 @@ function List(props) {
|
|||
width: 100,
|
||||
render: (_, record) => (
|
||||
<Space>
|
||||
{props.permission("qyd-case-library-download") && (
|
||||
{(props.isRecord || props.permission("qyd-case-library-download")) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={async () => {
|
||||
|
|
|
|||
|
|
@ -33,7 +33,7 @@ function List(props) {
|
|||
|
||||
const { tableProps, getData } = useTable(props["emergencyKnowledgeLibraryList"], {
|
||||
form,
|
||||
params: { likeEmergencyCaseType: 4, corpinfoId: query.corpinfoId },
|
||||
params: { likeEmergencyCaseType: 4, corpId: query.corpinfoId },
|
||||
});
|
||||
|
||||
const onDelete = (record) => {
|
||||
|
|
@ -122,7 +122,7 @@ function List(props) {
|
|||
width: 100,
|
||||
render: (_, record) => (
|
||||
<Space>
|
||||
{props.permission("qyd-generation-process-download") && (
|
||||
{(props.isRecord || props.permission("qyd-generation-process-download")) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={async () => {
|
||||
|
|
|
|||
|
|
@ -33,7 +33,7 @@ function List(props) {
|
|||
|
||||
const { tableProps, getData } = useTable(props["emergencyKnowledgeLibraryList"], {
|
||||
form,
|
||||
params: { likeEmergencyCaseType: 3, corpinfoId: query.corpinfoId },
|
||||
params: { likeEmergencyCaseType: 3, corpId: query.corpinfoId },
|
||||
});
|
||||
|
||||
const onDelete = (record) => {
|
||||
|
|
@ -121,7 +121,7 @@ function List(props) {
|
|||
width: 100,
|
||||
render: (_, record) => (
|
||||
<Space>
|
||||
{props.permission("qyd-hazardous-chemicals-download") && (
|
||||
{(props.isRecord || props.permission("qyd-hazardous-chemicals-download")) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={async () => {
|
||||
|
|
|
|||
|
|
@ -33,7 +33,7 @@ function List(props) {
|
|||
|
||||
const { tableProps, getData } = useTable(props["emergencyKnowledgeLibraryList"], {
|
||||
form,
|
||||
params: { likeEmergencyCaseType: 2, corpinfoId: query.corpinfoId },
|
||||
params: { likeEmergencyCaseType: 2, corpId: query.corpinfoId },
|
||||
});
|
||||
|
||||
const onDelete = (record) => {
|
||||
|
|
@ -120,7 +120,7 @@ function List(props) {
|
|||
width: 100,
|
||||
render: (_, record) => (
|
||||
<Space>
|
||||
{props.permission("qyd-hazardous-goods-download") && (
|
||||
{(props.isRecord || props.permission("qyd-hazardous-goods-download")) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={async () => {
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ function List(props) {
|
|||
occurrenceStartTime: formData.occurrenceTime?.[0],
|
||||
occurrenceEndTime: formData.occurrenceTime?.[1],
|
||||
}),
|
||||
params: { corpinfoId: query.corpinfoId },
|
||||
params: { corpId: query.corpinfoId },
|
||||
});
|
||||
|
||||
const onRescue = async (id) => {
|
||||
|
|
@ -94,7 +94,7 @@ function List(props) {
|
|||
是否救援
|
||||
</Button>
|
||||
)}
|
||||
{props.permission("qyd-event-report-view") && (
|
||||
{(props.isRecord || props.permission("qyd-event-report-view")) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ function List(props) {
|
|||
|
||||
const { tableProps, getData } = useTable(props["closedCardPortList"], {
|
||||
form,
|
||||
params: { corpinfoId: query.corpinfoId },
|
||||
params: { corpId: query.corpinfoId },
|
||||
});
|
||||
|
||||
const onDelete = (record) => {
|
||||
|
|
@ -109,7 +109,7 @@ function List(props) {
|
|||
fixed: "right",
|
||||
render: (_, record) => (
|
||||
<Space>
|
||||
{props.permission("qyd-closed-card-port-view") && (
|
||||
{(props.isRecord || props.permission("qyd-closed-card-port-view")) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ function List(props) {
|
|||
|
||||
const { tableProps, getData } = useTable(props["drainageWellList"], {
|
||||
form,
|
||||
params: { corpinfoId: query.corpinfoId },
|
||||
params: { corpId: query.corpinfoId },
|
||||
});
|
||||
|
||||
const onDelete = (record) => {
|
||||
|
|
@ -112,7 +112,7 @@ function List(props) {
|
|||
fixed: "right",
|
||||
render: (_, record) => (
|
||||
<Space>
|
||||
{props.permission("qyd-drainage-well-view") && (
|
||||
{(props.isRecord || props.permission("qyd-drainage-well-view")) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ function List(props) {
|
|||
|
||||
const { tableProps, getData } = useTable(props["emergencyEquipmentList"], {
|
||||
form,
|
||||
params: { corpinfoId: query.corpinfoId },
|
||||
params: { corpId: query.corpinfoId },
|
||||
});
|
||||
|
||||
const onDelete = (record) => {
|
||||
|
|
@ -111,7 +111,7 @@ function List(props) {
|
|||
fixed: "right",
|
||||
render: (_, record) => (
|
||||
<Space>
|
||||
{props.permission("qyd-emergency-equipment-view") && (
|
||||
{(props.isRecord || props.permission("qyd-emergency-equipment-view")) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ function List(props) {
|
|||
|
||||
const { tableProps, getData } = useTable(props["emergencyShelterList"], {
|
||||
form,
|
||||
params: { corpinfoId: query.corpinfoId },
|
||||
params: { corpId: query.corpinfoId },
|
||||
});
|
||||
|
||||
const onDelete = (record) => {
|
||||
|
|
@ -109,7 +109,7 @@ function List(props) {
|
|||
fixed: "right",
|
||||
render: (_, record) => (
|
||||
<Space>
|
||||
{props.permission("qyd-emergency-shelter-view") && (
|
||||
{(props.isRecord || props.permission("qyd-emergency-shelter-view")) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ function List(props) {
|
|||
|
||||
const { tableProps, getData } = useTable(props["materialEquipmentList"], {
|
||||
form,
|
||||
params: { corpinfoId: query.corpinfoId },
|
||||
params: { corpId: query.corpinfoId },
|
||||
});
|
||||
|
||||
const onDelete = (record) => {
|
||||
|
|
@ -113,8 +113,7 @@ function List(props) {
|
|||
fixed: "right",
|
||||
render: (_, record) => (
|
||||
<Space>
|
||||
{props.permission("qyd-material-equipment-facilities-equipment")
|
||||
&& (
|
||||
{(props.isRecord || props.permission("qyd-material-equipment-facilities-equipment")) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
@ -124,8 +123,7 @@ function List(props) {
|
|||
查看设施设备
|
||||
</Button>
|
||||
)}
|
||||
{props.permission("qyd-material-equipment-rescue-equipment")
|
||||
&& (
|
||||
{(props.isRecord || props.permission("qyd-material-equipment-rescue-equipment")) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
@ -135,7 +133,7 @@ function List(props) {
|
|||
查看救援装备
|
||||
</Button>
|
||||
)}
|
||||
{props.permission("qyd-material-equipment-material") && (
|
||||
{(props.isRecord || props.permission("qyd-material-equipment-material")) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
@ -145,7 +143,7 @@ function List(props) {
|
|||
查看物资
|
||||
</Button>
|
||||
)}
|
||||
{props.permission("qyd-material-equipment-view") && (
|
||||
{(props.isRecord || props.permission("qyd-material-equipment-view")) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@ function List(props) {
|
|||
drillStartTime: formData.drillTime?.[0],
|
||||
drillEndTime: formData.drillTime?.[1],
|
||||
}),
|
||||
params: { corpinfoId: query.corpinfoId },
|
||||
params: { corpId: query.corpinfoId },
|
||||
});
|
||||
|
||||
const onDelete = (record) => {
|
||||
|
|
@ -115,7 +115,7 @@ function List(props) {
|
|||
fixed: "right",
|
||||
render: (_, record) => (
|
||||
<Space>
|
||||
{props.permission("qyd-enterprise-emergency-exercise-view") && (
|
||||
{(props.isRecord || props.permission("qyd-enterprise-emergency-exercise-view")) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ function List(props) {
|
|||
|
||||
const { tableProps, getData } = useTable(props["emergencyPlanList"], {
|
||||
form,
|
||||
params: { corpinfoId: query.corpinfoId },
|
||||
params: { corpId: query.corpinfoId },
|
||||
});
|
||||
|
||||
const onDelete = (record) => {
|
||||
|
|
@ -109,7 +109,7 @@ function List(props) {
|
|||
fixed: "right",
|
||||
render: (_, record) => (
|
||||
<Space>
|
||||
{props.permission("qyd-enterprise-emergency-plan-view") && (
|
||||
{(props.isRecord || props.permission("qyd-enterprise-emergency-plan-view")) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ function List(props) {
|
|||
|
||||
const { tableProps, getData } = useTable(props["enterprisePlanBasicInfoList"], {
|
||||
form,
|
||||
params: { processStatus: props.processStatus || 0, corpinfoId: query.corpinfoId },
|
||||
params: { processStatus: props.processStatus || 0, corpId: query.corpinfoId },
|
||||
});
|
||||
|
||||
const onDelete = (record) => {
|
||||
|
|
@ -51,7 +51,7 @@ function List(props) {
|
|||
<Table
|
||||
toolBarRender={() => (
|
||||
<Space>
|
||||
{(!props.processStatus && props.permission("qyd-enterprise-plan-add")) && (
|
||||
{(!props.isRecord && !props.processStatus && props.permission("qyd-enterprise-plan-add")) && (
|
||||
<Button
|
||||
type="primary"
|
||||
icon={(<AddIcon />)}
|
||||
|
|
@ -80,7 +80,7 @@ function List(props) {
|
|||
fixed: "right",
|
||||
render: (_, record) => (
|
||||
<Space>
|
||||
{(props.processStatus !== 2 && props.permission(props.viewBtn || "qyd-enterprise-plan-view")) && (
|
||||
{(props.isRecord || (props.processStatus !== 2 && props.permission(props.viewBtn || "qyd-enterprise-plan-view"))) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
@ -90,7 +90,7 @@ function List(props) {
|
|||
查看
|
||||
</Button>
|
||||
)}
|
||||
{(props.processStatus === 2 && props.permission("qyd-enterprise-plan-audit-audit")) && (
|
||||
{(!props.isRecord && props.processStatus === 2 && props.permission("qyd-enterprise-plan-audit-audit")) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
@ -100,7 +100,7 @@ function List(props) {
|
|||
审核
|
||||
</Button>
|
||||
)}
|
||||
{(record.auditFlag === "3" && props.permission(props.reasonsRefusalBtn || "qyd-enterprise-plan-reasons-refusal")) && (
|
||||
{(record.auditFlag === "3" && (props.isRecord || props.permission(props.reasonsRefusalBtn || "qyd-enterprise-plan-reasons-refusal"))) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
@ -111,7 +111,7 @@ function List(props) {
|
|||
驳回原因
|
||||
</Button>
|
||||
)}
|
||||
{(!props.processStatus && props.permission("qyd-enterprise-plan-edit")) && (
|
||||
{(!props.isRecord && !props.processStatus && props.permission("qyd-enterprise-plan-edit")) && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
@ -121,7 +121,7 @@ function List(props) {
|
|||
编辑
|
||||
</Button>
|
||||
)}
|
||||
{(!props.processStatus && props.permission("qyd-enterprise-plan-del")) && (
|
||||
{(!props.isRecord && !props.processStatus && props.permission("qyd-enterprise-plan-del")) && (
|
||||
<Button
|
||||
type="link"
|
||||
danger
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import { Permission } from "@cqsjjb/jjb-common-decorator/permission";
|
||||
import { Connect } from "@cqsjjb/jjb-dva-runtime";
|
||||
import { Button } from "antd";
|
||||
import { Button, Space } from "antd";
|
||||
import Page from "zy-react-library/components/Page";
|
||||
import Search from "zy-react-library/components/Search";
|
||||
import Table from "zy-react-library/components/Table";
|
||||
|
|
@ -32,6 +33,8 @@ function List(props) {
|
|||
width: 150,
|
||||
fixed: "right",
|
||||
render: (_, record) => (
|
||||
<Space>
|
||||
{props.permission("jgd-emergency-address-book") && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
@ -40,6 +43,8 @@ function List(props) {
|
|||
>
|
||||
应急救援人列表
|
||||
</Button>
|
||||
)}
|
||||
</Space>
|
||||
),
|
||||
},
|
||||
]}
|
||||
|
|
@ -49,4 +54,4 @@ function List(props) {
|
|||
);
|
||||
}
|
||||
|
||||
export default Connect([NS_STATISTICS], true)(List);
|
||||
export default Connect([NS_STATISTICS], true)(Permission(List));
|
||||
|
|
|
|||
|
|
@ -1,10 +1,11 @@
|
|||
import { Permission } from "@cqsjjb/jjb-common-decorator/permission";
|
||||
import { Connect } from "@cqsjjb/jjb-dva-runtime";
|
||||
import { Button } from "antd";
|
||||
import Page from "zy-react-library/components/Page";
|
||||
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_STATISTICS } from "~/enumerate/namespace";
|
||||
import { permissionButtonByStatistics } from "~/utils";
|
||||
|
||||
function List(props) {
|
||||
const [form] = Search.useForm();
|
||||
|
|
@ -29,42 +30,36 @@ function List(props) {
|
|||
title: "救援队伍数",
|
||||
dataIndex: "emergencyRescueTeamCount",
|
||||
render: (_, record) => (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
props.history.push(`./expertEmergencyRescueTeam/list?corpinfoId=${record.corpinfoId}`);
|
||||
}}
|
||||
>
|
||||
{record.emergencyRescueTeamCount}
|
||||
</Button>
|
||||
permissionButtonByStatistics({
|
||||
permission: props.permission("jgd-expert-emergency-rescue-team"),
|
||||
url: `./expertEmergencyRescueTeam/list?corpinfoId=${record.corpinfoId}`,
|
||||
text: record.emergencyRescueTeamCount,
|
||||
history: props.history,
|
||||
})
|
||||
),
|
||||
},
|
||||
{
|
||||
title: "应急救援专家数",
|
||||
dataIndex: "emergencyRescueExpertCount",
|
||||
render: (_, record) => (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
props.history.push(`./expertEmergencyRescueExpert/list?corpinfoId=${record.corpinfoId}`);
|
||||
}}
|
||||
>
|
||||
{record.emergencyRescueExpertCount}
|
||||
</Button>
|
||||
permissionButtonByStatistics({
|
||||
permission: props.permission("jgd-expert-emergency-rescue-expert"),
|
||||
url: `./expertEmergencyRescueExpert/list?corpinfoId=${record.corpinfoId}`,
|
||||
text: record.emergencyRescueExpertCount,
|
||||
history: props.history,
|
||||
})
|
||||
),
|
||||
},
|
||||
{
|
||||
title: "应急救援专家组数",
|
||||
dataIndex: "emergencyRescueExpertGroupCount",
|
||||
render: (_, record) => (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
props.history.push(`./expertEmergencyRescueExpertGroup/list?corpinfoId=${record.corpinfoId}`);
|
||||
}}
|
||||
>
|
||||
{record.emergencyRescueExpertGroupCount}
|
||||
</Button>
|
||||
permissionButtonByStatistics({
|
||||
permission: props.permission("jgd-expert-emergency-rescue-expert-group"),
|
||||
url: `./expertEmergencyRescueExpertGroup/list?corpinfoId=${record.corpinfoId}`,
|
||||
text: record.emergencyRescueExpertGroupCount,
|
||||
history: props.history,
|
||||
})
|
||||
),
|
||||
},
|
||||
]}
|
||||
|
|
@ -74,4 +69,4 @@ function List(props) {
|
|||
);
|
||||
}
|
||||
|
||||
export default Connect([NS_STATISTICS], true)(List);
|
||||
export default Connect([NS_STATISTICS], true)(Permission(List));
|
||||
|
|
|
|||
|
|
@ -1,10 +1,11 @@
|
|||
import { Permission } from "@cqsjjb/jjb-common-decorator/permission";
|
||||
import { Connect } from "@cqsjjb/jjb-dva-runtime";
|
||||
import { Button } from "antd";
|
||||
import Page from "zy-react-library/components/Page";
|
||||
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_STATISTICS } from "~/enumerate/namespace";
|
||||
import { permissionButtonByStatistics } from "~/utils";
|
||||
|
||||
function List(props) {
|
||||
const [form] = Search.useForm();
|
||||
|
|
@ -29,28 +30,24 @@ function List(props) {
|
|||
title: "应急机构数",
|
||||
dataIndex: "enterpriseEmergencyAgencyCount",
|
||||
render: (_, record) => (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
props.history.push(`./enterpriseEmergencyOrganization/list?corpinfoId=${record.corpinfoId}`);
|
||||
}}
|
||||
>
|
||||
{record.enterpriseEmergencyAgencyCount}
|
||||
</Button>
|
||||
permissionButtonByStatistics({
|
||||
permission: props.permission("jgd-enterprise-emergency-organization"),
|
||||
url: `./enterpriseEmergencyOrganization/list?corpinfoId=${record.corpinfoId}`,
|
||||
text: record.enterpriseEmergencyAgencyCount,
|
||||
history: props.history,
|
||||
})
|
||||
),
|
||||
},
|
||||
{
|
||||
title: "应急救援人数",
|
||||
dataIndex: "enterpriseEmergencyPersonnelCount",
|
||||
render: (_, record) => (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
props.history.push(`./enterpriseEmergencyPersonnel/list?corpinfoId=${record.corpinfoId}`);
|
||||
}}
|
||||
>
|
||||
{record.enterpriseEmergencyPersonnelCount}
|
||||
</Button>
|
||||
permissionButtonByStatistics({
|
||||
permission: props.permission("jgd-enterprise-emergency-personnel"),
|
||||
url: `./enterpriseEmergencyPersonnel/list?corpinfoId=${record.corpinfoId}`,
|
||||
text: record.enterpriseEmergencyPersonnelCount,
|
||||
history: props.history,
|
||||
})
|
||||
),
|
||||
},
|
||||
]}
|
||||
|
|
@ -60,4 +57,4 @@ function List(props) {
|
|||
);
|
||||
}
|
||||
|
||||
export default Connect([NS_STATISTICS], true)(List);
|
||||
export default Connect([NS_STATISTICS], true)(Permission(List));
|
||||
|
|
|
|||
|
|
@ -1,10 +1,11 @@
|
|||
import { Permission } from "@cqsjjb/jjb-common-decorator/permission";
|
||||
import { Connect } from "@cqsjjb/jjb-dva-runtime";
|
||||
import { Button } from "antd";
|
||||
import Page from "zy-react-library/components/Page";
|
||||
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_STATISTICS } from "~/enumerate/namespace";
|
||||
import { permissionButtonByStatistics } from "~/utils";
|
||||
|
||||
function List(props) {
|
||||
const [form] = Search.useForm();
|
||||
|
|
@ -29,14 +30,12 @@ function List(props) {
|
|||
title: "救援队伍数量",
|
||||
dataIndex: "emergencyRescueTeamManagementCount",
|
||||
render: (_, record) => (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
props.history.push(`./emergencyRescueTeam/list?corpinfoId=${record.corpinfoId}`);
|
||||
}}
|
||||
>
|
||||
{record.emergencyRescueTeamManagementCount}
|
||||
</Button>
|
||||
permissionButtonByStatistics({
|
||||
permission: props.permission("jgd-emergency-rescue-team"),
|
||||
url: `./emergencyRescueTeam/list?corpinfoId=${record.corpinfoId}`,
|
||||
text: record.emergencyRescueTeamManagementCount,
|
||||
history: props.history,
|
||||
})
|
||||
),
|
||||
},
|
||||
]}
|
||||
|
|
@ -46,4 +45,4 @@ function List(props) {
|
|||
);
|
||||
}
|
||||
|
||||
export default Connect([NS_STATISTICS], true)(List);
|
||||
export default Connect([NS_STATISTICS], true)(Permission(List));
|
||||
|
|
|
|||
|
|
@ -1,10 +1,11 @@
|
|||
import { Permission } from "@cqsjjb/jjb-common-decorator/permission";
|
||||
import { Connect } from "@cqsjjb/jjb-dva-runtime";
|
||||
import { Button } from "antd";
|
||||
import Page from "zy-react-library/components/Page";
|
||||
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_STATISTICS } from "~/enumerate/namespace";
|
||||
import { permissionButtonByStatistics } from "~/utils";
|
||||
|
||||
function List(props) {
|
||||
const [form] = Search.useForm();
|
||||
|
|
@ -29,56 +30,48 @@ function List(props) {
|
|||
title: "运输保障机构",
|
||||
dataIndex: "transportSecurityAgencyCount",
|
||||
render: (_, record) => (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
props.history.push(`./transportGuaranteeOrganization/list?corpinfoId=${record.corpinfoId}`);
|
||||
}}
|
||||
>
|
||||
{record.transportSecurityAgencyCount}
|
||||
</Button>
|
||||
permissionButtonByStatistics({
|
||||
permission: props.permission("jgd-transport-guarantee-organization"),
|
||||
url: `./transportGuaranteeOrganization/list?corpinfoId=${record.corpinfoId}`,
|
||||
text: record.transportSecurityAgencyCount,
|
||||
history: props.history,
|
||||
})
|
||||
),
|
||||
},
|
||||
{
|
||||
title: "医疗保障机构",
|
||||
dataIndex: "medicalSecurityAgencyCount",
|
||||
render: (_, record) => (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
props.history.push(`./medicalGuaranteeOrganization/list?corpinfoId=${record.corpinfoId}`);
|
||||
}}
|
||||
>
|
||||
{record.medicalSecurityAgencyCount}
|
||||
</Button>
|
||||
permissionButtonByStatistics({
|
||||
permission: props.permission("jgd-medical-guarantee-organization"),
|
||||
url: `./medicalGuaranteeOrganization/list?corpinfoId=${record.corpinfoId}`,
|
||||
text: record.medicalSecurityAgencyCount,
|
||||
history: props.history,
|
||||
})
|
||||
),
|
||||
},
|
||||
{
|
||||
title: "通讯保障机构",
|
||||
dataIndex: "communicationSecurityAgencyCount",
|
||||
render: (_, record) => (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
props.history.push(`./communicationGuaranteeOrganization/list?corpinfoId=${record.corpinfoId}`);
|
||||
}}
|
||||
>
|
||||
{record.communicationSecurityAgencyCount}
|
||||
</Button>
|
||||
permissionButtonByStatistics({
|
||||
permission: props.permission("jgd-communication-guarantee-organization"),
|
||||
url: `./communicationGuaranteeOrganization/list?corpinfoId=${record.corpinfoId}`,
|
||||
text: record.communicationSecurityAgencyCount,
|
||||
history: props.history,
|
||||
})
|
||||
),
|
||||
},
|
||||
{
|
||||
title: "技术支持机构",
|
||||
dataIndex: "technicalSupportAgencyCount",
|
||||
render: (_, record) => (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
props.history.push(`./technicalSupportGuaranteeOrganization/list?corpinfoId=${record.corpinfoId}`);
|
||||
}}
|
||||
>
|
||||
{record.technicalSupportAgencyCount}
|
||||
</Button>
|
||||
permissionButtonByStatistics({
|
||||
permission: props.permission("jgd-technical-support-guarantee-organization"),
|
||||
url: `./technicalSupportGuaranteeOrganization/list?corpinfoId=${record.corpinfoId}`,
|
||||
text: record.technicalSupportAgencyCount,
|
||||
history: props.history,
|
||||
})
|
||||
),
|
||||
},
|
||||
]}
|
||||
|
|
@ -88,4 +81,4 @@ function List(props) {
|
|||
);
|
||||
}
|
||||
|
||||
export default Connect([NS_STATISTICS], true)(List);
|
||||
export default Connect([NS_STATISTICS], true)(Permission(List));
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import { Permission } from "@cqsjjb/jjb-common-decorator/permission";
|
||||
import { Connect } from "@cqsjjb/jjb-dva-runtime";
|
||||
import { Button } from "antd";
|
||||
import { Button, Space } from "antd";
|
||||
import Page from "zy-react-library/components/Page";
|
||||
import Search from "zy-react-library/components/Search";
|
||||
import Table from "zy-react-library/components/Table";
|
||||
|
|
@ -33,6 +34,8 @@ function List(props) {
|
|||
width: 100,
|
||||
fixed: "right",
|
||||
render: (_, record) => (
|
||||
<Space>
|
||||
{props.permission("jgd-event-report") && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
@ -41,6 +44,8 @@ function List(props) {
|
|||
>
|
||||
查看
|
||||
</Button>
|
||||
)}
|
||||
</Space>
|
||||
),
|
||||
},
|
||||
]}
|
||||
|
|
@ -50,4 +55,4 @@ function List(props) {
|
|||
);
|
||||
}
|
||||
|
||||
export default Connect([NS_STATISTICS], true)(List);
|
||||
export default Connect([NS_STATISTICS], true)(Permission(List));
|
||||
|
|
|
|||
|
|
@ -1,10 +1,11 @@
|
|||
import { Permission } from "@cqsjjb/jjb-common-decorator/permission";
|
||||
import { Connect } from "@cqsjjb/jjb-dva-runtime";
|
||||
import { Button } from "antd";
|
||||
import Page from "zy-react-library/components/Page";
|
||||
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_STATISTICS } from "~/enumerate/namespace";
|
||||
import { permissionButtonByStatistics } from "~/utils";
|
||||
|
||||
function List(props) {
|
||||
const [form] = Search.useForm();
|
||||
|
|
@ -29,56 +30,48 @@ function List(props) {
|
|||
title: "案例库数",
|
||||
dataIndex: "todo",
|
||||
render: (_, record) => (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
props.history.push(`./case/list?corpinfoId=${record.corpinfoId}`);
|
||||
}}
|
||||
>
|
||||
{record.todo}
|
||||
</Button>
|
||||
permissionButtonByStatistics({
|
||||
permission: props.permission("jgd-case"),
|
||||
url: `./case/list?corpinfoId=${record.corpinfoId}`,
|
||||
text: record.todo,
|
||||
history: props.history,
|
||||
})
|
||||
),
|
||||
},
|
||||
{
|
||||
title: "危险货物品数",
|
||||
dataIndex: "todo",
|
||||
render: (_, record) => (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
props.history.push(`./hazardousGoods/list?corpinfoId=${record.corpinfoId}`);
|
||||
}}
|
||||
>
|
||||
{record.todo}
|
||||
</Button>
|
||||
permissionButtonByStatistics({
|
||||
permission: props.permission("jgd-hazardous-goods"),
|
||||
url: `./hazardousGoods/list?corpinfoId=${record.corpinfoId}`,
|
||||
text: record.todo,
|
||||
history: props.history,
|
||||
})
|
||||
),
|
||||
},
|
||||
{
|
||||
title: "危化品数",
|
||||
dataIndex: "todo",
|
||||
render: (_, record) => (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
props.history.push(`./hazardousChemicals/list?corpinfoId=${record.corpinfoId}`);
|
||||
}}
|
||||
>
|
||||
{record.todo}
|
||||
</Button>
|
||||
permissionButtonByStatistics({
|
||||
permission: props.permission("jgd-hazardous-chemicals"),
|
||||
url: `./hazardousChemicals/list?corpinfoId=${record.corpinfoId}`,
|
||||
text: record.todo,
|
||||
history: props.history,
|
||||
})
|
||||
),
|
||||
},
|
||||
{
|
||||
title: "生产工艺数",
|
||||
dataIndex: "todo",
|
||||
render: (_, record) => (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
props.history.push(`./generationProcess/list?corpinfoId=${record.corpinfoId}`);
|
||||
}}
|
||||
>
|
||||
{record.todo}
|
||||
</Button>
|
||||
permissionButtonByStatistics({
|
||||
permission: props.permission("jgd-generation-process"),
|
||||
url: `./generationProcess/list?corpinfoId=${record.corpinfoId}`,
|
||||
text: record.todo,
|
||||
history: props.history,
|
||||
})
|
||||
),
|
||||
},
|
||||
]}
|
||||
|
|
@ -88,4 +81,4 @@ function List(props) {
|
|||
);
|
||||
}
|
||||
|
||||
export default Connect([NS_STATISTICS], true)(List);
|
||||
export default Connect([NS_STATISTICS], true)(Permission(List));
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
import { Permission } from "@cqsjjb/jjb-common-decorator/permission";
|
||||
import { Connect } from "@cqsjjb/jjb-dva-runtime";
|
||||
import { Button, Space } from "antd";
|
||||
import Page from "zy-react-library/components/Page";
|
||||
|
|
@ -29,6 +30,7 @@ function List(props) {
|
|||
title: "操作",
|
||||
render: (_, record) => (
|
||||
<Space>
|
||||
{props.permission("jgd-duty-log") && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
@ -37,6 +39,8 @@ function List(props) {
|
|||
>
|
||||
值班日志
|
||||
</Button>
|
||||
)}
|
||||
{props.permission("jgd-scheduling-registration") && (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
|
|
@ -45,6 +49,7 @@ function List(props) {
|
|||
>
|
||||
排班登记记录
|
||||
</Button>
|
||||
)}
|
||||
</Space>
|
||||
),
|
||||
},
|
||||
|
|
@ -55,4 +60,4 @@ function List(props) {
|
|||
);
|
||||
}
|
||||
|
||||
export default Connect([NS_STATISTICS], true)(List);
|
||||
export default Connect([NS_STATISTICS], true)(Permission(List));
|
||||
|
|
|
|||
|
|
@ -1,10 +1,11 @@
|
|||
import { Permission } from "@cqsjjb/jjb-common-decorator/permission";
|
||||
import { Connect } from "@cqsjjb/jjb-dva-runtime";
|
||||
import { Button } from "antd";
|
||||
import Page from "zy-react-library/components/Page";
|
||||
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_STATISTICS } from "~/enumerate/namespace";
|
||||
import { permissionButtonByStatistics } from "~/utils";
|
||||
|
||||
function List(props) {
|
||||
const [form] = Search.useForm();
|
||||
|
|
@ -28,7 +29,14 @@ function List(props) {
|
|||
{
|
||||
title: "救援次数",
|
||||
dataIndex: "todo",
|
||||
render: (_, record) => <Button type="link">{record.todo}</Button>,
|
||||
render: (_, record) => (
|
||||
permissionButtonByStatistics({
|
||||
permission: props.permission("jgd-rescue"),
|
||||
url: `./todo/list?corpinfoId=${record.corpinfoId}`,
|
||||
text: record.todo,
|
||||
history: props.history,
|
||||
})
|
||||
),
|
||||
},
|
||||
]}
|
||||
{...tableProps}
|
||||
|
|
@ -37,4 +45,4 @@ function List(props) {
|
|||
);
|
||||
}
|
||||
|
||||
export default Connect([NS_STATISTICS], true)(List);
|
||||
export default Connect([NS_STATISTICS], true)(Permission(List));
|
||||
|
|
|
|||
|
|
@ -1,10 +1,11 @@
|
|||
import { Permission } from "@cqsjjb/jjb-common-decorator/permission";
|
||||
import { Connect } from "@cqsjjb/jjb-dva-runtime";
|
||||
import { Button } from "antd";
|
||||
import Page from "zy-react-library/components/Page";
|
||||
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_STATISTICS } from "~/enumerate/namespace";
|
||||
import { permissionButtonByStatistics } from "~/utils";
|
||||
|
||||
function List(props) {
|
||||
const [form] = Search.useForm();
|
||||
|
|
@ -29,84 +30,72 @@ function List(props) {
|
|||
title: "应急装备数",
|
||||
dataIndex: "emergencyEquipmentCount",
|
||||
render: (_, record) => (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
props.history.push(`./emergencyEquipment/list?corpinfoId=${record.corpinfoId}`);
|
||||
}}
|
||||
>
|
||||
{record.emergencyEquipmentCount}
|
||||
</Button>
|
||||
permissionButtonByStatistics({
|
||||
permission: props.permission("jgd-emergency-equipment"),
|
||||
url: `./emergencyEquipment/list?corpinfoId=${record.corpinfoId}`,
|
||||
text: record.emergencyEquipmentCount,
|
||||
history: props.history,
|
||||
})
|
||||
),
|
||||
},
|
||||
{
|
||||
title: "物资装备库数",
|
||||
dataIndex: "materialEquipmentCount",
|
||||
render: (_, record) => (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
props.history.push(`./materialEquipment/list?corpinfoId=${record.corpinfoId}`);
|
||||
}}
|
||||
>
|
||||
{record.materialEquipmentCount}
|
||||
</Button>
|
||||
permissionButtonByStatistics({
|
||||
permission: props.permission("jgd-material-equipment"),
|
||||
url: `./materialEquipment/list?corpinfoId=${record.corpinfoId}`,
|
||||
text: record.materialEquipmentCount,
|
||||
history: props.history,
|
||||
})
|
||||
),
|
||||
},
|
||||
{
|
||||
title: "应急避难场所数",
|
||||
dataIndex: "placeInfoCount",
|
||||
render: (_, record) => (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
props.history.push(`./emergencyShelter/list?corpinfoId=${record.corpinfoId}`);
|
||||
}}
|
||||
>
|
||||
{record.placeInfoCount}
|
||||
</Button>
|
||||
permissionButtonByStatistics({
|
||||
permission: props.permission("jgd-emergency-shelter"),
|
||||
url: `./emergencyShelter/list?corpinfoId=${record.corpinfoId}`,
|
||||
text: record.placeInfoCount,
|
||||
history: props.history,
|
||||
})
|
||||
),
|
||||
},
|
||||
{
|
||||
title: "消防物资数",
|
||||
dataIndex: "fireFightingCount",
|
||||
render: (_, record) => (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
props.history.push(`./firefightingEquipment/list?corpinfoId=${record.corpinfoId}`);
|
||||
}}
|
||||
>
|
||||
{record.fireFightingCount}
|
||||
</Button>
|
||||
permissionButtonByStatistics({
|
||||
permission: props.permission("jgd-firefighting-equipment"),
|
||||
url: `./firefightingEquipment/list?corpinfoId=${record.corpinfoId}`,
|
||||
text: record.fireFightingCount,
|
||||
history: props.history,
|
||||
})
|
||||
),
|
||||
},
|
||||
{
|
||||
title: "排水井数",
|
||||
dataIndex: "drainageWellCount",
|
||||
render: (_, record) => (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
props.history.push(`./drainageWell/list?corpinfoId=${record.corpinfoId}`);
|
||||
}}
|
||||
>
|
||||
{record.drainageWellCount}
|
||||
</Button>
|
||||
permissionButtonByStatistics({
|
||||
permission: props.permission("jgd-drainage-well"),
|
||||
url: `./drainageWell/list?corpinfoId=${record.corpinfoId}`,
|
||||
text: record.drainageWellCount,
|
||||
history: props.history,
|
||||
})
|
||||
),
|
||||
},
|
||||
{
|
||||
title: "封闭卡口数",
|
||||
dataIndex: "closedCheckpointInfoCount",
|
||||
render: (_, record) => (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
props.history.push(`./closedCardPort/list?corpinfoId=${record.corpinfoId}`);
|
||||
}}
|
||||
>
|
||||
{record.closedCheckpointInfoCount}
|
||||
</Button>
|
||||
permissionButtonByStatistics({
|
||||
permission: props.permission("jgd-closed-card-port"),
|
||||
url: `./closedCardPort/list?corpinfoId=${record.corpinfoId}`,
|
||||
text: record.closedCheckpointInfoCount,
|
||||
history: props.history,
|
||||
})
|
||||
),
|
||||
},
|
||||
]}
|
||||
|
|
@ -116,4 +105,4 @@ function List(props) {
|
|||
);
|
||||
}
|
||||
|
||||
export default Connect([NS_STATISTICS], true)(List);
|
||||
export default Connect([NS_STATISTICS], true)(Permission(List));
|
||||
|
|
|
|||
|
|
@ -1,10 +1,11 @@
|
|||
import { Permission } from "@cqsjjb/jjb-common-decorator/permission";
|
||||
import { Connect } from "@cqsjjb/jjb-dva-runtime";
|
||||
import { Button } from "antd";
|
||||
import Page from "zy-react-library/components/Page";
|
||||
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_STATISTICS } from "~/enumerate/namespace";
|
||||
import { permissionButtonByStatistics } from "~/utils";
|
||||
|
||||
function List(props) {
|
||||
const [form] = Search.useForm();
|
||||
|
|
@ -29,14 +30,12 @@ function List(props) {
|
|||
title: "应急演练次数",
|
||||
dataIndex: "todo",
|
||||
render: (_, record) => (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
props.history.push(`./emergencyExercise/list?corpinfoId=${record.corpinfoId}`);
|
||||
}}
|
||||
>
|
||||
{record.todo}
|
||||
</Button>
|
||||
permissionButtonByStatistics({
|
||||
permission: props.permission("jgd-emergency-exercise"),
|
||||
url: `./emergencyExercise/list?corpinfoId=${record.corpinfoId}`,
|
||||
text: record.todo,
|
||||
history: props.history,
|
||||
})
|
||||
),
|
||||
},
|
||||
]}
|
||||
|
|
@ -46,4 +45,4 @@ function List(props) {
|
|||
);
|
||||
}
|
||||
|
||||
export default Connect([NS_STATISTICS], true)(List);
|
||||
export default Connect([NS_STATISTICS], true)(Permission(List));
|
||||
|
|
|
|||
|
|
@ -1,10 +1,11 @@
|
|||
import { Permission } from "@cqsjjb/jjb-common-decorator/permission";
|
||||
import { Connect } from "@cqsjjb/jjb-dva-runtime";
|
||||
import { Button } from "antd";
|
||||
import Page from "zy-react-library/components/Page";
|
||||
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_STATISTICS } from "~/enumerate/namespace";
|
||||
import { permissionButtonByStatistics } from "~/utils";
|
||||
|
||||
function List(props) {
|
||||
const [form] = Search.useForm();
|
||||
|
|
@ -29,14 +30,12 @@ function List(props) {
|
|||
title: "应急预案数量",
|
||||
dataIndex: "todo",
|
||||
render: (_, record) => (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
props.history.push(`./emergencyPlan/list?corpinfoId=${record.corpinfoId}`);
|
||||
}}
|
||||
>
|
||||
{record.todo}
|
||||
</Button>
|
||||
permissionButtonByStatistics({
|
||||
permission: props.permission("jgd-emergency-plan"),
|
||||
url: `./emergencyPlan/list?corpinfoId=${record.corpinfoId}`,
|
||||
text: record.todo,
|
||||
history: props.history,
|
||||
})
|
||||
),
|
||||
},
|
||||
]}
|
||||
|
|
@ -46,4 +45,4 @@ function List(props) {
|
|||
);
|
||||
}
|
||||
|
||||
export default Connect([NS_STATISTICS], true)(List);
|
||||
export default Connect([NS_STATISTICS], true)(Permission(List));
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
import ListPage from "~/pages/Container/Enterprise/PlanAndDrill/EnterprisePlan/List";
|
||||
|
||||
function List(props) {
|
||||
return (<ListPage processStatus={1} headerTitle="企业预案" {...props} />);
|
||||
return (<ListPage processStatus={1} isRecord headerTitle="企业预案" {...props} />);
|
||||
}
|
||||
|
||||
export default List;
|
||||
|
|
|
|||
|
|
@ -1,10 +1,11 @@
|
|||
import { Permission } from "@cqsjjb/jjb-common-decorator/permission";
|
||||
import { Connect } from "@cqsjjb/jjb-dva-runtime";
|
||||
import { Button } from "antd";
|
||||
import Page from "zy-react-library/components/Page";
|
||||
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_STATISTICS } from "~/enumerate/namespace";
|
||||
import { permissionButtonByStatistics } from "~/utils";
|
||||
|
||||
function List(props) {
|
||||
const [form] = Search.useForm();
|
||||
|
|
@ -29,14 +30,12 @@ function List(props) {
|
|||
title: "企业预案数量",
|
||||
dataIndex: "todo",
|
||||
render: (_, record) => (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
props.history.push(`./enterprisePlan/list?corpinfoId=${record.corpinfoId}`);
|
||||
}}
|
||||
>
|
||||
{record.todo}
|
||||
</Button>
|
||||
permissionButtonByStatistics({
|
||||
permission: props.permission("jgd-enterprise-plan"),
|
||||
url: `./enterprisePlan/list?corpinfoId=${record.corpinfoId}`,
|
||||
text: record.todo,
|
||||
history: props.history,
|
||||
})
|
||||
),
|
||||
},
|
||||
]}
|
||||
|
|
@ -46,4 +45,4 @@ function List(props) {
|
|||
);
|
||||
}
|
||||
|
||||
export default Connect([NS_STATISTICS], true)(List);
|
||||
export default Connect([NS_STATISTICS], true)(Permission(List));
|
||||
|
|
|
|||
|
|
@ -0,0 +1,35 @@
|
|||
import { Button } from "antd";
|
||||
|
||||
/**
|
||||
* 统计页面权限按钮组件
|
||||
* @param {object} options - 配置选项
|
||||
* @param {boolean} options.permission - 权限标识
|
||||
* @param {object} options.history - history 对象
|
||||
* @param {string|number} options.text - 按钮显示文本
|
||||
* @param {string} options.url - 跳转路径
|
||||
* @returns {JSX.Element} 有权限时返回 Button 组件,无权限时返回 span 标签
|
||||
*
|
||||
* @example
|
||||
* permissionButtonByStatistics({
|
||||
* permission: props.permission(""),
|
||||
* url: "",
|
||||
* text: "",
|
||||
* history: props.history,
|
||||
* })
|
||||
*/
|
||||
export function permissionButtonByStatistics({ permission, history, text, url }) {
|
||||
return (
|
||||
permission
|
||||
? (
|
||||
<Button
|
||||
type="link"
|
||||
onClick={() => {
|
||||
history.push(url);
|
||||
}}
|
||||
>
|
||||
{text}
|
||||
</Button>
|
||||
)
|
||||
: <span>{text}</span>
|
||||
);
|
||||
}
|
||||
Loading…
Reference in New Issue