Quellcode durchsuchen

✨ update ortho-photo layer right after date select

resolves #8
jmacura vor 3 Jahren
Ursprung
Commit
0238e2e647

+ 1 - 0
src/app/calculator/calculator.component.ts

@@ -94,6 +94,7 @@ export class CalculatorComponent implements HsPanelComponent, OnInit {
     this.calcService.selectedDate = `${value.year}-${
       value.month < 10 ? '0' : ''
     }${value.month}-${value.day < 10 ? '0' : ''}${value.day}`;
+    this.calcService.updateImageBackground(this.calcService.selectedDate);
   }
 
   hasDataAvailable(date: NgbDateStruct): boolean {

+ 0 - 1
src/app/calculator/calculator.service.ts

@@ -176,7 +176,6 @@ export class CalculatorService {
       await this.zonesService.updateZones(data, {
         quantileCount: this.quantileCount,
       });
-      this.updateImageBackground(this.selectedDate);
     } catch (err) {
       const errLoadingZones =
         this.hsLanguageService.getTranslationIgnoreNonExisting(