本文整理汇总了C#中Nop.Core.Domain.Stores.Store.GetLocalized方法的典型用法代码示例。如果您正苦于以下问题:C# Store.GetLocalized方法的具体用法?C# Store.GetLocalized怎么用?C# Store.GetLocalized使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Nop.Core.Domain.Stores.Store
的用法示例。
在下文中一共展示了Store.GetLocalized方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: AddStoreTokens
public virtual void AddStoreTokens(IList<Token> tokens, Store store)
{
tokens.Add(new Token("Store.Name", store.GetLocalized(x => x.Name)));
tokens.Add(new Token("Store.URL", store.Url, true));
var defaultEmailAccount = _emailAccountService.GetEmailAccountById(_emailAccountSettings.DefaultEmailAccountId);
if (defaultEmailAccount == null)
defaultEmailAccount = _emailAccountService.GetAllEmailAccounts().FirstOrDefault();
tokens.Add(new Token("Store.Email", defaultEmailAccount.Email));
//event notification
_eventPublisher.EntityTokensAdded(store, tokens);
}
示例2: AddStoreTokens
public virtual void AddStoreTokens(IList<Token> tokens, Store store, EmailAccount emailAccount)
{
if (emailAccount == null)
throw new ArgumentNullException("emailAccount");
tokens.Add(new Token("Store.Name", store.GetLocalized(x => x.Name)));
tokens.Add(new Token("Store.URL", store.Url, true));
tokens.Add(new Token("Store.Email", emailAccount.Email));
tokens.Add(new Token("Store.CompanyName", store.CompanyName));
tokens.Add(new Token("Store.CompanyAddress", store.CompanyAddress));
tokens.Add(new Token("Store.CompanyPhoneNumber", store.CompanyPhoneNumber));
tokens.Add(new Token("Store.CompanyVat", store.CompanyVat));
//event notification
_eventPublisher.EntityTokensAdded(store, tokens);
}
示例3: AddStoreTokens
public virtual void AddStoreTokens(IList<Token> tokens, Store store, EmailAccount emailAccount)
{
if (emailAccount == null)
throw new ArgumentNullException("emailAccount");
tokens.Add(new Token("Store.Name", store.GetLocalized(x => x.Name)));
tokens.Add(new Token("Store.URL", store.Url, true));
tokens.Add(new Token("Store.Email", emailAccount.Email));
tokens.Add(new Token("Store.CompanyName", store.CompanyName));
tokens.Add(new Token("Store.CompanyAddress", store.CompanyAddress));
tokens.Add(new Token("Store.CompanyPhoneNumber", store.CompanyPhoneNumber));
tokens.Add(new Token("Store.CompanyVat", store.CompanyVat));
tokens.Add(new Token("Twitter.URL", _storeInformationSettings.TwitterLink));
tokens.Add(new Token("Facebook.URL", _storeInformationSettings.FacebookLink));
tokens.Add(new Token("YouTube.URL", _storeInformationSettings.YoutubeLink));
tokens.Add(new Token("GooglePlus.URL", _storeInformationSettings.GooglePlusLink));
//event notification
_eventPublisher.EntityTokensAdded(store, tokens);
}