Fix Bug 1975: Map view Issue in VIM account 42/11842/2
authorSANDHYA.JS <sandhya.j@tataelxsi.co.in>
Tue, 5 Apr 2022 03:28:00 +0000 (08:58 +0530)
committerramanathan <ramerama@tataelxsi.co.in>
Thu, 7 Apr 2022 05:36:58 +0000 (07:36 +0200)
- Map view in VIM account will not show Invalid location when the location is not provided.
- Added an error message for quota limit in project section when quota limit is exceeded

Change-Id: I175fd2df02d320534e0f02bf3e3dd1882f195546
Signed-off-by: SANDHYA.JS <sandhya.j@tataelxsi.co.in>
src/app/projects/project-create-update/ProjectCreateUpdateComponent.ts
src/app/vim-accounts/vim-account-details/VimAccountDetailsComponent.ts
src/assets/i18n/de.json
src/assets/i18n/en.json
src/assets/i18n/es.json
src/assets/i18n/pt.json

index 5eb2d5d..bb1207a 100644 (file)
@@ -164,6 +164,12 @@ export class ProjectCreateUpdateComponent implements OnInit {
             message: 'Done'
         };
         this.sharedService.cleanForm(this.projectForm);
+        for (const data of this.quotaItems) {
+            if (this.getFormControl(data.value).value > data.maxValue) {
+                this.notifierService.notify('error', this.translateService.instant('PAGE.PROJECT.QUOTALIMIT'));
+                break;
+            }
+        }
         if (!this.projectForm.invalid) {
             if (userType === 'Add') {
                 this.createProject();
index 18dffa0..f580e8a 100644 (file)
@@ -361,10 +361,12 @@ export class VimAccountDetailsComponent implements OnInit {
         if (this.getLocation !== []) {
             this.getLocation.filter((loc: GetLocation) => {
                 if (loc.location !== '') {
-                    const getLatLong: string[] = loc.location.split(',');
-                    this.lng = +getLatLong[CONSTANTNUMBER.splitLongitude];
-                    this.lat = +getLatLong[CONSTANTNUMBER.splitLatitude];
-                    this.addMarker(getLatLong[0], loc.id, loc.name);
+                    if (loc.location !== ',,') {
+                        const getLatLong: string[] = loc.location.split(',');
+                        this.lng = +getLatLong[CONSTANTNUMBER.splitLongitude];
+                        this.lat = +getLatLong[CONSTANTNUMBER.splitLatitude];
+                        this.addMarker(getLatLong[0], loc.id, loc.name);
+                    }
                 }
             });
         }
index ffa152f..54dfe73 100644 (file)
             "NEWPROJECT": "Nieuw project",
             "CREATEDSUCCESSFULLY": "Projekt erfolgreich erstellt",
             "UPDATEDSUCCESSFULLY": "Projekt erfolgreich aktualisiert",
-            "QUOTA": "Kontingentlimit"
+            "QUOTA": "Kontingentlimit",
+            "QUOTALIMIT": "Kontingentlimit überschritten"
         },
         "NSPACKAGE": {
             "ADDNSPACKAGE": "Verfassen Sie eine neue NS",
index 1642dbc..200e1b9 100644 (file)
             "NEWPROJECT": "New Project",
             "CREATEDSUCCESSFULLY": "Project Created Successfully",
             "UPDATEDSUCCESSFULLY": "Project Updated Successfully",
-            "QUOTA": "Quota Limit"
+            "QUOTA": "Quota Limit",
+            "QUOTALIMIT": "Quota Limit exceeded"
         },
         "NSPACKAGE": {
             "ADDNSPACKAGE": "Compose a new NS",
index d826ccb..3f6092c 100644 (file)
             "NEWPROJECT": "Nuevo proyecto",
             "CREATEDSUCCESSFULLY": "Proyecto creado correctamente",
             "UPDATEDSUCCESSFULLY": "Proyecto actualizado correctamente",
-            "QUOTA": "Límite de cuota"
+            "QUOTA": "Límite de cuota",
+            "QUOTALIMIT": "Límite de cuota excedido"
         },
         "NSPACKAGE": {
             "ADDNSPACKAGE": "Componer un nuevo NS",
index bd9d91b..64a5c13 100644 (file)
             "NEWPROJECT": "Novo projeto",
             "CREATEDSUCCESSFULLY": "Projeto criado com sucesso",
             "UPDATEDSUCCESSFULLY": "Projeto atualizado com sucesso",
-            "QUOTA": "Limite de cota"
+            "QUOTA": "Limite de cota",
+            "QUOTALIMIT": "Limite de cota excedido"
         },
         "NSPACKAGE": {
             "ADDNSPACKAGE": "Componha um novo NS",