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
85c0d722
Commit
85c0d722
authored
Nov 28, 2024
by
liwei
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/master'
parents
601cbca4
506faa35
Changes
7
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
1759 additions
and
6 deletions
+1759
-6
dataLakePunctual.data.ts
...dataIntegration/dataLakePunctual/dataLakePunctual.data.ts
+120
-0
getMetadataModal.vue
...ews/dataIntegration/dataLakePunctual/getMetadataModal.vue
+140
-0
index.vue
src/views/dataIntegration/dataLakePunctual/index.vue
+913
-0
mock.ts
src/views/dataIntegration/dataLakePunctual/mock.ts
+370
-0
data.ts
src/views/realTimeSync/dataBaseToDataBase/data.ts
+28
-0
dataBaseData.ts
src/views/realTimeSync/dataBaseToDataBase/dataBaseData.ts
+4
-0
optionPage.vue
src/views/realTimeSync/dataBaseToDataBase/optionPage.vue
+184
-6
No files found.
src/views/dataIntegration/dataLakePunctual/dataLakePunctual.data.ts
0 → 100644
View file @
85c0d722
import
{
BasicColumn
,
FormSchema
}
from
"@/components/Table"
;
/**源端配置-left-表单 */
export
const
sourceSideConfigurationFormSchema
:
FormSchema
[]
=
[
{
field
:
'logParser'
,
label
:
'日志解析器'
,
component
:
'RadioGroup'
,
defaultValue
:
'1'
,
componentProps
:
({
formModel
,
formActionType
})
=>
({
onChange
:
()
=>
{
loadType
.
value
=
formModel
.
loadType
;
},
options
:
[
{
label
:
'Canal'
,
value
:
'1'
},
{
label
:
'OGG'
,
value
:
'2'
},
],
}),
},
{
field
:
'metadataAcquisitionMode'
,
label
:
'元数据获取方式'
,
component
:
'RadioGroup'
,
defaultValue
:
'从JDBC获取元数据'
,
show
:
({
model
})
=>
{
return
model
.
logParser
===
'2'
;
},
// show: false,
componentProps
:
({
formModel
,
formActionType
})
=>
({
options
:
[
{
label
:
'从JDBC获取元数据'
,
value
:
'从JDBC获取元数据'
},
// { label: '自定义SQL', value: '自定义SQL' },
{
label
:
'导入元数据文件'
,
value
:
'导入元数据文件'
},
],
}),
},
{
field
:
'dataSource'
,
label
:
'数据源'
,
component
:
'Select'
,
required
:
true
,
defaultValue
:
[],
componentProps
:
{
placeholder
:
'请选择数据源'
,
options
:
[
{
label
:
'KunOB数据源'
,
value
:
'KunOB数据源'
},
{
label
:
'MongoDB数据源'
,
value
:
'MongoDB数据源'
},
{
label
:
'AmazonS3'
,
value
:
'AmazonS3'
},
],
},
},
{
field
:
'dataBase'
,
label
:
'数据库'
,
component
:
'Cascader'
,
required
:
true
,
componentProps
:
{
placeholder
:
'请选择数据源'
,
displayRender
:
({
labels
})
=>
{
return
labels
[
labels
.
length
-
1
];
},
options
:
[
{
value
:
'数据库对象资源'
,
label
:
'数据库对象资源'
,
children
:
[
{
value
:
'数据中台工作区01'
,
label
:
'数据中台工作区01'
,
children
:
[
{
value
:
'ArgoDB_Dev01'
,
label
:
'ArgoDB_Dev01'
,
},
{
value
:
'ArgoDB_Dev02'
,
label
:
'ArgoDB_Dev02'
,
},
{
value
:
'GbaseDB_Dev01'
,
label
:
'GbaseDB_Dev01'
,
},
],
},
],
},
],
},
},
{
field
:
'getMetadata'
,
label
:
' '
,
component
:
'Slot'
,
slot
:
'getMetadata'
,
},
];
/**源端配置-获取元数据按钮(弹窗)-字段名 */
export
const
getMetadataColumns
:
BasicColumn
[]
=
[
{
title
:
'表名'
,
dataIndex
:
'tableName'
,
},
];
/**源端配置-右-列表字段配置 */
export
const
notCustomSQLColumns
:
BasicColumn
[]
=
[
{
title
:
'列名'
,
dataIndex
:
'fieldName'
,
},
{
title
:
'类型'
,
dataIndex
:
'fieldType'
,
},
];
src/views/dataIntegration/dataLakePunctual/getMetadataModal.vue
0 → 100644
View file @
85c0d722
<
template
>
<BasicModal
v-bind=
"$attrs"
@
register=
"registerModal"
title=
"获取元数据"
@
ok=
"handleSubmit"
minHeight=
"50"
>
<div
style=
"display: flex; justify-content: space-between"
>
<a-input-search
style=
"width: 220px"
@
search=
"onSearch"
/>
<a-button
@
click=
"handleClick"
>
通过序号批量选择
<Icon
v-if=
"unfold"
icon=
"fe:arrow-up"
/>
<Icon
v-else
icon=
"fe:arrow-down"
/>
</a-button>
</div>
<div
v-if=
"unfold"
style=
"margin-top: 5px"
>
从
<a-input
v-model:value=
"startId"
class=
"getMetadataInput"
style=
"margin-right: 10px; margin-left: 10px"
/>
到
<a-input
v-model:value=
"endId"
class=
"getMetadataInput"
style=
"margin-right: 10px; margin-left: 10px"
/>
<a-button
@
click=
"handleSelect"
style=
"margin-right: 10px"
>
选择
</a-button>
<a-button
@
click=
"handleResetInputs"
style=
"margin-right: 10px"
>
清空
</a-button>
</div>
<BasicTable
@
register=
"registerTable"
/>
</BasicModal>
</
template
>
<
script
lang=
"ts"
setup
>
import
{
ref
}
from
'vue'
;
import
{
BasicTable
,
useTable
}
from
'@/components/Table'
;
import
{
BasicModal
,
useModalInner
}
from
'@/components/Modal'
;
import
{
useMessage
}
from
'@/hooks/web/useMessage'
;
import
{
getMetadataTableList
}
from
'./mock'
import
{
getMetadataColumns
}
from
'./dataLakePunctual.data'
;
import
Icon
from
'@/components/Icon/Icon.vue'
;
const
emit
=
defineEmits
([
'success'
,
'register'
]);
const
{
createMessage
}
=
useMessage
();
const
unfold
=
ref
(
false
);
let
startId
=
ref
();
let
endId
=
ref
();
let
getMetadataTable
=
ref
(
getMetadataTableList
);
const
[
registerTable
,
{
reload
,
getDataSource
,
getRowSelection
,
setSelectedRowKeys
}]
=
useTable
({
api
:
async
()
=>
{
const
response
=
{
pageNu
:
'1'
,
pageSize
:
'5'
,
pages
:
'1'
,
total
:
getMetadataTable
.
value
.
length
,
code
:
''
,
message
:
''
,
data
:
getMetadataTable
.
value
,
};
return
{
...
response
};
},
scroll
:
{
y
:
300
},
rowKey
:
'businessId'
,
rowSelection
:
true
,
columns
:
getMetadataColumns
,
showTableSetting
:
false
,
showIndexColumn
:
true
,
bordered
:
false
,
});
//初始化弹框
const
[
registerModal
,
{
closeModal
}]
=
useModalInner
(
async
()
=>
{});
function
handleClick
()
{
unfold
.
value
=
!
unfold
.
value
;
}
/**确定按钮*/
async
function
handleSubmit
()
{
closeModal
();
}
/**获取元数据-选择按钮*/
function
handleSelect
()
{
const
selectedRowKeys
=
getRowSelection
().
selectedRowKeys
;
const
ids
=
ref
([...
selectedRowKeys
]);
const
dataIds
=
ref
(
getDataSource
());
if
(
startId
.
value
&&
endId
.
value
)
{
for
(
let
i
=
startId
.
value
-
1
;
i
<=
endId
.
value
-
1
&&
i
<
getDataSource
().
length
;
i
++
)
{
const
businessId
=
dataIds
.
value
[
i
].
businessId
;
if
(
!
ids
.
value
.
includes
(
businessId
))
{
ids
.
value
.
push
(
businessId
);
}
}
}
setSelectedRowKeys
(
ids
.
value
);
}
/**获取元数据-清空按钮*/
function
handleResetInputs
()
{
const
selectedRowKeys
=
getRowSelection
().
selectedRowKeys
;
const
ids
=
ref
([...
selectedRowKeys
]);
const
dataIds
=
ref
(
getDataSource
());
if
(
startId
.
value
&&
endId
.
value
)
{
const
startIndex
=
startId
.
value
-
1
;
const
endIndex
=
endId
.
value
-
1
;
// 过滤掉与 i 相等的值
const
filteredIds
=
ids
.
value
.
filter
((
id
)
=>
{
for
(
let
i
=
startIndex
;
i
<=
endIndex
&&
i
<
getDataSource
().
length
;
i
++
)
{
if
(
dataIds
.
value
[
i
].
businessId
===
id
)
{
return
false
;
}
}
return
true
;
});
// // 清空 startId 和 endId
// startId.value = null;
// endId.value = null;
setSelectedRowKeys
(
filteredIds
);
}
}
function
onSearch
(
searchValue
)
{
getMetadataTable
.
value
=
getMetadataTableList
.
filter
((
item
)
=>
item
.
tableName
.
includes
(
searchValue
),
);
reload
();
}
</
script
>
<
style
scoped
lang=
"scss"
>
.getMetadataInput
{
width
:
120px
;
}
</
style
>
src/views/dataIntegration/dataLakePunctual/index.vue
0 → 100644
View file @
85c0d722
This diff is collapsed.
Click to expand it.
src/views/dataIntegration/dataLakePunctual/mock.ts
0 → 100644
View file @
85c0d722
/**源端配置-中间树-表头列表*/
export
const
tableTreeData
=
[
{
title
:
'bm_datasource'
,
key
:
'0'
,
icon
:
'majesticons:table-line'
,
sql
:
'SELECT uuid, catalog_id FROM bm_datasource'
,
},
{
title
:
'user_info'
,
key
:
'1'
,
icon
:
'majesticons:table-line'
,
sql
:
'SELECT uuid, catalog_id, name, description FROM user_info'
,
},
{
title
:
'customer_details'
,
key
:
'2'
,
icon
:
'majesticons:table-line'
,
sql
:
'SELECT uuid, user_id, username, email FROM customer_details'
,
},
{
title
:
'order_history'
,
key
:
'3'
,
icon
:
'majesticons:table-line'
,
sql
:
'SELECT uuid, order_id, total_amount FROM order_history'
,
},
{
title
:
'product_inventory'
,
key
:
'4'
,
icon
:
'majesticons:table-line'
,
sql
:
'SELECT uuid, product_id, product_name, price FROM product_inventory'
,
},
{
title
:
'transaction_logs'
,
key
:
'5'
,
icon
:
'majesticons:table-line'
,
sql
:
'SELECT uuid, category_id, category_name FROM transaction_logs'
,
},
{
title
:
'employee_records'
,
key
:
'6'
,
icon
:
'majesticons:table-line'
,
sql
:
'SELECT uuid, customer_id, customer_name FROM employee_records'
,
},
{
title
:
'payment_details'
,
key
:
'7'
,
icon
:
'majesticons:table-line'
,
sql
:
'SELECT uuid, customer_id, order_date FROM payment_details'
,
},
{
title
:
'shipping_addresses'
,
key
:
'8'
,
icon
:
'majesticons:table-line'
,
sql
:
'SELECT uuid, product_id, stock_quantity, last_updated FROM shipping_addresses'
,
},
{
title
:
'invoice_data'
,
key
:
'9'
,
icon
:
'majesticons:table-line'
,
sql
:
'SELECT uuid, user_id, address, phone_number FROM invoice_data'
,
},
{
title
:
'customer_feedback'
,
key
:
'10'
,
icon
:
'majesticons:table-line'
,
sql
:
'SELECT uuid, category_id, category_description, parent_category_id FROM customer_feedback'
,
},
{
title
:
'supplier_info'
,
key
:
'11'
,
icon
:
'majesticons:table-line'
,
sql
:
'SELECT * FROM supplier_info'
,
// 假设 supplier_info 表没有在 isCustomSQLTableList 中定义字段
},
];
/**源端配置-右列表*/
export
const
notCustomSQLTableList
=
[
// bm_datasource
{
businessId
:
'1'
,
ownershipTableId
:
'0'
,
fieldName
:
'uuid'
,
fieldType
:
'VARCHAR(50,0)'
,
},
{
businessId
:
'2'
,
ownershipTableId
:
'0'
,
fieldName
:
'catalog_id'
,
fieldType
:
'BIGINT(19,0)'
,
},
// user_info
{
businessId
:
'3'
,
ownershipTableId
:
'1'
,
fieldName
:
'user_id'
,
fieldType
:
'INT(11,0)'
,
},
{
businessId
:
'4'
,
ownershipTableId
:
'1'
,
fieldName
:
'username'
,
fieldType
:
'VARCHAR(50,0)'
,
},
{
businessId
:
'5'
,
ownershipTableId
:
'1'
,
fieldName
:
'email'
,
fieldType
:
'VARCHAR(100,0)'
,
},
// customer_details
{
businessId
:
'6'
,
ownershipTableId
:
'2'
,
fieldName
:
'customer_id'
,
fieldType
:
'INT(11,0)'
,
},
{
businessId
:
'7'
,
ownershipTableId
:
'2'
,
fieldName
:
'first_name'
,
fieldType
:
'VARCHAR(50,0)'
,
},
{
businessId
:
'8'
,
ownershipTableId
:
'2'
,
fieldName
:
'last_name'
,
fieldType
:
'VARCHAR(50,0)'
,
},
{
businessId
:
'9'
,
ownershipTableId
:
'2'
,
fieldName
:
'address'
,
fieldType
:
'VARCHAR(255,0)'
,
},
// order_history
{
businessId
:
'10'
,
ownershipTableId
:
'3'
,
fieldName
:
'order_id'
,
fieldType
:
'INT(11,0)'
,
},
{
businessId
:
'11'
,
ownershipTableId
:
'3'
,
fieldName
:
'customer_id'
,
fieldType
:
'INT(11,0)'
,
},
{
businessId
:
'12'
,
ownershipTableId
:
'3'
,
fieldName
:
'order_date'
,
fieldType
:
'DATETIME'
,
},
// product_inventory
{
businessId
:
'13'
,
ownershipTableId
:
'4'
,
fieldName
:
'product_id'
,
fieldType
:
'INT(11,0)'
,
},
{
businessId
:
'14'
,
ownershipTableId
:
'4'
,
fieldName
:
'quantity'
,
fieldType
:
'INT(11,0)'
,
},
{
businessId
:
'15'
,
ownershipTableId
:
'4'
,
fieldName
:
'price'
,
fieldType
:
'DECIMAL(10,2)'
,
},
// transaction_logs
{
businessId
:
'16'
,
ownershipTableId
:
'5'
,
fieldName
:
'log_id'
,
fieldType
:
'INT(11,0)'
,
},
{
businessId
:
'17'
,
ownershipTableId
:
'5'
,
fieldName
:
'transaction_type'
,
fieldType
:
'VARCHAR(50,0)'
,
},
{
businessId
:
'18'
,
ownershipTableId
:
'5'
,
fieldName
:
'amount'
,
fieldType
:
'DECIMAL(10,2)'
,
},
// employee_records
{
businessId
:
'19'
,
ownershipTableId
:
'6'
,
fieldName
:
'employee_id'
,
fieldType
:
'INT(11,0)'
,
},
{
businessId
:
'20'
,
ownershipTableId
:
'6'
,
fieldName
:
'name'
,
fieldType
:
'VARCHAR(100,0)'
,
},
{
businessId
:
'21'
,
ownershipTableId
:
'6'
,
fieldName
:
'position'
,
fieldType
:
'VARCHAR(100,0)'
,
},
// payment_details
{
businessId
:
'22'
,
ownershipTableId
:
'7'
,
fieldName
:
'payment_id'
,
fieldType
:
'INT(11,0)'
,
},
{
businessId
:
'23'
,
ownershipTableId
:
'7'
,
fieldName
:
'payment_method'
,
fieldType
:
'VARCHAR(50,0)'
,
},
{
businessId
:
'24'
,
ownershipTableId
:
'7'
,
fieldName
:
'amount'
,
fieldType
:
'DECIMAL(10,2)'
,
},
// shipping_addresses
{
businessId
:
'25'
,
ownershipTableId
:
'8'
,
fieldName
:
'address_id'
,
fieldType
:
'INT(11,0)'
,
},
{
businessId
:
'26'
,
ownershipTableId
:
'8'
,
fieldName
:
'customer_id'
,
fieldType
:
'INT(11,0)'
,
},
{
businessId
:
'27'
,
ownershipTableId
:
'8'
,
fieldName
:
'address'
,
fieldType
:
'VARCHAR(255,0)'
,
},
// invoice_data
{
businessId
:
'28'
,
ownershipTableId
:
'9'
,
fieldName
:
'invoice_id'
,
fieldType
:
'INT(11,0)'
,
},
{
businessId
:
'29'
,
ownershipTableId
:
'9'
,
fieldName
:
'invoice_date'
,
fieldType
:
'DATETIME'
,
},
{
businessId
:
'30'
,
ownershipTableId
:
'9'
,
fieldName
:
'total_amount'
,
fieldType
:
'DECIMAL(10,2)'
,
},
// customer_feedback
{
businessId
:
'31'
,
ownershipTableId
:
'10'
,
fieldName
:
'feedback_id'
,
fieldType
:
'INT(11,0)'
,
},
{
businessId
:
'32'
,
ownershipTableId
:
'10'
,
fieldName
:
'customer_id'
,
fieldType
:
'INT(11,0)'
,
},
{
businessId
:
'33'
,
ownershipTableId
:
'10'
,
fieldName
:
'feedback_text'
,
fieldType
:
'TEXT'
,
},
// supplier_info
{
businessId
:
'34'
,
ownershipTableId
:
'11'
,
fieldName
:
'supplier_id'
,
fieldType
:
'INT(11,0)'
,
},
{
businessId
:
'35'
,
ownershipTableId
:
'11'
,
fieldName
:
'company_name'
,
fieldType
:
'VARCHAR(100,0)'
,
},
{
businessId
:
'36'
,
ownershipTableId
:
'11'
,
fieldName
:
'contact_person'
,
fieldType
:
'VARCHAR(100,0)'
,
},
];
/**源端配置-获取元数据按钮(弹窗)-列表*/
export
const
getMetadataTableList
=
[
{
tableName
:
'bm_datasource'
,
businessId
:
'0'
,
},
{
tableName
:
'user_info'
,
businessId
:
'1'
,
},
{
tableName
:
'customer_details'
,
businessId
:
'2'
,
},
{
tableName
:
'order_history'
,
businessId
:
'3'
,
},
{
tableName
:
'product_inventory'
,
businessId
:
'4'
,
},
{
tableName
:
'transaction_logs'
,
businessId
:
'5'
,
},
{
tableName
:
'employee_records'
,
businessId
:
'6'
,
},
{
tableName
:
'payment_details'
,
businessId
:
'7'
,
},
{
tableName
:
'shipping_addresses'
,
businessId
:
'8'
,
},
{
tableName
:
'invoice_data'
,
businessId
:
'9'
,
},
{
tableName
:
'customer_feedback'
,
businessId
:
'10'
,
},
{
tableName
:
'supplier_info'
,
businessId
:
'11'
,
},
];
src/views/realTimeSync/dataBaseToDataBase/data.ts
View file @
85c0d722
...
@@ -705,3 +705,31 @@ export const policyOptionFormSchema: FormSchema[] = [
...
@@ -705,3 +705,31 @@ export const policyOptionFormSchema: FormSchema[] = [
},
},
},
},
];
];
export
const
serverOptionsFormSchema
:
FormSchema
[]
=
[
{
field
:
'type'
,
label
:
'存储格式'
,
component
:
'Select'
,
defaultValue
:
'1'
,
componentProps
:
{
options
:
[{
label
:
'JSON'
,
value
:
'1'
}],
},
colProps
:
{
lg
:
6
,
md
:
6
},
},
];
export
const
serverSourceOptionsColumns
:
BasicColumn
[]
=
[
{
title
:
'Key'
,
dataIndex
:
'keyData'
,
edit
:
true
,
editable
:
true
,
width
:
120
,
},
{
title
:
'Value'
,
dataIndex
:
'valueData'
,
edit
:
true
,
editable
:
true
,
width
:
120
,
},
];
src/views/realTimeSync/dataBaseToDataBase/dataBaseData.ts
View file @
85c0d722
...
@@ -1061,3 +1061,7 @@ export const writePolicyData: any[] = [
...
@@ -1061,3 +1061,7 @@ export const writePolicyData: any[] = [
timeInterval
:
'1'
,
timeInterval
:
'1'
,
},
},
];
];
export
const
jsonData
=
`
{
}
`
;
src/views/realTimeSync/dataBaseToDataBase/optionPage.vue
View file @
85c0d722
...
@@ -340,7 +340,83 @@
...
@@ -340,7 +340,83 @@
</BasicForm>
</BasicForm>
</TabPane>
</TabPane>
<TabPane
v-if=
"tabKey === '4'"
key=
"9"
tab=
"服务配置"
>
<TabPane
v-if=
"tabKey === '4'"
key=
"9"
tab=
"服务配置"
>
<!-- <BasicTable>-->
<div
class=
"flex"
>
<div
style=
"width: 50%"
>
<Description
size=
"middle"
title=
"源端配置"
:bordered=
"false"
/>
<BasicForm
@
register=
"registerServerOptionsForm"
/>
<div>
<BasicTable
@
register=
"registerServerSourceOptionsTable"
>
<
template
#
toolbar
>
<a-button
type=
"primary"
@
click=
"addServerSourceOptions"
>
添加参数
</a-button>
</
template
>
<
template
#
bodyCell=
"{ column, record }"
>
<template
v-if=
"column.key === 'action'"
>
<TableAction
:actions=
"[
{
icon: 'ic:outline-delete-outline',
onClick: deleteServerSourceOptions.bind(null, record),
},
]"
/>
</
template
>
</template>
</BasicTable>
</div>
<Description
size=
"middle"
title=
"配置预览"
:bordered=
"false"
>
<
template
#
action
>
<Icon
style=
"font-size: 30px !important"
icon=
"fa6-regular:copy"
@
click=
"handleCopy"
/>
<Icon
style=
"font-size: 30px !important; margin-right: 5px"
icon=
"icon-park-outline:reload"
@
click=
"handleReload"
/>
</
template
>
</Description>
<CodeEditor
v-model:value=
"jsonData"
:mode=
"MODE.JSON"
/>
</div>
<div
style=
"width: 50%"
>
<Description
size=
"middle"
title=
"目标端配置"
:bordered=
"false"
/>
<div>
<BasicTable
@
register=
"registerServerTopicOptionsTable"
>
<
template
#
toolbar
>
<a-button
type=
"primary"
@
click=
"addServerTopicOptions"
>
添加参数
</a-button>
</
template
>
<
template
#
bodyCell=
"{ column, record }"
>
<template
v-if=
"column.key === 'action'"
>
<TableAction
:actions=
"[
{
icon: 'ic:outline-delete-outline',
onClick: deleteServerTopicOptions.bind(null, record),
},
]"
/>
</
template
>
</template>
</BasicTable>
</div>
<Description
size=
"middle"
title=
"配置预览"
:bordered=
"false"
>
<
template
#
action
>
<Icon
style=
"font-size: 30px !important"
icon=
"fa6-regular:copy"
@
click=
"handleCopy"
/>
<Icon
style=
"font-size: 30px !important; margin-right: 5px"
icon=
"icon-park-outline:reload"
@
click=
"handleReload"
/>
</
template
>
</Description>
<CodeEditor
v-model:value=
"jsonData"
:mode=
"MODE.JSON"
/>
</div>
</div>
</TabPane>
</TabPane>
<TabPane
v-if=
"tabKey === '5'"
key=
"10"
tab=
"数据流向"
>
<TabPane
v-if=
"tabKey === '5'"
key=
"10"
tab=
"数据流向"
>
<Img
src=
"src/assets/images/dataDirection.png"
style=
"width: 1800px"
/>
<Img
src=
"src/assets/images/dataDirection.png"
style=
"width: 1800px"
/>
...
@@ -357,7 +433,7 @@
...
@@ -357,7 +433,7 @@
</template>
</template>
<
script
lang=
"ts"
setup
>
<
script
lang=
"ts"
setup
>
import
{
Tabs
,
TabPane
,
Alert
,
Col
,
ListItem
,
List
,
Card
,
Row
}
from
'ant-design-vue'
;
import
{
Tabs
,
TabPane
,
Alert
,
Col
,
ListItem
,
List
,
Card
,
Row
}
from
'ant-design-vue'
;
import
{
ref
,
onMounted
}
from
'vue'
;
import
{
ref
}
from
'vue'
;
import
{
BasicForm
,
FormSchema
,
useForm
}
from
'@/components/Form'
;
import
{
BasicForm
,
FormSchema
,
useForm
}
from
'@/components/Form'
;
import
{
import
{
mappingRuleConfigurationColumns
,
mappingRuleConfigurationColumns
,
...
@@ -374,6 +450,8 @@
...
@@ -374,6 +450,8 @@
tableMappingColumns
,
tableMappingColumns
,
writePolicyColumns
,
writePolicyColumns
,
policyOptionFormSchema
,
policyOptionFormSchema
,
serverOptionsFormSchema
,
serverSourceOptionsColumns
,
}
from
'./data'
;
}
from
'./data'
;
import
Icon
from
'@/components/Icon/Icon.vue'
;
import
Icon
from
'@/components/Icon/Icon.vue'
;
import
{
useMessage
}
from
'@/hooks/web/useMessage'
;
import
{
useMessage
}
from
'@/hooks/web/useMessage'
;
...
@@ -388,6 +466,7 @@
...
@@ -388,6 +466,7 @@
mappingRulesTableData
,
mappingRulesTableData
,
tableMappingData
,
tableMappingData
,
writePolicyData
,
writePolicyData
,
jsonData
,
}
from
'./dataBaseData'
;
}
from
'./dataBaseData'
;
import
{
router
}
from
'@/router'
;
import
{
router
}
from
'@/router'
;
import
{
BasicTable
,
useTable
,
TableAction
}
from
'@/components/Table'
;
import
{
BasicTable
,
useTable
,
TableAction
}
from
'@/components/Table'
;
...
@@ -396,14 +475,17 @@
...
@@ -396,14 +475,17 @@
import
SaveModal
from
'@/views/dataIntegration/dataLoading/dataEntryLake/saveModal.vue'
;
import
SaveModal
from
'@/views/dataIntegration/dataLoading/dataEntryLake/saveModal.vue'
;
import
VersionManageModal
from
'@/views/dataIntegration/dataLoading/dataEntryLake/versionManageModal.vue'
;
import
VersionManageModal
from
'@/views/dataIntegration/dataLoading/dataEntryLake/versionManageModal.vue'
;
import
{
Description
}
from
'@/components/Description'
;
import
{
Description
}
from
'@/components/Description'
;
import
{
CodeEditor
,
MODE
}
from
'@/components/CodeEditor'
;
const
emit
=
defineEmits
([
'success'
,
'register'
]);
const
emit
=
defineEmits
([
'success'
,
'register'
]);
const
{
createMessage
,
createConfirm
}
=
useMessage
();
const
{
createMessage
,
createConfirm
}
=
useMessage
();
const
route
=
useRoute
();
const
route
=
useRoute
();
const
mappingRuleConfigurationTable
=
ref
([]);
const
mappingRuleConfigurationTable
=
ref
([]);
const
kafkaOptionDataTable
=
ref
([]);
const
kafkaOptionDataTable
=
ref
([]);
const
serverSourceOptionsTable
=
ref
([]);
const
serverTopicOptionsTable
=
ref
([]);
const
tabKey
=
ref
(
'1'
);
const
tabKey
=
ref
(
'1'
);
const
n
=
ref
(
'1'
);
const
n
=
ref
(
1
);
const
mappingRulesTableShow
=
ref
(
false
);
const
mappingRulesTableShow
=
ref
(
false
);
const
mappingRulesTopicTableShow
=
ref
(
false
);
const
mappingRulesTopicTableShow
=
ref
(
false
);
const
getMetadataTable
=
ref
(
getMetadataTableList
);
const
getMetadataTable
=
ref
(
getMetadataTableList
);
...
@@ -510,6 +592,16 @@
...
@@ -510,6 +592,16 @@
span
:
23
,
span
:
23
,
},
},
});
});
const
[
registerServerOptionsForm
]
=
useForm
({
labelWidth
:
110
,
labelAlign
:
'left'
,
baseColProps
:
{
lg
:
24
,
md
:
24
},
schemas
:
serverOptionsFormSchema
,
showActionButtonGroup
:
false
,
actionColOptions
:
{
span
:
23
,
},
});
const
[
registerMappingRuleConfigurationTable
,
{
getRowSelection
,
reload
}]
=
useTable
({
const
[
registerMappingRuleConfigurationTable
,
{
getRowSelection
,
reload
}]
=
useTable
({
api
:
async
()
=>
{
api
:
async
()
=>
{
const
response
=
{
const
response
=
{
...
@@ -579,7 +671,54 @@
...
@@ -579,7 +671,54 @@
showIndexColumn
:
false
,
showIndexColumn
:
false
,
scroll
:
{
y
:
500
},
scroll
:
{
y
:
500
},
});
});
const
[
registerServerSourceOptionsTable
,
{
reload
:
reloadServerSourceOptionsTable
}]
=
useTable
({
title
:
'高级配置'
,
api
:
async
()
=>
{
const
response
=
{
pageNu
:
'1'
,
pageSize
:
'5'
,
pages
:
'1'
,
total
:
serverSourceOptionsTable
.
value
.
length
,
code
:
''
,
message
:
''
,
data
:
serverSourceOptionsTable
.
value
,
};
return
{
...
response
};
},
columns
:
serverSourceOptionsColumns
,
pagination
:
true
,
showIndexColumn
:
false
,
actionColumn
:
{
width
:
50
,
title
:
'操作'
,
dataIndex
:
'action'
,
},
scroll
:
{
y
:
200
},
});
const
[
registerServerTopicOptionsTable
,
{
reload
:
reloadServerTopicOptionsTable
}]
=
useTable
({
title
:
'高级配置'
,
api
:
async
()
=>
{
const
response
=
{
pageNu
:
'1'
,
pageSize
:
'5'
,
pages
:
'1'
,
total
:
serverTopicOptionsTable
.
value
.
length
,
code
:
''
,
message
:
''
,
data
:
serverTopicOptionsTable
.
value
,
};
return
{
...
response
};
},
columns
:
serverSourceOptionsColumns
,
pagination
:
true
,
showIndexColumn
:
false
,
actionColumn
:
{
width
:
50
,
title
:
'操作'
,
dataIndex
:
'action'
,
},
scroll
:
{
y
:
200
},
});
const
[
registerTableMappingTable
]
=
useTable
({
const
[
registerTableMappingTable
]
=
useTable
({
dataSource
:
tableMappingData
,
dataSource
:
tableMappingData
,
columns
:
tableMappingColumns
,
columns
:
tableMappingColumns
,
...
@@ -664,12 +803,51 @@
...
@@ -664,12 +803,51 @@
mappingRulesTableShow
.
value
=
true
;
mappingRulesTableShow
.
value
=
true
;
}
}
onMounted
(()
=>
{});
function
addServerSourceOptions
()
{
const
data
=
{
businessId
:
n
.
value
,
keyData
:
''
,
valueData
:
''
,
};
serverSourceOptionsTable
.
value
.
push
(
data
);
n
.
value
++
;
reloadServerSourceOptionsTable
();
}
function
deleteServerSourceOptions
(
record
:
Recordable
)
{
serverSourceOptionsTable
.
value
.
splice
(
serverSourceOptionsTable
.
value
.
findIndex
((
item
)
=>
item
.
businessId
===
record
.
businessId
),
1
,
);
reloadServerSourceOptionsTable
();
}
function
addServerTopicOptions
()
{
const
topicData
=
{
businessId
:
n
.
value
,
keyData
:
''
,
valueData
:
''
,
};
serverTopicOptionsTable
.
value
.
push
(
topicData
);
n
.
value
++
;
reloadServerTopicOptionsTable
();
}
function
deleteServerTopicOptions
(
record
:
Recordable
)
{
serverTopicOptionsTable
.
value
.
splice
(
serverTopicOptionsTable
.
value
.
findIndex
((
item
)
=>
item
.
businessId
===
record
.
businessId
),
1
,
);
reloadServerTopicOptionsTable
();
}
function
handleChangeTab
(
key
)
{
function
handleChangeTab
(
key
)
{
tabKey
.
value
=
key
;
tabKey
.
value
=
key
;
}
}
function
handleCopy
()
{
createMessage
.
success
(
'复制成功'
);
}
function
handleReload
()
{
createMessage
.
success
(
'刷新成功'
);
}
function
goBack
()
{
function
goBack
()
{
router
.
back
();
router
.
back
();
}
}
...
...
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