Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
J
jinfa-platform
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
linweijiong
jinfa-platform
Commits
5b53736f
Commit
5b53736f
authored
Aug 16, 2021
by
前端-钟卫鹏
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: 取消招投标提交评标报告修正总分与总分的联动,处理采购规则配置支付配置项显示隐藏异常问题
parent
bb9144f8
Hide whitespace changes
Inline
Side-by-side
Showing
12 changed files
with
61 additions
and
55 deletions
+61
-55
index.tsx
src/pages/procurement/callForBids/addNewBid/index.tsx
+1
-4
index.tsx
...rocurement/callForBids/callForBidsSearch/detail/index.tsx
+1
-24
index.tsx
...ds/readyExpertRemark/components/remarkTableCell/index.tsx
+2
-1
index.tsx
...rocurement/callForBids/readyExpertRemark/detail/index.tsx
+1
-1
index.tsx
...ds/readySubmitReport/components/remarkBidReport/index.tsx
+8
-7
index.tsx
...rocurement/callForBids/readySubmitReport/detail/index.tsx
+0
-2
index.tsx
src/pages/procurement/components/bidDetailSection/index.tsx
+1
-5
index.tsx
src/pages/procurement/components/bidParticulars/index.tsx
+2
-2
index.tsx
src/pages/procurement/components/remarkBidReport/index.tsx
+4
-4
usePaymentInfo.tsx
...on/purchaseOrder/orderCollectB2b/model/usePaymentInfo.tsx
+2
-2
RuleSetting.tsx
...s/transaction/transactionRules/components/RuleSetting.tsx
+34
-3
index.tsx
src/pages/transaction/transactionRules/schema/index.tsx
+5
-0
No files found.
src/pages/procurement/callForBids/addNewBid/index.tsx
View file @
5b53736f
import
React
,
{
useRef
,
useState
,
useEffect
,
useCallback
}
from
'react'
import
React
,
{
useRef
,
useState
,
useEffect
}
from
'react'
import
{
history
}
from
'umi'
import
{
PageHeaderWrapper
}
from
'@ant-design/pro-layout'
import
ReutrnEle
from
'@/components/ReturnEle'
...
...
@@ -101,7 +101,6 @@ const AddNewBid:React.FC<AddNewBidProps> = (props) => {
const
handleSubmit
=
async
(
value
)
=>
{
setBtnLoading
(
true
)
const
params
=
paramsConversionFn
(
value
)
console
.
log
(
params
,
value
,
'ppp'
)
if
(
!
params
.
isQualificationCheck
)
{
delete
params
.
preCheckStartTime
delete
params
.
preCheckEndTime
...
...
@@ -147,7 +146,6 @@ const AddNewBid:React.FC<AddNewBidProps> = (props) => {
// // 新增或复制 剔除id操作
// omitID(params)
// }
// console.log(params, 'after')
try
{
addSchemaAction
.
getFieldState
(
'deliverAddressId'
,
state
=>
{
if
(
params
?.
deliverAddressId
)
{
...
...
@@ -223,7 +221,6 @@ const AddNewBid:React.FC<AddNewBidProps> = (props) => {
const
clickAddMember
=
()
=>
{
memberRef
.
current
.
setVisible
(
true
)
// if (id) {
// console.log(hadMembers.current, 'hadMembers')
// memberRef.current.rowSelectionCtl.setSelectedRowKeys(hadMembers.current.map(item => item.memberId))
// memberRef.current.rowSelectionCtl.setSelectRow(hadMembers.current)
// }
...
...
src/pages/procurement/callForBids/callForBidsSearch/detail/index.tsx
View file @
5b53736f
...
...
@@ -5,10 +5,9 @@ import { BidDetailContext } from '@/pages/procurement/_public/bid/context';
import
{
useBidDetail
}
from
'@/pages/procurement/_public/bid/effects/useBidDetail'
;
import
BidDetailHeader
from
'@/pages/procurement/components/bidDetailHeader'
;
import
BidDetailSection
from
'@/pages/procurement/components/bidDetailSection'
;
import
{
BidOuterWorkState
}
from
'@/constants/procurement'
;
const
CallForBidsSearchDetail
:
React
.
FC
=
()
=>
{
const
{
formContext
,
id
}
=
useBidDetail
({
type
:
'callForBid'
})
const
{
formContext
}
=
useBidDetail
({
type
:
'callForBid'
})
const
{
data
}
=
formContext
// type? 用于区分DescriptionsInfo组件的内容
...
...
@@ -30,28 +29,6 @@ const CallForBidsSearchDetail: React.FC = () => {
{
title
:
'流转记录'
,
id
:
'transferRecord'
,
componentName
:
"BidTransformRecord"
},
]
// // 已经报名 才有报名信息 @注释原因:无法通过状态判断
// if(data?.inviteTenderOutStatus < BidOuterWorkState.Not_Submitted_Qualifications_Check) {
// anchorTitleList.splice(5, 1)
// }
// // 已经资格预审 才有资格预审信息
// if(data?.inviteTenderOutStatus < BidOuterWorkState.Not_Submit_Tender && !data?.isQualificationCheck) {
// // anchorTitleList.splice(7, 1)
// anchorTitleList.forEach((ele, index) => ele['title'] === '资格预审信息' && anchorTitleList.splice(index, 1))
// }
// // 已经评标 才有评标报告
// if(data?.inviteTenderOutStatus < BidOuterWorkState.Not_Finish_Notice) {
// // anchorTitleList.splice(9, 1)
// anchorTitleList.forEach((ele, index) => ele['title'] === '评标报告' && anchorTitleList.splice(index, 1))
// }
// // 已经完成招标 才有招标结果
// if(data?.inviteTenderOutStatus < BidOuterWorkState.Finish_Invite_Tender) {
// anchorTitleList.splice(-2, 1)
// }
// 勾选资格预审 才有资格预审信息
if
(
!
data
?.
isQualificationCheck
)
{
anchorTitleList
.
forEach
((
ele
,
index
)
=>
ele
[
'title'
]
===
'资格预审要求'
&&
anchorTitleList
.
splice
(
index
,
1
))
...
...
src/pages/procurement/callForBids/readyExpertRemark/components/remarkTableCell/index.tsx
View file @
5b53736f
...
...
@@ -51,7 +51,8 @@ export const RemarkTableCell:React.FC<TableCellProps> = ({
try
{
const
values
=
await
form
.
validateFields
()
console
.
log
(
values
,
e
,
'vvv'
)
values
.
totalScore
=
Object
.
values
(
values
).
reduce
((
a
,
b
)
=>
Number
(
a
)
+
Number
(
b
),
0
)
const
score
=
Object
.
values
(
values
).
reduce
((
a
,
b
)
=>
Number
(
a
)
+
Number
(
b
),
0
)
values
.
totalScore
=
Number
(
score
).
toFixed
(
2
)
handleSave
({
...
record
,
...
values
})
}
catch
(
errInfo
)
{
console
.
log
(
'Save failed:'
,
errInfo
)
...
...
src/pages/procurement/callForBids/readyExpertRemark/detail/index.tsx
View file @
5b53736f
...
...
@@ -82,7 +82,7 @@ const ReadyExpertRemarkDetail: React.FC = () => {
return
item
})
const
res
=
await
PublicApi
.
postPurchaseExpertExtractRecordEvaluationTender
({
id
,
evaluationTenderList
:
evaluationList
.
filter
(
Boolean
),
evaluationTenderRecommendList
})
const
res
=
await
PublicApi
.
postPurchaseExpertExtractRecordEvaluationTender
({
id
:
Number
(
id
)
,
evaluationTenderList
:
evaluationList
.
filter
(
Boolean
),
evaluationTenderRecommendList
})
if
(
res
.
code
===
1000
)
{
history
.
goBack
()
...
...
src/pages/procurement/callForBids/readySubmitReport/components/remarkBidReport/index.tsx
View file @
5b53736f
...
...
@@ -31,7 +31,7 @@ export interface RemarkBidReportProps {
editable
?:
Boolean
,
}
const
RemarkBidReport
:
React
.
FC
<
RemarkBidReportProps
>
=
({
cardTitle
,
editable
})
=>
{
const
RemarkBidReport
:
React
.
FC
<
RemarkBidReportProps
>
=
({
editable
})
=>
{
const
{
token
}
=
getAuth
()
||
{}
const
{
data
,
submitData
,
submitCtl
}
=
useContext
(
ReportDetailContext
)
const
currentRef
=
useRef
<
any
>
({})
...
...
@@ -292,11 +292,11 @@ const RemarkBidReport: React.FC<RemarkBidReportProps> = ({cardTitle, editable})
beforeUpload
(
file
)
{
if
(
file
.
name
.
length
>
100
)
{
message
.
warning
(
'文件名过长'
);
return
Promise
.
reject
();
return
Promise
.
reject
(
'文件名过长'
);
}
if
(
file
.
size
/
1024
/
1024
>
20
)
{
message
.
warning
(
'附件大小超过20M'
);
return
Promise
.
reject
();
return
Promise
.
reject
(
'附件大小超过20M'
);
}
},
}
...
...
@@ -332,7 +332,7 @@ const RemarkBidReport: React.FC<RemarkBidReportProps> = ({cardTitle, editable})
},
}
const
handleSave
=
(
row
,
index
)
=>
{
const
handleSave
=
(
row
)
=>
{
// 双重遍历childTableData数据 改变total和average
setChildrenTableData
(()
=>
{
return
childTableData
.
map
(
element
=>
{
...
...
@@ -340,8 +340,9 @@ const RemarkBidReport: React.FC<RemarkBidReportProps> = ({cardTitle, editable})
if
(
_e
.
memberName
===
row
.
memberName
)
{
return
{
...
_e
,
total
:
Number
(
row
.
total
),
average
:
(
Number
(
row
.
total
)
/
row
.
expertNumber
).
toFixed
(
2
),
// @reason:修正总分和总分不需要联动
// total: Number(row.total),
// average: (Number(row.total) / row.expertNumber).toFixed(2),
}
}
else
{
return
_e
...
...
@@ -436,7 +437,7 @@ const RemarkBidReport: React.FC<RemarkBidReportProps> = ({cardTitle, editable})
editable
:
col
.
editable
,
dataIndex
:
col
.
dataIndex
,
title
:
col
.
title
,
handleSave
:
(
row
)
=>
handleSave
(
row
,
index
),
handleSave
:
(
row
)
=>
handleSave
(
row
),
}),
};
});
...
...
src/pages/procurement/callForBids/readySubmitReport/detail/index.tsx
View file @
5b53736f
...
...
@@ -44,7 +44,6 @@ const readySubmitReportDetail: React.FC = () => {
const
handleSubmit
=
()
=>
{
setLoading
(
true
)
console
.
log
(
submitData
)
const
{
fileList
,
recommandList
,
childTableData
,
offlineData
}
=
submitData
let
params
:
any
=
{
id
}
if
(
recommandList
&&
recommandList
.
length
)
{
...
...
@@ -66,7 +65,6 @@ const readySubmitReportDetail: React.FC = () => {
:
[]
}
console
.
log
(
params
)
PublicApi
.
postPurchaseExpertExtractReportSubmitEvaluationTenderReport
(
params
).
then
(
res
=>
{
setLoading
(
true
)
if
(
res
.
code
===
1000
)
{
...
...
src/pages/procurement/components/bidDetailSection/index.tsx
View file @
5b53736f
import
React
,
{
useEffect
}
from
'react'
import
{
findLastIndexFlowState
}
from
'@/utils'
import
{
Skeleton
}
from
'antd'
;
import
style
from
'./index.less'
import
TransferProcess
from
'../transferProcess'
import
DescriptionsInfo
from
'../descriptionsInfo'
...
...
@@ -23,7 +22,6 @@ export interface BidDetailSectionProps {
const
BidDetailSection
:
React
.
FC
<
BidDetailSectionProps
>
=
({
formContext
,
type
=
'callForBid'
,
anchorList
=
[],
})
=>
{
...
...
@@ -74,7 +72,7 @@ const BidDetailSection:React.FC<BidDetailSectionProps> = ({
}
}
const
RenderCertainContent
=
({
id
,
title
,
type
=
null
,
componentName
=
null
})
=>
{
const
RenderCertainContent
=
({
title
,
type
=
null
,
componentName
=
null
})
=>
{
let
RcDom
:
any
=
null
;
switch
(
componentName
)
{
//@todo 需另外调用接口获取数据
...
...
@@ -138,11 +136,9 @@ const BidDetailSection:React.FC<BidDetailSectionProps> = ({
return
(
formContext
.
data
&&
// <Skeleton active loading={!(formContext.externalWorkflowFlowRecordLogResponses || formContext.interiorWorkflowFlowRecordLogResponses)}>
<
div
className=
{
[
style
.
anchorContentWrap
,
"anchorContent"
].
join
(
' '
)
}
>
<
RenderDetailSection
componentList=
{
anchorList
}
/>
</
div
>
// </Skeleton>
)
}
...
...
src/pages/procurement/components/bidParticulars/index.tsx
View file @
5b53736f
...
...
@@ -46,9 +46,9 @@ const BidParticulars: React.FC<BidParticularsProps> = ({cardTitle}) => {
const
[
tableColumn
,
setTableColumn
]
=
useState
<
any
>
(()
=>
{
let
totalMoney
=
0
;
data
.
submitTender
?
data
.
submitTender
.
submitTenderMateriel
.
forEach
(
item
=>
{
data
.
submitTender
?
data
.
submitTender
.
submitTenderMateriel
.
forEach
(
item
=>
{
if
(
cardTitle
===
'中标明细'
)
{
totalMoney
+=
item
.
price
*
item
.
inviteTenderMateriel
.
count
*
Number
(
item
.
awardTenderRatio
)
/
100
totalMoney
+=
(
item
.
isAwardTender
?
item
.
price
*
item
.
inviteTenderMateriel
.
count
*
Number
(
item
.
awardTenderRatio
)
/
100
:
0
)
}
else
{
totalMoney
+=
item
.
price
*
item
.
inviteTenderMateriel
.
count
}
...
...
src/pages/procurement/components/remarkBidReport/index.tsx
View file @
5b53736f
...
...
@@ -58,7 +58,7 @@ const RemarkBidReport: React.FC<RemarkBidReportProps> = ({cardTitle}) => {
// 计算总分 计算平均分
const
computedData
=
groupBy
(
dataSource
,
'memberName'
)
const
computedScore
=
Object
.
keys
(
computedData
).
map
((
item
,
index
)
=>
{
const
computedScore
=
Object
.
keys
(
computedData
).
map
((
item
)
=>
{
let
expertNumber
=
Object
.
keys
(
groupBy
(
computedData
[
item
],
'expertExtractRecordId'
)).
length
let
total
=
computedData
[
item
].
reduce
((
a
,
b
)
=>
a
+
b
.
score
,
0
)
...
...
@@ -75,7 +75,7 @@ const RemarkBidReport: React.FC<RemarkBidReportProps> = ({cardTitle}) => {
// 根据评标sort分类后的数据 遍历 分子表格
let
childrenTableDataSource
=
[]
// table data
let
childTableDataColumns
=
[]
// table columns
Object
.
keys
(
dataBySort
).
forEach
((
item
,
index
)
=>
{
Object
.
keys
(
dataBySort
).
forEach
((
item
)
=>
{
let
childTableData
=
[]
let
childTableColumns
=
[{
title
:
'会员'
,
dataIndex
:
'memberName'
,
key
:
'memberName'
,
...
...
@@ -192,7 +192,7 @@ const RemarkBidReport: React.FC<RemarkBidReportProps> = ({cardTitle}) => {
},
}
const
handleSave
=
(
row
,
index
)
=>
{
const
handleSave
=
(
row
)
=>
{
// 双重遍历childTableData数据 改变total和average
setChildrenTableData
(()
=>
{
return
childTableData
.
map
(
element
=>
{
...
...
@@ -242,7 +242,7 @@ const RemarkBidReport: React.FC<RemarkBidReportProps> = ({cardTitle}) => {
editable
:
col
.
editable
,
dataIndex
:
col
.
dataIndex
,
title
:
col
.
title
,
handleSave
:
(
row
)
=>
handleSave
(
row
,
index
),
handleSave
:
(
row
)
=>
handleSave
(
row
),
}),
};
});
...
...
src/pages/transaction/purchaseOrder/orderCollectB2b/model/usePaymentInfo.tsx
View file @
5b53736f
import
{
paymentInformationColumns
}
from
'../constant'
import
{
PayInfoCell
,
EditableRow
}
from
'../components/payInfoTableCell'
import
{
ISchemaFormActions
,
ISchemaFormAsyncActions
}
from
'@formily/antd'
import
{
useEffect
,
useState
,
useRef
,
useContext
}
from
'react'
import
{
useEffect
,
useState
,
useRef
}
from
'react'
import
{
PublicApi
}
from
'@/services/api'
export
const
usePaymentInfo
=
(
ctx
:
ISchemaFormActions
|
ISchemaFormAsyncActions
,
memberId
:
any
,
memberRoleId
:
any
,
orderProducts
:
any
):
any
=>
{
...
...
@@ -36,7 +36,7 @@ export const usePaymentInfo = (ctx: ISchemaFormActions | ISchemaFormAsyncActions
shopId
:
ctx
.
getFieldValue
(
'shopId'
),
orderMode
:
ctx
.
getFieldValue
(
'orderMode'
),
products
:
ctx
.
getFieldValue
(
'products'
).
map
(
item
=>
({
productId
:
item
.
commodityId
,
skuId
:
item
.
productId
}))
}).
then
(
res
=>
{
}
,
{
ctlType
:
'none'
}
).
then
(
res
=>
{
const
{
code
,
data
}
=
res
if
(
code
===
1000
)
{
const
newColumns
=
[...
columns
]
...
...
src/pages/transaction/transactionRules/components/RuleSetting.tsx
View file @
5b53736f
...
...
@@ -337,9 +337,10 @@ const RuleSetting:React.FC<RuleSettingProps> = (props) => {
})
fatchSetedProducts
(
parentState
.
value
[
0
])
})
// 此项隐藏操作在编辑下能无效
$
(
'onFieldValueChange'
,
'baseProcessId'
).
subscribe
(
parentState
=>
{
const
selectedObject
=
parentState
.
dataSource
.
filter
(
item
=>
item
.
baseProcessid
===
parentState
.
value
)[
0
]
// 不是下单交易类型 隐藏
电子合同
// 不是下单交易类型 隐藏
取消时间
if
(
selectedObject
&&
selectedObject
[
"processType"
]
!==
1
)
{
setFieldState
(
"MEGA_LAYOUT1_1"
,
state
=>
{
state
.
visible
=
false
...
...
@@ -360,7 +361,7 @@ const RuleSetting:React.FC<RuleSettingProps> = (props) => {
setFieldState
(
"payments"
,
state
=>
{
state
.
visible
=
true
})
if
(
pageStatus
===
PageStatus
.
ADD
)
{
//
if(pageStatus === PageStatus.ADD)
{
let
initPayments
:
any
[]
=
[];
for
(
let
i
=
1
;
i
<=
selectedObject
[
'payTimes'
];
i
++
)
{
initPayments
.
push
({
...
...
@@ -370,13 +371,43 @@ const RuleSetting:React.FC<RuleSettingProps> = (props) => {
})
}
setFieldValue
(
"payments"
,
initPayments
)
}
//
}
}
else
{
setFieldState
(
"payments"
,
state
=>
{
state
.
visible
=
false
})
}
})
// 处理编辑下支付配置的显示隐藏
$
(
'onFieldValueChange'
,
'payments'
).
subscribe
(
parentState
=>
{
if
(
pageStatus
===
PageStatus
.
EDIT
)
{
if
(
parentState
.
value
.
length
)
{
setFieldState
(
"payments"
,
state
=>
{
state
.
visible
=
true
})
}
}
})
// 处理编辑下电子的显示隐藏
$
(
'onFieldValueChange'
,
'processType'
).
subscribe
(
parentState
=>
{
if
(
pageStatus
===
PageStatus
.
EDIT
)
{
if
(
parentState
.
value
===
1
)
{
setFieldState
(
"MEGA_LAYOUT1_1"
,
state
=>
{
state
.
visible
=
true
})
setFieldState
(
"expireHours"
,
state
=>
{
state
.
visible
=
true
})
}
else
{
setFieldState
(
"MEGA_LAYOUT1_1"
,
state
=>
{
state
.
visible
=
false
})
setFieldState
(
"expireHours"
,
state
=>
{
state
.
visible
=
false
})
}
}
})
}
}
onSubmit=
{
handleSubmit
}
actions=
{
addSchemaAction
}
...
...
src/pages/transaction/transactionRules/schema/index.tsx
View file @
5b53736f
...
...
@@ -129,6 +129,11 @@ export const ruleDetailSchema: ISchema = padRequiredMessage({
},
visible
:
false
},
"processType"
:
{
type
:
'number'
,
title
:
'流程类型'
,
visible
:
false
}
}
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment