Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
W
wms
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
wms
Commits
37633e16
Commit
37633e16
authored
Jul 27, 2022
by
左玲玲
😬
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
问题修复
parent
6e91f9c3
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
35 additions
and
12 deletions
+35
-12
mtable.jsx
src/components/AutoTable/mtable.jsx
+2
-2
index.jsx
src/components/TreeRender/index.jsx
+29
-6
fields.js
src/pages/insertstore/Instore/fields.js
+1
-1
fields.js
src/pages/outsetstore/Outstore/fields.js
+1
-1
detailTotalCard.js
src/utils/detailTotalCard.js
+2
-2
No files found.
src/components/AutoTable/mtable.jsx
View file @
37633e16
...
...
@@ -33,9 +33,9 @@ class Mtable extends PureComponent {
this
.
props
.
columns
!=
nextprops
.
columns
)
{
if
(
nextprops
.
actionRef
)
{
nextprops
.
actionRef
?.
current
?.
re
load
();
nextprops
.
actionRef
?.
current
?.
re
set
();
}
else
{
this
.
actionRefs
?.
current
?.
re
load
();
this
.
actionRefs
?.
current
?.
re
set
();
}
this
.
initDrage
(
nextprops
);
}
...
...
src/components/TreeRender/index.jsx
View file @
37633e16
...
...
@@ -76,14 +76,22 @@ function TreeRender({ url, deleteurl, saveurl, onselected, params, noaction, max
},
[
data
]);
const
onChange
=
(
e
)
=>
{
const
{
value
}
=
e
.
target
;
const
newExpandedKeys
=
alldata
.
map
((
item
)
=>
{
const
dataLists
=
getAllList
();
const
newExpandedKeys
=
dataLists
.
map
((
item
)
=>
{
if
(
item
.
title
.
indexOf
(
value
)
>
-
1
)
{
return
getParentKey
(
item
.
key
,
treeData
);
}
return
null
;
}).
filter
((
item
,
i
,
self
)
=>
item
&&
self
.
indexOf
(
item
)
===
i
);
onExpand
(
newExpandedKeys
);
setsearch
(
value
);
if
(
newExpandedKeys
.
length
>
0
){
setexpandall
(
true
);
setAutoExpandParent
(
true
)
}
else
{
setexpandall
(
false
);
setAutoExpandParent
(
false
)
}
onExpand
(
newExpandedKeys
);
};
const
loop
=
data
=>
data
.
map
(
item
=>
{
const
index
=
item
.
title
.
indexOf
(
search
);
...
...
@@ -240,7 +248,22 @@ function TreeRender({ url, deleteurl, saveurl, onselected, params, noaction, max
useEffect
(()
=>
{
setexpandall
(
true
);
onExpand
(
allkeys
)
},
[
allkeys
])
},
[
allkeys
]);
function
getAllList
()
{
const
dataLists
=
[];
const
generateLists
=
data
=>
{
for
(
let
i
=
0
;
i
<
data
.
length
;
i
++
)
{
const
node
=
data
[
i
];
const
key
=
node
.
key
;
dataLists
.
push
({
key
,
title
:
node
.
title
,
level
:
node
.
level
});
if
(
node
.
children
)
{
generateLists
(
node
.
children
,
node
.
key
);
}
}
};
generateLists
(
treeData
);
return
dataLists
;
}
return
(
<
div
>
<
Modal
...
...
@@ -329,12 +352,12 @@ function TreeRender({ url, deleteurl, saveurl, onselected, params, noaction, max
autoExpandParent=
{
autoExpandParent
}
defaultExpandAll=
{
true
}
expandedKeys=
{
expandedKeys
}
onExpand=
{
(
expandedKeys
,
{
expanded
:
bool
,
node
})
=>
{
onExpand=
{
(
expandedKeys
,
{
expanded
:
bool
,
node
})
=>
{
onExpand
(
expandedKeys
);
setAutoExpandParent
(
false
);
if
(
!
bool
&&
node
.
key
==
"00000000"
)
{
if
(
!
bool
&&
node
.
key
==
"00000000"
)
{
setexpandall
(
false
)
}
else
{
}
else
{
setexpandall
(
true
)
}
}
}
...
...
src/pages/insertstore/Instore/fields.js
View file @
37633e16
...
...
@@ -50,7 +50,7 @@ const EditUpload = ({ record, fid, storeId }) => {
search
:
false
,
valueType
:
"select"
,
request
:
async
(
params
)
=>
{
let
res
=
await
doFetch
({
url
:
"/ngic-auth/sysStorePosition/queryByStoreId/selection"
,
params
});
let
res
=
await
doFetch
({
url
:
"/ngic-auth/sysStorePosition/queryByStoreId/selection"
,
params
:{
storeId
:
params
.
storeId
}
});
return
res
?.
data
?.
dataList
},
editable
:
(
text
,
record
,
index
)
=>
{
...
...
src/pages/outsetstore/Outstore/fields.js
View file @
37633e16
...
...
@@ -65,7 +65,7 @@ const EditUpload = ({ record, fid, storeId }) => {
search
:
false
,
valueType
:
"select"
,
request
:
async
(
params
)
=>
{
let
res
=
await
doFetch
({
url
:
"/ngic-auth/sysStorePosition/queryByStoreId/selection"
,
params
});
let
res
=
await
doFetch
({
url
:
"/ngic-auth/sysStorePosition/queryByStoreId/selection"
,
params
:{
storeId
:
params
.
storeId
}
});
return
res
?.
data
?.
dataList
},
editable
:
(
text
,
record
,
index
)
=>
{
...
...
src/utils/detailTotalCard.js
View file @
37633e16
...
...
@@ -741,8 +741,8 @@ const materielDetail = [
columns
:
[
{
title
:
"辅助单位"
,
dataIndex
:
"productionUnit"
,
key
:
"productionUnit"
,
dataIndex
:
"productionUnit
Name
"
,
key
:
"productionUnit
Name
"
,
search
:
false
,
},
{
...
...
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