Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
B
bigDataSystem
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
张伯涛
bigDataSystem
Commits
15526b48
Commit
15526b48
authored
Nov 25, 2024
by
曹泽华
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
数据服务 服务监控-开发者/管理员
parent
49471aac
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
96 additions
and
110 deletions
+96
-110
index.vue
src/views/dataService/serviceDevelopment/index.vue
+95
-94
index.vue
src/views/dataService/serviceMonitor/index.vue
+1
-16
No files found.
src/views/dataService/serviceDevelopment/index.vue
View file @
15526b48
...
@@ -4,10 +4,25 @@
...
@@ -4,10 +4,25 @@
<BasicTable
@
register=
"registerTable"
class=
"w-3/4 xl:w-4/5"
:searchInfo=
"searchInfo"
>
<BasicTable
@
register=
"registerTable"
class=
"w-3/4 xl:w-4/5"
:searchInfo=
"searchInfo"
>
<template
#
toolbar
>
<template
#
toolbar
>
<a-button
type=
"primary"
@
click=
"typeManageButton"
>
类别管理
</a-button>
<a-button
type=
"primary"
@
click=
"typeManageButton"
>
类别管理
</a-button>
<a-button
type=
"primary"
:disabled=
"getRowSelection().selectedRowKeys
<
=
0
"
@
click=
"exportButton"
>
导出
</a-button>
<a-button
type=
"primary"
:disabled=
"getRowSelection().selectedRowKeys
<
=
0
"
@
click=
"exportButton"
>
导出
</a-button
>
<a-button
type=
"primary"
@
click=
"importButton"
>
导入
</a-button>
<a-button
type=
"primary"
@
click=
"importButton"
>
导入
</a-button>
<a-button
type=
"primary"
:disabled=
"getRowSelection().selectedRowKeys
<
=
0
"
@
click=
"copyButton"
>
复制到
</a-button>
<a-button
<a-button
type=
"primary"
:disabled=
"getRowSelection().selectedRowKeys
<
=
0
"
@
click=
"MoveButton"
>
移动
</a-button>
type=
"primary"
:disabled=
"getRowSelection().selectedRowKeys
<
=
0
"
@
click=
"copyButton"
>
复制到
</a-button
>
<a-button
type=
"primary"
:disabled=
"getRowSelection().selectedRowKeys
<
=
0
"
@
click=
"MoveButton"
>
移动
</a-button
>
<a-button
type=
"primary"
@
click=
"createDocumentButton"
>
新建文件夹
</a-button>
<a-button
type=
"primary"
@
click=
"createDocumentButton"
>
新建文件夹
</a-button>
<a-button
type=
"primary"
@
click=
"createAPIButton"
>
新建API
</a-button>
<a-button
type=
"primary"
@
click=
"createAPIButton"
>
新建API
</a-button>
</
template
>
</
template
>
...
@@ -20,12 +35,17 @@
...
@@ -20,12 +35,17 @@
// label: '重命名',
// label: '重命名',
onClick: resetNameButton.bind(null, record),
onClick: resetNameButton.bind(null, record),
},
},
{
icon: 'ant-design:fund-projection-screen-outlined',
// label: '重命名',
onClick: apiMonitorButton.bind(null, record),
},
{
{
icon: 'eos-icons:api-outlined',
icon: 'eos-icons:api-outlined',
// label: 'api doc',
// label: 'api doc',
onClick: apiDocButton.bind(null, record),
onClick: apiDocButton.bind(null, record),
},
},
{
{
icon: 'ant-design:send-outlined',
icon: 'ant-design:send-outlined',
// label: '发布',
// label: '发布',
onClick: publishButton.bind(null, record),
onClick: publishButton.bind(null, record),
...
@@ -63,28 +83,28 @@
...
@@ -63,28 +83,28 @@
<a
@
click=
"editApi(record)"
>
{{
text
}}
</a>
<a
@
click=
"editApi(record)"
>
{{
text
}}
</a>
</
template
>
</
template
>
</BasicTable>
</BasicTable>
<!-- 新建文件夹 弹窗-->
<!-- 新建文件夹 弹窗-->
<CreateDocument
@
register=
"registerCreateDocumentModal"
@
success=
"handleSuccess"
/>
<CreateDocument
@
register=
"registerCreateDocumentModal"
@
success=
"handleSuccess"
/>
<!-- 新建API 弹窗-->
<!-- 新建API 弹窗-->
<CreateAPI
@
register=
"registerCreateAPIModal"
@
success=
"handleSuccess"
/>
<CreateAPI
@
register=
"registerCreateAPIModal"
@
success=
"handleSuccess"
/>
<!-- 移动 弹窗-->
<!-- 移动 弹窗-->
<MoveModal
@
register=
"registerMoveModal"
@
success=
"handleSuccess"
/>
<MoveModal
@
register=
"registerMoveModal"
@
success=
"handleSuccess"
/>
<!-- 复制到 弹窗-->
<!-- 复制到 弹窗-->
<CopyModal
@
register=
"registerCopyModal"
@
success=
"handleSuccess"
/>
<CopyModal
@
register=
"registerCopyModal"
@
success=
"handleSuccess"
/>
<!-- 重命名 弹窗-->
<!-- 重命名 弹窗-->
<ResetNameModal
@
register=
"registerResetNameModal"
@
success=
"handleSuccess"
/>
<ResetNameModal
@
register=
"registerResetNameModal"
@
success=
"handleSuccess"
/>
<!-- 版本管理 弹窗-->
<!-- 版本管理 弹窗-->
<VersionModal
@
register=
"registerVersionModal"
@
success=
"handleSuccess"
/>
<VersionModal
@
register=
"registerVersionModal"
@
success=
"handleSuccess"
/>
<!-- 导入 弹窗-->
<!-- 导入 弹窗-->
<ImportModal
@
register=
"registerImportModal"
@
success=
"handleSuccess"
/>
<ImportModal
@
register=
"registerImportModal"
@
success=
"handleSuccess"
/>
<!-- 版本发布申请 弹窗-->
<!-- 版本发布申请 弹窗-->
<PublishApplicationModal
@
register=
"registerPublishApplicationModal"
@
success=
"handleSuccess"
/>
<PublishApplicationModal
@
register=
"registerPublishApplicationModal"
@
success=
"handleSuccess"
/>
<!-- 类别管理 弹窗-->
<!-- 类别管理 弹窗-->
<TypeManageModal
@
register=
"registerTypeManageModal"
@
success=
"handleSuccess"
/>
<TypeManageModal
@
register=
"registerTypeManageModal"
@
success=
"handleSuccess"
/>
</PageWrapper>
</PageWrapper>
</template>
</template>
<
script
lang=
"ts"
setup
>
<
script
lang=
"ts"
setup
>
import
{
reactive
,
unref
,
onDeactivated
,
onMounted
,
ref
}
from
'vue'
;
import
{
reactive
,
unref
,
onDeactivated
,
onMounted
,
ref
}
from
'vue'
;
import
{
BasicTable
,
useTable
,
TableAction
}
from
'@/components/Table'
;
import
{
BasicTable
,
useTable
,
TableAction
}
from
'@/components/Table'
;
import
{
PageWrapper
}
from
'@/components/Page'
;
import
{
PageWrapper
}
from
'@/components/Page'
;
import
ApiTree
from
'./ApiTree.vue'
;
import
ApiTree
from
'./ApiTree.vue'
;
...
@@ -99,13 +119,13 @@
...
@@ -99,13 +119,13 @@
import
{
columns
,
searchFormSchema
}
from
'./api.data'
;
import
{
columns
,
searchFormSchema
}
from
'./api.data'
;
import
{
useGo
}
from
'@/hooks/web/usePage'
;
import
{
useGo
}
from
'@/hooks/web/usePage'
;
import
{
useRoute
}
from
'vue-router'
;
import
{
useRoute
}
from
'vue-router'
;
import
{
TreeData
}
from
"./apiData"
;
import
{
TreeData
}
from
'./apiData'
;
import
{
router
}
from
'@/router'
;
import
{
router
}
from
'@/router'
;
import
{
exportUserList
}
from
"@/api/system/user/user"
;
import
{
exportUserList
}
from
'@/api/system/user/user'
;
import
{
downloadByData
}
from
"@/utils/file/download"
;
import
{
downloadByData
}
from
'@/utils/file/download'
;
import
ImportModal
from
'./ImportModal.vue'
import
ImportModal
from
'./ImportModal.vue'
;
import
PublishApplicationModal
from
'./PublishApplicationModal.vue'
import
PublishApplicationModal
from
'./PublishApplicationModal.vue'
;
import
TypeManageModal
from
'./TypeManageModal.vue'
import
TypeManageModal
from
'./TypeManageModal.vue'
;
defineOptions
({
name
:
'AccountManagement'
});
defineOptions
({
name
:
'AccountManagement'
});
const
{
createMessage
,
createConfirm
}
=
useMessage
();
const
{
createMessage
,
createConfirm
}
=
useMessage
();
...
@@ -121,30 +141,33 @@
...
@@ -121,30 +141,33 @@
const
[
registerCopyModal
,
{
openModal
:
openCopyModal
}]
=
useModal
();
const
[
registerCopyModal
,
{
openModal
:
openCopyModal
}]
=
useModal
();
const
[
registerResetNameModal
,
{
openModal
:
openResetNameModal
}]
=
useModal
();
const
[
registerResetNameModal
,
{
openModal
:
openResetNameModal
}]
=
useModal
();
const
searchInfo
=
reactive
<
Recordable
>
({});
const
searchInfo
=
reactive
<
Recordable
>
({});
const
tableData
=
ref
([])
const
tableData
=
ref
([]);
const
[
registerTable
,
{
reload
,
updateTableDataRecord
,
getSearchInfo
,
getForm
,
getRowSelection
}]
=
useTable
({
const
[
registerTable
,
{
reload
,
updateTableDataRecord
,
getSearchInfo
,
getForm
,
getRowSelection
},
]
=
useTable
({
title
:
''
,
title
:
''
,
api
:
async
(
params
)
=>
{
api
:
async
(
params
)
=>
{
//过滤掉tableData.value中,businessId等于100的
//过滤掉tableData.value中,businessId等于100的
var
data
=
[];
var
data
=
[];
if
(
params
.
taskId
==
undefined
||
params
.
taskId
==
''
)
{
if
(
params
.
taskId
==
undefined
||
params
.
taskId
==
''
)
{
data
=
tableData
.
value
.
filter
((
item
)
=>
item
.
businessId
>=
200
);
data
=
tableData
.
value
.
filter
((
item
)
=>
item
.
businessId
>=
200
);
}
else
if
(
params
.
taskId
>=
200
)
{
}
else
if
(
params
.
taskId
>=
200
)
{
data
=
tableData
.
value
.
filter
((
item
)
=>
item
.
businessId
==
params
.
taskId
);
data
=
tableData
.
value
.
filter
((
item
)
=>
item
.
businessId
==
params
.
taskId
);
}
else
{
}
else
{
data
=
tableData
.
value
.
filter
((
item
)
=>
item
.
parentId
==
params
.
taskId
);
data
=
tableData
.
value
.
filter
((
item
)
=>
item
.
parentId
==
params
.
taskId
);
}
}
const
response
=
{
const
response
=
{
pageNu
:
"1"
,
pageNu
:
'1'
,
pageSize
:
"10"
,
pageSize
:
'10'
,
pages
:
"1"
,
pages
:
'1'
,
total
:
data
.
length
,
total
:
data
.
length
,
code
:
''
,
code
:
''
,
message
:
''
,
message
:
''
,
data
:
[],
data
:
[],
};
};
//过滤data中的数据,取出等于params.deptId的数据
//过滤data中的数据,取出等于params.deptId的数据
return
{
...
response
,
data
:
data
};
return
{
...
response
,
data
:
data
};
},
},
rowKey
:
'businessId'
,
rowKey
:
'businessId'
,
columns
,
columns
,
...
@@ -154,92 +177,85 @@
...
@@ -154,92 +177,85 @@
schemas
:
searchFormSchema
,
schemas
:
searchFormSchema
,
autoSubmitOnEnter
:
true
,
autoSubmitOnEnter
:
true
,
resetFunc
:
()
=>
{
resetFunc
:
()
=>
{
searchInfo
.
taskId
=
''
searchInfo
.
taskId
=
''
;
},
},
},
},
useSearchForm
:
true
,
useSearchForm
:
true
,
showTableSetting
:
false
,
showTableSetting
:
false
,
showIndexColumn
:
false
,
showIndexColumn
:
false
,
bordered
:
true
,
bordered
:
true
,
handleSearchInfoFn
(
info
)
{
handleSearchInfoFn
(
info
)
{
return
info
;
return
info
;
},
},
actionColumn
:
{
actionColumn
:
{
width
:
25
0
,
width
:
30
0
,
title
:
'操作'
,
title
:
'操作'
,
dataIndex
:
'action'
,
dataIndex
:
'action'
,
},
},
});
});
/**类别管理 按钮*/
/**类别管理 按钮*/
function
typeManageButton
()
{
function
typeManageButton
()
{
openTypeManageModal
(
true
,
{
openTypeManageModal
(
true
,
{});
});
}
}
/**版本管理 按钮*/
/**版本管理 按钮*/
function
versionButton
()
{
function
versionButton
()
{
openVersionModal
(
true
,
{
openVersionModal
(
true
,
{});
});
}
}
/**复制到 按钮*/
/**复制到 按钮*/
function
copyButton
()
{
function
copyButton
()
{
openCopyModal
(
true
,
{
openCopyModal
(
true
,
{});
});
}
}
/**导入*/
/**导入*/
function
importButton
()
{
function
importButton
()
{
openImportModal
(
true
,
{
openImportModal
(
true
,
{});
});
}
}
/**重命名 按钮*/
/**重命名 按钮*/
function
resetNameButton
(
record
)
{
function
resetNameButton
(
record
)
{
openResetNameModal
(
true
,
{
openResetNameModal
(
true
,
{
record
record
,
});
}
/**查看API监控信息 按钮*/
function
apiMonitorButton
(
record
)
{
router
.
push
({
path
:
'/dataService/serviceMonitor/monitorInfo'
,
query
:
{},
});
});
}
}
/**发布 按钮*/
/**发布 按钮*/
function
publishButton
(
record
)
{
function
publishButton
(
record
)
{
openPublishApplicationModal
(
true
,{
openPublishApplicationModal
(
true
,
{
record
record
,
})
})
;
}
}
/**编辑API*/
/**编辑API*/
function
editApi
(
record
)
{
function
editApi
(
record
)
{
const
mode
=
record
.
mode
const
mode
=
record
.
mode
;
if
(
mode
===
'向导模式'
){
if
(
mode
===
'向导模式'
)
{
router
.
push
({
router
.
push
({
path
:
'/dataService/serviceDevelopment/guideModeApi'
,
path
:
'/dataService/serviceDevelopment/guideModeApi'
,
query
:
{
query
:
{},
});
}
})
}
}
if
(
mode
===
'SQL模式'
){
if
(
mode
===
'SQL模式'
)
{
router
.
push
({
router
.
push
({
path
:
'/dataService/serviceDevelopment/sqlModeApi'
,
path
:
'/dataService/serviceDevelopment/sqlModeApi'
,
query
:
{
query
:
{},
});
}
})
}
}
if
(
mode
===
'托管模式'
){
if
(
mode
===
'托管模式'
)
{
router
.
push
({
router
.
push
({
path
:
'/dataService/serviceDevelopment/trusteeshipModeApi'
,
path
:
'/dataService/serviceDevelopment/trusteeshipModeApi'
,
query
:
{
query
:
{},
});
}
})
}
}
}
}
...
@@ -247,18 +263,13 @@
...
@@ -247,18 +263,13 @@
function
apiDocButton
(
record
)
{
function
apiDocButton
(
record
)
{
router
.
push
({
router
.
push
({
path
:
'/dataService/serviceDevelopment/ApiDoc'
,
path
:
'/dataService/serviceDevelopment/ApiDoc'
,
query
:
{
query
:
{},
});
},
})
}
}
/**复制到 按钮*/
/**复制到 按钮*/
function
copyButton1
()
{
function
copyButton1
()
{
openCopyModal
(
true
,
{
openCopyModal
(
true
,
{});
});
}
}
/**查看详情*/
/**查看详情*/
...
@@ -266,19 +277,16 @@
...
@@ -266,19 +277,16 @@
router
.
push
({
router
.
push
({
path
:
'/dataStandards/publicCode/detailPublicCode'
,
path
:
'/dataStandards/publicCode/detailPublicCode'
,
query
:
{
query
:
{
businessId
:
record
.
businessId
,
businessId
:
record
.
businessId
,
},
},
});
});
}
}
/**移动*/
/**移动*/
function
MoveButton
()
{
function
MoveButton
()
{
openMoveModal
(
true
,
{
openMoveModal
(
true
,
{});
});
}
}
/**删除按钮*/
/**删除按钮*/
function
deleteButton
()
{
function
deleteButton
()
{
createMessage
.
success
(
'删除成功!'
);
createMessage
.
success
(
'删除成功!'
);
...
@@ -286,16 +294,12 @@
...
@@ -286,16 +294,12 @@
/**新建文件夹*/
/**新建文件夹*/
function
createDocumentButton
()
{
function
createDocumentButton
()
{
openCreateDocumentModal
(
true
,
{
openCreateDocumentModal
(
true
,
{});
});
}
}
/**新建API*/
/**新建API*/
function
createAPIButton
()
{
function
createAPIButton
()
{
openCreateAPIModal
(
true
,
{
openCreateAPIModal
(
true
,
{});
});
}
}
/**导出 按钮*/
/**导出 按钮*/
...
@@ -305,10 +309,7 @@
...
@@ -305,10 +309,7 @@
downloadByData
(
data
,
'API信息'
+
'.xlsx'
);
downloadByData
(
data
,
'API信息'
+
'.xlsx'
);
}
}
function
handleSuccess
({
isUpdate
,
values
})
{
function
handleSuccess
({
isUpdate
,
values
})
{}
}
/** 树的select*/
/** 树的select*/
function
handleSelect
(
taskId
=
''
)
{
function
handleSelect
(
taskId
=
''
)
{
...
@@ -321,12 +322,12 @@
...
@@ -321,12 +322,12 @@
router
.
push
({
router
.
push
({
path
:
'/dataStandards/publicCode/relatedRelationships'
,
path
:
'/dataStandards/publicCode/relatedRelationships'
,
query
:
{
query
:
{
businessId
:
record
.
businessId
,
businessId
:
record
.
businessId
,
},
},
});
});
}
}
onMounted
(()
=>
{
onMounted
(()
=>
{
tableData
.
value
=
TreeData
tableData
.
value
=
TreeData
;
});
});
</
script
>
</
script
>
src/views/dataService/serviceMonitor/index.vue
View file @
15526b48
...
@@ -82,7 +82,7 @@
...
@@ -82,7 +82,7 @@
const
APIRate
=
ref
(
'375'
);
const
APIRate
=
ref
(
'375'
);
const
[
const
[
registerTable
,
registerTable
,
{
reload
,
updateTableDataRecord
,
getSearchInfo
,
getForm
,
getRowSelection
},
{
reload
,
updateTableDataRecord
,
setTableData
,
getSearchInfo
,
getForm
,
getRowSelection
},
]
=
useTable
({
]
=
useTable
({
title
:
'执行中请求'
,
title
:
'执行中请求'
,
scroll
:
{
y
:
500
},
scroll
:
{
y
:
500
},
...
@@ -127,27 +127,12 @@
...
@@ -127,27 +127,12 @@
},
},
});
});
function
handleImport
()
{
openImportModal
(
true
,
{});
}
function
handleLog
()
{
function
handleLog
()
{
router
.
push
({
router
.
push
({
path
:
'/dataService/serviceMonitor/useLog'
,
path
:
'/dataService/serviceMonitor/useLog'
,
});
});
}
}
function
handleDeleteIds
()
{
createConfirm
({
iconType
:
'warning'
,
title
:
'确认删除'
,
content
:
'确认批量删除选中数据吗?'
,
onOk
()
{
createMessage
.
success
(
'批量删除成功!'
);
},
});
}
/** 部门树的select*/
/** 部门树的select*/
function
handleSelect
(
key
)
{
function
handleSelect
(
key
)
{
if
(
key
!==
null
&&
key
!==
undefined
)
{
if
(
key
!==
null
&&
key
!==
undefined
)
{
...
...
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