Authored by weiqingting

菜单下拉问题

... ... @@ -31,13 +31,35 @@ $('.leftpanel .nav .parent>a').click(function() {
return false;
});
var isMenuShow=false;
var localStorage=window.localStorage;
// $(".leftpanel .nav .children a").each(function() {
// var attr = $(this).attr('href');
$(".leftpanel .nav .children a").each(function() {
var attr = $(this).attr('href');
// if (attr == window.location.pathname + window.location.search) {
// $(this).parents(".children").show();
// $(this).parent("li").addClass("active");
// $(this).parents(".parent").addClass("parent-focus");
// }
// });
\ No newline at end of file
if (attr == window.location.pathname + window.location.search) {
$(this).parents(".children").show();
$(this).parent("li").addClass("active");
$(this).parents(".parent").addClass("active");
localStorage.setItem("router",attr);
localStorage.getItem("router");
isMenuShow=true;
}
});
if(!isMenuShow&&localStorage.getItem("router")){
$(".leftpanel .nav .children a").each(function() {
var attr = $(this).attr('href');
if (localStorage.getItem("router") == attr) {
$(this).parents(".children").show();
$(this).parent("li").addClass("active");
$(this).parents(".parent").addClass("active");
isMenuShow=true;
}
});
}
// LocalStorage.setItem("router",);
\ No newline at end of file
... ...
... ... @@ -3,8 +3,8 @@
* 入口管理
*/
//exports.domain = require('../config/common.js').domain;
exports.domain = "http://172.16.6.127:8088/platform";
exports.domain = require('../config/common.js').domain;
// exports.domain = "http://172.16.6.127:8088/platform";
exports.res = [
{//入口信息管理界面
... ...
... ... @@ -3,8 +3,8 @@
* APP意见反馈管理
*/
//exports.domain = require('../config/common.js').domain;
exports.domain = "http://172.16.6.127:8088/platform";
exports.domain = require('../config/common.js').domain;
// exports.domain = "http://172.16.6.127:8088/platform";
exports.res = [
{
... ...
//exports.domain = require('../config/common.js').domain;
exports.domain = require('../config/common.js').domain;
// exports.domain = "http://192.168.102.201:8082/platform";
exports.domain = "http://172.16.6.210:8083/platform";
// exports.domain = "http://172.16.6.210:8083/platform";
exports.res = [
{
... ...
... ... @@ -3,8 +3,8 @@
* 版本管理
*/
//exports.domain = require('../config/common.js').domain;
exports.domain = "http://172.16.6.127:8088/platform";
exports.domain = require('../config/common.js').domain;
// exports.domain = "http://172.16.6.127:8088/platform";
exports.res = [
{
... ...
{{#menu}}
<li {{#if parent}}class="parent {{active}}"{{/if}}>
<li {{#if parent}}class="parent "{{/if}}>
<a href="javascript:;">
<i class="fa fa-suitcase"></i>
<span>{{title}}</span>
... ... @@ -7,7 +7,7 @@
{{#if menu}}
<ul class="children">
{{#menu}}
<li class="{{active}}">
<li >
<a {{#if href}}href="{{href}}"{{/if}}>
<i class="fa fa-suitcase"></i>
<span>{{title}}</span>
... ...