Commit 7ee86de6 authored by TZW's avatar TZW

111

parent e23bd161
import React, { useState, useEffect } from 'react'; import React, { useState, useEffect } from 'react';
import { ProDescriptions } from '@ant-design/pro-components'; import { ProDescriptions } from '@ant-design/pro-components';
import { Divider, Image, Collapse } from 'antd'; import { Divider, Image, Collapse } from 'antd';
import AutoTable from '../AutoTable/mtable';
const { Panel } = Collapse; const { Panel } = Collapse;
export default (props) => { export default (props) => {
...@@ -229,77 +229,6 @@ export default (props) => { ...@@ -229,77 +229,6 @@ export default (props) => {
dataIndex: 'repairContent', dataIndex: 'repairContent',
key: 'repairContent', key: 'repairContent',
}, },
{
title: '非寿命件消耗',
key: 'noLifeConsume',
valueType: 'table',
dataIndex: 'noLifeConsume',
columns: [
{
title: '备件料号',
dataIndex: 'sparePartNo',
key: 'sparePartNo',
},
{
title: '备件名称',
dataIndex: 'sparePartName',
key: 'sparePartName',
},
{
title: '供应商编号',
dataIndex: 'supplierNo',
key: 'supplierNo',
},
{
title: '供应商名称',
dataIndex: 'supplierName',
key: 'supplierName',
},
{
title: '消耗数量',
dataIndex: 'operateNum',
key: 'operateNum',
},
],
},
{
title: '寿命件更换',
key: 'yesLifeConsume',
valueType: 'table',
dataIndex: 'yesLifeConsume',
columns: [
{
title: '备件料号',
dataIndex: 'sparePartNo',
key: 'sparePartNo',
},
{
title: '备件名称',
dataIndex: 'sparePartName',
key: 'sparePartName',
},
{
title: '供应商编号',
dataIndex: 'supplierNo',
key: 'supplierNo',
},
{
title: '供应商名称',
dataIndex: 'supplierName',
key: 'supplierName',
},
{
title: '安装部位',
dataIndex: 'installPosition',
key: 'installPosition',
},
{
title: '更换数量',
dataIndex: 'operateNum',
key: 'operateNum',
},
],
},
], ],
4: [ 4: [
{ {
...@@ -674,7 +603,7 @@ export default (props) => { ...@@ -674,7 +603,7 @@ export default (props) => {
<div style={{ flex: 1, display: 'flex', flexDirection: 'row' }}> <div style={{ flex: 1, display: 'flex', flexDirection: 'row' }}>
<div className="fault-index ">{index}</div> <div className="fault-index ">{index}</div>
<div style={{ display: 'flex', flexDirection: 'column' }}> <div style={{ display: 'flex', flexDirection: 'column' }}>
<label style={{ width: '100px', fontSize: 18, fontWeight: 600 }}> <label style={{ width: '80px', fontSize: 18, fontWeight: 600 }}>
{dataSource?.operationTypeName} {dataSource?.operationTypeName}
</label> </label>
<span>{dataSource?.updateUserName}</span> <span>{dataSource?.updateUserName}</span>
...@@ -689,6 +618,83 @@ export default (props) => { ...@@ -689,6 +618,83 @@ export default (props) => {
dataSource={dataSource} dataSource={dataSource}
columns={columns_wxgd[dataSource?.operationType]} columns={columns_wxgd[dataSource?.operationType]}
/> />
{dataSource?.operationType == 3 ? (
<>
<div style={{ marginTop: 8, marginBottom: 8 }}>
<b>非寿命件消耗</b>
<AutoTable
dataSource={dataSource?.noLifeConsume}
columns={[
{
title: '备件料号',
dataIndex: 'sparePartNo',
key: 'sparePartNo',
},
{
title: '备件名称',
dataIndex: 'sparePartName',
key: 'sparePartName',
},
{
title: '供应商编号',
dataIndex: 'supplierNo',
key: 'supplierNo',
},
{
title: '供应商名称',
dataIndex: 'supplierName',
key: 'supplierName',
},
{
title: '消耗数量',
dataIndex: 'operateNum',
key: 'operateNum',
},
]}
style={{ marginTop: 8 }}
/>
</div>
<div style={{ marginTop: 8, marginBottom: 8 }}>
<b>寿命件更换</b>
<AutoTable
dataSource={dataSource?.yesLifeConsume}
columns={[
{
title: '备件料号',
dataIndex: 'sparePartNo',
key: 'sparePartNo',
},
{
title: '备件名称',
dataIndex: 'sparePartName',
key: 'sparePartName',
},
{
title: '供应商编号',
dataIndex: 'supplierNo',
key: 'supplierNo',
},
{
title: '供应商名称',
dataIndex: 'supplierName',
key: 'supplierName',
},
{
title: '安装部位',
dataIndex: 'installPosition',
key: 'installPosition',
},
{
title: '更换数量',
dataIndex: 'operateNum',
key: 'operateNum',
},
]}
style={{ marginTop: 8 }}
/>
</div>
</>
) : null}
</div> </div>
</div> </div>
</div> </div>
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* @Author: Li Hanlin * @Author: Li Hanlin
* @Date: 2023-01-19 09:53:59 * @Date: 2023-01-19 09:53:59
* @Last Modified by: Li Hanlin * @Last Modified by: Li Hanlin
* @Last Modified time: 2023-02-24 15:56:19 * @Last Modified time: 2023-02-24 17:39:49
*/ */
import * as React from 'react'; import * as React from 'react';
......
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