Skip to content

Commit

Permalink
Add new locale
Browse files Browse the repository at this point in the history
  • Loading branch information
RomanovM committed Apr 30, 2020
1 parent f1aee2f commit 5b05443
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4122,6 +4122,9 @@
<LocaleResource Name="Admin.Common.Edit">
<Value>Edit</Value>
</LocaleResource>
<LocaleResource Name="Admin.Common.EmptyItemText">
<Value>---</Value>
</LocaleResource>
<LocaleResource Name="Admin.Common.ExcelFile">
<Value>Excel file</Value>
</LocaleResource>
Expand Down Expand Up @@ -8934,9 +8937,6 @@
<LocaleResource Name="Admin.Configuration.Stores.Fields.DefaultLanguage">
<Value>Default language</Value>
</LocaleResource>
<LocaleResource Name="Admin.Configuration.Stores.Fields.DefaultLanguage.DefaultItemText">
<Value>---</Value>
</LocaleResource>
<LocaleResource Name="Admin.Configuration.Stores.Fields.DefaultLanguage.Hint">
<Value>This property allows a store owner to specify a default language for a store. If not specified, then the default language display order will be used.</Value>
</LocaleResource>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -135,8 +135,8 @@ public virtual LanguageModel PrepareLanguageModel(LanguageModel model, Language
}

//prepare available currencies
//TODO: add locale resource for "---"
_baseAdminModelFactory.PrepareCurrencies(model.AvailableCurrencies, defaultItemText: "---");
_baseAdminModelFactory.PrepareCurrencies(model.AvailableCurrencies,
defaultItemText: _localizationService.GetResource("Admin.Common.EmptyItemText"));

//prepare available stores
_storeMappingSupportedModelFactory.PrepareModelStores(model, language, excludeProperties);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,8 @@ public virtual StoreModel PrepareStoreModel(StoreModel model, Store store, bool
}

//prepare available languages
_baseAdminModelFactory.PrepareLanguages(model.AvailableLanguages, defaultItemText: _localizationService.GetResource("Admin.Configuration.Stores.Fields.DefaultLanguage.DefaultItemText"));
_baseAdminModelFactory.PrepareLanguages(model.AvailableLanguages,
defaultItemText: _localizationService.GetResource("Admin.Common.EmptyItemText"));

//prepare localized models
if (!excludeProperties)
Expand Down
6 changes: 6 additions & 0 deletions upgradescripts/4.20-4.30 (under development)/upgrade.sql
Original file line number Diff line number Diff line change
Expand Up @@ -874,6 +874,12 @@ set @resources='
<LocaleResource Name="Account.AssociatedExternalAuth.AccountAlreadyAssigned">
<Value>Account is already assigned</Value>
</LocaleResource>
<LocaleResource Name="Admin.Configuration.Stores.Fields.DefaultLanguage.DefaultItemText">
<Value></Value>
</LocaleResource>
<LocaleResource Name="Admin.Common.EmptyItemText">
<Value>---</Value>
</LocaleResource>
</Language>
'

Expand Down

0 comments on commit 5b05443

Please sign in to comment.