Commit 2cd55116 authored by TZW's avatar TZW

qweqwe

parent c64cfb4d
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* @Author: Li Hanlin * @Author: Li Hanlin
* @Date: 2022-11-10 09:39:56 * @Date: 2022-11-10 09:39:56
* @Last Modified by: Li Hanlin * @Last Modified by: Li Hanlin
* @Last Modified time: 2022-12-16 15:40:58 * @Last Modified time: 2022-12-16 21:23:19
*/ */
import * as React from 'react'; import * as React from 'react';
...@@ -255,68 +255,35 @@ function Model(props) { ...@@ -255,68 +255,35 @@ function Model(props) {
}, },
{ {
title: '借用公司', title: '借用公司',
dataIndex: 'organizationName', dataIndex: 'toOrganizationName',
key: 'toOrganizationId', key: 'toOrganizationName',
valueType: 'select',
options: { path: '/auth/sysDepartment/query/organization/selectbox', params: {} },
formItemProps: { rules: [{ required: true, message: '此项为必填项' }] },
}, },
{ {
title: '借用部门', title: '借用部门',
valueType: 'treeSelect', valueType: 'treeSelect',
dataIndex: 'departmentName', dataIndex: 'toDepartmentName',
key: 'toDepartmentId', key: 'toDepartmentName',
options: {
path: '/auth/sysDepartment/query/children/tree',
linkParams: {
toOrganizationId: 'parentId',
},
},
}, },
{ {
title: '借用工厂', title: '借用工厂',
dataIndex: 'factoryName', dataIndex: 'toFactoryName',
key: 'toFactoryId', key: 'toFactoryName',
valueType: 'select',
options: { path: '/auth/sysFactory/getAllFactorySelection', params: {} },
formItemProps: { rules: [{ required: true, message: '此项为必填项' }] },
}, },
{ {
title: '借用车间', title: '借用车间',
dataIndex: 'shopName', dataIndex: 'toShopName',
valueType: 'select', valueType: 'select',
options: { key: 'toShopName',
path: '/auth/sysShop/getShopSelectionByFactory',
linkParams: {
toFactoryId: 'factoryId',
},
},
key: 'toShopId',
formItemProps: { rules: [{ required: true, message: '此项为必填项' }] },
}, },
{ {
title: '借用工段', title: '借用工段',
dataIndex: 'sectionName', dataIndex: 'toSectionName',
key: 'toSectionId', key: 'toSectionName',
valueType: 'select',
options: {
path: '/auth/sysSection/getAllSectionSelectionByShop',
linkParams: {
toShopId: 'shopId',
},
},
}, },
{ {
title: '借用产线', title: '借用产线',
dataIndex: 'productionLines', dataIndex: 'toProductLineName',
valueType: 'select', key: 'toProductLineName',
key: 'toProductLineId',
options: {
path: '/auth/sysProductionLine/getAllProductLineSelectionByShop',
linkParams: {
toShopId: 'shopId',
},
},
}, },
{ {
title: '借用位置号', title: '借用位置号',
...@@ -359,8 +326,8 @@ function Model(props) { ...@@ -359,8 +326,8 @@ function Model(props) {
}, },
{ {
title: '接收公司', title: '接收公司',
dataIndex: 'returnOrganizationId', dataIndex: 'returnOrganizationName',
key: 'returnOrganizationId', key: 'returnOrganizationName',
valueType: 'select', valueType: 'select',
options: { path: '/auth/sysDepartment/query/organization/selectbox', params: {} }, options: { path: '/auth/sysDepartment/query/organization/selectbox', params: {} },
formItemProps: { rules: [{ required: true, message: '此项为必填项' }] }, formItemProps: { rules: [{ required: true, message: '此项为必填项' }] },
...@@ -368,8 +335,8 @@ function Model(props) { ...@@ -368,8 +335,8 @@ function Model(props) {
{ {
title: '接收部门', title: '接收部门',
valueType: 'treeSelect', valueType: 'treeSelect',
dataIndex: 'returnDepartmentId', dataIndex: 'returnDepartmentName',
key: 'returnDepartmentId', key: 'returnDepartmentName',
options: { options: {
path: '/auth/sysDepartment/query/children/tree', path: '/auth/sysDepartment/query/children/tree',
linkParams: { linkParams: {
...@@ -379,15 +346,15 @@ function Model(props) { ...@@ -379,15 +346,15 @@ function Model(props) {
}, },
{ {
title: '接收工厂', title: '接收工厂',
dataIndex: 'returnFactoryId', dataIndex: 'returnFactoryName',
key: 'returnFactoryId', key: 'returnFactoryName',
valueType: 'select', valueType: 'select',
options: { path: '/auth/sysFactory/getAllFactorySelection', params: {} }, options: { path: '/auth/sysFactory/getAllFactorySelection', params: {} },
formItemProps: { rules: [{ required: true, message: '此项为必填项' }] }, formItemProps: { rules: [{ required: true, message: '此项为必填项' }] },
}, },
{ {
title: '接收车间', title: '接收车间',
dataIndex: 'returnShopId', dataIndex: 'returnShopName',
valueType: 'select', valueType: 'select',
options: { options: {
path: '/auth/sysShop/getShopSelectionByFactory', path: '/auth/sysShop/getShopSelectionByFactory',
...@@ -400,7 +367,7 @@ function Model(props) { ...@@ -400,7 +367,7 @@ function Model(props) {
}, },
{ {
title: '接收工段', title: '接收工段',
dataIndex: 'returnSectionId', dataIndex: 'returnSectionName',
key: 'returnSectionId', key: 'returnSectionId',
valueType: 'select', valueType: 'select',
options: { options: {
...@@ -412,7 +379,7 @@ function Model(props) { ...@@ -412,7 +379,7 @@ function Model(props) {
}, },
{ {
title: '接收产线', title: '接收产线',
dataIndex: 'returnProductLineId', dataIndex: 'returnProductLineName',
valueType: 'select', valueType: 'select',
key: 'returnProductLineId', key: 'returnProductLineId',
options: { options: {
...@@ -567,6 +534,9 @@ function Model(props) { ...@@ -567,6 +534,9 @@ function Model(props) {
id: row.id, id: row.id,
reformDate: formatDate(new Date()), reformDate: formatDate(new Date()),
scrapDate: formatDate(new Date()), scrapDate: formatDate(new Date()),
transferDate: formatDate(new Date()),
borrowDate: formatDate(new Date()),
realReturnDate: formatDate(new Date()),
}, },
val: 'only', val: 'only',
title: '履历登记', title: '履历登记',
...@@ -1073,6 +1043,7 @@ function Model(props) { ...@@ -1073,6 +1043,7 @@ function Model(props) {
dataIndex: 'createTime', dataIndex: 'createTime',
key: 'createTime', key: 'createTime',
width: 120, width: 120,
searchValueType: 'timeRange',
formItemProps: { rules: [{ required: true, message: '此项为必填项' }] }, formItemProps: { rules: [{ required: true, message: '此项为必填项' }] },
}, },
{ {
...@@ -1764,7 +1735,7 @@ function Model(props) { ...@@ -1764,7 +1735,7 @@ function Model(props) {
dataIndex: 'remark', dataIndex: 'remark',
key: 'remark', key: 'remark',
valueType: 'textarea', valueType: 'textarea',
formItemProps: { rules: [{ required: true, message: '此项为必填项' }] }, formItemProps: { rules: [{ required: false, message: '此项为必填项' }] },
}, },
], ],
}; };
...@@ -1905,6 +1876,7 @@ function Model(props) { ...@@ -1905,6 +1876,7 @@ function Model(props) {
children: activeTab == 3 && ( children: activeTab == 3 && (
<InitForm <InitForm
fields={fields[activeTab]} fields={fields[activeTab]}
defaultFormValue={drawer?.item}
onFinish={async (vals) => { onFinish={async (vals) => {
//console.log(vals); //console.log(vals);
let res = await doFetch({ let res = await doFetch({
...@@ -1929,6 +1901,7 @@ function Model(props) { ...@@ -1929,6 +1901,7 @@ function Model(props) {
key: 4, key: 4,
children: activeTab == 4 && ( children: activeTab == 4 && (
<InitForm <InitForm
defaultFormValue={drawer?.item}
fields={fields[activeTab]} fields={fields[activeTab]}
onFinish={async (vals) => { onFinish={async (vals) => {
//console.log(vals); //console.log(vals);
...@@ -1955,6 +1928,7 @@ function Model(props) { ...@@ -1955,6 +1928,7 @@ function Model(props) {
children: activeTab == 5 && ( children: activeTab == 5 && (
<InitForm <InitForm
fields={fields[activeTab]} fields={fields[activeTab]}
defaultFormValue={drawer?.item}
onFinish={async (vals) => { onFinish={async (vals) => {
//console.log(vals); //console.log(vals);
let res = await doFetch({ let res = await doFetch({
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* @Author: Li Hanlin * @Author: Li Hanlin
* @Date: 2022-11-09 14:44:44 * @Date: 2022-11-09 14:44:44
* @Last Modified by: Li Hanlin * @Last Modified by: Li Hanlin
* @Last Modified time: 2022-12-16 20:20:17 * @Last Modified time: 2022-12-16 20:51:25
*/ */
import * as React from 'react'; import * as React from 'react';
...@@ -160,7 +160,7 @@ function User(props) { ...@@ -160,7 +160,7 @@ function User(props) {
setDrawer={setDrawer} setDrawer={setDrawer}
drawer={drawer} drawer={drawer}
formRef={formRef} formRef={formRef}
columns={columns} columns={getcolumns(false, formRef)}
formId={'1'} formId={'1'}
// urlParams={urlParams} // urlParams={urlParams}
onFinish={async (vals) => { onFinish={async (vals) => {
......
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