8e994be3 by xukangle

updata: 分类分级目录模块开发

1 parent 210b5eb5
......@@ -3,8 +3,8 @@ VITE_APP_TITLE = 数据资产管理系统
# 接口域名
# VITE_API_BASEURL = https://www.zgsjzc.com/api
# VITE_API_BASEURL = https://swzl-test.csbr.cn/api
# VITE_API_BASEURL = http://localhost:9000
VITE_API_BASEURL = http://10.4.82.1:28052/
VITE_API_BASEURL = http://localhost:9000
# VITE_API_BASEURL = http://10.4.82.1:28052/
# 平台用户 接口请地址
VITE_APP_USER_API_BASEURL = gateway-server/user
# 系统管理 接口地址
......@@ -25,8 +25,8 @@ VITE_APP_PLAN_BASEURL = ms-daop-jgjf-data-plan-service
VITE_APP_QUALITY_BASEURL = ms-daop-data-quality-service
#数据盘点接口地址ms-daop-zcgl-data-inventory
# VITE_APP_CHECK_BASEURL = /mock
VITE_APP_CHECK_BASEURL = ms-daop-zcgl-data-inventory
VITE_APP_CHECK_BASEURL = /mock
# VITE_APP_CHECK_BASEURL = ms-daop-zcgl-data-inventory
#门户接口
VITE_API_PORTALURL = https://swzl-test.zgsjzc.com/portal
......
......@@ -226,3 +226,45 @@ export const getCgDirFieldPageList = (data) => request({
method: 'post',
data
})
/** 获取字典列表
* VITE_APP_PLAN_BASEURL 为环境变量 现在只是mock数据
*/
export const getDictionary = (params) => request({
url: `${import.meta.env.VITE_APP_CHECK_BASEURL}/data-dictionary-general/list-all?state=1`,
method: 'post'
})
/** 业务规则配置-新增
* @param {Object}
* @path /biz-rule-config/save
*/
export const saveBizRuleConfig = (data) => request({
url: `${import.meta.env.VITE_APP_CHECK_BASEURL}/biz-rule-config/save`,
method: 'post',
data
})
/**树形目录
* @param {Object}
* @path /db-dir/tree-list
*/
export const getDbDirTreeList = (data) => request({
url: `${import.meta.env.VITE_APP_CHECK_BASEURL}/db-dir/tree-list`,
method: 'post',
data
})
/**
* 数据库目录-表数据列表查询
* @param {Object}
* @path /db-dir/table/page-list
*/
export const getDbDirTablePageList = (data) => request({
url: `${import.meta.env.VITE_APP_CHECK_BASEURL}/db-dir/table/page-list`,
method: 'post',
data
})
......
......@@ -2,18 +2,296 @@ import type { MockMethod } from 'vite-plugin-mock'
import Mock from 'mockjs'
export const confirmDelivery = {
url: '/mock/youthBoost/admin/shipment',
/**
* {
"children": [
{
"parentGuids": [
"string"
]
}
],
"parentGuids": [
"string"
],
"guid": "string",
"tenantGuid": "string",
"cgDirName": "string",
"classifyName": "string",
"orderNum": 0,
"level": 0,
"levelCode": "string",
"parentGuid": "string"
}
*/
export const getCgDirTreeList = {
url: '/mock/cg-dir/tree-list',
method: 'post',
response: ({body}:{body:any}) => {
return {
code: '00000',
message: '成功',
'data|10-30': [{
guid: '@guid',
tenantGuid: '@guid',
cgDirName: '@cword(3, 10)',
classifyName: '@cword(3, 5)',
orderNum: '@integer(1, 100)',
level: '@integer(1, 3)',
levelCode: '@string("number", 6)',
parentGuid: '@guid',
'parentGuids|1-2': ['@guid'],
'children|0-3': [{
guid: '@guid',
tenantGuid: '@guid',
cgDirName: '@cword(3, 5)',
classifyName: '@cword(3, 5)',
orderNum: '@integer(1, 100)',
level: '@integer(1, 3)',
levelCode: '@string("number", 6)',
parentGuid: '@guid',
'parentGuids|1-2': ['@guid']
}]
}]
}
}
}
/**
* "data": {
"totalRows": 0,
"totalPages": 0,
"pageSize": 0,
"pageIndex": 0,
"records": [
{
"guid": "string",
"tenantGuid": "string",
"cgDirName": "string",
"dirGuid": "string",
"classifyName": "string",
"gradeDetailName": "string",
"label": "string",
"fieldName": "string",
"fieldChName": "string",
"tableName": "string",
"tableChName": "string",
"database": "string",
"databaseChName": "string"
}
],
export const getCgDirFieldPageList = (data) => request({
url: `${import.meta.env.VITE_APP_CHECK_BASEURL}/cg-dir/field/page-list`,
method: 'post',
data
})
*/
export const getCgDirFieldPageList = {
url: '/mock/cg-dir/field/page-list',
method: 'post',
response: ({body}:{body:any}) => {
return {
code: '00000',
message: '成功',
'data': {
totalRows: '@integer(50, 100)',
totalPages: '@integer(1, 10)',
pageSize: 10,
pageIndex: 1,
'records|20-30': [{
guid: '@guid',
tenantGuid: '@guid',
cgDirName: '@cword(3, 5)',
dirGuid: '@guid',
classifyName: '@cword(3, 5)',
gradeDetailName: '@cword(3, 5)',
label: '@cword(3, 5)',
fieldName: '@cword(3, 5)',
fieldChName: '@cword(3, 5)',
tableName: '@cword(3, 5)',
tableChName: '@cword(3, 5)',
database: '@cword(3, 5)',
databaseChName: '@cword(3, 5)'
}]
}
}
}
}
/**
*
* export const getDictionary = (params) => request({
url: `${import.meta.env.VITE_APP_PLAN_BASEURL}/data-dictionary-general/list-all?state=1`,
method: 'post'
})
*/
export const getDictionary = {
url: '/mock/data-dictionary-general/list-all',
method: 'post',
response: ({body}:{body:any}) => {
return {
code: '00000',
message: '成功',
'data|10-30': [{
guid: '@guid',
tenantGuid: '@guid',
chName: '@cword(3, 5)',
classifyName: '@cword(3, 5)',
orderNum: '@integer(1, 100)',
level: '@integer(1, 3)',
levelCode: '@string("number", 6)',
parentGuid: '@guid',
'parentGuids|1-2': ['@guid'],
'children|0-3': [{
guid: '@guid',
tenantGuid: '@guid',
chName: '@cword(3, 5)',
classifyName: '@cword(3, 5)',
orderNum: '@integer(1, 100)',
level: '@integer(1, 3)',
levelCode: '@string("number", 6)',
parentGuid: '@guid',
'parentGuids|1-2': ['@guid']
}]
}]
}
}
}
export const saveBizRuleConfig = {
url: '/mock/biz-rule-config/save',
method: 'post',
response: ({body}:{body:any}) => {
return {
code: '00000',
message: '成功'
}
}
}
/**
* "data": [
{
"cgDirName": "string",
"childList": [
{
"databaseGuid": "string",
"database": "string",
"databaseChName": "string",
"childList": [
{
"tableGuid": "string",
"tableName": "string",
"tableChName": "string"
}
]
}
]
}
],
export const getDbDirTreeList = (data) => request({
url: `${import.meta.env.VITE_APP_CHECK_BASEURL}/db-dir/tree-list`,
method: 'post',
data
})
*/
export const getDbDirTreeList = {
url: '/mock/db-dir/tree-list',
method: 'post',
response: ({body}:{body:any}) => {
return {
code: 200,
code: '00000',
message: '成功',
data: []
'data|10-30': [{
cgDirName: '@cword(3, 5)',
'children|1-3': [{
databaseGuid: '@guid',
database: '@cword(3, 5)',
databaseChName: '@cword(3, 5)',
'children|1-3': [{
tableGuid: '@guid',
tableName: '@cword(3, 5)',
tableChName: '@cword(3, 5)'
}]
}]
}]
}
}
}
/**
* /**
* 数据库目录-表数据列表查询
* @param {Object}
* @path /db-dir/table/page-list
* export const getDbDirTablePageList = (data) => request({
url: `${import.meta.env.VITE_APP_CHECK_BASEURL}/db-dir/table/page-list`,
method: 'post',
data
})
"data": {
"totalRows": 0,
"totalPages": 0,
"pageSize": 0,
"pageIndex": 0,
"records": [
{
"guid": "string",
"tenantGuid": "string",
"cgDirName": "string",
"dirGuid": "string",
"tableGuid": "string",
"tableName": "string",
"tableChName": "string",
"databaseGuid": "string",
"database": "string",
"databaseChName": "string",
"foundMode": 0,
"state": 0,
"isDataAsset": "string"
}
],
}
*/
export const getDbDirTablePageList = {
url: '/mock/db-dir/table/page-list',
method: 'post',
response: ({body}:{body:any}) => {
const {pageIndex, pageSize} = body
return {
code: '00000',
message: '成功',
'data': {
totalRows: '@integer(50, 100)',
totalPages: '@integer(1, 10)',
pageSize,
pageIndex,
'records|20-30': [{
guid: '@guid',
tenantGuid: '@guid',
cgDirName: '@cword(3, 5)',
dirGuid: '@guid',
tableGuid: '@guid',
tableName: '@cword(3, 5)',
tableChName: '@cword(3, 5)',
databaseGuid: '@guid',
database: '@cword(3, 5)',
databaseChName: '@cword(3, 5)',
foundMode: '@integer(1, 3)',
state: '@integer(0,2)',
isDataAsset: 'Y'
}]
}
}
}
}
export default [confirmDelivery] as MockMethod[]
export default [getCgDirTreeList,getCgDirFieldPageList, getDictionary,saveBizRuleConfig, getDbDirTreeList, getDbDirTablePageList] as MockMethod[]
......
......@@ -176,6 +176,20 @@ const routes: RouteRecordRaw[] = [
cache: true
},
},
{
path: 'configure-rules',
name: 'configureRules',
component: () => import('@/views/data_inventory/configureRules.vue'),
meta: {
title: '配置业务规则',
sidebar: false,
breadcrumb: false,
cache: true,
reuse: true,
editPage: true,
activeMenu: '/data-inventory/classify-grade-catalogue',
},
},
],
}
]
......
<route lang="yaml">
name: configureRules //标签管理
</route>
<script lang="ts" setup name="configureRules"></script>
<template>
<div>111</div>
</template>
......@@ -7,7 +7,7 @@ import TableTools from '@/components/Tools/table_tools.vue';
import { getGradeList } from "@/api/modules/dataInventory";
import { getLabelList, getClassifyGradeTreeList, saveLabel, getLabelPageList, deleteLabel, updateLabel } from "@/api/modules/dataLabel";
import { CirclePlus, Delete } from "@element-plus/icons-vue";
import { el, tr } from 'element-plus/es/locale';
const { proxy } = getCurrentInstance() as any;
const dialogLabelFormRef = ref();
......@@ -560,7 +560,6 @@ const searchClass = async (val: any, clear: boolean = false) => {
return;
}
if (val?.labelName?.length !== 0) {
console.log('调用了吗');
tableInfo.value.loading = true;
const params = {
pageIndex: page.value.curr,
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!