Commit 9690d0f7 authored by TZW's avatar TZW

1007

parent f7862cfa
......@@ -83,11 +83,15 @@ function Expandables({ value = [], onChange, item }) {
editable: false,
},
{
title: '更换数量',
title: (
<div>
更换数量 <span style={{ color: 'red' }}>* </span>
</div>
),
dataIndex: 'operateNum',
search: false,
key: 'operateNum',
valueType: 'input',
valueType: 'digit',
fieldProps: {
precision: 3,
},
......
......@@ -2,7 +2,7 @@
* @Author: Li Hanlin
* @Date: 2023-01-19 09:53:59
* @Last Modified by: Li Hanlin
* @Last Modified time: 2023-02-24 19:18:49
* @Last Modified time: 2023-02-27 09:44:54
*/
import * as React from 'react';
......@@ -14,7 +14,7 @@ import getcolumns from './columns';
import { useRequest } from 'ahooks';
import { doFetch } from '@/utils/doFetch';
import AutoTables from '@/components/AutoTable/mtable';
import { Radio, InputNumber, Input, Divider } from 'antd';
import { Radio, InputNumber, Input, Divider, message } from 'antd';
import InitForm from '@/components/InitForm';
import getDetailColumns from './detailColumns';
import { useModel } from '@umijs/max';
......@@ -34,6 +34,7 @@ function WorkOrder(props) {
manual: true,
onSuccess: (res, params) => {
if (res?.code == '0000') {
message.success('操作成功!');
actionRef?.current?.reload();
setdrawer((s) => ({
...s,
......@@ -603,8 +604,8 @@ function WorkOrder(props) {
valueType: 'split',
},
{
dataIndex: 'ifePieceStockUseList',
key: 'ifePieceStockUseList',
dataIndex: 'lifePieceStockUseList',
key: 'lifePieceStockUseList',
valueType: 'Expandable',
colProps: {
span: 24,
......@@ -652,7 +653,7 @@ function WorkOrder(props) {
],
path: '/sparepart/lifePieceAccount/queryPageByEquipment',
extraparams: { equipmentId: drawer?.item?.equipmentId },
expandablePath: '/sparepart/lineStock/queryReplaceStock',
expandablePath: '/sparepart/lineStock/queryReplaceStockAll',
},
]}
onFinish={(vals) => {
......@@ -677,14 +678,14 @@ function WorkOrder(props) {
lineStockId: it?.id,
operateNum: it?.operateNum,
})) ?? [];
let ifePieceStockUseList = vals?.ifePieceStockUseList ?? [];
let lifePieceStockUseList = vals?.lifePieceStockUseList ?? [];
run({
url: '/maintain/umMaintainTask/finishMaintainTask',
params: {
id: drawer?.item?.id,
maintainTaskItemList,
lineStockUseList,
ifePieceStockUseList,
lifePieceStockUseList,
},
});
}}
......
......@@ -3,7 +3,7 @@
* @Author: Li Hanlin
* @Date: 2022-12-02 11:41:03
* @Last Modified by: Li Hanlin
* @Last Modified time: 2023-02-24 19:10:16
* @Last Modified time: 2023-02-27 09:12:42
*/
import * as React from 'react';
......@@ -711,90 +711,6 @@ function Failure(props) {
};
// 完成维修
const Finishrepair = () => {
// const EditTableItem = ({ record }) => {
// const [value, setvalue] = useState([]);
// return (
// <div>
// <EditTable
// resizeable={false}
// alwaysShowAlert={false}
// tableAlertRender={false}
// tableAlertOptionRender={false}
// columns={[
// {
// title: '线边库',
// dataIndex: 'supplierNo',
// key: 'supplierNo',
// editable: false,
// },
// {
// title: '供应商编号',
// dataIndex: 'supplierNo',
// key: 'supplierNo',
// span: 3,
// editable: false,
// },
// {
// title: '供应商名称',
// dataIndex: 'supplierName',
// key: 'supplierName',
// span: 3,
// editable: false,
// },
// {
// title: '可用数量',
// dataIndex: 'usedStock',
// key: 'usedStock',
// search: false,
// span: 3,
// editable: false,
// },
// {
// title: (
// <div>
// 更换数量 <span style={{ color: 'red' }}>* </span>
// </div>
// ),
// search: false,
// dataIndex: 'operateNum',
// valueType: 'digit',
// fieldProps: {
// precision: 3,
// },
// key: 'operateNum',
// span: 3,
// hideInForm: true,
// editable: true,
// },
// ]}
// path="/sparepart/lineStock/queryReplaceStock"
// extraparams={{ lifePieceAccountId: record?.id }}
// rowSelection={{
// type: 'checkbox',
// columnWidth: 44,
// preserveSelectedRowKeys: true,
// selectedRowKeys: value?.map((it) => it?.lineStockId) ?? [],
// onChange: (selectedKeys, selectedRows) => {
// const lineStockUseList = selectedRows?.map((it) => {
// return { lineStockId: it?.id, operateNum: it?.operateNum };
// });
// setvalue(lineStockUseList);
// },
// }}
// editable={{
// onValuesChange: (rower, recordList) => {
// setvalue((value) => {
// const curkey = value?.map((it) => it?.lineStockId);
// const newValue = value.concat(rower);
// return [...newValue];
// });
// },
// }}
// />
// </div>
// );
// };
const columns_fsmjxh = [
{
title: '线边库',
......@@ -846,7 +762,7 @@ function Failure(props) {
),
search: false,
dataIndex: 'operateNum',
valueType: 'input',
valueType: 'digit',
fieldProps: {
precision: 3,
},
......@@ -1002,8 +918,8 @@ function Failure(props) {
},
{
title: '寿命件更换',
dataIndex: 'ifePieceStockUseList',
key: 'ifePieceStockUseList',
dataIndex: 'lifePieceStockUseList',
key: 'lifePieceStockUseList',
valueType: 'Expandable',
colProps: {
span: 24,
......@@ -1090,7 +1006,7 @@ function Failure(props) {
lineStockId: it?.id,
operateNum: it?.operateNum,
})),
ifePieceStockUseList: vals?.ifePieceStockUseList,
lifePieceStockUseList: vals?.lifePieceStockUseList,
};
let res = await doFetch({
url: '/repair/umRepairOrder/completeRepair',
......
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