Commit 4da8b85f authored by XieZhiXiong's avatar XieZhiXiong

完善内外部流程步骤条

parent 4950d0e6
......@@ -2,7 +2,7 @@
* @Author: XieZhiXiong
* @Date: 2020-09-15 17:48:36
* @LastEditors: XieZhiXiong
* @LastEditTime: 2020-11-06 18:34:26
* @LastEditTime: 2020-11-06 18:47:46
* @Description: 内外部流转记录组件
*/
import React from 'react';
......
import React from 'react'
import AuditProcess from '@/components/AuditProcess'
import { findLastIndexFlowState } from '../../_public/order/utils'
import { findLastIndexFlowState } from '@/utils'
import OrderProductTable from '../../components/orderProductTable'
import SaleOrderProductTable from '../../components/saleOrderProductTable'
import OrderPayTabs from '../../components/orderPayTabs'
......@@ -22,8 +22,22 @@ const OrderDetailSection:React.FC<OrderDetailSectionProps> = ({formContext, type
customKey='state'
outerVerifyCurrent={findLastIndexFlowState(formContext.data.externalWorkflowFlowRecordLogResponses)}
innerVerifyCurrent={findLastIndexFlowState(formContext.data.interiorWorkflowFlowRecordLogResponses)}
outerVerifySteps={formContext.data.externalWorkflowFlowRecordLogResponses || []}
innerVerifySteps={formContext.data.interiorWorkflowFlowRecordLogResponses || []}
outerVerifySteps={
formContext.data.externalWorkflowFlowRecordLogResponses ?
formContext.data.externalWorkflowFlowRecordLogResponses.map(item => ({
...item,
status: item.isExecute ? 'finish' : 'wait',
})) :
[]
}
innerVerifySteps={
formContext.data.interiorWorkflowFlowRecordLogResponses ?
formContext.data.interiorWorkflowFlowRecordLogResponses.map(item => ({
...item,
status: item.isExecute ? 'finish' : 'wait',
})) :
[]
}
></AuditProcess>
{ type === 'saleOrder' ? <SaleOrderProductTable/> : <OrderProductTable editable /> }
......
......@@ -24,8 +24,8 @@ import { useProductTable } from './model/useProductTable'
import styled from 'styled-components'
import { useUpdate } from '@umijs/hooks'
import { PublicApi } from '@/services/api'
import { formatTimeString, omit } from '@/utils'
import { changeRouterTitleByStatus, findLastIndexFlowState } from '../../_public/order/utils'
import { formatTimeString, omit, findLastIndexFlowState } from '@/utils'
import { changeRouterTitleByStatus } from '../../_public/order/utils'
import { ReadyAddOrderDetailContext } from '../context'
import AuditProcess from '@/components/AuditProcess'
......@@ -293,8 +293,22 @@ const PurchaseOrderDetail:React.FC<PurchaseOrderDetailProps> = (props) => {
customKey='state'
outerVerifyCurrent={findLastIndexFlowState(initFormValue.externalWorkflowFlowRecordLogResponses)}
innerVerifyCurrent={findLastIndexFlowState(initFormValue.interiorWorkflowFlowRecordLogResponses)}
outerVerifySteps={initFormValue.externalWorkflowFlowRecordLogResponses}
innerVerifySteps={initFormValue.interiorWorkflowFlowRecordLogResponses}
outerVerifySteps={
initFormValue.externalWorkflowFlowRecordLogResponses ?
initFormValue.externalWorkflowFlowRecordLogResponses.map(item => ({
...item,
status: item.isExecute ? 'finish' : 'wait',
})) :
[]
}
innerVerifySteps={
initFormValue.interiorWorkflowFlowRecordLogResponses ?
initFormValue.interiorWorkflowFlowRecordLogResponses.map(item => ({
...item,
status: item.isExecute ? 'finish' : 'wait',
})) :
[]
}
></AuditProcess> }
<Card className='' style={{marginTop: 24}}>
<NiceForm
......
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