Commit fbe74105 authored by 前端-黄佳鑫's avatar 前端-黄佳鑫

增加询价报价后台新加的字段

parent 6c5035f9
import React, { useState, useEffect, useRef } from 'react';
import style from './index.less'
import { history } from 'umi';
import { Button, Card, Tabs, Steps, Table } from 'antd';
import { Button, Tabs, Steps, Table } from 'antd';
import { LinkOutlined } from '@ant-design/icons';
import { ColumnType } from 'antd/lib/table/interface';
import { EyeOutlined, ClockCircleOutlined, UpOutlined, DownOutlined, StopOutlined, CheckSquareOutlined } from '@ant-design/icons'
import ReutrnEle from '@/components/ReturnEle';
import { CheckSquareOutlined } from '@ant-design/icons'
import { StandardTable } from 'god';
import { PageHeaderWrapper } from '@ant-design/pro-layout';
import StatusColors from '@/pages/transaction/components/StatusColors';
import { quoteOrderInternalState, inquiryQuoteOuterState } from '../../common/tableStatusList';
import { confirmExternalState, confirmInteriorState, inquiryQuoteOuterState, quoteOrderInternalState } from '../../common/tableStatusList';
import AuditModal from '../components/auditModel';
import EyePreview from '@/components/EyePreview';
import { PublicApi } from '@/services/api';
import moment from 'moment';
const { TabPane } = Tabs;
const { Step } = Steps;
......@@ -34,6 +33,9 @@ export interface parmas {
const Details: React.FC<parmas> = (props) => {
const [visible, setvisible] = useState(false)
const ref = useRef<any>({});
const format = (text) => {
return <>{moment(text).format("YYYY-MM-DD HH:mm:ss")}</>
}
//page_type: 1.待确认报价单,2.待审核报价单1级,3.待审核报价单2级,4.报价单查询,5.待提交审核报价单
//view: 1.询价单号,2.报价单号
const { id, page_type } = props;
......@@ -138,12 +140,12 @@ const Details: React.FC<parmas> = (props) => {
base: {
title: '交易条件',
leftElem: [
{ title: '交付日期', key: '', value: data.deliveryTime },
{ title: '交付日期', key: '', value: format(data.deliveryTime) },
{ title: '交付地址', key: '', value: data.fullAddress },
{ title: '物流要求', key: '', value: data.logistics }
],
centerElem: [
{ title: '报价截止日期', key: '', value: data.quotationAsTime },
{ title: '报价截止日期', key: '', value: format(data.quotationAsTime) },
{ title: '报价要求', key: '', value: data.offer },
{ title: '包装要求', key: '', value: data.packRequire },
],
......@@ -184,6 +186,7 @@ const Details: React.FC<parmas> = (props) => {
title: '状态',
key: 'state',
dataIndex: 'state',
render:(text:any, record:any) => confirmExternalState(record.externalState)
}, {
title: '操作',
key: 'operation',
......@@ -192,6 +195,7 @@ const Details: React.FC<parmas> = (props) => {
title: '操作时间',
key: 'operationTime',
dataIndex: 'operationTime',
render:(text:any, record:any) => format(text)
}, {
title: '审核意见',
key: 'auditOpinion',
......@@ -217,6 +221,7 @@ const Details: React.FC<parmas> = (props) => {
title: '状态',
key: 'state',
dataIndex: 'state',
render:(text:any, record:any) => confirmInteriorState(record.interiorState)
}, {
title: '操作',
key: 'operation',
......@@ -225,6 +230,7 @@ const Details: React.FC<parmas> = (props) => {
title: '操作时间',
key: 'operationTime',
dataIndex: 'operationTime',
render:(text:any, record:any) => format(text)
}, {
title: '审核意见',
key: 'auditOpinion',
......@@ -350,6 +356,8 @@ const Details: React.FC<parmas> = (props) => {
inquiryQuoteOuterState(item.value) :
item.name === 'interiorState' ?
quoteOrderInternalState(item.value) :
(item.name === 'voucherTime' || item.name === 'quotationAsTime' ) ?
format(item.value) :
item.value
}
</div>
......
......@@ -64,7 +64,7 @@ const EnquiryOrder: React.FC<{}> = (props) => {
title: '操作',
key: 'options',
dataIndex: 'options',
render: (text: any, record: any) => <Button disabled={record.externalState!==2 && record.externalState!==5} type='link'><Link to={`/memberCenter/tranactionAbility/inquiryQuote/addInquiryOrder/quote?id=${record.id}`}>报价</Link></Button>
render: (text: any, record: any) => <Button disabled={record.externalState!==2 && record.externalState!==5 && record.isQuoted !==1} type='link'><Link to={`/memberCenter/tranactionAbility/inquiryQuote/addInquiryOrder/quote?id=${record.id}`}>报价</Link></Button>
}];
//交易能力 询价报价 询价单查询
const fetchData = (params?: any) => {
......
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