提交 9dd9c254 authored 作者: kxjia's avatar kxjia

指标名称

上级 dc235789
...@@ -8,7 +8,7 @@ VITE_GLOB_APP_TITLE = 科技风险管理平台 ...@@ -8,7 +8,7 @@ VITE_GLOB_APP_TITLE = 科技风险管理平台
VITE_GLOB_APP_SHORT_NAME = 科技风险管理平台 VITE_GLOB_APP_SHORT_NAME = 科技风险管理平台
# 单点登录服务端地址 # 单点登录服务端地址
VITE_GLOB_APP_CAS_BASE_URL=http://cas.test.com:8443/cas # VITE_GLOB_APP_CAS_BASE_URL=http://cas.test.com:8443/cas
# 是否开启单点登录 # 是否开启单点登录
...@@ -18,10 +18,10 @@ VITE_GLOB_APP_OPEN_SSO = false ...@@ -18,10 +18,10 @@ VITE_GLOB_APP_OPEN_SSO = false
VITE_GLOB_APP_OPEN_QIANKUN=true VITE_GLOB_APP_OPEN_QIANKUN=true
#后台接口全路径地址(必填) #后台接口全路径地址(必填)
VITE_GLOB_DOMAIN_URL=http://47.98.203.68:8080/stm/ #VITE_GLOB_DOMAIN_URL=http://47.98.203.68:8080/stm/
# 文件预览地址 # 文件预览地址
# VITE_GLOB_ONLINE_VIEW_URL=http://fileview.jeecg.com/onlinePreview # VITE_GLOB_ONLINE_VIEW_URL=http://fileview.jeecg.com/onlinePreview
VITE_GLOB_ONLINE_VIEW_URL=http://47.98.203.68:8080/stm/sys/common/static/ # VITE_GLOB_ONLINE_VIEW_URL=http://47.98.203.68:8080/stm/sys/common/static/
...@@ -9,7 +9,7 @@ VITE_PUBLIC_PATH = / ...@@ -9,7 +9,7 @@ VITE_PUBLIC_PATH = /
VITE_PROXY = [["/stm","http://localhost:8080/stm"],["/upload","http://localhost:3300/upload"]] VITE_PROXY = [["/stm","http://localhost:8080/stm"],["/upload","http://localhost:3300/upload"]]
#后台接口全路径地址(必填) #后台接口全路径地址(必填)
VITE_GLOB_DOMAIN_URL=http://localhost:8080/stm/ VITE_GLOB_DOMAIN_URL=http://localhost:8080/stm
#后台接口父地址(必填) #后台接口父地址(必填)
VITE_GLOB_API_URL=/stm VITE_GLOB_API_URL=/stm
...@@ -33,5 +33,5 @@ VITE_APP_SUB_jeecg-app-1 = '//localhost:8092' ...@@ -33,5 +33,5 @@ VITE_APP_SUB_jeecg-app-1 = '//localhost:8092'
VITE_GLOB_ONLINE_DOCUMENT_VERSION=wps VITE_GLOB_ONLINE_DOCUMENT_VERSION=wps
# 文件预览地址 # 文件预览地址
VITE_GLOB_ONLINE_VIEW_URL=http://localhost:8080/stm/sys/common/static/ VITE_GLOB_ONLINE_VIEW_URL=http://localhost:3100/stm/sys/common/static/
...@@ -16,13 +16,12 @@ VITE_BUILD_COMPRESS_DELETE_ORIGIN_FILE = false ...@@ -16,13 +16,12 @@ VITE_BUILD_COMPRESS_DELETE_ORIGIN_FILE = false
VITE_GLOB_API_URL=/stm VITE_GLOB_API_URL=/stm
#后台接口全路径地址(必填) #后台接口全路径地址(必填)
# VITE_GLOB_DOMAIN_URL=https://itrm.westmining.com:8080/stm VITE_GLOB_DOMAIN_URL=https://itrm.westmining.com/stm
# VITE_GLOB_ONLINE_VIEW_URL=https://itrm.westmining.com:8080/stm/sys/common/static/ VITE_GLOB_ONLINE_VIEW_URL=https://itrm.westmining.com/stm/sys/common/static/
#后台接口全路径地址(必填) #后台接口全路径地址(必填)
VITE_GLOB_DOMAIN_URL=http://47.98.203.68:8080/stm/ # VITE_GLOB_DOMAIN_URL=http://47.98.203.68:8080/stm/
# VITE_GLOB_ONLINE_VIEW_URL=http://47.98.203.68:8080/stm/sys/common/static/
VITE_GLOB_ONLINE_VIEW_URL=http://47.98.203.68:8080/stm/sys/common/static/
# 接口父路径前缀 # 接口父路径前缀
VITE_GLOB_API_URL_PREFIX= VITE_GLOB_API_URL_PREFIX=
......
...@@ -157,7 +157,7 @@ ...@@ -157,7 +157,7 @@
</style> </style>
<div class="app-loading"> <div class="app-loading">
<div class="app-loading-wrap"> <div class="app-loading-wrap">
<img src="<%= basePublicPath %>/resource/img/logo.png" class="app-loading-logo" alt="Logo" style="width: 80px;height:32px;" /> <img src="<%= basePublicPath %>/resource/img/logo.png" class="app-loading-logo" alt="Logo" />
<div class="app-loading-dots"> <div class="app-loading-dots">
<span class="dot dot-spin"><i></i><i></i><i></i><i></i></span> <span class="dot dot-spin"><i></i><i></i><i></i><i></i></span>
</div> </div>
......
...@@ -22,8 +22,13 @@ enum Api { ...@@ -22,8 +22,13 @@ enum Api {
queryDepartPostUserPageList = '/sys/user/queryDepartPostUserPageList', queryDepartPostUserPageList = '/sys/user/queryDepartPostUserPageList',
//查询所选部门的所有父节点ID //查询所选部门的所有父节点ID
queryAllParentId = '/sys/sysDepart/queryAllParentId', queryAllParentId = '/sys/sysDepart/queryAllParentId',
getMetricList = '/metric/metricMonitorSet/list',
queryAllMetric = '/metric/metricMonitorSet/queryAllMetric',
rateRuleList = '/rate/rateRule/list',
} }
/** /**
* 上传父路径 * 上传父路径
*/ */
...@@ -188,3 +193,16 @@ export const refreshDragCache = () => defHttp.get({ url: Api.refreshDragCache }, ...@@ -188,3 +193,16 @@ export const refreshDragCache = () => defHttp.get({ url: Api.refreshDragCache },
* @param params * @param params
*/ */
export const refreshHomeCache = () => defHttp.get({ url: Api.refreshDefaultIndexCache }, { isTransformResponse: false }); export const refreshHomeCache = () => defHttp.get({ url: Api.refreshDefaultIndexCache }, { isTransformResponse: false });
export const getMetricList = (params) => {
return defHttp.get({ url: Api.getMetricList, params })
};
export const queryAllMetric = (params) =>{
return defHttp.get({url: Api.queryAllMetric, params})
}
export const getRateRuleList = (params) => {
return defHttp.get({ url: Api.rateRuleList, params });
};
...@@ -76,7 +76,7 @@ import JCaSelect from './jeecg/components/JCaSelect.vue'; ...@@ -76,7 +76,7 @@ import JCaSelect from './jeecg/components/JCaSelect.vue';
import StSelectLable from './jeecg/components/StSelectLable.vue'; import StSelectLable from './jeecg/components/StSelectLable.vue';
import JSearchSelectDuty from './jeecg/components/JSearchSelectDuty.vue'; import JSearchSelectDuty from './jeecg/components/JSearchSelectDuty.vue';
import JSelectMetric from './jeecg/components/JSelectMetric.vue';
const componentMap = new Map<ComponentType, Component>(); const componentMap = new Map<ComponentType, Component>();
...@@ -182,6 +182,8 @@ componentMap.set('JCaSelect', JCaSelect); ...@@ -182,6 +182,8 @@ componentMap.set('JCaSelect', JCaSelect);
componentMap.set('StSelectLable', StSelectLable); componentMap.set('StSelectLable', StSelectLable);
componentMap.set('JSearchSelectDuty', JSearchSelectDuty); componentMap.set('JSearchSelectDuty', JSearchSelectDuty);
componentMap.set('JSelectMetric', JSelectMetric);
export function add(compName: ComponentType, component: Component) { export function add(compName: ComponentType, component: Component) {
componentMap.set(compName, component); componentMap.set(compName, component);
} }
......
...@@ -29,7 +29,7 @@ ...@@ -29,7 +29,7 @@
enum Api { enum Api {
url = '/sys/dict/loadTreeData', url = '/sys/dict/loadTreeData',
view = '/sys/dict/loadDictItem/', view = '/base.domain/stDomain/queryByCode',
} }
const props = defineProps({ const props = defineProps({
...@@ -110,29 +110,30 @@ ...@@ -110,29 +110,30 @@
treeValue.value = props.multiple ? [] : null; treeValue.value = props.multiple ? [] : null;
return; return;
} }
console.log(props.value, 'props.value');
const params = { key: props.value }; const params = { code: props.value };
const result = await defHttp.get({ url: `${Api.view}${props.dict}`, params }, { isTransformResponse: false }); const result = await defHttp.get({ url: `${Api.view}`, params }, { isTransformResponse: false });
if (result.success && result.result?.length > 0) {
console.log(result, 'result'); console.log(result, 'result');
console.log(result.result, 'result.result'); if (result.success && result.result) {
console.log(props, 'props');
const values = props.value; // console.log(result.result, 'result.result');
console.log(values, 'values'); // console.log(props, 'props');
const length = values.length; // const values = props.value;
console.log(length, 'length'); // console.log(values, 'values');
if (length === 2) { // const length = values.length;
treeValue.value = [values]; // console.log(length, 'length');
console.log(treeValue.value, 'treeValue.value2'); // if (length === 2) {
} else if (length === 4) { // treeValue.value = [values];
treeValue.value = [values.substring(0, 2), values]; // console.log(treeValue.value, 'treeValue.value2');
console.log(treeValue.value, 'treeValue.value4'); // } else if (length === 4) {
} else if (length === 6) { // treeValue.value = [values.substring(0, 2), values];
treeValue.value = [values.substring(0, 2), values.substring(0, 4), values]; // console.log(treeValue.value, 'treeValue.value4');
console.log(treeValue.value, 'treeValue.value6'); // } else if (length === 6) {
} // treeValue.value = [values.substring(0, 2), values.substring(0, 4), values];
// console.log(treeValue.value, 'treeValue.value6');
// }
treeValue.value = [result.result];
onLoadTriggleChange(result.result[0]); onLoadTriggleChange(result.result[0]);
} }
} }
......
<template> <template>
<div> <div>
<JMetricBiz @handleOpen="handleOpen" :loading="loadingEcho" v-bind="attrs"></JMetricBiz> <JMetricBiz @handleOpen="handleOpen" :loading="loadingEcho" v-bind="attrs"></JMetricBiz>
......
...@@ -168,4 +168,5 @@ export type ComponentType = ...@@ -168,4 +168,5 @@ export type ComponentType =
| 'StSelectLable' | 'StSelectLable'
| 'JTreeSelectDomain' | 'JTreeSelectDomain'
| 'JCaSelect' | 'JCaSelect'
| 'JInputSelect'; | 'JInputSelect'
\ No newline at end of file | 'JSelectMetric';
\ No newline at end of file
...@@ -275,7 +275,7 @@ ...@@ -275,7 +275,7 @@
</vxe-column> </vxe-column>
<!-- 备注列 --> <!-- 备注列 -->
<vxe-column field="remarks" title="备注" width="200"> <vxe-column field="remarks" title="备注" width="100">
<template #default="{ row }"> <template #default="{ row }">
<vxe-textarea <vxe-textarea
:rows="row.remarks.rows" :rows="row.remarks.rows"
......
...@@ -23,6 +23,7 @@ export const columns: BasicColumn[] = [ ...@@ -23,6 +23,7 @@ export const columns: BasicColumn[] = [
ellipsis: true, ellipsis: true,
dataIndex: 'domainDesc', dataIndex: 'domainDesc',
width: 300, width: 300,
ifShow: false,
}, },
{ {
title: '更新时间', title: '更新时间',
......
...@@ -7,6 +7,8 @@ ...@@ -7,6 +7,8 @@
<a-button type="primary" @click="handleCreate" preIcon="ant-design:plus-outlined">新建</a-button> <a-button type="primary" @click="handleCreate" preIcon="ant-design:plus-outlined">新建</a-button>
<a-button v-show="showBtn" type="primary" preIcon="ant-design:export-outlined" @click="onExportXls"> 导出</a-button> <a-button v-show="showBtn" type="primary" preIcon="ant-design:export-outlined" @click="onExportXls"> 导出</a-button>
<j-upload-button v-show="showBtn" type="primary" preIcon="ant-design:import-outlined" @click="onImportXls">导入</j-upload-button> <j-upload-button v-show="showBtn" type="primary" preIcon="ant-design:import-outlined" @click="onImportXls">导入</j-upload-button>
<a-button type="primary" @click="handleExpandAll" preIcon="ant-design:down-outlined">展开所有</a-button>
<a-button type="primary" @click="handleCollapseAll" preIcon="ant-design:up-outlined">折叠所有</a-button>
<a-dropdown v-show="showBtn" v-if="selectedRowKeys.length > 0"> <a-dropdown v-show="showBtn" v-if="selectedRowKeys.length > 0">
<template #overlay> <template #overlay>
...@@ -217,7 +219,6 @@ import { downloadFile } from '/@/utils/common/renderUtils'; ...@@ -217,7 +219,6 @@ import { downloadFile } from '/@/utils/common/renderUtils';
getDataByResult(result.items); getDataByResult(result.items);
setTimeout(() => { setTimeout(() => {
loadDataByExpandedRows() loadDataByExpandedRows()
nextTick(expandAll)
}, 800); }, 800);
} }
...@@ -281,10 +282,7 @@ import { downloadFile } from '/@/utils/common/renderUtils'; ...@@ -281,10 +282,7 @@ import { downloadFile } from '/@/utils/common/renderUtils';
//判断是否标记了带有子节点 //判断是否标记了带有子节点
if(item["hasChild"]=='1'){ if(item["hasChild"]=='1'){
let loadChild = { id: item.id+'_loadChild', name: 'loading...', isLoading: true } let loadChild = { id: item.id+'_loadChild', name: 'loading...', isLoading: true }
console.log(loadChild)
item.children = [loadChild] item.children = [loadChild]
// // 设置展开的key
handleExpand(true,item)
} }
return item return item
}) })
...@@ -394,6 +392,51 @@ import { downloadFile } from '/@/utils/common/renderUtils'; ...@@ -394,6 +392,51 @@ import { downloadFile } from '/@/utils/common/renderUtils';
] ]
} }
/**
* 展开所有节点
*/
async function handleExpandAll() {
// 展开所有节点
expandAll();
// 加载所有子节点数据
const dataSource = getDataSource();
await loadAllChildren(dataSource);
}
/**
* 折叠所有节点
*/
function handleCollapseAll() {
// 清空展开的节点
expandedRowKeys.value = [];
// 重新加载表格数据,确保所有节点都折叠
reload();
}
/**
* 递归加载所有子节点数据
*/
async function loadAllChildren(nodes) {
if (!nodes || nodes.length === 0) return;
for (const node of nodes) {
if (node.children && node.children.length > 0 && node.children[0].isLoading) {
let data = getFormVlaue();
if (data.level !== "1") {
let result = await getChildList({upperDomainCode: node.domainCode, level: data.level, domainName: data.domainName});
result = result.records ? result.records : result;
if (result && result.length > 0) {
node.children = getDataByResult(result);
await loadAllChildren(node.children);
}
}
} else if (node.children && node.children.length > 0) {
await loadAllChildren(node.children);
}
}
}
</script> </script>
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论