Averos View-Edit Entity Component
1. Description
Averos View Edit Entity Component is a generic angular component that is aimed to fit to any view
, edit
or create
use case that is targeting a specific entity.
The component is self-context aware and adapt its view UI according to the target use case; meaning that it could switch from view to edit layout and vice versa with respect to the desired implementation depending on its current Use Case View Layout context.
Any time you change from one view type to another, the related view layout type will change accordingly.
AverosViewEditEntity
generic component, fits well with CRUD use cases and could, alone, fully meet CREATE, VIEW, EDIT use cases, all in the same component.
Averos has defined a custom workflow, named create-entity-uc
, that leverage this generic component and which will generate a fully functional CREATE entity use case based on a given entity.
2. Component’s usage example
<averos-view-edit-entity *ngIf="reactiveForm"
[useCaseConfig]="useCaseConfig"
[entityUseCaseViewLayout$]="useCaseViewLayout"
[reactiveForm]="reactiveForm"
[editModeActivated]="editModeActivated"
[displayActions]="true"
(submitForm)="onSubmit($event)"
(updateEditMode)="updateEditMode($event)"
(cloneEvent)="clone()"
(editEvent)="edit()"
(updateRelationCollectionEvent)="updateRelationCollection($event)">
</averos-view-edit-entity>