Commit a8ed6d6d authored by 卢均锐's avatar 卢均锐

Merge branch 'dev-srm' of http://10.0.0.22:3000/lingxi/lingxi-business-paltform into dev-srm

* 'dev-srm' of http://10.0.0.22:3000/lingxi/lingxi-business-paltform: feat: 采购计划管理页面完善
parents 19fa73b3 c8416811
......@@ -17,6 +17,22 @@ export const purchasePlanRoute = [
component: '@/pages/transaction/purchaseAbility/purchasePlan/demandPlanSummary'
},
{
/** 待汇总需求计划 - 详情 */
path: '/memberCenter/procurementAbility/purchasePlan/demandPlanSummary/preview',
name: '待新增需求计划',
component: '@/pages/transaction/purchaseAbility/purchasePlan/demand',
hideInMenu: true,
noMargin: true,
},
{
/** 待汇总需求计划 - 详情 */
path: '/memberCenter/procurementAbility/purchasePlan/demandPlanSummary/detail',
name: '待新增需求计划',
component: '@/pages/transaction/purchaseAbility/purchasePlan/demand',
hideInMenu: true,
noMargin: true,
},
{
/** 采购计划查询 */
path: '/memberCenter/procurementAbility/purchasePlan/purchasePlanSearch',
name: '采购计划查询',
......
......@@ -14,7 +14,7 @@ export interface IProps {
title: string,
visible: boolean,
id: number,
modalType: 'audit' | 'abandon' | 'date' | 'next' | 'key' | 'discard' | 'planAudit',
modalType: 'audit' | 'abandon' | 'date' | 'next' | 'key' | 'discard' | 'planAudit' | 'billBack',
onCancel?: () => void,
onOk?: () => void,
fetch?: () => Promise<unknown>,
......@@ -72,7 +72,17 @@ const ModalOperate: React.FC<IProps> = (props: any) => {
return current && current <= moment().startOf('day');
}
const modalText = modalType === 'audit' ? '审核不通过原因' : '作废原因';
const modalText = () => {
switch (modalType) {
case 'audit':
case 'planAudit':
return '审核不通过原因';
case 'billBack':
return '退回原因';
default:
return '作废原因';
}
}
const modalNode = () => {
switch (modalType) {
case 'audit':
......@@ -205,6 +215,9 @@ const ModalOperate: React.FC<IProps> = (props: any) => {
} else if (modalType === 'planAudit') {
params.status = value.status;
value.status !== 1 && (params.cause = value.cause);
} else if (modalType === 'billBack') {
params.status = 0;
params.cause = value.cause;
} else {
params.password = value.password;
}
......@@ -260,9 +273,9 @@ const ModalOperate: React.FC<IProps> = (props: any) => {
}}
>
{modalNode()}
{(modalType === 'audit' || modalType === 'abandon' || modalType === 'discard' || modalType === 'planAudit')
{(modalType === 'audit' || modalType === 'abandon' || modalType === 'discard' || modalType === 'planAudit' || modalType === 'billBack')
&& (<Field
title={modalText}
title={modalText()}
name={causeName(modalType)}
x-component="TextArea"
required
......
......@@ -15,7 +15,7 @@ const { Text } = Typography;
const DemandPlanAdded = () => {
const ref = useRef<any>({});
const format = (text) => {
return <>{moment(text).format("YYYY-MM-DD HH:mm:ss")}</>
return <>{moment(text).format("YYYY-MM-DD")}</>
}
const columns: ColumnType<any>[] = [{
title: '需求计划编号/摘要',
......
......@@ -15,7 +15,7 @@ const { Text } = Typography;
const DemandPlanOne = () => {
console.log('待新增采购需求单');
const format = (text) => {
return <>{moment(text).format("YYYY-MM-DD HH:mm:ss")}</>
return <>{moment(text).format("YYYY-MM-DD")}</>
}
const columns: ColumnType<any>[] = [{
title: '需求计划编号/摘要',
......@@ -33,8 +33,8 @@ const DemandPlanOne = () => {
dataIndex: 'startTime',
render: (text: any, record: any) => (
<Space direction='vertical'>
<Text><PlayCircleOutlined />{format(text)}</Text>
<Text><PoweroffOutlined />{format(record.endTime)}</Text>
<Text><PlayCircleOutlined style={{ marginRight: 5 }} />{format(text)}</Text>
<Text><PoweroffOutlined style={{ marginRight: 5 }} />{format(record.endTime)}</Text>
</Space>
)
}, {
......
......@@ -15,7 +15,7 @@ const { Text } = Typography;
const DemandPlanSearch = () => {
console.log('待新增采购需求单');
const format = (text) => {
return <>{moment(text).format("YYYY-MM-DD HH:mm:ss")}</>
return <>{moment(text).format("YYYY-MM-DD")}</>
}
const columns: ColumnType<any>[] = [{
title: '需求计划编号/摘要',
......@@ -33,8 +33,8 @@ const DemandPlanSearch = () => {
dataIndex: 'startTime',
render: (text: any, record: any) => (
<Space direction='vertical'>
<Text><PlayCircleOutlined />{format(text)}</Text>
<Text><PoweroffOutlined />{format(record.endTime)}</Text>
<Text><PlayCircleOutlined style={{ marginRight: 5 }} />{format(text)}</Text>
<Text><PoweroffOutlined style={{ marginRight: 5 }} />{format(record.endTime)}</Text>
</Space>
)
}, {
......
......@@ -14,7 +14,7 @@ const { Text } = Typography;
const DemandPlanSubmit = () => {
const ref = useRef<any>({});
const format = (text) => {
return <>{moment(text).format("YYYY-MM-DD HH:mm:ss")}</>
return <>{moment(text).format("YYYY-MM-DD")}</>
}
const columns: ColumnType<any>[] = [{
title: '需求计划编号/摘要',
......@@ -32,8 +32,8 @@ const DemandPlanSubmit = () => {
dataIndex: 'startTime',
render: (text: any, record: any) => (
<Space direction='vertical'>
<Text><PlayCircleOutlined />{format(text)}</Text>
<Text><PoweroffOutlined />{format(record.endTime)}</Text>
<Text><PlayCircleOutlined style={{ marginRight: 5 }} />{format(text)}</Text>
<Text><PoweroffOutlined style={{ marginRight: 5 }} />{format(record.endTime)}</Text>
</Space>
)
}, {
......
......@@ -15,7 +15,7 @@ const { Text } = Typography;
const DemanPlanTwo = () => {
console.log('待新增采购需求单');
const format = (text) => {
return <>{moment(text).format("YYYY-MM-DD HH:mm:ss")}</>
return <>{moment(text).format("YYYY-MM-DD")}</>
}
const columns: ColumnType<any>[] = [{
title: '需求计划编号/摘要',
......@@ -33,8 +33,8 @@ const DemanPlanTwo = () => {
dataIndex: 'startTime',
render: (text: any, record: any) => (
<Space direction='vertical'>
<Text><PlayCircleOutlined />{format(text)}</Text>
<Text><PoweroffOutlined />{format(record.endTime)}</Text>
<Text><PlayCircleOutlined style={{ marginRight: 5 }} />{format(text)}</Text>
<Text><PoweroffOutlined style={{ marginRight: 5 }} />{format(record.endTime)}</Text>
</Space>
)
}, {
......
import React, { Fragment, useEffect, useState } from 'react';
import { Badge, Button } from 'antd';
import { history } from 'umi';
import { PublicApi } from '@/services/api';
import { Context } from '../../components/detail/components/context';
import PeripheralLayout from '../../components/detail';
import ProgressLayout from '../../components/detail/components/progressLayout';
import BasicLayout from '../../components/detail/components/basicLayout';
import RecordLyout from '../../components/detail/components/recordLyout';
import moment from 'moment';
import {
OFFTER_INTERNALSTATE_COLOR
} from '../../constants';
import { MinusCircleOutlined } from '@ant-design/icons';
import ModalOperate from '../../components/modalOperate';
import DemandPlanMaterialLayout from '../../components/detail/components/demandPlanMaterialLayout';
const TABLINK = [
{ id: 'progressLayout', title: '流转进度' },
{ id: 'basicLayout', title: '基本信息' },
{ id: 'materialLayout', title: '采购物料' },
{ id: 'recordLyout', title: '流转记录' },
]
const DemandDetailed = () => {
const format = (text) => {
return <>{moment(text).format("YYYY-MM-DD HH:mm:ss")}</>
}
const {
query: {
id
},
pathname,
} = history.location;
const [path] = useState(pathname.split('/')[pathname.split('/').length - 1]);
const [visible, setVisible] = useState<boolean>(false);
const [dataSource, setDataSource] = useState<any>({});
const [basicEffect, setBasicEffect] = useState<any>([]);
const handleBasicEffect = (data: any) => {
setBasicEffect([
{
col: [
{ label: '需求计划编号', extra: data.needPlanNo },
{ label: '需求计划摘要', extra: data.summary },
{ label: '内部状态', extra: <Badge status={OFFTER_INTERNALSTATE_COLOR[data.innerStatus]} text={data.innerStatusName} /> },
]
},
{
col: [
{ label: '需求计划开始', extra: format(data.startTime) },
{ label: '需求计划截止', extra: format(data.endTime) },
]
},
{
col: [
{ label: '编制部门', extra: data.department },
{ label: '编制人', extra: data.userName },
{ label: '编制时间', extra: format(data.createTime) },
]
},
])
}
const fetchDataSource = async () => {
const params = {
id,
}
await PublicApi.getPurchaseNeedPlanDetails({ ...params }).then(res => {
if (res.code !== 1000) {
history.goBack();
return;
}
let { data } = res;
let interiorLogs: any = []
let interiorLogStates: any = []
data.innerTaskList.forEach((item: any) => {
interiorLogStates.push({
state: item.step,
stateName: null,
isExecute: item.isExecute,
operationalProcess: item.taskName,
roleName: item.roleName,
})
})
data.innerRecords.forEach((item: any) => {
interiorLogs.push({
auditOpinion: item.opinion,
createMemberId: item.memberId,
createRoleId: item.needPlanId,
createTime: item.operateTime,
department: item.department,
id: item.id,
memberId: null,
memberRoleId: null,
operation: item.operate,
position: '',
purchaseInquiryId: null,
roleName: item.operator,
state: item.step + 1,
step: item.step,
})
})
data.interiorLogs = interiorLogs;
data.interiorLogStates = interiorLogStates;
setDataSource(data);
handleBasicEffect(data);
})
}
useEffect(() => {
fetchDataSource();
}, [])
return (
<Context.Provider value={dataSource}>
<PeripheralLayout
no={dataSource.needPlanNo}
detail={dataSource.summary}
tabLink={TABLINK}
effect={
<>
{path === 'detail'
&& (
<Button
onClick={() => setVisible(true)}
type='primary'
>
<MinusCircleOutlined />
单据退回
</Button>
)}
</>
}
components={
<Fragment>
<ProgressLayout />
<BasicLayout effect={basicEffect} />
<DemandPlanMaterialLayout
id={id}
fetch={PublicApi.getPurchaseNeedPlanNeedPlanDetail}
/>
<RecordLyout />
</Fragment>
}
/>
<ModalOperate
id={id}
title="单据退回"
modalType="billBack"
visible={visible}
fetch={PublicApi.postPurchaseNeedPlanSendBack}
onCancel={() => setVisible(false)}
onOk={() => history.goBack()}
/>
</Context.Provider>
)
}
export default DemandDetailed;
import React from 'react';
import React, { useState, useRef } from 'react';
import { history } from 'umi';
import Table from '../../components/table'
import { ColumnType } from 'antd/lib/table/interface';
import EyePreview from '@/components/EyePreview';
import moment from 'moment';
import { PublicApi } from '@/services/api';
import { Row, Col, Button, Badge, Space, Typography } from 'antd';
import { Row, Col, Button, Badge, Space, Typography, Modal, message } from 'antd';
import {
OFFTER_INTERNALSTATE_COLOR,
} from '../../constants';
import { PlayCircleOutlined, PlusOutlined, PoweroffOutlined } from '@ant-design/icons';
import { PlayCircleOutlined, PoweroffOutlined } from '@ant-design/icons';
import { isEmpty } from 'lodash';
const { Text } = Typography;
const DemandPlanSummary = () => {
console.log('待新增采购需求单');
const ref = useRef<any>({});
const [idList, setIdList] = useState<Array<number>>([]);
const [visible, setVisible] = useState<boolean>(false);
const [confirmLoading, setConfirmLoading] = useState<boolean>(false);
const format = (text) => {
return <>{moment(text).format("YYYY-MM-DD HH:mm:ss")}</>
return <>{moment(text).format("YYYY-MM-DD")}</>
}
const columns: ColumnType<any>[] = [{
title: '需求计划编号/摘要',
......@@ -23,8 +27,8 @@ const DemandPlanSummary = () => {
dataIndex: 'needPlanNo',
render: (text: any, record: any) => (
<Space direction='vertical'>
<EyePreview url={`/memberCenter/procurementAbility/offter/auditOffterOne/view?id=${record.id}&number=${record.quotedPriceNo}&turn=${record.turn}`}>{text}</EyePreview>
<Text type='secondary'>{record.summary}</Text>
<EyePreview url={`/memberCenter/procurementAbility/purchasePlan/demandPlanSummary/preview?id=${record.id}`}>{text}</EyePreview>
<Text>{record.summary}</Text>
</Space>
)
}, {
......@@ -33,8 +37,8 @@ const DemandPlanSummary = () => {
dataIndex: 'startTime',
render: (text: any, record: any) => (
<Space direction='vertical'>
<Text type='secondary'><PlayCircleOutlined />{format(text)}</Text>
<Text type='secondary'><PoweroffOutlined />{format(record.endTime)}</Text>
<Text><PlayCircleOutlined style={{ marginRight: 5 }} />{format(text)}</Text>
<Text><PoweroffOutlined style={{ marginRight: 5 }} />{format(record.endTime)}</Text>
</Space>
)
}, {
......@@ -49,7 +53,7 @@ const DemandPlanSummary = () => {
title: '编制时间',
key: 'createTime',
dataIndex: 'createTime',
render: (text: any, record: any) => <Text type='secondary'>{format(text)}</Text>
render: (text: any, record: any) => <Text>{format(text)}</Text>
}, {
title: '内部状态',
key: 'innerStatus',
......@@ -63,34 +67,71 @@ const DemandPlanSummary = () => {
<>
<Button
type='link'
onClick={() => history.push(`/memberCenter/procurementAbility/offter/auditOffterOne/detail?id=${record.id}&number=${record.quotedPriceNo}`)}
onClick={() => history.push(`/memberCenter/procurementAbility/purchasePlan/demandPlanSummary/detail?id=${record.id}`)}
>
审核
退回
</Button>
</>
)
}];
const handleCancel = () => {
setVisible(false)
}
const fetchSubmitBatch = async () => {
if (isEmpty(idList)) {
message.warning('请勾选要汇总生成订单');
return;
}
setConfirmLoading(true);
await PublicApi.postPurchaseNeedPlanCollect({ idList }).then(res => {
if (res.code !== 1000) {
setConfirmLoading(false);
return
}
ref.current.reload();
setIdList([]);
setVisible(false);
setConfirmLoading(false);
})
}
return (
<Table
schemaType="DEMANDPLANADDED_SECHEMA"
columns={columns}
effects="needPlanNo"
fetch={PublicApi.getPurchaseNeedPlanList}
controllerBtns={
<Row>
<Col span={6}>
<Button
onClick={() => history.push('/memberCenter/procurementAbility/purchaseInquiry/add')}
type="primary"
icon={<PlusOutlined />}
>
新建
<>
<Table
selectedRow
reload={ref}
fetchRowkeys={(e) => setIdList(e)}
schemaType="DEMANDPLANADDED_SECHEMA"
columns={columns}
effects="needPlanNo"
fetch={PublicApi.getPurchaseNeedPlanToBeCollectList}
controllerBtns={
<Row>
<Col span={6}>
<Button
disabled={idList.length === 0}
onClick={() => setVisible(true)}
>
汇总生成采购计划
</Button>
</Col>
</Row>
}
/>
</Col>
</Row>
}
/>
<Modal
title="汇总生成采购计划"
visible={visible}
onOk={fetchSubmitBatch}
confirmLoading={confirmLoading}
onCancel={handleCancel}
>
<p>
是否将选择的需求计划汇总生成采购计划?生成采购计划后如需重新生成,需要先删除已生成的采购计划
</p>
</Modal>
</>
)
}
export default DemandPlanSummary
......@@ -13,9 +13,8 @@ import { PlayCircleOutlined, PoweroffOutlined } from '@ant-design/icons';
const { Text } = Typography;
const PurchasePlanOne = () => {
console.log('待新增采购需求单');
const format = (text) => {
return <>{moment(text).format("YYYY-MM-DD HH:mm:ss")}</>
return <>{moment(text).format("YYYY-MM-DD")}</>
}
const columns: ColumnType<any>[] = [{
title: '采购计划编号/摘要',
......@@ -24,7 +23,7 @@ const PurchasePlanOne = () => {
render: (text: any, record: any) => (
<Space direction='vertical'>
<EyePreview url={`/memberCenter/procurementAbility/offter/auditOffterOne/view?id=${record.id}&number=${record.quotedPriceNo}&turn=${record.turn}`}>{text}</EyePreview>
<Text type='secondary'>{record.summary}</Text>
<Text>{record.summary}</Text>
</Space>
)
}, {
......@@ -33,8 +32,8 @@ const PurchasePlanOne = () => {
dataIndex: 'startTime',
render: (text: any, record: any) => (
<Space direction='vertical'>
<Text type='secondary'><PlayCircleOutlined />{format(text)}</Text>
<Text type='secondary'><PoweroffOutlined />{format(record.endTime)}</Text>
<Text><PlayCircleOutlined style={{ marginRight: 5 }} />{format(text)}</Text>
<Text><PoweroffOutlined style={{ marginRight: 5 }} />{format(record.endTime)}</Text>
</Space>
)
}, {
......@@ -49,7 +48,7 @@ const PurchasePlanOne = () => {
title: '编制时间',
key: 'createTime',
dataIndex: 'createTime',
render: (text: any, record: any) => <Text type='secondary'>{format(text)}</Text>
render: (text: any, record: any) => <Text>{format(text)}</Text>
}, {
title: '内部状态',
key: 'innerStatus',
......@@ -76,7 +75,7 @@ const PurchasePlanOne = () => {
schemaType="PURCHASEPLAN_SECHEMA"
columns={columns}
effects="purchasePlanNo"
fetch={PublicApi.getPurchasePurchasePlanList}
fetch={PublicApi.getPurchasePurchasePlanToBeFirstExamList}
/>
)
}
......
......@@ -13,9 +13,8 @@ import { PlayCircleOutlined, PoweroffOutlined } from '@ant-design/icons';
const { Text } = Typography;
const PurchasePlanPerform = () => {
console.log('待新增采购需求单');
const format = (text) => {
return <>{moment(text).format("YYYY-MM-DD HH:mm:ss")}</>
return <>{moment(text).format("YYYY-MM-DD")}</>
}
const columns: ColumnType<any>[] = [{
title: '采购计划编号/摘要',
......@@ -24,7 +23,7 @@ const PurchasePlanPerform = () => {
render: (text: any, record: any) => (
<Space direction='vertical'>
<EyePreview url={`/memberCenter/procurementAbility/offter/auditOffterOne/view?id=${record.id}&number=${record.quotedPriceNo}&turn=${record.turn}`}>{text}</EyePreview>
<Text type='secondary'>{record.summary}</Text>
<Text>{record.summary}</Text>
</Space>
)
}, {
......@@ -33,8 +32,8 @@ const PurchasePlanPerform = () => {
dataIndex: 'startTime',
render: (text: any, record: any) => (
<Space direction='vertical'>
<Text type='secondary'><PlayCircleOutlined />{format(text)}</Text>
<Text type='secondary'><PoweroffOutlined />{format(record.endTime)}</Text>
<Text><PlayCircleOutlined style={{ marginRight: 5 }} />{format(text)}</Text>
<Text><PoweroffOutlined style={{ marginRight: 5 }} />{format(record.endTime)}</Text>
</Space>
)
}, {
......@@ -49,7 +48,7 @@ const PurchasePlanPerform = () => {
title: '编制时间',
key: 'createTime',
dataIndex: 'createTime',
render: (text: any, record: any) => <Text type='secondary'>{format(text)}</Text>
render: (text: any, record: any) => <Text>{format(text)}</Text>
}, {
title: '内部状态',
key: 'innerStatus',
......@@ -76,7 +75,7 @@ const PurchasePlanPerform = () => {
schemaType="PURCHASEPLAN_SECHEMA"
columns={columns}
effects="purchasePlanNo"
fetch={PublicApi.getPurchasePurchasePlanList}
fetch={PublicApi.getPurchasePurchasePlanToBeExecuteList}
/>
)
}
......
......@@ -13,9 +13,8 @@ import { PlayCircleOutlined, PoweroffOutlined } from '@ant-design/icons';
const { Text } = Typography;
const PurchasePlanSearch = () => {
console.log('待新增采购需求单');
const format = (text) => {
return <>{moment(text).format("YYYY-MM-DD HH:mm:ss")}</>
return <>{moment(text).format("YYYY-MM-DD")}</>
}
const columns: ColumnType<any>[] = [{
title: '采购计划编号/摘要',
......@@ -24,7 +23,7 @@ const PurchasePlanSearch = () => {
render: (text: any, record: any) => (
<Space direction='vertical'>
<EyePreview url={`/memberCenter/procurementAbility/offter/auditOffterOne/view?id=${record.id}&number=${record.quotedPriceNo}&turn=${record.turn}`}>{text}</EyePreview>
<Text type='secondary'>{record.summary}</Text>
<Text>{record.summary}</Text>
</Space>
)
}, {
......@@ -33,8 +32,8 @@ const PurchasePlanSearch = () => {
dataIndex: 'startTime',
render: (text: any, record: any) => (
<Space direction='vertical'>
<Text type='secondary'><PlayCircleOutlined />{format(text)}</Text>
<Text type='secondary'><PoweroffOutlined />{format(record.endTime)}</Text>
<Text><PlayCircleOutlined style={{ marginRight: 5 }} />{format(text)}</Text>
<Text><PoweroffOutlined style={{ marginRight: 5 }} />{format(record.endTime)}</Text>
</Space>
)
}, {
......@@ -49,34 +48,20 @@ const PurchasePlanSearch = () => {
title: '编制时间',
key: 'createTime',
dataIndex: 'createTime',
render: (text: any, record: any) => <Text type='secondary'>{format(text)}</Text>
render: (text: any, record: any) => <Text>{format(text)}</Text>
}, {
title: '内部状态',
key: 'innerStatus',
dataIndex: 'innerStatus',
render: (text: any, record: any) => <Badge status={OFFTER_INTERNALSTATE_COLOR[text]} text={record.innerStatusName} />
}, {
title: '操作',
key: 'operate',
dataIndex: 'operate',
render: (text: any, record: any) => (
<>
<Button
type='link'
onClick={() => history.push(`/memberCenter/procurementAbility/offter/auditOffterOne/detail?id=${record.id}&number=${record.quotedPriceNo}`)}
>
审核
</Button>
</>
)
}];
},];
return (
<Table
schemaType="DEMANDPLAN_SECHEMA"
columns={columns}
effects="needPlanNo"
fetch={PublicApi.getPurchasePurchasePlanList}
fetch={PublicApi.getPurchasePurchasePlanAllList}
/>
)
}
......
......@@ -13,9 +13,8 @@ import { PlayCircleOutlined, PoweroffOutlined } from '@ant-design/icons';
const { Text } = Typography;
const PurchasePlanSubmit = () => {
console.log('待新增采购需求单');
const format = (text) => {
return <>{moment(text).format("YYYY-MM-DD HH:mm:ss")}</>
return <>{moment(text).format("YYYY-MM-DD")}</>
}
const columns: ColumnType<any>[] = [{
title: '采购计划编号/摘要',
......@@ -24,7 +23,7 @@ const PurchasePlanSubmit = () => {
render: (text: any, record: any) => (
<Space direction='vertical'>
<EyePreview url={`/memberCenter/procurementAbility/offter/auditOffterOne/view?id=${record.id}&number=${record.quotedPriceNo}&turn=${record.turn}`}>{text}</EyePreview>
<Text type='secondary'>{record.summary}</Text>
<Text>{record.summary}</Text>
</Space>
)
}, {
......@@ -33,8 +32,8 @@ const PurchasePlanSubmit = () => {
dataIndex: 'startTime',
render: (text: any, record: any) => (
<Space direction='vertical'>
<Text type='secondary'><PlayCircleOutlined />{format(text)}</Text>
<Text type='secondary'><PoweroffOutlined />{format(record.endTime)}</Text>
<Text><PlayCircleOutlined style={{ marginRight: 5 }} />{format(text)}</Text>
<Text><PoweroffOutlined style={{ marginRight: 5 }} />{format(record.endTime)}</Text>
</Space>
)
}, {
......@@ -49,7 +48,7 @@ const PurchasePlanSubmit = () => {
title: '编制时间',
key: 'createTime',
dataIndex: 'createTime',
render: (text: any, record: any) => <Text type='secondary'>{format(text)}</Text>
render: (text: any, record: any) => <Text>{format(text)}</Text>
}, {
title: '内部状态',
key: 'innerStatus',
......@@ -76,7 +75,7 @@ const PurchasePlanSubmit = () => {
schemaType="PURCHASEPLAN_SECHEMA"
columns={columns}
effects="purchasePlanNo"
fetch={PublicApi.getPurchasePurchasePlanList}
fetch={PublicApi.getPurchasePurchasePlanToBeSubmitExamList}
/>
)
}
......
......@@ -13,9 +13,8 @@ import { PlayCircleOutlined, PoweroffOutlined } from '@ant-design/icons';
const { Text } = Typography;
const PurchasePlanTwo = () => {
console.log('待新增采购需求单');
const format = (text) => {
return <>{moment(text).format("YYYY-MM-DD HH:mm:ss")}</>
return <>{moment(text).format("YYYY-MM-DD")}</>
}
const columns: ColumnType<any>[] = [{
title: '采购计划编号/摘要',
......@@ -24,7 +23,7 @@ const PurchasePlanTwo = () => {
render: (text: any, record: any) => (
<Space direction='vertical'>
<EyePreview url={`/memberCenter/procurementAbility/offter/auditOffterOne/view?id=${record.id}&number=${record.quotedPriceNo}&turn=${record.turn}`}>{text}</EyePreview>
<Text type='secondary'>{record.summary}</Text>
<Text>{record.summary}</Text>
</Space>
)
}, {
......@@ -33,8 +32,8 @@ const PurchasePlanTwo = () => {
dataIndex: 'startTime',
render: (text: any, record: any) => (
<Space direction='vertical'>
<Text type='secondary'><PlayCircleOutlined />{format(text)}</Text>
<Text type='secondary'><PoweroffOutlined />{format(record.endTime)}</Text>
<Text><PlayCircleOutlined style={{ marginRight: 5 }} />{format(text)}</Text>
<Text><PoweroffOutlined style={{ marginRight: 5 }} />{format(record.endTime)}</Text>
</Space>
)
}, {
......@@ -49,7 +48,7 @@ const PurchasePlanTwo = () => {
title: '编制时间',
key: 'createTime',
dataIndex: 'createTime',
render: (text: any, record: any) => <Text type='secondary'>{format(text)}</Text>
render: (text: any, record: any) => <Text>{format(text)}</Text>
}, {
title: '内部状态',
key: 'innerStatus',
......@@ -76,7 +75,7 @@ const PurchasePlanTwo = () => {
schemaType="PURCHASEPLAN_SECHEMA"
columns={columns}
effects="purchasePlanNo"
fetch={PublicApi.getPurchasePurchasePlanList}
fetch={PublicApi.getPurchasePurchasePlanToBeSecondExamList}
/>
)
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment