Commit a32d2cbe authored by xiexiuxing's avatar xiexiuxing

flx:合同代码合并miju

parent ff0162b6
......@@ -33,6 +33,7 @@ const Examine: React.FC<Iprops> = ({
}) => {
const [isPass, setIsAllMember] = useState(1)
const [state, setstate] = useState<any>(false);
const [contractUrl, setcontractUrl] = useState('');
/* 设置选中值 */
const handleIsAllMemberChange = (v: any) => {
setIsAllMember(v.target.value)
......@@ -91,11 +92,13 @@ const Examine: React.FC<Iprops> = ({
/* 合同协同签订-签订合同 */
case 'Signacontract':
fn = postContractManageSign
values.contractUrl = contractUrl;
values.contractId = applyId;
break;
}
console.log(values)
const msg = message.loading({
content: intl.formatMessage({id: 'contract.zhengzaicaozuo'}),
content: intl.formatMessage({ id: 'contract.zhengzaicaozuo' }),
duration: 0,
});
fn(values).then(res => {
......@@ -136,9 +139,10 @@ const Examine: React.FC<Iprops> = ({
},
onChange(info) {
if (info.file.response) {
const { code } = info.file.response;
const { code, data: { url } } = info.file.response;
console.log(code);
message.info(intl.formatMessage({id: 'contract.shangchuanchenggong'}));
setcontractUrl(url)
message.info(intl.formatMessage({ id: 'contract.shangchuanchenggong' }));
console.log(info.file)
setstate(true);
}
......@@ -148,12 +152,12 @@ const Examine: React.FC<Iprops> = ({
}
if (info.file.status === 'done') {
} else if (info.file.status === 'error') {
message.error(`${info.file.name} ${intl.formatMessage({id: 'contract.shangchuanshibai'})}`);
message.error(`${info.file.name} ${intl.formatMessage({ id: 'contract.shangchuanshibai' })}`);
}
},
beforeUpload(file) {
if (file.size / 1024 / 1024 > 20) {
message.warning(intl.formatMessage({id: 'contract.fujiandaxiaochaoguo20M'}));
message.warning(intl.formatMessage({ id: 'contract.fujiandaxiaochaoguo20M' }));
return Promise.reject();
}
},
......@@ -161,13 +165,14 @@ const Examine: React.FC<Iprops> = ({
const uploadNode = () => {
return (
<div>
<p style={{ paddingTop: 10, paddingBottom: 10, }}>{intl.formatMessage({id: 'contract.zhizhihetongyifangyi'})}</p>
<p style={{ paddingTop: 10, paddingBottom: 10, }}>{intl.formatMessage({ id: 'contract.zhizhihetongyifangyi' })}</p>
<Row style={{ marginBottom: 30, }}>
<Col>
<Upload
{...uploadProps}
maxCount={1}
>
<Button icon={<UploadOutlined />}>{intl.formatMessage({id: 'contract.shangchuanfujian'})}</Button>
<Button icon={<UploadOutlined />}>{intl.formatMessage({ id: 'contract.shangchuanfujian' })}</Button>
</Upload>
</Col>
</Row>
......@@ -176,7 +181,7 @@ const Examine: React.FC<Iprops> = ({
}
return (
<div>
<Modal footer={null} title={intl.formatMessage({id: 'contract.tijiaoshenhe'})} visible={ExamineFlag} onCancel={() => fetchData('onCancel')}>
<Modal footer={null} title={intl.formatMessage({ id: 'contract.tijiaoshenhe' })} visible={ExamineFlag} onCancel={() => fetchData('onCancel')}>
<Form
name="basic"
form={form}
......@@ -185,20 +190,20 @@ const Examine: React.FC<Iprops> = ({
onFinishFailed={onFinishFailed}
>
{type === 'Signacontract' ? uploadNode() : null}
<Form.Item name="isPass" label="" rules={[{ required: true, message: intl.formatMessage({id: 'contract.qingxuanzetongguofangshi'}) }]} initialValue={isPass} >
<Form.Item name="isPass" label="" rules={[{ required: true, message: intl.formatMessage({ id: 'contract.qingxuanzetongguofangshi' }) }]} initialValue={isPass} >
<Radio.Group onChange={handleIsAllMemberChange}>
<Radio value={1}>{agreeText}</Radio>
<Radio value={0}>{disagree}</Radio>
</Radio.Group>
</Form.Item>
<Form.Item label={isPass ? intl.formatMessage({id: 'contract.shenhetongguoyuanyin'}) : intl.formatMessage({id: 'contract.shenbuhetongguoyuanyin'})} rules={[{ required: true, message: intl.formatMessage({id: 'contract.qingxuanzezuofeiriqi'}) }]}>
<Form.Item label={isPass ? intl.formatMessage({ id: 'contract.shenhetongguoyuanyin' }) : intl.formatMessage({ id: 'contract.shenbuhetongguoyuanyin' })} rules={[{ required: true, message: intl.formatMessage({ id: 'contract.qingxuanzezuofeiriqi' }) }]}>
</Form.Item>
<Form.Item label='' name="opinion" rules={[{ required: isPass ? false : true, message: intl.formatMessage({id: 'contract.shenhetongguoyijian'}) }]}>
<TextArea placeholder={intl.formatMessage({id: 'contract.zaicishurunideyuanyin'})} maxLength={120} />
<Form.Item label='' name="opinion" rules={[{ required: isPass ? false : true, message: intl.formatMessage({ id: 'contract.shenhetongguoyijian' }) }]}>
<TextArea placeholder={intl.formatMessage({ id: 'contract.zaicishurunideyuanyin' })} maxLength={120} />
</Form.Item>
<div style={{ display: 'flex', justifyContent: 'flex-end' }}>
<Button onClick={() => fetchData('onCancel')} style={{ marginRight: 10 }}>{intl.formatMessage({id: 'contract.quxiao'})}</Button>
<Button type="primary" htmlType="submit">{intl.formatMessage({id: 'contract.baocun'})}</Button>
<Button onClick={() => fetchData('onCancel')} style={{ marginRight: 10 }}>{intl.formatMessage({ id: 'contract.quxiao' })}</Button>
<Button type="primary" htmlType="submit">{intl.formatMessage({ id: 'contract.baocun' })}</Button>
</div>
</Form>
</Modal>
......@@ -206,8 +211,8 @@ const Examine: React.FC<Iprops> = ({
)
}
Examine.defaultProps = {
agreeText: intl.formatMessage({id: 'contract.tongguo'}),
disagree: intl.formatMessage({id: 'contract.butongguo'}),
agreeText: intl.formatMessage({ id: 'contract.tongguo' }),
disagree: intl.formatMessage({ id: 'contract.butongguo' }),
uploadNode: null
}
export default Examine;
import React, { useEffect, useState, useRef } from 'react';
import { Anchor, Table,DatePicker, Input, Space, Typography, message, Button } from 'antd';
import { Anchor, Table, DatePicker, Input, Space, Typography, message, Button } from 'antd';
import style from './index.less';
import { ArrowLeftOutlined } from '@ant-design/icons';
const { Link } = Anchor;
......@@ -19,10 +19,10 @@ const intl = getIntl();
const PAGE_SIZE = 8;
const { RangePicker } = DatePicker
type FromProps = {
orderNo:string,
orderAbstract:string,
startTime:string,
endTime:string,
orderNo: string,
orderAbstract: string,
startTime: string,
endTime: string,
}
const Details = (props: any) => {
const ref = useRef({});
......@@ -51,10 +51,10 @@ const Details = (props: any) => {
const [basics, setbasics] = useState({})
const [contractAbstract, setcontractAbstract] = useState();
const [tabPane] = useState([
{ id: 'process', title: intl.formatMessage({id: 'contract.jibenliucheng'}) },
{ id: 'conditions', title: intl.formatMessage({id: 'contract.fukuanjihua'}) },
{ id: 'docking', title: intl.formatMessage({id: 'contract.zhixingqingkuang'}) },
{ id: 'record', title: intl.formatMessage({id: 'contract.qingkuantongji'}) },
{ id: 'process', title: intl.formatMessage({ id: 'contract.jibenliucheng' }) },
{ id: 'conditions', title: intl.formatMessage({ id: 'contract.fukuanjihua' }) },
{ id: 'docking', title: intl.formatMessage({ id: 'contract.zhixingqingkuang' }) },
{ id: 'record', title: intl.formatMessage({ id: 'contract.qingkuantongji' }) },
])
const [targetOffset, setTargetOffset] = useState<number | undefined>(undefined);
/* 单据总金额 */
......@@ -105,29 +105,29 @@ const Details = (props: any) => {
const [selectRow, setSelectRow] = useState<any[]>([]) // 模态框选择的行数据
const [selectedRowKeys, setSelectedRowKeys] = useState<Array<string>>([])
// 设置提交数据
const [from,setfrom] = useState<FromProps>({
orderNo :'',
orderAbstract:'',
startTime:'',
endTime:'',
const [from, setfrom] = useState<FromProps>({
orderNo: '',
orderAbstract: '',
startTime: '',
endTime: '',
})
// 设置搜索的值
const setvalue = (e,name)=>{
const setvalue = (e, name) => {
const value = e.target.value;
from[name] = value;
console.log(value,name,from)
setfrom({...from})
console.log(value, name, from)
setfrom({ ...from })
}
const onChange = (value, dateString) => {
console.log(moment(value[0]).format('YYYY-MM-DD HH:mm:ss') ,'111')
console.log(moment(value[0]).format('YYYY-MM-DD HH:mm:ss'), '111')
// moment(value).format('YYYY-MM-DD HH:mm:ss') : ''
from.startTime = moment(value[0]).format('YYYY-MM-DD HH:mm:ss')
from.endTime = moment(value[1]).format('YYYY-MM-DD HH:mm:ss')
console.log(from)
setfrom(from)
}
const query = ()=>{
const query = () => {
const data = {
contractId,
...from,
......@@ -139,7 +139,7 @@ const Details = (props: any) => {
/* 获取详情的数据 */
const getDetail = () => {
console.log(contractId)
getContractExecuteGetDetail({ contractId }).then((res:any) => {
getContractExecuteGetDetail({ contractId }).then((res: any) => {
if (res.code === 1000) {
let { basics, payPlanList } = res.data
setcontractNo(basics.contractNo)
......@@ -147,19 +147,19 @@ const Details = (props: any) => {
setbasics(basics)
const basicInfo = {
col1: [
{ label: intl.formatMessage({id: 'contract.hetongbianhao'}), extra: basics.contractNo ? basics.contractNo : '', url: `/memberCenter/contract/manage/QueryList/QueryListdetails?contractId=${basics.id}` },
{ label: intl.formatMessage({id: 'contract.hetongzhaiyao'}), extra: basics.contractAbstract ? basics.contractAbstract : '' },
{ label: intl.formatMessage({id: 'contract.waibuzhuangtai'}), extra: basics.outerStatusName ? basics.outerStatusName : '' },
{ label: intl.formatMessage({ id: 'contract.hetongbianhao' }), extra: basics.contractNo ? basics.contractNo : '', url: `/memberCenter/contract/manage/QueryList/QueryListdetails?contractId=${basics.id}` },
{ label: intl.formatMessage({ id: 'contract.hetongzhaiyao' }), extra: basics.contractAbstract ? basics.contractAbstract : '' },
{ label: intl.formatMessage({ id: 'contract.waibuzhuangtai' }), extra: basics.outerStatusName ? basics.outerStatusName : '' },
],
col2: [
{ label: intl.formatMessage({id: 'contract.xunyuanleixing'}), extra: basics.sourceTypeName ? basics.sourceTypeName : '' },
{ label: intl.formatMessage({id: 'contract.duiyingdanju'}), extra: basics.sourceNo ? basics.sourceNo : '', url: '' },
{ label: intl.formatMessage({id: 'contract.hetongyifang'}), extra: basics.partyBName ? basics.partyBName : '' },
{ label: intl.formatMessage({ id: 'contract.xunyuanleixing' }), extra: basics.sourceTypeName ? basics.sourceTypeName : '' },
{ label: intl.formatMessage({ id: 'contract.duiyingdanju' }), extra: basics.sourceNo ? basics.sourceNo : '', url: '' },
{ label: intl.formatMessage({ id: 'contract.hetongyifang' }), extra: basics.partyBName ? basics.partyBName : '' },
],
col3: [
{ label: intl.formatMessage({id: 'contract.hetongjine'}), extra: basics.totalAmount ? `${intl.formatMessage({ id: 'common.money' })}${basics.totalAmount}` : '' },
{ label: intl.formatMessage({id: 'contract.hetongyouxiaoqi'}), extra: `${basics.startTime}${intl.formatMessage({id: 'common.text.to'})}${basics.endTime}` },
{ label: intl.formatMessage({ id: 'contract.hetongjine' }), extra: basics.totalAmount ? `${intl.formatMessage({ id: 'common.money' })}${basics.totalAmount}` : '' },
{ label: intl.formatMessage({ id: 'contract.hetongyouxiaoqi' }), extra: `${basics.startTime}${intl.formatMessage({ id: 'common.text.to' })}${basics.endTime}` },
],
}
if (basics.sourceId) {
......@@ -209,7 +209,7 @@ const Details = (props: any) => {
/* 查看付款明细 */
const columns: any = [
{
title: intl.formatMessage({id: 'contract.danjuhaozhaiyao'}), dataIndex: 'orderNO', align: 'left',
title: intl.formatMessage({ id: 'contract.danjuhaozhaiyao' }), dataIndex: 'orderNO', align: 'left',
render: (text: any, record: any) => {
return (
<div>
......@@ -224,11 +224,11 @@ const Details = (props: any) => {
},
},
{
title: intl.formatMessage({id: 'contract.danjuleixing'}), dataIndex: 'orderTypeName', align: 'left',
title: intl.formatMessage({ id: 'contract.danjuleixing' }), dataIndex: 'orderTypeName', align: 'left',
},
{ title: intl.formatMessage({id: 'contract.danjuzhuangtai'}), dataIndex: 'orderStatusName', align: 'left', },
{ title: intl.formatMessage({ id: 'contract.danjuzhuangtai' }), dataIndex: 'orderStatusName', align: 'left', },
{
title: intl.formatMessage({id: 'contract.danjushijian'}), dataIndex: 'orderTime', align: 'left',
title: intl.formatMessage({ id: 'contract.danjushijian' }), dataIndex: 'orderTime', align: 'left',
render: (text: any, record: any) => {
return (
<Text>{moment(Number(text)).format('YYYY-MM-DD')}</Text>
......@@ -239,8 +239,8 @@ const Details = (props: any) => {
dataIndex: 'orderAmount', align: 'left',
title: (
<Space direction='vertical'>
<Text>{intl.formatMessage({id: 'contract.danjujine'})}</Text>
<Text>{intl.formatMessage({id: 'contract.heji'})}: {intl.formatMessage({ id: 'common.money' })}{orderAmount}</Text>
<Text>{intl.formatMessage({ id: 'contract.danjujine' })}</Text>
<Text>{intl.formatMessage({ id: 'contract.heji' })}: {intl.formatMessage({ id: 'common.money' })}{orderAmount}</Text>
</Space>
),
render: (text) => (
......@@ -248,10 +248,10 @@ const Details = (props: any) => {
)
},
{
title: intl.formatMessage({id: 'contract.hanshuishuil'}), dataIndex: 'taxRate', align: 'left',
title: intl.formatMessage({ id: 'contract.hanshuishuil' }), dataIndex: 'taxRate', align: 'left',
render: (text, record) => (
<Space direction='vertical'>
<Text>{record.isHasTax == 1 ? intl.formatMessage({id: 'contract.shi'}) : intl.formatMessage({id: 'contract.fou'})}</Text>
<Text>{record.isHasTax == 1 ? intl.formatMessage({ id: 'contract.shi' }) : intl.formatMessage({ id: 'contract.fou' })}</Text>
<Text>{text}%</Text>
</Space>
)
......@@ -260,8 +260,8 @@ const Details = (props: any) => {
dataIndex: 'payAmount', align: 'left',
title: (
<Space direction='vertical'>
<Text>{intl.formatMessage({id: 'contract.yifukuan'})}</Text>
<Text>{intl.formatMessage({id: 'contract.heji'})}: {intl.formatMessage({ id: 'common.money' })}{payAmount}</Text>
<Text>{intl.formatMessage({ id: 'contract.yifukuan' })}</Text>
<Text>{intl.formatMessage({ id: 'contract.heji' })}: {intl.formatMessage({ id: 'common.money' })}{payAmount}</Text>
</Space>
),
render: (text) => (
......@@ -271,8 +271,8 @@ const Details = (props: any) => {
{
title: (
<Space direction='vertical'>
<Text>{intl.formatMessage({id: 'contract.yiqingkuandaifukuan'})}</Text>
<Text>{intl.formatMessage({id: 'contract.heji'})}: {intl.formatMessage({ id: 'common.money' })}{unPayApplyAmount}</Text>
<Text>{intl.formatMessage({ id: 'contract.yiqingkuandaifukuan' })}</Text>
<Text>{intl.formatMessage({ id: 'contract.heji' })}: {intl.formatMessage({ id: 'common.money' })}{unPayApplyAmount}</Text>
</Space>
),
dataIndex: 'unPayApplyAmount', align: 'left',
......@@ -283,8 +283,8 @@ const Details = (props: any) => {
{
title: (
<Space direction='vertical'>
<Text>{intl.formatMessage({id: 'contract.daiqingkuan'})}</Text>
<Text>{intl.formatMessage({id: 'contract.heji'})}: {intl.formatMessage({ id: 'common.money' })}{unApplyAmount}</Text>
<Text>{intl.formatMessage({ id: 'contract.daiqingkuan' })}</Text>
<Text>{intl.formatMessage({ id: 'contract.heji' })}: {intl.formatMessage({ id: 'common.money' })}{unApplyAmount}</Text>
</Space>
),
dataIndex: 'unApplyAmount', align: 'left',
......@@ -293,13 +293,13 @@ const Details = (props: any) => {
)
},
{
title: intl.formatMessage({id: 'contract.caozuo'}), dataIndex: 'type', align: 'left',
title: intl.formatMessage({ id: 'contract.caozuo' }), dataIndex: 'type', align: 'left',
render: (text, record) => {
// 已付款大于0或已请款待付款大于0的才显示查看付款明细按钮。
return(
<div>
<a onClick={() => getPayment(record)} className={style.gesture}>{intl.formatMessage({id: 'contract.zhakanfukuanmingxi'})}</a>
</div>
return (
<div>
<a onClick={() => getPayment(record)} className={style.gesture}>{intl.formatMessage({ id: 'contract.zhakanfukuanmingxi' })}</a>
</div>
)
// if (record.payAmount !== 0) {
// node =
......@@ -343,7 +343,7 @@ const Details = (props: any) => {
}
};
/* 查看付款明细回调 */
const setDrawerModal = () => {
setVisible(!visible)
......@@ -420,37 +420,37 @@ const Details = (props: any) => {
<div className='ant-card-head'>
<div className='ant-card-head-wrapper' style={{ display: 'flex', justifyContent: 'space-between' }}>
<div className='ant-card-head-wrapper'>
{intl.formatMessage({id: 'contract.zhixingqingkuang'})}
{intl.formatMessage({ id: 'contract.zhixingqingkuang' })}
</div>
<div className={style.wrapper}>
<Input
style={{ width: 240 ,marginRight:10}}
placeholder={intl.formatMessage({id: 'contract.qingshurudanjuhao'})}
<Input
style={{ width: 240, marginRight: 10 }}
placeholder={intl.formatMessage({ id: 'contract.qingshurudanjuhao' })}
allowClear
value={from.orderNo}
onChange={(e)=>setvalue(e,'orderNo')}
onChange={(e) => setvalue(e, 'orderNo')}
/>
<Input
style={{ width: 240 ,marginRight:10}}
placeholder={intl.formatMessage({id: 'contract.qingshurudanzaiyao'})}
<Input
style={{ width: 240, marginRight: 10 }}
placeholder={intl.formatMessage({ id: 'contract.qingshurudanzaiyao' })}
allowClear
value={from.orderAbstract}
onChange={(e)=>setvalue(e,'orderAbstract')}
onChange={(e) => setvalue(e, 'orderAbstract')}
/>
<RangePicker
showTime={{ format: 'HH:mm' }}
format="YYYY-MM-DD HH:mm"
onChange={onChange}
/>
<Button type="primary" onClick={query}>
{intl.formatMessage({id: 'contract.chaxun'})}
</Button>
<RangePicker
showTime={{ format: 'HH:mm' }}
format="YYYY-MM-DD HH:mm"
onChange={onChange}
/>
<Button type="primary" onClick={query}>
{intl.formatMessage({ id: 'contract.chaxun' })}
</Button>
</div>
</div>
</div>
<div className='ant-card-body'>
<Table
rowKey='keyId'
rowSelection={rowSelection}
......
......@@ -64,6 +64,7 @@ const Details = (props: any) => {
const [basicData, setbasicData] = useState<any>({
invoiceProveVOList: [],
}) // 合同付款基本信息
const [contractUrl, setcontractUrl] = useState('');
/* 获取详情的数据 */
const getDetail = () => {
getContractCoordinationGetDetail({ contractId }).then(res => {
......@@ -178,8 +179,10 @@ const Details = (props: any) => {
},
onChange(info) {
if (info.file.response) {
const { code } = info.file.response;
console.log(info.file)
const { code, data: { url } } = info.file.response;
console.log(code);
setcontractUrl(url)
message.info(intl.formatMessage({ id: 'contract.shangchuanchenggong' }));
setstate(true);
}
......@@ -247,6 +250,7 @@ const Details = (props: any) => {
break;
case 'Sign':
fn = postContractCoordinationSign;
values.contractUrl = contractUrl
break;
default:
break;
......@@ -479,6 +483,7 @@ const Details = (props: any) => {
<Col>
<Upload
{...uploadProps}
maxCount={1}
>
<Button icon={<UploadOutlined />}>{intl.formatMessage({ id: 'contract.shangchuanfujian' })}</Button>
</Upload>
......
......@@ -145,8 +145,8 @@ export const supplierColumns = [
* 第二个内容
*/
export const goodcolumns: any = [
{ title: intl.formatMessage({id: 'contract.wuliaobianhao'}), dataIndex: 'code', align: 'left', },
{ title: intl.formatMessage({id: 'contract.wuliaomingcheng'}), dataIndex: 'name', key: 'name', align: 'left', },
{ title: intl.formatMessage({id: 'contract.huohao'}), dataIndex: 'code', align: 'left', },
{ title: intl.formatMessage({id: 'contract.huopinmingcheng'}), dataIndex: 'name', key: 'name', align: 'left', },
{ title: intl.formatMessage({id: 'contract.guigexinghao'}), dataIndex: 'type', align: 'left', },
{
title: intl.formatMessage({id: 'contract.pinlei'}), dataIndex: 'type', align: 'left',
......
......@@ -72,7 +72,7 @@ const ContractText = (props: any) => {
/* 生成电子合同 */
const generate = () => {
if (!Templatel.id) {
message.info(intl.formatMessage({id: 'contract.qingxianxuanzehetongmoban'}))
message.info(intl.formatMessage({ id: 'contract.qingxianxuanzehetongmoban' }))
} else {
const param = {
contractTemplateId: Templatel.id,
......@@ -98,7 +98,7 @@ const ContractText = (props: any) => {
const beforeDocUpload = (file: any) => {
const isLt20M = file.size / 1024 / 1024 < 20;
if (!isLt20M) {
message.error(intl.formatMessage({id: 'contract.shangchuanwenjiandaxiaobuchao'}));
message.error(intl.formatMessage({ id: 'contract.shangchuanwenjiandaxiaobuchao' }));
}
return isLt20M;
}
......@@ -119,21 +119,21 @@ const ContractText = (props: any) => {
width: '100%',
}}
>
<Form.Item label={intl.formatMessage({id: 'contract.hetongmuban'})} labelAlign="left" labelCol={{ span: 2 }}>
<Form.Item label={intl.formatMessage({ id: 'contract.hetongmuban' })} labelAlign="left" labelCol={{ span: 2 }}>
<Select
style={{ width: 600 }}
options={TemplatePage}
placeholder={intl.formatMessage({id: 'contract.qingxuanzehetongmuban'})}
placeholder={intl.formatMessage({ id: 'contract.qingxuanzehetongmuban' })}
onChange={(e) => getTemplate(e)}
>
</Select>
{
checkNick && <Button type='link' onClick={() => generate()}>{intl.formatMessage({id: 'contract.shengchenghetong'})}</Button>
checkNick && <Button type='link' onClick={() => generate()}>{intl.formatMessage({ id: 'contract.shengchenghetong' })}</Button>
}
</Form.Item>
{
Object.keys(Templatel).length != 0 &&
<Form.Item label={intl.formatMessage({id: 'contract.hetongwenben'})} labelAlign="left" labelCol={{ span: 2 }}>
<Form.Item label={intl.formatMessage({ id: 'contract.hetongwenben' })} labelAlign="left" labelCol={{ span: 2 }}>
<div className={styles.upload_item} style={{ width: 680 }}>
<div className={styles.upload_left} style={{ width: 600 }} onClick={() => onDownload()}>
<FileWordFilled />
......@@ -147,17 +147,18 @@ const ContractText = (props: any) => {
beforeUpload={beforeDocUpload}
onChange={handleChange}
accept='.doc,.docx'
maxCount={1}
>
<div className={styles.uploadIconBtn}>
<Button type='link' >{intl.formatMessage({id: 'contract.shangchuanhetong'})}</Button>
<Button type='link' >{intl.formatMessage({ id: 'contract.shangchuanhetong' })}</Button>
</div>
</Upload>
</div>
</Form.Item>
}
<Form.Item label={intl.formatMessage({id: 'contract.dianzihetong'})} labelAlign="left" labelCol={{ span: 2 }}>
<Form.Item label={intl.formatMessage({ id: 'contract.dianzihetong' })} labelAlign="left" labelCol={{ span: 2 }}>
<Checkbox checked={checkNick} onChange={onCheckboxChange}>
{intl.formatMessage({id: 'contract.shiyongdianzihetong'})}
{intl.formatMessage({ id: 'contract.shiyongdianzihetong' })}
</Checkbox>
</Form.Item>
</div>
......
......@@ -310,6 +310,7 @@ const Details = (props: any) => {
window.open(res.data.url)
}
} else {
console.log(1111)
setIsModalVisible(!Visible)
}
}
......@@ -432,14 +433,14 @@ const Details = (props: any) => {
<div className='ant-card-head'>
<div className='ant-card-head-wrapper'>
<div className='ant-card-head-wrapper'>
{intl.formatMessage({ id: 'contract.dianzihetong' })}
{contractText.isUseElectronicContract ? intl.formatMessage({ id: 'contract.dianzihetong' }) : intl.formatMessage({ id: 'contract.zhizhihetong' })}
</div>
</div>
</div>
<div className='ant-card-body'>
<div className={style.upload_item} style={{ width: 680 }}>
<div className='ant-card-head-wrapper'>
{intl.formatMessage({ id: 'contract.dianzihetong' })}
{contractText.isUseElectronicContract ? intl.formatMessage({ id: 'contract.dianzihetong' }) : intl.formatMessage({ id: 'contract.zhizhihetong' })}
</div>
<div className={style.upload_left} onClick={() => onDownload(contractText)} style={{ width: 600, cursor: 'pointer' }}>
<FileWordFilled />
......
......@@ -88,9 +88,10 @@ const ContractText = (props: any) => {
// 上传回调
const handleChange = ({ fileList }) => {
if (fileList[0].response) {
console.log(fileList[0].name, fileList[0].response.data)
if (fileList[0].response.code === 1000) {
Templatel.name = fileList[0].name
Templatel.fileUrl = fileList[0].response.data
Templatel.fileName = fileList[0].name
Templatel.contractUrl = fileList[0].response.data
setTemplatel({ ...Templatel })
}
}
......@@ -153,6 +154,7 @@ const ContractText = (props: any) => {
onChange={handleChange}
accept='.doc,.docx'
maxCount={1}
>
<div className={styles.uploadIconBtn}>
<Button type='link' >{intl.formatMessage({ id: 'contract.shangchuanhetong' })}</Button>
......
......@@ -23,7 +23,7 @@ const PurchaseList = () => {
const [selectRow, setSelectRow] = useState<any[]>([]) // 模态框选择的行数据
//表头
const columns: ColumnType<any>[] = [{
title: intl.formatMessage({id: 'contract.xuqiudanhaozhaiyao'}),
title: intl.formatMessage({ id: 'contract.xuqiudanhaozhaiyao' }),
dataIndex: 'demandNO',
align: 'left',
render: (text, record) =>
......@@ -37,7 +37,7 @@ const PurchaseList = () => {
<p>{record.demandAbstract}</p>
</div>
}, {
title: intl.formatMessage({id: 'contract.xuqiufabushijian'}),
title: intl.formatMessage({ id: 'contract.xuqiufabushijian' }),
dataIndex: 'demandPublishTime',
align: 'left',
sorter: {
......@@ -45,12 +45,12 @@ const PurchaseList = () => {
multiple: 1,
},
}, {
title: intl.formatMessage({id: 'contract.shoubiaohuiyuan'}),
title: intl.formatMessage({ id: 'contract.shoubiaohuiyuan' }),
dataIndex: 'awardName',
align: 'left',
},
{
title: intl.formatMessage({id: 'contract.shoubiaoshijian'}),
title: intl.formatMessage({ id: 'contract.shoubiaoshijian' }),
dataIndex: 'awardTime',
align: 'left',
sorter: {
......@@ -59,7 +59,7 @@ const PurchaseList = () => {
},
},
{
title: intl.formatMessage({id: 'contract.shoubiaojine'}),
title: intl.formatMessage({ id: 'contract.shoubiaojine' }),
dataIndex: 'awardAmount',
align: 'left',
sorter: {
......@@ -75,7 +75,7 @@ const PurchaseList = () => {
}
},
{
title: intl.formatMessage({id: 'contract.waibuzhuangtai'}),
title: intl.formatMessage({ id: 'contract.waibuzhuangtai' }),
dataIndex: 'outerStatus',
align: 'left',
......@@ -87,7 +87,7 @@ const PurchaseList = () => {
}
},
{
title: intl.formatMessage({id: 'contract.neibuzhuangtai'}),
title: intl.formatMessage({ id: 'contract.neibuzhuangtai' }),
dataIndex: 'innerStatus',
align: 'left',
render: (text) => {
......@@ -99,13 +99,13 @@ const PurchaseList = () => {
)
}
}, {
title: intl.formatMessage({id: 'contract.caozuo'}),
title: intl.formatMessage({ id: 'contract.caozuo' }),
dataIndex: 'state',
align: 'left',
render: (_, record) => {
return (
<div>
<span style={{ color: '#00B37A', cursor: 'pointer', marginRight: 10 }} onClick={() => like(record)}>{intl.formatMessage({id: 'contract.chuangjiancaigouxunjiahetong'})}</span>
<span style={{ color: '#00B37A', cursor: 'pointer', marginRight: 10 }} onClick={() => like(record)}>{intl.formatMessage({ id: 'contract.chuangjiancaigouxunjiahetong' })}</span>
</div>
)
}
......
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