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
d0e7d733
Commit
d0e7d733
authored
Mar 29, 2024
by
zhaochengxiang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
服务导出增加状态过滤
parent
8f7d1cb0
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
9 deletions
+20
-9
ModelTree.jsx
src/view/Manage/Model/Component/ModelTree.jsx
+2
-1
index.jsx
src/view/Manage/Model/index.jsx
+18
-8
No files found.
src/view/Manage/Model/Component/ModelTree.jsx
View file @
d0e7d733
...
...
@@ -34,7 +34,7 @@ const ModelTree = (props) => {
id
:
MENU_ID
,
});
const
{
onSelect
,
onViewChange
,
refrence
=
''
,
importStockModel
,
keyword
,
isOnlyEnding
=
false
}
=
props
;
const
{
onSelect
,
onViewChange
,
refrence
=
''
,
importStockModel
,
keyword
,
isOnlyEnding
=
false
,
getRootId
}
=
props
;
const
{
user
,
env
}
=
useContext
(
AppContext
);
const
[
loading
,
setLoading
]
=
useState
(
false
);
...
...
@@ -207,6 +207,7 @@ const ModelTree = (props) => {
setLoading(false);
setTreeData(data.subCatalogs||[]);
setRootId(data.id||'');
getRootId(data.id||'');
setRootItem(data);
const _dataList = [];
...
...
src/view/Manage/Model/index.jsx
View file @
d0e7d733
...
...
@@ -75,6 +75,7 @@ class Model extends React.Component {
offlineVisible
:
false
,
jdbcInformationVisible
:
false
,
isRoot
:
false
,
rootId
:
undefined
,
importServicesVisible
:
false
,
loadingAttrs
:
false
,
attrs
:
[],
...
...
@@ -332,7 +333,8 @@ class Model extends React.Component {
}
onSearchInputChange = (value) => {
this.setState({ keyword: value||'', catalogId: '', isRoot: true }, () => {
const { rootId } = this.state
this.setState({ keyword: value||'', catalogId: rootId||'', isRoot: true }, () => {
if (value !== '') {
this.onTableChange();
}
...
...
@@ -422,9 +424,19 @@ class Model extends React.Component {
onExportClick = () => {
const { modal } = this.props;
const { catalogId, selectModelerIds } = this.state;
const { catalogId, selectModelerIds
, currentModelState
} = this.state;
if ((selectModelerIds??[]).length === 0) {
let params = {
pdsDataServiceCatalogId: catalogId,
namespace: this.props.app?.env?.domainId,
isExcludeOtherOwner: !this.props.isOnlyEnding,
}
if (currentModelState) {
params.stateId = currentModelState
}
modal?.confirm({
title: '提示',
content: '是否确认导表格中所有数据?',
...
...
@@ -433,11 +445,7 @@ class Model extends React.Component {
type: 'pds.exportAll',
payload: {
responseType: 'blob',
params: {
pdsDataServiceCatalogId: catalogId,
namespace: this.props.app?.env?.domainId,
isExcludeOtherOwner: !this.props.isOnlyEnding
}
params,
},
callback: (res) => {
download(res)
...
...
@@ -803,7 +811,9 @@ class Model extends React.Component {
axis='x'
minConstraints={[230, Infinity]} maxConstraints={[Infinity, Infinity]}
>
<ModelTree onViewChange={this.onViewChange} onSelect={this.onTreeSelect} importStockModel={this.importStockModel} keyword={keyword} isOnlyEnding={isOnlyEnding} {...this.props} />
<ModelTree onViewChange={this.onViewChange} onSelect={this.onTreeSelect} importStockModel={this.importStockModel} keyword={keyword} isOnlyEnding={isOnlyEnding} getRootId={(val) => {
this.setState({ rootId: val })
}} {...this.props} />
</ResizableBox>
<div className='tree-toggle-wrap'>
<div className='tree-toggle' onClick={this.treeToggleClick}>
...
...
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