|
@@ -244,16 +244,19 @@
|
|
|
<div class="formula-title"> 嵌套公式:</div>
|
|
|
<div class="formula-box">
|
|
|
<div class="formula-list-box" v-for="(item,index) in innerFormulaList" :key="index" @click="checkInnerList(item,index)">
|
|
|
- <span class="formula-list" v-bind:class="{'span-select':index===nowIndex}"> {{'('+Number(index+1)+')'}}{{item.title}}</span>
|
|
|
+ <span class="formula-list" v-if="item&&item['children']&&item['children'].length>0" v-bind:class="{'span-select':index===nowIndex}"> {{'('+Number(index+1)+')'}}{{item['children'][0]['name']}}</span>
|
|
|
<div class="formula-detail" v-if="index===nowIndex">
|
|
|
- <!-- <component ref="dynamiccomponent" v-bind:is="componentMap[item.name]" :formulainfo="item" :curele="equationSelectEle" :formulamap="formulaMap" @uncheck="unCheckEleComp" class="flex1"></component> -->
|
|
|
<component
|
|
|
+ style="font-size:12px"
|
|
|
ref="dynamiccomponent"
|
|
|
- v-bind:is="'date-deviation'"
|
|
|
- :formulainfo="item"
|
|
|
+ v-if="item&&item['children']&&item['children'].length>0"
|
|
|
+ v-bind:is="componentMap[item['children'][0]['name']]"
|
|
|
+ :formulainfo="item['children'][0]"
|
|
|
:curele="equationSelectEle"
|
|
|
:formulamap="formulaMap"
|
|
|
@uncheck="unCheckEleComp"
|
|
|
+ :isShow="false"
|
|
|
+ :inputSize="'small'"
|
|
|
class="flex1">
|
|
|
</component>
|
|
|
<div class="formula-detail-element">
|
|
@@ -554,6 +557,7 @@ import {formulaArrayToString} from "./formulaArrayToString"
|
|
|
import {formulaStringToArray} from "./formulaStringToArray"
|
|
|
|
|
|
import draggable from 'vuedraggable'
|
|
|
+import { log } from '@antv/g2plot/lib/utils';
|
|
|
|
|
|
export default {
|
|
|
components: {
|
|
@@ -690,7 +694,7 @@ export default {
|
|
|
elementTbinfo:false,
|
|
|
istabinfo:false,
|
|
|
stringTypeList:[],
|
|
|
- checkFormula:[],
|
|
|
+ checkFormula:[{initTableName:''}],
|
|
|
checkid:'',
|
|
|
nowIndex:'',
|
|
|
innerFormulaList:[
|
|
@@ -1166,7 +1170,11 @@ export default {
|
|
|
this.processSelectIndex = index;
|
|
|
this.processType = arrName;
|
|
|
item.selected = true;
|
|
|
- this.elementTbinfo=true
|
|
|
+ if(arrName==='resultFormula'){
|
|
|
+ this.elementTbinfo=true
|
|
|
+ }else{
|
|
|
+ this.elementTbinfo=false
|
|
|
+ }
|
|
|
|
|
|
if(this.showFunDetail){
|
|
|
//切到第一个
|
|
@@ -1176,6 +1184,7 @@ export default {
|
|
|
}else{
|
|
|
this.processType = '';
|
|
|
}
|
|
|
+ this.innerFormulaList=this.processFormula//内部元素嵌套公式
|
|
|
},
|
|
|
//点选公式溯源公式
|
|
|
equationClicksouce(item,index){
|
|
@@ -1183,6 +1192,8 @@ export default {
|
|
|
this.nowtitleIndex=index;
|
|
|
this.istabinfo=true;
|
|
|
this.checkid=item.id
|
|
|
+
|
|
|
+ console.log(this.processFormula,'this.processFormula');
|
|
|
this.getEleDeatilList()
|
|
|
|
|
|
|
|
@@ -1468,8 +1479,6 @@ export default {
|
|
|
//let formula = formulaStringToArray('FC.sum(FC.repeat(E[测试测试_222]))+FC.ifelse(3<E[测试测试_333]&&E[测试测试_333]<10,E[测试测试_222]+E[测试测试_333],E[测试测试_333])',detail.map,this.formulaMap);
|
|
|
let formula = formulaStringToArray(detail.formula,detail.map,this.formulaMap);
|
|
|
this.processFormula = formula.processFormula;
|
|
|
- this.processFormula1=formula.processFormula;
|
|
|
-
|
|
|
formula.resultFormula[0].id = this.resultFormula[0].id;
|
|
|
formula.resultFormula[0].name = this.resultFormula[0].name;
|
|
|
formula.resultFormula[0].tableElementKey = this.resultFormula[0].tableElementKey;
|
|
@@ -1793,6 +1802,7 @@ export default {
|
|
|
})
|
|
|
}
|
|
|
}
|
|
|
+ console.log( this.formulaList,' this.formulaList');
|
|
|
}).finally(() => {
|
|
|
resolve();
|
|
|
})
|
|
@@ -1813,11 +1823,12 @@ export default {
|
|
|
|
|
|
},
|
|
|
checkInnerList(item,index){
|
|
|
+ console.log(item,'item');
|
|
|
this.nowIndex=index
|
|
|
// this.innerFormulaList.forEach((item)=>{
|
|
|
// item.selected=false
|
|
|
// })
|
|
|
- item.selected=!item.selected;
|
|
|
+
|
|
|
}
|
|
|
}
|
|
|
};
|