Fix Bug 2294: Incorrect notification in update descriptor
- Fixed the update descriptor issue to show 'Please Change something'
when no changes is made.
Change-Id: I042835c1934c1b94a8e8d880dae8d97b289750df
Signed-off-by: SANDHYA.JS <sandhya.j@tataelxsi.co.in>
diff --git a/src/app/users/project-role/ProjectRoleComponent.ts b/src/app/users/project-role/ProjectRoleComponent.ts
index 3a7e612..0c1121b 100644
--- a/src/app/users/project-role/ProjectRoleComponent.ts
+++ b/src/app/users/project-role/ProjectRoleComponent.ts
@@ -210,6 +210,10 @@
this.projectRoleMap.project_role_mappings.push({ project: res.project_name, role: res.role_name });
});
if (this.projectRoleMap.project_role_mappings.length !== 0) {
+ if (!this.projectRoleForm.dirty) {
+ this.notifierService.notify('warning', this.translateService.instant('PAGE.TOPOLOGY.DATAEMPTY'));
+ return;
+ }
this.isLoadingResults = true;
this.restService.patchResource(apiURLHeader, this.projectRoleMap).subscribe((result: {}): void => {
this.isLoadingResults = false;