Class BaseTreeViewController<T>
Inheritance
BaseTreeViewController<T>
Assembly: LemonEdge.ClientCore.dll
Syntax
public abstract class BaseTreeViewController<T> : BaseTreeViewAnyController<T>, ICollectionExportable, ISearchController, IModelViewController where T : IBaseEntity
Type Parameters
Constructors
BaseTreeViewController(IBaseTreeView<T>)
Declaration
public BaseTreeViewController(IBaseTreeView<T> view)
Parameters
Properties
AutoPromptForLabelOnNew
Declaration
protected override bool AutoPromptForLabelOnNew { get; }
Property Value
Overrides
CommandCopy
Provides the ability for an inheriting class to override the Copy command
Declaration
protected override ViewCommand CommandCopy { get; }
Property Value
Overrides
CommandDelete
Provides the ability for an inheriting class to override the Delete command
Declaration
protected override ViewCommand CommandDelete { get; }
Property Value
Overrides
CommandDeleteAllow
Indicates if the view should show the Delete command - default is true
Declaration
protected override bool CommandDeleteAllow { get; }
Property Value
Overrides
CommandNew
Provides the ability for an inheriting class to override the New command
Declaration
protected override ViewCommand CommandNew { get; }
Property Value
Overrides
CommandNewAllow
Indicates if the view should show the New command - Default is true
Declaration
protected override bool CommandNewAllow { get; }
Property Value
Overrides
CommandNewType
Declaration
protected override Type CommandNewType { get; }
Property Value
Overrides
CommandOpen
Provides the ability for an inheriting class to override the Open command
Declaration
protected override ViewCommand CommandOpen { get; }
Property Value
Overrides
Methods
AlterQuery(QueryableExecuter<T>)
Provides an inheriting class the oportunity to alter the default query with custom options
Declaration
protected virtual QueryableExecuter<T> AlterQuery(QueryableExecuter<T> query)
Parameters
Type |
Name |
Description |
QueryableExecuter<T> |
query |
The default query to load all the entities for
|
Returns
Type |
Description |
QueryableExecuter<T> |
The query to load all the relevant tree view entities with
|
CreateCopiedNode(TreeNode<T>, TreeNode<T>)
Declaration
protected override Task<TreeNode<T>> CreateCopiedNode(TreeNode<T> original, TreeNode<T> copiedParent)
Parameters
Returns
Overrides
CreateNewItem()
Creates a new entity of type T
Declaration
protected virtual Task<T> CreateNewItem()
Returns
GetIDValue(T)
Declaration
public override Guid GetIDValue(T item)
Parameters
Type |
Name |
Description |
T |
item |
|
Returns
Overrides
GetQuery()
Declaration
protected virtual QueryableExecuter<T> GetQuery()
Returns
Type |
Description |
QueryableExecuter<T> |
The query to load all the relevant tree view entities with
|
GetQueryForExcelResults()
Returns the query used to load all the entities in the tree view display
Declaration
public override QueryableExecuter GetQueryForExcelResults()
Returns
Overrides
InitCommands(IList<ViewCommand>)
Adds the following commands: Open, New, Delete, MoveUp, MoveDown, and Export Data
Declaration
protected override void InitCommands(IList<ViewCommand> commands)
Parameters
Overrides
InsertAndSelectNewItem(T)
Declaration
protected void InsertAndSelectNewItem(T item)
Parameters
Type |
Name |
Description |
T |
item |
|
LoadItems()
The method used by DisplayUI() to load all the entities for this tree view
Declaration
protected override Task<IEnumerable<T>> LoadItems()
Returns
Type |
Description |
Task<IEnumerable<T>> |
The list of loaded entities to be displayed in the tree view
|
Overrides
OnItemMovedUpOrDown(T, bool)
Declaration
protected virtual void OnItemMovedUpOrDown(T item, bool movedUp)
Parameters
Type |
Name |
Description |
T |
item |
|
bool |
movedUp |
|
UpdateNewItem(T)
Updates the newly created item to be a child of the currently selected tree node in the TreeView if
there is a current treenode selected
Declaration
protected override Task UpdateNewItem(T newItem)
Parameters
Type |
Name |
Description |
T |
newItem |
The new item to be updated as being a child of the currently selected tree node in the tree view
|
Returns
Overrides
Implements
Extension Methods