本文整理汇总了C#中Universe.Modules.Web.WebInterface.GetGridSettings方法的典型用法代码示例。如果您正苦于以下问题:C# WebInterface.GetGridSettings方法的具体用法?C# WebInterface.GetGridSettings怎么用?C# WebInterface.GetGridSettings使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Universe.Modules.Web.WebInterface
的用法示例。
在下文中一共展示了WebInterface.GetGridSettings方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Fill
public Dictionary<string, object> Fill (WebInterface webInterface, string filename, OSHttpRequest httpRequest,
OSHttpResponse httpResponse, Dictionary<string, object> requestParameters,
ITranslator translator, out string response)
{
response = null;
var vars = new Dictionary<string, object> ();
var settings = webInterface.GetGridSettings ();
if (requestParameters.ContainsKey ("Submit")) {
settings.Gridname = requestParameters ["Gridname"].ToString ();
settings.Gridnick = requestParameters ["Gridnick"].ToString ();
settings.WelcomeMessage = requestParameters ["WelcomeMessage"].ToString ();
settings.GovernorName = requestParameters ["GovernorName"].ToString ();
settings.RealEstateOwnerName = requestParameters ["RealEstateOwnerName"].ToString ();
settings.BankerName = requestParameters ["BankerName"].ToString ();
settings.MarketplaceOwnerName = requestParameters ["MarketplaceOwnerName"].ToString ();
settings.MainlandEstateName = requestParameters ["MainlandEstateName"].ToString ();
settings.SystemEstateName = requestParameters ["SystemEstateName"].ToString ();
// update main grid setup
webInterface.SaveGridSettings (settings);
response = "Successfully updated grid settings.";
return null;
}
vars.Add ("Gridname", settings.Gridname);
vars.Add ("Gridnick", settings.Gridnick);
vars.Add ("WelcomeMessage", settings.WelcomeMessage);
vars.Add ("GovernorName", settings.GovernorName);
vars.Add ("RealEstateOwnerName", settings.RealEstateOwnerName);
vars.Add ("BankerName", settings.BankerName);
vars.Add ("MarketplaceOwnerName", settings.MarketplaceOwnerName);
vars.Add ("MainlandEstateName", settings.MainlandEstateName);
vars.Add ("SystemEstateName", settings.SystemEstateName);
vars.Add ("GridSettingsManager", translator.GetTranslatedString ("GridSettingsManager"));
vars.Add ("GridnameText", translator.GetTranslatedString ("GridnameText"));
vars.Add ("GridnickText", translator.GetTranslatedString ("GridnickText"));
vars.Add ("WelcomeMessageText", translator.GetTranslatedString ("WelcomeMessageText"));
vars.Add ("GovernorNameText", translator.GetTranslatedString ("GovernorNameText"));
vars.Add ("RealEstateOwnerNameText", translator.GetTranslatedString ("RealEstateOwnerNameText"));
vars.Add ("BankerNameText", translator.GetTranslatedString ("BankerNameText"));
vars.Add ("MarketPlaceOwnerNameText", translator.GetTranslatedString ("MarketPlaceOwnerNameText"));
vars.Add ("MainlandEstateNameText", translator.GetTranslatedString ("MainlandEstateNameText"));
vars.Add ("SystemEstateNameText", translator.GetTranslatedString ("SystemEstateNameText"));
vars.Add ("Save", translator.GetTranslatedString ("Save"));
vars.Add ("No", translator.GetTranslatedString ("No"));
vars.Add ("Yes", translator.GetTranslatedString ("Yes"));
return vars;
}