Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
B
bigDataSystem
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
张伯涛
bigDataSystem
Commits
fd865fd2
Commit
fd865fd2
authored
Nov 12, 2024
by
LiXuyang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
逻辑模型-删除/待发布/按钮禁用
parent
bee33105
Changes
14
Hide whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
336 additions
and
40 deletions
+336
-40
index.vue
src/views/dataSecurity/sensitiveRules/index.vue
+1
-1
importModel.vue
src/views/dataWarehousePlanning/logicalModel/importModel.vue
+68
-0
index.vue
src/views/dataWarehousePlanning/logicalModel/index.vue
+57
-25
model.data.ts
src/views/dataWarehousePlanning/logicalModel/model.data.ts
+42
-0
index.vue
...ehousePlanning/logicalModel/modelDetail/ERchart/index.vue
+1
-1
connectionTable.vue
...ousePlanning/logicalModel/modelDetail/connectionTable.vue
+24
-1
crossTable.vue
...WarehousePlanning/logicalModel/modelDetail/crossTable.vue
+24
-2
entityConnectionTable.vue
...lModel/modelDetail/entityDetail/entityConnectionTable.vue
+11
-1
entityData.ts
...nning/logicalModel/modelDetail/entityDetail/entityData.ts
+4
-0
propertyTabel.vue
...g/logicalModel/modelDetail/entityDetail/propertyTabel.vue
+31
-3
entityTable.vue
...arehousePlanning/logicalModel/modelDetail/entityTable.vue
+37
-2
index.vue
.../dataWarehousePlanning/logicalModel/modelDetail/index.vue
+29
-3
modelData.ts
...taWarehousePlanning/logicalModel/modelDetail/modelData.ts
+6
-0
modelEdit.vue
src/views/dataWarehousePlanning/logicalModel/modelEdit.vue
+1
-1
No files found.
src/views/dataSecurity/sensitiveRules/index.vue
View file @
fd865fd2
...
...
@@ -56,7 +56,7 @@ const [registerModal, { openModal }] = useModal();
const
[
registerResetPassword
,
{
openModal
:
openResetPasswordModal
}]
=
useModal
();
const
[
registerImport
,
{
openModal
:
openImportModal
}]
=
useModal
();
const
searchInfo
=
reactive
<
Recordable
>
({});
const
[
registerTable
,
{
reload
,
updateTableDataRecord
,
getSearchInfo
,
getForm
,
getRowSelection
}]
=
useTable
({
const
[
registerTable
,
{
reload
,
updateTableDataRecord
,
getSearchInfo
,
getForm
,
getRowSelection
}]
=
useTable
({
title
:
'敏感规则'
,
api
:
async
(
params
)
=>
{
console
.
log
(
params
)
...
...
src/views/dataWarehousePlanning/logicalModel/importModel.vue
0 → 100644
View file @
fd865fd2
<
template
>
<BasicModal
width=
"40%"
v-bind=
"$attrs"
@
register=
"registerModal"
:title=
"getTitle"
@
ok=
"handleSubmit"
>
<BasicForm
@
register=
"registerForm"
>
<template
#
fileMethods=
"
{ model, field }">
<div
style=
"display: flex"
>
<div>
<a-button>
下载模板
</a-button>
<a-button
type=
"primary"
style=
"margin-left: 5px"
>
选择文件
</a-button>
</div>
<div
style=
"width: 200px; margin-top: -6px; margin-left: 5px"
>
只能导入单个Excel文件,且单次导入不超过100000条数据
</div
>
</div>
</
template
>
</BasicForm>
</BasicModal>
</template>
<
script
lang=
"ts"
setup
>
import
{
ref
,
unref
}
from
'vue'
;
import
{
BasicModal
,
useModalInner
}
from
'@/components/Modal'
;
import
{
BasicForm
,
useForm
}
from
'@/components/Form'
;
import
{
importFormSchema
,
modelFormSchema
}
from
'./model.data'
;
const
emit
=
defineEmits
([
'success'
,
'register'
]);
const
isUpdate
=
ref
(
true
);
const
isMove
=
ref
(
false
);
const
rowId
=
ref
(
''
);
//获取接口数据并放在下拉框里(这里是打开了一个弹框)
//初始化表单
const
[
registerForm
,
{
setFieldsValue
,
updateSchema
,
resetFields
,
validate
}]
=
useForm
({
labelWidth
:
100
,
baseColProps
:
{
lg
:
12
,
md
:
24
},
schemas
:
importFormSchema
,
showActionButtonGroup
:
false
,
actionColOptions
:
{
span
:
23
,
},
});
//初始化弹框
const
[
registerModal
,
{
setModalProps
,
closeModal
}]
=
useModalInner
(
async
(
data
)
=>
{
resetFields
();
setModalProps
({
confirmLoading
:
false
});
isUpdate
.
value
=
!!
data
?.
isUpdate
;
isMove
.
value
=
!!
data
?.
isMove
;
if
(
unref
(
isUpdate
))
{
// 获取行数据的id
rowId
.
value
=
data
.
record
.
businessId
;
// 塞值
setFieldsValue
({
...
data
.
record
,
});
}
});
// const getTitle = computed(() => '新建文件');
const
getTitle
=
'导入逻辑模型'
;
/**确定按钮*/
async
function
handleSubmit
()
{
closeModal
();
}
</
script
>
src/views/dataWarehousePlanning/logicalModel/index.vue
View file @
fd865fd2
...
...
@@ -4,35 +4,25 @@
<BasicTable
@
register=
"registerTable"
class=
"w-3/4 xl:w-4/5"
:searchInfo=
"searchInfo"
>
<template
#
toolbar
>
<a-button
type=
"primary"
@
click=
"handleVersion"
>
转换记录
</a-button>
<a-button
type=
"primary"
>
转物理模型
</a-button>
<a-button
type=
"primary"
>
设为待发布
</a-button>
<a-button
type=
"primary"
>
发布
</a-button>
<a-button
type=
"primary"
@
click=
"handleImport"
>
导入
</a-button>
<a-button
type=
"primary"
:disabled=
"getRowSelection().selectedRowKeys
<
=
0
"
@
click=
"handleTurnPhy"
>
转物理模型
</a-button>
<a-button
type=
"primary"
:disabled=
"getRowSelection().selectedRowKeys
<
=
0
"
@
click=
"handleWaitUpload"
>
设为待发布
</a-button>
<a-button
type=
"primary"
:disabled=
"getRowSelection().selectedRowKeys
<
=
0
"
>
发布
</a-button>
<a-button
type=
"primary"
:disabled=
"getRowSelection().selectedRowKeys
<
=
0
"
@
click=
"handleImport"
>
导入
</a-button>
<a-button
type=
"primary"
@
click=
"handleExport"
>
导出
</a-button>
<a-button
type=
"primary"
@
click=
"handleCreateFile"
>
新建文件夹
</a-button>
<a-button
type=
"primary"
@
click=
"handleCreateModel"
>
新建文件
</a-button>
<a-button
type=
"primary"
>
删除
</a-button>
<a-button
type=
"primary"
:disabled=
"getRowSelection().selectedRowKeys
<
=
0
"
@
click=
"handleDelete"
>
删除
</a-button>
</
template
>
<
template
#
bodyCell=
"{ column, record }"
>
<template
v-if=
"column.key === 'action'"
>
<TableAction
:actions=
"[
{
// icon: 'clarity:note-edit-line',
label: '编辑',
icon: 'clarity:note-edit-line',
onClick: handleEdit.bind(null, record),
},
{
color: 'error',
label: '删除',
popConfirm: {
title: '是否确认删除',
placement: 'left',
confirm: handleDelete.bind(null, record),
},
},
{
label: '移动',
icon: 'ion:ellipsis-horizontal-outline',
onClick: handleMove.bind(null, record),
},
]"
...
...
@@ -45,6 +35,8 @@
</BasicTable>
<ModelModal
@
register=
"registerModal"
@
success=
"handleSuccess"
/>
<ModelEdit
@
register=
"registerModelEdit"
@
success=
"handleSuccess"
/>
<ImportModel
@
register=
"importModel"
@
success=
"handleSuccess"
/>
<TurnPhysicalModel
@
register=
"turnPhysicalModel"
@
success=
"handleSuccess"
/>
</PageWrapper>
</template>
<
script
lang=
"ts"
setup
>
...
...
@@ -61,17 +53,21 @@
import
{
useGo
}
from
'@/hooks/web/usePage'
;
import
{
useFilterStore
}
from
'@/store/modules/filterData'
;
import
{
TreeData
}
from
'@/views/dataWarehousePlanning/logicalModel/modelData'
;
import
ImportModel
from
'./importModel.vue'
;
import
TurnPhysicalModel
from
'@/views/dataWarehousePlanning/logicalModel/modelDetail/turnPhysicalModel.vue'
;
defineOptions
({
name
:
'AccountManagement'
});
const
{
createMessage
}
=
useMessage
();
const
{
createMessage
,
createConfirm
}
=
useMessage
();
const
filterStore
=
useFilterStore
();
const
route
=
useRoute
();
const
go
=
useGo
();
const
{
push
}
=
useRouter
();
const
[
registerModal
,
{
openModal
}]
=
useModal
();
const
[
registerModelEdit
,
{
openModal
:
openEditUserModal
}]
=
useModal
();
const
[
importModel
,
{
openModal
:
openImportModel
}]
=
useModal
();
const
[
registerAddUserModal
,
{
openModal
:
addUserModal
}]
=
useModal
();
const
[
registerMoveUser
,
{
openModal
:
openMoveUserModal
}]
=
useModal
();
const
[
turnPhysicalModel
,
{
openModal
:
openTurnPhysicalModel
}]
=
useModal
();
const
searchInfo
=
reactive
<
Recordable
>
({});
const
tableData
=
ref
([]);
const
[
...
...
@@ -99,6 +95,7 @@
rowKey
:
'businessId'
,
columns
,
rowSelection
:
true
,
striped
:
false
,
formConfig
:
{
labelWidth
:
120
,
schemas
:
searchFormSchema
,
...
...
@@ -134,6 +131,30 @@
});
}
/**
* 转物理模型
*/
function
handleTurnPhy
()
{
openTurnPhysicalModel
(
true
,
{
isUpdate
:
false
,
});
}
/**
* 设为待发布
*/
function
handleWaitUpload
()
{
createConfirm
({
iconType
:
'success'
,
title
:
'设为待发布成功'
,
okText
:
'发布'
,
content
:
'设为待发布成功,是否选择发布?'
,
onOk
()
{
createMessage
.
success
(
'发布成功!'
);
},
});
}
/** 移动按钮*/
function
handleMove
(
record
:
Recordable
)
{
openMoveUserModal
(
true
,
{
...
...
@@ -150,14 +171,25 @@
});
}
/**
* 导入
*/
function
handleImport
()
{
openImportModel
(
true
,
{
isUpdate
:
false
,
});
}
/** 删除按钮*/
function
handleDelete
(
record
:
Recordable
)
{
tableData
.
value
.
splice
(
tableData
.
value
.
findIndex
((
item
)
=>
item
.
businessId
===
record
.
businessId
),
1
,
);
createMessage
.
success
(
'删除成功!'
);
reload
();
function
handleDelete
()
{
createConfirm
({
iconType
:
'warning'
,
title
:
'确认删除'
,
content
:
'确认批量删除选中数据吗?'
,
onOk
()
{
createMessage
.
success
(
'批量删除成功!'
);
},
});
}
/** 新增/编辑成功*/
...
...
src/views/dataWarehousePlanning/logicalModel/model.data.ts
View file @
fd865fd2
...
...
@@ -168,3 +168,45 @@ export const MoveFormSchema: any[] = [
required
:
true
,
},
];
export
const
importFormSchema
:
any
[]
=
[
{
field
:
'fileType'
,
label
:
'导入文件类型'
,
component
:
'Select'
,
colProps
:
{
lg
:
24
,
md
:
24
},
componentProps
:
{
options
:
[
{
label
:
'Erwin(.xml)'
,
value
:
'1'
},
{
label
:
'PowerDesigner(.ldm)'
,
value
:
'2'
},
{
label
:
'Excel(.xlsx)'
,
value
:
'3'
},
],
},
},
{
field
:
'filePath'
,
label
:
'路径'
,
component
:
'Input'
,
colProps
:
{
lg
:
24
,
md
:
24
},
},
{
field
:
'fileMethods'
,
label
:
'导入文件选择'
,
slot
:
'fileMethods'
,
colProps
:
{
lg
:
24
,
md
:
24
},
},
{
field
:
'fileRename'
,
label
:
'文件重名'
,
component
:
'RadioGroup'
,
required
:
true
,
colProps
:
{
lg
:
24
,
md
:
24
},
componentProps
:
{
options
:
[
{
label
:
'全部放弃'
,
value
:
'1'
},
{
label
:
'全部替换'
,
value
:
'2'
},
{
label
:
'自动重命名'
,
value
:
'3'
},
],
},
},
];
src/views/dataWarehousePlanning/logicalModel/modelDetail/ERchart/index.vue
View file @
fd865fd2
...
...
@@ -8,7 +8,7 @@
<
template
#
footer
>
<div
style=
"display: flex"
>
<div
style=
"flex: 1"
>
<BasicTree
search=
"true"
:treeData=
"chartTreeData"
/>
<BasicTree
search=
"true"
:treeData=
"chartTreeData"
defaultExpandLevel=
"1"
/>
</div>
<div
style=
"flex: 4"
>
<img
src=
"../../../../../assets/images/ERchart.jpg"
class=
"erchart-img"
/>
...
...
src/views/dataWarehousePlanning/logicalModel/modelDetail/connectionTable.vue
View file @
fd865fd2
...
...
@@ -3,7 +3,7 @@
<span
class=
"table-title"
style=
"font-size: 18px; margin: 12px 10px 0"
>
实体关联关系
</span>
<BasicTable
@
register=
"registerTable"
:searchInfo=
"searchInfo"
>
<template
#
toolbar
>
<a-button
type=
"primary"
v-if=
"editFlag
"
>
批量删除
</a-button>
<a-button
:disabled=
"getRowSelection().selectedRowKeys
<
=
0
"
type=
"primary"
v-if=
"editFlag"
@
click=
"handleDelete
"
>
批量删除
</a-button>
<a-button
type=
"primary"
v-if=
"editFlag"
@
click=
"handleConnectionModel"
>
新建关联
</a-button>
</
template
>
<
template
#
bodyCell=
"{ column, record }"
>
...
...
@@ -20,6 +20,11 @@
{
// 删除
icon: 'ant-design:delete-outlined',
popConfirm: {
title: '是否确认删除',
placement: 'left',
confirm: handleRemove.bind(null, record),
},
color: 'error',
},
]
...
...
@@ -40,10 +45,12 @@
import
{
useFilterStore
}
from
'@/store/modules/filterData'
;
import
{
TreeData
}
from
'@/views/dataWarehousePlanning/logicalModel/modelData'
;
import
{
connectionData
}
from
'@/views/dataWarehousePlanning/logicalModel/modelDetail/modelData'
;
import
{
useMessage
}
from
'@/hooks/web/useMessage'
;
import
{
useModal
}
from
'@/components/Modal'
;
import
ConnectionModel
from
'./connectionModel.vue'
;
defineOptions
({
name
:
'AccountManagement'
});
const
{
createMessage
,
createConfirm
}
=
useMessage
();
const
props
=
defineProps
({
editFlag
:
Boolean
,
});
...
...
@@ -102,6 +109,7 @@
// 列
columns
:
connectionTable
,
rowSelection
:
true
,
striped
:
false
,
// 搜索
formConfig
:
{
labelWidth
:
120
,
...
...
@@ -121,6 +129,21 @@
},
});
/** 删除按钮*/
function
handleDelete
()
{
createConfirm
({
iconType
:
'warning'
,
title
:
'确认删除'
,
content
:
'确认批量删除选中数据吗?'
,
onOk
()
{
createMessage
.
success
(
'批量删除成功!'
);
},
});
}
/** 列表删除 */
function
handleRemove
(
record
)
{
createMessage
.
success
(
'删除成功!'
);
}
onMounted
(()
=>
{
tableData
.
value
=
TreeData
;
const
path
=
route
.
path
;
...
...
src/views/dataWarehousePlanning/logicalModel/modelDetail/crossTable.vue
View file @
fd865fd2
...
...
@@ -2,7 +2,7 @@
<div>
<BasicTable
@
register=
"registerTable"
:searchInfo=
"searchInfo"
>
<template
#
toolbar
>
<a-button
type=
"primary
"
><DeleteTwoTone
/>
批量删除
</a-button>
<a-button
:disabled=
"getRowSelection().selectedRowKeys
<
=
0
"
type=
"primary"
@
click=
"handleDelete
"
><DeleteTwoTone
/>
批量删除
</a-button>
<a-button
type=
"primary"
@
click=
"handleCrossModel"
><PlusCircleTwoTone
/>
新增关联关系
</a-button
>
...
...
@@ -17,6 +17,11 @@
},
{
icon: 'ant-design:delete-outlined',
popConfirm: {
title: '是否确认删除',
placement: 'left',
confirm: handleRemove.bind(null, record),
},
color: 'error',
},
]"
...
...
@@ -38,8 +43,10 @@
import
{
DeleteTwoTone
,
PlusCircleTwoTone
}
from
'@ant-design/icons-vue'
;
import
CrossModel
from
'./crossModel.vue'
;
import
{
useModal
}
from
'@/components/Modal'
;
import
{
useMessage
}
from
"@/hooks/web/useMessage"
;
defineOptions
({
name
:
'AccountManagement'
});
const
{
createMessage
,
createConfirm
}
=
useMessage
();
const
filterStore
=
useFilterStore
();
const
route
=
useRoute
();
const
searchInfo
=
reactive
<
Recordable
>
({});
...
...
@@ -94,6 +101,7 @@
// 列
columns
:
crossTable
,
rowSelection
:
true
,
striped
:
false
,
// 搜索
formConfig
:
{
labelWidth
:
120
,
...
...
@@ -112,7 +120,21 @@
dataIndex
:
'action'
,
},
});
/** 删除按钮*/
function
handleDelete
()
{
createConfirm
({
iconType
:
'warning'
,
title
:
'确认删除'
,
content
:
'确认批量删除选中数据吗?'
,
onOk
()
{
createMessage
.
success
(
'批量删除成功!'
);
},
});
}
/** 列表删除 */
function
handleRemove
(
record
)
{
createMessage
.
success
(
'删除成功!'
);
}
onMounted
(()
=>
{
tableData
.
value
=
TreeData
;
const
path
=
route
.
path
;
...
...
src/views/dataWarehousePlanning/logicalModel/modelDetail/entityDetail/entityConnectionTable.vue
View file @
fd865fd2
...
...
@@ -17,6 +17,11 @@
{
// 删除
icon: 'ant-design:delete-outlined',
popConfirm: {
title: '是否确认删除',
placement: 'left',
confirm: handleRemove.bind(null, record),
},
color: 'error',
},
]"
...
...
@@ -40,8 +45,10 @@
}
from
'@/views/dataWarehousePlanning/logicalModel/modelDetail/entityDetail/enetity.data'
;
import
{
entityConnectionData
}
from
'@/views/dataWarehousePlanning/logicalModel/modelDetail/entityDetail/entityData'
;
import
EntityConnectionModel
from
'./entityConnectionModel.vue'
;
import
{
useMessage
}
from
'@/hooks/web/useMessage'
;
defineOptions
({
name
:
'AccountManagement'
});
const
{
createMessage
,
createConfirm
}
=
useMessage
();
const
filterStore
=
useFilterStore
();
const
route
=
useRoute
();
const
searchInfo
=
reactive
<
Recordable
>
({});
...
...
@@ -108,7 +115,10 @@
dataIndex
:
'action'
,
},
});
/** 列表删除 */
function
handleRemove
(
record
)
{
createMessage
.
success
(
'删除成功!'
);
}
onMounted
(()
=>
{
tableData
.
value
=
TreeData
;
const
path
=
route
.
path
;
...
...
src/views/dataWarehousePlanning/logicalModel/modelDetail/entityDetail/entityData.ts
View file @
fd865fd2
export
const
propertyData
:
any
[]
=
[
{
businessId
:
'1'
,
propName
:
'业务日'
,
fieldName
:
'biz_date'
,
dataType
:
'varchar'
,
...
...
@@ -14,6 +15,7 @@ export const propertyData: any[] = [
describe
:
'1'
,
},
{
businessId
:
'2'
,
propName
:
'前结算价'
,
fieldName
:
'last_clear_price'
,
dataType
:
'decimal'
,
...
...
@@ -28,6 +30,7 @@ export const propertyData: any[] = [
describe
:
'1'
,
},
{
businessId
:
'3'
,
propName
:
'合约号'
,
fieldName
:
'contract_id'
,
dataType
:
'varchar'
,
...
...
@@ -42,6 +45,7 @@ export const propertyData: any[] = [
describe
:
'1'
,
},
{
businessId
:
'4'
,
propName
:
'结算价'
,
fieldName
:
'clear_price'
,
dataType
:
'decimal'
,
...
...
src/views/dataWarehousePlanning/logicalModel/modelDetail/entityDetail/propertyTabel.vue
View file @
fd865fd2
...
...
@@ -3,7 +3,7 @@
<span
class=
"table-title"
style=
"font-size: 18px; margin: 12px 10px 0"
>
属性
</span>
<BasicTable
@
register=
"registerTable"
:searchInfo=
"searchInfo"
>
<template
#
toolbar
>
<a-button
type=
"primary"
><DeleteTwoTone
/>
批量删除
</a-button>
<a-button
type=
"primary"
@
click=
"handleDelete"
><DeleteTwoTone
/>
批量删除
</a-button>
<a-button
type=
"primary"
@
click=
"handlePropertyModel"
><PlusCircleTwoTone
/>
新建属性
</a-button
>
...
...
@@ -28,6 +28,11 @@
},
{
icon: 'ant-design:delete-outlined',
popConfirm: {
title: '是否确认删除',
placement: 'left',
confirm: handleRemove.bind(null, record),
},
color: 'error',
},
]"
...
...
@@ -42,7 +47,7 @@
import
{
reactive
,
onMounted
,
ref
}
from
'vue'
;
import
{
BasicTable
,
useTable
,
TableAction
}
from
'@/components/Table'
;
import
{
useRoute
,
onBeforeRouteLeave
}
from
'vue-router'
;
import
{
propertyFormSchema
,
propertyTable
}
from
'./enetity.data'
;
import
{
entityConnectionFormSchema
,
propertyFormSchema
,
propertyTable
}
from
'./enetity.data'
;
import
{
useFilterStore
}
from
'@/store/modules/filterData'
;
import
{
TreeData
}
from
'@/views/dataWarehousePlanning/logicalModel/modelData'
;
import
{
crossData
}
from
'@/views/dataWarehousePlanning/logicalModel/modelDetail/modelData'
;
...
...
@@ -50,8 +55,10 @@
import
{
useModal
}
from
'@/components/Modal'
;
import
{
propertyData
}
from
'@/views/dataWarehousePlanning/logicalModel/modelDetail/entityDetail/entityData'
;
import
PropertyModel
from
'./propertyModel.vue'
;
import
{
useMessage
}
from
'@/hooks/web/useMessage'
;
defineOptions
({
name
:
'AccountManagement'
});
const
{
createMessage
,
createConfirm
}
=
useMessage
();
const
filterStore
=
useFilterStore
();
const
route
=
useRoute
();
const
searchInfo
=
reactive
<
Recordable
>
({});
...
...
@@ -114,13 +121,34 @@
handleSearchInfoFn
(
info
)
{
return
info
;
},
// 搜索
formConfig
:
{
labelWidth
:
120
,
schemas
:
propertyFormSchema
,
autoSubmitOnEnter
:
true
,
},
actionColumn
:
{
width
:
150
,
title
:
'操作'
,
dataIndex
:
'action'
,
},
});
/** 删除按钮*/
function
handleDelete
()
{
createConfirm
({
iconType
:
'warning'
,
title
:
'确认删除'
,
content
:
'确认批量删除选中数据吗?'
,
onOk
()
{
createMessage
.
success
(
'删除成功!'
);
reload
();
},
});
}
/** 列表删除 */
function
handleRemove
(
record
)
{
createMessage
.
success
(
'删除成功!'
);
}
onMounted
(()
=>
{
tableData
.
value
=
TreeData
;
const
path
=
route
.
path
;
...
...
src/views/dataWarehousePlanning/logicalModel/modelDetail/entityTable.vue
View file @
fd865fd2
...
...
@@ -3,8 +3,8 @@
<span
class=
"table-title"
style=
"font-size: 18px; margin: 12px 10px 0"
>
实体信息
</span>
<BasicTable
@
register=
"registerTable"
:searchInfo=
"searchInfo"
>
<template
#
toolbar
>
<a-button
type=
"primary"
v-if=
"editFlag"
>
编辑ER图
</a-button>
<a-button
type=
"primary"
v-if=
"editFlag
"
>
批量删除
</a-button>
<a-button
type=
"primary"
v-if=
"editFlag"
@
click=
"handleChart"
>
编辑ER图
</a-button>
<a-button
type=
"primary"
:disabled=
"getRowSelection().selectedRowKeys
<
=
0
"
v-if=
"editFlag"
@
click=
"handleDelete
"
>
批量删除
</a-button>
<a-button
type=
"primary"
v-if=
"editFlag"
@
click=
"handleEntityModel"
>
新建实体
</a-button>
</
template
>
<
template
#
bodyCell=
"{ column, record }"
>
...
...
@@ -20,6 +20,11 @@
{
// 删除
icon: 'ant-design:delete-outlined',
popConfirm: {
title: '是否确认删除',
placement: 'left',
confirm: handleRemove.bind(null, record),
},
color: 'error',
},
]
...
...
@@ -47,9 +52,11 @@
import
{
entityData
}
from
'@/views/dataWarehousePlanning/logicalModel/modelDetail/modelData'
;
import
EntityModel
from
'./entityModel.vue'
;
import
{
useModal
}
from
'@/components/Modal'
;
import
{
useMessage
}
from
'@/hooks/web/useMessage'
;
const
{
push
}
=
useRouter
();
defineOptions
({
name
:
'AccountManagement'
});
const
{
createMessage
,
createConfirm
}
=
useMessage
();
const
props
=
defineProps
({
editFlag
:
Boolean
,
});
...
...
@@ -109,6 +116,7 @@
// 列
columns
:
entityColumns
,
rowSelection
:
true
,
striped
:
false
,
// 搜索
formConfig
:
{
labelWidth
:
120
,
...
...
@@ -127,7 +135,34 @@
dataIndex
:
'action'
,
},
});
/** 删除按钮*/
function
handleDelete
()
{
createConfirm
({
iconType
:
'warning'
,
title
:
'确认删除'
,
content
:
'确认批量删除选中数据吗?'
,
onOk
()
{
createMessage
.
success
(
'批量删除成功!'
);
},
});
}
/**
* er图
*/
function
handleChart
()
{
push
({
path
:
'/dataWarehousePlanning/logicalModel/ERchart'
,
});
}
/**
* 列表删除
* @param record
*/
function
handleRemove
(
record
)
{
createMessage
.
success
(
'删除成功!'
);
}
onMounted
(()
=>
{
tableData
.
value
=
TreeData
;
const
path
=
route
.
path
;
...
...
src/views/dataWarehousePlanning/logicalModel/modelDetail/index.vue
View file @
fd865fd2
...
...
@@ -10,8 +10,8 @@
>
<a-button
type=
"primary"
v-if=
"!editFlag"
@
click=
"handleExport"
>
导出
</a-button>
<a-button
type=
"primary"
v-if=
"!editFlag"
@
click=
"handleEdit"
>
编辑
</a-button>
<a-button
type=
"primary"
v-if=
"!editFlag"
>
删除
</a-button>
<a-button
type=
"primary"
v-if=
"editFlag"
>
设为待发布
</a-button>
<a-button
type=
"primary"
v-if=
"!editFlag"
@
click=
"handleDelete"
>
删除
</a-button>
<a-button
type=
"primary"
v-if=
"editFlag"
@
click=
"handleWaitUpload"
>
设为待发布
</a-button>
<a-button
type=
"primary"
v-if=
"editFlag"
>
发布
</a-button>
<a-button
type=
"primary"
v-if=
"editFlag"
@
click=
"handleSave"
>
保存
</a-button>
<a-button
type=
"primary"
v-if=
"editFlag"
@
click=
"handleCancel"
>
取消
</a-button>
...
...
@@ -119,7 +119,9 @@
import
{
RollbackOutlined
}
from
'@ant-design/icons-vue'
;
import
TurnPhysicalModel
from
'./turnPhysicalModel.vue'
;
import
VersionDetailModel
from
'./versionModel.vue'
;
import
{
useMessage
}
from
'@/hooks/web/useMessage'
;
const
{
createMessage
,
createConfirm
}
=
useMessage
();
const
[
turnPhysicalModal
,
{
openModal
:
turnPhysical
}]
=
useModal
();
const
[
versionDetailModal
,
{
openModal
:
versionDetail
}]
=
useModal
();
const
{
push
}
=
useRouter
();
...
...
@@ -250,7 +252,31 @@
});
console
.
log
(
'被调用'
,
editFlag
);
}
/** 删除按钮*/
function
handleDelete
()
{
createConfirm
({
iconType
:
'warning'
,
title
:
'确认删除'
,
content
:
'确认删除当前模型吗?'
,
onOk
()
{
createMessage
.
success
(
'删除成功!'
);
},
});
}
/**
* 设为待发布
*/
function
handleWaitUpload
()
{
createConfirm
({
iconType
:
'success'
,
title
:
'设为待发布成功'
,
okText
:
'发布'
,
content
:
'设为待发布成功,是否选择发布?'
,
onOk
()
{
createMessage
.
success
(
'发布成功!'
);
},
});
}
/**
* 保存
*/
...
...
src/views/dataWarehousePlanning/logicalModel/modelDetail/modelData.ts
View file @
fd865fd2
...
...
@@ -27,6 +27,7 @@ export const entityData: any[] = [
];
export
const
connectionData
:
any
[]
=
[
{
businessId
:
'1'
,
name
:
'合约_行情'
,
fatherName
:
'dw_合约'
,
fatherPK
:
'合约号'
,
...
...
@@ -36,6 +37,7 @@ export const connectionData: any[] = [
sonNum
:
'1'
,
},
{
businessId
:
'2'
,
name
:
'合约_行情'
,
fatherName
:
'dw_合约'
,
fatherPK
:
'合约号'
,
...
...
@@ -45,6 +47,7 @@ export const connectionData: any[] = [
sonNum
:
'1'
,
},
{
businessId
:
'3'
,
name
:
'合约_行情'
,
fatherName
:
'dw_合约'
,
fatherPK
:
'合约号'
,
...
...
@@ -54,6 +57,7 @@ export const connectionData: any[] = [
sonNum
:
'1'
,
},
{
businessId
:
'4'
,
name
:
'合约_行情'
,
fatherName
:
'dw_合约'
,
fatherPK
:
'合约号'
,
...
...
@@ -63,6 +67,7 @@ export const connectionData: any[] = [
sonNum
:
'1'
,
},
{
businessId
:
'5'
,
name
:
'合约_行情'
,
fatherName
:
'dw_合约'
,
fatherPK
:
'合约号'
,
...
...
@@ -74,6 +79,7 @@ export const connectionData: any[] = [
];
export
const
crossData
:
any
[]
=
[
{
businessId
:
'1'
,
name
:
'合约_行情'
,
fatherModelName
:
'SDM_DM数仓模型'
,
fatherName
:
'dm_会员客户合约盈亏每日深汇'
,
...
...
src/views/dataWarehousePlanning/logicalModel/modelEdit.vue
View file @
fd865fd2
...
...
@@ -52,7 +52,7 @@
}
});
const
getTitle
=
computed
(()
=>
'编辑文件夹'
);
const
getTitle
=
computed
(()
=>
(
isUpdate
.
value
?
'编辑文件夹'
:
'新增文件夹'
)
);
/**确定按钮*/
async
function
handleSubmit
()
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment