本帖最后由 ysk007 于 2015-4-23 09:38 编辑
两个login.w文件增加游客登录按钮,按钮事件中增加下面的代码
this.comp("name").val("guest");
this.comp("password").val("163728");
this.login();
return false;
portal/pc/changePassword/changePassword.js中增加游客不能修改密码
//游客不能改密码
var curPerson = this.getContext().getCurrentPersonName();
if(curPerson == '游客'){
this.comp('alert').show({
type: 'OK',
message: '游客不能修改密码'
});
return;
}
portal/pc/changePassword/changePassword.js中增加游客不能修改密码
//游客不能改密码
var curPerson = this.getContext().getCurrentPersonName();
if(curPerson == '游客'){
justep.Util.hint("游客不能修改密码!", {type: 'danger', parent: this.getRootNode()});
return;
}
|