|
@@ -143,12 +143,12 @@
|
|
|
style="display: flex; align-items: center"
|
|
|
v-if="select_node===data.UniqueCode&&data.HaveOperaAuth"
|
|
|
>
|
|
|
- <img
|
|
|
+ <!-- <img
|
|
|
src="~@/assets/img/data_m/move_ico.png"
|
|
|
alt=""
|
|
|
style="width: 14px; height: 14px; margin-right: 8px"
|
|
|
v-if="data.Button.MoveButton&&isEdbBtnShow('moveCatalog')"
|
|
|
- />
|
|
|
+ /> -->
|
|
|
<!-- 添加子项 -->
|
|
|
<img
|
|
|
src="~@/assets/img/set_m/add.png"
|
|
@@ -175,25 +175,25 @@
|
|
|
v-if="!data.EdbCode&&(data.Button.DeleteButton)&&isEdbBtnShow('deleteCatalog')"
|
|
|
/>
|
|
|
<!-- 查看计算指标 -->
|
|
|
- <i class="el-icon-view"
|
|
|
+ <!-- <i class="el-icon-view"
|
|
|
v-if="data.EdbType===2&&![58,59,67,68,74].includes(data.Source)&&isEdbBtnShow('checkCalcChart')"
|
|
|
- @click.stop="viewNode(node,data)"></i>
|
|
|
+ @click.stop="viewNode(node,data)"></i> -->
|
|
|
<!-- 查看关联图表 -->
|
|
|
- <img
|
|
|
+ <!-- <img
|
|
|
v-if="data.Button.ShowChartRelation&&isEdbBtnShow('checkRelatedChart')"
|
|
|
@click.stop="showAssociateChart=true,showAssociateComputeData=false"
|
|
|
src="~@/assets/img/icons/associate_chart.png"
|
|
|
style="width: 14px; height: 14px;margin-left: 8px"
|
|
|
alt=""
|
|
|
- />
|
|
|
+ /> -->
|
|
|
<!-- 查看关联指标 -->
|
|
|
- <img
|
|
|
+ <!-- <img
|
|
|
v-if="data.Button.ShowEdbRelation&&isEdbBtnShow('checkRelatedEdb')"
|
|
|
@click.stop="showAssociateComputeData=true,showAssociateChart=false"
|
|
|
src="~@/assets/img/icons/associate_data.png"
|
|
|
style="width: 14px; height: 14px;margin-left: 8px"
|
|
|
alt=""
|
|
|
- />
|
|
|
+ /> -->
|
|
|
</span>
|
|
|
</span>
|
|
|
</el-tree>
|
|
@@ -219,10 +219,10 @@
|
|
|
</div>
|
|
|
<!-- 指标关联图模块 -->
|
|
|
<div class="main-right right" id="right" style="background:transparent;border:none;box-shadow:none" v-if="showAssociateChart">
|
|
|
- <dataAssociateChart :edbInfoId="selected_edbid"></dataAssociateChart>
|
|
|
+ <dataAssociateChart :edbInfoId="selected_edbid" @returnHandle="showAssociateChart=false,showAssociateComputeData=false"></dataAssociateChart>
|
|
|
</div>
|
|
|
<div class="main-right right" id="right" style="background:transparent;border:none;box-shadow:none;padding-top: 30px;box-sizing: border-box;" v-if="showAssociateComputeData">
|
|
|
- <dataAssociateComputeData :edbInfoId="selected_edbid"></dataAssociateComputeData>
|
|
|
+ <dataAssociateComputeData :edbInfoId="selected_edbid" @returnHandle="showAssociateChart=false,showAssociateComputeData=false"></dataAssociateComputeData>
|
|
|
</div>
|
|
|
<!-- 指标图表列表 -->
|
|
|
<div class="main-right right list" id="right" v-show="isShowList">
|
|
@@ -316,6 +316,21 @@
|
|
|
type="text"
|
|
|
@click="copyCode"
|
|
|
>{{$t('Edb.detail_copydata_btn')}}<!-- 复制数据 --></el-button>
|
|
|
+ <el-button
|
|
|
+ v-if="EdbData.EdbType===2&&![58,59,67,68,74].includes(EdbData.Source)&&isEdbBtnShow('checkCalcChart')"
|
|
|
+ type="text"
|
|
|
+ @click.stop="viewNode"
|
|
|
+ >{{$t('Edb.detail_formula_btn')}}<!-- 查看公式 --></el-button>
|
|
|
+ <el-button
|
|
|
+ v-if="EdbData.Button.ShowChartRelation&&isEdbBtnShow('checkRelatedChart')"
|
|
|
+ type="text"
|
|
|
+ @click="showAssociateChart=true,showAssociateComputeData=false"
|
|
|
+ >{{$t('Edb.detail_related_charts_btn')}}<!-- 关联图 --></el-button>
|
|
|
+ <el-button
|
|
|
+ v-if="EdbData.Button.ShowEdbRelation&&isEdbBtnShow('checkRelatedEdb')"
|
|
|
+ type="text"
|
|
|
+ @click="showAssociateComputeData=true,showAssociateChart=false"
|
|
|
+ >{{$t('Edb.detail_related_metrics_btn')}}<!-- 关联指标 --></el-button>
|
|
|
<el-button
|
|
|
v-if="EdbData.Button.DeleteButton&&isEdbBtnShow('deleteEdb')"
|
|
|
type="text"
|
|
@@ -567,6 +582,10 @@
|
|
|
@updateLang="updateLang"
|
|
|
cType="ebd"
|
|
|
/>
|
|
|
+
|
|
|
+ <!-- 指标已经被引用 -->
|
|
|
+ <edbHasUsedDia :show.sync="edbHasUsedDiaShow" :dataList="hasUsedList"/>
|
|
|
+
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
@@ -597,6 +616,7 @@ import edbDetailData from './databaseComponents/edbDetailData.vue';
|
|
|
import SmoothEdbDialog from './databaseComponents/smoothEdbDialog.vue';
|
|
|
import batchComputedV2 from './databaseComponents/batchComputedV2.vue';
|
|
|
import setLangInfoDia from './components/setLangInfo.vue'
|
|
|
+import edbHasUsedDia from './components/edbHasUsedDia.vue';
|
|
|
export default {
|
|
|
name: '',
|
|
|
components: {
|
|
@@ -622,7 +642,8 @@ export default {
|
|
|
edbDetailData,
|
|
|
SmoothEdbDialog,
|
|
|
batchComputedV2,
|
|
|
- setLangInfoDia
|
|
|
+ setLangInfoDia,
|
|
|
+ edbHasUsedDia
|
|
|
},
|
|
|
directives: {
|
|
|
drag(el, bindings,vnode) {
|
|
@@ -757,7 +778,10 @@ export default {
|
|
|
showBatchComputedPop:false,
|
|
|
|
|
|
/* 修改对应版本信息弹窗 替换原有设置英文*/
|
|
|
- isLangInfoDia: false
|
|
|
+ isLangInfoDia: false,
|
|
|
+
|
|
|
+ edbHasUsedDiaShow:false,
|
|
|
+ hasUsedList:[]
|
|
|
};
|
|
|
},
|
|
|
watch: {
|
|
@@ -1492,15 +1516,23 @@ export default {
|
|
|
* 0 可删除
|
|
|
* 1 关联指标
|
|
|
* 2 有子目录无指标
|
|
|
+ * 4 当前指标已用作指标运算,不可删除
|
|
|
+ * 5 当前指标已用作预测指标,不可删除
|
|
|
+ * 6 当前指标已被表格引用,不可删除
|
|
|
+ * 7 当前指标已添加到跨品种分析,不可删除
|
|
|
*/
|
|
|
const deleteLabelMap = {
|
|
|
1: /* '该目录关联指标不可删除' */this.$t('Edb.MsgPrompt.del_not_relate_edb'),
|
|
|
2: /* '确认删除当前目录及包含的子目录吗?' */this.$t('Edb.MsgPrompt.del_confirm_menu_or_children'),
|
|
|
3: /* '当前指标已用作画图,不可删除' */this.$t('Edb.MsgPrompt.del_edb_use_chart'),
|
|
|
- 4: res.Data.TipsMsg
|
|
|
+ 4: res.Data.TipsMsg,
|
|
|
+ 5: res.Data.TipsMsg,
|
|
|
+ 6: res.Data.TipsMsg,
|
|
|
+ 7: res.Data.TipsMsg,
|
|
|
}
|
|
|
|
|
|
- if([1,3,4].includes(res.Data.DeleteStatus)) this.$confirm(
|
|
|
+ if([1,3,4,5,7].includes(res.Data.DeleteStatus)){
|
|
|
+ this.$confirm(
|
|
|
deleteLabelMap[res.Data.DeleteStatus],
|
|
|
/* '删除失败' */this.$t('Edb.MsgPrompt.del_failed'),
|
|
|
{
|
|
@@ -1508,7 +1540,12 @@ export default {
|
|
|
showCancelButton:false,
|
|
|
type: 'error'
|
|
|
})
|
|
|
- else if([0,2].includes(res.Data.DeleteStatus)) this.$confirm(
|
|
|
+ }else if(res.Data.DeleteStatus == 6){
|
|
|
+ this.edbHasUsedDiaShow=true
|
|
|
+ this.hasUsedList=res.Data.TableList.map(it =>{
|
|
|
+ return {...it,routeUrl:this.getRouteUrl(it)}
|
|
|
+ })
|
|
|
+ }else if([0,2].includes(res.Data.DeleteStatus)) this.$confirm(
|
|
|
res.Data.DeleteStatus === 2
|
|
|
? deleteLabelMap[res.Data.DeleteStatus]
|
|
|
: data.EdbCode? this.$t('Edb.MsgPrompt.del_edb_confirm')/* '删除后指标和指标值均不可使用,确认删除吗?' */:/* '确定删除当前目录吗?' */this.$t('Edb.MsgPrompt.del_menu_confirm'),
|
|
@@ -1525,6 +1562,36 @@ export default {
|
|
|
})
|
|
|
|
|
|
},
|
|
|
+ getRouteUrl(table){
|
|
|
+ /**
|
|
|
+ 1 // 自定义excel
|
|
|
+ 2 // 时间序列表格
|
|
|
+ 3 // 混合表格
|
|
|
+ 4 // 自定义分析表格
|
|
|
+ 5 // 平衡表
|
|
|
+ */
|
|
|
+ let url=''
|
|
|
+ switch (table.Source) {
|
|
|
+ case 1:
|
|
|
+ url = this.$router.resolve({ path: '/sheetAnalysisList',query:{code:table.UniqueCode,id:table.ExcelInfoId}}).href;
|
|
|
+ break;
|
|
|
+ case 2:
|
|
|
+ url = this.$router.resolve({ path: '/sheetTimeList',query:{code:table.UniqueCode,id:table.ExcelInfoId}}).href;
|
|
|
+ break;
|
|
|
+ case 3:
|
|
|
+ url = this.$router.resolve({ path: '/sheetMixedList',query:{code:table.UniqueCode,id:table.ExcelInfoId}}).href;
|
|
|
+ break;
|
|
|
+ case 4:
|
|
|
+ url = this.$router.resolve({ path: '/sheetList',query:{code:table.UniqueCode,id:table.ExcelInfoId}}).href;
|
|
|
+ break;
|
|
|
+ case 5:
|
|
|
+ url = this.$router.resolve({ path: '/viewBalanceSheet',query:{id:table.ExcelInfoId}}).href;
|
|
|
+ break;
|
|
|
+ default:
|
|
|
+ break;
|
|
|
+ }
|
|
|
+ return url
|
|
|
+ },
|
|
|
/* 删除方法 */
|
|
|
delHandle(ClassifyId,EdbInfoId) {
|
|
|
dataBaseInterface.nodeDelete({
|
|
@@ -1785,7 +1852,7 @@ export default {
|
|
|
|
|
|
/* 查看计算公式 打开弹窗 */
|
|
|
viewNode(node,data) {
|
|
|
- const { EdbInfoId,Source } = data;
|
|
|
+ const { EdbInfoId,Source } = this.EdbData;
|
|
|
|
|
|
//代码运算指标
|
|
|
if( Source === 27 ) return this.$router.push({
|
|
@@ -1801,7 +1868,7 @@ export default {
|
|
|
}).then(res => {
|
|
|
if(res.Ret !== 200) return
|
|
|
this.setComputedDialogForm(Source,res.Data,true);
|
|
|
- switch (data.Source) {
|
|
|
+ switch (this.EdbData.Source) {
|
|
|
case 23:
|
|
|
case 24:
|
|
|
this.computed_type = 'joint';
|
|
@@ -1811,7 +1878,7 @@ export default {
|
|
|
this.computed_type = 'alpha';
|
|
|
break
|
|
|
default:
|
|
|
- this.computed_type = data.Source;
|
|
|
+ this.computed_type = this.EdbData.Source;
|
|
|
break
|
|
|
}
|
|
|
})
|