Class NewItemCommand
This command executes the NewItem system command
Creates a new item of the specified entity type form the NewSingleCommandParam parameter
Inherited Members
Namespace: LemonEdge.Client.Core.Commands.Core
Assembly: LemonEdge.ClientCore.dll
Syntax
[CommandDescriptorOptions(Command.NewItem, typeof(NewSingleCommandParam))]
public class NewItemCommand : EPCommand, IHasChildren<EPCommandWithDescriptor>, IHasChildren, IEPCommand, ICommand, IDisposable
Constructors
NewItemCommand(IRootController, IModelLayoutCommon)
Declaration
public NewItemCommand(IRootController root, IModelLayoutCommon owner)
Parameters
Type | Name | Description |
---|---|---|
IRootController | root | |
IModelLayoutCommon | owner |
Methods
InternalCanExecute(object)
Returns if this command can be executed or not from the client application UI
You must override InternalCanExecute(object?) or InternalCanExecuteAsync(object?) in order to implement if it can be executed
Declaration
public override bool InternalCanExecute(object parameter)
Parameters
Type | Name | Description |
---|---|---|
object | parameter | The command parameter |
Returns
Type | Description |
---|---|
bool | If this command can be executed or not from the client application UI |
Overrides
InternalExecuteAsync(object)
Opens a collection item of the entity type specified from the parameter
serialized string of
the AnySingleCommandParam parameter
Declaration
public override Task InternalExecuteAsync(object parameter)
Parameters
Type | Name | Description |
---|---|---|
object | parameter | A serialized string instance of the AnySingleCommandParam paramter for this command |
Returns
Type | Description |
---|---|
Task |