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
a8aaeab0
Commit
a8aaeab0
authored
Jan 31, 2023
by
TZW
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ccc
parent
557da31f
Changes
6
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
523 additions
and
472 deletions
+523
-472
index.jsx
src/components/InitForm/index.jsx
+1
-1
index.jsx
src/pages/device/account/index.jsx
+498
-464
index.jsx
src/pages/repair/order/index.jsx
+5
-5
columns.js
src/pages/repair/track/columns.js
+1
-1
index.jsx
src/pages/repair/track/index.jsx
+1
-1
columns.js
src/pages/setting/users/columns.js
+17
-0
No files found.
src/components/InitForm/index.jsx
View file @
a8aaeab0
...
...
@@ -182,7 +182,7 @@ function InitForm(props) {
}
}
>
<
FormRender
fields=
{
fields
.
filter
((
it
)
=>
it
.
valueType
!=
'option'
)
}
fields=
{
fields
?
.
filter
((
it
)
=>
it
.
valueType
!=
'option'
)
}
colProps=
{
colProps
}
proformRef=
{
proformRef
}
/>
...
...
src/pages/device/account/index.jsx
View file @
a8aaeab0
...
...
@@ -2,7 +2,7 @@
* @Author: Li Hanlin
* @Date: 2022-11-10 09:39:56
* @Last Modified by: Li Hanlin
* @Last Modified time: 2023-01-31 1
5:25:02
* @Last Modified time: 2023-01-31 1
7:38:49
*/
import
*
as
React
from
'react'
;
...
...
@@ -12,7 +12,18 @@ import AutoTable from '@/components/AutoTable';
import
PremButton
from
'@/components/PremButton'
;
import
getcolumns
from
'./columns'
;
import
{
doFetch
}
from
'@/utils/doFetch'
;
import
{
message
,
Dropdown
,
Menu
,
Layout
,
Button
,
Image
,
Space
,
Divider
,
Tabs
}
from
'antd'
;
import
{
message
,
Dropdown
,
Menu
,
Layout
,
Button
,
Image
,
Space
,
Divider
,
Tabs
,
Tooltip
,
}
from
'antd'
;
import
TreeRender
from
'@/components/TreeRender'
;
import
{
ProDescriptions
}
from
'@ant-design/pro-components'
;
import
InitForm
from
'@/components/InitForm'
;
...
...
@@ -30,6 +41,7 @@ function Model(props) {
[
currDrawer
,
setCurrDrawer
]
=
useState
({
visible
:
false
,
}),
[
resumeTab
,
setresumeTab
]
=
useState
(
null
),
currfields
=
{
1
:
[
{
...
...
@@ -549,8 +561,8 @@ function Model(props) {
url
:
'/asset/equipmentLog/getAllResumeType'
,
params
:
{
equipmentId
:
row
?.
id
},
});
console
.
log
(
res
);
setDrawer
((
s
)
=>
({
await
setresumeTab
(
res
?.
data
?.
dataList
);
await
setDrawer
((
s
)
=>
({
...
s
,
visible
:
true
,
type
:
'resume'
,
...
...
@@ -1499,7 +1511,6 @@ function Model(props) {
const
Resume
=
()
=>
{
const
[
selectArr
,
setSelectArr
]
=
useState
([]);
const
[
activeTab
,
setactiveTab
]
=
useState
(
1
);
useEffect
(()
=>
{
const
fun
=
async
()
=>
{
const
result
=
await
doFetch
({
...
...
@@ -1512,8 +1523,18 @@ function Model(props) {
}
};
fun
();
let
dis
=
resumeTab
?.
filter
((
it
)
=>
it
?.
disabled
);
if
(
dis
.
length
>
0
&&
dis
[
0
].
key
==
1
)
{
setactiveTab
(
menulist
?.
filter
((
it
)
=>
!
dis
?.
map
((
item
)
=>
item
.
key
).
includes
(
it
?.
key
))[
0
]?.
key
,
);
}
else
{
setactiveTab
(
1
);
}
},
[]);
const
menulist
=
useMemo
(()
=>
{
console
.
log
(
activeTab
);
const
fields
=
{
1
:
[
{
...
...
@@ -1869,83 +1890,7 @@ function Model(props) {
},
],
};
return
(
<>
<
ProDescriptions
request=
{
async
()
=>
{
const
{
data
}
=
await
doFetch
({
url
:
urlParams
.
detail
,
params
:
{
id
:
drawer
?.
item
?.
id
},
});
return
{
success
:
true
,
data
:
data
?.
data
,
};
}
}
columns=
{
[
{
title
:
'设备编号'
,
dataIndex
:
'equipmentNo'
,
key
:
'equipmentNo'
,
},
{
title
:
'设备名称'
,
dataIndex
:
'equipmentName'
,
key
:
'equipmentName'
,
},
{
title
:
'位置号'
,
dataIndex
:
'positionNo'
,
key
:
'positionNo'
,
},
{
title
:
'公司名称'
,
dataIndex
:
'organizationName'
,
key
:
'organizationId'
,
},
{
title
:
'部门名称'
,
dataIndex
:
'departmentName'
,
key
:
'departmentId'
,
},
{
title
:
'工厂名称'
,
dataIndex
:
'factoryName'
,
key
:
'factoryId'
,
},
{
title
:
'车间名称'
,
dataIndex
:
'shopName'
,
key
:
'shopId'
,
},
{
title
:
'工段名称'
,
dataIndex
:
'sectionName'
,
key
:
'sectionId'
,
},
{
title
:
'产线名称'
,
dataIndex
:
'productLineName'
,
key
:
'productLineName'
,
},
{
title
:
'供应商'
,
dataIndex
:
'supplierName'
,
key
:
'supplierId'
,
},
{
title
:
'安装投产日期'
,
dataIndex
:
'productDate'
,
key
:
'productDate'
,
},
]
}
/>
<
Divider
/>
<
Tabs
activeKey=
{
activeTab
}
onChange=
{
setactiveTab
}
items=
{
[
let
arr
=
[
{
label
:
'改造'
,
key
:
1
,
...
...
@@ -2075,8 +2020,97 @@ function Model(props) {
/>
),
},
];
let
dis
=
resumeTab
?.
filter
((
it
)
=>
it
?.
disabled
);
arr
.
forEach
((
item
)
=>
{
dis
?.
forEach
((
it
)
=>
{
if
(
item
?.
key
==
it
?.
key
)
{
let
string
=
item
.
label
;
item
.
disabled
=
true
;
item
.
label
=
(
<
Tooltip
placement=
"topLeft"
title=
{
it
.
disabledReason
}
>
<
span
>
{
string
}
</
span
>
</
Tooltip
>
);
}
});
});
return
arr
;
},
[
activeTab
]);
return
(
<>
<
ProDescriptions
request=
{
async
()
=>
{
const
{
data
}
=
await
doFetch
({
url
:
urlParams
.
detail
,
params
:
{
id
:
drawer
?.
item
?.
id
},
});
return
{
success
:
true
,
data
:
data
?.
data
,
};
}
}
columns=
{
[
{
title
:
'设备编号'
,
dataIndex
:
'equipmentNo'
,
key
:
'equipmentNo'
,
},
{
title
:
'设备名称'
,
dataIndex
:
'equipmentName'
,
key
:
'equipmentName'
,
},
{
title
:
'位置号'
,
dataIndex
:
'positionNo'
,
key
:
'positionNo'
,
},
{
title
:
'公司名称'
,
dataIndex
:
'organizationName'
,
key
:
'organizationId'
,
},
{
title
:
'部门名称'
,
dataIndex
:
'departmentName'
,
key
:
'departmentId'
,
},
{
title
:
'工厂名称'
,
dataIndex
:
'factoryName'
,
key
:
'factoryId'
,
},
{
title
:
'车间名称'
,
dataIndex
:
'shopName'
,
key
:
'shopId'
,
},
{
title
:
'工段名称'
,
dataIndex
:
'sectionName'
,
key
:
'sectionId'
,
},
{
title
:
'产线名称'
,
dataIndex
:
'productLineName'
,
key
:
'productLineName'
,
},
{
title
:
'供应商'
,
dataIndex
:
'supplierName'
,
key
:
'supplierId'
,
},
{
title
:
'安装投产日期'
,
dataIndex
:
'productDate'
,
key
:
'productDate'
,
},
]
}
/>
<
Divider
/>
<
Tabs
activeKey=
{
activeTab
}
onChange=
{
setactiveTab
}
items=
{
menulist
}
/>
</>
);
};
...
...
src/pages/repair/order/index.jsx
View file @
a8aaeab0
...
...
@@ -3,7 +3,7 @@
* @Author: Li Hanlin
* @Date: 2022-12-02 11:41:03
* @Last Modified by: Li Hanlin
* @Last Modified time: 2023-01-31 1
5:14:34
* @Last Modified time: 2023-01-31 1
7:43:42
*/
import
*
as
React
from
'react'
;
...
...
@@ -1077,7 +1077,7 @@ function Failure(props) {
valueType
:
'radio'
,
options
:
[
{
label
:
'通过'
,
value
:
'1'
},
{
label
:
'不通过'
,
value
:
'
2
'
},
{
label
:
'不通过'
,
value
:
'
0
'
},
],
formItemProps
:
{
rules
:
[
...
...
@@ -1160,7 +1160,7 @@ function Failure(props) {
valueType
:
'radio'
,
options
:
[
{
label
:
'通过'
,
value
:
'1'
},
{
label
:
'不通过'
,
value
:
'
2
'
},
{
label
:
'不通过'
,
value
:
'
0
'
},
],
formItemProps
:
{
rules
:
[
...
...
@@ -1240,7 +1240,7 @@ function Failure(props) {
valueType
:
'radio'
,
options
:
[
{
label
:
'通过'
,
value
:
'1'
},
{
label
:
'不通过'
,
value
:
'
2
'
},
{
label
:
'不通过'
,
value
:
'
0
'
},
],
formItemProps
:
{
rules
:
[
...
...
@@ -1320,7 +1320,7 @@ function Failure(props) {
valueType
:
'radio'
,
options
:
[
{
label
:
'通过'
,
value
:
'1'
},
{
label
:
'不通过'
,
value
:
'
2
'
},
{
label
:
'不通过'
,
value
:
'
0
'
},
],
formItemProps
:
{
rules
:
[
...
...
src/pages/repair/track/columns.js
View file @
a8aaeab0
...
...
@@ -80,7 +80,7 @@ function getcolumns(setdrawer, bus) {
<
span
style
=
{{
color
:
`
${
row
.
nextTrackDate
.
valueOf
()
<
dayjs
().
format
(
'YYYY-MM-DD'
).
valueOf
()
row
?.
nextTrackDate
?
.
valueOf
()
<
dayjs
().
format
(
'YYYY-MM-DD'
).
valueOf
()
?
'#f50'
:
'rgba(0, 0, 0, 0.85)'
}
`,
...
...
src/pages/repair/track/index.jsx
View file @
a8aaeab0
...
...
@@ -3,7 +3,7 @@
* @Author: Li Hanlin
* @Date: 2022-12-02 11:41:03
* @Last Modified by: Li Hanlin
* @Last Modified time: 2023-01-31
09:20:37
* @Last Modified time: 2023-01-31
15:46:59
*/
import
*
as
React
from
'react'
;
...
...
src/pages/setting/users/columns.js
View file @
a8aaeab0
...
...
@@ -179,6 +179,7 @@ function getcolumns(setDrawer, ifs, formRef) {
width
:
120
,
valueType
:
'treeSelect'
,
dataIndex
:
'departmentName'
,
search
:
false
,
formItemProps
:
{
rules
:
[{
required
:
true
,
message
:
'此项为必填项'
}]
},
key
:
'departmentId'
,
options
:
{
...
...
@@ -188,6 +189,22 @@ function getcolumns(setDrawer, ifs, formRef) {
},
},
},
{
title
:
'部门名称'
,
width
:
120
,
valueType
:
'select'
,
dataIndex
:
'departmentName'
,
formItemProps
:
{
rules
:
[{
required
:
true
,
message
:
'此项为必填项'
}]
},
key
:
'departmentId'
,
options
:
{
path
:
'/auth/sysDepartment/query/all/department/selection'
,
},
fieldProps
:
{
showSearch
:
true
,
},
hideInForm
:
true
,
hideInTable
:
true
,
},
{
title
:
'角色名称'
,
dataIndex
:
'roleNames'
,
...
...
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