import {
    Component,
    Injector,
    ViewChild
 } from '@angular/core';
 import {
    AppComponentBase
 } from '@shared/common/app-component-base';
import { ModalDirective } from 'ngx-bootstrap';
 
 @Component({
    selector: 'generateRoutesTracking',
    templateUrl: './generate-routes-tracking.component.html'
 })
 export class GenerateRoutesTrackingComponent extends AppComponentBase {

   @ViewChild('trackingModal', {static: false}) modal: ModalDirective;

   generatingRoutes = true;

   messages = [];
   
   constructor(
      injector: Injector
   ) {
      super(injector);
   }

   clearMessages() {
      this.messages = [];
   }

   logMessage(message: string) {

      this.messages.push(message);
   }

   complete () {
      
      this.generatingRoutes = false;
   }
 }