PortalSecurity.IsInRoles("Admins")(amdin文件夹下的文件只用具有Admins权限就都可以访问)
PortalSecurity.HasEditPermissions(moduleId)(其他页面中判断是否具有编辑权限)
base.UserID != -1 说明没有登陆 还有UserInfo
if (PortalSecurity.IsInRole(base.PortalSettings.RegisteredRoleName)) //true 表示登陆
{
this.EditTable.Visible = true;
}
else
{
this.EditTable.Visible = false;
}
{
this.EditTable.Visible = true;
}
else
{
this.EditTable.Visible = false;
}