|
@@ -135,7 +135,25 @@
|
|
|
|
|
|
<!-- 右键菜单 -->
|
|
|
<div class="contextMenu-wrapper" id="contextMenu-wrapper" @mouseleave="hideContextMenu">
|
|
|
- <div :class="['item',{'deletesty': menu.key==='reset'}]" v-for="menu in config.contextMenuOption" :key="menu.key" @click="handleContext(menu.key)">{{menu.label}}</div>
|
|
|
+ <div :class="['item',{'deletesty': menu.key==='reset'}]" v-for="menu in config.contextMenuOption" :key="menu.key" @click="handleContext(menu.key)">
|
|
|
+ {{menu.label}}
|
|
|
+
|
|
|
+ <i class="el-icon-arrow-right" v-if="menu.children"></i>
|
|
|
+
|
|
|
+ <!-- 二级菜单 -->
|
|
|
+ <div class="subMenu-wrapper" v-if="menu.children">
|
|
|
+ <div slot="reference" class="item" v-for="submenu in menu.children" :key="submenu.key" @click="edbCalculateInsertOpen(menu.key,submenu)">
|
|
|
+ <el-popover
|
|
|
+ width="300"
|
|
|
+ trigger="hover"
|
|
|
+ placement="right"
|
|
|
+ >
|
|
|
+ <div v-html="formulaTip.get(submenu.fromEdbKey)"></div>
|
|
|
+ <div slot="reference" style="width:100%">{{submenu.label}}</div>
|
|
|
+ </el-popover>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
@@ -179,6 +197,7 @@ import { dataBaseInterface } from '@/api/api.js';
|
|
|
import md5 from '@/utils/md5.js';
|
|
|
import selectTargetValueDia from './selectTargetValueDia.vue';
|
|
|
import insertDateDia from './insertDateDia.vue';
|
|
|
+import { formulaTip } from '@/views/dataEntry_manage/databaseComponents/util';
|
|
|
export default {
|
|
|
props: {
|
|
|
disabled: { //是否只预览
|
|
@@ -237,7 +256,8 @@ export default {
|
|
|
isInsertDateDialog: false,//导入日期弹窗
|
|
|
insertDateInfo: {
|
|
|
key: '',
|
|
|
- }
|
|
|
+ },
|
|
|
+ formulaTip
|
|
|
};
|
|
|
},
|
|
|
mounted() {
|
|
@@ -347,6 +367,7 @@ export default {
|
|
|
// 建立插入单元格和依赖单元格关联关系
|
|
|
setRelation(data,cellType=4) {
|
|
|
const { insert_cell } = data;
|
|
|
+
|
|
|
let relation_obj = {
|
|
|
type: cellType,
|
|
|
key: insert_cell.key,
|
|
@@ -639,6 +660,7 @@ export default {
|
|
|
'choose-target': this.selectTargetOpen,//选择指标插入值
|
|
|
'insert-sys-date': this.insertDateOpen,//导入系统日期
|
|
|
'insert-edb-date': this.insertDateOpen,//导入指标日期
|
|
|
+ // 'insert-edb-calculate': this.edbCalculateInsertOpen,//指标计算
|
|
|
'reset': this.clearCell, //清空
|
|
|
'cell-edit': this.insertDateOpen
|
|
|
}
|
|
@@ -827,6 +849,11 @@ export default {
|
|
|
this.insertTargetCell.DataTime = insertValue;
|
|
|
},
|
|
|
|
|
|
+ /* 公式计算弹窗 */
|
|
|
+ edbCalculateInsertOpen(key) {
|
|
|
+ console.log(key)
|
|
|
+ },
|
|
|
+
|
|
|
/* 初始化8行5列 */
|
|
|
initData(initData=null) {
|
|
|
if(initData) {
|
|
@@ -1043,6 +1070,19 @@ export default {
|
|
|
&:hover {
|
|
|
background-color: #f5f7fa;
|
|
|
}
|
|
|
+ &:hover .subMenu-wrapper {
|
|
|
+ display: block;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ .subMenu-wrapper {
|
|
|
+ display: none;
|
|
|
+ padding: 10px 0;
|
|
|
+ box-shadow: 0 1px 4px #999;
|
|
|
+ background: #fff;
|
|
|
+ position: absolute;
|
|
|
+ right: -174px;
|
|
|
+ top: -50%;
|
|
|
}
|
|
|
}
|
|
|
}
|