Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
E
ems3.3
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wuhao
ems3.3
Commits
97b50a3a
Commit
97b50a3a
authored
Dec 12, 2022
by
TZW
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
12121648
parent
53be0daa
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
199 additions
and
118 deletions
+199
-118
mtable.jsx
src/components/AutoTable/mtable.jsx
+2
-0
DesItem.jsx
src/components/RepaireDetail/DesItem.jsx
+139
-104
Detail.jsx
src/components/RepaireDetail/Detail.jsx
+40
-2
columns.js
src/pages/device/supplier/columns.js
+3
-1
index.jsx
src/pages/repair/order/index.jsx
+15
-11
No files found.
src/components/AutoTable/mtable.jsx
View file @
97b50a3a
...
@@ -209,6 +209,8 @@ const Mtable = (props) => {
...
@@ -209,6 +209,8 @@ const Mtable = (props) => {
return
{
return
{
...
it
,
...
it
,
...
options
,
...
options
,
key
:
it
.
searchKey
??
it
?.
key
,
valueType
:
it
.
searchValueType
??
it
?.
valueType
,
};
};
});
});
},
[
columns
,
newparames
]);
},
[
columns
,
newparames
]);
...
...
src/components/RepaireDetail/DesItem.jsx
View file @
97b50a3a
...
@@ -2,105 +2,106 @@ import React, { useState, useEffect } from 'react';
...
@@ -2,105 +2,106 @@ import React, { useState, useEffect } from 'react';
import
{
ProDescriptions
}
from
'@ant-design/pro-components'
;
import
{
ProDescriptions
}
from
'@ant-design/pro-components'
;
import
{
Divider
,
Image
}
from
'antd'
;
import
{
Divider
,
Image
}
from
'antd'
;
export
default
({
index
,
title
,
dataSource
,
columns
,
hidden
})
=>
{
export
default
({
index
,
title
,
dataSource
,
columns
,
hidden
,
navhidden
=
false
})
=>
{
const
[
flag
,
setflag
]
=
useState
(
true
);
const
[
flag
,
setflag
]
=
useState
(
true
);
// 0:报修 1:接单 2:派单 3:完成维修 4:转追踪 5:转外协 6:转单 7:退单 8:追踪审核 9:外协审核 10:退单审核 11:效果验证
// 0:报修 1:接单 2:派单 3:完成维修 4:转追踪 5:转外协 6:转单 7:退单 8:追踪审核 9:外协审核 10:退单审核 11:效果验证
const
columns_mes
=
{
const
columns_mes
=
{
sbxx
:
[
sbxx
:
[
{
{
title
:
'设备编号'
,
title
:
'设备编号'
,
dataIndex
:
'equipmentNo'
,
dataIndex
:
'equipmentNo'
,
key
:
'equipmentNo'
,
key
:
'equipmentNo'
,
},
},
{
{
title
:
'设备名称'
,
title
:
'设备名称'
,
dataIndex
:
'equipmentName'
,
dataIndex
:
'equipmentName'
,
key
:
'equipmentName'
,
key
:
'equipmentName'
,
},
},
{
{
title
:
'设备型号'
,
title
:
'设备型号'
,
dataIndex
:
'equipmentName'
,
dataIndex
:
'equipmentName'
,
key
:
'equipmentName'
,
key
:
'equipmentName'
,
},
},
{
{
title
:
'公司名称'
,
title
:
'公司名称'
,
dataIndex
:
'organizationName'
,
dataIndex
:
'organizationName'
,
key
:
'organizationId'
,
key
:
'organizationId'
,
},
},
{
{
title
:
'部门名称'
,
title
:
'部门名称'
,
dataIndex
:
'departmentName'
,
dataIndex
:
'departmentName'
,
key
:
'departmentId'
,
key
:
'departmentId'
,
},
},
{
{
title
:
'工厂名称'
,
title
:
'工厂名称'
,
dataIndex
:
'factoryName'
,
dataIndex
:
'factoryName'
,
key
:
'factoryId'
,
key
:
'factoryId'
,
},
},
{
{
title
:
'车间名称'
,
title
:
'车间名称'
,
dataIndex
:
'shopName'
,
dataIndex
:
'shopName'
,
key
:
'shopId'
,
key
:
'shopId'
,
},
},
{
{
title
:
'工段名称'
,
title
:
'工段名称'
,
dataIndex
:
'sectionName'
,
dataIndex
:
'sectionName'
,
key
:
'sectionId'
,
key
:
'sectionId'
,
},
},
{
{
title
:
'产线名称'
,
title
:
'产线名称'
,
dataIndex
:
'productLineName'
,
dataIndex
:
'productLineName'
,
key
:
'productLineName'
,
key
:
'productLineName'
,
},
},
],
],
gzxx
:
[
gzxx
:
[
{
{
title
:
'报修人员'
,
title
:
'报修人员'
,
dataIndex
:
'repairUserName'
,
dataIndex
:
'repairUserName'
,
key
:
'repairUserName'
,
key
:
'repairUserName'
,
},
},
{
{
title
:
'报修时间'
,
title
:
'报修时间'
,
dataIndex
:
'repairTime'
,
dataIndex
:
'repairTime'
,
key
:
'repairTime'
,
key
:
'repairTime'
,
},
},
{
{
title
:
'是否停机'
,
title
:
'是否停机'
,
dataIndex
:
'isShutdown'
,
dataIndex
:
'isShutdown'
,
key
:
'isShutdown'
,
key
:
'isShutdown'
,
render
:
(
text
,
row
,
_
,
action
)
=>
{
render
:
(
text
,
row
,
_
,
action
)
=>
{
return
row
?.
isShutdown
==
'1'
?
'是'
:
'否'
;
return
row
?.
isShutdown
==
'1'
?
'是'
:
'否'
;
},
},
},
},
{
{
title
:
'故障类型'
,
title
:
'故障类型'
,
dataIndex
:
'faultType'
,
dataIndex
:
'faultType'
,
key
:
'faultType'
,
key
:
'faultType'
,
},
},
{
{
title
:
'故障名称'
,
title
:
'故障名称'
,
dataIndex
:
'faultDetailName'
,
dataIndex
:
'faultDetailName'
,
key
:
'faultDetailName'
,
key
:
'faultDetailName'
,
},
},
{
{
title
:
'故障描述'
,
title
:
'故障描述'
,
dataIndex
:
'faultDescription'
,
dataIndex
:
'faultDescription'
,
key
:
'faultDescription'
,
key
:
'faultDescription'
,
},
},
{
{
title
:
'故障图片'
,
title
:
'故障图片'
,
dataIndex
:
'pictureUrl'
,
dataIndex
:
'pictureUrl'
,
key
:
'pictureUrl'
,
key
:
'pictureUrl'
,
render
:
(
text
,
row
,
_
,
action
)
=>
{
render
:
(
text
,
row
,
_
,
action
)
=>
{
if
(
row
?.
pictureUrl
)
{
if
(
row
?.
pictureUrl
)
{
return
<
Image
width=
{
70
}
src=
{
row
.
pictureUrl
}
/>;
return
<
Image
width=
{
70
}
src=
{
row
.
pictureUrl
}
/>;
}
else
{
}
else
{
return
'暂无'
;
return
'暂无'
;
}
}
},
},
},
},
],
],
};
},
columns_wxgd
=
{};
useEffect
(()
=>
{
useEffect
(()
=>
{
setflag
(
hidden
);
setflag
(
hidden
);
},
[]);
},
[]);
...
@@ -110,15 +111,43 @@ export default ({ index, title, dataSource, columns, hidden }) => {
...
@@ -110,15 +111,43 @@ export default ({ index, title, dataSource, columns, hidden }) => {
{
flag
?
(
{
flag
?
(
<
div
>
<
div
>
{
index
==
0
?
(
{
index
==
0
?
(
<
div
>
navhidden
?
(
<
div
>
<
div
>
<
h2
className=
"page-title"
>
{
title
}
</
h2
>
<
div
>
<
h2
className=
"page-title"
>
{
title
}
</
h2
>
</
div
>
<
Divider
orientation=
"left"
>
设备信息
</
Divider
>
<
ProDescriptions
dataSource=
{
dataSource
?.
equipment
}
columns=
{
columns_mes
[
'sbxx'
]
}
/>
<
Divider
orientation=
"left"
>
故障信息
</
Divider
>
<
ProDescriptions
dataSource=
{
dataSource
}
columns=
{
columns_mes
[
'gzxx'
]
}
/>
</
div
>
</
div
>
<
Divider
orientation=
"left"
>
设备信息
</
Divider
>
)
:
(
<
ProDescriptions
dataSource=
{
dataSource
?.
equipment
}
columns=
{
columns_mes
[
'sbxx'
]
}
/>
<
div
>
<
Divider
orientation=
"left"
>
故障信息
</
Divider
>
<
div
style=
{
{
borderLeft
:
'1px solid #ccc'
}
}
>
<
ProDescriptions
dataSource=
{
dataSource
}
columns=
{
columns_mes
[
'gzxx'
]
}
/>
<
span
</
div
>
style=
{
{
border
:
'1px solid #ccc'
,
backgroundColor
:
'white'
,
borderRidus
:
'30%'
,
}
}
>
{
index
}
</
span
>
</
div
>
<
div
>
<
div
>
<
h2
className=
"page-title"
>
{
title
}
</
h2
>
</
div
>
<
Divider
orientation=
"left"
>
设备信息
</
Divider
>
<
ProDescriptions
dataSource=
{
dataSource
?.
equipment
}
columns=
{
columns_mes
[
'sbxx'
]
}
/>
<
Divider
orientation=
"left"
>
故障信息
</
Divider
>
<
ProDescriptions
dataSource=
{
dataSource
}
columns=
{
columns_mes
[
'gzxx'
]
}
/>
</
div
>
</
div
>
)
)
:
(
)
:
(
<
div
>
<
div
>
<
div
style=
{
{
borderLeft
:
'1px solid #ccc'
}
}
>
<
div
style=
{
{
borderLeft
:
'1px solid #ccc'
}
}
>
...
@@ -128,7 +157,13 @@ export default ({ index, title, dataSource, columns, hidden }) => {
...
@@ -128,7 +157,13 @@ export default ({ index, title, dataSource, columns, hidden }) => {
{
index
}
{
index
}
</
span
>
</
span
>
</
div
>
</
div
>
<
ProDescriptions
dataSource=
{
dataSource
}
columns=
{
columns
}
/>
<
div
>
<
div
>
<
h2
className=
"page-title"
>
{
dataSource
?.
operationTypeName
}
信息
</
h2
>
</
div
>
<
ProDescriptions
dataSource=
{
dataSource
?.
equipment
}
columns=
{
columns_mes
[
'sbxx'
]
}
/>
<
ProDescriptions
dataSource=
{
dataSource
}
columns=
{
columns_mes
[
'gzxx'
]
}
/>
</
div
>
</
div
>
</
div
>
)
}
)
}
</
div
>
</
div
>
...
...
src/components/RepaireDetail/Detail.jsx
View file @
97b50a3a
...
@@ -15,7 +15,45 @@ export default (props) => {
...
@@ -15,7 +15,45 @@ export default (props) => {
console
.
log
(
request
);
console
.
log
(
request
);
const
selectType
=
{
const
selectType
=
{
gzbx
:
<
DesItem
index=
"0"
dataSource=
{
request
?.
data
}
title=
"基本信息"
hidden=
{
true
}
/>,
gzbx
:
(
<
DesItem
type=
"gzbx"
index=
"0"
dataSource=
{
request
?.
data
}
title=
"基本信息"
hidden=
{
true
}
navhidden=
{
true
}
/>
),
wxgd
:
<
Wxgd
/>,
};
// 维修工单
const
Wxgd
=
()
=>
{
return
(
<>
<
DesItem
type=
"wxgd"
dataSource=
{
request
?.
data
}
title=
"报修信息"
hidden=
{
true
}
navhidden=
{
false
}
/>
{
request
?.
data
?.
map
((
it
,
index
)
=>
{
return
(
<>
<
DesItem
type=
"wxgd"
dataSource=
{
request
?.
data
}
title=
"报修信息"
hidden=
{
true
}
navhidden=
{
false
}
/>
</>
);
})
}
</>
);
};
};
return
(
return
(
<>
<>
...
@@ -26,7 +64,7 @@ export default (props) => {
...
@@ -26,7 +64,7 @@ export default (props) => {
</
div
>
</
div
>
<
ProDescriptions
columns=
{
basecolumns
}
dataSource=
{
request
.
data
}
/>
<
ProDescriptions
columns=
{
basecolumns
}
dataSource=
{
request
.
data
}
/>
<
Divider
/>
<
Divider
/>
{
selectType
[
'gzbx'
]
}
{
selectType
[
type
]
}
</>
</>
);
);
};
};
src/pages/device/supplier/columns.js
View file @
97b50a3a
...
@@ -84,7 +84,6 @@ function getcolumns(setdrawer) {
...
@@ -84,7 +84,6 @@ function getcolumns(setdrawer) {
title
:
'状态'
,
title
:
'状态'
,
dataIndex
:
'status'
,
dataIndex
:
'status'
,
key
:
'status'
,
key
:
'status'
,
search
:
false
,
valueType
:
'radio'
,
valueType
:
'radio'
,
formItemProps
:
{
formItemProps
:
{
rules
:
[
rules
:
[
...
@@ -134,8 +133,11 @@ function getcolumns(setdrawer) {
...
@@ -134,8 +133,11 @@ function getcolumns(setdrawer) {
key
:
'score'
,
key
:
'score'
,
width
:
50
,
width
:
50
,
valueType
:
'rate'
,
valueType
:
'rate'
,
searchValueType
:
'digit'
,
fieldProps
:
{
fieldProps
:
{
defaultValue
:
1
,
defaultValue
:
1
,
max
:
5
,
precision
:
1
,
},
},
formItemProps
:
{
formItemProps
:
{
rules
:
[
rules
:
[
...
...
src/pages/repair/order/index.jsx
View file @
97b50a3a
...
@@ -2,7 +2,7 @@
...
@@ -2,7 +2,7 @@
* @Author: Li Hanlin
* @Author: Li Hanlin
* @Date: 2022-12-02 11:41:03
* @Date: 2022-12-02 11:41:03
* @Last Modified by: Li Hanlin
* @Last Modified by: Li Hanlin
* @Last Modified time: 2022-12-12 1
4:20:44
* @Last Modified time: 2022-12-12 1
5:59:07
*/
*/
import
*
as
React
from
'react'
;
import
*
as
React
from
'react'
;
...
@@ -1045,7 +1045,7 @@ function Failure(props) {
...
@@ -1045,7 +1045,7 @@ function Failure(props) {
};
};
const
basecolumns
=
useMemo
(()
=>
{
const
basecolumns
=
useMemo
(()
=>
{
if
(
activeTabKey
==
1
)
{
if
(
activeTabKey
==
3
)
{
return
[
return
[
{
{
title
:
'创建时间'
,
title
:
'创建时间'
,
...
@@ -1064,8 +1064,13 @@ function Failure(props) {
...
@@ -1064,8 +1064,13 @@ function Failure(props) {
},
},
{
{
title
:
'最新维修人员'
,
title
:
'最新维修人员'
,
dataIndex
:
'repairNo'
,
dataIndex
:
'newRepairUserName'
,
key
:
'repairNo'
,
key
:
'newRepairUserName'
,
},
{
title
:
'关单时间'
,
dataIndex
:
'repairCloseTime'
,
key
:
'repairCloseTime'
,
},
},
];
];
}
else
{
}
else
{
...
@@ -1081,15 +1086,14 @@ function Failure(props) {
...
@@ -1081,15 +1086,14 @@ function Failure(props) {
key
:
'statusName'
,
key
:
'statusName'
,
},
},
{
{
title
:
'
维
修单号'
,
title
:
'
报
修单号'
,
dataIndex
:
'repair
Order
No'
,
dataIndex
:
'repairNo'
,
key
:
'repair
Order
No'
,
key
:
'repairNo'
,
},
},
{
{
title
:
'关单时间'
,
title
:
'最新维修人员'
,
dataIndex
:
'faultDescription'
,
dataIndex
:
'newRepairUserName'
,
key
:
'faultDescription'
,
key
:
'newRepairUserName'
,
valueType
:
'textarea'
,
},
},
];
];
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment