Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
csbr-daop
/
fe-data-trusted-space
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
751d9bbf
authored
2024-12-23 16:34:37 +0800
by
xukangle
Browse Files
Options
Browse Files
Tag
Download
Plain Diff
Merge branch 'develop' into dev_20241202_xukangle
2 parents
1fec05c1
a36959df
Show whitespace changes
Inline
Side-by-side
Showing
12 changed files
with
1215 additions
and
2151 deletions
src/api/modules/dataInventory.ts
src/components/Dialog/index.vue
src/components/Tools/table_search.vue
src/components/Tools/table_tools.vue
src/layouts/components/SidebarItem/index.vue
src/router/modules/dataInventory.ts
src/store/modules/user.ts
src/utils/request.ts
src/views/data_inventory/taskConfig.vue
src/views/data_inventory/taskDetail.vue
src/views/data_inventory/taskEdit.vue
src/views/data_inventory/taskLog.vue
src/api/modules/dataInventory.ts
View file @
751d9bb
...
...
@@ -230,6 +230,17 @@ export const getClassifyGradList = (data) => request({
data
})
/**
* 分级列表详情
* @param {Object}
* @path /classify-grade/page-list
*/
export
const
getClassifyGradDetail
=
(
data
)
=>
request
({
url
:
`
${
import
.
meta
.
env
.
VITE_APP_CHECK_BASEURL
}
/classify-grade/detail`
,
method
:
'get'
,
params
:
data
})
/**
* 分级新增
...
...
@@ -397,6 +408,178 @@ export const getCgDirFieldPageList = (data) => request({
data
})
// 分来分级任务-分页
export
const
getCgTaskPageList
=
(
data
)
=>
request
({
url
:
`
${
import
.
meta
.
env
.
VITE_APP_CHECK_BASEURL
}
/cg-task/page-list`
,
method
:
'post'
,
data
})
// 分来分级任务-详情
export
const
getCgTaskDetail
=
(
data
)
=>
request
({
url
:
`
${
import
.
meta
.
env
.
VITE_APP_CHECK_BASEURL
}
/cg-task/detail`
,
method
:
'get'
,
params
:
data
})
// 分来分级任务-新增
export
const
cgTaskSave
=
(
data
)
=>
request
({
url
:
`
${
import
.
meta
.
env
.
VITE_APP_CHECK_BASEURL
}
/cg-task/save`
,
method
:
'post'
,
data
})
// 分来分级任务-修改
export
const
cgTaskUpdate
=
(
data
)
=>
request
({
url
:
`
${
import
.
meta
.
env
.
VITE_APP_CHECK_BASEURL
}
/cg-task/update`
,
method
:
'put'
,
data
})
// 分来分级任务-删除
export
const
cgTaskDelete
=
(
data
)
=>
request
({
url
:
`
${
import
.
meta
.
env
.
VITE_APP_CHECK_BASEURL
}
/cg-task/delete`
,
method
:
'delete'
,
data
})
// 手动执行任务
export
const
runExecTask
=
(
data
)
=>
request
({
url
:
`
${
import
.
meta
.
env
.
VITE_APP_CHECK_BASEURL
}
/cg-task/exec-task`
,
method
:
'post'
,
params
:
data
})
// 分类分级任务日志
export
const
getTaskExecPageList
=
(
data
)
=>
request
({
url
:
`
${
import
.
meta
.
env
.
VITE_APP_CHECK_BASEURL
}
/cg-task-exec/page-list`
,
method
:
'post'
,
data
})
// 分类分级任务执行树形数据
export
const
getTaskExeTreeList
=
(
data
)
=>
request
({
url
:
`
${
import
.
meta
.
env
.
VITE_APP_CHECK_BASEURL
}
/cg-task-exec/classify/tree-list`
,
method
:
'get'
,
params
:
data
})
// 分类分级任务执行字段统计
export
const
getTaskFieldCount
=
(
data
)
=>
request
({
url
:
`
${
import
.
meta
.
env
.
VITE_APP_CHECK_BASEURL
}
/cg-task-exec-result/confirm-field-cnt`
,
method
:
'get'
,
params
:
data
})
// 分类分级任务执行数据库信息查询
export
const
getDbFieldList
=
(
data
)
=>
request
({
url
:
`
${
import
.
meta
.
env
.
VITE_APP_CHECK_BASEURL
}
/cg-task-exec-result/confirm-query-db-list`
,
method
:
'get'
,
params
:
data
})
// 分类分级任务执行字段查询
export
const
execTaskFieldList
=
(
data
)
=>
request
({
url
:
`
${
import
.
meta
.
env
.
VITE_APP_CHECK_BASEURL
}
/cg-task-exec-result/confirm-field-list-query`
,
method
:
'post'
,
data
})
// 分类分级任务执行库表查询
export
const
execTaskSheetList
=
(
data
)
=>
request
({
url
:
`
${
import
.
meta
.
env
.
VITE_APP_CHECK_BASEURL
}
/cg-task-exec-result/confirm-db-list-query`
,
method
:
'post'
,
data
})
// 分类分级任务执行任务确认
export
const
execTaskConfirm
=
(
data
)
=>
request
({
url
:
`
${
import
.
meta
.
env
.
VITE_APP_CHECK_BASEURL
}
/cg-task-exec-result/confirm-task`
,
method
:
'post'
,
params
:
data
})
// 分类分级任务执行字段确认
export
const
execFieldConfirm
=
(
data
)
=>
request
({
url
:
`
${
import
.
meta
.
env
.
VITE_APP_CHECK_BASEURL
}
/cg-task-exec-result/confirm-field`
,
method
:
'post'
,
data
})
// 标签规则-分页
export
const
getCgLabelPageList
=
(
data
)
=>
request
({
url
:
`
${
import
.
meta
.
env
.
VITE_APP_CHECK_BASEURL
}
/cg-label/page-list`
,
method
:
'post'
,
data
})
// 元数据采集任务-分页
export
const
getMetaTableCollectList
=
(
data
)
=>
request
({
url
:
`
${
import
.
meta
.
env
.
VITE_APP_CHECK_BASEURL
}
/meta-table/meta-table-collect-list`
,
method
:
'post'
,
data
})
export
const
filterVal
=
(
val
,
type
)
=>
{
let
status
=
'--'
;
if
(
type
==
'status'
){
switch
(
val
)
{
case
'N'
:
status
=
'未运行'
;
break
;
case
'Y'
:
status
=
'成功'
;
break
;
case
'E'
:
status
=
'失败'
;
break
;
case
'R'
:
status
=
'运行中'
;
break
;
default
:
status
=
'未运行'
;
break
;
}
}
else
if
(
type
==
'confirmStatus'
){
switch
(
val
)
{
case
'N'
:
status
=
'待确认'
;
break
;
case
'Y'
:
status
=
'已确认'
;
break
;
default
:
status
=
'--'
;
break
;
}
}
else
if
(
type
==
'isCgChange'
){
switch
(
val
)
{
case
'N'
:
status
=
'待确认'
;
break
;
case
'Y'
:
status
=
'已确认'
;
break
;
default
:
status
=
'待确认'
;
break
;
}
}
else
if
(
type
==
'changeStatus'
){
switch
(
val
)
{
case
'N'
:
status
=
'待确认'
;
break
;
case
'Y'
:
status
=
'已确认'
;
break
;
default
:
status
=
'--'
;
break
;
}
}
return
status
;
}
/** 获取字典列表
* VITE_APP_PLAN_BASEURL 为环境变量 现在只是mock数据
*/
...
...
src/components/Dialog/index.vue
View file @
751d9bb
...
...
@@ -498,6 +498,11 @@ const scheduleChange = (val, rowValue) => {
const
treeSelectNodeChange
=
(
node
,
item
,
nodeObj
)
=>
{
emits
(
"treeSelectNodeChange"
,
node
,
item
,
nodeObj
);
}
const
getCascaderCheckedData
=
()
=>
{
const
dialogForm
=
dialogFormRef
.
value
[
0
]
||
dialogFormRef
.
value
;
return
dialogForm
.
getCascaderCheckedData
();
}
const
setTreeChecked
=
(
checkedKeys
,
leafOnly
:
boolean
=
false
)
=>
{
nextTick
(()
=>
{
const
formTree
=
formTreeRef
.
value
[
0
]
||
formTreeRef
.
value
;
...
...
@@ -533,7 +538,8 @@ defineExpose({
formTreeRef
,
setTableRowSelected
,
setTreeChecked
,
getDialogConRef
getDialogConRef
,
getCascaderCheckedData
});
</
script
>
...
...
src/components/Tools/table_search.vue
View file @
751d9bb
...
...
@@ -3,7 +3,17 @@ import { computed, reactive, ref } from 'vue'
import
{
Search
}
from
'@element-plus/icons-vue'
import
type
{
FormInstance
,
FormRules
}
from
'element-plus'
import
{
debounce
}
from
"@/utils/common"
const
emits
=
defineEmits
([
"tableSearch"
,
"toolFilterChange"
,
"loadMore"
,
"remoteMethod"
,
"treeSelectLoad"
,
"selectChange"
,
"treeSelectNodeChange"
,
"treeSelectNodeClick"
]);
const
emits
=
defineEmits
([
"tableSearch"
,
"toolFilterChange"
,
"loadMore"
,
"remoteMethod"
,
"treeSelectLoad"
,
"selectChange"
,
"treeSelectNodeChange"
,
"treeSelectNodeClick"
,
"cascaderChange"
,
]);
const
props
=
defineProps
({
itemList
:
{
type
:
Array
,
...
...
@@ -34,6 +44,7 @@ const resetForm = (formEl: FormInstance | undefined) => {
emits
(
'tableSearch'
,
form
,
true
)
})
}
defineExpose
({
formInline
,
formRef
...
...
@@ -68,10 +79,13 @@ const selectChange = (val, row) => {
const
handleTreeSelectNodeChange
=
(
node
,
item
)
=>
{
emits
(
"treeSelectNodeChange"
,
node
,
item
);
}
const
handleTreeSelectNodeClick
=
(
node
,
item
)
=>
{
const
handleTreeSelectNodeClick
=
(
node
,
item
)
=>
{
emits
(
"treeSelectNodeClick"
,
node
,
item
);
}
const
inputChange
=
(
val
)
=>
{
const
cascaderChange
=
(
val
,
item
)
=>
{
emits
(
"cascaderChange"
,
val
,
item
);
}
const
inputChange
=
(
val
)
=>
{
onSubmit
()
}
onMounted
(()
=>
{
...
...
@@ -86,56 +100,47 @@ onMounted(() => {
:class=
"
{ 'width_auto': item.type == 'radio-button' }" :prop="item.field">
<template
v-if=
"item.type == 'select'"
>
<el-select
:class=
"
{ 'is-multiple': item.multiple }" v-model="formInline[item.field]"
:placeholder="item.placeholder" :clearable="item.clearable" :filterable="item.filterable" @change="(val) => selectChange(val, item)">
<el-option
v-for=
"opt in item.options"
:label=
"item.props?.label ? opt[item.props.label] : opt.label"
:value=
"item.props?.value ? opt[item.props.value] : opt.value"
/>
:placeholder="item.placeholder" :clearable="item.clearable" :filterable="item.filterable"
:disabled="item.disabled ?? false" @change="(val) => selectChange(val, item)">
<el-option
v-for=
"opt in item.options"
:label=
"item.props?.label ? opt[item.props.label] : opt.label"
:value=
"item.props?.value ? opt[item.props.value] : opt.value"
/>
</el-select>
</
template
>
<
template
v-else-if=
"item.type == 'input-select'"
>
<el-input
v-model
.
trim=
"formInline[item.field]"
:placeholder=
"item.placeholder"
class=
"input-with-select"
:maxlength=
"item.maxlength ?? ''"
:suffix-icon=
"Search"
>
<el-input
v-model
.
trim=
"formInline[item.field]"
:placeholder=
"item.placeholder"
class=
"input-with-select"
:
maxlength=
"item.maxlength ?? ''"
:
suffix-icon=
"Search"
>
<template
#
prepend
>
<span
v-for=
"child in item.children"
>
<el-select
v-model=
"formItemList[child.field]"
:placeholder=
"child.placeholder"
:clearable=
"item.clearable"
style=
"vertical-align: inherit;"
>
<el-option
v-for=
"opts in child.options"
:label=
"child.props?.label ? opts[item.props.label] : opts.label"
:value=
"child.props?.value ? opts[item.props.value] : opts.value"
/>
<el-option
v-for=
"opts in child.options"
:label=
"child.props?.label ? opts[item.props.label] : opts.label"
:value=
"child.props?.value ? opts[item.props.value] : opts.value"
/>
</el-select>
</span>
</
template
>
</el-input>
</template>
<
template
v-else-if=
"item.type
==
'tree-select'"
>
<
template
v-else-if=
"item.type
==
'tree-select'"
>
<div
class=
"select_slots_panel"
>
<div
class=
"slot-prefix"
v-for=
"child in item.children"
>
<el-select
v-model=
"formInline[child.field]"
:placeholder=
"child.placeholder"
@
change=
"(val) => selectChange(val, child)"
>
<el-select
v-model=
"formInline[child.field]"
:placeholder=
"child.placeholder"
@
change=
"(val) => selectChange(val, child)"
>
<el-option
v-for=
"cpt in child.options"
:label=
"cpt.label"
:value=
"cpt.value"
/>
</el-select>
</div>
</div>
<div
class=
"slot-default"
>
<el-tree-select
v-model=
"formInline[item.field]"
:data=
"item.options"
:placeholder=
"item.placeholder"
:clearable=
"item.clearable"
:filterable=
"item.filterable"
:disabled=
"item.disabled"
:lazy=
"item.lazy ?? true"
:check-strictly =
"item.checkStrictly ?? false"
:node-key=
"item.nodeKey ?? 'guid'"
:load=
"(node, resolve) => treeSelectLoad(node, resolve, item)"
:props=
"item.props"
:multiple=
"item.multiple ?? false"
:render-after-expand=
"true"
:teleported=
"item.teleported ?? true"
:default-expanded-keys=
"item.expandKeys"
:collapse-tags-tooltip=
"item.collapseTagsTooltip ?? false"
:collapse-tags=
"item.collapseTags ?? false"
:max-collapse-tags=
"item.maxTags ?? 1"
:show-checkbox=
"item.showCheckbox ?? false"
@
change=
"(val) => selectChange(val, item)"
<el-tree-select
v-model=
"formInline[item.field]"
:data=
"item.options"
:placeholder=
"item.placeholder"
:clearable=
"item.clearable"
:filterable=
"item.filterable"
:disabled=
"item.disabled"
:lazy=
"item.lazy ?? true"
:check-strictly=
"item.checkStrictly ?? false"
:node-key=
"item.nodeKey ?? 'guid'"
:load=
"(node, resolve) => treeSelectLoad(node, resolve, item)"
:props=
"item.props"
:multiple=
"item.multiple ?? false"
:render-after-expand=
"true"
:teleported=
"item.teleported ?? true"
:default-expanded-keys=
"item.expandKeys"
:collapse-tags-tooltip=
"item.collapseTagsTooltip ?? false"
:collapse-tags=
"item.collapseTags ?? false"
:max-collapse-tags=
"item.maxTags ?? 1"
:show-checkbox=
"item.showCheckbox ?? false"
@
change=
"(val) => selectChange(val, item)"
@
current-change=
"(node) => handleTreeSelectNodeChange(node, item)"
@
node-click =
"(node)=>handleTreeSelectNodeClick(node, item)"
>
@
node-click=
"(node) => handleTreeSelectNodeClick(node, item)"
>
<!--
<template
#
default=
"
{ node, data }">
<template
v-if=
"item.getName"
>
...
...
@@ -153,8 +158,8 @@ onMounted(() => {
{{
item
.
getName
(
data
,
node
)
}}
</div>
</
template
>
<span
v-else
>
{{ data[item.props.label] }}
</span>
</template>
-->
<span
v-else
>
{{ data[item.props.label] }}
</span>
</template>
-->
</el-tree-select>
</div>
...
...
@@ -178,13 +183,21 @@ onMounted(() => {
<div
class=
"slot-default"
>
<el-select
:class=
"
{ 'is-multiple': item.multiple }" v-model="formInline[item.field]"
:placeholder="item.placeholder" :multiple="item.multiple" collapse-tags collapse-tags-tooltip
@change="(val) => selectChange(val, item)"
:
max-collapse-tags="3" :filterable="item.filterable" :
clearable="item.clearable" v-loadmore="loadMore">
@change="(val) => selectChange(val, item)"
:max-collapse-tags="3" :filterable="item.filterable"
:clearable="item.clearable" v-loadmore="loadMore">
<el-option
v-for=
"opt in item.options"
:label=
"opt.label"
:value=
"opt.value"
/>
</el-select>
</div>
</div>
</
template
>
<
template
v-else-if=
"item.type == 'cascader'"
>
<el-cascader
ref=
"formCascaderRef"
:class=
"[item.col,
{ is_block: item.block }]"
v-model="formInline[item.field]" :options="item.options" :props="item.props" :placeholder="item.placeholder"
:show-all-levels="item.showAllLevels ?? true" :clearable="item.clearable"
:filterable="item.filterable ?? false" :collapse-tags="item.collapse ?? false"
:collapse-tags-tooltip="item.tagsTooltip ?? false" :max-collapse-tags="item.maxTags ?? 1"
:disabled="item.disabled ?? false" @change="(val) => cascaderChange(val, item)" />
</
template
>
<
template
v-else
>
<el-input
v-model
.
trim=
"formInline[item.field]"
:placeholder=
"item.placeholder"
:clearable=
"item.clearable"
@
clear=
"inputChange"
/>
...
...
src/components/Tools/table_tools.vue
View file @
751d9bb
<
script
lang=
"ts"
setup
name=
"TableTools"
>
import
TableSearch
from
'./table_search.vue'
const
emits
=
defineEmits
([
"search"
,
"filterChange"
,
"loadMore"
,
"remoteMethod"
,
"treeSelectLoad"
,
"selectChange"
,
"treeSelectNodeChange"
,
"treeSelectNodeClick"
]);
const
emits
=
defineEmits
([
"search"
,
"filterChange"
,
"loadMore"
,
"remoteMethod"
,
"treeSelectLoad"
,
"selectChange"
,
"treeSelectNodeChange"
,
"treeSelectNodeClick"
,
"cascaderChange"
]);
const
props
=
defineProps
({
searchItems
:
{
type
:
Array
,
...
...
@@ -53,6 +53,10 @@ const handleTreeSelectNodeChange = (node, item) => {
const
treeSelectNodeClick
=
(
node
,
item
)
=>
{
emits
(
"treeSelectNodeClick"
,
node
,
item
);
}
const
cascaderChange
=
(
val
,
item
)
=>
{
emits
(
"cascaderChange"
,
val
,
item
);
}
defineExpose
({
toolSearch
,
})
...
...
@@ -69,6 +73,7 @@ defineExpose({
@
selectChange=
"selectChange"
@
treeSelectNodeChange=
"handleTreeSelectNodeChange"
@
treeSelectNodeClick=
"treeSelectNodeClick"
@
cascaderChange=
"cascaderChange"
/>
</div>
<div
class=
"tools_bar"
v-if=
"bars?.length"
>
...
...
src/layouts/components/SidebarItem/index.vue
View file @
751d9bb
src/router/modules/dataInventory.ts
View file @
751d9bb
...
...
@@ -74,15 +74,8 @@ const routes: RouteRecordRaw[] = [
sidebar
:
false
,
breadcrumb
:
false
,
cache
:
true
,
reuse
:
true
,
editPage
:
true
,
activeMenu
:
'/data-inventory/classify-grade-manage/task-config'
},
beforeEnter
:
(
to
,
from
)
=>
{
// if (to.query.name) {
// to.meta.title = `编辑-${to.query.name}`;
// }
}
},
{
path
:
'template-config'
,
...
...
src/store/modules/user.ts
View file @
751d9bb
...
...
@@ -33,12 +33,8 @@ const useUserStore = defineStore(
function
getToken
(
data
,
state
)
{
data
.
platformGuid
=
"7f16f697aec111ef8656fa163e60becd"
;
data
.
userType
=
2
;
data
.
validateUri
=
location
.
origin
+
'/'
;
debugger
debugger
data
.
validateUri
=
location
.
origin
==
'http://localhost:9000'
?
'http://localhost:9000/'
:
location
.
origin
+
'/'
;
return
getTokenPromise
.
value
=
getTokenByCode
(
data
).
then
((
res
:
any
)
=>
{
debugger
debugger
getTokenPromise
.
value
=
null
;
console
.
log
(
res
);
if
(
res
.
code
==
'00000'
)
{
...
...
@@ -105,9 +101,9 @@ const useUserStore = defineStore(
}).
then
((
resInfo
:
any
)
=>
{
getTokenPromise
.
value
=
null
;
if
(
resInfo
.
code
==
'00000'
){
localStorage
.
setItem
(
'token'
,
resInfo
.
data
.
access
_t
oken
);
token
.
value
=
resInfo
.
data
.
access
_t
oken
;
localStorage
.
setItem
(
'refresh_token'
,
resInfo
.
data
.
refresh
_t
oken
);
localStorage
.
setItem
(
'token'
,
resInfo
.
data
.
access
T
oken
);
token
.
value
=
resInfo
.
data
.
access
T
oken
;
localStorage
.
setItem
(
'refresh_token'
,
resInfo
.
data
.
refresh
T
oken
);
const
expiresIn
=
(
Date
.
now
()
+
1700000
)
+
""
;
localStorage
.
setItem
(
'expiresIn'
,
expiresIn
);
}
else
{
...
...
src/utils/request.ts
View file @
751d9bb
...
...
@@ -112,7 +112,7 @@ service.interceptors.request.use(
return
config
;
};
/** 若是刷新token的请求,则不需要等refreshToken完成。 */
if
(
config
.
url
.
includes
(
'/
csbr-zuul/
user/refreshToken'
))
{
if
(
config
.
url
.
includes
(
'/user/refreshToken'
))
{
return
process
();
}
let
expiresIn
=
localStorage
.
getItem
(
'expiresIn'
);
...
...
src/views/data_inventory/taskConfig.vue
View file @
751d9bb
...
...
@@ -9,329 +9,16 @@ import useUserStore from "@/store/modules/user";
import
{
ElMessage
,
ElMessageBox
}
from
"element-plus"
;
import
useDataAssetStore
from
"@/store/modules/dataAsset"
;
import
{
getListingList
,
listingDelete
,
listingUpdateStatus
,
filterVal
,
getParamsDataList
}
from
"@/api/modules/dataProduct
"
;
import
{
filterVal
,
getCgTaskPageList
,
cgTaskDelete
,
runExecTask
}
from
"@/api/modules/dataInventory
"
;
import
{
TableColumnWidth
}
from
'@/utils/enum'
;
import
Table
from
"@/components/Table/index.vue"
;
const
{
proxy
}
=
getCurrentInstance
()
as
any
;
const
router
=
useRouter
();
const
userStore
=
useUserStore
();
const
userData
=
JSON
.
parse
(
userStore
.
userData
);
const
assetStore
=
useDataAssetStore
();
const
datas
=
[
{
"updateTime"
:
"2024-07-16 13:17:00"
,
"updateUserName"
:
"数往知来管理员"
,
"guid"
:
"4e0e76c48fa043d5b35d09f3ccc7c265"
,
"approvalGuid"
:
null
,
"standardSetGuid"
:
"58d1178a04904d599284fc1e61594c43"
,
"fieldStandardCode"
:
"COL202406070021"
,
"dataVersion"
:
1
,
"chName"
:
"地址"
,
"enName"
:
"address"
,
"dataTypeValue"
:
"字符型"
,
"dataTypeCode"
:
"varchar"
,
"dataDicGuid"
:
""
,
"dataDicName"
:
null
,
"isDataDic"
:
"N"
,
"fieldLength"
:
600
,
"fieldPrecision"
:
null
,
"dataState"
:
0
,
"approveState"
:
"N"
,
"dataCategory"
:
"合伙人"
,
"dataEncryptionLevel"
:
"界面加密"
,
"businessDefDesc"
:
"地址"
,
"flowFlag"
:
null
,
"flowCode"
:
null
,
"functionCode"
:
null
,
"createStaffGuid"
:
null
,
"createUserId"
:
"98df01b8d86c46f786dd10b4d0eb11dd"
,
"displayVersion"
:
"V1"
,
"standardSetName"
:
null
,
"ruleType"
:
null
},
{
"updateTime"
:
"2024-01-27 10:19:45"
,
"updateUserName"
:
"数往知来管理员"
,
"guid"
:
"bc630207357c466dbff7613ea38985cc"
,
"approvalGuid"
:
null
,
"standardSetGuid"
:
"58d1178a04904d599284fc1e61594c43"
,
"fieldStandardCode"
:
"COL202401260124"
,
"dataVersion"
:
1
,
"chName"
:
"包含最小销售包装单元数量"
,
"enName"
:
"inboxQuantity"
,
"dataTypeValue"
:
"整型"
,
"dataTypeCode"
:
"int"
,
"dataDicGuid"
:
null
,
"dataDicName"
:
null
,
"isDataDic"
:
null
,
"fieldLength"
:
null
,
"fieldPrecision"
:
null
,
"dataState"
:
1
,
"approveState"
:
"A"
,
"dataCategory"
:
null
,
"dataEncryptionLevel"
:
"明文显示"
,
"businessDefDesc"
:
"当前药品追溯码中包含的最小销售包装单元药品追溯码的数量,发货类型为03时可选"
,
"flowFlag"
:
null
,
"flowCode"
:
null
,
"functionCode"
:
null
,
"createStaffGuid"
:
null
,
"createUserId"
:
"98df01b8d86c46f786dd10b4d0eb11dd"
,
"displayVersion"
:
"V1"
,
"standardSetName"
:
null
,
"ruleType"
:
null
},
{
"updateTime"
:
"2024-01-27 11:03:59"
,
"updateUserName"
:
"审批人4"
,
"guid"
:
"420f2a68bd4441bf92010eadf698b685"
,
"approvalGuid"
:
null
,
"standardSetGuid"
:
"58d1178a04904d599284fc1e61594c43"
,
"fieldStandardCode"
:
"COL202401260122"
,
"dataVersion"
:
1
,
"chName"
:
"包装层级"
,
"enName"
:
"packageLevel"
,
"dataTypeValue"
:
"字符型"
,
"dataTypeCode"
:
"varchar"
,
"dataDicGuid"
:
null
,
"dataDicName"
:
null
,
"isDataDic"
:
null
,
"fieldLength"
:
200
,
"fieldPrecision"
:
null
,
"dataState"
:
1
,
"approveState"
:
"A"
,
"dataCategory"
:
null
,
"dataEncryptionLevel"
:
"明文显示"
,
"businessDefDesc"
:
"当前药品追溯码所处包装层级描述,发货类型为03时可选"
,
"flowFlag"
:
null
,
"flowCode"
:
null
,
"functionCode"
:
null
,
"createStaffGuid"
:
null
,
"createUserId"
:
"98df01b8d86c46f786dd10b4d0eb11dd"
,
"displayVersion"
:
"V1"
,
"standardSetName"
:
null
,
"ruleType"
:
null
},
{
"updateTime"
:
"2024-06-06 10:01:06"
,
"updateUserName"
:
"审批人1"
,
"guid"
:
"f841e1848ab94b1e81a0217a09a7a3d3"
,
"approvalGuid"
:
"b674bffe8d2f4132918016b6baaf75aa"
,
"standardSetGuid"
:
"58d1178a04904d599284fc1e61594c43"
,
"fieldStandardCode"
:
"COL202401260120"
,
"dataVersion"
:
1
,
"chName"
:
"上一级包装药品追溯码"
,
"enName"
:
"parentDTC"
,
"dataTypeValue"
:
"字符型"
,
"dataTypeCode"
:
"varchar"
,
"dataDicGuid"
:
""
,
"dataDicName"
:
null
,
"isDataDic"
:
"N"
,
"fieldLength"
:
200
,
"fieldPrecision"
:
null
,
"dataState"
:
1
,
"approveState"
:
"Y"
,
"dataCategory"
:
""
,
"dataEncryptionLevel"
:
"明文显示"
,
"businessDefDesc"
:
"当前药品追溯码大一级包装上的药品追溯码,发货类型为03时可选;当存在上一级包装时必选"
,
"flowFlag"
:
null
,
"flowCode"
:
null
,
"functionCode"
:
null
,
"createStaffGuid"
:
null
,
"createUserId"
:
"98df01b8d86c46f786dd10b4d0eb11dd"
,
"displayVersion"
:
"V1"
,
"standardSetName"
:
null
,
"ruleType"
:
null
},
{
"updateTime"
:
"2024-01-26 00:10:47"
,
"updateUserName"
:
"数往知来管理员"
,
"guid"
:
"d4d42dea2a5844b4a7f9238806ea507b"
,
"approvalGuid"
:
null
,
"standardSetGuid"
:
"58d1178a04904d599284fc1e61594c43"
,
"fieldStandardCode"
:
"COL202401260118"
,
"dataVersion"
:
1
,
"chName"
:
"药品追溯码"
,
"enName"
:
"DTC"
,
"dataTypeValue"
:
"字符型"
,
"dataTypeCode"
:
"varchar"
,
"dataDicGuid"
:
null
,
"dataDicName"
:
null
,
"isDataDic"
:
null
,
"fieldLength"
:
200
,
"fieldPrecision"
:
null
,
"dataState"
:
0
,
"approveState"
:
"N"
,
"dataCategory"
:
null
,
"dataEncryptionLevel"
:
"明文显示"
,
"businessDefDesc"
:
"用于唯一标识药品各级销售包装单元的代码,发货类型为03时可选"
,
"flowFlag"
:
null
,
"flowCode"
:
null
,
"functionCode"
:
null
,
"createStaffGuid"
:
null
,
"createUserId"
:
"98df01b8d86c46f786dd10b4d0eb11dd"
,
"displayVersion"
:
"V1"
,
"standardSetName"
:
null
,
"ruleType"
:
null
},
{
"updateTime"
:
"2024-01-26 00:10:47"
,
"updateUserName"
:
"数往知来管理员"
,
"guid"
:
"ff9d0e4f6fbb444c8dcf6f67bffcb659"
,
"approvalGuid"
:
null
,
"standardSetGuid"
:
"58d1178a04904d599284fc1e61594c43"
,
"fieldStandardCode"
:
"COL202401260116"
,
"dataVersion"
:
1
,
"chName"
:
"发货数量"
,
"enName"
:
"deliveryQuantity"
,
"dataTypeValue"
:
"整型"
,
"dataTypeCode"
:
"int"
,
"dataDicGuid"
:
null
,
"dataDicName"
:
null
,
"isDataDic"
:
null
,
"fieldLength"
:
null
,
"fieldPrecision"
:
null
,
"dataState"
:
0
,
"approveState"
:
"N"
,
"dataCategory"
:
null
,
"dataEncryptionLevel"
:
"明文显示"
,
"businessDefDesc"
:
"发货的最小销售包装单元数量"
,
"flowFlag"
:
null
,
"flowCode"
:
null
,
"functionCode"
:
null
,
"createStaffGuid"
:
null
,
"createUserId"
:
"98df01b8d86c46f786dd10b4d0eb11dd"
,
"displayVersion"
:
"V1"
,
"standardSetName"
:
null
,
"ruleType"
:
null
},
{
"updateTime"
:
"2024-01-26 00:10:46"
,
"updateUserName"
:
"数往知来管理员"
,
"guid"
:
"fe88ac9e8d9c4f148833dbb3976fca77"
,
"approvalGuid"
:
null
,
"standardSetGuid"
:
"58d1178a04904d599284fc1e61594c43"
,
"fieldStandardCode"
:
"COL202401260114"
,
"dataVersion"
:
1
,
"chName"
:
"药品生产批号"
,
"enName"
:
"batch"
,
"dataTypeValue"
:
"字符型"
,
"dataTypeCode"
:
"varchar"
,
"dataDicGuid"
:
null
,
"dataDicName"
:
null
,
"isDataDic"
:
null
,
"fieldLength"
:
20
,
"fieldPrecision"
:
null
,
"dataState"
:
0
,
"approveState"
:
"N"
,
"dataCategory"
:
null
,
"dataEncryptionLevel"
:
"明文显示"
,
"businessDefDesc"
:
"药品包装上标示的生产批号"
,
"flowFlag"
:
null
,
"flowCode"
:
null
,
"functionCode"
:
null
,
"createStaffGuid"
:
null
,
"createUserId"
:
"98df01b8d86c46f786dd10b4d0eb11dd"
,
"displayVersion"
:
"V1"
,
"standardSetName"
:
null
,
"ruleType"
:
null
},
{
"updateTime"
:
"2024-01-26 00:10:45"
,
"updateUserName"
:
"数往知来管理员"
,
"guid"
:
"9759837e0d72472ab7441c1873c9159a"
,
"approvalGuid"
:
null
,
"standardSetGuid"
:
"58d1178a04904d599284fc1e61594c43"
,
"fieldStandardCode"
:
"COL202401260112"
,
"dataVersion"
:
1
,
"chName"
:
"药品有效期截止日期"
,
"enName"
:
"expirationDate"
,
"dataTypeValue"
:
"日期型"
,
"dataTypeCode"
:
"date"
,
"dataDicGuid"
:
null
,
"dataDicName"
:
null
,
"isDataDic"
:
null
,
"fieldLength"
:
null
,
"fieldPrecision"
:
null
,
"dataState"
:
0
,
"approveState"
:
"N"
,
"dataCategory"
:
null
,
"dataEncryptionLevel"
:
"明文显示"
,
"businessDefDesc"
:
"药品有效期的截止日期"
,
"flowFlag"
:
null
,
"flowCode"
:
null
,
"functionCode"
:
null
,
"createStaffGuid"
:
null
,
"createUserId"
:
"98df01b8d86c46f786dd10b4d0eb11dd"
,
"displayVersion"
:
"V1"
,
"standardSetName"
:
null
,
"ruleType"
:
null
},
{
"updateTime"
:
"2024-01-26 00:10:45"
,
"updateUserName"
:
"数往知来管理员"
,
"guid"
:
"a39ed6123c6a420d9d1265315e714f86"
,
"approvalGuid"
:
null
,
"standardSetGuid"
:
"58d1178a04904d599284fc1e61594c43"
,
"fieldStandardCode"
:
"COL202401260110"
,
"dataVersion"
:
1
,
"chName"
:
"药品生产日期"
,
"enName"
:
"productionDate"
,
"dataTypeValue"
:
"日期型"
,
"dataTypeCode"
:
"date"
,
"dataDicGuid"
:
null
,
"dataDicName"
:
null
,
"isDataDic"
:
null
,
"fieldLength"
:
null
,
"fieldPrecision"
:
null
,
"dataState"
:
0
,
"approveState"
:
"N"
,
"dataCategory"
:
null
,
"dataEncryptionLevel"
:
"明文显示"
,
"businessDefDesc"
:
"药品包装上标示的生产日期"
,
"flowFlag"
:
null
,
"flowCode"
:
null
,
"functionCode"
:
null
,
"createStaffGuid"
:
null
,
"createUserId"
:
"98df01b8d86c46f786dd10b4d0eb11dd"
,
"displayVersion"
:
"V1"
,
"standardSetName"
:
null
,
"ruleType"
:
null
},
{
"updateTime"
:
"2024-01-26 00:10:45"
,
"updateUserName"
:
"数往知来管理员"
,
"guid"
:
"ea597c1b8bb24a5ab053a80b084de98c"
,
"approvalGuid"
:
null
,
"standardSetGuid"
:
"58d1178a04904d599284fc1e61594c43"
,
"fieldStandardCode"
:
"COL202401260108"
,
"dataVersion"
:
1
,
"chName"
:
"统一社会信用代码(进口药品代理企业)"
,
"enName"
:
"drugImporterUSCID"
,
"dataTypeValue"
:
"字符型"
,
"dataTypeCode"
:
"varchar"
,
"dataDicGuid"
:
null
,
"dataDicName"
:
null
,
"isDataDic"
:
null
,
"fieldLength"
:
18
,
"fieldPrecision"
:
null
,
"dataState"
:
0
,
"approveState"
:
"N"
,
"dataCategory"
:
null
,
"dataEncryptionLevel"
:
"明文显示"
,
"businessDefDesc"
:
"进口药品代理企业的统一社会信用代码,进口药品必选;没有统一社会信用代码时使用组织机构代码"
,
"flowFlag"
:
null
,
"flowCode"
:
null
,
"functionCode"
:
null
,
"createStaffGuid"
:
null
,
"createUserId"
:
"98df01b8d86c46f786dd10b4d0eb11dd"
,
"displayVersion"
:
"V1"
,
"standardSetName"
:
null
,
"ruleType"
:
null
}
]
const
loading
=
ref
(
false
);
const
page
=
ref
({
limit
:
50
,
curr
:
1
,
...
...
@@ -353,82 +40,71 @@ const tableInfo = ref({
{
label
:
"目录名称"
,
field
:
"cgDirName"
,
width
:
120
,
type
:
"text_btn"
,
columClass
:
'text_btn'
,
click
:
(
scope
)
=>
{
router
.
push
({
name
:
"
templateConfig
"
,
query
:
{
guid
:
scope
.
row
.
damGuid
},
name
:
"
classifyGradeCatalogue
"
,
//
query: { guid: scope.row.damGuid },
});
}
},
{
label
:
"分类分级模板"
,
field
:
"cgTemplateName"
,
width
:
200
},
{
label
:
"元数据"
,
field
:
"metaNames"
,
width
:
200
},
{
label
:
"元数据"
,
field
:
"metaNames"
,
width
:
200
,
getName
:
(
scope
)
=>
{
const
metaNames
=
scope
.
row
.
metaNames
||
[];
return
metaNames
.
join
(
','
);
}
},
{
label
:
"执行状态"
,
field
:
"status"
,
width
:
TableColumnWidth
.
STATE
,
align
:
'center'
,
type
:
"tag"
,
getName
:
(
scope
)
=>
{
return
filterVal
(
scope
.
row
.
status
,
'status'
);
}
},
{
label
:
"任务修改人"
,
field
:
"
dataCategory
"
,
width
:
120
},
{
label
:
"任务修改人"
,
field
:
"
updateUserName
"
,
width
:
120
},
{
label
:
"修改时间"
,
field
:
"updateTime"
,
width
:
TableColumnWidth
.
DATETIME
},
{
label
:
"确认次数"
,
field
:
"
fieldLength
"
,
width
:
96
,
align
:
'right'
},
{
label
:
"结果确认人"
,
field
:
"
update
UserName"
,
width
:
120
},
{
label
:
"确认时间"
,
field
:
"
update
Time"
,
width
:
TableColumnWidth
.
DATETIME
},
{
label
:
"确认次数"
,
field
:
"
confirmCnt
"
,
width
:
96
,
align
:
'right'
},
{
label
:
"结果确认人"
,
field
:
"
confirm
UserName"
,
width
:
120
},
{
label
:
"确认时间"
,
field
:
"
confirm
Time"
,
width
:
TableColumnWidth
.
DATETIME
},
{
label
:
"结果状态"
,
field
:
"approveState"
,
width
:
TableColumnWidth
.
STATE
,
align
:
'center'
,
type
:
"tag"
,
getName
:
(
scope
)
=>
{
return
filterVal
(
scope
.
row
.
approveState
,
'approveState'
);
}
label
:
"结果状态"
,
field
:
"confirmStatus"
,
width
:
TableColumnWidth
.
STATE
,
align
:
'center'
,
type
:
"tag"
,
getName
:
(
scope
)
=>
{
return
filterVal
(
scope
.
row
.
confirmStatus
,
'confirmStatus'
);
},
tagType
:
(
scope
)
=>
{
return
scope
.
row
.
confirmStatus
==
'Y'
?
'success'
:
'warning'
;
},
],
loading
:
false
,
data
:
datas
||
[],
page
:
{
type
:
"normal"
,
rows
:
0
,
...
page
.
value
,
},
],
data
:
[],
showPage
:
false
,
actionInfo
:
{
label
:
"操作"
,
type
:
"btn"
,
width
:
280
,
btns
:
(
scope
)
=>
{
let
row
=
scope
.
row
,
btnArr
:
any
=
[
{
label
:
"结果确认"
,
value
:
"confirm"
},
{
label
:
"结果修改"
,
value
:
"modify"
},
{
label
:
"手动执行"
,
value
:
"run"
},
{
label
:
"编辑"
,
value
:
"edit"
},
{
label
:
"日志"
,
value
:
"log"
},
{
label
:
"删除"
,
value
:
"delete"
}
];
// if (row.approveState == 'Y') {
// if (row.listingStatus == 'Y') {
// btnArr.splice(0, 0, { label: "详情", value: "detail" });
// } else {
// btnArr.splice(0, 0, { label: "编辑", value: "edit" }, { label: "详情", value: "detail" }, { label: "删除", value: "delete" });
// }
// } else {
// if (row.approveState == 'A') {
// btnArr.splice(0, 0, { label: "详情", value: "detail" });
// } else {
// btnArr.splice(0, 0, { label: "编辑", value: "edit" }, { label: "详情", value: "detail" }, { label: "删除", value: "delete" });
// }
// }
if
(
row
.
confirmStatus
==
'Y'
)
{
btnArr
.
splice
(
0
,
0
,
{
label
:
"结果修改"
,
value
:
"modify"
});
}
else
{
btnArr
.
splice
(
0
,
0
,
{
label
:
"结果确认"
,
value
:
"confirm"
,
disabled
:
row
.
status
!=
'Y'
});
}
return
btnArr
;
},
},
});
const
getTableData
=
()
=>
{
tableInfo
.
value
.
loading
=
true
;
get
Listing
List
(
loading
.
value
=
true
;
get
CgTaskPage
List
(
Object
.
assign
({},
searchItemValue
.
value
,
{
pageIndex
:
page
.
value
.
curr
,
pageSize
:
page
.
value
.
limit
,
pageSize
:
-
1
,
})
).
then
((
res
:
any
)
=>
{
tableInfo
.
value
.
loading
=
false
;
loading
.
value
=
false
;
tableInfo
.
value
.
data
=
res
.
data
.
records
||
[];
tableInfo
.
value
.
page
.
curr
=
res
.
data
.
pageIndex
;
tableInfo
.
value
.
page
.
limit
=
res
.
data
.
pageSize
;
tableInfo
.
value
.
page
.
rows
=
res
.
data
.
totalRows
;
})
.
catch
((
res
)
=>
{
tableInfo
.
value
.
loading
=
false
;
loading
.
value
=
false
;
});
};
...
...
@@ -436,8 +112,25 @@ const tableBtnClick = (scope, btn) => {
const
type
=
btn
.
value
;
const
row
=
scope
.
row
;
currTableData
.
value
=
row
;
if
(
type
==
'confirm'
||
type
==
'modify'
||
type
==
'edit'
||
type
==
"log"
)
{
if
(
type
==
'confirm'
||
type
==
'modify'
||
type
==
'edit'
||
type
==
"log"
)
{
toPath
(
type
);
}
else
if
(
type
==
'run'
)
{
const
params
=
{
guid
:
currTableData
.
value
.
guid
};
runExecTask
(
params
).
then
((
res
:
any
)
=>
{
if
(
res
.
code
==
proxy
.
$passCode
)
{
getTableData
();
}
else
{
ElMessage
({
type
:
"error"
,
message
:
res
.
msg
,
});
}
}).
catch
((
res
)
=>
{
ElMessage
({
type
:
"error"
,
message
:
'请求失败'
,
});
});
}
else
if
(
type
===
"delete"
)
{
open
(
"此操作将永久删除,是否继续?"
,
"warning"
);
}
...
...
@@ -451,21 +144,22 @@ const toPath = (type) => {
type
},
});
}
else
if
(
type
==
'edit'
)
{
}
else
if
(
type
==
'edit'
)
{
router
.
push
({
name
:
"taskEdit"
,
query
:
{
guid
:
currTableData
.
value
.
guid
,
name
:
currTableData
.
value
.
dam
Name
,
name
:
currTableData
.
value
.
task
Name
,
type
},
});
}
else
if
(
type
==
'confirm'
||
type
==
'modify'
)
{
}
else
if
(
type
==
'confirm'
||
type
==
'modify'
)
{
router
.
push
({
name
:
"taskDetail"
,
query
:
{
guid
:
currTableData
.
value
.
guid
,
name
:
currTableData
.
value
.
damName
,
name
:
currTableData
.
value
.
taskName
,
detail
:
JSON
.
stringify
(
currTableData
.
value
),
type
},
});
...
...
@@ -474,21 +168,13 @@ const toPath = (type) => {
name
:
"taskLog"
,
query
:
{
guid
:
currTableData
.
value
.
guid
,
name
:
currTableData
.
value
.
dam
Name
,
name
:
currTableData
.
value
.
task
Name
,
type
},
});
}
}
const
tablePageChange
=
(
info
)
=>
{
page
.
value
.
curr
=
Number
(
info
.
curr
);
page
.
value
.
limit
=
Number
(
info
.
limit
);
tableInfo
.
value
.
page
.
limit
=
page
.
value
.
limit
;
tableInfo
.
value
.
page
.
curr
=
page
.
value
.
curr
;
getTableData
();
};
const
open
=
(
msg
,
type
,
isBatch
=
false
)
=>
{
ElMessageBox
.
confirm
(
msg
,
"提示"
,
{
confirmButtonText
:
"确定"
,
...
...
@@ -496,9 +182,9 @@ const open = (msg, type, isBatch = false) => {
type
:
type
,
}).
then
(()
=>
{
const
guids
=
[
currTableData
.
value
.
guid
];
listing
Delete
(
guids
).
then
((
res
:
any
)
=>
{
cgTask
Delete
(
guids
).
then
((
res
:
any
)
=>
{
if
(
res
.
code
==
proxy
.
$passCode
)
{
get
FirstPag
eData
();
get
Tabl
eData
();
ElMessage
({
type
:
"success"
,
message
:
"删除成功"
,
...
...
@@ -510,41 +196,33 @@ const open = (msg, type, isBatch = false) => {
});
}
}).
catch
((
res
)
=>
{
tableInfo
.
value
.
loading
=
false
;
});
});
};
const
getFirstPageData
=
()
=>
{
page
.
value
.
curr
=
1
tableInfo
.
value
.
page
.
curr
=
1
;
getTableData
();
}
onActivated
(()
=>
{
if
(
assetStore
.
isRefresh
)
{
//如果是首次加载,则不需要调用
getFirstPageData
();
assetStore
.
set
(
false
);
}
//
if (assetStore.isRefresh) {//如果是首次加载,则不需要调用
//
getFirstPageData();
//
assetStore.set(false);
//
}
})
onBeforeMount
(()
=>
{
getTableData
()
})
</
script
>
<
template
>
<div
class=
"container_wrap"
v-
if=
"tableInfo.data.length
"
>
<div
class=
"table_tool_wrap"
>
<div
class=
"container_wrap"
v-
loading=
"loading
"
>
<div
class=
"table_tool_wrap"
v-if=
"tableInfo.data.length"
>
<div
class=
"table_title"
>
分类分级任务
</div>
</div>
<div
class=
"table_panel_wrap"
>
<Table
:tableInfo=
"tableInfo"
@
tableBtnClick=
"tableBtnClick"
@
tablePageChange=
"tablePageChange"
/>
</div>
<div
class=
"table_panel_wrap"
v-if=
"tableInfo.data.length"
>
<Table
:tableInfo=
"tableInfo"
@
tableBtnClick=
"tableBtnClick"
/>
</div>
<div
class=
"container_wrap"
v-else
>
<div
class=
"card-noData"
>
<div
class=
"card-noData"
v-else
>
<img
src=
"@/assets/images/no-data.png"
:style=
"
{ width: '96px', height: '96px' }" />
<p>
暂无分类分级任务,
<span
class=
"text_btn"
@
click=
"toPath('add')"
>
去新建
</span></p>
</div>
...
...
@@ -554,7 +232,7 @@ onBeforeMount(() => {
<
style
scoped
lang=
"scss"
>
.table_tool_wrap
{
width
:
100%
;
height
:
40px
!importan
t
;
min-height
:
unse
t
;
padding
:
0
8px
;
.table_title
{
...
...
@@ -569,7 +247,7 @@ onBeforeMount(() => {
.table_panel_wrap
{
width
:
100%
;
height
:
calc
(
100%
-
40px
);
padding
:
0px
8px
0
;
padding
:
8px
8px
16px
;
}
.card-noData
{
...
...
src/views/data_inventory/taskDetail.vue
View file @
751d9bb
...
...
@@ -11,639 +11,55 @@ import { Search, Warning } from "@element-plus/icons-vue";
import
{
setItemsDisabled
,
tagMethod
,
tagType
,
changeNum
,
}
from
"@/utils/common"
;
import
useDataAssetStore
from
"@/store/modules/dataAsset"
;
import
TableTools
from
'@/components/Tools/table_tools.vue'
;
import
Table
from
"@/components/Table/index.vue"
;
import
{
getListingList
,
listingDelete
,
listingUpdateStatus
,
filterVal
,
getParamsDataList
}
from
"@/api/modules/dataProduct"
;
import
{
getTaskExeTreeList
,
getTaskFieldCount
,
execTaskFieldList
,
execTaskSheetList
,
execTaskConfirm
,
execFieldConfirm
,
filterVal
,
getGradeList
,
getDbFieldList
}
from
"@/api/modules/dataInventory"
;
const
{
proxy
}
=
getCurrentInstance
()
as
any
;
const
router
=
useRouter
();
const
route
=
useRoute
();
const
userStore
=
useUserStore
();
const
userData
=
JSON
.
parse
(
userStore
.
userData
);
const
assetStore
=
useDataAssetStore
();
const
datas
=
[
{
"updateTime"
:
"2024-07-16 13:17:00"
,
"updateUserName"
:
"数往知来管理员"
,
"guid"
:
"4e0e76c48fa043d5b35d09f3ccc7c265"
,
"approvalGuid"
:
null
,
"standardSetGuid"
:
"58d1178a04904d599284fc1e61594c43"
,
"fieldStandardCode"
:
"COL202406070021"
,
"dataVersion"
:
1
,
"chName"
:
"地址"
,
"enName"
:
"address"
,
"dataTypeValue"
:
"字符型"
,
"dataTypeCode"
:
"varchar"
,
"dataDicGuid"
:
""
,
"dataDicName"
:
null
,
"isDataDic"
:
"N"
,
"fieldLength"
:
600
,
"fieldPrecision"
:
null
,
"dataState"
:
0
,
"approveState"
:
"N"
,
"dataCategory"
:
"合伙人"
,
"dataEncryptionLevel"
:
"界面加密"
,
"businessDefDesc"
:
"地址"
,
"flowFlag"
:
null
,
"flowCode"
:
null
,
"functionCode"
:
null
,
"createStaffGuid"
:
null
,
"createUserId"
:
"98df01b8d86c46f786dd10b4d0eb11dd"
,
"displayVersion"
:
"V1"
,
"standardSetName"
:
null
,
"ruleType"
:
null
},
{
"updateTime"
:
"2024-01-27 10:19:45"
,
"updateUserName"
:
"数往知来管理员"
,
"guid"
:
"bc630207357c466dbff7613ea38985cc"
,
"approvalGuid"
:
null
,
"standardSetGuid"
:
"58d1178a04904d599284fc1e61594c43"
,
"fieldStandardCode"
:
"COL202401260124"
,
"dataVersion"
:
1
,
"chName"
:
"包含最小销售包装单元数量"
,
"enName"
:
"inboxQuantity"
,
"dataTypeValue"
:
"整型"
,
"dataTypeCode"
:
"int"
,
"dataDicGuid"
:
null
,
"dataDicName"
:
null
,
"isDataDic"
:
null
,
"fieldLength"
:
null
,
"fieldPrecision"
:
null
,
"dataState"
:
1
,
"approveState"
:
"A"
,
"dataCategory"
:
null
,
"dataEncryptionLevel"
:
"明文显示"
,
"businessDefDesc"
:
"当前药品追溯码中包含的最小销售包装单元药品追溯码的数量,发货类型为03时可选"
,
"flowFlag"
:
null
,
"flowCode"
:
null
,
"functionCode"
:
null
,
"createStaffGuid"
:
null
,
"createUserId"
:
"98df01b8d86c46f786dd10b4d0eb11dd"
,
"displayVersion"
:
"V1"
,
"standardSetName"
:
null
,
"ruleType"
:
null
},
{
"updateTime"
:
"2024-01-27 11:03:59"
,
"updateUserName"
:
"审批人4"
,
"guid"
:
"420f2a68bd4441bf92010eadf698b685"
,
"approvalGuid"
:
null
,
"standardSetGuid"
:
"58d1178a04904d599284fc1e61594c43"
,
"fieldStandardCode"
:
"COL202401260122"
,
"dataVersion"
:
1
,
"chName"
:
"包装层级"
,
"enName"
:
"packageLevel"
,
"dataTypeValue"
:
"字符型"
,
"dataTypeCode"
:
"varchar"
,
"dataDicGuid"
:
null
,
"dataDicName"
:
null
,
"isDataDic"
:
null
,
"fieldLength"
:
200
,
"fieldPrecision"
:
null
,
"dataState"
:
1
,
"approveState"
:
"A"
,
"dataCategory"
:
null
,
"dataEncryptionLevel"
:
"明文显示"
,
"businessDefDesc"
:
"当前药品追溯码所处包装层级描述,发货类型为03时可选"
,
"flowFlag"
:
null
,
"flowCode"
:
null
,
"functionCode"
:
null
,
"createStaffGuid"
:
null
,
"createUserId"
:
"98df01b8d86c46f786dd10b4d0eb11dd"
,
"displayVersion"
:
"V1"
,
"standardSetName"
:
null
,
"ruleType"
:
null
},
{
"updateTime"
:
"2024-06-06 10:01:06"
,
"updateUserName"
:
"审批人1"
,
"guid"
:
"f841e1848ab94b1e81a0217a09a7a3d3"
,
"approvalGuid"
:
"b674bffe8d2f4132918016b6baaf75aa"
,
"standardSetGuid"
:
"58d1178a04904d599284fc1e61594c43"
,
"fieldStandardCode"
:
"COL202401260120"
,
"dataVersion"
:
1
,
"chName"
:
"上一级包装药品追溯码"
,
"enName"
:
"parentDTC"
,
"dataTypeValue"
:
"字符型"
,
"dataTypeCode"
:
"varchar"
,
"dataDicGuid"
:
""
,
"dataDicName"
:
null
,
"isDataDic"
:
"N"
,
"fieldLength"
:
200
,
"fieldPrecision"
:
null
,
"dataState"
:
1
,
"approveState"
:
"Y"
,
"dataCategory"
:
""
,
"dataEncryptionLevel"
:
"明文显示"
,
"businessDefDesc"
:
"当前药品追溯码大一级包装上的药品追溯码,发货类型为03时可选;当存在上一级包装时必选"
,
"flowFlag"
:
null
,
"flowCode"
:
null
,
"functionCode"
:
null
,
"createStaffGuid"
:
null
,
"createUserId"
:
"98df01b8d86c46f786dd10b4d0eb11dd"
,
"displayVersion"
:
"V1"
,
"standardSetName"
:
null
,
"ruleType"
:
null
},
{
"updateTime"
:
"2024-01-26 00:10:47"
,
"updateUserName"
:
"数往知来管理员"
,
"guid"
:
"d4d42dea2a5844b4a7f9238806ea507b"
,
"approvalGuid"
:
null
,
"standardSetGuid"
:
"58d1178a04904d599284fc1e61594c43"
,
"fieldStandardCode"
:
"COL202401260118"
,
"dataVersion"
:
1
,
"chName"
:
"药品追溯码"
,
"enName"
:
"DTC"
,
"dataTypeValue"
:
"字符型"
,
"dataTypeCode"
:
"varchar"
,
"dataDicGuid"
:
null
,
"dataDicName"
:
null
,
"isDataDic"
:
null
,
"fieldLength"
:
200
,
"fieldPrecision"
:
null
,
"dataState"
:
0
,
"approveState"
:
"N"
,
"dataCategory"
:
null
,
"dataEncryptionLevel"
:
"明文显示"
,
"businessDefDesc"
:
"用于唯一标识药品各级销售包装单元的代码,发货类型为03时可选"
,
"flowFlag"
:
null
,
"flowCode"
:
null
,
"functionCode"
:
null
,
"createStaffGuid"
:
null
,
"createUserId"
:
"98df01b8d86c46f786dd10b4d0eb11dd"
,
"displayVersion"
:
"V1"
,
"standardSetName"
:
null
,
"ruleType"
:
null
},
{
"updateTime"
:
"2024-01-26 00:10:47"
,
"updateUserName"
:
"数往知来管理员"
,
"guid"
:
"ff9d0e4f6fbb444c8dcf6f67bffcb659"
,
"approvalGuid"
:
null
,
"standardSetGuid"
:
"58d1178a04904d599284fc1e61594c43"
,
"fieldStandardCode"
:
"COL202401260116"
,
"dataVersion"
:
1
,
"chName"
:
"发货数量"
,
"enName"
:
"deliveryQuantity"
,
"dataTypeValue"
:
"整型"
,
"dataTypeCode"
:
"int"
,
"dataDicGuid"
:
null
,
"dataDicName"
:
null
,
"isDataDic"
:
null
,
"fieldLength"
:
null
,
"fieldPrecision"
:
null
,
"dataState"
:
0
,
"approveState"
:
"N"
,
"dataCategory"
:
null
,
"dataEncryptionLevel"
:
"明文显示"
,
"businessDefDesc"
:
"发货的最小销售包装单元数量"
,
"flowFlag"
:
null
,
"flowCode"
:
null
,
"functionCode"
:
null
,
"createStaffGuid"
:
null
,
"createUserId"
:
"98df01b8d86c46f786dd10b4d0eb11dd"
,
"displayVersion"
:
"V1"
,
"standardSetName"
:
null
,
"ruleType"
:
null
},
{
"updateTime"
:
"2024-01-26 00:10:46"
,
"updateUserName"
:
"数往知来管理员"
,
"guid"
:
"fe88ac9e8d9c4f148833dbb3976fca77"
,
"approvalGuid"
:
null
,
"standardSetGuid"
:
"58d1178a04904d599284fc1e61594c43"
,
"fieldStandardCode"
:
"COL202401260114"
,
"dataVersion"
:
1
,
"chName"
:
"药品生产批号"
,
"enName"
:
"batch"
,
"dataTypeValue"
:
"字符型"
,
"dataTypeCode"
:
"varchar"
,
"dataDicGuid"
:
null
,
"dataDicName"
:
null
,
"isDataDic"
:
null
,
"fieldLength"
:
20
,
"fieldPrecision"
:
null
,
"dataState"
:
0
,
"approveState"
:
"N"
,
"dataCategory"
:
null
,
"dataEncryptionLevel"
:
"明文显示"
,
"businessDefDesc"
:
"药品包装上标示的生产批号"
,
"flowFlag"
:
null
,
"flowCode"
:
null
,
"functionCode"
:
null
,
"createStaffGuid"
:
null
,
"createUserId"
:
"98df01b8d86c46f786dd10b4d0eb11dd"
,
"displayVersion"
:
"V1"
,
"standardSetName"
:
null
,
"ruleType"
:
null
},
{
"updateTime"
:
"2024-01-26 00:10:45"
,
"updateUserName"
:
"数往知来管理员"
,
"guid"
:
"9759837e0d72472ab7441c1873c9159a"
,
"approvalGuid"
:
null
,
"standardSetGuid"
:
"58d1178a04904d599284fc1e61594c43"
,
"fieldStandardCode"
:
"COL202401260112"
,
"dataVersion"
:
1
,
"chName"
:
"药品有效期截止日期"
,
"enName"
:
"expirationDate"
,
"dataTypeValue"
:
"日期型"
,
"dataTypeCode"
:
"date"
,
"dataDicGuid"
:
null
,
"dataDicName"
:
null
,
"isDataDic"
:
null
,
"fieldLength"
:
null
,
"fieldPrecision"
:
null
,
"dataState"
:
0
,
"approveState"
:
"N"
,
"dataCategory"
:
null
,
"dataEncryptionLevel"
:
"明文显示"
,
"businessDefDesc"
:
"药品有效期的截止日期"
,
"flowFlag"
:
null
,
"flowCode"
:
null
,
"functionCode"
:
null
,
"createStaffGuid"
:
null
,
"createUserId"
:
"98df01b8d86c46f786dd10b4d0eb11dd"
,
"displayVersion"
:
"V1"
,
"standardSetName"
:
null
,
"ruleType"
:
null
},
{
"updateTime"
:
"2024-01-26 00:10:45"
,
"updateUserName"
:
"数往知来管理员"
,
"guid"
:
"a39ed6123c6a420d9d1265315e714f86"
,
"approvalGuid"
:
null
,
"standardSetGuid"
:
"58d1178a04904d599284fc1e61594c43"
,
"fieldStandardCode"
:
"COL202401260110"
,
"dataVersion"
:
1
,
"chName"
:
"药品生产日期"
,
"enName"
:
"productionDate"
,
"dataTypeValue"
:
"日期型"
,
"dataTypeCode"
:
"date"
,
"dataDicGuid"
:
null
,
"dataDicName"
:
null
,
"isDataDic"
:
null
,
"fieldLength"
:
null
,
"fieldPrecision"
:
null
,
"dataState"
:
0
,
"approveState"
:
"N"
,
"dataCategory"
:
null
,
"dataEncryptionLevel"
:
"明文显示"
,
"businessDefDesc"
:
"药品包装上标示的生产日期"
,
"flowFlag"
:
null
,
"flowCode"
:
null
,
"functionCode"
:
null
,
"createStaffGuid"
:
null
,
"createUserId"
:
"98df01b8d86c46f786dd10b4d0eb11dd"
,
"displayVersion"
:
"V1"
,
"standardSetName"
:
null
,
"ruleType"
:
null
},
{
"updateTime"
:
"2024-01-26 00:10:45"
,
"updateUserName"
:
"数往知来管理员"
,
"guid"
:
"ea597c1b8bb24a5ab053a80b084de98c"
,
"approvalGuid"
:
null
,
"standardSetGuid"
:
"58d1178a04904d599284fc1e61594c43"
,
"fieldStandardCode"
:
"COL202401260108"
,
"dataVersion"
:
1
,
"chName"
:
"统一社会信用代码(进口药品代理企业)"
,
"enName"
:
"drugImporterUSCID"
,
"dataTypeValue"
:
"字符型"
,
"dataTypeCode"
:
"varchar"
,
"dataDicGuid"
:
null
,
"dataDicName"
:
null
,
"isDataDic"
:
null
,
"fieldLength"
:
18
,
"fieldPrecision"
:
null
,
"dataState"
:
0
,
"approveState"
:
"N"
,
"dataCategory"
:
null
,
"dataEncryptionLevel"
:
"明文显示"
,
"businessDefDesc"
:
"进口药品代理企业的统一社会信用代码,进口药品必选;没有统一社会信用代码时使用组织机构代码"
,
"flowFlag"
:
null
,
"flowCode"
:
null
,
"functionCode"
:
null
,
"createStaffGuid"
:
null
,
"createUserId"
:
"98df01b8d86c46f786dd10b4d0eb11dd"
,
"displayVersion"
:
"V1"
,
"standardSetName"
:
null
,
"ruleType"
:
null
}
]
const
data1
=
[
{
"children"
:
[
{
"children"
:
null
,
"parentGuids"
:
[
"c32ddd77191ff4afe149538ef4b2e0c3"
],
"guid"
:
"9c92df55a19cdce88f61e20a8e1e8a65"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
"11150001"
,
"organisationName"
:
"链享供应链运营一部"
,
"bizState"
:
"Y"
,
"createTime"
:
"2023-10-25 14:23:31"
,
"createUserName"
:
"测试"
,
"parentGuid"
:
"c32ddd77191ff4afe149538ef4b2e0c3"
,
"orderNum"
:
1
,
"level"
:
2
,
"levelCode"
:
"1.1"
,
"displayCreateTime"
:
"2023-10-25 14:23:31"
}
],
"parentGuids"
:
null
,
"guid"
:
"c32ddd77191ff4afe149538ef4b2e0c3"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
"1115004"
,
"organisationName"
:
"链享供应链"
,
"bizState"
:
"Y"
,
"createTime"
:
"2023-08-15 12:59:10"
,
"createUserName"
:
"测试"
,
"parentGuid"
:
""
,
"orderNum"
:
2
,
"level"
:
0
,
"levelCode"
:
"1"
,
"displayCreateTime"
:
"2023-08-15 12:59:10"
},
{
"children"
:
[
{
"children"
:
[
{
"children"
:
null
,
"parentGuids"
:
[
"e10332122834077907cd5ea61fa576c1"
,
"cdae7bb3cafb560482cad1b89a1e4b78"
],
"guid"
:
"16ea472a155c07433a63220f2ae1afe9"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
"11160011"
,
"organisationName"
:
"链享运营一部1组"
,
"bizState"
:
"S"
,
"createTime"
:
"2023-10-25 13:15:57"
,
"createUserName"
:
"测试"
,
"parentGuid"
:
"cdae7bb3cafb560482cad1b89a1e4b78"
,
"orderNum"
:
1
,
"level"
:
2
,
"levelCode"
:
"2.1.1"
,
"displayCreateTime"
:
"2023-10-25 13:15:57"
}
],
"parentGuids"
:
[
"e10332122834077907cd5ea61fa576c1"
],
"guid"
:
"cdae7bb3cafb560482cad1b89a1e4b78"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
"1116001"
,
"organisationName"
:
"链享运营一部"
,
"bizState"
:
"S"
,
"createTime"
:
"2023-10-25 13:14:15"
,
"createUserName"
:
"测试"
,
"parentGuid"
:
"e10332122834077907cd5ea61fa576c1"
,
"orderNum"
:
1
,
"level"
:
1
,
"levelCode"
:
"2.1"
,
"displayCreateTime"
:
"2023-10-25 13:14:15"
},
{
"children"
:
null
,
"parentGuids"
:
[
"e10332122834077907cd5ea61fa576c1"
],
"guid"
:
"d98b44ffb35e4d17cf68f9a922e1c7b7"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
null
,
"organisationName"
:
"二部"
,
"bizState"
:
"Y"
,
"createTime"
:
"2023-10-26 09:45:36"
,
"createUserName"
:
"测试"
,
"parentGuid"
:
"e10332122834077907cd5ea61fa576c1"
,
"orderNum"
:
2
,
"level"
:
1
,
"levelCode"
:
"2.2"
,
"displayCreateTime"
:
"2023-10-26 09:45:36"
}
],
"parentGuids"
:
null
,
"guid"
:
"e10332122834077907cd5ea61fa576c1"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
"1115005"
,
"organisationName"
:
"链享医药"
,
"bizState"
:
"Y"
,
"createTime"
:
"2023-09-12 15:59:35"
,
"createUserName"
:
"测试"
,
"parentGuid"
:
null
,
"orderNum"
:
3
,
"level"
:
0
,
"levelCode"
:
"2"
,
"displayCreateTime"
:
"2023-09-12 15:59:35"
},
{
"children"
:
[
{
"children"
:
null
,
"parentGuids"
:
[
"9bd46f0f4fcf429518fae6ecb4849a9e"
],
"guid"
:
"870f23ae47e036eb88b35f726c31959b"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
null
,
"organisationName"
:
"运用三部"
,
"bizState"
:
"Y"
,
"createTime"
:
"2024-04-28 16:33:24"
,
"createUserName"
:
"数往知来管理员"
,
"parentGuid"
:
"9bd46f0f4fcf429518fae6ecb4849a9e"
,
"orderNum"
:
3
,
"level"
:
1
,
"levelCode"
:
"3.3"
,
"displayCreateTime"
:
"2024-04-28 16:33:24"
},
{
"children"
:
null
,
"parentGuids"
:
[
"9bd46f0f4fcf429518fae6ecb4849a9e"
],
"guid"
:
"e06049046241dd71b153f227dbe7f801"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
null
,
"organisationName"
:
"运营二部"
,
"bizState"
:
"Y"
,
"createTime"
:
"2023-11-14 16:01:50"
,
"createUserName"
:
"数往知来管理员"
,
"parentGuid"
:
"9bd46f0f4fcf429518fae6ecb4849a9e"
,
"orderNum"
:
40
,
"level"
:
1
,
"levelCode"
:
"3.2"
,
"displayCreateTime"
:
"2023-11-14 16:01:50"
},
{
"children"
:
null
,
"parentGuids"
:
[
"9bd46f0f4fcf429518fae6ecb4849a9e"
],
"guid"
:
"731cd185c868da8af48b492068ffaed4"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
null
,
"organisationName"
:
"运营一部"
,
"bizState"
:
"Y"
,
"createTime"
:
"2023-11-14 15:19:35"
,
"createUserName"
:
"测试"
,
"parentGuid"
:
"9bd46f0f4fcf429518fae6ecb4849a9e"
,
"orderNum"
:
41
,
"level"
:
1
,
"levelCode"
:
"3.1"
,
"displayCreateTime"
:
"2023-11-14 15:19:35"
}
],
"parentGuids"
:
null
,
"guid"
:
"9bd46f0f4fcf429518fae6ecb4849a9e"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
null
,
"organisationName"
:
"药企服务事业部1"
,
"bizState"
:
"Y"
,
"createTime"
:
"2023-11-14 14:49:14"
,
"createUserName"
:
"数往知来管理员"
,
"parentGuid"
:
""
,
"orderNum"
:
4
,
"level"
:
0
,
"levelCode"
:
"3"
,
"displayCreateTime"
:
"2023-11-14 14:49:14"
},
{
"children"
:
[
const
detailData
=
JSON
.
parse
(
route
.
query
.
detail
);
const
gradeList
=
ref
([]);
const
treeData
=
ref
([
{
"children"
:
null
,
"parentGuids"
:
[
"23be149ea3167a3f7f2d383023336efe"
classifyName
:
"全部"
,
guid
:
"all"
,
children
:
[
{
classifyName
:
'未分类'
,
guid
:
'unclassified'
}
],
"guid"
:
"e5f2b4958ee2d99309a41e0c6e1447c8"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
null
,
"organisationName"
:
"智能存储装备部"
,
"bizState"
:
"Y"
,
"createTime"
:
"2023-11-14 16:09:36"
,
"createUserName"
:
"数往知来管理员"
,
"parentGuid"
:
"23be149ea3167a3f7f2d383023336efe"
,
"orderNum"
:
51
,
"level"
:
1
,
"levelCode"
:
"4.1"
,
"displayCreateTime"
:
"2023-11-14 16:09:36"
}
],
"parentGuids"
:
null
,
"guid"
:
"23be149ea3167a3f7f2d383023336efe"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
null
,
"organisationName"
:
"医药物联网事业部"
,
"bizState"
:
"Y"
,
"createTime"
:
"2023-11-14 15:11:35"
,
"createUserName"
:
"数往知来管理员"
,
"parentGuid"
:
""
,
"orderNum"
:
5
,
"level"
:
0
,
"levelCode"
:
"4"
,
"displayCreateTime"
:
"2023-11-14 15:11:35"
},
{
"children"
:
null
,
"parentGuids"
:
null
,
"guid"
:
"1d82e875163749ca9ae45809ec432ae8"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
null
,
"organisationName"
:
"财务管理中心"
,
"bizState"
:
"S"
,
"createTime"
:
"2023-11-14 15:14:07"
,
"createUserName"
:
"数往知来管理员"
,
"parentGuid"
:
""
,
"orderNum"
:
6
,
"level"
:
0
,
"levelCode"
:
"6"
,
"displayCreateTime"
:
"2023-11-14 15:14:07"
},
{
"children"
:
null
,
"parentGuids"
:
null
,
"guid"
:
"cd9e6a0c76102364a9e88b79b28b0b32"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
null
,
"organisationName"
:
"资产服务"
,
"bizState"
:
"Y"
,
"createTime"
:
"2024-08-14 11:40:33"
,
"createUserName"
:
"数往知来管理员"
,
"parentGuid"
:
""
,
"orderNum"
:
7
,
"level"
:
0
,
"levelCode"
:
"9"
,
"displayCreateTime"
:
"2024-08-14 11:40:33"
},
{
"children"
:
[
{
"children"
:
null
,
"parentGuids"
:
[
"dac448b77fa35f798bb4a06d8fd86334"
],
"guid"
:
"cb76777efe69182cfb2c75d41944553c"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
null
,
"organisationName"
:
"审批1"
,
"bizState"
:
"Y"
,
"createTime"
:
"2024-01-17 14:28:36"
,
"createUserName"
:
"数往知来管理员"
,
"parentGuid"
:
"dac448b77fa35f798bb4a06d8fd86334"
,
"orderNum"
:
100
,
"level"
:
1
,
"levelCode"
:
"8.1"
,
"displayCreateTime"
:
"2024-01-17 14:28:36"
}
],
"parentGuids"
:
null
,
"guid"
:
"dac448b77fa35f798bb4a06d8fd86334"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
null
,
"organisationName"
:
"审批组织"
,
"bizState"
:
"Y"
,
"createTime"
:
"2024-01-16 11:38:24"
,
"createUserName"
:
"数往知来管理员"
,
"parentGuid"
:
""
,
"orderNum"
:
99
,
"level"
:
0
,
"levelCode"
:
"8"
,
"displayCreateTime"
:
"2024-01-16 11:38:24"
}
]
const
data2
=
[
{}
]
const
treeIndex
:
any
=
ref
({})
const
treeInfo
=
ref
({
]);
const
currTreeNode
=
ref
({
classifyName
:
"全部"
,
guid
:
"all"
})
const
treeInfoRef
=
ref
();
const
treeInfo
:
any
=
ref
({
id
:
"data-pickup-tree"
,
filter
:
true
,
queryValue
:
""
,
queryPlaceholder
:
"输入组织名称搜索"
,
props
:
{
label
:
"
organisation
Name"
,
label
:
"
classify
Name"
,
value
:
"guid"
,
},
nodeKey
:
'guid'
,
expandedKey
:
[],
expandOnNodeClick
:
false
,
data
:
data1
||
[],
data
:
[],
});
const
templateInfo
=
ref
({
title
:
'医疗数据分类分级模板'
,
mark
:
'待确认'
,
descGroup
:
[
{
label
:
'目录名称'
,
value
:
'医疗数据'
,
type
:
'text_btn'
},
{
label
:
'执行时间'
,
value
:
'2021-12-12 09:12:13'
},
{
label
:
'分级分类模板'
,
value
:
'医疗数据分级分类'
,
type
:
'text_btn'
},
{
label
:
'版本'
,
value
:
'V5'
},
{
label
:
'元数据名称'
,
value
:
'名称1、名称2、名称3'
},
],
})
const
taskDetail
:
any
=
ref
({})
const
fieldCounts
=
ref
({})
const
tabsInfo
=
ref
({
activeName
:
'field'
,
tabs
:
[
...
...
@@ -651,31 +67,19 @@ const tabsInfo = ref({
{
label
:
'字段'
,
name
:
'field'
},
]
});
const
cascaderRef
=
ref
();
const
sheetParams
=
ref
({});
const
sheetItemList
=
ref
([
{
type
:
"select"
,
label
:
""
,
placeholder
:
'变更类型'
,
field
:
'dataSourceGuid'
,
default
:
''
,
options
:
[],
props
:
{
label
:
'databaseNameZh'
,
value
:
'guid'
},
clearable
:
true
,
},
{
type
:
"select"
,
label
:
""
,
placeholder
:
'数据库名'
,
field
:
'data
Sourc
eGuid'
,
field
:
'data
bas
eGuid'
,
default
:
''
,
options
:
[],
props
:
{
label
:
'
databaseNameZh
'
,
value
:
'
g
uid'
label
:
'
name
'
,
value
:
'
dbG
uid'
},
clearable
:
true
,
},
...
...
@@ -683,41 +87,41 @@ const sheetItemList = ref([
type
:
"select"
,
label
:
""
,
placeholder
:
'表中文/英文名'
,
field
:
'
dataSourc
eGuid'
,
field
:
'
tabl
eGuid'
,
default
:
''
,
options
:
[],
props
:
{
label
:
'
databaseNameZh
'
,
value
:
'
g
uid'
label
:
'
name
'
,
value
:
'
dbG
uid'
},
clearable
:
true
,
disabled
:
true
},
]);
const
fieldParams
=
ref
({});
const
fieldItemList
=
ref
([
{
type
:
"select"
,
label
:
""
,
placeholder
:
'
变更类型
'
,
field
:
'
dataSourceGuid
'
,
placeholder
:
'
确认状态
'
,
field
:
'
changeStatus
'
,
default
:
''
,
options
:
[],
props
:
{
label
:
'databaseNameZh'
,
value
:
'guid'
},
options
:
[
{
label
:
'已确认'
,
value
:
'Y'
},
{
label
:
'待确认'
,
value
:
'N'
},
],
clearable
:
true
,
},
{
type
:
"select"
,
label
:
""
,
placeholder
:
'
字段中文/英文
名'
,
field
:
'data
Sourc
eGuid'
,
placeholder
:
'
数据库
名'
,
field
:
'data
bas
eGuid'
,
default
:
''
,
options
:
[],
props
:
{
label
:
'
databaseNameZh
'
,
value
:
'
g
uid'
label
:
'
name
'
,
value
:
'
dbG
uid'
},
clearable
:
true
,
},
...
...
@@ -725,59 +129,62 @@ const fieldItemList = ref([
type
:
"select"
,
label
:
""
,
placeholder
:
'表中文/英文名'
,
field
:
'
dataSourc
eGuid'
,
field
:
'
tabl
eGuid'
,
default
:
''
,
options
:
[],
props
:
{
label
:
'
databaseNameZh
'
,
value
:
'
g
uid'
label
:
'
name
'
,
value
:
'
dbG
uid'
},
clearable
:
true
,
disabled
:
true
},
{
type
:
"select"
,
label
:
""
,
placeholder
:
'
分类
'
,
field
:
'
dataSource
Guid'
,
placeholder
:
'
字段中文/英文名
'
,
field
:
'
field
Guid'
,
default
:
''
,
options
:
[],
props
:
{
label
:
'
databaseNameZh
'
,
value
:
'
g
uid'
label
:
'
name
'
,
value
:
'
dbG
uid'
},
clearable
:
true
,
disabled
:
true
},
{
type
:
"
select
"
,
type
:
"
cascader
"
,
label
:
""
,
placeholder
:
'分
级
'
,
field
:
'
dataSourceGuid
'
,
default
:
''
,
placeholder
:
'分
类
'
,
field
:
'
classifyName
'
,
default
:
[]
,
options
:
[],
showAllLevels
:
false
,
props
:
{
label
:
'databaseNameZh'
,
value
:
'guid'
checkStrictly
:
true
,
expandTrigger
:
"hover"
,
label
:
"classifyName"
,
value
:
"guid"
,
},
filterable
:
true
,
clearable
:
true
,
},
{
type
:
"select"
,
label
:
""
,
placeholder
:
'
数据库名
'
,
field
:
'
dataSource
Guid'
,
placeholder
:
'
分级
'
,
field
:
'
gradeDetail
Guid'
,
default
:
''
,
options
:
[],
props
:
{
label
:
'
databaseNameZh
'
,
label
:
'
gradeName
'
,
value
:
'guid'
},
clearable
:
true
,
},
]);
const
checked1
=
ref
(
false
);
const
checked2
=
ref
(
false
);
const
page
=
ref
({
limit
:
50
,
curr
:
1
,
...
...
@@ -789,33 +196,28 @@ const page = ref({
{
label
:
"200"
,
value
:
200
},
],
});
const
searchItemValue
:
any
=
ref
({});
const
currTableData
:
any
=
ref
({});
const
sheetTableInfo
=
ref
({
id
:
"mapping-table"
,
fields
:
[
{
label
:
"序号"
,
type
:
"index"
,
width
:
56
,
align
:
"center"
,
fixed
:
"left"
},
// {
// label: "分类分级变更状态", field: "isCgChange", width: 140, align: 'center', type: "tag", getName: (scope) => {
// return filterVal(scope.row.isCgChange, 'isCgChange');
// }
// },
{
label
:
"表中文名"
,
field
:
"tableChName"
,
width
:
120
},
{
label
:
"分类分级变更状态"
,
field
:
"damCode"
,
width
:
140
,
align
:
'center'
,
type
:
"tag"
,
getName
:
(
scope
)
=>
{
return
filterVal
(
scope
.
row
.
status
,
'status'
);
}
label
:
"表英文名"
,
field
:
"tableName"
,
width
:
200
,
type
:
"text_btn"
,
value
:
'tab'
},
{
label
:
"表中文名"
,
field
:
"damTypeName"
,
width
:
120
},
{
label
:
"表英文名"
,
field
:
"damName"
,
width
:
200
,
type
:
"text_btn"
,
columClass
:
'text_btn'
,
click
:
(
scope
)
=>
{
router
.
push
({
name
:
"templateConfig"
,
query
:
{
guid
:
scope
.
row
.
damGuid
},
});
}
},
{
label
:
"数据库名"
,
field
:
"damTypeName"
,
width
:
120
},
{
label
:
"字段数"
,
field
:
"damTypeName"
,
width
:
96
,
align
:
'right'
},
{
label
:
"已分类字段数"
,
field
:
"damTypeName"
,
width
:
120
,
align
:
'right'
},
{
label
:
"已分级字段数"
,
field
:
"damTypeName"
,
width
:
120
,
align
:
'right'
},
{
label
:
"数据库名"
,
field
:
"database"
,
width
:
120
},
{
label
:
"字段数"
,
field
:
"fieldNum"
,
width
:
96
,
align
:
'right'
},
{
label
:
"已分类字段数"
,
field
:
"classifyFieldNum"
,
width
:
120
,
align
:
'right'
},
{
label
:
"已分级字段数"
,
field
:
"gradeFieldNum"
,
width
:
120
,
align
:
'right'
},
],
loading
:
false
,
data
:
datas
||
[],
data
:
[],
page
:
{
type
:
"normal"
,
rows
:
0
,
...
...
@@ -825,28 +227,54 @@ const sheetTableInfo = ref({
show
:
false
},
});
const
selectRowData
=
ref
([]);
const
fieldTableInfo
=
ref
({
id
:
"metadata-table"
,
fields
:
[
{
label
:
"序号"
,
type
:
"index"
,
width
:
56
,
align
:
"center"
,
fixed
:
"left"
},
{
label
:
"分类分级变更状态"
,
field
:
"approveState"
,
width
:
140
,
align
:
'center'
,
type
:
"tag"
,
getName
:
(
scope
)
=>
{
return
filterVal
(
scope
.
row
.
approveState
,
'approveState'
);
label
:
"确认状态"
,
field
:
"changeStatus"
,
width
:
96
,
align
:
'center'
,
type
:
"tag"
,
getName
:
(
scope
)
=>
{
return
filterVal
(
scope
.
row
.
changeStatus
,
'changeStatus'
);
},
tagType
:
(
scope
)
=>
{
return
scope
.
row
.
changeStatus
==
'Y'
?
'success'
:
'warning'
;
},
},
{
label
:
"字段名"
,
field
:
"fieldName"
,
width
:
120
},
{
label
:
"字段中文名"
,
field
:
"fieldChName"
,
width
:
200
},
{
label
:
"分类"
,
field
:
"classifyDetailGuid"
,
width
:
280
,
type
:
"cascader"
,
options
:
[],
showAllLevels
:
false
,
props
:
{
checkStrictly
:
false
,
expandTrigger
:
"hover"
,
label
:
"classifyName"
,
value
:
"guid"
,
},
filterable
:
true
,
clearable
:
true
,
getName
:
(
scope
)
=>
{
if
(
scope
.
row
[
'STATE'
]
===
'Running'
)
{
const
classifyNames
=
scope
.
row
.
classifyDetailGuidRoutes
||
[];
return
classifyNames
;
}
else
{
const
classifyNames
=
scope
.
row
.
classifyDetailNameRoutes
||
[];
return
classifyNames
.
length
?
classifyNames
.
join
(
'/'
)
:
'--'
;
}
}
},
{
label
:
"字段名"
,
field
:
"damTypeName"
,
width
:
200
},
{
label
:
"字段中文名"
,
field
:
"damTypeName"
,
width
:
200
},
{
label
:
"分类"
,
field
:
"damTypeName"
,
width
:
280
,
type
:
'select'
,
columClass
:
'edit_cell'
},
{
label
:
"分级"
,
field
:
"damTypeName"
,
width
:
120
,
type
:
'select'
,
columClass
:
'edit_cell'
},
{
label
:
"标签"
,
field
:
"damCode"
,
width
:
96
},
{
label
:
"规则"
,
field
:
"damCode"
,
width
:
200
},
{
label
:
"表中文名"
,
field
:
"damTypeName"
,
width
:
120
},
{
label
:
"表英文名"
,
field
:
"damName"
,
width
:
200
},
{
label
:
"数据库名"
,
field
:
"damTypeName"
,
width
:
120
},
{
label
:
"分级"
,
field
:
"gradeDetailName"
,
width
:
120
,
type
:
'select'
,
options
:
[],
props
:
{
label
:
'gradeName'
,
value
:
'guid'
},
},
{
label
:
"标签"
,
field
:
"label"
,
width
:
96
},
{
label
:
"规则"
,
field
:
"ruleDetail"
,
width
:
200
},
{
label
:
"表英文名"
,
field
:
"tableName"
,
width
:
200
},
{
label
:
"表中文名"
,
field
:
"tableChName"
,
width
:
120
},
{
label
:
"数据库名"
,
field
:
"database"
,
width
:
120
},
],
loading
:
false
,
data
:
data2
||
[],
data
:
[],
showPage
:
true
,
page
:
{
type
:
"normal"
,
...
...
@@ -856,168 +284,445 @@ const fieldTableInfo = ref({
actionInfo
:
{
label
:
"操作"
,
type
:
"btn"
,
width
:
80
,
btns
:
(
scope
)
=>
{
let
row
=
scope
.
row
,
btnArr
:
any
=
[
{
label
:
"编辑"
,
value
:
"edit"
},
];
// if (row.approveState == 'Y') {
// if (row.listingStatus == 'Y') {
// btnArr.splice(0, 0, { label: "详情", value: "detail" });
// } else {
// btnArr.splice(0, 0, { label: "编辑", value: "edit" }, { label: "详情", value: "detail" }, { label: "删除", value: "delete" });
// }
// } else {
// if (row.approveState == 'A') {
// btnArr.splice(0, 0, { label: "详情", value: "detail" });
// } else {
// btnArr.splice(0, 0, { label: "编辑", value: "edit" }, { label: "详情", value: "detail" }, { label: "删除", value: "delete" });
// }
// }
return
btnArr
;
width
:
60
,
},
})
const
formItems
=
ref
([
{
label
:
"分类"
,
type
:
"cascader"
,
placeholder
:
"请选择"
,
field
:
"classifyName"
,
default
:
[],
options
:
[],
showAllLevels
:
false
,
props
:
{
checkStrictly
:
false
,
expandTrigger
:
"hover"
,
label
:
"classifyName"
,
value
:
"guid"
,
},
filterable
:
true
,
clearable
:
true
,
required
:
true
,
block
:
true
,
},
{
label
:
'分级'
,
type
:
'select'
,
placeholder
:
'请选择'
,
field
:
'gradeGuid'
,
default
:
''
,
options
:
[],
props
:
{
value
:
'guid'
,
label
:
'gradeName'
},
clearable
:
true
,
required
:
true
,
block
:
true
,
},
]);
const
formRules
=
ref
({
classifyName
:
[
{
required
:
true
,
trigger
:
'change'
,
message
:
"请选择分类"
}
],
gradeGuid
:
[
{
required
:
true
,
trigger
:
'change'
,
message
:
"请选择分级"
}
],
});
const
dialogRef
=
ref
();
const
dialogInfo
:
any
=
ref
({
visible
:
false
,
size
:
480
,
direction
:
"column"
,
header
:
{
title
:
"新建"
,
},
type
:
'form'
,
contents
:
[
{
type
:
'form'
,
title
:
''
,
formInfo
:
{
id
:
'confirm-upload-file'
,
items
:
formItems
.
value
,
rules
:
formRules
.
value
}
}
],
footer
:
{
visible
:
true
,
btns
:
[
{
type
:
"default"
,
label
:
"取消"
,
value
:
"cancel"
},
{
type
:
"primary"
,
label
:
"确定"
,
value
:
"submit"
},
],
},
})
// 获取字段统计
const
getFieldCount
=
()
=>
{
getTaskFieldCount
({
execGuid
:
taskDetail
.
value
.
execGuid
}).
then
((
res
:
any
)
=>
{
if
(
res
.
code
==
proxy
.
$passCode
)
{
const
data
=
res
.
data
||
{};
fieldCounts
.
value
=
data
;
}
else
{
ElMessage
.
error
(
res
.
msg
);
}
})
}
// 获取分级数据
const
getGradeData
=
()
=>
{
getGradeList
({
classifyGradeGuid
:
taskDetail
.
value
.
gradeGuid
,
pageIndex
:
1
,
pageSize
:
-
1
}).
then
((
res
:
any
)
=>
{
if
(
res
.
code
==
proxy
.
$passCode
)
{
let
data
=
res
.
data
.
records
||
[];
data
.
map
(
d
=>
d
.
gradeName
=
d
.
dataGrade
+
'级'
);
gradeList
.
value
=
JSON
.
parse
(
JSON
.
stringify
(
data
));
formItems
.
value
[
1
].
options
=
JSON
.
parse
(
JSON
.
stringify
(
data
));
fieldItemList
.
value
[
5
].
options
=
JSON
.
parse
(
JSON
.
stringify
(
data
));
fieldTableInfo
.
value
.
fields
[
5
].
options
=
JSON
.
parse
(
JSON
.
stringify
(
data
));
}
else
{
ElMessage
.
error
(
res
.
msg
);
}
})
}
// 获取分类树形数据
const
getFieldTree
=
()
=>
{
treeInfo
.
value
.
loading
=
true
;
getTaskExeTreeList
({
execGuid
:
taskDetail
.
value
.
execGuid
}).
then
((
res
:
any
)
=>
{
treeInfo
.
value
.
loading
=
false
;
if
(
res
.
code
==
proxy
.
$passCode
)
{
const
data
=
res
.
data
||
[];
treeData
.
value
[
0
].
children
.
splice
(
1
);
treeData
.
value
[
0
].
children
.
push
(...
data
);
treeInfo
.
value
.
data
=
treeData
.
value
;
treeInfo
.
value
.
expandedKey
=
[
'all'
];
treeInfoRef
.
value
.
setCurrentKey
(
'all'
);
formItems
.
value
[
0
].
options
=
JSON
.
parse
(
JSON
.
stringify
(
data
));
fieldItemList
.
value
[
4
].
options
=
JSON
.
parse
(
JSON
.
stringify
(
data
));
fieldTableInfo
.
value
.
fields
[
4
].
options
=
JSON
.
parse
(
JSON
.
stringify
(
data
));
}
else
{
ElMessage
.
error
(
res
.
msg
);
}
}).
catch
(()
=>
{
treeInfo
.
value
.
loading
=
false
;
})
}
// 获取库、表、字段信息
const
getSheetFieldList
=
(
params
,
tId
=
null
)
=>
{
getDbFieldList
({
execGuid
:
taskDetail
.
value
.
execGuid
,
...
params
}).
then
(
res
=>
{
if
(
res
.
code
==
proxy
.
$passCode
)
{
const
data
=
res
.
data
||
[];
if
(
params
.
type
==
1
)
{
sheetItemList
.
value
[
0
].
options
=
JSON
.
parse
(
JSON
.
stringify
(
data
));
fieldItemList
.
value
[
1
].
options
=
JSON
.
parse
(
JSON
.
stringify
(
data
));
}
else
if
(
params
.
type
==
2
)
{
if
(
tabsInfo
.
value
.
activeName
==
'sheet'
)
{
sheetItemList
.
value
[
1
].
options
=
JSON
.
parse
(
JSON
.
stringify
(
data
));
}
else
{
fieldItemList
.
value
[
2
].
options
=
JSON
.
parse
(
JSON
.
stringify
(
data
));
if
(
tId
)
{
fieldItemList
.
value
[
2
].
default
=
tId
;
}
}
}
else
{
fieldItemList
.
value
[
3
].
options
=
JSON
.
parse
(
JSON
.
stringify
(
data
));
}
}
else
{
ElMessage
.
error
(
res
.
msg
);
}
})
}
const
tabChange
=
(
val
)
=>
{
tabsInfo
.
value
.
activeName
=
val
;
}
const
nodeClick
=
(
data
)
=>
{
treeIndex
.
value
=
data
currTreeNode
.
value
=
data
;
if
(
data
.
guid
==
'all'
)
{
getFieldTableData
({
isClassify
:
''
})
}
else
if
(
data
.
guid
==
'unclassified'
)
{
getFieldTableData
({
isClassify
:
'N'
})
}
else
{
getFieldTableData
({
isClassify
:
'Y'
,
classifyDetail
:
data
.
guid
});
const
parentGuids
=
data
.
parentGuids
||
[];
parentGuids
.
push
(
data
.
guid
)
fieldItemList
.
value
[
4
].
default
=
parentGuids
;
}
}
const
getTableData
=
()
=>
{
tableInfo
.
value
.
loading
=
true
;
getListingList
(
Object
.
assign
({},
searchItemValue
.
value
,
{
pageIndex
:
page
.
value
.
curr
,
pageSize
:
page
.
value
.
limit
,
// 获取库表数据
const
getSheetTableData
=
()
=>
{
sheetTableInfo
.
value
.
loading
=
true
;
execTaskSheetList
(
Object
.
assign
({},
{
...
sheetParams
.
value
},
{
execGuid
:
taskDetail
.
value
.
execGuid
,
pageIndex
:
sheetTableInfo
.
value
.
page
.
curr
,
pageSize
:
sheetTableInfo
.
value
.
page
.
limit
,
})
).
then
((
res
:
any
)
=>
{
tableInfo
.
value
.
loading
=
false
;
tableInfo
.
value
.
data
=
res
.
data
.
records
||
[];
tableInfo
.
value
.
page
.
curr
=
res
.
data
.
pageIndex
;
tableInfo
.
value
.
page
.
limit
=
res
.
data
.
pageSize
;
tableInfo
.
value
.
page
.
rows
=
res
.
data
.
totalRows
;
sheetTableInfo
.
value
.
loading
=
false
;
if
(
res
.
code
==
proxy
.
$passCode
)
{
sheetTableInfo
.
value
.
data
=
res
.
data
.
records
||
[];
sheetTableInfo
.
value
.
page
.
curr
=
res
.
data
.
pageIndex
;
sheetTableInfo
.
value
.
page
.
limit
=
res
.
data
.
pageSize
;
sheetTableInfo
.
value
.
page
.
rows
=
res
.
data
.
totalRows
;
}
else
{
ElMessage
.
error
(
res
.
msg
);
}
})
.
catch
((
res
)
=>
{
t
ableInfo
.
value
.
loading
=
false
;
fieldT
ableInfo
.
value
.
loading
=
false
;
});
};
// 获取字段表格数据
const
getFieldTableData
=
(
param
:
any
=
{})
=>
{
fieldTableInfo
.
value
.
loading
=
true
;
let
params
:
any
=
{
...
fieldParams
.
value
,
...
param
,
execGuid
:
taskDetail
.
value
.
execGuid
,
pageIndex
:
fieldTableInfo
.
value
.
page
.
curr
,
pageSize
:
fieldTableInfo
.
value
.
page
.
limit
,
}
delete
params
.
classifyName
execTaskFieldList
(
params
).
then
((
res
:
any
)
=>
{
fieldTableInfo
.
value
.
loading
=
false
;
if
(
res
.
code
==
proxy
.
$passCode
)
{
let
data
=
res
.
data
.
records
||
[];
data
.
map
(
item
=>
item
.
STATE
=
''
);
fieldTableInfo
.
value
.
data
=
data
;
fieldTableInfo
.
value
.
page
.
curr
=
res
.
data
.
pageIndex
;
fieldTableInfo
.
value
.
page
.
limit
=
res
.
data
.
pageSize
;
fieldTableInfo
.
value
.
page
.
rows
=
res
.
data
.
totalRows
;
}
else
{
ElMessage
.
error
(
res
.
msg
);
}
})
.
catch
((
res
)
=>
{
fieldTableInfo
.
value
.
loading
=
false
;
});
};
const
tableCellClassName
=
(
scope
)
=>
{
return
(
scope
.
column
.
label
==
'分类'
||
scope
.
column
.
label
==
'分级'
)
&&
scope
.
row
[
'STATE'
]
===
'Running'
?
'edit_cell'
:
''
}
const
rowSelectable
=
(
row
,
index
)
=>
{
return
row
.
selectable
??
true
;
};
const
tableSelectionChange
=
(
val
)
=>
{
selectRowData
.
value
=
val
;
};
const
getCascaderCheckedData
=
()
=>
{
const
formCascader
=
cascaderRef
.
value
[
0
]
||
cascaderRef
.
value
;
const
data
=
formCascader
.
getCheckedNodes
();
return
data
;
};
const
tableBtnClick
=
(
scope
,
btn
)
=>
{
const
type
=
btn
.
value
;
const
row
=
scope
.
row
;
currTableData
.
value
=
row
;
if
(
type
==
"detail"
||
type
===
"edit"
)
{
toPath
(
type
);
}
else
if
(
type
===
"delete"
)
{
open
(
"此操作将永久删除,是否继续?"
,
"warning"
);
if
(
type
==
'tab'
)
{
tabsInfo
.
value
.
activeName
=
'field'
;
fieldItemList
.
value
.
map
(
item
=>
item
.
default
=
''
)
fieldItemList
.
value
[
1
].
default
=
row
.
databaseGuid
;
fieldItemList
.
value
[
2
].
disabled
=
false
;
treeInfo
.
value
.
expandedKey
=
[
'all'
];
treeInfoRef
.
value
.
setCurrentKey
(
'all'
);
getSheetFieldList
({
type
:
2
,
databaseGuid
:
row
.
databaseGuid
},
row
.
tableGuid
);
getFieldTableData
({
databaseGuid
:
row
.
databaseGuid
,
tableGuid
:
row
.
tableGuid
});
}
else
if
(
type
==
"edit"
)
{
row
.
STATE
=
'Running'
;
}
else
if
(
type
==
'save'
)
{
const
cascaderData
=
getCascaderCheckedData
();
row
.
classifyDetailNameRoutes
=
cascaderData
.
length
?
cascaderData
[
0
].
pathLabels
:
[];
row
.
classifyDetailGuidRoutes
=
cascaderData
.
length
?
cascaderData
[
0
].
pathValues
:
[];
row
.
classifyDetailGuid
=
cascaderData
.
length
?
cascaderData
[
0
].
value
:
''
;
row
.
classifyDetailName
=
cascaderData
.
length
?
cascaderData
[
0
].
label
:
''
;
row
.
STATE
=
''
;
if
(
cascaderData
.
length
&&
row
.
gradeDetailName
)
{
const
params
=
[
{
guid
:
row
.
guid
,
classifyDetailGuid
:
row
.
classifyDetailGuid
,
classifyDetailName
:
row
.
classifyDetailName
,
gradeDetailGuid
:
row
.
gradeDetailGuid
,
gradeDetailName
:
row
.
gradeDetailName
,
}
];
saveFields
(
params
)
}
}
};
const
tablePageChange
=
(
info
)
=>
{
if
(
tabsInfo
.
value
.
activeName
==
'sheet'
)
{
sheetTableInfo
.
value
.
page
.
limit
=
Number
(
info
.
limit
);
sheetTableInfo
.
value
.
page
.
curr
=
Number
(
info
.
curr
);
getSheetTableData
();
}
else
{
fieldTableInfo
.
value
.
page
.
limit
=
page
.
value
.
limit
;
fieldTableInfo
.
value
.
page
.
curr
=
page
.
value
.
curr
;
getFieldTableData
();
}
};
const
toPath
=
(
type
=
null
)
=>
{
const
btnClick
=
async
(
btn
,
bType
=
null
)
=>
{
const
type
=
btn
.
value
;
if
(
type
==
'path'
)
{
router
.
push
({
name
:
"classifyGradeCatalogue"
,
});
}
else
if
(
type
==
'batch'
)
{
if
(
selectRowData
.
value
.
length
==
0
)
{
ElMessage
.
warning
(
'请选择需要操作的数据'
);
return
}
dialogInfo
.
value
.
visible
=
true
;
}
else
if
(
type
==
'cancel'
)
{
router
.
push
({
name
:
"taskConfig"
,
query
:
{
type
},
});
}
const
tablePageChange
=
(
info
)
=>
{
page
.
value
.
curr
=
Number
(
info
.
curr
);
page
.
value
.
limit
=
Number
(
info
.
limit
);
tableInfo
.
value
.
page
.
limit
=
page
.
value
.
limit
;
tableInfo
.
value
.
page
.
curr
=
page
.
value
.
curr
;
getTableData
();
}
else
if
(
type
==
'confirm'
)
{
saveTask
();
}
};
const
open
=
(
msg
,
type
,
isBatch
=
false
)
=>
{
ElMessageBox
.
confirm
(
msg
,
"提示"
,
{
confirmButtonText
:
"确定"
,
cancelButtonText
:
"取消"
,
type
:
type
,
}).
then
(()
=>
{
const
guids
=
[
currTableData
.
value
.
guid
];
listingDelete
(
guids
).
then
((
res
:
any
)
=>
{
// 保存字段
const
saveFields
=
(
params
,
isBatch
=
false
)
=>
{
execFieldConfirm
(
params
).
then
((
res
:
any
)
=>
{
if
(
res
.
code
==
proxy
.
$passCode
)
{
getFirstPageData
();
ElMessage
({
type
:
"success"
,
message
:
"删除成功"
,
});
ElMessage
.
success
(
'保存成功'
);
isBatch
&&
getFieldTableData
();
}
else
{
ElMessage
({
type
:
"error"
,
message
:
res
.
msg
,
});
ElMessage
.
error
(
res
.
msg
);
}
}).
catch
((
res
)
=>
{
tableInfo
.
value
.
loading
=
false
;
});
});
};
})
}
const
getFirstPageData
=
()
=>
{
page
.
value
.
curr
=
1
tableInfo
.
value
.
page
.
curr
=
1
;
getTableData
();
// 任务确认
const
saveTask
=
()
=>
{
execTaskConfirm
({
execGuid
:
taskDetail
.
value
.
execGuid
}).
then
((
res
:
any
)
=>
{
if
(
res
.
code
==
proxy
.
$passCode
)
{
ElMessage
.
success
(
'保存成功'
);
router
.
push
({
name
:
"taskConfig"
,
});
}
else
{
ElMessage
.
error
(
res
.
msg
);
}
})
}
const
btnClick
=
async
(
btn
,
bType
=
null
)
=>
{
const
type
=
btn
.
value
;
/** 搜索查询分类分级模板。 */
const
searchSheet
=
(
val
:
any
,
clear
:
boolean
=
false
)
=>
{
if
(
clear
)
{
sheetItemList
.
value
.
map
(
item
=>
item
.
default
=
''
)
}
sheetParams
.
value
=
Object
.
assign
({},
{
...
sheetParams
.
value
},
{
...
val
});
getSheetTableData
();
};
/** 搜索查询分类分级模板。 */
const
searchTemplate
=
(
val
:
any
,
clear
:
boolean
=
false
)
=>
{
// page.value.curr = 1;
// if (clear) {
// searchItemList.value.map(item => item.default = '')
// page.value.planName = '';
// page.value.state = null;
// getTableData();
// return;
// }
// page.value.planName = val.planName;
// page.value.state = val.state;
// getTableData();
const
searchField
=
(
val
:
any
,
clear
:
boolean
=
false
)
=>
{
if
(
clear
)
{
fieldItemList
.
value
.
map
(
item
=>
item
.
default
=
''
)
}
fieldParams
.
value
=
Object
.
assign
({},
{
...
fieldParams
.
value
},
{
...
val
});
getFieldTableData
();
};
const
c
hangTable
=
(
)
=>
{
// toSearch({})
const
c
ascaderChange
=
(
val
,
row
)
=>
{
console
.
log
(
val
,
row
);
};
const
getPermissionList
=
(
val
,
init
=
false
)
=>
{
let
params
:
any
=
val
?
{
...
val
}
:
{}
// params.pageIndex = listPage.value.curr;
// params.pageSize = listPage.value.limit;
// getPermissionDictList(params).then((res: any) => {
// if (res.code == proxy.$passCode) {
// const data = res.data?.records || []
// if (init) {
// permissionList.value = JSON.parse(JSON.stringify(data))
// currpermissionList.value = JSON.parse(JSON.stringify(data))
// listPage.value.totalPages = res.data.totalPages
// toSearch({})
// } else {
// permissionList.value.push(...JSON.parse(JSON.stringify(data)))
// querySearch(asideSearchInput.value)
// }
// }
// listLoading.value = false
// }).catch(() => {
// listLoading.value = false
// })
const
selectChange
=
(
val
,
item
,
scope
=
null
)
=>
{
if
(
scope
)
{
let
row
=
scope
.
row
;
row
.
gradeGuid
=
val
||
''
;
row
.
gradeDetailName
=
val
?
item
.
options
.
find
(
i
=>
i
.
guid
==
val
)?.
gradeName
:
''
;
}
else
{
if
(
tabsInfo
.
value
.
activeName
==
'sheet'
)
{
if
(
!
val
)
{
sheetItemList
.
value
[
1
].
default
=
''
;
sheetItemList
.
value
[
1
].
disabled
=
true
;
}
else
{
sheetItemList
.
value
[
1
].
disabled
=
false
;
}
}
else
{
if
(
item
.
field
==
"databaseGuid"
)
{
if
(
!
val
)
{
fieldItemList
.
value
[
2
].
default
=
''
;
fieldItemList
.
value
[
3
].
default
=
''
;
fieldItemList
.
value
[
2
].
disabled
=
true
;
fieldItemList
.
value
[
3
].
disabled
=
true
;
}
else
{
fieldItemList
.
value
[
2
].
disabled
=
false
;
}
}
else
{
if
(
!
val
)
{
fieldItemList
.
value
[
3
].
default
=
''
;
fieldItemList
.
value
[
3
].
disabled
=
true
;
}
else
{
fieldItemList
.
value
[
3
].
disabled
=
false
;
}
}
}
if
(
val
)
{
const
params
=
{
type
:
item
.
field
==
"databaseGuid"
?
2
:
3
,
dbGuid
:
val
||
''
}
getSheetFieldList
(
params
)
}
}
}
const
dialogBtnClick
=
(
btn
,
info
)
=>
{
if
(
btn
.
value
==
'submit'
)
{
let
params
:
any
=
[]
const
cascaderData
=
dialogRef
.
value
.
getCascaderCheckedData
();
const
gradeName
=
gradeList
.
value
.
find
(
i
=>
i
.
guid
==
info
.
gradeGuid
)?.
gradeName
;
selectRowData
.
value
.
map
((
item
:
any
)
=>
{
const
param
=
{
guid
:
item
.
guid
,
classifyDetailGuid
:
cascaderData
[
0
].
value
,
classifyDetailName
:
cascaderData
[
0
].
label
,
gradeDetailGuid
:
info
.
gradeGuid
,
gradeDetailName
:
gradeName
,
}
params
.
push
(
param
)
})
saveFields
(
params
,
true
);
dialogInfo
.
value
.
visible
=
false
;
}
else
if
(
btn
.
value
==
'cancel'
)
{
dialogInfo
.
value
.
visible
=
false
;
}
};
onActivated
(()
=>
{
})
onBeforeMount
(()
=>
{
taskDetail
.
value
=
detailData
;
getFieldCount
()
getSheetFieldList
({
type
:
1
});
getFieldTree
()
getSheetTableData
();
getFieldTableData
();
getGradeData
();
})
</
script
>
...
...
@@ -1029,29 +734,37 @@ onBeforeMount(() => {
<div
class=
"template_panel"
>
<div
class=
"panel_title"
>
<div
class=
"title_wrap"
>
<span
class=
"title_text"
>
{{
templateInfo
.
title
}}
</span>
<el-tag
type=
"warning"
>
{{
templateInfo
.
mark
}}
</el-tag>
<span
class=
"title_text"
>
{{
taskDetail
.
taskName
}}
</span>
<el-tag
:type=
"taskDetail.confirmStatus == 'Y' ? 'success' : 'warning'"
>
{{
filterVal
(
taskDetail
.
confirmStatus
,
'confirmStatus'
)
}}
</el-tag>
</div>
</div>
<div
class=
"title_desc"
>
<div
class=
"desc_group"
>
<div
class=
"desc_item"
>
<span
class=
"desc_label"
>
目录名称:
</span>
<span
class=
"desc_value text_btn"
>
医疗数据
</span>
<span
class=
"desc_value text_btn"
@
click=
"btnClick(
{ value: 'path' })">
{{
taskDetail
.
cgDirName
||
'--'
}}
</span>
</div>
<div
class=
"desc_item"
>
<span
class=
"desc_label"
>
执行时间:
</span>
<span
class=
"desc_value"
>
2021-12-12 09:12:13
</span>
<span
class=
"desc_value"
>
{{
taskDetail
.
cgDirName
||
'--'
}}
</span>
</div>
</div>
<div
class=
"desc_group"
>
<div
class=
"desc_item"
>
<span
class=
"desc_label"
>
分类:
</span>
<span
class=
"desc_value text_btn"
>
医疗数据
</span>
<span
class=
"desc_value text_btn"
>
{{
taskDetail
.
classifyName
||
'--'
}}
</span>
</div>
<div
class=
"desc_item"
>
<span
class=
"desc_label"
>
分级:
</span>
<span
class=
"desc_value text_btn"
>
{{
taskDetail
.
gradeName
||
'--'
}}
</span>
</div>
<div
class=
"desc_item"
>
<span
class=
"desc_label"
>
元数据名称:
</span>
<span
class=
"desc_value"
>
名称1、名称2、名称3
</span>
<span
class=
"desc_value"
>
{{
(
taskDetail
.
metaNames
||
[]).
length
?
taskDetail
.
metaNames
.
join
(
','
)
:
'--'
}}
</span>
</div>
</div>
</div>
...
...
@@ -1060,13 +773,13 @@ onBeforeMount(() => {
<Warning
/>
</el-icon>
<span>
本次分类分级任务共涉及:
</span>
<span
class=
"text_btn"
>
40
</span>
<span
class=
"text_btn"
>
{{
changeNum
(
fieldCounts
.
tableNum
||
0
)
}}
</span>
<span>
张表,共
</span>
<span
class=
"text_btn"
>
4023
</span>
<span
class=
"text_btn"
>
{{
changeNum
(
fieldCounts
.
fieldNum
||
0
)
}}
</span>
<span>
个字段,已分类
</span>
<span
class=
"text_btn"
>
2099
</span>
<span
class=
"text_btn"
>
{{
changeNum
(
fieldCounts
.
classifyFieldNum
||
0
)
}}
</span>
<span>
个字段,已分级
</span>
<span
class=
"text_btn"
>
1987
</span>
<span
class=
"text_btn"
>
{{
changeNum
(
fieldCounts
.
gradeFieldNum
||
0
)
}}
</span>
<span>
个字段
</span>
</p>
</div>
...
...
@@ -1074,7 +787,8 @@ onBeforeMount(() => {
<Tabs
class=
"panel_tabs"
:tabs-info=
"tabsInfo"
@
tab-change=
"tabChange"
/>
<div
class=
"panel"
v-show=
"tabsInfo.activeName == 'sheet'"
>
<div
class=
"table_tool_wrap"
>
<TableTools
:searchItems=
"sheetItemList"
:searchId=
"'template-manage-search'"
@
search=
"searchTemplate"
/>
<TableTools
:searchItems=
"sheetItemList"
:searchId=
"'sheet-search'"
:init=
"false"
@
selectChange=
"selectChange"
@
search=
"searchSheet"
/>
</div>
<div
class=
"table_panel_wrap"
>
<Table
:tableInfo=
"sheetTableInfo"
@
tableBtnClick=
"tableBtnClick"
@
tablePageChange=
"tablePageChange"
/>
...
...
@@ -1082,43 +796,54 @@ onBeforeMount(() => {
</div>
<div
class=
"panel flex"
v-show=
"tabsInfo.activeName == 'field'"
>
<div
class=
"box_left"
>
<div
class=
"aside_title"
>
分类分级目录
</div>
<Tree
:treeInfo=
"treeInfo"
@
nodeClick=
"nodeClick"
/>
<Tree
ref=
"treeInfoRef"
:treeInfo=
"treeInfo"
@
nodeClick=
"nodeClick"
/>
</div>
<div
class=
"box_right"
>
<div
class=
"table_tool_wrap"
>
<TableTools
:searchItems=
"fieldItemList"
:searchId=
"'
template-manage-search'
"
@
se
arch=
"searchTemplate
"
/>
<TableTools
:searchItems=
"fieldItemList"
:searchId=
"'
field-search'"
:init=
"false
"
@
se
lectChange=
"selectChange"
@
cascaderChange=
"cascaderChange"
@
search=
"searchField
"
/>
<div
class=
"tools_btns"
>
<div
class=
"btns"
>
<el-button
type=
"primary"
plain
@
click=
"btnClick(
{ value: 'batch' })">批量变量分类分级
</el-button>
<el-button
plain
@
click=
"btnClick(
{ value: 'import' })">导入
</el-button>
<el-button
plain
@
click=
"btnClick(
{ value: 'export' })">导出
</el-button>
</div>
<div
class=
"checkboxs"
>
<el-checkbox
v-model=
"checked1"
>
仅看未分级分类
</el-checkbox>
<el-checkbox
v-model=
"checked2"
>
仅看变更
</el-checkbox>
</div>
</div>
</div>
<div
class=
"table_panel_wrap panel"
>
<div
class=
"table_panel"
>
<div
class=
"table_panel"
v-loading=
"fieldTableInfo.loading"
>
<el-table
ref=
"costTableRef"
:data=
"fieldTableInfo.data"
border
:height=
"'100%'"
style=
"width: 100%; display: inline-block"
:style=
"
{ 'min-height': '100%' }">
style=
"width: 100%; display: inline-block"
:style=
"
{ 'max-height': 'calc(100% - 44px)' }"
:cell-class-name="tableCellClassName" @selection-change="tableSelectionChange">
<el-table-column
type=
"selection"
align=
"center"
:width=
"32"
:selectable=
"rowSelectable"
fixed=
"left"
/>
<el-table-column
v-for=
"(item, i) in fieldTableInfo.fields"
:label=
"item.label"
:width=
"item.width"
:min-width=
"item.minWidth"
:fixed=
"item.fixed"
:align=
"item.align"
:sortable=
"item.sortable ?? false"
:prop=
"item.field"
:class-name=
"item.columClass"
show-overflow-tooltip
>
<template
#
default=
"scope"
>
<div
class=
"select_cell"
v-if=
"item.type == 'select'"
>
<el-select
v-model=
"scope.row[item.field]"
:placeholder=
"item.placeholder"
:disabled=
"item.disabled"
:clearable=
"item.clearable || true"
/>
</div>
<div
v-else-if=
"item.type == 'tag'"
>
<el-tag
:type=
"item.tagType ? item.tagType(scope) : tagType(scope.row, item.field)"
>
{{
<span
v-if=
"item.type == 'index'"
>
{{
fieldTableInfo
.
page
.
curr
!==
undefined
?
(
fieldTableInfo
.
page
.
curr
-
1
)
*
fieldTableInfo
.
page
.
limit
+
scope
.
$index
+
1
:
scope
.
$index
+
1
}}
</span>
<el-tag
v-else-if=
"item.type == 'tag'"
:type=
"item.tagType ? item.tagType(scope) : tagType(scope.row, item.field)"
>
{{
item
.
getName
?
item
.
getName
(
scope
)
:
tagMethod
(
scope
.
row
,
item
.
field
)
}}
</el-tag>
</div>
<el-select
v-else-if=
"item.type == 'select' && scope.row['STATE'] === 'Running'"
v-model=
"scope.row[item.field]"
:placeholder=
"item.placeholder"
:disabled=
"item.disabled ?? false"
:clearable=
"item.clearable ?? true"
size=
"small"
@
change=
"(val) => selectChange(val, item, scope)"
>
<el-option
v-for=
"opt in item.options"
:key=
"opt.value"
:label=
"opt[item.props?.label ?? 'label']"
:value=
"opt[item.props?.value ?? 'value']"
/>
</el-select>
<el-cascader
v-else-if=
"item.type == 'cascader' && scope.row['STATE'] === 'Running'"
ref=
"cascaderRef"
v-model=
"scope.row[item.field]"
:options=
"item.options"
:props=
"item.props"
:show-all-levels=
"item.showAllLevels ?? true"
:disabled=
"item.disabled ?? false"
:clearable=
"item.clearable ?? true"
size=
"small"
/>
<span
v-else
>
{{
item
.
getName
?
item
.
getName
(
scope
)
:
scope
.
row
[
item
.
field
]
!==
0
&&
!
scope
.
row
[
item
.
field
]
?
...
...
@@ -1126,18 +851,11 @@ onBeforeMount(() => {
</span>
</
template
>
</el-table-column>
<el-table-column
label=
"操作"
:width=
"fieldTableInfo.actionInfo.width"
:class-name=
"fieldTableInfo.actionInfo.columClass"
fixed=
"right"
>
<el-table-column
label=
"操作"
:width=
"fieldTableInfo.actionInfo.width"
fixed=
"right"
>
<
template
#
default=
"scope"
>
<template
v-for=
"(btn, b) in Array.isArray(fieldTableInfo.actionInfo.btns)
? fieldTableInfo.actionInfo.btns
: fieldTableInfo.actionInfo.btns(scope)"
>
<span
class=
"operate_btn"
:class=
"
{ active: btn.visible ?? true }" v-if="btn.visible ?? true">
<span
class=
"text_btn"
:class=
"
{ 'is-disabled': !!btn.disabled }"
@click="(btn.click
&&
!btn.disabled
&&
!scope.row.disabled) ? btn.click(scope, btn) : tableBtnClick(scope, btn)"
v-preReClick>
{{
btn
.
label
}}
</span>
</span>
</
template
>
<span
class=
"text_btn"
@
click=
"tableBtnClick(scope,
{ value: scope.row['STATE'] === 'Running' ? 'save' : 'edit' })"
v-preReClick>
{{
scope
.
row
[
'STATE'
]
===
'Running'
?
'保存'
:
'编辑'
}}
</span>
</
template
>
</el-table-column>
</el-table>
...
...
@@ -1152,10 +870,11 @@ onBeforeMount(() => {
<div
class=
"tool_btns"
>
<div
class=
"btns"
>
<el-button
@
click=
"btnClick({ value: 'cancel' })"
>
暂存
</el-button>
<el-button
type=
"primary"
@
click=
"btnClick({ value: '
next
' })"
>
确认变更
</el-button>
<el-button
type=
"primary"
@
click=
"btnClick({ value: '
confirm
' })"
>
确认变更
</el-button>
</div>
</div>
</div>
<Dialog
ref=
"dialogRef"
:dialogInfo=
"dialogInfo"
@
btnClick=
"dialogBtnClick"
/>
</div>
</template>
...
...
@@ -1290,10 +1009,10 @@ onBeforeMount(() => {
}
.panel_content
{
height
:
100%
;
height
:
calc
(
100%
-
145px
)
;
.panel
{
height
:
calc
(
100%
-
47
px
);
height
:
calc
(
100%
-
35
px
);
padding
:
0
16px
;
&.flex
{
...
...
@@ -1319,12 +1038,16 @@ onBeforeMount(() => {
}
.tree_panel
{
padding
:
0
;
height
:
100%
;
padding
:
8px
0
;
}
}
.box_right
{
width
:
calc
(
100%
-
240px
);
height
:
100%
;
display
:
flex
;
flex-direction
:
column
;
}
}
}
...
...
@@ -1342,7 +1065,7 @@ onBeforeMount(() => {
:deep
(
.table_tool_wrap
)
{
.table-tools
{
.tools_search
{
padding-top
:
12
px
;
padding-top
:
8
px
;
}
}
}
...
...
@@ -1356,15 +1079,37 @@ onBeforeMount(() => {
.table_panel_wrap
{
width
:
100%
;
height
:
calc
(
100%
-
4
0
px
);
height
:
calc
(
100%
-
4
9
px
);
padding
:
4px
0
0
;
&.panel
{
height
:
calc
(
100%
-
135px
)
;
flex
:
1
;
.table_panel
{
width
:
100%
;
height
:
100%
;
overflow
:
hidden
;
}
}
:deep
(
.el-table
)
{
td.el-table__cell
{
&.edit_cell
{
padding
:
0
;
.cell
{
padding
:
0
4px
;
line-height
:
1
;
.el-cascader
{
width
:
100%
;
.el-input
.el-input__inner
{
height
:
auto
!important
;
}
}
}
}
}
}
}
...
...
src/views/data_inventory/taskEdit.vue
View file @
751d9bb
...
...
@@ -9,303 +9,18 @@ import useUserStore from "@/store/modules/user";
import
{
ElMessage
,
ElMessageBox
}
from
"element-plus"
;
import
{
Search
}
from
"@element-plus/icons-vue"
;
import
useDataAssetStore
from
"@/store/modules/dataAsset"
;
import
{
getListingList
,
listingDelete
,
listingUpdateStatus
,
filterVal
,
getParamsDataList
}
from
"@/api/modules/dataProduct"
;
import
{
TableColumnWidth
}
from
'@/utils/enum'
;
import
Table
from
"@/components/Table/index.vue"
;
import
{
getCgTaskDetail
,
getClassifyGradList
,
getClassifyTreeList
,
getCgLabelPageList
,
getMetaTableCollectList
,
cgTaskSave
,
cgTaskUpdate
}
from
"@/api/modules/dataInventory"
;
const
{
proxy
}
=
getCurrentInstance
()
as
any
;
const
router
=
useRouter
();
const
route
=
useRoute
();
const
userStore
=
useUserStore
();
const
userData
=
JSON
.
parse
(
userStore
.
userData
);
const
assetStore
=
useDataAssetStore
();
const
data1
=
[
{
"children"
:
[
{
"children"
:
null
,
"parentGuids"
:
[
"c32ddd77191ff4afe149538ef4b2e0c3"
],
"guid"
:
"9c92df55a19cdce88f61e20a8e1e8a65"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
"11150001"
,
"organisationName"
:
"链享供应链运营一部"
,
"bizState"
:
"Y"
,
"createTime"
:
"2023-10-25 14:23:31"
,
"createUserName"
:
"测试"
,
"parentGuid"
:
"c32ddd77191ff4afe149538ef4b2e0c3"
,
"orderNum"
:
1
,
"level"
:
2
,
"levelCode"
:
"1.1"
,
"displayCreateTime"
:
"2023-10-25 14:23:31"
}
],
"parentGuids"
:
null
,
"guid"
:
"c32ddd77191ff4afe149538ef4b2e0c3"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
"1115004"
,
"organisationName"
:
"链享供应链"
,
"bizState"
:
"Y"
,
"createTime"
:
"2023-08-15 12:59:10"
,
"createUserName"
:
"测试"
,
"parentGuid"
:
""
,
"orderNum"
:
2
,
"level"
:
0
,
"levelCode"
:
"1"
,
"displayCreateTime"
:
"2023-08-15 12:59:10"
},
{
"children"
:
[
{
"children"
:
[
{
"children"
:
null
,
"parentGuids"
:
[
"e10332122834077907cd5ea61fa576c1"
,
"cdae7bb3cafb560482cad1b89a1e4b78"
],
"guid"
:
"16ea472a155c07433a63220f2ae1afe9"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
"11160011"
,
"organisationName"
:
"链享运营一部1组"
,
"bizState"
:
"S"
,
"createTime"
:
"2023-10-25 13:15:57"
,
"createUserName"
:
"测试"
,
"parentGuid"
:
"cdae7bb3cafb560482cad1b89a1e4b78"
,
"orderNum"
:
1
,
"level"
:
2
,
"levelCode"
:
"2.1.1"
,
"displayCreateTime"
:
"2023-10-25 13:15:57"
}
],
"parentGuids"
:
[
"e10332122834077907cd5ea61fa576c1"
],
"guid"
:
"cdae7bb3cafb560482cad1b89a1e4b78"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
"1116001"
,
"organisationName"
:
"链享运营一部"
,
"bizState"
:
"S"
,
"createTime"
:
"2023-10-25 13:14:15"
,
"createUserName"
:
"测试"
,
"parentGuid"
:
"e10332122834077907cd5ea61fa576c1"
,
"orderNum"
:
1
,
"level"
:
1
,
"levelCode"
:
"2.1"
,
"displayCreateTime"
:
"2023-10-25 13:14:15"
},
{
"children"
:
null
,
"parentGuids"
:
[
"e10332122834077907cd5ea61fa576c1"
],
"guid"
:
"d98b44ffb35e4d17cf68f9a922e1c7b7"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
null
,
"organisationName"
:
"二部"
,
"bizState"
:
"Y"
,
"createTime"
:
"2023-10-26 09:45:36"
,
"createUserName"
:
"测试"
,
"parentGuid"
:
"e10332122834077907cd5ea61fa576c1"
,
"orderNum"
:
2
,
"level"
:
1
,
"levelCode"
:
"2.2"
,
"displayCreateTime"
:
"2023-10-26 09:45:36"
}
],
"parentGuids"
:
null
,
"guid"
:
"e10332122834077907cd5ea61fa576c1"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
"1115005"
,
"organisationName"
:
"链享医药"
,
"bizState"
:
"Y"
,
"createTime"
:
"2023-09-12 15:59:35"
,
"createUserName"
:
"测试"
,
"parentGuid"
:
null
,
"orderNum"
:
3
,
"level"
:
0
,
"levelCode"
:
"2"
,
"displayCreateTime"
:
"2023-09-12 15:59:35"
},
{
"children"
:
[
{
"children"
:
null
,
"parentGuids"
:
[
"9bd46f0f4fcf429518fae6ecb4849a9e"
],
"guid"
:
"870f23ae47e036eb88b35f726c31959b"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
null
,
"organisationName"
:
"运用三部"
,
"bizState"
:
"Y"
,
"createTime"
:
"2024-04-28 16:33:24"
,
"createUserName"
:
"数往知来管理员"
,
"parentGuid"
:
"9bd46f0f4fcf429518fae6ecb4849a9e"
,
"orderNum"
:
3
,
"level"
:
1
,
"levelCode"
:
"3.3"
,
"displayCreateTime"
:
"2024-04-28 16:33:24"
},
{
"children"
:
null
,
"parentGuids"
:
[
"9bd46f0f4fcf429518fae6ecb4849a9e"
],
"guid"
:
"e06049046241dd71b153f227dbe7f801"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
null
,
"organisationName"
:
"运营二部"
,
"bizState"
:
"Y"
,
"createTime"
:
"2023-11-14 16:01:50"
,
"createUserName"
:
"数往知来管理员"
,
"parentGuid"
:
"9bd46f0f4fcf429518fae6ecb4849a9e"
,
"orderNum"
:
40
,
"level"
:
1
,
"levelCode"
:
"3.2"
,
"displayCreateTime"
:
"2023-11-14 16:01:50"
},
{
"children"
:
null
,
"parentGuids"
:
[
"9bd46f0f4fcf429518fae6ecb4849a9e"
],
"guid"
:
"731cd185c868da8af48b492068ffaed4"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
null
,
"organisationName"
:
"运营一部"
,
"bizState"
:
"Y"
,
"createTime"
:
"2023-11-14 15:19:35"
,
"createUserName"
:
"测试"
,
"parentGuid"
:
"9bd46f0f4fcf429518fae6ecb4849a9e"
,
"orderNum"
:
41
,
"level"
:
1
,
"levelCode"
:
"3.1"
,
"displayCreateTime"
:
"2023-11-14 15:19:35"
}
],
"parentGuids"
:
null
,
"guid"
:
"9bd46f0f4fcf429518fae6ecb4849a9e"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
null
,
"organisationName"
:
"药企服务事业部1"
,
"bizState"
:
"Y"
,
"createTime"
:
"2023-11-14 14:49:14"
,
"createUserName"
:
"数往知来管理员"
,
"parentGuid"
:
""
,
"orderNum"
:
4
,
"level"
:
0
,
"levelCode"
:
"3"
,
"displayCreateTime"
:
"2023-11-14 14:49:14"
},
{
"children"
:
[
{
"children"
:
null
,
"parentGuids"
:
[
"23be149ea3167a3f7f2d383023336efe"
],
"guid"
:
"e5f2b4958ee2d99309a41e0c6e1447c8"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
null
,
"organisationName"
:
"智能存储装备部"
,
"bizState"
:
"Y"
,
"createTime"
:
"2023-11-14 16:09:36"
,
"createUserName"
:
"数往知来管理员"
,
"parentGuid"
:
"23be149ea3167a3f7f2d383023336efe"
,
"orderNum"
:
51
,
"level"
:
1
,
"levelCode"
:
"4.1"
,
"displayCreateTime"
:
"2023-11-14 16:09:36"
}
],
"parentGuids"
:
null
,
"guid"
:
"23be149ea3167a3f7f2d383023336efe"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
null
,
"organisationName"
:
"医药物联网事业部"
,
"bizState"
:
"Y"
,
"createTime"
:
"2023-11-14 15:11:35"
,
"createUserName"
:
"数往知来管理员"
,
"parentGuid"
:
""
,
"orderNum"
:
5
,
"level"
:
0
,
"levelCode"
:
"4"
,
"displayCreateTime"
:
"2023-11-14 15:11:35"
},
{
"children"
:
null
,
"parentGuids"
:
null
,
"guid"
:
"1d82e875163749ca9ae45809ec432ae8"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
null
,
"organisationName"
:
"财务管理中心"
,
"bizState"
:
"S"
,
"createTime"
:
"2023-11-14 15:14:07"
,
"createUserName"
:
"数往知来管理员"
,
"parentGuid"
:
""
,
"orderNum"
:
6
,
"level"
:
0
,
"levelCode"
:
"6"
,
"displayCreateTime"
:
"2023-11-14 15:14:07"
},
{
"children"
:
null
,
"parentGuids"
:
null
,
"guid"
:
"cd9e6a0c76102364a9e88b79b28b0b32"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
null
,
"organisationName"
:
"资产服务"
,
"bizState"
:
"Y"
,
"createTime"
:
"2024-08-14 11:40:33"
,
"createUserName"
:
"数往知来管理员"
,
"parentGuid"
:
""
,
"orderNum"
:
7
,
"level"
:
0
,
"levelCode"
:
"9"
,
"displayCreateTime"
:
"2024-08-14 11:40:33"
},
{
"children"
:
[
{
"children"
:
null
,
"parentGuids"
:
[
"dac448b77fa35f798bb4a06d8fd86334"
],
"guid"
:
"cb76777efe69182cfb2c75d41944553c"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
null
,
"organisationName"
:
"审批1"
,
"bizState"
:
"Y"
,
"createTime"
:
"2024-01-17 14:28:36"
,
"createUserName"
:
"数往知来管理员"
,
"parentGuid"
:
"dac448b77fa35f798bb4a06d8fd86334"
,
"orderNum"
:
100
,
"level"
:
1
,
"levelCode"
:
"8.1"
,
"displayCreateTime"
:
"2024-01-17 14:28:36"
}
],
"parentGuids"
:
null
,
"guid"
:
"dac448b77fa35f798bb4a06d8fd86334"
,
"tenantGuid"
:
"9e5b9d7bfd8c4f4f8079e05de19bf7e0"
,
"organisationCode"
:
null
,
"organisationName"
:
"审批组织"
,
"bizState"
:
"Y"
,
"createTime"
:
"2024-01-16 11:38:24"
,
"createUserName"
:
"数往知来管理员"
,
"parentGuid"
:
""
,
"orderNum"
:
99
,
"level"
:
0
,
"levelCode"
:
"8"
,
"displayCreateTime"
:
"2024-01-16 11:38:24"
}
]
const
step
=
ref
(
0
);
const
selectIndex
=
ref
(
0
);
const
taskDetail
=
ref
({});
const
asideSearchInput
=
ref
(
""
);
const
permissionList
:
any
=
ref
([])
const
listLoading
=
ref
(
false
)
...
...
@@ -314,63 +29,29 @@ const listPage = ref({
curr
:
1
,
totalPages
:
0
})
const
currpermissionList
:
any
=
ref
([
{
"guid"
:
"62d01ad586774db2bb3955dfb2d18366"
,
"productGuid"
:
null
,
"productName"
:
null
,
"dataPermissionName"
:
"当前用户"
,
"bizState"
:
"Y"
,
"createUserName"
:
"数往知来管理员"
,
"createTime"
:
"2024-01-24 14:08:43"
,
"sqlScript"
:
null
,
"dataSourceGuid"
:
null
},
{
"guid"
:
"d68a27c1998540a2b8e8f22a2d5eebef"
,
"productGuid"
:
null
,
"productName"
:
null
,
"dataPermissionName"
:
"组织权限"
,
"bizState"
:
"Y"
,
"createUserName"
:
"数往知来管理员"
,
"createTime"
:
"2024-01-24 11:47:02"
,
"sqlScript"
:
null
,
"dataSourceGuid"
:
null
}
])
const
templateInfo
=
ref
({
title
:
'医疗数据分类'
,
descGroup
:
[
{
label
:
'模型确认人'
,
value
:
'管理员 '
},
{
label
:
'模型确认时间'
,
value
:
'2021-12-12 09:12:13'
},
],
tags
:
[
{
type
:
'info'
,
name
:
'医疗行业分类'
},
{
type
:
'success'
,
name
:
'五级'
},
{
type
:
'primary'
,
name
:
'V5'
},
],
desc
:
'适用于各级医疗机构、卫生健康管理部门、公共卫生服务机构、相关专项业务服务机构、相关信息技术服务机构等开展医疗健康数据分类分级。适用于各级医疗机构、卫生健康管理部门、公共卫生服务机构、相关专项业务服务机构、相关信息技术服务机构等开展医疗健康数据分类分级。适用于各级医疗机构、卫生健康。'
})
const
treeIndex
:
any
=
ref
({})
const
currpermissionList
:
any
=
ref
([])
const
templateInfo
=
ref
({})
const
treeInfoRef
=
ref
();
const
treeInfo
=
ref
({
id
:
"data-pickup-tree"
,
filter
:
true
,
queryValue
:
""
,
queryPlaceholder
:
"输入组织名称搜索"
,
loading
:
false
,
queryPlaceholder
:
"请输入分类名称搜索"
,
props
:
{
label
:
"
organisation
Name"
,
label
:
"
classify
Name"
,
value
:
"guid"
,
},
nodeKey
:
'guid'
,
expandedKey
:
[],
expandOnNodeClick
:
false
,
data
:
data1
||
[],
data
:
[],
});
const
expand1
=
ref
(
true
)
const
expand2
=
ref
(
true
)
const
taskFormRef
=
ref
();
const
taskFormItems
:
any
=
ref
([
{
label
:
'任务名称'
,
...
...
@@ -385,7 +66,7 @@ const taskFormItems: any = ref([
label
:
'分级分类目录名称'
,
type
:
'input'
,
placeholder
:
'请输入'
,
field
:
'c
atalog
Name'
,
field
:
'c
gDir
Name'
,
default
:
''
,
maxlength
:
50
,
required
:
true
...
...
@@ -396,7 +77,7 @@ const taskFormRules = ref({
taskName
:
[
{
required
:
true
,
trigger
:
'blur'
,
message
:
"请填写任务名称"
}
],
c
atalog
Name
:
[
c
gDir
Name
:
[
{
required
:
true
,
trigger
:
'blur'
,
message
:
"请填写分级分类目录名称"
}
],
});
...
...
@@ -412,17 +93,25 @@ const page = ref({
{
label
:
"200"
,
value
:
200
},
],
});
const
searchItemValue
:
any
=
ref
({});
const
searchItemValue
:
any
=
ref
({
classifyGuid
:
''
,
detailGuid
:
''
});
const
currTableData
:
any
=
ref
({});
const
selectRowData
=
ref
([])
const
tableInfo
=
ref
({
id
:
"mapping-table"
,
fields
:
[
{
label
:
"序号"
,
type
:
"index"
,
width
:
56
,
align
:
"center"
,
fixed
:
"left"
},
{
label
:
"标签"
,
field
:
"damCode"
,
width
:
96
},
{
label
:
"分类"
,
field
:
"damTypeName"
,
width
:
380
},
{
label
:
"分级"
,
field
:
"damName"
,
width
:
55
},
{
label
:
"规则"
,
field
:
"damTypeName"
,
width
:
380
},
{
label
:
"标签"
,
field
:
"label"
,
width
:
96
},
{
label
:
"分类"
,
field
:
"classifyNames"
,
width
:
380
,
getName
:
(
scope
)
=>
{
const
names
=
scope
.
row
.
classifyNames
||
[];
return
names
.
join
(
'/'
);
}
},
{
label
:
"分级"
,
field
:
"gradeDetailName"
,
width
:
55
},
{
label
:
"规则"
,
field
:
"rule"
,
width
:
380
},
],
loading
:
false
,
data
:
[],
...
...
@@ -436,110 +125,113 @@ const tableInfo = ref({
},
});
const
metadataTableRef
=
ref
();
const
metadataTableInfo
=
ref
({
id
:
"metadata-table"
,
multiple
:
true
,
rowKey
:
'guid'
,
fields
:
[
{
label
:
"序号"
,
type
:
"index"
,
width
:
56
,
align
:
"center"
,
fixed
:
"left"
},
{
label
:
"数据库名称"
,
field
:
"da
mCode
"
,
width
:
200
},
{
label
:
"数据库名"
,
field
:
"da
mTyp
eName"
,
width
:
200
},
{
label
:
"总表数"
,
field
:
"
damName
"
,
width
:
120
,
align
:
"right"
},
{
label
:
"存储量(约/MB)"
,
field
:
"
damTypeName
"
,
width
:
200
,
align
:
"right"
},
{
label
:
"数据库名称"
,
field
:
"da
tabaseNameZh
"
,
width
:
200
},
{
label
:
"数据库名"
,
field
:
"da
tabas
eName"
,
width
:
200
},
{
label
:
"总表数"
,
field
:
"
tableCount
"
,
width
:
120
,
align
:
"right"
},
{
label
:
"存储量(约/MB)"
,
field
:
"
storageCapacities
"
,
width
:
200
,
align
:
"right"
},
],
loading
:
false
,
data
:
[],
page
:
{
type
:
"normal"
,
rows
:
0
,
...
page
.
value
,
},
showPage
:
false
,
// page: {
// type: "normal",
// rows: 0,
// ...page.value,
// },
actionInfo
:
{
show
:
false
},
})
const
getTaskDetail
=
(
data
)
=>
{
getCgTaskDetail
(
data
).
then
((
res
:
any
)
=>
{
if
(
res
.
code
==
proxy
.
$passCode
)
{
const
data
=
res
.
data
||
{};
taskDetail
.
value
=
data
;
taskFormItems
.
value
.
map
((
item
)
=>
{
item
.
default
=
data
[
item
.
field
]
||
''
;
})
selectRowData
.
value
=
data
.
metaGuids
||
[];
getPermissionList
({});
getMetaTableData
();
}
})
}
const
nodeClick
=
(
data
)
=>
{
treeIndex
.
value
=
data
searchItemValue
.
value
.
classifyGuid
=
templateInfo
.
value
.
guid
;
searchItemValue
.
value
.
detailGuid
=
data
.
guid
;
getTableData
();
}
// 获取标签数据
const
getTableData
=
()
=>
{
tableInfo
.
value
.
loading
=
true
;
get
Listing
List
(
get
CgLabelPage
List
(
Object
.
assign
({},
searchItemValue
.
value
,
{
pageIndex
:
page
.
value
.
curr
,
pageSize
:
page
.
value
.
limit
,
})
).
then
((
res
:
any
)
=>
{
tableInfo
.
value
.
loading
=
false
;
if
(
res
.
code
==
proxy
.
$passCode
)
{
tableInfo
.
value
.
data
=
res
.
data
.
records
||
[];
tableInfo
.
value
.
page
.
curr
=
res
.
data
.
pageIndex
;
tableInfo
.
value
.
page
.
limit
=
res
.
data
.
pageSize
;
tableInfo
.
value
.
page
.
rows
=
res
.
data
.
totalRows
;
}
})
.
catch
((
res
)
=>
{
tableInfo
.
value
.
loading
=
false
;
});
};
const
tableBtnClick
=
(
scope
,
btn
)
=>
{
const
type
=
btn
.
value
;
const
row
=
scope
.
row
;
currTableData
.
value
=
row
;
if
(
type
==
"detail"
||
type
===
"edit"
)
{
toPath
(
type
);
}
else
if
(
type
===
"delete"
)
{
open
(
"此操作将永久删除,是否继续?"
,
"warning"
);
}
};
const
toPath
=
(
type
=
null
)
=>
{
const
toPath
=
()
=>
{
router
.
push
({
name
:
"taskConfig"
,
query
:
{
type
},
query
:
{},
});
}
const
tableSelectionChange
=
(
val
)
=>
{
selectRowData
.
value
=
val
.
map
((
item
)
=>
item
.
databaseGuid
);
};
const
tablePageChange
=
(
info
)
=>
{
if
(
step
.
value
==
0
)
{
page
.
value
.
curr
=
Number
(
info
.
curr
);
page
.
value
.
limit
=
Number
(
info
.
limit
);
tableInfo
.
value
.
page
.
limit
=
page
.
value
.
limit
;
tableInfo
.
value
.
page
.
curr
=
page
.
value
.
curr
;
getTableData
();
}
else
{
}
};
const
open
=
(
msg
,
type
,
isBatch
=
false
)
=>
{
ElMessageBox
.
confirm
(
msg
,
"提示"
,
{
confirmButtonText
:
"确定"
,
cancelButtonText
:
"取消"
,
type
:
type
,
}).
then
(()
=>
{
const
guids
=
[
currTableData
.
value
.
guid
];
listingDelete
(
guids
).
then
((
res
:
any
)
=>
{
// 获取元数据表格
const
getMetaTableData
=
()
=>
{
getMetaTableCollectList
({}).
then
((
res
:
any
)
=>
{
metadataTableInfo
.
value
.
loading
=
false
;
if
(
res
.
code
==
proxy
.
$passCode
)
{
getFirstPageData
();
ElMessage
({
type
:
"success"
,
message
:
"删除成功"
,
});
}
else
{
ElMessage
({
type
:
"error"
,
message
:
res
.
msg
,
const
data
=
res
.
data
.
records
||
[];
metadataTableInfo
.
value
.
data
=
data
;
if
(
route
.
query
.
type
===
'edit'
)
{
nextTick
(()
=>
{
data
.
map
((
row
)
=>
{
taskDetail
.
value
.
metaGuids
.
indexOf
(
row
.
guid
)
>
-
1
&&
metadataTableRef
.
value
.
tableRef
.
toggleRowSelection
(
row
,
true
);
});
})
}
}).
catch
((
res
)
=>
{
tableInfo
.
value
.
loading
=
false
;
});
});
};
const
getFirstPageData
=
()
=>
{
page
.
value
.
curr
=
1
tableInfo
.
value
.
page
.
curr
=
1
;
getTableData
();
}
})
}
const
querySearch
=
(
queryString
:
string
)
=>
{
...
...
@@ -557,11 +249,73 @@ const btnClick = async (btn, bType = null) => {
step
.
value
++
;
}
else
if
(
type
==
'prev'
)
{
step
.
value
--
;
}
else
if
(
type
==
'path'
)
{
if
(
selectRowData
.
value
.
length
==
0
)
{
ElMessage
({
type
:
'warning'
,
message
:
'请选择元数据'
})
return
}
const
formEl
=
taskFormRef
.
value
.
ruleFormRef
;
const
form
=
taskFormRef
.
value
.
formInline
;
const
subForm
=
{
...
form
};
submitForm
(
formEl
,
subForm
);
}
else
{
toPath
()
}
};
const
submitForm
=
(
formEl
,
info
)
=>
{
if
(
!
formEl
)
return
;
formEl
.
validate
((
valid
,
fields
)
=>
{
if
(
valid
)
{
const
params
=
{
classifyGuid
:
templateInfo
.
value
.
guid
,
metaGuids
:
selectRowData
.
value
,
...
info
}
if
(
route
.
query
.
type
===
'edit'
)
{
params
.
guid
=
taskDetail
.
value
.
guid
;
params
.
execGuid
=
taskDetail
.
value
.
execGuid
;
cgTaskUpdate
(
params
).
then
((
res
:
any
)
=>
{
if
(
res
.
code
==
proxy
.
$passCode
)
{
toPath
()
}
else
{
ElMessage
({
type
:
"error"
,
message
:
res
.
msg
,
});
}
}).
catch
(()
=>
{
ElMessage
({
type
:
"error"
,
message
:
'请求失败'
,
});
})
}
else
{
cgTaskSave
(
params
).
then
((
res
:
any
)
=>
{
if
(
res
.
code
==
proxy
.
$passCode
)
{
toPath
()
}
else
{
ElMessage
({
type
:
"error"
,
message
:
res
.
msg
,
});
}
}).
catch
(()
=>
{
ElMessage
({
type
:
"error"
,
message
:
'请求失败'
,
});
})
}
}
else
{
console
.
log
(
"error submit!"
,
fields
);
}
});
};
// 监听滚动事件
const
handleScroll
=
()
=>
{
if
(
listPage
.
value
.
curr
<
listPage
.
value
.
totalPages
)
{
...
...
@@ -570,40 +324,80 @@ const handleScroll = () => {
}
}
const
changTable
=
()
=>
{
// toSearch({})
// 点击分类列表
const
listClick
=
(
row
)
=>
{
templateInfo
.
value
=
row
;
getClassifyTree
()
};
const
getPermissionList
=
(
val
,
init
=
false
)
=>
{
// 获取分类列表
const
getPermissionList
=
(
val
,
init
=
true
)
=>
{
let
params
:
any
=
val
?
{
...
val
}
:
{}
params
.
pageIndex
=
listPage
.
value
.
curr
;
params
.
pageSize
=
listPage
.
value
.
limit
;
params
.
type
=
'C'
;
listLoading
.
value
=
true
// getPermissionDictList(params).then((res: any) => {
// if (res.code == proxy.$passCode) {
// const data = res.data?.records || []
// if (init) {
// permissionList.value = JSON.parse(JSON.stringify(data))
// currpermissionList.value = JSON.parse(JSON.stringify(data))
// listPage.value.totalPages = res.data.totalPages
// toSearch({})
// } else {
// permissionList.value.push(...JSON.parse(JSON.stringify(data)))
// querySearch(asideSearchInput.value)
// }
// }
// listLoading.value = false
// }).catch(() => {
// listLoading.value = false
// })
getClassifyGradList
(
params
).
then
((
res
:
any
)
=>
{
if
(
res
.
code
==
proxy
.
$passCode
)
{
const
data
=
res
.
data
?.
records
||
[]
if
(
init
)
{
permissionList
.
value
=
JSON
.
parse
(
JSON
.
stringify
(
data
))
currpermissionList
.
value
=
JSON
.
parse
(
JSON
.
stringify
(
data
))
listPage
.
value
.
totalPages
=
res
.
data
.
totalPages
if
(
data
.
length
)
{
if
(
route
.
query
.
type
==
'edit'
)
{
templateInfo
.
value
=
data
.
filter
(
item
=>
item
.
guid
==
taskDetail
.
value
.
classifyGuid
)[
0
]
}
else
{
templateInfo
.
value
=
data
[
0
];
}
getClassifyTree
()
}
}
else
{
permissionList
.
value
.
push
(...
JSON
.
parse
(
JSON
.
stringify
(
data
)))
querySearch
(
asideSearchInput
.
value
)
}
}
listLoading
.
value
=
false
}).
catch
(()
=>
{
listLoading
.
value
=
false
})
}
onActivated
(()
=>
{
// 获取树形列表
const
getClassifyTree
=
()
=>
{
const
params
=
{
classifyGradeGuid
:
templateInfo
.
value
.
guid
}
treeInfo
.
value
.
loading
=
true
;
getClassifyTreeList
(
params
).
then
((
res
:
any
)
=>
{
treeInfo
.
value
.
loading
=
false
;
if
(
res
.
code
==
proxy
.
$passCode
)
{
const
data
=
res
.
data
||
[];
treeInfo
.
value
.
data
=
data
;
treeInfoRef
.
value
.
setCurrentKey
(
''
);
tableInfo
.
value
.
data
=
[];
}
}).
catch
(()
=>
{
treeInfo
.
value
.
loading
=
false
;
})
}
onActivated
(()
=>
{
// if (route.query.type == 'edit') {
// getTaskDetail({ guid: route.query.guid })
// } else {
// getPermissionList({});
// getMetaTableData();
// }
})
onBeforeMount
(()
=>
{
if
(
route
.
query
.
type
==
'edit'
)
{
getTaskDetail
({
guid
:
route
.
query
.
guid
})
}
else
{
getPermissionList
({});
getMetaTableData
();
}
})
</
script
>
...
...
@@ -618,46 +412,38 @@ onBeforeMount(() => {
</div>
<div
class=
"aside_list"
v-loading=
"listLoading"
v-infinite-scroll=
"handleScroll"
>
<div
class=
"list_item"
v-for=
"(item, i) in currpermissionList"
:class=
"
{ active: selectIndex == i }"
@click="selectIndex = i;
changTable();" v-preReClick>
{{
item
.
dataPermissionN
ame
}}
</div>
@click="selectIndex = i;
listClick(item);" v-preReClick>
{{
item
.
n
ame
}}
</div>
</div>
</div>
<div
class=
"main_wrap"
:class=
"
{ full: step == 1 }">
<div
class=
"content_main"
v-show=
"step == 0"
>
<div
class=
"template_panel"
>
<div
class=
"panel_title"
>
<span
class=
"title_text"
>
{{
templateInfo
.
title
}}
</span>
<div
class=
"title_desc"
>
<div
class=
"desc_group"
v-for=
"desc in templateInfo.descGroup"
>
<span
class=
"desc_label"
>
{{
desc
.
label
}}
:
</span>
<span
class=
"desc_value"
>
{{
desc
.
value
}}
</span>
</div>
<div
class=
"title_item"
>
<span
class=
"title_label"
>
分类标准:
</span>
<span
class=
"title_text"
>
{{
templateInfo
.
name
||
'--'
}}
</span>
</div>
<div
class=
"title_item"
>
<span
class=
"title_label"
>
分级标准:
</span>
<span
class=
"title_text"
>
{{
templateInfo
.
refGradeName
||
'--'
}}
</span>
</div>
<div
class=
"panel_tags"
>
<el-tag
v-for=
"tag in templateInfo.tags"
:type=
"tag.type"
>
{{
tag
.
name
}}
</el-tag>
<div
class=
"title_item is_block"
>
<span
class=
"title_label"
>
描述:
</span>
<span
class=
"title_text"
>
{{
templateInfo
.
description
||
'--'
}}
</span>
</div>
<p
class=
"panel_desc"
>
{{
templateInfo
.
desc
}}
</p>
</div>
<div
class=
"panel_content"
>
<div
class=
"box_left"
>
<div
class=
"aside_title"
>
分类分级目录
</div>
<Tree
:treeInfo=
"treeInfo"
@
nodeClick=
"nodeClick"
/>
<Tree
ref=
"treeInfoRef"
:treeInfo=
"treeInfo"
@
nodeClick=
"nodeClick"
/>
</div>
<div
class=
"box_right"
>
<el-breadcrumb
separator=
"/"
>
<el-breadcrumb-item>
全部
</el-breadcrumb-item>
<el-breadcrumb-item>
promotion management
</el-breadcrumb-item>
<el-breadcrumb-item>
promotion list
</el-breadcrumb-item>
<el-breadcrumb-item>
promotion detail
</el-breadcrumb-item>
</el-breadcrumb>
<div
class=
"table_panel_wrap"
>
<Table
:tableInfo=
"tableInfo"
@
table
BtnClick=
"tableBtnClick"
@
table
PageChange=
"tablePageChange"
/>
<Table
:tableInfo=
"tableInfo"
@
tablePageChange=
"tablePageChange"
/>
</div>
</div>
</div>
</div>
<div
class=
"content_main panel"
v-show=
"step == 1"
>
<ContentWrap
id=
"id-approveInfo"
title=
"创建任务"
expandSwicth
style=
"margin-top: 15px"
:isExpand=
"expand1"
<ContentWrap
title=
"创建任务"
expandSwicth
style=
"margin-top: 15px"
:isExpand=
"expand1"
@
expand=
"(v) => expand1 = v"
>
<div
class=
"form_panel"
>
<Form
ref=
"taskFormRef"
formId=
"edit-standard-form"
:itemList=
"taskFormItems"
:rules=
"taskFormRules"
...
...
@@ -666,7 +452,9 @@ onBeforeMount(() => {
</ContentWrap>
<ContentWrap
id=
"id-approveInfo"
title=
"选择元数据"
expandSwicth
style=
"margin-top: 15px"
:isExpand=
"expand2"
@
expand=
"(v) => expand2 = v"
>
<Table
:tableInfo=
"metadataTableInfo"
/>
<div
class=
"table_panel_wrap full"
>
<Table
ref=
"metadataTableRef"
:tableInfo=
"metadataTableInfo"
@
tableSelectionChange=
"tableSelectionChange"
/>
</div>
</ContentWrap>
</div>
<div
class=
"tool_btns"
>
...
...
@@ -746,44 +534,40 @@ onBeforeMount(() => {
}
.template_panel
{
padding
:
0
8px
;
.panel_title
{
display
:
flex
;
justify-content
:
space-between
;
align-items
:
center
;
margin
:
8px
0
;
.title_text
{
font-size
:
16px
;
color
:
#212121
;
line-height
:
24px
;
font-weight
:
600
;
}
flex-wrap
:
wrap
;
padding
:
16px
16px
8px
;
.title_desc
{
.title_item
{
display
:
flex
;
margin-bottom
:
8px
;
.desc_group
{
margin-left
:
16px
;
}
}
+.title_item
{
margin-left
:
40px
;
}
.panel_tags
{
.el-tag
{
margin-right
:
8
px
;
}
.title_label
{
display
:
block
;
width
:
80
px
;
line-height
:
1.5
;
}
.panel_desc
{
margin
:
8px
0
16px
;
font-size
:
14px
;
color
:
#666
;
.title_text
{
line-height
:
1.5
;
}
&
.is_block
{
width
:
100%
;
margin-left
:
0
;
.title_text
{
display
:
block
;
width
:
calc
(
100%
-
80px
);
text-align
:
justify
;
}
}
}
}
.panel_content
{
height
:
100%
;
...
...
@@ -806,12 +590,13 @@ onBeforeMount(() => {
}
.tree_panel
{
padding
:
0
;
height
:
100%
;
}
}
.box_right
{
width
:
100%
;
width
:
calc
(
100%
-
240px
);
padding-top
:
8px
;
.el-breadcrumb
{
padding
:
0
12px
;
...
...
@@ -820,10 +605,26 @@ onBeforeMount(() => {
}
}
:deep
(
#id-approveInfo
)
{
height
:
calc
(
100%
-
192px
);
.el-card__body
{
height
:
calc
(
100%
-
50px
)
!important
;
.card-body-content
{
height
:
100%
;
}
}
}
.table_panel_wrap
{
width
:
100%
;
height
:
calc
(
100%
-
40px
)
;
height
:
100%
;
padding
:
0
12px
;
&.full
{
padding
:
0
;
}
}
}
...
...
src/views/data_inventory/taskLog.vue
View file @
751d9bb
...
...
@@ -9,329 +9,17 @@ import useUserStore from "@/store/modules/user";
import
{
ElMessage
,
ElMessageBox
}
from
"element-plus"
;
import
useDataAssetStore
from
"@/store/modules/dataAsset"
;
import
{
get
ListingList
,
listingDelete
,
listingUpdateStatus
,
filterVal
,
getParamsDataList
}
from
"@/api/modules/dataProduct
"
;
import
{
get
TaskExecPageList
,
filterVal
}
from
"@/api/modules/dataInventory
"
;
import
{
TableColumnWidth
}
from
'@/utils/enum'
;
import
Table
from
"@/components/Table/index.vue"
;
const
{
proxy
}
=
getCurrentInstance
()
as
any
;
const
router
=
useRouter
();
const
route
=
useRoute
();
const
userStore
=
useUserStore
();
const
userData
=
JSON
.
parse
(
userStore
.
userData
);
const
assetStore
=
useDataAssetStore
();
const
datas
=
[
{
"updateTime"
:
"2024-07-16 13:17:00"
,
"updateUserName"
:
"数往知来管理员"
,
"guid"
:
"4e0e76c48fa043d5b35d09f3ccc7c265"
,
"approvalGuid"
:
null
,
"standardSetGuid"
:
"58d1178a04904d599284fc1e61594c43"
,
"fieldStandardCode"
:
"COL202406070021"
,
"dataVersion"
:
1
,
"chName"
:
"地址"
,
"enName"
:
"address"
,
"dataTypeValue"
:
"字符型"
,
"dataTypeCode"
:
"varchar"
,
"dataDicGuid"
:
""
,
"dataDicName"
:
null
,
"isDataDic"
:
"N"
,
"fieldLength"
:
600
,
"fieldPrecision"
:
null
,
"dataState"
:
0
,
"approveState"
:
"N"
,
"dataCategory"
:
"合伙人"
,
"dataEncryptionLevel"
:
"界面加密"
,
"businessDefDesc"
:
"地址"
,
"flowFlag"
:
null
,
"flowCode"
:
null
,
"functionCode"
:
null
,
"createStaffGuid"
:
null
,
"createUserId"
:
"98df01b8d86c46f786dd10b4d0eb11dd"
,
"displayVersion"
:
"V1"
,
"standardSetName"
:
null
,
"ruleType"
:
null
},
{
"updateTime"
:
"2024-01-27 10:19:45"
,
"updateUserName"
:
"数往知来管理员"
,
"guid"
:
"bc630207357c466dbff7613ea38985cc"
,
"approvalGuid"
:
null
,
"standardSetGuid"
:
"58d1178a04904d599284fc1e61594c43"
,
"fieldStandardCode"
:
"COL202401260124"
,
"dataVersion"
:
1
,
"chName"
:
"包含最小销售包装单元数量"
,
"enName"
:
"inboxQuantity"
,
"dataTypeValue"
:
"整型"
,
"dataTypeCode"
:
"int"
,
"dataDicGuid"
:
null
,
"dataDicName"
:
null
,
"isDataDic"
:
null
,
"fieldLength"
:
null
,
"fieldPrecision"
:
null
,
"dataState"
:
1
,
"approveState"
:
"A"
,
"dataCategory"
:
null
,
"dataEncryptionLevel"
:
"明文显示"
,
"businessDefDesc"
:
"当前药品追溯码中包含的最小销售包装单元药品追溯码的数量,发货类型为03时可选"
,
"flowFlag"
:
null
,
"flowCode"
:
null
,
"functionCode"
:
null
,
"createStaffGuid"
:
null
,
"createUserId"
:
"98df01b8d86c46f786dd10b4d0eb11dd"
,
"displayVersion"
:
"V1"
,
"standardSetName"
:
null
,
"ruleType"
:
null
},
{
"updateTime"
:
"2024-01-27 11:03:59"
,
"updateUserName"
:
"审批人4"
,
"guid"
:
"420f2a68bd4441bf92010eadf698b685"
,
"approvalGuid"
:
null
,
"standardSetGuid"
:
"58d1178a04904d599284fc1e61594c43"
,
"fieldStandardCode"
:
"COL202401260122"
,
"dataVersion"
:
1
,
"chName"
:
"包装层级"
,
"enName"
:
"packageLevel"
,
"dataTypeValue"
:
"字符型"
,
"dataTypeCode"
:
"varchar"
,
"dataDicGuid"
:
null
,
"dataDicName"
:
null
,
"isDataDic"
:
null
,
"fieldLength"
:
200
,
"fieldPrecision"
:
null
,
"dataState"
:
1
,
"approveState"
:
"A"
,
"dataCategory"
:
null
,
"dataEncryptionLevel"
:
"明文显示"
,
"businessDefDesc"
:
"当前药品追溯码所处包装层级描述,发货类型为03时可选"
,
"flowFlag"
:
null
,
"flowCode"
:
null
,
"functionCode"
:
null
,
"createStaffGuid"
:
null
,
"createUserId"
:
"98df01b8d86c46f786dd10b4d0eb11dd"
,
"displayVersion"
:
"V1"
,
"standardSetName"
:
null
,
"ruleType"
:
null
},
{
"updateTime"
:
"2024-06-06 10:01:06"
,
"updateUserName"
:
"审批人1"
,
"guid"
:
"f841e1848ab94b1e81a0217a09a7a3d3"
,
"approvalGuid"
:
"b674bffe8d2f4132918016b6baaf75aa"
,
"standardSetGuid"
:
"58d1178a04904d599284fc1e61594c43"
,
"fieldStandardCode"
:
"COL202401260120"
,
"dataVersion"
:
1
,
"chName"
:
"上一级包装药品追溯码"
,
"enName"
:
"parentDTC"
,
"dataTypeValue"
:
"字符型"
,
"dataTypeCode"
:
"varchar"
,
"dataDicGuid"
:
""
,
"dataDicName"
:
null
,
"isDataDic"
:
"N"
,
"fieldLength"
:
200
,
"fieldPrecision"
:
null
,
"dataState"
:
1
,
"approveState"
:
"Y"
,
"dataCategory"
:
""
,
"dataEncryptionLevel"
:
"明文显示"
,
"businessDefDesc"
:
"当前药品追溯码大一级包装上的药品追溯码,发货类型为03时可选;当存在上一级包装时必选"
,
"flowFlag"
:
null
,
"flowCode"
:
null
,
"functionCode"
:
null
,
"createStaffGuid"
:
null
,
"createUserId"
:
"98df01b8d86c46f786dd10b4d0eb11dd"
,
"displayVersion"
:
"V1"
,
"standardSetName"
:
null
,
"ruleType"
:
null
},
{
"updateTime"
:
"2024-01-26 00:10:47"
,
"updateUserName"
:
"数往知来管理员"
,
"guid"
:
"d4d42dea2a5844b4a7f9238806ea507b"
,
"approvalGuid"
:
null
,
"standardSetGuid"
:
"58d1178a04904d599284fc1e61594c43"
,
"fieldStandardCode"
:
"COL202401260118"
,
"dataVersion"
:
1
,
"chName"
:
"药品追溯码"
,
"enName"
:
"DTC"
,
"dataTypeValue"
:
"字符型"
,
"dataTypeCode"
:
"varchar"
,
"dataDicGuid"
:
null
,
"dataDicName"
:
null
,
"isDataDic"
:
null
,
"fieldLength"
:
200
,
"fieldPrecision"
:
null
,
"dataState"
:
0
,
"approveState"
:
"N"
,
"dataCategory"
:
null
,
"dataEncryptionLevel"
:
"明文显示"
,
"businessDefDesc"
:
"用于唯一标识药品各级销售包装单元的代码,发货类型为03时可选"
,
"flowFlag"
:
null
,
"flowCode"
:
null
,
"functionCode"
:
null
,
"createStaffGuid"
:
null
,
"createUserId"
:
"98df01b8d86c46f786dd10b4d0eb11dd"
,
"displayVersion"
:
"V1"
,
"standardSetName"
:
null
,
"ruleType"
:
null
},
{
"updateTime"
:
"2024-01-26 00:10:47"
,
"updateUserName"
:
"数往知来管理员"
,
"guid"
:
"ff9d0e4f6fbb444c8dcf6f67bffcb659"
,
"approvalGuid"
:
null
,
"standardSetGuid"
:
"58d1178a04904d599284fc1e61594c43"
,
"fieldStandardCode"
:
"COL202401260116"
,
"dataVersion"
:
1
,
"chName"
:
"发货数量"
,
"enName"
:
"deliveryQuantity"
,
"dataTypeValue"
:
"整型"
,
"dataTypeCode"
:
"int"
,
"dataDicGuid"
:
null
,
"dataDicName"
:
null
,
"isDataDic"
:
null
,
"fieldLength"
:
null
,
"fieldPrecision"
:
null
,
"dataState"
:
0
,
"approveState"
:
"N"
,
"dataCategory"
:
null
,
"dataEncryptionLevel"
:
"明文显示"
,
"businessDefDesc"
:
"发货的最小销售包装单元数量"
,
"flowFlag"
:
null
,
"flowCode"
:
null
,
"functionCode"
:
null
,
"createStaffGuid"
:
null
,
"createUserId"
:
"98df01b8d86c46f786dd10b4d0eb11dd"
,
"displayVersion"
:
"V1"
,
"standardSetName"
:
null
,
"ruleType"
:
null
},
{
"updateTime"
:
"2024-01-26 00:10:46"
,
"updateUserName"
:
"数往知来管理员"
,
"guid"
:
"fe88ac9e8d9c4f148833dbb3976fca77"
,
"approvalGuid"
:
null
,
"standardSetGuid"
:
"58d1178a04904d599284fc1e61594c43"
,
"fieldStandardCode"
:
"COL202401260114"
,
"dataVersion"
:
1
,
"chName"
:
"药品生产批号"
,
"enName"
:
"batch"
,
"dataTypeValue"
:
"字符型"
,
"dataTypeCode"
:
"varchar"
,
"dataDicGuid"
:
null
,
"dataDicName"
:
null
,
"isDataDic"
:
null
,
"fieldLength"
:
20
,
"fieldPrecision"
:
null
,
"dataState"
:
0
,
"approveState"
:
"N"
,
"dataCategory"
:
null
,
"dataEncryptionLevel"
:
"明文显示"
,
"businessDefDesc"
:
"药品包装上标示的生产批号"
,
"flowFlag"
:
null
,
"flowCode"
:
null
,
"functionCode"
:
null
,
"createStaffGuid"
:
null
,
"createUserId"
:
"98df01b8d86c46f786dd10b4d0eb11dd"
,
"displayVersion"
:
"V1"
,
"standardSetName"
:
null
,
"ruleType"
:
null
},
{
"updateTime"
:
"2024-01-26 00:10:45"
,
"updateUserName"
:
"数往知来管理员"
,
"guid"
:
"9759837e0d72472ab7441c1873c9159a"
,
"approvalGuid"
:
null
,
"standardSetGuid"
:
"58d1178a04904d599284fc1e61594c43"
,
"fieldStandardCode"
:
"COL202401260112"
,
"dataVersion"
:
1
,
"chName"
:
"药品有效期截止日期"
,
"enName"
:
"expirationDate"
,
"dataTypeValue"
:
"日期型"
,
"dataTypeCode"
:
"date"
,
"dataDicGuid"
:
null
,
"dataDicName"
:
null
,
"isDataDic"
:
null
,
"fieldLength"
:
null
,
"fieldPrecision"
:
null
,
"dataState"
:
0
,
"approveState"
:
"N"
,
"dataCategory"
:
null
,
"dataEncryptionLevel"
:
"明文显示"
,
"businessDefDesc"
:
"药品有效期的截止日期"
,
"flowFlag"
:
null
,
"flowCode"
:
null
,
"functionCode"
:
null
,
"createStaffGuid"
:
null
,
"createUserId"
:
"98df01b8d86c46f786dd10b4d0eb11dd"
,
"displayVersion"
:
"V1"
,
"standardSetName"
:
null
,
"ruleType"
:
null
},
{
"updateTime"
:
"2024-01-26 00:10:45"
,
"updateUserName"
:
"数往知来管理员"
,
"guid"
:
"a39ed6123c6a420d9d1265315e714f86"
,
"approvalGuid"
:
null
,
"standardSetGuid"
:
"58d1178a04904d599284fc1e61594c43"
,
"fieldStandardCode"
:
"COL202401260110"
,
"dataVersion"
:
1
,
"chName"
:
"药品生产日期"
,
"enName"
:
"productionDate"
,
"dataTypeValue"
:
"日期型"
,
"dataTypeCode"
:
"date"
,
"dataDicGuid"
:
null
,
"dataDicName"
:
null
,
"isDataDic"
:
null
,
"fieldLength"
:
null
,
"fieldPrecision"
:
null
,
"dataState"
:
0
,
"approveState"
:
"N"
,
"dataCategory"
:
null
,
"dataEncryptionLevel"
:
"明文显示"
,
"businessDefDesc"
:
"药品包装上标示的生产日期"
,
"flowFlag"
:
null
,
"flowCode"
:
null
,
"functionCode"
:
null
,
"createStaffGuid"
:
null
,
"createUserId"
:
"98df01b8d86c46f786dd10b4d0eb11dd"
,
"displayVersion"
:
"V1"
,
"standardSetName"
:
null
,
"ruleType"
:
null
},
{
"updateTime"
:
"2024-01-26 00:10:45"
,
"updateUserName"
:
"数往知来管理员"
,
"guid"
:
"ea597c1b8bb24a5ab053a80b084de98c"
,
"approvalGuid"
:
null
,
"standardSetGuid"
:
"58d1178a04904d599284fc1e61594c43"
,
"fieldStandardCode"
:
"COL202401260108"
,
"dataVersion"
:
1
,
"chName"
:
"统一社会信用代码(进口药品代理企业)"
,
"enName"
:
"drugImporterUSCID"
,
"dataTypeValue"
:
"字符型"
,
"dataTypeCode"
:
"varchar"
,
"dataDicGuid"
:
null
,
"dataDicName"
:
null
,
"isDataDic"
:
null
,
"fieldLength"
:
18
,
"fieldPrecision"
:
null
,
"dataState"
:
0
,
"approveState"
:
"N"
,
"dataCategory"
:
null
,
"dataEncryptionLevel"
:
"明文显示"
,
"businessDefDesc"
:
"进口药品代理企业的统一社会信用代码,进口药品必选;没有统一社会信用代码时使用组织机构代码"
,
"flowFlag"
:
null
,
"flowCode"
:
null
,
"functionCode"
:
null
,
"createStaffGuid"
:
null
,
"createUserId"
:
"98df01b8d86c46f786dd10b4d0eb11dd"
,
"displayVersion"
:
"V1"
,
"standardSetName"
:
null
,
"ruleType"
:
null
}
]
const
loading
=
ref
(
false
);
const
page
=
ref
({
limit
:
50
,
curr
:
1
,
...
...
@@ -349,30 +37,32 @@ const tableInfo = ref({
id
:
"mapping-table"
,
fields
:
[
{
label
:
"序号"
,
type
:
"index"
,
width
:
56
,
align
:
"center"
,
fixed
:
"left"
},
{
label
:
"任务名称"
,
field
:
"
ch
Name"
,
width
:
96
},
{
label
:
"任务名称"
,
field
:
"
task
Name"
,
width
:
96
},
{
label
:
"目录名称"
,
field
:
"
dataTypeValu
e"
,
width
:
120
,
type
:
"text_btn"
,
columClass
:
'text_btn'
,
click
:
(
scope
)
=>
{
label
:
"目录名称"
,
field
:
"
cgDirNam
e"
,
width
:
120
,
type
:
"text_btn"
,
columClass
:
'text_btn'
,
click
:
(
scope
)
=>
{
router
.
push
({
name
:
"templateConfig"
,
query
:
{
guid
:
scope
.
row
.
damGuid
},
});
}
},
{
label
:
"分类分级模板"
,
field
:
"dataTypeValue"
,
width
:
200
},
{
label
:
"元数据"
,
field
:
"fieldStandardCode"
,
width
:
200
},
{
label
:
"任务修改人"
,
field
:
"dataCategory"
,
width
:
120
},
{
label
:
"元数据"
,
field
:
"metaNames"
,
width
:
200
,
getName
:
(
scope
)
=>
{
const
metaNames
=
scope
.
row
.
metaNames
||
[];
return
metaNames
.
join
(
','
);
}
},
{
label
:
"任务修改人"
,
field
:
"updateUserName"
,
width
:
120
},
{
label
:
"修改时间"
,
field
:
"updateTime"
,
width
:
TableColumnWidth
.
DATETIME
},
{
label
:
"确认次数"
,
field
:
"fieldLength"
,
width
:
96
,
align
:
'right'
},
{
label
:
"结果确认人"
,
field
:
"updateUserName"
,
width
:
120
},
{
label
:
"确认时间"
,
field
:
"updateTime"
,
width
:
TableColumnWidth
.
DATETIME
},
{
label
:
"结果确认人"
,
field
:
"confirmUserName"
,
width
:
120
},
{
label
:
"确认时间"
,
field
:
"confirmTime"
,
width
:
TableColumnWidth
.
DATETIME
},
{
label
:
"结果状态"
,
field
:
"
approveState
"
,
width
:
TableColumnWidth
.
STATE
,
align
:
'center'
,
type
:
"tag"
,
getName
:
(
scope
)
=>
{
return
filterVal
(
scope
.
row
.
approveState
,
'approveState
'
);
label
:
"结果状态"
,
field
:
"
status
"
,
width
:
TableColumnWidth
.
STATE
,
align
:
'center'
,
type
:
"tag"
,
getName
:
(
scope
)
=>
{
return
filterVal
(
scope
.
row
.
status
,
'confirmStatus
'
);
}
},
],
loading
:
false
,
data
:
datas
||
[],
data
:
[],
page
:
{
type
:
"normal"
,
rows
:
0
,
...
...
@@ -386,40 +76,30 @@ const tableInfo = ref({
let
row
=
scope
.
row
,
btnArr
:
any
=
[
{
label
:
"查看结果"
,
value
:
"path"
},
];
// if (row.approveState == 'Y') {
// if (row.listingStatus == 'Y') {
// btnArr.splice(0, 0, { label: "详情", value: "detail" });
// } else {
// btnArr.splice(0, 0, { label: "编辑", value: "edit" }, { label: "详情", value: "detail" }, { label: "删除", value: "delete" });
// }
// } else {
// if (row.approveState == 'A') {
// btnArr.splice(0, 0, { label: "详情", value: "detail" });
// } else {
// btnArr.splice(0, 0, { label: "编辑", value: "edit" }, { label: "详情", value: "detail" }, { label: "删除", value: "delete" });
// }
// }
return
btnArr
;
},
},
});
const
getTableData
=
()
=>
{
tableInfo
.
value
.
loading
=
true
;
get
Listing
List
(
loading
.
value
=
true
;
get
TaskExecPage
List
(
Object
.
assign
({},
searchItemValue
.
value
,
{
pageIndex
:
page
.
value
.
curr
,
pageSize
:
page
.
value
.
limit
,
taskGuid
:
route
.
query
.
guid
})
).
then
((
res
:
any
)
=>
{
tableInfo
.
value
.
loading
=
false
;
loading
.
value
=
false
;
if
(
res
.
code
==
proxy
.
$passCode
)
{
tableInfo
.
value
.
data
=
res
.
data
.
records
||
[];
tableInfo
.
value
.
page
.
curr
=
res
.
data
.
pageIndex
;
tableInfo
.
value
.
page
.
limit
=
res
.
data
.
pageSize
;
tableInfo
.
value
.
page
.
rows
=
res
.
data
.
totalRows
;
}
})
.
catch
((
res
)
=>
{
tableInfo
.
value
.
loading
=
false
;
loading
.
value
=
false
;
});
};
...
...
@@ -429,8 +109,6 @@ const tableBtnClick = (scope, btn) => {
currTableData
.
value
=
row
;
if
(
type
==
"path"
)
{
toPath
(
type
);
}
else
if
(
type
===
"delete"
)
{
open
(
"此操作将永久删除,是否继续?"
,
"warning"
);
}
};
...
...
@@ -453,32 +131,6 @@ const tablePageChange = (info) => {
getTableData
();
};
const
open
=
(
msg
,
type
,
isBatch
=
false
)
=>
{
ElMessageBox
.
confirm
(
msg
,
"提示"
,
{
confirmButtonText
:
"确定"
,
cancelButtonText
:
"取消"
,
type
:
type
,
}).
then
(()
=>
{
const
guids
=
[
currTableData
.
value
.
guid
];
listingDelete
(
guids
).
then
((
res
:
any
)
=>
{
if
(
res
.
code
==
proxy
.
$passCode
)
{
getFirstPageData
();
ElMessage
({
type
:
"success"
,
message
:
"删除成功"
,
});
}
else
{
ElMessage
({
type
:
"error"
,
message
:
res
.
msg
,
});
}
}).
catch
((
res
)
=>
{
tableInfo
.
value
.
loading
=
false
;
});
});
};
const
getFirstPageData
=
()
=>
{
page
.
value
.
curr
=
1
tableInfo
.
value
.
page
.
curr
=
1
;
...
...
@@ -486,10 +138,7 @@ const getFirstPageData = () => {
}
onActivated
(()
=>
{
if
(
assetStore
.
isRefresh
)
{
//如果是首次加载,则不需要调用
getFirstPageData
();
assetStore
.
set
(
false
);
}
getFirstPageData
()
})
onBeforeMount
(()
=>
{
...
...
@@ -499,18 +148,13 @@ onBeforeMount(() => {
</
script
>
<
template
>
<div
class=
"container_wrap"
v-if=
"tableInfo.data.length"
>
<div
class=
"table_tool_wrap"
>
<div
class=
"table_title"
>
分类分级任务
</div>
</div>
<div
class=
"table_panel_wrap"
>
<div
class=
"container_wrap"
v-loading=
"loading"
>
<div
class=
"table_panel_wrap"
v-if=
"tableInfo.data.length"
>
<Table
:tableInfo=
"tableInfo"
@
tableBtnClick=
"tableBtnClick"
@
tablePageChange=
"tablePageChange"
/>
</div>
</div>
<div
class=
"container_wrap"
v-else
>
<div
class=
"card-noData"
>
<div
class=
"card-noData"
v-else
>
<img
src=
"@/assets/images/no-data.png"
:style=
"
{ width: '96px', height: '96px' }" />
<p>
暂无分类分级任务
,
<span
class=
"text_btn"
@
click=
"toPath('add')"
>
去新建
</span>
</p>
<p>
暂无分类分级任务
日志记录
</p>
</div>
</div>
</
template
>
...
...
@@ -532,7 +176,7 @@ onBeforeMount(() => {
.table_panel_wrap
{
width
:
100%
;
height
:
calc
(
100%
-
40px
)
;
height
:
100%
;
padding
:
0px
8px
0
;
}
...
...
Write
Preview
Styling with
Markdown
is supported
Attach a file
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 post a comment