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
0ba92ffc
Commit
0ba92ffc
authored
Dec 01, 2022
by
zhaochengxiang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
增加URI
parent
e6409075
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
22 additions
and
3 deletions
+22
-3
ModelTable.jsx
src/view/Manage/Model/Component/ModelTable.jsx
+15
-2
ODataConfigModal.jsx
src/view/Manage/Model/Component/ODataConfigModal.jsx
+7
-1
No files found.
src/view/Manage/Model/Component/ModelTable.jsx
View file @
0ba92ffc
...
...
@@ -277,6 +277,19 @@ const ModelTable = (props) => {
);
}
},
{
title
:
'URI'
,
dataIndex
:
'odata'
,
ellipsis
:
true
,
width
:
170
,
render
:
(
text
,
_
,
__
)
=>
{
return
(
<
Tooltip
title=
{
text
||
''
}
overlayClassName=
'tooltip-common'
>
<
Text
ellipsis=
{
true
}
>
{
text
||
''
}
</
Text
>
</
Tooltip
>
);
}
},
];
const
[
columns
,
setColumns
]
=
useState
([]);
...
...
@@ -856,12 +869,12 @@ const ModelTable = (props) => {
</
RcItem
>
}
{
getDataModelerRole
(
user
)
!==
DataModelerRoleReader
&&
view
!==
'grant'
&&
!
isOnlyEnding
&&
<
RcItem
id=
"enableOData"
onClick=
{
handleItemClick
}
>
getDataModelerRole
(
user
)
!==
DataModelerRoleReader
&&
view
!==
'grant'
&&
!
isOnlyEnding
&&
currentItem
?.
supportODataEnable
&&
<
RcItem
id=
"enableOData"
onClick=
{
handleItemClick
}
>
启动OData
</
RcItem
>
}
{
getDataModelerRole
(
user
)
!==
DataModelerRoleReader
&&
view
!==
'grant'
&&
!
isOnlyEnding
&&
<
RcItem
id=
"disableOData"
onClick=
{
handleItemClick
}
>
getDataModelerRole
(
user
)
!==
DataModelerRoleReader
&&
view
!==
'grant'
&&
!
isOnlyEnding
&&
currentItem
?.
supportODataDisable
&&
<
RcItem
id=
"disableOData"
onClick=
{
handleItemClick
}
>
停用OData
</
RcItem
>
}
...
...
src/view/Manage/Model/Component/ODataConfigModal.jsx
View file @
0ba92ffc
import
React
,
{
useState
}
from
'react'
;
import
React
,
{
use
Effect
,
use
State
}
from
'react'
;
import
{
Modal
,
Button
,
Form
,
Input
}
from
'antd'
;
import
{
dispatch
}
from
'../../../../model'
;
...
...
@@ -7,6 +7,12 @@ const FC = (props) => {
const
[
confirmLoading
,
setConfirmLoading
]
=
useState
(
false
);
const
[
form
]
=
Form
.
useForm
();
useEffect
(()
=>
{
if
(
visible
)
{
form
?.
setFieldsValue
({
name
:
service
?.
odata
});
}
},
[
visible
])
const
onOk
=
async
()
=>
{
try
{
const
row
=
await
form
.
validateFields
();
...
...
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