Class EntityTransactionsController
A standard base controller for displaying all the transactions against transactional entity. All transactions with this SingleItem as their EntityID
Inheritance
Implements
Inherited Members
Namespace: LemonEdge.Client.Core.Views.Controllers
Assembly: LemonEdge.ClientCore.dll
Syntax
public class EntityTransactionsController : BaseGridRelatedCollectionController<IObjectEntityBase, ITransaction>, IBaseGridController, ICollectionExportable, INewGridItemImplementor<ITransaction>, ICopyGridItemImplementor<ITransaction>, IGrid, IDeleteGridItemImplementor<ITransaction>, ISearchController, IModelViewController
Constructors
EntityTransactionsController(IBaseGridRelatedCollection<IObjectEntityBase, ITransaction>)
Creates a new EntityTransactionsController
Declaration
public EntityTransactionsController(IBaseGridRelatedCollection<IObjectEntityBase, ITransaction> view)
Parameters
Type | Name | Description |
---|---|---|
IBaseGridRelatedCollection<IObjectEntityBase, ITransaction> | view | The IBaseGridRelatedCollection view implementation using the UI components of the client application |
Properties
AllowCopyCommand
Indicates that by default selected entities can be copied by the user with the copy command
Declaration
public override bool AllowCopyCommand { get; }
Property Value
Type | Description |
---|---|
bool |
Overrides
AllowXMLImportExport
Indicates the command to allow the xml export of the data by the user is included in the InitCommands(IList<ViewCommand>)
The default is true if the type ITransaction derives from ISetCopier
Declaration
public override bool AllowXMLImportExport { get; }
Property Value
Type | Description |
---|---|
bool |
Overrides
AutoOpenNewItemInTab
Indicates when creating a new item in the grid that it should automatically be opened in a new tab as well
The default is true if the type ITransaction is an entity that is not a IsStandingDataEntity
Declaration
public override bool AutoOpenNewItemInTab { get; }
Property Value
Type | Description |
---|---|
bool |
Overrides
CollectionRelationshipColumnName
Specified that the property EntityID holds the relationship from an ITransaction to the parent IObjectEntityBase SingleItem of this view
Declaration
public override string CollectionRelationshipColumnName { get; }
Property Value
Type | Description |
---|---|
string |
Overrides
DefaultSearchColumn
The name of the column to use in the default search of text in the grid
Declaration
protected override string DefaultSearchColumn { get; }
Property Value
Type | Description |
---|---|
string |
Overrides
Methods
AlterQuery(QueryableExecuter<ITransaction>)
Returns all transactions ordered by Date/Reference
Declaration
protected override QueryableExecuter<ITransaction> AlterQuery(QueryableExecuter<ITransaction> query)
Parameters
Type | Name | Description |
---|---|---|
QueryableExecuter<ITransaction> | query | The transaction query |
Returns
Type | Description |
---|---|
QueryableExecuter<ITransaction> | The query to find all transactions for this grid |
Overrides
ColumnNames()
Adds the standard header columns from ColumnNames()
Declaration
protected override IEnumerable<ControlDisplayInfoLight> ColumnNames()
Returns
Type | Description |
---|---|
IEnumerable<ControlDisplayInfoLight> | The standard header columns for a grid of header transactions |
Overrides
DeleteCommandIsQuickAccess()
Declaration
public override bool DeleteCommandIsQuickAccess()
Returns
Type | Description |
---|---|
bool |
Overrides
InitAsync()
Provides the controller a chance to initialize any dependant data. Called once by the system after controller creation.
Declaration
public override Task InitAsync()
Returns
Type | Description |
---|---|
Task | A task indicating the completion of the operation |
Overrides
InitCommands(IList<ViewCommand>)
Adds the ViewAllocation and TransactionSettingsEdit commands to the standard grid commands
Declaration
protected override void InitCommands(IList<ViewCommand> commands)
Parameters
Type | Name | Description |
---|---|---|
IList<ViewCommand> | commands | The commands for this transaction grid |
Overrides
UpdateNewItem(ITransaction)
ENsures all new transactions created in this grid have the EntityID set to the id of this parent SingleItem entity
Declaration
protected override Task UpdateNewItem(ITransaction item)
Parameters
Type | Name | Description |
---|---|---|
ITransaction | item | The new transaction |
Returns
Type | Description |
---|---|
Task | A task indicating the completion of this operation |