8e6500f7 by lihua

提交与后端联调的网关修改

1 parent 2ab01a61
...@@ -2,14 +2,14 @@ ...@@ -2,14 +2,14 @@
2 VITE_APP_TITLE = 数据资产管理系统 2 VITE_APP_TITLE = 数据资产管理系统
3 # 接口域名 3 # 接口域名
4 # VITE_API_BASEURL = https://www.zgsjzc.com/api 4 # VITE_API_BASEURL = https://www.zgsjzc.com/api
5 VITE_API_BASEURL = https://swzl-test.csbr.cn/api 5 # VITE_API_BASEURL = https://swzl-test.csbr.cn/api
6 # VITE_API_BASEURL = http://192.168.3.122:8083/ 6 VITE_API_BASEURL = http://10.4.82.30:8052/
7 # 平台用户 接口请地址 7 # 平台用户 接口请地址
8 VITE_APP_USER_API_BASEURL = csbr-zuul/user 8 VITE_APP_USER_API_BASEURL = gateway-server/user
9 # 系统管理 接口地址 9 # 系统管理 接口地址
10 VITE_APP_API_BASEURL = ms-swzl-system-manager-service 10 VITE_APP_API_BASEURL = ms-daop-zcgl-system-manager-service
11 # 文件上传请求地址 11 # 文件上传请求地址
12 VITE_APP_ADD_FILE = ms-common-import-data-service 12 VITE_APP_ADD_FILE = ms-daop-import-data-service
13 # 调试工具,可设置 eruda 或 vconsole,如果不需要开启则留空 13 # 调试工具,可设置 eruda 或 vconsole,如果不需要开启则留空
14 VITE_APP_DEBUG_TOOL = 14 VITE_APP_DEBUG_TOOL =
15 # 是否开启代理 15 # 是否开启代理
...@@ -19,11 +19,10 @@ VITE_SERVE_BASE = / ...@@ -19,11 +19,10 @@ VITE_SERVE_BASE = /
19 # 流程设计访问地址 19 # 流程设计访问地址
20 VITE_BPMN_URL = https://workflow-swzl-test.csbr.cn 20 VITE_BPMN_URL = https://workflow-swzl-test.csbr.cn
21 # 数据标准、元数据、数据目录 接口地址 21 # 数据标准、元数据、数据目录 接口地址
22 VITE_APP_PLAN_BASEURL = ms-swzl-data-plan-service 22 VITE_APP_PLAN_BASEURL = ms-daop-zcgl-data-plan-service
23 #数据质量接口地址 23 #数据质量接口地址
24 VITE_APP_QUALITY_BASEURL = ms-swzl-data-quality-service 24 VITE_APP_QUALITY_BASEURL = ms-daop-zcgl-data-quality-service
25 #数据服务接口地址 25
26 VITE_APP_SERVICE_BASEURL = ms-swzl-data-open-service
27 26
28 #门户接口 27 #门户接口
29 VITE_API_PORTALURL = https://swzl-test.zgsjzc.com/portal 28 VITE_API_PORTALURL = https://swzl-test.zgsjzc.com/portal
......
...@@ -4,11 +4,11 @@ VITE_APP_TITLE = 数据资产管理系统 ...@@ -4,11 +4,11 @@ VITE_APP_TITLE = 数据资产管理系统
4 VITE_API_BASEURL = https://www.zgsjzc.com/api 4 VITE_API_BASEURL = https://www.zgsjzc.com/api
5 # VITE_API_BASEURL = http://49.4.26.201:31709/ 5 # VITE_API_BASEURL = http://49.4.26.201:31709/
6 # 平台用户 接口请地址 6 # 平台用户 接口请地址
7 VITE_APP_USER_API_BASEURL = csbr-zuul/user 7 VITE_APP_USER_API_BASEURL = gateway-server/user
8 # 系统管理 接口地址 8 # 系统管理 接口地址
9 VITE_APP_API_BASEURL = ms-swzl-system-manager-service 9 VITE_APP_API_BASEURL = ms-daop-zcgl-system-manager-service
10 # 文件上传请求地址 10 # 文件上传请求地址
11 VITE_APP_ADD_FILE = ms-common-import-data-service 11 VITE_APP_ADD_FILE = ms-daop-import-data-service
12 # 调试工具,可设置 eruda 或 vconsole,如果不需要开启则留空 12 # 调试工具,可设置 eruda 或 vconsole,如果不需要开启则留空
13 VITE_APP_DEBUG_TOOL = 13 VITE_APP_DEBUG_TOOL =
14 # 是否开启代理 14 # 是否开启代理
...@@ -18,11 +18,10 @@ VITE_SERVE_BASE = / ...@@ -18,11 +18,10 @@ VITE_SERVE_BASE = /
18 # 流程设计访问地址 18 # 流程设计访问地址
19 VITE_BPMN_URL = https://workflow.zgsjzc.com 19 VITE_BPMN_URL = https://workflow.zgsjzc.com
20 # 数据标准、元数据、数据目录 接口地址 20 # 数据标准、元数据、数据目录 接口地址
21 VITE_APP_PLAN_BASEURL = ms-swzl-data-plan-service 21 VITE_APP_PLAN_BASEURL = ms-daop-zcgl-data-plan-service
22 #数据质量接口地址 22 #数据质量接口地址
23 VITE_APP_QUALITY_BASEURL = ms-swzl-data-quality-service 23 VITE_APP_QUALITY_BASEURL = ms-daop-zcgl-data-quality-service
24 #数据服务接口地址 24
25 VITE_APP_SERVICE_BASEURL = ms-swzl-data-open-service
26 #门户接口 25 #门户接口
27 VITE_API_PORTALURL = https://www.zgsjzc.com/portal 26 VITE_API_PORTALURL = https://www.zgsjzc.com/portal
28 27
......
...@@ -22,12 +22,11 @@ ...@@ -22,12 +22,11 @@
22 "@vueuse/integrations": "^10.1.0", 22 "@vueuse/integrations": "^10.1.0",
23 "@wangeditor/editor": "^5.1.23", 23 "@wangeditor/editor": "^5.1.23",
24 "@wangeditor/editor-for-vue": "^5.1.12", 24 "@wangeditor/editor-for-vue": "^5.1.12",
25 "ant-design-vue": "^3.2.20",
26 "axios": "^1.4.0", 25 "axios": "^1.4.0",
27 "crypto-js": "^4.2.0", 26 "crypto-js": "^4.2.0",
28 "dayjs": "^1.11.7", 27 "dayjs": "^1.11.7",
29 "echarts": "^5.4.3", 28 "echarts": "^5.4.3",
30 "element-plus": "^2.5.3", 29 "element-plus": "^2.5.2",
31 "eruda": "^3.0.0", 30 "eruda": "^3.0.0",
32 "file-saver": "^2.0.5", 31 "file-saver": "^2.0.5",
33 "hotkeys-js": "^3.10.2", 32 "hotkeys-js": "^3.10.2",
......
...@@ -26,9 +26,6 @@ dependencies: ...@@ -26,9 +26,6 @@ dependencies:
26 '@wangeditor/editor-for-vue': 26 '@wangeditor/editor-for-vue':
27 specifier: ^5.1.12 27 specifier: ^5.1.12
28 version: 5.1.12(@wangeditor/editor@5.1.23)(vue@3.5.13) 28 version: 5.1.12(@wangeditor/editor@5.1.23)(vue@3.5.13)
29 ant-design-vue:
30 specifier: ^3.2.20
31 version: 3.2.20(vue@3.5.13)
32 axios: 29 axios:
33 specifier: ^1.4.0 30 specifier: ^1.4.0
34 version: 1.7.7 31 version: 1.7.7
...@@ -42,7 +39,7 @@ dependencies: ...@@ -42,7 +39,7 @@ dependencies:
42 specifier: ^5.4.3 39 specifier: ^5.4.3
43 version: 5.5.1 40 version: 5.5.1
44 element-plus: 41 element-plus:
45 specifier: ^2.5.3 42 specifier: ^2.5.2
46 version: 2.8.8(vue@3.5.13) 43 version: 2.8.8(vue@3.5.13)
47 eruda: 44 eruda:
48 specifier: ^3.0.0 45 specifier: ^3.0.0
......
...@@ -155,3 +155,48 @@ export const updateAllFinish = (staffGuid) => request({ ...@@ -155,3 +155,48 @@ export const updateAllFinish = (staffGuid) => request({
155 url: `${import.meta.env.VITE_API_MESSAGE}/message/update-all-finish?staffGuid=${staffGuid}`, 155 url: `${import.meta.env.VITE_API_MESSAGE}/message/update-all-finish?staffGuid=${staffGuid}`,
156 method: 'put' 156 method: 'put'
157 }); 157 });
158
159
160 /** 导入导出 */
161 // 数据导入-新增
162 export const addImportData = (url, params) => request({
163 url: url,
164 method: 'post',
165 data: params,
166 headers: {
167 'Content-Type': 'multipart/form-data'
168 }
169 })
170 // 数据导入-删除
171 export const deleteImportData = (params) => request({
172 url: `${import.meta.env.VITE_APP_ADD_FILE}/import-data/delete`,
173 method: 'delete',
174 data: params,
175 })
176 // 数据导入-分页查询
177 export const getImportData = (params) => request({
178 url: `${import.meta.env.VITE_APP_ADD_FILE}/import-data/list`,
179 method: 'post',
180 data: params,
181 })
182
183 // 导出数据字典模板
184 export const exportDictionary = (params) => request({
185 url: `${import.meta.env.VITE_APP_PLAN_BASEURL}/export/data-dictionary/schema`,
186 method: 'post',
187 data: params,
188 responseType: 'blob'
189 })
190
191 /** 获取树形结构的标准集列表 */
192 export const getStandardSetTree = () => request({
193 url: `${import.meta.env.VITE_APP_PLAN_BASEURL}/data-standard-set/list-tree`,
194 method: 'get'
195 })
196
197 // 数据字典树形数据
198 export const getDictionaryTree = (params) => request({
199 url: `${import.meta.env.VITE_APP_PLAN_BASEURL}/data-dictionary-general/tree-list`,
200 method: 'post',
201 params
202 })
...\ No newline at end of file ...\ No newline at end of file
......
...@@ -590,6 +590,7 @@ ...@@ -590,6 +590,7 @@
590 // dialog弹出层样式 590 // dialog弹出层样式
591 .el-dialog { 591 .el-dialog {
592 --el-dialog-bg-color: #fff; 592 --el-dialog-bg-color: #fff;
593 padding: 0px;
593 594
594 .el-dialog__header { 595 .el-dialog__header {
595 padding: 0 20px; 596 padding: 0 20px;
......
...@@ -146,6 +146,12 @@ defineExpose({ ...@@ -146,6 +146,12 @@ defineExpose({
146 :max-collapse-tags="item.cascaderInfo.maxTags ?? 1" :filterable="item.cascaderInfo.filterable ?? false" 146 :max-collapse-tags="item.cascaderInfo.maxTags ?? 1" :filterable="item.cascaderInfo.filterable ?? false"
147 @change="cascaderChange" /> 147 @change="cascaderChange" />
148 </div> 148 </div>
149 <div class="form_item" v-if="item.type == 'input'">
150 <span class="item_label" :class="{ required_mark: item.selectInfo.required }">{{ item.selectInfo.label
151 }}:</span>
152 <el-input v-model="extraParams[item.selectInfo.field]" :placeholder="item.selectInfo.placeholder"
153 :disabled="item.selectInfo.disabled" :clearable="item.selectInfo.disabled"> </el-input>
154 </div>
149 <div class="item_btn" v-else-if="item.type == 'btn_down'"> 155 <div class="item_btn" v-else-if="item.type == 'btn_down'">
150 <el-button plain @click="toolBtnClick({ value: 'exoprt_model' })" v-preReClick> 156 <el-button plain @click="toolBtnClick({ value: 'exoprt_model' })" v-preReClick>
151 <el-icon> 157 <el-icon>
...@@ -332,6 +338,10 @@ defineExpose({ ...@@ -332,6 +338,10 @@ defineExpose({
332 } 338 }
333 } 339 }
334 } 340 }
341
342 .el-input {
343 width: 240px;
344 }
335 } 345 }
336 346
337 .item_btn { 347 .item_btn {
......
...@@ -39,6 +39,23 @@ const routes: RouteRecordRaw[] = [ ...@@ -39,6 +39,23 @@ const routes: RouteRecordRaw[] = [
39 } 39 }
40 } 40 }
41 }, 41 },
42 {
43 path: 'import-file-meta',
44 name: 'importFileMeta',
45 component: () => import('@/views/importFile.vue'),
46 meta: {
47 title: '导入数据',
48 sidebar: false,
49 breadcrumb: false,
50 cache: true,
51 reuse: true
52 },
53 beforeEnter: (to, from) => {
54 if (to.query.bizGuid) {
55 to.meta.title = `导入数据-采集任务`;
56 }
57 }
58 }
42 ], 59 ],
43 }, 60 },
44 { 61 {
......
...@@ -23,7 +23,7 @@ interface metaInfoRaw { ...@@ -23,7 +23,7 @@ interface metaInfoRaw {
23 // 固定路由(默认路由) 23 // 固定路由(默认路由)
24 const constantRoutes: RouteRecordRaw[] = [ 24 const constantRoutes: RouteRecordRaw[] = [
25 { 25 {
26 path: '/login-zgsjzc', 26 path: '/login',
27 name: 'login', 27 name: 'login',
28 component: () => import('@/views/login.vue'), 28 component: () => import('@/views/login.vue'),
29 meta: { 29 meta: {
......
...@@ -571,6 +571,17 @@ const dialogBtnClick = (btn, info) => { ...@@ -571,6 +571,17 @@ const dialogBtnClick = (btn, info) => {
571 } 571 }
572 }; 572 };
573 573
574 const importMeta = () => {
575 let query: any = {
576 isfileImport: '4'
577 }
578 // 打开导入文件.
579 router.push({
580 name: 'importFileMeta',
581 query: query
582 });
583 }
584
574 onActivated(() => { 585 onActivated(() => {
575 getDataSourceList() 586 getDataSourceList()
576 }) 587 })
...@@ -586,7 +597,8 @@ onBeforeMount(() => { ...@@ -586,7 +597,8 @@ onBeforeMount(() => {
586 <!-- 头部搜索 --> 597 <!-- 头部搜索 -->
587 <TableTools :searchItems="searchItemList" :searchId="'data-source-search'" @search="toSearch" :init="false" /> 598 <TableTools :searchItems="searchItemList" :searchId="'data-source-search'" @search="toSearch" :init="false" />
588 <div class="tools_btns"> 599 <div class="tools_btns">
589 <el-button type="primary" @click="loadDrawer" v-preReClick>新建</el-button> 600 <el-button type="primary" @click="loadDrawer">新建</el-button>
601 <el-button type="primary" @click="importMeta">导入</el-button>
590 </div> 602 </div>
591 </div> 603 </div>
592 <div class="table_panel_wrap"> 604 <div class="table_panel_wrap">
......
...@@ -826,6 +826,24 @@ const radioGroupChange = (val, inlineValue, init) => { ...@@ -826,6 +826,24 @@ const radioGroupChange = (val, inlineValue, init) => {
826 } else { 826 } else {
827 item.visible = true; 827 item.visible = true;
828 } 828 }
829 } else if (val === 'value_of_range') { // 值域范围
830 item.visible = false
831 if (index === 3 || index === 4 || index === 5 || index === 6 || index == 7 || index == 9 || index == 10 || index == 11 || index === 13) {
832 } else {
833 item.visible = true;
834 }
835 } else if (val === 'ref_integrality') { // 引用完整性
836 item.visible = false
837 if (index === 3 || index === 4 || index === 5 || index === 6 || index == 7 || index == 9 || index == 10 || index == 11 || index === 13) {
838 } else {
839 item.visible = true;
840 }
841 } else if (val === 'norm_check') { // 规范校验
842 item.visible = false
843 if (index === 3 || index === 4 || index === 5 || index === 6 || index == 7 || index == 9 || index == 10 || index == 11 || index === 13) {
844 } else {
845 item.visible = true;
846 }
829 } else if (val === 'custom_sql') {//自定义sql 847 } else if (val === 'custom_sql') {//自定义sql
830 item.visible = false 848 item.visible = false
831 if (index === 3 || index === 4 || index === 5 || index === 6 || index == 7 || index == 8 || index == 10 || index == 11 || index === 13) { 849 if (index === 3 || index === 4 || index === 5 || index === 6 || index == 7 || index == 8 || index == 10 || index == 11 || index === 13) {
...@@ -1558,6 +1576,9 @@ defineExpose({ ...@@ -1558,6 +1576,9 @@ defineExpose({
1558 </template> 1576 </template>
1559 </el-dialog> 1577 </el-dialog>
1560 1578
1579 <!-- 值域范围 -->
1580 <el-dialog></el-dialog>
1581
1561 <!-- 表行数检查 --> 1582 <!-- 表行数检查 -->
1562 <el-dialog v-model="tableRowDialogVisible" title="规则设置" width="750" :modal="true" :close-on-click-modal="false" 1583 <el-dialog v-model="tableRowDialogVisible" title="规则设置" width="750" :modal="true" :close-on-click-modal="false"
1563 destroy-on-close align-center> 1584 destroy-on-close align-center>
......
...@@ -18,7 +18,7 @@ const enterCompany = () => { ...@@ -18,7 +18,7 @@ const enterCompany = () => {
18 } 18 }
19 19
20 const logon = () => { 20 const logon = () => {
21 window.open('/login-zgsjzc'); 21 window.open('/login');
22 } 22 }
23 23
24 const register = () => { 24 const register = () => {
......
...@@ -18,9 +18,9 @@ import { ...@@ -18,9 +18,9 @@ import {
18 getImportData, 18 getImportData,
19 exportDictionary, 19 exportDictionary,
20 getStandardSetTree, 20 getStandardSetTree,
21 getDictionaryTree 21 getDictionaryTree,
22 } from '@/api/modules/dataStandardService' 22 getImageContent
23 import { getImageContent } from "@/api/modules/queryService"; 23 } from '@/api/modules/queryService';
24 import { commonPageConfig } from '@/utils/enum'; 24 import { commonPageConfig } from '@/utils/enum';
25 25
26 const { proxy } = getCurrentInstance() as any; 26 const { proxy } = getCurrentInstance() as any;
...@@ -28,6 +28,7 @@ const { proxy } = getCurrentInstance() as any; ...@@ -28,6 +28,7 @@ const { proxy } = getCurrentInstance() as any;
28 const userStore = useUserStore() 28 const userStore = useUserStore()
29 const route = useRoute() 29 const route = useRoute()
30 const router = useRouter() 30 const router = useRouter()
31 /** 2表示资产目录的。3是主数据; 4是元数据导入 */
31 const isfileImport = route.query.isfileImport 32 const isfileImport = route.query.isfileImport
32 const userData = JSON.parse(userStore.userData) 33 const userData = JSON.parse(userStore.userData)
33 const cacheStore = useCatchStore() 34 const cacheStore = useCatchStore()
...@@ -129,46 +130,24 @@ const dialogInfo: any = ref({ ...@@ -129,46 +130,24 @@ const dialogInfo: any = ref({
129 }, 130 },
130 }) 131 })
131 132
132 // 获取所有标准集 133 // // 获取所有数据字典
133 const getSetList = () => { 134 // const getDictList = () => {
134 let params: any = {} 135 // const params = {
135 params.pageIndex = 0; 136 // paramCode: 'data_structure_code'
136 params.pageSize = 0; 137 // }
137 getStandardSetTree().then((res: any) => { 138 // getDictionaryTree(params).then((res: any) => {
138 if (res.code == proxy.$passCode) { 139 // if (res.code == proxy.$passCode) {
139 const data = res.data || [] 140 // const data = res.data ?? []
140 data.map(item => { 141 // const treeList = data.filter(item => item.children && item.children.length)
141 item.label = item.standardName 142 // dictionaryList.value = treeList
142 item.value = item.guid 143 // } else {
143 }) 144 // ElMessage({
144 standardSetList.value = data 145 // type: 'error',
145 } else { 146 // message: res.msg,
146 ElMessage({ 147 // })
147 type: 'info', 148 // }
148 message: res.msg, 149 // })
149 }) 150 // }
150 }
151 })
152 }
153
154 // 获取所有数据字典
155 const getDictList = () => {
156 const params = {
157 paramCode: 'data_structure_code'
158 }
159 getDictionaryTree(params).then((res: any) => {
160 if (res.code == proxy.$passCode) {
161 const data = res.data ?? []
162 const treeList = data.filter(item => item.children && item.children.length)
163 dictionaryList.value = treeList
164 } else {
165 ElMessage({
166 type: 'error',
167 message: res.msg,
168 })
169 }
170 })
171 }
172 151
173 const tabsChange = (name) => { 152 const tabsChange = (name) => {
174 tabsActiveName.value = name 153 tabsActiveName.value = name
...@@ -290,7 +269,7 @@ const batching = (type) => { ...@@ -290,7 +269,7 @@ const batching = (type) => {
290 } 269 }
291 open("此操作将永久删除, 是否继续?", "warning", true); 270 open("此操作将永久删除, 是否继续?", "warning", true);
292 } else if(type === 'importFile') { 271 } else if(type === 'importFile') {
293 if (isfileImport == '2') { 272 if (isfileImport == '2' || isfileImport == '4') {
294 dialogInfo.value.header.title = '导入数据' 273 dialogInfo.value.header.title = '导入数据'
295 dialogInfo.value.type = 'upload' 274 dialogInfo.value.type = 'upload'
296 dialogInfo.value.size = 500 275 dialogInfo.value.size = 500
...@@ -539,7 +518,7 @@ const setUploadInfo = () => { ...@@ -539,7 +518,7 @@ const setUploadInfo = () => {
539 uploadInfo.value.uploadInfo.extraParams = { 518 uploadInfo.value.uploadInfo.extraParams = {
540 dictionaryGuid: dictionaryGuid.value 519 dictionaryGuid: dictionaryGuid.value
541 } 520 }
542 } else if (tabsActiveName.value == 'importFile') { 521 } else if (tabsActiveName.value == 'importFile' && isfileImport == '2') {
543 uploadSteps.value = [ 522 uploadSteps.value = [
544 { 523 {
545 title: '选择准备好的文件导入', 524 title: '选择准备好的文件导入',
...@@ -555,6 +534,40 @@ const setUploadInfo = () => { ...@@ -555,6 +534,40 @@ const setUploadInfo = () => {
555 } 534 }
556 ] 535 ]
557 uploadInfo.value.uploadInfo.extraParams = {} 536 uploadInfo.value.uploadInfo.extraParams = {}
537 } else if (tabsActiveName.value == 'importFile' && isfileImport == '4') { //元数据导入
538 uploadSteps.value = [
539 {
540 title: '1、导入前请先录入以下内容',
541 type: 'input',
542 selectInfo: {
543 label: '采集任务名称',
544 placeholder: '请输入',
545 field: 'collectTaskName',
546 default: '',
547 clearable: true,
548 maxlength: 50,
549 filterable: true,
550 required: true
551 }
552 },
553 {
554 title: '2、请下载最新的模板,并按照模板格式准备需要导入的数据',
555 type: 'btn_down'
556 },
557 {
558 title: '3、选择准备好的文件导入',
559 type: 'btn_upload',
560 uploadInfo: {
561 action: '',
562 auto: false,
563 cover: true,
564 fileList: [],
565 accept: '.xlsx, .xls',
566 tips: '当前支持xls、xlsx文件,默认使用第一个sheet'
567 }
568 }
569 ]
570 uploadInfo.value.uploadInfo.extraParams = {}
558 } else { 571 } else {
559 uploadSteps.value = [ 572 uploadSteps.value = [
560 { 573 {
...@@ -586,8 +599,7 @@ onActivated(() => { ...@@ -586,8 +599,7 @@ onActivated(() => {
586 tabsActiveName.value = uploadSetting.value?.type || 'standard' 599 tabsActiveName.value = uploadSetting.value?.type || 'standard'
587 } 600 }
588 601
589 getSetList() 602 //getDictList()
590 getDictList()
591 setUploadInfo() 603 setUploadInfo()
592 }) 604 })
593 605
......
...@@ -537,14 +537,6 @@ font-weight: 200; ...@@ -537,14 +537,6 @@ font-weight: 200;
537 .el-input__suffix { 537 .el-input__suffix {
538 right: 10px; 538 right: 10px;
539 } 539 }
540 .el-input__wrapper {
541 // border-radius: 0;
542 // box-shadow: none;
543 // border-bottom: 1px solid #e5e5e5;
544 &:hover {
545 // box-shadow: none;
546 }
547 }
548 } 540 }
549 } 541 }
550 .flex-bar { 542 .flex-bar {
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!