Commit 5fdba405 authored by 前端-钟卫鹏's avatar 前端-钟卫鹏

fix: 招标报名/资格审核筛选字段变更,处理新增编辑招标id传参异常

parent e10a9591
import React from 'react'
import { history } from 'umi'
import moment from 'moment'
import { BidInStateTexts, BidOutStateTexts } from '@/constants'
import { usePageStatus, PageStatus } from '@/hooks/usePageStatus'
const { pageStatus, id } = usePageStatus()
/** 时间转时间戳 */
export const dataChangeUnix = (t) => moment(t).valueOf()
......@@ -13,6 +12,7 @@ export const unixChangeRender = (t) => t ? moment(t).format('YYYY-MM-DD HH:mm:ss
/** 文件数组转url字符串数组 */
export const fileChangeStringArray = (arr) => arr.map(item => {
const { pageStatus } = usePageStatus()
let param = {
id: item.id,
name: item.name.split('/').pop(),
......@@ -25,6 +25,7 @@ export const fileChangeStringArray = (arr) => arr.map(item => {
/** 传参 数据转换 id:判断是否编辑 */
export const paramsConversionFn = (value) => {
const { pageStatus } = usePageStatus()
const _value = {...value}
value['evaluationStartTime'] = dataChangeUnix(_value['evaluationStartTime'])
value['evaluationEndTime'] = dataChangeUnix(_value['evaluationEndTime'])
......@@ -71,6 +72,7 @@ export const paramsConversionFn = (value) => {
memberRoleName: item.roleName,
...item,
}
console.log(pageStatus, 'gan')
if(pageStatus === PageStatus.ADD) {
delete param.id
}
......@@ -89,7 +91,10 @@ export const paramsConversionFn = (value) => {
cityName: item.city,
isAllCity: item?.cityCode ? false : true
}
if(pageStatus === PageStatus.ADD) { delete param.id }
console.log(pageStatus, 'gan')
if(pageStatus === PageStatus.ADD) {
delete param.id
}
return param
})
} else {
......
......@@ -19,7 +19,7 @@ export interface ReadyCheckedRegisterProps {}
const fetchTableData = async (params) => {
const { data } = await PublicApi.postPurchaseInviteTenderGetSubmitTenderList({
...params,
submitTenderOutStatusList: [TenderOutWorkState.Not_Check_Register_Check]
inviteTenderOutStatusList: [BidOuterWorkState.Not_Check_Register_Check]
}, { ctlType: "none" })
return data
}
......
......@@ -19,7 +19,7 @@ export interface ReadyQualifityCheckedProps {}
const fetchTableData = async (params) => {
const { data } = await PublicApi.postPurchaseInviteTenderGetSubmitTenderList({
...params,
submitTenderOutStatusList: [TenderOutWorkState.Not_Qualifications_Check],
inviteTenderOutStatusList: [BidOuterWorkState.Not_Qualifications_Check],
}, { ctlType: "none" })
return data
}
......
......@@ -67,7 +67,7 @@ export const useSelfTable = () => {
align: 'left',
dataIndex: 'inviteTender',
key: 'inviteTender',
render: (text, record) => <CustomTag status={record.inviteTender.inviteTenderOutStatus} type='out' />
render: (text, record) => <CustomTag status={record.submitTenderOutStatus} type='tenderOut' />
},
// {
// title: '内部状态',
......
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