fix: Correct dependencies of Entity selection in Entity Data Table checks (#2628)
Status and other dependent dropdowns didn't show values dependent correctly on Entity selection. This also fixes the misspelled name part "enity" to "entity". FIXES: WEB-302
This commit is contained in:
+9
-8
@@ -17,14 +17,14 @@ import { STANDALONE_SHARED_IMPORTS } from 'app/standalone-shared.module';
|
||||
* Create Entity Data Table Checks component.
|
||||
*/
|
||||
@Component({
|
||||
selector: 'mifosx-create-enity-data-table-checks',
|
||||
templateUrl: './create-enity-data-table-checks.component.html',
|
||||
styleUrls: ['./create-enity-data-table-checks.component.scss'],
|
||||
selector: 'mifosx-create-entity-data-table-checks',
|
||||
templateUrl: './create-entity-data-table-checks.component.html',
|
||||
styleUrls: ['./create-entity-data-table-checks.component.scss'],
|
||||
imports: [
|
||||
...STANDALONE_SHARED_IMPORTS
|
||||
]
|
||||
})
|
||||
export class CreateEnityDataTableChecksComponent implements OnInit {
|
||||
export class CreateEntityDataTableChecksComponent implements OnInit {
|
||||
/** Create Entity Datatable Checks form. */
|
||||
createEntityForm: UntypedFormGroup;
|
||||
/** Entity Datatable Checks data. */
|
||||
@@ -53,11 +53,12 @@ export class CreateEnityDataTableChecksComponent implements OnInit {
|
||||
) {
|
||||
this.route.data.subscribe((data: { dataTableEntity: any }) => {
|
||||
this.createEntityData = data.dataTableEntity;
|
||||
// hardcoded, because data.dataTableEntity.entities might change anytime its order
|
||||
this.entityTypes = [
|
||||
{ name: 'Client', value: this.createEntityData.entities[0] },
|
||||
{ name: 'Loan', value: this.createEntityData.entities[1] },
|
||||
{ name: 'Group', value: this.createEntityData.entities[2] },
|
||||
{ name: 'Savings Account', value: this.createEntityData.entities[3] }
|
||||
{ name: 'Client', value: 'm_client' },
|
||||
{ name: 'Loan', value: 'm_loan' },
|
||||
{ name: 'Group', value: 'm_group' },
|
||||
{ name: 'Savings Account', value: 'm_savings_account' }
|
||||
];
|
||||
});
|
||||
}
|
||||
Reference in New Issue
Block a user