Authored by weiqingting

tijiao

... ... @@ -85,6 +85,9 @@ module.exports = {
userInfo = { auth: userData, uid: userData.pid, name: userData.truename, right: {},shopList:[]};
allRes.data.forEach(function (data) {
if (data.platform_id == Iaccount.WEBSITE) {
if(data.path.indexOf("/operations/helpcategory")>-1){
console.log(data.path);
}
userInfo.right[data.path] = true;
}
});
... ... @@ -124,6 +127,9 @@ module.exports = {
if (path && user.right[path]) {
common.isUsedMenuAuth(user.auth.pid,user.auth.role_id,path).done(function(isURes){
result = { code: 200, message: "具有权限" };
if(isURes.data){
result={code:isURes.data.code,message:isURes.data.errmsg};
}
return callback(null, result);
},function(error){
return callback(error, result);
... ...
ERROR:<%message%>
\ No newline at end of file
ERROR:用户失效,或者没有权限
\ No newline at end of file
... ...
... ... @@ -3,7 +3,11 @@ module.exports=function(Filter){
if(gray.code==200){
next();
}else{
res.redirect('/login');
if(req.xhr){
res.json(gray);
}else{
res.redirect('/login');
}
}
});
};
... ...
... ... @@ -181,6 +181,7 @@ var $=require('jquery');
uploadComplete: function(r){
var me = this;
try{
r=r.match(/\{.*\}/g)[0];
var json = eval('('+r+')');
Base.callback(me.editor, me.dialog, json.url, json.state);
}catch (e){
... ... @@ -378,7 +379,7 @@ var $=require('jquery');
dataType: 'json',
method:'post',
success:function(res){
var data = res.data;
var data = res;
if (res.code == 200 && data.data.list instanceof Array && data.data.list[0].pictureBoList instanceof Array) {
$.each(data.data.list[0].pictureBoList, function(i, value) {
var url=value.fileName;
... ...
... ... @@ -7,9 +7,9 @@
.edui-dialog-image .edui-image-form{position: absolute;left: 0px;top: 0px;width: 100%;height: 100%;opacity: 0;cursor: pointer;}
.edui-dialog-image .edui-image-form .edui-image-file{width: 100%;height:100%;filter: alpha(opacity=0)}
.edui-dialog-image .edui-image-upload1 .edui-image-icon{display: inline-block;width:44px;height:38px;background-image: url('../assets/images/upload1.png')}
.edui-dialog-image .edui-image-upload1 .edui-image-icon{display: inline-block;width:44px;height:38px;background-image: url('assets/images/upload1.png')}
.edui-dialog-image .edui-image-upload1 .edui-image-icon.hover{background-position: -50px 0;}
.edui-dialog-image .edui-image-upload2 .edui-image-icon{display: inline-block;width:120px;height:120px;background-image: url('../assets/images/upload2.png')}
.edui-dialog-image .edui-image-upload2 .edui-image-icon{display: inline-block;width:120px;height:120px;background-image: url('assets/images/upload2.png')}
.edui-dialog-image .edui-image-dragTip{position: absolute;display:none;top:50%;left:50%;margin-top:30px;margin-left: -60px;
color: #222;font-size:14px;text-shadow: 0px 2px 3px #555;}
... ... @@ -38,5 +38,5 @@
/*common*/
.edui-dialog-image .edui-image-item{position:relative;float:left;width:120px;height:120px;border: 1px solid #CCC;cursor: default;margin: 5px 0 0 5px;}
.edui-dialog-image .edui-image-item .edui-image-pic{position: absolute;left:-9999px;}
.edui-dialog-image .edui-image-item .edui-image-close{position:absolute;right:0;background: url('../assets/images/close.png');width:17px;height:17px;cursor:pointer;z-index:1}
.edui-dialog-image .edui-image-item .edui-image-close{position:absolute;right:0;background: url('assets/images/close.png');width:17px;height:17px;cursor:pointer;z-index:1}
.edui-dialog-image .edui-image-item.hover .edui-image-close{display: block;}
... ...