|
@@ -1,42 +1,32 @@
|
|
|
import React from 'react'
|
|
import React from 'react'
|
|
|
import { Row, Col, Divider } from 'antd'
|
|
import { Row, Col, Divider } from 'antd'
|
|
|
-import { useModal } from '@/components/Modal'
|
|
|
|
|
import { ProductLabel } from '@/pages/Product/Lock/LockStore'
|
|
import { ProductLabel } from '@/pages/Product/Lock/LockStore'
|
|
|
import ChangeClient from '@/pages/Product/Lock/LockStore/components/ChangeClient'
|
|
import ChangeClient from '@/pages/Product/Lock/LockStore/components/ChangeClient'
|
|
|
import CopyAuthorizeStr from '../CopyAuthorizeStr'
|
|
import CopyAuthorizeStr from '../CopyAuthorizeStr'
|
|
|
import DownUpdateFile from '../DownUpdateFile'
|
|
import DownUpdateFile from '../DownUpdateFile'
|
|
|
-import CompanyDetail from '@/pages/Customer/Company/components/CompanyDetail'
|
|
|
|
|
import { dayjsFormat } from '@/utils/utils'
|
|
import { dayjsFormat } from '@/utils/utils'
|
|
|
-
|
|
|
|
|
-export const ChangeCompMap = {
|
|
|
|
|
- LONGLE: {
|
|
|
|
|
- key: 'longle',
|
|
|
|
|
- title: '软件锁'
|
|
|
|
|
- }
|
|
|
|
|
-}
|
|
|
|
|
|
|
+import ChangeCompanyInput, {
|
|
|
|
|
+ ChangeCompMap
|
|
|
|
|
+} from '@/pages/Customer/Company/components/ChangeCompany'
|
|
|
|
|
|
|
|
const LockForm = props => {
|
|
const LockForm = props => {
|
|
|
- const { longle, customerId } = props
|
|
|
|
|
- const { toggleDrawer, setDrawerProps } = useModal()
|
|
|
|
|
- const changeCopInputData = {
|
|
|
|
|
|
|
+ const { longle } = props
|
|
|
|
|
+ const changeClientInputData = {
|
|
|
clientName: longle.client,
|
|
clientName: longle.client,
|
|
|
longleId: longle.id,
|
|
longleId: longle.id,
|
|
|
clientId: longle.clientId,
|
|
clientId: longle.clientId,
|
|
|
- actionPayload: ChangeCompMap.LONGLE.key
|
|
|
|
|
|
|
+ actionPayload: ChangeCompMap.SOFTWARE.key
|
|
|
}
|
|
}
|
|
|
- const handleCompanyClick = () => {
|
|
|
|
|
- toggleDrawer()
|
|
|
|
|
- setDrawerProps({
|
|
|
|
|
- closable: true,
|
|
|
|
|
- onClose: () => toggleDrawer(),
|
|
|
|
|
- bodyStyle: {
|
|
|
|
|
- height: '100vh',
|
|
|
|
|
- overflowY: 'hidden'
|
|
|
|
|
- },
|
|
|
|
|
- children: <CompanyDetail dataId={customerId} />
|
|
|
|
|
- })
|
|
|
|
|
- toggleDrawer()
|
|
|
|
|
|
|
+
|
|
|
|
|
+ const changeCompanyInputData = {
|
|
|
|
|
+ customerId: longle.customerId,
|
|
|
|
|
+ dataId: longle.id,
|
|
|
|
|
+ customerName: longle.customerName,
|
|
|
|
|
+ targetName: longle.keyNum,
|
|
|
|
|
+ actionPayload: ChangeCompMap.SOFTWARE.key,
|
|
|
|
|
+ title: '软件锁'
|
|
|
}
|
|
}
|
|
|
|
|
+
|
|
|
// 出库状态
|
|
// 出库状态
|
|
|
const longleStockStatusNum = {
|
|
const longleStockStatusNum = {
|
|
|
1: '生成',
|
|
1: '生成',
|
|
@@ -59,6 +49,7 @@ const LockForm = props => {
|
|
|
// 0: '未使用',
|
|
// 0: '未使用',
|
|
|
// 1: '使用'
|
|
// 1: '使用'
|
|
|
// }
|
|
// }
|
|
|
|
|
+
|
|
|
return (
|
|
return (
|
|
|
<div>
|
|
<div>
|
|
|
<Row>
|
|
<Row>
|
|
@@ -130,14 +121,12 @@ const LockForm = props => {
|
|
|
<Divider style={{ margin: '12px 0' }} />
|
|
<Divider style={{ margin: '12px 0' }} />
|
|
|
<Col span={6}>单位名称</Col>
|
|
<Col span={6}>单位名称</Col>
|
|
|
<Col span={18}>
|
|
<Col span={18}>
|
|
|
- <span className="textPurple text-hex-967bbd cursor-pointer" onClick={handleCompanyClick}>
|
|
|
|
|
- {longle.customerName}
|
|
|
|
|
- </span>
|
|
|
|
|
|
|
+ <ChangeCompanyInput dataSource={changeCompanyInputData} />
|
|
|
</Col>
|
|
</Col>
|
|
|
<Divider style={{ margin: '12px 0' }} />
|
|
<Divider style={{ margin: '12px 0' }} />
|
|
|
<Col span={6}>客户</Col>
|
|
<Col span={6}>客户</Col>
|
|
|
<Col span={18}>
|
|
<Col span={18}>
|
|
|
- <ChangeClient dataSource={changeCopInputData} />
|
|
|
|
|
|
|
+ <ChangeClient dataSource={changeClientInputData} />
|
|
|
</Col>
|
|
</Col>
|
|
|
<Divider style={{ margin: '12px 0' }} />
|
|
<Divider style={{ margin: '12px 0' }} />
|
|
|
<Col span={6}>注册码</Col>
|
|
<Col span={6}>注册码</Col>
|