Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
CivManage
Project
Project
Details
Activity
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
ReactWeb5
CivManage
Commits
6d52b027
Commit
6d52b027
authored
Jul 09, 2021
by
shaoan123
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
解决表字段bug
parent
c18cb7e7
Pipeline
#31314
skipped with stages
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
14 deletions
+6
-14
index.jsx
src/pages/platformCenter/bsmanager/tablemanager/index.jsx
+5
-13
AddModal.jsx
...atformCenter/dimensionsConfig/projectMessage/AddModal.jsx
+1
-1
No files found.
src/pages/platformCenter/bsmanager/tablemanager/index.jsx
View file @
6d52b027
...
...
@@ -39,7 +39,7 @@ const TableManager = () => {
const
[
groupArr
,
setGroupArr
]
=
useState
([])
const
[
allData
,
setAllData
]
=
useState
([])
const
[
tableData
,
setTableData
]
=
useState
([])
const
[
spread
,
setSpread
]
=
useState
([])
useEffect
((
record
)
=>
{
loadTable
(
searchValue
)
getField
()
...
...
@@ -183,7 +183,8 @@ const TableManager = () => {
}
return
tempObj
}
const
expandedRowRender
=
()
=>
{
const
expandedRowRender
=
(
item
)
=>
{
console
.
log
(
'item'
,
item
);
const
columns1
=
[
{
title
:
'名称'
,
...
...
@@ -293,7 +294,7 @@ const TableManager = () => {
];
return
<
Table
columns=
{
columns1
}
dataSource=
{
spread
}
pagination=
{
false
}
/>;
return
<
Table
columns=
{
columns1
}
dataSource=
{
allData
[
item
.
type
]
}
pagination=
{
false
}
/>;
};
const
columns
=
[
...
...
@@ -305,14 +306,7 @@ const TableManager = () => {
},
];
const
openClick
=
(
status
,
item
)
=>
{
if
(
!
status
)
return
let
arr
=
[]
allData
[
item
.
type
].
map
((
item
,
index
)
=>
{
arr
.
push
({
...
item
,
key
:
index
})
})
setSpread
(
arr
)
}
return
(
<
Spin
tip=
"loading..."
spinning=
{
treeLoading
}
>
<
PageContainer
>
...
...
@@ -359,8 +353,6 @@ const TableManager = () => {
columns=
{
columns
}
expandable=
{
{
expandedRowRender
}
}
dataSource=
{
groupArr
}
onExpand=
{
openClick
}
// 展开时触发的回调
size=
"small"
style=
{
{
height
:
'8rem'
}
}
pagination=
{
{
...
...
src/pages/platformCenter/dimensionsConfig/projectMessage/AddModal.jsx
View file @
6d52b027
...
...
@@ -210,7 +210,7 @@ const AddModal = props => {
<
Input
placeholder=
"请输入方案名"
allowClear
/>
</
Item
>
<
Item
label=
"
管网
"
label=
"
数据源
"
>
<
Select
onChange=
{
handleService
}
mode=
"multiple"
>
{
pipeArr
.
length
?
pipeArr
.
map
((
item
,
index
)
=>
{
return
<
Option
key=
{
index
}
value=
{
item
}
>
{
item
}
</
Option
>;
})
:
''
}
...
...
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