Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
szse
Overview
Overview
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
zhaochengxiang
szse
Commits
f7f6b3b8
Commit
f7f6b3b8
authored
Apr 20, 2023
by
zhaochengxiang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
衍生表
parent
c698c607
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
11 additions
and
8 deletions
+11
-8
EditModel.jsx
src/view/Manage/Model/Component/EditModel.jsx
+2
-2
ImportAction.jsx
src/view/Manage/Model/Component/ImportAction.jsx
+0
-1
ImportActionInherited.jsx
src/view/Manage/Model/Component/ImportActionInherited.jsx
+9
-5
No files found.
src/view/Manage/Model/Component/EditModel.jsx
View file @
f7f6b3b8
...
@@ -317,7 +317,7 @@ const EditModel = (props) => {
...
@@ -317,7 +317,7 @@ const EditModel = (props) => {
readOnly
!==
'true'
&&
<
Space
>
readOnly
!==
'true'
&&
<
Space
>
{
{
!
modelerData
?.
final
&&
<
Button
type=
'primary'
onClick=
{
editInherite
}
danger
>
!
modelerData
?.
final
&&
<
Button
type=
'primary'
onClick=
{
editInherite
}
danger
>
编辑
历史存储形式
编辑
衍生表
</
Button
>
</
Button
>
}
}
<
Tooltip
title=
{
editTip
}
>
<
Tooltip
title=
{
editTip
}
>
...
@@ -344,7 +344,7 @@ const EditModel = (props) => {
...
@@ -344,7 +344,7 @@ const EditModel = (props) => {
loading=
{
confirmLoading
}
loading=
{
confirmLoading
}
danger
danger
>
>
保存
{
action
===
'edit'
?
'保存'
:
'保存衍生表'
}
</
Button
>
</
Button
>
</
Space
>
</
Space
>
)
)
...
...
src/view/Manage/Model/Component/ImportAction.jsx
View file @
f7f6b3b8
...
@@ -31,7 +31,6 @@ const ImportAction = (props) => {
...
@@ -31,7 +31,6 @@ const ImportAction = (props) => {
const
modelerDataRef
=
useRef
(
null
);
const
modelerDataRef
=
useRef
(
null
);
useEffect
(()
=>
{
useEffect
(()
=>
{
if
((
action
||
''
)
===
''
)
return
;
if
((
action
||
''
)
===
''
)
return
;
if
(
!
mountRef
.
current
&&
action
===
'edit'
&&
!
permitCheckOut
)
{
if
(
!
mountRef
.
current
&&
action
===
'edit'
&&
!
permitCheckOut
)
{
...
...
src/view/Manage/Model/Component/ImportActionInherited.jsx
View file @
f7f6b3b8
import
React
,
{
useState
,
useContext
,
useEffect
}
from
"react"
;
import
React
,
{
useState
,
useContext
,
useEffect
,
useRef
}
from
"react"
;
import
{
Button
,
Tabs
,
Checkbox
}
from
"antd"
;
import
{
Button
,
Tabs
,
Checkbox
}
from
"antd"
;
import
{
DownOutlined
,
UpOutlined
}
from
"@ant-design/icons"
;
import
{
DownOutlined
,
UpOutlined
}
from
"@ant-design/icons"
;
...
@@ -19,6 +19,8 @@ const FC = (props) => {
...
@@ -19,6 +19,8 @@ const FC = (props) => {
const
[
zipperModelerData
,
setZipperModelerData
]
=
useState
(
undefined
);
const
[
zipperModelerData
,
setZipperModelerData
]
=
useState
(
undefined
);
const
{
createHistoryModel
,
createZipperModel
,
setInheriteState
,
setInheriteData
}
=
useContext
(
EditInheritedModelContext
);
const
{
createHistoryModel
,
createZipperModel
,
setInheriteState
,
setInheriteData
}
=
useContext
(
EditInheritedModelContext
);
const
mountRef
=
useRef
(
true
);
useEffect
(()
=>
{
useEffect
(()
=>
{
if
(
!
editable
)
{
if
(
!
editable
)
{
if
(
modelerData
?.
final
)
{
if
(
modelerData
?.
final
)
{
...
@@ -38,18 +40,20 @@ const FC = (props) => {
...
@@ -38,18 +40,20 @@ const FC = (props) => {
if
(
modelerData
)
{
if
(
modelerData
)
{
if
(
modelerData
.
inherited
?.
historical
)
{
if
(
modelerData
.
inherited
?.
historical
)
{
setHistoricalModelerData
(
modelerData
.
inherited
?.
historical
);
setHistoricalModelerData
(
modelerData
.
inherited
?.
historical
);
}
else
{
}
else
if
(
mountRef
.
current
)
{
getInheriteDataModel
(
inheritanceHistoricalType
);
getInheriteDataModel
(
inheritanceHistoricalType
);
}
}
if
(
modelerData
.
inherited
?.
zipper
)
{
if
(
modelerData
.
inherited
?.
zipper
)
{
setZipperModelerData
(
modelerData
.
inherited
?.
zipper
);
setZipperModelerData
(
modelerData
.
inherited
?.
zipper
);
}
else
{
}
else
if
(
mountRef
.
current
)
{
getInheriteDataModel
(
inheritanceZipperType
);
getInheriteDataModel
(
inheritanceZipperType
);
}
}
mountRef
.
current
=
false
;
}
}
}
}
//eslint-disable-next-line react-hooks/exhaustive-deps
//eslint-disable-next-line react-hooks/exhaustive-deps
},
[
editable
,
modelerData
])
},
[
modelerData
,
editable
])
const
getInheriteDataModel
=
(
type
)
=>
{
const
getInheriteDataModel
=
(
type
)
=>
{
dispatch
({
dispatch
({
...
@@ -146,7 +150,7 @@ const FC = (props) => {
...
@@ -146,7 +150,7 @@ const FC = (props) => {
</
Tabs
>
:
<
div
className=
'flex'
style=
{
{
alignItems
:
'center'
}
}
>
</
Tabs
>
:
<
div
className=
'flex'
style=
{
{
alignItems
:
'center'
}
}
>
<
h2
className=
'mr-3'
style=
{
{
marginBottom
:
0
}
}
>
历史存储形式
</
h2
>
<
h2
className=
'mr-3'
style=
{
{
marginBottom
:
0
}
}
>
历史存储形式
</
h2
>
{
{
relationModelerDatas
?.
map
((
item
,
index
)
=>
<
a
className=
'mr-3'
key=
{
index
}
onClick=
{
()
=>
{
relationModelerDatas
?.
length
===
0
?
<
span
>
暂无信息
</
span
>
:
relationModelerDatas
?.
map
((
item
,
index
)
=>
<
a
className=
'mr-3'
key=
{
index
}
onClick=
{
()
=>
{
window
.
open
(
`/data-govern/data-model-action?${Action}=detail&${ModelerId}=${item.id}&${PermitCheckOut}=${item.permitCheckOut||false}&${Editable}=${item.editable||false}&${StateId}=${item.state?.id||''}&${Holder}=${item.holder||''}&${ReadOnly}=false`
);
window
.
open
(
`/data-govern/data-model-action?${Action}=detail&${ModelerId}=${item.id}&${PermitCheckOut}=${item.permitCheckOut||false}&${Editable}=${item.editable||false}&${StateId}=${item.state?.id||''}&${Holder}=${item.holder||''}&${ReadOnly}=false`
);
}
}
>
{
item
.
cnName
}
</
a
>)
}
}
>
{
item
.
cnName
}
</
a
>)
}
}
...
...
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