Skip to content
This repository has been archived by the owner on Dec 13, 2021. It is now read-only.

Commit

Permalink
Preserves the ContentType order, as definied in the PreValue
Browse files Browse the repository at this point in the history
Fixes #36
  • Loading branch information
leekelleher committed Aug 14, 2018
1 parent 1d3e703 commit bce419f
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ public IEnumerable<object> GetAllContentTypes()
[HttpGet]
public IEnumerable<object> GetContentTypesByGuid([ModelBinder] Guid[] guids)
{
var contentTypes = Services.ContentTypeService.GetAllContentTypes(guids).OrderBy(x => x.SortOrder).ToList();
var contentTypes = Services.ContentTypeService.GetAllContentTypes(guids).OrderBy(x => Array.IndexOf(guids, x.Key)).ToList();
var blueprints = Services.ContentService.GetBlueprintsForContentTypes(contentTypes.Select(x => x.Id).ToArray()).ToArray();

// NOTE: Using an anonymous class, as the `ContentTypeBasic` type is heavier than what we need (for our requirements)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ <h5 ng-show="selectBlueprint"><localize key="blueprints_selectBlueprint">Select

<ul class="umb-actions umb-actions-child" ng-show="selectContentType">

<li data-element="action-create-{{docType.alias}}" ng-repeat="docType in allowedTypes | orderBy:'name':false">
<li data-element="action-create-{{docType.alias}}" ng-repeat="docType in allowedTypes">
<a ng-click="createOrSelectBlueprintIfAny(docType)">
<i class="large {{docType.icon}}"></i>
<span class="menu-label">
Expand Down

0 comments on commit bce419f

Please sign in to comment.