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
66e565ea
Commit
66e565ea
authored
2 years ago
by
TZW
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bug
parent
6885c97e
Changes
15
Hide whitespace changes
Inline
Side-by-side
Showing
15 changed files
with
269 additions
and
158 deletions
+269
-158
proxy.js
config/proxy.js
+2
-2
index.jsx
src/components/InitForm/EditTable/index.jsx
+11
-9
FormItems.jsx
src/components/InitForm/FormItems.jsx
+114
-102
DesItem.jsx
src/components/RepaireDetail/DesItem.jsx
+2
-2
Detail.jsx
src/components/RepaireDetail/Detail.jsx
+70
-14
detailColumns.js
src/pages/maintain/workOrder/detailColumns.js
+2
-2
index.jsx
src/pages/repair/failure/index.jsx
+3
-4
index.jsx
src/pages/repair/order/index.jsx
+17
-3
columns.js
src/pages/repair/outsourcing/columns.js
+6
-0
index.jsx
src/pages/repair/outsourcing/index.jsx
+2
-2
columns.js
src/pages/repair/track/columns.js
+7
-0
index.jsx
src/pages/repair/track/index.jsx
+12
-10
columns.js
src/pages/spare/instore/columns.js
+9
-4
columns.js
src/pages/spare/setting/columns.js
+9
-1
request.js
src/utils/request.js
+3
-3
No files found.
config/proxy.js
View file @
66e565ea
...
...
@@ -13,9 +13,9 @@ export default {
dev
:
{
[
defaultSetting
.
proxypath
]:
{
// 要代理的地址
target
:
'http://192.168.40.64:28000'
,
//jf哥
//
target: 'http://192.168.40.64:28000', //jf哥
// target: 'http://192.168.40.64:28000', //gc哥
//
target: 'http://192.168.40.203:8000', //dj哥
target
:
'http://192.168.40.203:8000'
,
//dj哥
changeOrigin
:
true
,
},
'/token'
:
{
...
...
This diff is collapsed.
Click to expand it.
src/components/InitForm/EditTable/index.jsx
View file @
66e565ea
...
...
@@ -29,6 +29,7 @@ const EditTable = (props) => {
//调用接口
const
request
=
async
(
params
,
sort
,
filter
)
=>
{
console
.
log
(
params
);
if
(
!
path
)
return
{
data
:
dataSource
??
[],
...
...
@@ -125,6 +126,7 @@ const EditTable = (props) => {
{
...
props
}
recordCreatorProps=
{
false
}
size=
{
size
}
params=
{
{
...
extraparams
}
}
onSubmit=
{
(
params
)
=>
{
//console.log(params, 'onSubmit');
}
}
...
...
@@ -142,20 +144,20 @@ const EditTable = (props) => {
scroll=
{
x
?
{
x
:
x
,
}
x
:
x
,
}
:
{}
}
pagination=
{
ifspagination
?
false
:
{
showTotal
:
(
total
,
range
)
=>
<
span
>
共
{
total
}
条
</
span
>,
showQuickJumper
:
true
,
showSizeChanger
:
true
,
pageSizeOptions
:
[
5
,
10
,
15
,
30
,
50
,
100
,
200
],
defaultPageSize
:
pageSize
||
15
,
}
showTotal
:
(
total
,
range
)
=>
<
span
>
共
{
total
}
条
</
span
>,
showQuickJumper
:
true
,
showSizeChanger
:
true
,
pageSizeOptions
:
[
5
,
10
,
15
,
30
,
50
,
100
,
200
],
defaultPageSize
:
pageSize
||
15
,
}
}
editable=
{
{
type
:
'multiple'
,
...
...
@@ -164,7 +166,7 @@ const EditTable = (props) => {
}
}
search=
{
{
filterType
:
'light'
,
//轻量模式
placement
:
'bottomLeft'
placement
:
'bottomLeft'
,
}
}
/>
);
...
...
This diff is collapsed.
Click to expand it.
src/components/InitForm/FormItems.jsx
View file @
66e565ea
/* eslint-disable react-hooks/exhaustive-deps */
import
React
,
{
useState
,
useRef
,
memo
,
createElement
,
useEffect
}
from
'react'
;
import
React
,
{
useState
,
useRef
,
memo
,
createElement
,
useEffect
,
useMemo
}
from
'react'
;
import
{
ProForm
,
ProFormDependency
,
...
...
@@ -1472,6 +1472,108 @@ function FormList({ item, colProps, formRef }) {
);
}
const Todo = ({ actionRef, value, item, params, rowKey, chooses, onChange }) => {
console.log(params);
return (
<EditTable
actionRef={actionRef}
defaultValue={value} //调用接口合并初始值
path={item.path}
extraparams={params ?? {}}
rowKey={rowKey}
columns={item.columns}
resizeable={false}
alwaysShowAlert={false}
tableAlertRender={false}
tableAlertOptionRender={false}
rowClassName={(record, index) => {
if (chooses.includes(record[rowKey])) {
return 'lightblue';
} else {
return '';
}
}}
rowSelection={{
...item.rowSelection,
columnWidth: 44,
preserveSelectedRowKeys: true,
selectedRowKeys: value && value?.map((it) => it[rowKey]),
onChange: (selectedKeys, selectedRows) => {
const rowkeylist = value ? value?.map((it) => it[rowKey]) : [];
const newValue = selectedRows?.map((its) => {
if (rowkeylist.includes(its[rowKey])) {
return value.filter((it) => it[rowKey] == its[rowKey])[0];
} else {
return its;
}
});
onChange(newValue);
},
}}
editable={{
onValuesChange: (record, recordList) => {
const newValue = value?.map((its) => {
if (its[rowKey] == record[rowKey]) {
return record;
} else {
return its;
}
});
onChange(newValue);
},
}}
/>
);
};
const Done = ({ actionRef, value, item, params, rowKey, chooses, onChange }) => (
<EditTable
value={value}
rowKey={rowKey}
columns={item.columns}
resizeable={false}
alwaysShowAlert={false}
tableAlertRender={false}
tableAlertOptionRender={false}
rowClassName={(record, index) => {
if (chooses.includes(record[rowKey])) {
return 'lightblue';
} else {
return '';
}
}}
rowSelection={{
...item.rowSelection,
columnWidth: 44,
preserveSelectedRowKeys: true,
selectedRowKeys: value && value?.map((it) => it[rowKey]),
onChange: (selectedKeys, selectedRows) => {
const rowkeylist = value ? value?.map((it) => it[rowKey]) : [];
const newValue = selectedRows?.map((its) => {
if (rowkeylist.includes(its[rowKey])) {
return value.filter((it) => it[rowKey] == its[rowKey])[0];
} else {
return its;
}
});
onChange(newValue);
},
}}
editable={{
onValuesChange: (record, recordList) => {
const newValue = value?.map((its) => {
if (its[rowKey] == record[rowKey]) {
return record;
} else {
return its;
}
});
onChange(newValue);
},
}}
/>
);
function TableSelect({ item, value, onChange, params = {} }) {
const rowKey = item?.rowKey ?? 'id';
const [chooses, setchooses] = useState([]); //mark 标记
...
...
@@ -1540,105 +1642,15 @@ function TableSelect({ item, value, onChange, params = {} }) {
/>
);
const Todo = () => (
<EditTable
actionRef={actionRef}
defaultValue={value} //调用接口合并初始值
path={item.path}
extraparams={params ?? {}}
rowKey={rowKey}
columns={item.columns}
resizeable={false}
alwaysShowAlert={false}
tableAlertRender={false}
tableAlertOptionRender={false}
rowClassName={(record, index) => {
if (chooses.includes(record[rowKey])) {
return 'lightblue';
} else {
return '';
}
}}
rowSelection={{
...item.rowSelection,
columnWidth: 44,
preserveSelectedRowKeys: true,
selectedRowKeys: value && value?.map((it) => it[rowKey]),
onChange: (selectedKeys, selectedRows) => {
const rowkeylist = value ? value?.map((it) => it[rowKey]) : [];
const newValue = selectedRows?.map((its) => {
if (rowkeylist.includes(its[rowKey])) {
return value.filter((it) => it[rowKey] == its[rowKey])[0];
} else {
return its;
}
});
onChange(newValue);
},
}}
editable={{
onValuesChange: (record, recordList) => {
const newValue = value?.map((its) => {
if (its[rowKey] == record[rowKey]) {
return record;
} else {
return its;
}
});
onChange(newValue);
},
}}
/>
);
const Done = () => (
<EditTable
value={value}
rowKey={rowKey}
columns={item.columns}
resizeable={false}
alwaysShowAlert={false}
tableAlertRender={false}
tableAlertOptionRender={false}
rowClassName={(record, index) => {
if (chooses.includes(record[rowKey])) {
return 'lightblue';
} else {
return '';
}
}}
rowSelection={{
...item.rowSelection,
columnWidth: 44,
preserveSelectedRowKeys: true,
selectedRowKeys: value && value?.map((it) => it[rowKey]),
onChange: (selectedKeys, selectedRows) => {
const rowkeylist = value ? value?.map((it) => it[rowKey]) : [];
const newValue = selectedRows?.map((its) => {
if (rowkeylist.includes(its[rowKey])) {
return value.filter((it) => it[rowKey] == its[rowKey])[0];
} else {
return its;
}
});
onChange(newValue);
},
}}
editable={{
onValuesChange: (record, recordList) => {
const newValue = value?.map((its) => {
if (its[rowKey] == record[rowKey]) {
return record;
} else {
return its;
}
});
onChange(newValue);
},
}}
/>
);
const propes = {
actionRef,
value,
item,
params,
rowKey,
chooses,
onChange,
};
return (
<div className="selecttable">
<Tabs
...
...
@@ -1669,8 +1681,8 @@ function TableSelect({ item, value, onChange, params = {} }) {
{ label: `
选择结果
$
{
value
?.
length
??
0
}
项
`, key: 2 },
]}
/>
{activetab == 1 && <Todo />}
{activetab == 2 && <Done />}
{activetab == 1 && <Todo
{...propes}
/>}
{activetab == 2 && <Done
{...propes}
/>}
</div>
);
}
...
...
This diff is collapsed.
Click to expand it.
src/components/RepaireDetail/DesItem.jsx
View file @
66e565ea
...
...
@@ -22,8 +22,8 @@ export default (props) => {
},
{
title
:
'设备型号'
,
dataIndex
:
'equipmentName'
,
key
:
'equipmentName'
,
dataIndex
:
'equipment
Model
Name'
,
key
:
'equipment
Model
Name'
,
},
{
title
:
'公司名称'
,
...
...
This diff is collapsed.
Click to expand it.
src/components/RepaireDetail/Detail.jsx
View file @
66e565ea
...
...
@@ -19,7 +19,76 @@ export default (props) => {
// 维修工单
const
Wxgd
=
()
=>
{
return
(
// return (
// <>
// <DesItem
// dataSource={request?.data?.dataList[0]}
// title="报修信息"
// hidden={true}
// index="0"
// // navhidden={false}
// />
// {request?.data?.dataList?.splice(1).map((it, index) => {
// return (
// <>
// <DesItem
// type="wxgd"
// dataSource={it}
// index={index + 2}
// hidden={true}
// navhidden={false}
// />
// </>
// );
// })}
// </>
// );
return
hidden
?
(
<>
<
DesItem
dataSource=
{
request
?.
data
?.
dataList
[
0
]
}
title=
"基本信息"
hidden=
{
true
}
type=
"wxgd"
index=
"0"
// navhidden={false}
/>
<
DesItem
type=
"wxgd"
dataSource=
{
request
?.
data
?.
dataList
[
1
]
}
index=
{
'2'
}
hidden=
{
true
}
navhidden=
{
false
}
/>
<
div
className=
"fault-detail"
style=
{
{
paddingTop
:
30
,
paddingBottom
:
30
}
}
>
<
Tooltip
title=
"点击展开"
>
<
Button
type=
"primary"
shape=
"circle"
icon=
{
<
MoreOutlined
/>
}
onClick=
{
()
=>
{
sethidden
(
false
);
}
}
/>
</
Tooltip
>
</
div
>
<
DesItem
type=
"wxgd"
dataSource=
{
request
?.
data
?.
dataList
[
request
?.
data
?.
dataList
?.
length
-
2
]
}
index=
{
request
?.
data
?.
dataList
?.
length
-
1
}
hidden=
{
true
}
navhidden=
{
false
}
/>
<
DesItem
type=
"wxgd"
dataSource=
{
request
?.
data
?.
dataList
[
request
?.
data
?.
dataList
?.
length
-
1
]
}
index=
{
request
?.
data
?.
dataList
?.
length
}
hidden=
{
true
}
navhidden=
{
false
}
/>
</>
)
:
(
<>
<
DesItem
dataSource=
{
request
?.
data
?.
dataList
[
0
]
}
...
...
@@ -89,19 +158,6 @@ export default (props) => {
hidden=
{
true
}
navhidden=
{
false
}
/>
{
/* {request?.data?.dataList?.splice(1).map((it, index) => {
return (
<>
<DesItem
type="zzgd"
dataSource={it}
index={index + 2}
hidden={true}
navhidden={false}
/>
</>
);
})} */
}
</>
)
:
(
<>
...
...
This diff is collapsed.
Click to expand it.
src/pages/maintain/workOrder/detailColumns.js
View file @
66e565ea
...
...
@@ -14,8 +14,8 @@ const getcolumns = {
},
{
title
:
'设备型号'
,
dataIndex
:
'equipmentName'
,
key
:
'equipmentName'
,
dataIndex
:
'equipment
Model
Name'
,
key
:
'equipment
Model
Name'
,
},
{
title
:
'保养类型'
,
...
...
This diff is collapsed.
Click to expand it.
src/pages/repair/failure/index.jsx
View file @
66e565ea
...
...
@@ -2,7 +2,7 @@
* @Author: Li Hanlin
* @Date: 2022-12-02 11:41:03
* @Last Modified by: Li Hanlin
* @Last Modified time: 2023-0
1-30 15:59:06
* @Last Modified time: 2023-0
2-07 13:31:07
*/
import
*
as
React
from
'react'
;
...
...
@@ -149,9 +149,8 @@ function Failure(props) {
},
{
title
:
'关单时间'
,
dataIndex
:
'faultDescription'
,
key
:
'faultDescription'
,
valueType
:
'textarea'
,
dataIndex
:
'repairCloseTime'
,
key
:
'repairCloseTime'
,
},
];
}
...
...
This diff is collapsed.
Click to expand it.
src/pages/repair/order/index.jsx
View file @
66e565ea
...
...
@@ -3,7 +3,7 @@
* @Author: Li Hanlin
* @Date: 2022-12-02 11:41:03
* @Last Modified by: Li Hanlin
* @Last Modified time: 2023-02-0
2 17:04:01
* @Last Modified time: 2023-02-0
7 15:25:45
*/
import
*
as
React
from
'react'
;
...
...
@@ -146,8 +146,10 @@ function Failure(props) {
type
:
'wcwx'
,
item
:
{
...
row
,
repairType
:
'101'
,
isShutdown
:
1
,
repairContent
:
res
?.
data
?.
data
?.
faultSolution
,
repairAssistList
:
row
?.
repairAssistList
.
map
((
it
)
=>
it
?.
assistUserId
),
},
val
:
'only'
,
title
:
'完成维修'
,
...
...
@@ -158,7 +160,12 @@ function Failure(props) {
...
s
,
open
:
true
,
type
:
'wcwx'
,
item
:
{
...
row
,
isShutdown
:
1
},
item
:
{
...
row
,
isShutdown
:
1
,
repairType
:
'101'
,
repairAssistList
:
row
?.
repairAssistList
.
map
((
it
)
=>
it
?.
assistUserId
),
},
val
:
'only'
,
title
:
'完成维修'
,
}));
...
...
@@ -408,8 +415,10 @@ function Failure(props) {
type
:
'wcwx'
,
item
:
{
...
row
,
repairType
:
'101'
,
isShutdown
:
1
,
repairContent
:
res
?.
data
?.
data
?.
faultSolution
,
repairAssistList
:
row
?.
repairAssistList
.
map
((
it
)
=>
it
?.
assistUserId
),
},
val
:
'only'
,
title
:
'完成维修'
,
...
...
@@ -420,7 +429,12 @@ function Failure(props) {
...
s
,
open
:
true
,
type
:
'wcwx'
,
item
:
{
...
row
,
isShutdown
:
1
},
item
:
{
...
row
,
repairType
:
'101'
,
isShutdown
:
1
,
repairAssistList
:
row
?.
repairAssistList
.
map
((
it
)
=>
it
?.
assistUserId
),
},
val
:
'only'
,
title
:
'完成维修'
,
}));
...
...
This diff is collapsed.
Click to expand it.
src/pages/repair/outsourcing/columns.js
View file @
66e565ea
...
...
@@ -320,6 +320,12 @@ function getcolumns(setdrawer, bus) {
path
:
'/auth/sysUser/selection'
,
},
},
{
title
:
'关单时间'
,
dataIndex
:
'repairCloseTime'
,
key
:
'repairCloseTime'
,
valueType
:
'dateTimeRange'
,
},
{
title
:
'来源单号'
,
dataIndex
:
'dataSourcesNo'
,
...
...
This diff is collapsed.
Click to expand it.
src/pages/repair/outsourcing/index.jsx
View file @
66e565ea
...
...
@@ -3,7 +3,7 @@
* @Author: Li Hanlin
* @Date: 2022-12-02 11:41:03
* @Last Modified by: Li Hanlin
* @Last Modified time: 2023-02-0
3 10:40:38
* @Last Modified time: 2023-02-0
7 16:50:52
*/
import
*
as
React
from
'react'
;
...
...
@@ -179,7 +179,7 @@ function Failure(props) {
]
}
onFinish=
{
async
(
vals
)
=>
{
let
params
=
{
otherUnitsAssistList
:
vals
?.
otherUnitsAssistList
.
map
((
it
)
=>
({
assistUserId
:
it
}))
,
otherUnitsAssistList
:
[{
assistUserId
:
vals
?.
otherUnitsAssistList
}]
,
id
:
drawer
?.
item
?.
id
,
};
let
res
=
await
doFetch
({
...
...
This diff is collapsed.
Click to expand it.
src/pages/repair/track/columns.js
View file @
66e565ea
import
dayjs
from
'dayjs'
;
function
getcolumns
(
setdrawer
,
bus
)
{
let
listOptions
=
bus
?.
map
((
it
)
=>
({
label
:
it
?.
name
,
value
:
it
?.
code
}));
console
.
log
(
listOptions
);
return
[
{
tab
:
'我的待办'
,
...
...
@@ -325,6 +326,12 @@ function getcolumns(setdrawer, bus) {
path: '/auth/sysUser/selection',
},
},
{
title: '关单时间',
dataIndex: 'repairCloseTime',
key: 'repairCloseTime',
valueType: 'dateTimeRange',
},
{
title: '来源单号',
dataIndex: 'repairNo',
...
...
This diff is collapsed.
Click to expand it.
src/pages/repair/track/index.jsx
View file @
66e565ea
...
...
@@ -3,7 +3,7 @@
* @Author: Li Hanlin
* @Date: 2022-12-02 11:41:03
* @Last Modified by: Li Hanlin
* @Last Modified time: 2023-02-0
1 18:48:57
* @Last Modified time: 2023-02-0
7 16:08:46
*/
import
*
as
React
from
'react'
;
...
...
@@ -54,7 +54,7 @@ function Failure(props) {
...
s
,
SpecName
:
res
?.
data
?.
dataList
,
}));
},
[]);
},
[
activeTabKey
]);
// 重新指派
const
Reassig
=
()
=>
{
...
...
@@ -132,11 +132,11 @@ function Failure(props) {
formItemProps
:
{
rules
:
[{
required
:
true
,
message
:
'此项为必填项'
}]
},
options
:
[
{
value
:
'1'
,
value
:
1
,
label
:
'正常'
,
},
{
value
:
'2'
,
value
:
2
,
label
:
'异常'
,
},
],
...
...
@@ -152,11 +152,11 @@ function Failure(props) {
key
:
'isFinishTrack'
,
options
:
[
{
value
:
'1'
,
value
:
1
,
label
:
'是'
,
},
{
value
:
'2'
,
value
:
2
,
label
:
'否'
,
},
],
...
...
@@ -165,6 +165,8 @@ function Failure(props) {
title
:
'追踪周期'
,
dataIndex
:
'trackCycle'
,
key
:
'trackCycle'
,
valueType
:
'digit'
,
precision
:
0
,
fieldProps
:
{
disabled
:
true
,
},
...
...
@@ -424,8 +426,8 @@ function Failure(props) {
trackResult
:
'1'
,
isFinishTrack
:
'2'
,
},
//
detailpath: '/repair/umTrackTraceinfo/queryByTrackOrderId',
//
params:
{
trackOrderId
:
row
?.
id
},
detailpath
:
'/repair/umTrackTraceinfo/queryByTrackOrderId'
,
params
:
{
trackOrderId
:
row
?.
id
},
val
:
'only'
,
title
:
'追踪信息'
,
}));
...
...
@@ -451,7 +453,7 @@ function Failure(props) {
open
:
true
,
val
:
'only'
,
title
:
'验证'
,
item
:
row
,
item
:
{
...
row
,
reviewerResult
:
1
}
,
detailpath
:
'/repair/umTrackTraceinfo/queryByTrackOrderId'
,
params
:
{
trackOrderId
:
row
?.
id
},
type
:
'check'
,
...
...
@@ -555,7 +557,7 @@ function Failure(props) {
}
else
if
(
activeTabKey
==
'3'
)
{
return
defcolumn
;
}
},
[
activeTabKey
]);
},
[
activeTabKey
,
drawer
?.
SpecName
]);
const
pathconfig
=
useMemo
(()
=>
{
let
defpath
=
getcolumns
(
setdrawer
).
filter
((
it
)
=>
it
.
key
==
activeTabKey
)[
0
]?.
pathconfig
??
{};
...
...
This diff is collapsed.
Click to expand it.
src/pages/spare/instore/columns.js
View file @
66e565ea
...
...
@@ -102,6 +102,9 @@ function getcolumns(setdrawer) {
title
:
'入库单号'
,
dataIndex
:
'taskNo'
,
key
:
'taskNo'
,
fieldProps
:
{
placeholder
:
'不填系统自动生成'
,
},
},
{
title
:
'入库类型'
,
...
...
@@ -216,7 +219,7 @@ function getcolumns(setdrawer) {
dataIndex
:
'createTime'
,
key
:
'createTimeList'
,
hideInForm
:
true
,
valueType
:
'dateRange'
,
valueType
:
'date
Time
Range'
,
render
:
(
text
,
row
)
=>
{
return
<
span
>
{
row
?.
createTime
}
<
/span>
;
},
...
...
@@ -228,7 +231,6 @@ function getcolumns(setdrawer) {
valueType
:
'split'
,
},
{
title
:
'备件'
,
dataIndex
:
'detailsList'
,
key
:
'detailsList'
,
valueType
:
'formList'
,
...
...
@@ -387,7 +389,7 @@ function getcolumns(setdrawer) {
dataIndex
:
'createTime'
,
key
:
'createTimeList'
,
hideInForm
:
true
,
valueType
:
'dateRange'
,
valueType
:
'date
Time
Range'
,
render
:
(
text
,
row
)
=>
{
return
<
span
>
{
row
?.
createTime
}
<
/span>
;
},
...
...
@@ -397,6 +399,7 @@ function getcolumns(setdrawer) {
dataIndex
:
'completeTime'
,
key
:
'completeTimeList'
,
hideInForm
:
true
,
span
:
3
,
valueType
:
'dateRange'
,
render
:
(
text
,
row
)
=>
{
return
<
span
>
{
row
?.
completeTime
}
<
/span>
;
...
...
@@ -409,7 +412,6 @@ function getcolumns(setdrawer) {
valueType
:
'split'
,
},
{
title
:
'备件'
,
dataIndex
:
'detailsList'
,
key
:
'detailsList'
,
valueType
:
'formList'
,
...
...
@@ -445,6 +447,9 @@ function getcolumns(setdrawer) {
key
:
'status'
,
hideInForm
:
true
,
valueType
:
'select'
,
fieldProps
:
{
dropdownMatchSelectWidth
:
120
,
},
width
:
120
,
options
:
[
{
label
:
'已入库'
,
value
:
2
},
...
...
This diff is collapsed.
Click to expand it.
src/pages/spare/setting/columns.js
View file @
66e565ea
...
...
@@ -112,6 +112,14 @@ function getcolumns(setdrawer) {
dataIndex
:
'isLifeName'
,
key
:
'isLife'
,
valueType
:
'select'
,
formItemProps
:
{
rules
:
[
{
required
:
true
,
message
:
'此项为必填项'
,
},
],
},
options
:
[
{
label
:
'是'
,
...
...
@@ -132,7 +140,7 @@ function getcolumns(setdrawer) {
valueType
:
'split'
,
},
{
title
:
'供应商'
,
//
title: '供应商',
dataIndex
:
'relationSupplierList'
,
key
:
'relationSupplierList'
,
valueType
:
'formSelectList'
,
...
...
This diff is collapsed.
Click to expand it.
src/utils/request.js
View file @
66e565ea
...
...
@@ -77,9 +77,9 @@ request.interceptors.request.use(async (url, options) => {
// response拦截器, 处理response
request
.
interceptors
.
response
.
use
(
async
(
response
,
options
)
=>
{
if
(
response
?.
status
==
'401'
)
{
window
.
location
.
href
=
'/'
;
}
//
if (response?.status == '401') {
//
window.location.href = '/';
//
}
if
(
options
.
responseType
==
'blob'
)
{
const
data
=
await
response
.
clone
().
blob
();
let
blobUrl
=
window
.
URL
.
createObjectURL
(
data
);
...
...
This diff is collapsed.
Click to expand it.
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