Plugins have a base WebViewPage to inherit, this offers integration with various Disco services. Plugins can also add Authorization attributes to their Web Handlers and Controller Methods.
This commit is contained in:
@@ -0,0 +1,21 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace Disco.Services.Plugins
|
||||
{
|
||||
public abstract class PluginWebViewPage<T> : Disco.Services.Web.WebViewPage<T>
|
||||
{
|
||||
public WebHelper<T> Plugin { get; private set; }
|
||||
|
||||
public PluginWebViewPage()
|
||||
{
|
||||
var self = this.GetType();
|
||||
var manifest = Plugins.GetPlugin(self.Assembly);
|
||||
|
||||
this.Plugin = new WebHelper<T>(this, manifest);
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user