From 2c3183b32664cb114a179dc382e55a247c64e91d Mon Sep 17 00:00:00 2001 From: pan <1029559041@qq.com> Date: Sun, 18 Oct 2020 00:18:17 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E9=A1=B9=E7=9B=AE=E8=8F=9C?= =?UTF-8?q?=E5=8D=95=E6=8E=A5=E5=8F=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- routes/project/info.js | 8 ++++++++ routes/project/project.js | 5 +++-- 2 files changed, 11 insertions(+), 2 deletions(-) create mode 100644 routes/project/info.js diff --git a/routes/project/info.js b/routes/project/info.js new file mode 100644 index 0000000..ada051d --- /dev/null +++ b/routes/project/info.js @@ -0,0 +1,8 @@ +var express = require('express'); +var router = express.Router(); +var mock = require('../../public/javascripts/mock') +var Mock = require("mockjs") + + + +module.exports = router \ No newline at end of file diff --git a/routes/project/project.js b/routes/project/project.js index 99ee96c..a6db11d 100644 --- a/routes/project/project.js +++ b/routes/project/project.js @@ -10,7 +10,7 @@ router.get('/menu', function (req, res, next) { body: { menus: function () { let menus = [] - let config = [{name: '项目基本信息', childMenu: [{name: '一般信息'}, {name: '团队成员'}, {name: '会议信息'}]} + let config = [{name: '项目基本信息', childMenu: [{name: '一般信息',path:'/project/info/baseinfo',selected:true}, {name: '团队成员'}, {name: '会议信息'}]} ,{name: '项目准备', childMenu: [{name: 'HAZOP节点划分'}, {name: 'HAZOP节点复用'}, {name: 'SIF节点划分'}, {name: '矩阵选择'}]} ,{name: 'HAZOP分析', childMenu: [{name: 'HAZOP分析'}, {name: 'HAZOP所有'}]} ,{name:'LOPA定级', childMenu: [{name:'LOPA'},{name:'LOPA表单'},{name:'LOPA所有节点'}]} @@ -26,7 +26,8 @@ router.get('/menu', function (req, res, next) { childMenu.push({ menuId: index, menuName: item.name, - isSelected: false + isSelected: item.selected?item.selected:false, + path:item.path?item.path:'' }) }) menu.childMenu = childMenu