📄 sysclientconfig.cs
字号:
namespace Imps.Client.Core
{
using System;
using System.IO;
using System.Xml;
public class SysClientConfig
{
private Imps.Client.Core.SystemSetting _systemSetting;
public const string REDIRECT_URL_BASE_DEFAULT = "https://uid.fetion.com.cn/SSIPortal/Redirect.aspx?key=";
public SysClientConfig(Imps.Client.Core.SystemSetting systemSetting)
{
this._systemSetting = systemSetting;
}
public override string ToString()
{
using (StringWriter w = new StringWriter())
{
using (XmlTextWriter tw = new XmlTextWriter(w))
{
tw.WriteStartElement("client-config");
tw.WriteAttributeString("version", this._systemSetting.SysClientConfigVersion.ToString());
this.WriteKeyValue(tw, "fee-charge-desc-url", "fee-charge-desc-url", this.NN_FreeChargeDescUrl);
this.WriteKeyValue(tw, "info-redirect-url", "info-redirect-url", this.NN_InfoRedirectUrl);
this.WriteKeyValue(tw, "ivr-charge-desc", "ivr-charge-desc", this.NN_IvrChargeDesc);
this.WriteKeyValue(tw, "mobile-no-dist", "mobile-no-dist", this.NN_MobileNoDist);
this.WriteKeyValue(tw, "online-garden-desc", "online-garden-desc", this.NN_OnlineGardenDes);
this.WriteKeyValue(tw, "online-no-buddies", "online-no-buddies", this.NN_OnlineNoBuddies);
this.WriteKeyValue(tw, "sms-mode-invite-buddy", "sms-mode-invite-buddy", this.NN_SmsModeInviteBuddy);
this.WriteKeyValue(tw, "sms-mode-main-desc", "sms-mode-main-desc", this.NN_SmsModeMainDes);
this.WriteKeyValue(tw, "sms-mode-no-contact-list", "sms-mode-no-contact-list", this.NN_SmsModeNoContactList);
this.WriteKeyValue(tw, "sysmsg-daily-display-count", "sysmsg-daily-display-count", this.NN_DailyMsgCount.ToString());
this.WriteKeyValue(tw, "group-meaning-url", "group-meaning-url", this.NN_GroupMeaningUrl);
this.WriteKeyValue(tw, "how-to-create-group-url", "how-to-create-group-url", this.NN_CreateGroupUrl);
this.WriteKeyValue(tw, "how-to-find-group-url", "how-to-find-group-url", this.NN_FindGroupUrl);
this.WriteKeyValue(tw, "no-responsibility-declaration-url", "no-responsibility-declaration-url", this.NN_ResponsibilityDeclUrl);
this.WriteKeyValue(tw, "score-faq-url", "score-faq-url", this.NN_ScoreFaqUrl);
tw.WriteEndElement();
}
return w.ToString();
}
}
private void WriteKeyValue(XmlTextWriter tw, string nodeName, string key, string value)
{
tw.WriteStartElement(nodeName);
tw.WriteAttributeString("key", key);
tw.WriteAttributeString("value", value);
tw.WriteEndElement();
}
public string NN_CreateGroupUrl
{
get
{
return this._systemSetting.GetPropertyValue<string>("how-to-create-group-url");
}
}
public int NN_DailyMsgCount
{
get
{
try
{
return int.Parse(this._systemSetting.GetPropertyValue<string>("sysmsg-daily-display-count", "3"));
}
catch
{
return 3;
}
}
}
public string NN_FindGroupUrl
{
get
{
return this._systemSetting.GetPropertyValue<string>("how-to-find-group-url");
}
}
public string NN_FreeChargeDescUrl
{
get
{
return this._systemSetting.GetPropertyValue<string>("fee-charge-desc-url");
}
}
public string NN_GroupMeaningUrl
{
get
{
return this._systemSetting.GetPropertyValue<string>("group-meaning-url");
}
}
public string NN_InfoRedirectUrl
{
get
{
return this._systemSetting.GetPropertyValue<string>("info-redirect-url", "https://uid.fetion.com.cn/SSIPortal/Redirect.aspx?key=");
}
}
public string NN_IvrChargeDesc
{
get
{
return this._systemSetting.GetPropertyValue<string>("ivr-charge-desc", "资费请咨询当地10086");
}
}
public string NN_MobileNoDist
{
get
{
return this._systemSetting.GetPropertyValue<string>("mobile-no-dist");
}
}
public string NN_OnlineGardenDes
{
get
{
return this._systemSetting.GetPropertyValue<string>("online-garden-desc");
}
}
public string NN_OnlineNoBuddies
{
get
{
return this._systemSetting.GetPropertyValue<string>("online-no-buddies");
}
}
public string NN_ResponsibilityDeclUrl
{
get
{
return this._systemSetting.GetPropertyValue<string>("no-responsibility-declaration-url");
}
}
public string NN_ScoreFaqUrl
{
get
{
return this._systemSetting.GetPropertyValue<string>("score-faq-url");
}
}
public string NN_SmsModeInviteBuddy
{
get
{
return this._systemSetting.GetPropertyValue<string>("sms-mode-invite-buddy");
}
}
public string NN_SmsModeMainDes
{
get
{
return this._systemSetting.GetPropertyValue<string>("sms-mode-main-desc");
}
}
public string NN_SmsModeNoContactList
{
get
{
return this._systemSetting.GetPropertyValue<string>("sms-mode-no-contact-list");
}
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -