|
|
@@ -1,5 +1,5 @@
|
|
|
import { Row, Col } from 'antd'
|
|
|
-import React from 'react'
|
|
|
+import React, { useMemo } from 'react'
|
|
|
import EditableForm from '@/components/EditableForm'
|
|
|
import ChangeCompanyInput, {
|
|
|
ChangeCompMap
|
|
|
@@ -10,6 +10,10 @@ import Step from './Step/index'
|
|
|
const Form = props => {
|
|
|
const { business, groupStatus, updateKey } = props
|
|
|
|
|
|
+ const isEnd = useMemo(() => {
|
|
|
+ return groupStatus.findIndex(item => item.endProcess && item.selected) !== -1
|
|
|
+ }, [groupStatus, business.businessStatusId])
|
|
|
+
|
|
|
const changeCopInputData = {
|
|
|
customerName: business.customerName,
|
|
|
customerId: business.customerId,
|
|
|
@@ -35,7 +39,7 @@ const Form = props => {
|
|
|
dataIndex: 'customerId',
|
|
|
label: '单位名称',
|
|
|
editCellType: 'custom',
|
|
|
- customCell: <ChangeCompanyInput dataSource={changeCopInputData} />,
|
|
|
+ customCell: <ChangeCompanyInput dataSource={changeCopInputData} editable={!isEnd} />,
|
|
|
span: 24
|
|
|
},
|
|
|
{
|
|
|
@@ -84,6 +88,7 @@ const Form = props => {
|
|
|
columns={columns}
|
|
|
tartgetUrl="/business/update"
|
|
|
type={updateKey}
|
|
|
+ editable={!isEnd}
|
|
|
/>
|
|
|
</div>
|
|
|
)
|