-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Minor fixes for localizations (#8726)
* wip fixing Fields/TaxonomyFieldList.cshtml * restored selector for expando label/handle * cleanup * fixed comparison to find parent blog # Conflicts: # src/Orchard.Web/Modules/Orchard.Blogs/BlogsLocalizationExtensions/Handlers/BlogPostPartHandler.cs * fixed initialization of localizedtaxonomyfields * Checks culture equality based on strings instead of culture records * If term is culture neutral it is added to the applied terms list without looking for its localization. # Conflicts: # src/Orchard.Web/Modules/Orchard.Taxonomies/Controllers/LocalizedTaxonomyController.cs * Added AdminLocalizedTaxonomyController to properly managed localized taxonomies back office calls. # Conflicts: # src/Orchard.Web/Modules/Orchard.Taxonomies/Controllers/LocalizedTaxonomyController.cs # src/Orchard.Web/Modules/Orchard.Taxonomies/Views/EditorTemplates/Fields/TaxonomyFieldList.cshtml * Added selectedValues parameter to controller call --------- Co-authored-by: HermesSbicego-Laser <hermes.sbicego@laser-group.com> Co-authored-by: Andrea Piovanelli <andrea.piovanelli@laser-group.com>
- Loading branch information
1 parent
4a05e77
commit 151bb12
Showing
6 changed files
with
213 additions
and
99 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
34 changes: 34 additions & 0 deletions
34
src/Orchard.Web/Modules/Orchard.Taxonomies/Controllers/AdminLocalizedTaxonomyController.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
using System.Web.Mvc; | ||
using System.Web.Routing; | ||
using Orchard.ContentManagement.MetaData; | ||
using Orchard.Environment.Extensions; | ||
using Orchard.Localization.Services; | ||
using Orchard.Taxonomies.Services; | ||
using Orchard.UI.Admin; | ||
|
||
namespace Orchard.Taxonomies.Controllers { | ||
[OrchardFeature("Orchard.Taxonomies.LocalizationExtensions")] | ||
public class AdminLocalizedTaxonomyController : LocalizedTaxonomyController { | ||
private readonly RequestContext _requestContext; | ||
|
||
public AdminLocalizedTaxonomyController(IContentDefinitionManager contentDefinitionManager, | ||
ILocalizationService localizationService, | ||
ITaxonomyService taxonomyService, | ||
ITaxonomyExtensionsService | ||
taxonomyExtensionsService, | ||
RequestContext requestContext) : base(contentDefinitionManager, | ||
localizationService, | ||
taxonomyService, | ||
taxonomyExtensionsService) { | ||
|
||
_requestContext = requestContext; | ||
} | ||
|
||
[OutputCache(NoStore = true, Duration = 0)] | ||
public new ActionResult GetTaxonomy(string contentTypeName, string taxonomyFieldName, int contentId, string culture, string selectedValues) { | ||
AdminFilter.Apply(_requestContext); | ||
|
||
return GetTaxonomyInternal(contentTypeName, taxonomyFieldName, contentId, culture, selectedValues); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.