diff --git a/src/views/planMonitor/editToolTJ/component/menuItem.vue b/src/views/planMonitor/editToolTJ/component/menuItem.vue index ec69f0cfe..df22bd87c 100644 --- a/src/views/planMonitor/editToolTJ/component/menuItem.vue +++ b/src/views/planMonitor/editToolTJ/component/menuItem.vue @@ -1,6 +1,11 @@ @@ -12,9 +17,52 @@ export default { menu: { type: Object, required: true + }, + color: { + type: String, + required: true + }, + check: { + type: Boolean, + default: false + } + }, + methods: { + onClick() { + this.$emit('click'); + }, + onMouseEnter() { + this.$emit('mouseenter'); + }, + onMouseLeave() { + this.$emit('mouseleave'); } } } diff --git a/src/views/planMonitor/editToolTJ/component/menuList.vue b/src/views/planMonitor/editToolTJ/component/menuList.vue index 1a09e6dad..ac3780950 100644 --- a/src/views/planMonitor/editToolTJ/component/menuList.vue +++ b/src/views/planMonitor/editToolTJ/component/menuList.vue @@ -1,12 +1,19 @@ + + diff --git a/src/views/planMonitor/editToolTJ/component/menuNav.vue b/src/views/planMonitor/editToolTJ/component/menuNav.vue index 7605ce434..af9a4114d 100644 --- a/src/views/planMonitor/editToolTJ/component/menuNav.vue +++ b/src/views/planMonitor/editToolTJ/component/menuNav.vue @@ -1,10 +1,16 @@ @@ -23,21 +29,55 @@ export default { menus: { type: Array, required: true + }, + background: { + type: String, + default: '#F6F6F6' + }, + color: { + type: String, + default: '#222' + }, + elNavClass: { + type: String, + default: '' + }, + elMenuClass: { + type: String, + default: '' } }, data() { return { + index: -1, active: -1 } }, methods: { - doClick(el, i){ - if (el.disabled) return; + onClick(el, i){ this.active = i; + if (el.disabled) return; if (el.handle) { - el.handle(el, i); + el.handle(el); + this.onMouseLeave(); } + }, + onMouseEnter(el, i) { + this.index = i; + }, + onMouseLeave(el, i) { + this.index = -1; } } } + diff --git a/src/views/planMonitor/editToolTJ/navBar.vue b/src/views/planMonitor/editToolTJ/navBar.vue index 46edd879a..e6d95120d 100644 --- a/src/views/planMonitor/editToolTJ/navBar.vue +++ b/src/views/planMonitor/editToolTJ/navBar.vue @@ -18,40 +18,138 @@ export default { title: '文件(F)', children: [ { - title: '创建', - click: this.newRunPlan + title: '打开数据库', + handle: this.newRunPlan + }, + { + title: '退出', + handle: this.newRunPlan } ] }, { title: '车站(A)', children: [ + { + title: '车站平面图(F)', + handle: this.newRunPlan + }, + { + title: '追踪间隔时分(I)', + handle: this.newRunPlan, + } ] }, { title: '区间(S)', children: [ + { + title: '区间信息(I)', + handle: this.newRunPlan + } ] }, { title: '车底(C)', children: [ - + { + title: '车底信息(I)', + handle: this.newRunPlan + }, + { + title: '车底折返时间(R)', + handle: this.newRunPlan + } ] }, + { + title: '列车(N)', + children: [ + { + title: '区间运行标尺(E)', + handle: this.newRunPlan + }, + { + title: '列车停站标尺(S)', + handle: this.newRunPlan + }, + { + title: '列车交路管理(S)', + handle: this.newRunPlan, + children: [ + { + title: 'test1', + handle: this.newRunPlan, + children: [ + { + title: 'test1', + handle: this.newRunPlan + }, + { + isSeparation: true + }, + { + title: 'test2', + handle: this.newRunPlan, + children: [ + { + title: 'test1', + handle: this.newRunPlan + }, + { + title: 'test2', + handle: this.newRunPlan + }, + ] + }, + ] + }, + { + title: 'test2', + handle: this.newRunPlan + }, + ] + } + ] + }, { title: '底图结构(D)', children: [ + { + title: '生成地图结构(C)', + handle: this.newRunPlan + }, + { + title: '地图结构管理(M)', + handle: this.newRunPlan + } ] }, { title: '运行图(T)', children: [ + { + title: '运行图编制(G)', + handle: this.newRunPlan + } ] }, { + title: '系统(S)', + children: [ + { + title: '系统参数(P)', + handle: this.newRunPlan + } + ] + }, + { title: '帮助(H)', children: [ + { + title: '有关(A)', + handle: this.newRunPlan + } ] } ] @@ -60,6 +158,9 @@ export default { mounted() { }, methods: { + newRunPlan() { + console.log(11111111) + } } };