11.15 电子评标室模块增加权限字
This commit is contained in:
@ -3,6 +3,7 @@ import { message, PageHeader, Button, Spin } from 'antd';
|
||||
import ProTable, { ProColumns, ActionType } from '@ant-design/pro-table';
|
||||
import { getPage, handleAlarm } from './service';
|
||||
import ViewEvalAlarmUpdateModal from '../../Evaluation/BidControl/BidControlManager/components/ViewEvalAlarmUpdateModal';
|
||||
import { btnAuthority } from '@/utils/authority';
|
||||
|
||||
|
||||
interface alarmData {
|
||||
@ -82,10 +83,10 @@ const AbnormalAalarm: React.FC<{}> = () => {
|
||||
render: (_, record) => {
|
||||
if (record.type === "1") {
|
||||
if (record.status === "0") {
|
||||
return <Button type="text" onClick={() => { handle(record); }}>处理</Button>
|
||||
return !btnAuthority(["ebtp-site-supervision"]) && <Button type="text" onClick={() => { handle(record); }}>处理</Button>
|
||||
}
|
||||
} else {
|
||||
return (<Button type='text' onClick={() => { EnvData(record); setViewDetailModalVisible(true); }}>查看详情</Button>
|
||||
return (!btnAuthority(["ebtp-site-supervision"]) && <Button type='text' onClick={() => { EnvData(record); setViewDetailModalVisible(true); }}>查看详情</Button>
|
||||
)
|
||||
}
|
||||
}
|
||||
|
@ -7,6 +7,7 @@ import MeetingReservation from '@/components/ElecBidEvaluation/MeetingReservatio
|
||||
import { getRecordData, getSiteList } from './service';
|
||||
import { isEmpty } from '@/utils/CommonUtils';
|
||||
import { getSessionRoleData } from '@/utils/session';
|
||||
import { btnAuthority } from '@/utils/authority';
|
||||
|
||||
const orange_bg = { background: '#ffbc83', color: '#333333', cursor: 'pointer', width: '100%', overflow: 'hidden', textOverflow: 'ellipsis', whiteSpace: 'nowrap' };
|
||||
const light_orange_bg = { background: '#faf7e5' };
|
||||
@ -45,7 +46,7 @@ const ScreenTable = (props: { record: any, onCellClick: (id: any) => void, refre
|
||||
onCell: (record) => {
|
||||
return {
|
||||
style: record[ite.id]?.iskssj ? orange_bg : light_orange_bg,
|
||||
onClick: record[ite.id]?.iskssj ? () => onCellClick(record[ite.id]) : void 0,
|
||||
onClick: !btnAuthority(["ebtp-appointment", "ebtp-site-admin"]) && record[ite.id]?.iskssj ? () => onCellClick(record[ite.id]) : void 0,
|
||||
}
|
||||
},
|
||||
render: (_: any, record: any) => {
|
||||
@ -86,14 +87,14 @@ const ScreenTable = (props: { record: any, onCellClick: (id: any) => void, refre
|
||||
<div>
|
||||
{tableData.length > 0 && (
|
||||
<div style={{ display: 'flex', justifyContent: 'space-between', alignItems: 'center', paddingBottom: 16 }}>
|
||||
<Space>
|
||||
{!btnAuthority(["ebtp-appointment", "ebtp-site-admin"]) && <Space>
|
||||
<Button key="last-week" size='small' type="primary" onClick={() => weekChange("0")}>
|
||||
上一周
|
||||
</Button>
|
||||
<Button key="after-week" size='small' type="primary" onClick={() => weekChange("1")}>
|
||||
下一周
|
||||
</Button>
|
||||
</Space>
|
||||
</Space>}
|
||||
<Space size="middle">
|
||||
<div style={align_middle}><Tag color="#faf7e5" style={tag_size}></Tag>可预约{roleCode == "ebtp-appointment" ? "会议室" : "电子评标室"}</div>
|
||||
<div style={align_middle}><Tag color="#ffbc83" style={tag_size}></Tag>已预约{roleCode == "ebtp-appointment" ? "会议室" : "电子评标室"}</div>
|
||||
@ -172,15 +173,15 @@ export default () => {
|
||||
<Card title={roleCode == "ebtp-appointment" ? "会议室预约情况" : "评标室预约情况"} bodyStyle={{ padding: '16px 0px', height: window.innerHeight - 120, overflowY: 'auto' }}>
|
||||
<div style={{ display: 'flex', justifyContent: 'space-between', alignItems: 'center', padding: '0 36px 16px' }}>
|
||||
<Space>
|
||||
<Button key="yuyue" type="primary" onClick={() => createMeet()}>
|
||||
{!btnAuthority(["ebtp-appointment", "ebtp-site-admin"]) && <Button key="yuyue" type="primary" onClick={() => createMeet()}>
|
||||
预约
|
||||
</Button>
|
||||
</Button>}
|
||||
{roleCode == "ebtp-appointment" ? (//预约人员
|
||||
<Button key="myyuyue" onClick={() => MyReserveContent()}>
|
||||
我的预约
|
||||
</Button>
|
||||
) : (
|
||||
<Button key="yuyueconfirm" onClick={() => viewMeetContent()}>
|
||||
!btnAuthority(["ebtp-site-admin"]) && <Button key="yuyueconfirm" onClick={() => viewMeetContent()}>
|
||||
查看预约详情
|
||||
</Button>
|
||||
)}
|
||||
|
@ -7,6 +7,7 @@ import { getURLInformation, isNotEmpty } from '@/utils/CommonUtils';
|
||||
import MeetingReservation from '@/components/ElecBidEvaluation/MeetingReservation';
|
||||
import moment from 'moment';
|
||||
import { dateTimeFormatter } from '@/utils/DateUtils';
|
||||
import { btnAuthority } from '@/utils/authority';
|
||||
|
||||
const MyReserve: React.FC<{}> = () => {
|
||||
const meetingRelationRef = useRef<ActionType>(); //操作数据后刷新列表
|
||||
@ -139,7 +140,7 @@ const MyReserve: React.FC<{}> = () => {
|
||||
search: false,
|
||||
render: (text: any, record: any) => {
|
||||
return (
|
||||
<>
|
||||
!btnAuthority(["ebtp-appointment"]) && <>
|
||||
<Button type="text" onClick={() => viewMeet(record)} danger>
|
||||
查看
|
||||
</Button>
|
||||
@ -211,7 +212,7 @@ const MyReserve: React.FC<{}> = () => {
|
||||
>
|
||||
{searchConfig?.searchText}
|
||||
</Button>,
|
||||
<Button
|
||||
!btnAuthority(["ebtp-appointment"]) && <Button
|
||||
key="addText"
|
||||
type="primary"
|
||||
onClick={() => createMeet()}
|
||||
|
@ -7,6 +7,7 @@ import { getURLInformation, isNotEmpty } from '@/utils/CommonUtils';
|
||||
import MeetingReservation from '@/components/ElecBidEvaluation/MeetingReservation';
|
||||
import moment from 'moment';
|
||||
import { dateTimeFormatter } from '@/utils/DateUtils';
|
||||
import { btnAuthority } from '@/utils/authority';
|
||||
|
||||
const { TabPane } = Tabs;
|
||||
const statusEnum = {
|
||||
@ -166,7 +167,7 @@ const Index: React.FC<{}> = () => {
|
||||
search: false,
|
||||
render: (text: any, record: any) => {
|
||||
return (
|
||||
<>
|
||||
!btnAuthority(["ebtp-site-admin"]) && <>
|
||||
<Button type="text" onClick={() => viewMeet(record)} danger>
|
||||
查看
|
||||
</Button>
|
||||
@ -254,7 +255,7 @@ const Index: React.FC<{}> = () => {
|
||||
search: false,
|
||||
render: (text: any, record: any) => {
|
||||
return (
|
||||
<>
|
||||
!btnAuthority(["ebtp-site-admin"]) && <>
|
||||
<Button type="text" onClick={() => viewMeet(record)} danger>
|
||||
查看
|
||||
</Button>
|
||||
@ -392,7 +393,7 @@ const Index: React.FC<{}> = () => {
|
||||
>
|
||||
{searchConfig?.searchText}
|
||||
</Button>,
|
||||
<Button
|
||||
!btnAuthority(["ebtp-site-admin"]) && <Button
|
||||
key="addText"
|
||||
type="primary"
|
||||
onClick={() => createMeet()}
|
||||
|
@ -3,6 +3,7 @@ import ProTable, { ActionType } from '@ant-design/pro-table';
|
||||
import { getList } from './service';
|
||||
import { Card, Spin } from 'antd';
|
||||
import PersonReportModal from './components/PersonReportModal';
|
||||
import { btnAuthority } from '@/utils/authority';
|
||||
|
||||
const PersonReport: React.FC<{}> = () => {
|
||||
const checkRelationRef = useRef<ActionType>(); //操作数据后刷新列表
|
||||
@ -86,7 +87,7 @@ const PersonReport: React.FC<{}> = () => {
|
||||
width: 80,
|
||||
render: (text: any, record: any) => {
|
||||
return (
|
||||
<>
|
||||
!btnAuthority(["ebtp-site-admin"]) && <>
|
||||
<a onClick={() => setFormVals(record)}>查看详情</a>
|
||||
</>
|
||||
)
|
||||
|
@ -4,6 +4,7 @@ import { getGroupPageList, saveSiteGroup, delSiteGroup } from '../service';
|
||||
import { Button, Form, message, Spin, Popconfirm } from 'antd';
|
||||
import SiteGroupModal from './SiteGroupModal';
|
||||
import AuthorizeModal from './AuthorizeModal';
|
||||
import { btnAuthority } from '@/utils/authority';
|
||||
|
||||
|
||||
const GroupPermission: React.FC<{}> = () => {
|
||||
@ -48,7 +49,7 @@ const GroupPermission: React.FC<{}> = () => {
|
||||
width: '30%',
|
||||
render: (text: any, record: any) => {
|
||||
return (
|
||||
<>
|
||||
!btnAuthority(["ebtp-site-admin"]) && <>
|
||||
<a onClick={() => setFormVals(record)}>编辑</a>
|
||||
<a onClick={() => setAuthorize(record)}>授权管理</a>
|
||||
<Popconfirm placement="topRight" title={"当前分组下所有人员将会同时删除,确定删除么?"} onConfirm={async () => { delPerson(record.id); }} okText="确定" cancelText="取消" ><a > 删除 </a></Popconfirm>
|
||||
@ -117,7 +118,7 @@ const GroupPermission: React.FC<{}> = () => {
|
||||
// defaultCollapsed: false,//是否展开搜索条件
|
||||
optionRender: (searchConfig, formProps, dom) => [
|
||||
...dom.reverse(),
|
||||
<Button key="out" type="primary" onClick={() => insertSitePerson()}>
|
||||
!btnAuthority(["ebtp-site-admin"]) && <Button key="out" type="primary" onClick={() => insertSitePerson()}>
|
||||
新增
|
||||
</Button>,
|
||||
],
|
||||
@ -152,7 +153,7 @@ const GroupPermission: React.FC<{}> = () => {
|
||||
{
|
||||
isEditModalVisible ?
|
||||
<SiteGroupModal
|
||||
title={typename+"分组信息"}
|
||||
title={typename + "分组信息"}
|
||||
type={type}
|
||||
modalVisible={isEditModalVisible}
|
||||
values={editForm}
|
||||
|
@ -4,6 +4,7 @@ import { getUserList, saveSiteUser, delSiteUser, getGroupList } from '../service
|
||||
import { Button, Form, message, Spin, Popconfirm } from 'antd';
|
||||
import SiteUserModal from './SiteUserModal';
|
||||
import AuthorizeModal from './AuthorizeModal';
|
||||
import { btnAuthority } from '@/utils/authority';
|
||||
|
||||
|
||||
const UserPermission: React.FC<{}> = () => {
|
||||
@ -65,7 +66,7 @@ const UserPermission: React.FC<{}> = () => {
|
||||
// 是否关联分组:0-否,1-是
|
||||
if (record.groupStatus == '0') {
|
||||
return (
|
||||
<>
|
||||
!btnAuthority(["ebtp-site-admin"]) && <>
|
||||
<a onClick={() => setFormVals(record)}>编辑</a>
|
||||
<a onClick={() => setAuthorize(record)}>授权管理</a>
|
||||
<Popconfirm placement="topRight" title={"确定删除么?"} onConfirm={async () => { delUser(record.id); }} okText="确定" cancelText="取消" ><a > 删除 </a></Popconfirm>
|
||||
@ -73,13 +74,13 @@ const UserPermission: React.FC<{}> = () => {
|
||||
)
|
||||
} else if (record.groupStatus == '1') {
|
||||
return (
|
||||
<>
|
||||
!btnAuthority(["ebtp-site-admin"]) && <>
|
||||
<a onClick={() => setFormVals(record)}>编辑</a>
|
||||
<Popconfirm placement="topRight" title={"确定删除么?"} onConfirm={async () => { delUser(record.id); }} okText="确定" cancelText="取消" ><a > 删除 </a></Popconfirm>
|
||||
</>
|
||||
)
|
||||
} else {
|
||||
return(<></>)
|
||||
return (<></>)
|
||||
}
|
||||
}
|
||||
},
|
||||
@ -155,7 +156,7 @@ const UserPermission: React.FC<{}> = () => {
|
||||
// defaultCollapsed: false,//是否展开搜索条件
|
||||
optionRender: (searchConfig, formProps, dom) => [
|
||||
...dom.reverse(),
|
||||
<Button key="out" type="primary" onClick={() => insertSiteUser()}>
|
||||
!btnAuthority(["ebtp-site-admin"]) && <Button key="out" type="primary" onClick={() => insertSiteUser()}>
|
||||
新增
|
||||
</Button>,
|
||||
],
|
||||
@ -190,7 +191,7 @@ const UserPermission: React.FC<{}> = () => {
|
||||
{
|
||||
isEditModalVisible ?
|
||||
<SiteUserModal
|
||||
title={typename+"人员信息"}
|
||||
title={typename + "人员信息"}
|
||||
type={type}
|
||||
modalVisible={isEditModalVisible}
|
||||
groupList={groupList}
|
||||
|
@ -5,6 +5,7 @@ import React, { useRef, useState } from 'react';
|
||||
import { useHistory } from 'umi';
|
||||
import ViewModal from '../../ViewModal';
|
||||
import { getPage } from '../../service';
|
||||
import { btnAuthority } from '@/utils/authority';
|
||||
|
||||
/**
|
||||
* 在线监督列表
|
||||
@ -115,7 +116,7 @@ const OnlineSupervision: React.FC<{}> = () => {
|
||||
width: '9%',
|
||||
render: (_: any, record: any) =>
|
||||
(
|
||||
<>
|
||||
!btnAuthority(["ebtp-site-supervision"]) && <>
|
||||
<Button
|
||||
key="viewDetails"
|
||||
type="text"
|
||||
|
@ -5,6 +5,7 @@ import React, { useRef, useState } from 'react';
|
||||
import { useHistory } from 'umi';
|
||||
import ViewModal from '../../ViewModal';
|
||||
import { getPage } from '../../service';
|
||||
import { btnAuthority } from '@/utils/authority';
|
||||
|
||||
/**
|
||||
* 预约项目列表
|
||||
@ -113,7 +114,7 @@ const ReservedItems: React.FC<{}> = () => {
|
||||
width: '4.5%',
|
||||
render: (_: any, record: any) =>
|
||||
(
|
||||
<>
|
||||
!btnAuthority(["ebtp-site-supervision"]) && <>
|
||||
<Button
|
||||
key="viewDetails"
|
||||
type="text"
|
||||
@ -174,7 +175,7 @@ const ReservedItems: React.FC<{}> = () => {
|
||||
rowKey={"id"}
|
||||
/>
|
||||
</div>
|
||||
<ViewModal modalVisible = {visible} showStatus={false} onCancel = {()=> closeViewDetails()} ref = {viewModalRef}/>
|
||||
<ViewModal modalVisible={visible} showStatus={false} onCancel={() => closeViewDetails()} ref={viewModalRef} />
|
||||
</Spin>
|
||||
)
|
||||
}
|
||||
|
@ -1,10 +1,11 @@
|
||||
import { isNotEmpty } from '@/utils/CommonUtils';
|
||||
import ProTable, { ProColumns } from '@ant-design/pro-table';
|
||||
import { Button, Spin, message } from 'antd';
|
||||
import { Button, Spin, message, Card } from 'antd';
|
||||
import React, { useRef, useState } from 'react';
|
||||
import { useHistory } from 'umi';
|
||||
import ViewModal from '../ViewModal';
|
||||
import { getPage } from '../service';
|
||||
import { btnAuthority } from '@/utils/authority';
|
||||
|
||||
/**
|
||||
* 事后监督列表
|
||||
@ -117,7 +118,7 @@ const PostSupervision: React.FC<{}> = () => {
|
||||
width: '10%',
|
||||
render: (_: any, record: any) =>
|
||||
(
|
||||
<>
|
||||
!btnAuthority(["ebtp-after-supervision"]) && <>
|
||||
<Button
|
||||
key="viewDetails"
|
||||
type="text"
|
||||
@ -143,7 +144,7 @@ const PostSupervision: React.FC<{}> = () => {
|
||||
|
||||
return (
|
||||
<Spin spinning={spin}>
|
||||
<div className="zjl-entrust confirm">
|
||||
<Card className="zjl-entrust confirm">
|
||||
<ProTable
|
||||
columns={columns}
|
||||
options={false}
|
||||
@ -186,7 +187,7 @@ const PostSupervision: React.FC<{}> = () => {
|
||||
onReset={() => { pageDataSet({ pageNo: 1, pageSize: 10 }) }}
|
||||
rowKey={"id"}
|
||||
/>
|
||||
</div>
|
||||
</Card>
|
||||
<ViewModal modalVisible={visible} showStatus={true} onCancel={() => closeViewDetails()} ref={viewModalRef} />
|
||||
</Spin>
|
||||
)
|
||||
|
Reference in New Issue
Block a user