2018-09-20 17:22:39 +02:00
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
|
using System.Linq;
|
|
|
|
|
|
using Umbraco.Core;
|
|
|
|
|
|
using Umbraco.Core.Composing;
|
|
|
|
|
|
using Umbraco.Core.Models.ContentEditing;
|
|
|
|
|
|
|
|
|
|
|
|
namespace Umbraco.Web.ContentApps
|
|
|
|
|
|
{
|
|
|
|
|
|
public class ContentAppDefinitionCollection : BuilderCollectionBase<IContentAppDefinition>
|
|
|
|
|
|
{
|
|
|
|
|
|
public ContentAppDefinitionCollection(IEnumerable<IContentAppDefinition> items)
|
|
|
|
|
|
: base(items)
|
|
|
|
|
|
{ }
|
|
|
|
|
|
|
|
|
|
|
|
public IEnumerable<ContentApp> GetContentAppsFor(object o)
|
|
|
|
|
|
{
|
2018-09-21 09:42:36 +02:00
|
|
|
|
return this.Select(x => x.GetContentAppFor(o)).WhereNotNull().OrderBy(x => x.Weight);
|
2018-09-20 17:22:39 +02:00
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|