📄 permissionspageelement.cs
字号:
namespace PowerEasy.Web.Configuration
{
using System;
using System.Configuration;
using System.Globalization;
public sealed class PermissionsPageElement : ConfigurationElement
{
private static readonly ConfigurationProperty m_CheckType = new ConfigurationProperty("checkType", typeof(string), "or");
private static readonly ConfigurationProperty m_OperateCode = new ConfigurationProperty("operateCode", typeof(string), "", ConfigurationPropertyOptions.IsRequired);
private static readonly ConfigurationProperty m_Pageurl = new ConfigurationProperty("url", typeof(string), "", ConfigurationPropertyOptions.IsKey | ConfigurationPropertyOptions.IsRequired);
private static ConfigurationPropertyCollection m_Properties = new ConfigurationPropertyCollection();
public PermissionsPageElement()
{
m_Properties.Add(m_Pageurl);
m_Properties.Add(m_OperateCode);
m_Properties.Add(m_CheckType);
}
public PermissionsPageElement(string elementName)
{
this.Pageurl = elementName;
}
[ConfigurationProperty("checkType")]
public string CheckType
{
get
{
return ((string) base[m_CheckType]).ToLower(CultureInfo.CurrentCulture);
}
set
{
base[m_CheckType] = value;
}
}
[ConfigurationProperty("operateCode", IsRequired=true)]
public string OperateCode
{
get
{
return ((string) base[m_OperateCode]).ToLower(CultureInfo.CurrentCulture);
}
set
{
base[m_OperateCode] = value;
}
}
[ConfigurationProperty("url", IsKey=true, IsRequired=true)]
public string Pageurl
{
get
{
return ((string) base[m_Pageurl]).ToLower(CultureInfo.CurrentCulture);
}
set
{
base[m_Pageurl] = value;
}
}
protected override ConfigurationPropertyCollection Properties
{
get
{
return m_Properties;
}
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -