(self["webpackChunknginvoka"] = self["webpackChunknginvoka"] || []).push([["main"],{

/***/ 90158:
/*!***************************************!*\
  !*** ./src/app/app-routing.module.ts ***!
  \***************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "AppRoutingModule": () => (/* binding */ AppRoutingModule)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _modules_modules_module__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./modules/modules.module */ 27354);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _page_not_found_component_page_not_found_component_component__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./page-not-found-component/page-not-found-component.component */ 94588);
/* harmony import */ var _auth_auth_module__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./auth/auth.module */ 71674);
/* harmony import */ var _auth_auth_routing_module__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./auth/auth-routing.module */ 40431);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/platform-browser */ 34497);
/* harmony import */ var angular_datatables__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! angular-datatables */ 51282);










const routes = [{
  path: '',
  redirectTo: '',
  pathMatch: 'full'
}, {
  path: '404',
  component: _page_not_found_component_page_not_found_component_component__WEBPACK_IMPORTED_MODULE_1__.PageNotFoundComponentComponent
}, {
  path: '**',
  component: _page_not_found_component_page_not_found_component_component__WEBPACK_IMPORTED_MODULE_1__.PageNotFoundComponentComponent
}];
let AppRoutingModule = class AppRoutingModule {};
AppRoutingModule = (0,tslib__WEBPACK_IMPORTED_MODULE_5__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_6__.NgModule)({
  imports: [_angular_router__WEBPACK_IMPORTED_MODULE_7__.RouterModule.forRoot(routes, {
    onSameUrlNavigation: 'reload',
    useHash: true
  }), _angular_forms__WEBPACK_IMPORTED_MODULE_8__.FormsModule, _angular_forms__WEBPACK_IMPORTED_MODULE_8__.ReactiveFormsModule, _angular_platform_browser__WEBPACK_IMPORTED_MODULE_9__.BrowserModule, _auth_auth_module__WEBPACK_IMPORTED_MODULE_2__.AuthModule, _auth_auth_routing_module__WEBPACK_IMPORTED_MODULE_3__.AuthRoutingModule, _modules_modules_module__WEBPACK_IMPORTED_MODULE_0__.ModulesModule, angular_datatables__WEBPACK_IMPORTED_MODULE_4__.DataTablesModule],
  exports: [_angular_router__WEBPACK_IMPORTED_MODULE_7__.RouterModule]
})], AppRoutingModule);


/***/ }),

/***/ 55041:
/*!**********************************!*\
  !*** ./src/app/app.component.ts ***!
  \**********************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "AppComponent": () => (/* binding */ AppComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _app_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./app.component.html?ngResource */ 33383);
/* harmony import */ var _app_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./app.component.scss?ngResource */ 4594);
/* harmony import */ var _app_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_app_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var _auth_auth_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./auth/auth.service */ 50384);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./global */ 27266);
/* harmony import */ var _modules_messaging_service__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./modules/messaging.service */ 30565);
/* harmony import */ var _app_modules_module_service__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../app/modules/module.service */ 22947);









// import { SwUpdate, SwPush } from '@angular';
const MINUTES_UNITL_AUTO_LOGOUT = 60; // in mins
const CHECK_INTERVAL = 10000; // in ms
const STORE_KEY = 'lastAction';
let AppComponent = class AppComponent {
  getLastAction() {
    return parseInt(localStorage.getItem(STORE_KEY));
  }
  setLastAction(lastAction) {
    localStorage.setItem(STORE_KEY, lastAction.toString());
  }
  constructor(router, activatedRoute, authService, messagingService, moduleservice) {
    this.router = router;
    this.activatedRoute = activatedRoute;
    this.authService = authService;
    this.messagingService = messagingService;
    this.moduleservice = moduleservice;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_3__.GlobalVariable.BASE_URL;
    this.title = 'Dial-Digits';
    // console.log(this.router.url)
    this.check();
    this.initListener();
    this.initInterval();
    localStorage.setItem(STORE_KEY, Date.now().toString());
    this.activatedRoute.params.subscribe(data => {
      this.routeurl = data.id;
    });
  }
  ngOnInit() {
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 5000);
    // console.log(this.ServerUrl);
    // console.log(window.location.href);
    this.routeurl = window.location.href.replace(this.ServerUrl + 'publisher-registration/', "");
    this.emailurl = window.location.href.replace(this.ServerUrl + 'verify-email/', "");
    // console.log(this.routeurl);
    // this.checkcompanyavail(this.routeurl);
    $('body:has(.login)').addClass('redBorder');
    // this.messagingService.requestPermission()
    // this.messagingService.receiveMessage()
    this.message = this.messagingService.currentMessage;
  }
  checkcompanyavail(company_uuid) {
    this.moduleservice.checkcompanyavail(company_uuid).subscribe(res => {
      console.log('gettting');
      console.log(res.isavail);
      if (res.isavail !== 1) {
        this.router.navigate(['./404']);
      }
      //  this.email = res['email'];     
    });
  }

  initListener() {
    document.body.addEventListener('click', () => this.reset());
    document.body.addEventListener('mouseover', () => this.reset());
    document.body.addEventListener('mouseout', () => this.reset());
    document.body.addEventListener('keydown', () => this.reset());
    document.body.addEventListener('keyup', () => this.reset());
    document.body.addEventListener('keypress', () => this.reset());
  }
  reset() {
    this.setLastAction(Date.now());
  }
  initInterval() {
    setInterval(() => {
      this.check();
    }, CHECK_INTERVAL);
  }
  check() {
    const now = Date.now();
    const timeleft = this.getLastAction() + MINUTES_UNITL_AUTO_LOGOUT * 60 * 1000;
    const diff = timeleft - now;
    const isTimeout = diff < 0;
    if (isTimeout) {
      this.authService.logout();
      this.router.navigate(['./login']);
    }
  }
  static #_ = this.ctorParameters = () => [{
    type: _angular_router__WEBPACK_IMPORTED_MODULE_6__.Router
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_6__.ActivatedRoute
  }, {
    type: _auth_auth_service__WEBPACK_IMPORTED_MODULE_2__.AuthService
  }, {
    type: _modules_messaging_service__WEBPACK_IMPORTED_MODULE_4__.MessagingService
  }, {
    type: _app_modules_module_service__WEBPACK_IMPORTED_MODULE_5__.ModuleService
  }];
};
AppComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_7__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_8__.Component)({
  selector: 'app-root',
  template: _app_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_app_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], AppComponent);

// setInterval(() => {
//   this.authService.logout();
// }, 1 * 60 * 1000);
// this.islogin = this.authService.isLoggedIn();
// if(this.islogin=='false'){
// console.log(this.islogin);  
// this.router.navigate(['/login']);
// }  
// @HostListener("window:onbeforeunload",["$event"])
// clearLocalStorage(event){
//     // localStorage.clear();
//     alert('kk')
//     localStorage.removeItem('currentuser');
// }
// @HostListener('window:beforeunload', [ '$event' ])
// @HostListener('click')
// onclick() {
//   alert('kk')
// }
// @HostListener('window:beforeunload', ['$event'])
//    public beforeunloadHandler($event) {
//    $event.returnValue = "Are you sure?";
//   }
// @HostListener('window:unload', [ '$event' ])
// unloadHandler(event) {
//   alert('kk')
// }

/***/ }),

/***/ 36747:
/*!*******************************!*\
  !*** ./src/app/app.module.ts ***!
  \*******************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "AppModule": () => (/* binding */ AppModule)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _modules_module_service__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./modules/module.service */ 22947);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _modules_modules_module__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./modules/modules.module */ 27354);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(/*! @angular/platform-browser */ 34497);
/* harmony import */ var _angular_http__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(/*! @angular/http */ 83702);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _app_routing_module__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./app-routing.module */ 90158);
/* harmony import */ var _app_component__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./app.component */ 55041);
/* harmony import */ var _header_header_component__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./header/header.component */ 93482);
/* harmony import */ var _footer_footer_component__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./footer/footer.component */ 10970);
/* harmony import */ var _sidebar_sidebar_component__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./sidebar/sidebar.component */ 6804);
/* harmony import */ var _auth_auth_module__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./auth/auth.module */ 71674);
/* harmony import */ var _page_not_found_component_page_not_found_component_component__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./page-not-found-component/page-not-found-component.component */ 94588);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var _http_interceptors_index__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./http-interceptors/index */ 71122);
/* harmony import */ var _auth_auth_service__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ./auth/auth.service */ 50384);
/* harmony import */ var _sidebar_sidebar_service__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ./sidebar/sidebar.service */ 13414);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_26__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var _node_modules_angular_common__WEBPACK_IMPORTED_MODULE_27__ = __webpack_require__(/*! ../../node_modules/@angular/common */ 94666);
/* harmony import */ var _angular_platform_browser_animations__WEBPACK_IMPORTED_MODULE_24__ = __webpack_require__(/*! @angular/platform-browser/animations */ 37146);
/* harmony import */ var ngx_bootstrap_dropdown__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ngx-bootstrap/dropdown */ 15896);
/* harmony import */ var ng_select2__WEBPACK_IMPORTED_MODULE_23__ = __webpack_require__(/*! ng-select2 */ 31283);
/* harmony import */ var _angular_material_moment_adapter__WEBPACK_IMPORTED_MODULE_28__ = __webpack_require__(/*! @angular/material-moment-adapter */ 77118);
/* harmony import */ var _modules_messaging_service__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ./modules/messaging.service */ 30565);
/* harmony import */ var _swimlane_ngx_datatable__WEBPACK_IMPORTED_MODULE_25__ = __webpack_require__(/*! @swimlane/ngx-datatable */ 93143);
/* harmony import */ var _pagenotfound_pagenotfound_component__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! ./pagenotfound/pagenotfound.component */ 43019);
/* harmony import */ var _tinymce_tinymce_angular__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! @tinymce/tinymce-angular */ 73889);






























let AppModule = class AppModule {};
AppModule = (0,tslib__WEBPACK_IMPORTED_MODULE_15__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_16__.NgModule)({
  declarations: [_app_component__WEBPACK_IMPORTED_MODULE_3__.AppComponent, _header_header_component__WEBPACK_IMPORTED_MODULE_4__.HeaderComponent, _footer_footer_component__WEBPACK_IMPORTED_MODULE_5__.FooterComponent, _sidebar_sidebar_component__WEBPACK_IMPORTED_MODULE_6__.SidebarComponent, _page_not_found_component_page_not_found_component_component__WEBPACK_IMPORTED_MODULE_8__.PageNotFoundComponentComponent, _pagenotfound_pagenotfound_component__WEBPACK_IMPORTED_MODULE_14__.PagenotfoundComponent],
  imports: [_tinymce_tinymce_angular__WEBPACK_IMPORTED_MODULE_17__.EditorModule, _angular_platform_browser__WEBPACK_IMPORTED_MODULE_18__.BrowserModule, _angular_forms__WEBPACK_IMPORTED_MODULE_19__.FormsModule, _angular_forms__WEBPACK_IMPORTED_MODULE_19__.ReactiveFormsModule, _angular_http__WEBPACK_IMPORTED_MODULE_20__.HttpModule, _angular_common_http__WEBPACK_IMPORTED_MODULE_21__.HttpClientModule, _app_routing_module__WEBPACK_IMPORTED_MODULE_2__.AppRoutingModule, _auth_auth_module__WEBPACK_IMPORTED_MODULE_7__.AuthModule, _modules_modules_module__WEBPACK_IMPORTED_MODULE_1__.ModulesModule, _angular_router__WEBPACK_IMPORTED_MODULE_22__.RouterModule, ng_select2__WEBPACK_IMPORTED_MODULE_23__.NgSelect2Module, _angular_platform_browser_animations__WEBPACK_IMPORTED_MODULE_24__.BrowserAnimationsModule, _swimlane_ngx_datatable__WEBPACK_IMPORTED_MODULE_25__.NgxDatatableModule, ngx_bootstrap_dropdown__WEBPACK_IMPORTED_MODULE_12__.BsDropdownModule.forRoot(), ngx_toastr__WEBPACK_IMPORTED_MODULE_26__.ToastrModule.forRoot()],
  providers: [_auth_auth_service__WEBPACK_IMPORTED_MODULE_10__.AuthService, _sidebar_sidebar_service__WEBPACK_IMPORTED_MODULE_11__.SidebarService, _modules_module_service__WEBPACK_IMPORTED_MODULE_0__.ModuleService, _modules_messaging_service__WEBPACK_IMPORTED_MODULE_13__.MessagingService, _node_modules_angular_common__WEBPACK_IMPORTED_MODULE_27__.AsyncPipe, _angular_platform_browser__WEBPACK_IMPORTED_MODULE_18__.Title, _http_interceptors_index__WEBPACK_IMPORTED_MODULE_9__.httpInterceptorProviders, {
    provide: _node_modules_angular_common__WEBPACK_IMPORTED_MODULE_27__.LocationStrategy,
    useClass: _node_modules_angular_common__WEBPACK_IMPORTED_MODULE_27__.HashLocationStrategy
  }, {
    provide: _angular_material_moment_adapter__WEBPACK_IMPORTED_MODULE_28__.MAT_MOMENT_DATE_ADAPTER_OPTIONS,
    useValue: {
      useUtc: true
    }
  }],
  schemas: [_angular_core__WEBPACK_IMPORTED_MODULE_16__.CUSTOM_ELEMENTS_SCHEMA, _angular_core__WEBPACK_IMPORTED_MODULE_16__.NO_ERRORS_SCHEMA],
  bootstrap: [_app_component__WEBPACK_IMPORTED_MODULE_3__.AppComponent]
})], AppModule);

// platformBrowserDynamic().bootstrapModule(AppModule);

/***/ }),

/***/ 40431:
/*!*********************************************!*\
  !*** ./src/app/auth/auth-routing.module.ts ***!
  \*********************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "AuthRoutingModule": () => (/* binding */ AuthRoutingModule)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var _login_componunt_login_componunt_component__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./login-componunt/login-componunt.component */ 3380);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/forms */ 2508);





const routes = [{
  path: 'login',
  component: _login_componunt_login_componunt_component__WEBPACK_IMPORTED_MODULE_0__.LoginComponuntComponent
}];
let AuthRoutingModule = class AuthRoutingModule {};
AuthRoutingModule = (0,tslib__WEBPACK_IMPORTED_MODULE_1__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_2__.NgModule)({
  imports: [_angular_router__WEBPACK_IMPORTED_MODULE_3__.RouterModule.forChild(routes), _angular_forms__WEBPACK_IMPORTED_MODULE_4__.ReactiveFormsModule],
  exports: [_angular_router__WEBPACK_IMPORTED_MODULE_3__.RouterModule]
})], AuthRoutingModule);


/***/ }),

/***/ 3870:
/*!************************************!*\
  !*** ./src/app/auth/auth.guard.ts ***!
  \************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "AuthGuard": () => (/* binding */ AuthGuard)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var _auth_auth_service__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../auth/auth.service */ 50384);




let AuthGuard = class AuthGuard {
  constructor(authService, router, route) {
    this.authService = authService;
    this.router = router;
    this.route = route;
  }
  // canActivate(
  //   route: ActivatedRouteSnapshot,
  //   state: RouterStateSnapshot): boolean {
  //   const url: string = state.url;
  //   return this.checkLogin(url);
  // }
  canActivate(route, state) {
    const url = state.url;
    this.user = JSON.parse(localStorage.getItem('currentUser'));
    this.id = this.route.snapshot.paramMap.get('id');
    this.checkLogin(url);
    // if(url != '/buyer' && url != '/profile' && url != '/add-target' && url != '/edit-numbers/' && url != '/campaign-wizard' && url != '/edit-campaign/this.id' && url != '/new-ivr-menu' && url != '/edit-ivr/'){
    // this.authService.get_permission(url,this.user.role).subscribe(
    //   res => {
    //     // console.log(res);
    //     if(res == 'no'){
    //       // if(this.user.user_type == 1){
    //         // this.router.navigate(['/']);
    //       // }
    //     }
    //   }
    // );
    // }
    // if(this.user.role==4){
    //   if(url != '/target' && url != '/reports' && url != '/profile' && url != '/404'){
    //     this.router.navigate(['/buyer']);
    //   }
    // }
    if (this.user.role == 1) {
      if (url != '/notes' && url != '/reports' && url != '/' && url != '/profile') {
        this.router.navigate(['/']);
      }
    }
    if (this.user.role == 3) {
      if (url != '/numbers' && url != '/campaigns' && url != '/reports' && url != '/profile' && url != '/404' && !url.startsWith('/view-campaign/')) {
        this.router.navigate(['/campaigns']);
      }
    }
    if (this.user.role == 4) {
      if (url != '/target' && url != '/reports' && url != '/profile' && url != '/404') {
        this.router.navigate(['/target']);
      }
    }
    // if(this.user.role==3){
    //   if(url != '/campaigns' && url != '/reports' && url != '/numbers'  && url != '/profile'){
    //     this.router.navigate(['/campaigns']);
    //   }
    // }
    return this.checkLogin(url);
  }
  canActivateChild(route, state) {
    return this.canActivate(route, state);
  }
  checkLogin(url) {
    // console.log(localStorage.getItem('currentUser'));
    if (this.authService.isLoggedIn()) {
      return true;
    }
    this.authService.redirectUrl = url;
    this.router.navigate(['/login']);
  }
  static #_ = this.ctorParameters = () => [{
    type: _auth_auth_service__WEBPACK_IMPORTED_MODULE_0__.AuthService
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_1__.Router
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_1__.ActivatedRoute
  }];
};
AuthGuard = (0,tslib__WEBPACK_IMPORTED_MODULE_2__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_3__.Injectable)({
  providedIn: 'root'
})], AuthGuard);


/***/ }),

/***/ 71674:
/*!*************************************!*\
  !*** ./src/app/auth/auth.module.ts ***!
  \*************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "AuthModule": () => (/* binding */ AuthModule)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_common__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/common */ 94666);
/* harmony import */ var _auth_routing_module__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./auth-routing.module */ 40431);
/* harmony import */ var _login_componunt_login_componunt_component__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./login-componunt/login-componunt.component */ 3380);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/platform-browser */ 34497);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _profile_profile_component__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./profile/profile.component */ 96499);









let AuthModule = class AuthModule {};
AuthModule = (0,tslib__WEBPACK_IMPORTED_MODULE_3__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_4__.NgModule)({
  declarations: [_login_componunt_login_componunt_component__WEBPACK_IMPORTED_MODULE_1__.LoginComponuntComponent, _profile_profile_component__WEBPACK_IMPORTED_MODULE_2__.ProfileComponent],
  imports: [_angular_common__WEBPACK_IMPORTED_MODULE_5__.CommonModule, _angular_platform_browser__WEBPACK_IMPORTED_MODULE_6__.BrowserModule, _angular_router__WEBPACK_IMPORTED_MODULE_7__.RouterModule, _angular_forms__WEBPACK_IMPORTED_MODULE_8__.FormsModule, _angular_forms__WEBPACK_IMPORTED_MODULE_8__.ReactiveFormsModule],
  exports: [_angular_platform_browser__WEBPACK_IMPORTED_MODULE_6__.BrowserModule, _login_componunt_login_componunt_component__WEBPACK_IMPORTED_MODULE_1__.LoginComponuntComponent, _auth_routing_module__WEBPACK_IMPORTED_MODULE_0__.AuthRoutingModule]
})], AuthModule);


/***/ }),

/***/ 50384:
/*!**************************************!*\
  !*** ./src/app/auth/auth.service.ts ***!
  \**************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "AuthService": () => (/* binding */ AuthService)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var rxjs__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! rxjs */ 66587);
/* harmony import */ var rxjs_operators__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! rxjs/operators */ 86942);
/* harmony import */ var rxjs_operators__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! rxjs/operators */ 47418);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! .././global */ 27266);






let AuthService = class AuthService {
  constructor(http) {
    this.http = http;
    // serverUrl = 'http://192.168.1.50/angapi/index.php/';
    // serverUrl = 'http://104.131.72.90/index.php/';
    this.serverUrl = _global__WEBPACK_IMPORTED_MODULE_0__.GlobalVariable.BASE_API_URL;
    this.jsonObj = {};
  }
  login(username, password) {
    // console.log(password);return false;
    return this.http.post(`${this.serverUrl}login`, {
      username: username,
      password: password
    }).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_1__.map)(user => {
      // console.log(user);return
      if (user && user.token) {
        // console.log(companny); return;
        localStorage.setItem('currentUser', JSON.stringify(user));
        if (user.role == 2) {
          var companny = user.companydetails;
          for (let index = 0; index < companny.length; index++) {
            const element = companny[index];
            if (element.active == 1) {
              this.jsonObj = {
                "uuid": element.uuid,
                "name": element.name
              };
            }
          }
        } else {
          // console.log(user.role); return;
          this.jsonObj = {
            "uuid": user.company_uuid,
            "name": user.first_name
          };
        }
        // console.log(this.jsonObj);return false;
        if (user.role == 3) {
          this.redirectUrl = '/campaigns';
        }
        if (user.role == 4) {
          this.redirectUrl = '/target';
        }
        // console.log(this.jsonObj);return false;
        localStorage.setItem('currentCompany', JSON.stringify(this.jsonObj));
        // console.log(compaany_arr);
        // return false;
      }
    }), (0,rxjs_operators__WEBPACK_IMPORTED_MODULE_2__.catchError)(this.handleError));
  }
  get_permission(url, user_id) {
    return this.http.post(this.serverUrl + 'get_permission/' + user_id, url).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_2__.catchError)(this.handleError));
  }
  isLoggedIn() {
    // console.log(localStorage.getItem('currentUser'));return false;
    if (localStorage.getItem('currentUser')) {
      return true;
    } else {
      return false;
    }
  }
  getAuthorizationToken() {
    const currentUser = JSON.parse(localStorage.getItem('currentUser'));
    // console.log(currentUser);return false;
    return currentUser.token;
  }
  logout() {
    // localStorage.removeItem('currentUser');
    localStorage.clear();
  }
  handleError(error) {
    if (error.error instanceof ErrorEvent) {
      // A client-side or network error occurred. Handle it accordingly.
      console.error('An error occurred:', error.error.message);
    } else {
      // The backend returned an unsuccessful response code.
      // The response body may contain clues as to what went wrong.
      console.error(`Backend returned code ${error.status}, ` + `body was: ${error.error}`);
    }
    // return an observable with a user-facing error message
    this.errorData = {
      errorTitle: 'Oops! Request for document failed',
      errorDesc: 'Something bad happened. Please try again later.'
    };
    return (0,rxjs__WEBPACK_IMPORTED_MODULE_3__.throwError)(this.errorData);
  }
  static #_ = this.ctorParameters = () => [{
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_4__.HttpClient
  }];
};
AuthService = (0,tslib__WEBPACK_IMPORTED_MODULE_5__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_6__.Injectable)({
  providedIn: 'root'
})], AuthService);


/***/ }),

/***/ 3380:
/*!*******************************************************************!*\
  !*** ./src/app/auth/login-componunt/login-componunt.component.ts ***!
  \*******************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "LoginComponuntComponent": () => (/* binding */ LoginComponuntComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _login_componunt_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./login-componunt.component.html?ngResource */ 28899);
/* harmony import */ var _login_componunt_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./login-componunt.component.scss?ngResource */ 92650);
/* harmony import */ var _login_componunt_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_login_componunt_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var _auth_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../auth.service */ 50384);







let LoginComponuntComponent = class LoginComponuntComponent {
  constructor(fb, router, authService) {
    // if (authService.isLoggedIn()) {
    //     router.navigate(['/']);
    // }
    this.fb = fb;
    this.router = router;
    this.authService = authService;
    this.submitted = false;
  }
  ngOnInit() {
    this.loginForm = this.fb.group({
      username: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_3__.Validators.required],
      password: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_3__.Validators.required]
    });
    if (localStorage.getItem('currentUser')) {
      this.router.navigate(['/']);
      return false;
    }
    this.islogin = this.authService.isLoggedIn();
    // if(this.islogin='true'){
    //   // console.log(this.islogin);  
    //   this.router.navigate(['']);
    // }
    this.authService.logout();
  }
  get username() {
    return this.loginForm.get('username');
  }
  get password() {
    return this.loginForm.get('password');
  }
  onSubmit() {
    this.submitted = true;
    this.authService.login(this.username.value, this.password.value).subscribe(data => {
      if (localStorage.getItem('currentUser')) {
        //  console.log(this.authService.isLoggedIn);return false;
        // return false;
        const redirect = this.authService.redirectUrl ? this.authService.redirectUrl : '/';
        this.router.navigate([redirect]);
      } else {
        this.loginError = 'Username or password is incorrect.';
      }
    }, error => this.error = error);
  }
  static #_ = this.ctorParameters = () => [{
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_3__.FormBuilder
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_4__.Router
  }, {
    type: _auth_service__WEBPACK_IMPORTED_MODULE_2__.AuthService
  }];
};
LoginComponuntComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_5__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_6__.Component)({
  selector: 'app-login-componunt',
  template: _login_componunt_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_login_componunt_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], LoginComponuntComponent);


/***/ }),

/***/ 96499:
/*!***************************************************!*\
  !*** ./src/app/auth/profile/profile.component.ts ***!
  \***************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "ProfileComponent": () => (/* binding */ ProfileComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _profile_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./profile.component.html?ngResource */ 36911);
/* harmony import */ var _profile_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./profile.component.scss?ngResource */ 12274);
/* harmony import */ var _profile_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_profile_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _modules_module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../../modules/module.service */ 22947);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ngx-toastr */ 94817);








let ProfileComponent = class ProfileComponent {
  constructor(fb, moduleService, router, route, toastrService) {
    this.fb = fb;
    this.moduleService = moduleService;
    this.router = router;
    this.route = route;
    this.toastrService = toastrService;
    this.submitted = false;
    this.jsonObj = {};
    this.currentCompany = JSON.parse(localStorage.getItem('currentUser'));
  }
  ngOnInit() {
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.profileForm = this.fb.group({
      firstname: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_3__.Validators.required],
      lastname: [''],
      password: ['', ''],
      timezone: ['']
    });
    const company_uuid = this.currentCompany.uuid;
    // console.log(this.currentCompany);
    if (company_uuid) {
      let user_uuid = JSON.parse(localStorage.getItem('currentUser'));
      let company_uuid1 = JSON.parse(localStorage.getItem('currentCompany'));
      let formdata = new FormData();
      // console.log(user_uuid);
      formdata.append('userdata', JSON.stringify(user_uuid));
      formdata.append('company_uuid', company_uuid1.uuid);
      this.moduleService.getProfiledata(company_uuid, formdata).subscribe(res => {
        this.recordingval = res && res.is_recording ? res.is_recording : "";
        // console.log(res);
        if (user_uuid.role == 2 || user_uuid.role == 0) {
          this.profileForm.patchValue({
            firstname: res.first_name,
            lastname: res.last_name,
            timezone: res.timezone
          });
        }
        if (user_uuid.role == 3) {
          let name = res.name.split(' ');
          this.profileForm.patchValue({
            firstname: name[0],
            lastname: name[1],
            timezone: res.timezone
          });
        }
        if (user_uuid.role == 4) {
          this.profileForm.patchValue({
            firstname: res.company,
            timezone: res.timezone
          });
        }
      });
    }
    this.gettimezone();
  }
  gettimezone() {
    this.moduleService.gettimezone().subscribe(res => {
      this.alltimezone = res;
      // console.log(res);
    });
  }

  get_recordingstatus(event) {
    this.recording = event.target.checked;
  }
  get f() {
    return this.profileForm.controls;
  }
  onSubmit() {
    const formData = new FormData();
    this.submitted = true;
    if (this.profileForm.invalid) {
      return;
    }
    var userdata = JSON.parse(localStorage.getItem('currentUser'));
    formData.append('firstname', this.profileForm.get('firstname').value);
    formData.append('lastname', this.profileForm.get('lastname').value);
    formData.append('password', this.profileForm.get('password').value);
    formData.append('timezone', this.profileForm.get('timezone').value);
    formData.append('is_recording', this.recording);
    formData.append('role', userdata.role);
    formData.append('user_uuid', userdata.uuid);
    let company = JSON.parse(localStorage.getItem('currentCompany'));
    const company_uuid = company.uuid;
    if (company_uuid) {
      this.moduleService.editProfile(formData, company_uuid).subscribe(res => {
        // console.log(res); return false;
        if (res.status !== 'error') {
          var userdata = JSON.parse(localStorage.getItem('currentUser'));
          // console.log(this.profileForm.get('timezone').value);return false;
          userdata.timezone = this.profileForm.get('timezone').value;
          // console.log(userdata);return false;
          localStorage.setItem('currentUser', JSON.stringify(userdata));
          this.toastrService.success('Profile Updated Successfully');
        } else {
          this.toastrService.success('Failed To Save! Please Try Again Later..');
        }
      }, error => this.error = error);
    }
  }
  static #_ = this.ctorParameters = () => [{
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_3__.FormBuilder
  }, {
    type: _modules_module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_4__.Router
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_4__.ActivatedRoute
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_5__.ToastrService
  }];
};
ProfileComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_6__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_7__.Component)({
  selector: 'app-profile',
  template: _profile_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_profile_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], ProfileComponent);


/***/ }),

/***/ 10970:
/*!********************************************!*\
  !*** ./src/app/footer/footer.component.ts ***!
  \********************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "FooterComponent": () => (/* binding */ FooterComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _footer_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./footer.component.html?ngResource */ 82811);
/* harmony import */ var _footer_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./footer.component.scss?ngResource */ 92152);
/* harmony import */ var _footer_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_footer_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_common__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/common */ 94666);





let FooterComponent = class FooterComponent {
  constructor(renderer, elementRef, doc) {
    this.renderer = renderer;
    this.elementRef = elementRef;
    this.doc = doc;
    this.count = 0;
  }
  ngOnInit() {
    // let link1: HTMLLinkElement = this.doc.createElement('link');
    //  link1.setAttribute('rel', 'amphtml');
    //  link1.setAttribute('href', '../assets/css/app.min.css');
    //  this.doc.head.appendChild(link1);
    //  let link2: HTMLLinkElement = this.doc.createElement('link');
    //  link2.setAttribute('rel', 'amphtml');
    //  link2.setAttribute('href', '../assets/css/components.css');
    //  this.doc.head.appendChild(link2);
    // $('.settingPanelToggle').click(function(){
    //   this.count = 1;
    //   console.log(this.count);
    //   // $('.settingPanelToggle').toggleClass('showSettingPanel');
    //   // $('.settingSidebar').toggleClass('showSettingPanel');      
    // });
    // $('.settingPanelToggle').removeClass('showSettingPanel');
    // $('.settingSidebar').removeClass('showSettingPanel');
    // this.addJsToElement("../assets/js/app.min.js").onload ;
    this.addJsToElement("../assets/js/scripts.js").onload;
    this.addJsToElement("../assets/js/custom.js").onload;
    this.getyear = new Date().getFullYear();
  }
  show() {
    this.count = this.count + 1;
    if (this.count % 2 == 0) {
      this.count = 0;
    }
  }
  addJsToElement(src) {
    const script = document.createElement('script');
    script.type = 'text/javascript';
    script.src = src;
    this.renderer.appendChild(document.body, script);
    return script;
  }
  static #_ = this.ctorParameters = () => [{
    type: _angular_core__WEBPACK_IMPORTED_MODULE_2__.Renderer2
  }, {
    type: _angular_core__WEBPACK_IMPORTED_MODULE_2__.ElementRef
  }, {
    type: undefined,
    decorators: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_2__.Inject,
      args: [_angular_common__WEBPACK_IMPORTED_MODULE_3__.DOCUMENT]
    }]
  }];
};
FooterComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_4__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_2__.Component)({
  selector: 'app-footer',
  template: _footer_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_footer_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], FooterComponent);


/***/ }),

/***/ 27266:
/*!***************************!*\
  !*** ./src/app/global.ts ***!
  \***************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "GlobalVariable": () => (/* binding */ GlobalVariable)
/* harmony export */ });
const GlobalVariable = Object.freeze({
  BASE_API_URL: 'https://apiv2.dialdigits.com/',
  BASE_URL: 'https://app.dialdigits.com/#/'
  // BASE_URL: 'http://localhost:4200/#/',    
  // BASE_API_URL: 'http://localhost/DDV2API/',   
  // BASE_API_URL: 'http://testapi.dialdigits.com/',       
  // BASE_URL: 'https://testapp.dialdigits.com/#/'
});

/***/ }),

/***/ 93482:
/*!********************************************!*\
  !*** ./src/app/header/header.component.ts ***!
  \********************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "HeaderComponent": () => (/* binding */ HeaderComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _header_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./header.component.html?ngResource */ 46727);
/* harmony import */ var _header_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./header.component.scss?ngResource */ 50779);
/* harmony import */ var _header_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_header_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../global */ 27266);
/* harmony import */ var _modules_module_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../modules/module.service */ 22947);
/* harmony import */ var rxjs__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! rxjs */ 13491);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! moment */ 56908);
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(moment__WEBPACK_IMPORTED_MODULE_4__);










let HeaderComponent = class HeaderComponent {
  constructor(moduleservice, router, toastrService) {
    this.moduleservice = moduleservice;
    this.router = router;
    this.toastrService = toastrService;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_2__.GlobalVariable.BASE_API_URL;
    this.timeIntevalSeconds = 0;
    this.jsonObj = {};
    // switchcompany(item,role){
    //   var loggedinuser = JSON.parse(localStorage.getItem('currentUser'));
    //   this.moduleservice.getcompanydetailsbyuuid(item.user_uuid,this.role,loggedinuser.uuid).subscribe(
    //     res => {
    //       // this.completedcalls = res.completedcall;
    //       if(role == 4){
    //         this.jsonObj = {
    //           "user_id":  item.id,
    //           "uuid": item.user_uuid,
    //           "company_uuid": item.uuid,
    //           "first_name": res.companies.company,
    //           "last_name": "",
    //           "pic": "",
    //           "token": loggedinuser.token,
    //           "role": 4,
    //           "companydetails" : this.companies,
    //           "timezone" : res.companies.timezone
    //         }
    //         // console.log(this.jsonObj);return
    //         localStorage.setItem('currentUser', JSON.stringify(this.jsonObj));
    //       }
    //       // else{
    //       //   // this.jsonObj = {
    //       //   //   "user_id":  item.id,
    //       //   //   "uuid": item.user_uuid,
    //       //   //   "company_uuid": item.uuid,
    //       //   //   "first_name": res.companydetails.name,
    //       //   //   "last_name": "",
    //       //   //   "pic": "",
    //       //   //   "token": loggedinuser.token,
    //       //   //   "role": 4,
    //       //   //   "companydetails" : this.companies,
    //       //   //   "timezone" : loggedinuser.timezone
    //       //   // }
    //       //   this.jsonObj = {
    //       //     "user_id":  loggedinuser.id,
    //       //     "uuid": loggedinuser.user_id,
    //       //     "company_uuid": loggedinuser.company_uuid,
    //       //     "first_name": loggedinuser.first_name,
    //       //     "last_name": loggedinuser.last_name,
    //       //     "pic": loggedinuser.pic,
    //       //     "token": loggedinuser.token,
    //       //     "role": loggedinuser.role,
    //       //     "companydetails" : this.companies,
    //       //     "timezone" : loggedinuser.timezone,
    //       //     "gmttime" : loggedinuser.gmttime
    //       //   }
    //       // }
    //       localStorage.setItem('currentCompany', JSON.stringify(item));
    //       setTimeout(()=>{
    //         this.showLoadingIndicator= false;
    //         window.location.reload();
    //       },1000);
    //       if (res) {
    //         this.toastrService.success('Welcome To '+res.companydetails.name);
    //       }else{
    //         this.toastrService.error('Failed To Switch Company');
    //       }
    //     }
    //   );
    // }
    this.clickcount = 0;
  }
  ngOnInit() {
    var loggedinuser = JSON.parse(localStorage.getItem('currentUser'));
    let currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.currentcompany = currentCompany.uuid;
    if (loggedinuser) {
      this.firstName = loggedinuser.first_name;
      this.lastName = loggedinuser.last_name;
      this.role = loggedinuser.role;
      // console.log(loggedinuser.companydetails);
      if (this.role == 0 || this.role == 2 || this.role == 4) {
        this.companies = loggedinuser.companydetails;
        // console.log(this.companies);
      }

      this.showLoadingIndicator = true;
      setTimeout(() => {
        this.showLoadingIndicator = false;
      }, 1000);
      this.getcallvalue();
      const source = (0,rxjs__WEBPACK_IMPORTED_MODULE_5__.interval)(30000);
      this.subscription = source.subscribe(val => this.getcallvalue());
    }
  }
  getcallvalue() {
    this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    let date1 = {
      startDate: moment__WEBPACK_IMPORTED_MODULE_4__().format("MM/DD/YYYY 00:00"),
      endDate: moment__WEBPACK_IMPORTED_MODULE_4__().format("MM/DD/YYYY 23:59")
    };
    let formdata = new FormData();
    formdata.append('userdata', JSON.stringify(this.currentUser));
    formdata.append('dates', JSON.stringify(date1));
    this.moduleservice.getcallvalue(this.currentCompany.uuid, formdata).subscribe(res => {
      // console.log(res);return false;
      this.livecall = res.livecall;
      this.completedcalls = res.completedcall;
    });
  }
  logout() {
    localStorage.clear();
    this.router.navigate(['./login']);
  }
  switchcompany(item, role) {
    // console.log(item); return
    var loggedinuser = JSON.parse(localStorage.getItem('currentUser'));
    if (role == 4 || role == 0 || role == 2) {
      this.moduleservice.getcompanydetailsbyuuid(item.user_uuid, this.role, loggedinuser.uuid).subscribe(res => {
        // console.log(res);
        this.jsonObj = {
          "user_id": item.id,
          "uuid": item.user_uuid,
          "company_uuid": item.uuid,
          "first_name": res.companydetails && res.companydetails.name ? res.companydetails.name : res.companies.company,
          "last_name": "",
          "pic": "",
          "token": loggedinuser.token,
          "role": role,
          "companydetails": this.companies ? this.companies : "",
          "timezone": res.companydetails && res.companydetails.timezone ? res.companydetails.timezone : res.companies.timezone
        };
        localStorage.setItem('currentUser', JSON.stringify(this.jsonObj));
      });
    }
    // let cu = localStorage.getItem('currentUser');
    // console.log(cu); return
    //  return
    localStorage.setItem('currentCompany', JSON.stringify(item));
    setTimeout(() => {
      this.showLoadingIndicator = false;
      window.location.reload();
    }, 1000);
    if (item) {
      this.toastrService.success('Welcome To ' + item.name);
    } else {
      this.toastrService.error('Failed To Switch Company');
    }
  }
  getSidebar() {
    if (this.clickcount == 1) {
      // $('body').removeClass("sidebar-mini");
      $('body').addClass("sidebar");
      this.clickcount = 0;
    } else {
      $('body').removeClass("sidebar");
      // $('body').addClass("sidebar-mini");
      $('body').removeClass("sidebar-gone");
      this.clickcount = 1;
    }
  }
  static #_ = this.ctorParameters = () => [{
    type: _modules_module_service__WEBPACK_IMPORTED_MODULE_3__.ModuleService
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_6__.Router
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_7__.ToastrService
  }];
};
HeaderComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_8__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_9__.Component)({
  selector: 'app-header',
  template: _header_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_header_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], HeaderComponent);


/***/ }),

/***/ 34332:
/*!*******************************************************!*\
  !*** ./src/app/http-interceptors/auth-interceptor.ts ***!
  \*******************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "AuthInterceptor": () => (/* binding */ AuthInterceptor)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _auth_auth_service__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../auth/auth.service */ 50384);



let AuthInterceptor = class AuthInterceptor {
  constructor(authService) {
    this.authService = authService;
  }
  intercept(req, next) {
    if (this.authService.isLoggedIn()) {
      const authToken = this.authService.getAuthorizationToken();
      req = req.clone({
        setHeaders: {
          Authorization: authToken
        }
      });
    }
    return next.handle(req);
  }
  static #_ = this.ctorParameters = () => [{
    type: _auth_auth_service__WEBPACK_IMPORTED_MODULE_0__.AuthService
  }];
};
AuthInterceptor = (0,tslib__WEBPACK_IMPORTED_MODULE_1__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_2__.Injectable)()], AuthInterceptor);


/***/ }),

/***/ 71122:
/*!********************************************!*\
  !*** ./src/app/http-interceptors/index.ts ***!
  \********************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "httpInterceptorProviders": () => (/* binding */ httpInterceptorProviders)
/* harmony export */ });
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _auth_interceptor__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./auth-interceptor */ 34332);


const httpInterceptorProviders = [{
  provide: _angular_common_http__WEBPACK_IMPORTED_MODULE_1__.HTTP_INTERCEPTORS,
  useClass: _auth_interceptor__WEBPACK_IMPORTED_MODULE_0__.AuthInterceptor,
  multi: true
}];

/***/ }),

/***/ 21526:
/*!****************************************************************!*\
  !*** ./src/app/modules/audible-ring/audible-ring.component.ts ***!
  \****************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "AudibleRingComponent": () => (/* binding */ AudibleRingComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _audible_ring_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./audible-ring.component.html?ngResource */ 59010);
/* harmony import */ var _audible_ring_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./audible-ring.component.scss?ngResource */ 42314);
/* harmony import */ var _audible_ring_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_audible_ring_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../module.service */ 22947);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var _angular_http__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/http */ 83702);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! sweetalert2 */ 60598);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(sweetalert2__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../global */ 27266);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @angular/platform-browser */ 34497);










//import 'sweetalert2/src/sweetalert2.scss'



let requestOptions = new _angular_http__WEBPACK_IMPORTED_MODULE_5__.RequestOptions({
  headers: null,
  withCredentials: true
});
const router = _angular_router__WEBPACK_IMPORTED_MODULE_6__.Router;
class DataTablesResponse {}
const ParseHeaders = {
  headers: new _angular_common_http__WEBPACK_IMPORTED_MODULE_7__.HttpHeaders({
    'Content-Type': 'application/x-www-form-urlencoded'
  })
};
let AudibleRingComponent = class AudibleRingComponent {
  constructor(moduleservice, toastrService, handler, fb, titleService) {
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.fb = fb;
    this.titleService = titleService;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_4__.GlobalVariable.BASE_API_URL;
    this.dtOptions = {};
    this.LabelSubmitted = false;
    this.count = 0;
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_7__.HttpClient(handler);
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngOnInit() {
    this.setTitle('Audible Ring');
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.loadaudiblerings();
    this.addLabelForm = this.fb.group({
      number: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_8__.Validators.required],
      notes: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_8__.Validators.required]
    });
    // this.addLabelForm.patchValue({
    //   number: "",
    // });
    this.getallnumbers();
    this.getaudiblering();
  }
  getaudiblering() {
    this.moduleservice.getIVRAudio(this.currentCompany.uuid, 1).subscribe(res => {
      this.audiblering = res;
    }, error => this.error = error);
  }
  getallnumbers() {
    this.moduleservice.getallnumbers(this.currentCompany.uuid).subscribe(res => {
      this.allnumbers = res;
    }, error => this.error = error);
  }
  loadaudiblerings() {
    if ($.fn.DataTable.isDataTable(this.table.nativeElement)) {
      $(this.table.nativeElement).dataTable().fnDestroy();
    }
    var that = this;
    this.dtOptions = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "pageLength": 20,
      "lengthMenu": [[-1, 20, 100, 500, 2000], ["All", 20, 100, 500, 2000]],
      "order": [[2, "desc"]],
      ajax: (dataTablesParameters, callback) => {
        that.http.post(this.ServerUrl + '/getaudiblerinfnumbers/' + this.currentCompany.uuid, dataTablesParameters, {}).subscribe(resp => {
          // console.log(resp);
          that.labels = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [{
        data: "name"
      }, {
        data: "notes"
      }, {
        data: "created_at"
      }, {
        data: "action"
      }]
    };
    this.dataTable = $(this.table.nativeElement);
    this.dataTable.dataTable(this.dtOptions);
  }
  Delete(uuid) {
    sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
      title: 'Are you sure?',
      text: 'You want to Delete Record!',
      showCancelButton: true,
      confirmButtonText: 'Yes, delete it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        this.moduleservice.deleteAudibleRingNumber(uuid).subscribe(res => {
          // console.log(res);return false;
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Record Deleted Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
          this.loadaudiblerings();
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
        }, 2000);
      }
    });
  }
  get labelcontrol() {
    return this.addLabelForm.controls;
  }
  onLabelSubmit() {
    const formData = new FormData();
    this.LabelSubmitted = true;
    if (this.addLabelForm.invalid) {
      return;
    }
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('number', this.addLabelForm.get('number').value);
    formData.append('notes', this.addLabelForm.get('notes').value);
    this.moduleservice.addExceptionNumber(formData).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('New Exception Number Added Successfully');
      } else {
        this.toastrService.error('Failed To Add New Exception Number');
      }
    }, error => this.error = error);
  }
  closeModal() {
    if (this.addLabelForm.get('number').value && this.addLabelForm.get('notes').value) {
      $("#addLabels").modal("hide");
      this.loadaudiblerings();
      setTimeout(() => {
        this.LabelSubmitted = false;
        this.addLabelForm.reset();
      }, 2000);
    }
  }
  selectFile(event) {
    this.currentFileUpload = event.target.files.item(0);
    this.ext = this.currentFileUpload.name.split('.').pop();
    // console.log(event.target.files); return false;
    if (this.ext == 'mp3' || this.ext == 'wav') {
      this.moduleservice.uploadfile(event.target.files.item(0), this.currentCompany.uuid, 1).subscribe(res => {
        // console.log(res); return false;
        if (res.body) {
          if (res.body.status == 'success') {
            this.toastrService.success('Audio Uploaded Succssfully');
            this.getaudiblering();
          } else if (this.count == 0 && res.status == 'error') {
            this.toastrService.error('Failed To Add');
          }
          this.count = 1;
        }
      }, error => this.error = error);
    } else {
      this.toastrService.error('Please Upload only .mp3 or .wav file');
    }
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_9__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_7__.HttpBackend
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_8__.FormBuilder
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_10__.Title
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_11__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }]
  };
};
AudibleRingComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_12__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_11__.Component)({
  selector: 'app-audible-ring',
  template: _audible_ring_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_audible_ring_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], AudibleRingComponent);


/***/ }),

/***/ 15805:
/*!**********************************************************!*\
  !*** ./src/app/modules/blacklist/blacklist.component.ts ***!
  \**********************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "BlacklistComponent": () => (/* binding */ BlacklistComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _blacklist_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./blacklist.component.html?ngResource */ 94436);
/* harmony import */ var _blacklist_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./blacklist.component.scss?ngResource */ 51720);
/* harmony import */ var _blacklist_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_blacklist_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../module.service */ 22947);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var _angular_http__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/http */ 83702);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! sweetalert2 */ 60598);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(sweetalert2__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../global */ 27266);










//import 'sweetalert2/src/sweetalert2.scss'


const router = _angular_router__WEBPACK_IMPORTED_MODULE_5__.Router;
class DataTablesResponse {}
let requestOptions = new _angular_http__WEBPACK_IMPORTED_MODULE_6__.RequestOptions({
  headers: null,
  withCredentials: true
});
const ParseHeaders = {
  headers: new _angular_common_http__WEBPACK_IMPORTED_MODULE_7__.HttpHeaders({
    'Content-Type': 'application/x-www-form-urlencoded'
  })
};
let BlacklistComponent = class BlacklistComponent {
  constructor(moduleservice, toastrService, handler, fb) {
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.fb = fb;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_4__.GlobalVariable.BASE_API_URL;
    this.dtOptions = {};
    this.ischecked = '1';
    this.numberSubmitted = false;
    this.numbereditSubmitted = false;
    this.checkboxes = [];
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_7__.HttpClient(handler);
  }
  ngOnInit() {
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.loadnumbers();
    this.addNumberForm = this.fb.group({
      number: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_8__.Validators.required]
    });
    this.editNumberForm = this.fb.group({
      uuid: ['', ''],
      number: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_8__.Validators.required]
    });
  }
  loadnumbers() {
    if ($.fn.DataTable.isDataTable(this.table.nativeElement)) {
      $(this.table.nativeElement).dataTable().fnDestroy();
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    var that = this;
    this.dtOptions = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "pageLength": 20,
      "order": [[0, "desc"]],
      ajax: (dataTablesParameters, callback) => {
        that.http.post(this.ServerUrl + '/getlistnumbers/0/' + this.currentCompany.uuid, dataTablesParameters, {}).subscribe(resp => {
          console.log(resp);
          that.numbers = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [{
        data: "checkall"
      }, {
        data: "number"
      }, {
        data: "created_at"
      }, {
        data: "action"
      }],
      columnDefs: [{
        "targets": [0, 3],
        "orderable": false
      }]
    };
    this.dataTable = $(this.table.nativeElement);
    this.dataTable.dataTable(this.dtOptions);
  }
  Delete(uuid) {
    // alert(uuid);
    sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
      title: 'Are you sure?',
      text: 'You want to Delete Record!',
      showCancelButton: true,
      confirmButtonText: 'Yes, delete it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        this.moduleservice.deleteListNumber(uuid, 0).subscribe(res => {
          // console.log(res);return false;
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Record Deleted Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
          this.loadnumbers();
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
        }, 2000);
      }
    });
  }
  //Add Labels
  get numbercontrol() {
    return this.addNumberForm.controls;
  }
  onNumberSubmit() {
    const formData = new FormData();
    this.numberSubmitted = true;
    if (this.addNumberForm.invalid) {
      return;
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    // console.log(this.currentCompany); return false;
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('number', this.addNumberForm.get('number').value);
    formData.append('type', '0');
    this.moduleservice.addNumberlist(formData).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Number Added Successfully');
      } else {
        this.toastrService.error('Failed To Add Label');
      }
    }, error => this.error = error);
  }
  closeModal() {
    if (this.addNumberForm.get('number').value) {
      $("#addNumber").modal("hide");
      this.loadnumbers();
      setTimeout(() => {
        this.numberSubmitted = false;
        this.addNumberForm.reset();
      }, 2000);
    }
    if (this.editNumberForm.get('number').value) {
      $("#editNumber").modal("hide");
      setTimeout(() => {
        this.numbereditSubmitted = false;
        this.editNumberForm.reset();
        this.loadnumbers();
      }, 2000);
    }
  }
  // Edit Label
  editNumber(uuid, number) {
    this.editNumberForm.patchValue({
      uuid: uuid,
      number: number
    });
  }
  get numbereditcontrol() {
    return this.editNumberForm.controls;
  }
  onNumberEditSubmit() {
    const formData = new FormData();
    this.numbereditSubmitted = true;
    if (this.editNumberForm.invalid) {
      return;
    }
    formData.append('number', this.editNumberForm.get('number').value);
    formData.append('type', '0');
    this.moduleservice.editNumberList(formData, this.editNumberForm.get('uuid').value).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Black List Number Saved Successfully');
      } else {
        this.toastrService.error('Failed To Save Black List Number Data');
      }
    }, error => this.error = error);
  }
  _keyPress(event) {
    const isNumericInput = event => {
      const key = event.keyCode;
      return key >= 48 && key <= 57 ||
      // Allow number line
      key >= 96 && key <= 105 // Allow number pad
      ;
    };

    const isModifierKey = event => {
      const key = event.keyCode;
      return event.shiftKey === true || key === 35 || key === 36 ||
      // Allow Shift, Home, End
      key === 8 || key === 9 || key === 13 || key === 46 ||
      // Allow Backspace, Tab, Enter, Delete
      key > 36 && key < 41 ||
      // Allow left, up, right, down

      // Allow Ctrl/Command + A,C,V,X,Z
      (event.ctrlKey === true || event.metaKey === true) && (key === 65 || key === 67 || key === 86 || key === 88 || key === 90);
    };
    const enforceFormat = event => {
      // Input must be of a valid number format or a modifier key, and not longer than ten digits
      if (!isNumericInput(event) && !isModifierKey(event)) {
        event.preventDefault();
      }
    };
    const formatToPhone = event => {
      if (isModifierKey(event)) {
        return;
      }
      const target = event.target;
      const input = event.target.value.replace(/\D/g, '').substring(0, 10); // First ten digits of input only
      const zip = input.substring(0, 3);
      const middle = input.substring(3, 6);
      const last = input.substring(6, 10);
      if (input.length > 6) {
        target.value = `(${zip}) ${middle} - ${last}`;
      } else if (input.length > 3) {
        target.value = `(${zip}) ${middle}`;
      } else if (input.length > 0) {
        target.value = `(${zip}`;
      }
    };
    const number = document.getElementById('number');
    const editnumber = document.getElementById('editnumber');
    if (number) {
      number.addEventListener('keydown', enforceFormat);
      number.addEventListener('keyup', formatToPhone);
    }
    if (editnumber) {
      editnumber.addEventListener('keydown', enforceFormat);
      editnumber.addEventListener('keyup', formatToPhone);
    }
  }
  // Check Delete
  checkalldelete(event) {
    const checked = event.target.checked;
    this.numbers.forEach(chkbox => chkbox.selected = checked);
  }
  deleteselected(event) {
    if (event.target.checked == true) {
      if (event.target.value == 'on') {
        this.checkboxes = [];
        this.numbers.forEach(lbl => {
          this.checkboxes.push(lbl.id);
        });
      } else {
        if (this.checkboxes.length + 1 == this.numbers.length) {
          $("#customCheck1").prop("checked", true);
        }
        this.checkboxes.push(event.target.value);
      }
      this.ischecked = '0';
    } else {
      // console.log(this.checkboxes);      
      if (this.checkboxes.length != 0) {
        $("#customCheck1").prop("checked", false);
      }
      if (event.target.value != 'on') {
        const index = this.checkboxes.indexOf(event.target.value);
        this.checkboxes.splice(index, 1);
      } else {
        this.checkboxes = [];
      }
      this.ischecked = '1';
    }
    // console.log(this.checkboxes); 
  }

  onDeleteSubmit() {
    if (this.checkboxes.length == 0) {
      this.toastrService.error('Please Select Row To Delete');
    } else {
      // console.log(this.checkboxes);  
      sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
        title: 'Are you sure?',
        text: 'You want to Delete Selected Record!',
        showCancelButton: true,
        confirmButtonText: 'Yes, delete it!',
        cancelButtonText: 'No, keep it'
      }).then(result => {
        if (result.value) {
          this.moduleservice.deletewbSelectedNumbers(this.checkboxes, 0).subscribe(res => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Records Deleted Successfully.');
            setTimeout(() => {
              sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
            }, 2000);
            this.loadnumbers();
          }, error => this.error = error);
        } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
        }
      });
    }
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_9__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_7__.HttpBackend
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_8__.FormBuilder
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_10__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }]
  };
};
BlacklistComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_11__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_10__.Component)({
  selector: 'app-blacklist',
  template: _blacklist_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_blacklist_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], BlacklistComponent);


/***/ }),

/***/ 96658:
/*!********************************************************************************!*\
  !*** ./src/app/modules/campaigns/campaign-create/campaign-create.component.ts ***!
  \********************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "CampaignCreateComponent": () => (/* binding */ CampaignCreateComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _campaign_create_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./campaign-create.component.html?ngResource */ 16079);
/* harmony import */ var _campaign_create_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./campaign-create.component.scss?ngResource */ 94672);
/* harmony import */ var _campaign_create_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_campaign_create_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../../module.service */ 22947);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @angular/platform-browser */ 34497);










let CampaignCreateComponent = class CampaignCreateComponent {
  constructor(renderer, moduleservice, toastrService, handler, fb, router, changedetect, titleService) {
    this.renderer = renderer;
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.fb = fb;
    this.router = router;
    this.changedetect = changedetect;
    this.titleService = titleService;
    this.locations = [];
    this.dropdownList = [];
    this.selectedItems = [];
    this.dropdownSettings = {};
    this.labeldropdownSettings = {};
    this.payout_typevalueedit = 0;
    this.selectedpub = [];
    this.selectedtarget = [];
    this.Submitted = false;
  }
  get_maxcon(event) {
    this.maxconcurrency = event.target.checked;
    // this.isselectlabel = false;    
    // $(".labelswitch").prop('checked',false);
  }

  get_labelisselect(event) {
    this.isselectlabel = event.target.checked;
    // this.maxconcurrency = false;    
    // $(".labelnumber").prop('checked',false);
  }

  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngOnInit() {
    this.setTitle('Create Campaign');
    this.dropdownSettings = {
      singleSelection: false,
      text: "Select Numbers",
      selectAllText: 'Select All',
      unSelectAllText: 'UnSelect All',
      enableSearchFilter: true,
      classes: "myclass custom-class"
    };
    this.labeldropdownSettings = {
      singleSelection: false,
      text: "Select Labels",
      selectAllText: 'Select All',
      unSelectAllText: 'UnSelect All',
      enableSearchFilter: true,
      classes: "myclass custom-class"
    };
    var parentElement = $(".asdf");
    $(".js-example-basic-single").select2({
      dropdownParent: parentElement
    });
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    // this.addJsToElement('../assets/bundles/jquery-validation/dist/jquery.validate.min.js').onload ;
    // this.addJsToElement('../assets/bundles/jquery-steps/jquery.steps.min.js').onload;
    // this.addJsToElement('../assets/js/page/form-wizard.js').onload ;    
    // this.loadNumbers();
    this.loadNumbers();
    this.getAllpublishers();
    this.getAlltarget();
    this.getAllLabels();
    this.addForm = this.fb.group({
      campaignName: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_3__.Validators.required],
      country: [''],
      // option: [''],      
      number: [''],
      labeldata: [''],
      numberIsFor: [''],
      // numberType: [''],             
      publisher: [''],
      payout_typeedit: [''],
      payout_amount: [''],
      payout_trigger: [''],
      payout_seconds: [''],
      target: [''],
      conversation_revenue: [''],
      conversation_event: [''],
      conversation_seconds: [''],
      user_uuid: [''],
      recording: ['']
    });
    this.addForm.patchValue({
      country: 'United States'
    });
    // this.value = ['multiple2', 'multiple4'];
    this.options = {
      width: '300',
      multiple: true
      // tags: true
    };
  }

  ngAfterViewInit() {
    this.changedetect.detectChanges();
  }
  payout_typevaledit(val) {
    this.payout_typevalueedit = val;
    this.addForm.get('payout_typeedit').setValue(val);
  }
  ngOnDestroy() {
    const selectOptionsContainer = $('.select2-container');
    selectOptionsContainer.removeClass('span.select2-selection.select2-selection--single');
  }
  // public numberdata: any;
  // public numberdata: Array<Select2OptionData>;
  loadNumbers() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleservice.loadNumbersfordropdown(this.currentCompany.uuid).subscribe(resp => {
      this.numberdata = resp;
    }, error => this.error = error);
  }
  getAllLabels() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleservice.getAllLabels(this.currentCompany.uuid).subscribe(res => {
      this.labeldata = res;
      // console.log(res);
    }, error => this.error = error);
  }
  getAllpublishers() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleservice.getAllpublishers(this.currentCompany.uuid).subscribe(res => {
      this.publisherdata = res;
    }, error => this.error = error);
  }
  getAlltarget() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleservice.getAlltarget(this.currentCompany.uuid).subscribe(res => {
      // console.log(res);
      this.targetdata = res;
    }, error => this.error = error);
  }
  getPublisher(event) {
    this.addForm.get('publisher').setValue(event[0].id);
  }
  getTarget(event) {
    this.addForm.get('target').setValue(event[0].id);
  }
  numberIsForval(type) {
    this.numberIsFor = type;
    this.addForm.get('numberIsFor').setValue(type);
  }
  get_recordingstatus(event) {
    this.recording = event.target.checked;
    this.addForm.get('recording').setValue(this.recording);
  }
  //Add Publisher
  get addFormcontrol() {
    return this.addForm.controls;
  }
  onSubmit() {
    // console.log(this.addForm.value);
    // return false;
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    var currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.addForm.get('user_uuid').setValue(currentUser.uuid);
    this.moduleservice.addCampaign(this.currentCompany.uuid, this.addForm.value).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.isName = "fail";
        this.toastrService.success('Campaign Added Successfully');
        this.Submitted = false;
        this.router.navigate(['/campaigns']);
      } else {
        this.toastrService.error('Failed To Add Campaign');
      }
    }, error => this.error = error);
  }
  validatename() {
    if (this.addForm.get('campaignName').value != '') {
      this.moduleservice.validateCampaignName(this.addForm.get('campaignName').value).subscribe(res => {
        // console.log(res); return false;  
        this.isName = res;
        if (this.isName.status == 'success') {
          this.isName = "success";
        } else {
          this.isName = "fail";
        }
      });
    } else {
      this.isName = "";
    }
  }
  static #_ = this.ctorParameters = () => [{
    type: _angular_core__WEBPACK_IMPORTED_MODULE_4__.Renderer2
  }, {
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_5__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_6__.HttpBackend
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_3__.FormBuilder
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_7__.Router
  }, {
    type: _angular_core__WEBPACK_IMPORTED_MODULE_4__.ChangeDetectorRef
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_8__.Title
  }];
};
CampaignCreateComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_9__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_4__.Component)({
  selector: 'app-campaign-create',
  template: _campaign_create_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  changeDetection: _angular_core__WEBPACK_IMPORTED_MODULE_4__.ChangeDetectionStrategy.OnPush,
  styles: [(_campaign_create_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], CampaignCreateComponent);


/***/ }),

/***/ 84155:
/*!****************************************************************************!*\
  !*** ./src/app/modules/campaigns/campaign-edit/campaign-edit.component.ts ***!
  \****************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "CampaignEditComponent": () => (/* binding */ CampaignEditComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _campaign_edit_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./campaign-edit.component.html?ngResource */ 51159);
/* harmony import */ var _campaign_edit_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./campaign-edit.component.scss?ngResource */ 59483);
/* harmony import */ var _campaign_edit_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_campaign_edit_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../../../global */ 27266);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./../../module.service */ 22947);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! sweetalert2 */ 60598);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(sweetalert2__WEBPACK_IMPORTED_MODULE_4__);
/* harmony import */ var ngx_csv__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ngx-csv */ 94551);
/* harmony import */ var rxjs__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! rxjs */ 92218);
/* harmony import */ var ngx_ui_loader__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! ngx-ui-loader */ 36413);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! @angular/platform-browser */ 34497);
/* harmony import */ var angular_highcharts__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! angular-highcharts */ 55199);
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! highcharts */ 75972);
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_6__);
/* harmony import */ var highcharts_modules_exporting__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! highcharts/modules/exporting */ 43916);
/* harmony import */ var highcharts_modules_exporting__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(highcharts_modules_exporting__WEBPACK_IMPORTED_MODULE_7__);


















highcharts_modules_exporting__WEBPACK_IMPORTED_MODULE_7___default()(highcharts__WEBPACK_IMPORTED_MODULE_6__);
class DataTablesResponse {}
let CampaignEditComponent = class CampaignEditComponent {
  constructor(renderer, moduleservice, toastrService, handler, fb, router, route, cdRef, ngxLoader, titleService) {
    this.renderer = renderer;
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.fb = fb;
    this.router = router;
    this.route = route;
    this.cdRef = cdRef;
    this.ngxLoader = ngxLoader;
    this.titleService = titleService;
    this.locations = [];
    this.dropdownList = [];
    this.selectedItems = [];
    this.dropdownSettings = {};
    this.pubdropdownSettings = {};
    this.labeldropdownSettings = {};
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_2__.GlobalVariable.BASE_API_URL;
    this.dtTrigger = new rxjs__WEBPACK_IMPORTED_MODULE_8__.Subject();
    this.dtOptions = {};
    this.dtOptionsTarget = {};
    this.dtOptionsRouting = {};
    this.dtOptionsPending = {};
    this.campaignNumbers = [];
    this.campaignLabels = [];
    this.campaignoffers = [];
    this.event = "";
    this.pendingdata = [];
    this.completed = [];
    this.offerdetails = [];
    this.allRoutingPlan = [];
    this.Submitted = false;
    //Add Publisher
    //  uuid = this.route.snapshot.paramMap.get('id');
    this.payout_typevalueedit = 0;
    this.notype = 0;
    this.istollfree = 0;
    this.payoutSubmitted = false;
    this.publisherSubmitted = false;
    // default payout
    this.dpayout_type = 0;
    this.dpSubmitted = false;
    this.recording = 2;
    this.isblacklistaliance = 2;
    this.is_enable_offer = 2;
    this.ispredicaterouting = 2;
    this.settingToggleDurationvalue = 0;
    this.targetname = "";
    this.filtertype = 1;
    this.pfiltertype = 1;
    this.iscreateoffer = false;
    this.isshowmessage = true;
    // Offer Section
    this.is_approval = 1;
    this.isallow_tollfree_no = 1;
    this.allow_did_no = 1;
    this.isadded = 0;
    this.addofferSubmitted = false;
    this.isedit = false;
    this.addnoSubmitted = false;
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_9__.HttpClient(handler);
    this.uuid = this.route.snapshot.paramMap.get('id');
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngAfterViewChecked() {
    this.cdRef.detectChanges();
  }
  getRulesByName(target_uuid) {
    //  console.log(name);
    if (target_uuid != '') {
      this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
      this.moduleservice.getRulesByTargetuuid(target_uuid, this.currentCompany.uuid).subscribe(res => {
        // console.log(res);
        this.allRulesbyname = res;
      }, error => this.error = error);
    } else {
      this.allRulesbyname = "";
    }
  }
  loadallweekdays() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleservice.loadallweekdays(this.currentCompany.uuid).subscribe(res => {
      //  console.log(res); return false;
      this.allweekdays = res.data;
    }, error => this.error = error);
  }
  loadcalls() {
    if ($.fn.DataTable.isDataTable(this.Pertable.nativeElement)) {
      $(this.Pertable.nativeElement).dataTable().fnDestroy();
    }
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    var that = this;
    this.dtOptions = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "paging": false,
      "info": false,
      // "lengthMenu": [[-1, 50, 100, 500, 2000, 5000], ["All", 50, 100, 500, 2000, 5000 ]],
      "pageLength": 20,
      // "ordering": false,
      "searching": false,
      ajax: (dataTablesParameters, callback) => {
        that.http.post(this.ServerUrl + 'getlastweekcalls/' + this.currentCompany.uuid + '/' + currentUser.timezone + '/', {
          'dataTablesParameters': dataTablesParameters,
          'user_uuid': currentUser.uuid,
          'role': currentUser.role,
          'campaign_uuid': this.uuid
        }, {}).subscribe(resp => {
          // console.log(resp); return false;
          that.labels = resp.campaign_no;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [{
        data: "did"
      }, {
        data: "incoming_number"
      }, {
        data: "publisher"
      }, {
        data: "target"
      }, {
        data: "campaign"
      }, {
        data: "routed_to"
      }, {
        data: "routed_to"
      }, {
        data: "routed_to"
      }]
    };
    this.dataTable = $(this.Pertable.nativeElement);
    this.dataTable.dataTable(this.dtOptions);
  }
  getAllLabels() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleservice.getAllLabels(this.currentCompany.uuid).subscribe(res => {
      this.labeldata = res;
      // console.log(res);
    }, error => this.error = error);
  }
  ngOnDestroy() {
    this.dtTrigger.unsubscribe();
  }
  ngOnInit() {
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.today = new Date().toISOString().split('T')[0];
    this.dropdownSettings = {
      singleSelection: true,
      text: "Select Number",
      selectAllText: 'Select All',
      unSelectAllText: 'UnSelect All',
      enableSearchFilter: true,
      classes: "myclass custom-class"
    };
    this.pubdropdownSettings = {
      singleSelection: true,
      text: "Select Publisher",
      selectAllText: 'Select All',
      unSelectAllText: 'UnSelect All',
      enableSearchFilter: true,
      classes: "myclass custom-class"
    };
    this.labeldropdownSettings = {
      singleSelection: false,
      text: "Select Labels",
      selectAllText: 'Select All',
      unSelectAllText: 'UnSelect All',
      enableSearchFilter: true,
      classes: "myclass custom-class"
    };
    this.getcampaignbyuuid();
    this.getPredicateRouting();
    this.gettimezone();
    this.getAllLabels();
    this.getAllpublishers();
    this.loadallweekdays();
    this.loadNumbers();
    this.loadcalls();
    this.getChartNumberOfCalls(this.event);
    this.getAlltarget();
    this.loadcampaignpublishers(this.uuid);
    this.loadparticipationrequest(this.uuid);
    this.loadcampaigntarget();
    this.loadallRoutingplan(this.uuid);
    this.payoutForm = this.fb.group({
      user_uuid: [''],
      phoneno: [''],
      publisher_uuid: [''],
      payout_typeedit: [''],
      payout_amount: [''],
      payout_trigger: [''],
      payout_seconds: ['']
    });
    this.numberForm = this.fb.group({
      company_uuid: [''],
      user_uuid: [''],
      campaign_uuid: [''],
      notype: [0],
      prefix: [''],
      isexisting: [''],
      selectedExistingNumber: [''],
      payoutuuid: [''],
      isedit: ['1']
    });
    this.addofferForm = this.fb.group({
      name: [''],
      description: [''],
      hoursofoperation: [''],
      exp_timezone: [''],
      exp_date: [''],
      start_hrs: ['23'],
      start_min: ['59'],
      max_no_per_publisher: ['100']
    });
    this.publishtertocampaignForm = this.fb.group({
      user_uuid: [''],
      number: [''],
      publisher_uuid: [''],
      payout_typeedit: [''],
      payout_amount: [''],
      payout_trigger: [''],
      payout_seconds: ['']
    });
    this.defaultpayoutForm = this.fb.group({
      user_uuid: [''],
      payout_type: [''],
      payout_amount: [''],
      payout_trigger: [''],
      payout_seconds: ['']
    });
    this.editRoutingForm = this.fb.group({
      user_uuid: [''],
      uuid: [''],
      priority: [''],
      weight: [''],
      conversation_revenue: [''],
      conversation_event: [''],
      conversation_seconds: [''],
      restrictdup: [''],
      restrictafter: [''],
      days: [''],
      settingToggleDurationval: [''],
      settingToggleDuration: ['']
    });
    this.editForm = this.fb.group({
      campaignName: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_10__.Validators.required],
      user_uuid: [''],
      country: [''],
      // option: [''],
      number: [''],
      labeldata: [''],
      numberIsFor: [''],
      // numberType: [''],
      publisher: [''],
      target: [''],
      conversation_revenue: [''],
      conversation_event: [''],
      conversation_seconds: [''],
      //  payout_typeedit: ['',Validators.required],
      //  payout_amount: [''],
      //  payout_trigger: [''],
      //  payout_seconds: [''],
      recording: [''],
      enable_blacklist_aliance: [''],
      is_enable_offer: [''],
      enable_predicaterouting: [''],
      predicate_routing: ['']
    });
    // this.options = {
    //   multiple: true,
    //   theme: 'classic',
    //   closeOnSelect: false,
    //   width: '370'
    // };
  }

  getcampaignbyuuid() {
    this.moduleservice.getcampainbyuuid(this.uuid).subscribe(res => {
      this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
      if (this.currentCompany.uuid != res.campaigns.company_uuid) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire({
          title: 'Error!',
          html: 'This campaign is assigned to another company.',
          icon: 'warning',
          timer: 2000
        });
        this.router.navigate(['/campaigns']);
      }
      this.setTitle(res.campaigns.name + ' | Campaign');
      this.getdata = res.campaigns;
      // console.log(this.getdata);
      this.campaignoffers = res.campaign_offer;
      this.dpayout_type = res.campaigns.payout_type;
      this.editpayout_typeval = res.campaigns.payout_type;
      this.payout_typevalueedit = res.campaigns.payout_type;
      this.isrecording = res.campaigns.is_recording;
      this.isblacklistaliance = Number(res.campaigns.enable_blacklist_aliance);
      this.is_enable_offer = Number(res.campaigns.is_enable_offer);
      this.ispredicaterouting = Number(res.campaigns.isPredicateRouting);
      this.defaultconf = res.conf;
      if (res.campaigns.payout_amount != "") {
        this.defaultpayoutForm.patchValue({
          payout_type: res.campaigns.payout_type,
          payout_amount: res.campaigns.payout_amount,
          payout_trigger: res.campaigns.payout_trigger,
          payout_seconds: res.campaigns.payout_seconds
        });
      }
      this.editForm.patchValue({
        campaignName: res.campaigns.name,
        country: res.campaigns.country,
        number: res.campaigns.number,
        publisher: res.campaigns.publisher_uuid,
        enable_predicaterouting: this.ispredicaterouting,
        predicate_routing: Number(res.campaigns.predicateRouting)
      });
      // console.log(res.campaigns.predicate_routing);
      this.numberIsFor = res.campaigns.numberIs_For;
      // console.log(res.campaigns.company_uuid);
      this.editForm.get('numberIsFor').setValue(res.campaigns.numberIs_For);
      this.editForm.get('enable_blacklist_aliance').setValue(Number(res.campaigns.enable_blacklist_aliance));
      this.editForm.get('is_enable_offer').setValue(Number(res.campaigns.is_enable_offer));
    }, error => this.error = error);
  }
  getpayoutdata(uuid, phone, number_uuid) {
    // console.log(phone[0]['number_uuid']);
    // if(phone.length>0){    
    //   this.payoutForm.get('phoneno').setValue(phone[0]['number_uuid']);
    // }
    this.payoutForm.get('phoneno').setValue(number_uuid);
    this.ngxLoader.startLoader('loader-10');
    this.payoutForm.get('publisher_uuid').setValue(uuid);
    this.moduleservice.getpayoutdata(uuid, number_uuid).subscribe(resp => {
      // console.log(resp);
      if (resp != null) {
        this.editpayout_typeval = resp.payout_type;
        this.payout_typevalueedit = resp.payout_type;
        this.payoutForm.get('payout_typeedit').setValue(this.editpayout_typeval);
        this.payoutForm.patchValue({
          payout_typeedit: resp.payout_type,
          payout_amount: resp.payout_amount,
          payout_trigger: resp.payout_trigger,
          payout_seconds: resp.payout_seconds
        });
      } else {
        this.editpayout_typeval = 0;
        this.payout_typevalueedit = 0;
        this.payoutForm.get('payout_typeedit').setValue(0);
        this.payoutForm.patchValue({
          payout_typeedit: 0,
          payout_amount: "",
          payout_trigger: 0,
          payout_seconds: ""
        });
      }
      this.ngxLoader.stopLoader('loader-10');
    }, error => this.error = error);
  }
  loadcampaignpublishers(uuid) {
    // console.log('ok');
    // return false;
    if ($.fn.DataTable.isDataTable(this.table.nativeElement)) {
      $(this.table.nativeElement).dataTable().fnDestroy();
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.dtOptions = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "pageLength": 20,
      "lengthMenu": [[-1, 20, 100, 500, 2000], ["All", 20, 100, 500, 2000]],
      "order": [[0, "asc"]],
      "searchDelay": 350,
      ajax: (dataTablesParameters, callback) => {
        this.http.post(this.ServerUrl + 'getCampaignPublisher/' + uuid, dataTablesParameters, {}).subscribe(resp => {
          this.campaignpublisher = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [{
        data: "enabled"
      }, {
        data: "publisher"
      }, {
        data: "phoneno"
      }, {
        data: "conf"
      }, {
        data: "status"
      }, {
        data: "action"
      }
      // ,{data:"labels"}
      ],

      columnDefs: [{
        "targets": [0],
        "orderable": false
      }]
    };
    this.dataTable = $(this.table.nativeElement);
    this.dataTable.dataTable(this.dtOptions);
  }
  getChartNumberOfCalls(event) {
    // console.log(event);return false;
    if (event != '') {
      this.date1 = event.endDate._d;
    } else {
      this.date1 = '';
    }
    // console.log(this.date1);
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    let params = {
      user_uuid: currentUser.uuid,
      role: currentUser.role,
      date: this.date1,
      campaign_uuid: this.uuid
    };
    // console.log(this.uuid);
    this.moduleservice.getChartbyDate(this.currentCompany.uuid, params, currentUser.timezone).subscribe(res => {
      //  console.log(res);
      if ($("html").hasClass("dark")) {
        this.bgcolorcode = 'rgb(17,19,25)';
      }
      this.chart = new angular_highcharts__WEBPACK_IMPORTED_MODULE_11__.Chart({
        chart: {
          // polar: true,
          type: 'line',
          backgroundColor: this.bgcolorcode
        },
        exporting: {
          enabled: true
        },
        title: {
          text: ''
        },
        credits: {
          enabled: false
        },
        xAxis: {
          minRange: 0,
          gridLineWidth: 0,
          title: {
            text: 'Hours'
          }
        },
        yAxis: {
          min: 0,
          gridLineWidth: 1,
          title: {
            text: 'Number Of Calls'
          }
        },
        legend: {
          enabled: false
        },
        plotOptions: {
          area: {
            fillColor: {
              linearGradient: {
                x1: 0,
                y1: 0,
                x2: 0,
                y2: 1
              },
              stops: [[0, '#7cb5ec'], [1, 'rgba(124,181,236,0)']]
            },
            marker: {
              radius: 2
            },
            lineWidth: 1,
            states: {
              hover: {
                lineWidth: 1
              }
            },
            threshold: null
          },
          line: {
            dataLabels: {
              enabled: true
            },
            enableMouseTracking: false
          }
        },
        series: [{
          data: res,
          type: 'area',
          name: "Call Count"
        }]
      });
    }, error => this.error = error);
  }
  loadparticipationrequest(uuid) {
    this.ngxLoader.startLoader('loader-03');
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.http.post(this.ServerUrl + 'getParticipationRequest/' + uuid, {}).subscribe(resp => {
      // console.log(resp);
      this.offerdetails = resp.offerdetails;
      if (resp.offerdetails && resp.offerdetails.exp_date) {
        this.firstDate = new Date(resp.offerdetails.exp_date);
      }
      this.secondDate = new Date();
      const ONE_DAY = 1000 * 60 * 60 * 24;
      const differenceMs = Math.abs(this.firstDate - this.secondDate);
      this.diffdays = Math.round(differenceMs / ONE_DAY);
      this.pendingdata = resp.data.pending ? resp.data.pending : [];
      this.completed = resp.data.completed ? resp.data.completed : [];
      this.dtTrigger.next();
      this.ngxLoader.stopLoader('loader-03');
    }, error => this.error = error);
  }
  loadcampaigntarget() {
    if ($.fn.DataTable.isDataTable(this.tabletarget.nativeElement)) {
      $(this.tabletarget.nativeElement).dataTable().fnDestroy();
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.dtOptionsTarget = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "pageLength": 20,
      "lengthMenu": [[-1, 20, 100, 500, 2000], ["All", 20, 100, 500, 2000]],
      "order": [[0, "asc"]],
      ajax: (dataTablesParameters, callback) => {
        this.http.post(this.ServerUrl + 'gettargets/' + this.currentCompany.uuid + '/' + this.uuid, {
          'dataTablesParameters': dataTablesParameters,
          'user_uuid': currentUser.uuid,
          'role': currentUser.role
        }, {}).subscribe(resp => {
          this.allTargets = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [{
        data: "name"
      }, {
        data: "typeval"
      }, {
        data: "status"
      }, {
        data: "action"
      }],
      columnDefs: [{
        "targets": [0],
        "orderable": false
      }]
    };
    this.dataTableTarget = $(this.tabletarget.nativeElement);
    this.dataTableTarget.dataTable(this.dtOptionsTarget);
  }
  loadallRoutingplan(uuid) {
    if ($.fn.DataTable.isDataTable(this.tablerouting.nativeElement)) {
      $(this.tablerouting.nativeElement).dataTable().fnDestroy();
    }
    this.dtOptionsRouting = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      // "scrollX": true,
      "pageLength": 20,
      "lengthMenu": [[-1, 20, 100, 500, 2000], ["All", 20, 100, 500, 2000]],
      "order": [[0, "asc"]],
      "searching": true,
      ajax: (dataTablesParameters, callback) => {
        this.http.post(this.ServerUrl + 'getallRoutingplan/' + uuid + '/' + this.currentCompany.uuid, dataTablesParameters, {}).subscribe(resp => {
          this.allRoutingPlan = resp.data;
          console.log(this.allRoutingPlan);
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [{
        data: "priority"
      }, {
        data: "weight"
      }, {
        data: "name"
      }, {
        data: "destination"
      }, {
        data: "revenue"
      }, {
        data: "status"
      }, {
        data: "action"
      }]
      // columnDefs: [
      //   {
      //       "targets": [0],
      //       "orderable": false,
      //   },
      //   ],
    };

    this.dataTableRouting = $(this.tablerouting.nativeElement);
    this.dataTableRouting.dataTable(this.dtOptionsRouting);
  }
  DeleteRoutingPlan(uuid) {
    sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire({
      title: 'Are you sure?',
      text: 'You want to Delete Record!',
      showCancelButton: true,
      confirmButtonText: 'Yes, delete it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        var currentUser = JSON.parse(localStorage.getItem('currentUser'));
        this.moduleservice.deleteRoutingPlan(uuid, currentUser.uuid).subscribe(res => {
          // console.log(res);return false;
          sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Deleted!', 'Record Deleted Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
          }, 2000);
          this.loadallRoutingplan(this.uuid);
          this.loadcampaigntarget();
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Cancelled', 'Your Record is safe :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
        }, 2000);
      }
    });
  }
  DeletePublisherPayout(uuid) {
    sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire({
      title: 'Are you sure?',
      text: 'You want to Delete Record!',
      showCancelButton: true,
      confirmButtonText: 'Yes, delete it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        this.moduleservice.deletePublisherPayout(uuid).subscribe(res => {
          // console.log(res);return false;
          sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Deleted!', 'Record Deleted Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
          }, 2000);
          this.loadNumbers();
          this.loadcampaignpublishers(this.uuid);
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Cancelled', 'Your Record is safe :)');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
        }, 2000);
      }
    });
  }
  DeletePayoutNo(uuid, nouuid) {
    // console.log(nouuid); return
    sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire({
      title: 'Are you sure?',
      text: 'You want to Delete Record!',
      showCancelButton: true,
      confirmButtonText: 'Yes, delete it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        this.moduleservice.DeletePayoutNo(uuid, nouuid).subscribe(res => {
          // console.log(res);return false;
          sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Deleted!', 'Record Deleted Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
          }, 2000);
          this.loadNumbers();
          this.loadcampaignpublishers(this.uuid);
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Cancelled', 'Your Record is safe :)');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
        }, 2000);
      }
    });
  }
  Deletedefaultpayout() {
    this.defaultpayoutForm.reset();
    var currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.defaultpayoutForm.get('user_uuid').setValue(currentUser.uuid);
    this.defaultpayoutForm.get('payout_type').setValue(0);
    this.defaultpayoutForm.get('payout_amount').setValue("");
    this.defaultpayoutForm.get('payout_trigger').setValue(0);
    this.defaultpayoutForm.get('payout_seconds').setValue("");
    // console.log(this.defaultpayoutForm.value); return
    sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire({
      title: 'Are you sure?',
      text: 'You want to Delete Record!',
      showCancelButton: true,
      confirmButtonText: 'Yes, delete it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        var currentUser = JSON.parse(localStorage.getItem('currentUser'));
        this.moduleservice.adddefaultpayout(this.uuid, this.defaultpayoutForm.value).subscribe(res => {
          if (res.status !== 'error') {
            this.toastrService.success('Campaign default payout saved successfully');
            this.Submitted = false;
            this.getcampaignbyuuid();
            this.defaultpayoutForm.reset();
          } else {
            this.toastrService.error('Failed To add campaign payout');
          }
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Cancelled', 'Your Record is safe :)');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
        }, 2000);
      }
    });
  }
  setRouting(uuid) {
    sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire({
      title: 'Are you sure?',
      text: 'You want Add Routing Plan!',
      showCancelButton: true,
      confirmButtonText: 'Yes, Add it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        var currentUser = JSON.parse(localStorage.getItem('currentUser'));
        this.moduleservice.setcampaignRouting(uuid, this.uuid, currentUser.uuid).subscribe(res => {
          var currentUser = JSON.parse(localStorage.getItem('currentUser'));
          this.editForm.get('user_uuid').setValue(currentUser.uuid);
          // console.log(res);return false;
          this.loadallRoutingplan(this.uuid);
          this.loadcampaigntarget();
          // this.toastrService.success('Number Deleted Successfully');
          sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Added!', 'Routing Plan Added Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
          }, 2000);
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Cancelled', 'Routing Plan Cancelled :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
        }, 2000);
      }
    });
  }
  loadNumbers() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleservice.loadNumbersfordropdown(this.currentCompany.uuid).subscribe(resp => {
      this.numberdata = resp;
      //  console.log(this.numberdata);
    }, error => this.error = error);
  }
  getAllpublishers() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleservice.getAllpublishers(this.currentCompany.uuid).subscribe(res => {
      this.publisherdata = res;
      //  console.log(res);
    }, error => this.error = error);
  }
  getAlltarget() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleservice.getAlltarget(this.currentCompany.uuid).subscribe(res => {
      this.targetdata = res;
    }, error => this.error = error);
  }
  numberIsForval(type) {
    this.numberIsFor = type;
    this.editForm.get('numberIsFor').setValue(type);
  }
  payout_typevaledit(val) {
    this.payout_typevalueedit = val;
    this.payoutForm.get('payout_typeedit').setValue(val);
    this.publishtertocampaignForm.get('payout_typeedit').setValue(val);
  }
  notype_toggle(val) {
    this.notype = val;
    this.publishtertocampaignForm.get('isexisting').setValue(val);
  }
  istollfreenotype_toggle(val) {
    this.istollfree = val;
    this.publishtertocampaignForm.get('notype').setValue(val);
  }
  get editFormcontrol() {
    return this.editForm.controls;
  }
  onSubmit() {
    //  console.log(this.campaignNumbers);
    //  return false;
    var currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.editForm.get('user_uuid').setValue(currentUser.uuid);
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    // this.editForm.get('number').setValue(this.campaignNumbers)
    // this.editForm.get('labeldata').setValue(this.campaignLabels)
    if (this.recording == 2) {
      this.editForm.get('recording').setValue(2);
    }
    // console.log(this.isblacklistaliance);
    if (this.isblacklistaliance == 2) {
      this.editForm.get('enable_blacklist_aliance').setValue(2);
    }
    if (this.is_enable_offer == 2) {
      this.editForm.get('is_enable_offer').setValue(2);
    }
    if (this.ispredicaterouting == 2) {
      this.editForm.get('enable_predicaterouting').setValue(2);
    }
    this.showLoadingIndicator = true;
    this.moduleservice.updateCampaign(this.uuid, this.currentCompany.uuid, this.editForm.value).subscribe(res => {
      //  console.log(res); return false;
      this.showLoadingIndicator = false;
      if (res.status !== 'error') {
        this.isName = "fail";
        this.toastrService.success('Campaign Updated Successfully');
        this.Submitted = false;
        this.router.navigate(['/campaigns']);
      } else {
        this.toastrService.error('Failed To Update Campaign');
      }
    }, error => this.error = error);
  }
  validatename() {
    if (this.editForm.get('campaignName').value != '') {
      this.moduleservice.validateCampaignName(this.editForm.get('campaignName').value).subscribe(res => {
        // console.log(res); return false;
        this.isName = res;
        if (this.isName.status == 'success') {
          this.isName = "success";
        } else {
          this.isName = "fail";
        }
      });
    } else {
      this.isName = "";
    }
  }
  closeModal() {
    if (!this.payoutForm.invalid) {
      $("#addLabels").modal("hide");
    }
  }
  closepubModal() {
    if (!this.publishtertocampaignForm.invalid) {
      $("#addpublisher").modal("hide");
    }
  }
  closeroutingModal() {
    if (!this.editRoutingForm.invalid) {
      $("#editRouting").modal("hide");
    }
  }
  closedpayoutModal() {
    if (!this.defaultpayoutForm.invalid) {
      $("#addcampaignpayout").modal("hide");
    }
  }
  get payoutFormcontrol() {
    return this.payoutForm.controls;
  }
  onPayoutSubmit() {
    //  console.log(this.payoutForm.value);
    //  return false;
    var currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.payoutForm.get('user_uuid').setValue(currentUser.uuid);
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleservice.addpublisherpayout(this.uuid, this.payoutForm.value).subscribe(res => {
      if (res.status !== 'error') {
        this.toastrService.success('Publisher Payout Added Successfully');
        this.Submitted = false;
        this.loadcampaignpublishers(this.uuid);
      } else {
        this.toastrService.error('Failed To Update Campaign');
      }
    }, error => this.error = error);
  }
  get publisherFormcontrol() {
    return this.publishtertocampaignForm.controls;
  }
  onpublisherSubmit() {
    if (this.publisherselected) {
      this.publisherselected = this.publisherselected[0]['id'];
      this.publishtertocampaignForm.get('publisher_uuid').setValue(this.publisherselected);
    } else {
      sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Error!', 'Please select Publisher', 'error');
      return;
    }
    $("#addpublisher").modal("hide");
    if (this.publisherNumber) {
      this.publisherNumber = this.publisherNumber[0]['id'];
      this.publishtertocampaignForm.get('number').setValue(this.publisherNumber);
    }
    //  console.log(this.publisherNumber);
    //  return false;
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    var currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.publishtertocampaignForm.get('user_uuid').setValue(currentUser.uuid);
    this.moduleservice.addpublishertocampaign(this.uuid, this.publishtertocampaignForm.value).subscribe(res => {
      if (res.status !== 'error') {
        this.toastrService.success('Publisher to Campaign Added Successfully');
        this.Submitted = false;
        this.loadcampaignpublishers(this.uuid);
        this.publishtertocampaignForm.reset();
        this.loadNumbers();
        this.publisherselected = "";
      } else {
        this.toastrService.error('Failed To Update Campaign');
      }
    }, error => this.error = error);
  }
  payout_typeedit(val) {
    this.dpayout_type = val;
    this.defaultpayoutForm.get('payout_type').setValue(val);
  }
  get defaultpayoutFormcontrol() {
    return this.defaultpayoutForm.controls;
  }
  ondpayoutSubmit() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    var currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.defaultpayoutForm.get('user_uuid').setValue(currentUser.uuid);
    // console.log(this.defaultpayoutForm.value); return
    this.moduleservice.adddefaultpayout(this.uuid, this.defaultpayoutForm.value).subscribe(res => {
      if (res.status !== 'error') {
        this.toastrService.success('Campaign default payout saved successfully');
        this.Submitted = false;
        this.getcampaignbyuuid();
        this.defaultpayoutForm.reset();
      } else {
        this.toastrService.error('Failed To add campaign payout');
      }
    }, error => this.error = error);
  }
  get_recordingstatus(event) {
    this.recording = event.target.checked;
    // console.log(this.recording);
    if (this.recording == true) {
      this.editForm.get('recording').setValue(1);
      this.recording = 1;
    }
    if (this.recording == false) {
      this.editForm.get('recording').setValue(0);
      this.recording = 0;
    }
  }
  get_blacklistAliance(event) {
    this.isblacklistaliance = event.target.checked;
    if (this.isblacklistaliance == true) {
      this.editForm.get('enable_blacklist_aliance').setValue(1);
      this.isblacklistaliance = 1;
    }
    if (this.isblacklistaliance == false) {
      this.editForm.get('enable_blacklist_aliance').setValue(0);
      this.isblacklistaliance = 0;
    }
  }
  is_enable_offer_toggle(event) {
    this.is_enable_offer = event.target.checked;
    if (this.is_enable_offer == true) {
      this.editForm.get('is_enable_offer').setValue(1);
      this.is_enable_offer = 1;
    }
    if (this.is_enable_offer == false) {
      this.editForm.get('is_enable_offer').setValue(0);
      this.is_enable_offer = 0;
    }
  }
  get_predicaterouting(event) {
    this.ispredicaterouting = event.target.checked;
    if (this.ispredicaterouting == true) {
      this.editForm.get('enable_predicaterouting').setValue(1);
      this.ispredicaterouting = 1;
    }
    if (this.ispredicaterouting == false) {
      this.editForm.get('enable_predicaterouting').setValue(0);
      this.ispredicaterouting = 0;
    }
  }
  get_maxcon(event) {
    this.maxconcurrency = event.target.checked;
    // this.isselectlabel = false;
    // $(".labelswitch").prop('checked',false);
  }

  get_labelisselect(event) {
    this.isselectlabel = event.target.checked;
    // this.maxconcurrency = false;
    // $(".labelnumber").prop('checked',false);
  }

  settingToggleDuration(val) {
    this.settingToggleDurationvalue = val;
    this.editRoutingForm.get('settingToggleDurationval').setValue(val);
  }
  editRoutingdata(uuid, priority, weight, revenue, type, seconds, restrictdup, restrictafter, settingToggleDurationval, days, name) {
    // console.log(uuid)
    this.targetname = name;
    this.editRoutingForm.patchValue({
      uuid: uuid,
      priority: priority,
      weight: weight,
      conversation_revenue: revenue,
      conversation_event: type,
      conversation_seconds: seconds,
      restrictdup: restrictdup,
      restrictafter: restrictafter,
      days: days,
      settingToggleDurationval: settingToggleDurationval,
      settingToggleDuration: settingToggleDurationval
    });
    this.settingToggleDurationvalue = settingToggleDurationval;
  }
  changeVal(uuid, val, type) {
    this.moduleservice.change_routingplanval(uuid, val, type).subscribe(res => {
      if (res.status !== 'error') {
        // this.toastrService.success('Routing Plan Updated Successfully');
        this.Submitted = false;
        this.loadallRoutingplan(this.uuid);
      } else {
        // this.toastrService.error('Failed To Update Campaign');
      }
    }, error => this.error = error);
  }
  get editRoutingSubmit() {
    return this.editRoutingForm.controls;
  }
  oneditRoutingSubmit() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    var currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.editRoutingForm.get('user_uuid').setValue(currentUser.uuid);
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleservice.editRoutingSubmit(this.uuid, this.editRoutingForm.value).subscribe(res => {
      if (res.status !== 'error') {
        this.toastrService.success('Routing Plan Updated Successfully');
        this.Submitted = false;
        this.loadallRoutingplan(this.uuid);
      } else {
        this.toastrService.error('Failed To Update Campaign');
      }
    }, error => this.error = error);
  }
  gettimezone() {
    this.moduleservice.gettimezone().subscribe(res => {
      this.alltimezone = res;
      // console.log(res);
    });
  }

  getPredicateRouting() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleservice.getpredictiverouting(this.currentCompany.uuid).subscribe(res => {
      this.PredicateRouting = res;
      // console.log(res);
    });
  }

  exportdata() {
    var options = {
      fieldSeparator: ',',
      quoteStrings: '"',
      decimalseparator: '.',
      showLabels: true,
      useBom: true,
      headers: ["UUID", "Enabled", " Publisher", "Publisher UUID", "Number", "Associated Labels", "Number UUID", "Configuration Overrides", "Status"]
    };
    // console.log(this.campaignpublisher);
    new ngx_csv__WEBPACK_IMPORTED_MODULE_5__.ngxCsv(this.campaignpublisher, 'All Campaign Publishers', options);
  }
  getType(type, val) {
    // if(val==1){
    //   this.renderer.setProperty(window, 'scrollTo', {
    //     top: this.targetDiv.nativeElement.offsetTop,
    //     behavior: 'smooth'
    //   });
    // }
    if (type == 1) {
      $("#tabs3").removeClass("btn btn-primary btn-sm camactivetab");
      $("#tabs2").removeClass("btn btn-primary btn-sm camactivetab");
      $("#tabs1").addClass("camactivetab");
      this.filtertype = 1;
      //  this.loadcallsdata(this.filterselected,this.selecteddate,1);
    }

    if (type == 2) {
      $("#tabs1").removeClass("btn btn-primary btn-sm camactivetab");
      $("#tabs3").removeClass("btn btn-primary btn-sm camactivetab");
      $("#tabs2").addClass("camactivetab");
      this.filtertype = 2;
      //  this.loadcallsdata(this.filterselected,this.selecteddate,4);
    }

    if (type == 3) {
      $("#tabs1").removeClass("btn btn-primary btn-sm camactivetab");
      $("#tabs2").removeClass("btn btn-primary btn-sm camactivetab");
      $("#tabs3").addClass("camactivetab");
      this.filtertype = 3;
      //  this.loadcallsdata(this.filterselected,this.selecteddate,4);
    }
  }

  getScroll(val) {
    try {
      const errorField = this.renderer.selectRootElement('.first-class');
      errorField.scrollIntoView();
    } catch (err) {}
  }
  getParticipationType(type) {
    if (type == 1) {
      $("#tabs4").removeClass("btn btn-primary btn-sm camactivetab");
      $("#tabs3").addClass("camactivetab");
      this.pfiltertype = 1;
      //  this.loadcallsdata(this.filterselected,this.selecteddate,1);
    }

    if (type == 2) {
      $("#tabs3").removeClass("btn btn-primary btn-sm camactivetab");
      $("#tabs4").addClass("camactivetab");
      this.pfiltertype = 2;
      //  this.loadcallsdata(this.filterselected,this.selecteddate,4);
    }
  }

  reqdata(details) {
    this.parreqdata = details;
  }
  iscreateoffertoggle() {
    this.iscreateoffer = !this.iscreateoffer;
  }
  isshowmessagetoggle() {
    this.isshowmessage = !this.isshowmessage;
  }
  is_approvaltoggle(event) {
    if (event.target.checked == true) {
      this.is_approval = 1;
    } else {
      this.is_approval = 0;
    }
  }
  allow_tollfree_notoggle(event) {
    if (event.target.checked == true) {
      this.isallow_tollfree_no = 1;
    } else {
      this.isallow_tollfree_no = 0;
    }
  }
  is_allow_did_notoggle(event) {
    if (event.target.checked == true) {
      this.allow_did_no = 1;
    } else {
      this.allow_did_no = 0;
    }
  }
  get addOfferFormcontrol() {
    return this.addofferForm.controls;
  }
  onAddOfferSubmit(buttonType) {
    // console.log(this.addofferForm.get('description').value); return
    this.addofferSubmitted = true;
    const formData = new FormData();
    if (this.addofferForm.invalid) {
      return;
    }
    let exp_date = this.addofferForm.get('exp_date').value;
    let hrs = this.addofferForm.get('start_hrs').value;
    let min = this.addofferForm.get('start_min').value;
    let exp_date_full = `${exp_date} ${hrs}:${min}`;
    // console.log(exp_date_full); return
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    formData.append('campaign_uuid', this.uuid);
    formData.append('user_uuid', currentUser.uuid);
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('submittype', buttonType);
    formData.append('name', this.addofferForm.get('name').value);
    formData.append('description', this.addofferForm.get('description').value);
    formData.append('hoursofoperation', this.addofferForm.get('hoursofoperation').value);
    formData.append('exp_timezone', this.addofferForm.get('exp_timezone').value);
    formData.append('exp_date', exp_date_full);
    formData.append('req_approval', this.is_approval);
    formData.append('max_no_per_publisher', this.addofferForm.get('max_no_per_publisher').value);
    formData.append('allow_tollfree_no', this.isallow_tollfree_no);
    formData.append('allow_did_no', this.allow_did_no);
    // console.log(formData);
    this.moduleservice.addOffer(formData).subscribe(res => {
      if (res.status !== 'error') {
        this.toastrService.success('Offer details submitted Successfully');
        this.Submitted = false;
        this.isadded = 1;
        this.isedit = false;
        this.campaignoffers = [[]];
        this.loadparticipationrequest(this.uuid);
      } else {
        this.toastrService.error('Failed To save offer details');
      }
    }, error => this.error = error);
  }
  isedittoggle() {
    this.iscreateoffer = true;
    this.isedit = !this.isedit;
    var now = new Date(this.offerdetails.exp_date);
    var time = now.toTimeString();
    this.addofferForm.patchValue({
      name: this.offerdetails.name,
      description: this.offerdetails.description,
      hoursofoperation: this.offerdetails.hoursofoperation,
      exp_timezone: this.offerdetails.exp_timezone,
      exp_date: this.offerdetails.exp_date,
      start_hrs: time.slice(0, 2),
      start_min: time.slice(3, 5),
      max_no_per_publisher: this.offerdetails.max_no_per_publisher
    });
    this.today = new Date(this.offerdetails.exp_date).toISOString().split('T')[0];
    // console.log(time);
    this.is_approval = this.offerdetails.req_approval;
    this.isallow_tollfree_no = this.offerdetails.allow_tollfree_no;
    this.allow_did_no = this.offerdetails.allow_did_no;
  }
  changeofferstatus(status) {
    let msg = "Pause";
    let content = "Are you sure you want to pause the offer? Publishers won't be able to participate in the paused offer.";
    if (status == 1) {
      msg = "Resume";
      content = "Are you sure you want to resume the offer? Publishers will be able to participate in the offer.";
    }
    if (status == 3) {
      msg = "End";
      content = "Are you sure you want to end the offer and remove it from the campaign? All related phone numbers will be terminated, all participating publishers will be notified of this change.";
    }
    if (status == 4) {
      msg = "Enable";
      content = "Are you sure you want to enable the offer?";
    }
    if (status == 5) {
      msg = "Disable";
      content = "Are you sure you want to disable the offer?";
    }
    if (status == 2) {
      msg = "End";
    }
    sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire({
      title: 'Confirm ' + msg + ' Offer',
      text: content,
      showCancelButton: true,
      confirmButtonText: msg,
      cancelButtonText: 'Cancel'
    }).then(result => {
      if (result.value) {
        this.moduleservice.changeofferstatus(this.uuid, status).subscribe(res => {
          // console.log(res);return false;
          sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Success!', 'Offer ' + msg + ' Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
          }, 2000);
          if (status != 4 || status != 5) {
            this.loadparticipationrequest(this.uuid);
          }
          this.getcampaignbyuuid();
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Cancelled', 'Your Record is safe :)');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
        }, 2000);
      }
    });
  }
  approverejoffer(status) {
    // console.log(this.parreqdata); return
    let msg = "Approve";
    if (status == 3) {
      msg = "Reject";
    }
    sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire({
      text: 'Confirm ' + msg + ' Offer',
      // text: content,
      //
      showCancelButton: true,
      confirmButtonText: msg,
      cancelButtonText: 'Cancel'
    }).then(result => {
      if (result.value) {
        this.moduleservice.approverejoffer(this.parreqdata.uuid, status).subscribe(res => {
          // console.log(res);return false;
          $("#approveoffermodel").modal("hide");
          sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Success!', 'Offer ' + msg + ' Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
          }, 2000);
          this.loadparticipationrequest(this.uuid);
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Cancelled', 'Your Record is safe :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
        }, 2000);
      }
    });
  }
  setuuid(uuid) {
    this.payoutuuid = uuid;
  }
  get addnoFormcontrol() {
    return this.numberForm.controls;
  }
  onAddNoSubmit() {
    //  console.log(this.notype);
    //  console.log(this.selectedExistingNumber);
    //  console.log(this.payoutuuid);
    //  return false;
    this.addnoSubmitted = true;
    if (this.numberForm.invalid) {
      return;
    }
    $("#addNumber").modal("hide");
    var currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.numberForm.get('company_uuid').setValue(this.currentCompany.uuid);
    this.numberForm.get('user_uuid').setValue(currentUser.uuid);
    this.numberForm.get('campaign_uuid').setValue(this.uuid);
    this.numberForm.get('isexisting').setValue(this.notype);
    this.numberForm.get('selectedExistingNumber').setValue(JSON.stringify(this.selectedExistingNumber));
    this.numberForm.get('payoutuuid').setValue(this.payoutuuid);
    this.numberForm.get('isedit').setValue(1);
    this.numberForm.get('notype').setValue(this.istollfree);
    this.ngxLoader.startLoader('loader-04');
    this.moduleservice.purchase_number(this.uuid, this.numberForm.value).subscribe(res => {
      if (res.status !== 'error') {
        this.toastrService.success(res.message);
        this.Submitted = false;
        this.loadcampaignpublishers(this.uuid);
      } else {
        this.toastrService.error(res.message);
      }
      this.ngxLoader.stopLoader('loader-04');
    }, error => this.error = error);
  }
  static #_ = this.ctorParameters = () => [{
    type: _angular_core__WEBPACK_IMPORTED_MODULE_12__.Renderer2
  }, {
    type: _module_service__WEBPACK_IMPORTED_MODULE_3__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_13__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_9__.HttpBackend
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_10__.FormBuilder
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_14__.Router
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_14__.ActivatedRoute
  }, {
    type: _angular_core__WEBPACK_IMPORTED_MODULE_12__.ChangeDetectorRef
  }, {
    type: ngx_ui_loader__WEBPACK_IMPORTED_MODULE_15__.NgxUiLoaderService
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_16__.Title
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_12__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }],
    tabletarget: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_12__.ViewChild,
      args: ['dataTableTarget', {
        static: true
      }]
    }],
    tablependingreq: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_12__.ViewChild,
      args: ['dataTablePendingReq', {
        static: true
      }]
    }],
    tablerouting: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_12__.ViewChild,
      args: ['dataTableRouting', {
        static: true
      }]
    }],
    targetDiv: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_12__.ViewChild,
      args: ['targetDiv']
    }],
    Pertable: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_12__.ViewChild,
      args: ['PerdataTable', {
        static: true
      }]
    }],
    editdiv: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_12__.ViewChild,
      args: ['editdiv']
    }]
  };
};
CampaignEditComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_17__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_12__.Component)({
  selector: 'app-campaign-edit',
  template: _campaign_edit_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_campaign_edit_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], CampaignEditComponent);


/***/ }),

/***/ 51086:
/*!****************************************************************************!*\
  !*** ./src/app/modules/campaigns/campaign-view/campaign-view.component.ts ***!
  \****************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "CampaignViewComponent": () => (/* binding */ CampaignViewComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _campaign_view_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./campaign-view.component.html?ngResource */ 63681);
/* harmony import */ var _campaign_view_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./campaign-view.component.scss?ngResource */ 70771);
/* harmony import */ var _campaign_view_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_campaign_view_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../../../global */ 27266);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./../../module.service */ 22947);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! sweetalert2 */ 60598);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(sweetalert2__WEBPACK_IMPORTED_MODULE_4__);
/* harmony import */ var rxjs__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! rxjs */ 92218);
/* harmony import */ var ngx_ui_loader__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! ngx-ui-loader */ 36413);
/* harmony import */ var angular_highcharts__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! angular-highcharts */ 55199);
/* harmony import */ var highcharts_modules_exporting__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! highcharts/modules/exporting */ 43916);
/* harmony import */ var highcharts_modules_exporting__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(highcharts_modules_exporting__WEBPACK_IMPORTED_MODULE_5__);
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! highcharts */ 75972);
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_6__);
















highcharts_modules_exporting__WEBPACK_IMPORTED_MODULE_5___default()(highcharts__WEBPACK_IMPORTED_MODULE_6__);
class DataTablesResponse {}
let CampaignViewComponent = class CampaignViewComponent {
  constructor(renderer, moduleservice, toastrService, handler, fb, router, route, cdRef, ngxLoader) {
    this.renderer = renderer;
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.fb = fb;
    this.router = router;
    this.route = route;
    this.cdRef = cdRef;
    this.ngxLoader = ngxLoader;
    this.locations = [];
    this.dropdownList = [];
    this.selectedItems = [];
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_2__.GlobalVariable.BASE_API_URL;
    this.dtTrigger = new rxjs__WEBPACK_IMPORTED_MODULE_7__.Subject();
    this.dtOptions = {};
    this.editpayout_typeval = 0;
    this.campaignNumbers = [];
    this.campaignLabels = [];
    this.event = "";
    this.pendingdata = [];
    this.completed = [];
    this.offerdetails = [];
    this.Submitted = false;
    this.filtertype = 1;
    this.payout_typevalueedit = 0;
    this.addnoSubmitted = false;
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_8__.HttpClient(handler);
    this.uuid = this.route.snapshot.paramMap.get('id');
  }
  ngAfterViewChecked() {
    this.cdRef.detectChanges();
  }
  ngOnDestroy() {
    this.dtTrigger.unsubscribe();
  }
  ngOnInit() {
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.today = new Date().toISOString().split('T')[0];
    this.numberForm = this.fb.group({
      company_uuid: [''],
      user_uuid: [''],
      campaign_uuid: [''],
      notype: [0],
      prefix: ['']
    });
    this.getcampaignbyuuid();
    this.loadNumbers();
    this.loadcalls();
    this.getChartNumberOfCalls(this.event);
    this.loadcampaignpublishers(this.uuid);
    this.loadparticipationrequest(this.uuid);
  }
  getcampaignbyuuid() {
    this.moduleservice.getcampainbyuuid(this.uuid).subscribe(res => {
      this.getdata = res.campaigns;
      this.defaultconf = res.conf;
    }, error => this.error = error);
  }
  loadcampaignpublishers(uuid) {
    // console.log('ok');
    // return false;
    if ($.fn.DataTable.isDataTable(this.table.nativeElement)) {
      $(this.table.nativeElement).dataTable().fnDestroy();
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.dtOptions = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "pageLength": 20,
      "lengthMenu": [[-1, 20, 100, 500, 2000], ["All", 20, 100, 500, 2000]],
      "order": [[0, "asc"]],
      "searchDelay": 350,
      ajax: (dataTablesParameters, callback) => {
        this.http.post(this.ServerUrl + 'getCampaignPublisher/' + uuid, dataTablesParameters, {}).subscribe(resp => {
          this.campaignpublisher = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [{
        data: "phoneno"
      }, {
        data: "action"
      }],
      columnDefs: [{
        "targets": [0],
        "orderable": false
      }]
    };
    this.dataTable = $(this.table.nativeElement);
    this.dataTable.dataTable(this.dtOptions);
  }
  loadparticipationrequest(uuid) {
    this.ngxLoader.startLoader('loader-03');
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.http.post(this.ServerUrl + 'getParticipationRequest/' + uuid, {}).subscribe(resp => {
      // console.log(resp);                    
      this.offerdetails = resp.offerdetails;
      this.firstDate = new Date(resp.offerdetails.exp_date);
      this.secondDate = new Date();
      const ONE_DAY = 1000 * 60 * 60 * 24;
      const differenceMs = Math.abs(this.firstDate - this.secondDate);
      this.diffdays = Math.round(differenceMs / ONE_DAY);
      this.pendingdata = resp.data.pending ? resp.data.pending : [];
      this.completed = resp.data.completed ? resp.data.completed : [];
      this.dtTrigger.next();
      this.ngxLoader.stopLoader('loader-03');
    }, error => this.error = error);
  }
  loadNumbers() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleservice.loadNumbersfordropdown(this.currentCompany.uuid).subscribe(resp => {
      this.numberdata = resp;
      //  console.log(this.numberdata);
    }, error => this.error = error);
  }
  getType(type, val) {
    if (type == 1) {
      $("#tabs3").removeClass("btn btn-primary btn-sm camactivetab");
      $("#tabs2").removeClass("btn btn-primary btn-sm camactivetab");
      $("#tabs1").addClass("camactivetab");
      this.filtertype = 1;
      //  this.loadcallsdata(this.filterselected,this.selecteddate,1);
    }

    if (type == 2) {
      $("#tabs1").removeClass("btn btn-primary btn-sm camactivetab");
      $("#tabs3").removeClass("btn btn-primary btn-sm camactivetab");
      $("#tabs2").addClass("camactivetab");
      this.filtertype = 2;
      //  this.loadcallsdata(this.filterselected,this.selecteddate,4);
    }

    if (type == 3) {
      $("#tabs1").removeClass("btn btn-primary btn-sm camactivetab");
      $("#tabs2").removeClass("btn btn-primary btn-sm camactivetab");
      $("#tabs3").addClass("camactivetab");
      this.filtertype = 3;
      //  this.loadcallsdata(this.filterselected,this.selecteddate,4);
    }
  }

  reqdata(details) {
    this.parreqdata = details;
  }
  // iscreateoffer:Boolean=false;
  // iscreateoffertoggle() {    
  //   this.iscreateoffer = !this.iscreateoffer;    
  // }
  // isshowmessage:Boolean=true;
  // isshowmessagetoggle() {    
  //   this.isshowmessage = !this.isshowmessage;    
  // }
  offer_hide(status) {
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    $("#addpublisher").modal("hide");
    sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire({
      text: 'Are you sure you want to Leave offer?',
      showCancelButton: true,
      confirmButtonText: "Apply",
      cancelButtonText: 'Cancel'
    }).then(result => {
      if (result.value) {
        this.moduleservice.hideoffer(this.uuid, currentUser.uuid, status).subscribe(res => {
          // console.log(res);return false;              
          sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Success!', 'Offer Leave Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
          }, 2000);
          this.router.navigate(['/campaigns']);
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Cancelled', 'Your Record is safe :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
        }, 2000);
      }
    });
  }
  loadcalls() {
    if ($.fn.DataTable.isDataTable(this.Pertable.nativeElement)) {
      $(this.Pertable.nativeElement).dataTable().fnDestroy();
    }
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    var that = this;
    this.dtOptions = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "paging": false,
      "info": false,
      // "lengthMenu": [[-1, 50, 100, 500, 2000, 5000], ["All", 50, 100, 500, 2000, 5000 ]],
      "pageLength": 20,
      // "ordering": false,
      "searching": false,
      ajax: (dataTablesParameters, callback) => {
        that.http.post(this.ServerUrl + 'getlastweekcalls/' + this.currentCompany.uuid + '/' + currentUser.timezone + '/', {
          'dataTablesParameters': dataTablesParameters,
          'user_uuid': currentUser.uuid,
          'role': currentUser.role,
          'campaign_uuid': this.uuid
        }, {}).subscribe(resp => {
          // console.log(resp); return false;
          that.labels = resp.campaign_no;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [{
        data: "did"
      }, {
        data: "incoming_number"
      }, {
        data: "publisher"
      }, {
        data: "target"
      }, {
        data: "campaign"
      }, {
        data: "routed_to"
      }, {
        data: "routed_to"
      }, {
        data: "routed_to"
      }]
    };
    this.dataTable = $(this.Pertable.nativeElement);
    this.dataTable.dataTable(this.dtOptions);
  }
  getChartNumberOfCalls(event) {
    // console.log(event);return false;
    if (event != '') {
      this.date1 = event.endDate._d;
    } else {
      this.date1 = '';
    }
    // console.log(this.date1);
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    let params = {
      user_uuid: currentUser.uuid,
      role: currentUser.role,
      date: this.date1,
      campaign_uuid: this.uuid
    };
    this.moduleservice.getChartbyDate(this.currentCompany.uuid, params, currentUser.timezone).subscribe(res => {
      //  console.log(res); 
      if ($("html").hasClass("dark")) {
        this.bgcolorcode = 'rgb(17,19,25)';
      }
      this.chart = new angular_highcharts__WEBPACK_IMPORTED_MODULE_9__.Chart({
        chart: {
          // polar: true,
          type: 'line',
          backgroundColor: this.bgcolorcode
        },
        exporting: {
          enabled: true
        },
        title: {
          text: ''
        },
        credits: {
          enabled: false
        },
        xAxis: {
          minRange: 0,
          gridLineWidth: 0,
          title: {
            text: 'Hours'
          }
        },
        yAxis: {
          min: 0,
          gridLineWidth: 1,
          title: {
            text: 'Number Of Calls'
          }
        },
        legend: {
          enabled: false
        },
        plotOptions: {
          area: {
            fillColor: {
              linearGradient: {
                x1: 0,
                y1: 0,
                x2: 0,
                y2: 1
              },
              stops: [[0, '#7cb5ec'], [1, 'rgba(124,181,236,0)']]
            },
            marker: {
              radius: 2
            },
            lineWidth: 1,
            states: {
              hover: {
                lineWidth: 1
              }
            },
            threshold: null
          },
          line: {
            dataLabels: {
              enabled: true
            },
            enableMouseTracking: false
          }
        },
        series: [{
          data: res,
          type: 'area',
          name: "Call Count"
        }]
      });
    }, error => this.error = error);
  }
  closeModal() {
    if (!this.numberForm.invalid) {
      $("#addNumber").modal("hide");
    }
  }
  payout_typevaledit(val) {
    this.payout_typevalueedit = val;
    this.numberForm.get('notype').setValue(val);
  }
  get addnoFormcontrol() {
    return this.numberForm.controls;
  }
  onAddNoSubmit() {
    //  console.log(this.payoutForm.value);
    //  return false;
    this.addnoSubmitted = true;
    if (this.numberForm.invalid) {
      return;
    }
    var currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.numberForm.get('company_uuid').setValue(this.currentCompany.uuid);
    this.numberForm.get('user_uuid').setValue(currentUser.uuid);
    this.numberForm.get('campaign_uuid').setValue(this.uuid);
    this.ngxLoader.startLoader('loader-04');
    this.moduleservice.purchase_number(this.uuid, this.numberForm.value).subscribe(res => {
      if (res.status !== 'error') {
        this.toastrService.success(res.message);
        this.Submitted = false;
        this.loadcampaignpublishers(this.uuid);
      } else {
        this.toastrService.error(res.message);
      }
      this.ngxLoader.stopLoader('loader-04');
    }, error => this.error = error);
  }
  DeleteNumber(no, uuid) {
    sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire({
      title: 'Are you sure?',
      text: 'You want to Delete Record!',
      showCancelButton: true,
      confirmButtonText: 'Yes, delete it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        var currentUser = JSON.parse(localStorage.getItem('currentUser'));
        let formData = new FormData();
        formData.append('number', no);
        formData.append('number_uuid', uuid);
        this.ngxLoader.startLoader('loader-04');
        this.moduleservice.DeletePurNumber(formData).subscribe(res => {
          // console.log(res);return false;
          this.ngxLoader.stopLoader('loader-04');
          sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Deleted!', 'Record Deleted Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
          }, 2000);
          this.loadcampaignpublishers(this.uuid);
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Cancelled', 'Your Record is safe :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
        }, 2000);
      }
    });
  }
  static #_ = this.ctorParameters = () => [{
    type: _angular_core__WEBPACK_IMPORTED_MODULE_10__.Renderer2
  }, {
    type: _module_service__WEBPACK_IMPORTED_MODULE_3__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_11__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_8__.HttpBackend
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_12__.FormBuilder
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_13__.Router
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_13__.ActivatedRoute
  }, {
    type: _angular_core__WEBPACK_IMPORTED_MODULE_10__.ChangeDetectorRef
  }, {
    type: ngx_ui_loader__WEBPACK_IMPORTED_MODULE_14__.NgxUiLoaderService
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_10__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }],
    Pertable: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_10__.ViewChild,
      args: ['PerdataTable', {
        static: true
      }]
    }]
  };
};
CampaignViewComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_15__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_10__.Component)({
  selector: 'app-campaign-view',
  template: _campaign_view_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_campaign_view_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], CampaignViewComponent);


/***/ }),

/***/ 78007:
/*!**********************************************************!*\
  !*** ./src/app/modules/campaigns/campaigns.component.ts ***!
  \**********************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "CampaignsComponent": () => (/* binding */ CampaignsComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _campaigns_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./campaigns.component.html?ngResource */ 70517);
/* harmony import */ var _campaigns_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./campaigns.component.scss?ngResource */ 79315);
/* harmony import */ var _campaigns_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_campaigns_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../module.service */ 22947);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! sweetalert2 */ 60598);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(sweetalert2__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../global */ 27266);
/* harmony import */ var rxjs__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! rxjs */ 92218);
/* harmony import */ var ngx_ui_loader__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ngx-ui-loader */ 36413);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! @angular/platform-browser */ 34497);









//import 'sweetalert2/src/sweetalert2.scss'





const router = _angular_router__WEBPACK_IMPORTED_MODULE_5__.Router;
class DataTablesResponse {}
let CampaignsComponent = class CampaignsComponent {
  constructor(moduleservice, toastrService, handler, fb, changedetect, ngxLoader, titleService) {
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.fb = fb;
    this.changedetect = changedetect;
    this.ngxLoader = ngxLoader;
    this.titleService = titleService;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_4__.GlobalVariable.BASE_API_URL;
    this.dtOptions = {
      "pageLength": 20,
      "lengthMenu": [[-1, 20, 50, 100, 500, 2000, 5000], ["All", 20, 50, 100, 500, 2000, 5000]]
    };
    this.dtTrigger = new rxjs__WEBPACK_IMPORTED_MODULE_6__.Subject();
    this.ischecked = '1';
    // loadpublishers(){
    //       // console.log('ok');
    //       // return false;
    //         if ($.fn.DataTable.isDataTable(this.table.nativeElement) ) {
    //           $(this.table.nativeElement).dataTable().fnDestroy();
    //         }
    //        this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    //        let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    //       //  console.log(currentUser); return
    //        this.dtOptions = {
    //           "pagingType": 'full_numbers',
    //           "processing": true,
    //           "serverSide": true,
    //           "pageLength": 20,
    //           "order": [[ 0, "asc" ]],
    //           ajax: (dataTablesParameters: any, callback) => {
    //             this.http.post<DataTablesResponse>(
    //               this.ServerUrl+'getCampaign/'+this.currentCompany.uuid +'/'+ currentUser.timezone,
    //               dataTablesParameters, {}
    //             ).subscribe(resp => {
    //                       this.numbers = resp.data;
    //                       callback({
    //                           recordsTotal: resp.recordsTotal,
    //                           recordsFiltered: resp.recordsFiltered,
    //                           data: [],
    //                       });
    //                   });
    //           },
    //           columns: [
    //             {data:"name"},{data:"country"},{data:"status"},{data:"is_recording"},{data:"created_at"},{data:"action"},
    //           ],
    //           columnDefs: [
    //             {
    //                 "targets": [0],
    //                 "orderable": false,
    //             },
    //             ],
    //       };
    //     this.dataTable = $(this.table.nativeElement);
    //     this.dataTable.dataTable(this.dtOptions);
    // }
    this.settingToggleAccessToRecordingsvaldata = 0;
    this.settingToggleBlockCallsIfCappeddata = 0;
    this.checkboxes = [];
    this.settingToggleBlockCallsIfCappededit = 0;
    this.settingToggleAccessToRecordingsedit = 0;
    this.Submitted = false;
    this.editSubmitted = false;
    this.payoutdata = [];
    this.conf = "";
    this.isoffer = false;
    this.isrevshareper = false;
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_7__.HttpClient(handler);
    this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.loader = {
      // hasProgressBar: true,
      loaderId: 'customLoaderId'
      // isMaster: false,
      // fgsSize: 100,
      // bgsSize: 64,
      // gap: 80,
      // text: '',
    };
  }

  ngOnDestroy() {
    this.dtTrigger.unsubscribe();
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngOnInit() {
    this.setTitle('Manage Campaigns');
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.loadpublishers();
    // this.loadNumbers();
    this.addForm = this.fb.group({
      name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_8__.Validators.required],
      sub_id: [''],
      number_creation: [''],
      settingToggleBlockCallsIfCapped: [''],
      settingToggleAccessToRecordings: ['']
    });
    this.editForm = this.fb.group({
      uuid: [''],
      name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_8__.Validators.required],
      sub_id: [''],
      number_creation: [''],
      settingToggleBlockCallsIfCapped: [''],
      settingToggleAccessToRecordings: ['']
    });
  }
  ngAfterViewInit() {
    this.changedetect.detectChanges();
  }
  // numberdata:any;
  // loadNumbers(){
  //   this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
  //   this.moduleservice.loadNumbersfordropdown(this.currentCompany.uuid).subscribe(
  //     res => {
  //       this.numberdata= res
  //       },
  //       error => this.error = error
  //   );
  // }
  loadpublishers() {
    $("#campaigntbl").dataTable().fnDestroy();
    this.ngxLoader.startLoader('customLoaderId', 'loader-03');
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.http.post(this.ServerUrl + 'getCampaign/' + this.currentCompany.uuid + '/' + currentUser.timezone, {
      role: currentUser.role,
      uuid: currentUser.uuid
    }).subscribe(resp => {
      // console.log(resp);
      this.numbers = resp.data;
      this.dtTrigger.next();
      this.ngxLoader.stopLoader('customLoaderId', 'loader-03');
    }, error => this.error = error);
  }
  editdata(uuid, name, sub_id, create_number, settingToggleBlockCallsIfCapped, settingToggleAccessToRecordings) {
    this.settingToggleAccessToRecordingsvaldata = settingToggleAccessToRecordings;
    this.settingToggleBlockCallsIfCappeddata = settingToggleBlockCallsIfCapped;
    this.editForm.patchValue({
      uuid: uuid,
      name: name,
      sub_id: sub_id,
      number_creation: create_number,
      settingToggleBlockCallsIfCapped: settingToggleBlockCallsIfCapped,
      settingToggleAccessToRecordings: settingToggleAccessToRecordings
    });
  }
  checkalldelete(event) {
    const checked = event.target.checked;
    this.numbers.forEach(chkbox => chkbox.selected = checked);
  }
  deleteselected(event) {
    // $("#customCheck1").prop("checked", false);
    if (event.target.checked == true) {
      if (event.target.value == 'on') {
        this.checkboxes = [];
        this.numbers.forEach(lbl => {
          this.checkboxes.push(lbl.id);
        });
      } else {
        if (this.checkboxes.length + 1 == this.numbers.length) {
          $("#customCheck1").prop("checked", true);
        }
        this.checkboxes.push(event.target.value);
      }
      this.ischecked = '0';
    } else {
      // console.log(this.checkboxes);
      if (this.checkboxes.length != 0) {
        $("#customCheck1").prop("checked", false);
      }
      if (event.target.value != 'on') {
        const index = this.checkboxes.indexOf(event.target.value);
        this.checkboxes.splice(index, 1);
      } else {
        this.checkboxes = [];
      }
      this.ischecked = '1';
    }
    // console.log(this.checkboxes);
  }
  // onDeleteSubmit(){
  //   if(this.checkboxes.length==0){
  //     this.toastrService.error('Please Select Row To Delete');
  //   }else{
  //     // console.log(this.checkboxes);
  //     Swal.fire({
  //       title: 'Are you sure?',
  //       text: 'You want to Delete Selected Record!',
  //
  //       showCancelButton: true,
  //       confirmButtonText: 'Yes, delete it!',
  //       cancelButtonText: 'No, keep it'
  //     }).then((result) => {
  //       if (result.value) {
  //         this.moduleservice.deleteSelectedNumbers(this.checkboxes).subscribe(
  //           res => {
  //               Swal.fire(
  //                 'Deleted!',
  //                 'Records Deleted Successfully.',
  //                 'success',
  //               )
  //               setTimeout(() => {
  //                 Swal.close()
  //               }, 2000);
  //               this.loadpublishers();
  //             },
  //             error => this.error = error
  //         );
  //       } else if (result.dismiss === Swal.DismissReason.cancel) {
  //         Swal.fire(
  //           'Cancelled',
  //           'Your Record is safe :)',
  //           'error'
  //         )
  //         setTimeout(() => {
  //           Swal.close()
  //         }, 2000);
  //       }
  //     });
  //   }
  // }
  Delete(id) {
    sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
      title: 'Are you sure?',
      text: 'You want to Delete Record!',
      showCancelButton: true,
      confirmButtonText: 'Yes, delete it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        this.moduleservice.deleteCampaign(+id).subscribe(res => {
          // console.log(res);return false;
          this.loadpublishers();
          // this.toastrService.success('Number Deleted Successfully');
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Record Deleted Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
        }, 2000);
      }
    });
  }
  settingToggleBlockCallsIfCappedval(val) {
    this.addForm.get('settingToggleBlockCallsIfCapped').setValue(val);
  }
  settingToggleAccessToRecordingsval(val) {
    this.addForm.get('settingToggleAccessToRecordings').setValue(val);
  }
  settingToggleBlockCallsIfCappedvaledit(val) {
    this.settingToggleBlockCallsIfCappededit = val;
    this.editForm.get('settingToggleBlockCallsIfCapped').setValue(val);
  }
  settingToggleAccessToRecordingsvaledit(val) {
    this.settingToggleAccessToRecordingsedit = val;
    this.editForm.get('settingToggleAccessToRecordings').setValue(val);
  }
  //Add Publisher
  get addformcontrol() {
    return this.addForm.controls;
  }
  onSubmit() {
    const formData = new FormData();
    this.Submitted = true;
    if (this.addForm.invalid) {
      return;
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('name', this.addForm.get('name').value);
    formData.append('sub_id', this.addForm.get('sub_id').value);
    formData.append('number_creation', this.addForm.get('number_creation').value);
    formData.append('settingToggleBlockCallsIfCapped', this.addForm.get('settingToggleBlockCallsIfCapped').value);
    formData.append('settingToggleAccessToRecordings', this.addForm.get('settingToggleAccessToRecordings').value);
    // console.log(formData); return false;
    this.moduleservice.addPublisher(formData).subscribe(res => {
      // console.log(res.status); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Publisher Added Successfully');
        this.loadpublishers();
        this.Submitted = false;
      } else {
        this.toastrService.error('Failed To Add Label');
      }
    }, error => this.error = error);
  }
  //Add Buyer
  get editFormcontrol() {
    return this.editForm.controls;
  }
  onEditSubmit() {
    // alert('ok');return false;
    const formData = new FormData();
    this.editSubmitted = true;
    if (this.editForm.invalid) {
      return;
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('uuid', this.editForm.get('uuid').value);
    formData.append('name', this.editForm.get('name').value);
    formData.append('sub_id', this.editForm.get('sub_id').value);
    formData.append('number_creation', this.editForm.get('number_creation').value);
    formData.append('settingToggleBlockCallsIfCapped', this.editForm.get('settingToggleBlockCallsIfCapped').value);
    formData.append('settingToggleAccessToRecordings', this.editForm.get('settingToggleAccessToRecordings').value);
    // console.log(formData);
    this.moduleservice.editPublisher(formData).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Publisher Updated Successfully');
        this.loadpublishers();
        this.editSubmitted = false;
      } else {
        this.toastrService.error('Failed To Add Label');
      }
    }, error => this.error = error);
  }
  closeModal() {
    if (this.addForm.get('name').value != '') {
      $("#addLabels").modal("hide");
      // $(".custom-switch-input").prop('checked',false);
      this.Submitted = false;
      setTimeout(() => {
        this.addForm.reset();
      }, 2000);
    }
  }
  closeEditModal() {
    if (this.editForm.get('name').value != '') {
      $("#editLabels").modal("hide");
      this.editSubmitted = false;
      setTimeout(() => {
        this.editForm.reset();
      }, 2000);
    }
  }
  Status(id, status) {
    sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
      title: 'Are you sure?',
      text: 'You want to change Status!',
      showCancelButton: true,
      confirmButtonText: 'Yes, Change it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        this.moduleservice.changeCampaignstatus(id, status).subscribe(res => {
          this.loadpublishers();
          // this.toastrService.success('Number Deleted Successfully');
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Changed!', 'Status Changes Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
        }, 2000);
      }
    });
  }
  applyoffer(conf, payoutdata, details, campaign, offer_apply_status) {
    this.offerdetails = details;
    this.offer_apply_status = offer_apply_status;
    this.campaign = campaign;
    this.payoutdata = payoutdata;
    this.conf = conf;
    // console.log(conf);
  }

  isofferpayout() {
    this.isoffer = !this.isoffer;
  }
  isrevsharepertg() {
    this.isrevshareper = !this.isrevshareper;
  }
  offer_hide(uuid, status) {
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    $("#addpublisher").modal("hide");
    sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
      text: 'Are you sure you want to hide offer?',
      showCancelButton: true,
      confirmButtonText: "Apply",
      cancelButtonText: 'Cancel'
    }).then(result => {
      if (result.value) {
        this.moduleservice.hideoffer(uuid, currentUser.uuid, status).subscribe(res => {
          // console.log(res);return false;
          this.loadpublishers();
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Success!', 'Offer hide Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
        }, 2000);
      }
    });
  }
  apply_offer() {
    const formData = new FormData();
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    formData.append('user_uuid', currentUser.uuid);
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('apply_message', this.apply_message);
    formData.append('offerdetails', JSON.stringify(this.offerdetails));
    this.moduleservice.apply_offer(formData).subscribe(res => {
      // console.log(res);return false;
      $('#offer_apply').modal('hide');
      this.loadpublishers();
      sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
        title: 'Success!',
        text: 'Offer applied Successfully.'
      });
      setTimeout(() => {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
      }, 2000);
      // this.loadparticipationrequest(this.uuid);
    }, error => this.error = error);
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_9__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_7__.HttpBackend
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_8__.FormBuilder
  }, {
    type: _angular_core__WEBPACK_IMPORTED_MODULE_10__.ChangeDetectorRef
  }, {
    type: ngx_ui_loader__WEBPACK_IMPORTED_MODULE_11__.NgxUiLoaderService
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_12__.Title
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_10__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }]
  };
};
CampaignsComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_13__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_10__.Component)({
  selector: 'app-campaigns',
  template: _campaigns_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_campaigns_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], CampaignsComponent);


/***/ }),

/***/ 97316:
/*!**********************************************************!*\
  !*** ./src/app/modules/changelog/changelog.component.ts ***!
  \**********************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "ChangelogComponent": () => (/* binding */ ChangelogComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _changelog_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./changelog.component.html?ngResource */ 23635);
/* harmony import */ var _changelog_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./changelog.component.scss?ngResource */ 36080);
/* harmony import */ var _changelog_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_changelog_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../module.service */ 22947);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../global */ 27266);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/platform-browser */ 34497);










const router = _angular_router__WEBPACK_IMPORTED_MODULE_4__.Router;
class DataTablesResponse {}
let ChangelogComponent = class ChangelogComponent {
  constructor(moduleservice, toastrService, handler, titleService) {
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.titleService = titleService;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_3__.GlobalVariable.BASE_API_URL;
    this.dtOptions = {};
    this.ischecked = '1';
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_5__.HttpClient(handler);
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngOnInit() {
    this.setTitle('Change Logs');
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.loadChangeLogs();
  }
  loadChangeLogs() {
    // console.log('ok');
    // return false;
    if ($.fn.DataTable.isDataTable(this.table.nativeElement)) {
      $(this.table.nativeElement).dataTable().fnDestroy();
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.dtOptions = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "lengthMenu": [[-1, 50, 100, 200, 500, 1000], ["All", 50, 100, 200, 500, 1000]],
      "pageLength": 200,
      "order": [[1, "desc"]],
      ajax: (dataTablesParameters, callback) => {
        this.http.post(this.ServerUrl + 'getchangelog/' + this.currentCompany.uuid, dataTablesParameters, {}).subscribe(resp => {
          this.numbers = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [{
        data: "user"
      }, {
        data: "modulename"
      }, {
        data: "operation_type"
      }, {
        data: "description_string"
      }, {
        data: "created_at"
      }]
      // columnDefs: [
      //   { 
      //       "targets": [0], 
      //       "orderable": false,
      //   },
      //   ],
    };

    this.dataTable = $(this.table.nativeElement);
    this.dataTable.dataTable(this.dtOptions);
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_6__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_5__.HttpBackend
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_7__.Title
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_8__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }]
  };
};
ChangelogComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_9__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_8__.Component)({
  selector: 'app-changelog',
  template: _changelog_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_changelog_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], ChangelogComponent);


/***/ }),

/***/ 6957:
/*!**********************************************************!*\
  !*** ./src/app/modules/dashboard/dashboard.component.ts ***!
  \**********************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "DashboardComponent": () => (/* binding */ DashboardComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _dashboard_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./dashboard.component.html?ngResource */ 19250);
/* harmony import */ var _dashboard_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./dashboard.component.scss?ngResource */ 32399);
/* harmony import */ var _dashboard_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_dashboard_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../module.service */ 22947);
/* harmony import */ var angular_highcharts__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! angular-highcharts */ 55199);
/* harmony import */ var highcharts_modules_exporting__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! highcharts/modules/exporting */ 43916);
/* harmony import */ var highcharts_modules_exporting__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(highcharts_modules_exporting__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! highcharts */ 75972);
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_4__);
/* harmony import */ var datatables_net__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! datatables.net */ 84375);
/* harmony import */ var datatables_net__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(datatables_net__WEBPACK_IMPORTED_MODULE_5__);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../global */ 27266);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var rxjs__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! rxjs */ 92218);
/* harmony import */ var ngx_ui_loader__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ngx-ui-loader */ 36413);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! @angular/platform-browser */ 34497);
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! moment */ 56908);
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(moment__WEBPACK_IMPORTED_MODULE_7__);











highcharts_modules_exporting__WEBPACK_IMPORTED_MODULE_3___default()(highcharts__WEBPACK_IMPORTED_MODULE_4__);




class DataTablesResponse {}
let DashboardComponent = class DashboardComponent {
  constructor(moduleservice, handler, titleService, ngxLoader) {
    this.moduleservice = moduleservice;
    this.titleService = titleService;
    this.ngxLoader = ngxLoader;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_6__.GlobalVariable.BASE_API_URL;
    this.NumberOfNumbers = 0;
    this.event = "";
    this.dtTrigger = new rxjs__WEBPACK_IMPORTED_MODULE_8__.Subject();
    this.dtTrigger_target = new rxjs__WEBPACK_IMPORTED_MODULE_8__.Subject();
    this.dtOptionsTop = {
      dom: 'rt'
    };
    this.dtOptions = {};
    this.dtOptions_target = {};
    this.currentDate = new Date();
    this.numbers = [];
    this.pfiltertype = 0;
    this.top_performer = [];
    this.top_target = [];
    this.top_campaign = [];
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_9__.HttpClient(handler);
    this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.loader = {
      loaderId: 'customLoaderId',
      loaderId1: 'customLoaderId1',
      loaderId2: 'customLoaderId2'
    };
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngOnInit() {
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.setTitle('Dashboard');
    // console.log(this.currentCompany);
    // this.getNumberOfCounts();
    // this.getNumberOfIVR();
    // this.getNumberOfNumbers();
    // this.getNumberOfSMS();
    this.getChartNumberOfCalls(this.event);
    this.loadcalls();
    this.loadtoppreformenr();
    this.loadTargets();
  }
  loadTargets() {
    if ($.fn.DataTable.isDataTable(this.table_target.nativeElement)) {
      $(this.table_target.nativeElement).dataTable().fnDestroy();
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.dtOptions_target = {
      "pagingType": 'full_numbers',
      // "lengthChange": false,
      "processing": true,
      "searching": false,
      "serverSide": true,
      "pageLength": 20,
      "lengthMenu": [[-1, 20, 50, 100], ["All", 20, 50, 100]],
      "order": [[1, "desc"]],
      ajax: (dataTablesParameters, callback) => {
        this.http.post(this.ServerUrl + 'gettargets/' + this.currentCompany.uuid, {
          'dataTablesParameters': dataTablesParameters,
          'user_uuid': currentUser.uuid,
          'role': currentUser.role,
          'type': 1
        }, {}).subscribe(resp => {
          // let data = resp.data.filter((item,i)=>{
          //   return item.month>0;
          // })
          // let finaldata = data.sort((a,b)=>{
          //     return b.month - a.month;
          // })
          this.dtTrigger_target.next();
          this.numbers = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [{
        data: "name"
      }, {
        data: "hour"
      }, {
        data: "active_status"
      }, {
        data: "action"
      }]
    };
    this.datatable_target = $(this.table_target.nativeElement);
    this.datatable_target.dataTable(this.dtOptions_target);
  }
  getChartNumberOfCalls(event) {
    // console.log(event);return false;
    if (event != '') {
      this.date1 = event.endDate._d;
    } else {
      this.date1 = JSON.stringify({
        startDate: moment__WEBPACK_IMPORTED_MODULE_7__().format("MM/DD/YYYY 00:00"),
        endDate: moment__WEBPACK_IMPORTED_MODULE_7__().format("MM/DD/YYYY 23:59")
      });
    }
    let params = {
      user_uuid: this.currentUser.uuid,
      role: "",
      date: this.date1
    };
    // console.log(this.date1);
    this.moduleservice.getChartbyDate(this.currentCompany.uuid, params, this.currentUser.timezone).subscribe(res => {
      //  console.log(res);
      if ($("html").hasClass("dark")) {
        this.bgcolorcode = 'rgb(17,19,25)';
      }
      this.chart = new angular_highcharts__WEBPACK_IMPORTED_MODULE_10__.Chart({
        chart: {
          // polar: true,
          type: 'line',
          backgroundColor: this.bgcolorcode
        },
        exporting: {
          enabled: true
        },
        title: {
          text: ''
        },
        // subtitle: {
        //   text: document.ontouchstart === undefined ?
        //     'Click and drag in the plot area to zoom in' : 'Pinch the chart to zoom in'
        // },
        credits: {
          enabled: false
        },
        xAxis: {
          minRange: 0,
          gridLineWidth: 0,
          title: {
            text: 'Hours'
          }
        },
        yAxis: {
          min: 0,
          gridLineWidth: 1,
          title: {
            text: 'Number Of Calls'
          },
          gridLineColor: '#2f3031'
        },
        legend: {
          enabled: false
        },
        // plotOptions: {
        //   area: {
        //     fillColor: {
        //       linearGradient: {
        //         x1: 0,
        //         y1: 0,
        //         x2: 0,
        //         y2: 1
        //       },
        //       stops: [
        //         [0, '#7cb5ec'],
        //         [1, 'rgba(124,181,236,0)']
        //       ]
        //     },
        //     marker: {
        //       radius: 2
        //     },
        //     lineWidth: 1,
        //     states: {
        //       hover: {
        //         lineWidth: 1
        //       }
        //     },
        //     threshold: null
        //   }
        // },
        plotOptions: {
          area: {
            fillColor: {
              linearGradient: {
                x1: 0,
                y1: 0,
                x2: 0,
                y2: 1
              },
              stops: [[0, '#7cb5ec'], [1, 'rgba(124,181,236,0)']]
            },
            marker: {
              radius: 2
            },
            lineWidth: 1,
            states: {
              hover: {
                lineWidth: 1
              }
            },
            threshold: null
          },
          line: {
            dataLabels: {
              enabled: true
            },
            enableMouseTracking: false
          }
        },
        series: [{
          data: res,
          type: 'area',
          name: "Call Count"
        }]
      });
    }, error => this.error = error);
  }
  // getchart(event:any){
  //   const date = event.startDate._d;
  //   // console.log();
  //   this.moduleservice.getChartbyDate(this.currentUser.uuid,date).subscribe(
  //     res => {
  //       this.NumberOfCalls = res;
  //     },
  //     error => this.error = error
  //   );
  // }
  loadcalls() {
    if ($.fn.DataTable.isDataTable(this.table.nativeElement)) {
      $(this.table.nativeElement).dataTable().fnDestroy();
    }
    this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    var that = this;
    this.dtOptions = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "paging": false,
      "info": false,
      // "lengthMenu": [[-1, 50, 100, 500, 2000, 5000], ["All", 50, 100, 500, 2000, 5000 ]],
      "pageLength": 20,
      // "ordering": false,
      "searching": false,
      ajax: (dataTablesParameters, callback) => {
        that.http.post(this.ServerUrl + 'getlastweekcalls/' + this.currentCompany.uuid + '/' + this.currentUser.timezone + '/', {
          'dataTablesParameters': dataTablesParameters,
          'user_uuid': this.currentUser.uuid,
          'role': ""
        }, {}).subscribe(resp => {
          // console.log(resp); return false;
          that.labels = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [{
        data: "did"
      }, {
        data: "incoming_number"
      }, {
        data: "publisher"
      }, {
        data: "target"
      }, {
        data: "campaign"
      }, {
        data: "routed_to"
      }, {
        data: "routed_to"
      }, {
        data: "routed_to"
      }]
    };
    this.dataTable = $(this.table.nativeElement);
    this.dataTable.dataTable(this.dtOptions);
  }
  getNumberOfCounts() {
    // console.log(this.currentUser.timezone);
    this.moduleservice.getNumberOfCount(this.currentCompany.uuid, this.currentUser.timezone).subscribe(res => {
      this.NumberOfCalls = res.NumberOfcalls;
      this.NumberOfIVR = res.NumberOfivr;
      this.NumberOfNumbers = res.NumberOfnos;
      this.NumberOfSMS = res.NumberOfsms;
      // console.log(this.NumberOfCounts);
    }, error => this.error = error);
  }
  getParticipationType(type) {
    if (type == 0) {
      $("#tabs2").removeClass("btn btn-primary btn-sm camactivetab");
      $("#tabs3").removeClass("btn btn-primary btn-sm camactivetab");
      $("#tabs1").addClass("camactivetab");
      this.pfiltertype = 0;
      this.loadtoppreformenr();
    }
    if (type == 1) {
      $("#tabs1").removeClass("btn btn-primary btn-sm camactivetab");
      $("#tabs3").removeClass("btn btn-primary btn-sm camactivetab");
      $("#tabs2").addClass("camactivetab");
      this.pfiltertype = 1;
      this.loadtoptarget();
    }
    if (type == 2) {
      $("#tabs1").removeClass("btn btn-primary btn-sm camactivetab");
      $("#tabs2").removeClass("btn btn-primary btn-sm camactivetab");
      $("#tabs3").addClass("camactivetab");
      this.pfiltertype = 2;
      this.loadtopcampaign();
    }
  }
  loadtoppreformenr() {
    if ($.fn.DataTable.isDataTable(this.table_top)) {
      $($('#dt').dataTable().fnDestroy());
    }
    this.ngxLoader.startLoader('customLoaderId');
    let currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    let date1 = {
      startDate: moment__WEBPACK_IMPORTED_MODULE_7__().format("MM/DD/YYYY 00:00"),
      endDate: moment__WEBPACK_IMPORTED_MODULE_7__().format("MM/DD/YYYY 23:59")
    };
    this.http.post(this.ServerUrl + 'getcallsdata/' + currentCompany.uuid, {
      'role': currentUser.role,
      'user_uuid': currentUser.uuid,
      'timezone': this.currentUser.timezone,
      'groupby': 4,
      date: date1
    }).subscribe(resp => {
      let finaldata = resp.data.sort((a, b) => {
        return b.revenue - a.revenue;
      });
      this.top_performer = finaldata;
      this.ngxLoader.stopLoader('customLoaderId');
      this.dtTrigger.next();
    }, error => this.error = error);
  }
  loadtoptarget() {
    if ($.fn.DataTable.isDataTable(this.table_top)) {
      $($('#dt').dataTable().fnDestroy());
    }
    this.ngxLoader.startLoader('customLoaderId1');
    let currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    let date1 = {
      startDate: moment__WEBPACK_IMPORTED_MODULE_7__().format("MM/DD/YYYY 00:00"),
      endDate: moment__WEBPACK_IMPORTED_MODULE_7__().format("MM/DD/YYYY 23:59")
    };
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.http.post(this.ServerUrl + 'getcallsdata/' + currentCompany.uuid, {
      'role': currentUser.role,
      'user_uuid': currentUser.uuid,
      'timezone': this.currentUser.timezone,
      'groupby': 2,
      date: date1
    }).subscribe(resp => {
      let finaldata = resp.data.sort((a, b) => {
        return b.revenue - a.revenue;
      });
      this.top_target = finaldata;
      this.ngxLoader.stopLoader('customLoaderId1');
      this.dtTrigger.next();
    }, error => this.error = error);
  }
  loadtopcampaign() {
    if ($.fn.DataTable.isDataTable(this.table_top)) {
      $($('#dt').dataTable().fnDestroy());
    }
    this.ngxLoader.startLoader('customLoaderId2');
    let currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    let date1 = {
      startDate: moment__WEBPACK_IMPORTED_MODULE_7__().format("MM/DD/YYYY 00:00"),
      endDate: moment__WEBPACK_IMPORTED_MODULE_7__().format("MM/DD/YYYY 23:59")
    };
    this.http.post(this.ServerUrl + 'getcallsdata/' + currentCompany.uuid, {
      'role': currentUser.role,
      'user_uuid': currentUser.uuid,
      'timezone': this.currentUser.timezone,
      'groupby': 1,
      date: date1
    }).subscribe(resp => {
      let finaldata = resp.data.sort((a, b) => {
        return b.revenue - a.revenue;
      });
      this.top_campaign = finaldata;
      this.ngxLoader.stopLoader('customLoaderId2');
      this.dtTrigger.next();
    }, error => this.error = error);
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_9__.HttpBackend
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_11__.Title
  }, {
    type: ngx_ui_loader__WEBPACK_IMPORTED_MODULE_12__.NgxUiLoaderService
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_13__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }],
    table_top: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_13__.ViewChild,
      args: ['dataTable_top', {
        static: true
      }]
    }],
    table_target: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_13__.ViewChild,
      args: ['datatable_target', {
        static: true
      }]
    }]
  };
};
DashboardComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_14__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_13__.Component)({
  selector: 'app-dashboard',
  template: _dashboard_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_dashboard_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], DashboardComponent);


/***/ }),

/***/ 27393:
/*!**************************************************************************!*\
  !*** ./src/app/modules/dynamic-parameter/dynamic-parameter.component.ts ***!
  \**************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "DynamicParameterComponent": () => (/* binding */ DynamicParameterComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _dynamic_parameter_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./dynamic-parameter.component.html?ngResource */ 67145);
/* harmony import */ var _dynamic_parameter_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./dynamic-parameter.component.scss?ngResource */ 68834);
/* harmony import */ var _dynamic_parameter_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_dynamic_parameter_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _modules_module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../../modules/module.service */ 22947);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ngx-toastr */ 94817);








let DynamicParameterComponent = class DynamicParameterComponent {
  constructor(fb, moduleService, router, route, toastrService) {
    this.fb = fb;
    this.moduleService = moduleService;
    this.router = router;
    this.route = route;
    this.toastrService = toastrService;
    this.submitted = false;
  }
  ngOnInit() {
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.addparaForm = this.fb.group({
      xyzcalltimespan: ['', ''],
      default_rule: ['', ''],
      abc_rule_expiration: ['', ''],
      sho_rel_period: ['', ''],
      long_rel_period: ['', ''],
      short_call_time_win: ['', ''],
      call_threshold: ['', '']
    });
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    if (this.currentCompany.uuid) {
      this.moduleService.getDynParadata(this.currentCompany.uuid).subscribe(res => {
        for (let index = 0; index < res.length + 1; index++) {
          // console.log(res[index]);
          if (res[index]['label'] == 'XYZ Call Time Span') {
            this.addparaForm.patchValue({
              xyzcalltimespan: res[index]['value']
            });
          }
          if (res[index]['label'] == 'Default Rule') {
            this.addparaForm.patchValue({
              default_rule: res[index]['value']
            });
          }
          if (res[index]['label'] == 'ABC Rule Expiration') {
            this.addparaForm.patchValue({
              abc_rule_expiration: res[index]['value']
            });
          }
          if (res[index]['label'] == 'Shortlist Release Period') {
            this.addparaForm.patchValue({
              sho_rel_period: res[index]['value']
            });
          }
          if (res[index]['label'] == 'Longlist Release Period') {
            this.addparaForm.patchValue({
              long_rel_period: res[index]['value']
            });
          }
          if (res[index]['label'] == 'Shortlist Call Time Window') {
            console.log(res[index]['value']);
            this.addparaForm.patchValue({
              short_call_time_win: res[index]['value']
            });
          }
          if (res[index]['label'] == 'Call Threshold') {
            this.addparaForm.patchValue({
              call_threshold: res[index]['value']
            });
          }
        }
      });
    }
  }
  get f() {
    return this.addparaForm.controls;
  }
  onSubmit() {
    const formData = new FormData();
    if (this.addparaForm.invalid) {
      return;
    }
    this.submitted = true;
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    formData.append('call_threshold', this.addparaForm.get('call_threshold').value);
    const company_uuid = this.currentCompany.uuid;
    if (company_uuid) {
      this.moduleService.addDyPara(this.addparaForm.value, company_uuid).subscribe(res => {
        // console.log(res); return false;
        if (res.status == 'success') {
          this.toastrService.success('Dynamic Parameter Saved Successfully');
        } else {
          this.toastrService.success('Failed To Save! Please Try Again Later..');
        }
      }, error => this.error = error);
    }
  }
  static #_ = this.ctorParameters = () => [{
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_3__.FormBuilder
  }, {
    type: _modules_module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_4__.Router
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_4__.ActivatedRoute
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_5__.ToastrService
  }];
};
DynamicParameterComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_6__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_7__.Component)({
  selector: 'app-dynamic-parameter',
  template: _dynamic_parameter_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_dynamic_parameter_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], DynamicParameterComponent);


/***/ }),

/***/ 83770:
/*!************************************************************************!*\
  !*** ./src/app/modules/ivr-menus/add-ivrmenu/add-ivrmenu.component.ts ***!
  \************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "AddIVRMenuComponent": () => (/* binding */ AddIVRMenuComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _add_ivrmenu_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./add-ivrmenu.component.html?ngResource */ 58632);
/* harmony import */ var _add_ivrmenu_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./add-ivrmenu.component.scss?ngResource */ 36178);
/* harmony import */ var _add_ivrmenu_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_add_ivrmenu_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../../module.service */ 22947);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @angular/platform-browser */ 34497);










let AddIVRMenuComponent = class AddIVRMenuComponent {
  constructor(fb, moduleService, router, route, toastrService, handler, cdRef, titleService) {
    this.fb = fb;
    this.moduleService = moduleService;
    this.router = router;
    this.route = route;
    this.toastrService = toastrService;
    this.cdRef = cdRef;
    this.titleService = titleService;
    this.msbapTitle = 'Audio Title';
    this.msbapAudioUrl = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/fsdffsdf.mp3';
    this.msbapDisplayTitle = false;
    this.msbapDisplayVolumeControls = true;
    this.allBuyers = [];
    this.settings = {};
    this.forward_0 = 'FORWARD_TO_NUMBER';
    this.forward_1 = 'FORWARD_TO_NUMBER';
    this.forward_2 = 'FORWARD_TO_NUMBER';
    this.forward_3 = 'FORWARD_TO_NUMBER';
    this.forward_4 = 'FORWARD_TO_NUMBER';
    this.forward_5 = 'FORWARD_TO_NUMBER';
    this.forward_6 = 'FORWARD_TO_NUMBER';
    this.forward_7 = 'FORWARD_TO_NUMBER';
    this.forward_8 = 'FORWARD_TO_NUMBER';
    this.forward_9 = 'FORWARD_TO_NUMBER';
    this.forward_10 = 'FORWARD_TO_NUMBER';
    this.url_0 = '';
    this.url_1 = '';
    this.url_2 = '';
    this.url_3 = '';
    this.url_4 = '';
    this.url_5 = '';
    this.url_6 = '';
    this.url_7 = '';
    this.url_8 = '';
    this.url_9 = '';
    this.url_10 = '';
    this.formdata = new FormData();
    this.submitted = false;
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_3__.HttpClient(handler);
  }
  ngAfterContentChecked() {
    this.cdRef.detectChanges();
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngOnInit() {
    this.setTitle('Create IVR Menu');
    // this.showLoadingIndicator= true;
    // setTimeout(()=>{this.showLoadingIndicator= false; },1000);
    this.addIVRMenuForm = this.fb.group({
      user_uuid: [''],
      name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_4__.Validators.required],
      noofretries: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_4__.Validators.required],
      timeout: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_4__.Validators.required],
      forward_to: [''],
      // openingmenu_forward_to: [''],        
      ivr_options: [''],
      // openingmenu_forward_tonumber: [''],        
      default_response: [''],
      buyer: [''],
      // Select Audio UUID
      audio_uuid_0: [''],
      audio_uuid_1: [''],
      audio_uuid_2: [''],
      audio_uuid_3: [''],
      audio_uuid_4: [''],
      audio_uuid_5: [''],
      audio_uuid_6: [''],
      audio_uuid_7: [''],
      audio_uuid_8: [''],
      audio_uuid_9: [''],
      audio_uuid_10: [''],
      // Upload Audio File
      upload_audio_0: [''],
      upload_audio_1: [''],
      upload_audio_2: [''],
      upload_audio_3: [''],
      upload_audio_4: [''],
      upload_audio_5: [''],
      upload_audio_6: [''],
      upload_audio_7: [''],
      upload_audio_8: [''],
      upload_audio_9: [''],
      upload_audio_10: [''],
      // Forward to Number or IVR Menu
      forward_to_0: [''],
      forward_to_1: [''],
      forward_to_2: [''],
      forward_to_3: [''],
      forward_to_4: [''],
      forward_to_5: [''],
      forward_to_6: [''],
      forward_to_7: [''],
      forward_to_8: [''],
      forward_to_9: [''],
      forward_to_10: [''],
      // Forward to Number
      forwardto_phone_0: [''],
      forwardto_phone_1: [''],
      forwardto_phone_2: [''],
      forwardto_phone_3: [''],
      forwardto_phone_4: [''],
      forwardto_phone_5: [''],
      forwardto_phone_6: [''],
      forwardto_phone_7: [''],
      forwardto_phone_8: [''],
      forwardto_phone_9: [''],
      forwardto_phone_10: [''],
      // Forward to Campaign
      forwardto_campaign_0: [''],
      forwardto_campaign_1: [''],
      forwardto_campaign_2: [''],
      forwardto_campaign_3: [''],
      forwardto_campaign_4: [''],
      forwardto_campaign_5: [''],
      forwardto_campaign_6: [''],
      forwardto_campaign_7: [''],
      forwardto_campaign_8: [''],
      forwardto_campaign_9: [''],
      forwardto_campaign_10: [''],
      forwardto_ivr_0: [''],
      forwardto_ivr_1: [''],
      forwardto_ivr_2: [''],
      forwardto_ivr_3: [''],
      forwardto_ivr_4: [''],
      forwardto_ivr_5: [''],
      forwardto_ivr_6: [''],
      forwardto_ivr_7: [''],
      forwardto_ivr_8: [''],
      forwardto_ivr_9: [''],
      forwardto_ivr_10: [''],
      forwardto_routing_0: [''],
      forwardto_routing_1: [''],
      forwardto_routing_2: [''],
      forwardto_routing_3: [''],
      forwardto_routing_4: [''],
      forwardto_routing_5: [''],
      forwardto_routing_6: [''],
      forwardto_routing_7: [''],
      forwardto_routing_8: [''],
      forwardto_routing_9: [''],
      forwardto_routing_10: [''],
      forwardto_ivrrouting_0: [''],
      forwardto_ivrrouting_1: [''],
      forwardto_ivrrouting_2: [''],
      forwardto_ivrrouting_3: [''],
      forwardto_ivrrouting_4: [''],
      forwardto_ivrrouting_5: [''],
      forwardto_ivrrouting_6: [''],
      forwardto_ivrrouting_7: [''],
      forwardto_ivrrouting_8: [''],
      forwardto_ivrrouting_9: [''],
      forwardto_ivrrouting_10: ['']
    });
    this.addIVRMenuForm.patchValue({
      forward_to_0: 'FORWARD_TO_NUMBER',
      forward_to_1: 'FORWARD_TO_NUMBER',
      forward_to_2: 'FORWARD_TO_NUMBER',
      forward_to_3: 'FORWARD_TO_NUMBER',
      forward_to_4: 'FORWARD_TO_NUMBER',
      forward_to_5: 'FORWARD_TO_NUMBER',
      forward_to_6: 'FORWARD_TO_NUMBER',
      forward_to_7: 'FORWARD_TO_NUMBER',
      forward_to_8: 'FORWARD_TO_NUMBER',
      forward_to_9: 'FORWARD_TO_NUMBER',
      forward_to_10: 'FORWARD_TO_NUMBER'
    });
    this.settings = {
      enableSearchFilter: true,
      singleSelection: true,
      showCheckbox: false,
      text: "Select Buyer"
    };
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleService.getallbuyers(this.currentCompany.uuid).subscribe(res => {
      this.allBuyers = res;
      //  console.log(this.allBuyers);
    }, error => this.error = error);
    this.moduleService.getIVRMenus(this.currentCompany.uuid).subscribe(res => {
      this.menuname = res;
    }, error => this.error = error);
    this.moduleService.getAlltarget(this.currentCompany.uuid).subscribe(res => {
      this.alltarget = res;
    }, error => this.error = error);
    this.moduleService.allivrroutingplan(this.currentCompany.uuid).subscribe(res => {
      console.log(res);
      this.allivrroutingplan = res;
    }, error => this.error = error);
    this.moduleService.getallcampaindata(this.currentCompany.uuid).subscribe(res => {
      this.campaigns = res;
    }, error => this.error = error);
    this.getaudio();
    // console.log(this.audio);
  }

  IVR_Options(event) {
    this.selectedIVR_Options = event.target.value;
  }
  forward_to(event, i) {
    if (i == 0) {
      this.forward_0 = event.target.value;
    }
    if (i == 1) {
      this.forward_1 = event.target.value;
    }
    if (i == 2) {
      this.forward_2 = event.target.value;
    }
    if (i == 3) {
      this.forward_3 = event.target.value;
    }
    if (i == 4) {
      this.forward_4 = event.target.value;
    }
    if (i == 5) {
      this.forward_5 = event.target.value;
    }
    if (i == 6) {
      this.forward_6 = event.target.value;
    }
    if (i == 7) {
      this.forward_7 = event.target.value;
    }
    if (i == 8) {
      this.forward_8 = event.target.value;
    }
    if (i == 9) {
      this.forward_9 = event.target.value;
    }
    if (i == 10) {
      this.forward_10 = event.target.value;
    }
  }
  audiochange(args, count) {
    // alert(count);
    // console.log(args);return false;
    this.audioname = args.target.options[args.target.selectedIndex].text;
    if (count == 0) {
      this.url_0 = '';
      this.url_0 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + this.audioname;
    }
    // return false;
    if (count == 1) {
      this.url_1 = '';
      this.url_1 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + this.audioname;
    }
    if (count == 2) {
      this.url_2 = '';
      this.url_2 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + this.audioname;
    }
    if (count == 3) {
      this.url_3 = '';
      this.url_3 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + this.audioname;
    }
    if (count == 4) {
      this.url_4 = '';
      this.url_4 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + this.audioname;
    }
    if (count == 5) {
      this.url_5 = '';
      this.url_5 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + this.audioname;
    }
    if (count == 6) {
      this.url_6 = '';
      this.url_6 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + this.audioname;
    }
    if (count == 7) {
      this.url_7 = '';
      this.url_7 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + this.audioname;
    }
    if (count == 8) {
      this.url_8 = '';
      this.url_8 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + this.audioname;
    }
    if (count == 9) {
      this.url_9 = '';
      this.url_9 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + this.audioname;
    }
    if (count == 10) {
      this.url_10 = '';
      this.url_10 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + this.audioname;
    }
    // alert(this.url);
  }

  openingmenu_forward(event) {
    this.openingmenuforward = event.target.value;
  }
  getaudio() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleService.getIVRAudio(this.currentCompany.uuid, 0).subscribe(res => {
      this.audio = res;
      //  console.log(this.audio);
    }, error => this.error = error);
  }
  selectedIVR() {
    let array = [];
    if (!this.selectedIVR_Options) {
      this.selectedIVR_Options = 1;
    }
    for (let i = 0; i < this.selectedIVR_Options; i++) {
      array.push(i);
    }
    return array;
  }
  // selectedFile(event){
  //   alert(event);
  //   console.log(event);
  // }
  setaudioselected(uuid, count) {
    if (count == 0) {
      this.addIVRMenuForm.patchValue({
        audio_uuid_0: uuid
      });
    }
    if (count == 1) {
      this.addIVRMenuForm.patchValue({
        audio_uuid_1: uuid
      });
    }
    if (count == 2) {
      this.addIVRMenuForm.patchValue({
        audio_uuid_2: uuid
      });
    }
    if (count == 3) {
      this.addIVRMenuForm.patchValue({
        audio_uuid_3: uuid
      });
    }
    if (count == 4) {
      this.addIVRMenuForm.patchValue({
        audio_uuid_4: uuid
      });
    }
    if (count == 5) {
      this.addIVRMenuForm.patchValue({
        audio_uuid_5: uuid
      });
    }
    if (count == 6) {
      this.addIVRMenuForm.patchValue({
        audio_uuid_6: uuid
      });
    }
    if (count == 7) {
      this.addIVRMenuForm.patchValue({
        audio_uuid_7: uuid
      });
    }
    if (count == 8) {
      this.addIVRMenuForm.patchValue({
        audio_uuid_8: uuid
      });
    }
    if (count == 9) {
      this.addIVRMenuForm.patchValue({
        audio_uuid_9: uuid
      });
    }
    if (count == 10) {
      this.addIVRMenuForm.patchValue({
        audio_uuid_10: uuid
      });
    }
  }
  // currentFileUpload: File;
  selectFile(event, count) {
    this.showLoadingIndicator = true;
    // alert(count);return false;
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    // this.currentFileUpload = event.target.files.item(0);
    // console.log(this.currentFileUpload);return false;
    this.moduleService.uploadfile(event.target.files.item(0), this.currentCompany.uuid, 0).subscribe(res => {
      // console.log(JSON.parse(sessionStorage.getItem('progress')));
      // this.progress.percentage = res;
      //        console.log(res.status);
      //  return false; 
      // if (res.status != 200) {
      // alert('ok');
      // }
      if (res.status !== 'error' && event.target.files.item(0).name != '' && res.body) {
        //   console.log(res.status);
        //  return false;         
        if (res.status === 200) {
          this.showLoadingIndicator = false;
        }
        this.toastrService.success('Audio Uploaded Succssfully');
        // return false;
        this.getaudio();
        this.setaudioselected(res.body.uuid, count);
        if (res.status == 200) if (count == 0) {
          this.url_0 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + event.target.files.item(0).name;
        }
        if (count == 1) {
          this.url_1 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + event.target.files.item(0).name;
        }
        if (count == 2) {
          this.url_2 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + event.target.files.item(0).name;
        }
        if (count == 3) {
          this.url_3 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + event.target.files.item(0).name;
        }
        if (count == 4) {
          this.url_4 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + event.target.files.item(0).name;
        }
        if (count == 5) {
          this.url_5 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + event.target.files.item(0).name;
        }
        if (count == 6) {
          this.url_6 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + event.target.files.item(0).name;
        }
        if (count == 7) {
          this.url_7 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + event.target.files.item(0).name;
        }
        if (count == 8) {
          this.url_8 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + event.target.files.item(0).name;
        }
        if (count == 9) {
          this.url_9 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + event.target.files.item(0).name;
        }
        if (count == 10) {
          this.url_10 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + event.target.files.item(0).name;
        }
      } else {
        if (res.status === 'error') {
          this.toastrService.error('Failed To Add');
        }
      }
    }, error => this.error = error);
  }
  get f() {
    return this.addIVRMenuForm.controls;
  }
  onSubmit() {
    // const formData = new FormData();      
    this.submitted = true;
    if (this.addIVRMenuForm.invalid) {
      return;
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.addIVRMenuForm.get("user_uuid").setValue(currentUser.uuid);
    // console.log(this.buyername); return
    // this.addIVRMenuForm.get("buyer").setValue(this.buyername);
    this.moduleService.addIVR(this.addIVRMenuForm.value, this.currentCompany.uuid).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('IVR Menu Added Successfully');
        this.router.navigate(['/ivr-menu']);
      } else {
        this.toastrService.error('Failed To Add');
      }
    }, error => this.error = error);
  }
  _keyPress(event) {
    const isNumericInput = event => {
      const key = event.keyCode;
      return key >= 48 && key <= 57 ||
      // Allow number line
      key >= 96 && key <= 105 // Allow number pad
      ;
    };

    const isModifierKey = event => {
      const key = event.keyCode;
      return event.shiftKey === true || key === 35 || key === 36 ||
      // Allow Shift, Home, End
      key === 8 || key === 9 || key === 13 || key === 46 ||
      // Allow Backspace, Tab, Enter, Delete
      key > 36 && key < 41 ||
      // Allow left, up, right, down

      // Allow Ctrl/Command + A,C,V,X,Z
      (event.ctrlKey === true || event.metaKey === true) && (key === 65 || key === 67 || key === 86 || key === 88 || key === 90);
    };
    const enforceFormat = event => {
      // Input must be of a valid number format or a modifier key, and not longer than ten digits
      if (!isNumericInput(event) && !isModifierKey(event)) {
        event.preventDefault();
      }
    };
    const formatToPhone = event => {
      if (isModifierKey(event)) {
        return;
      }
      const target = event.target;
      const input = event.target.value.replace(/\D/g, '').substring(0, 10); // First ten digits of input only
      const zip = input.substring(0, 3);
      const middle = input.substring(3, 6);
      const last = input.substring(6, 10);
      if (input.length > 6) {
        target.value = `(${zip}) ${middle}-${last}`;
      } else if (input.length > 3) {
        target.value = `(${zip}) ${middle}`;
      } else if (input.length > 0) {
        target.value = `(${zip}`;
      }
    };
    const forwardto_phone_0no = document.getElementById('forwardto_phone_0');
    const forwardto_phone_1no = document.getElementById('forwardto_phone_1');
    const forwardto_phone_2no = document.getElementById('forwardto_phone_2');
    const forwardto_phone_3no = document.getElementById('forwardto_phone_3');
    const forwardto_phone_4no = document.getElementById('forwardto_phone_4');
    const forwardto_phone_5no = document.getElementById('forwardto_phone_5');
    const forwardto_phone_6no = document.getElementById('forwardto_phone_6');
    const forwardto_phone_7no = document.getElementById('forwardto_phone_7');
    const forwardto_phone_8no = document.getElementById('forwardto_phone_8');
    const forwardto_phone_9no = document.getElementById('forwardto_phone_9');
    const forwardto_phone_10no = document.getElementById('forwardto_phone_10');
    if (forwardto_phone_0no) {
      forwardto_phone_0no.addEventListener('keydown', enforceFormat);
      forwardto_phone_0no.addEventListener('keyup', formatToPhone);
    }
    if (forwardto_phone_1no) {
      forwardto_phone_1no.addEventListener('keydown', enforceFormat);
      forwardto_phone_1no.addEventListener('keyup', formatToPhone);
    }
    if (forwardto_phone_2no) {
      forwardto_phone_2no.addEventListener('keydown', enforceFormat);
      forwardto_phone_2no.addEventListener('keyup', formatToPhone);
    }
    if (forwardto_phone_3no) {
      forwardto_phone_3no.addEventListener('keydown', enforceFormat);
      forwardto_phone_3no.addEventListener('keyup', formatToPhone);
    }
    if (forwardto_phone_4no) {
      forwardto_phone_4no.addEventListener('keydown', enforceFormat);
      forwardto_phone_4no.addEventListener('keyup', formatToPhone);
    }
    if (forwardto_phone_5no) {
      forwardto_phone_5no.addEventListener('keydown', enforceFormat);
      forwardto_phone_5no.addEventListener('keyup', formatToPhone);
    }
    if (forwardto_phone_6no) {
      forwardto_phone_6no.addEventListener('keydown', enforceFormat);
      forwardto_phone_6no.addEventListener('keyup', formatToPhone);
    }
    if (forwardto_phone_7no) {
      forwardto_phone_7no.addEventListener('keydown', enforceFormat);
      forwardto_phone_7no.addEventListener('keyup', formatToPhone);
    }
    if (forwardto_phone_8no) {
      forwardto_phone_8no.addEventListener('keydown', enforceFormat);
      forwardto_phone_8no.addEventListener('keyup', formatToPhone);
    }
    if (forwardto_phone_9no) {
      forwardto_phone_9no.addEventListener('keydown', enforceFormat);
      forwardto_phone_9no.addEventListener('keyup', formatToPhone);
    }
    if (forwardto_phone_10no) {
      forwardto_phone_10no.addEventListener('keydown', enforceFormat);
      forwardto_phone_10no.addEventListener('keyup', formatToPhone);
    }
  }
  static #_ = this.ctorParameters = () => [{
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_4__.FormBuilder
  }, {
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_5__.Router
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_5__.ActivatedRoute
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_6__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_3__.HttpBackend
  }, {
    type: _angular_core__WEBPACK_IMPORTED_MODULE_7__.ChangeDetectorRef
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_8__.Title
  }];
};
AddIVRMenuComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_9__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_7__.Component)({
  selector: 'app-add-ivrmenu',
  template: _add_ivrmenu_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_add_ivrmenu_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], AddIVRMenuComponent);


/***/ }),

/***/ 42926:
/*!**************************************************************************!*\
  !*** ./src/app/modules/ivr-menus/edit-ivrmenu/edit-ivrmenu.component.ts ***!
  \**************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "EditIvrmenuComponent": () => (/* binding */ EditIvrmenuComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _edit_ivrmenu_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./edit-ivrmenu.component.html?ngResource */ 23404);
/* harmony import */ var _edit_ivrmenu_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./edit-ivrmenu.component.scss?ngResource */ 60489);
/* harmony import */ var _edit_ivrmenu_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_edit_ivrmenu_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../../module.service */ 22947);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var ngx_ui_loader__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ngx-ui-loader */ 36413);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/platform-browser */ 34497);











let EditIvrmenuComponent = class EditIvrmenuComponent {
  constructor(fb, moduleService, router, route, toastrService, handler, ngxLoader, cdRef, titleService) {
    this.fb = fb;
    this.moduleService = moduleService;
    this.router = router;
    this.route = route;
    this.toastrService = toastrService;
    this.ngxLoader = ngxLoader;
    this.cdRef = cdRef;
    this.titleService = titleService;
    this.url_0 = '';
    this.url_1 = '';
    this.url_2 = '';
    this.url_3 = '';
    this.url_4 = '';
    this.url_5 = '';
    this.url_6 = '';
    this.url_7 = '';
    this.url_8 = '';
    this.url_9 = '';
    this.url_10 = '';
    this.alltarget = [];
    this.allBuyers = [];
    this.allivrroutingplan = [];
    this.settings = {};
    this.selectedItems = [];
    this.forward_0 = 'FORWARD_TO_NUMBER';
    this.forward_1 = 'FORWARD_TO_NUMBER';
    this.forward_2 = 'FORWARD_TO_NUMBER';
    this.forward_3 = 'FORWARD_TO_NUMBER';
    this.forward_4 = 'FORWARD_TO_NUMBER';
    this.forward_5 = 'FORWARD_TO_NUMBER';
    this.forward_6 = 'FORWARD_TO_NUMBER';
    this.forward_7 = 'FORWARD_TO_NUMBER';
    this.forward_8 = 'FORWARD_TO_NUMBER';
    this.forward_9 = 'FORWARD_TO_NUMBER';
    this.forward_10 = 'FORWARD_TO_NUMBER';
    this.progress = {
      percentage: 0
    };
    this.formdata = new FormData();
    this.submitted = false;
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_3__.HttpClient(handler);
    this.loader = {
      loaderId: 'customLoaderId'
    };
  }
  ngAfterContentChecked() {
    this.cdRef.detectChanges();
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngOnInit() {
    // this.showLoadingIndicator= true;
    this.ngxLoader.startLoader('customLoaderId');
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.settings = {
      enableSearchFilter: true,
      showCheckbox: false,
      singleSelection: true,
      text: "Select Buyer"
    };
    this.editIVRMenuForm = this.fb.group({
      user_uuid: [''],
      name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_4__.Validators.required],
      noofretries: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_4__.Validators.required],
      timeout: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_4__.Validators.required],
      forward_to: [''],
      openingmenu_forward_to: [''],
      ivr_options: [''],
      openingmenu_forward_tonumber: [''],
      default_response: [''],
      buyer: [''],
      // Select Audio UUID
      audio_uuid_0: [''],
      audio_uuid_1: [''],
      audio_uuid_2: [''],
      audio_uuid_3: [''],
      audio_uuid_4: [''],
      audio_uuid_5: [''],
      audio_uuid_6: [''],
      audio_uuid_7: [''],
      audio_uuid_8: [''],
      audio_uuid_9: [''],
      audio_uuid_10: [''],
      // Upload Audio File
      upload_audio_0: [''],
      upload_audio_1: [''],
      upload_audio_2: [''],
      upload_audio_3: [''],
      upload_audio_4: [''],
      upload_audio_5: [''],
      upload_audio_6: [''],
      upload_audio_7: [''],
      upload_audio_8: [''],
      upload_audio_9: [''],
      upload_audio_10: [''],
      // Forward to Number or IVR Menu
      forward_to_0: [''],
      forward_to_1: [''],
      forward_to_2: [''],
      forward_to_3: [''],
      forward_to_4: [''],
      forward_to_5: [''],
      forward_to_6: [''],
      forward_to_7: [''],
      forward_to_8: [''],
      forward_to_9: [''],
      forward_to_10: [''],
      // Forward to Number
      forwardto_phone_0: [''],
      forwardto_phone_1: [''],
      forwardto_phone_2: [''],
      forwardto_phone_3: [''],
      forwardto_phone_4: [''],
      forwardto_phone_5: [''],
      forwardto_phone_6: [''],
      forwardto_phone_7: [''],
      forwardto_phone_8: [''],
      forwardto_phone_9: [''],
      forwardto_phone_10: [''],
      // Forward to Campaign
      forwardto_campaign_0: [''],
      forwardto_campaign_1: [''],
      forwardto_campaign_2: [''],
      forwardto_campaign_3: [''],
      forwardto_campaign_4: [''],
      forwardto_campaign_5: [''],
      forwardto_campaign_6: [''],
      forwardto_campaign_7: [''],
      forwardto_campaign_8: [''],
      forwardto_campaign_9: [''],
      forwardto_campaign_10: [''],
      forwardto_ivr_0: [''],
      forwardto_ivr_1: [''],
      forwardto_ivr_2: [''],
      forwardto_ivr_3: [''],
      forwardto_ivr_4: [''],
      forwardto_ivr_5: [''],
      forwardto_ivr_6: [''],
      forwardto_ivr_7: [''],
      forwardto_ivr_8: [''],
      forwardto_ivr_9: [''],
      forwardto_ivr_10: [''],
      forwardto_routing_0: [''],
      forwardto_routing_1: [''],
      forwardto_routing_2: [''],
      forwardto_routing_3: [''],
      forwardto_routing_4: [''],
      forwardto_routing_5: [''],
      forwardto_routing_6: [''],
      forwardto_routing_7: [''],
      forwardto_routing_8: [''],
      forwardto_routing_9: [''],
      forwardto_routing_10: [''],
      forwardto_ivrrouting_0: [''],
      forwardto_ivrrouting_1: [''],
      forwardto_ivrrouting_2: [''],
      forwardto_ivrrouting_3: [''],
      forwardto_ivrrouting_4: [''],
      forwardto_ivrrouting_5: [''],
      forwardto_ivrrouting_6: [''],
      forwardto_ivrrouting_7: [''],
      forwardto_ivrrouting_8: [''],
      forwardto_ivrrouting_9: [''],
      forwardto_ivrrouting_10: ['']
    });
    // console.log(1);
    this.getalldata();
    // .then((res)=>{
    //   console.log(2);
    //   this.allBuyers = res
    // })   
    // this.getallbuyers().then((res)=>{
    //   console.log(2);
    //   this.allBuyers = res
    // })   
    // this.getIVRMenus().then((res)=>{
    //   console.log(3);
    //   this.menuname = res
    // })   
    // this.gettarget().then((res)=>{
    //   console.log(4);
    //   this.alltarget = res
    // })
    // this.getallivrroutingplan().then((res)=>{
    //   console.log(5);
    //   this.allivrroutingplan = res
    // })
    // console.log(6);
    this.getaudio();
    this.showLoadingIndicator = false;
  }
  getalldata() {
    const p1 = new Promise((res, rej) => {
      this.moduleService.getAlltarget(this.currentCompany.uuid).subscribe(result => {
        if (result.length > 0) {
          res(result);
        }
      }, error => this.error = error);
    });
    const p2 = new Promise((res, rej) => {
      this.moduleService.getallbuyers(this.currentCompany.uuid).subscribe(result => {
        res(result);
      }, error => this.error = error);
    });
    const p3 = new Promise((res, rej) => {
      this.moduleService.getIVRMenus(this.currentCompany.uuid).subscribe(result => {
        res(result);
      }, error => this.error = error);
    });
    const p4 = new Promise((res, rej) => {
      this.moduleService.allivrroutingplan(this.currentCompany.uuid).subscribe(result => {
        res(result);
      }, error => this.error = error);
    });
    const prm = [p1, p2, p3, p4];
    Promise.all(prm).then(results => {
      this.allBuyers = results[1];
      this.menuname = results[2];
      this.alltarget = results[0];
      this.allivrroutingplan = results[3];
      // console.log(this.allBuyers)
      const uuid = this.route.snapshot.paramMap.get('id');
      if (uuid) {
        this.moduleService.getivrdata(uuid).subscribe(res => {
          // console.log(res); 
          // console.log(this.alltarget);
          this.setTitle(res.ivr_data.name + ' | IVR');
          this.editIVRMenuForm.patchValue({
            name: res.ivr_data.name,
            noofretries: res.ivr_data.number_of_retries,
            timeout: res.ivr_data.timeout,
            forward_to: res.ivr_data.forward_to,
            ivr_options: res.ivr_data.number_of_options,
            default_response: res.ivr_data.default_response_value
            // buyer: res.ivr_data.buyer,            
          });
          // console.log(res.ivr_data.buyer);
          if (res.ivr_data.buyer != "" || res.ivr_data.buyer != undefined) {
            let text = this.allBuyers.filter(x => x.id == res.ivr_data.buyer)[0];
            if (text != undefined) {
              this.selectedItems = [{
                "id": res.ivr_data.buyer,
                "itemName": text.text
              }];
            }
          }
          this.selecteddefault = res.ivr_data.number_of_options;
          for (let i = 0; i <= res.ivr_data.number_of_options + 1; i++) {
            if (res.ivr_optiondata[i].forward_to_uuid && res.ivr_optiondata[i].forward_to_uuid == 'CONTINUE') {
              if (i == 0) {
                this.getfortoval = 'CONTINUE';
                this.forward_0 = '';
              }
              if (i == 1) {
                this.getfortoval = 'CONTINUE';
                this.forward_1 = '';
              }
              if (i == 2) {
                this.getfortoval = 'CONTINUE';
                this.forward_2 = '';
              }
              if (i == 3) {
                this.getfortoval = 'CONTINUE';
                this.forward_3 = '';
              }
              if (i == 4) {
                this.getfortoval = 'CONTINUE';
                this.forward_4 = '';
              }
              if (i == 5) {
                this.getfortoval = 'CONTINUE';
                this.forward_5 = '';
              }
              if (i == 6) {
                this.getfortoval = 'CONTINUE';
                this.forward_6 = '';
              }
              if (i == 7) {
                this.getfortoval = 'CONTINUE';
                this.forward_7 = '';
              }
              if (i == 8) {
                this.getfortoval = 'CONTINUE';
                this.forward_8 = '';
              }
              if (i == 9) {
                this.getfortoval = 'CONTINUE';
                this.forward_9 = '';
              }
              if (i == 10) {
                this.getfortoval = 'CONTINUE';
                this.forward_10 = '';
              }
            }
            if (res.ivr_optiondata[i].forward_to_uuid == 'FORWARD_TO_NUMBER') {
              this.getfortoval = 'FORWARD_TO_NUMBER';
              this.getfortonumberval = res.ivr_optiondata[i].forward_to;
            }
            if (res.ivr_optiondata[i].forward_to_uuid == 'FORWARD_TO_IVR') {
              this.getfortoval = res.ivr_optiondata[i].forward_to_uuid;
              if (i == 0) {
                this.forward_0 = 'FORWARD_TO_IVR';
                this.editIVRMenuForm.patchValue({
                  forwardto_ivr_0: res.ivr_optiondata[0].forward_to
                });
              }
              if (i == 1) {
                this.forward_1 = 'FORWARD_TO_IVR';
                this.editIVRMenuForm.patchValue({
                  forwardto_ivr_1: res.ivr_optiondata[1].forward_to
                });
              }
              if (i == 2) {
                this.forward_2 = 'FORWARD_TO_IVR';
                if (res.ivr_optiondata[2].forward_to != "") {
                  let text = this.menuname.filter(x => x.id == res.ivr_optiondata[2].forward_to)[0];
                  if (text != undefined) {
                    this.forwardto_ivr_2 = [{
                      "uuid": text.uuid,
                      "id": res.ivr_optiondata[2].forward_to,
                      "itemName": text.name
                    }];
                  }
                }
              }
              if (i == 3) {
                this.forward_3 = 'FORWARD_TO_IVR';
                if (res.ivr_optiondata[3].forward_to != "") {
                  let text = this.menuname.filter(x => x.id == res.ivr_optiondata[3].forward_to)[0];
                  if (text != undefined) {
                    this.forwardto_ivr_3 = [{
                      "uuid": text.uuid,
                      "id": res.ivr_optiondata[3].forward_to,
                      "itemName": text.name
                    }];
                  }
                }
                // this.editIVRMenuForm.patchValue({
                //   forwardto_ivr_3:res.ivr_optiondata[3].forward_to
                // });
              }

              if (i == 4) {
                this.forward_4 = 'FORWARD_TO_IVR';
                // this.editIVRMenuForm.patchValue({
                //   forwardto_ivr_4:res.ivr_optiondata[4].forward_to
                // });
                if (res.ivr_optiondata[4].forward_to != "") {
                  let text = this.menuname.filter(x => x.id == res.ivr_optiondata[4].forward_to)[0];
                  if (text != undefined) {
                    this.forwardto_ivr_4 = [{
                      "uuid": text.uuid,
                      "id": res.ivr_optiondata[4].forward_to,
                      "itemName": text.name
                    }];
                  }
                }
              }
              if (i == 5) {
                this.forward_5 = 'FORWARD_TO_IVR';
                // this.editIVRMenuForm.patchValue({
                //   forwardto_ivr_5:res.ivr_optiondata[5].forward_to
                // });
                if (res.ivr_optiondata[5].forward_to != "") {
                  let text = this.menuname.filter(x => x.id == res.ivr_optiondata[5].forward_to)[0];
                  if (text != undefined) {
                    this.forwardto_ivr_5 = [{
                      "uuid": text.uuid,
                      "id": res.ivr_optiondata[5].forward_to,
                      "itemName": text.name
                    }];
                  }
                }
              }
              if (i == 6) {
                this.forward_6 = 'FORWARD_TO_IVR';
                if (res.ivr_optiondata[6].forward_to != "") {
                  let text = this.menuname.filter(x => x.id == res.ivr_optiondata[6].forward_to)[0];
                  if (text != undefined) {
                    this.forwardto_ivr_6 = [{
                      "uuid": text.uuid,
                      "id": res.ivr_optiondata[6].forward_to,
                      "itemName": text.name
                    }];
                  }
                }
              }
              if (i == 7) {
                this.forward_7 = 'FORWARD_TO_IVR';
                if (res.ivr_optiondata[7].forward_to != "") {
                  let text = this.menuname.filter(x => x.id == res.ivr_optiondata[7].forward_to)[0];
                  if (text != undefined) {
                    this.forwardto_ivr_7 = [{
                      "uuid": text.uuid,
                      "id": res.ivr_optiondata[7].forward_to,
                      "itemName": text.name
                    }];
                  }
                }
              }
              if (i == 8) {
                this.forward_8 = 'FORWARD_TO_IVR';
                if (res.ivr_optiondata[8].forward_to != "") {
                  let text = this.menuname.filter(x => x.id == res.ivr_optiondata[8].forward_to)[0];
                  if (text != undefined) {
                    this.forwardto_ivr_8 = [{
                      "uuid": text.uuid,
                      "id": res.ivr_optiondata[8].forward_to,
                      "itemName": text.name
                    }];
                  }
                }
              }
              if (i == 9) {
                this.forward_9 = 'FORWARD_TO_IVR';
                if (res.ivr_optiondata[9].forward_to != "") {
                  let text = this.menuname.filter(x => x.id == res.ivr_optiondata[9].forward_to)[0];
                  if (text != undefined) {
                    this.forwardto_ivr_9 = [{
                      "uuid": text.uuid,
                      "id": res.ivr_optiondata[9].forward_to,
                      "itemName": text.name
                    }];
                  }
                }
              }
              if (i == 10) {
                this.forward_10 = 'FORWARD_TO_IVR';
                if (res.ivr_optiondata[10].forward_to != "") {
                  let text = this.menuname.filter(x => x.id == res.ivr_optiondata[10].forward_to)[0];
                  if (text != undefined) {
                    this.forwardto_ivr_10 = [{
                      "uuid": text.uuid,
                      "id": res.ivr_optiondata[10].forward_to,
                      "itemName": text.name
                    }];
                  }
                }
              }
            }
            if (res.ivr_optiondata[i].forward_to_uuid == 'FORWARD_TO_ROUTING') {
              this.getfortoval = res.ivr_optiondata[i].forward_to_uuid;
              if (i == 0) {
                this.forward_0 = 'FORWARD_TO_ROUTING';
                this.editIVRMenuForm.patchValue({
                  forwardto_routing_0: res.ivr_optiondata[0].forward_to
                });
              }
              if (i == 1) {
                this.forward_1 = 'FORWARD_TO_ROUTING';
                this.editIVRMenuForm.patchValue({
                  forwardto_routing_1: res.ivr_optiondata[1].forward_to
                });
              }
              if (i == 2) {
                this.forward_2 = 'FORWARD_TO_ROUTING';
                // console.log(res.ivr_optiondata[2].forward_to);return
                if (res.ivr_optiondata[2].forward_to != "") {
                  let text = this.alltarget.filter(x => x.id == res.ivr_optiondata[2].forward_to)[0];
                  if (text != undefined) {
                    this.forwardto_routing_2 = [{
                      "uuid": text.uuid,
                      "id": res.ivr_optiondata[2].forward_to,
                      "itemName": text.itemName
                    }];
                  }
                }
                // this.editIVRMenuForm.patchValue({
                //   forwardto_routing_2:res.ivr_optiondata[2].forward_to
                // });
              }

              if (i == 3) {
                this.forward_3 = 'FORWARD_TO_ROUTING';
                // this.editIVRMenuForm.patchValue({
                //   forwardto_routing_3:res.ivr_optiondata[3].forward_to
                // });
                if (res.ivr_optiondata[3].forward_to != "") {
                  if (this.alltarget.length > 0) {
                    let text = this.alltarget.filter(x => x.id == res.ivr_optiondata[3].forward_to)[0];
                    if (text != undefined) {
                      this.forwardto_routing_3 = [{
                        "uuid": text.uuid,
                        "id": res.ivr_optiondata[3].forward_to,
                        "itemName": text.itemName
                      }];
                    }
                  }
                }
              }
              if (i == 4) {
                this.forward_4 = 'FORWARD_TO_ROUTING';
                if (res.ivr_optiondata[4].forward_to != "") {
                  let text = this.alltarget.filter(x => x.id == res.ivr_optiondata[4].forward_to)[0];
                  if (text != undefined) {
                    this.forwardto_routing_4 = [{
                      "uuid": text.uuid,
                      "id": res.ivr_optiondata[4].forward_to,
                      "itemName": text.itemName
                    }];
                  }
                }
                // console.log(this.forwardto_routing_4);return
              }

              if (i == 5) {
                this.forward_5 = 'FORWARD_TO_ROUTING';
                if (res.ivr_optiondata[5].forward_to != "") {
                  let text = this.alltarget.filter(x => x.id == res.ivr_optiondata[5].forward_to)[0];
                  if (text != undefined) {
                    this.forwardto_routing_5 = [{
                      "uuid": text.uuid,
                      "id": res.ivr_optiondata[5].forward_to,
                      "itemName": text.itemName
                    }];
                  }
                }
              }
              if (i == 6) {
                this.forward_6 = 'FORWARD_TO_ROUTING';
                if (res.ivr_optiondata[6].forward_to != "") {
                  let text = this.alltarget.filter(x => x.id == res.ivr_optiondata[6].forward_to)[0];
                  if (text != undefined) {
                    this.forwardto_routing_6 = [{
                      "uuid": text.uuid,
                      "id": res.ivr_optiondata[6].forward_to,
                      "itemName": text.itemName
                    }];
                  }
                }
              }
              if (i == 7) {
                this.forward_7 = 'FORWARD_TO_ROUTING';
                if (res.ivr_optiondata[7].forward_to != "") {
                  let text = this.alltarget.filter(x => x.id == res.ivr_optiondata[7].forward_to)[0];
                  if (text != undefined) {
                    this.forwardto_routing_7 = [{
                      "uuid": text.uuid,
                      "id": res.ivr_optiondata[7].forward_to,
                      "itemName": text.itemName
                    }];
                  }
                }
              }
              if (i == 8) {
                this.forward_8 = 'FORWARD_TO_ROUTING';
                if (res.ivr_optiondata[8].forward_to != "") {
                  let text = this.alltarget.filter(x => x.id == res.ivr_optiondata[8].forward_to)[0];
                  if (text != undefined) {
                    this.forwardto_routing_8 = [{
                      "uuid": text.uuid,
                      "id": res.ivr_optiondata[8].forward_to,
                      "itemName": text.itemName
                    }];
                  }
                }
              }
              if (i == 9) {
                this.forward_9 = 'FORWARD_TO_ROUTING';
                if (res.ivr_optiondata[9].forward_to != "") {
                  let text = this.alltarget.filter(x => x.id == res.ivr_optiondata[9].forward_to)[0];
                  if (text != undefined) {
                    this.forwardto_routing_9 = [{
                      "uuid": text.uuid,
                      "id": res.ivr_optiondata[9].forward_to,
                      "itemName": text.itemName
                    }];
                  }
                }
              }
              if (i == 10) {
                this.forward_10 = 'FORWARD_TO_ROUTING';
                if (res.ivr_optiondata[10].forward_to != "") {
                  let text = this.alltarget.filter(x => x.id == res.ivr_optiondata[10].forward_to)[0];
                  if (text != undefined) {
                    this.forwardto_routing_10 = [{
                      "uuid": text.uuid,
                      "id": res.ivr_optiondata[10].forward_to,
                      "itemName": text.itemName
                    }];
                  }
                }
              }
              // console.log(this.forward_3);
            }

            if (res.ivr_optiondata[i].forward_to_uuid == 'FORWARD_TO_IVRROUTING') {
              this.getfortoval = res.ivr_optiondata[i].forward_to_uuid;
              // console.log(i);
              if (i == 0) {
                this.forward_0 = 'FORWARD_TO_IVRROUTING';
                this.editIVRMenuForm.patchValue({
                  forwardto_ivrrouting_0: res.ivr_optiondata[0].forward_to
                });
              }
              if (i == 1) {
                this.forward_1 = 'FORWARD_TO_IVRROUTING';
                this.editIVRMenuForm.patchValue({
                  forwardto_ivrrouting_1: res.ivr_optiondata[1].forward_to
                });
              }
              if (i == 2) {
                this.forward_2 = 'FORWARD_TO_IVRROUTING';
                if (res.ivr_optiondata[2].forward_to != "") {
                  let text = this.allivrroutingplan.filter(x => x.id == res.ivr_optiondata[2].forward_to)[0];
                  if (text != undefined) {
                    this.forwardto_ivrrouting_2 = [{
                      "uuid": text.uuid,
                      "id": res.ivr_optiondata[2].forward_to,
                      "itemName": text.itemName
                    }];
                  }
                }
                // console.log(this.forward_2);
                // this.editIVRMenuForm.patchValue({
                //   forwardto_ivrrouting_2:res.ivr_optiondata[2].forward_to
                // });
              }

              if (i == 3) {
                this.forward_3 = 'FORWARD_TO_IVRROUTING';
                // this.editIVRMenuForm.patchValue({
                //   forwardto_ivrrouting_3:res.ivr_optiondata[3].forward_to
                // });
                if (res.ivr_optiondata[3].forward_to != "") {
                  let text = this.allivrroutingplan.filter(x => x.id == res.ivr_optiondata[3].forward_to)[0];
                  if (text != undefined) {
                    this.forwardto_ivrrouting_3 = [{
                      "uuid": text.uuid,
                      "id": res.ivr_optiondata[3].forward_to,
                      "itemName": text.itemName
                    }];
                  }
                }
              }
              if (i == 4) {
                this.forward_4 = 'FORWARD_TO_IVRROUTING';
                // this.editIVRMenuForm.patchValue({
                //   forwardto_ivrrouting_4:res.ivr_optiondata[4].forward_to
                // });
                if (res.ivr_optiondata[4].forward_to != "") {
                  let text = this.allivrroutingplan.filter(x => x.id == res.ivr_optiondata[4].forward_to)[0];
                  if (text != undefined) {
                    this.forwardto_ivrrouting_4 = [{
                      "uuid": text.uuid,
                      "id": res.ivr_optiondata[4].forward_to,
                      "itemName": text.itemName
                    }];
                  }
                }
              }
              if (i == 5) {
                this.forward_5 = 'FORWARD_TO_IVRROUTING';
                // this.editIVRMenuForm.patchValue({
                //   forwardto_ivrrouting_5:res.ivr_optiondata[5].forward_to
                // });
                if (res.ivr_optiondata[5].forward_to != "") {
                  let text = this.allivrroutingplan.filter(x => x.id == res.ivr_optiondata[5].forward_to)[0];
                  if (text != undefined) {
                    this.forwardto_ivrrouting_5 = [{
                      "uuid": text.uuid,
                      "id": res.ivr_optiondata[5].forward_to,
                      "itemName": text.itemName
                    }];
                  }
                }
              }
              if (i == 6) {
                this.forward_6 = 'FORWARD_TO_IVRROUTING';
                // this.editIVRMenuForm.patchValue({
                //   forwardto_ivrrouting_6:res.ivr_optiondata[6].forward_to
                // });
                if (res.ivr_optiondata[6].forward_to != "") {
                  let text = this.allivrroutingplan.filter(x => x.id == res.ivr_optiondata[6].forward_to)[0];
                  if (text != undefined) {
                    this.forwardto_ivrrouting_6 = [{
                      "uuid": text.uuid,
                      "id": res.ivr_optiondata[6].forward_to,
                      "itemName": text.itemName
                    }];
                  }
                }
              }
              if (i == 7) {
                this.forward_7 = 'FORWARD_TO_IVRROUTING';
                // this.editIVRMenuForm.patchValue({
                //   forwardto_ivrrouting_7:res.ivr_optiondata[7].forward_to
                // });
                if (res.ivr_optiondata[7].forward_to != "") {
                  let text = this.allivrroutingplan.filter(x => x.id == res.ivr_optiondata[7].forward_to)[0];
                  if (text != undefined) {
                    this.forwardto_ivrrouting_7 = [{
                      "uuid": text.uuid,
                      "id": res.ivr_optiondata[7].forward_to,
                      "itemName": text.itemName
                    }];
                  }
                }
              }
              if (i == 8) {
                this.forward_8 = 'FORWARD_TO_IVRROUTING';
                // this.editIVRMenuForm.patchValue({
                //   forwardto_ivrrouting_8:res.ivr_optiondata[8].forward_to
                // });
                if (res.ivr_optiondata[8].forward_to != "") {
                  let text = this.allivrroutingplan.filter(x => x.id == res.ivr_optiondata[8].forward_to)[0];
                  if (text != undefined) {
                    this.forwardto_ivrrouting_8 = [{
                      "uuid": text.uuid,
                      "id": res.ivr_optiondata[8].forward_to,
                      "itemName": text.itemName
                    }];
                  }
                }
              }
              if (i == 9) {
                this.forward_9 = 'FORWARD_TO_IVRROUTING';
                // this.editIVRMenuForm.patchValue({
                //   forwardto_ivrrouting_9:res.ivr_optiondata[9].forward_to
                // });
                if (res.ivr_optiondata[9].forward_to != "") {
                  let text = this.allivrroutingplan.filter(x => x.id == res.ivr_optiondata[9].forward_to)[0];
                  if (text != undefined) {
                    this.forwardto_ivrrouting_9 = [{
                      "uuid": text.uuid,
                      "id": res.ivr_optiondata[9].forward_to,
                      "itemName": text.itemName
                    }];
                  }
                }
              }
              if (i == 10) {
                this.forward_10 = 'FORWARD_TO_IVRROUTING';
                // this.editIVRMenuForm.patchValue({
                //   forwardto_ivrrouting_10:res.ivr_optiondata[10].forward_to
                // });
                if (res.ivr_optiondata[10].forward_to != "") {
                  let text = this.allivrroutingplan.filter(x => x.id == res.ivr_optiondata[10].forward_to)[0];
                  if (text != undefined) {
                    this.forwardto_ivrrouting_10 = [{
                      "uuid": text.uuid,
                      "id": res.ivr_optiondata[10].forward_to,
                      "itemName": text.itemName
                    }];
                  }
                }
              }
              // console.log(this.forward_3);
            }

            if (res.ivr_optiondata[i].forward_to_uuid != 'FORWARD_TO_CAMPAIGN' && res.ivr_optiondata[i].forward_to_uuid != 'FORWARD_TO_NUMBER' && res.ivr_optiondata[i].forward_to_uuid != 'FORWARD_TO_IVR' && res.ivr_optiondata[i].forward_to_uuid != 'FORWARD_TO_ROUTING' && res.ivr_optiondata[i].forward_to_uuid != 'FORWARD_TO_IVRROUTING' && res.ivr_optiondata[i].forward_to_uuid != 'CONTINUE') {
              this.getfortoval = res.ivr_optiondata[i].forward_to_uuid;
              if (i == 0) {
                this.forward_0 = '';
              }
              if (i == 1) {
                this.forward_1 = '';
              }
              if (i == 2) {
                this.forward_2 = '';
              }
              if (i == 3) {
                this.forward_3 = '';
              }
              if (i == 4) {
                this.forward_4 = '';
              }
              if (i == 5) {
                this.forward_5 = '';
              }
              if (i == 6) {
                this.forward_6 = '';
              }
              if (i == 7) {
                this.forward_7 = '';
              }
              if (i == 8) {
                this.forward_8 = '';
              }
              if (i == 9) {
                this.forward_9 = '';
              }
              if (i == 10) {
                this.forward_10 = '';
              }
            }
            this.audid = "audio_uuid_" + i;
            this.getforto = "forward_to_" + i;
            this.getfortonumber = "forwardto_phone_" + i;
            this.audiosrc = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/';
            if (i == 0) {
              this.url_0 = this.audiosrc + '' + res.ivr_optiondata[i].original_filename;
            }
            if (i == 1) {
              this.url_1 = this.audiosrc + '' + res.ivr_optiondata[i].original_filename;
            }
            if (i == 2) {
              this.url_2 = this.audiosrc + '' + res.ivr_optiondata[i].original_filename;
            }
            if (i == 3) {
              this.url_3 = this.audiosrc + '' + res.ivr_optiondata[i].original_filename;
            }
            if (i == 4) {
              this.url_4 = this.audiosrc + '' + res.ivr_optiondata[i].original_filename;
            }
            if (i == 5) {
              this.url_5 = this.audiosrc + '' + res.ivr_optiondata[i].original_filename;
            }
            if (i == 6) {
              this.url_6 = this.audiosrc + '' + res.ivr_optiondata[i].original_filename;
            }
            if (i == 7) {
              this.url_7 = this.audiosrc + '' + res.ivr_optiondata[i].original_filename;
            }
            if (i == 8) {
              this.url_8 = this.audiosrc + '' + res.ivr_optiondata[i].original_filename;
            }
            if (i == 9) {
              this.url_9 = this.audiosrc + '' + res.ivr_optiondata[i].original_filename;
            }
            if (i == 10) {
              this.url_10 = this.audiosrc + '' + res.ivr_optiondata[i].original_filename;
            }
            this.editIVRMenuForm.patchValue({
              [this.audid]: res.ivr_optiondata[i].audio_uuid,
              [this.getforto]: this.getfortoval,
              [this.getfortonumber]: this.getfortonumberval
            });
          }
        });
        this.ngxLoader.stopLoader('customLoaderId');
      }
    });
  }
  // gettarget(){
  //  return new Promise((res,rej)=>{
  //     this.moduleService.getAlltarget(this.currentCompany.uuid).subscribe(
  //       result => {
  //         if(result.length>0){
  //           res(result)
  //         }
  //       },
  //       error => this.error = error
  //     ); 
  //   }) 
  // }
  // getallbuyers(){
  //  return new Promise((res,rej)=>{
  //   this.moduleService.getallbuyers(this.currentCompany.uuid).subscribe(
  //     result => {
  //       res(result)
  //     },
  //     error => this.error = error
  //   ); 
  //   }) 
  // }
  // getIVRMenus(){
  //  return new Promise((res,rej)=>{
  //   this.moduleService.getIVRMenus(this.currentCompany.uuid).subscribe(
  //     result => {
  //       res(result)
  //     },
  //     error => this.error = error
  // ); 
  //   }) 
  // }
  // getallivrroutingplan(){
  //  return new Promise((res,rej)=>{
  //   this.moduleService.allivrroutingplan(this.currentCompany.uuid).subscribe(
  //     result => {
  //         res(result)
  //       },
  //       error => this.error = error
  //   ); 
  //   }) 
  // }
  getaudio() {
    this.moduleService.getIVRAudio(this.currentCompany.uuid, 0).subscribe(res => {
      // console.log(res);
      this.audio = res;
    }, error => this.error = error);
  }
  IVR_Options(event) {
    this.selecteddefault = event.target.value;
  }
  forward_to(event, i) {
    if (i == 0) {
      this.forward_0 = event.target.value;
    }
    if (i == 1) {
      this.forward_1 = event.target.value;
    }
    if (i == 2) {
      this.forward_2 = event.target.value;
    }
    if (i == 3) {
      this.forward_3 = event.target.value;
    }
    if (i == 4) {
      this.forward_4 = event.target.value;
    }
    if (i == 5) {
      this.forward_5 = event.target.value;
    }
    if (i == 6) {
      this.forward_6 = event.target.value;
    }
    if (i == 7) {
      this.forward_7 = event.target.value;
    }
    if (i == 8) {
      this.forward_8 = event.target.value;
    }
    if (i == 9) {
      this.forward_9 = event.target.value;
    }
    if (i == 10) {
      this.forward_10 = event.target.value;
    }
  }
  audiochange(args, count) {
    // alert(count);    
    this.audioname = args.target.options[args.target.selectedIndex].text;
    if (count == 0) {
      this.url_0 = '';
      this.url_0 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + this.audioname;
    }
    if (count == 1) {
      this.url_1 = '';
      this.url_1 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + this.audioname;
    }
    if (count == 2) {
      this.url_2 = '';
      this.url_2 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + this.audioname;
    }
    if (count == 3) {
      this.url_3 = '';
      this.url_3 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + this.audioname;
    }
    if (count == 4) {
      this.url_4 = '';
      this.url_4 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + this.audioname;
    }
    if (count == 5) {
      this.url_5 = '';
      this.url_5 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + this.audioname;
    }
    if (count == 6) {
      this.url_6 = '';
      this.url_6 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + this.audioname;
    }
    if (count == 7) {
      this.url_7 = '';
      this.url_7 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + this.audioname;
    }
    if (count == 8) {
      this.url_8 = '';
      this.url_8 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + this.audioname;
    }
    if (count == 9) {
      this.url_9 = '';
      this.url_9 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + this.audioname;
    }
    if (count == 10) {
      this.url_10 = '';
      this.url_10 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + this.audioname;
    }
  }
  openingmenu_forward(event) {
    this.openingmenuforward = event.target.value;
  }
  selectedIVR() {
    let array = [];
    // if(!this.selectedIVR_Options){
    //   this.itr = this.selectedIVR_Options;    
    // }else{
    this.itr = this.selecteddefault;
    // }  
    for (let i = 0; i < this.itr; i++) {
      array.push(i);
    }
    // console.log(array);  
    return array;
  }
  // selectedFile(event){
  //   alert(event);
  //   console.log(event);
  // }
  setaudioselected(uuid, count) {
    if (count == 0) {
      this.editIVRMenuForm.patchValue({
        audio_uuid_0: uuid
      });
    }
    if (count == 1) {
      this.editIVRMenuForm.patchValue({
        audio_uuid_1: uuid
      });
    }
    if (count == 2) {
      this.editIVRMenuForm.patchValue({
        audio_uuid_2: uuid
      });
    }
    if (count == 3) {
      this.editIVRMenuForm.patchValue({
        audio_uuid_3: uuid
      });
    }
    if (count == 4) {
      this.editIVRMenuForm.patchValue({
        audio_uuid_4: uuid
      });
    }
    if (count == 5) {
      this.editIVRMenuForm.patchValue({
        audio_uuid_5: uuid
      });
    }
    if (count == 6) {
      this.editIVRMenuForm.patchValue({
        audio_uuid_6: uuid
      });
    }
    if (count == 7) {
      this.editIVRMenuForm.patchValue({
        audio_uuid_7: uuid
      });
    }
    if (count == 8) {
      this.editIVRMenuForm.patchValue({
        audio_uuid_8: uuid
      });
    }
    if (count == 9) {
      this.editIVRMenuForm.patchValue({
        audio_uuid_9: uuid
      });
    }
    if (count == 10) {
      this.editIVRMenuForm.patchValue({
        audio_uuid_10: uuid
      });
    }
  }
  selectFile(event, count) {
    // alert(count);return false;
    this.progress.percentage = 0;
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.currentFileUpload = event.target.files.item(0);
    // console.log(this.currentFileUpload);return false;
    this.showLoadingIndicator = true;
    this.moduleService.uploadfile(event.target.files.item(0), this.currentCompany.uuid, 0).subscribe(res => {
      // if(res.body){
      //   console.log(res.body.uuid);
      // }
      // console.log(res);
      //  return false;
      if (res.status !== 'error' && event.target.files.item(0).name != '' && res.body) {
        // console.log(count);
        if (res.status === 'progress') {
          this.showLoadingIndicator = true;
        }
        if (res.status == 200) {
          this.showLoadingIndicator = false;
        }
        this.toastrService.success('Audio Uploaded Succssfully');
        if (count == 0) {
          this.url_0 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + event.target.files.item(0).name;
        }
        if (count == 1) {
          this.url_1 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + event.target.files.item(0).name;
        }
        if (count == 2) {
          this.url_2 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + event.target.files.item(0).name;
        }
        if (count == 3) {
          this.url_3 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + event.target.files.item(0).name;
        }
        if (count == 4) {
          this.url_4 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + event.target.files.item(0).name;
        }
        if (count == 5) {
          this.url_5 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + event.target.files.item(0).name;
        }
        if (count == 6) {
          this.url_6 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + event.target.files.item(0).name;
        }
        if (count == 7) {
          this.url_7 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + event.target.files.item(0).name;
        }
        if (count == 8) {
          this.url_8 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + event.target.files.item(0).name;
        }
        if (count == 9) {
          this.url_9 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + event.target.files.item(0).name;
        }
        if (count == 10) {
          this.url_10 = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + event.target.files.item(0).name;
        }
        this.setaudioselected(res.body.uuid, count);
        this.getaudio();
      } else {
        if (res.status === 'error') {
          this.toastrService.error('Failed To Add');
        }
      }
    }, error => this.error = error);
  }
  get f() {
    return this.editIVRMenuForm.controls;
  }
  onSubmit() {
    // const formData = new FormData();      
    this.submitted = true;
    if (this.editIVRMenuForm.invalid) {
      return;
    }
    // this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    const uuid = this.route.snapshot.paramMap.get('id');
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.editIVRMenuForm.get("user_uuid").setValue(currentUser.uuid);
    // this.editIVRMenuForm.get("buyer").setValue(this.buyername);
    this.moduleService.updateIVR(this.editIVRMenuForm.value, uuid).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('IVR Menu Updated Successfully');
        this.router.navigate(['/ivr-menu']);
      } else {
        this.toastrService.error('Failed To Add');
      }
    }, error => this.error = error);
  }
  _keyPress(event) {
    const isNumericInput = event => {
      const key = event.keyCode;
      return key >= 48 && key <= 57 ||
      // Allow number line
      key >= 96 && key <= 105 // Allow number pad
      ;
    };

    const isModifierKey = event => {
      const key = event.keyCode;
      return event.shiftKey === true || key === 35 || key === 36 ||
      // Allow Shift, Home, End
      key === 8 || key === 9 || key === 13 || key === 46 ||
      // Allow Backspace, Tab, Enter, Delete
      key > 36 && key < 41 ||
      // Allow left, up, right, down

      // Allow Ctrl/Command + A,C,V,X,Z
      (event.ctrlKey === true || event.metaKey === true) && (key === 65 || key === 67 || key === 86 || key === 88 || key === 90);
    };
    const enforceFormat = event => {
      // Input must be of a valid number format or a modifier key, and not longer than ten digits
      if (!isNumericInput(event) && !isModifierKey(event)) {
        event.preventDefault();
      }
    };
    const formatToPhone = event => {
      if (isModifierKey(event)) {
        return;
      }
      const target = event.target;
      const input = event.target.value.replace(/\D/g, '').substring(0, 10); // First ten digits of input only
      const zip = input.substring(0, 3);
      const middle = input.substring(3, 6);
      const last = input.substring(6, 10);
      if (input.length > 6) {
        target.value = `(${zip}) ${middle}-${last}`;
      } else if (input.length > 3) {
        target.value = `(${zip}) ${middle}`;
      } else if (input.length > 0) {
        target.value = `(${zip}`;
      }
    };
    const forwardto_phone_0no = document.getElementById('forwardto_phone_0');
    const forwardto_phone_1no = document.getElementById('forwardto_phone_1');
    const forwardto_phone_2no = document.getElementById('forwardto_phone_2');
    const forwardto_phone_3no = document.getElementById('forwardto_phone_3');
    const forwardto_phone_4no = document.getElementById('forwardto_phone_4');
    const forwardto_phone_5no = document.getElementById('forwardto_phone_5');
    const forwardto_phone_6no = document.getElementById('forwardto_phone_6');
    const forwardto_phone_7no = document.getElementById('forwardto_phone_7');
    const forwardto_phone_8no = document.getElementById('forwardto_phone_8');
    const forwardto_phone_9no = document.getElementById('forwardto_phone_9');
    const forwardto_phone_10no = document.getElementById('forwardto_phone_10');
    if (forwardto_phone_0no) {
      forwardto_phone_0no.addEventListener('keydown', enforceFormat);
      forwardto_phone_0no.addEventListener('keyup', formatToPhone);
    }
    if (forwardto_phone_1no) {
      forwardto_phone_1no.addEventListener('keydown', enforceFormat);
      forwardto_phone_1no.addEventListener('keyup', formatToPhone);
    }
    if (forwardto_phone_2no) {
      forwardto_phone_2no.addEventListener('keydown', enforceFormat);
      forwardto_phone_2no.addEventListener('keyup', formatToPhone);
    }
    if (forwardto_phone_3no) {
      forwardto_phone_3no.addEventListener('keydown', enforceFormat);
      forwardto_phone_3no.addEventListener('keyup', formatToPhone);
    }
    if (forwardto_phone_4no) {
      forwardto_phone_4no.addEventListener('keydown', enforceFormat);
      forwardto_phone_4no.addEventListener('keyup', formatToPhone);
    }
    if (forwardto_phone_5no) {
      forwardto_phone_5no.addEventListener('keydown', enforceFormat);
      forwardto_phone_5no.addEventListener('keyup', formatToPhone);
    }
    if (forwardto_phone_6no) {
      forwardto_phone_6no.addEventListener('keydown', enforceFormat);
      forwardto_phone_6no.addEventListener('keyup', formatToPhone);
    }
    if (forwardto_phone_7no) {
      forwardto_phone_7no.addEventListener('keydown', enforceFormat);
      forwardto_phone_7no.addEventListener('keyup', formatToPhone);
    }
    if (forwardto_phone_8no) {
      forwardto_phone_8no.addEventListener('keydown', enforceFormat);
      forwardto_phone_8no.addEventListener('keyup', formatToPhone);
    }
    if (forwardto_phone_9no) {
      forwardto_phone_9no.addEventListener('keydown', enforceFormat);
      forwardto_phone_9no.addEventListener('keyup', formatToPhone);
    }
    if (forwardto_phone_10no) {
      forwardto_phone_10no.addEventListener('keydown', enforceFormat);
      forwardto_phone_10no.addEventListener('keyup', formatToPhone);
    }
  }
  static #_ = this.ctorParameters = () => [{
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_4__.FormBuilder
  }, {
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_5__.Router
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_5__.ActivatedRoute
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_6__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_3__.HttpBackend
  }, {
    type: ngx_ui_loader__WEBPACK_IMPORTED_MODULE_7__.NgxUiLoaderService
  }, {
    type: _angular_core__WEBPACK_IMPORTED_MODULE_8__.ChangeDetectorRef
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_9__.Title
  }];
};
EditIvrmenuComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_10__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_8__.Component)({
  selector: 'app-edit-ivrmenu',
  template: _edit_ivrmenu_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_edit_ivrmenu_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], EditIvrmenuComponent);


/***/ }),

/***/ 192:
/*!**********************************************************!*\
  !*** ./src/app/modules/ivr-menus/ivr-menus.component.ts ***!
  \**********************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "IvrMenusComponent": () => (/* binding */ IvrMenusComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _ivr_menus_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./ivr-menus.component.html?ngResource */ 20388);
/* harmony import */ var _ivr_menus_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./ivr-menus.component.scss?ngResource */ 99757);
/* harmony import */ var _ivr_menus_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_ivr_menus_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../module.service */ 22947);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! sweetalert2 */ 60598);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(sweetalert2__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../global */ 27266);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @angular/platform-browser */ 34497);








//import 'sweetalert2/src/sweetalert2.scss'



const router = _angular_router__WEBPACK_IMPORTED_MODULE_5__.Router;
class DataTablesResponse {}
class IVRMenus {}
let IvrMenusComponent = class IvrMenusComponent {
  constructor(moduleservice, toastrService, handler, router, titleService) {
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.router = router;
    this.titleService = titleService;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_4__.GlobalVariable.BASE_API_URL;
    this.dtOptions = {};
    this.ischecked = '1';
    this.checkboxes = [];
    this.filter = [];
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_6__.HttpClient(handler);
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngOnInit() {
    this.setTitle('IVR Menus');
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.loadIVRMenus();
  }
  loadIVRMenus() {
    if ($.fn.DataTable.isDataTable(this.table.nativeElement)) {
      $(this.table.nativeElement).dataTable().fnDestroy();
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    var that = this;
    this.dtOptions = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "pageLength": 20,
      "lengthMenu": [[-1, 20, 100, 500, 2000], ["All", 20, 100, 500, 2000]],
      "order": [[1, "asc"]],
      ajax: (dataTablesParameters, callback) => {
        that.http.post(this.ServerUrl + 'getIVRMenus/' + this.currentCompany.uuid, dataTablesParameters, {}).subscribe(resp => {
          that.IVRMenus = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [
      // {data:"checkall"},
      {
        data: "name"
      }, {
        data: "buyer"
      }, {
        data: "created_at"
      }, {
        data: "action"
      }],
      columnDefs: [{
        "targets": [0, 3],
        "orderable": false
      }]
    };
    this.dataTable = $(this.table.nativeElement);
    this.dataTable.dataTable(this.dtOptions);
  }
  checkalldelete(event) {
    const checked = event.target.checked;
    this.IVRMenus.forEach(chkbox => chkbox.selected = checked);
  }
  deleteselected(event) {
    // $("#customCheck1").prop("checked", false);
    if (event.target.checked == true) {
      if (event.target.value == 'on') {
        this.checkboxes = [];
        this.IVRMenus.forEach(lbl => {
          this.checkboxes.push(lbl.id);
        });
      } else {
        if (this.checkboxes.length + 1 == this.IVRMenus.length) {
          $("#customCheck1").prop("checked", true);
        }
        this.checkboxes.push(event.target.value);
      }
      this.ischecked = '0';
    } else {
      // console.log(this.checkboxes);
      if (this.checkboxes.length != 0) {
        $("#customCheck1").prop("checked", false);
      }
      if (event.target.value != 'on') {
        const index = this.checkboxes.indexOf(event.target.value);
        this.checkboxes.splice(index, 1);
      } else {
        this.checkboxes = [];
      }
      this.ischecked = '1';
    }
    // console.log(this.checkboxes);
  }

  onDeleteSubmit() {
    if (this.checkboxes.length == 0) {
      this.toastrService.error('Please Select Row To Delete');
    } else {
      // console.log(this.checkboxes);
      sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
        title: 'Are you sure?',
        text: 'You want to Delete Selected Record!',
        showCancelButton: true,
        confirmButtonText: 'Yes, delete it!',
        cancelButtonText: 'No, keep it'
      }).then(result => {
        if (result.value) {
          this.moduleservice.deleteSelectedIVR(this.checkboxes).subscribe(res => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Records Deleted Successfully.');
            setTimeout(() => {
              sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
            }, 2000);
            this.loadIVRMenus();
          }, error => this.error = error);
        } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
        }
      });
    }
  }
  Delete(uuid) {
    // alert(uuid);return false;
    sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
      title: 'Are you sure?',
      text: 'You want to Delete Record!',
      showCancelButton: true,
      confirmButtonText: 'Yes, delete it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        let currentUser = JSON.parse(localStorage.getItem('currentUser'));
        this.moduleservice.deleteIVRMenu(uuid, currentUser.uuid).subscribe(res => {
          // console.log(res);return false;
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Record Deleted Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
          this.loadIVRMenus();
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
        }, 2000);
      }
    });
  }
  Clone(id) {
    sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
      title: 'Are you sure?',
      text: 'You want to clone this IVR Menu!',
      showCancelButton: true,
      confirmButtonText: 'Yes, clone it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        let currentUser = JSON.parse(localStorage.getItem('currentUser'));
        this.moduleservice.cloneIVR(id, currentUser.uuid).subscribe(res => {
          this.filter = [res];
          if (this.filter[0]['status'] == 'success') {
            this.loadIVRMenus();
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Success!', 'IVR Menu Clone Successfully.');
            setTimeout(() => {
              sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
            }, 2000);
            this.router.navigate(['/edit-ivr/' + this.filter[0]['uuid']]);
          } else {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Error', 'IVR Menu Clone failed.', 'error');
          }
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', '', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
        }, 2000);
      }
    });
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_7__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_6__.HttpBackend
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_5__.Router
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_8__.Title
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_9__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }]
  };
};
IvrMenusComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_10__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_9__.Component)({
  selector: 'app-ivr-menus',
  template: _ivr_menus_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_ivr_menus_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], IvrMenusComponent);


/***/ }),

/***/ 69039:
/*!************************************************************************************!*\
  !*** ./src/app/modules/ivr-menus/ivr-routing-plans/add-plan/add-plan.component.ts ***!
  \************************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "AddPlanComponent": () => (/* binding */ AddPlanComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _add_plan_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./add-plan.component.html?ngResource */ 48952);
/* harmony import */ var _add_plan_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./add-plan.component.scss?ngResource */ 75027);
/* harmony import */ var _add_plan_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_add_plan_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../../../../global */ 27266);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./../../../module.service */ 22947);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! sweetalert2 */ 60598);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(sweetalert2__WEBPACK_IMPORTED_MODULE_4__);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @angular/platform-browser */ 34497);












class DataTablesResponse {}
let AddPlanComponent = class AddPlanComponent {
  constructor(renderer, moduleservice, toastrService, handler, fb, router, route, cdRef, titleService) {
    this.renderer = renderer;
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.fb = fb;
    this.router = router;
    this.route = route;
    this.cdRef = cdRef;
    this.titleService = titleService;
    this.locations = [];
    this.dropdownList = [];
    this.selectedItems = [];
    this.dropdownSettings = {};
    this.pubdropdownSettings = {};
    this.labeldropdownSettings = {};
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_2__.GlobalVariable.BASE_API_URL;
    this.dtOptions = {};
    this.dtOptionsTarget = {};
    this.dtOptionsRouting = {};
    this.Submitted = false;
    this.nameadded = 0;
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_5__.HttpClient(handler);
    this.uuid = this.route.snapshot.paramMap.get('id');
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngAfterViewChecked() {
    this.cdRef.detectChanges();
  }
  ngOnInit() {
    this.setTitle('Create IVR Routing Plan');
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.getAlltarget();
    this.loadalltarget();
    this.loadallRoutingplan(this.nam_uuid);
    this.editRoutingForm = this.fb.group({
      user_uuid: [''],
      uuid: [''],
      priority: [''],
      weight: [''],
      conversation_revenue: [''],
      conversation_event: [''],
      conversation_seconds: [''],
      restrictdup: [''],
      restrictafter: [''],
      days: [''],
      settingToggleDurationval: [''],
      settingToggleDuration: ['']
    });
    this.editForm = this.fb.group({
      name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required],
      user_uuid: ['']
    });
  }
  loadalltarget() {
    let type = 1;
    if ($.fn.DataTable.isDataTable(this.tabletarget.nativeElement)) {
      $(this.tabletarget.nativeElement).dataTable().fnDestroy();
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.dtOptionsTarget = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "pageLength": 20,
      "lengthMenu": [[10, 20, 50, 100, "All"], [10, 20, 50, 100, "All"]],
      "order": [[0, "asc"]],
      ajax: (dataTablesParameters, callback) => {
        this.http.post(this.ServerUrl + 'gettargets/' + this.currentCompany.uuid + '/' + this.nam_uuid + '/' + type, {
          'dataTablesParameters': dataTablesParameters,
          'user_uuid': currentUser.uuid,
          'role': currentUser.role
        }, {}).subscribe(resp => {
          this.allTargets = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [{
        data: "name"
      }, {
        data: "typeval"
      }, {
        data: "action"
      }],
      columnDefs: [{
        "targets": [0],
        "orderable": false
      }]
    };
    this.dataTableTarget = $(this.tabletarget.nativeElement);
    this.dataTableTarget.dataTable(this.dtOptionsTarget);
  }
  loadallRoutingplan(uuid) {
    if ($.fn.DataTable.isDataTable(this.tablerouting.nativeElement)) {
      $(this.tablerouting.nativeElement).dataTable().fnDestroy();
    }
    this.dtOptionsRouting = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "pageLength": 20,
      "lengthMenu": [[10, 20, 50, 100, "All"], [10, 20, 50, 100, "All"]],
      "order": [[0, "asc"]],
      "searching": false,
      ajax: (dataTablesParameters, callback) => {
        this.http.post(this.ServerUrl + 'getallIVRRoutingplan/' + uuid, dataTablesParameters, {}).subscribe(resp => {
          this.allRoutingPlan = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [{
        data: "prority"
      }, {
        data: "name"
      }, {
        data: "destination"
      }, {
        data: "revenue"
      }, {
        data: "status"
      }, {
        data: "action"
      }],
      columnDefs: [{
        "targets": [0],
        "orderable": false
      }]
    };
    this.dataTableRouting = $(this.tablerouting.nativeElement);
    this.dataTableRouting.dataTable(this.dtOptionsRouting);
  }
  DeleteRoutingPlan(uuid) {
    sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire({
      title: 'Are you sure?',
      text: 'You want to Delete Record!',
      showCancelButton: true,
      confirmButtonText: 'Yes, delete it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        var currentUser = JSON.parse(localStorage.getItem('currentUser'));
        this.moduleservice.deleteIVRRoutingPlan(uuid, currentUser.uuid).subscribe(res => {
          // console.log(res);return false;
          sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Deleted!', 'Record Deleted Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
          }, 2000);
          this.loadallRoutingplan(this.uuid);
          this.loadalltarget();
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Cancelled', 'Your Record is safe :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
        }, 2000);
      }
    });
  }
  setRouting(uuid) {
    if (this.editForm.get('name').value == "") {
      sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Error', 'Please Enter Name of Routing First :)', 'error');
      setTimeout(() => {
        sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
      }, 2000);
      return false;
    }
    sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire({
      title: 'Are you sure?',
      text: 'You want Add Routing Plan!',
      showCancelButton: true,
      confirmButtonText: 'Yes, Add it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        var currentUser = JSON.parse(localStorage.getItem('currentUser'));
        var currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
        this.moduleservice.setivrRouting(uuid, this.namvalue, currentUser.uuid, currentCompany.uuid).subscribe(res => {
          this.loadallRoutingplan(this.nam_uuid);
          this.loadalltarget();
          sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Added!', 'Routing Plan Added Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
          }, 2000);
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Cancelled', 'Routing Plan Cancelled :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
        }, 2000);
      }
    });
  }
  getAlltarget() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleservice.getAlltarget(this.currentCompany.uuid).subscribe(res => {
      this.targetdata = res;
    }, error => this.error = error);
  }
  get editFormcontrol() {
    return this.editForm.controls;
  }
  onSubmit() {
    this.Submitted = true;
    if (this.editForm.invalid) {
      return;
    }
    var currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.editForm.get('user_uuid').setValue(currentUser.uuid);
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleservice.addIVRPlan(currentUser.uuid, this.currentCompany.uuid, this.editForm.value).subscribe(res => {
      //  console.log(res); return false;
      if (res.status !== 'error') {
        this.nameadded = 1;
        this.nam_uuid = res.uuid;
        this.namvalue = this.editForm.get('name').value;
        this.toastrService.success('IVR Routing Plan Added Successfully');
        this.Submitted = false;
        //  this.router.navigate(['/campaigns']);
      } else {
        this.toastrService.error('Failed To Add Plan! Please try again');
      }
    }, error => this.error = error);
  }
  closeModal() {
    if (!this.payoutForm.invalid) {
      $("#addLabels").modal("hide");
    }
  }
  closeroutingModal() {
    if (!this.editRoutingForm.invalid) {
      $("#editRouting").modal("hide");
    }
  }
  editRoutingdata(uuid, priority, weight, revenue, type, seconds, restrictdup, restrictafter, settingToggleDurationval, days) {
    // console.log(uuid)
    this.editRoutingForm.patchValue({
      uuid: uuid,
      priority: priority,
      weight: weight,
      conversation_revenue: revenue,
      conversation_event: type,
      conversation_seconds: seconds,
      restrictdup: restrictdup,
      restrictafter: restrictafter,
      days: days,
      settingToggleDurationval: settingToggleDurationval,
      settingToggleDuration: settingToggleDurationval
    });
    // this.settingToggleDurationvalue = settingToggleDurationval;
  }

  get editRoutingSubmit() {
    return this.editRoutingForm.controls;
  }
  oneditRoutingSubmit() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    var currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.editRoutingForm.get('user_uuid').setValue(currentUser.uuid);
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleservice.editIVRRoutingSubmit(this.uuid, this.editRoutingForm.value).subscribe(res => {
      if (res.status !== 'error') {
        this.toastrService.success('Routing Plan Updated Successfully');
        this.Submitted = false;
        this.loadallRoutingplan(this.nam_uuid);
      } else {
        this.toastrService.error('Failed To Update Campaign');
      }
    }, error => this.error = error);
  }
  static #_ = this.ctorParameters = () => [{
    type: _angular_core__WEBPACK_IMPORTED_MODULE_7__.Renderer2
  }, {
    type: _module_service__WEBPACK_IMPORTED_MODULE_3__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_8__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_5__.HttpBackend
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_6__.FormBuilder
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_9__.Router
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_9__.ActivatedRoute
  }, {
    type: _angular_core__WEBPACK_IMPORTED_MODULE_7__.ChangeDetectorRef
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_10__.Title
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_7__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }],
    tabletarget: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_7__.ViewChild,
      args: ['dataTableTarget', {
        static: true
      }]
    }],
    tablerouting: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_7__.ViewChild,
      args: ['dataTableRouting', {
        static: true
      }]
    }]
  };
};
AddPlanComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_11__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_7__.Component)({
  selector: 'app-add-plan',
  template: _add_plan_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_add_plan_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], AddPlanComponent);


/***/ }),

/***/ 71352:
/*!**************************************************************************************!*\
  !*** ./src/app/modules/ivr-menus/ivr-routing-plans/edit-plan/edit-plan.component.ts ***!
  \**************************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "EditPlanComponent": () => (/* binding */ EditPlanComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _edit_plan_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./edit-plan.component.html?ngResource */ 76799);
/* harmony import */ var _edit_plan_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./edit-plan.component.scss?ngResource */ 97089);
/* harmony import */ var _edit_plan_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_edit_plan_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../../../../global */ 27266);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./../../../module.service */ 22947);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! sweetalert2 */ 60598);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(sweetalert2__WEBPACK_IMPORTED_MODULE_4__);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @angular/platform-browser */ 34497);












class DataTablesResponse {}
let EditPlanComponent = class EditPlanComponent {
  constructor(renderer, moduleservice, toastrService, handler, fb, router, route, cdRef, titleService) {
    this.renderer = renderer;
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.fb = fb;
    this.router = router;
    this.route = route;
    this.cdRef = cdRef;
    this.titleService = titleService;
    this.locations = [];
    this.dropdownList = [];
    this.selectedItems = [];
    this.dropdownSettings = {};
    this.pubdropdownSettings = {};
    this.labeldropdownSettings = {};
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_2__.GlobalVariable.BASE_API_URL;
    this.dtOptions = {};
    this.dtOptionsTarget = {};
    this.dtOptionsRouting = {};
    this.Submitted = false;
    this.nameadded = 0;
    this.getsettingToggleDurationval = 0;
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_5__.HttpClient(handler);
    this.uuid = this.route.snapshot.paramMap.get('id');
  }
  ngAfterViewChecked() {
    this.cdRef.detectChanges();
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngOnInit() {
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.uuid = this.route.snapshot.paramMap.get('id');
    this.moduleservice.getplanbyuuid(this.uuid).subscribe(res => {
      this.setTitle(res.plan_name + ' | IVR Routing Plan');
      this.editForm.patchValue({
        name: res.plan_name
      });
      this.addedname = res.plan_name;
    });
    //  this.getAlltarget();
    this.loadalltarget();
    this.loadallRoutingplan(this.uuid);
    this.editRoutingForm = this.fb.group({
      user_uuid: [''],
      uuid: [''],
      priority: [''],
      weight: [''],
      conversation_revenue: [''],
      conversation_event: [''],
      conversation_seconds: [''],
      restrictdup: [''],
      restrictafter: [''],
      days: [''],
      settingToggleDurationval: [''],
      settingToggleDuration: ['']
    });
    this.editForm = this.fb.group({
      name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required],
      user_uuid: ['']
    });
  }
  loadalltarget() {
    let type = 1;
    if ($.fn.DataTable.isDataTable(this.tabletarget.nativeElement)) {
      $(this.tabletarget.nativeElement).dataTable().fnDestroy();
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.dtOptionsTarget = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "pageLength": 20,
      "lengthMenu": [[10, 20, 50, 100, "All"], [10, 20, 50, 100, "All"]],
      "order": [[0, "asc"]],
      ajax: (dataTablesParameters, callback) => {
        this.http.post(this.ServerUrl + 'gettargets/' + this.currentCompany.uuid + '/' + this.uuid + '/' + type, {
          'dataTablesParameters': dataTablesParameters,
          'user_uuid': currentUser.uuid,
          'role': currentUser.role
        }, {}).subscribe(resp => {
          this.allTargets = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [{
        data: "name"
      }, {
        data: "typeval"
      }, {
        data: "action"
      }],
      columnDefs: [{
        "targets": [0],
        "orderable": false
      }]
    };
    this.dataTableTarget = $(this.tabletarget.nativeElement);
    this.dataTableTarget.dataTable(this.dtOptionsTarget);
  }
  loadallRoutingplan(uuid) {
    if ($.fn.DataTable.isDataTable(this.tablerouting.nativeElement)) {
      $(this.tablerouting.nativeElement).dataTable().fnDestroy();
    }
    this.dtOptionsRouting = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "pageLength": 20,
      "lengthMenu": [[10, 20, 50, 100, "All"], [10, 20, 50, 100, "All"]],
      "order": [[0, "asc"]],
      "searching": false,
      ajax: (dataTablesParameters, callback) => {
        this.http.post(this.ServerUrl + 'getallIVRRoutingplan/' + uuid, dataTablesParameters, {}).subscribe(resp => {
          this.allRoutingPlan = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [{
        data: "prority"
      }, {
        data: "name"
      }, {
        data: "destination"
      }, {
        data: "revenue"
      }, {
        data: "status"
      }, {
        data: "action"
      }],
      columnDefs: [{
        "targets": [0],
        "orderable": false
      }]
    };
    this.dataTableRouting = $(this.tablerouting.nativeElement);
    this.dataTableRouting.dataTable(this.dtOptionsRouting);
  }
  DeleteRoutingPlan(uuid) {
    sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire({
      title: 'Are you sure?',
      text: 'You want to Delete Record!',
      showCancelButton: true,
      confirmButtonText: 'Yes, delete it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        var currentUser = JSON.parse(localStorage.getItem('currentUser'));
        // alert(uuid);return;
        this.moduleservice.deleteIVRRoutingPlan(uuid, currentUser.uuid).subscribe(res => {
          // console.log(res);return false;
          sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Deleted!', 'Record Deleted Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
          }, 2000);
          this.loadallRoutingplan(this.uuid);
          this.loadalltarget();
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Cancelled', 'Your Record is safe :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
        }, 2000);
      }
    });
  }
  setRouting(uuid) {
    if (this.editForm.get('name').value == "") {
      sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Error', 'Please Enter Name of Routing First :)', 'error');
      setTimeout(() => {
        sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
      }, 2000);
      return false;
    }
    sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire({
      title: 'Are you sure?',
      text: 'You want Add Routing Plan!',
      showCancelButton: true,
      confirmButtonText: 'Yes, Add it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        var currentUser = JSON.parse(localStorage.getItem('currentUser'));
        var currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
        if (this.namvalue == undefined) {
          this.namvalue = this.addedname;
        }
        // console.log(this.namvalue); return;
        this.moduleservice.setivrRouting(uuid, this.namvalue, currentUser.uuid, currentCompany.uuid).subscribe(res => {
          this.loadallRoutingplan(this.uuid);
          this.loadalltarget();
          sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Added!', 'Routing Plan Added Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
          }, 2000);
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Cancelled', 'Routing Plan Cancelled :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
        }, 2000);
      }
    });
  }
  getAlltarget() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleservice.getAlltarget(this.currentCompany.uuid).subscribe(res => {
      this.targetdata = res;
    }, error => this.error = error);
  }
  get editFormcontrol() {
    return this.editForm.controls;
  }
  onSubmit() {
    this.Submitted = true;
    if (this.editForm.invalid) {
      return;
    }
    var currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.editForm.get('user_uuid').setValue(currentUser.uuid);
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.uuid = this.route.snapshot.paramMap.get('id');
    this.moduleservice.editIVRPlan(currentUser.uuid, this.uuid, this.editForm.value).subscribe(res => {
      //  console.log(res); return false;
      if (res.status !== 'error') {
        this.nameadded = 1;
        this.nam_uuid = res.uuid;
        this.namvalue = this.editForm.get('name').value;
        this.toastrService.success('IVR Routing Plan Updated Successfully');
        this.Submitted = false;
        //  this.router.navigate(['/campaigns']);
      } else {
        this.toastrService.error('Failed To Add Plan! Please try again');
      }
    }, error => this.error = error);
  }
  closeModal() {
    if (!this.payoutForm.invalid) {
      $("#addLabels").modal("hide");
    }
  }
  closeroutingModal() {
    if (!this.editRoutingForm.invalid) {
      $("#editRouting").modal("hide");
    }
  }
  settingToggleDuration(type) {
    this.getsettingToggleDurationval = type;
    this.editRoutingForm.get('settingToggleDuration').setValue(type);
    //  console.log(this.editRoutingForm.get('settingToggleDurationval').value);
  }

  editRoutingdata(uuid, priority, weight, revenue, type, seconds, restrictdup, restrictafter, settingToggleDurationval, days) {
    // console.log(uuid)
    this.editRoutingForm.patchValue({
      uuid: uuid,
      priority: priority,
      weight: weight,
      conversation_revenue: revenue,
      conversation_event: type,
      conversation_seconds: seconds,
      restrictdup: restrictdup,
      restrictafter: restrictafter,
      days: days,
      settingToggleDurationval: settingToggleDurationval,
      settingToggleDuration: settingToggleDurationval
    });
    // console.log(settingToggleDurationval);
    this.getsettingToggleDurationval = settingToggleDurationval;
  }
  get editRoutingSubmit() {
    return this.editRoutingForm.controls;
  }
  oneditRoutingSubmit() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    var currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.editRoutingForm.get('user_uuid').setValue(currentUser.uuid);
    this.editRoutingForm.get('settingToggleDuration').setValue(this.getsettingToggleDurationval);
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    //  console.log(this.editRoutingForm.value); return;
    this.moduleservice.editIVRRoutingSubmit(this.uuid, this.editRoutingForm.value).subscribe(res => {
      if (res.status !== 'error') {
        this.toastrService.success('Routing Plan Updated Successfully');
        this.Submitted = false;
        this.loadallRoutingplan(this.uuid);
      } else {
        this.toastrService.error('Failed To Update Campaign');
      }
    }, error => this.error = error);
  }
  static #_ = this.ctorParameters = () => [{
    type: _angular_core__WEBPACK_IMPORTED_MODULE_7__.Renderer2
  }, {
    type: _module_service__WEBPACK_IMPORTED_MODULE_3__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_8__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_5__.HttpBackend
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_6__.FormBuilder
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_9__.Router
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_9__.ActivatedRoute
  }, {
    type: _angular_core__WEBPACK_IMPORTED_MODULE_7__.ChangeDetectorRef
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_10__.Title
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_7__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }],
    tabletarget: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_7__.ViewChild,
      args: ['dataTableTarget', {
        static: true
      }]
    }],
    tablerouting: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_7__.ViewChild,
      args: ['dataTableRouting', {
        static: true
      }]
    }]
  };
};
EditPlanComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_11__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_7__.Component)({
  selector: 'app-edit-plan',
  template: _edit_plan_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_edit_plan_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], EditPlanComponent);


/***/ }),

/***/ 24066:
/*!************************************************************************************!*\
  !*** ./src/app/modules/ivr-menus/ivr-routing-plans/ivr-routing-plans.component.ts ***!
  \************************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "IVRRoutingPlansComponent": () => (/* binding */ IVRRoutingPlansComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _ivr_routing_plans_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./ivr-routing-plans.component.html?ngResource */ 74437);
/* harmony import */ var _ivr_routing_plans_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./ivr-routing-plans.component.scss?ngResource */ 20447);
/* harmony import */ var _ivr_routing_plans_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_ivr_routing_plans_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../../module.service */ 22947);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! sweetalert2 */ 60598);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(sweetalert2__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../global */ 27266);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @angular/platform-browser */ 34497);









//import 'sweetalert2/src/sweetalert2.scss'



const router = _angular_router__WEBPACK_IMPORTED_MODULE_5__.Router;
class DataTablesResponse {}
let IVRRoutingPlansComponent = class IVRRoutingPlansComponent {
  constructor(moduleservice, toastrService, handler, fb, changedetect, titleService, router) {
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.fb = fb;
    this.changedetect = changedetect;
    this.titleService = titleService;
    this.router = router;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_4__.GlobalVariable.BASE_API_URL;
    this.dtOptions = {};
    this.ischecked = '1';
    this.settingToggleAccessToRecordingsvaldata = 0;
    this.settingToggleBlockCallsIfCappeddata = 0;
    this.checkboxes = [];
    this.settingToggleBlockCallsIfCappededit = 0;
    this.settingToggleAccessToRecordingsedit = 0;
    this.Submitted = false;
    this.editSubmitted = false;
    this.filter = [];
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_6__.HttpClient(handler);
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngOnInit() {
    this.setTitle('Manage Routing Plans');
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.loadivrplans();
    // this.loadNumbers();
    this.addForm = this.fb.group({
      name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      sub_id: [''],
      number_creation: [''],
      settingToggleBlockCallsIfCapped: [''],
      settingToggleAccessToRecordings: ['']
    });
    this.editForm = this.fb.group({
      uuid: [''],
      name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      sub_id: [''],
      number_creation: [''],
      settingToggleBlockCallsIfCapped: [''],
      settingToggleAccessToRecordings: ['']
    });
  }
  ngAfterViewInit() {
    this.changedetect.detectChanges();
  }
  loadivrplans() {
    if ($.fn.DataTable.isDataTable(this.table.nativeElement)) {
      $(this.table.nativeElement).dataTable().fnDestroy();
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.dtOptions = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "pageLength": 20,
      "lengthMenu": [[-1, 20, 100, 500, 2000], ["All", 20, 100, 500, 2000]],
      "order": [[0, "asc"]],
      ajax: (dataTablesParameters, callback) => {
        this.http.post(this.ServerUrl + 'getIVRPlans/' + this.currentCompany.uuid, dataTablesParameters, {}).subscribe(resp => {
          this.numbers = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [{
        data: "name"
      }, {
        data: "created_at"
      }, {
        data: "action"
      }]
      // columnDefs: [
      //   { 
      //       "targets": [0], 
      //       "orderable": false,
      //   },
      //   ],
    };

    this.dataTable = $(this.table.nativeElement);
    this.dataTable.dataTable(this.dtOptions);
  }
  editdata(uuid, name, sub_id, create_number, settingToggleBlockCallsIfCapped, settingToggleAccessToRecordings) {
    this.settingToggleAccessToRecordingsvaldata = settingToggleAccessToRecordings;
    this.settingToggleBlockCallsIfCappeddata = settingToggleBlockCallsIfCapped;
    this.editForm.patchValue({
      uuid: uuid,
      name: name,
      sub_id: sub_id,
      number_creation: create_number,
      settingToggleBlockCallsIfCapped: settingToggleBlockCallsIfCapped,
      settingToggleAccessToRecordings: settingToggleAccessToRecordings
    });
  }
  checkalldelete(event) {
    const checked = event.target.checked;
    this.numbers.forEach(chkbox => chkbox.selected = checked);
  }
  deleteselected(event) {
    // $("#customCheck1").prop("checked", false);    
    if (event.target.checked == true) {
      if (event.target.value == 'on') {
        this.checkboxes = [];
        this.numbers.forEach(lbl => {
          this.checkboxes.push(lbl.id);
        });
      } else {
        if (this.checkboxes.length + 1 == this.numbers.length) {
          $("#customCheck1").prop("checked", true);
        }
        this.checkboxes.push(event.target.value);
      }
      this.ischecked = '0';
    } else {
      // console.log(this.checkboxes);      
      if (this.checkboxes.length != 0) {
        $("#customCheck1").prop("checked", false);
      }
      if (event.target.value != 'on') {
        const index = this.checkboxes.indexOf(event.target.value);
        this.checkboxes.splice(index, 1);
      } else {
        this.checkboxes = [];
      }
      this.ischecked = '1';
    }
    // console.log(this.checkboxes); 
  }
  // onDeleteSubmit(){    
  //   if(this.checkboxes.length==0){
  //     this.toastrService.error('Please Select Row To Delete');
  //   }else{
  //     // console.log(this.checkboxes);  
  //     Swal.fire({
  //       title: 'Are you sure?',
  //       text: 'You want to Delete Selected Record!',
  //       
  //       showCancelButton: true,
  //       confirmButtonText: 'Yes, delete it!',
  //       cancelButtonText: 'No, keep it'
  //     }).then((result) => {
  //       if (result.value) {
  //         this.moduleservice.deleteSelectedNumbers(this.checkboxes).subscribe(
  //           res => {
  //               Swal.fire(
  //                 'Deleted!',
  //                 'Records Deleted Successfully.',
  //                 'success',                
  //               )
  //               setTimeout(() => {
  //                 Swal.close()
  //               }, 2000);
  //               this.loadivrplans();
  //             },
  //             error => this.error = error
  //         );      
  //       } else if (result.dismiss === Swal.DismissReason.cancel) {
  //         Swal.fire(
  //           'Cancelled',
  //           'Your Record is safe :)',
  //           'error'
  //         )
  //         setTimeout(() => {
  //           Swal.close()
  //         }, 2000);
  //       }
  //     });
  //   }
  // }
  Delete(planuuid) {
    sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
      title: 'Are you sure?',
      text: 'You want to Delete Record!',
      showCancelButton: true,
      confirmButtonText: 'Yes, delete it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        let currentUser = JSON.parse(localStorage.getItem('currentUser'));
        this.moduleservice.deleteIVRRoutingPlan(planuuid, currentUser.uuid).subscribe(res => {
          // console.log(res);return false;
          this.loadivrplans();
          // this.toastrService.success('Number Deleted Successfully');
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Record Deleted Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
        }, 2000);
      }
    });
  }
  settingToggleBlockCallsIfCappedval(val) {
    this.addForm.get('settingToggleBlockCallsIfCapped').setValue(val);
  }
  settingToggleAccessToRecordingsval(val) {
    this.addForm.get('settingToggleAccessToRecordings').setValue(val);
  }
  settingToggleBlockCallsIfCappedvaledit(val) {
    this.settingToggleBlockCallsIfCappededit = val;
    this.editForm.get('settingToggleBlockCallsIfCapped').setValue(val);
  }
  settingToggleAccessToRecordingsvaledit(val) {
    this.settingToggleAccessToRecordingsedit = val;
    this.editForm.get('settingToggleAccessToRecordings').setValue(val);
  }
  //Add Publisher
  get addformcontrol() {
    return this.addForm.controls;
  }
  onSubmit() {
    const formData = new FormData();
    this.Submitted = true;
    if (this.addForm.invalid) {
      return;
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('name', this.addForm.get('name').value);
    formData.append('sub_id', this.addForm.get('sub_id').value);
    formData.append('number_creation', this.addForm.get('number_creation').value);
    formData.append('settingToggleBlockCallsIfCapped', this.addForm.get('settingToggleBlockCallsIfCapped').value);
    formData.append('settingToggleAccessToRecordings', this.addForm.get('settingToggleAccessToRecordings').value);
    // console.log(formData); return false;
    this.moduleservice.addPublisher(formData).subscribe(res => {
      // console.log(res.status); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Publisher Added Successfully');
        this.loadivrplans();
        this.Submitted = false;
      } else {
        this.toastrService.error('Failed To Add Label');
      }
    }, error => this.error = error);
  }
  //Add Buyer
  get editFormcontrol() {
    return this.editForm.controls;
  }
  onEditSubmit() {
    // alert('ok');return false;
    const formData = new FormData();
    this.editSubmitted = true;
    if (this.editForm.invalid) {
      return;
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('uuid', this.editForm.get('uuid').value);
    formData.append('name', this.editForm.get('name').value);
    formData.append('sub_id', this.editForm.get('sub_id').value);
    formData.append('number_creation', this.editForm.get('number_creation').value);
    formData.append('settingToggleBlockCallsIfCapped', this.editForm.get('settingToggleBlockCallsIfCapped').value);
    formData.append('settingToggleAccessToRecordings', this.editForm.get('settingToggleAccessToRecordings').value);
    // console.log(formData); 
    this.moduleservice.editPublisher(formData).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Publisher Updated Successfully');
        this.loadivrplans();
        this.editSubmitted = false;
      } else {
        this.toastrService.error('Failed To Add Label');
      }
    }, error => this.error = error);
  }
  closeModal() {
    if (this.addForm.get('name').value != '') {
      $("#addLabels").modal("hide");
      // $(".custom-switch-input").prop('checked',false);
      this.Submitted = false;
      setTimeout(() => {
        this.addForm.reset();
      }, 2000);
    }
  }
  closeEditModal() {
    if (this.editForm.get('name').value != '') {
      $("#editLabels").modal("hide");
      this.editSubmitted = false;
      setTimeout(() => {
        this.editForm.reset();
      }, 2000);
    }
  }
  Status(id, status) {
    sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
      title: 'Are you sure?',
      text: 'You want to change Status!',
      showCancelButton: true,
      confirmButtonText: 'Yes, Change it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        this.moduleservice.changeCampaignstatus(id, status).subscribe(res => {
          this.loadivrplans();
          // this.toastrService.success('Number Deleted Successfully');
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Changed!', 'Status Changes Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
        }, 2000);
      }
    });
  }
  Clone(id) {
    sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
      title: 'Are you sure?',
      text: 'You want to clone this routing plan!',
      showCancelButton: true,
      confirmButtonText: 'Yes, clone it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        let currentUser = JSON.parse(localStorage.getItem('currentUser'));
        this.moduleservice.cloneRoutingPlan(id, currentUser.uuid).subscribe(res => {
          this.filter = [res];
          if (this.filter[0]['status'] == 'success') {
            this.loadivrplans();
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Success!', 'Routing plan Clone Successfully.');
            setTimeout(() => {
              sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
            }, 2000);
            this.router.navigate(['/ivrplan-edit/' + this.filter[0]['uuid']]);
          } else {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Error', 'Routing plan Clone failed.');
          }
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', '');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
        }, 2000);
      }
    });
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_8__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_6__.HttpBackend
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_7__.FormBuilder
  }, {
    type: _angular_core__WEBPACK_IMPORTED_MODULE_9__.ChangeDetectorRef
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_10__.Title
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_5__.Router
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_9__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }]
  };
};
IVRRoutingPlansComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_11__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_9__.Component)({
  selector: 'app-ivr-routing-plans',
  template: _ivr_routing_plans_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_ivr_routing_plans_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], IVRRoutingPlansComponent);


/***/ }),

/***/ 82714:
/*!******************************************************************!*\
  !*** ./src/app/modules/label/label-view/label-view.component.ts ***!
  \******************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "LabelViewComponent": () => (/* binding */ LabelViewComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _label_view_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./label-view.component.html?ngResource */ 69822);
/* harmony import */ var _label_view_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./label-view.component.scss?ngResource */ 79195);
/* harmony import */ var _label_view_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_label_view_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../module.service */ 22947);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! sweetalert2 */ 60598);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(sweetalert2__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../global */ 27266);
/* harmony import */ var ngx_csv_ngx_csv__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ngx-csv/ngx-csv */ 94551);
/* harmony import */ var ngx_ui_loader__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ngx-ui-loader */ 36413);








//import 'sweetalert2/src/sweetalert2.scss'




const router = _angular_router__WEBPACK_IMPORTED_MODULE_6__.Router;
class DataTablesResponse {}
let LabelViewComponent = class LabelViewComponent {
  constructor(moduleservice, toastrService, handler, route, ngxLoader) {
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.route = route;
    this.ngxLoader = ngxLoader;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_4__.GlobalVariable.BASE_API_URL;
    this.dtOptions = {};
    this.ischecked = '1';
    this.exportNumber = {};
    this.finalexportNumber = [];
    this.countNo = 0;
    this.checkboxes = [];
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_7__.HttpClient(handler);
  }
  ngOnInit() {
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    const labelname = this.route.snapshot.paramMap.get('labelname');
    this.loadNumbers(labelname);
    // console.log(labelname);
  }

  loadNumbers(labelname) {
    if ($.fn.DataTable.isDataTable(this.table.nativeElement)) {
      $(this.table.nativeElement).dataTable().fnDestroy();
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.dtOptions = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "pageLength": 50,
      "lengthMenu": [50, 100, 500, 1000, 2000, 5000],
      "order": [[1, "asc"]],
      ajax: (dataTablesParameters, callback) => {
        // this.http.post<DataTablesResponse>(
        //   this.ServerUrl+'getnumbersdata/'+this.currentCompany.uuid,
        //   dataTablesParameters, {}
        this.http.post(this.ServerUrl + 'getnumbersdata/' + this.currentCompany.uuid + '/' + labelname, {
          'dataTablesParameters': dataTablesParameters,
          'number': "",
          'campaign': "",
          'labels': ""
        }, {}).subscribe(resp => {
          this.numbers = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [
      // ,{data:"target"}
      {
        data: "checkall"
      }, {
        data: "number"
      }, {
        data: "campaign"
      }, {
        data: "publisher"
      }, {
        data: "status"
      }, {
        data: "created_at"
      }, {
        data: "assosciated_label"
      }, {
        data: "action"
      }],
      columnDefs: [{
        "targets": [0],
        "orderable": false
      }]
    };
    this.dataTable = $(this.table.nativeElement);
    this.dataTable.dataTable(this.dtOptions);
  }
  Delete(uuid) {
    sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
      title: 'Are you sure?',
      text: 'You want to Delete Record!',
      showCancelButton: true,
      confirmButtonText: 'Yes, delete it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        let currentUser = JSON.parse(localStorage.getItem('currentUser'));
        this.moduleservice.deleteNumberdata(uuid, currentUser.uuid).subscribe(res => {
          // this.toastrService.success('Number Deleted Successfully');
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Record Deleted Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
          const labelname = this.route.snapshot.paramMap.get('labelname');
          this.loadNumbers(labelname);
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
        }, 2000);
      }
    });
  }
  exportdata() {
    var options = {
      fieldSeparator: ',',
      quoteStrings: '"',
      decimalseparator: '.',
      showLabels: true,
      // showTitle: true,
      // title: 'Your title',
      useBom: true,
      // noDownload: true,
      headers: ["Number", "Country", "Campaign", "Publisher", "Status", "Allocated"]
    };
    // for (let index = 0; index < this.numbers.length; index++) {
    //   const element = this.numbers[index];
    //   // this.finalexportNumber.push({[index]:element.number});
    //   // this.finalexportNumber.push({[index]:element.country});
    //   this.exportNumber[index] = element.number;
    //   this.exportNumber[index+1] = element.country;
    //   this.exportNumber[index+2] = element.campaign;
    //   this.exportNumber[index+3] = element.publisher;
    //   this.exportNumber[index+4] = element.target;
    //   this.exportNumber[index+5] = element.created_at;
    //   // this.finalexportNumber[this.countNo] = this.exportNumber;
    //   this.finalexportNumber.push(this.exportNumber);
    //   // console.log(this.exportNumber);
    //   // this.countNo++;
    // }
    // console.log(this.finalexportNumber);
    // return
    // new   ngxCsv(this.finalexportNumber, 'Label-Numbers', options);
    //   this.numbers.forEach((element,index)=>{        
    //     this.exportNumber.number = element.number;
    //     this.exportNumber.country = element.country;
    //     this.exportNumber.campaign = element.campaign;
    //     this.exportNumber.publisher = element.publisher;
    //     this.exportNumber.target = element.target;
    //     // this.exportNumber.assosciated_labels = element.assosciated_labels;
    //     this.exportNumber.created_at = element.created_at;
    //     // console.log(index);
    //     this.finalexportNumber[index] = this.exportNumber;
    //  });
    //  console.log(this.finalexportNumber);
    //  return false; 
    // this.ngxLoader.start();
    this.showLoadingIndicator = true;
    // console.log('ok');
    // return false; 
    const labelname = this.route.snapshot.paramMap.get('labelname');
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleservice.getNumberForExport(this.currentCompany.uuid, labelname).subscribe(res => {
      // console.log(res);return
      // this.ngxLoader.stop();
      new ngx_csv_ngx_csv__WEBPACK_IMPORTED_MODULE_5__.ngxCsv(res, 'Label-Numbers', options);
      this.showLoadingIndicator = false;
    }, error => this.error = error);
  }
  checkalldelete(event) {
    const checked = event.target.checked;
    this.numbers.forEach(chkbox => chkbox.selected = checked);
  }
  deleteselected(event) {
    // $("#customCheck1").prop("checked", false);    
    if (event.target.checked == true) {
      if (event.target.value == 'on') {
        this.checkboxes = [];
        this.numbers.forEach(lbl => {
          this.checkboxes.push(lbl.id);
        });
      } else {
        if (this.checkboxes.length + 1 == this.numbers.length) {
          $("#customCheck1").prop("checked", true);
        }
        this.checkboxes.push(event.target.value);
      }
      this.ischecked = '0';
    } else {
      // console.log(this.checkboxes);      
      if (this.checkboxes.length != 0) {
        $("#customCheck1").prop("checked", false);
      }
      if (event.target.value != 'on') {
        const index = this.checkboxes.indexOf(event.target.value);
        this.checkboxes.splice(index, 1);
      } else {
        this.checkboxes = [];
      }
      this.ischecked = '1';
    }
    // console.log(this.checkboxes); 
  }

  onDeleteSubmit() {
    if (this.checkboxes.length == 0) {
      this.toastrService.error('Please Select Row To Delete');
    } else {
      // console.log(this.checkboxes);  
      sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
        title: 'Are you sure?',
        text: 'You want to Delete Selected Record!',
        showCancelButton: true,
        confirmButtonText: 'Yes, delete it!',
        cancelButtonText: 'No, keep it'
      }).then(result => {
        if (result.value) {
          this.moduleservice.deleteSelectedNumbers(this.checkboxes).subscribe(res => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Records Deleted Successfully.');
            setTimeout(() => {
              sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
            }, 2000);
            const labelname = this.route.snapshot.paramMap.get('labelname');
            this.loadNumbers(labelname);
          }, error => this.error = error);
        } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
        }
      });
    }
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_8__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_7__.HttpBackend
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_6__.ActivatedRoute
  }, {
    type: ngx_ui_loader__WEBPACK_IMPORTED_MODULE_9__.NgxUiLoaderService
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_10__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }]
  };
};
LabelViewComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_11__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_10__.Component)({
  selector: 'app-label-view',
  template: _label_view_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_label_view_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], LabelViewComponent);


/***/ }),

/***/ 92751:
/*!**************************************************!*\
  !*** ./src/app/modules/label/label.component.ts ***!
  \**************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "LabelComponent": () => (/* binding */ LabelComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _label_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./label.component.html?ngResource */ 31994);
/* harmony import */ var _label_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./label.component.scss?ngResource */ 50928);
/* harmony import */ var _label_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_label_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../module.service */ 22947);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! sweetalert2 */ 60598);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(sweetalert2__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../global */ 27266);
/* harmony import */ var ngx_csv_ngx_csv__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ngx-csv/ngx-csv */ 94551);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/platform-browser */ 34497);








//import 'sweetalert2/src/sweetalert2.scss'




class DataTablesResponse {}
class Labels {}
let LabelComponent = class LabelComponent {
  // payout_typeval:any;
  // flag: any;
  constructor(moduleservice, toastrService, handler, fb, titleService) {
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.fb = fb;
    this.titleService = titleService;
    //  rows = [
    //     { name: 'Austin', gender: 'Male', company: 'Swimlane' },
    //     { name: 'Dany', gender: 'Male', company: 'KFC' },
    //     { name: 'Molly', gender: 'Female', company: 'Burger King' }
    //   ];
    //   columns = [{ prop: 'name' }, { name: 'Gender' }, { name: 'Company' }]; 
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_4__.GlobalVariable.BASE_API_URL;
    this.dtOptions = {};
    this.LabelSubmitted = false;
    this.ischecked = '1';
    this.data = {};
    this.checkboxes = [];
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_6__.HttpClient(handler);
    // this.payout_typeval= 0;
    // this.flag = 0;
  }

  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngOnInit() {
    this.setTitle('Labels');
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.loadlabels();
    this.addLabelForm = this.fb.group({
      name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      notes: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      user_uuid: ['']
      // conversation_revenue: [''],      
      // conversation_event: [''],      
      // conversation_seconds: [''],      
      // payout_type: [''],      
      // payout_amount: [''],      
      // payout_trigger: [''],      
      // payout_seconds: [''],            
    });

    this.editLabelForm = this.fb.group({
      uuid: ['', ''],
      name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      notes: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      user_uuid: ['']
      // conversation_revenue: ['',Validators.required],      
      // conversation_event: ['',Validators.required],      
      // conversation_seconds: [''],      
      // payout_typeedit: [''],      
      // payout_amount: [''],      
      // payout_trigger: [''],      
      // payout_seconds: [''],            
    });
  }
  // payout_typevalue:any = 0;
  // payout_typeval(val:number) {
  //   this.payout_typevalue = val;
  // }
  // payout_typevalueedit:any = 0;
  // payout_typevaledit(val:number) {
  //   this.payout_typevalueedit = val;
  //   this.editLabelForm.get('payout_typeedit').setValue(val); 
  // }
  loadlabels() {
    if ($.fn.DataTable.isDataTable(this.table.nativeElement)) {
      $(this.table.nativeElement).dataTable().fnDestroy();
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    var that = this;
    this.dtOptions = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "pageLength": 500,
      "order": [[0, "asc"]],
      "lengthMenu": [10, 25, 50, 100, 500, 1000],
      ajax: (dataTablesParameters, callback) => {
        that.http.post(this.ServerUrl + 'getlabels/' + this.currentCompany.uuid, dataTablesParameters, {}).subscribe(resp => {
          // console.log(resp);
          that.labels = resp.data;
          //   setTimeout( function () {
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
          // }, 50 );
          var out = [];
          // for ( var i=0, ien=resp.data.length; i<ien ; i++ ) {
          //     out.push( [ i+'-1', i+'-2', i+'-3', i+'-4', i+'-5' ] );
          // }
          // for (let i = 0; i < resp.data.length; i++) {
          //   const name = resp.data[i].name;
          //   const notes = resp.data[i].notes;
          //   const noofnos = resp.data[i].noofnos;
          //   const created_at = resp.data[i].created_at;
          //   out.push([
          //     '',
          //     name,
          //     notes,
          //     noofnos,
          //     created_at,
          //     ''
          //   ]);
          // }
          // console.log(JSON.stringify(out)); 
          // console.log(resp.data); return false;
          // for ( var i=0, ien=0+resp.data.length ; i<ien ; i++ ) {
          //     out.push([ "name",i+'-1', i+'-2', i+'-3', i+'-4', i+'-5', i+'-6' ]);
          // }
          // console.log(resp.data);
          // console.log(out);
          // setTimeout( function () {
          //   callback( {
          //     draw: resp.draw,
          //     data: resp.data,
          //     recordsTotal: resp.recordsTotal,
          //     recordsFiltered: resp.recordsFiltered,
          // } );
          // callback({
          //         recordsTotal: resp.recordsTotal,
          //         recordsFiltered: resp.recordsFiltered,
          //         data: out,
          //         draw: resp.draw,
          //     });
          // }, 50 );
        });
      },

      // "deferRender":    true,
      "scrollY": 800,
      // "scrollCollapse": true,
      // ordering: false,
      // searching: false,
      // "scroller": {
      //     loadingIndicator: true
      // },
      columns: [{
        data: ""
      }, {
        data: "name"
      }, {
        data: "notes"
      }, {
        data: "noofnos"
      }, {
        data: "created_at"
      }, {
        data: ""
      }],
      columnDefs: [{
        "targets": [0],
        "orderable": false
      }]
    };
    this.dataTable = $(this.table.nativeElement);
    this.dataTable.dataTable(this.dtOptions);
  }
  Delete(uuid) {
    sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
      title: 'Are you sure?',
      text: 'You want to Delete Record!',
      showCancelButton: true,
      confirmButtonText: 'Yes, delete it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        let currentUser = JSON.parse(localStorage.getItem('currentUser'));
        this.moduleservice.deleteLabel(uuid, currentUser.uuid).subscribe(res => {
          // console.log(res);return false;
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Record Deleted Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
          this.loadlabels();
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
        }, 2000);
      }
    });
  }
  // recording:string;
  // get_recordingstatus(event:any){
  //   this.recording = event.target.checked;
  // }
  //Add Labels
  get labelcontrol() {
    return this.addLabelForm.controls;
  }
  onLabelSubmit() {
    const formData = new FormData();
    this.LabelSubmitted = true;
    if (this.addLabelForm.invalid) {
      return;
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    formData.append('user_uuid', currentUser.uuid);
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('name', this.addLabelForm.get('name').value);
    formData.append('notes', this.addLabelForm.get('notes').value);
    // formData.append('conversation_revenue', this.addLabelForm.get('conversation_revenue').value);
    // formData.append('conversation_event', this.addLabelForm.get('conversation_event').value);
    // formData.append('conversation_seconds', this.addLabelForm.get('conversation_seconds').value);
    // formData.append('payout_type', this.payout_typevalue);
    // formData.append('payout_amount', this.addLabelForm.get('payout_amount').value);
    // formData.append('payout_trigger', this.addLabelForm.get('payout_trigger').value);
    // formData.append('payout_seconds', this.addLabelForm.get('payout_seconds').value);
    // formData.append('is_recording', this.recording);
    // console.log(formData); return false;
    this.moduleservice.addLabel(formData).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Label Added Successfully');
        this.loadlabels();
        this.LabelSubmitted = false;
        this.isName = false;
      } else {
        this.toastrService.error('Failed To Add Label');
      }
    }, error => this.error = error);
  }
  closeModal() {
    if (this.addLabelForm.get('name').value && this.addLabelForm.get('notes').value) {
      $("#addLabels").modal("hide");
      $(".custom-switch-input").prop('checked', false);
      this.LabelSubmitted = false;
      setTimeout(() => {
        this.addLabelForm.reset();
        this.isName = "";
      }, 2000);
    }
    if (this.editLabelForm.get('name').value && this.editLabelForm.get('notes').value) {
      $("#editLabels").modal("hide");
      this.LabelSubmitted = false;
      setTimeout(() => {
        this.editLabelForm.reset();
        this.isName = "";
      }, 2000);
    }
  }
  editLabel(uuid, recording, name, notes) {
    // ,conversation_revenue:any,conversation_event:any,conversation_seconds:any,payout_type:any,payout_amount:any,payout_trigger:any,payout_seconds:any
    // alert(recording);
    // if(recording==1){
    //   this.recordingval = 1;
    // }else{
    //   this.recordingval = 0;
    // }
    // this.editpayout_typeval = payout_type;
    // this.payout_typevalueedit = payout_type;
    // console.log(this.editpayout_typeval);
    this.editLabelForm.patchValue({
      uuid: uuid,
      name: name,
      notes: notes
      // conversation_revenue: conversation_revenue,      
      // conversation_event: conversation_event,      
      // conversation_seconds: conversation_seconds,      
      // // payout_typeedit: payout_type,      
      // payout_amount: payout_amount,      
      // payout_trigger: payout_trigger,      
      // payout_seconds: payout_seconds,              
    });
  }

  get labeleditcontrol() {
    return this.editLabelForm.controls;
  }
  onLabelEditSubmit() {
    const formData = new FormData();
    if (this.editLabelForm.invalid) {
      return;
    }
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    formData.append('user_uuid', currentUser.uuid);
    formData.append('name', this.editLabelForm.get('name').value);
    formData.append('notes', this.editLabelForm.get('notes').value);
    // formData.append('conversation_revenue', this.editLabelForm.get('conversation_revenue').value);
    // formData.append('conversation_event', this.editLabelForm.get('conversation_event').value);
    // formData.append('conversation_seconds', this.editLabelForm.get('conversation_seconds').value);
    // formData.append('payout_typeedit',  this.payout_typevalueedit);
    // formData.append('payout_amount', this.editLabelForm.get('payout_amount').value);
    // formData.append('payout_trigger', this.editLabelForm.get('payout_trigger').value);
    // formData.append('payout_seconds', this.editLabelForm.get('payout_seconds').value);
    // formData.append('is_recording', this.recording);
    // console.log(this.editLabelForm.get('payout_typeedit').value); return false;
    this.moduleservice.editLabel(formData, this.editLabelForm.get('uuid').value).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.loadlabels();
        this.toastrService.success('Label Data Saved Successfully');
      } else {
        this.toastrService.error('Failed To Save Label Data');
      }
    }, error => this.error = error);
  }
  validatename() {
    if (this.addLabelForm.get('name').value != '') {
      this.moduleservice.validateLabelName(this.addLabelForm.get('name').value).subscribe(res => {
        // console.log(res); return false;  
        this.isName = res;
        if (this.isName.status == 'success') {
          this.isName = "success";
        } else {
          this.isName = "fail";
        }
      });
    } else {
      this.isName = "";
    }
  }
  exportdata() {
    var options = {
      fieldSeparator: ',',
      quoteStrings: '"',
      decimalseparator: '.',
      showLabels: true,
      // showTitle: true,
      // title: 'Your title',
      useBom: true,
      // noDownload: true,
      headers: ["Label Name", "Notes", "Created At"]
    };
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleservice.getLabelForExport(this.currentCompany.uuid).subscribe(res => {
      console.log(res);
      new ngx_csv_ngx_csv__WEBPACK_IMPORTED_MODULE_5__.ngxCsv(res.data, 'All Labels', options);
    }, error => this.error = error);
  }
  checkalldelete(event) {
    const checked = event.target.checked;
    this.labels.forEach(chkbox => chkbox.selected = checked);
  }
  deleteselected(event) {
    // $("#customCheck1").prop("checked", false);    
    if (event.target.checked == true) {
      if (event.target.value == 'on') {
        this.checkboxes = [];
        this.labels.forEach(lbl => {
          this.checkboxes.push(lbl.id);
        });
      } else {
        if (this.checkboxes.length + 1 == this.labels.length) {
          $("#customCheck1").prop("checked", true);
        }
        this.checkboxes.push(event.target.value);
      }
      this.ischecked = '0';
    } else {
      // console.log(this.checkboxes);      
      if (this.checkboxes.length != 0) {
        $("#customCheck1").prop("checked", false);
      }
      if (event.target.value != 'on') {
        const index = this.checkboxes.indexOf(event.target.value);
        this.checkboxes.splice(index, 1);
      } else {
        this.checkboxes = [];
      }
      this.ischecked = '1';
    }
    // console.log(this.checkboxes); 
  }

  onDeleteSubmit() {
    if (this.checkboxes.length == 0) {
      this.toastrService.error('Please Select Row To Delete');
    } else {
      // console.log(this.checkboxes);  
      sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
        title: 'Are you sure?',
        text: 'You want to Delete Selected Record!',
        showCancelButton: true,
        confirmButtonText: 'Yes, delete it!',
        cancelButtonText: 'No, keep it'
      }).then(result => {
        if (result.value) {
          this.moduleservice.deleteSelectedLabels(this.checkboxes).subscribe(res => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Records Deleted Successfully.');
            setTimeout(() => {
              sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
            }, 2000);
            this.loadlabels();
          }, error => this.error = error);
        } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
        }
      });
    }
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_8__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_6__.HttpBackend
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_7__.FormBuilder
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_9__.Title
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_10__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }]
  };
};
LabelComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_11__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_10__.Component)({
  selector: 'app-label',
  template: _label_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_label_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], LabelComponent);


/***/ }),

/***/ 86489:
/*!************************************************************!*\
  !*** ./src/app/modules/label/ngxdemo/ngxdemo.component.ts ***!
  \************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "NgxdemoComponent": () => (/* binding */ NgxdemoComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _ngxdemo_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./ngxdemo.component.html?ngResource */ 16890);
/* harmony import */ var _ngxdemo_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./ngxdemo.component.scss?ngResource */ 4023);
/* harmony import */ var _ngxdemo_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_ngxdemo_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _swimlane_ngx_datatable__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @swimlane/ngx-datatable */ 93143);
/* harmony import */ var ngx_ui_loader__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ngx-ui-loader */ 36413);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../global */ 27266);








let NgxdemoComponent = class NgxdemoComponent {
  constructor(handler, el, ngxLoader) {
    this.el = el;
    this.ngxLoader = ngxLoader;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_2__.GlobalVariable.BASE_API_URL;
    this.pageSize = 10;
    this.ColumnMode = _swimlane_ngx_datatable__WEBPACK_IMPORTED_MODULE_3__.ColumnMode;
    this.loadingIndicator = false;
    this.lists = [];
    this.headerHeight = 50;
    this.rowHeight = 50;
    this.pageLimit = 10;
    this.temp = [];
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_4__.HttpClient(handler);
  }
  ngOnInit() {
    this.searchBlogPosts();
  }
  searchBlogPosts() {
    this.blogPostsList = [];
    // this.loadingIndicator = true;
    this.ngxLoader.start();
    let currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.http.post(this.ServerUrl + 'getcompanydetailsbyuuid/' + currentCompany.uuid, {}).subscribe(resp => {
      this.blogPostsList = resp[0].Response.data;
      this.lists = resp[0].Response.data;
      // this.loadingIndicator = false;
      this.ngxLoader.stop();
      // console.log(this.blogPostsList);
    }, error => {
      this.loadingIndicator = false;
    });
  }
  loadPage(limit) {
    // console.log(limit);
    // set the loading flag, which serves two purposes:
    // 1) it prevents the same page from being loaded twice
    // 2) it enables display of the loading indicator
    // this.loadingIndicator = true;
    this.ngxLoader.start();
    let currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.http.post(this.ServerUrl + 'getcompanydetailsbyuuid/' + currentCompany.uuid + '/' + this.blogPostsList.length + '/' + limit, {}).subscribe(resp => {
      const rows = [...this.blogPostsList, ...resp[0].Response.data];
      this.blogPostsList = rows;
      this.lists = resp[0].Response.data;
      // this.loadingIndicator = false;
      this.ngxLoader.stop();
      // console.log(this.blogPostsList);
    }, error => {
      // this.loadingIndicator = false;
      this.ngxLoader.stop();
    });
  }
  onScroll(offsetY) {
    const viewHeight = this.el.nativeElement.getBoundingClientRect().height - this.headerHeight;
    // check if we scrolled to the end of the viewport
    // 
    if (!this.loadingIndicator && offsetY + viewHeight >= this.blogPostsList.length * this.rowHeight) {
      // total number of results to load
      let limit = this.pageLimit;
      // check if we haven't fetched any results yet
      if (this.blogPostsList.length === 0) {
        // calculate the number of rows that fit within viewport
        const pageSize = Math.ceil(viewHeight / this.rowHeight);
        // change the limit to pageSize such that we fill the first page entirely
        // (otherwise, we won't be able to scroll past it)
        limit = Math.max(pageSize, this.pageLimit);
      }
      this.loadPage(limit);
    }
  }
  updateFilter(event) {
    // console.log(event.target.value);
    const val = event.target.value.toLowerCase().trim();
    if (val) {
      // filter our data
      const temp = this.blogPostsList.filter(function (d) {
        return d.incoming_number.toLowerCase().indexOf(val) !== -1 || d.publisher.toLowerCase().indexOf(val) !== -1 || d.target.toLowerCase().indexOf(val) !== -1 || d.campaign.toLowerCase().indexOf(val) !== -1 || !val;
      });
      // console.log(val);
      this.blogPostsList = temp;
    } else {
      this.blogPostsList = this.lists;
    }
    this.table1.offset = 0;
  }
  getpage(event) {
    this.pageSize = event.target.value;
    // console.log(this.pageSize);
  }
  static #_ = this.ctorParameters = () => [{
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_4__.HttpBackend
  }, {
    type: _angular_core__WEBPACK_IMPORTED_MODULE_5__.ElementRef
  }, {
    type: ngx_ui_loader__WEBPACK_IMPORTED_MODULE_6__.NgxUiLoaderService
  }];
  static #_2 = this.propDecorators = {
    table1: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_5__.ViewChild,
      args: [_swimlane_ngx_datatable__WEBPACK_IMPORTED_MODULE_3__.DatatableComponent]
    }]
  };
};
NgxdemoComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_7__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_5__.Component)({
  selector: 'app-ngxdemo',
  template: _ngxdemo_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_ngxdemo_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], NgxdemoComponent);


/***/ }),

/***/ 93619:
/*!********************************************************!*\
  !*** ./src/app/modules/longlist/longlist.component.ts ***!
  \********************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "LonglistComponent": () => (/* binding */ LonglistComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _longlist_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./longlist.component.html?ngResource */ 36766);
/* harmony import */ var _longlist_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./longlist.component.scss?ngResource */ 55925);
/* harmony import */ var _longlist_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_longlist_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../module.service */ 22947);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../global */ 27266);
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! moment */ 56908);
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(moment__WEBPACK_IMPORTED_MODULE_4__);
/* harmony import */ var datatables_net__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! datatables.net */ 84375);
/* harmony import */ var datatables_net__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(datatables_net__WEBPACK_IMPORTED_MODULE_5__);











const router = _angular_router__WEBPACK_IMPORTED_MODULE_6__.Router;
class DataTablesResponse {}
let LonglistComponent = class LonglistComponent {
  constructor(moduleservice, handler, fb) {
    this.moduleservice = moduleservice;
    this.fb = fb;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_3__.GlobalVariable.BASE_API_URL;
    this.numbers = '';
    // maxDate: moment.Moment;
    // minDate: moment.Moment;
    // invalidDates: moment.Moment[] = [];
    this.ranges = {
      Today: [moment__WEBPACK_IMPORTED_MODULE_4__(), moment__WEBPACK_IMPORTED_MODULE_4__()],
      Yesterday: [moment__WEBPACK_IMPORTED_MODULE_4__().subtract(1, 'days'), moment__WEBPACK_IMPORTED_MODULE_4__().subtract(1, 'days')],
      'Last 7 Days': [moment__WEBPACK_IMPORTED_MODULE_4__().subtract(6, 'days'), moment__WEBPACK_IMPORTED_MODULE_4__()],
      'Last 30 Days': [moment__WEBPACK_IMPORTED_MODULE_4__().subtract(29, 'days'), moment__WEBPACK_IMPORTED_MODULE_4__()],
      'This Month': [moment__WEBPACK_IMPORTED_MODULE_4__().startOf('month'), moment__WEBPACK_IMPORTED_MODULE_4__().endOf('month')],
      'Last Month': [moment__WEBPACK_IMPORTED_MODULE_4__().subtract(1, 'month').startOf('month'), moment__WEBPACK_IMPORTED_MODULE_4__().subtract(1, 'month').endOf('month')]
    };
    this.dtOptions = {};
    this.submitted = false;
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_7__.HttpClient(handler);
    // this.maxDate = moment().add(2,  'weeks');
    // this.minDate = moment().subtract(3, 'days');
    this.alwaysShowCalendars = true;
    this.keepCalendarOpeningWithRange = true;
    this.showRangeLabelOnInput = true;
    this.selected = {
      startDate: moment__WEBPACK_IMPORTED_MODULE_4__().startOf('day'),
      endDate: moment__WEBPACK_IMPORTED_MODULE_4__().endOf('day')
    };
  }
  ngOnInit() {
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.loadcalls();
  }
  get f() {
    return this.searchcallsform.controls;
  }
  loadcalls() {
    if ($.fn.DataTable.isDataTable(this.table.nativeElement)) {
      $(this.table.nativeElement).dataTable().fnDestroy();
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.dtOptions = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "pageLength": 20,
      "order": [[1, "desc"]],
      ajax: (dataTablesParameters, callback) => {
        this.http.post(this.ServerUrl + 'getshortlonglistnumbers/' + this.currentCompany.uuid + '/1', {
          'dataTablesParameters': dataTablesParameters,
          'number': this.numbers,
          'date': this.selected
        }, {}).subscribe(resp => {
          // console.log(resp); return false;
          this.alldata = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [{
        data: "number"
      }, {
        data: "forward_to"
      }, {
        data: "created_at"
      }]
    };
    this.dataTable = $(this.table.nativeElement);
    this.dataTable.dataTable(this.dtOptions);
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_7__.HttpBackend
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_8__.FormBuilder
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_9__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }]
  };
};
LonglistComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_10__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_9__.Component)({
  selector: 'app-longlist',
  template: _longlist_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_longlist_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], LonglistComponent);


/***/ }),

/***/ 52354:
/*!**************************************************************************!*\
  !*** ./src/app/modules/mail-verification/mail-verification.component.ts ***!
  \**************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "MailVerificationComponent": () => (/* binding */ MailVerificationComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _mail_verification_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./mail-verification.component.html?ngResource */ 934);
/* harmony import */ var _mail_verification_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./mail-verification.component.scss?ngResource */ 54211);
/* harmony import */ var _mail_verification_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_mail_verification_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../module.service */ 22947);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ngx-toastr */ 94817);







//import 'sweetalert2/src/sweetalert2.scss'
let MailVerificationComponent = class MailVerificationComponent {
  constructor(moduleservice, toastrService, route, router) {
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.route = route;
    this.router = router;
    // this.http = new HttpClient(handler);
  }

  ngOnInit() {}
  //verify Publisher
  onSubmit() {
    const formData = new FormData();
    this.uuid = this.route.snapshot.paramMap.get('uuid');
    this.moduleservice.verifyEmail(1, this.uuid).subscribe(res => {
      // console.log(res.status); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Publisher Accounts Verified Successfully! Please Login to continue..');
        setTimeout(() => {
          this.router.navigate(['/login']);
        }, 2000);
      } else {
        this.toastrService.error('Failed To Verify Accounts or Already Verified..');
      }
    }, error => this.error = error);
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_3__.ToastrService
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_4__.ActivatedRoute
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_4__.Router
  }];
};
MailVerificationComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_5__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_6__.Component)({
  selector: 'app-mail-verification',
  template: _mail_verification_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_mail_verification_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], MailVerificationComponent);


/***/ }),

/***/ 30565:
/*!**********************************************!*\
  !*** ./src/app/modules/messaging.service.ts ***!
  \**********************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "MessagingService": () => (/* binding */ MessagingService)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var rxjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! rxjs */ 84505);



let MessagingService = class MessagingService {
  constructor() {
    this.currentMessage = new rxjs__WEBPACK_IMPORTED_MODULE_0__.BehaviorSubject(null);
  }
  static #_ = this.ctorParameters = () => [];
};
MessagingService = (0,tslib__WEBPACK_IMPORTED_MODULE_1__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_2__.Injectable)({
  providedIn: 'root'
})], MessagingService);


/***/ }),

/***/ 22947:
/*!*******************************************!*\
  !*** ./src/app/modules/module.service.ts ***!
  \*******************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "ModuleService": () => (/* binding */ ModuleService)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var rxjs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! rxjs */ 92218);
/* harmony import */ var rxjs__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! rxjs */ 66587);
/* harmony import */ var rxjs_BehaviorSubject__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! rxjs/BehaviorSubject */ 80371);
/* harmony import */ var rxjs_BehaviorSubject__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(rxjs_BehaviorSubject__WEBPACK_IMPORTED_MODULE_4__);
/* harmony import */ var rxjs_operators__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! rxjs/operators */ 47418);
/* harmony import */ var rxjs_operators__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! rxjs/operators */ 86942);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! .././global */ 27266);
/* harmony import */ var aws_sdk_clients_s3__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! aws-sdk/clients/s3 */ 24315);
/* harmony import */ var aws_sdk_clients_s3__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(aws_sdk_clients_s3__WEBPACK_IMPORTED_MODULE_1__);








let ModuleService = class ModuleService {
  constructor(handler, httpClient) {
    this.httpClient = httpClient;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_0__.GlobalVariable.BASE_API_URL;
    this.subjectName = new rxjs__WEBPACK_IMPORTED_MODULE_2__.Subject(); //need to create a subject
    this.httpOptions = {
      headers: new _angular_common_http__WEBPACK_IMPORTED_MODULE_3__.HttpHeaders({
        'Content-Type': 'application/json'
      })
    };
    // pass data
    this.numbersdata = new rxjs_BehaviorSubject__WEBPACK_IMPORTED_MODULE_4__.BehaviorSubject({
      // numberslist:this.numbers
    });
    this.FOLDER = 'ivr-audio/';
    this.Obj = this;
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_3__.HttpClient(handler);
  }
  // Menu Update Subject
  sendMenuUpdateMessage(message) {
    this.subjectName.next({
      text: message
    }); //next() will feed the value in Subject
  }

  getUpdate() {
    return this.subjectName.asObservable(); //it returns as an observable to which the receiver funtion will subscribe
  }

  setNumbersdata(numbers) {
    this.numbersdata.next(numbers);
  }
  getnumbersInfo() {
    return this.numbersdata.asObservable();
  }
  // private menudata = new BehaviorSubject<any>({
  //   // numberslist:this.numbers
  // });
  // setMenudata(numbers: any) {
  //   this.menudata.next(numbers);
  // }
  // getMenuInfo() {
  //   return this.menudata.asObservable();
  // }
  // Header
  getcallvalue(company_uuid, userdata) {
    return this.http.post(this.ServerUrl + 'getcallvalue/' + company_uuid, userdata).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getcompanydetailsbyuuid(uuid, role, user_uuid) {
    return this.http.get(this.ServerUrl + 'getcompanydetailsbyuuid/' + uuid + '/' + role + '/' + user_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getcompanydetailsbyuuid1(length, limit) {
    return this.http.get(this.ServerUrl + 'getcompanydetailsbyuuid1/' + length + '/' + limit).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  // Profile
  getProfiledata(company_uuid, userdata) {
    return this.http.post(this.ServerUrl + 'getProfiledata/' + company_uuid, userdata).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  editProfile(formData, company_uuid) {
    return this.http.post(this.ServerUrl + 'editProfile/' + company_uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  // Dashboard Module
  getNumberOfCount(company_uuid, timezone) {
    return this.http.post(this.ServerUrl + 'getNumberOfCount/' + company_uuid + '/', timezone).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getChartbyDate(company_uuid, params, timezone) {
    return this.http.post(this.ServerUrl + 'getChartNumberOfCalls/' + company_uuid + '/' + timezone + '/', params).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getChartbyfilter(company_uuid, chartarg, daytype, timezone) {
    // if(val==''){
    //   val = 0;
    // }
    return this.http.post(this.ServerUrl + 'getChartbyfilter/' + company_uuid + '/' + daytype + '/' + timezone + '/', chartarg).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getChartbyfilterforcomparison(company_uuid, chartarg, daytype, timezone) {
    // if(val==''){
    //   val = 0;
    // }
    return this.http.post(this.ServerUrl + 'getChartbyfilterforcomparison/' + company_uuid + '/' + daytype + '/' + timezone + '/', chartarg).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  // getChartNumberOfCalls(company_uuid: string,date:any) {
  //   return this.http.get<any>(this.ServerUrl + 'getChartNumberOfCalls/'+company_uuid).pipe(
  //     catchError(this.handleError)
  //   );
  // }
  // Buyer
  deleteBuyer(id, user_uuid) {
    return this.http.get(this.ServerUrl + 'deleteBuyer/' + id + '/' + user_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  addBuyer(formData) {
    return this.http.post(this.ServerUrl + 'addBuyer/', formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  editBuyer(formData) {
    return this.http.post(this.ServerUrl + 'editBuyer/', formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  // Publishers
  addPublisher(formData) {
    return this.http.post(this.ServerUrl + 'addPublisher/', formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  editPublisher(formData) {
    return this.http.post(this.ServerUrl + 'editPublisher/', formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  editNumberdata(formData) {
    return this.http.post(this.ServerUrl + 'editNumberdata/', formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  deletePublisher(id, user_uuid) {
    return this.http.get(this.ServerUrl + 'deletePublisher/' + id + '/' + user_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  loadNumbersfordropdown(company_uuid) {
    return this.http.get(this.ServerUrl + 'loadNumbersfordropdown/' + company_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  // Campaign
  addCampaign(company_uuid, formData) {
    return this.http.post(this.ServerUrl + 'addCampaign/' + company_uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  deleteCampaign(id) {
    return this.http.get(this.ServerUrl + 'deleteCampaign/' + id).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  changeCampaignstatus(id, status) {
    return this.http.get(this.ServerUrl + 'changeCampaignstatus/' + id + '/' + status).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getcampainbyuuid(uuid) {
    return this.http.get(this.ServerUrl + 'getcampainbyuuid/' + uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getallcampain(uuid) {
    return this.http.get(this.ServerUrl + 'getallcampain/' + uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getallcampaindata(uuid) {
    return this.http.get(this.ServerUrl + 'getallcampaindata/' + uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getallbuyers(uuid) {
    return this.http.get(this.ServerUrl + 'getallbuyers/' + uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getallusers(uuid, role) {
    return this.http.get(this.ServerUrl + 'getallusers/' + uuid + '/' + role).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  updateCampaign(uuid, company_uuid, formData) {
    return this.http.post(this.ServerUrl + 'updateCampaign/' + uuid + '/' + company_uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  addpublisherpayout(uuid, formData) {
    return this.http.post(this.ServerUrl + 'addpublisherpayout/' + uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  addpublishertocampaign(uuid, formData) {
    return this.http.post(this.ServerUrl + 'addpublishertocampaign/' + uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  adddefaultpayout(uuid, formData) {
    return this.http.post(this.ServerUrl + 'adddefaultpayout/' + uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  editRoutingSubmit(uuid, formData) {
    return this.http.post(this.ServerUrl + 'editRoutingSubmit/' + uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  change_routingplanval(uuid, val, type) {
    return this.http.post(this.ServerUrl + 'change_routingplanval/' + uuid + '/' + type, val).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  editIVRRoutingSubmit(uuid, formData) {
    return this.http.post(this.ServerUrl + 'editIVRRoutingSubmit/' + uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  setcampaignRouting(uuid, campaign_uuid, user_uuid) {
    return this.http.post(this.ServerUrl + 'setcampaignRouting/' + campaign_uuid + '/' + user_uuid, uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  setivrRouting(uuid, name, user_uuid, company_uuid) {
    return this.http.post(this.ServerUrl + 'setivrRouting/' + user_uuid + '/' + uuid + '/' + company_uuid, name).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getplanbyuuid(uuid) {
    return this.http.get(this.ServerUrl + 'getplanbyuuid/' + uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  addIVRPlan(user_uuid, company_uuid, formdata) {
    return this.http.post(this.ServerUrl + 'addIVRPlan/' + company_uuid + '/' + user_uuid, formdata).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  editIVRPlan(user_uuid, uuid, formdata) {
    return this.http.post(this.ServerUrl + 'editIVRPlan/' + uuid + '/' + user_uuid, formdata).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getpayoutdata(uuid, phone) {
    return this.http.post(this.ServerUrl + 'getpayoutdata/' + uuid, phone).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getpayoutbynumberuuid(uuid) {
    return this.http.get(this.ServerUrl + 'getpayoutbynumberuuid/' + uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  deleteRoutingPlan(uuid, user_uuid) {
    return this.http.get(this.ServerUrl + 'deleteRoutingPlan/' + uuid + '/' + user_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  deleteIVRRoutingPlan(uuid, user_uuid) {
    return this.http.get(this.ServerUrl + 'deleteIVRRoutingPlan/' + uuid + '/' + user_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  deletePublisherPayout(uuid) {
    return this.http.get(this.ServerUrl + 'deletePublisherPayout/' + uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  DeletePayoutNo(uuid, number_uuid) {
    return this.http.get(this.ServerUrl + 'deletePayoutNo/' + uuid + '/' + number_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  // Report
  savereport(formData) {
    return this.http.post(this.ServerUrl + 'savereport/', formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getAllsavedreport(company_uuid) {
    return this.http.post(this.ServerUrl + 'getAllsavedreport/', company_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getReportdetailsdata(row_uuid, company_uuid) {
    return this.http.post(this.ServerUrl + 'getReportdetailsdata/' + row_uuid, company_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getsavedreportsbyuuid(uuid) {
    return this.http.post(this.ServerUrl + 'getsavedreportsbyuuid/', uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  deleteSelectedSavedReport(uuid) {
    return this.http.post(this.ServerUrl + 'deleteSelectedSavedReport/', uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  // Number Module Start
  getnumberAssciatedlabels(company_uuid, number) {
    return this.http.post(this.ServerUrl + 'getnumberAssciatedlabels/' + company_uuid, number).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getTargetdata(uuid, company_uuid) {
    return this.http.get(this.ServerUrl + 'getTargetbyid/' + uuid + '/' + company_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getNumberForExport(company_uuid, labelname) {
    return this.http.post(this.ServerUrl + 'getNumberForExport/' + company_uuid, labelname).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  changeTargetStatus(activestatus, currentUseruuid, targetuuid) {
    return this.http.post(this.ServerUrl + 'changeTargetStatus/' + activestatus + '/' + targetuuid, currentUseruuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  updateTarget(formData, uuid) {
    return this.http.post(this.ServerUrl + 'updateTarget/' + uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  addTarget(formData) {
    return this.http.post(this.ServerUrl + 'addTarget/', formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  deleteSelectedNumbers(lblarr) {
    return this.http.post(this.ServerUrl + 'deleteSelectedNumbers/', lblarr).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  StatusChangeSelectedNumbers(lblarr) {
    return this.http.post(this.ServerUrl + 'StatusChangeSelectedNumbers/', lblarr).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  importNumber(formData) {
    return this.http.post(this.ServerUrl + 'importNumber/', formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  batcheditnos(formData) {
    return this.http.post(this.ServerUrl + 'batcheditnos/', formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  addFSLRules(formData, uid) {
    return this.http.post(this.ServerUrl + 'addFSLRules/' + uid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  addWeekdays(formData, uid) {
    return this.http.post(this.ServerUrl + 'addWeekdays/' + uid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  deleteWeekday(uuid) {
    return this.http.get(this.ServerUrl + 'deleteWeekday/' + uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  editWeekdays(formData, uuid) {
    return this.http.post(this.ServerUrl + 'editWeekdays/' + uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  loadallweekdays(company_uuid) {
    return this.http.get(this.ServerUrl + 'loadallweekdays/' + company_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  //
  getRecentRules(FSLRulesInsertID, company_uuid) {
    return this.http.post(this.ServerUrl + 'getRecentRules/' + company_uuid, FSLRulesInsertID).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getRulesByName(name, company_uuid) {
    return this.http.post(this.ServerUrl + 'getRecentRules/' + company_uuid, {
      name: name
    }).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getRulesByTargetuuid(target_uuid, company_uuid) {
    return this.http.post(this.ServerUrl + 'getRulesByTargetuuid/' + company_uuid, {
      target_uuid: target_uuid
    }).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getAllRules(company_uuid) {
    return this.http.get(this.ServerUrl + 'getAllRules/' + company_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  deleteNumber(id, user_uuid) {
    return this.http.get(this.ServerUrl + 'deleteNumber/' + id + '/' + user_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  cloneNumber(id, user_uuid, company_uuid) {
    return this.http.get(this.ServerUrl + 'cloneNumber/' + id + '/' + user_uuid + '/' + company_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  cloneRoutingPlan(id, user_uuid) {
    return this.http.get(this.ServerUrl + 'cloneRoutingPlan/' + id + '/' + user_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  cloneIVR(id, user_uuid) {
    return this.http.get(this.ServerUrl + 'cloneIVR/' + id + '/' + user_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  deleteFSLRules(uuid) {
    return this.http.get(this.ServerUrl + 'deleteFSLRules/' + uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  deleteFSLRulesbyname(name) {
    return this.http.get(this.ServerUrl + 'deleteFSLRulesbyname/' + name).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getFSLbyuuid(uuid) {
    return this.http.post(this.ServerUrl + 'getFSLbyuuid/', uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getselectednumbers(formData) {
    // console.log(uploadfile);return false;
    return this.http.post(this.ServerUrl + 'getselectednumbers/', formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  numberbatchedit(formData) {
    // console.log(uploadfile);return false;
    return this.http.post(this.ServerUrl + 'numberbatchedit/', formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  editFSLRules(formData, uid) {
    return this.http.post(this.ServerUrl + 'editFSLRules/' + uid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  // FSL Rule Name Validation
  validatename(name) {
    // alert(name);
    return this.http.post(this.ServerUrl + 'validatename/', {
      name: name
    }).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  // Label Module Start
  addLabel(formData) {
    return this.http.post(this.ServerUrl + 'addLabel/', formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  deleteLabel(uuid, usert_uuid) {
    // alert(uuid);
    return this.http.get(this.ServerUrl + 'deleteLabel/' + uuid + '/' + usert_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  deleteSelectedLabels(lblarr) {
    return this.http.post(this.ServerUrl + 'deleteSelectedLabels/', lblarr).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  editLabel(formData, uuid) {
    return this.http.post(this.ServerUrl + 'editLabel/' + uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getAllLabels(company_uuid) {
    return this.http.get(this.ServerUrl + 'getAllLabels/' + company_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getLabelForExport(company_uuid) {
    return this.http.get(this.ServerUrl + 'getLabelForExport/' + company_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  validateLabelName(name) {
    // alert(name);
    return this.http.post(this.ServerUrl + 'validateLabelName/', {
      name: name
    }).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  validateTargetName(name, company_uuid) {
    // alert(name);
    return this.http.post(this.ServerUrl + 'validateTargetName/', {
      name: name,
      company_uuid: company_uuid
    }).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  validateCampaignName(name) {
    // alert(name);
    return this.http.post(this.ServerUrl + 'validateCampaignName/', {
      name: name
    }).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  // Notes Module Start
  addNotes(formData, company_uuid) {
    return this.http.post(this.ServerUrl + 'addNotes/' + company_uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getNotesdata(company_uuid) {
    return this.http.get(this.ServerUrl + 'getNotesdata/' + company_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  // IVR Menu
  deleteIVRMenu(uuid, user_uuid) {
    return this.http.get(this.ServerUrl + 'deleteIVRMenu/' + uuid + '/' + user_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  deleteSelectedIVR(arr) {
    return this.http.post(this.ServerUrl + 'deleteSelectedIVR/', arr).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getIVRMenus(company_uuid) {
    return this.http.get(this.ServerUrl + 'getIVRMenuname/' + company_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getIVRAudio(company_uuid, type) {
    return this.http.get(this.ServerUrl + 'getIVRAudio/' + company_uuid + '/' + type).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  addIVR(formData, uuid) {
    return this.http.post(this.ServerUrl + 'addIVR/' + uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  addemail(formData, uuid) {
    return this.http.post(this.ServerUrl + 'addEmailID/' + uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getivrdata(uuid) {
    return this.http.get(this.ServerUrl + 'getivrbyuuid/' + uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  // Rule Set
  addRuleSet(formData, uuid) {
    return this.http.post(this.ServerUrl + 'addRuleSet/' + uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getruledata(uuid, company_uuid) {
    return this.http.get(this.ServerUrl + 'getruledata/' + uuid + '/' + company_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  editRuleSet(formData, company_uuid, uuid) {
    return this.http.post(this.ServerUrl + 'editRuleSet/' + company_uuid + '/' + uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  deleteRuleset(uuid) {
    return this.http.get(this.ServerUrl + 'deleteRuleset/' + uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  // Dynamic Parameter
  addDyPara(formData, uuid) {
    return this.http.post(this.ServerUrl + 'addDyPara/' + uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getDynParadata(uuid) {
    return this.http.get(this.ServerUrl + 'getDynParadata/' + uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  // Verification Management
  getRules(company_uuid) {
    return this.http.get(this.ServerUrl + 'getRulesName/' + company_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  GetIVRnamedata(company_uuid) {
    return this.http.get(this.ServerUrl + 'GetIVRnamedata/' + company_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  GetEmails(company_uuid) {
    return this.http.get(this.ServerUrl + 'GetEmails/' + company_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  addEmail(formData, uuid) {
    return this.http.post(this.ServerUrl + 'addEmail/' + uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  addWildcard(formData, uuid) {
    return this.http.post(this.ServerUrl + 'addWildcard/' + uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getWildcard(company_uuid) {
    return this.http.get(this.ServerUrl + 'getWildcard/' + company_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  addVerificationRuleSet(formData, uuid) {
    return this.http.post(this.ServerUrl + 'addVerificationRuleSet/' + uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getverificationruledata(company_uuid) {
    return this.http.get(this.ServerUrl + 'getverificationruledata/' + company_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  editWildcard(formData, company_uuid) {
    return this.http.post(this.ServerUrl + 'editWildcard/' + company_uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  editEmail(formData, company_uuid) {
    return this.http.post(this.ServerUrl + 'editEmail/' + company_uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  addZipcode(formData, uuid) {
    return this.http.post(this.ServerUrl + 'addZipcode/' + uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getallzipcode(uuid, target_uuid) {
    return this.http.get(this.ServerUrl + 'getallzipcode/' + uuid + '/' + target_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  uploadfile(file, uuid, type) {
    const bucket = new aws_sdk_clients_s3__WEBPACK_IMPORTED_MODULE_1__({
      accessKeyId: 'AKIA6GBFL5HD7YNVODHR',
      secretAccessKey: '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',
      region: 'us-west-1'
    });
    const params = {
      Bucket: 'dialdigit2',
      Key: this.FOLDER + file.name,
      Body: file,
      ACL: ''
    };
    // console.log(bucket);return
    // bucket.upload(params, function (err, data) {
    //     if (err) {
    //         console.log('There was an error uploading your file: ', err);
    //         return false;
    //     }
    //     // console.log('Successfully uploaded file.', data);
    //     return true;
    // });
    //for upload progress
    // bucket.upload(params).on('httpUploadProgress', function (evt) {
    //           console.log(evt.loaded + ' of ' + evt.total + ' Bytes');
    //       }).send(function (err, data) {
    //           if (err) {
    //               console.log('There was an error uploading your file: ', err);
    //               return false;
    //           }
    //           console.log('Successfully uploaded file.', data);
    //           return data;
    //     });
    const formData = new FormData();
    formData.append('fileKey', file.name);
    formData.append('Bucket', 'dialdigit2');
    formData.append('ETag', '0c481e87f2774b1bd41a0a70d9b70d11');
    formData.append('Key', 'ivr-audio/' + file.name);
    formData.append('type', file.type);
    formData.append('Folder', 'ivr-audio/');
    formData.append('Location', 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/' + file.name);
    return this.http.post(this.ServerUrl + 'add_audio/' + uuid + '/' + type, formData, {
      reportProgress: true,
      observe: 'events'
    }).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_6__.map)(event => {
      // console.log(event); return false;
      bucket.upload(params, function (err, data) {
        if (err) {
          // console.log('There was an error uploading your file: ', err);
          return false;
        }
        // console.log('Successfully uploaded file.', data);
        return true;
      });
      switch (event.type) {
        case _angular_common_http__WEBPACK_IMPORTED_MODULE_3__.HttpEventType.UploadProgress:
          const progress = Math.round(100 * event.loaded / event.total);
          // console.log(progress);
          this.resp = {
            status: 'progress',
            message: progress
          };
          break;
        case _angular_common_http__WEBPACK_IMPORTED_MODULE_3__.HttpEventType.Response:
          this.resp = event;
          break;
        default:
          this.resp = `Unhandled event: ${event.type}`;
          break;
      }
      return this.resp;
    }));
  }
  // add_audio(file){
  //   // console.log(file);return false;
  //     return this.http.post<any>(this.ServerUrl + 'add_audio/', file)
  //     .pipe(
  //       catchError(this.handleError)
  //     );
  // }
  add_audio(fileToUpload) {
    const formData = new FormData();
    formData.append('fileKey', fileToUpload, fileToUpload.name);
    return this.http.post(this.ServerUrl + 'add_audio/', formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  updateIVR(formData, uuid) {
    return this.http.post(this.ServerUrl + 'updateIVR/' + uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  // White and Black List Numbers
  deleteListNumber(uuid, type) {
    return this.http.get(this.ServerUrl + 'deleteListNumber/' + uuid + '/' + type).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  deletewbSelectedNumbers(lblarr, type) {
    return this.http.post(this.ServerUrl + 'deletewbSelectedNumbers/' + type, lblarr).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  addNumberlist(formData) {
    return this.http.post(this.ServerUrl + 'addNumberlist/', formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  editNumberList(formData, uuid) {
    return this.http.post(this.ServerUrl + 'editNumberList/' + uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  // Audible Ring
  deleteAudibleRingNumber(uuid) {
    return this.http.get(this.ServerUrl + 'deleteAudibleRingNumber/' + uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getallnumbers(company_uuid) {
    return this.http.get(this.ServerUrl + 'getallnumbers/' + company_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  addExceptionNumber(formData) {
    return this.http.post(this.ServerUrl + 'addExceptionNumber/', formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  // Reports
  getCallsForExport(company_uuid) {
    return this.http.get(this.ServerUrl + 'getCallsForExport/' + company_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getCalldetailsForExport(company_uuid, formData) {
    return this.http.post(this.ServerUrl + 'getCalldetailsForExport/' + company_uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getCallReports(formdata, company_uuid) {
    return this.http.post(this.ServerUrl + 'getCallReports/' + company_uuid, formdata).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getLabelReports(formdata, company_uuid) {
    return this.http.post(this.ServerUrl + 'getLabelReports/' + company_uuid, formdata).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  // SMS
  getsmsForExport(company_uuid) {
    return this.http.get(this.ServerUrl + 'getsmsForExport/' + company_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  // NumberModule
  getAllpublishers(company_uuid) {
    return this.http.get(this.ServerUrl + 'getAllpublishers/' + company_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getAllpublisherssetting(company_uuid) {
    return this.http.get(this.ServerUrl + 'getAllpublisherssetting/' + company_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  addPublisherSettingdata(formData) {
    return this.http.post(this.ServerUrl + 'addPublisherSettingdata/', formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  purchase_number(uuid, formData) {
    return this.http.post(this.ServerUrl + 'purchase_number/', formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  // Number pool
  addNumberpooldata(formData) {
    return this.http.post(this.ServerUrl + 'addNumberpooldata/', formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  deleteNumberpooldata(uuid, user_uuid) {
    return this.http.get(this.ServerUrl + 'deleteNumberpooldata/' + uuid + '/' + user_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  editNumberpooldata(formData) {
    return this.http.post(this.ServerUrl + 'editNumberpooldata/', formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  // Basic Settings
  getAllbasicsetting(company_uuid) {
    return this.http.get(this.ServerUrl + 'getAllbasicsetting/' + company_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  addBasicSettingdata(formData) {
    return this.http.post(this.ServerUrl + 'addBasicSettingdata/', formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  addPublisherRegistration(formData) {
    return this.http.post(this.ServerUrl + 'addPublisherRegistration/', formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  verifyEmail(type, uuid) {
    return this.http.post(this.ServerUrl + 'verifyEmail/' + type, uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  addNumberdata(formData) {
    return this.http.post(this.ServerUrl + 'addNumberdata/', formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  deleteNumberdata(id, user_uuid) {
    // alert(id);
    return this.http.get(this.ServerUrl + 'deleteNumberdata/' + id + '/' + user_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  DeletePurNumber(no) {
    // alert(id);
    return this.http.post(this.ServerUrl + 'DeletePurNumber/', no).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getAlltarget(company_uuid) {
    return this.http.post(this.ServerUrl + 'getAlltarget/' + company_uuid, "").pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getNumberdatabyno(number, company_uuid, type = 0) {
    return this.http.get(this.ServerUrl + 'getNumberdatabyno/' + number + '/' + company_uuid + '/' + type).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getAlltargetbybuyer(company_uuid, role, user_uuid, buyer_uuids) {
    return this.http.post(this.ServerUrl + 'getAlltarget/' + company_uuid + '/' + role + '/' + user_uuid, buyer_uuids).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  allivrroutingplan(company_uuid) {
    return this.http.get(this.ServerUrl + 'allivrroutingplan/' + company_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getcitystatevalue(uuid, citystatetypeval) {
    return this.http.post(this.ServerUrl + 'getcitystatevalue/' + uuid, citystatetypeval).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  loadcitystate(type, datatype) {
    return this.http.post(this.ServerUrl + 'loadcitystate/' + datatype, type).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  loadcity(type) {
    return this.http.post(this.ServerUrl + 'loadcity/', type).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  // Blocked Numbers
  deleteblckedno(uuid) {
    // alert(uuid);
    return this.http.get(this.ServerUrl + 'deleteblckedno/' + uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  addblockedcalls(formData, company_uuid) {
    return this.http.post(this.ServerUrl + 'addblockedcalls/' + company_uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  adjust_call(formData, company_uuid) {
    return this.http.post(this.ServerUrl + 'adjust_call/' + company_uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  editblockednumbers(formData, uuid) {
    return this.http.post(this.ServerUrl + 'editblockednumbers/' + uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  // Add User
  addUser(formData) {
    return this.http.post(this.ServerUrl + 'addUser/', formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  deleteUser(id, user_uuid) {
    return this.http.get(this.ServerUrl + 'deleteUser/' + id + '/' + user_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  // Company Management
  addCompany(formData) {
    return this.http.post(this.ServerUrl + 'addCompany/', formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  editCompany(formData, uuid) {
    return this.http.post(this.ServerUrl + 'updateCompany/' + uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  deleteCompany(id) {
    return this.http.get(this.ServerUrl + 'deleteCompany/' + id).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getTagetdetailsdata(row_uuid, company_uuid) {
    return this.http.post(this.ServerUrl + 'getTagetdetailsdata/' + row_uuid, company_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  checkcompanyavail(company_uuid) {
    return this.http.post(this.ServerUrl + 'checkcompanyavail/', company_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  // offersection
  addOffer(formData) {
    return this.http.post(this.ServerUrl + 'addOffer/', formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  apply_offer(formData) {
    return this.http.post(this.ServerUrl + 'apply_offer/', formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  changeofferstatus(uuid, status) {
    return this.http.get(this.ServerUrl + 'changeofferstatus/' + uuid + '/' + status).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  approverejoffer(uuid, status) {
    return this.http.get(this.ServerUrl + 'approverejoffer/' + uuid + '/' + status).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  hideoffer(uuid, user_uuid, status) {
    return this.http.get(this.ServerUrl + 'hideoffer/' + uuid + '/' + user_uuid + '/' + status).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  // Get Timezone
  gettimezone() {
    return this.http.get(this.ServerUrl + 'gettimezone/').pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  // get tasks
  loadtasks(company_uuid) {
    return this.http.post(this.ServerUrl + 'loadtasks/' + company_uuid, "").pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  approvestatus(company_uuid) {
    return this.http.post(this.ServerUrl + 'loadtasks/' + company_uuid, "").pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  approvepayoutstatus(data, user_uuid, status) {
    return this.http.post(this.ServerUrl + 'approvepayoutstatus/' + status + '/' + user_uuid, data).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  // Predictive Routing
  addPredictiveRouting(formData, uuid) {
    return this.http.post(this.ServerUrl + 'addPredictiveRouting/' + uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  deletePredictiveRouting(uuid, user_uuid) {
    return this.http.get(this.ServerUrl + 'deletePredictiveRouting/' + uuid + '/' + user_uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getpredictiveroutingdata(uuid) {
    return this.http.get(this.ServerUrl + 'getpredictiveroutingdata/' + uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  getpredictiverouting(uuid) {
    return this.http.get(this.ServerUrl + 'getpredictiveroutingnames/' + uuid).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  updatePredictiveRouting(uuid, company_uuid, formData) {
    return this.http.post(this.ServerUrl + 'updatePredictiveRouting/' + uuid + '/' + company_uuid, formData).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_5__.catchError)(this.handleError));
  }
  // Error Handler Start
  handleError(error) {
    if (error.error instanceof ErrorEvent) {
      console.error('An error occurred:', error.error.message);
    } else {
      console.error(`Backend returned code ${error.status}, ` + `body was: ${error.error}`);
    }
    this.errorData = {
      errorTitle: 'Oops! Request for document failed',
      errorDesc: 'Something bad happened. Please try again later.'
    };
    return (0,rxjs__WEBPACK_IMPORTED_MODULE_7__.throwError)(this.errorData);
  }
  static #_ = this.ctorParameters = () => [{
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_3__.HttpBackend
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_3__.HttpClient
  }];
};
ModuleService = (0,tslib__WEBPACK_IMPORTED_MODULE_8__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_9__.Injectable)({
  providedIn: 'root'
})], ModuleService);


/***/ }),

/***/ 34555:
/*!***************************************************!*\
  !*** ./src/app/modules/modules-routing.module.ts ***!
  \***************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "ModulesRoutingModule": () => (/* binding */ ModulesRoutingModule)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_59__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _campaigns_campaign_view_campaign_view_component__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./campaigns/campaign-view/campaign-view.component */ 51086);
/* harmony import */ var _publishers_thankyou_thankyou_component__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./publishers/thankyou/thankyou.component */ 49377);
/* harmony import */ var _voicemail_voicemail_component__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./voicemail/voicemail.component */ 29032);
/* harmony import */ var _auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./../auth/auth.guard */ 3870);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_60__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_61__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_62__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _auth_profile_profile_component__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../auth/profile/profile.component */ 96499);
/* harmony import */ var _number_number_component__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./number/number.component */ 47760);
/* harmony import */ var _number_numberadd_numberadd_component__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./number/numberadd/numberadd.component */ 11722);
/* harmony import */ var _number_numberedit_numberedit_component__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./number/numberedit/numberedit.component */ 63092);
/* harmony import */ var _number_number_upload_number_upload_component__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./number/number-upload/number-upload.component */ 11724);
/* harmony import */ var _number_number_batchedit_number_batchedit_component__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./number/number-batchedit/number-batchedit.component */ 84359);
/* harmony import */ var _number_number_addfslrules_number_addfslrules_component__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ./number/number-addfslrules/number-addfslrules.component */ 26736);
/* harmony import */ var _label_label_component__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ./label/label.component */ 92751);
/* harmony import */ var _label_label_view_label_view_component__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ./label/label-view/label-view.component */ 82714);
/* harmony import */ var _dashboard_dashboard_component__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ./dashboard/dashboard.component */ 6957);
/* harmony import */ var _notes_notes_component__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! ./notes/notes.component */ 44892);
/* harmony import */ var _ivr_menus_ivr_menus_component__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! ./ivr-menus/ivr-menus.component */ 192);
/* harmony import */ var _ivr_menus_add_ivrmenu_add_ivrmenu_component__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! ./ivr-menus/add-ivrmenu/add-ivrmenu.component */ 83770);
/* harmony import */ var _ivr_menus_edit_ivrmenu_edit_ivrmenu_component__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! ./ivr-menus/edit-ivrmenu/edit-ivrmenu.component */ 42926);
/* harmony import */ var _rules_rules_component__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(/*! ./rules/rules.component */ 46315);
/* harmony import */ var _rules_rulesadd_rulesadd_component__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(/*! ./rules/rulesadd/rulesadd.component */ 34904);
/* harmony import */ var _rules_rulesedit_rulesedit_component__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(/*! ./rules/rulesedit/rulesedit.component */ 73692);
/* harmony import */ var _modules_dynamic_parameter_dynamic_parameter_component__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__(/*! ../modules/dynamic-parameter/dynamic-parameter.component */ 27393);
/* harmony import */ var _blacklist_blacklist_component__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(/*! ./blacklist/blacklist.component */ 15805);
/* harmony import */ var _whitelist_whitelist_component__WEBPACK_IMPORTED_MODULE_23__ = __webpack_require__(/*! ./whitelist/whitelist.component */ 45520);
/* harmony import */ var _reports_reports_component__WEBPACK_IMPORTED_MODULE_24__ = __webpack_require__(/*! ./reports/reports.component */ 15574);
/* harmony import */ var _reports_report_calls_report_calls_component__WEBPACK_IMPORTED_MODULE_25__ = __webpack_require__(/*! ./reports/report-calls/report-calls.component */ 55761);
/* harmony import */ var _reports_report_labelsummary_report_labelsummary_component__WEBPACK_IMPORTED_MODULE_26__ = __webpack_require__(/*! ./reports/report-labelsummary/report-labelsummary.component */ 4463);
/* harmony import */ var _verification_management_verification_management_component__WEBPACK_IMPORTED_MODULE_27__ = __webpack_require__(/*! ./verification-management/verification-management.component */ 21178);
/* harmony import */ var _audible_ring_audible_ring_component__WEBPACK_IMPORTED_MODULE_28__ = __webpack_require__(/*! ./audible-ring/audible-ring.component */ 21526);
/* harmony import */ var _shortlist_shortlist_component__WEBPACK_IMPORTED_MODULE_29__ = __webpack_require__(/*! ./shortlist/shortlist.component */ 26516);
/* harmony import */ var _longlist_longlist_component__WEBPACK_IMPORTED_MODULE_30__ = __webpack_require__(/*! ./longlist/longlist.component */ 93619);
/* harmony import */ var _sms_sms_component__WEBPACK_IMPORTED_MODULE_31__ = __webpack_require__(/*! ./sms/sms.component */ 44321);
/* harmony import */ var _recordings_recordings_component__WEBPACK_IMPORTED_MODULE_32__ = __webpack_require__(/*! ./recordings/recordings.component */ 54577);
/* harmony import */ var _number_number_buyer_number_buyer_component__WEBPACK_IMPORTED_MODULE_33__ = __webpack_require__(/*! ./number/number-buyer/number-buyer.component */ 91522);
/* harmony import */ var _publishers_publishers_component__WEBPACK_IMPORTED_MODULE_34__ = __webpack_require__(/*! ./publishers/publishers.component */ 64617);
/* harmony import */ var _campaigns_campaigns_component__WEBPACK_IMPORTED_MODULE_35__ = __webpack_require__(/*! ./campaigns/campaigns.component */ 78007);
/* harmony import */ var _campaigns_campaign_create_campaign_create_component__WEBPACK_IMPORTED_MODULE_36__ = __webpack_require__(/*! ./campaigns/campaign-create/campaign-create.component */ 96658);
/* harmony import */ var _numbers_numbers_component__WEBPACK_IMPORTED_MODULE_37__ = __webpack_require__(/*! ./numbers/numbers.component */ 13224);
/* harmony import */ var _numbers_number_pool_number_pool_component__WEBPACK_IMPORTED_MODULE_38__ = __webpack_require__(/*! ./numbers/number-pool/number-pool.component */ 25700);
/* harmony import */ var _numbers_blocked_numbers_blocked_numbers_component__WEBPACK_IMPORTED_MODULE_39__ = __webpack_require__(/*! ./numbers/blocked-numbers/blocked-numbers.component */ 85351);
/* harmony import */ var _campaigns_campaign_edit_campaign_edit_component__WEBPACK_IMPORTED_MODULE_40__ = __webpack_require__(/*! ./campaigns/campaign-edit/campaign-edit.component */ 84155);
/* harmony import */ var _settings_manage_users_manage_users_component__WEBPACK_IMPORTED_MODULE_41__ = __webpack_require__(/*! ./settings/manage-users/manage-users.component */ 57632);
/* harmony import */ var _settings_basic_setting_basic_setting_component__WEBPACK_IMPORTED_MODULE_42__ = __webpack_require__(/*! ./settings/basic-setting/basic-setting.component */ 76251);
/* harmony import */ var _publishers_publisher_settings_publisher_settings_component__WEBPACK_IMPORTED_MODULE_43__ = __webpack_require__(/*! ./publishers/publisher-settings/publisher-settings.component */ 80301);
/* harmony import */ var _publishers_publisher_terms_publisher_terms_component__WEBPACK_IMPORTED_MODULE_44__ = __webpack_require__(/*! ./publishers/publisher-terms/publisher-terms.component */ 75102);
/* harmony import */ var _publishers_advertiser_terms_advertiser_terms_component__WEBPACK_IMPORTED_MODULE_45__ = __webpack_require__(/*! ./publishers/advertiser-terms/advertiser-terms.component */ 61312);
/* harmony import */ var _settings_alert_configuration_alert_configuration_component__WEBPACK_IMPORTED_MODULE_46__ = __webpack_require__(/*! ./settings/alert-configuration/alert-configuration.component */ 32279);
/* harmony import */ var _settings_manage_company_manage_company_component__WEBPACK_IMPORTED_MODULE_47__ = __webpack_require__(/*! ./settings/manage-company/manage-company.component */ 78376);
/* harmony import */ var _changelog_changelog_component__WEBPACK_IMPORTED_MODULE_48__ = __webpack_require__(/*! ./changelog/changelog.component */ 97316);
/* harmony import */ var _ivr_menus_ivr_routing_plans_ivr_routing_plans_component__WEBPACK_IMPORTED_MODULE_49__ = __webpack_require__(/*! ./ivr-menus/ivr-routing-plans/ivr-routing-plans.component */ 24066);
/* harmony import */ var _ivr_menus_ivr_routing_plans_add_plan_add_plan_component__WEBPACK_IMPORTED_MODULE_50__ = __webpack_require__(/*! ./ivr-menus/ivr-routing-plans/add-plan/add-plan.component */ 69039);
/* harmony import */ var _ivr_menus_ivr_routing_plans_edit_plan_edit_plan_component__WEBPACK_IMPORTED_MODULE_51__ = __webpack_require__(/*! ./ivr-menus/ivr-routing-plans/edit-plan/edit-plan.component */ 71352);
/* harmony import */ var _mail_verification_mail_verification_component__WEBPACK_IMPORTED_MODULE_52__ = __webpack_require__(/*! ./mail-verification/mail-verification.component */ 52354);
/* harmony import */ var _label_ngxdemo_ngxdemo_component__WEBPACK_IMPORTED_MODULE_53__ = __webpack_require__(/*! ./label/ngxdemo/ngxdemo.component */ 86489);
/* harmony import */ var _reports_comparison_reports_comparison_component__WEBPACK_IMPORTED_MODULE_54__ = __webpack_require__(/*! ./reports-comparison/reports-comparison.component */ 41740);
/* harmony import */ var _tasks_tasks_component__WEBPACK_IMPORTED_MODULE_55__ = __webpack_require__(/*! ./tasks/tasks.component */ 5601);
/* harmony import */ var _settings_predictive_routing_predictive_routing_component__WEBPACK_IMPORTED_MODULE_56__ = __webpack_require__(/*! ./settings/predictive-routing/predictive-routing.component */ 74982);
/* harmony import */ var _settings_predictive_routing_add_routing_add_routing_component__WEBPACK_IMPORTED_MODULE_57__ = __webpack_require__(/*! ./settings/predictive-routing/add-routing/add-routing.component */ 64943);
/* harmony import */ var _settings_predictive_routing_edit_routing_edit_routing_component__WEBPACK_IMPORTED_MODULE_58__ = __webpack_require__(/*! ./settings/predictive-routing/edit-routing/edit-routing.component */ 57977);































































const routes = [{
  path: '',
  component: _dashboard_dashboard_component__WEBPACK_IMPORTED_MODULE_13__.DashboardComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
},
// Profile
{
  path: 'profile',
  component: _auth_profile_profile_component__WEBPACK_IMPORTED_MODULE_4__.ProfileComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
},
// Target Module  
{
  path: 'target',
  component: _number_number_component__WEBPACK_IMPORTED_MODULE_5__.NumberComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'numbers-import/:id',
  component: _number_number_upload_number_upload_component__WEBPACK_IMPORTED_MODULE_8__.NumberUploadComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'add-target',
  component: _number_numberadd_numberadd_component__WEBPACK_IMPORTED_MODULE_6__.NumberaddComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'edit-numbers/:id',
  component: _number_numberedit_numberedit_component__WEBPACK_IMPORTED_MODULE_7__.NumbereditComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'batch-edit',
  component: _number_number_batchedit_number_batchedit_component__WEBPACK_IMPORTED_MODULE_9__.NumberBatcheditComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'buyer',
  component: _number_number_buyer_number_buyer_component__WEBPACK_IMPORTED_MODULE_33__.NumberBuyerComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'add-weekdays',
  component: _number_number_addfslrules_number_addfslrules_component__WEBPACK_IMPORTED_MODULE_10__.NumberAddfslrulesComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'labels',
  component: _label_label_component__WEBPACK_IMPORTED_MODULE_11__.LabelComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'labels/view/:labelname',
  component: _label_label_view_label_view_component__WEBPACK_IMPORTED_MODULE_12__.LabelViewComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'notes',
  component: _notes_notes_component__WEBPACK_IMPORTED_MODULE_14__.NotesComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'ivr-menu',
  component: _ivr_menus_ivr_menus_component__WEBPACK_IMPORTED_MODULE_15__.IvrMenusComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'new-ivr-menu',
  component: _ivr_menus_add_ivrmenu_add_ivrmenu_component__WEBPACK_IMPORTED_MODULE_16__.AddIVRMenuComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'edit-ivr/:id',
  component: _ivr_menus_edit_ivrmenu_edit_ivrmenu_component__WEBPACK_IMPORTED_MODULE_17__.EditIvrmenuComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'ivr-routing-plans',
  component: _ivr_menus_ivr_routing_plans_ivr_routing_plans_component__WEBPACK_IMPORTED_MODULE_49__.IVRRoutingPlansComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'ivrplan-add',
  component: _ivr_menus_ivr_routing_plans_add_plan_add_plan_component__WEBPACK_IMPORTED_MODULE_50__.AddPlanComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'ivrplan-edit/:id',
  component: _ivr_menus_ivr_routing_plans_edit_plan_edit_plan_component__WEBPACK_IMPORTED_MODULE_51__.EditPlanComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'rules',
  component: _rules_rules_component__WEBPACK_IMPORTED_MODULE_18__.RulesComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'add-rule',
  component: _rules_rulesadd_rulesadd_component__WEBPACK_IMPORTED_MODULE_19__.RulesaddComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'edit-rule/:id',
  component: _rules_rulesedit_rulesedit_component__WEBPACK_IMPORTED_MODULE_20__.RuleseditComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'dynamic-forwarding-parameters',
  component: _modules_dynamic_parameter_dynamic_parameter_component__WEBPACK_IMPORTED_MODULE_21__.DynamicParameterComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'blacklist',
  component: _blacklist_blacklist_component__WEBPACK_IMPORTED_MODULE_22__.BlacklistComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'whitelist',
  component: _whitelist_whitelist_component__WEBPACK_IMPORTED_MODULE_23__.WhitelistComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'reports',
  component: _reports_reports_component__WEBPACK_IMPORTED_MODULE_24__.ReportsComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'reports/:id',
  component: _reports_reports_component__WEBPACK_IMPORTED_MODULE_24__.ReportsComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'call-reports',
  component: _reports_report_calls_report_calls_component__WEBPACK_IMPORTED_MODULE_25__.ReportCallsComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'call-reports-labelsummary',
  component: _reports_report_labelsummary_report_labelsummary_component__WEBPACK_IMPORTED_MODULE_26__.ReportLabelsummaryComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'comparison-reports',
  component: _reports_comparison_reports_comparison_component__WEBPACK_IMPORTED_MODULE_54__.ReportsComparisonComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'shortlist',
  component: _shortlist_shortlist_component__WEBPACK_IMPORTED_MODULE_29__.ShortlistComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'longlist',
  component: _longlist_longlist_component__WEBPACK_IMPORTED_MODULE_30__.LonglistComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'verification-management',
  component: _verification_management_verification_management_component__WEBPACK_IMPORTED_MODULE_27__.VerificationManagementComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'audible-ring',
  component: _audible_ring_audible_ring_component__WEBPACK_IMPORTED_MODULE_28__.AudibleRingComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'sms',
  component: _sms_sms_component__WEBPACK_IMPORTED_MODULE_31__.SmsComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'recordings',
  component: _recordings_recordings_component__WEBPACK_IMPORTED_MODULE_32__.RecordingsComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'publishers',
  component: _publishers_publishers_component__WEBPACK_IMPORTED_MODULE_34__.PublishersComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'publishers-registration-settings',
  component: _publishers_publisher_settings_publisher_settings_component__WEBPACK_IMPORTED_MODULE_43__.PublisherSettingsComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'publisher-registration/:id',
  component: _publishers_publisher_terms_publisher_terms_component__WEBPACK_IMPORTED_MODULE_44__.PublisherTermsComponent
}, {
  path: 'advertiser-terms',
  component: _publishers_advertiser_terms_advertiser_terms_component__WEBPACK_IMPORTED_MODULE_45__.AdvertiserTermsComponent
}, {
  path: 'thank-you',
  component: _publishers_thankyou_thankyou_component__WEBPACK_IMPORTED_MODULE_1__.ThankyouComponent
}, {
  path: 'campaigns',
  component: _campaigns_campaigns_component__WEBPACK_IMPORTED_MODULE_35__.CampaignsComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'campaign-wizard',
  component: _campaigns_campaign_create_campaign_create_component__WEBPACK_IMPORTED_MODULE_36__.CampaignCreateComponent
}, {
  path: 'numbers',
  component: _numbers_numbers_component__WEBPACK_IMPORTED_MODULE_37__.NumbersComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'number-pools',
  component: _numbers_number_pool_number_pool_component__WEBPACK_IMPORTED_MODULE_38__.NumberPoolComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'blocked-numbers',
  component: _numbers_blocked_numbers_blocked_numbers_component__WEBPACK_IMPORTED_MODULE_39__.BlockedNumbersComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
},
// {path:'create-number',component:NumberCreateComponent, canActivate: [AuthGuard]},  
{
  path: 'edit-campaign/:id',
  component: _campaigns_campaign_edit_campaign_edit_component__WEBPACK_IMPORTED_MODULE_40__.CampaignEditComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'view-campaign/:id',
  component: _campaigns_campaign_view_campaign_view_component__WEBPACK_IMPORTED_MODULE_0__.CampaignViewComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'manage-users',
  component: _settings_manage_users_manage_users_component__WEBPACK_IMPORTED_MODULE_41__.ManageUsersComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'basic-setting',
  component: _settings_basic_setting_basic_setting_component__WEBPACK_IMPORTED_MODULE_42__.BasicSettingComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'alert-configuration',
  component: _settings_alert_configuration_alert_configuration_component__WEBPACK_IMPORTED_MODULE_46__.AlertConfigurationComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'manage-company',
  component: _settings_manage_company_manage_company_component__WEBPACK_IMPORTED_MODULE_47__.ManageCompanyComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'change-log',
  component: _changelog_changelog_component__WEBPACK_IMPORTED_MODULE_48__.ChangelogComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'verify-email/:uuid',
  component: _mail_verification_mail_verification_component__WEBPACK_IMPORTED_MODULE_52__.MailVerificationComponent
}, {
  path: 'NgxdemoComponent',
  component: _label_ngxdemo_ngxdemo_component__WEBPACK_IMPORTED_MODULE_53__.NgxdemoComponent
}, {
  path: 'voicemail',
  component: _voicemail_voicemail_component__WEBPACK_IMPORTED_MODULE_2__.VoicemailComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'tasks',
  component: _tasks_tasks_component__WEBPACK_IMPORTED_MODULE_55__.TasksComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'predictive-routing',
  component: _settings_predictive_routing_predictive_routing_component__WEBPACK_IMPORTED_MODULE_56__.PredictiveRoutingComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'predictive-routing-add',
  component: _settings_predictive_routing_add_routing_add_routing_component__WEBPACK_IMPORTED_MODULE_57__.AddRoutingComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}, {
  path: 'predictive-routing-edit/:id',
  component: _settings_predictive_routing_edit_routing_edit_routing_component__WEBPACK_IMPORTED_MODULE_58__.EditRoutingComponent,
  canActivate: [_auth_auth_guard__WEBPACK_IMPORTED_MODULE_3__.AuthGuard]
}];
let ModulesRoutingModule = class ModulesRoutingModule {};
ModulesRoutingModule = (0,tslib__WEBPACK_IMPORTED_MODULE_59__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_60__.NgModule)({
  imports: [_angular_router__WEBPACK_IMPORTED_MODULE_61__.RouterModule.forChild(routes), _angular_forms__WEBPACK_IMPORTED_MODULE_62__.FormsModule, _angular_forms__WEBPACK_IMPORTED_MODULE_62__.ReactiveFormsModule],
  exports: [_angular_router__WEBPACK_IMPORTED_MODULE_61__.RouterModule]
})], ModulesRoutingModule);


/***/ }),

/***/ 27354:
/*!*******************************************!*\
  !*** ./src/app/modules/modules.module.ts ***!
  \*******************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "MY_MOMENT_FORMATS": () => (/* binding */ MY_MOMENT_FORMATS),
/* harmony export */   "ModulesModule": () => (/* binding */ ModulesModule)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_63__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_64__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_69__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _angular_common__WEBPACK_IMPORTED_MODULE_66__ = __webpack_require__(/*! @angular/common */ 94666);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_67__ = __webpack_require__(/*! @angular/platform-browser */ 34497);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_68__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var _modules_routing_module__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./modules-routing.module */ 34555);
/* harmony import */ var _number_number_component__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./number/number.component */ 47760);
/* harmony import */ var _number_number_upload_number_upload_component__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./number/number-upload/number-upload.component */ 11724);
/* harmony import */ var _dashboard_dashboard_component__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./dashboard/dashboard.component */ 6957);
/* harmony import */ var _number_numberedit_numberedit_component__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./number/numberedit/numberedit.component */ 63092);
/* harmony import */ var _number_numberadd_numberadd_component__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./number/numberadd/numberadd.component */ 11722);
/* harmony import */ var ng_pick_datetime__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ng-pick-datetime */ 37526);
/* harmony import */ var _angular_platform_browser_animations__WEBPACK_IMPORTED_MODULE_70__ = __webpack_require__(/*! @angular/platform-browser/animations */ 37146);
/* harmony import */ var _label_label_component__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./label/label.component */ 92751);
/* harmony import */ var _notes_notes_component__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./notes/notes.component */ 44892);
/* harmony import */ var _ivr_menus_ivr_menus_component__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./ivr-menus/ivr-menus.component */ 192);
/* harmony import */ var _ivr_menus_add_ivrmenu_add_ivrmenu_component__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ./ivr-menus/add-ivrmenu/add-ivrmenu.component */ 83770);
/* harmony import */ var angular2_multiselect_dropdown__WEBPACK_IMPORTED_MODULE_71__ = __webpack_require__(/*! angular2-multiselect-dropdown */ 31890);
/* harmony import */ var _ivr_menus_edit_ivrmenu_edit_ivrmenu_component__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ./ivr-menus/edit-ivrmenu/edit-ivrmenu.component */ 42926);
/* harmony import */ var _rules_rules_component__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ./rules/rules.component */ 46315);
/* harmony import */ var _rules_rulesadd_rulesadd_component__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! ./rules/rulesadd/rulesadd.component */ 34904);
/* harmony import */ var _rules_rulesedit_rulesedit_component__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! ./rules/rulesedit/rulesedit.component */ 73692);
/* harmony import */ var _dynamic_parameter_dynamic_parameter_component__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! ./dynamic-parameter/dynamic-parameter.component */ 27393);
/* harmony import */ var _blacklist_blacklist_component__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! ./blacklist/blacklist.component */ 15805);
/* harmony import */ var _whitelist_whitelist_component__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! ./whitelist/whitelist.component */ 45520);
/* harmony import */ var _reports_reports_component__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(/*! ./reports/reports.component */ 15574);
/* harmony import */ var _verification_management_verification_management_component__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(/*! ./verification-management/verification-management.component */ 21178);
/* harmony import */ var _audible_ring_audible_ring_component__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(/*! ./audible-ring/audible-ring.component */ 21526);
/* harmony import */ var ngx_daterangepicker_material__WEBPACK_IMPORTED_MODULE_75__ = __webpack_require__(/*! ngx-daterangepicker-material */ 16155);
/* harmony import */ var _shortlist_shortlist_component__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__(/*! ./shortlist/shortlist.component */ 26516);
/* harmony import */ var _longlist_longlist_component__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(/*! ./longlist/longlist.component */ 93619);
/* harmony import */ var _number_number_batchedit_number_batchedit_component__WEBPACK_IMPORTED_MODULE_23__ = __webpack_require__(/*! ./number/number-batchedit/number-batchedit.component */ 84359);
/* harmony import */ var _number_number_addfslrules_number_addfslrules_component__WEBPACK_IMPORTED_MODULE_24__ = __webpack_require__(/*! ./number/number-addfslrules/number-addfslrules.component */ 26736);
/* harmony import */ var _label_label_view_label_view_component__WEBPACK_IMPORTED_MODULE_25__ = __webpack_require__(/*! ./label/label-view/label-view.component */ 82714);
/* harmony import */ var angular_highcharts__WEBPACK_IMPORTED_MODULE_72__ = __webpack_require__(/*! angular-highcharts */ 55199);
/* harmony import */ var _sms_sms_component__WEBPACK_IMPORTED_MODULE_26__ = __webpack_require__(/*! ./sms/sms.component */ 44321);
/* harmony import */ var _recordings_recordings_component__WEBPACK_IMPORTED_MODULE_27__ = __webpack_require__(/*! ./recordings/recordings.component */ 54577);
/* harmony import */ var ng_pick_datetime_moment__WEBPACK_IMPORTED_MODULE_28__ = __webpack_require__(/*! ng-pick-datetime-moment */ 19005);
/* harmony import */ var ngx_audio_player__WEBPACK_IMPORTED_MODULE_74__ = __webpack_require__(/*! ngx-audio-player */ 28589);
/* harmony import */ var _reports_report_calls_report_calls_component__WEBPACK_IMPORTED_MODULE_29__ = __webpack_require__(/*! ./reports/report-calls/report-calls.component */ 55761);
/* harmony import */ var _reports_report_labelsummary_report_labelsummary_component__WEBPACK_IMPORTED_MODULE_30__ = __webpack_require__(/*! ./reports/report-labelsummary/report-labelsummary.component */ 4463);
/* harmony import */ var _number_number_buyer_number_buyer_component__WEBPACK_IMPORTED_MODULE_31__ = __webpack_require__(/*! ./number/number-buyer/number-buyer.component */ 91522);
/* harmony import */ var _publishers_publishers_component__WEBPACK_IMPORTED_MODULE_32__ = __webpack_require__(/*! ./publishers/publishers.component */ 64617);
/* harmony import */ var _campaigns_campaigns_component__WEBPACK_IMPORTED_MODULE_33__ = __webpack_require__(/*! ./campaigns/campaigns.component */ 78007);
/* harmony import */ var _campaigns_campaign_create_campaign_create_component__WEBPACK_IMPORTED_MODULE_34__ = __webpack_require__(/*! ./campaigns/campaign-create/campaign-create.component */ 96658);
/* harmony import */ var _numbers_numbers_component__WEBPACK_IMPORTED_MODULE_35__ = __webpack_require__(/*! ./numbers/numbers.component */ 13224);
/* harmony import */ var angular_datatables__WEBPACK_IMPORTED_MODULE_36__ = __webpack_require__(/*! angular-datatables */ 51282);
/* harmony import */ var _tinymce_tinymce_angular__WEBPACK_IMPORTED_MODULE_65__ = __webpack_require__(/*! @tinymce/tinymce-angular */ 73889);
/* harmony import */ var _ngx_formly_core__WEBPACK_IMPORTED_MODULE_84__ = __webpack_require__(/*! @ngx-formly/core */ 91531);
/* harmony import */ var _ngx_formly_bootstrap__WEBPACK_IMPORTED_MODULE_78__ = __webpack_require__(/*! @ngx-formly/bootstrap */ 35249);
/* harmony import */ var _angular_material_stepper__WEBPACK_IMPORTED_MODULE_76__ = __webpack_require__(/*! @angular/material/stepper */ 44193);
/* harmony import */ var _angular_material_input__WEBPACK_IMPORTED_MODULE_79__ = __webpack_require__(/*! @angular/material/input */ 68562);
/* harmony import */ var _angular_material_button__WEBPACK_IMPORTED_MODULE_80__ = __webpack_require__(/*! @angular/material/button */ 84522);
/* harmony import */ var _angular_material_select__WEBPACK_IMPORTED_MODULE_77__ = __webpack_require__(/*! @angular/material/select */ 57371);
/* harmony import */ var _angular_material_form_field__WEBPACK_IMPORTED_MODULE_73__ = __webpack_require__(/*! @angular/material/form-field */ 75074);
/* harmony import */ var ng_select2__WEBPACK_IMPORTED_MODULE_81__ = __webpack_require__(/*! ng-select2 */ 31283);
/* harmony import */ var _campaigns_campaign_edit_campaign_edit_component__WEBPACK_IMPORTED_MODULE_37__ = __webpack_require__(/*! ./campaigns/campaign-edit/campaign-edit.component */ 84155);
/* harmony import */ var _numbers_blocked_numbers_blocked_numbers_component__WEBPACK_IMPORTED_MODULE_38__ = __webpack_require__(/*! ./numbers/blocked-numbers/blocked-numbers.component */ 85351);
/* harmony import */ var _settings_manage_users_manage_users_component__WEBPACK_IMPORTED_MODULE_39__ = __webpack_require__(/*! ./settings/manage-users/manage-users.component */ 57632);
/* harmony import */ var _publishers_publisher_settings_publisher_settings_component__WEBPACK_IMPORTED_MODULE_40__ = __webpack_require__(/*! ./publishers/publisher-settings/publisher-settings.component */ 80301);
/* harmony import */ var _publishers_publisher_terms_publisher_terms_component__WEBPACK_IMPORTED_MODULE_41__ = __webpack_require__(/*! ./publishers/publisher-terms/publisher-terms.component */ 75102);
/* harmony import */ var _publishers_advertiser_terms_advertiser_terms_component__WEBPACK_IMPORTED_MODULE_42__ = __webpack_require__(/*! ./publishers/advertiser-terms/advertiser-terms.component */ 61312);
/* harmony import */ var _settings_basic_setting_basic_setting_component__WEBPACK_IMPORTED_MODULE_43__ = __webpack_require__(/*! ./settings/basic-setting/basic-setting.component */ 76251);
/* harmony import */ var _angular_material_moment_adapter__WEBPACK_IMPORTED_MODULE_85__ = __webpack_require__(/*! @angular/material-moment-adapter */ 77118);
/* harmony import */ var _settings_alert_configuration_alert_configuration_component__WEBPACK_IMPORTED_MODULE_44__ = __webpack_require__(/*! ./settings/alert-configuration/alert-configuration.component */ 32279);
/* harmony import */ var _numbers_number_pool_number_pool_component__WEBPACK_IMPORTED_MODULE_45__ = __webpack_require__(/*! ./numbers/number-pool/number-pool.component */ 25700);
/* harmony import */ var _settings_manage_company_manage_company_component__WEBPACK_IMPORTED_MODULE_46__ = __webpack_require__(/*! ./settings/manage-company/manage-company.component */ 78376);
/* harmony import */ var _changelog_changelog_component__WEBPACK_IMPORTED_MODULE_47__ = __webpack_require__(/*! ./changelog/changelog.component */ 97316);
/* harmony import */ var _ivr_menus_ivr_routing_plans_ivr_routing_plans_component__WEBPACK_IMPORTED_MODULE_48__ = __webpack_require__(/*! ./ivr-menus/ivr-routing-plans/ivr-routing-plans.component */ 24066);
/* harmony import */ var _ivr_menus_ivr_routing_plans_add_plan_add_plan_component__WEBPACK_IMPORTED_MODULE_49__ = __webpack_require__(/*! ./ivr-menus/ivr-routing-plans/add-plan/add-plan.component */ 69039);
/* harmony import */ var _ivr_menus_ivr_routing_plans_edit_plan_edit_plan_component__WEBPACK_IMPORTED_MODULE_50__ = __webpack_require__(/*! ./ivr-menus/ivr-routing-plans/edit-plan/edit-plan.component */ 71352);
/* harmony import */ var _mail_verification_mail_verification_component__WEBPACK_IMPORTED_MODULE_51__ = __webpack_require__(/*! ./mail-verification/mail-verification.component */ 52354);
/* harmony import */ var _swimlane_ngx_datatable__WEBPACK_IMPORTED_MODULE_82__ = __webpack_require__(/*! @swimlane/ngx-datatable */ 93143);
/* harmony import */ var _label_ngxdemo_ngxdemo_component__WEBPACK_IMPORTED_MODULE_52__ = __webpack_require__(/*! ./label/ngxdemo/ngxdemo.component */ 86489);
/* harmony import */ var _ng_bootstrap_ng_bootstrap__WEBPACK_IMPORTED_MODULE_83__ = __webpack_require__(/*! @ng-bootstrap/ng-bootstrap */ 3191);
/* harmony import */ var time_ago_pipe__WEBPACK_IMPORTED_MODULE_53__ = __webpack_require__(/*! time-ago-pipe */ 93739);
/* harmony import */ var ngx_ui_loader__WEBPACK_IMPORTED_MODULE_62__ = __webpack_require__(/*! ngx-ui-loader */ 36413);
/* harmony import */ var _reports_comparison_reports_comparison_component__WEBPACK_IMPORTED_MODULE_54__ = __webpack_require__(/*! ./reports-comparison/reports-comparison.component */ 41740);
/* harmony import */ var _voicemail_voicemail_component__WEBPACK_IMPORTED_MODULE_55__ = __webpack_require__(/*! ./voicemail/voicemail.component */ 29032);
/* harmony import */ var _publishers_thankyou_thankyou_component__WEBPACK_IMPORTED_MODULE_56__ = __webpack_require__(/*! ./publishers/thankyou/thankyou.component */ 49377);
/* harmony import */ var _campaigns_campaign_view_campaign_view_component__WEBPACK_IMPORTED_MODULE_57__ = __webpack_require__(/*! ./campaigns/campaign-view/campaign-view.component */ 51086);
/* harmony import */ var _tasks_tasks_component__WEBPACK_IMPORTED_MODULE_58__ = __webpack_require__(/*! ./tasks/tasks.component */ 5601);
/* harmony import */ var _settings_predictive_routing_predictive_routing_component__WEBPACK_IMPORTED_MODULE_59__ = __webpack_require__(/*! ./settings/predictive-routing/predictive-routing.component */ 74982);
/* harmony import */ var _settings_predictive_routing_add_routing_add_routing_component__WEBPACK_IMPORTED_MODULE_60__ = __webpack_require__(/*! ./settings/predictive-routing/add-routing/add-routing.component */ 64943);
/* harmony import */ var _settings_predictive_routing_edit_routing_edit_routing_component__WEBPACK_IMPORTED_MODULE_61__ = __webpack_require__(/*! ./settings/predictive-routing/edit-routing/edit-routing.component */ 57977);

// import { NgxUiLoaderService } from 'ngx-ui-loader';
















































// import { NgxTinymceModule } from 'ngx-tinymce';
const MY_MOMENT_FORMATS = {
  //   fullPickerInput: 'YYYY-MM-DD HH:mm:ss',
  // parseInput: 'YYYY-MM-DD HH:mm:ss',
  // datePickerInput: 'YYYY-MM-DD HH:mm:ss',
  timePickerInput: 'HH:mm'
  // monthYearLabel: 'MMM YYYY',
  // dateA11yLabel: 'LL',
  // monthYearA11yLabel: 'MMMM YYYY'
};





























// import { NgxUiLoaderModule } from "ngx-ui-loader";









const ngxUiLoaderConfig = {
  // bgsColor: '#3858E7',
  bgsPosition: ngx_ui_loader__WEBPACK_IMPORTED_MODULE_62__.POSITION.centerCenter
  // bgsSize: 30,
  // bgsType: SPINNER.rectangleBounce, // background spinner type
  // fgsType: SPINNER.chasingDots, // foreground spinner type
  // pbDirection: PB_DIRECTION.leftToRight, // progress bar direction
  // pbThickness: 2, // progress bar thickness
};

let ModulesModule = class ModulesModule {};
ModulesModule = (0,tslib__WEBPACK_IMPORTED_MODULE_63__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_64__.NgModule)({
  declarations: [time_ago_pipe__WEBPACK_IMPORTED_MODULE_53__.TimeAgoPipe, _number_number_component__WEBPACK_IMPORTED_MODULE_1__.NumberComponent, _dashboard_dashboard_component__WEBPACK_IMPORTED_MODULE_3__.DashboardComponent, _number_numberedit_numberedit_component__WEBPACK_IMPORTED_MODULE_4__.NumbereditComponent, _number_numberadd_numberadd_component__WEBPACK_IMPORTED_MODULE_5__.NumberaddComponent, _label_label_component__WEBPACK_IMPORTED_MODULE_7__.LabelComponent, _notes_notes_component__WEBPACK_IMPORTED_MODULE_8__.NotesComponent, _ivr_menus_ivr_menus_component__WEBPACK_IMPORTED_MODULE_9__.IvrMenusComponent, _ivr_menus_add_ivrmenu_add_ivrmenu_component__WEBPACK_IMPORTED_MODULE_10__.AddIVRMenuComponent, _ivr_menus_edit_ivrmenu_edit_ivrmenu_component__WEBPACK_IMPORTED_MODULE_11__.EditIvrmenuComponent, _rules_rules_component__WEBPACK_IMPORTED_MODULE_12__.RulesComponent, _rules_rulesadd_rulesadd_component__WEBPACK_IMPORTED_MODULE_13__.RulesaddComponent, _rules_rulesedit_rulesedit_component__WEBPACK_IMPORTED_MODULE_14__.RuleseditComponent, _dynamic_parameter_dynamic_parameter_component__WEBPACK_IMPORTED_MODULE_15__.DynamicParameterComponent, _blacklist_blacklist_component__WEBPACK_IMPORTED_MODULE_16__.BlacklistComponent, _whitelist_whitelist_component__WEBPACK_IMPORTED_MODULE_17__.WhitelistComponent, _reports_reports_component__WEBPACK_IMPORTED_MODULE_18__.ReportsComponent, _verification_management_verification_management_component__WEBPACK_IMPORTED_MODULE_19__.VerificationManagementComponent, _audible_ring_audible_ring_component__WEBPACK_IMPORTED_MODULE_20__.AudibleRingComponent, _number_number_upload_number_upload_component__WEBPACK_IMPORTED_MODULE_2__.NumberUploadComponent, _shortlist_shortlist_component__WEBPACK_IMPORTED_MODULE_21__.ShortlistComponent, _longlist_longlist_component__WEBPACK_IMPORTED_MODULE_22__.LonglistComponent, _number_number_batchedit_number_batchedit_component__WEBPACK_IMPORTED_MODULE_23__.NumberBatcheditComponent, _number_number_addfslrules_number_addfslrules_component__WEBPACK_IMPORTED_MODULE_24__.NumberAddfslrulesComponent, _label_label_view_label_view_component__WEBPACK_IMPORTED_MODULE_25__.LabelViewComponent, _sms_sms_component__WEBPACK_IMPORTED_MODULE_26__.SmsComponent, _recordings_recordings_component__WEBPACK_IMPORTED_MODULE_27__.RecordingsComponent, _reports_report_calls_report_calls_component__WEBPACK_IMPORTED_MODULE_29__.ReportCallsComponent, _reports_report_labelsummary_report_labelsummary_component__WEBPACK_IMPORTED_MODULE_30__.ReportLabelsummaryComponent, _number_number_buyer_number_buyer_component__WEBPACK_IMPORTED_MODULE_31__.NumberBuyerComponent, _publishers_publishers_component__WEBPACK_IMPORTED_MODULE_32__.PublishersComponent, _campaigns_campaigns_component__WEBPACK_IMPORTED_MODULE_33__.CampaignsComponent, _campaigns_campaign_create_campaign_create_component__WEBPACK_IMPORTED_MODULE_34__.CampaignCreateComponent, _numbers_numbers_component__WEBPACK_IMPORTED_MODULE_35__.NumbersComponent, _campaigns_campaign_edit_campaign_edit_component__WEBPACK_IMPORTED_MODULE_37__.CampaignEditComponent, _numbers_blocked_numbers_blocked_numbers_component__WEBPACK_IMPORTED_MODULE_38__.BlockedNumbersComponent, _settings_manage_users_manage_users_component__WEBPACK_IMPORTED_MODULE_39__.ManageUsersComponent, _publishers_publisher_settings_publisher_settings_component__WEBPACK_IMPORTED_MODULE_40__.PublisherSettingsComponent, _publishers_publisher_terms_publisher_terms_component__WEBPACK_IMPORTED_MODULE_41__.PublisherTermsComponent, _publishers_advertiser_terms_advertiser_terms_component__WEBPACK_IMPORTED_MODULE_42__.AdvertiserTermsComponent, _settings_basic_setting_basic_setting_component__WEBPACK_IMPORTED_MODULE_43__.BasicSettingComponent, _settings_alert_configuration_alert_configuration_component__WEBPACK_IMPORTED_MODULE_44__.AlertConfigurationComponent, _numbers_number_pool_number_pool_component__WEBPACK_IMPORTED_MODULE_45__.NumberPoolComponent, _settings_manage_company_manage_company_component__WEBPACK_IMPORTED_MODULE_46__.ManageCompanyComponent, _changelog_changelog_component__WEBPACK_IMPORTED_MODULE_47__.ChangelogComponent, _ivr_menus_ivr_routing_plans_ivr_routing_plans_component__WEBPACK_IMPORTED_MODULE_48__.IVRRoutingPlansComponent, _ivr_menus_ivr_routing_plans_add_plan_add_plan_component__WEBPACK_IMPORTED_MODULE_49__.AddPlanComponent, _ivr_menus_ivr_routing_plans_edit_plan_edit_plan_component__WEBPACK_IMPORTED_MODULE_50__.EditPlanComponent, _mail_verification_mail_verification_component__WEBPACK_IMPORTED_MODULE_51__.MailVerificationComponent, _label_ngxdemo_ngxdemo_component__WEBPACK_IMPORTED_MODULE_52__.NgxdemoComponent, _reports_comparison_reports_comparison_component__WEBPACK_IMPORTED_MODULE_54__.ReportsComparisonComponent, _voicemail_voicemail_component__WEBPACK_IMPORTED_MODULE_55__.VoicemailComponent, _publishers_thankyou_thankyou_component__WEBPACK_IMPORTED_MODULE_56__.ThankyouComponent, _campaigns_campaign_view_campaign_view_component__WEBPACK_IMPORTED_MODULE_57__.CampaignViewComponent, _tasks_tasks_component__WEBPACK_IMPORTED_MODULE_58__.TasksComponent, _settings_predictive_routing_predictive_routing_component__WEBPACK_IMPORTED_MODULE_59__.PredictiveRoutingComponent, _settings_predictive_routing_add_routing_add_routing_component__WEBPACK_IMPORTED_MODULE_60__.AddRoutingComponent, _settings_predictive_routing_edit_routing_edit_routing_component__WEBPACK_IMPORTED_MODULE_61__.EditRoutingComponent],
  imports: [_tinymce_tinymce_angular__WEBPACK_IMPORTED_MODULE_65__.EditorModule, _angular_common__WEBPACK_IMPORTED_MODULE_66__.CommonModule, _modules_routing_module__WEBPACK_IMPORTED_MODULE_0__.ModulesRoutingModule, _angular_platform_browser__WEBPACK_IMPORTED_MODULE_67__.BrowserModule, _angular_router__WEBPACK_IMPORTED_MODULE_68__.RouterModule, _angular_forms__WEBPACK_IMPORTED_MODULE_69__.FormsModule, _angular_platform_browser_animations__WEBPACK_IMPORTED_MODULE_70__.BrowserAnimationsModule, _angular_forms__WEBPACK_IMPORTED_MODULE_69__.ReactiveFormsModule, ng_pick_datetime__WEBPACK_IMPORTED_MODULE_6__.OwlDateTimeModule, ng_pick_datetime__WEBPACK_IMPORTED_MODULE_6__.OwlNativeDateTimeModule, angular2_multiselect_dropdown__WEBPACK_IMPORTED_MODULE_71__.AngularMultiSelectModule, angular_highcharts__WEBPACK_IMPORTED_MODULE_72__.ChartModule, _angular_material_form_field__WEBPACK_IMPORTED_MODULE_73__.MatFormFieldModule, ngx_audio_player__WEBPACK_IMPORTED_MODULE_74__.NgxAudioPlayerModule, ngx_daterangepicker_material__WEBPACK_IMPORTED_MODULE_75__.NgxDaterangepickerMd.forRoot(), _angular_material_stepper__WEBPACK_IMPORTED_MODULE_76__.MatStepperModule, _angular_material_select__WEBPACK_IMPORTED_MODULE_77__.MatSelectModule, _ngx_formly_bootstrap__WEBPACK_IMPORTED_MODULE_78__.FormlyBootstrapModule, _angular_material_input__WEBPACK_IMPORTED_MODULE_79__.MatInputModule, _angular_material_button__WEBPACK_IMPORTED_MODULE_80__.MatButtonModule, ng_select2__WEBPACK_IMPORTED_MODULE_81__.NgSelect2Module, _swimlane_ngx_datatable__WEBPACK_IMPORTED_MODULE_82__.NgxDatatableModule, _ng_bootstrap_ng_bootstrap__WEBPACK_IMPORTED_MODULE_83__.NgbTooltipModule, angular_datatables__WEBPACK_IMPORTED_MODULE_36__.DataTablesModule,
  // NgxTinymceModule,
  ngx_ui_loader__WEBPACK_IMPORTED_MODULE_62__.NgxUiLoaderModule.forRoot(ngxUiLoaderConfig), _ngx_formly_core__WEBPACK_IMPORTED_MODULE_84__.FormlyModule.forRoot({
    validationMessages: [{
      name: 'required',
      message: 'This field is required'
    }]
  })],
  schemas: [_angular_core__WEBPACK_IMPORTED_MODULE_64__.CUSTOM_ELEMENTS_SCHEMA],
  exports: [_angular_platform_browser__WEBPACK_IMPORTED_MODULE_67__.BrowserModule, _number_number_component__WEBPACK_IMPORTED_MODULE_1__.NumberComponent, _angular_forms__WEBPACK_IMPORTED_MODULE_69__.FormsModule],
  providers: [{
    provide: ng_pick_datetime__WEBPACK_IMPORTED_MODULE_6__.DateTimeAdapter,
    useClass: ng_pick_datetime_moment__WEBPACK_IMPORTED_MODULE_28__.MomentDateTimeAdapter,
    deps: [ng_pick_datetime__WEBPACK_IMPORTED_MODULE_6__.OWL_DATE_TIME_LOCALE]
  }, {
    provide: ng_pick_datetime__WEBPACK_IMPORTED_MODULE_6__.OWL_DATE_TIME_FORMATS,
    useValue: MY_MOMENT_FORMATS
  }, {
    provide: _angular_material_moment_adapter__WEBPACK_IMPORTED_MODULE_85__.MAT_MOMENT_DATE_ADAPTER_OPTIONS,
    useValue: {
      useUtc: true
    }
  }]
})], ModulesModule);


/***/ }),

/***/ 44892:
/*!**************************************************!*\
  !*** ./src/app/modules/notes/notes.component.ts ***!
  \**************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "NotesComponent": () => (/* binding */ NotesComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _notes_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./notes.component.html?ngResource */ 82174);
/* harmony import */ var _notes_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./notes.component.scss?ngResource */ 59361);
/* harmony import */ var _notes_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_notes_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _modules_module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../../modules/module.service */ 22947);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/platform-browser */ 34497);









let NotesComponent = class NotesComponent {
  constructor(fb, moduleService, router, route, toastrService, titleService) {
    this.fb = fb;
    this.moduleService = moduleService;
    this.router = router;
    this.route = route;
    this.toastrService = toastrService;
    this.titleService = titleService;
    this.submitted = false;
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngOnInit() {
    this.setTitle('Notes');
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.addNotesForm = this.fb.group({
      note: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_3__.Validators.required]
    });
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    const company_uuid = this.currentCompany.uuid;
    // alert(company_uuid);
    if (company_uuid) {
      this.moduleService.getNotesdata(company_uuid).subscribe(res => {
        // console.log(res);
        this.addNotesForm.patchValue({
          note: res[0]['notes']
        });
      });
    }
  }
  get f() {
    return this.addNotesForm.controls;
  }
  onSubmit() {
    const formData = new FormData();
    if (this.addNotesForm.invalid) {
      return;
    }
    this.submitted = true;
    formData.append('note', this.addNotesForm.get('note').value);
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    formData.append('company_uuid', this.currentCompany.uuid);
    const company_uuid = this.currentCompany.uuid;
    if (company_uuid) {
      this.moduleService.addNotes(formData, company_uuid).subscribe(res => {
        // console.log(res); return false;
        if (res.status !== 'error') {
          this.toastrService.success('Notes Saved Successfully');
        } else {
          this.toastrService.success('Failed To Save! Please Try Again Later..');
        }
      }, error => this.error = error);
    }
  }
  static #_ = this.ctorParameters = () => [{
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_3__.FormBuilder
  }, {
    type: _modules_module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_4__.Router
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_4__.ActivatedRoute
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_5__.ToastrService
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_6__.Title
  }];
};
NotesComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_7__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_8__.Component)({
  selector: 'app-notes',
  template: _notes_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_notes_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], NotesComponent);


/***/ }),

/***/ 26736:
/*!***********************************************************************************!*\
  !*** ./src/app/modules/number/number-addfslrules/number-addfslrules.component.ts ***!
  \***********************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "NumberAddfslrulesComponent": () => (/* binding */ NumberAddfslrulesComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _number_addfslrules_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./number-addfslrules.component.html?ngResource */ 49539);
/* harmony import */ var _number_addfslrules_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./number-addfslrules.component.scss?ngResource */ 10111);
/* harmony import */ var _number_addfslrules_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_number_addfslrules_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../module.service */ 22947);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! sweetalert2 */ 60598);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(sweetalert2__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../global */ 27266);









//import 'sweetalert2/src/sweetalert2.scss'


class DataTablesResponse {}
class FSLClass {}
let NumberAddfslrulesComponent = class NumberAddfslrulesComponent {
  constructor(fb, moduleService, router, route, toastrService, handler) {
    this.fb = fb;
    this.moduleService = moduleService;
    this.router = router;
    this.route = route;
    this.toastrService = toastrService;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_4__.GlobalVariable.BASE_API_URL;
    this.dtOptions = {};
    this.FSLRulesSubmitted = false;
    this.FSLRulesEditSubmitted = false;
    this.daysSubmitted = false;
    this.daysEditSubmitted = false;
    this.dropdownList = [];
    this.selectedItems = [];
    // public dateTime1: Date;
    // dropdownSettings: { singleSelection: boolean; text: string; selectAllText: string; unSelectAllText: string; enableSearchFilter: boolean; classes: string; };
    this.dropdownSettings = {};
    this.daytype = 0;
    this.flag = 0;
    // Day0
    this.selectedPrimaryForaward_0_day0 = 0;
    this.selectedPrimaryCount_0_day0 = 0;
    this.selected_0_day_0 = 0;
    this.selectedPrimaryForaward_1_day0 = 0;
    this.selectedPrimaryCount_1_day0 = 0;
    this.selected_1_day_0 = 0;
    this.selectedPrimaryForaward_2_day0 = 0;
    this.selectedPrimaryCount_2_day0 = 0;
    this.selected_2_day_0 = 0;
    this.selectedPrimaryForaward_3_day0 = 0;
    this.selectedPrimaryCount_3_day0 = 0;
    this.selected_3_day_0 = 0;
    this.selectedPrimaryForaward_4_day0 = 0;
    this.selectedPrimaryCount_4_day0 = 0;
    this.selected_4_day_0 = 0;
    this.selectedPrimaryForaward_5_day0 = 0;
    this.selectedPrimaryCount_5_day0 = 0;
    this.selected_5_day_0 = 0;
    this.selectedPrimaryForaward_6_day0 = 0;
    this.selectedPrimaryCount_6_day0 = 0;
    this.selected_6_day_0 = 0;
    this.selectedPrimaryForaward_7_day0 = 0;
    this.selectedPrimaryCount_7_day0 = 0;
    this.selected_7_day_0 = 0;
    this.selectedPrimaryForaward_8_day0 = 0;
    this.selectedPrimaryCount_8_day0 = 0;
    this.selected_8_day_0 = 0;
    this.selectedPrimaryForaward_9_day0 = 0;
    this.selectedPrimaryCount_9_day0 = 0;
    this.selected_9_day_0 = 0;
    // Day1
    this.selectedPrimaryForaward_0_day1 = 0;
    this.selectedPrimaryCount_0_day1 = 0;
    this.selected_0_day_1 = 0;
    this.selectedPrimaryForaward_1_day1 = 0;
    this.selectedPrimaryCount_1_day1 = 0;
    this.selected_1_day_1 = 0;
    this.selectedPrimaryForaward_2_day1 = 0;
    this.selectedPrimaryCount_2_day1 = 0;
    this.selected_2_day_1 = 0;
    this.selectedPrimaryForaward_3_day1 = 0;
    this.selectedPrimaryCount_3_day1 = 0;
    this.selected_3_day_1 = 0;
    this.selectedPrimaryForaward_4_day1 = 0;
    this.selectedPrimaryCount_4_day1 = 0;
    this.selected_4_day_1 = 0;
    this.selectedPrimaryForaward_5_day1 = 0;
    this.selectedPrimaryCount_5_day1 = 0;
    this.selected_5_day_1 = 0;
    this.selectedPrimaryForaward_6_day1 = 0;
    this.selectedPrimaryCount_6_day1 = 0;
    this.selected_6_day_1 = 0;
    this.selectedPrimaryForaward_7_day1 = 0;
    this.selectedPrimaryCount_7_day1 = 0;
    this.selected_7_day_1 = 0;
    this.selectedPrimaryForaward_8_day1 = 0;
    this.selectedPrimaryCount_8_day1 = 0;
    this.selected_8_day_1 = 0;
    this.selectedPrimaryForaward_9_day1 = 0;
    this.selectedPrimaryCount_9_day1 = 0;
    this.selected_9_day_1 = 0;
    // Day2
    this.selectedPrimaryForaward_0_day2 = 0;
    this.selectedPrimaryCount_0_day2 = 0;
    this.selected_0_day_2 = 0;
    this.selectedPrimaryForaward_1_day2 = 0;
    this.selectedPrimaryCount_1_day2 = 0;
    this.selected_1_day_2 = 0;
    this.selectedPrimaryForaward_2_day2 = 0;
    this.selectedPrimaryCount_2_day2 = 0;
    this.selected_2_day_2 = 0;
    this.selectedPrimaryForaward_3_day2 = 0;
    this.selectedPrimaryCount_3_day2 = 0;
    this.selected_3_day_2 = 0;
    this.selectedPrimaryForaward_4_day2 = 0;
    this.selectedPrimaryCount_4_day2 = 0;
    this.selected_4_day_2 = 0;
    this.selectedPrimaryForaward_5_day2 = 0;
    this.selectedPrimaryCount_5_day2 = 0;
    this.selected_5_day_2 = 0;
    this.selectedPrimaryForaward_6_day2 = 0;
    this.selectedPrimaryCount_6_day2 = 0;
    this.selected_6_day_2 = 0;
    this.selectedPrimaryForaward_7_day2 = 0;
    this.selectedPrimaryCount_7_day2 = 0;
    this.selected_7_day_2 = 0;
    this.selectedPrimaryForaward_8_day2 = 0;
    this.selectedPrimaryCount_8_day2 = 0;
    this.selected_8_day_2 = 0;
    this.selectedPrimaryForaward_9_day2 = 0;
    this.selectedPrimaryCount_9_day2 = 0;
    this.selected_9_day_2 = 0;
    // Day3
    this.selectedPrimaryForaward_0_day3 = 0;
    this.selectedPrimaryCount_0_day3 = 0;
    this.selected_0_day_3 = 0;
    this.selectedPrimaryForaward_1_day3 = 0;
    this.selectedPrimaryCount_1_day3 = 0;
    this.selected_1_day_3 = 0;
    this.selectedPrimaryForaward_2_day3 = 0;
    this.selectedPrimaryCount_2_day3 = 0;
    this.selected_2_day_3 = 0;
    this.selectedPrimaryForaward_3_day3 = 0;
    this.selectedPrimaryCount_3_day3 = 0;
    this.selected_3_day_3 = 0;
    this.selectedPrimaryForaward_4_day3 = 0;
    this.selectedPrimaryCount_4_day3 = 0;
    this.selected_4_day_3 = 0;
    this.selectedPrimaryForaward_5_day3 = 0;
    this.selectedPrimaryCount_5_day3 = 0;
    this.selected_5_day_3 = 0;
    this.selectedPrimaryForaward_6_day3 = 0;
    this.selectedPrimaryCount_6_day3 = 0;
    this.selected_6_day_3 = 0;
    this.selectedPrimaryForaward_7_day3 = 0;
    this.selectedPrimaryCount_7_day3 = 0;
    this.selected_7_day_3 = 0;
    this.selectedPrimaryForaward_8_day3 = 0;
    this.selectedPrimaryCount_8_day3 = 0;
    this.selected_8_day_3 = 0;
    this.selectedPrimaryForaward_9_day3 = 0;
    this.selectedPrimaryCount_9_day3 = 0;
    this.selected_9_day_3 = 0;
    // Day4
    this.selectedPrimaryForaward_0_day4 = 0;
    this.selectedPrimaryCount_0_day4 = 0;
    this.selected_0_day_4 = 0;
    this.selectedPrimaryForaward_1_day4 = 0;
    this.selectedPrimaryCount_1_day4 = 0;
    this.selected_1_day_4 = 0;
    this.selectedPrimaryForaward_2_day4 = 0;
    this.selectedPrimaryCount_2_day4 = 0;
    this.selected_2_day_4 = 0;
    this.selectedPrimaryForaward_3_day4 = 0;
    this.selectedPrimaryCount_3_day4 = 0;
    this.selected_3_day_4 = 0;
    this.selectedPrimaryForaward_4_day4 = 0;
    this.selectedPrimaryCount_4_day4 = 0;
    this.selected_4_day_4 = 0;
    this.selectedPrimaryForaward_5_day4 = 0;
    this.selectedPrimaryCount_5_day4 = 0;
    this.selected_5_day_4 = 0;
    this.selectedPrimaryForaward_6_day4 = 0;
    this.selectedPrimaryCount_6_day4 = 0;
    this.selected_6_day_4 = 0;
    this.selectedPrimaryForaward_7_day4 = 0;
    this.selectedPrimaryCount_7_day4 = 0;
    this.selected_7_day_4 = 0;
    this.selectedPrimaryForaward_8_day4 = 0;
    this.selectedPrimaryCount_8_day4 = 0;
    this.selected_8_day_4 = 0;
    this.selectedPrimaryForaward_9_day4 = 0;
    this.selectedPrimaryCount_9_day4 = 0;
    this.selected_9_day_4 = 0;
    // Day5
    this.selectedPrimaryForaward_0_day5 = 0;
    this.selectedPrimaryCount_0_day5 = 0;
    this.selected_0_day_5 = 0;
    this.selectedPrimaryForaward_1_day5 = 0;
    this.selectedPrimaryCount_1_day5 = 0;
    this.selected_1_day_5 = 0;
    this.selectedPrimaryForaward_2_day5 = 0;
    this.selectedPrimaryCount_2_day5 = 0;
    this.selected_2_day_5 = 0;
    this.selectedPrimaryForaward_3_day5 = 0;
    this.selectedPrimaryCount_3_day5 = 0;
    this.selected_3_day_5 = 0;
    this.selectedPrimaryForaward_4_day5 = 0;
    this.selectedPrimaryCount_4_day5 = 0;
    this.selected_4_day_5 = 0;
    this.selectedPrimaryForaward_5_day5 = 0;
    this.selectedPrimaryCount_5_day5 = 0;
    this.selected_5_day_5 = 0;
    this.selectedPrimaryForaward_6_day5 = 0;
    this.selectedPrimaryCount_6_day5 = 0;
    this.selected_6_day_5 = 0;
    this.selectedPrimaryForaward_7_day5 = 0;
    this.selectedPrimaryCount_7_day5 = 0;
    this.selected_7_day_5 = 0;
    this.selectedPrimaryForaward_8_day5 = 0;
    this.selectedPrimaryCount_8_day5 = 0;
    this.selected_8_day_5 = 0;
    this.selectedPrimaryForaward_9_day5 = 0;
    this.selectedPrimaryCount_9_day5 = 0;
    this.selected_9_day_5 = 0;
    // Day6
    this.selectedPrimaryForaward_0_day6 = 0;
    this.selectedPrimaryCount_0_day6 = 0;
    this.selected_0_day_6 = 0;
    this.selectedPrimaryForaward_1_day6 = 0;
    this.selectedPrimaryCount_1_day6 = 0;
    this.selected_1_day_6 = 0;
    this.selectedPrimaryForaward_2_day6 = 0;
    this.selectedPrimaryCount_2_day6 = 0;
    this.selected_2_day_6 = 0;
    this.selectedPrimaryForaward_3_day6 = 0;
    this.selectedPrimaryCount_3_day6 = 0;
    this.selected_3_day_6 = 0;
    this.selectedPrimaryForaward_4_day6 = 0;
    this.selectedPrimaryCount_4_day6 = 0;
    this.selected_4_day_6 = 0;
    this.selectedPrimaryForaward_5_day6 = 0;
    this.selectedPrimaryCount_5_day6 = 0;
    this.selected_5_day_6 = 0;
    this.selectedPrimaryForaward_6_day6 = 0;
    this.selectedPrimaryCount_6_day6 = 0;
    this.selected_6_day_6 = 0;
    this.selectedPrimaryForaward_7_day6 = 0;
    this.selectedPrimaryCount_7_day6 = 0;
    this.selected_7_day_6 = 0;
    this.selectedPrimaryForaward_8_day6 = 0;
    this.selectedPrimaryCount_8_day6 = 0;
    this.selected_8_day_6 = 0;
    this.selectedPrimaryForaward_9_day6 = 0;
    this.selectedPrimaryCount_9_day6 = 0;
    this.selected_9_day_6 = 0;
    this.selectedLevel = 0;
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_5__.HttpClient(handler);
  }
  validatename(event) {
    // console.log(event.target.value); return false; 
    if (event.target.value != '') {
      this.moduleService.validatename(event.target.value).subscribe(res => {
        // console.log(res); return false;  
        this.isName = res;
        if (this.isName.status == 'success') {
          this.isName = "success";
        } else {
          this.isName = "fail";
        }
        // console.log(this.isName); return false;  
      }
      // }
      );
    } else {
      this.isName = "";
    }
  }
  getFSLbyuuid(uuid) {
    // alert(uuid);
    // console.log(uuid);
    this.moduleService.getFSLbyuuid(uuid).subscribe(res => {
      this.forwarding = res.forwarding[0].name;
      this.forwardingtimeframe = res.forwarding[0].nooftimeframe;
      this.noofforwarding = res.forwarding[0].nooftimeframe;
      for (let index = 0; index < res.forwarding.length; index++) {
        var start = res.forwarding[index].start_time.split(':');
        var end = res.forwarding[index].end_time.split(':');
        var startkey = 'start_time_' + index;
        var endkey = 'end_time_' + index;
        var daykey = 'day_' + index;
        // console.log(start[0]);
        this.editFSLRules.patchValue({
          [daykey]: res.forwarding[index].timeofday,
          [startkey]: new Date(new Date().setHours(start[0], start[1])),
          [endkey]: new Date(new Date().setHours(end[0], end[1]))
        });
        for (let j = 0; j < res.forwarding[index].locations.length; j++) {
          var inc = j + 1;
          // var forlocationkey ='noofforwardinglocation_'+inc;
          var PrimaryforwardType = 'PrimaryforwardType_' + j + '_day' + index;
          var number_value = 'number_' + j + '_day' + index;
          var ivr_value = 'ivrMenu_' + j + '_day' + index;
          var sip_value = 'sipAdd_' + j + '_day' + index;
          // this.flag =res.forwarding[index].locations[j].primary_forwarding_type;
          // console.log(res.forwarding[index].locations[j].primary_forwarding_type);
          if (res.forwarding[index].locations[j].primary_forwarding_type == 0) {
            this.setPrimaryforward(0, j, index);
            this.flag = 0;
          }
          if (res.forwarding[index].locations[j].primary_forwarding_type == 1) {
            this.setPrimaryforward(1, j, index);
            this.flag = 1;
          }
          if (res.forwarding[index].locations[j].primary_forwarding_type == 2) {
            this.flag = 2;
            this.setPrimaryforward(2, j, index);
          }
          if (res.forwarding[index].locations[j].primary_forwarding_number != '') {
            var number = res.forwarding[index].locations[j].primary_forwarding_number;
            var formatted = '(' + number.substr(0, 3) + ') ' + number.substr(3, 3) + '-' + number.substr(6, 4);
          } else {
            var formatted = "";
          }
          if (index == 0) {
            this.noofforwardinglocation_1 = res.forwarding[index].locations[j].noofforwardinglocation;
            // if(this.noofforwardinglocation_1!=1)  {
            // this.noofforwardinglocation_1++;                             
            // }
          }
          //  console.log(res.forwarding[index].locations[j].noofforwardinglocation);
          if (index == 1) {
            this.noofforwardinglocation_2 = res.forwarding[index].locations[j].noofforwardinglocation;
            // if(res.forwarding[index].locations[j].noofforwardinglocation!=1)  {
            //   this.noofforwardinglocation_2++;                             
            //   }
          }

          if (index == 2) {
            this.noofforwardinglocation_3 = res.forwarding[index].locations[j].noofforwardinglocation;
            // if(res.forwarding[index].locations[j].noofforwardinglocation!=1)  {
            //   this.noofforwardinglocation_3++;                             
            // }                              
          }

          if (index == 3) {
            this.noofforwardinglocation_4 = res.forwarding[index].locations[j].noofforwardinglocation;
            // if(res.forwarding[index].locations[j].noofforwardinglocation!=1)  {
            //   this.noofforwardinglocation_4++;                             
            // }                              
          }

          if (index == 4) {
            this.noofforwardinglocation_5 = res.forwarding[index].locations[j].noofforwardinglocation;
            // if(res.forwarding[index].locations[j].noofforwardinglocation!=1)  {
            //   this.noofforwardinglocation_5++;                             
            // }                                
          }

          if (index == 5) {
            this.noofforwardinglocation_6 = res.forwarding[index].locations[j].noofforwardinglocation;
          }
          if (index == 6) {
            this.noofforwardinglocation_7 = res.forwarding[index].locations[j].noofforwardinglocation;
          }
          // console.log(index);
          this.editFSLRules.patchValue({
            // [forlocationkey]: res.forwarding[index].locations[j].noofforwardinglocation,
            [PrimaryforwardType]: this.flag,
            [number_value]: formatted,
            [ivr_value]: res.forwarding[index].locations[j].primary_forwarding_ivr,
            [sip_value]: res.forwarding[index].locations[j].primary_forwarding_sip
          });
        }
      }
    }, error => this.error = error);
  }
  addFSL() {
    this.FSLRulesSubmitted = false;
    this.addFSLRules.reset();
  }
  getWeekbyuuid(uuid, start_day, end_day) {
    this.editWeekDaysForm.patchValue({
      'uuid': uuid,
      'start_day': start_day,
      'end_day': end_day
    });
  }
  ngOnInit() {
    // this.showLoadingIndicator= true;
    // setTimeout(()=>{this.showLoadingIndicator= false; },1000);
    // this.loadNumbers();
    this.loadallweekdays();
    this.loadweekdays();
    this.getAllLabels();
    this.getIVRMenu();
    this.getAllLabels();
    this.getAllRuleset();
    this.getAllLabels();
    this.dropdownSettings = {
      singleSelection: false,
      text: "Select Associated Label",
      selectAllText: 'Select All',
      unSelectAllText: 'UnSelect All',
      enableSearchFilter: true,
      classes: "myclass custom-class"
    };
    // if(localStorage.getItem('FSLRulesInsertID')){
    // this.getRules();
    // }
    this.addWeekDaysForm = this.fb.group({
      start_day: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required],
      end_day: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required]
    });
    this.editWeekDaysForm = this.fb.group({
      uuid: ['', ''],
      start_day: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required],
      end_day: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required]
    });
    this.addFSLRules = this.fb.group({
      name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required],
      numberoftimeframe: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required],
      noofforwardinglocation_1: ['', ''],
      noofforwardinglocation_2: ['', ''],
      noofforwardinglocation_3: ['', ''],
      noofforwardinglocation_4: ['', ''],
      noofforwardinglocation_5: ['', ''],
      noofforwardinglocation_6: ['', ''],
      noofforwardinglocation_7: ['', ''],
      // Day 1
      day_0: ['', ''],
      start_time_0: ['', ''],
      end_time_0: ['', ''],
      PrimaryforwardType_0_day0: ['', ''],
      number_0_day0: ['', ''],
      ivrMenu_0_day0: ['', ''],
      sipAdd_0_day0: ['', ''],
      PrimaryforwardType_1_day0: ['', ''],
      number_1_day0: ['', ''],
      ivrMenu_1_day0: ['', ''],
      sipAdd_1_day0: ['', ''],
      PrimaryforwardType_2_day0: ['', ''],
      number_2_day0: ['', ''],
      ivrMenu_2_day0: ['', ''],
      sipAdd_2_day0: ['', ''],
      PrimaryforwardType_3_day0: ['', ''],
      number_3_day0: ['', ''],
      ivrMenu_3_day0: ['', ''],
      sipAdd_3_day0: ['', ''],
      PrimaryforwardType_4_day0: ['', ''],
      number_4_day0: ['', ''],
      ivrMenu_4_day0: ['', ''],
      sipAdd_4_day0: ['', ''],
      PrimaryforwardType_5_day0: ['', ''],
      number_5_day0: ['', ''],
      ivrMenu_5_day0: ['', ''],
      sipAdd_5_day0: ['', ''],
      PrimaryforwardType_6_day0: ['', ''],
      number_6_day0: ['', ''],
      ivrMenu_6_day0: ['', ''],
      sipAdd_6_day0: ['', ''],
      PrimaryforwardType_7_day0: ['', ''],
      number_7_day0: ['', ''],
      ivrMenu_7_day0: ['', ''],
      sipAdd_7_day0: ['', ''],
      PrimaryforwardType_8_day0: ['', ''],
      number_8_day0: ['', ''],
      ivrMenu_8_day0: ['', ''],
      sipAdd_8_day0: ['', ''],
      PrimaryforwardType_9_day0: ['', ''],
      number_9_day0: ['', ''],
      ivrMenu_9_day0: ['', ''],
      sipAdd_9_day0: ['', ''],
      // Day2
      day_1: ['', ''],
      start_time_1: ['', ''],
      end_time_1: ['', ''],
      PrimaryforwardType_0_day1: ['', ''],
      number_0_day1: ['', ''],
      ivrMenu_0_day1: ['', ''],
      sipAdd_0_day1: ['', ''],
      PrimaryforwardType_1_day1: ['', ''],
      number_1_day1: ['', ''],
      ivrMenu_1_day1: ['', ''],
      sipAdd_1_day1: ['', ''],
      PrimaryforwardType_2_day1: ['', ''],
      number_2_day1: ['', ''],
      ivrMenu_2_day1: ['', ''],
      sipAdd_2_day1: ['', ''],
      PrimaryforwardType_3_day1: ['', ''],
      number_3_day1: ['', ''],
      ivrMenu_3_day1: ['', ''],
      sipAdd_3_day1: ['', ''],
      PrimaryforwardType_4_day1: ['', ''],
      number_4_day1: ['', ''],
      ivrMenu_4_day1: ['', ''],
      sipAdd_4_day1: ['', ''],
      PrimaryforwardType_5_day1: ['', ''],
      number_5_day1: ['', ''],
      ivrMenu_5_day1: ['', ''],
      sipAdd_5_day1: ['', ''],
      PrimaryforwardType_6_day1: ['', ''],
      number_6_day1: ['', ''],
      ivrMenu_6_day1: ['', ''],
      sipAdd_6_day1: ['', ''],
      PrimaryforwardType_7_day1: ['', ''],
      number_7_day1: ['', ''],
      ivrMenu_7_day1: ['', ''],
      sipAdd_7_day1: ['', ''],
      PrimaryforwardType_8_day1: ['', ''],
      number_8_day1: ['', ''],
      ivrMenu_8_day1: ['', ''],
      sipAdd_8_day1: ['', ''],
      PrimaryforwardType_9_day1: ['', ''],
      number_9_day1: ['', ''],
      ivrMenu_9_day1: ['', ''],
      sipAdd_9_day1: ['', ''],
      // Day3
      day_2: ['', ''],
      start_time_2: ['', ''],
      end_time_2: ['', ''],
      PrimaryforwardType_0_day2: ['', ''],
      number_0_day2: ['', ''],
      ivrMenu_0_day2: ['', ''],
      sipAdd_0_day2: ['', ''],
      PrimaryforwardType_1_day2: ['', ''],
      number_1_day2: ['', ''],
      ivrMenu_1_day2: ['', ''],
      sipAdd_1_day2: ['', ''],
      PrimaryforwardType_2_day2: ['', ''],
      number_2_day2: ['', ''],
      ivrMenu_2_day2: ['', ''],
      sipAdd_2_day2: ['', ''],
      PrimaryforwardType_3_day2: ['', ''],
      number_3_day2: ['', ''],
      ivrMenu_3_day2: ['', ''],
      sipAdd_3_day2: ['', ''],
      PrimaryforwardType_4_day2: ['', ''],
      number_4_day2: ['', ''],
      ivrMenu_4_day2: ['', ''],
      sipAdd_4_day2: ['', ''],
      PrimaryforwardType_5_day2: ['', ''],
      number_5_day2: ['', ''],
      ivrMenu_5_day2: ['', ''],
      sipAdd_5_day2: ['', ''],
      PrimaryforwardType_6_day2: ['', ''],
      number_6_day2: ['', ''],
      ivrMenu_6_day2: ['', ''],
      sipAdd_6_day2: ['', ''],
      PrimaryforwardType_7_day2: ['', ''],
      number_7_day2: ['', ''],
      ivrMenu_7_day2: ['', ''],
      sipAdd_7_day2: ['', ''],
      PrimaryforwardType_8_day2: ['', ''],
      number_8_day2: ['', ''],
      ivrMenu_8_day2: ['', ''],
      sipAdd_8_day2: ['', ''],
      PrimaryforwardType_9_day2: ['', ''],
      number_9_day2: ['', ''],
      ivrMenu_9_day2: ['', ''],
      sipAdd_9_day2: ['', ''],
      // Day4
      day_3: ['', ''],
      start_time_3: ['', ''],
      end_time_3: ['', ''],
      PrimaryforwardType_0_day3: ['', ''],
      number_0_day3: ['', ''],
      ivrMenu_0_day3: ['', ''],
      sipAdd_0_day3: ['', ''],
      PrimaryforwardType_1_day3: ['', ''],
      number_1_day3: ['', ''],
      ivrMenu_1_day3: ['', ''],
      sipAdd_1_day3: ['', ''],
      PrimaryforwardType_2_day3: ['', ''],
      number_2_day3: ['', ''],
      ivrMenu_2_day3: ['', ''],
      sipAdd_2_day3: ['', ''],
      PrimaryforwardType_3_day3: ['', ''],
      number_3_day3: ['', ''],
      ivrMenu_3_day3: ['', ''],
      sipAdd_3_day3: ['', ''],
      PrimaryforwardType_4_day3: ['', ''],
      number_4_day3: ['', ''],
      ivrMenu_4_day3: ['', ''],
      sipAdd_4_day3: ['', ''],
      PrimaryforwardType_5_day3: ['', ''],
      number_5_day3: ['', ''],
      ivrMenu_5_day3: ['', ''],
      sipAdd_5_day3: ['', ''],
      PrimaryforwardType_6_day3: ['', ''],
      number_6_day3: ['', ''],
      ivrMenu_6_day3: ['', ''],
      sipAdd_6_day3: ['', ''],
      PrimaryforwardType_7_day3: ['', ''],
      number_7_day3: ['', ''],
      ivrMenu_7_day3: ['', ''],
      sipAdd_7_day3: ['', ''],
      PrimaryforwardType_8_day3: ['', ''],
      number_8_day3: ['', ''],
      ivrMenu_8_day3: ['', ''],
      sipAdd_8_day3: ['', ''],
      PrimaryforwardType_9_day3: ['', ''],
      number_9_day3: ['', ''],
      ivrMenu_9_day3: ['', ''],
      sipAdd_9_day3: ['', ''],
      // Day5
      day_4: ['', ''],
      start_time_4: ['', ''],
      end_time_4: ['', ''],
      PrimaryforwardType_0_day4: ['', ''],
      number_0_day4: ['', ''],
      ivrMenu_0_day4: ['', ''],
      sipAdd_0_day4: ['', ''],
      PrimaryforwardType_1_day4: ['', ''],
      number_1_day4: ['', ''],
      ivrMenu_1_day4: ['', ''],
      sipAdd_1_day4: ['', ''],
      PrimaryforwardType_2_day4: ['', ''],
      number_2_day4: ['', ''],
      ivrMenu_2_day4: ['', ''],
      sipAdd_2_day4: ['', ''],
      PrimaryforwardType_3_day4: ['', ''],
      number_3_day4: ['', ''],
      ivrMenu_3_day4: ['', ''],
      sipAdd_3_day4: ['', ''],
      PrimaryforwardType_4_day4: ['', ''],
      number_4_day4: ['', ''],
      ivrMenu_4_day4: ['', ''],
      sipAdd_4_day4: ['', ''],
      PrimaryforwardType_5_day4: ['', ''],
      number_5_day4: ['', ''],
      ivrMenu_5_day4: ['', ''],
      sipAdd_5_day4: ['', ''],
      PrimaryforwardType_6_day4: ['', ''],
      number_6_day4: ['', ''],
      ivrMenu_6_day4: ['', ''],
      sipAdd_6_day4: ['', ''],
      PrimaryforwardType_7_day4: ['', ''],
      number_7_day4: ['', ''],
      ivrMenu_7_day4: ['', ''],
      sipAdd_7_day4: ['', ''],
      PrimaryforwardType_8_day4: ['', ''],
      number_8_day4: ['', ''],
      ivrMenu_8_day4: ['', ''],
      sipAdd_8_day4: ['', ''],
      PrimaryforwardType_9_day4: ['', ''],
      number_9_day4: ['', ''],
      ivrMenu_9_day4: ['', ''],
      sipAdd_9_day4: ['', ''],
      // Day6
      day_5: ['', ''],
      start_time_5: ['', ''],
      end_time_5: ['', ''],
      PrimaryforwardType_0_day5: ['', ''],
      number_0_day5: ['', ''],
      ivrMenu_0_day5: ['', ''],
      sipAdd_0_day5: ['', ''],
      PrimaryforwardType_1_day5: ['', ''],
      number_1_day5: ['', ''],
      ivrMenu_1_day5: ['', ''],
      sipAdd_1_day5: ['', ''],
      PrimaryforwardType_2_day5: ['', ''],
      number_2_day5: ['', ''],
      ivrMenu_2_day5: ['', ''],
      sipAdd_2_day5: ['', ''],
      PrimaryforwardType_3_day5: ['', ''],
      number_3_day5: ['', ''],
      ivrMenu_3_day5: ['', ''],
      sipAdd_3_day5: ['', ''],
      PrimaryforwardType_4_day5: ['', ''],
      number_4_day5: ['', ''],
      ivrMenu_4_day5: ['', ''],
      sipAdd_4_day5: ['', ''],
      PrimaryforwardType_5_day5: ['', ''],
      number_5_day5: ['', ''],
      ivrMenu_5_day5: ['', ''],
      sipAdd_5_day5: ['', ''],
      PrimaryforwardType_6_day5: ['', ''],
      number_6_day5: ['', ''],
      ivrMenu_6_day5: ['', ''],
      sipAdd_6_day5: ['', ''],
      PrimaryforwardType_7_day5: ['', ''],
      number_7_day5: ['', ''],
      ivrMenu_7_day5: ['', ''],
      sipAdd_7_day5: ['', ''],
      PrimaryforwardType_8_day5: ['', ''],
      number_8_day5: ['', ''],
      ivrMenu_8_day5: ['', ''],
      sipAdd_8_day5: ['', ''],
      PrimaryforwardType_9_day5: ['', ''],
      number_9_day5: ['', ''],
      ivrMenu_9_day5: ['', ''],
      sipAdd_9_day5: ['', ''],
      // Day7
      day_6: ['', ''],
      start_time_6: ['', ''],
      end_time_6: ['', ''],
      PrimaryforwardType_0_day6: ['', ''],
      number_0_day6: ['', ''],
      ivrMenu_0_day6: ['', ''],
      sipAdd_0_day6: ['', ''],
      PrimaryforwardType_1_day6: ['', ''],
      number_1_day6: ['', ''],
      ivrMenu_1_day6: ['', ''],
      sipAdd_1_day6: ['', ''],
      PrimaryforwardType_2_day6: ['', ''],
      number_2_day6: ['', ''],
      ivrMenu_2_day6: ['', ''],
      sipAdd_2_day6: ['', ''],
      PrimaryforwardType_3_day6: ['', ''],
      number_3_day6: ['', ''],
      ivrMenu_3_day6: ['', ''],
      sipAdd_3_day6: ['', ''],
      PrimaryforwardType_4_day6: ['', ''],
      number_4_day6: ['', ''],
      ivrMenu_4_day6: ['', ''],
      sipAdd_4_day6: ['', ''],
      PrimaryforwardType_5_day6: ['', ''],
      number_5_day6: ['', ''],
      ivrMenu_5_day6: ['', ''],
      sipAdd_5_day6: ['', ''],
      PrimaryforwardType_6_day6: ['', ''],
      number_6_day6: ['', ''],
      ivrMenu_6_day6: ['', ''],
      sipAdd_6_day6: ['', ''],
      PrimaryforwardType_7_day6: ['', ''],
      number_7_day6: ['', ''],
      ivrMenu_7_day6: ['', ''],
      sipAdd_7_day6: ['', ''],
      PrimaryforwardType_8_day6: ['', ''],
      number_8_day6: ['', ''],
      ivrMenu_8_day6: ['', ''],
      sipAdd_8_day6: ['', ''],
      PrimaryforwardType_9_day6: ['', ''],
      number_9_day6: ['', ''],
      ivrMenu_9_day6: ['', ''],
      sipAdd_9_day6: ['', '']
    });
    this.editFSLRules = this.fb.group({
      rulename: ['', ''],
      numberoftimeframe: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required],
      noofforwardinglocation_1: ['', ''],
      noofforwardinglocation_2: ['', ''],
      noofforwardinglocation_3: ['', ''],
      noofforwardinglocation_4: ['', ''],
      noofforwardinglocation_5: ['', ''],
      noofforwardinglocation_6: ['', ''],
      noofforwardinglocation_7: ['', ''],
      // Day 1
      day_0: ['', ''],
      start_time_0: ['', ''],
      end_time_0: ['', ''],
      PrimaryforwardType_0_day0: ['', ''],
      number_0_day0: ['', ''],
      ivrMenu_0_day0: ['', ''],
      sipAdd_0_day0: ['', ''],
      PrimaryforwardType_1_day0: ['', ''],
      number_1_day0: ['', ''],
      ivrMenu_1_day0: ['', ''],
      sipAdd_1_day0: ['', ''],
      PrimaryforwardType_2_day0: ['', ''],
      number_2_day0: ['', ''],
      ivrMenu_2_day0: ['', ''],
      sipAdd_2_day0: ['', ''],
      PrimaryforwardType_3_day0: ['', ''],
      number_3_day0: ['', ''],
      ivrMenu_3_day0: ['', ''],
      sipAdd_3_day0: ['', ''],
      PrimaryforwardType_4_day0: ['', ''],
      number_4_day0: ['', ''],
      ivrMenu_4_day0: ['', ''],
      sipAdd_4_day0: ['', ''],
      PrimaryforwardType_5_day0: ['', ''],
      number_5_day0: ['', ''],
      ivrMenu_5_day0: ['', ''],
      sipAdd_5_day0: ['', ''],
      PrimaryforwardType_6_day0: ['', ''],
      number_6_day0: ['', ''],
      ivrMenu_6_day0: ['', ''],
      sipAdd_6_day0: ['', ''],
      PrimaryforwardType_7_day0: ['', ''],
      number_7_day0: ['', ''],
      ivrMenu_7_day0: ['', ''],
      sipAdd_7_day0: ['', ''],
      PrimaryforwardType_8_day0: ['', ''],
      number_8_day0: ['', ''],
      ivrMenu_8_day0: ['', ''],
      sipAdd_8_day0: ['', ''],
      PrimaryforwardType_9_day0: ['', ''],
      number_9_day0: ['', ''],
      ivrMenu_9_day0: ['', ''],
      sipAdd_9_day0: ['', ''],
      // Day2
      day_1: ['', ''],
      start_time_1: ['', ''],
      end_time_1: ['', ''],
      PrimaryforwardType_0_day1: ['', ''],
      number_0_day1: ['', ''],
      ivrMenu_0_day1: ['', ''],
      sipAdd_0_day1: ['', ''],
      PrimaryforwardType_1_day1: ['', ''],
      number_1_day1: ['', ''],
      ivrMenu_1_day1: ['', ''],
      sipAdd_1_day1: ['', ''],
      PrimaryforwardType_2_day1: ['', ''],
      number_2_day1: ['', ''],
      ivrMenu_2_day1: ['', ''],
      sipAdd_2_day1: ['', ''],
      PrimaryforwardType_3_day1: ['', ''],
      number_3_day1: ['', ''],
      ivrMenu_3_day1: ['', ''],
      sipAdd_3_day1: ['', ''],
      PrimaryforwardType_4_day1: ['', ''],
      number_4_day1: ['', ''],
      ivrMenu_4_day1: ['', ''],
      sipAdd_4_day1: ['', ''],
      PrimaryforwardType_5_day1: ['', ''],
      number_5_day1: ['', ''],
      ivrMenu_5_day1: ['', ''],
      sipAdd_5_day1: ['', ''],
      PrimaryforwardType_6_day1: ['', ''],
      number_6_day1: ['', ''],
      ivrMenu_6_day1: ['', ''],
      sipAdd_6_day1: ['', ''],
      PrimaryforwardType_7_day1: ['', ''],
      number_7_day1: ['', ''],
      ivrMenu_7_day1: ['', ''],
      sipAdd_7_day1: ['', ''],
      PrimaryforwardType_8_day1: ['', ''],
      number_8_day1: ['', ''],
      ivrMenu_8_day1: ['', ''],
      sipAdd_8_day1: ['', ''],
      PrimaryforwardType_9_day1: ['', ''],
      number_9_day1: ['', ''],
      ivrMenu_9_day1: ['', ''],
      sipAdd_9_day1: ['', ''],
      // Day3
      day_2: ['', ''],
      start_time_2: ['', ''],
      end_time_2: ['', ''],
      PrimaryforwardType_0_day2: ['', ''],
      number_0_day2: ['', ''],
      ivrMenu_0_day2: ['', ''],
      sipAdd_0_day2: ['', ''],
      PrimaryforwardType_1_day2: ['', ''],
      number_1_day2: ['', ''],
      ivrMenu_1_day2: ['', ''],
      sipAdd_1_day2: ['', ''],
      PrimaryforwardType_2_day2: ['', ''],
      number_2_day2: ['', ''],
      ivrMenu_2_day2: ['', ''],
      sipAdd_2_day2: ['', ''],
      PrimaryforwardType_3_day2: ['', ''],
      number_3_day2: ['', ''],
      ivrMenu_3_day2: ['', ''],
      sipAdd_3_day2: ['', ''],
      PrimaryforwardType_4_day2: ['', ''],
      number_4_day2: ['', ''],
      ivrMenu_4_day2: ['', ''],
      sipAdd_4_day2: ['', ''],
      PrimaryforwardType_5_day2: ['', ''],
      number_5_day2: ['', ''],
      ivrMenu_5_day2: ['', ''],
      sipAdd_5_day2: ['', ''],
      PrimaryforwardType_6_day2: ['', ''],
      number_6_day2: ['', ''],
      ivrMenu_6_day2: ['', ''],
      sipAdd_6_day2: ['', ''],
      PrimaryforwardType_7_day2: ['', ''],
      number_7_day2: ['', ''],
      ivrMenu_7_day2: ['', ''],
      sipAdd_7_day2: ['', ''],
      PrimaryforwardType_8_day2: ['', ''],
      number_8_day2: ['', ''],
      ivrMenu_8_day2: ['', ''],
      sipAdd_8_day2: ['', ''],
      PrimaryforwardType_9_day2: ['', ''],
      number_9_day2: ['', ''],
      ivrMenu_9_day2: ['', ''],
      sipAdd_9_day2: ['', ''],
      // Day4
      day_3: ['', ''],
      start_time_3: ['', ''],
      end_time_3: ['', ''],
      PrimaryforwardType_0_day3: ['', ''],
      number_0_day3: ['', ''],
      ivrMenu_0_day3: ['', ''],
      sipAdd_0_day3: ['', ''],
      PrimaryforwardType_1_day3: ['', ''],
      number_1_day3: ['', ''],
      ivrMenu_1_day3: ['', ''],
      sipAdd_1_day3: ['', ''],
      PrimaryforwardType_2_day3: ['', ''],
      number_2_day3: ['', ''],
      ivrMenu_2_day3: ['', ''],
      sipAdd_2_day3: ['', ''],
      PrimaryforwardType_3_day3: ['', ''],
      number_3_day3: ['', ''],
      ivrMenu_3_day3: ['', ''],
      sipAdd_3_day3: ['', ''],
      PrimaryforwardType_4_day3: ['', ''],
      number_4_day3: ['', ''],
      ivrMenu_4_day3: ['', ''],
      sipAdd_4_day3: ['', ''],
      PrimaryforwardType_5_day3: ['', ''],
      number_5_day3: ['', ''],
      ivrMenu_5_day3: ['', ''],
      sipAdd_5_day3: ['', ''],
      PrimaryforwardType_6_day3: ['', ''],
      number_6_day3: ['', ''],
      ivrMenu_6_day3: ['', ''],
      sipAdd_6_day3: ['', ''],
      PrimaryforwardType_7_day3: ['', ''],
      number_7_day3: ['', ''],
      ivrMenu_7_day3: ['', ''],
      sipAdd_7_day3: ['', ''],
      PrimaryforwardType_8_day3: ['', ''],
      number_8_day3: ['', ''],
      ivrMenu_8_day3: ['', ''],
      sipAdd_8_day3: ['', ''],
      PrimaryforwardType_9_day3: ['', ''],
      number_9_day3: ['', ''],
      ivrMenu_9_day3: ['', ''],
      sipAdd_9_day3: ['', ''],
      // Day5
      day_4: ['', ''],
      start_time_4: ['', ''],
      end_time_4: ['', ''],
      PrimaryforwardType_0_day4: ['', ''],
      number_0_day4: ['', ''],
      ivrMenu_0_day4: ['', ''],
      sipAdd_0_day4: ['', ''],
      PrimaryforwardType_1_day4: ['', ''],
      number_1_day4: ['', ''],
      ivrMenu_1_day4: ['', ''],
      sipAdd_1_day4: ['', ''],
      PrimaryforwardType_2_day4: ['', ''],
      number_2_day4: ['', ''],
      ivrMenu_2_day4: ['', ''],
      sipAdd_2_day4: ['', ''],
      PrimaryforwardType_3_day4: ['', ''],
      number_3_day4: ['', ''],
      ivrMenu_3_day4: ['', ''],
      sipAdd_3_day4: ['', ''],
      PrimaryforwardType_4_day4: ['', ''],
      number_4_day4: ['', ''],
      ivrMenu_4_day4: ['', ''],
      sipAdd_4_day4: ['', ''],
      PrimaryforwardType_5_day4: ['', ''],
      number_5_day4: ['', ''],
      ivrMenu_5_day4: ['', ''],
      sipAdd_5_day4: ['', ''],
      PrimaryforwardType_6_day4: ['', ''],
      number_6_day4: ['', ''],
      ivrMenu_6_day4: ['', ''],
      sipAdd_6_day4: ['', ''],
      PrimaryforwardType_7_day4: ['', ''],
      number_7_day4: ['', ''],
      ivrMenu_7_day4: ['', ''],
      sipAdd_7_day4: ['', ''],
      PrimaryforwardType_8_day4: ['', ''],
      number_8_day4: ['', ''],
      ivrMenu_8_day4: ['', ''],
      sipAdd_8_day4: ['', ''],
      PrimaryforwardType_9_day4: ['', ''],
      number_9_day4: ['', ''],
      ivrMenu_9_day4: ['', ''],
      sipAdd_9_day4: ['', ''],
      // Day6
      day_5: ['', ''],
      start_time_5: ['', ''],
      end_time_5: ['', ''],
      PrimaryforwardType_0_day5: ['', ''],
      number_0_day5: ['', ''],
      ivrMenu_0_day5: ['', ''],
      sipAdd_0_day5: ['', ''],
      PrimaryforwardType_1_day5: ['', ''],
      number_1_day5: ['', ''],
      ivrMenu_1_day5: ['', ''],
      sipAdd_1_day5: ['', ''],
      PrimaryforwardType_2_day5: ['', ''],
      number_2_day5: ['', ''],
      ivrMenu_2_day5: ['', ''],
      sipAdd_2_day5: ['', ''],
      PrimaryforwardType_3_day5: ['', ''],
      number_3_day5: ['', ''],
      ivrMenu_3_day5: ['', ''],
      sipAdd_3_day5: ['', ''],
      PrimaryforwardType_4_day5: ['', ''],
      number_4_day5: ['', ''],
      ivrMenu_4_day5: ['', ''],
      sipAdd_4_day5: ['', ''],
      PrimaryforwardType_5_day5: ['', ''],
      number_5_day5: ['', ''],
      ivrMenu_5_day5: ['', ''],
      sipAdd_5_day5: ['', ''],
      PrimaryforwardType_6_day5: ['', ''],
      number_6_day5: ['', ''],
      ivrMenu_6_day5: ['', ''],
      sipAdd_6_day5: ['', ''],
      PrimaryforwardType_7_day5: ['', ''],
      number_7_day5: ['', ''],
      ivrMenu_7_day5: ['', ''],
      sipAdd_7_day5: ['', ''],
      PrimaryforwardType_8_day5: ['', ''],
      number_8_day5: ['', ''],
      ivrMenu_8_day5: ['', ''],
      sipAdd_8_day5: ['', ''],
      PrimaryforwardType_9_day5: ['', ''],
      number_9_day5: ['', ''],
      ivrMenu_9_day5: ['', ''],
      sipAdd_9_day5: ['', ''],
      // Day7
      day_6: ['', ''],
      start_time_6: ['', ''],
      end_time_6: ['', ''],
      PrimaryforwardType_0_day6: ['', ''],
      number_0_day6: ['', ''],
      ivrMenu_0_day6: ['', ''],
      sipAdd_0_day6: ['', ''],
      PrimaryforwardType_1_day6: ['', ''],
      number_1_day6: ['', ''],
      ivrMenu_1_day6: ['', ''],
      sipAdd_1_day6: ['', ''],
      PrimaryforwardType_2_day6: ['', ''],
      number_2_day6: ['', ''],
      ivrMenu_2_day6: ['', ''],
      sipAdd_2_day6: ['', ''],
      PrimaryforwardType_3_day6: ['', ''],
      number_3_day6: ['', ''],
      ivrMenu_3_day6: ['', ''],
      sipAdd_3_day6: ['', ''],
      PrimaryforwardType_4_day6: ['', ''],
      number_4_day6: ['', ''],
      ivrMenu_4_day6: ['', ''],
      sipAdd_4_day6: ['', ''],
      PrimaryforwardType_5_day6: ['', ''],
      number_5_day6: ['', ''],
      ivrMenu_5_day6: ['', ''],
      sipAdd_5_day6: ['', ''],
      PrimaryforwardType_6_day6: ['', ''],
      number_6_day6: ['', ''],
      ivrMenu_6_day6: ['', ''],
      sipAdd_6_day6: ['', ''],
      PrimaryforwardType_7_day6: ['', ''],
      number_7_day6: ['', ''],
      ivrMenu_7_day6: ['', ''],
      sipAdd_7_day6: ['', ''],
      PrimaryforwardType_8_day6: ['', ''],
      number_8_day6: ['', ''],
      ivrMenu_8_day6: ['', ''],
      sipAdd_8_day6: ['', ''],
      PrimaryforwardType_9_day6: ['', ''],
      number_9_day6: ['', ''],
      ivrMenu_9_day6: ['', ''],
      sipAdd_9_day6: ['', '']
    });
  }
  loadweekdays() {
    if ($.fn.DataTable.isDataTable(this.daysTable.nativeElement)) {
      $(this.daysTable.nativeElement).dataTable().fnDestroy();
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.dtOptions = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "pageLength": 20,
      "order": [[1, "desc"]],
      ajax: (dataTablesParameters, callback) => {
        this.http.post(this.ServerUrl + 'getallweekdays/' + this.currentCompany.uuid, dataTablesParameters, {}).subscribe(resp => {
          // console.log(resp);return false;
          this.days = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [{
        data: "start_day"
      }, {
        data: "end_day"
      }, {
        data: "created_at"
      }, {
        data: "action"
      }]
    };
    this.daysdataTable = $(this.daysTable.nativeElement);
    this.daysdataTable.dataTable(this.dtOptions);
  }
  closeModal() {
    if (this.noofforwarding) {
      $("#addFSLRules").modal("hide");
      setTimeout(() => {
        this.FSLRulesSubmitted = false;
        this.addFSLRules.reset();
        this.isName = "";
        this.getAllRules();
      }, 2000);
    }
  }
  addweekcloseModal() {
    if (this.addWeekDaysForm.get('start_day').value && this.addWeekDaysForm.get('end_day').value) {
      $("#addWeekDays").modal("hide");
      setTimeout(() => {
        this.daysSubmitted = false;
        this.addWeekDaysForm.reset({
          'start_day': '',
          'end_day': ''
        });
      }, 2000);
    }
  }
  editweekcloseModal() {
    if (this.editWeekDaysForm.get('start_day').value && this.editWeekDaysForm.get('end_day').value) {
      $("#editweekdays").modal("hide");
      setTimeout(() => {}, 2000);
    }
  }
  loadallweekdays() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleService.loadallweekdays(this.currentCompany.uuid).subscribe(res => {
      //  console.log(res); return false;  
      this.allweekdays = res.data;
    }, error => this.error = error);
  }
  getAllRules() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleService.getAllRules(this.currentCompany.uuid).subscribe(res => {
      //  console.log(res); return false;  
      this.allRulesData = res;
    }, error => this.error = error);
  }
  getAllLabels() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleService.getAllLabels(this.currentCompany.uuid).subscribe(res => {
      this.dropdownList = res;
    }, error => this.error = error);
  }
  getRulesByName(name) {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleService.getRulesByName(name, this.currentCompany.uuid).subscribe(res => {
      this.allRulesbyname = res;
    }, error => this.error = error);
  }
  _keyPress(event) {
    const isNumericInput = event => {
      const key = event.keyCode;
      return key >= 48 && key <= 57 ||
      // Allow number line
      key >= 96 && key <= 105 // Allow number pad
      ;
    };

    const isModifierKey = event => {
      const key = event.keyCode;
      return event.shiftKey === true || key === 35 || key === 36 ||
      // Allow Shift, Home, End
      key === 8 || key === 9 || key === 13 || key === 46 ||
      // Allow Backspace, Tab, Enter, Delete
      key > 36 && key < 41 ||
      // Allow left, up, right, down

      // Allow Ctrl/Command + A,C,V,X,Z
      (event.ctrlKey === true || event.metaKey === true) && (key === 65 || key === 67 || key === 86 || key === 88 || key === 90);
    };
    const enforceFormat = event => {
      // Input must be of a valid number format or a modifier key, and not longer than ten digits
      if (!isNumericInput(event) && !isModifierKey(event)) {
        event.preventDefault();
      }
    };
    const formatToPhone = event => {
      if (isModifierKey(event)) {
        return;
      }
      const target = event.target;
      const input = event.target.value.replace(/\D/g, '').substring(0, 10); // First ten digits of input only
      const zip = input.substring(0, 3);
      const middle = input.substring(3, 6);
      const last = input.substring(6, 10);
      if (input.length > 6) {
        target.value = `(${zip}) ${middle}-${last}`;
      } else if (input.length > 3) {
        target.value = `(${zip}) ${middle}`;
      } else if (input.length > 0) {
        target.value = `(${zip}`;
      }
    };
    const inputElement = document.getElementById('number');
    const number_0_day0 = document.getElementById('number_0_day0');
    const number_1_day0 = document.getElementById('number_1_day0');
    const number_2_day0 = document.getElementById('number_2_day0');
    const number_3_day0 = document.getElementById('number_3_day0');
    const number_4_day0 = document.getElementById('number_4_day0');
    const number_5_day0 = document.getElementById('number_5_day0');
    const number_6_day0 = document.getElementById('number_6_day0');
    const number_7_day0 = document.getElementById('number_7_day0');
    const number_8_day0 = document.getElementById('number_8_day0');
    const number_9_day0 = document.getElementById('number_9_day0');
    const number_0_day1 = document.getElementById('number_0_day1');
    const number_1_day1 = document.getElementById('number_1_day1');
    const number_2_day1 = document.getElementById('number_2_day1');
    const number_3_day1 = document.getElementById('number_3_day1');
    const number_4_day1 = document.getElementById('number_4_day1');
    const number_5_day1 = document.getElementById('number_5_day1');
    const number_6_day1 = document.getElementById('number_6_day1');
    const number_7_day1 = document.getElementById('number_7_day1');
    const number_8_day1 = document.getElementById('number_8_day1');
    const number_9_day1 = document.getElementById('number_9_day1');
    const number_0_day2 = document.getElementById('number_0_day2');
    const number_1_day2 = document.getElementById('number_1_day2');
    const number_2_day2 = document.getElementById('number_2_day2');
    const number_3_day2 = document.getElementById('number_3_day2');
    const number_4_day2 = document.getElementById('number_4_day2');
    const number_5_day2 = document.getElementById('number_5_day2');
    const number_6_day2 = document.getElementById('number_6_day2');
    const number_7_day2 = document.getElementById('number_7_day2');
    const number_8_day2 = document.getElementById('number_8_day2');
    const number_9_day2 = document.getElementById('number_9_day2');
    const number_0_day3 = document.getElementById('number_0_day3');
    const number_1_day3 = document.getElementById('number_1_day3');
    const number_2_day3 = document.getElementById('number_2_day3');
    const number_3_day3 = document.getElementById('number_3_day3');
    const number_4_day3 = document.getElementById('number_4_day3');
    const number_5_day3 = document.getElementById('number_5_day3');
    const number_6_day3 = document.getElementById('number_6_day3');
    const number_7_day3 = document.getElementById('number_7_day3');
    const number_8_day3 = document.getElementById('number_8_day3');
    const number_9_day3 = document.getElementById('number_9_day3');
    const number_0_day4 = document.getElementById('number_0_day4');
    const number_1_day4 = document.getElementById('number_1_day4');
    const number_2_day4 = document.getElementById('number_2_day4');
    const number_3_day4 = document.getElementById('number_3_day4');
    const number_4_day4 = document.getElementById('number_4_day4');
    const number_5_day4 = document.getElementById('number_5_day4');
    const number_6_day4 = document.getElementById('number_6_day4');
    const number_7_day4 = document.getElementById('number_7_day4');
    const number_8_day4 = document.getElementById('number_8_day4');
    const number_9_day4 = document.getElementById('number_9_day4');
    const number_0_day5 = document.getElementById('number_0_day5');
    const number_1_day5 = document.getElementById('number_1_day5');
    const number_2_day5 = document.getElementById('number_2_day5');
    const number_3_day5 = document.getElementById('number_3_day5');
    const number_4_day5 = document.getElementById('number_4_day5');
    const number_5_day5 = document.getElementById('number_5_day5');
    const number_6_day5 = document.getElementById('number_6_day5');
    const number_7_day5 = document.getElementById('number_7_day5');
    const number_8_day5 = document.getElementById('number_8_day5');
    const number_9_day5 = document.getElementById('number_9_day5');
    const number_0_day6 = document.getElementById('number_0_day6');
    const number_1_day6 = document.getElementById('number_1_day6');
    const number_2_day6 = document.getElementById('number_2_day6');
    const number_3_day6 = document.getElementById('number_3_day6');
    const number_4_day6 = document.getElementById('number_4_day6');
    const number_5_day6 = document.getElementById('number_5_day6');
    const number_6_day6 = document.getElementById('number_6_day6');
    const number_7_day6 = document.getElementById('number_7_day6');
    const number_8_day6 = document.getElementById('number_8_day6');
    const number_9_day6 = document.getElementById('number_9_day6');
    if (inputElement) {
      inputElement.addEventListener('keydown', enforceFormat);
      inputElement.addEventListener('keyup', formatToPhone);
    }
    if (number_0_day0) {
      number_0_day0.addEventListener('keydown', enforceFormat);
      number_0_day0.addEventListener('keyup', formatToPhone);
    }
    if (number_1_day0) {
      number_1_day0.addEventListener('keydown', enforceFormat);
      number_1_day0.addEventListener('keyup', formatToPhone);
    }
    if (number_2_day0) {
      number_2_day0.addEventListener('keydown', enforceFormat);
      number_2_day0.addEventListener('keyup', formatToPhone);
    }
    if (number_3_day0) {
      number_3_day0.addEventListener('keydown', enforceFormat);
      number_3_day0.addEventListener('keyup', formatToPhone);
    }
    if (number_4_day0) {
      number_4_day0.addEventListener('keydown', enforceFormat);
      number_4_day0.addEventListener('keyup', formatToPhone);
    }
    if (number_5_day0) {
      number_5_day0.addEventListener('keydown', enforceFormat);
      number_5_day0.addEventListener('keyup', formatToPhone);
    }
    if (number_6_day0) {
      number_6_day0.addEventListener('keydown', enforceFormat);
      number_6_day0.addEventListener('keyup', formatToPhone);
    }
    if (number_7_day0) {
      number_7_day0.addEventListener('keydown', enforceFormat);
      number_7_day0.addEventListener('keyup', formatToPhone);
    }
    if (number_8_day0) {
      number_8_day0.addEventListener('keydown', enforceFormat);
      number_8_day0.addEventListener('keyup', formatToPhone);
    }
    if (number_9_day0) {
      number_9_day0.addEventListener('keydown', enforceFormat);
      number_9_day0.addEventListener('keyup', formatToPhone);
    }
    if (number_0_day1) {
      number_0_day1.addEventListener('keydown', enforceFormat);
      number_0_day1.addEventListener('keyup', formatToPhone);
    }
    if (number_1_day1) {
      number_1_day1.addEventListener('keydown', enforceFormat);
      number_1_day1.addEventListener('keyup', formatToPhone);
    }
    if (number_2_day1) {
      number_2_day1.addEventListener('keydown', enforceFormat);
      number_2_day1.addEventListener('keyup', formatToPhone);
    }
    if (number_3_day1) {
      number_3_day1.addEventListener('keydown', enforceFormat);
      number_3_day1.addEventListener('keyup', formatToPhone);
    }
    if (number_4_day1) {
      number_4_day1.addEventListener('keydown', enforceFormat);
      number_4_day1.addEventListener('keyup', formatToPhone);
    }
    if (number_5_day1) {
      number_5_day1.addEventListener('keydown', enforceFormat);
      number_5_day1.addEventListener('keyup', formatToPhone);
    }
    if (number_6_day1) {
      number_6_day1.addEventListener('keydown', enforceFormat);
      number_6_day1.addEventListener('keyup', formatToPhone);
    }
    if (number_7_day1) {
      number_7_day1.addEventListener('keydown', enforceFormat);
      number_7_day1.addEventListener('keyup', formatToPhone);
    }
    if (number_8_day1) {
      number_8_day1.addEventListener('keydown', enforceFormat);
      number_8_day1.addEventListener('keyup', formatToPhone);
    }
    if (number_9_day1) {
      number_9_day1.addEventListener('keydown', enforceFormat);
      number_9_day1.addEventListener('keyup', formatToPhone);
    }
    if (number_0_day2) {
      number_0_day2.addEventListener('keydown', enforceFormat);
      number_0_day2.addEventListener('keyup', formatToPhone);
    }
    if (number_1_day2) {
      number_1_day2.addEventListener('keydown', enforceFormat);
      number_1_day2.addEventListener('keyup', formatToPhone);
    }
    if (number_2_day2) {
      number_2_day2.addEventListener('keydown', enforceFormat);
      number_2_day2.addEventListener('keyup', formatToPhone);
    }
    if (number_3_day2) {
      number_3_day2.addEventListener('keydown', enforceFormat);
      number_3_day2.addEventListener('keyup', formatToPhone);
    }
    if (number_4_day2) {
      number_4_day2.addEventListener('keydown', enforceFormat);
      number_4_day2.addEventListener('keyup', formatToPhone);
    }
    if (number_5_day2) {
      number_5_day2.addEventListener('keydown', enforceFormat);
      number_5_day2.addEventListener('keyup', formatToPhone);
    }
    if (number_6_day2) {
      number_6_day2.addEventListener('keydown', enforceFormat);
      number_6_day2.addEventListener('keyup', formatToPhone);
    }
    if (number_7_day2) {
      number_7_day2.addEventListener('keydown', enforceFormat);
      number_7_day2.addEventListener('keyup', formatToPhone);
    }
    if (number_8_day2) {
      number_8_day2.addEventListener('keydown', enforceFormat);
      number_8_day2.addEventListener('keyup', formatToPhone);
    }
    if (number_9_day2) {
      number_9_day2.addEventListener('keydown', enforceFormat);
      number_9_day2.addEventListener('keyup', formatToPhone);
    }
    if (number_0_day3) {
      number_0_day3.addEventListener('keydown', enforceFormat);
      number_0_day3.addEventListener('keyup', formatToPhone);
    }
    if (number_1_day3) {
      number_1_day3.addEventListener('keydown', enforceFormat);
      number_1_day3.addEventListener('keyup', formatToPhone);
    }
    if (number_2_day3) {
      number_2_day3.addEventListener('keydown', enforceFormat);
      number_2_day3.addEventListener('keyup', formatToPhone);
    }
    if (number_3_day3) {
      number_3_day3.addEventListener('keydown', enforceFormat);
      number_3_day3.addEventListener('keyup', formatToPhone);
    }
    if (number_4_day3) {
      number_4_day3.addEventListener('keydown', enforceFormat);
      number_4_day3.addEventListener('keyup', formatToPhone);
    }
    if (number_5_day3) {
      number_5_day3.addEventListener('keydown', enforceFormat);
      number_5_day3.addEventListener('keyup', formatToPhone);
    }
    if (number_6_day3) {
      number_6_day3.addEventListener('keydown', enforceFormat);
      number_6_day3.addEventListener('keyup', formatToPhone);
    }
    if (number_7_day3) {
      number_7_day3.addEventListener('keydown', enforceFormat);
      number_7_day3.addEventListener('keyup', formatToPhone);
    }
    if (number_8_day3) {
      number_8_day3.addEventListener('keydown', enforceFormat);
      number_8_day3.addEventListener('keyup', formatToPhone);
    }
    if (number_9_day3) {
      number_9_day3.addEventListener('keydown', enforceFormat);
      number_9_day3.addEventListener('keyup', formatToPhone);
    }
    if (number_0_day4) {
      number_0_day4.addEventListener('keydown', enforceFormat);
      number_0_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_1_day4) {
      number_1_day4.addEventListener('keydown', enforceFormat);
      number_1_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_2_day4) {
      number_2_day4.addEventListener('keydown', enforceFormat);
      number_2_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_3_day4) {
      number_3_day4.addEventListener('keydown', enforceFormat);
      number_3_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_4_day4) {
      number_4_day4.addEventListener('keydown', enforceFormat);
      number_4_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_5_day4) {
      number_5_day4.addEventListener('keydown', enforceFormat);
      number_5_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_6_day4) {
      number_6_day4.addEventListener('keydown', enforceFormat);
      number_6_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_7_day4) {
      number_7_day4.addEventListener('keydown', enforceFormat);
      number_7_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_8_day4) {
      number_8_day4.addEventListener('keydown', enforceFormat);
      number_8_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_9_day4) {
      number_9_day4.addEventListener('keydown', enforceFormat);
      number_9_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_0_day4) {
      number_0_day4.addEventListener('keydown', enforceFormat);
      number_0_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_1_day4) {
      number_1_day4.addEventListener('keydown', enforceFormat);
      number_1_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_2_day4) {
      number_2_day4.addEventListener('keydown', enforceFormat);
      number_2_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_3_day4) {
      number_3_day4.addEventListener('keydown', enforceFormat);
      number_3_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_4_day4) {
      number_4_day4.addEventListener('keydown', enforceFormat);
      number_4_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_5_day4) {
      number_5_day4.addEventListener('keydown', enforceFormat);
      number_5_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_6_day4) {
      number_6_day4.addEventListener('keydown', enforceFormat);
      number_6_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_7_day4) {
      number_7_day4.addEventListener('keydown', enforceFormat);
      number_7_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_8_day4) {
      number_8_day4.addEventListener('keydown', enforceFormat);
      number_8_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_9_day4) {
      number_9_day4.addEventListener('keydown', enforceFormat);
      number_9_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_0_day5) {
      number_0_day5.addEventListener('keydown', enforceFormat);
      number_0_day5.addEventListener('keyup', formatToPhone);
    }
    if (number_1_day5) {
      number_1_day5.addEventListener('keydown', enforceFormat);
      number_1_day5.addEventListener('keyup', formatToPhone);
    }
    if (number_2_day5) {
      number_2_day5.addEventListener('keydown', enforceFormat);
      number_2_day5.addEventListener('keyup', formatToPhone);
    }
    if (number_3_day5) {
      number_3_day5.addEventListener('keydown', enforceFormat);
      number_3_day5.addEventListener('keyup', formatToPhone);
    }
    if (number_4_day5) {
      number_4_day5.addEventListener('keydown', enforceFormat);
      number_4_day5.addEventListener('keyup', formatToPhone);
    }
    if (number_5_day5) {
      number_5_day5.addEventListener('keydown', enforceFormat);
      number_5_day5.addEventListener('keyup', formatToPhone);
    }
    if (number_6_day5) {
      number_6_day5.addEventListener('keydown', enforceFormat);
      number_6_day5.addEventListener('keyup', formatToPhone);
    }
    if (number_7_day5) {
      number_7_day5.addEventListener('keydown', enforceFormat);
      number_7_day5.addEventListener('keyup', formatToPhone);
    }
    if (number_8_day5) {
      number_8_day5.addEventListener('keydown', enforceFormat);
      number_8_day5.addEventListener('keyup', formatToPhone);
    }
    if (number_9_day5) {
      number_9_day5.addEventListener('keydown', enforceFormat);
      number_9_day5.addEventListener('keyup', formatToPhone);
    }
    if (number_0_day6) {
      number_0_day6.addEventListener('keydown', enforceFormat);
      number_0_day6.addEventListener('keyup', formatToPhone);
    }
    if (number_1_day6) {
      number_1_day6.addEventListener('keydown', enforceFormat);
      number_1_day6.addEventListener('keyup', formatToPhone);
    }
    if (number_2_day6) {
      number_2_day6.addEventListener('keydown', enforceFormat);
      number_2_day6.addEventListener('keyup', formatToPhone);
    }
    if (number_3_day6) {
      number_3_day6.addEventListener('keydown', enforceFormat);
      number_3_day6.addEventListener('keyup', formatToPhone);
    }
    if (number_4_day6) {
      number_4_day6.addEventListener('keydown', enforceFormat);
      number_4_day6.addEventListener('keyup', formatToPhone);
    }
    if (number_5_day6) {
      number_5_day6.addEventListener('keydown', enforceFormat);
      number_5_day6.addEventListener('keyup', formatToPhone);
    }
    if (number_6_day6) {
      number_6_day6.addEventListener('keydown', enforceFormat);
      number_6_day6.addEventListener('keyup', formatToPhone);
    }
    if (number_7_day6) {
      number_7_day6.addEventListener('keydown', enforceFormat);
      number_7_day6.addEventListener('keyup', formatToPhone);
    }
    if (number_8_day6) {
      number_8_day6.addEventListener('keydown', enforceFormat);
      number_8_day6.addEventListener('keyup', formatToPhone);
    }
    if (number_9_day6) {
      number_9_day6.addEventListener('keydown', enforceFormat);
      number_9_day6.addEventListener('keyup', formatToPhone);
    }
    const editnumber_0_day0 = document.getElementById('editnumber_0_day0');
    const editnumber_1_day0 = document.getElementById('editnumber_1_day0');
    const editnumber_2_day0 = document.getElementById('editnumber_2_day0');
    const editnumber_3_day0 = document.getElementById('editnumber_3_day0');
    const editnumber_4_day0 = document.getElementById('editnumber_4_day0');
    const editnumber_5_day0 = document.getElementById('editnumber_5_day0');
    const editnumber_6_day0 = document.getElementById('editnumber_6_day0');
    const editnumber_7_day0 = document.getElementById('editnumber_7_day0');
    const editnumber_8_day0 = document.getElementById('editnumber_8_day0');
    const editnumber_9_day0 = document.getElementById('editnumber_9_day0');
    const editnumber_0_day1 = document.getElementById('editnumber_0_day1');
    const editnumber_1_day1 = document.getElementById('editnumber_1_day1');
    const editnumber_2_day1 = document.getElementById('editnumber_2_day1');
    const editnumber_3_day1 = document.getElementById('editnumber_3_day1');
    const editnumber_4_day1 = document.getElementById('editnumber_4_day1');
    const editnumber_5_day1 = document.getElementById('editnumber_5_day1');
    const editnumber_6_day1 = document.getElementById('editnumber_6_day1');
    const editnumber_7_day1 = document.getElementById('editnumber_7_day1');
    const editnumber_8_day1 = document.getElementById('editnumber_8_day1');
    const editnumber_9_day1 = document.getElementById('editnumber_9_day1');
    const editnumber_0_day2 = document.getElementById('editnumber_0_day2');
    const editnumber_1_day2 = document.getElementById('editnumber_1_day2');
    const editnumber_2_day2 = document.getElementById('editnumber_2_day2');
    const editnumber_3_day2 = document.getElementById('editnumber_3_day2');
    const editnumber_4_day2 = document.getElementById('editnumber_4_day2');
    const editnumber_5_day2 = document.getElementById('editnumber_5_day2');
    const editnumber_6_day2 = document.getElementById('editnumber_6_day2');
    const editnumber_7_day2 = document.getElementById('editnumber_7_day2');
    const editnumber_8_day2 = document.getElementById('editnumber_8_day2');
    const editnumber_9_day2 = document.getElementById('editnumber_9_day2');
    const editnumber_0_day3 = document.getElementById('editnumber_0_day3');
    const editnumber_1_day3 = document.getElementById('editnumber_1_day3');
    const editnumber_2_day3 = document.getElementById('editnumber_2_day3');
    const editnumber_3_day3 = document.getElementById('editnumber_3_day3');
    const editnumber_4_day3 = document.getElementById('editnumber_4_day3');
    const editnumber_5_day3 = document.getElementById('editnumber_5_day3');
    const editnumber_6_day3 = document.getElementById('editnumber_6_day3');
    const editnumber_7_day3 = document.getElementById('editnumber_7_day3');
    const editnumber_8_day3 = document.getElementById('editnumber_8_day3');
    const editnumber_9_day3 = document.getElementById('editnumber_9_day3');
    const editnumber_0_day4 = document.getElementById('editnumber_0_day4');
    const editnumber_1_day4 = document.getElementById('editnumber_1_day4');
    const editnumber_2_day4 = document.getElementById('editnumber_2_day4');
    const editnumber_3_day4 = document.getElementById('editnumber_3_day4');
    const editnumber_4_day4 = document.getElementById('editnumber_4_day4');
    const editnumber_5_day4 = document.getElementById('editnumber_5_day4');
    const editnumber_6_day4 = document.getElementById('editnumber_6_day4');
    const editnumber_7_day4 = document.getElementById('editnumber_7_day4');
    const editnumber_8_day4 = document.getElementById('editnumber_8_day4');
    const editnumber_9_day4 = document.getElementById('editnumber_9_day4');
    const editnumber_0_day5 = document.getElementById('editnumber_0_day5');
    const editnumber_1_day5 = document.getElementById('editnumber_1_day5');
    const editnumber_2_day5 = document.getElementById('editnumber_2_day5');
    const editnumber_3_day5 = document.getElementById('editnumber_3_day5');
    const editnumber_4_day5 = document.getElementById('editnumber_4_day5');
    const editnumber_5_day5 = document.getElementById('editnumber_5_day5');
    const editnumber_6_day5 = document.getElementById('editnumber_6_day5');
    const editnumber_7_day5 = document.getElementById('editnumber_7_day5');
    const editnumber_8_day5 = document.getElementById('editnumber_8_day5');
    const editnumber_9_day5 = document.getElementById('editnumber_9_day5');
    const editnumber_0_day6 = document.getElementById('editnumber_0_day6');
    const editnumber_1_day6 = document.getElementById('editnumber_1_day6');
    const editnumber_2_day6 = document.getElementById('editnumber_2_day6');
    const editnumber_3_day6 = document.getElementById('editnumber_3_day6');
    const editnumber_4_day6 = document.getElementById('editnumber_4_day6');
    const editnumber_5_day6 = document.getElementById('editnumber_5_day6');
    const editnumber_6_day6 = document.getElementById('editnumber_6_day6');
    const editnumber_7_day6 = document.getElementById('editnumber_7_day6');
    const editnumber_8_day6 = document.getElementById('editnumber_8_day6');
    const editnumber_9_day6 = document.getElementById('editnumber_9_day6');
    if (editnumber_0_day0) {
      editnumber_0_day0.addEventListener('keydown', enforceFormat);
      editnumber_0_day0.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_1_day0) {
      editnumber_1_day0.addEventListener('keydown', enforceFormat);
      editnumber_1_day0.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_2_day0) {
      editnumber_2_day0.addEventListener('keydown', enforceFormat);
      editnumber_2_day0.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_3_day0) {
      editnumber_3_day0.addEventListener('keydown', enforceFormat);
      editnumber_3_day0.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_4_day0) {
      editnumber_4_day0.addEventListener('keydown', enforceFormat);
      editnumber_4_day0.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_5_day0) {
      editnumber_5_day0.addEventListener('keydown', enforceFormat);
      editnumber_5_day0.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_6_day0) {
      editnumber_6_day0.addEventListener('keydown', enforceFormat);
      editnumber_6_day0.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_7_day0) {
      editnumber_7_day0.addEventListener('keydown', enforceFormat);
      editnumber_7_day0.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_8_day0) {
      editnumber_8_day0.addEventListener('keydown', enforceFormat);
      editnumber_8_day0.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_9_day0) {
      editnumber_9_day0.addEventListener('keydown', enforceFormat);
      editnumber_9_day0.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_0_day1) {
      editnumber_0_day1.addEventListener('keydown', enforceFormat);
      editnumber_0_day1.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_1_day1) {
      editnumber_1_day1.addEventListener('keydown', enforceFormat);
      editnumber_1_day1.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_2_day1) {
      editnumber_2_day1.addEventListener('keydown', enforceFormat);
      editnumber_2_day1.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_3_day1) {
      editnumber_3_day1.addEventListener('keydown', enforceFormat);
      editnumber_3_day1.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_4_day1) {
      editnumber_4_day1.addEventListener('keydown', enforceFormat);
      editnumber_4_day1.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_5_day1) {
      editnumber_5_day1.addEventListener('keydown', enforceFormat);
      editnumber_5_day1.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_6_day1) {
      editnumber_6_day1.addEventListener('keydown', enforceFormat);
      editnumber_6_day1.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_7_day1) {
      editnumber_7_day1.addEventListener('keydown', enforceFormat);
      editnumber_7_day1.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_8_day1) {
      editnumber_8_day1.addEventListener('keydown', enforceFormat);
      editnumber_8_day1.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_9_day1) {
      editnumber_9_day1.addEventListener('keydown', enforceFormat);
      editnumber_9_day1.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_0_day2) {
      editnumber_0_day2.addEventListener('keydown', enforceFormat);
      editnumber_0_day2.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_1_day2) {
      editnumber_1_day2.addEventListener('keydown', enforceFormat);
      editnumber_1_day2.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_2_day2) {
      editnumber_2_day2.addEventListener('keydown', enforceFormat);
      editnumber_2_day2.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_3_day2) {
      editnumber_3_day2.addEventListener('keydown', enforceFormat);
      editnumber_3_day2.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_4_day2) {
      editnumber_4_day2.addEventListener('keydown', enforceFormat);
      editnumber_4_day2.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_5_day2) {
      editnumber_5_day2.addEventListener('keydown', enforceFormat);
      editnumber_5_day2.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_6_day2) {
      editnumber_6_day2.addEventListener('keydown', enforceFormat);
      editnumber_6_day2.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_7_day2) {
      editnumber_7_day2.addEventListener('keydown', enforceFormat);
      editnumber_7_day2.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_8_day2) {
      editnumber_8_day2.addEventListener('keydown', enforceFormat);
      editnumber_8_day2.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_9_day2) {
      editnumber_9_day2.addEventListener('keydown', enforceFormat);
      editnumber_9_day2.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_0_day3) {
      editnumber_0_day3.addEventListener('keydown', enforceFormat);
      editnumber_0_day3.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_1_day3) {
      editnumber_1_day3.addEventListener('keydown', enforceFormat);
      editnumber_1_day3.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_2_day3) {
      editnumber_2_day3.addEventListener('keydown', enforceFormat);
      editnumber_2_day3.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_3_day3) {
      editnumber_3_day3.addEventListener('keydown', enforceFormat);
      editnumber_3_day3.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_4_day3) {
      editnumber_4_day3.addEventListener('keydown', enforceFormat);
      editnumber_4_day3.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_5_day3) {
      editnumber_5_day3.addEventListener('keydown', enforceFormat);
      editnumber_5_day3.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_6_day3) {
      editnumber_6_day3.addEventListener('keydown', enforceFormat);
      editnumber_6_day3.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_7_day3) {
      editnumber_7_day3.addEventListener('keydown', enforceFormat);
      editnumber_7_day3.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_8_day3) {
      editnumber_8_day3.addEventListener('keydown', enforceFormat);
      editnumber_8_day3.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_9_day3) {
      editnumber_9_day3.addEventListener('keydown', enforceFormat);
      editnumber_9_day3.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_0_day4) {
      editnumber_0_day4.addEventListener('keydown', enforceFormat);
      editnumber_0_day4.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_1_day4) {
      editnumber_1_day4.addEventListener('keydown', enforceFormat);
      editnumber_1_day4.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_2_day4) {
      editnumber_2_day4.addEventListener('keydown', enforceFormat);
      editnumber_2_day4.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_3_day4) {
      editnumber_3_day4.addEventListener('keydown', enforceFormat);
      editnumber_3_day4.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_4_day4) {
      editnumber_4_day4.addEventListener('keydown', enforceFormat);
      editnumber_4_day4.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_5_day4) {
      editnumber_5_day4.addEventListener('keydown', enforceFormat);
      editnumber_5_day4.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_6_day4) {
      editnumber_6_day4.addEventListener('keydown', enforceFormat);
      editnumber_6_day4.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_7_day4) {
      editnumber_7_day4.addEventListener('keydown', enforceFormat);
      editnumber_7_day4.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_8_day4) {
      editnumber_8_day4.addEventListener('keydown', enforceFormat);
      editnumber_8_day4.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_9_day4) {
      editnumber_9_day4.addEventListener('keydown', enforceFormat);
      editnumber_9_day4.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_0_day5) {
      editnumber_0_day5.addEventListener('keydown', enforceFormat);
      editnumber_0_day5.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_1_day5) {
      editnumber_1_day5.addEventListener('keydown', enforceFormat);
      editnumber_1_day5.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_2_day5) {
      editnumber_2_day5.addEventListener('keydown', enforceFormat);
      editnumber_2_day5.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_3_day5) {
      editnumber_3_day5.addEventListener('keydown', enforceFormat);
      editnumber_3_day5.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_4_day5) {
      editnumber_4_day5.addEventListener('keydown', enforceFormat);
      editnumber_4_day5.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_5_day5) {
      editnumber_5_day5.addEventListener('keydown', enforceFormat);
      editnumber_5_day5.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_6_day5) {
      editnumber_6_day5.addEventListener('keydown', enforceFormat);
      editnumber_6_day5.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_7_day5) {
      editnumber_7_day5.addEventListener('keydown', enforceFormat);
      editnumber_7_day5.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_8_day5) {
      editnumber_8_day5.addEventListener('keydown', enforceFormat);
      editnumber_8_day5.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_9_day5) {
      editnumber_9_day5.addEventListener('keydown', enforceFormat);
      editnumber_9_day5.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_0_day6) {
      editnumber_0_day6.addEventListener('keydown', enforceFormat);
      editnumber_0_day6.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_1_day6) {
      editnumber_1_day6.addEventListener('keydown', enforceFormat);
      editnumber_1_day6.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_2_day6) {
      editnumber_2_day6.addEventListener('keydown', enforceFormat);
      editnumber_2_day6.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_3_day6) {
      editnumber_3_day6.addEventListener('keydown', enforceFormat);
      editnumber_3_day6.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_4_day6) {
      editnumber_4_day6.addEventListener('keydown', enforceFormat);
      editnumber_4_day6.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_5_day6) {
      editnumber_5_day6.addEventListener('keydown', enforceFormat);
      editnumber_5_day6.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_6_day6) {
      editnumber_6_day6.addEventListener('keydown', enforceFormat);
      editnumber_6_day6.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_7_day6) {
      editnumber_7_day6.addEventListener('keydown', enforceFormat);
      editnumber_7_day6.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_8_day6) {
      editnumber_8_day6.addEventListener('keydown', enforceFormat);
      editnumber_8_day6.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_9_day6) {
      editnumber_9_day6.addEventListener('keydown', enforceFormat);
      editnumber_9_day6.addEventListener('keyup', formatToPhone);
    }
  }
  getAllRuleset() {
    this.moduleService.getRules(this.currentCompany.uuid).subscribe(res => {
      // console.log(res);        
      this.allrules = res.rule_data;
    });
  }
  getIVRMenu() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleService.getIVRMenus(this.currentCompany.uuid).subscribe(res => {
      this.ivrmenus = res;
      // console.log(this.ivrmenus);
    }, error => this.error = error);
  }
  get rules() {
    return this.addFSLRules.controls;
  }
  onFSLSubmit() {
    this.FSLRulesSubmitted = true;
    // stop here if form is invalid
    if (this.addFSLRules.invalid) {
      return;
    }
    // console.log(this.addFSLRules.get('start_time_0').value._d);
    //  return false;
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    // console.log(this.addFSLRules.value); return false;     
    this.moduleService.addFSLRules(this.addFSLRules.value, this.currentCompany.uuid).subscribe(res => {
      // console.log(res);
      // return false;  
      // localStorage.setItem('FSLRulesInsertID', JSON.stringify(res.insertid));
      this.addFSL();
      if (res.status !== 'error') {
        this.toastrService.success('FSL Rules Added Successfully');
      } else {
        this.toastrService.error('Failed To Add');
      }
    }, error => this.error = error);
  }
  get editrules() {
    return this.editFSLRules.controls;
  }
  onFSLEditSubmit() {
    this.FSLRulesEditSubmitted = true;
    // stop here if form is invalid
    if (this.editFSLRules.invalid) {
      return;
    }
    this.editFSLRules.get('rulename').setValue(this.forwarding);
    // console.log(this.editFSLRules.value);
    // return false;
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    // console.log(this.currentCompany.uuid); return false;     
    this.moduleService.editFSLRules(this.editFSLRules.value, this.currentCompany.uuid).subscribe(res => {
      // console.log(res);
      // return false;  
      // localStorage.setItem('FSLRulesInsertID', JSON.stringify(res.insertid));
      if (res.status !== 'error') {
        this.toastrService.success('FSL Rules Updated Successfully');
      } else {
        this.toastrService.error('Failed To Add');
      }
    }, error => this.error = error);
  }
  get daycontrol() {
    return this.addWeekDaysForm.controls;
  }
  onWeekdaySubmit() {
    this.daysSubmitted = true;
    // stop here if form is invalid
    if (this.addWeekDaysForm.invalid) {
      return;
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleService.addWeekdays(this.addWeekDaysForm.value, this.currentCompany.uuid).subscribe(res => {
      // console.log(res);
      // return false;  
      this.loadweekdays();
      this.loadallweekdays();
      if (res.status !== 'error') {
        this.toastrService.success('Week Day Added Successfully');
      } else {
        this.toastrService.error('Failed To Add');
      }
    }, error => this.error = error);
  }
  get dayeditcontrol() {
    return this.editWeekDaysForm.controls;
  }
  oneditWeekdaySubmit() {
    this.daysEditSubmitted = true;
    // stop here if form is invalid
    if (this.editWeekDaysForm.invalid) {
      return;
    }
    // console.log(this.currentCompany.value);return false; 
    this.moduleService.editWeekdays(this.editWeekDaysForm.value, this.editWeekDaysForm.get('uuid').value).subscribe(res => {
      // console.log(res);
      // return false;  
      this.loadweekdays();
      this.loadallweekdays();
      if (res.status !== 'error') {
        this.toastrService.success('Week Day Updated Successfully');
      } else {
        this.toastrService.error('Failed To Add');
      }
    }, error => this.error = error);
  }
  selectednoofforwardinglocation() {
    let array = [];
    if (this.noofforwardinglocation_1 >= 10) {
      this.ite = 10;
    } else {
      this.ite = this.noofforwardinglocation_1;
    }
    for (let i = 0; i < this.ite; i++) {
      array.push(i);
    }
    return array;
  }
  selectednoofforwardinglocation_2() {
    let array = [];
    if (this.noofforwardinglocation_2 >= 10) {
      this.ite2 = 10;
    } else {
      this.ite2 = this.noofforwardinglocation_2;
    }
    for (let i = 0; i < this.ite2; i++) {
      array.push(i);
    }
    return array;
  }
  selectednoofforwardinglocation_3() {
    let array = [];
    if (this.noofforwardinglocation_3 >= 10) {
      this.ite3 = 10;
    } else {
      this.ite3 = this.noofforwardinglocation_3;
    }
    for (let i = 0; i < this.ite3; i++) {
      array.push(i);
    }
    return array;
  }
  selectednoofforwardinglocation_4() {
    let array = [];
    if (this.noofforwardinglocation_4 >= 10) {
      this.ite4 = 10;
    } else {
      this.ite4 = this.noofforwardinglocation_4;
    }
    for (let i = 0; i < this.ite4; i++) {
      array.push(i);
    }
    return array;
  }
  selectednoofforwardinglocation_5() {
    let array = [];
    if (this.noofforwardinglocation_5 >= 10) {
      this.ite5 = 10;
    } else {
      this.ite5 = this.noofforwardinglocation_5;
    }
    for (let i = 0; i < this.ite5; i++) {
      array.push(i);
    }
    return array;
  }
  selectednoofforwardinglocation_6() {
    let array = [];
    if (this.noofforwardinglocation_6 >= 10) {
      this.ite6 = 10;
    } else {
      this.ite6 = this.noofforwardinglocation_6;
    }
    for (let i = 0; i < this.ite6; i++) {
      array.push(i);
    }
    return array;
  }
  selectednoofforwardinglocation_7() {
    let array = [];
    if (this.noofforwardinglocation_7 >= 10) {
      this.ite7 = 10;
    } else {
      this.ite7 = this.noofforwardinglocation_7;
    }
    for (let i = 0; i < this.ite7; i++) {
      array.push(i);
    }
    return array;
  }
  setPrimaryforward(id, count, day) {
    // Day0
    if (count == 0 && day == 0) {
      this.selectedPrimaryForaward_0_day0 = id;
      this.selectedPrimaryCount_0_day0 = count;
      this.selected_0_day_0 = day;
    }
    if (count == 1 && day == 0) {
      this.selectedPrimaryForaward_1_day0 = id;
      this.selectedPrimaryCount_1_day0 = count;
      this.selected_1_day_0 = day;
    }
    if (count == 2 && day == 0) {
      this.selectedPrimaryForaward_2_day0 = id;
      this.selectedPrimaryCount_2_day0 = count;
      this.selected_2_day_0 = day;
    }
    if (count == 3 && day == 0) {
      this.selectedPrimaryForaward_3_day0 = id;
      this.selectedPrimaryCount_3_day0 = count;
      this.selected_3_day_0 = day;
    }
    if (count == 4 && day == 0) {
      this.selectedPrimaryForaward_4_day0 = id;
      this.selectedPrimaryCount_4_day0 = count;
      this.selected_4_day_0 = day;
    }
    if (count == 5 && day == 0) {
      this.selectedPrimaryForaward_5_day0 = id;
      this.selectedPrimaryCount_5_day0 = count;
      this.selected_5_day_0 = day;
    }
    if (count == 6 && day == 0) {
      this.selectedPrimaryForaward_6_day0 = id;
      this.selectedPrimaryCount_6_day0 = count;
      this.selected_6_day_0 = day;
    }
    if (count == 7 && day == 0) {
      this.selectedPrimaryForaward_7_day0 = id;
      this.selectedPrimaryCount_7_day0 = count;
      this.selected_7_day_0 = day;
    }
    if (count == 8 && day == 0) {
      this.selectedPrimaryForaward_8_day0 = id;
      this.selectedPrimaryCount_8_day0 = count;
      this.selected_8_day_0 = day;
    }
    if (count == 9 && day == 0) {
      this.selectedPrimaryForaward_9_day0 = id;
      this.selectedPrimaryCount_9_day0 = count;
      this.selected_9_day_0 = day;
    }
    // Day1
    if (count == 0 && day == 1) {
      this.selectedPrimaryForaward_0_day1 = id;
      this.selectedPrimaryCount_0_day1 = count;
      this.selected_0_day_1 = day;
    }
    if (count == 1 && day == 1) {
      this.selectedPrimaryForaward_1_day1 = id;
      this.selectedPrimaryCount_1_day1 = count;
      this.selected_1_day_1 = day;
    }
    if (count == 2 && day == 1) {
      this.selectedPrimaryForaward_2_day1 = id;
      this.selectedPrimaryCount_2_day1 = count;
      this.selected_2_day_1 = day;
    }
    if (count == 3 && day == 1) {
      this.selectedPrimaryForaward_3_day1 = id;
      this.selectedPrimaryCount_3_day1 = count;
      this.selected_3_day_1 = day;
    }
    if (count == 4 && day == 1) {
      this.selectedPrimaryForaward_4_day1 = id;
      this.selectedPrimaryCount_4_day1 = count;
      this.selected_4_day_1 = day;
    }
    if (count == 5 && day == 1) {
      this.selectedPrimaryForaward_5_day1 = id;
      this.selectedPrimaryCount_5_day1 = count;
      this.selected_5_day_1 = day;
    }
    if (count == 6 && day == 1) {
      this.selectedPrimaryForaward_6_day1 = id;
      this.selectedPrimaryCount_6_day1 = count;
      this.selected_6_day_1 = day;
    }
    if (count == 7 && day == 1) {
      this.selectedPrimaryForaward_7_day1 = id;
      this.selectedPrimaryCount_7_day1 = count;
      this.selected_7_day_1 = day;
    }
    if (count == 8 && day == 1) {
      this.selectedPrimaryForaward_8_day1 = id;
      this.selectedPrimaryCount_8_day1 = count;
      this.selected_8_day_1 = day;
    }
    if (count == 9 && day == 1) {
      this.selectedPrimaryForaward_9_day1 = id;
      this.selectedPrimaryCount_9_day1 = count;
      this.selected_9_day_1 = day;
    }
    // Day2
    if (count == 0 && day == 2) {
      this.selectedPrimaryForaward_0_day2 = id;
      this.selectedPrimaryCount_0_day2 = count;
      this.selected_0_day_2 = day;
    }
    if (count == 1 && day == 2) {
      this.selectedPrimaryForaward_1_day2 = id;
      this.selectedPrimaryCount_1_day2 = count;
      this.selected_1_day_2 = day;
    }
    if (count == 2 && day == 2) {
      this.selectedPrimaryForaward_2_day2 = id;
      this.selectedPrimaryCount_2_day2 = count;
      this.selected_2_day_2 = day;
    }
    if (count == 3 && day == 2) {
      this.selectedPrimaryForaward_3_day2 = id;
      this.selectedPrimaryCount_3_day2 = count;
      this.selected_3_day_2 = day;
    }
    if (count == 4 && day == 2) {
      this.selectedPrimaryForaward_4_day2 = id;
      this.selectedPrimaryCount_4_day2 = count;
      this.selected_4_day_2 = day;
    }
    if (count == 5 && day == 2) {
      this.selectedPrimaryForaward_5_day2 = id;
      this.selectedPrimaryCount_5_day2 = count;
      this.selected_5_day_2 = day;
    }
    if (count == 6 && day == 2) {
      this.selectedPrimaryForaward_6_day2 = id;
      this.selectedPrimaryCount_6_day2 = count;
      this.selected_6_day_2 = day;
    }
    if (count == 7 && day == 2) {
      this.selectedPrimaryForaward_7_day2 = id;
      this.selectedPrimaryCount_7_day2 = count;
      this.selected_7_day_2 = day;
    }
    if (count == 8 && day == 2) {
      this.selectedPrimaryForaward_8_day2 = id;
      this.selectedPrimaryCount_8_day2 = count;
      this.selected_8_day_2 = day;
    }
    if (count == 9 && day == 2) {
      this.selectedPrimaryForaward_9_day2 = id;
      this.selectedPrimaryCount_9_day2 = count;
      this.selected_9_day_2 = day;
    }
    // Day3
    if (count == 0 && day == 3) {
      this.selectedPrimaryForaward_0_day3 = id;
      this.selectedPrimaryCount_0_day3 = count;
      this.selected_0_day_3 = day;
    }
    if (count == 1 && day == 3) {
      this.selectedPrimaryForaward_1_day3 = id;
      this.selectedPrimaryCount_1_day3 = count;
      this.selected_1_day_3 = day;
    }
    if (count == 2 && day == 3) {
      this.selectedPrimaryForaward_2_day3 = id;
      this.selectedPrimaryCount_2_day3 = count;
      this.selected_2_day_3 = day;
    }
    if (count == 3 && day == 3) {
      this.selectedPrimaryForaward_3_day3 = id;
      this.selectedPrimaryCount_3_day3 = count;
      this.selected_3_day_3 = day;
    }
    if (count == 4 && day == 3) {
      this.selectedPrimaryForaward_4_day3 = id;
      this.selectedPrimaryCount_4_day3 = count;
      this.selected_4_day_3 = day;
    }
    if (count == 5 && day == 3) {
      this.selectedPrimaryForaward_5_day3 = id;
      this.selectedPrimaryCount_5_day3 = count;
      this.selected_5_day_3 = day;
    }
    if (count == 6 && day == 3) {
      this.selectedPrimaryForaward_6_day3 = id;
      this.selectedPrimaryCount_6_day3 = count;
      this.selected_6_day_3 = day;
    }
    if (count == 7 && day == 3) {
      this.selectedPrimaryForaward_7_day3 = id;
      this.selectedPrimaryCount_7_day3 = count;
      this.selected_7_day_3 = day;
    }
    if (count == 8 && day == 3) {
      this.selectedPrimaryForaward_8_day3 = id;
      this.selectedPrimaryCount_8_day3 = count;
      this.selected_8_day_3 = day;
    }
    if (count == 9 && day == 3) {
      this.selectedPrimaryForaward_9_day3 = id;
      this.selectedPrimaryCount_9_day3 = count;
      this.selected_9_day_3 = day;
    }
    // Day4
    if (count == 0 && day == 4) {
      this.selectedPrimaryForaward_0_day4 = id;
      this.selectedPrimaryCount_0_day4 = count;
      this.selected_0_day_4 = day;
    }
    if (count == 1 && day == 4) {
      this.selectedPrimaryForaward_1_day4 = id;
      this.selectedPrimaryCount_1_day4 = count;
      this.selected_1_day_4 = day;
    }
    if (count == 2 && day == 4) {
      this.selectedPrimaryForaward_2_day4 = id;
      this.selectedPrimaryCount_2_day4 = count;
      this.selected_2_day_4 = day;
    }
    if (count == 3 && day == 4) {
      this.selectedPrimaryForaward_3_day4 = id;
      this.selectedPrimaryCount_3_day4 = count;
      this.selected_3_day_4 = day;
    }
    if (count == 4 && day == 4) {
      this.selectedPrimaryForaward_4_day4 = id;
      this.selectedPrimaryCount_4_day4 = count;
      this.selected_4_day_4 = day;
    }
    if (count == 5 && day == 4) {
      this.selectedPrimaryForaward_5_day4 = id;
      this.selectedPrimaryCount_5_day4 = count;
      this.selected_5_day_4 = day;
    }
    if (count == 6 && day == 4) {
      this.selectedPrimaryForaward_6_day4 = id;
      this.selectedPrimaryCount_6_day4 = count;
      this.selected_6_day_4 = day;
    }
    if (count == 7 && day == 4) {
      this.selectedPrimaryForaward_7_day4 = id;
      this.selectedPrimaryCount_7_day4 = count;
      this.selected_7_day_4 = day;
    }
    if (count == 8 && day == 4) {
      this.selectedPrimaryForaward_8_day4 = id;
      this.selectedPrimaryCount_8_day4 = count;
      this.selected_8_day_4 = day;
    }
    if (count == 9 && day == 4) {
      this.selectedPrimaryForaward_9_day4 = id;
      this.selectedPrimaryCount_9_day4 = count;
      this.selected_9_day_4 = day;
    }
    // Day5
    if (count == 0 && day == 5) {
      this.selectedPrimaryForaward_0_day5 = id;
      this.selectedPrimaryCount_0_day5 = count;
      this.selected_0_day_5 = day;
    }
    if (count == 1 && day == 5) {
      this.selectedPrimaryForaward_1_day5 = id;
      this.selectedPrimaryCount_1_day5 = count;
      this.selected_1_day_5 = day;
    }
    if (count == 2 && day == 5) {
      this.selectedPrimaryForaward_2_day5 = id;
      this.selectedPrimaryCount_2_day5 = count;
      this.selected_2_day_5 = day;
    }
    if (count == 3 && day == 5) {
      this.selectedPrimaryForaward_3_day5 = id;
      this.selectedPrimaryCount_3_day5 = count;
      this.selected_3_day_5 = day;
    }
    if (count == 4 && day == 5) {
      this.selectedPrimaryForaward_4_day5 = id;
      this.selectedPrimaryCount_4_day5 = count;
      this.selected_4_day_5 = day;
    }
    if (count == 5 && day == 5) {
      this.selectedPrimaryForaward_5_day5 = id;
      this.selectedPrimaryCount_5_day5 = count;
      this.selected_5_day_5 = day;
    }
    if (count == 6 && day == 5) {
      this.selectedPrimaryForaward_6_day5 = id;
      this.selectedPrimaryCount_6_day5 = count;
      this.selected_6_day_5 = day;
    }
    if (count == 7 && day == 5) {
      this.selectedPrimaryForaward_7_day5 = id;
      this.selectedPrimaryCount_7_day5 = count;
      this.selected_7_day_5 = day;
    }
    if (count == 8 && day == 5) {
      this.selectedPrimaryForaward_8_day5 = id;
      this.selectedPrimaryCount_8_day5 = count;
      this.selected_8_day_5 = day;
    }
    if (count == 9 && day == 5) {
      this.selectedPrimaryForaward_9_day5 = id;
      this.selectedPrimaryCount_9_day5 = count;
      this.selected_9_day_5 = day;
    }
    // Day6
    if (count == 0 && day == 6) {
      this.selectedPrimaryForaward_0_day6 = id;
      this.selectedPrimaryCount_0_day6 = count;
      this.selected_0_day_6 = day;
    }
    if (count == 1 && day == 6) {
      this.selectedPrimaryForaward_1_day6 = id;
      this.selectedPrimaryCount_1_day6 = count;
      this.selected_1_day_6 = day;
    }
    if (count == 2 && day == 6) {
      this.selectedPrimaryForaward_2_day6 = id;
      this.selectedPrimaryCount_2_day6 = count;
      this.selected_2_day_6 = day;
    }
    if (count == 3 && day == 6) {
      this.selectedPrimaryForaward_3_day6 = id;
      this.selectedPrimaryCount_3_day6 = count;
      this.selected_3_day_6 = day;
    }
    if (count == 4 && day == 6) {
      this.selectedPrimaryForaward_4_day6 = id;
      this.selectedPrimaryCount_4_day6 = count;
      this.selected_4_day_6 = day;
    }
    if (count == 5 && day == 6) {
      this.selectedPrimaryForaward_5_day6 = id;
      this.selectedPrimaryCount_5_day6 = count;
      this.selected_5_day_6 = day;
    }
    if (count == 6 && day == 6) {
      this.selectedPrimaryForaward_6_day6 = id;
      this.selectedPrimaryCount_6_day6 = count;
      this.selected_6_day_6 = day;
    }
    if (count == 7 && day == 6) {
      this.selectedPrimaryForaward_7_day6 = id;
      this.selectedPrimaryCount_7_day6 = count;
      this.selected_7_day_6 = day;
    }
    if (count == 8 && day == 6) {
      this.selectedPrimaryForaward_8_day6 = id;
      this.selectedPrimaryCount_8_day6 = count;
      this.selected_8_day_6 = day;
    }
    if (count == 9 && day == 6) {
      this.selectedPrimaryForaward_9_day6 = id;
      this.selectedPrimaryCount_9_day6 = count;
      this.selected_9_day_6 = day;
    }
  }
  isPrimarySelected(id, count, day) {
    // Day0
    if (count == 0 && day == 0) {
      if (this.selectedPrimaryForaward_0_day0 == id && this.selectedPrimaryCount_0_day0 === count && this.selected_0_day_0 == day) return true;else return false;
    }
    if (count == 1 && day == 0) {
      if (this.selectedPrimaryForaward_1_day0 == id && this.selectedPrimaryCount_1_day0 === count && this.selected_1_day_0 == day) return true;else return false;
    }
    if (count == 2 && day == 0) {
      if (this.selectedPrimaryForaward_2_day0 == id && this.selectedPrimaryCount_2_day0 === count && this.selected_2_day_0 == day) return true;else return false;
    }
    if (count == 3 && day == 0) {
      if (this.selectedPrimaryForaward_3_day0 == id && this.selectedPrimaryCount_3_day0 === count && this.selected_3_day_0 == day) return true;else return false;
    }
    if (count == 4 && day == 0) {
      if (this.selectedPrimaryForaward_4_day0 == id && this.selectedPrimaryCount_4_day0 === count && this.selected_4_day_0 == day) return true;else return false;
    }
    if (count == 5 && day == 0) {
      if (this.selectedPrimaryForaward_5_day0 == id && this.selectedPrimaryCount_5_day0 === count && this.selected_5_day_0 == day) return true;else return false;
    }
    if (count == 6 && day == 0) {
      if (this.selectedPrimaryForaward_6_day0 == id && this.selectedPrimaryCount_6_day0 === count && this.selected_6_day_0 == day) return true;else return false;
    }
    if (count == 7 && day == 0) {
      if (this.selectedPrimaryForaward_7_day0 == id && this.selectedPrimaryCount_7_day0 === count && this.selected_7_day_0 == day) return true;else return false;
    }
    if (count == 8 && day == 0) {
      if (this.selectedPrimaryForaward_8_day0 == id && this.selectedPrimaryCount_8_day0 === count && this.selected_8_day_0 == day) return true;else return false;
    }
    if (count == 9 && day == 0) {
      if (this.selectedPrimaryForaward_9_day0 == id && this.selectedPrimaryCount_9_day0 === count && this.selected_9_day_0 == day) return true;else return false;
    }
    // Day1
    if (count == 0 && day == 1) {
      if (this.selectedPrimaryForaward_0_day1 == id && this.selectedPrimaryCount_0_day1 === count && this.selected_0_day_1 == day) return true;else return false;
    }
    if (count == 1 && day == 1) {
      if (this.selectedPrimaryForaward_1_day1 == id && this.selectedPrimaryCount_1_day1 === count && this.selected_1_day_1 == day) return true;else return false;
    }
    if (count == 2 && day == 1) {
      if (this.selectedPrimaryForaward_2_day1 == id && this.selectedPrimaryCount_2_day1 === count && this.selected_2_day_1 == day) return true;else return false;
    }
    if (count == 3 && day == 1) {
      if (this.selectedPrimaryForaward_3_day1 == id && this.selectedPrimaryCount_3_day1 === count && this.selected_3_day_1 == day) return true;else return false;
    }
    if (count == 4 && day == 1) {
      if (this.selectedPrimaryForaward_4_day1 == id && this.selectedPrimaryCount_4_day1 === count && this.selected_4_day_1 == day) return true;else return false;
    }
    if (count == 5 && day == 1) {
      if (this.selectedPrimaryForaward_5_day1 == id && this.selectedPrimaryCount_5_day1 === count && this.selected_5_day_1 == day) return true;else return false;
    }
    if (count == 6 && day == 1) {
      if (this.selectedPrimaryForaward_6_day1 == id && this.selectedPrimaryCount_6_day1 === count && this.selected_6_day_1 == day) return true;else return false;
    }
    if (count == 7 && day == 1) {
      if (this.selectedPrimaryForaward_7_day1 == id && this.selectedPrimaryCount_7_day1 === count && this.selected_7_day_1 == day) return true;else return false;
    }
    if (count == 8 && day == 1) {
      if (this.selectedPrimaryForaward_8_day1 == id && this.selectedPrimaryCount_8_day1 === count && this.selected_8_day_1 == day) return true;else return false;
    }
    if (count == 9 && day == 1) {
      if (this.selectedPrimaryForaward_9_day1 == id && this.selectedPrimaryCount_9_day1 === count && this.selected_9_day_1 == day) return true;else return false;
    }
    // Day2
    if (count == 0 && day == 2) {
      if (this.selectedPrimaryForaward_0_day2 == id && this.selectedPrimaryCount_0_day2 === count && this.selected_0_day_2 == day) return true;else return false;
    }
    if (count == 1 && day == 2) {
      if (this.selectedPrimaryForaward_1_day2 == id && this.selectedPrimaryCount_1_day2 === count && this.selected_1_day_2 == day) return true;else return false;
    }
    if (count == 2 && day == 2) {
      if (this.selectedPrimaryForaward_2_day2 == id && this.selectedPrimaryCount_2_day2 === count && this.selected_2_day_2 == day) return true;else return false;
    }
    if (count == 3 && day == 2) {
      if (this.selectedPrimaryForaward_3_day2 == id && this.selectedPrimaryCount_3_day2 === count && this.selected_3_day_2 == day) return true;else return false;
    }
    if (count == 4 && day == 2) {
      if (this.selectedPrimaryForaward_4_day2 == id && this.selectedPrimaryCount_4_day2 === count && this.selected_4_day_2 == day) return true;else return false;
    }
    if (count == 5 && day == 2) {
      if (this.selectedPrimaryForaward_5_day2 == id && this.selectedPrimaryCount_5_day2 === count && this.selected_5_day_2 == day) return true;else return false;
    }
    if (count == 6 && day == 2) {
      if (this.selectedPrimaryForaward_6_day2 == id && this.selectedPrimaryCount_6_day2 === count && this.selected_6_day_2 == day) return true;else return false;
    }
    if (count == 7 && day == 2) {
      if (this.selectedPrimaryForaward_7_day2 == id && this.selectedPrimaryCount_7_day2 === count && this.selected_7_day_2 == day) return true;else return false;
    }
    if (count == 8 && day == 2) {
      if (this.selectedPrimaryForaward_8_day2 == id && this.selectedPrimaryCount_8_day2 === count && this.selected_8_day_2 == day) return true;else return false;
    }
    if (count == 9 && day == 2) {
      if (this.selectedPrimaryForaward_9_day2 == id && this.selectedPrimaryCount_9_day2 === count && this.selected_9_day_2 == day) return true;else return false;
    }
    // Day3
    if (count == 0 && day == 3) {
      if (this.selectedPrimaryForaward_0_day3 == id && this.selectedPrimaryCount_0_day3 === count && this.selected_0_day_3 == day) return true;else return false;
    }
    if (count == 1 && day == 3) {
      if (this.selectedPrimaryForaward_1_day3 == id && this.selectedPrimaryCount_1_day3 === count && this.selected_1_day_3 == day) return true;else return false;
    }
    if (count == 2 && day == 3) {
      if (this.selectedPrimaryForaward_2_day3 == id && this.selectedPrimaryCount_2_day3 === count && this.selected_2_day_3 == day) return true;else return false;
    }
    if (count == 3 && day == 3) {
      if (this.selectedPrimaryForaward_3_day3 == id && this.selectedPrimaryCount_3_day3 === count && this.selected_3_day_3 == day) return true;else return false;
    }
    if (count == 4 && day == 3) {
      if (this.selectedPrimaryForaward_4_day3 == id && this.selectedPrimaryCount_4_day3 === count && this.selected_4_day_3 == day) return true;else return false;
    }
    if (count == 5 && day == 3) {
      if (this.selectedPrimaryForaward_5_day3 == id && this.selectedPrimaryCount_5_day3 === count && this.selected_5_day_3 == day) return true;else return false;
    }
    if (count == 6 && day == 3) {
      if (this.selectedPrimaryForaward_6_day3 == id && this.selectedPrimaryCount_6_day3 === count && this.selected_6_day_3 == day) return true;else return false;
    }
    if (count == 7 && day == 3) {
      if (this.selectedPrimaryForaward_7_day3 == id && this.selectedPrimaryCount_7_day3 === count && this.selected_7_day_3 == day) return true;else return false;
    }
    if (count == 8 && day == 3) {
      if (this.selectedPrimaryForaward_8_day3 == id && this.selectedPrimaryCount_8_day3 === count && this.selected_8_day_3 == day) return true;else return false;
    }
    if (count == 9 && day == 3) {
      if (this.selectedPrimaryForaward_9_day3 == id && this.selectedPrimaryCount_9_day3 === count && this.selected_9_day_3 == day) return true;else return false;
    }
    // Day4
    if (count == 0 && day == 4) {
      if (this.selectedPrimaryForaward_0_day4 == id && this.selectedPrimaryCount_0_day4 === count && this.selected_0_day_4 == day) return true;else return false;
    }
    if (count == 1 && day == 4) {
      if (this.selectedPrimaryForaward_1_day4 == id && this.selectedPrimaryCount_1_day4 === count && this.selected_1_day_4 == day) return true;else return false;
    }
    if (count == 2 && day == 4) {
      if (this.selectedPrimaryForaward_2_day4 == id && this.selectedPrimaryCount_2_day4 === count && this.selected_2_day_4 == day) return true;else return false;
    }
    if (count == 3 && day == 4) {
      if (this.selectedPrimaryForaward_3_day4 == id && this.selectedPrimaryCount_3_day4 === count && this.selected_3_day_4 == day) return true;else return false;
    }
    if (count == 4 && day == 4) {
      if (this.selectedPrimaryForaward_4_day4 == id && this.selectedPrimaryCount_4_day4 === count && this.selected_4_day_4 == day) return true;else return false;
    }
    if (count == 5 && day == 4) {
      if (this.selectedPrimaryForaward_5_day4 == id && this.selectedPrimaryCount_5_day4 === count && this.selected_5_day_4 == day) return true;else return false;
    }
    if (count == 6 && day == 4) {
      if (this.selectedPrimaryForaward_6_day4 == id && this.selectedPrimaryCount_6_day4 === count && this.selected_6_day_4 == day) return true;else return false;
    }
    if (count == 7 && day == 4) {
      if (this.selectedPrimaryForaward_7_day4 == id && this.selectedPrimaryCount_7_day4 === count && this.selected_7_day_4 == day) return true;else return false;
    }
    if (count == 8 && day == 4) {
      if (this.selectedPrimaryForaward_8_day4 == id && this.selectedPrimaryCount_8_day4 === count && this.selected_8_day_4 == day) return true;else return false;
    }
    if (count == 9 && day == 4) {
      if (this.selectedPrimaryForaward_9_day4 == id && this.selectedPrimaryCount_9_day4 === count && this.selected_9_day_4 == day) return true;else return false;
    }
    // Day5
    if (count == 0 && day == 5) {
      if (this.selectedPrimaryForaward_0_day5 == id && this.selectedPrimaryCount_0_day5 === count && this.selected_0_day_5 == day) return true;else return false;
    }
    if (count == 1 && day == 5) {
      if (this.selectedPrimaryForaward_1_day5 == id && this.selectedPrimaryCount_1_day5 === count && this.selected_1_day_5 == day) return true;else return false;
    }
    if (count == 2 && day == 5) {
      if (this.selectedPrimaryForaward_2_day5 == id && this.selectedPrimaryCount_2_day5 === count && this.selected_2_day_5 == day) return true;else return false;
    }
    if (count == 3 && day == 5) {
      if (this.selectedPrimaryForaward_3_day5 == id && this.selectedPrimaryCount_3_day5 === count && this.selected_3_day_5 == day) return true;else return false;
    }
    if (count == 4 && day == 5) {
      if (this.selectedPrimaryForaward_4_day5 == id && this.selectedPrimaryCount_4_day5 === count && this.selected_4_day_5 == day) return true;else return false;
    }
    if (count == 5 && day == 5) {
      if (this.selectedPrimaryForaward_5_day5 == id && this.selectedPrimaryCount_5_day5 === count && this.selected_5_day_5 == day) return true;else return false;
    }
    if (count == 6 && day == 5) {
      if (this.selectedPrimaryForaward_6_day5 == id && this.selectedPrimaryCount_6_day5 === count && this.selected_6_day_5 == day) return true;else return false;
    }
    if (count == 7 && day == 5) {
      if (this.selectedPrimaryForaward_7_day5 == id && this.selectedPrimaryCount_7_day5 === count && this.selected_7_day_5 == day) return true;else return false;
    }
    if (count == 8 && day == 5) {
      if (this.selectedPrimaryForaward_8_day5 == id && this.selectedPrimaryCount_8_day5 === count && this.selected_8_day_5 == day) return true;else return false;
    }
    if (count == 9 && day == 5) {
      if (this.selectedPrimaryForaward_9_day5 == id && this.selectedPrimaryCount_9_day5 === count && this.selected_9_day_5 == day) return true;else return false;
    }
    // Day6
    if (count == 0 && day == 6) {
      if (this.selectedPrimaryForaward_0_day6 == id && this.selectedPrimaryCount_0_day6 === count && this.selected_0_day_6 == day) return true;else return false;
    }
    if (count == 1 && day == 6) {
      if (this.selectedPrimaryForaward_1_day6 == id && this.selectedPrimaryCount_1_day6 === count && this.selected_1_day_6 == day) return true;else return false;
    }
    if (count == 2 && day == 6) {
      if (this.selectedPrimaryForaward_2_day6 == id && this.selectedPrimaryCount_2_day6 === count && this.selected_2_day_6 == day) return true;else return false;
    }
    if (count == 3 && day == 6) {
      if (this.selectedPrimaryForaward_3_day6 == id && this.selectedPrimaryCount_3_day6 === count && this.selected_3_day_6 == day) return true;else return false;
    }
    if (count == 4 && day == 6) {
      if (this.selectedPrimaryForaward_4_day6 == id && this.selectedPrimaryCount_4_day6 === count && this.selected_4_day_6 == day) return true;else return false;
    }
    if (count == 5 && day == 6) {
      if (this.selectedPrimaryForaward_5_day6 == id && this.selectedPrimaryCount_5_day6 === count && this.selected_5_day_6 == day) return true;else return false;
    }
    if (count == 6 && day == 6) {
      if (this.selectedPrimaryForaward_6_day6 == id && this.selectedPrimaryCount_6_day6 === count && this.selected_6_day_6 == day) return true;else return false;
    }
    if (count == 7 && day == 6) {
      if (this.selectedPrimaryForaward_7_day6 == id && this.selectedPrimaryCount_7_day6 === count && this.selected_7_day_6 == day) return true;else return false;
    }
    if (count == 8 && day == 6) {
      if (this.selectedPrimaryForaward_8_day6 == id && this.selectedPrimaryCount_8_day6 === count && this.selected_8_day_6 == day) return true;else return false;
    }
    if (count == 9 && day == 6) {
      if (this.selectedPrimaryForaward_9_day6 == id && this.selectedPrimaryCount_9_day6 === count && this.selected_9_day_6 == day) return true;else return false;
    }
  }
  onFSLReset() {
    this.FSLRulesSubmitted = false;
    this.addFSLRules.reset();
  }
  selected() {
    let array = [];
    for (let i = 0; i < this.noofforwarding; i++) {
      array.push(i);
    }
    return array;
  }
  Delete(uuid) {
    // alert(uuid);return false
    sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
      title: 'Are you sure?',
      text: 'You want to Delete Record!',
      showCancelButton: true,
      confirmButtonText: 'Yes, delete it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        this.moduleService.deleteFSLRules(uuid).subscribe(res => {
          // this.toastrService.success('Number Deleted Successfully');
          // this.FSLRulesSubmitted = false;
          this.addFSLRules.reset();
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Record Deleted Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
          // this.loadNumbers();
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
        }, 2000);
      }
    });
  }
  DeleteWeekDay(uuid) {
    // alert(uuid);return false
    sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
      title: 'Are you sure?',
      text: 'You want to Delete Record!',
      showCancelButton: true,
      confirmButtonText: 'Yes, delete it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        this.moduleService.deleteWeekday(uuid).subscribe(res => {
          // this.toastrService.success('Number Deleted Successfully');
          // this.FSLRulesSubmitted = false;
          this.addFSLRules.reset();
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Record Deleted Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
          this.loadweekdays();
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
        }, 2000);
      }
    });
  }
  static #_ = this.ctorParameters = () => [{
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_6__.FormBuilder
  }, {
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_7__.Router
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_7__.ActivatedRoute
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_8__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_5__.HttpBackend
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_9__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }],
    daysTable: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_9__.ViewChild,
      args: ['daysdataTable', {
        static: true
      }]
    }]
  };
};
NumberAddfslrulesComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_10__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_9__.Component)({
  selector: 'app-number-addfslrules',
  template: _number_addfslrules_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_number_addfslrules_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], NumberAddfslrulesComponent);


/***/ }),

/***/ 84359:
/*!*******************************************************************************!*\
  !*** ./src/app/modules/number/number-batchedit/number-batchedit.component.ts ***!
  \*******************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "NumberBatcheditComponent": () => (/* binding */ NumberBatcheditComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _number_batchedit_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./number-batchedit.component.html?ngResource */ 77188);
/* harmony import */ var _number_batchedit_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./number-batchedit.component.scss?ngResource */ 55471);
/* harmony import */ var _number_batchedit_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_number_batchedit_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../../module.service */ 22947);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/platform-browser */ 34497);









let NumberBatcheditComponent = class NumberBatcheditComponent {
  constructor(fb, moduleService, router, route, toastrService, titleService) {
    this.fb = fb;
    this.moduleService = moduleService;
    this.router = router;
    this.route = route;
    this.toastrService = toastrService;
    this.titleService = titleService;
    this.submitted = false;
    this.dropdownList = [];
    this.selectedItems = [];
    this.dropdownSettings = {};
    this.selectednumber = [];
    this.pageTitle = "Batch Edit Numbers";
    this.payout_typevalueedit = 0;
    this.jklrules = 'false';
    this.LabelSubmitted = false;
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngOnInit() {
    this.setTitle(this.pageTitle);
    this.getAllpublisher();
    this.getAllcampaign();
    this.getAllLabels();
    // console.log(this.selectednumber);
    this.dropdownSettings = {
      singleSelection: false,
      text: "Select Associated Labels",
      selectAllText: 'Select All',
      unSelectAllText: 'UnSelect All',
      enableSearchFilter: true,
      classes: "myclass custom-class"
    };
    this.addForm = this.fb.group({
      number: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_3__.Validators.required],
      campaign: [''],
      add_assosciated_labels: [''],
      remove_assosciated_labels: [''],
      publisher: [''],
      payout_typeedit: [''],
      payout_amount: [''],
      payout_trigger: [''],
      payout_seconds: ['']
    });
    this.addLabelForm = this.fb.group({
      name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_3__.Validators.required],
      notes: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_3__.Validators.required]
    });
    // this.id = this.route.snapshot.paramMap.get('id');
    // if(this.id==1){
    this.moduleService.getnumbersInfo().subscribe(info => {
      this.getselectednumberslist = info.numberslist;
      // console.log(this.getselectednumberslist);
      var numberlist = '';
      if (this.getselectednumberslist) {
        for (let index = 0; index < this.getselectednumberslist.length; index++) {
          numberlist += this.getselectednumberslist[index] + "\r\n";
        }
        this.addForm.patchValue({
          number: numberlist.toString()
        });
      }
      // this.addForm.get('number').setValue("hello");
      // this.addForm.patchValue({
      //   number:this.getselectednumberslist,      
      // });
      // console.log(this.getselectednumberslist);
    });
    // }
  }

  payout_typevaledit(val) {
    this.payout_typevalueedit = val;
    this.addForm.get('payout_typeedit').setValue(val);
  }
  get_campaign(event) {
    this.iscampaign = event.target.checked;
  }
  get_publishter(event) {
    this.ispublisher = event.target.checked;
  }
  get_label(event) {
    this.islabel = event.target.checked;
  }
  get_removelabel(event) {
    this.isremovelabel = event.target.checked;
  }
  getAllRules() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleService.getAllRules(this.currentCompany.uuid).subscribe(res => {
      //  console.log(res); return false;  
      this.allRulesData = res;
    }, error => this.error = error);
  }
  getRulesByName(name) {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleService.getRulesByName(name, this.currentCompany.uuid).subscribe(res => {
      this.allRulesbyname = res;
    }, error => this.error = error);
  }
  getAllpublisher() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleService.getAllpublishers(this.currentCompany.uuid).subscribe(res => {
      this.Allpublisher = res;
    }, error => this.error = error);
  }
  getAllcampaign() {
    this.moduleService.getallcampaindata(this.currentCompany.uuid).subscribe(res => {
      this.getallcampain = res;
      // console.log(this.getallcampain);
    });
  }

  getAllLabels() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleService.getAllLabels(this.currentCompany.uuid).subscribe(res => {
      this.dropdownList = res;
    }, error => this.error = error);
  }
  onFileChange(event) {
    if (event.target.files.length > 0) {
      const file = event.target.files[0];
      const ext = file.name.split('.').pop();
      ;
      if (ext == 'csv') {
        this.uploadfile = file;
        this.filename = file.name;
      } else {
        this.addForm.reset({
          number: ''
        });
        this.toastrService.error('Please Select only .csv file to import numbers');
      }
    }
  }
  get_jklrules(event) {
    this.jklrules = event.target.checked;
  }
  get f() {
    return this.addForm.controls;
  }
  onSubmit() {
    const formData = new FormData();
    this.submitted = true;
    if (this.addForm.invalid) {
      return;
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    // formData.append('number', this.uploadfile);    
    formData.append('number', this.addForm.get('number').value);
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('iscampaign', this.iscampaign);
    formData.append('ispublisher', this.ispublisher);
    formData.append('islabel', this.islabel);
    formData.append('isremovelabel', this.isremovelabel);
    formData.append('campaign', JSON.stringify(this.addForm.get('campaign').value));
    formData.append('publisher', JSON.stringify(this.addForm.get('publisher').value));
    formData.append('payout_typeedit', this.addForm.get('payout_typeedit').value);
    formData.append('payout_amount', this.addForm.get('payout_amount').value);
    formData.append('payout_trigger', this.addForm.get('payout_trigger').value);
    formData.append('payout_seconds', this.addForm.get('payout_seconds').value);
    // formData.append('ruleset', this.addForm.get('ruleset').value);
    formData.append('add_assosciated_labels', JSON.stringify(this.addForm.get('add_assosciated_labels').value));
    formData.append('remove_assosciated_labels', JSON.stringify(this.addForm.get('remove_assosciated_labels').value));
    // console.log(formData); return false;
    this.showLoadingIndicator = true;
    this.moduleService.batcheditnos(formData).subscribe(res => {
      this.showLoadingIndicator = false;
      // console.log(res); return false;
      if (res.status == 'success') {
        this.toastrService.success(res.noofrecords + ' Numbers Updated Successfully');
        // this.router.navigate(['/numbers']);
        this.router.navigate(['/numbers']);
      } else {
        this.toastrService.error('Failed To Add');
      }
    }, error => this.error = error);
  }
  onReset() {
    this.submitted = false;
    this.addForm.reset();
  }
  closeModal() {
    if (this.addLabelForm.get('name').value && this.addLabelForm.get('notes').value) {
      $("#addLabels").modal("hide");
      $(".custom-switch-input").prop('checked', false);
      this.LabelSubmitted = false;
      setTimeout(() => {
        this.addLabelForm.reset();
        this.isName = "";
      }, 2000);
    }
  }
  validatename() {
    if (this.addLabelForm.get('name').value != '') {
      this.moduleService.validateLabelName(this.addLabelForm.get('name').value).subscribe(res => {
        // console.log(res); return false;  
        this.isName = res;
        if (this.isName.status == 'success') {
          this.isName = "success";
        } else {
          this.isName = "fail";
        }
      });
    } else {
      this.isName = "";
    }
  }
  get labelcontrol() {
    return this.addLabelForm.controls;
  }
  onLabelSubmit() {
    const formData = new FormData();
    this.LabelSubmitted = true;
    if (this.addLabelForm.invalid) {
      return;
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('name', this.addLabelForm.get('name').value);
    formData.append('notes', this.addLabelForm.get('notes').value);
    this.moduleService.addLabel(formData).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Label Added Successfully');
        this.getAllLabels();
        this.LabelSubmitted = false;
        this.isName = false;
      } else {
        this.toastrService.error('Failed To Add Label');
      }
    }, error => this.error = error);
  }
  static #_ = this.ctorParameters = () => [{
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_3__.FormBuilder
  }, {
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_4__.Router
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_4__.ActivatedRoute
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_5__.ToastrService
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_6__.Title
  }];
  static #_2 = this.propDecorators = {
    selectednumber: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_7__.Input
    }]
  };
};
NumberBatcheditComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_8__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_7__.Component)({
  selector: 'app-number-batchedit',
  template: _number_batchedit_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  changeDetection: _angular_core__WEBPACK_IMPORTED_MODULE_7__.ChangeDetectionStrategy.OnPush,
  styles: [(_number_batchedit_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], NumberBatcheditComponent);


/***/ }),

/***/ 91522:
/*!***********************************************************************!*\
  !*** ./src/app/modules/number/number-buyer/number-buyer.component.ts ***!
  \***********************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "NumberBuyerComponent": () => (/* binding */ NumberBuyerComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _number_buyer_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./number-buyer.component.html?ngResource */ 88453);
/* harmony import */ var _number_buyer_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./number-buyer.component.scss?ngResource */ 38052);
/* harmony import */ var _number_buyer_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_number_buyer_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../../module.service */ 22947);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! sweetalert2 */ 60598);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(sweetalert2__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../global */ 27266);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/platform-browser */ 34497);









//import 'sweetalert2/src/sweetalert2.scss'


// import { ngxCsv } from 'ngx-csv/ngx-csv';

const router = _angular_router__WEBPACK_IMPORTED_MODULE_5__.Router;
class DataTablesResponse {}
let NumberBuyerComponent = class NumberBuyerComponent {
  constructor(moduleservice, toastrService, handler, fb, titleService) {
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.fb = fb;
    this.titleService = titleService;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_4__.GlobalVariable.BASE_API_URL;
    this.dtOptions = {};
    this.ischecked = '1';
    this.checkboxes = [];
    this.Submitted = false;
    this.editSubmitted = false;
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_6__.HttpClient(handler);
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngOnInit() {
    this.setTitle('Manage Buyers');
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.loadNumbers();
    this.addForm = this.fb.group({
      company: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      email: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      password: [''],
      sub_id: [''],
      allow_buyer_to_pause_target: [''],
      allow_buyer_to_set_target_concurrency: [''],
      allow_buyer_to_dispute_call_conversions: [''],
      limit_revenue: ['']
    });
    this.editForm = this.fb.group({
      uuid: [''],
      company: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      email: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      password: [''],
      sub_id: [''],
      allow_buyer_to_pause_target: [''],
      allow_buyer_to_set_target_concurrency: [''],
      allow_buyer_to_dispute_call_conversions: [''],
      limit_revenue: ['']
    });
  }
  loadNumbers() {
    // console.log('ok');
    // return false;
    if ($.fn.DataTable.isDataTable(this.table.nativeElement)) {
      $(this.table.nativeElement).dataTable().fnDestroy();
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.dtOptions = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "pageLength": 20,
      "lengthMenu": [[-1, 20, 100, 500, 2000], ["All", 20, 100, 500, 2000]],
      "order": [[0, "asc"]],
      ajax: (dataTablesParameters, callback) => {
        this.http.post(this.ServerUrl + 'getbuyers/' + this.currentCompany.uuid, dataTablesParameters, {}).subscribe(resp => {
          this.numbers = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [
      // {data:"checkall"},
      // {data:"hour"},{data:"day"},{data:"month"},{data:"total"},
      // ,{data:"status"}
      // {data:"allow_buyer_to_set_target_concurrency"},{data:"allow_buyer_to_dispute_call_conversions"},
      {
        data: "company"
      }, {
        data: "email"
      }, {
        data: "sub_id"
      }, {
        data: "allow_buyer_to_pause_target"
      }, {
        data: "created_at"
      }, {
        data: "action"
      }],
      columnDefs: [{
        "targets": [0],
        "orderable": false
      }]
    };
    this.dataTable = $(this.table.nativeElement);
    this.dataTable.dataTable(this.dtOptions);
  }
  editdata(uuid, company, sub_id, allow_buyer_to_pause_target, allow_buyer_to_set_target_concurrency, allow_buyer_to_dispute_call_conversions, limit_revenue, email) {
    this.editForm.patchValue({
      uuid: uuid,
      company: company,
      email: email,
      sub_id: sub_id,
      allow_buyer_to_pause_target: allow_buyer_to_pause_target,
      allow_buyer_to_set_target_concurrency: allow_buyer_to_set_target_concurrency,
      allow_buyer_to_dispute_call_conversions: allow_buyer_to_dispute_call_conversions,
      limit_revenue: limit_revenue
    });
  }
  checkalldelete(event) {
    const checked = event.target.checked;
    this.numbers.forEach(chkbox => chkbox.selected = checked);
  }
  deleteselected(event) {
    // $("#customCheck1").prop("checked", false);
    if (event.target.checked == true) {
      if (event.target.value == 'on') {
        this.checkboxes = [];
        this.numbers.forEach(lbl => {
          this.checkboxes.push(lbl.id);
        });
      } else {
        if (this.checkboxes.length + 1 == this.numbers.length) {
          $("#customCheck1").prop("checked", true);
        }
        this.checkboxes.push(event.target.value);
      }
      this.ischecked = '0';
    } else {
      // console.log(this.checkboxes);
      if (this.checkboxes.length != 0) {
        $("#customCheck1").prop("checked", false);
      }
      if (event.target.value != 'on') {
        const index = this.checkboxes.indexOf(event.target.value);
        this.checkboxes.splice(index, 1);
      } else {
        this.checkboxes = [];
      }
      this.ischecked = '1';
    }
    // console.log(this.checkboxes);
  }

  onDeleteSubmit() {
    if (this.checkboxes.length == 0) {
      this.toastrService.error('Please Select Row To Delete');
    } else {
      // console.log(this.checkboxes);
      sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
        title: 'Are you sure?',
        text: 'You want to Delete Selected Record!',
        showCancelButton: true,
        confirmButtonText: 'Yes, delete it!',
        cancelButtonText: 'No, keep it'
      }).then(result => {
        if (result.value) {
          this.moduleservice.deleteSelectedNumbers(this.checkboxes).subscribe(res => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Records Deleted Successfully.');
            setTimeout(() => {
              sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
            }, 2000);
            this.loadNumbers();
          }, error => this.error = error);
        } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
        }
      });
    }
  }
  Delete(id) {
    sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
      title: 'Are you sure?',
      text: 'You want to Delete Record!',
      showCancelButton: true,
      confirmButtonText: 'Yes, delete it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        let currentUser = JSON.parse(localStorage.getItem('currentUser'));
        this.moduleservice.deleteBuyer(+id, currentUser.uuid).subscribe(res => {
          this.loadNumbers();
          // this.toastrService.success('Number Deleted Successfully');
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Record Deleted Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
        }, 2000);
      }
    });
  }
  //Add Buyer
  get buyercontrol() {
    return this.addForm.controls;
  }
  onSubmit() {
    const formData = new FormData();
    this.Submitted = true;
    if (this.addForm.invalid) {
      return;
    }
    this.closeModal();
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    // console.log(this.currentUser);return;
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('user_uuid', this.currentUser.uuid);
    formData.append('company', this.addForm.get('company').value);
    formData.append('email', this.addForm.get('email').value);
    formData.append('password', this.addForm.get('password').value);
    formData.append('sub_id', this.addForm.get('sub_id').value);
    formData.append('allow_buyer_to_pause_target', this.addForm.get('allow_buyer_to_pause_target').value);
    formData.append('allow_buyer_to_set_target_concurrency', this.addForm.get('allow_buyer_to_set_target_concurrency').value);
    formData.append('allow_buyer_to_dispute_call_conversions', this.addForm.get('allow_buyer_to_dispute_call_conversions').value);
    formData.append('limit_revenue', this.addForm.get('limit_revenue').value);
    // console.log(formData); return false;
    this.moduleservice.addBuyer(formData).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Buyer Added Successfully');
        this.loadNumbers();
        this.Submitted = false;
      } else {
        this.toastrService.error('Failed To Add Label');
      }
    }, error => this.error = error);
  }
  closeModal() {
    if (this.addForm.get('company').value) {
      $("#addLabels").modal("hide");
      $(".custom-switch-input").prop('checked', false);
      this.Submitted = false;
      setTimeout(() => {
        this.addForm.reset();
      }, 2000);
    }
  }
  //Add Buyer
  get editbuyercontrol() {
    return this.editForm.controls;
  }
  onEditSubmit() {
    // alert('ok');return false;
    const formData = new FormData();
    this.editSubmitted = true;
    if (this.editForm.invalid) {
      return;
    }
    this.closeEditModal();
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('user_uuid', this.currentUser.uuid);
    formData.append('uuid', this.editForm.get('uuid').value);
    formData.append('company', this.editForm.get('company').value);
    formData.append('email', this.editForm.get('email').value);
    formData.append('password', this.editForm.get('password').value);
    formData.append('sub_id', this.editForm.get('sub_id').value);
    formData.append('allow_buyer_to_pause_target', this.editForm.get('allow_buyer_to_pause_target').value);
    formData.append('allow_buyer_to_set_target_concurrency', this.editForm.get('allow_buyer_to_set_target_concurrency').value);
    formData.append('allow_buyer_to_dispute_call_conversions', this.editForm.get('allow_buyer_to_dispute_call_conversions').value);
    formData.append('limit_revenue', this.editForm.get('limit_revenue').value);
    // console.log(formData);
    this.moduleservice.editBuyer(formData).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Buyer Updated Successfully');
        this.loadNumbers();
        this.editSubmitted = false;
      } else {
        this.toastrService.error('Failed To Add Label');
      }
    }, error => this.error = error);
  }
  closeEditModal() {
    if (this.editForm.get('company').value) {
      $("#editLabels").modal("hide");
      this.editSubmitted = false;
      setTimeout(() => {
        this.editForm.reset();
      }, 2000);
    }
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_8__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_6__.HttpBackend
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_7__.FormBuilder
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_9__.Title
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_10__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }]
  };
};
NumberBuyerComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_11__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_10__.Component)({
  selector: 'app-number-buyer',
  template: _number_buyer_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_number_buyer_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], NumberBuyerComponent);


/***/ }),

/***/ 11724:
/*!*************************************************************************!*\
  !*** ./src/app/modules/number/number-upload/number-upload.component.ts ***!
  \*************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "NumberUploadComponent": () => (/* binding */ NumberUploadComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _number_upload_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./number-upload.component.html?ngResource */ 25751);
/* harmony import */ var _number_upload_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./number-upload.component.scss?ngResource */ 44559);
/* harmony import */ var _number_upload_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_number_upload_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../../module.service */ 22947);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var ngx_csv_ngx_csv__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ngx-csv/ngx-csv */ 94551);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/platform-browser */ 34497);










let NumberUploadComponent = class NumberUploadComponent {
  constructor(fb, moduleService, router, route, toastrService, titleService) {
    this.fb = fb;
    this.moduleService = moduleService;
    this.router = router;
    this.route = route;
    this.toastrService = toastrService;
    this.titleService = titleService;
    this.submitted = false;
    this.dropdownList = [];
    this.selectedItems = [];
    this.dropdownSettings = {};
    this.selectednumber = [];
    this.payout_typevalueedit = 0;
    this.pageTitle = "Import Numbers";
    this.jklrules = 'false';
    this.LabelSubmitted = false;
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
  }
  getAllRules() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleService.getAllRules(this.currentCompany.uuid).subscribe(res => {
      //  console.log(res); return false;  
      this.allRulesData = res;
    }, error => this.error = error);
  }
  getRulesByName(name) {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleService.getRulesByName(name, this.currentCompany.uuid).subscribe(res => {
      this.allRulesbyname = res;
    }, error => this.error = error);
  }
  getAllpublisher() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleService.getAllpublishers(this.currentCompany.uuid).subscribe(res => {
      this.Allpublisher = res;
    }, error => this.error = error);
  }
  getAllcampaign() {
    this.moduleService.getallcampaindata(this.currentCompany.uuid).subscribe(res => {
      this.getallcampain = res;
      // console.log(this.getallcampain);
    });
  }

  payout_typevaledit(val) {
    this.payout_typevalueedit = val;
    this.addForm.get('payout_typeedit').setValue(val);
  }
  getAllLabels() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleService.getAllLabels(this.currentCompany.uuid).subscribe(res => {
      this.dropdownList = res;
    }, error => this.error = error);
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngOnInit() {
    this.setTitle('Import Numbers');
    this.getAllpublisher();
    this.getAllcampaign();
    this.getAllLabels();
    // console.log(this.selectednumber);
    this.dropdownSettings = {
      singleSelection: false,
      text: "Select Associated Labels",
      selectAllText: 'Select All',
      unSelectAllText: 'UnSelect All',
      enableSearchFilter: true,
      classes: "myclass custom-class"
    };
    this.addForm = this.fb.group({
      number: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_4__.Validators.required],
      campaign: [''],
      assosciated_labels: [''],
      publisher: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_4__.Validators.required],
      payout_typeedit: [''],
      payout_amount: [''],
      payout_trigger: [''],
      payout_seconds: ['']
    });
    this.addLabelForm = this.fb.group({
      name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_4__.Validators.required],
      notes: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_4__.Validators.required]
    });
    this.id = this.route.snapshot.paramMap.get('id');
    if (this.id == 1) {
      this.moduleService.getnumbersInfo().subscribe(info => {
        this.getselectednumberslist = info.numberslist;
        // console.log(this.getselectednumberslist);
        var numberlist = '';
        if (this.getselectednumberslist) {
          for (let index = 0; index < this.getselectednumberslist.length; index++) {
            numberlist += this.getselectednumberslist[index] + "\r\n";
          }
          this.pageTitle = "Batch Edit";
          this.addForm.patchValue({
            number: numberlist.toString()
          });
        }
        // this.addForm.get('number').setValue("hello");
        // this.addForm.patchValue({
        //   number:this.getselectednumberslist,      
        // });
        // console.log(this.getselectednumberslist);
      });
    }
  }

  onFileChange(event) {
    if (event.target.files.length > 0) {
      const file = event.target.files[0];
      const ext = file.name.split('.').pop();
      ;
      if (ext == 'csv') {
        this.uploadfile = file;
        this.filename = file.name;
      } else {
        this.addForm.reset({
          number: ''
        });
        this.toastrService.error('Please Select only .csv file to import numbers');
      }
    }
  }
  get_jklrules(event) {
    this.jklrules = event.target.checked;
  }
  get f() {
    return this.addForm.controls;
  }
  onSubmit() {
    const formData = new FormData();
    this.submitted = true;
    if (this.addForm.invalid) {
      return;
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    // formData.append('number', this.uploadfile);    
    formData.append('number', this.addForm.get('number').value);
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('campaign', JSON.stringify(this.addForm.get('campaign').value));
    formData.append('publisher', JSON.stringify(this.addForm.get('publisher').value));
    formData.append('payout_typeedit', this.addForm.get('payout_typeedit').value);
    formData.append('payout_amount', this.addForm.get('payout_amount').value);
    formData.append('payout_trigger', this.addForm.get('payout_trigger').value);
    formData.append('payout_seconds', this.addForm.get('payout_seconds').value);
    // formData.append('ruleset', this.addForm.get('ruleset').value);
    formData.append('assosciated_labels', JSON.stringify(this.addForm.get('assosciated_labels').value));
    // console.log(formData); return false;
    this.showLoadingIndicator = true;
    this.moduleService.importNumber(formData).subscribe(res => {
      this.showLoadingIndicator = false;
      // console.log(res.duplicatenumbers); return false;
      if (res.status == 'success') {
        this.toastrService.success(res.noofrecords + ' Number Imported Successfully');
        // this.router.navigate(['/numbers']);
        if (res.duplicatenumbers != '') {
          var options = {
            fieldSeparator: ',',
            quoteStrings: '"',
            decimalseparator: '.',
            showLabels: true,
            // showTitle: true,
            // title: 'Your title',
            useBom: true,
            // noDownload: true,
            headers: ["Duplicate Numbers"]
          };
          new ngx_csv_ngx_csv__WEBPACK_IMPORTED_MODULE_3__.ngxCsv(res.duplicatenumbers, 'All Duplicate Numbers', options);
        }
        this.router.navigate(['/numbers']);
      } else {
        this.toastrService.error('Failed To Add');
      }
    }, error => this.error = error);
  }
  onReset() {
    this.submitted = false;
    this.addForm.reset();
  }
  closeModal() {
    if (this.addLabelForm.get('name').value && this.addLabelForm.get('notes').value) {
      $("#addLabels").modal("hide");
      $(".custom-switch-input").prop('checked', false);
      this.LabelSubmitted = false;
      setTimeout(() => {
        this.addLabelForm.reset();
        this.isName = "";
      }, 2000);
    }
  }
  validatename() {
    if (this.addLabelForm.get('name').value != '') {
      this.moduleService.validateLabelName(this.addLabelForm.get('name').value).subscribe(res => {
        // console.log(res); return false;  
        this.isName = res;
        if (this.isName.status == 'success') {
          this.isName = "success";
        } else {
          this.isName = "fail";
        }
      });
    } else {
      this.isName = "";
    }
  }
  get labelcontrol() {
    return this.addLabelForm.controls;
  }
  onLabelSubmit() {
    const formData = new FormData();
    this.LabelSubmitted = true;
    if (this.addLabelForm.invalid) {
      return;
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('name', this.addLabelForm.get('name').value);
    formData.append('notes', this.addLabelForm.get('notes').value);
    this.moduleService.addLabel(formData).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Label Added Successfully');
        this.getAllLabels();
        this.LabelSubmitted = false;
        this.isName = false;
      } else {
        this.toastrService.error('Failed To Add Label');
      }
    }, error => this.error = error);
  }
  static #_ = this.ctorParameters = () => [{
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_4__.FormBuilder
  }, {
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_5__.Router
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_5__.ActivatedRoute
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_6__.ToastrService
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_7__.Title
  }];
  static #_2 = this.propDecorators = {
    selectednumber: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_8__.Input
    }]
  };
};
NumberUploadComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_9__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_8__.Component)({
  selector: 'app-number-upload',
  template: _number_upload_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  changeDetection: _angular_core__WEBPACK_IMPORTED_MODULE_8__.ChangeDetectionStrategy.OnPush,
  styles: [(_number_upload_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], NumberUploadComponent);


/***/ }),

/***/ 47760:
/*!****************************************************!*\
  !*** ./src/app/modules/number/number.component.ts ***!
  \****************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "NumberComponent": () => (/* binding */ NumberComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _number_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./number.component.html?ngResource */ 26022);
/* harmony import */ var _number_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./number.component.scss?ngResource */ 94111);
/* harmony import */ var _number_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_number_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../module.service */ 22947);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! sweetalert2 */ 60598);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(sweetalert2__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../global */ 27266);
/* harmony import */ var ngx_csv_ngx_csv__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ngx-csv/ngx-csv */ 94551);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/platform-browser */ 34497);
/* harmony import */ var ngx_ui_loader__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ngx-ui-loader */ 36413);








//import 'sweetalert2/src/sweetalert2.scss'





const router = _angular_router__WEBPACK_IMPORTED_MODULE_6__.Router;
class DataTablesResponse {}
let NumberComponent = class NumberComponent {
  constructor(moduleservice, toastrService, router, handler, titleService, ngxLoader) {
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.router = router;
    this.titleService = titleService;
    this.ngxLoader = ngxLoader;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_4__.GlobalVariable.BASE_API_URL;
    this.SiteUrl = _global__WEBPACK_IMPORTED_MODULE_4__.GlobalVariable.BASE_URL;
    this.dtOptions = {};
    this.ischecked = '1';
    this.checkboxes = [];
    this.filter = [];
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_7__.HttpClient(handler);
    this.role = JSON.parse(localStorage.getItem('currentUser')).role;
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngOnInit() {
    this.setTitle('Manage Targets');
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.loadTargets();
  }
  loadTargets() {
    // console.log('ok');
    // return false;
    if ($.fn.DataTable.isDataTable(this.table.nativeElement)) {
      $(this.table.nativeElement).dataTable().fnDestroy();
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    let company_uuid = currentUser?.companydetails.map(item => item.user_uuid);
    // console.log(company_uuid);
    this.dtOptions = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "pageLength": 20,
      "lengthMenu": [[-1, 20, 50, 100, 500, 2000, 5000], ["All", 20, 50, 100, 500, 2000, 5000]],
      "order": [[1, "asc"]],
      ajax: (dataTablesParameters, callback) => {
        this.http.post(this.ServerUrl + 'gettargets/' + this.currentCompany.uuid, {
          'dataTablesParameters': dataTablesParameters,
          'user_uuid': currentUser.uuid,
          'role': currentUser.role,
          'companies': company_uuid
        }, {}).subscribe(resp => {
          this.numbers = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [
      // {data:"checkall"},{data:"details"},,{data:"is_ringtree"}
      {
        data: "name"
      }, {
        data: "subid"
      }, {
        data: "valtype"
      }, {
        data: "typeval"
      }, {
        data: "hour"
      }, {
        data: "day"
      }, {
        data: "month"
      }, {
        data: "total"
      }, {
        data: "created_at"
      }, {
        data: "active_status"
      }, {
        data: "action"
      }],
      columnDefs: [{
        "targets": [9, 10],
        "orderable": false
      }]
    };
    this.dataTable = $(this.table.nativeElement);
    this.dataTable.dataTable(this.dtOptions);
  }
  checkalldelete(event) {
    const checked = event.target.checked;
    this.numbers.forEach(chkbox => chkbox.selected = checked);
  }
  deleteselected(event) {
    // $("#customCheck1").prop("checked", false);
    if (event.target.checked == true) {
      if (event.target.value == 'on') {
        this.checkboxes = [];
        this.numbers.forEach(lbl => {
          this.checkboxes.push(lbl.id);
        });
      } else {
        if (this.checkboxes.length + 1 == this.numbers.length) {
          $("#customCheck1").prop("checked", true);
        }
        this.checkboxes.push(event.target.value);
      }
      this.ischecked = '0';
    } else {
      // console.log(this.checkboxes);
      if (this.checkboxes.length != 0) {
        $("#customCheck1").prop("checked", false);
      }
      if (event.target.value != 'on') {
        const index = this.checkboxes.indexOf(event.target.value);
        this.checkboxes.splice(index, 1);
      } else {
        this.checkboxes = [];
      }
      this.ischecked = '1';
    }
    // console.log(this.checkboxes);
  }

  onDeleteSubmit() {
    if (this.checkboxes.length == 0) {
      this.toastrService.error('Please Select Row To Delete');
    } else {
      // console.log(this.checkboxes);
      sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
        title: 'Are you sure?',
        text: 'You want to Delete Selected Record!',
        showCancelButton: true,
        confirmButtonText: 'Yes, delete it!',
        cancelButtonText: 'No, keep it'
      }).then(result => {
        if (result.value) {
          this.moduleservice.deleteSelectedNumbers(this.checkboxes).subscribe(res => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Records Deleted Successfully.');
            setTimeout(() => {
              sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
            }, 2000);
            this.loadTargets();
          }, error => this.error = error);
        } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
        }
      });
    }
  }
  Delete(id, type, number, company_uuid) {
    // console.log(type);
    if (type == 'Number') {
      let no = number.replace(/[^\d]/g, '');
      this.moduleservice.getNumberdatabyno(no, company_uuid, 1).subscribe(res => {
        this.ngxLoader.stopLoader('loader-01');
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
          title: 'Are you sure?',
          html: `Hey! You're trying to delete a number that has received <span class="text-danger"><b>${res.allcalls}</b></span> calls in the past <span class="text-success"><b>7 days</b></span>, are you sure you want to delete this?`,
          showCancelButton: true,
          confirmButtonText: 'Yes, delete it!',
          cancelButtonText: 'No, keep it'
        }).then(result => {
          if (result.value) {
            let currentUser = JSON.parse(localStorage.getItem('currentUser'));
            this.moduleservice.deleteNumber(id, currentUser.uuid).subscribe(res => {
              this.loadTargets();
              // this.toastrService.success('Number Deleted Successfully');
              sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Record Deleted Successfully.');
              setTimeout(() => {
                sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
              }, 2000);
            }, error => this.error = error);
          } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)');
            setTimeout(() => {
              sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
            }, 2000);
          }
        });
      });
    } else {
      sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
        title: 'Are you sure?',
        text: 'You want to Delete Record!',
        showCancelButton: true,
        confirmButtonText: 'Yes, delete it!',
        cancelButtonText: 'No, keep it'
      }).then(result => {
        if (result.value) {
          let currentUser = JSON.parse(localStorage.getItem('currentUser'));
          this.moduleservice.deleteNumber(id, currentUser.uuid).subscribe(res => {
            this.loadTargets();
            // this.toastrService.success('Number Deleted Successfully');
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Record Deleted Successfully.');
            setTimeout(() => {
              sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
            }, 2000);
          }, error => this.error = error);
        } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
        }
      });
    }
  }
  Clone(id) {
    sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
      title: 'Are you sure?',
      text: 'You want to clone this target!',
      showCancelButton: true,
      confirmButtonText: 'Yes, clone it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        let currentUser = JSON.parse(localStorage.getItem('currentUser'));
        let currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
        // console.log(id,currentUser.uuid,currentCompany.uuid); return
        this.moduleservice.cloneNumber(id, currentUser.uuid, currentCompany.uuid).subscribe(res => {
          this.filter = [res];
          if (this.filter[0]['status'] == 'success') {
            this.loadTargets();
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Success!', 'Target Clone Successfully.');
            setTimeout(() => {
              sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
            }, 2000);
            this.router.navigate(['/edit-numbers/' + this.filter[0]['uuid']]);
          } else {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Error', 'Target Clone failed.');
          }
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', '');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
        }, 2000);
      }
    });
  }
  exportdata() {
    var options = {
      fieldSeparator: ',',
      quoteStrings: '"',
      decimalseparator: '.',
      showLabels: true,
      // showTitle: true,
      // title: 'Your title',
      useBom: true,
      // noDownload: true,
      headers: ["Number", "FSL Rule Name", "Rule Set", "Note", "Associated abel", "Created At"]
    };
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleservice.getNumberForExport(this.currentCompany.uuid, "all").subscribe(res => {
      console.log(res);
      new ngx_csv_ngx_csv__WEBPACK_IMPORTED_MODULE_5__.ngxCsv(res, 'All Targets', options);
    }, error => this.error = error);
  }
  change_status(event, tagetUuid) {
    this.status = event.target.checked;
    let activestatus, activestring;
    if (this.status == true) {
      activestatus = 1;
      activestring = "Activate";
    } else {
      activestatus = 0;
      activestring = "De-activate";
    }
    // alert(activestatus); return
    sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
      title: 'Are you sure?',
      text: 'You want to ' + activestring + ' Target!',
      showCancelButton: true,
      confirmButtonText: 'Yes, ' + activestring + ' it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        let currentUser = JSON.parse(localStorage.getItem('currentUser'));
        this.moduleservice.changeTargetStatus(activestatus, currentUser.uuid, tagetUuid).subscribe(res => {
          this.loadTargets();
          // this.toastrService.success('Number Deleted Successfully');
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Changed!', 'Target ' + activestring + ' Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
        }, 2000);
        this.loadTargets();
        return;
      }
    });
  }
  closeref(i) {
    $(".appendedtbl_" + i).remove();
    $(".detailrow_" + i).removeClass('shown');
  }
  details(i, data) {
    var tr = $('details-control').closest('tr').eq(i);
    // var divClass = $(".detailrow_"+i).eq(0).attr('class');
    var divClass1 = $('#home_' + i).attr('class');
    $('.appendedtable').remove();
    // console.log(divClass1);
    // if (divClass.indexOf('shown') > -1) {
    if (divClass1 != undefined) {
      $(".appendedtbl_" + i).remove();
      $(".detailrow_" + i).removeClass('shown');
    } else {
      let currentUser = JSON.parse(localStorage.getItem('currentUser'));
      this.moduleservice.getTagetdetailsdata(data.uuid, currentUser.uuid).subscribe(res => {
        var SiteUrl = this.SiteUrl;
        var campaigns = '';
        var campaignsdata = '<div class="">' + '<div class="mt-2 mb-2">' + '<div class="row" style="border-bottom: 1px solid #403f3f;">' + '<div class="col-md-2">' + '<h6 style="font-size:13px;padding: 2px;">Target Reference</h6>' + '</div>' + '<div class="col-md-9"></div>' + '<div class="col-md-1 text-right">' +
        // '<button class="btn btn-sm btn-danger" onClick="closeref('+i+')">Close</button>'+
        '</div>' + '</div>' + '</div>' + '<table class="table  table-striped targetreferencetable">' + '<tr style="background: #252d48!important;"><th>Type</th>' + '<th>Name</th>' + '<th>Reference</th></tr>';
        if (res.data.length > 0) {
          for (let index = 0; index < res.data.length; index++) {
            const data = res.data[index];
            // var count = index+1;
            campaignsdata += `<tr style="background:#1F263D!important">
                    <td>Campaign Routing</td>
                    <td><a class="expandlink" style="color:white;text-decoration:underline" target="_blank" href="${SiteUrl}edit-campaign/${data.uuid}">${data.name}</a></td>
                    <td>${data.uuid}</td>
                  </tr>`;
            // '<div class="mb-2">'+
            //   '<span class="text-job text-primary">Assigned Campaign - '+count+'</span>'+'</div>'+
            //   '<div class="row">'+
            //     '<div class="col-md-2">Campaign Name</div>'+
            //     '<div class="col-md-3"><a class="expandlink" style="color:white;text-decoration:underline" target="_blank" href="'+SiteUrl+'/edit-campaign/'+data.uuid+'">'+data.name+'</a></div>'+
            //   '</div>'+
            //   '<div class="row">'+
            //     '<div class="col-md-2">Country</div>'+
            //     '<div class="col-md-3">'+
            //     data.country+'</div>'+
            //   '</div>'+
          }
        }
        // else{
        //   campaignsdata +=`<tr>
        //   <td colspan="3">No Campaign Assigned</td>
        // </tr>`;
        //   // campaignsdata +='<div class="activity">'+
        //   //               '<div class="activity-icon bg-blue text-white">'+
        //   //               '<i class="fas fa-info"></i>'+
        //   //             '</div>'+
        //   //             '<div class="activity-detail">'+
        //   //               '<div class="mb-2">'+
        //   //                 '<span class="text-job text-primary">No Campaign Assigned</span>'+'</div>'+
        //   //             '</div>'+
        //   //           '</div>';
        // }
        // console.log(res.data1);
        if (res.data1.length > 0) {
          for (let index = 0; index < res.data1.length; index++) {
            const data1 = res.data1[index];
            // var count = index+1;
            campaignsdata += `<tr>
                    <td>IVR Routing</td>
                    <td><a class="expandlink" style="color:white;text-decoration:underline" target="_blank" href="${SiteUrl}edit-ivr/${data1.uuid}">${data1.name}</a></td>
                    <td>${data1.uuid}</td>
                  </tr>`;
          }
        }
        if (res.data1.length == 0 && res.data.length == 0) {
          campaignsdata += `<tr>
                <td colspan="3" class="text-center">This target does not have any references</td>
              </tr>`;
        }
        campaignsdata += '</th>' + '</div>';
        '</div>';
        // if(res.data1.length>0){
        //   for (let index = 0; index < res.data1.length; index++) {
        //     const data1 =  res.data1[index];
        //     var count = index+1;
        //     campaignsdata +='<div class="activity">'+
        //             '<div class="activity-icon bg-blue text-white">'+
        //             '<i class="fas fa-info"></i>'+
        //           '</div>'+
        //           '<div class="activity-detail">'+
        //             '<div class="mb-2">'+
        //               '<span class="text-job text-primary">Assigned IVR</span>'+'</div>'+
        //               '<div class="row">'+
        //                 '<div class="col-md-2">IVR Name</div>'+
        //                 '<div class="col-md-3"><a class="expandlink" style="color:white;text-decoration:underline" target="_blank" href="'+SiteUrl+'/edit-ivr/'+data1.uuid+'">'+data1.name+'</a></div>'+
        //               '</div>'+
        //           '</div>'+
        //         '</div>';
        //   }
        //   }else{
        //     campaignsdata +='<div class="activity">'+
        //                   '<div class="activity-icon bg-blue text-white">'+
        //                   '<i class="fas fa-info"></i>'+
        //                 '</div>'+
        //                 '<div class="activity-detail">'+
        //                   '<div class="mb-2">'+
        //                     '<span class="text-job text-primary">No IVR Assigned</span>'+'</div>'+
        //                 '</div>'+
        //               '</div>';
        //   }
        campaignsdata += '</th>' + '</div>';
        '</div>';
        campaigns += campaigns.concat(campaignsdata);
        // console.log(campaigns);
        $(".detailrow_" + i).after('<div class="appendedtable appendedtbl_' + i + '">' +
        // '<ul class="nav nav-tabs expandtabs">'+
        //   '<li id="eventtgl" style="padding: 6px 6px 0px 5px;border-radius: 3px;border: 1px solid #747e9a;margin-right: 2px;    margin-bottom: 3px;" class="active"><a class="active" data-toggle="tab" href="#home_'+i+'">Event</a></li>'+
        // '<li style="padding: 6px 6px 0px 5px;border-radius: 3px;border: 1px solid #747e9a;margin-right: 2px;    margin-bottom: 3px;"><a  data-toggle="tab" href="#menu_'+i+'">Record</a></li>'+
        // '<li style="padding: 6px 6px 0px 5px;border-radius: 3px;border: 1px solid #747e9a;margin-right: 2px;    margin-bottom: 3px;"><a data-toggle="tab" href="#tag_'+i+'">Tag</a></li>'+
        // '</ul>'+
        '<div class="tab-content">' + '<div id="home_' + i + '" class="tab-pane fade in active show">' + '<section class="section" style="width: 0px;">' + '<div class="section-body">' + '<div class="activities1" style="display: block;width: 1553px!important;">' +
        // '<div class="activity">'+
        //   '<div class="activity-icon bg-blue text-white">'+
        //     '<i class="fas fa-info"></i>'+
        //   '</div>'+
        //   '<div class="activity-detail">'+
        //     '<div class="mb-2">'+
        //       '<span class="text-job text-primary">Assigned Campaigns</span>'+'</div>'+
        //       '<div class="row">'+
        //         '<div class="col-md-1">Campaign Name</div>'+
        //         '<div class="col-md-3">'+name+'</div>'+
        //       '</div>'+
        //       '<div class="row">'+
        //         '<div class="col-md-1">Country</div>'+
        //         '<div class="col-md-3">'+
        //         country+'</div>'+
        //       '</div>'+
        //   '</div>'+
        // '</div>'+
        campaigns + '</span>' + '</div>' + '</section> ' + '</div>' + '</div>' + '</div>');
        tr.addClass('shown');
      }, error => this.error = error);
    }
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_8__.ToastrService
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_6__.Router
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_7__.HttpBackend
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_9__.Title
  }, {
    type: ngx_ui_loader__WEBPACK_IMPORTED_MODULE_10__.NgxUiLoaderService
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_11__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }]
  };
};
NumberComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_12__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_11__.Component)({
  selector: 'app-number',
  template: _number_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_number_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], NumberComponent);


/***/ }),

/***/ 11722:
/*!*****************************************************************!*\
  !*** ./src/app/modules/number/numberadd/numberadd.component.ts ***!
  \*****************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "NumberaddComponent": () => (/* binding */ NumberaddComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _numberadd_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./numberadd.component.html?ngResource */ 51489);
/* harmony import */ var _numberadd_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./numberadd.component.scss?ngResource */ 43969);
/* harmony import */ var _numberadd_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_numberadd_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../module.service */ 22947);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! moment */ 56908);
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(moment__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! sweetalert2 */ 60598);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(sweetalert2__WEBPACK_IMPORTED_MODULE_4__);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @angular/platform-browser */ 34497);










//import 'sweetalert2/src/sweetalert2.scss'


class FSLClass {}
class filterarr {}
let NumberaddComponent = class NumberaddComponent {
  constructor(handler, fb, moduleService, router, route, toastrService, cdRef, titleService) {
    this.fb = fb;
    this.moduleService = moduleService;
    this.router = router;
    this.route = route;
    this.toastrService = toastrService;
    this.cdRef = cdRef;
    this.titleService = titleService;
    this.submitted = false;
    this.FSLRulesSubmitted = false;
    this.FSLRulesEditSubmitted = false;
    this.daysSubmitted = false;
    this.daysEditSubmitted = false;
    this.dropdownList = [];
    this.selectedItems = [];
    // dropdownSettings: { singleSelection: boolean; text: string; selectAllText: string; unSelectAllText: string; enableSearchFilter: boolean; classes: string; };
    this.dropdownSettings = {};
    this.ivrdropdownSettings = {};
    this.citystatedropdownSettings = {};
    this.citydropdownSettings = {};
    this.allBuyers = [];
    this.alltimezone = [];
    this.daytype = 0;
    this.flag = 0;
    this.company = "";
    this.allzipcode = "";
    this.ringtree = false;
    this.ringtreetext = "Simple";
    this.methodtypeval = 0;
    this.hof_alwaysopen = false;
    this.isadvanced = 0;
    this.advanced = 'Advanced';
    this.is12or24 = 0;
    this.sundayopen = 1;
    this.mondayopen = 1;
    this.tuesdayopen = 1;
    this.wednesdayopen = 1;
    this.thursdayopen = 1;
    this.fridayopen = 1;
    this.saturdayopen = 1;
    this.isfilter = 0;
    this.ispubfilter = 0;
    this.addkeyword = [];
    this.settings = {};
    this.ivrMenu = [];
    this.allcitystate = [];
    this.allpublisher = [];
    this.allpublisherbkp = [];
    this.filterselected = [];
    this.settingToggleTypeval = 0;
    this.settingToggleDurationvalue = 0;
    this.timezoneval = [{
      "id": 6,
      "itemName": "(GMT-07:00) Arizona"
    }];
    this.loader = false;
    this.BuyerSubmitted = false;
    this.filename = ""; //for headings
    this.lines = []; //for headings
    this.linesR = []; // for rows
    this.selectedfile = null;
    // Day0
    this.selectedPrimaryForaward_0_day0 = 0;
    this.selectedPrimaryCount_0_day0 = 0;
    this.selected_0_day_0 = 0;
    this.selectedPrimaryForaward_1_day0 = 0;
    this.selectedPrimaryCount_1_day0 = 0;
    this.selected_1_day_0 = 0;
    this.selectedPrimaryForaward_2_day0 = 0;
    this.selectedPrimaryCount_2_day0 = 0;
    this.selected_2_day_0 = 0;
    this.selectedPrimaryForaward_3_day0 = 0;
    this.selectedPrimaryCount_3_day0 = 0;
    this.selected_3_day_0 = 0;
    this.selectedPrimaryForaward_4_day0 = 0;
    this.selectedPrimaryCount_4_day0 = 0;
    this.selected_4_day_0 = 0;
    this.selectedPrimaryForaward_5_day0 = 0;
    this.selectedPrimaryCount_5_day0 = 0;
    this.selected_5_day_0 = 0;
    this.selectedPrimaryForaward_6_day0 = 0;
    this.selectedPrimaryCount_6_day0 = 0;
    this.selected_6_day_0 = 0;
    this.selectedPrimaryForaward_7_day0 = 0;
    this.selectedPrimaryCount_7_day0 = 0;
    this.selected_7_day_0 = 0;
    this.selectedPrimaryForaward_8_day0 = 0;
    this.selectedPrimaryCount_8_day0 = 0;
    this.selected_8_day_0 = 0;
    this.selectedPrimaryForaward_9_day0 = 0;
    this.selectedPrimaryCount_9_day0 = 0;
    this.selected_9_day_0 = 0;
    // Day1
    this.selectedPrimaryForaward_0_day1 = 0;
    this.selectedPrimaryCount_0_day1 = 0;
    this.selected_0_day_1 = 0;
    this.selectedPrimaryForaward_1_day1 = 0;
    this.selectedPrimaryCount_1_day1 = 0;
    this.selected_1_day_1 = 0;
    this.selectedPrimaryForaward_2_day1 = 0;
    this.selectedPrimaryCount_2_day1 = 0;
    this.selected_2_day_1 = 0;
    this.selectedPrimaryForaward_3_day1 = 0;
    this.selectedPrimaryCount_3_day1 = 0;
    this.selected_3_day_1 = 0;
    this.selectedPrimaryForaward_4_day1 = 0;
    this.selectedPrimaryCount_4_day1 = 0;
    this.selected_4_day_1 = 0;
    this.selectedPrimaryForaward_5_day1 = 0;
    this.selectedPrimaryCount_5_day1 = 0;
    this.selected_5_day_1 = 0;
    this.selectedPrimaryForaward_6_day1 = 0;
    this.selectedPrimaryCount_6_day1 = 0;
    this.selected_6_day_1 = 0;
    this.selectedPrimaryForaward_7_day1 = 0;
    this.selectedPrimaryCount_7_day1 = 0;
    this.selected_7_day_1 = 0;
    this.selectedPrimaryForaward_8_day1 = 0;
    this.selectedPrimaryCount_8_day1 = 0;
    this.selected_8_day_1 = 0;
    this.selectedPrimaryForaward_9_day1 = 0;
    this.selectedPrimaryCount_9_day1 = 0;
    this.selected_9_day_1 = 0;
    // Day2
    this.selectedPrimaryForaward_0_day2 = 0;
    this.selectedPrimaryCount_0_day2 = 0;
    this.selected_0_day_2 = 0;
    this.selectedPrimaryForaward_1_day2 = 0;
    this.selectedPrimaryCount_1_day2 = 0;
    this.selected_1_day_2 = 0;
    this.selectedPrimaryForaward_2_day2 = 0;
    this.selectedPrimaryCount_2_day2 = 0;
    this.selected_2_day_2 = 0;
    this.selectedPrimaryForaward_3_day2 = 0;
    this.selectedPrimaryCount_3_day2 = 0;
    this.selected_3_day_2 = 0;
    this.selectedPrimaryForaward_4_day2 = 0;
    this.selectedPrimaryCount_4_day2 = 0;
    this.selected_4_day_2 = 0;
    this.selectedPrimaryForaward_5_day2 = 0;
    this.selectedPrimaryCount_5_day2 = 0;
    this.selected_5_day_2 = 0;
    this.selectedPrimaryForaward_6_day2 = 0;
    this.selectedPrimaryCount_6_day2 = 0;
    this.selected_6_day_2 = 0;
    this.selectedPrimaryForaward_7_day2 = 0;
    this.selectedPrimaryCount_7_day2 = 0;
    this.selected_7_day_2 = 0;
    this.selectedPrimaryForaward_8_day2 = 0;
    this.selectedPrimaryCount_8_day2 = 0;
    this.selected_8_day_2 = 0;
    this.selectedPrimaryForaward_9_day2 = 0;
    this.selectedPrimaryCount_9_day2 = 0;
    this.selected_9_day_2 = 0;
    // Day3
    this.selectedPrimaryForaward_0_day3 = 0;
    this.selectedPrimaryCount_0_day3 = 0;
    this.selected_0_day_3 = 0;
    this.selectedPrimaryForaward_1_day3 = 0;
    this.selectedPrimaryCount_1_day3 = 0;
    this.selected_1_day_3 = 0;
    this.selectedPrimaryForaward_2_day3 = 0;
    this.selectedPrimaryCount_2_day3 = 0;
    this.selected_2_day_3 = 0;
    this.selectedPrimaryForaward_3_day3 = 0;
    this.selectedPrimaryCount_3_day3 = 0;
    this.selected_3_day_3 = 0;
    this.selectedPrimaryForaward_4_day3 = 0;
    this.selectedPrimaryCount_4_day3 = 0;
    this.selected_4_day_3 = 0;
    this.selectedPrimaryForaward_5_day3 = 0;
    this.selectedPrimaryCount_5_day3 = 0;
    this.selected_5_day_3 = 0;
    this.selectedPrimaryForaward_6_day3 = 0;
    this.selectedPrimaryCount_6_day3 = 0;
    this.selected_6_day_3 = 0;
    this.selectedPrimaryForaward_7_day3 = 0;
    this.selectedPrimaryCount_7_day3 = 0;
    this.selected_7_day_3 = 0;
    this.selectedPrimaryForaward_8_day3 = 0;
    this.selectedPrimaryCount_8_day3 = 0;
    this.selected_8_day_3 = 0;
    this.selectedPrimaryForaward_9_day3 = 0;
    this.selectedPrimaryCount_9_day3 = 0;
    this.selected_9_day_3 = 0;
    // Day4
    this.selectedPrimaryForaward_0_day4 = 0;
    this.selectedPrimaryCount_0_day4 = 0;
    this.selected_0_day_4 = 0;
    this.selectedPrimaryForaward_1_day4 = 0;
    this.selectedPrimaryCount_1_day4 = 0;
    this.selected_1_day_4 = 0;
    this.selectedPrimaryForaward_2_day4 = 0;
    this.selectedPrimaryCount_2_day4 = 0;
    this.selected_2_day_4 = 0;
    this.selectedPrimaryForaward_3_day4 = 0;
    this.selectedPrimaryCount_3_day4 = 0;
    this.selected_3_day_4 = 0;
    this.selectedPrimaryForaward_4_day4 = 0;
    this.selectedPrimaryCount_4_day4 = 0;
    this.selected_4_day_4 = 0;
    this.selectedPrimaryForaward_5_day4 = 0;
    this.selectedPrimaryCount_5_day4 = 0;
    this.selected_5_day_4 = 0;
    this.selectedPrimaryForaward_6_day4 = 0;
    this.selectedPrimaryCount_6_day4 = 0;
    this.selected_6_day_4 = 0;
    this.selectedPrimaryForaward_7_day4 = 0;
    this.selectedPrimaryCount_7_day4 = 0;
    this.selected_7_day_4 = 0;
    this.selectedPrimaryForaward_8_day4 = 0;
    this.selectedPrimaryCount_8_day4 = 0;
    this.selected_8_day_4 = 0;
    this.selectedPrimaryForaward_9_day4 = 0;
    this.selectedPrimaryCount_9_day4 = 0;
    this.selected_9_day_4 = 0;
    // Day5
    this.selectedPrimaryForaward_0_day5 = 0;
    this.selectedPrimaryCount_0_day5 = 0;
    this.selected_0_day_5 = 0;
    this.selectedPrimaryForaward_1_day5 = 0;
    this.selectedPrimaryCount_1_day5 = 0;
    this.selected_1_day_5 = 0;
    this.selectedPrimaryForaward_2_day5 = 0;
    this.selectedPrimaryCount_2_day5 = 0;
    this.selected_2_day_5 = 0;
    this.selectedPrimaryForaward_3_day5 = 0;
    this.selectedPrimaryCount_3_day5 = 0;
    this.selected_3_day_5 = 0;
    this.selectedPrimaryForaward_4_day5 = 0;
    this.selectedPrimaryCount_4_day5 = 0;
    this.selected_4_day_5 = 0;
    this.selectedPrimaryForaward_5_day5 = 0;
    this.selectedPrimaryCount_5_day5 = 0;
    this.selected_5_day_5 = 0;
    this.selectedPrimaryForaward_6_day5 = 0;
    this.selectedPrimaryCount_6_day5 = 0;
    this.selected_6_day_5 = 0;
    this.selectedPrimaryForaward_7_day5 = 0;
    this.selectedPrimaryCount_7_day5 = 0;
    this.selected_7_day_5 = 0;
    this.selectedPrimaryForaward_8_day5 = 0;
    this.selectedPrimaryCount_8_day5 = 0;
    this.selected_8_day_5 = 0;
    this.selectedPrimaryForaward_9_day5 = 0;
    this.selectedPrimaryCount_9_day5 = 0;
    this.selected_9_day_5 = 0;
    // Day6
    this.selectedPrimaryForaward_0_day6 = 0;
    this.selectedPrimaryCount_0_day6 = 0;
    this.selected_0_day_6 = 0;
    this.selectedPrimaryForaward_1_day6 = 0;
    this.selectedPrimaryCount_1_day6 = 0;
    this.selected_1_day_6 = 0;
    this.selectedPrimaryForaward_2_day6 = 0;
    this.selectedPrimaryCount_2_day6 = 0;
    this.selected_2_day_6 = 0;
    this.selectedPrimaryForaward_3_day6 = 0;
    this.selectedPrimaryCount_3_day6 = 0;
    this.selected_3_day_6 = 0;
    this.selectedPrimaryForaward_4_day6 = 0;
    this.selectedPrimaryCount_4_day6 = 0;
    this.selected_4_day_6 = 0;
    this.selectedPrimaryForaward_5_day6 = 0;
    this.selectedPrimaryCount_5_day6 = 0;
    this.selected_5_day_6 = 0;
    this.selectedPrimaryForaward_6_day6 = 0;
    this.selectedPrimaryCount_6_day6 = 0;
    this.selected_6_day_6 = 0;
    this.selectedPrimaryForaward_7_day6 = 0;
    this.selectedPrimaryCount_7_day6 = 0;
    this.selected_7_day_6 = 0;
    this.selectedPrimaryForaward_8_day6 = 0;
    this.selectedPrimaryCount_8_day6 = 0;
    this.selected_8_day_6 = 0;
    this.selectedPrimaryForaward_9_day6 = 0;
    this.selectedPrimaryCount_9_day6 = 0;
    this.selected_9_day_6 = 0;
    this.selectedLevel = 0;
    this.isadded = 0;
    this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_5__.HttpClient(handler);
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  gettimezone() {
    this.moduleService.gettimezone().subscribe(res => {
      this.alltimezone = res;
      // console.log(res);
    });
  }
  // increment_hrs(index:string){
  //   let val = this.addForm.get(index).value;
  //   if(this.is12or24==1){
  //     if(val<23){
  //       this.addForm.get(index).setValue(Number(val)+1);
  //       }
  //   }else{
  //     if(val<12){
  //       this.addForm.get(index).setValue(Number(val)+1);
  //       }
  //   }
  // }
  // decrement_hrs(index:string){
  //   let val = this.addForm.get(index).value;
  //   if(val>0){
  //     this.addForm.get(index).setValue(Number(val)-1);
  //   }
  // }
  // increment_min(index:string){
  //   let val = this.addForm.get(index).value;
  //   if(val<59){
  //   this.addForm.get(index).setValue(Number(val)+1);
  //   }
  // }
  // decrement_min(index:string){
  //   let val = this.addForm.get(index).value;
  //   if(val>0){
  //     this.addForm.get(index).setValue(Number(val)-1);
  //   }
  // }
  increment_hrs(index) {
    let val = this.addForm.get(index).value;
    if (this.is12or24 == 0) {
      if (val < 23) {
        let fianlval = Number(val) + 1;
        this.addForm.get(index).setValue(fianlval < 10 ? "0" + fianlval : fianlval);
      }
    } else {
      if (val < 12) {
        let fianlval = Number(val) + 1;
        this.addForm.get(index).setValue(fianlval < 10 ? "0" + fianlval : fianlval);
      }
    }
  }
  decrement_hrs(index) {
    let val = this.addForm.get(index).value;
    if (val > 0) {
      let fianlval = Number(val) - 1;
      this.addForm.get(index).setValue(fianlval < 10 ? "0" + fianlval : fianlval);
    }
  }
  increment_min(index) {
    let val = this.addForm.get(index).value;
    if (val < 59) {
      let fianlval = Number(val) + 1;
      this.addForm.get(index).setValue(fianlval < 10 ? "0" + fianlval : fianlval);
    }
  }
  decrement_min(index) {
    let val = this.addForm.get(index).value;
    if (val > 0) {
      let fianlval = Number(val) - 1;
      this.addForm.get(index).setValue(fianlval < 10 ? "0" + fianlval : fianlval);
    }
  }
  appm_change(index) {
    let val = this.addForm.get(index).value;
    if (val == 0) {
      this.addForm.get(index).setValue(1);
    } else {
      this.addForm.get(index).setValue(0);
    }
    // if(this.addForm.get(index).value==0){
    //   this.addForm.get("start_hrs").setValue(0);
    //   this.addForm.get("start_min").setValue(1);
    // }else{
    //   this.addForm.get("start_hrs").setValue(23);
    //   this.addForm.get("start_min").setValue(59);
    // }
  }

  closeModal() {
    if (this.noofforwarding) {
      $("#addFSLRules").modal("hide");
      setTimeout(() => {
        this.addFSLRules.reset({
          'name': ' ',
          'numberoftimeframe': ' '
        });
        this.getAllRules();
      }, 2000);
    }
  }
  ngAfterViewChecked() {
    this.cdRef.detectChanges();
  }
  editcloseModal() {
    if (this.noofforwarding) {
      $("#editFSLRules").modal("hide");
      this.FSLRulesEditSubmitted = false;
      setTimeout(() => {
        this.getAllRules();
        this.getRulesByName(this.addForm.get('fslrulesname').value);
      }, 2000);
    }
  }
  getallbuyers() {
    this.moduleService.getallbuyers(this.currentCompany.uuid).subscribe(result => {
      if (result.length > 0) {
        let text = result.filter(x => x.itemName == this.company)[0];
        if (text != undefined) {
          this.selectedItems = [{
            "id": text.id,
            "itemName": text.text
          }];
        }
      }
      this.allBuyers = result;
    }, error => this.error = error);
  }
  getallzipcode() {
    this.moduleService.getallzipcode(this.currentCompany.uuid, "").subscribe(result => {
      // if(result.length>0){
      // let text =  result.filter(x => x.itemName == this.company)[0];
      // if(text!=undefined){
      //   this.selectedItems = [{"id":text.id,"itemName":text.text}];
      // }
      // }
      this.allzipcode = result;
    }, error => this.error = error);
  }
  getAllRules() {
    this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleService.getallbuyers(this.currentCompany.uuid).subscribe(res => {
      //  console.log(res); return false;
      // this.allRulesData = res.allrules;
      this.allBuyers = res;
    }, error => this.error = error);
  }
  getAllLabels() {
    this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleService.getAllLabels(this.currentCompany.uuid).subscribe(res => {
      this.dropdownList = res;
    }, error => this.error = error);
  }
  getRulesByName(name) {
    this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleService.getRulesByName(name, this.currentCompany.uuid).subscribe(res => {
      this.allRulesbyname = res;
    }, error => this.error = error);
  }
  _keyPress(event) {
    const isNumericInput = event => {
      const key = event.keyCode;
      return key >= 48 && key <= 57 ||
      // Allow number line
      key >= 96 && key <= 105 // Allow number pad
      ;
    };

    const isModifierKey = event => {
      const key = event.keyCode;
      return event.shiftKey === true || key === 35 || key === 36 ||
      // Allow Shift, Home, End
      key === 8 || key === 9 || key === 13 || key === 46 ||
      // Allow Backspace, Tab, Enter, Delete
      key > 36 && key < 41 ||
      // Allow left, up, right, down

      // Allow Ctrl/Command + A,C,V,X,Z
      (event.ctrlKey === true || event.metaKey === true) && (key === 65 || key === 67 || key === 86 || key === 88 || key === 90);
    };
    const enforceFormat = event => {
      // Input must be of a valid number format or a modifier key, and not longer than ten digits
      if (!isNumericInput(event) && !isModifierKey(event)) {
        event.preventDefault();
      }
    };
    const formatToPhone = event => {
      if (isModifierKey(event)) {
        return;
      }
      const target = event.target;
      const input = event.target.value.replace(/\D/g, '').substring(0, 10); // First ten digits of input only
      const zip = input.substring(0, 3);
      const middle = input.substring(3, 6);
      const last = input.substring(6, 10);
      if (input.length > 6) {
        target.value = `(${zip}) ${middle}-${last}`;
      } else if (input.length > 3) {
        target.value = `(${zip}) ${middle}`;
      } else if (input.length > 0) {
        target.value = `(${zip}`;
      }
    };
    const inputElement = document.getElementById('number');
    const number_0_day0 = document.getElementById('number_0_day0');
    const number_1_day0 = document.getElementById('number_1_day0');
    const number_2_day0 = document.getElementById('number_2_day0');
    const number_3_day0 = document.getElementById('number_3_day0');
    const number_4_day0 = document.getElementById('number_4_day0');
    const number_5_day0 = document.getElementById('number_5_day0');
    const number_6_day0 = document.getElementById('number_6_day0');
    const number_7_day0 = document.getElementById('number_7_day0');
    const number_8_day0 = document.getElementById('number_8_day0');
    const number_9_day0 = document.getElementById('number_9_day0');
    const number_0_day1 = document.getElementById('number_0_day1');
    const number_1_day1 = document.getElementById('number_1_day1');
    const number_2_day1 = document.getElementById('number_2_day1');
    const number_3_day1 = document.getElementById('number_3_day1');
    const number_4_day1 = document.getElementById('number_4_day1');
    const number_5_day1 = document.getElementById('number_5_day1');
    const number_6_day1 = document.getElementById('number_6_day1');
    const number_7_day1 = document.getElementById('number_7_day1');
    const number_8_day1 = document.getElementById('number_8_day1');
    const number_9_day1 = document.getElementById('number_9_day1');
    const number_0_day2 = document.getElementById('number_0_day2');
    const number_1_day2 = document.getElementById('number_1_day2');
    const number_2_day2 = document.getElementById('number_2_day2');
    const number_3_day2 = document.getElementById('number_3_day2');
    const number_4_day2 = document.getElementById('number_4_day2');
    const number_5_day2 = document.getElementById('number_5_day2');
    const number_6_day2 = document.getElementById('number_6_day2');
    const number_7_day2 = document.getElementById('number_7_day2');
    const number_8_day2 = document.getElementById('number_8_day2');
    const number_9_day2 = document.getElementById('number_9_day2');
    const number_0_day3 = document.getElementById('number_0_day3');
    const number_1_day3 = document.getElementById('number_1_day3');
    const number_2_day3 = document.getElementById('number_2_day3');
    const number_3_day3 = document.getElementById('number_3_day3');
    const number_4_day3 = document.getElementById('number_4_day3');
    const number_5_day3 = document.getElementById('number_5_day3');
    const number_6_day3 = document.getElementById('number_6_day3');
    const number_7_day3 = document.getElementById('number_7_day3');
    const number_8_day3 = document.getElementById('number_8_day3');
    const number_9_day3 = document.getElementById('number_9_day3');
    const number_0_day4 = document.getElementById('number_0_day4');
    const number_1_day4 = document.getElementById('number_1_day4');
    const number_2_day4 = document.getElementById('number_2_day4');
    const number_3_day4 = document.getElementById('number_3_day4');
    const number_4_day4 = document.getElementById('number_4_day4');
    const number_5_day4 = document.getElementById('number_5_day4');
    const number_6_day4 = document.getElementById('number_6_day4');
    const number_7_day4 = document.getElementById('number_7_day4');
    const number_8_day4 = document.getElementById('number_8_day4');
    const number_9_day4 = document.getElementById('number_9_day4');
    const number_0_day5 = document.getElementById('number_0_day5');
    const number_1_day5 = document.getElementById('number_1_day5');
    const number_2_day5 = document.getElementById('number_2_day5');
    const number_3_day5 = document.getElementById('number_3_day5');
    const number_4_day5 = document.getElementById('number_4_day5');
    const number_5_day5 = document.getElementById('number_5_day5');
    const number_6_day5 = document.getElementById('number_6_day5');
    const number_7_day5 = document.getElementById('number_7_day5');
    const number_8_day5 = document.getElementById('number_8_day5');
    const number_9_day5 = document.getElementById('number_9_day5');
    const number_0_day6 = document.getElementById('number_0_day6');
    const number_1_day6 = document.getElementById('number_1_day6');
    const number_2_day6 = document.getElementById('number_2_day6');
    const number_3_day6 = document.getElementById('number_3_day6');
    const number_4_day6 = document.getElementById('number_4_day6');
    const number_5_day6 = document.getElementById('number_5_day6');
    const number_6_day6 = document.getElementById('number_6_day6');
    const number_7_day6 = document.getElementById('number_7_day6');
    const number_8_day6 = document.getElementById('number_8_day6');
    const number_9_day6 = document.getElementById('number_9_day6');
    if (inputElement) {
      inputElement.addEventListener('keydown', enforceFormat);
      inputElement.addEventListener('keyup', formatToPhone);
    }
    if (number_0_day0) {
      number_0_day0.addEventListener('keydown', enforceFormat);
      number_0_day0.addEventListener('keyup', formatToPhone);
    }
    if (number_1_day0) {
      number_1_day0.addEventListener('keydown', enforceFormat);
      number_1_day0.addEventListener('keyup', formatToPhone);
    }
    if (number_2_day0) {
      number_2_day0.addEventListener('keydown', enforceFormat);
      number_2_day0.addEventListener('keyup', formatToPhone);
    }
    if (number_3_day0) {
      number_3_day0.addEventListener('keydown', enforceFormat);
      number_3_day0.addEventListener('keyup', formatToPhone);
    }
    if (number_4_day0) {
      number_4_day0.addEventListener('keydown', enforceFormat);
      number_4_day0.addEventListener('keyup', formatToPhone);
    }
    if (number_5_day0) {
      number_5_day0.addEventListener('keydown', enforceFormat);
      number_5_day0.addEventListener('keyup', formatToPhone);
    }
    if (number_6_day0) {
      number_6_day0.addEventListener('keydown', enforceFormat);
      number_6_day0.addEventListener('keyup', formatToPhone);
    }
    if (number_7_day0) {
      number_7_day0.addEventListener('keydown', enforceFormat);
      number_7_day0.addEventListener('keyup', formatToPhone);
    }
    if (number_8_day0) {
      number_8_day0.addEventListener('keydown', enforceFormat);
      number_8_day0.addEventListener('keyup', formatToPhone);
    }
    if (number_9_day0) {
      number_9_day0.addEventListener('keydown', enforceFormat);
      number_9_day0.addEventListener('keyup', formatToPhone);
    }
    if (number_0_day1) {
      number_0_day1.addEventListener('keydown', enforceFormat);
      number_0_day1.addEventListener('keyup', formatToPhone);
    }
    if (number_1_day1) {
      number_1_day1.addEventListener('keydown', enforceFormat);
      number_1_day1.addEventListener('keyup', formatToPhone);
    }
    if (number_2_day1) {
      number_2_day1.addEventListener('keydown', enforceFormat);
      number_2_day1.addEventListener('keyup', formatToPhone);
    }
    if (number_3_day1) {
      number_3_day1.addEventListener('keydown', enforceFormat);
      number_3_day1.addEventListener('keyup', formatToPhone);
    }
    if (number_4_day1) {
      number_4_day1.addEventListener('keydown', enforceFormat);
      number_4_day1.addEventListener('keyup', formatToPhone);
    }
    if (number_5_day1) {
      number_5_day1.addEventListener('keydown', enforceFormat);
      number_5_day1.addEventListener('keyup', formatToPhone);
    }
    if (number_6_day1) {
      number_6_day1.addEventListener('keydown', enforceFormat);
      number_6_day1.addEventListener('keyup', formatToPhone);
    }
    if (number_7_day1) {
      number_7_day1.addEventListener('keydown', enforceFormat);
      number_7_day1.addEventListener('keyup', formatToPhone);
    }
    if (number_8_day1) {
      number_8_day1.addEventListener('keydown', enforceFormat);
      number_8_day1.addEventListener('keyup', formatToPhone);
    }
    if (number_9_day1) {
      number_9_day1.addEventListener('keydown', enforceFormat);
      number_9_day1.addEventListener('keyup', formatToPhone);
    }
    if (number_0_day2) {
      number_0_day2.addEventListener('keydown', enforceFormat);
      number_0_day2.addEventListener('keyup', formatToPhone);
    }
    if (number_1_day2) {
      number_1_day2.addEventListener('keydown', enforceFormat);
      number_1_day2.addEventListener('keyup', formatToPhone);
    }
    if (number_2_day2) {
      number_2_day2.addEventListener('keydown', enforceFormat);
      number_2_day2.addEventListener('keyup', formatToPhone);
    }
    if (number_3_day2) {
      number_3_day2.addEventListener('keydown', enforceFormat);
      number_3_day2.addEventListener('keyup', formatToPhone);
    }
    if (number_4_day2) {
      number_4_day2.addEventListener('keydown', enforceFormat);
      number_4_day2.addEventListener('keyup', formatToPhone);
    }
    if (number_5_day2) {
      number_5_day2.addEventListener('keydown', enforceFormat);
      number_5_day2.addEventListener('keyup', formatToPhone);
    }
    if (number_6_day2) {
      number_6_day2.addEventListener('keydown', enforceFormat);
      number_6_day2.addEventListener('keyup', formatToPhone);
    }
    if (number_7_day2) {
      number_7_day2.addEventListener('keydown', enforceFormat);
      number_7_day2.addEventListener('keyup', formatToPhone);
    }
    if (number_8_day2) {
      number_8_day2.addEventListener('keydown', enforceFormat);
      number_8_day2.addEventListener('keyup', formatToPhone);
    }
    if (number_9_day2) {
      number_9_day2.addEventListener('keydown', enforceFormat);
      number_9_day2.addEventListener('keyup', formatToPhone);
    }
    if (number_0_day3) {
      number_0_day3.addEventListener('keydown', enforceFormat);
      number_0_day3.addEventListener('keyup', formatToPhone);
    }
    if (number_1_day3) {
      number_1_day3.addEventListener('keydown', enforceFormat);
      number_1_day3.addEventListener('keyup', formatToPhone);
    }
    if (number_2_day3) {
      number_2_day3.addEventListener('keydown', enforceFormat);
      number_2_day3.addEventListener('keyup', formatToPhone);
    }
    if (number_3_day3) {
      number_3_day3.addEventListener('keydown', enforceFormat);
      number_3_day3.addEventListener('keyup', formatToPhone);
    }
    if (number_4_day3) {
      number_4_day3.addEventListener('keydown', enforceFormat);
      number_4_day3.addEventListener('keyup', formatToPhone);
    }
    if (number_5_day3) {
      number_5_day3.addEventListener('keydown', enforceFormat);
      number_5_day3.addEventListener('keyup', formatToPhone);
    }
    if (number_6_day3) {
      number_6_day3.addEventListener('keydown', enforceFormat);
      number_6_day3.addEventListener('keyup', formatToPhone);
    }
    if (number_7_day3) {
      number_7_day3.addEventListener('keydown', enforceFormat);
      number_7_day3.addEventListener('keyup', formatToPhone);
    }
    if (number_8_day3) {
      number_8_day3.addEventListener('keydown', enforceFormat);
      number_8_day3.addEventListener('keyup', formatToPhone);
    }
    if (number_9_day3) {
      number_9_day3.addEventListener('keydown', enforceFormat);
      number_9_day3.addEventListener('keyup', formatToPhone);
    }
    if (number_0_day4) {
      number_0_day4.addEventListener('keydown', enforceFormat);
      number_0_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_1_day4) {
      number_1_day4.addEventListener('keydown', enforceFormat);
      number_1_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_2_day4) {
      number_2_day4.addEventListener('keydown', enforceFormat);
      number_2_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_3_day4) {
      number_3_day4.addEventListener('keydown', enforceFormat);
      number_3_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_4_day4) {
      number_4_day4.addEventListener('keydown', enforceFormat);
      number_4_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_5_day4) {
      number_5_day4.addEventListener('keydown', enforceFormat);
      number_5_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_6_day4) {
      number_6_day4.addEventListener('keydown', enforceFormat);
      number_6_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_7_day4) {
      number_7_day4.addEventListener('keydown', enforceFormat);
      number_7_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_8_day4) {
      number_8_day4.addEventListener('keydown', enforceFormat);
      number_8_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_9_day4) {
      number_9_day4.addEventListener('keydown', enforceFormat);
      number_9_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_0_day4) {
      number_0_day4.addEventListener('keydown', enforceFormat);
      number_0_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_1_day4) {
      number_1_day4.addEventListener('keydown', enforceFormat);
      number_1_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_2_day4) {
      number_2_day4.addEventListener('keydown', enforceFormat);
      number_2_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_3_day4) {
      number_3_day4.addEventListener('keydown', enforceFormat);
      number_3_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_4_day4) {
      number_4_day4.addEventListener('keydown', enforceFormat);
      number_4_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_5_day4) {
      number_5_day4.addEventListener('keydown', enforceFormat);
      number_5_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_6_day4) {
      number_6_day4.addEventListener('keydown', enforceFormat);
      number_6_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_7_day4) {
      number_7_day4.addEventListener('keydown', enforceFormat);
      number_7_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_8_day4) {
      number_8_day4.addEventListener('keydown', enforceFormat);
      number_8_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_9_day4) {
      number_9_day4.addEventListener('keydown', enforceFormat);
      number_9_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_0_day5) {
      number_0_day5.addEventListener('keydown', enforceFormat);
      number_0_day5.addEventListener('keyup', formatToPhone);
    }
    if (number_1_day5) {
      number_1_day5.addEventListener('keydown', enforceFormat);
      number_1_day5.addEventListener('keyup', formatToPhone);
    }
    if (number_2_day5) {
      number_2_day5.addEventListener('keydown', enforceFormat);
      number_2_day5.addEventListener('keyup', formatToPhone);
    }
    if (number_3_day5) {
      number_3_day5.addEventListener('keydown', enforceFormat);
      number_3_day5.addEventListener('keyup', formatToPhone);
    }
    if (number_4_day5) {
      number_4_day5.addEventListener('keydown', enforceFormat);
      number_4_day5.addEventListener('keyup', formatToPhone);
    }
    if (number_5_day5) {
      number_5_day5.addEventListener('keydown', enforceFormat);
      number_5_day5.addEventListener('keyup', formatToPhone);
    }
    if (number_6_day5) {
      number_6_day5.addEventListener('keydown', enforceFormat);
      number_6_day5.addEventListener('keyup', formatToPhone);
    }
    if (number_7_day5) {
      number_7_day5.addEventListener('keydown', enforceFormat);
      number_7_day5.addEventListener('keyup', formatToPhone);
    }
    if (number_8_day5) {
      number_8_day5.addEventListener('keydown', enforceFormat);
      number_8_day5.addEventListener('keyup', formatToPhone);
    }
    if (number_9_day5) {
      number_9_day5.addEventListener('keydown', enforceFormat);
      number_9_day5.addEventListener('keyup', formatToPhone);
    }
    if (number_0_day6) {
      number_0_day6.addEventListener('keydown', enforceFormat);
      number_0_day6.addEventListener('keyup', formatToPhone);
    }
    if (number_1_day6) {
      number_1_day6.addEventListener('keydown', enforceFormat);
      number_1_day6.addEventListener('keyup', formatToPhone);
    }
    if (number_2_day6) {
      number_2_day6.addEventListener('keydown', enforceFormat);
      number_2_day6.addEventListener('keyup', formatToPhone);
    }
    if (number_3_day6) {
      number_3_day6.addEventListener('keydown', enforceFormat);
      number_3_day6.addEventListener('keyup', formatToPhone);
    }
    if (number_4_day6) {
      number_4_day6.addEventListener('keydown', enforceFormat);
      number_4_day6.addEventListener('keyup', formatToPhone);
    }
    if (number_5_day6) {
      number_5_day6.addEventListener('keydown', enforceFormat);
      number_5_day6.addEventListener('keyup', formatToPhone);
    }
    if (number_6_day6) {
      number_6_day6.addEventListener('keydown', enforceFormat);
      number_6_day6.addEventListener('keyup', formatToPhone);
    }
    if (number_7_day6) {
      number_7_day6.addEventListener('keydown', enforceFormat);
      number_7_day6.addEventListener('keyup', formatToPhone);
    }
    if (number_8_day6) {
      number_8_day6.addEventListener('keydown', enforceFormat);
      number_8_day6.addEventListener('keyup', formatToPhone);
    }
    if (number_9_day6) {
      number_9_day6.addEventListener('keydown', enforceFormat);
      number_9_day6.addEventListener('keyup', formatToPhone);
    }
    const editnumber_0_day0 = document.getElementById('editnumber_0_day0');
    const editnumber_1_day0 = document.getElementById('editnumber_1_day0');
    const editnumber_2_day0 = document.getElementById('editnumber_2_day0');
    const editnumber_3_day0 = document.getElementById('editnumber_3_day0');
    const editnumber_4_day0 = document.getElementById('editnumber_4_day0');
    const editnumber_5_day0 = document.getElementById('editnumber_5_day0');
    const editnumber_6_day0 = document.getElementById('editnumber_6_day0');
    const editnumber_7_day0 = document.getElementById('editnumber_7_day0');
    const editnumber_8_day0 = document.getElementById('editnumber_8_day0');
    const editnumber_9_day0 = document.getElementById('editnumber_9_day0');
    const editnumber_0_day1 = document.getElementById('editnumber_0_day1');
    const editnumber_1_day1 = document.getElementById('editnumber_1_day1');
    const editnumber_2_day1 = document.getElementById('editnumber_2_day1');
    const editnumber_3_day1 = document.getElementById('editnumber_3_day1');
    const editnumber_4_day1 = document.getElementById('editnumber_4_day1');
    const editnumber_5_day1 = document.getElementById('editnumber_5_day1');
    const editnumber_6_day1 = document.getElementById('editnumber_6_day1');
    const editnumber_7_day1 = document.getElementById('editnumber_7_day1');
    const editnumber_8_day1 = document.getElementById('editnumber_8_day1');
    const editnumber_9_day1 = document.getElementById('editnumber_9_day1');
    const editnumber_0_day2 = document.getElementById('editnumber_0_day2');
    const editnumber_1_day2 = document.getElementById('editnumber_1_day2');
    const editnumber_2_day2 = document.getElementById('editnumber_2_day2');
    const editnumber_3_day2 = document.getElementById('editnumber_3_day2');
    const editnumber_4_day2 = document.getElementById('editnumber_4_day2');
    const editnumber_5_day2 = document.getElementById('editnumber_5_day2');
    const editnumber_6_day2 = document.getElementById('editnumber_6_day2');
    const editnumber_7_day2 = document.getElementById('editnumber_7_day2');
    const editnumber_8_day2 = document.getElementById('editnumber_8_day2');
    const editnumber_9_day2 = document.getElementById('editnumber_9_day2');
    const editnumber_0_day3 = document.getElementById('editnumber_0_day3');
    const editnumber_1_day3 = document.getElementById('editnumber_1_day3');
    const editnumber_2_day3 = document.getElementById('editnumber_2_day3');
    const editnumber_3_day3 = document.getElementById('editnumber_3_day3');
    const editnumber_4_day3 = document.getElementById('editnumber_4_day3');
    const editnumber_5_day3 = document.getElementById('editnumber_5_day3');
    const editnumber_6_day3 = document.getElementById('editnumber_6_day3');
    const editnumber_7_day3 = document.getElementById('editnumber_7_day3');
    const editnumber_8_day3 = document.getElementById('editnumber_8_day3');
    const editnumber_9_day3 = document.getElementById('editnumber_9_day3');
    const editnumber_0_day4 = document.getElementById('editnumber_0_day4');
    const editnumber_1_day4 = document.getElementById('editnumber_1_day4');
    const editnumber_2_day4 = document.getElementById('editnumber_2_day4');
    const editnumber_3_day4 = document.getElementById('editnumber_3_day4');
    const editnumber_4_day4 = document.getElementById('editnumber_4_day4');
    const editnumber_5_day4 = document.getElementById('editnumber_5_day4');
    const editnumber_6_day4 = document.getElementById('editnumber_6_day4');
    const editnumber_7_day4 = document.getElementById('editnumber_7_day4');
    const editnumber_8_day4 = document.getElementById('editnumber_8_day4');
    const editnumber_9_day4 = document.getElementById('editnumber_9_day4');
    const editnumber_0_day5 = document.getElementById('editnumber_0_day5');
    const editnumber_1_day5 = document.getElementById('editnumber_1_day5');
    const editnumber_2_day5 = document.getElementById('editnumber_2_day5');
    const editnumber_3_day5 = document.getElementById('editnumber_3_day5');
    const editnumber_4_day5 = document.getElementById('editnumber_4_day5');
    const editnumber_5_day5 = document.getElementById('editnumber_5_day5');
    const editnumber_6_day5 = document.getElementById('editnumber_6_day5');
    const editnumber_7_day5 = document.getElementById('editnumber_7_day5');
    const editnumber_8_day5 = document.getElementById('editnumber_8_day5');
    const editnumber_9_day5 = document.getElementById('editnumber_9_day5');
    const editnumber_0_day6 = document.getElementById('editnumber_0_day6');
    const editnumber_1_day6 = document.getElementById('editnumber_1_day6');
    const editnumber_2_day6 = document.getElementById('editnumber_2_day6');
    const editnumber_3_day6 = document.getElementById('editnumber_3_day6');
    const editnumber_4_day6 = document.getElementById('editnumber_4_day6');
    const editnumber_5_day6 = document.getElementById('editnumber_5_day6');
    const editnumber_6_day6 = document.getElementById('editnumber_6_day6');
    const editnumber_7_day6 = document.getElementById('editnumber_7_day6');
    const editnumber_8_day6 = document.getElementById('editnumber_8_day6');
    const editnumber_9_day6 = document.getElementById('editnumber_9_day6');
    if (editnumber_0_day0) {
      editnumber_0_day0.addEventListener('keydown', enforceFormat);
      editnumber_0_day0.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_1_day0) {
      editnumber_1_day0.addEventListener('keydown', enforceFormat);
      editnumber_1_day0.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_2_day0) {
      editnumber_2_day0.addEventListener('keydown', enforceFormat);
      editnumber_2_day0.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_3_day0) {
      editnumber_3_day0.addEventListener('keydown', enforceFormat);
      editnumber_3_day0.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_4_day0) {
      editnumber_4_day0.addEventListener('keydown', enforceFormat);
      editnumber_4_day0.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_5_day0) {
      editnumber_5_day0.addEventListener('keydown', enforceFormat);
      editnumber_5_day0.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_6_day0) {
      editnumber_6_day0.addEventListener('keydown', enforceFormat);
      editnumber_6_day0.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_7_day0) {
      editnumber_7_day0.addEventListener('keydown', enforceFormat);
      editnumber_7_day0.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_8_day0) {
      editnumber_8_day0.addEventListener('keydown', enforceFormat);
      editnumber_8_day0.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_9_day0) {
      editnumber_9_day0.addEventListener('keydown', enforceFormat);
      editnumber_9_day0.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_0_day1) {
      editnumber_0_day1.addEventListener('keydown', enforceFormat);
      editnumber_0_day1.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_1_day1) {
      editnumber_1_day1.addEventListener('keydown', enforceFormat);
      editnumber_1_day1.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_2_day1) {
      editnumber_2_day1.addEventListener('keydown', enforceFormat);
      editnumber_2_day1.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_3_day1) {
      editnumber_3_day1.addEventListener('keydown', enforceFormat);
      editnumber_3_day1.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_4_day1) {
      editnumber_4_day1.addEventListener('keydown', enforceFormat);
      editnumber_4_day1.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_5_day1) {
      editnumber_5_day1.addEventListener('keydown', enforceFormat);
      editnumber_5_day1.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_6_day1) {
      editnumber_6_day1.addEventListener('keydown', enforceFormat);
      editnumber_6_day1.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_7_day1) {
      editnumber_7_day1.addEventListener('keydown', enforceFormat);
      editnumber_7_day1.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_8_day1) {
      editnumber_8_day1.addEventListener('keydown', enforceFormat);
      editnumber_8_day1.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_9_day1) {
      editnumber_9_day1.addEventListener('keydown', enforceFormat);
      editnumber_9_day1.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_0_day2) {
      editnumber_0_day2.addEventListener('keydown', enforceFormat);
      editnumber_0_day2.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_1_day2) {
      editnumber_1_day2.addEventListener('keydown', enforceFormat);
      editnumber_1_day2.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_2_day2) {
      editnumber_2_day2.addEventListener('keydown', enforceFormat);
      editnumber_2_day2.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_3_day2) {
      editnumber_3_day2.addEventListener('keydown', enforceFormat);
      editnumber_3_day2.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_4_day2) {
      editnumber_4_day2.addEventListener('keydown', enforceFormat);
      editnumber_4_day2.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_5_day2) {
      editnumber_5_day2.addEventListener('keydown', enforceFormat);
      editnumber_5_day2.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_6_day2) {
      editnumber_6_day2.addEventListener('keydown', enforceFormat);
      editnumber_6_day2.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_7_day2) {
      editnumber_7_day2.addEventListener('keydown', enforceFormat);
      editnumber_7_day2.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_8_day2) {
      editnumber_8_day2.addEventListener('keydown', enforceFormat);
      editnumber_8_day2.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_9_day2) {
      editnumber_9_day2.addEventListener('keydown', enforceFormat);
      editnumber_9_day2.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_0_day3) {
      editnumber_0_day3.addEventListener('keydown', enforceFormat);
      editnumber_0_day3.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_1_day3) {
      editnumber_1_day3.addEventListener('keydown', enforceFormat);
      editnumber_1_day3.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_2_day3) {
      editnumber_2_day3.addEventListener('keydown', enforceFormat);
      editnumber_2_day3.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_3_day3) {
      editnumber_3_day3.addEventListener('keydown', enforceFormat);
      editnumber_3_day3.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_4_day3) {
      editnumber_4_day3.addEventListener('keydown', enforceFormat);
      editnumber_4_day3.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_5_day3) {
      editnumber_5_day3.addEventListener('keydown', enforceFormat);
      editnumber_5_day3.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_6_day3) {
      editnumber_6_day3.addEventListener('keydown', enforceFormat);
      editnumber_6_day3.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_7_day3) {
      editnumber_7_day3.addEventListener('keydown', enforceFormat);
      editnumber_7_day3.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_8_day3) {
      editnumber_8_day3.addEventListener('keydown', enforceFormat);
      editnumber_8_day3.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_9_day3) {
      editnumber_9_day3.addEventListener('keydown', enforceFormat);
      editnumber_9_day3.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_0_day4) {
      editnumber_0_day4.addEventListener('keydown', enforceFormat);
      editnumber_0_day4.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_1_day4) {
      editnumber_1_day4.addEventListener('keydown', enforceFormat);
      editnumber_1_day4.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_2_day4) {
      editnumber_2_day4.addEventListener('keydown', enforceFormat);
      editnumber_2_day4.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_3_day4) {
      editnumber_3_day4.addEventListener('keydown', enforceFormat);
      editnumber_3_day4.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_4_day4) {
      editnumber_4_day4.addEventListener('keydown', enforceFormat);
      editnumber_4_day4.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_5_day4) {
      editnumber_5_day4.addEventListener('keydown', enforceFormat);
      editnumber_5_day4.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_6_day4) {
      editnumber_6_day4.addEventListener('keydown', enforceFormat);
      editnumber_6_day4.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_7_day4) {
      editnumber_7_day4.addEventListener('keydown', enforceFormat);
      editnumber_7_day4.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_8_day4) {
      editnumber_8_day4.addEventListener('keydown', enforceFormat);
      editnumber_8_day4.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_9_day4) {
      editnumber_9_day4.addEventListener('keydown', enforceFormat);
      editnumber_9_day4.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_0_day5) {
      editnumber_0_day5.addEventListener('keydown', enforceFormat);
      editnumber_0_day5.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_1_day5) {
      editnumber_1_day5.addEventListener('keydown', enforceFormat);
      editnumber_1_day5.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_2_day5) {
      editnumber_2_day5.addEventListener('keydown', enforceFormat);
      editnumber_2_day5.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_3_day5) {
      editnumber_3_day5.addEventListener('keydown', enforceFormat);
      editnumber_3_day5.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_4_day5) {
      editnumber_4_day5.addEventListener('keydown', enforceFormat);
      editnumber_4_day5.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_5_day5) {
      editnumber_5_day5.addEventListener('keydown', enforceFormat);
      editnumber_5_day5.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_6_day5) {
      editnumber_6_day5.addEventListener('keydown', enforceFormat);
      editnumber_6_day5.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_7_day5) {
      editnumber_7_day5.addEventListener('keydown', enforceFormat);
      editnumber_7_day5.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_8_day5) {
      editnumber_8_day5.addEventListener('keydown', enforceFormat);
      editnumber_8_day5.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_9_day5) {
      editnumber_9_day5.addEventListener('keydown', enforceFormat);
      editnumber_9_day5.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_0_day6) {
      editnumber_0_day6.addEventListener('keydown', enforceFormat);
      editnumber_0_day6.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_1_day6) {
      editnumber_1_day6.addEventListener('keydown', enforceFormat);
      editnumber_1_day6.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_2_day6) {
      editnumber_2_day6.addEventListener('keydown', enforceFormat);
      editnumber_2_day6.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_3_day6) {
      editnumber_3_day6.addEventListener('keydown', enforceFormat);
      editnumber_3_day6.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_4_day6) {
      editnumber_4_day6.addEventListener('keydown', enforceFormat);
      editnumber_4_day6.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_5_day6) {
      editnumber_5_day6.addEventListener('keydown', enforceFormat);
      editnumber_5_day6.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_6_day6) {
      editnumber_6_day6.addEventListener('keydown', enforceFormat);
      editnumber_6_day6.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_7_day6) {
      editnumber_7_day6.addEventListener('keydown', enforceFormat);
      editnumber_7_day6.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_8_day6) {
      editnumber_8_day6.addEventListener('keydown', enforceFormat);
      editnumber_8_day6.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_9_day6) {
      editnumber_9_day6.addEventListener('keydown', enforceFormat);
      editnumber_9_day6.addEventListener('keyup', formatToPhone);
    }
  }
  getAllRuleset() {
    this.moduleService.getRules(this.currentCompany.uuid).subscribe(res => {
      // console.log(res);
      this.allrules = res.rule_data;
    });
  }
  getIVRMenu() {
    this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleService.getIVRMenus(this.currentCompany.uuid).subscribe(res => {
      this.ivrmenus = res;
      // console.log(this.ivrmenus);
    }, error => this.error = error);
  }
  get rules() {
    return this.addFSLRules.controls;
  }
  onFSLSubmit() {
    this.FSLRulesSubmitted = true;
    // stop here if form is invalid
    if (this.addFSLRules.invalid) {
      return;
    }
    // console.log(this.addFSLRules.get('start_time_0').value._d);
    //  return false;
    this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    // console.log(this.addFSLRules.value); return false;
    this.moduleService.addFSLRules(this.addFSLRules.value, this.currentCompany.uuid).subscribe(res => {
      // console.log(res);
      // return false;
      // localStorage.setItem('FSLRulesInsertID', JSON.stringify(res.insertid));
      this.addFSL();
      if (res.status !== 'error') {
        this.toastrService.success('FSL Rules Added Successfully');
      } else {
        this.toastrService.error('Failed To Add');
      }
    }, error => this.error = error);
  }
  get editrules() {
    return this.editFSLRules.controls;
  }
  onFSLEditSubmit() {
    this.FSLRulesEditSubmitted = true;
    // stop here if form is invalid
    if (this.editFSLRules.invalid) {
      return;
    }
    this.editFSLRules.get('rulename').setValue(this.forwarding);
    // console.log(this.editFSLRules.value);
    // return false;
    this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    // console.log(this.currentUser.uuid); return false;
    this.moduleService.editFSLRules(this.editFSLRules.value, this.currentCompany.uuid).subscribe(res => {
      // console.log(res);
      // return false;
      // localStorage.setItem('FSLRulesInsertID', JSON.stringify(res.insertid));
      if (res.status !== 'error') {
        this.toastrService.success('FSL Rules Updated Successfully');
      } else {
        this.toastrService.error('Failed To Add');
      }
    }, error => this.error = error);
  }
  getRules() {
    // alert('ok');
    this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.FSLRulesInsertID = localStorage.getItem('FSLRulesInsertID');
    // console.log(this.FSLRulesInsertID);return false;
    this.moduleService.getRecentRules(this.FSLRulesInsertID, this.currentCompany.uuid).subscribe(res => {
      // console.log(res.noofforwardinglocation);
      this.rulesData = res;
    }, error => this.error = error);
  }
  get_jklrules(event) {
    this.jklrules = event.target.checked;
  }
  global_revenue_cap(event) {
    this.global_revenuecap = event.target.checked;
  }
  global_cap(event) {
    this.globalcap = event.target.checked;
  }
  monthly_cap(event) {
    this.monthlycap = event.target.checked;
  }
  daily_cap(event) {
    this.dailycap = event.target.checked;
  }
  hourly_cap(event) {
    this.hourlycap = event.target.checked;
  }
  ringtree_toggle(event) {
    this.ringtree = event.target.checked;
    // console.log(event.target.checked);
    if (event.target.checked == true) {
      this.ringtreetext = "Ring Tree";
    } else {
      this.ringtreetext = "Simple";
    }
  }
  methodtype(event) {
    this.methodtypeval = event.target.value;
  }
  hof_alwaysopen_toggle(event) {
    this.hof_alwaysopen = event.target.checked;
  }
  isadvanced_toggle(event) {
    if (event == true) {
      this.advanced = 'Advanced';
      this.isadvanced = 1;
    }
    if (event == false) {
      this.advanced = 'Basic';
      this.isadvanced = 0;
    }
  }
  is12or24_toggle(event) {
    // default
    let default_ampm = this.addForm.get('default_ampm').value == 0 ? "AM" : "PM";
    let default_ampm_close = this.addForm.get('default_ampm_close').value == 0 ? "AM" : "PM";
    let starttime = this.addForm.get('start_hrs').value + ':' + this.addForm.get('start_min').value + ' ' + default_ampm;
    let endtime = this.addForm.get('end_hrs').value + ':' + this.addForm.get('end_min').value + ' ' + default_ampm_close;
    // sunday
    let sunday_ampm = this.addForm.get('sunday_ampm').value == 0 ? "AM" : "PM";
    let sunday_ampm_close = this.addForm.get('sunday_ampm_close').value == 0 ? "AM" : "PM";
    let sun_starttime = this.addForm.get('start_hrs_sunday').value + ':' + this.addForm.get('start_min_sunday').value + ' ' + sunday_ampm;
    let sun_endtime = this.addForm.get('end_hrs_sunday').value + ':' + this.addForm.get('end_min_sunday').value + ' ' + sunday_ampm_close;
    // monday
    let monday_ampm = this.addForm.get('monday_ampm').value == 0 ? "AM" : "PM";
    let monday_ampm_close = this.addForm.get('monday_ampm_close').value == 0 ? "AM" : "PM";
    let mon_starttime = this.addForm.get('start_hrs_monday').value + ':' + this.addForm.get('start_min_monday').value + ' ' + monday_ampm;
    let mon_endtime = this.addForm.get('end_hrs_monday').value + ':' + this.addForm.get('end_min_monday').value + ' ' + monday_ampm_close;
    // tuesday
    let tuesday_ampm = this.addForm.get('tuesday_ampm').value == 0 ? "AM" : "PM";
    let tuesday_ampm_close = this.addForm.get('tuesday_ampm_close').value == 0 ? "AM" : "PM";
    let tue_starttime = this.addForm.get('start_hrs_tuesday').value + ':' + this.addForm.get('start_min_tuesday').value + ' ' + tuesday_ampm;
    let tue_endtime = this.addForm.get('end_hrs_tuesday').value + ':' + this.addForm.get('end_min_tuesday').value + ' ' + tuesday_ampm_close;
    // wednesday
    let wednesday_ampm = this.addForm.get('wednesday_ampm').value == 0 ? "AM" : "PM";
    let wednesday_ampm_close = this.addForm.get('wednesday_ampm_close').value == 0 ? "AM" : "PM";
    let wed_starttime = this.addForm.get('start_hrs_wednesday').value + ':' + this.addForm.get('start_min_wednesday').value + ' ' + wednesday_ampm;
    let wed_endtime = this.addForm.get('end_hrs_wednesday').value + ':' + this.addForm.get('end_min_wednesday').value + ' ' + wednesday_ampm_close;
    // thursday
    let thursday_ampm = this.addForm.get('thursday_ampm').value == 0 ? "AM" : "PM";
    let thursday_ampm_close = this.addForm.get('thursday_ampm_close').value == 0 ? "AM" : "PM";
    let thu_starttime = this.addForm.get('start_hrs_thursday').value + ':' + this.addForm.get('start_min_thursday').value + ' ' + thursday_ampm;
    let thu_endtime = this.addForm.get('end_hrs_thursday').value + ':' + this.addForm.get('end_min_thursday').value + ' ' + thursday_ampm_close;
    // friday
    let friday_ampm = this.addForm.get('friday_ampm').value == 0 ? "AM" : "PM";
    let friday_ampm_close = this.addForm.get('friday_ampm_close').value == 0 ? "AM" : "PM";
    let fri_starttime = this.addForm.get('start_hrs_friday').value + ':' + this.addForm.get('start_min_friday').value + ' ' + friday_ampm;
    let fri_endtime = this.addForm.get('end_hrs_friday').value + ':' + this.addForm.get('end_min_friday').value + ' ' + friday_ampm_close;
    // saturday
    let saturday_ampm = this.addForm.get('saturday_ampm').value == 0 ? "AM" : "PM";
    let saturday_ampm_close = this.addForm.get('saturday_ampm_close').value == 0 ? "AM" : "PM";
    let sat_starttime = this.addForm.get('start_hrs_saturday').value + ':' + this.addForm.get('start_min_saturday').value + ' ' + saturday_ampm;
    let sat_endtime = this.addForm.get('end_hrs_saturday').value + ':' + this.addForm.get('end_min_saturday').value + ' ' + saturday_ampm_close;
    if (event == false) {
      this.is12or24 = 0;
      this.starttime_default = moment__WEBPACK_IMPORTED_MODULE_3__(starttime, 'h:mm A').format('HH:mm A');
      this.endtime_default = moment__WEBPACK_IMPORTED_MODULE_3__(endtime, 'h:mm A').format('HH:mm A');
      this.starttime_sunday = moment__WEBPACK_IMPORTED_MODULE_3__(sun_starttime, 'h:mm A').format('HH:mm A');
      this.endtime_sunday = moment__WEBPACK_IMPORTED_MODULE_3__(sun_endtime, 'h:mm A').format('HH:mm A');
      this.starttime_monday = moment__WEBPACK_IMPORTED_MODULE_3__(mon_starttime, 'h:mm A').format('HH:mm A');
      this.endtime_monday = moment__WEBPACK_IMPORTED_MODULE_3__(mon_endtime, 'h:mm A').format('HH:mm A');
      this.starttime_tuesday = moment__WEBPACK_IMPORTED_MODULE_3__(tue_starttime, 'h:mm A').format('HH:mm A');
      this.endtime_tuesday = moment__WEBPACK_IMPORTED_MODULE_3__(tue_endtime, 'h:mm A').format('HH:mm A');
      this.starttime_wednesday = moment__WEBPACK_IMPORTED_MODULE_3__(wed_starttime, 'h:mm A').format('HH:mm A');
      this.endtime_wednesday = moment__WEBPACK_IMPORTED_MODULE_3__(wed_endtime, 'h:mm A').format('HH:mm A');
      this.starttime_thursday = moment__WEBPACK_IMPORTED_MODULE_3__(thu_starttime, 'h:mm A').format('HH:mm A');
      this.endtime_thursday = moment__WEBPACK_IMPORTED_MODULE_3__(thu_endtime, 'h:mm A').format('HH:mm A');
      this.starttime_friday = moment__WEBPACK_IMPORTED_MODULE_3__(fri_starttime, 'h:mm A').format('HH:mm A');
      this.endtime_friday = moment__WEBPACK_IMPORTED_MODULE_3__(fri_endtime, 'h:mm A').format('HH:mm A');
      this.starttime_saturday = moment__WEBPACK_IMPORTED_MODULE_3__(sat_starttime, 'h:mm A').format('HH:mm A');
      this.endtime_saturday = moment__WEBPACK_IMPORTED_MODULE_3__(sat_endtime, 'h:mm A').format('HH:mm A');
    }
    if (event == true) {
      this.is12or24 = 1;
      this.starttime_default = moment__WEBPACK_IMPORTED_MODULE_3__(starttime, 'hh:mm A').format('hh:mm A');
      this.endtime_default = moment__WEBPACK_IMPORTED_MODULE_3__(endtime, 'hh:mm A').format('hh:mm A');
      this.starttime_sunday = moment__WEBPACK_IMPORTED_MODULE_3__(sun_starttime, 'h:mm A').format('hh:mm A');
      this.endtime_sunday = moment__WEBPACK_IMPORTED_MODULE_3__(sun_endtime, 'h:mm A').format('hh:mm A');
      this.starttime_monday = moment__WEBPACK_IMPORTED_MODULE_3__(mon_starttime, 'h:mm A').format('hh:mm A');
      this.endtime_monday = moment__WEBPACK_IMPORTED_MODULE_3__(mon_endtime, 'h:mm A').format('hh:mm A');
      this.starttime_tuesday = moment__WEBPACK_IMPORTED_MODULE_3__(tue_starttime, 'h:mm A').format('hh:mm A');
      this.endtime_tuesday = moment__WEBPACK_IMPORTED_MODULE_3__(tue_endtime, 'h:mm A').format('hh:mm A');
      this.starttime_wednesday = moment__WEBPACK_IMPORTED_MODULE_3__(wed_starttime, 'h:mm A').format('hh:mm A');
      this.endtime_wednesday = moment__WEBPACK_IMPORTED_MODULE_3__(wed_endtime, 'h:mm A').format('hh:mm A');
      this.starttime_thursday = moment__WEBPACK_IMPORTED_MODULE_3__(thu_starttime, 'h:mm A').format('hh:mm A');
      this.endtime_thursday = moment__WEBPACK_IMPORTED_MODULE_3__(thu_endtime, 'h:mm A').format('hh:mm A');
      this.starttime_friday = moment__WEBPACK_IMPORTED_MODULE_3__(fri_starttime, 'h:mm A').format('hh:mm A');
      this.endtime_friday = moment__WEBPACK_IMPORTED_MODULE_3__(fri_endtime, 'h:mm A').format('hh:mm A');
      this.starttime_saturday = moment__WEBPACK_IMPORTED_MODULE_3__(sat_starttime, 'h:mm A').format('hh:mm A');
      this.endtime_saturday = moment__WEBPACK_IMPORTED_MODULE_3__(sat_endtime, 'h:mm A').format('hh:mm A');
    }
    this.addForm.get('start_hrs').setValue(this.starttime_default.substring(0, 2));
    this.addForm.get('start_min').setValue(this.starttime_default.substring(3, 5));
    this.addForm.get('end_hrs').setValue(this.endtime_default.substring(0, 2));
    this.addForm.get('end_min').setValue(this.endtime_default.substring(3, 5));
    this.addForm.get('start_hrs_sunday').setValue(this.starttime_sunday.substring(0, 2));
    this.addForm.get('start_min_sunday').setValue(this.starttime_sunday.substring(3, 5));
    this.addForm.get('end_hrs_sunday').setValue(this.endtime_sunday.substring(0, 2));
    this.addForm.get('end_min_sunday').setValue(this.endtime_sunday.substring(3, 5));
    this.addForm.get('start_hrs_monday').setValue(this.starttime_monday.substring(0, 2));
    this.addForm.get('start_min_monday').setValue(this.starttime_monday.substring(3, 5));
    this.addForm.get('end_hrs_monday').setValue(this.endtime_monday.substring(0, 2));
    this.addForm.get('end_min_monday').setValue(this.endtime_monday.substring(3, 5));
    this.addForm.get('start_hrs_tuesday').setValue(this.starttime_tuesday.substring(0, 2));
    this.addForm.get('start_min_tuesday').setValue(this.starttime_tuesday.substring(3, 5));
    this.addForm.get('end_hrs_tuesday').setValue(this.endtime_tuesday.substring(0, 2));
    this.addForm.get('end_min_tuesday').setValue(this.endtime_tuesday.substring(3, 5));
    this.addForm.get('start_hrs_wednesday').setValue(this.starttime_wednesday.substring(0, 2));
    this.addForm.get('start_min_wednesday').setValue(this.starttime_wednesday.substring(3, 5));
    this.addForm.get('end_hrs_wednesday').setValue(this.endtime_wednesday.substring(0, 2));
    this.addForm.get('end_min_wednesday').setValue(this.endtime_wednesday.substring(3, 5));
    this.addForm.get('start_hrs_thursday').setValue(this.starttime_thursday.substring(0, 2));
    this.addForm.get('start_min_thursday').setValue(this.starttime_thursday.substring(3, 5));
    this.addForm.get('end_hrs_thursday').setValue(this.endtime_thursday.substring(0, 2));
    this.addForm.get('end_min_thursday').setValue(this.endtime_thursday.substring(3, 5));
    this.addForm.get('start_hrs_friday').setValue(this.starttime_friday.substring(0, 2));
    this.addForm.get('start_min_friday').setValue(this.starttime_friday.substring(3, 5));
    this.addForm.get('end_hrs_friday').setValue(this.endtime_friday.substring(0, 2));
    this.addForm.get('end_min_friday').setValue(this.endtime_friday.substring(3, 5));
    this.addForm.get('start_hrs_saturday').setValue(this.starttime_saturday.substring(0, 2));
    this.addForm.get('start_min_saturday').setValue(this.starttime_saturday.substring(3, 5));
    this.addForm.get('end_hrs_saturday').setValue(this.endtime_saturday.substring(0, 2));
    this.addForm.get('end_min_saturday').setValue(this.endtime_saturday.substring(3, 5));
  }
  sunday_open(event) {
    if (event.target.checked == true) {
      this.sundayopen = 1;
    } else {
      this.sundayopen = 0;
    }
  }
  monday_open(event) {
    if (event.target.checked == true) {
      this.mondayopen = 1;
    } else {
      this.mondayopen = 0;
    }
  }
  tuesday_open(event) {
    if (event.target.checked == true) {
      this.tuesdayopen = 1;
    } else {
      this.tuesdayopen = 0;
    }
  }
  wednesday_open(event) {
    if (event.target.checked == true) {
      this.wednesdayopen = 1;
    } else {
      this.wednesdayopen = 0;
    }
  }
  thursday_open(event) {
    if (event.target.checked == true) {
      this.thursdayopen = 1;
    } else {
      this.thursdayopen = 0;
    }
  }
  friday_open(event) {
    if (event.target.checked == true) {
      this.fridayopen = 1;
    } else {
      this.fridayopen = 0;
    }
  }
  saturday_open(event) {
    if (event.target.checked == true) {
      this.saturdayopen = 1;
    } else {
      this.saturdayopen = 0;
    }
  }
  dtmf_auto_toggle(event) {
    this.dtmf_auto = event.target.checked;
  }
  dtmf_zipcode_enable_toggle(event) {
    this.dtmf_zipcode_enable = event.target.checked;
  }
  monthly_revenue_cap(event) {
    this.monthly_revenuecap = event.target.checked;
  }
  daily_revenue_cap(event) {
    this.daily_revenuecap = event.target.checked;
  }
  hourly_revenue_cap(event) {
    this.hourly_revenuecap = event.target.checked;
  }
  get_maxcon(event) {
    this.maxconcurrency = event.target.checked;
  }
  get_disableRecordings(event) {
    this.disableRecordings = event.target.checked;
  }
  get_hourlyconcurrency(event) {
    this.hourlyconcurrency = event.target.checked;
  }
  getTimeonehrs(event) {
    console.log(this.timeonehrs);
    this.timeonehrs = event.target.value;
    if (this.timetwohrs < this.timeonehrs) {
      this.getTimeerror();
    }
  }
  getTimeonemin(event) {
    this.timeonemin = event.target.value;
    if (this.timetwohrs == this.timeonehrs && this.timetwomin <= this.timeonemin) {
      this.getTimeerror();
    }
  }
  getTimetwohrs(event) {
    this.timetwohrs = event.target.value;
    if (this.timetwohrs < this.timeonehrs) {
      this.getTimeerror();
    }
  }
  getTimetwomin(event) {
    this.timetwomin = event.target.value;
    if (this.timetwohrs == this.timeonehrs && this.timetwomin <= this.timeonemin) {
      this.getTimeerror();
    }
  }
  getTimetwohrs1(event) {
    this.timeonehrs1 = event.target.value;
    if (this.timetwohrs1 < this.timeonehrs1) {
      this.getTimeerror();
    }
  }
  getTimetwomin1(event) {
    this.timeonemin1 = event.target.value;
    if (this.timetwohrs1 == this.timeonehrs1 && this.timetwomin <= this.timeonemin1) {
      this.getTimeerror();
    }
  }
  getTimetwohrs2(event) {
    this.timetwohrs1 = event.target.value;
    if (this.timetwohrs1 < this.timeonehrs1) {
      this.getTimeerror();
    }
  }
  getTimetwomin2(event) {
    this.timetwomin1 = event.target.value;
    if (this.timetwohrs1 == this.timeonehrs1 && this.timetwomin1 <= this.timeonemin1) {
      this.getTimeerror();
    }
  }
  getTimeerror() {
    sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Error!', 'Closing Time must be greater than Opening Time.');
  }
  validatename() {
    this.moduleService.validatename(this.addFSLRules.get('name').value).subscribe(res => {
      // console.log(res); return false;
      this.isName = res;
      if (this.isName.status == 'success') {
        this.isName = "success";
      } else {
        this.isName = "fail";
      }
      // console.log(this.isName); return false;
    }
    // }
    );
  }

  getFSLbyuuid(uuid) {
    // alert(uuid);
    // console.log(uuid);
    this.moduleService.getFSLbyuuid(uuid).subscribe(res => {
      this.forwarding = res.forwarding[0].name;
      this.forwardingtimeframe = res.forwarding[0].nooftimeframe;
      this.noofforwarding = res.forwarding[0].nooftimeframe;
      for (let index = 0; index < res.forwarding.length; index++) {
        var start = res.forwarding[index].start_time.split(':');
        var end = res.forwarding[index].end_time.split(':');
        var starthrs = 'start_hrs_' + index;
        var startmin = 'start_min_' + index;
        var endhrs = 'end_hrs_' + index;
        var endmin = 'end_min_' + index;
        // var endkey ='end_time_'+index;
        var daykey = 'day_' + index;
        // console.log(start[0]);
        this.editFSLRules.patchValue({
          [daykey]: res.forwarding[index].timeofday,
          // [startkey]: new Date(new Date().setHours(start[0], start[1])),
          [starthrs]: start[0],
          [startmin]: start[1],
          [endhrs]: end[0],
          [endmin]: end[1]
          // [endkey]: new Date(new Date().setHours(end[0], end[1])),
        });

        for (let j = 0; j < res.forwarding[index].locations.length; j++) {
          var inc = j + 1;
          // var forlocationkey ='noofforwardinglocation_'+inc;
          var PrimaryforwardType = 'PrimaryforwardType_' + j + '_day' + index;
          var number_value = 'number_' + j + '_day' + index;
          var ivr_value = 'ivrMenu_' + j + '_day' + index;
          var sip_value = 'sipAdd_' + j + '_day' + index;
          // this.flag =res.forwarding[index].locations[j].primary_forwarding_type;
          // console.log(res.forwarding[index].locations[j].primary_forwarding_type);
          if (res.forwarding[index].locations[j].primary_forwarding_type == 0) {
            this.setPrimaryforward(0, j, index);
            this.flag = 0;
          }
          if (res.forwarding[index].locations[j].primary_forwarding_type == 1) {
            this.setPrimaryforward(1, j, index);
            this.flag = 1;
          }
          if (res.forwarding[index].locations[j].primary_forwarding_type == 2) {
            this.flag = 2;
            this.setPrimaryforward(2, j, index);
          }
          if (res.forwarding[index].locations[j].primary_forwarding_number != '') {
            var number = res.forwarding[index].locations[j].primary_forwarding_number;
            var formatted = '(' + number.substr(0, 3) + ') ' + number.substr(3, 3) + '-' + number.substr(6, 4);
          } else {
            var formatted = "";
          }
          if (index == 0) {
            this.noofforwardinglocation_1 = res.forwarding[index].locations[j].noofforwardinglocation;
            // if(this.noofforwardinglocation_1!=1)  {
            // this.noofforwardinglocation_1++;
            // }
          }
          //  console.log(res.forwarding[index].locations[j].noofforwardinglocation);
          if (index == 1) {
            this.noofforwardinglocation_2 = res.forwarding[index].locations[j].noofforwardinglocation;
            // if(res.forwarding[index].locations[j].noofforwardinglocation!=1)  {
            //   this.noofforwardinglocation_2++;
            //   }
          }

          if (index == 2) {
            this.noofforwardinglocation_3 = res.forwarding[index].locations[j].noofforwardinglocation;
            // if(res.forwarding[index].locations[j].noofforwardinglocation!=1)  {
            //   this.noofforwardinglocation_3++;
            // }
          }

          if (index == 3) {
            this.noofforwardinglocation_4 = res.forwarding[index].locations[j].noofforwardinglocation;
            // if(res.forwarding[index].locations[j].noofforwardinglocation!=1)  {
            //   this.noofforwardinglocation_4++;
            // }
          }

          if (index == 4) {
            this.noofforwardinglocation_5 = res.forwarding[index].locations[j].noofforwardinglocation;
            // if(res.forwarding[index].locations[j].noofforwardinglocation!=1)  {
            //   this.noofforwardinglocation_5++;
            // }
          }

          if (index == 5) {
            this.noofforwardinglocation_6 = res.forwarding[index].locations[j].noofforwardinglocation;
          }
          if (index == 6) {
            this.noofforwardinglocation_7 = res.forwarding[index].locations[j].noofforwardinglocation;
          }
          // console.log(index);
          this.editFSLRules.patchValue({
            // [forlocationkey]: res.forwarding[index].locations[j].noofforwardinglocation,
            [PrimaryforwardType]: this.flag,
            [number_value]: formatted,
            [ivr_value]: res.forwarding[index].locations[j].primary_forwarding_ivr,
            [sip_value]: res.forwarding[index].locations[j].primary_forwarding_sip
          });
        }
      }
    }, error => this.error = error);
  }
  addFSL() {
    this.FSLRulesSubmitted = false;
    this.addFSLRules.reset();
  }
  getWeekbyuuid(uuid, start_day, end_day) {
    this.editWeekDaysForm.patchValue({
      'uuid': uuid,
      'start_day': start_day,
      'end_day': end_day
    });
  }
  loadallweekdays() {
    this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleService.loadallweekdays(this.currentCompany.uuid).subscribe(res => {
      //  console.log(res); return false;
      this.allweekdays = res.data;
    }, error => this.error = error);
  }
  isfilterselect() {
    this.isfilter = 1;
    this.addForm.get('isfilter').setValue(this.isfilter);
  }
  ispubfilterselect() {
    this.ispubfilter = 1;
    this.addForm.get('ispubfilter').setValue(this.ispubfilter);
  }
  isfilterclear() {
    this.isfilter = 0;
    this.addForm.get('citystatetype').setValue(1);
    this.addForm.get('citystate').setValue('');
    this.addForm.get('cityval').setValue('');
  }
  ispubfilterclear() {
    this.filterselected = [];
    this.ispubfilter = 0;
    this.addForm.get('ispubfilter').setValue(0);
    this.addForm.get('pubiscontains').setValue(0);
    this.addForm.get('pubvalue').setValue('');
  }
  ngOnInit() {
    this.setTitle('Add Target');
    // this.getAllLabels();
    // this.getIVRMenu();
    // this.getAllLabels();
    // this.getAllRuleset();
    this.settings = {
      enableSearchFilter: true,
      singleSelection: true,
      showCheckbox: false,
      text: "Select Buyer"
    };
    this.addkeyword = [0];
    // this.getIVRMenu();
    // this.getAllRules();
    // this.gettimezone();
    this.getalldata();
    // this.loadNumbers();
    this.loadallweekdays();
    // this.loadweekdays();
    this.dropdownSettings = {
      singleSelection: false,
      text: "Select Associated Label",
      selectAllText: 'Select All',
      unSelectAllText: 'UnSelect All',
      enableSearchFilter: true,
      classes: "myclass custom-class"
    };
    this.addWeekDaysForm = this.fb.group({
      start_day: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required],
      end_day: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required]
    });
    this.editWeekDaysForm = this.fb.group({
      uuid: ['', ''],
      start_day: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required],
      end_day: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required]
    });
    this.addFSLRules = this.fb.group({
      name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required],
      numberoftimeframe: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required],
      noofforwardinglocation_1: ['', ''],
      noofforwardinglocation_2: ['', ''],
      noofforwardinglocation_3: ['', ''],
      noofforwardinglocation_4: ['', ''],
      noofforwardinglocation_5: ['', ''],
      noofforwardinglocation_6: ['', ''],
      noofforwardinglocation_7: ['', ''],
      // Day 1
      day_0: ['', ''],
      start_hrs_0: ['', ''],
      start_min_0: ['', ''],
      end_hrs_0: ['', ''],
      end_min_0: ['', ''],
      PrimaryforwardType_0_day0: ['', ''],
      number_0_day0: ['', ''],
      ivrMenu_0_day0: ['', ''],
      sipAdd_0_day0: ['', ''],
      PrimaryforwardType_1_day0: ['', ''],
      number_1_day0: ['', ''],
      ivrMenu_1_day0: ['', ''],
      sipAdd_1_day0: ['', ''],
      PrimaryforwardType_2_day0: ['', ''],
      number_2_day0: ['', ''],
      ivrMenu_2_day0: ['', ''],
      sipAdd_2_day0: ['', ''],
      PrimaryforwardType_3_day0: ['', ''],
      number_3_day0: ['', ''],
      ivrMenu_3_day0: ['', ''],
      sipAdd_3_day0: ['', ''],
      PrimaryforwardType_4_day0: ['', ''],
      number_4_day0: ['', ''],
      ivrMenu_4_day0: ['', ''],
      sipAdd_4_day0: ['', ''],
      PrimaryforwardType_5_day0: ['', ''],
      number_5_day0: ['', ''],
      ivrMenu_5_day0: ['', ''],
      sipAdd_5_day0: ['', ''],
      PrimaryforwardType_6_day0: ['', ''],
      number_6_day0: ['', ''],
      ivrMenu_6_day0: ['', ''],
      sipAdd_6_day0: ['', ''],
      PrimaryforwardType_7_day0: ['', ''],
      number_7_day0: ['', ''],
      ivrMenu_7_day0: ['', ''],
      sipAdd_7_day0: ['', ''],
      PrimaryforwardType_8_day0: ['', ''],
      number_8_day0: ['', ''],
      ivrMenu_8_day0: ['', ''],
      sipAdd_8_day0: ['', ''],
      PrimaryforwardType_9_day0: ['', ''],
      number_9_day0: ['', ''],
      ivrMenu_9_day0: ['', ''],
      sipAdd_9_day0: ['', ''],
      // Day2
      day_1: ['', ''],
      start_hrs_1: ['', ''],
      start_min_1: ['', ''],
      end_hrs_1: ['', ''],
      end_min_1: ['', ''],
      PrimaryforwardType_0_day1: ['', ''],
      number_0_day1: ['', ''],
      ivrMenu_0_day1: ['', ''],
      sipAdd_0_day1: ['', ''],
      PrimaryforwardType_1_day1: ['', ''],
      number_1_day1: ['', ''],
      ivrMenu_1_day1: ['', ''],
      sipAdd_1_day1: ['', ''],
      PrimaryforwardType_2_day1: ['', ''],
      number_2_day1: ['', ''],
      ivrMenu_2_day1: ['', ''],
      sipAdd_2_day1: ['', ''],
      PrimaryforwardType_3_day1: ['', ''],
      number_3_day1: ['', ''],
      ivrMenu_3_day1: ['', ''],
      sipAdd_3_day1: ['', ''],
      PrimaryforwardType_4_day1: ['', ''],
      number_4_day1: ['', ''],
      ivrMenu_4_day1: ['', ''],
      sipAdd_4_day1: ['', ''],
      PrimaryforwardType_5_day1: ['', ''],
      number_5_day1: ['', ''],
      ivrMenu_5_day1: ['', ''],
      sipAdd_5_day1: ['', ''],
      PrimaryforwardType_6_day1: ['', ''],
      number_6_day1: ['', ''],
      ivrMenu_6_day1: ['', ''],
      sipAdd_6_day1: ['', ''],
      PrimaryforwardType_7_day1: ['', ''],
      number_7_day1: ['', ''],
      ivrMenu_7_day1: ['', ''],
      sipAdd_7_day1: ['', ''],
      PrimaryforwardType_8_day1: ['', ''],
      number_8_day1: ['', ''],
      ivrMenu_8_day1: ['', ''],
      sipAdd_8_day1: ['', ''],
      PrimaryforwardType_9_day1: ['', ''],
      number_9_day1: ['', ''],
      ivrMenu_9_day1: ['', ''],
      sipAdd_9_day1: ['', ''],
      // Day3
      day_2: ['', ''],
      start_hrs_2: ['', ''],
      start_min_2: ['', ''],
      end_hrs_2: ['', ''],
      end_min_2: ['', ''],
      PrimaryforwardType_0_day2: ['', ''],
      number_0_day2: ['', ''],
      ivrMenu_0_day2: ['', ''],
      sipAdd_0_day2: ['', ''],
      PrimaryforwardType_1_day2: ['', ''],
      number_1_day2: ['', ''],
      ivrMenu_1_day2: ['', ''],
      sipAdd_1_day2: ['', ''],
      PrimaryforwardType_2_day2: ['', ''],
      number_2_day2: ['', ''],
      ivrMenu_2_day2: ['', ''],
      sipAdd_2_day2: ['', ''],
      PrimaryforwardType_3_day2: ['', ''],
      number_3_day2: ['', ''],
      ivrMenu_3_day2: ['', ''],
      sipAdd_3_day2: ['', ''],
      PrimaryforwardType_4_day2: ['', ''],
      number_4_day2: ['', ''],
      ivrMenu_4_day2: ['', ''],
      sipAdd_4_day2: ['', ''],
      PrimaryforwardType_5_day2: ['', ''],
      number_5_day2: ['', ''],
      ivrMenu_5_day2: ['', ''],
      sipAdd_5_day2: ['', ''],
      PrimaryforwardType_6_day2: ['', ''],
      number_6_day2: ['', ''],
      ivrMenu_6_day2: ['', ''],
      sipAdd_6_day2: ['', ''],
      PrimaryforwardType_7_day2: ['', ''],
      number_7_day2: ['', ''],
      ivrMenu_7_day2: ['', ''],
      sipAdd_7_day2: ['', ''],
      PrimaryforwardType_8_day2: ['', ''],
      number_8_day2: ['', ''],
      ivrMenu_8_day2: ['', ''],
      sipAdd_8_day2: ['', ''],
      PrimaryforwardType_9_day2: ['', ''],
      number_9_day2: ['', ''],
      ivrMenu_9_day2: ['', ''],
      sipAdd_9_day2: ['', ''],
      // Day4
      day_3: ['', ''],
      start_hrs_3: ['', ''],
      start_min_3: ['', ''],
      end_hrs_3: ['', ''],
      end_min_3: ['', ''],
      PrimaryforwardType_0_day3: ['', ''],
      number_0_day3: ['', ''],
      ivrMenu_0_day3: ['', ''],
      sipAdd_0_day3: ['', ''],
      PrimaryforwardType_1_day3: ['', ''],
      number_1_day3: ['', ''],
      ivrMenu_1_day3: ['', ''],
      sipAdd_1_day3: ['', ''],
      PrimaryforwardType_2_day3: ['', ''],
      number_2_day3: ['', ''],
      ivrMenu_2_day3: ['', ''],
      sipAdd_2_day3: ['', ''],
      PrimaryforwardType_3_day3: ['', ''],
      number_3_day3: ['', ''],
      ivrMenu_3_day3: ['', ''],
      sipAdd_3_day3: ['', ''],
      PrimaryforwardType_4_day3: ['', ''],
      number_4_day3: ['', ''],
      ivrMenu_4_day3: ['', ''],
      sipAdd_4_day3: ['', ''],
      PrimaryforwardType_5_day3: ['', ''],
      number_5_day3: ['', ''],
      ivrMenu_5_day3: ['', ''],
      sipAdd_5_day3: ['', ''],
      PrimaryforwardType_6_day3: ['', ''],
      number_6_day3: ['', ''],
      ivrMenu_6_day3: ['', ''],
      sipAdd_6_day3: ['', ''],
      PrimaryforwardType_7_day3: ['', ''],
      number_7_day3: ['', ''],
      ivrMenu_7_day3: ['', ''],
      sipAdd_7_day3: ['', ''],
      PrimaryforwardType_8_day3: ['', ''],
      number_8_day3: ['', ''],
      ivrMenu_8_day3: ['', ''],
      sipAdd_8_day3: ['', ''],
      PrimaryforwardType_9_day3: ['', ''],
      number_9_day3: ['', ''],
      ivrMenu_9_day3: ['', ''],
      sipAdd_9_day3: ['', ''],
      // Day5
      day_4: ['', ''],
      start_hrs_4: ['', ''],
      start_min_4: ['', ''],
      end_hrs_4: ['', ''],
      end_min_4: ['', ''],
      PrimaryforwardType_0_day4: ['', ''],
      number_0_day4: ['', ''],
      ivrMenu_0_day4: ['', ''],
      sipAdd_0_day4: ['', ''],
      PrimaryforwardType_1_day4: ['', ''],
      number_1_day4: ['', ''],
      ivrMenu_1_day4: ['', ''],
      sipAdd_1_day4: ['', ''],
      PrimaryforwardType_2_day4: ['', ''],
      number_2_day4: ['', ''],
      ivrMenu_2_day4: ['', ''],
      sipAdd_2_day4: ['', ''],
      PrimaryforwardType_3_day4: ['', ''],
      number_3_day4: ['', ''],
      ivrMenu_3_day4: ['', ''],
      sipAdd_3_day4: ['', ''],
      PrimaryforwardType_4_day4: ['', ''],
      number_4_day4: ['', ''],
      ivrMenu_4_day4: ['', ''],
      sipAdd_4_day4: ['', ''],
      PrimaryforwardType_5_day4: ['', ''],
      number_5_day4: ['', ''],
      ivrMenu_5_day4: ['', ''],
      sipAdd_5_day4: ['', ''],
      PrimaryforwardType_6_day4: ['', ''],
      number_6_day4: ['', ''],
      ivrMenu_6_day4: ['', ''],
      sipAdd_6_day4: ['', ''],
      PrimaryforwardType_7_day4: ['', ''],
      number_7_day4: ['', ''],
      ivrMenu_7_day4: ['', ''],
      sipAdd_7_day4: ['', ''],
      PrimaryforwardType_8_day4: ['', ''],
      number_8_day4: ['', ''],
      ivrMenu_8_day4: ['', ''],
      sipAdd_8_day4: ['', ''],
      PrimaryforwardType_9_day4: ['', ''],
      number_9_day4: ['', ''],
      ivrMenu_9_day4: ['', ''],
      sipAdd_9_day4: ['', ''],
      // Day6
      day_5: ['', ''],
      start_hrs_5: ['', ''],
      start_min_5: ['', ''],
      end_hrs_5: ['', ''],
      end_min_5: ['', ''],
      PrimaryforwardType_0_day5: ['', ''],
      number_0_day5: ['', ''],
      ivrMenu_0_day5: ['', ''],
      sipAdd_0_day5: ['', ''],
      PrimaryforwardType_1_day5: ['', ''],
      number_1_day5: ['', ''],
      ivrMenu_1_day5: ['', ''],
      sipAdd_1_day5: ['', ''],
      PrimaryforwardType_2_day5: ['', ''],
      number_2_day5: ['', ''],
      ivrMenu_2_day5: ['', ''],
      sipAdd_2_day5: ['', ''],
      PrimaryforwardType_3_day5: ['', ''],
      number_3_day5: ['', ''],
      ivrMenu_3_day5: ['', ''],
      sipAdd_3_day5: ['', ''],
      PrimaryforwardType_4_day5: ['', ''],
      number_4_day5: ['', ''],
      ivrMenu_4_day5: ['', ''],
      sipAdd_4_day5: ['', ''],
      PrimaryforwardType_5_day5: ['', ''],
      number_5_day5: ['', ''],
      ivrMenu_5_day5: ['', ''],
      sipAdd_5_day5: ['', ''],
      PrimaryforwardType_6_day5: ['', ''],
      number_6_day5: ['', ''],
      ivrMenu_6_day5: ['', ''],
      sipAdd_6_day5: ['', ''],
      PrimaryforwardType_7_day5: ['', ''],
      number_7_day5: ['', ''],
      ivrMenu_7_day5: ['', ''],
      sipAdd_7_day5: ['', ''],
      PrimaryforwardType_8_day5: ['', ''],
      number_8_day5: ['', ''],
      ivrMenu_8_day5: ['', ''],
      sipAdd_8_day5: ['', ''],
      PrimaryforwardType_9_day5: ['', ''],
      number_9_day5: ['', ''],
      ivrMenu_9_day5: ['', ''],
      sipAdd_9_day5: ['', ''],
      // Day7
      day_6: ['', ''],
      start_hrs_6: ['', ''],
      start_min_6: ['', ''],
      end_hrs_6: ['', ''],
      end_min_6: ['', ''],
      PrimaryforwardType_0_day6: ['', ''],
      number_0_day6: ['', ''],
      ivrMenu_0_day6: ['', ''],
      sipAdd_0_day6: ['', ''],
      PrimaryforwardType_1_day6: ['', ''],
      number_1_day6: ['', ''],
      ivrMenu_1_day6: ['', ''],
      sipAdd_1_day6: ['', ''],
      PrimaryforwardType_2_day6: ['', ''],
      number_2_day6: ['', ''],
      ivrMenu_2_day6: ['', ''],
      sipAdd_2_day6: ['', ''],
      PrimaryforwardType_3_day6: ['', ''],
      number_3_day6: ['', ''],
      ivrMenu_3_day6: ['', ''],
      sipAdd_3_day6: ['', ''],
      PrimaryforwardType_4_day6: ['', ''],
      number_4_day6: ['', ''],
      ivrMenu_4_day6: ['', ''],
      sipAdd_4_day6: ['', ''],
      PrimaryforwardType_5_day6: ['', ''],
      number_5_day6: ['', ''],
      ivrMenu_5_day6: ['', ''],
      sipAdd_5_day6: ['', ''],
      PrimaryforwardType_6_day6: ['', ''],
      number_6_day6: ['', ''],
      ivrMenu_6_day6: ['', ''],
      sipAdd_6_day6: ['', ''],
      PrimaryforwardType_7_day6: ['', ''],
      number_7_day6: ['', ''],
      ivrMenu_7_day6: ['', ''],
      sipAdd_7_day6: ['', ''],
      PrimaryforwardType_8_day6: ['', ''],
      number_8_day6: ['', ''],
      ivrMenu_8_day6: ['', ''],
      sipAdd_8_day6: ['', ''],
      PrimaryforwardType_9_day6: ['', ''],
      number_9_day6: ['', ''],
      ivrMenu_9_day6: ['', ''],
      sipAdd_9_day6: ['', '']
    });
    this.editFSLRules = this.fb.group({
      rulename: ['', ''],
      numberoftimeframe: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required],
      noofforwardinglocation_1: ['', ''],
      noofforwardinglocation_2: ['', ''],
      noofforwardinglocation_3: ['', ''],
      noofforwardinglocation_4: ['', ''],
      noofforwardinglocation_5: ['', ''],
      noofforwardinglocation_6: ['', ''],
      noofforwardinglocation_7: ['', ''],
      // Day 1
      day_0: ['', ''],
      start_hrs_0: ['', ''],
      start_min_0: ['', ''],
      end_hrs_0: ['', ''],
      end_min_0: ['', ''],
      PrimaryforwardType_0_day0: ['', ''],
      number_0_day0: ['', ''],
      ivrMenu_0_day0: ['', ''],
      sipAdd_0_day0: ['', ''],
      PrimaryforwardType_1_day0: ['', ''],
      number_1_day0: ['', ''],
      ivrMenu_1_day0: ['', ''],
      sipAdd_1_day0: ['', ''],
      PrimaryforwardType_2_day0: ['', ''],
      number_2_day0: ['', ''],
      ivrMenu_2_day0: ['', ''],
      sipAdd_2_day0: ['', ''],
      PrimaryforwardType_3_day0: ['', ''],
      number_3_day0: ['', ''],
      ivrMenu_3_day0: ['', ''],
      sipAdd_3_day0: ['', ''],
      PrimaryforwardType_4_day0: ['', ''],
      number_4_day0: ['', ''],
      ivrMenu_4_day0: ['', ''],
      sipAdd_4_day0: ['', ''],
      PrimaryforwardType_5_day0: ['', ''],
      number_5_day0: ['', ''],
      ivrMenu_5_day0: ['', ''],
      sipAdd_5_day0: ['', ''],
      PrimaryforwardType_6_day0: ['', ''],
      number_6_day0: ['', ''],
      ivrMenu_6_day0: ['', ''],
      sipAdd_6_day0: ['', ''],
      PrimaryforwardType_7_day0: ['', ''],
      number_7_day0: ['', ''],
      ivrMenu_7_day0: ['', ''],
      sipAdd_7_day0: ['', ''],
      PrimaryforwardType_8_day0: ['', ''],
      number_8_day0: ['', ''],
      ivrMenu_8_day0: ['', ''],
      sipAdd_8_day0: ['', ''],
      PrimaryforwardType_9_day0: ['', ''],
      number_9_day0: ['', ''],
      ivrMenu_9_day0: ['', ''],
      sipAdd_9_day0: ['', ''],
      // Day2
      day_1: ['', ''],
      start_hrs_1: ['', ''],
      start_min_1: ['', ''],
      end_hrs_1: ['', ''],
      end_min_1: ['', ''],
      PrimaryforwardType_0_day1: ['', ''],
      number_0_day1: ['', ''],
      ivrMenu_0_day1: ['', ''],
      sipAdd_0_day1: ['', ''],
      PrimaryforwardType_1_day1: ['', ''],
      number_1_day1: ['', ''],
      ivrMenu_1_day1: ['', ''],
      sipAdd_1_day1: ['', ''],
      PrimaryforwardType_2_day1: ['', ''],
      number_2_day1: ['', ''],
      ivrMenu_2_day1: ['', ''],
      sipAdd_2_day1: ['', ''],
      PrimaryforwardType_3_day1: ['', ''],
      number_3_day1: ['', ''],
      ivrMenu_3_day1: ['', ''],
      sipAdd_3_day1: ['', ''],
      PrimaryforwardType_4_day1: ['', ''],
      number_4_day1: ['', ''],
      ivrMenu_4_day1: ['', ''],
      sipAdd_4_day1: ['', ''],
      PrimaryforwardType_5_day1: ['', ''],
      number_5_day1: ['', ''],
      ivrMenu_5_day1: ['', ''],
      sipAdd_5_day1: ['', ''],
      PrimaryforwardType_6_day1: ['', ''],
      number_6_day1: ['', ''],
      ivrMenu_6_day1: ['', ''],
      sipAdd_6_day1: ['', ''],
      PrimaryforwardType_7_day1: ['', ''],
      number_7_day1: ['', ''],
      ivrMenu_7_day1: ['', ''],
      sipAdd_7_day1: ['', ''],
      PrimaryforwardType_8_day1: ['', ''],
      number_8_day1: ['', ''],
      ivrMenu_8_day1: ['', ''],
      sipAdd_8_day1: ['', ''],
      PrimaryforwardType_9_day1: ['', ''],
      number_9_day1: ['', ''],
      ivrMenu_9_day1: ['', ''],
      sipAdd_9_day1: ['', ''],
      // Day3
      day_2: ['', ''],
      start_hrs_2: ['', ''],
      start_min_2: ['', ''],
      end_hrs_2: ['', ''],
      end_min_2: ['', ''],
      PrimaryforwardType_0_day2: ['', ''],
      number_0_day2: ['', ''],
      ivrMenu_0_day2: ['', ''],
      sipAdd_0_day2: ['', ''],
      PrimaryforwardType_1_day2: ['', ''],
      number_1_day2: ['', ''],
      ivrMenu_1_day2: ['', ''],
      sipAdd_1_day2: ['', ''],
      PrimaryforwardType_2_day2: ['', ''],
      number_2_day2: ['', ''],
      ivrMenu_2_day2: ['', ''],
      sipAdd_2_day2: ['', ''],
      PrimaryforwardType_3_day2: ['', ''],
      number_3_day2: ['', ''],
      ivrMenu_3_day2: ['', ''],
      sipAdd_3_day2: ['', ''],
      PrimaryforwardType_4_day2: ['', ''],
      number_4_day2: ['', ''],
      ivrMenu_4_day2: ['', ''],
      sipAdd_4_day2: ['', ''],
      PrimaryforwardType_5_day2: ['', ''],
      number_5_day2: ['', ''],
      ivrMenu_5_day2: ['', ''],
      sipAdd_5_day2: ['', ''],
      PrimaryforwardType_6_day2: ['', ''],
      number_6_day2: ['', ''],
      ivrMenu_6_day2: ['', ''],
      sipAdd_6_day2: ['', ''],
      PrimaryforwardType_7_day2: ['', ''],
      number_7_day2: ['', ''],
      ivrMenu_7_day2: ['', ''],
      sipAdd_7_day2: ['', ''],
      PrimaryforwardType_8_day2: ['', ''],
      number_8_day2: ['', ''],
      ivrMenu_8_day2: ['', ''],
      sipAdd_8_day2: ['', ''],
      PrimaryforwardType_9_day2: ['', ''],
      number_9_day2: ['', ''],
      ivrMenu_9_day2: ['', ''],
      sipAdd_9_day2: ['', ''],
      // Day4
      day_3: ['', ''],
      start_hrs_3: ['', ''],
      start_min_3: ['', ''],
      end_hrs_3: ['', ''],
      end_min_3: ['', ''],
      PrimaryforwardType_0_day3: ['', ''],
      number_0_day3: ['', ''],
      ivrMenu_0_day3: ['', ''],
      sipAdd_0_day3: ['', ''],
      PrimaryforwardType_1_day3: ['', ''],
      number_1_day3: ['', ''],
      ivrMenu_1_day3: ['', ''],
      sipAdd_1_day3: ['', ''],
      PrimaryforwardType_2_day3: ['', ''],
      number_2_day3: ['', ''],
      ivrMenu_2_day3: ['', ''],
      sipAdd_2_day3: ['', ''],
      PrimaryforwardType_3_day3: ['', ''],
      number_3_day3: ['', ''],
      ivrMenu_3_day3: ['', ''],
      sipAdd_3_day3: ['', ''],
      PrimaryforwardType_4_day3: ['', ''],
      number_4_day3: ['', ''],
      ivrMenu_4_day3: ['', ''],
      sipAdd_4_day3: ['', ''],
      PrimaryforwardType_5_day3: ['', ''],
      number_5_day3: ['', ''],
      ivrMenu_5_day3: ['', ''],
      sipAdd_5_day3: ['', ''],
      PrimaryforwardType_6_day3: ['', ''],
      number_6_day3: ['', ''],
      ivrMenu_6_day3: ['', ''],
      sipAdd_6_day3: ['', ''],
      PrimaryforwardType_7_day3: ['', ''],
      number_7_day3: ['', ''],
      ivrMenu_7_day3: ['', ''],
      sipAdd_7_day3: ['', ''],
      PrimaryforwardType_8_day3: ['', ''],
      number_8_day3: ['', ''],
      ivrMenu_8_day3: ['', ''],
      sipAdd_8_day3: ['', ''],
      PrimaryforwardType_9_day3: ['', ''],
      number_9_day3: ['', ''],
      ivrMenu_9_day3: ['', ''],
      sipAdd_9_day3: ['', ''],
      // Day5
      day_4: ['', ''],
      start_hrs_4: ['', ''],
      start_min_4: ['', ''],
      end_hrs_4: ['', ''],
      end_min_4: ['', ''],
      PrimaryforwardType_0_day4: ['', ''],
      number_0_day4: ['', ''],
      ivrMenu_0_day4: ['', ''],
      sipAdd_0_day4: ['', ''],
      PrimaryforwardType_1_day4: ['', ''],
      number_1_day4: ['', ''],
      ivrMenu_1_day4: ['', ''],
      sipAdd_1_day4: ['', ''],
      PrimaryforwardType_2_day4: ['', ''],
      number_2_day4: ['', ''],
      ivrMenu_2_day4: ['', ''],
      sipAdd_2_day4: ['', ''],
      PrimaryforwardType_3_day4: ['', ''],
      number_3_day4: ['', ''],
      ivrMenu_3_day4: ['', ''],
      sipAdd_3_day4: ['', ''],
      PrimaryforwardType_4_day4: ['', ''],
      number_4_day4: ['', ''],
      ivrMenu_4_day4: ['', ''],
      sipAdd_4_day4: ['', ''],
      PrimaryforwardType_5_day4: ['', ''],
      number_5_day4: ['', ''],
      ivrMenu_5_day4: ['', ''],
      sipAdd_5_day4: ['', ''],
      PrimaryforwardType_6_day4: ['', ''],
      number_6_day4: ['', ''],
      ivrMenu_6_day4: ['', ''],
      sipAdd_6_day4: ['', ''],
      PrimaryforwardType_7_day4: ['', ''],
      number_7_day4: ['', ''],
      ivrMenu_7_day4: ['', ''],
      sipAdd_7_day4: ['', ''],
      PrimaryforwardType_8_day4: ['', ''],
      number_8_day4: ['', ''],
      ivrMenu_8_day4: ['', ''],
      sipAdd_8_day4: ['', ''],
      PrimaryforwardType_9_day4: ['', ''],
      number_9_day4: ['', ''],
      ivrMenu_9_day4: ['', ''],
      sipAdd_9_day4: ['', ''],
      // Day6
      day_5: ['', ''],
      start_hrs_5: ['', ''],
      start_min_5: ['', ''],
      end_hrs_5: ['', ''],
      end_min_5: ['', ''],
      PrimaryforwardType_0_day5: ['', ''],
      number_0_day5: ['', ''],
      ivrMenu_0_day5: ['', ''],
      sipAdd_0_day5: ['', ''],
      PrimaryforwardType_1_day5: ['', ''],
      number_1_day5: ['', ''],
      ivrMenu_1_day5: ['', ''],
      sipAdd_1_day5: ['', ''],
      PrimaryforwardType_2_day5: ['', ''],
      number_2_day5: ['', ''],
      ivrMenu_2_day5: ['', ''],
      sipAdd_2_day5: ['', ''],
      PrimaryforwardType_3_day5: ['', ''],
      number_3_day5: ['', ''],
      ivrMenu_3_day5: ['', ''],
      sipAdd_3_day5: ['', ''],
      PrimaryforwardType_4_day5: ['', ''],
      number_4_day5: ['', ''],
      ivrMenu_4_day5: ['', ''],
      sipAdd_4_day5: ['', ''],
      PrimaryforwardType_5_day5: ['', ''],
      number_5_day5: ['', ''],
      ivrMenu_5_day5: ['', ''],
      sipAdd_5_day5: ['', ''],
      PrimaryforwardType_6_day5: ['', ''],
      number_6_day5: ['', ''],
      ivrMenu_6_day5: ['', ''],
      sipAdd_6_day5: ['', ''],
      PrimaryforwardType_7_day5: ['', ''],
      number_7_day5: ['', ''],
      ivrMenu_7_day5: ['', ''],
      sipAdd_7_day5: ['', ''],
      PrimaryforwardType_8_day5: ['', ''],
      number_8_day5: ['', ''],
      ivrMenu_8_day5: ['', ''],
      sipAdd_8_day5: ['', ''],
      PrimaryforwardType_9_day5: ['', ''],
      number_9_day5: ['', ''],
      ivrMenu_9_day5: ['', ''],
      sipAdd_9_day5: ['', ''],
      // Day7
      day_6: ['', ''],
      start_hrs_6: ['', ''],
      start_min_6: ['', ''],
      end_hrs_6: ['', ''],
      end_min_6: ['', ''],
      PrimaryforwardType_0_day6: ['', ''],
      number_0_day6: ['', ''],
      ivrMenu_0_day6: ['', ''],
      sipAdd_0_day6: ['', ''],
      PrimaryforwardType_1_day6: ['', ''],
      number_1_day6: ['', ''],
      ivrMenu_1_day6: ['', ''],
      sipAdd_1_day6: ['', ''],
      PrimaryforwardType_2_day6: ['', ''],
      number_2_day6: ['', ''],
      ivrMenu_2_day6: ['', ''],
      sipAdd_2_day6: ['', ''],
      PrimaryforwardType_3_day6: ['', ''],
      number_3_day6: ['', ''],
      ivrMenu_3_day6: ['', ''],
      sipAdd_3_day6: ['', ''],
      PrimaryforwardType_4_day6: ['', ''],
      number_4_day6: ['', ''],
      ivrMenu_4_day6: ['', ''],
      sipAdd_4_day6: ['', ''],
      PrimaryforwardType_5_day6: ['', ''],
      number_5_day6: ['', ''],
      ivrMenu_5_day6: ['', ''],
      sipAdd_5_day6: ['', ''],
      PrimaryforwardType_6_day6: ['', ''],
      number_6_day6: ['', ''],
      ivrMenu_6_day6: ['', ''],
      sipAdd_6_day6: ['', ''],
      PrimaryforwardType_7_day6: ['', ''],
      number_7_day6: ['', ''],
      ivrMenu_7_day6: ['', ''],
      sipAdd_7_day6: ['', ''],
      PrimaryforwardType_8_day6: ['', ''],
      number_8_day6: ['', ''],
      ivrMenu_8_day6: ['', ''],
      sipAdd_8_day6: ['', ''],
      PrimaryforwardType_9_day6: ['', ''],
      number_9_day6: ['', ''],
      ivrMenu_9_day6: ['', ''],
      sipAdd_9_day6: ['', '']
    });
    this.dropdownSettings = {
      singleSelection: false,
      text: "Select Associated Label",
      selectAllText: 'Select All',
      unSelectAllText: 'UnSelect All',
      enableSearchFilter: true,
      classes: "myclass custom-class"
    };
    this.citystatedropdownSettings = {
      singleSelection: false,
      text: "Select State",
      selectAllText: 'Select All',
      unSelectAllText: 'UnSelect All',
      enableSearchFilter: true,
      classes: "myclass custom-class"
    };
    this.citydropdownSettings = {
      singleSelection: false,
      text: "Select City",
      selectAllText: 'Select All',
      unSelectAllText: 'UnSelect All',
      enableSearchFilter: true,
      classes: "myclass custom-class"
    };
    this.ivrdropdownSettings = {
      singleSelection: true,
      text: "Select IVR Menu",
      selectAllText: 'Select All',
      unSelectAllText: 'UnSelect All',
      enableSearchFilter: true,
      classes: "myclass custom-class"
    };
    // if(localStorage.getItem('FSLRulesInsertID')){
    // this.getRules();
    // }
    // this.getAllLabels();
    this.addForm = this.fb.group({
      name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required],
      subid: [''],
      buyer: [''],
      settingToggleBlockCallsIfCapped: [''],
      settingToggleType: [''],
      number: [''],
      ivrMenu: [''],
      sip_address: [''],
      voice_mail: ['505050'],
      url: [''],
      http_method: [''],
      content_type: [''],
      body: [''],
      http_headers_name: [''],
      http_headers_value: [''],
      keyword0: [''],
      keyword1: [''],
      keyword2: [''],
      // sip_endpoint: [''],
      // sip_username: [''],
      // sip_password: [''],
      // connection_timeout: [''],
      // dialivroption: [''],
      // timezone: ['',Validators.required],
      hoursofoperation_start: ['Monday'],
      hoursofoperation_end: ['Sunday'],
      start_hrs: ['00'],
      start_min: ['01'],
      end_hrs: ['23'],
      end_min: ['59'],
      timezone: ['6'],
      default_ampm: ['0'],
      default_ampm_close: ['1'],
      start_hrs_sunday: ['00'],
      start_min_sunday: ['01'],
      end_hrs_sunday: ['23'],
      end_min_sunday: ['59'],
      sunday_ampm: ['0'],
      sunday_ampm_close: ['1'],
      start_hrs_monday: ['00'],
      start_min_monday: ['01'],
      end_hrs_monday: ['23'],
      end_min_monday: ['59'],
      monday_ampm: ['0'],
      monday_ampm_close: ['1'],
      start_hrs_tuesday: ['00'],
      start_min_tuesday: ['01'],
      end_hrs_tuesday: ['23'],
      end_min_tuesday: ['59'],
      tuesday_ampm: ['0'],
      tuesday_ampm_close: ['1'],
      start_hrs_wednesday: ['00'],
      start_min_wednesday: ['01'],
      end_hrs_wednesday: ['23'],
      end_min_wednesday: ['59'],
      wednesday_ampm: ['0'],
      wednesday_ampm_close: ['1'],
      start_hrs_thursday: ['00'],
      start_min_thursday: ['01'],
      end_hrs_thursday: ['23'],
      end_min_thursday: ['59'],
      thursday_ampm: ['0'],
      thursday_ampm_close: ['1'],
      start_hrs_friday: ['00'],
      start_min_friday: ['01'],
      end_hrs_friday: ['23'],
      end_min_friday: ['59'],
      friday_ampm: ['0'],
      friday_ampm_close: ['1'],
      start_hrs_saturday: ['00'],
      start_min_saturday: ['01'],
      end_hrs_saturday: ['23'],
      end_min_saturday: ['59'],
      saturday_ampm: ['0'],
      saturday_ampm_close: ['1'],
      // hoursofoperation_start_1: ['Monday'],
      // hoursofoperation_end_1: ['Sunday'],
      // start_hrs_1: ['0'],
      // start_min_1: ['1'],
      // end_hrs_1: ['23'],
      // end_min_1: ['59'],
      // timezone1: ['6'],
      capon: [''],
      global_revenuecapvalue: [''],
      monthly_revenuecapvalue: [''],
      daily_revenuecapvalue: [''],
      hourly_revenuecapvalue: [''],
      global_capvalue: [''],
      monthly_capvalue: [''],
      daily_capvalue: [''],
      hourly_capvalue: [''],
      dtmf_value: [''],
      dtmf_interval: [''],
      dtmf_percent: [''],
      maxconvalue: [''],
      restrictdup: [''],
      restrictafter: [''],
      days: [''],
      settingToggleDurationval: [''],
      settingToggleDuration: [''],
      hourlyconcurrencyvalue: [''],
      isfilter: [''],
      citystate: [''],
      cityval: [''],
      citystatetype: [''],
      iscontains: [''],
      ispubfilter: [''],
      pubvalue: [''],
      pubfiltertype: ['0'],
      pubiscontains: ['0']
    });
    this.addForm.patchValue({
      http_method: 0,
      content_type: 0,
      citystatetype: 1,
      iscontains: 0,
      citystate: "",
      restrictafter: 0,
      restrictdup: 2,
      capon: 0
    });
    this.addBuyerForm = this.fb.group({
      company: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required],
      email: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required],
      password: [''],
      sub_id: [''],
      allow_buyer_to_pause_target: [''],
      allow_buyer_to_set_target_concurrency: [''],
      allow_buyer_to_dispute_call_conversions: [''],
      limit_revenue: ['']
    });
    this.getcitystate(1, 1);
    this.getAllpublishers();
  }
  getalldata() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    const p1 = new Promise((res, rej) => {
      this.moduleService.getIVRMenus(this.currentCompany.uuid).subscribe(result => {
        res(result);
      }, error => this.error = error);
    });
    const p2 = new Promise((res, rej) => {
      this.moduleService.getallbuyers(this.currentCompany.uuid).subscribe(result => {
        res(result);
      }, error => this.error = error);
    });
    const p3 = new Promise((res, rej) => {
      this.moduleService.gettimezone().subscribe(result => {
        res(result);
      }, error => this.error = error);
    });
    const p4 = new Promise((res, rej) => {
      this.moduleService.getallzipcode(this.currentCompany.uuid, this.currentCompany.uuid).subscribe(result => {
        res(result);
      }, error => this.error = error);
    });
    const prm = [p1, p2, p3, p4];
    Promise.all(prm).then(results => {
      this.allBuyers = results[1];
      this.ivrmenus = results[0];
      this.alltimezone = results[2];
      this.allzipcode = results[3];
      // console.log(this.allzipcode);
    });
  }

  addRow(e) {
    this.addkeyword.push(e);
  }
  removeRow(e) {
    this.addkeyword.pop(e);
  }
  getdata() {
    this.moduleService.loadcity(this.addForm.get('citystate').value).subscribe(res => {
      //  console.log(res); return false;
      this.allcity = res;
    }, error => this.error = error);
  }
  getcitystate(type, datatype) {
    this.moduleService.loadcitystate(type, datatype).subscribe(res => {
      //  console.log(res); return false;
      this.allcitystate = res;
    }, error => this.error = error);
  }
  getAllpublishers() {
    let cc = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleService.getAllpublishers(cc.uuid).subscribe(res => {
      //  console.log(res); return false;
      this.allpublisher = res;
      this.allpublisherbkp = res;
    }, error => this.error = error);
  }
  getpubfiltertype(event) {
    console.log(event.target.value);
    let filterdata = [];
    if (event.target.value == 1) {
      this.allpublisherbkp.forEach(element => {
        let obj = {
          'id': element.id,
          'itemName': element.id,
          'text': element.itemName
        };
        filterdata.push(obj);
      });
    } else {
      this.allpublisherbkp.forEach(element => {
        let obj = {
          'id': element.id,
          'itemName': element.itemName,
          'text': element.itemName
        };
        filterdata.push(obj);
      });
    }
    this.allpublisher = filterdata;
  }
  addorrule() {
    // console.log(this.filterselected);
    let typeval = this.addForm.get('pubiscontains').value;
    let typetext;
    if (typeval == 0) {
      typetext = "Equals Single Value";
    } else if (typeval == 1) {
      typetext = "Does Not Equal Single Value";
    } else if (typeval == 2) {
      typetext = "Contains";
    } else if (typeval == 3) {
      typetext = "Does Not contain";
    } else if (typeval == 4) {
      typetext = "Begins With";
    } else {
      typetext = "Does Not Begin With";
    }
    let customObj = new filterarr();
    customObj.filteradvanced = typeval;
    customObj.filterlabel = typetext;
    customObj.filtertype = 1;
    if (this.addForm.get('pubfiltertype').value == 1) {
      customObj.containfiltertext = 'Publisher';
    }
    if (this.addForm.get('pubfiltertype').value == 2) {
      customObj.containfiltertext = 'Zipcode';
    }
    customObj.containfiltertype = this.addForm.get('pubfiltertype').value;
    let itemname;
    let itemuuid;
    if (typeval == 0 || typeval == 1) {
      if (this.addForm.get('pubvalue').value != undefined && this.addForm.get('pubvalue').value != '') {
        itemuuid = this.addForm.get('pubvalue').value[0]['id'];
        itemname = this.addForm.get('pubvalue').value[0]['itemName'];
      } else {
        itemname = "";
        itemuuid = "";
      }
    } else {
      itemname = this.addForm.get('pubvalue').value;
      itemuuid = "";
    }
    // console.log(this.addForm.get('pubvalue').value);
    // console.log(itemname); return
    if (itemname == "") return;
    customObj.uuid = itemuuid;
    customObj.name = itemname;
    customObj.isorand = 0;
    if (itemname != undefined) {
      this.filterselected.push(customObj);
    }
    // console.log(this.filterselected);
  }

  addandrule() {
    let typeval = this.addForm.get('pubiscontains').value;
    let typetext;
    if (typeval == 0) {
      typetext = "Equals Single Value";
    } else if (typeval == 1) {
      typetext = "Does Not Equal Single Value";
    } else if (typeval == 2) {
      typetext = "Contains";
    } else if (typeval == 3) {
      typetext = "Does Not contain";
    } else if (typeval == 4) {
      typetext = "Begins With";
    } else {
      typetext = "Does Not Begin With";
    }
    let customObj = new filterarr();
    customObj.filteradvanced = typeval;
    customObj.filterlabel = typetext;
    customObj.filtertype = 1;
    customObj.containfiltertext = 'Publisher';
    customObj.containfiltertype = this.addForm.get('pubfiltertype').value;
    let itemname;
    let itemuuid;
    if (typeval == 0 || typeval == 1) {
      if (this.addForm.get('pubvalue').value != undefined && this.addForm.get('pubvalue').value != '') {
        itemuuid = this.addForm.get('pubvalue').value[0]['id'];
        itemname = this.addForm.get('pubvalue').value[0]['itemName'];
      } else {
        itemname = "";
        itemuuid = "";
      }
    } else {
      itemname = this.addForm.get('pubvalue').value;
      itemuuid = "";
    }
    if (itemname == "") return;
    customObj.uuid = itemuuid;
    customObj.name = itemname;
    customObj.isorand = 1;
    if (itemname != undefined) {
      this.filterselected.push(customObj);
    }
  }
  clearfilter(index) {
    this.filterselected.splice(index, 1);
  }
  settingToggleType(val) {
    this.settingToggleTypeval = val;
    this.addForm.get('settingToggleType').setValue(val);
  }
  settingToggleDuration(val) {
    this.settingToggleDurationvalue = val;
    this.addForm.get('settingToggleDurationval').setValue(val);
  }
  convert24hrs(time) {
    return moment__WEBPACK_IMPORTED_MODULE_3__(time, 'h:mm A').format('HH:mm');
  }
  get f() {
    return this.addForm.controls;
  }
  onSubmit() {
    this.loader = true;
    const formData = new FormData();
    this.submitted = true;
    if (this.addForm.invalid) {
      return;
    }
    // console.log(this.addForm.get('pubfiltertype').value);
    // console.log(this.addForm.get('pubiscontains').value);
    // console.log(this.addForm.get('pubvalue').value);
    // return
    // if(this.timetwohrs<this.timeonehrs){
    //   this.getTimeerror()
    //   return;
    // }
    // if(this.timetwohrs==this.timeonehrs && this.timetwomin<=this.timeonemin){
    //   this.getTimeerror()
    //   return;
    // }
    // if(this.timetwohrs1<this.timeonehrs1){
    //   this.getTimeerror()
    //   return;
    // }
    // if(this.timetwohrs1==this.timeonehrs1 && this.timetwomin1<=this.timeonemin1){
    //   this.getTimeerror()
    //   return;
    // }
    this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('user_uuid', this.currentUser.uuid);
    formData.append('name', this.addForm.get('name').value);
    formData.append('subid', this.addForm.get('subid').value);
    formData.append('buyer', JSON.stringify(this.addForm.get('buyer').value));
    // console.log(this.addForm.get('buyer').value); return
    // formData.append('settingToggleBlockCallsIfCapped', this.addForm.get('settingToggleBlockCallsIfCapped').value);
    formData.append('settingToggleType', this.addForm.get('settingToggleType').value);
    if (this.settingToggleTypeval == 0) {
      formData.append('number', this.addForm.get('number').value);
    }
    if (this.settingToggleTypeval == 1) {
      formData.append('ivrMenu', JSON.stringify(this.addForm.get('ivrMenu').value));
    }
    if (this.settingToggleTypeval == 2) {
      formData.append('sip_address', this.addForm.get('sip_address').value);
    }
    if (this.settingToggleTypeval == 3) {
      formData.append('voice_mail', this.addForm.get('voice_mail').value);
    }
    // formData.append('connection_timeout', this.addForm.get('connection_timeout').value);
    // formData.append('disableRecordings', this.disableRecordings);
    // formData.append('dialivroption', this.addForm.get('dialivroption').value);
    // formData.append('timezone', this.addForm.get('timezone').value);
    formData.append('ringtree', this.ringtree);
    if (this.ringtree == 1) {
      formData.append('url', this.addForm.get('url').value);
      formData.append('http_method', this.addForm.get('http_method').value);
      formData.append('content_type', this.addForm.get('content_type').value);
      formData.append('body', this.addForm.get('body').value);
      formData.append('http_headers_name', this.addForm.get('http_headers_name').value);
      formData.append('http_headers_value', this.addForm.get('http_headers_value').value);
      formData.append('keywordlength', this.addkeyword.length);
      formData.append('keyword0', this.addForm.get('keyword0').value);
      formData.append('keyword1', this.addForm.get('keyword1').value);
      formData.append('keyword2', this.addForm.get('keyword2').value);
    }
    formData.append('start_day', this.addForm.get('hoursofoperation_start').value);
    formData.append('end_day', this.addForm.get('hoursofoperation_end').value);
    formData.append('timezone', this.timezoneval[0].id);
    // console.log(this.timezoneval[0].id);return
    // var starttime;
    // var endtime
    // if(this.is12or24==1){
    //   starttime =  this.convert24hrs(this.addForm.get('start_hrs').value+':'+this.addForm.get('start_min').value);
    //   endtime =  this.convert24hrs(this.addForm.get('end_hrs').value+':'+this.addForm.get('end_min').value);
    // }else{
    //   starttime =  this.convert24hrs(this.addForm.get('start_hrs').value+':'+this.addForm.get('start_min').value);
    //   endtime =  this.convert24hrs(this.addForm.get('end_hrs').value+':'+this.addForm.get('end_min').value);
    // }
    var starttime;
    var endtime;
    let default_ampm = this.addForm.get('default_ampm').value == 0 ? "AM" : "PM";
    let default_ampm_close = this.addForm.get('default_ampm_close').value == 0 ? "AM" : "PM";
    if (this.is12or24 == 1) {
      starttime = this.convert24hrs(this.addForm.get('start_hrs').value + ':' + this.addForm.get('start_min').value + ' ' + default_ampm);
      endtime = this.convert24hrs(this.addForm.get('end_hrs').value + ':' + this.addForm.get('end_min').value + ' ' + default_ampm_close);
    } else {
      starttime = this.convert24hrs(this.addForm.get('start_hrs').value + ':' + this.addForm.get('start_min').value);
      endtime = this.convert24hrs(this.addForm.get('end_hrs').value + ':' + this.addForm.get('end_min').value);
    }
    formData.append('start_time', starttime);
    formData.append('end_time', endtime);
    // formData.append('isadded', this.isadded);
    // console.log(this.isadvanced); return
    formData.append('hof_alwaysopen', this.hof_alwaysopen);
    formData.append('isadded', this.isadvanced);
    if (this.isadvanced == 1) {
      formData.append('day_0', 'Sunday');
      formData.append('day_1', 'Monday');
      formData.append('day_2', 'Tuesday');
      formData.append('day_3', 'Wednesday');
      formData.append('day_4', 'Thursday');
      formData.append('day_5', 'Friday');
      formData.append('day_6', 'Saturday');
      formData.append('open_0', this.sundayopen);
      formData.append('open_1', this.mondayopen);
      formData.append('open_2', this.tuesdayopen);
      formData.append('open_3', this.wednesdayopen);
      formData.append('open_4', this.thursdayopen);
      formData.append('open_5', this.fridayopen);
      formData.append('open_6', this.saturdayopen);
      // if(this.is12or24==1){
      //   formData.append('0_open_time',  this.convert24hrs(this.addForm.get('start_hrs_sunday').value+':'+this.addForm.get('start_min_sunday').value));
      //   formData.append('0_close_time',  this.convert24hrs(this.addForm.get('end_hrs_sunday').value+':'+this.addForm.get('end_min_sunday').value));
      //   formData.append('1_open_time',  this.convert24hrs(this.addForm.get('start_hrs_monday').value+':'+this.addForm.get('start_min_monday').value));
      //   formData.append('1_close_time',  this.convert24hrs(this.addForm.get('end_hrs_monday').value+':'+this.addForm.get('end_min_sunday').value));
      //   formData.append('2_open_time',  this.convert24hrs(this.addForm.get('start_hrs_tuesday').value+':'+this.addForm.get('start_min_tuesday').value));
      //   formData.append('2_close_time',  this.convert24hrs(this.addForm.get('end_hrs_tuesday').value+':'+this.addForm.get('end_min_tuesday').value));
      //   formData.append('3_open_time',  this.convert24hrs(this.addForm.get('start_hrs_wednesday').value+':'+this.addForm.get('start_min_wednesday').value));
      //   formData.append('3_close_time',  this.convert24hrs(this.addForm.get('end_hrs_wednesday').value+':'+this.addForm.get('end_min_wednesday').value));
      //   formData.append('4_open_time',  this.convert24hrs(this.addForm.get('start_hrs_thursday').value+':'+this.addForm.get('start_min_thursday').value));
      //   formData.append('4_close_time',  this.convert24hrs(this.addForm.get('end_hrs_thursday').value+':'+this.addForm.get('end_min_thursday').value));
      //   formData.append('5_open_time',  this.convert24hrs(this.addForm.get('start_hrs_friday').value+':'+this.addForm.get('start_min_friday').value));
      //   formData.append('5_close_time',  this.convert24hrs(this.addForm.get('end_hrs_friday').value+':'+this.addForm.get('end_min_friday').value));
      //   formData.append('6_open_time',  this.convert24hrs(this.addForm.get('start_hrs_saturday').value+':'+this.addForm.get('start_min_saturday').value));
      //   formData.append('6_close_time',  this.convert24hrs(this.addForm.get('end_hrs_saturday').value+':'+this.addForm.get('end_min_saturday').value));
      // }else{
      //   formData.append('0_open_time',  this.addForm.get('start_hrs_sunday').value+':'+this.addForm.get('start_min_sunday').value);
      //   formData.append('0_close_time',  this.addForm.get('end_hrs_sunday').value+':'+this.addForm.get('end_min_sunday').value);
      //   formData.append('1_open_time',  this.addForm.get('start_hrs_monday').value+':'+this.addForm.get('start_min_monday').value);
      //   formData.append('1_close_time',  this.addForm.get('end_hrs_monday').value+':'+this.addForm.get('end_min_sunday').value);
      //   formData.append('2_open_time',  this.addForm.get('start_hrs_tuesday').value+':'+this.addForm.get('start_min_tuesday').value);
      //   formData.append('2_close_time',  this.addForm.get('end_hrs_tuesday').value+':'+this.addForm.get('end_min_tuesday').value);
      //   formData.append('3_open_time',  this.addForm.get('start_hrs_wednesday').value+':'+this.addForm.get('start_min_wednesday').value);
      //   formData.append('3_close_time',  this.addForm.get('end_hrs_wednesday').value+':'+this.addForm.get('end_min_wednesday').value);
      //   formData.append('4_open_time',  this.addForm.get('start_hrs_thursday').value+':'+this.addForm.get('start_min_thursday').value);
      //   formData.append('4_close_time',  this.addForm.get('end_hrs_thursday').value+':'+this.addForm.get('end_min_thursday').value);
      //   formData.append('5_open_time',  this.addForm.get('start_hrs_friday').value+':'+this.addForm.get('start_min_friday').value);
      //   formData.append('5_close_time',  this.addForm.get('end_hrs_friday').value+':'+this.addForm.get('end_min_friday').value);
      //   formData.append('6_open_time',  this.addForm.get('start_hrs_saturday').value+':'+this.addForm.get('start_min_saturday').value);
      //   formData.append('6_close_time',  this.addForm.get('end_hrs_saturday').value+':'+this.addForm.get('end_min_saturday').value);
      // }
      //   formData.append('start_day_1', this.addForm.get('hoursofoperation_start_1').value);
      //   formData.append('end_day_1', this.addForm.get('hoursofoperation_end_1').value);
      //   var starttime_1 =  this.addForm.get('start_hrs_1').value+':'+this.addForm.get('start_min_1').value;
      //   var endtime_1 =  this.addForm.get('end_hrs_1').value+':'+this.addForm.get('end_min_1').value;
      //   formData.append('start_time_1',starttime_1);
      //   formData.append('end_time_1',endtime_1);
      //   formData.append('timezone1', this.addForm.get('timezone1').value);
      let sunday_ampm = this.addForm.get('sunday_ampm').value == 0 ? "AM" : "PM";
      let sunday_ampm_close = this.addForm.get('sunday_ampm_close').value == 0 ? "AM" : "PM";
      let monday_ampm = this.addForm.get('monday_ampm').value == 0 ? "AM" : "PM";
      let monday_ampm_close = this.addForm.get('monday_ampm_close').value == 0 ? "AM" : "PM";
      let tuesday_ampm = this.addForm.get('tuesday_ampm').value == 0 ? "AM" : "PM";
      let tuesday_ampm_close = this.addForm.get('tuesday_ampm_close').value == 0 ? "AM" : "PM";
      let wednesday_ampm = this.addForm.get('wednesday_ampm').value == 0 ? "AM" : "PM";
      let wednesday_ampm_close = this.addForm.get('wednesday_ampm_close').value == 0 ? "AM" : "PM";
      let thursday_ampm = this.addForm.get('thursday_ampm').value == 0 ? "AM" : "PM";
      let thursday_ampm_close = this.addForm.get('thursday_ampm_close').value == 0 ? "AM" : "PM";
      let friday_ampm = this.addForm.get('friday_ampm').value == 0 ? "AM" : "PM";
      let friday_ampm_close = this.addForm.get('friday_ampm_close').value == 0 ? "AM" : "PM";
      let saturday_ampm = this.addForm.get('saturday_ampm').value == 0 ? "AM" : "PM";
      let saturday_ampm_close = this.addForm.get('saturday_ampm_close').value == 0 ? "AM" : "PM";
      if (this.is12or24 == 1) {
        formData.append('0_open_time', this.convert24hrs(this.addForm.get('start_hrs_sunday').value + ':' + this.addForm.get('start_min_sunday').value + ' ' + sunday_ampm));
        formData.append('0_close_time', this.convert24hrs(this.addForm.get('end_hrs_sunday').value + ':' + this.addForm.get('end_min_sunday').value + ' ' + sunday_ampm_close));
        formData.append('1_open_time', this.convert24hrs(this.addForm.get('start_hrs_monday').value + ':' + this.addForm.get('start_min_monday').value + ' ' + monday_ampm));
        formData.append('1_close_time', this.convert24hrs(this.addForm.get('end_hrs_monday').value + ':' + this.addForm.get('end_min_monday').value + ' ' + monday_ampm_close));
        formData.append('2_open_time', this.convert24hrs(this.addForm.get('start_hrs_tuesday').value + ':' + this.addForm.get('start_min_tuesday').value + ' ' + tuesday_ampm));
        formData.append('2_close_time', this.convert24hrs(this.addForm.get('end_hrs_tuesday').value + ':' + this.addForm.get('end_min_tuesday').value + ' ' + tuesday_ampm_close));
        formData.append('3_open_time', this.convert24hrs(this.addForm.get('start_hrs_wednesday').value + ':' + this.addForm.get('start_min_wednesday').value + ' ' + wednesday_ampm));
        formData.append('3_close_time', this.convert24hrs(this.addForm.get('end_hrs_wednesday').value + ':' + this.addForm.get('end_min_wednesday').value + ' ' + wednesday_ampm_close));
        formData.append('4_open_time', this.convert24hrs(this.addForm.get('start_hrs_thursday').value + ':' + this.addForm.get('start_min_thursday').value + ' ' + thursday_ampm));
        formData.append('4_close_time', this.convert24hrs(this.addForm.get('end_hrs_thursday').value + ':' + this.addForm.get('end_min_thursday').value + ' ' + thursday_ampm_close));
        formData.append('5_open_time', this.convert24hrs(this.addForm.get('start_hrs_friday').value + ':' + this.addForm.get('start_min_friday').value + ' ' + friday_ampm));
        formData.append('5_close_time', this.convert24hrs(this.addForm.get('end_hrs_friday').value + ':' + this.addForm.get('end_min_friday').value + ' ' + friday_ampm_close));
        formData.append('6_open_time', this.convert24hrs(this.addForm.get('start_hrs_saturday').value + ':' + this.addForm.get('start_min_saturday').value + ' ' + saturday_ampm));
        formData.append('6_close_time', this.convert24hrs(this.addForm.get('end_hrs_saturday').value + ':' + this.addForm.get('end_min_saturday').value + ' ' + saturday_ampm_close));
      } else {
        formData.append('0_open_time', this.addForm.get('start_hrs_sunday').value + ':' + this.addForm.get('start_min_sunday').value);
        formData.append('0_close_time', this.addForm.get('end_hrs_sunday').value + ':' + this.addForm.get('end_min_sunday').value);
        formData.append('1_open_time', this.addForm.get('start_hrs_monday').value + ':' + this.addForm.get('start_min_monday').value);
        formData.append('1_close_time', this.addForm.get('end_hrs_monday').value + ':' + this.addForm.get('end_min_monday').value);
        formData.append('2_open_time', this.addForm.get('start_hrs_tuesday').value + ':' + this.addForm.get('start_min_tuesday').value);
        formData.append('2_close_time', this.addForm.get('end_hrs_tuesday').value + ':' + this.addForm.get('end_min_tuesday').value);
        formData.append('3_open_time', this.addForm.get('start_hrs_wednesday').value + ':' + this.addForm.get('start_min_wednesday').value);
        formData.append('3_close_time', this.addForm.get('end_hrs_wednesday').value + ':' + this.addForm.get('end_min_wednesday').value);
        formData.append('4_open_time', this.addForm.get('start_hrs_thursday').value + ':' + this.addForm.get('start_min_thursday').value);
        formData.append('4_close_time', this.addForm.get('end_hrs_thursday').value + ':' + this.addForm.get('end_min_thursday').value);
        formData.append('5_open_time', this.addForm.get('start_hrs_friday').value + ':' + this.addForm.get('start_min_friday').value);
        formData.append('5_close_time', this.addForm.get('end_hrs_friday').value + ':' + this.addForm.get('end_min_friday').value);
        formData.append('6_open_time', this.addForm.get('start_hrs_saturday').value + ':' + this.addForm.get('start_min_saturday').value);
        formData.append('6_close_time', this.addForm.get('end_hrs_saturday').value + ':' + this.addForm.get('end_min_saturday').value);
      }
    }
    formData.append('capon', this.addForm.get('capon').value);
    formData.append('is_autodtmf', this.dtmf_auto);
    formData.append('dtmf_zipcode_enable', this.dtmf_zipcode_enable);
    formData.append('dtmf_value', this.addForm.get('dtmf_value').value);
    formData.append('dtmf_interval', this.addForm.get('dtmf_interval').value);
    formData.append('dtmf_percent', this.addForm.get('dtmf_percent').value);
    formData.append('global_revenuecaptoggle', this.global_revenuecap);
    formData.append('global_revenuecapvalue', this.addForm.get('global_revenuecapvalue').value);
    formData.append('monthly_revenuecaptoggle', this.monthly_revenuecap);
    formData.append('monthly_revenuecapvalue', this.addForm.get('monthly_revenuecapvalue').value);
    formData.append('daily_revenuecaptoggle', this.daily_revenuecap);
    formData.append('daily_revenuecapvalue', this.addForm.get('daily_revenuecapvalue').value);
    formData.append('hourly_revenuecaptoggle', this.hourly_revenuecap);
    formData.append('hourly_revenuecapvalue', this.addForm.get('hourly_revenuecapvalue').value);
    formData.append('global_cap', this.globalcap);
    formData.append('monthly_cap', this.monthlycap);
    formData.append('daily_cap', this.dailycap);
    formData.append('hourly_cap', this.hourlycap);
    formData.append('global_capvalue', this.addForm.get('global_capvalue').value);
    formData.append('monthly_capvalue', this.addForm.get('monthly_capvalue').value);
    formData.append('daily_capvalue', this.addForm.get('daily_capvalue').value);
    formData.append('hourly_capvalue', this.addForm.get('hourly_capvalue').value);
    formData.append('addcontoggle', this.maxconcurrency);
    formData.append('maxconvalue', this.addForm.get('maxconvalue').value);
    formData.append('restrictdup', this.addForm.get('restrictdup').value);
    formData.append('restrictafter', this.addForm.get('restrictafter').value);
    formData.append('settingToggleDurationval', this.settingToggleDurationvalue);
    formData.append('days', this.addForm.get('days').value);
    if (this.isfilter == 1) {
      formData.append('isfilter', this.addForm.get('isfilter').value);
      formData.append('citystatetype', this.addForm.get('citystatetype').value);
      formData.append('iscontains', this.addForm.get('iscontains').value);
      formData.append('citystate', JSON.stringify(this.addForm.get('citystate').value));
      formData.append('cityval', JSON.stringify(this.addForm.get('cityval').value));
    }
    formData.append('filterselected', JSON.stringify(this.filterselected));
    formData.append('is12or24', this.is12or24);
    const id = this.route.snapshot.paramMap.get('id');
    this.moduleService.addTarget(formData).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Target Added Successfully');
        this.isTargetName = false;
        this.loader = false;
        // localStorage.removeItem('FSLRulesInsertID');
        this.router.navigate(['/target']);
        // this.router.navigate(['/numbers']);
      } else {
        this.toastrService.error('Failed To Add');
      }
    }, error => this.error = error);
  }
  validateTargetname() {
    if (this.addForm.get('name').value != '') {
      this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
      this.moduleService.validateTargetName(this.addForm.get('name').value, this.currentCompany.uuid).subscribe(res => {
        // console.log(res); return false;
        this.isTargetName = res;
        if (this.isTargetName.status == 'success') {
          this.isTargetName = "success";
        } else {
          this.isTargetName = "fail";
        }
      });
    } else {
      this.isTargetName = "";
    }
  }
  //Add Buyer
  get buyercontrol() {
    return this.addBuyerForm.controls;
  }
  onBuyerSubmit() {
    const formData = new FormData();
    this.BuyerSubmitted = true;
    if (this.addBuyerForm.invalid) {
      return;
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('company', this.addBuyerForm.get('company').value);
    formData.append('email', this.addBuyerForm.get('email').value);
    formData.append('password', this.addBuyerForm.get('password').value);
    formData.append('sub_id', this.addBuyerForm.get('sub_id').value);
    formData.append('allow_buyer_to_pause_target', this.addBuyerForm.get('allow_buyer_to_pause_target').value);
    formData.append('allow_buyer_to_set_target_concurrency', this.addBuyerForm.get('allow_buyer_to_set_target_concurrency').value);
    formData.append('allow_buyer_to_dispute_call_conversions', this.addBuyerForm.get('allow_buyer_to_dispute_call_conversions').value);
    formData.append('limit_revenue', this.addBuyerForm.get('limit_revenue').value);
    // console.log(formData); return false;
    this.moduleService.addBuyer(formData).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Buyer Added Successfully');
        this.getallbuyers();
        this.BuyerSubmitted = false;
      } else {
        this.toastrService.error('Failed To Add Label');
      }
    }, error => this.error = error);
  }
  closeBuyerModal() {
    if (this.addBuyerForm.get('company').value) {
      $("#addBuyer").modal("hide");
      $(".custom-switch-input").prop('checked', false);
      this.BuyerSubmitted = false;
      setTimeout(() => {
        this.addBuyerForm.reset();
      }, 2000);
    }
  }
  selectFile(event) {
    // console.log(event.target.files);
    if (event) {
      let file = event.target.files.item(0);
      // console.log(file.name);
      this.filename = file.name;
      //  console.log(file.size);
      //  console.log(file.type);
      //File reader method
      let reader = new FileReader();
      reader.readAsText(file);
      reader.onload = e => {
        let csv = reader.result;
        let allTextLines = [];
        allTextLines = csv.split(/\r|\n|\r/);
        //Table Headings
        let headers = allTextLines[0].split(',');
        let data = headers;
        let tarr = [];
        for (let j = 0; j < headers.length; j++) {
          tarr.push(data[j]);
        }
        //Pusd headings to array variable
        this.lines.push(tarr);
        // Table Rows
        let tarrR = [];
        let arrl = allTextLines.length;
        let rows = [];
        for (let i = 1; i < arrl; i++) {
          rows.push(allTextLines[i].split(','));
        }
        for (let j = 0; j < arrl; j++) {
          tarrR.push(rows[j]);
        }
        //Push rows to array variable
        this.linesR.push(tarrR);
      };
    }
    this.selectedfile = this.linesR;
  }
  onZipSubmit() {
    this.closeZipModal();
    const formData = new FormData();
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    formData.append('target_uuid', "");
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('filename', this.filename);
    formData.append('file', JSON.stringify(this.selectedfile));
    this.moduleService.addZipcode(formData, this.currentCompany.uuid).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Zipcode Added Successfully');
        this.getallzipcode();
        this.BuyerSubmitted = false;
      } else {
        this.toastrService.error('Failed To Add Label');
      }
    }, error => this.error = error);
  }
  closeZipModal() {
    // $("#addZipcode").modal("hide");
  }
  setPrimaryforward(id, count, day) {
    // Day0
    if (count == 0 && day == 0) {
      this.selectedPrimaryForaward_0_day0 = id;
      this.selectedPrimaryCount_0_day0 = count;
      this.selected_0_day_0 = day;
    }
    if (count == 1 && day == 0) {
      this.selectedPrimaryForaward_1_day0 = id;
      this.selectedPrimaryCount_1_day0 = count;
      this.selected_1_day_0 = day;
    }
    if (count == 2 && day == 0) {
      this.selectedPrimaryForaward_2_day0 = id;
      this.selectedPrimaryCount_2_day0 = count;
      this.selected_2_day_0 = day;
    }
    if (count == 3 && day == 0) {
      this.selectedPrimaryForaward_3_day0 = id;
      this.selectedPrimaryCount_3_day0 = count;
      this.selected_3_day_0 = day;
    }
    if (count == 4 && day == 0) {
      this.selectedPrimaryForaward_4_day0 = id;
      this.selectedPrimaryCount_4_day0 = count;
      this.selected_4_day_0 = day;
    }
    if (count == 5 && day == 0) {
      this.selectedPrimaryForaward_5_day0 = id;
      this.selectedPrimaryCount_5_day0 = count;
      this.selected_5_day_0 = day;
    }
    if (count == 6 && day == 0) {
      this.selectedPrimaryForaward_6_day0 = id;
      this.selectedPrimaryCount_6_day0 = count;
      this.selected_6_day_0 = day;
    }
    if (count == 7 && day == 0) {
      this.selectedPrimaryForaward_7_day0 = id;
      this.selectedPrimaryCount_7_day0 = count;
      this.selected_7_day_0 = day;
    }
    if (count == 8 && day == 0) {
      this.selectedPrimaryForaward_8_day0 = id;
      this.selectedPrimaryCount_8_day0 = count;
      this.selected_8_day_0 = day;
    }
    if (count == 9 && day == 0) {
      this.selectedPrimaryForaward_9_day0 = id;
      this.selectedPrimaryCount_9_day0 = count;
      this.selected_9_day_0 = day;
    }
    // Day1
    if (count == 0 && day == 1) {
      this.selectedPrimaryForaward_0_day1 = id;
      this.selectedPrimaryCount_0_day1 = count;
      this.selected_0_day_1 = day;
    }
    if (count == 1 && day == 1) {
      this.selectedPrimaryForaward_1_day1 = id;
      this.selectedPrimaryCount_1_day1 = count;
      this.selected_1_day_1 = day;
    }
    if (count == 2 && day == 1) {
      this.selectedPrimaryForaward_2_day1 = id;
      this.selectedPrimaryCount_2_day1 = count;
      this.selected_2_day_1 = day;
    }
    if (count == 3 && day == 1) {
      this.selectedPrimaryForaward_3_day1 = id;
      this.selectedPrimaryCount_3_day1 = count;
      this.selected_3_day_1 = day;
    }
    if (count == 4 && day == 1) {
      this.selectedPrimaryForaward_4_day1 = id;
      this.selectedPrimaryCount_4_day1 = count;
      this.selected_4_day_1 = day;
    }
    if (count == 5 && day == 1) {
      this.selectedPrimaryForaward_5_day1 = id;
      this.selectedPrimaryCount_5_day1 = count;
      this.selected_5_day_1 = day;
    }
    if (count == 6 && day == 1) {
      this.selectedPrimaryForaward_6_day1 = id;
      this.selectedPrimaryCount_6_day1 = count;
      this.selected_6_day_1 = day;
    }
    if (count == 7 && day == 1) {
      this.selectedPrimaryForaward_7_day1 = id;
      this.selectedPrimaryCount_7_day1 = count;
      this.selected_7_day_1 = day;
    }
    if (count == 8 && day == 1) {
      this.selectedPrimaryForaward_8_day1 = id;
      this.selectedPrimaryCount_8_day1 = count;
      this.selected_8_day_1 = day;
    }
    if (count == 9 && day == 1) {
      this.selectedPrimaryForaward_9_day1 = id;
      this.selectedPrimaryCount_9_day1 = count;
      this.selected_9_day_1 = day;
    }
    // Day2
    if (count == 0 && day == 2) {
      this.selectedPrimaryForaward_0_day2 = id;
      this.selectedPrimaryCount_0_day2 = count;
      this.selected_0_day_2 = day;
    }
    if (count == 1 && day == 2) {
      this.selectedPrimaryForaward_1_day2 = id;
      this.selectedPrimaryCount_1_day2 = count;
      this.selected_1_day_2 = day;
    }
    if (count == 2 && day == 2) {
      this.selectedPrimaryForaward_2_day2 = id;
      this.selectedPrimaryCount_2_day2 = count;
      this.selected_2_day_2 = day;
    }
    if (count == 3 && day == 2) {
      this.selectedPrimaryForaward_3_day2 = id;
      this.selectedPrimaryCount_3_day2 = count;
      this.selected_3_day_2 = day;
    }
    if (count == 4 && day == 2) {
      this.selectedPrimaryForaward_4_day2 = id;
      this.selectedPrimaryCount_4_day2 = count;
      this.selected_4_day_2 = day;
    }
    if (count == 5 && day == 2) {
      this.selectedPrimaryForaward_5_day2 = id;
      this.selectedPrimaryCount_5_day2 = count;
      this.selected_5_day_2 = day;
    }
    if (count == 6 && day == 2) {
      this.selectedPrimaryForaward_6_day2 = id;
      this.selectedPrimaryCount_6_day2 = count;
      this.selected_6_day_2 = day;
    }
    if (count == 7 && day == 2) {
      this.selectedPrimaryForaward_7_day2 = id;
      this.selectedPrimaryCount_7_day2 = count;
      this.selected_7_day_2 = day;
    }
    if (count == 8 && day == 2) {
      this.selectedPrimaryForaward_8_day2 = id;
      this.selectedPrimaryCount_8_day2 = count;
      this.selected_8_day_2 = day;
    }
    if (count == 9 && day == 2) {
      this.selectedPrimaryForaward_9_day2 = id;
      this.selectedPrimaryCount_9_day2 = count;
      this.selected_9_day_2 = day;
    }
    // Day3
    if (count == 0 && day == 3) {
      this.selectedPrimaryForaward_0_day3 = id;
      this.selectedPrimaryCount_0_day3 = count;
      this.selected_0_day_3 = day;
    }
    if (count == 1 && day == 3) {
      this.selectedPrimaryForaward_1_day3 = id;
      this.selectedPrimaryCount_1_day3 = count;
      this.selected_1_day_3 = day;
    }
    if (count == 2 && day == 3) {
      this.selectedPrimaryForaward_2_day3 = id;
      this.selectedPrimaryCount_2_day3 = count;
      this.selected_2_day_3 = day;
    }
    if (count == 3 && day == 3) {
      this.selectedPrimaryForaward_3_day3 = id;
      this.selectedPrimaryCount_3_day3 = count;
      this.selected_3_day_3 = day;
    }
    if (count == 4 && day == 3) {
      this.selectedPrimaryForaward_4_day3 = id;
      this.selectedPrimaryCount_4_day3 = count;
      this.selected_4_day_3 = day;
    }
    if (count == 5 && day == 3) {
      this.selectedPrimaryForaward_5_day3 = id;
      this.selectedPrimaryCount_5_day3 = count;
      this.selected_5_day_3 = day;
    }
    if (count == 6 && day == 3) {
      this.selectedPrimaryForaward_6_day3 = id;
      this.selectedPrimaryCount_6_day3 = count;
      this.selected_6_day_3 = day;
    }
    if (count == 7 && day == 3) {
      this.selectedPrimaryForaward_7_day3 = id;
      this.selectedPrimaryCount_7_day3 = count;
      this.selected_7_day_3 = day;
    }
    if (count == 8 && day == 3) {
      this.selectedPrimaryForaward_8_day3 = id;
      this.selectedPrimaryCount_8_day3 = count;
      this.selected_8_day_3 = day;
    }
    if (count == 9 && day == 3) {
      this.selectedPrimaryForaward_9_day3 = id;
      this.selectedPrimaryCount_9_day3 = count;
      this.selected_9_day_3 = day;
    }
    // Day4
    if (count == 0 && day == 4) {
      this.selectedPrimaryForaward_0_day4 = id;
      this.selectedPrimaryCount_0_day4 = count;
      this.selected_0_day_4 = day;
    }
    if (count == 1 && day == 4) {
      this.selectedPrimaryForaward_1_day4 = id;
      this.selectedPrimaryCount_1_day4 = count;
      this.selected_1_day_4 = day;
    }
    if (count == 2 && day == 4) {
      this.selectedPrimaryForaward_2_day4 = id;
      this.selectedPrimaryCount_2_day4 = count;
      this.selected_2_day_4 = day;
    }
    if (count == 3 && day == 4) {
      this.selectedPrimaryForaward_3_day4 = id;
      this.selectedPrimaryCount_3_day4 = count;
      this.selected_3_day_4 = day;
    }
    if (count == 4 && day == 4) {
      this.selectedPrimaryForaward_4_day4 = id;
      this.selectedPrimaryCount_4_day4 = count;
      this.selected_4_day_4 = day;
    }
    if (count == 5 && day == 4) {
      this.selectedPrimaryForaward_5_day4 = id;
      this.selectedPrimaryCount_5_day4 = count;
      this.selected_5_day_4 = day;
    }
    if (count == 6 && day == 4) {
      this.selectedPrimaryForaward_6_day4 = id;
      this.selectedPrimaryCount_6_day4 = count;
      this.selected_6_day_4 = day;
    }
    if (count == 7 && day == 4) {
      this.selectedPrimaryForaward_7_day4 = id;
      this.selectedPrimaryCount_7_day4 = count;
      this.selected_7_day_4 = day;
    }
    if (count == 8 && day == 4) {
      this.selectedPrimaryForaward_8_day4 = id;
      this.selectedPrimaryCount_8_day4 = count;
      this.selected_8_day_4 = day;
    }
    if (count == 9 && day == 4) {
      this.selectedPrimaryForaward_9_day4 = id;
      this.selectedPrimaryCount_9_day4 = count;
      this.selected_9_day_4 = day;
    }
  }
  isPrimarySelected(id, count, day) {
    // Day0
    if (count == 0 && day == 0) {
      if (this.selectedPrimaryForaward_0_day0 == id && this.selectedPrimaryCount_0_day0 === count && this.selected_0_day_0 == day) return true;else return false;
    }
    if (count == 1 && day == 0) {
      if (this.selectedPrimaryForaward_1_day0 == id && this.selectedPrimaryCount_1_day0 === count && this.selected_1_day_0 == day) return true;else return false;
    }
    if (count == 2 && day == 0) {
      if (this.selectedPrimaryForaward_2_day0 == id && this.selectedPrimaryCount_2_day0 === count && this.selected_2_day_0 == day) return true;else return false;
    }
    if (count == 3 && day == 0) {
      if (this.selectedPrimaryForaward_3_day0 == id && this.selectedPrimaryCount_3_day0 === count && this.selected_3_day_0 == day) return true;else return false;
    }
    if (count == 4 && day == 0) {
      if (this.selectedPrimaryForaward_4_day0 == id && this.selectedPrimaryCount_4_day0 === count && this.selected_4_day_0 == day) return true;else return false;
    }
    if (count == 5 && day == 0) {
      if (this.selectedPrimaryForaward_5_day0 == id && this.selectedPrimaryCount_5_day0 === count && this.selected_5_day_0 == day) return true;else return false;
    }
    if (count == 6 && day == 0) {
      if (this.selectedPrimaryForaward_6_day0 == id && this.selectedPrimaryCount_6_day0 === count && this.selected_6_day_0 == day) return true;else return false;
    }
    if (count == 7 && day == 0) {
      if (this.selectedPrimaryForaward_7_day0 == id && this.selectedPrimaryCount_7_day0 === count && this.selected_7_day_0 == day) return true;else return false;
    }
    if (count == 8 && day == 0) {
      if (this.selectedPrimaryForaward_8_day0 == id && this.selectedPrimaryCount_8_day0 === count && this.selected_8_day_0 == day) return true;else return false;
    }
    if (count == 9 && day == 0) {
      if (this.selectedPrimaryForaward_9_day0 == id && this.selectedPrimaryCount_9_day0 === count && this.selected_9_day_0 == day) return true;else return false;
    }
    // Day1
    if (count == 0 && day == 1) {
      if (this.selectedPrimaryForaward_0_day1 == id && this.selectedPrimaryCount_0_day1 === count && this.selected_0_day_1 == day) return true;else return false;
    }
    if (count == 1 && day == 1) {
      if (this.selectedPrimaryForaward_1_day1 == id && this.selectedPrimaryCount_1_day1 === count && this.selected_1_day_1 == day) return true;else return false;
    }
    if (count == 2 && day == 1) {
      if (this.selectedPrimaryForaward_2_day1 == id && this.selectedPrimaryCount_2_day1 === count && this.selected_2_day_1 == day) return true;else return false;
    }
    if (count == 3 && day == 1) {
      if (this.selectedPrimaryForaward_3_day1 == id && this.selectedPrimaryCount_3_day1 === count && this.selected_3_day_1 == day) return true;else return false;
    }
    if (count == 4 && day == 1) {
      if (this.selectedPrimaryForaward_4_day1 == id && this.selectedPrimaryCount_4_day1 === count && this.selected_4_day_1 == day) return true;else return false;
    }
    if (count == 5 && day == 1) {
      if (this.selectedPrimaryForaward_5_day1 == id && this.selectedPrimaryCount_5_day1 === count && this.selected_5_day_1 == day) return true;else return false;
    }
    if (count == 6 && day == 1) {
      if (this.selectedPrimaryForaward_6_day1 == id && this.selectedPrimaryCount_6_day1 === count && this.selected_6_day_1 == day) return true;else return false;
    }
    if (count == 7 && day == 1) {
      if (this.selectedPrimaryForaward_7_day1 == id && this.selectedPrimaryCount_7_day1 === count && this.selected_7_day_1 == day) return true;else return false;
    }
    if (count == 8 && day == 1) {
      if (this.selectedPrimaryForaward_8_day1 == id && this.selectedPrimaryCount_8_day1 === count && this.selected_8_day_1 == day) return true;else return false;
    }
    if (count == 9 && day == 1) {
      if (this.selectedPrimaryForaward_9_day1 == id && this.selectedPrimaryCount_9_day1 === count && this.selected_9_day_1 == day) return true;else return false;
    }
    // Day2
    if (count == 0 && day == 2) {
      if (this.selectedPrimaryForaward_0_day2 == id && this.selectedPrimaryCount_0_day2 === count && this.selected_0_day_2 == day) return true;else return false;
    }
    if (count == 1 && day == 2) {
      if (this.selectedPrimaryForaward_1_day2 == id && this.selectedPrimaryCount_1_day2 === count && this.selected_1_day_2 == day) return true;else return false;
    }
    if (count == 2 && day == 2) {
      if (this.selectedPrimaryForaward_2_day2 == id && this.selectedPrimaryCount_2_day2 === count && this.selected_2_day_2 == day) return true;else return false;
    }
    if (count == 3 && day == 2) {
      if (this.selectedPrimaryForaward_3_day2 == id && this.selectedPrimaryCount_3_day2 === count && this.selected_3_day_2 == day) return true;else return false;
    }
    if (count == 4 && day == 2) {
      if (this.selectedPrimaryForaward_4_day2 == id && this.selectedPrimaryCount_4_day2 === count && this.selected_4_day_2 == day) return true;else return false;
    }
    if (count == 5 && day == 2) {
      if (this.selectedPrimaryForaward_5_day2 == id && this.selectedPrimaryCount_5_day2 === count && this.selected_5_day_2 == day) return true;else return false;
    }
    if (count == 6 && day == 2) {
      if (this.selectedPrimaryForaward_6_day2 == id && this.selectedPrimaryCount_6_day2 === count && this.selected_6_day_2 == day) return true;else return false;
    }
    if (count == 7 && day == 2) {
      if (this.selectedPrimaryForaward_7_day2 == id && this.selectedPrimaryCount_7_day2 === count && this.selected_7_day_2 == day) return true;else return false;
    }
    if (count == 8 && day == 2) {
      if (this.selectedPrimaryForaward_8_day2 == id && this.selectedPrimaryCount_8_day2 === count && this.selected_8_day_2 == day) return true;else return false;
    }
    if (count == 9 && day == 2) {
      if (this.selectedPrimaryForaward_9_day2 == id && this.selectedPrimaryCount_9_day2 === count && this.selected_9_day_2 == day) return true;else return false;
    }
    // Day3
    if (count == 0 && day == 3) {
      if (this.selectedPrimaryForaward_0_day3 == id && this.selectedPrimaryCount_0_day3 === count && this.selected_0_day_3 == day) return true;else return false;
    }
    if (count == 1 && day == 3) {
      if (this.selectedPrimaryForaward_1_day3 == id && this.selectedPrimaryCount_1_day3 === count && this.selected_1_day_3 == day) return true;else return false;
    }
    if (count == 2 && day == 3) {
      if (this.selectedPrimaryForaward_2_day3 == id && this.selectedPrimaryCount_2_day3 === count && this.selected_2_day_3 == day) return true;else return false;
    }
    if (count == 3 && day == 3) {
      if (this.selectedPrimaryForaward_3_day3 == id && this.selectedPrimaryCount_3_day3 === count && this.selected_3_day_3 == day) return true;else return false;
    }
    if (count == 4 && day == 3) {
      if (this.selectedPrimaryForaward_4_day3 == id && this.selectedPrimaryCount_4_day3 === count && this.selected_4_day_3 == day) return true;else return false;
    }
    if (count == 5 && day == 3) {
      if (this.selectedPrimaryForaward_5_day3 == id && this.selectedPrimaryCount_5_day3 === count && this.selected_5_day_3 == day) return true;else return false;
    }
    if (count == 6 && day == 3) {
      if (this.selectedPrimaryForaward_6_day3 == id && this.selectedPrimaryCount_6_day3 === count && this.selected_6_day_3 == day) return true;else return false;
    }
    if (count == 7 && day == 3) {
      if (this.selectedPrimaryForaward_7_day3 == id && this.selectedPrimaryCount_7_day3 === count && this.selected_7_day_3 == day) return true;else return false;
    }
    if (count == 8 && day == 3) {
      if (this.selectedPrimaryForaward_8_day3 == id && this.selectedPrimaryCount_8_day3 === count && this.selected_8_day_3 == day) return true;else return false;
    }
    if (count == 9 && day == 3) {
      if (this.selectedPrimaryForaward_9_day3 == id && this.selectedPrimaryCount_9_day3 === count && this.selected_9_day_3 == day) return true;else return false;
    }
    // Day4
    if (count == 0 && day == 4) {
      if (this.selectedPrimaryForaward_0_day4 == id && this.selectedPrimaryCount_0_day4 === count && this.selected_0_day_4 == day) return true;else return false;
    }
    if (count == 1 && day == 4) {
      if (this.selectedPrimaryForaward_1_day4 == id && this.selectedPrimaryCount_1_day4 === count && this.selected_1_day_4 == day) return true;else return false;
    }
    if (count == 2 && day == 4) {
      if (this.selectedPrimaryForaward_2_day4 == id && this.selectedPrimaryCount_2_day4 === count && this.selected_2_day_4 == day) return true;else return false;
    }
    if (count == 3 && day == 4) {
      if (this.selectedPrimaryForaward_3_day4 == id && this.selectedPrimaryCount_3_day4 === count && this.selected_3_day_4 == day) return true;else return false;
    }
    if (count == 4 && day == 4) {
      if (this.selectedPrimaryForaward_4_day4 == id && this.selectedPrimaryCount_4_day4 === count && this.selected_4_day_4 == day) return true;else return false;
    }
    if (count == 5 && day == 4) {
      if (this.selectedPrimaryForaward_5_day4 == id && this.selectedPrimaryCount_5_day4 === count && this.selected_5_day_4 == day) return true;else return false;
    }
    if (count == 6 && day == 4) {
      if (this.selectedPrimaryForaward_6_day4 == id && this.selectedPrimaryCount_6_day4 === count && this.selected_6_day_4 == day) return true;else return false;
    }
    if (count == 7 && day == 4) {
      if (this.selectedPrimaryForaward_7_day4 == id && this.selectedPrimaryCount_7_day4 === count && this.selected_7_day_4 == day) return true;else return false;
    }
    if (count == 8 && day == 4) {
      if (this.selectedPrimaryForaward_8_day4 == id && this.selectedPrimaryCount_8_day4 === count && this.selected_8_day_4 == day) return true;else return false;
    }
    if (count == 9 && day == 4) {
      if (this.selectedPrimaryForaward_9_day4 == id && this.selectedPrimaryCount_9_day4 === count && this.selected_9_day_4 == day) return true;else return false;
    }
  }
  onReset() {
    this.submitted = false;
    this.addForm.reset();
  }
  selectednoofforwardinglocation() {
    let array = [];
    if (this.noofforwardinglocation_1 >= 10) {
      this.ite = 10;
    } else {
      this.ite = this.noofforwardinglocation_1;
    }
    for (let i = 0; i < this.ite; i++) {
      array.push(i);
    }
    return array;
  }
  selectednoofforwardinglocation_2() {
    let array = [];
    if (this.noofforwardinglocation_2 >= 10) {
      this.ite2 = 10;
    } else {
      this.ite2 = this.noofforwardinglocation_2;
    }
    for (let i = 0; i < this.ite2; i++) {
      array.push(i);
    }
    return array;
  }
  selectednoofforwardinglocation_3() {
    let array = [];
    if (this.noofforwardinglocation_3 >= 10) {
      this.ite3 = 10;
    } else {
      this.ite3 = this.noofforwardinglocation_3;
    }
    for (let i = 0; i < this.ite3; i++) {
      array.push(i);
    }
    return array;
  }
  selectednoofforwardinglocation_4() {
    let array = [];
    if (this.noofforwardinglocation_4 >= 10) {
      this.ite4 = 10;
    } else {
      this.ite4 = this.noofforwardinglocation_4;
    }
    for (let i = 0; i < this.ite4; i++) {
      array.push(i);
    }
    return array;
  }
  selectednoofforwardinglocation_5() {
    let array = [];
    if (this.noofforwardinglocation_5 >= 10) {
      this.ite5 = 10;
    } else {
      this.ite5 = this.noofforwardinglocation_5;
    }
    for (let i = 0; i < this.ite5; i++) {
      array.push(i);
    }
    return array;
  }
  selectednoofforwardinglocation_6() {
    let array = [];
    if (this.noofforwardinglocation_6 >= 10) {
      this.ite6 = 10;
    } else {
      this.ite6 = this.noofforwardinglocation_6;
    }
    for (let i = 0; i < this.ite6; i++) {
      array.push(i);
    }
    return array;
  }
  selectednoofforwardinglocation_7() {
    let array = [];
    if (this.noofforwardinglocation_7 >= 10) {
      this.ite7 = 10;
    } else {
      this.ite7 = this.noofforwardinglocation_7;
    }
    for (let i = 0; i < this.ite7; i++) {
      array.push(i);
    }
    return array;
  }
  onFSLReset() {
    this.FSLRulesSubmitted = false;
    this.addFSLRules.reset();
  }
  selected() {
    let array = [];
    for (let i = 0; i < this.noofforwarding; i++) {
      array.push(i);
    }
    return array;
  }
  Delete(id) {
    // alert(id)
    sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire({
      title: 'Are you sure?',
      text: 'You want to Delete Record!',
      showCancelButton: true,
      confirmButtonText: 'Yes, delete it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        this.moduleService.deleteFSLRulesbyname(id).subscribe(res => {
          this.getAllRules();
          sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Deleted!', 'FSL Deleted Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
          }, 2000);
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Cancelled', 'Your Record is safe :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
        }, 2000);
      }
    });
  }
  addremoverow(type) {
    if (type == 0) {
      this.isadded = 1;
    }
    if (type == 1) {
      this.isadded = 0;
    }
  }
  static #_ = this.ctorParameters = () => [{
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_5__.HttpBackend
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_6__.FormBuilder
  }, {
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_7__.Router
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_7__.ActivatedRoute
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_8__.ToastrService
  }, {
    type: _angular_core__WEBPACK_IMPORTED_MODULE_9__.ChangeDetectorRef
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_10__.Title
  }];
};
NumberaddComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_11__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_9__.Component)({
  selector: 'app-numberadd',
  template: _numberadd_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_numberadd_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], NumberaddComponent);


/***/ }),

/***/ 63092:
/*!*******************************************************************!*\
  !*** ./src/app/modules/number/numberedit/numberedit.component.ts ***!
  \*******************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "NumbereditComponent": () => (/* binding */ NumbereditComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _numberedit_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./numberedit.component.html?ngResource */ 16385);
/* harmony import */ var _numberedit_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./numberedit.component.scss?ngResource */ 76803);
/* harmony import */ var _numberedit_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_numberedit_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../../module.service */ 22947);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! moment */ 56908);
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(moment__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! sweetalert2 */ 60598);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(sweetalert2__WEBPACK_IMPORTED_MODULE_4__);
/* harmony import */ var ngx_ui_loader__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! ngx-ui-loader */ 36413);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! @angular/platform-browser */ 34497);













class filterarr {
  constructor() {
    this.filtertype = 1;
  }
}
let NumbereditComponent = class NumbereditComponent {
  constructor(fb, moduleService, router, route, toastrService, handler, cdRef, ngxLoader, titleService) {
    this.fb = fb;
    this.moduleService = moduleService;
    this.router = router;
    this.route = route;
    this.toastrService = toastrService;
    this.cdRef = cdRef;
    this.ngxLoader = ngxLoader;
    this.titleService = titleService;
    this.submitted = false;
    this.FSLRulesSubmitted = false;
    this.dropdownList = [];
    this.selectedItemsBuyer = [];
    this.allBuyers = [];
    this.FSLRulesEditSubmitted = false;
    this.daysSubmitted = false;
    this.daysEditSubmitted = false;
    this.is12or24 = 1;
    this.daytype = 0;
    this.flag = 0;
    this.alltimezone = [];
    // this.fslrule = 1;
    // this.getAllRules();
    // this.getAllLabels();
    // this.getAllRuleset();
    // this.loadallweekdays();
    this.allcitystate = [];
    this.allpublisher = [];
    this.allpublisherbkp = [];
    this.ivrdropdownSettings = {};
    this.addkeyword = [];
    this.settings = {};
    this.selectedItems = [];
    this.selectedItemsBuyer1 = [];
    this.selected_ivr = [];
    this.timezoneval = [];
    this.isfilter = 0;
    this.ispubfilter = 0;
    this.filterselected = [];
    this.allzipcode = [];
    this.selectedItemsZip = [];
    this.company = "";
    this.BuyerSubmitted = false;
    this.filename = ""; //for headings
    this.filetype = ""; //for headings
    this.lines = []; //for headings
    this.linesR = []; // for rows
    this.selectedfiledata = [];
    this.selectedfile = null;
    this.settingToggleTypeval = 0;
    this.settingToggleDurationvalue = 0;
    this.ringtree = false;
    this.ringtreetext = "Simple";
    this.methodtypeval = 0;
    this.hof_alwaysopen = false;
    this.isadvanced = 0;
    this.advanced = 'Advanced';
    this.sundayopen = 1;
    this.mondayopen = 1;
    this.tuesdayopen = 1;
    this.wednesdayopen = 1;
    this.thursdayopen = 1;
    this.fridayopen = 1;
    this.saturdayopen = 1;
    // Day0
    this.selectedPrimaryForaward_0_day0 = 0;
    this.selectedPrimaryCount_0_day0 = 0;
    this.selected_0_day_0 = 0;
    this.selectedPrimaryForaward_1_day0 = 0;
    this.selectedPrimaryCount_1_day0 = 0;
    this.selected_1_day_0 = 0;
    this.selectedPrimaryForaward_2_day0 = 0;
    this.selectedPrimaryCount_2_day0 = 0;
    this.selected_2_day_0 = 0;
    this.selectedPrimaryForaward_3_day0 = 0;
    this.selectedPrimaryCount_3_day0 = 0;
    this.selected_3_day_0 = 0;
    this.selectedPrimaryForaward_4_day0 = 0;
    this.selectedPrimaryCount_4_day0 = 0;
    this.selected_4_day_0 = 0;
    this.selectedPrimaryForaward_5_day0 = 0;
    this.selectedPrimaryCount_5_day0 = 0;
    this.selected_5_day_0 = 0;
    this.selectedPrimaryForaward_6_day0 = 0;
    this.selectedPrimaryCount_6_day0 = 0;
    this.selected_6_day_0 = 0;
    this.selectedPrimaryForaward_7_day0 = 0;
    this.selectedPrimaryCount_7_day0 = 0;
    this.selected_7_day_0 = 0;
    this.selectedPrimaryForaward_8_day0 = 0;
    this.selectedPrimaryCount_8_day0 = 0;
    this.selected_8_day_0 = 0;
    this.selectedPrimaryForaward_9_day0 = 0;
    this.selectedPrimaryCount_9_day0 = 0;
    this.selected_9_day_0 = 0;
    // Day1
    this.selectedPrimaryForaward_0_day1 = 0;
    this.selectedPrimaryCount_0_day1 = 0;
    this.selected_0_day_1 = 0;
    this.selectedPrimaryForaward_1_day1 = 0;
    this.selectedPrimaryCount_1_day1 = 0;
    this.selected_1_day_1 = 0;
    this.selectedPrimaryForaward_2_day1 = 0;
    this.selectedPrimaryCount_2_day1 = 0;
    this.selected_2_day_1 = 0;
    this.selectedPrimaryForaward_3_day1 = 0;
    this.selectedPrimaryCount_3_day1 = 0;
    this.selected_3_day_1 = 0;
    this.selectedPrimaryForaward_4_day1 = 0;
    this.selectedPrimaryCount_4_day1 = 0;
    this.selected_4_day_1 = 0;
    this.selectedPrimaryForaward_5_day1 = 0;
    this.selectedPrimaryCount_5_day1 = 0;
    this.selected_5_day_1 = 0;
    this.selectedPrimaryForaward_6_day1 = 0;
    this.selectedPrimaryCount_6_day1 = 0;
    this.selected_6_day_1 = 0;
    this.selectedPrimaryForaward_7_day1 = 0;
    this.selectedPrimaryCount_7_day1 = 0;
    this.selected_7_day_1 = 0;
    this.selectedPrimaryForaward_8_day1 = 0;
    this.selectedPrimaryCount_8_day1 = 0;
    this.selected_8_day_1 = 0;
    this.selectedPrimaryForaward_9_day1 = 0;
    this.selectedPrimaryCount_9_day1 = 0;
    this.selected_9_day_1 = 0;
    // Day2
    this.selectedPrimaryForaward_0_day2 = 0;
    this.selectedPrimaryCount_0_day2 = 0;
    this.selected_0_day_2 = 0;
    this.selectedPrimaryForaward_1_day2 = 0;
    this.selectedPrimaryCount_1_day2 = 0;
    this.selected_1_day_2 = 0;
    this.selectedPrimaryForaward_2_day2 = 0;
    this.selectedPrimaryCount_2_day2 = 0;
    this.selected_2_day_2 = 0;
    this.selectedPrimaryForaward_3_day2 = 0;
    this.selectedPrimaryCount_3_day2 = 0;
    this.selected_3_day_2 = 0;
    this.selectedPrimaryForaward_4_day2 = 0;
    this.selectedPrimaryCount_4_day2 = 0;
    this.selected_4_day_2 = 0;
    this.selectedPrimaryForaward_5_day2 = 0;
    this.selectedPrimaryCount_5_day2 = 0;
    this.selected_5_day_2 = 0;
    this.selectedPrimaryForaward_6_day2 = 0;
    this.selectedPrimaryCount_6_day2 = 0;
    this.selected_6_day_2 = 0;
    this.selectedPrimaryForaward_7_day2 = 0;
    this.selectedPrimaryCount_7_day2 = 0;
    this.selected_7_day_2 = 0;
    this.selectedPrimaryForaward_8_day2 = 0;
    this.selectedPrimaryCount_8_day2 = 0;
    this.selected_8_day_2 = 0;
    this.selectedPrimaryForaward_9_day2 = 0;
    this.selectedPrimaryCount_9_day2 = 0;
    this.selected_9_day_2 = 0;
    // Day3
    this.selectedPrimaryForaward_0_day3 = 0;
    this.selectedPrimaryCount_0_day3 = 0;
    this.selected_0_day_3 = 0;
    this.selectedPrimaryForaward_1_day3 = 0;
    this.selectedPrimaryCount_1_day3 = 0;
    this.selected_1_day_3 = 0;
    this.selectedPrimaryForaward_2_day3 = 0;
    this.selectedPrimaryCount_2_day3 = 0;
    this.selected_2_day_3 = 0;
    this.selectedPrimaryForaward_3_day3 = 0;
    this.selectedPrimaryCount_3_day3 = 0;
    this.selected_3_day_3 = 0;
    this.selectedPrimaryForaward_4_day3 = 0;
    this.selectedPrimaryCount_4_day3 = 0;
    this.selected_4_day_3 = 0;
    this.selectedPrimaryForaward_5_day3 = 0;
    this.selectedPrimaryCount_5_day3 = 0;
    this.selected_5_day_3 = 0;
    this.selectedPrimaryForaward_6_day3 = 0;
    this.selectedPrimaryCount_6_day3 = 0;
    this.selected_6_day_3 = 0;
    this.selectedPrimaryForaward_7_day3 = 0;
    this.selectedPrimaryCount_7_day3 = 0;
    this.selected_7_day_3 = 0;
    this.selectedPrimaryForaward_8_day3 = 0;
    this.selectedPrimaryCount_8_day3 = 0;
    this.selected_8_day_3 = 0;
    this.selectedPrimaryForaward_9_day3 = 0;
    this.selectedPrimaryCount_9_day3 = 0;
    this.selected_9_day_3 = 0;
    // Day4
    this.selectedPrimaryForaward_0_day4 = 0;
    this.selectedPrimaryCount_0_day4 = 0;
    this.selected_0_day_4 = 0;
    this.selectedPrimaryForaward_1_day4 = 0;
    this.selectedPrimaryCount_1_day4 = 0;
    this.selected_1_day_4 = 0;
    this.selectedPrimaryForaward_2_day4 = 0;
    this.selectedPrimaryCount_2_day4 = 0;
    this.selected_2_day_4 = 0;
    this.selectedPrimaryForaward_3_day4 = 0;
    this.selectedPrimaryCount_3_day4 = 0;
    this.selected_3_day_4 = 0;
    this.selectedPrimaryForaward_4_day4 = 0;
    this.selectedPrimaryCount_4_day4 = 0;
    this.selected_4_day_4 = 0;
    this.selectedPrimaryForaward_5_day4 = 0;
    this.selectedPrimaryCount_5_day4 = 0;
    this.selected_5_day_4 = 0;
    this.selectedPrimaryForaward_6_day4 = 0;
    this.selectedPrimaryCount_6_day4 = 0;
    this.selected_6_day_4 = 0;
    this.selectedPrimaryForaward_7_day4 = 0;
    this.selectedPrimaryCount_7_day4 = 0;
    this.selected_7_day_4 = 0;
    this.selectedPrimaryForaward_8_day4 = 0;
    this.selectedPrimaryCount_8_day4 = 0;
    this.selected_8_day_4 = 0;
    this.selectedPrimaryForaward_9_day4 = 0;
    this.selectedPrimaryCount_9_day4 = 0;
    this.selected_9_day_4 = 0;
    // Day5
    this.selectedPrimaryForaward_0_day5 = 0;
    this.selectedPrimaryCount_0_day5 = 0;
    this.selected_0_day_5 = 0;
    this.selectedPrimaryForaward_1_day5 = 0;
    this.selectedPrimaryCount_1_day5 = 0;
    this.selected_1_day_5 = 0;
    this.selectedPrimaryForaward_2_day5 = 0;
    this.selectedPrimaryCount_2_day5 = 0;
    this.selected_2_day_5 = 0;
    this.selectedPrimaryForaward_3_day5 = 0;
    this.selectedPrimaryCount_3_day5 = 0;
    this.selected_3_day_5 = 0;
    this.selectedPrimaryForaward_4_day5 = 0;
    this.selectedPrimaryCount_4_day5 = 0;
    this.selected_4_day_5 = 0;
    this.selectedPrimaryForaward_5_day5 = 0;
    this.selectedPrimaryCount_5_day5 = 0;
    this.selected_5_day_5 = 0;
    this.selectedPrimaryForaward_6_day5 = 0;
    this.selectedPrimaryCount_6_day5 = 0;
    this.selected_6_day_5 = 0;
    this.selectedPrimaryForaward_7_day5 = 0;
    this.selectedPrimaryCount_7_day5 = 0;
    this.selected_7_day_5 = 0;
    this.selectedPrimaryForaward_8_day5 = 0;
    this.selectedPrimaryCount_8_day5 = 0;
    this.selected_8_day_5 = 0;
    this.selectedPrimaryForaward_9_day5 = 0;
    this.selectedPrimaryCount_9_day5 = 0;
    this.selected_9_day_5 = 0;
    // Day6
    this.selectedPrimaryForaward_0_day6 = 0;
    this.selectedPrimaryCount_0_day6 = 0;
    this.selected_0_day_6 = 0;
    this.selectedPrimaryForaward_1_day6 = 0;
    this.selectedPrimaryCount_1_day6 = 0;
    this.selected_1_day_6 = 0;
    this.selectedPrimaryForaward_2_day6 = 0;
    this.selectedPrimaryCount_2_day6 = 0;
    this.selected_2_day_6 = 0;
    this.selectedPrimaryForaward_3_day6 = 0;
    this.selectedPrimaryCount_3_day6 = 0;
    this.selected_3_day_6 = 0;
    this.selectedPrimaryForaward_4_day6 = 0;
    this.selectedPrimaryCount_4_day6 = 0;
    this.selected_4_day_6 = 0;
    this.selectedPrimaryForaward_5_day6 = 0;
    this.selectedPrimaryCount_5_day6 = 0;
    this.selected_5_day_6 = 0;
    this.selectedPrimaryForaward_6_day6 = 0;
    this.selectedPrimaryCount_6_day6 = 0;
    this.selected_6_day_6 = 0;
    this.selectedPrimaryForaward_7_day6 = 0;
    this.selectedPrimaryCount_7_day6 = 0;
    this.selected_7_day_6 = 0;
    this.selectedPrimaryForaward_8_day6 = 0;
    this.selectedPrimaryCount_8_day6 = 0;
    this.selected_8_day_6 = 0;
    this.selectedPrimaryForaward_9_day6 = 0;
    this.selectedPrimaryCount_9_day6 = 0;
    this.selected_9_day_6 = 0;
    this.selectedLevel = 0;
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_5__.HttpClient(handler);
    this.loader = {
      loaderId: 'customLoaderId'
    };
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  is12or24_toggle(event) {
    // default
    let default_ampm = this.editForm.get('default_ampm').value == 0 ? "AM" : "PM";
    let default_ampm_close = this.editForm.get('default_ampm_close').value == 0 ? "AM" : "PM";
    let starttime = this.editForm.get('start_hrs').value + ':' + this.editForm.get('start_min').value + ' ' + default_ampm;
    let endtime = this.editForm.get('end_hrs').value + ':' + this.editForm.get('end_min').value + ' ' + default_ampm_close;
    // sunday
    let sunday_ampm = this.editForm.get('sunday_ampm').value == 0 ? "AM" : "PM";
    let sunday_ampm_close = this.editForm.get('sunday_ampm_close').value == 0 ? "AM" : "PM";
    let sun_starttime = this.editForm.get('start_hrs_sunday').value + ':' + this.editForm.get('start_min_sunday').value + ' ' + sunday_ampm;
    let sun_endtime = this.editForm.get('end_hrs_sunday').value + ':' + this.editForm.get('end_min_sunday').value + ' ' + sunday_ampm_close;
    // monday
    let monday_ampm = this.editForm.get('monday_ampm').value == 0 ? "AM" : "PM";
    let monday_ampm_close = this.editForm.get('monday_ampm_close').value == 0 ? "AM" : "PM";
    let mon_starttime = this.editForm.get('start_hrs_monday').value + ':' + this.editForm.get('start_min_monday').value + ' ' + monday_ampm;
    let mon_endtime = this.editForm.get('end_hrs_monday').value + ':' + this.editForm.get('end_min_monday').value + ' ' + monday_ampm_close;
    // tuesday
    let tuesday_ampm = this.editForm.get('tuesday_ampm').value == 0 ? "AM" : "PM";
    let tuesday_ampm_close = this.editForm.get('tuesday_ampm_close').value == 0 ? "AM" : "PM";
    let tue_starttime = this.editForm.get('start_hrs_tuesday').value + ':' + this.editForm.get('start_min_tuesday').value + ' ' + tuesday_ampm;
    let tue_endtime = this.editForm.get('end_hrs_tuesday').value + ':' + this.editForm.get('end_min_tuesday').value + ' ' + tuesday_ampm_close;
    // wednesday
    let wednesday_ampm = this.editForm.get('wednesday_ampm').value == 0 ? "AM" : "PM";
    let wednesday_ampm_close = this.editForm.get('wednesday_ampm_close').value == 0 ? "AM" : "PM";
    let wed_starttime = this.editForm.get('start_hrs_wednesday').value + ':' + this.editForm.get('start_min_wednesday').value + ' ' + wednesday_ampm;
    let wed_endtime = this.editForm.get('end_hrs_wednesday').value + ':' + this.editForm.get('end_min_wednesday').value + ' ' + wednesday_ampm_close;
    // thursday
    let thursday_ampm = this.editForm.get('thursday_ampm').value == 0 ? "AM" : "PM";
    let thursday_ampm_close = this.editForm.get('thursday_ampm_close').value == 0 ? "AM" : "PM";
    let thu_starttime = this.editForm.get('start_hrs_thursday').value + ':' + this.editForm.get('start_min_thursday').value + ' ' + thursday_ampm;
    let thu_endtime = this.editForm.get('end_hrs_thursday').value + ':' + this.editForm.get('end_min_thursday').value + ' ' + thursday_ampm_close;
    // friday
    let friday_ampm = this.editForm.get('friday_ampm').value == 0 ? "AM" : "PM";
    let friday_ampm_close = this.editForm.get('friday_ampm_close').value == 0 ? "AM" : "PM";
    let fri_starttime = this.editForm.get('start_hrs_friday').value + ':' + this.editForm.get('start_min_friday').value + ' ' + friday_ampm;
    let fri_endtime = this.editForm.get('end_hrs_friday').value + ':' + this.editForm.get('end_min_friday').value + ' ' + friday_ampm_close;
    // saturday
    let saturday_ampm = this.editForm.get('saturday_ampm').value == 0 ? "AM" : "PM";
    let saturday_ampm_close = this.editForm.get('saturday_ampm_close').value == 0 ? "AM" : "PM";
    let sat_starttime = this.editForm.get('start_hrs_saturday').value + ':' + this.editForm.get('start_min_saturday').value + ' ' + saturday_ampm;
    let sat_endtime = this.editForm.get('end_hrs_saturday').value + ':' + this.editForm.get('end_min_saturday').value + ' ' + saturday_ampm_close;
    if (event == false) {
      this.is12or24 = 0;
      this.starttime_default = moment__WEBPACK_IMPORTED_MODULE_3__(starttime, 'h:mm A').format('HH:mm A');
      this.endtime_default = moment__WEBPACK_IMPORTED_MODULE_3__(endtime, 'h:mm A').format('HH:mm A');
      this.starttime_sunday = moment__WEBPACK_IMPORTED_MODULE_3__(sun_starttime, 'h:mm A').format('HH:mm A');
      this.endtime_sunday = moment__WEBPACK_IMPORTED_MODULE_3__(sun_endtime, 'h:mm A').format('HH:mm A');
      this.starttime_monday = moment__WEBPACK_IMPORTED_MODULE_3__(mon_starttime, 'h:mm A').format('HH:mm A');
      this.endtime_monday = moment__WEBPACK_IMPORTED_MODULE_3__(mon_endtime, 'h:mm A').format('HH:mm A');
      this.starttime_tuesday = moment__WEBPACK_IMPORTED_MODULE_3__(tue_starttime, 'h:mm A').format('HH:mm A');
      this.endtime_tuesday = moment__WEBPACK_IMPORTED_MODULE_3__(tue_endtime, 'h:mm A').format('HH:mm A');
      this.starttime_wednesday = moment__WEBPACK_IMPORTED_MODULE_3__(wed_starttime, 'h:mm A').format('HH:mm A');
      this.endtime_wednesday = moment__WEBPACK_IMPORTED_MODULE_3__(wed_endtime, 'h:mm A').format('HH:mm A');
      this.starttime_thursday = moment__WEBPACK_IMPORTED_MODULE_3__(thu_starttime, 'h:mm A').format('HH:mm A');
      this.endtime_thursday = moment__WEBPACK_IMPORTED_MODULE_3__(thu_endtime, 'h:mm A').format('HH:mm A');
      this.starttime_friday = moment__WEBPACK_IMPORTED_MODULE_3__(fri_starttime, 'h:mm A').format('HH:mm A');
      this.endtime_friday = moment__WEBPACK_IMPORTED_MODULE_3__(fri_endtime, 'h:mm A').format('HH:mm A');
      this.starttime_saturday = moment__WEBPACK_IMPORTED_MODULE_3__(sat_starttime, 'h:mm A').format('HH:mm A');
      this.endtime_saturday = moment__WEBPACK_IMPORTED_MODULE_3__(sat_endtime, 'h:mm A').format('HH:mm A');
    }
    if (event == true) {
      this.is12or24 = 1;
      this.starttime_default = moment__WEBPACK_IMPORTED_MODULE_3__(starttime, 'hh:mm A').format('hh:mm A');
      this.endtime_default = moment__WEBPACK_IMPORTED_MODULE_3__(endtime, 'hh:mm A').format('hh:mm A');
      this.starttime_sunday = moment__WEBPACK_IMPORTED_MODULE_3__(sun_starttime, 'h:mm A').format('hh:mm A');
      this.endtime_sunday = moment__WEBPACK_IMPORTED_MODULE_3__(sun_endtime, 'h:mm A').format('hh:mm A');
      this.starttime_monday = moment__WEBPACK_IMPORTED_MODULE_3__(mon_starttime, 'h:mm A').format('hh:mm A');
      this.endtime_monday = moment__WEBPACK_IMPORTED_MODULE_3__(mon_endtime, 'h:mm A').format('hh:mm A');
      this.starttime_tuesday = moment__WEBPACK_IMPORTED_MODULE_3__(tue_starttime, 'h:mm A').format('hh:mm A');
      this.endtime_tuesday = moment__WEBPACK_IMPORTED_MODULE_3__(tue_endtime, 'h:mm A').format('hh:mm A');
      this.starttime_wednesday = moment__WEBPACK_IMPORTED_MODULE_3__(wed_starttime, 'h:mm A').format('hh:mm A');
      this.endtime_wednesday = moment__WEBPACK_IMPORTED_MODULE_3__(wed_endtime, 'h:mm A').format('hh:mm A');
      this.starttime_thursday = moment__WEBPACK_IMPORTED_MODULE_3__(thu_starttime, 'h:mm A').format('hh:mm A');
      this.endtime_thursday = moment__WEBPACK_IMPORTED_MODULE_3__(thu_endtime, 'h:mm A').format('hh:mm A');
      this.starttime_friday = moment__WEBPACK_IMPORTED_MODULE_3__(fri_starttime, 'h:mm A').format('hh:mm A');
      this.endtime_friday = moment__WEBPACK_IMPORTED_MODULE_3__(fri_endtime, 'h:mm A').format('hh:mm A');
      this.starttime_saturday = moment__WEBPACK_IMPORTED_MODULE_3__(sat_starttime, 'h:mm A').format('hh:mm A');
      this.endtime_saturday = moment__WEBPACK_IMPORTED_MODULE_3__(sat_endtime, 'h:mm A').format('hh:mm A');
    }
    this.editForm.get('start_hrs').setValue(this.starttime_default.substring(0, 2));
    this.editForm.get('start_min').setValue(this.starttime_default.substring(3, 5));
    this.editForm.get('end_hrs').setValue(this.endtime_default.substring(0, 2));
    this.editForm.get('end_min').setValue(this.endtime_default.substring(3, 5));
    this.editForm.get('start_hrs_sunday').setValue(this.starttime_sunday.substring(0, 2));
    this.editForm.get('start_min_sunday').setValue(this.starttime_sunday.substring(3, 5));
    this.editForm.get('end_hrs_sunday').setValue(this.endtime_sunday.substring(0, 2));
    this.editForm.get('end_min_sunday').setValue(this.endtime_sunday.substring(3, 5));
    this.editForm.get('start_hrs_monday').setValue(this.starttime_monday.substring(0, 2));
    this.editForm.get('start_min_monday').setValue(this.starttime_monday.substring(3, 5));
    this.editForm.get('end_hrs_monday').setValue(this.endtime_monday.substring(0, 2));
    this.editForm.get('end_min_monday').setValue(this.endtime_monday.substring(3, 5));
    this.editForm.get('start_hrs_tuesday').setValue(this.starttime_tuesday.substring(0, 2));
    this.editForm.get('start_min_tuesday').setValue(this.starttime_tuesday.substring(3, 5));
    this.editForm.get('end_hrs_tuesday').setValue(this.endtime_tuesday.substring(0, 2));
    this.editForm.get('end_min_tuesday').setValue(this.endtime_tuesday.substring(3, 5));
    this.editForm.get('start_hrs_wednesday').setValue(this.starttime_wednesday.substring(0, 2));
    this.editForm.get('start_min_wednesday').setValue(this.starttime_wednesday.substring(3, 5));
    this.editForm.get('end_hrs_wednesday').setValue(this.endtime_wednesday.substring(0, 2));
    this.editForm.get('end_min_wednesday').setValue(this.endtime_wednesday.substring(3, 5));
    this.editForm.get('start_hrs_thursday').setValue(this.starttime_thursday.substring(0, 2));
    this.editForm.get('start_min_thursday').setValue(this.starttime_thursday.substring(3, 5));
    this.editForm.get('end_hrs_thursday').setValue(this.endtime_thursday.substring(0, 2));
    this.editForm.get('end_min_thursday').setValue(this.endtime_thursday.substring(3, 5));
    this.editForm.get('start_hrs_friday').setValue(this.starttime_friday.substring(0, 2));
    this.editForm.get('start_min_friday').setValue(this.starttime_friday.substring(3, 5));
    this.editForm.get('end_hrs_friday').setValue(this.endtime_friday.substring(0, 2));
    this.editForm.get('end_min_friday').setValue(this.endtime_friday.substring(3, 5));
    this.editForm.get('start_hrs_saturday').setValue(this.starttime_saturday.substring(0, 2));
    this.editForm.get('start_min_saturday').setValue(this.starttime_saturday.substring(3, 5));
    this.editForm.get('end_hrs_saturday').setValue(this.endtime_saturday.substring(0, 2));
    this.editForm.get('end_min_saturday').setValue(this.endtime_saturday.substring(3, 5));
  }
  closeModal() {
    if (this.noofforwarding) {
      $("#addFSLRules").modal("hide");
      setTimeout(() => {
        this.addFSLRules.reset({
          'name': ' ',
          'numberoftimeframe': ' '
        });
        // this.getAllRules();
        this.getalldata();
      }, 2000);
    }
  }
  editcloseModal() {
    if (this.noofforwarding) {
      $("#editFSLRules").modal("hide");
      this.FSLRulesEditSubmitted = false;
      setTimeout(() => {
        this.getalldata();
        this.getRulesByName(this.editForm.get('fslrulesname').value);
      }, 2000);
    }
  }
  ngAfterViewChecked() {
    this.cdRef.detectChanges();
  }
  getAllLabels() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleService.getAllLabels(this.currentCompany.uuid).subscribe(res => {
      this.dropdownList = res;
    }, error => this.error = error);
  }
  getRulesByName(name) {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleService.getRulesByName(name, this.currentCompany.uuid).subscribe(res => {
      this.allRulesbyname = res;
    }, error => this.error = error);
  }
  _keyPress(event) {
    const isNumericInput = event => {
      const key = event.keyCode;
      return key >= 48 && key <= 57 ||
      // Allow number line
      key >= 96 && key <= 105 // Allow number pad
      ;
    };

    const isModifierKey = event => {
      const key = event.keyCode;
      return event.shiftKey === true || key === 35 || key === 36 ||
      // Allow Shift, Home, End
      key === 8 || key === 9 || key === 13 || key === 46 ||
      // Allow Backspace, Tab, Enter, Delete
      key > 36 && key < 41 ||
      // Allow left, up, right, down

      // Allow Ctrl/Command + A,C,V,X,Z
      (event.ctrlKey === true || event.metaKey === true) && (key === 65 || key === 67 || key === 86 || key === 88 || key === 90);
    };
    const enforceFormat = event => {
      // Input must be of a valid number format or a modifier key, and not longer than ten digits
      if (!isNumericInput(event) && !isModifierKey(event)) {
        event.preventDefault();
      }
    };
    const formatToPhone = event => {
      if (isModifierKey(event)) {
        return;
      }
      const target = event.target;
      const input = event.target.value.replace(/\D/g, '').substring(0, 10); // First ten digits of input only
      const zip = input.substring(0, 3);
      const middle = input.substring(3, 6);
      const last = input.substring(6, 10);
      if (input.length > 6) {
        target.value = `(${zip}) ${middle}-${last}`;
      } else if (input.length > 3) {
        target.value = `(${zip}) ${middle}`;
      } else if (input.length > 0) {
        target.value = `(${zip}`;
      }
    };
    const inputElement = document.getElementById('number');
    const number_0_day0 = document.getElementById('number_0_day0');
    const number_1_day0 = document.getElementById('number_1_day0');
    const number_2_day0 = document.getElementById('number_2_day0');
    const number_3_day0 = document.getElementById('number_3_day0');
    const number_4_day0 = document.getElementById('number_4_day0');
    const number_5_day0 = document.getElementById('number_5_day0');
    const number_6_day0 = document.getElementById('number_6_day0');
    const number_7_day0 = document.getElementById('number_7_day0');
    const number_8_day0 = document.getElementById('number_8_day0');
    const number_9_day0 = document.getElementById('number_9_day0');
    const number_0_day1 = document.getElementById('number_0_day1');
    const number_1_day1 = document.getElementById('number_1_day1');
    const number_2_day1 = document.getElementById('number_2_day1');
    const number_3_day1 = document.getElementById('number_3_day1');
    const number_4_day1 = document.getElementById('number_4_day1');
    const number_5_day1 = document.getElementById('number_5_day1');
    const number_6_day1 = document.getElementById('number_6_day1');
    const number_7_day1 = document.getElementById('number_7_day1');
    const number_8_day1 = document.getElementById('number_8_day1');
    const number_9_day1 = document.getElementById('number_9_day1');
    const number_0_day2 = document.getElementById('number_0_day2');
    const number_1_day2 = document.getElementById('number_1_day2');
    const number_2_day2 = document.getElementById('number_2_day2');
    const number_3_day2 = document.getElementById('number_3_day2');
    const number_4_day2 = document.getElementById('number_4_day2');
    const number_5_day2 = document.getElementById('number_5_day2');
    const number_6_day2 = document.getElementById('number_6_day2');
    const number_7_day2 = document.getElementById('number_7_day2');
    const number_8_day2 = document.getElementById('number_8_day2');
    const number_9_day2 = document.getElementById('number_9_day2');
    const number_0_day3 = document.getElementById('number_0_day3');
    const number_1_day3 = document.getElementById('number_1_day3');
    const number_2_day3 = document.getElementById('number_2_day3');
    const number_3_day3 = document.getElementById('number_3_day3');
    const number_4_day3 = document.getElementById('number_4_day3');
    const number_5_day3 = document.getElementById('number_5_day3');
    const number_6_day3 = document.getElementById('number_6_day3');
    const number_7_day3 = document.getElementById('number_7_day3');
    const number_8_day3 = document.getElementById('number_8_day3');
    const number_9_day3 = document.getElementById('number_9_day3');
    const number_0_day4 = document.getElementById('number_0_day4');
    const number_1_day4 = document.getElementById('number_1_day4');
    const number_2_day4 = document.getElementById('number_2_day4');
    const number_3_day4 = document.getElementById('number_3_day4');
    const number_4_day4 = document.getElementById('number_4_day4');
    const number_5_day4 = document.getElementById('number_5_day4');
    const number_6_day4 = document.getElementById('number_6_day4');
    const number_7_day4 = document.getElementById('number_7_day4');
    const number_8_day4 = document.getElementById('number_8_day4');
    const number_9_day4 = document.getElementById('number_9_day4');
    const number_0_day5 = document.getElementById('number_0_day5');
    const number_1_day5 = document.getElementById('number_1_day5');
    const number_2_day5 = document.getElementById('number_2_day5');
    const number_3_day5 = document.getElementById('number_3_day5');
    const number_4_day5 = document.getElementById('number_4_day5');
    const number_5_day5 = document.getElementById('number_5_day5');
    const number_6_day5 = document.getElementById('number_6_day5');
    const number_7_day5 = document.getElementById('number_7_day5');
    const number_8_day5 = document.getElementById('number_8_day5');
    const number_9_day5 = document.getElementById('number_9_day5');
    const number_0_day6 = document.getElementById('number_0_day6');
    const number_1_day6 = document.getElementById('number_1_day6');
    const number_2_day6 = document.getElementById('number_2_day6');
    const number_3_day6 = document.getElementById('number_3_day6');
    const number_4_day6 = document.getElementById('number_4_day6');
    const number_5_day6 = document.getElementById('number_5_day6');
    const number_6_day6 = document.getElementById('number_6_day6');
    const number_7_day6 = document.getElementById('number_7_day6');
    const number_8_day6 = document.getElementById('number_8_day6');
    const number_9_day6 = document.getElementById('number_9_day6');
    if (inputElement) {
      inputElement.addEventListener('keydown', enforceFormat);
      inputElement.addEventListener('keyup', formatToPhone);
    }
    if (number_0_day0) {
      number_0_day0.addEventListener('keydown', enforceFormat);
      number_0_day0.addEventListener('keyup', formatToPhone);
    }
    if (number_1_day0) {
      number_1_day0.addEventListener('keydown', enforceFormat);
      number_1_day0.addEventListener('keyup', formatToPhone);
    }
    if (number_2_day0) {
      number_2_day0.addEventListener('keydown', enforceFormat);
      number_2_day0.addEventListener('keyup', formatToPhone);
    }
    if (number_3_day0) {
      number_3_day0.addEventListener('keydown', enforceFormat);
      number_3_day0.addEventListener('keyup', formatToPhone);
    }
    if (number_4_day0) {
      number_4_day0.addEventListener('keydown', enforceFormat);
      number_4_day0.addEventListener('keyup', formatToPhone);
    }
    if (number_5_day0) {
      number_5_day0.addEventListener('keydown', enforceFormat);
      number_5_day0.addEventListener('keyup', formatToPhone);
    }
    if (number_6_day0) {
      number_6_day0.addEventListener('keydown', enforceFormat);
      number_6_day0.addEventListener('keyup', formatToPhone);
    }
    if (number_7_day0) {
      number_7_day0.addEventListener('keydown', enforceFormat);
      number_7_day0.addEventListener('keyup', formatToPhone);
    }
    if (number_8_day0) {
      number_8_day0.addEventListener('keydown', enforceFormat);
      number_8_day0.addEventListener('keyup', formatToPhone);
    }
    if (number_9_day0) {
      number_9_day0.addEventListener('keydown', enforceFormat);
      number_9_day0.addEventListener('keyup', formatToPhone);
    }
    if (number_0_day1) {
      number_0_day1.addEventListener('keydown', enforceFormat);
      number_0_day1.addEventListener('keyup', formatToPhone);
    }
    if (number_1_day1) {
      number_1_day1.addEventListener('keydown', enforceFormat);
      number_1_day1.addEventListener('keyup', formatToPhone);
    }
    if (number_2_day1) {
      number_2_day1.addEventListener('keydown', enforceFormat);
      number_2_day1.addEventListener('keyup', formatToPhone);
    }
    if (number_3_day1) {
      number_3_day1.addEventListener('keydown', enforceFormat);
      number_3_day1.addEventListener('keyup', formatToPhone);
    }
    if (number_4_day1) {
      number_4_day1.addEventListener('keydown', enforceFormat);
      number_4_day1.addEventListener('keyup', formatToPhone);
    }
    if (number_5_day1) {
      number_5_day1.addEventListener('keydown', enforceFormat);
      number_5_day1.addEventListener('keyup', formatToPhone);
    }
    if (number_6_day1) {
      number_6_day1.addEventListener('keydown', enforceFormat);
      number_6_day1.addEventListener('keyup', formatToPhone);
    }
    if (number_7_day1) {
      number_7_day1.addEventListener('keydown', enforceFormat);
      number_7_day1.addEventListener('keyup', formatToPhone);
    }
    if (number_8_day1) {
      number_8_day1.addEventListener('keydown', enforceFormat);
      number_8_day1.addEventListener('keyup', formatToPhone);
    }
    if (number_9_day1) {
      number_9_day1.addEventListener('keydown', enforceFormat);
      number_9_day1.addEventListener('keyup', formatToPhone);
    }
    if (number_0_day2) {
      number_0_day2.addEventListener('keydown', enforceFormat);
      number_0_day2.addEventListener('keyup', formatToPhone);
    }
    if (number_1_day2) {
      number_1_day2.addEventListener('keydown', enforceFormat);
      number_1_day2.addEventListener('keyup', formatToPhone);
    }
    if (number_2_day2) {
      number_2_day2.addEventListener('keydown', enforceFormat);
      number_2_day2.addEventListener('keyup', formatToPhone);
    }
    if (number_3_day2) {
      number_3_day2.addEventListener('keydown', enforceFormat);
      number_3_day2.addEventListener('keyup', formatToPhone);
    }
    if (number_4_day2) {
      number_4_day2.addEventListener('keydown', enforceFormat);
      number_4_day2.addEventListener('keyup', formatToPhone);
    }
    if (number_5_day2) {
      number_5_day2.addEventListener('keydown', enforceFormat);
      number_5_day2.addEventListener('keyup', formatToPhone);
    }
    if (number_6_day2) {
      number_6_day2.addEventListener('keydown', enforceFormat);
      number_6_day2.addEventListener('keyup', formatToPhone);
    }
    if (number_7_day2) {
      number_7_day2.addEventListener('keydown', enforceFormat);
      number_7_day2.addEventListener('keyup', formatToPhone);
    }
    if (number_8_day2) {
      number_8_day2.addEventListener('keydown', enforceFormat);
      number_8_day2.addEventListener('keyup', formatToPhone);
    }
    if (number_9_day2) {
      number_9_day2.addEventListener('keydown', enforceFormat);
      number_9_day2.addEventListener('keyup', formatToPhone);
    }
    if (number_0_day3) {
      number_0_day3.addEventListener('keydown', enforceFormat);
      number_0_day3.addEventListener('keyup', formatToPhone);
    }
    if (number_1_day3) {
      number_1_day3.addEventListener('keydown', enforceFormat);
      number_1_day3.addEventListener('keyup', formatToPhone);
    }
    if (number_2_day3) {
      number_2_day3.addEventListener('keydown', enforceFormat);
      number_2_day3.addEventListener('keyup', formatToPhone);
    }
    if (number_3_day3) {
      number_3_day3.addEventListener('keydown', enforceFormat);
      number_3_day3.addEventListener('keyup', formatToPhone);
    }
    if (number_4_day3) {
      number_4_day3.addEventListener('keydown', enforceFormat);
      number_4_day3.addEventListener('keyup', formatToPhone);
    }
    if (number_5_day3) {
      number_5_day3.addEventListener('keydown', enforceFormat);
      number_5_day3.addEventListener('keyup', formatToPhone);
    }
    if (number_6_day3) {
      number_6_day3.addEventListener('keydown', enforceFormat);
      number_6_day3.addEventListener('keyup', formatToPhone);
    }
    if (number_7_day3) {
      number_7_day3.addEventListener('keydown', enforceFormat);
      number_7_day3.addEventListener('keyup', formatToPhone);
    }
    if (number_8_day3) {
      number_8_day3.addEventListener('keydown', enforceFormat);
      number_8_day3.addEventListener('keyup', formatToPhone);
    }
    if (number_9_day3) {
      number_9_day3.addEventListener('keydown', enforceFormat);
      number_9_day3.addEventListener('keyup', formatToPhone);
    }
    if (number_0_day4) {
      number_0_day4.addEventListener('keydown', enforceFormat);
      number_0_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_1_day4) {
      number_1_day4.addEventListener('keydown', enforceFormat);
      number_1_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_2_day4) {
      number_2_day4.addEventListener('keydown', enforceFormat);
      number_2_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_3_day4) {
      number_3_day4.addEventListener('keydown', enforceFormat);
      number_3_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_4_day4) {
      number_4_day4.addEventListener('keydown', enforceFormat);
      number_4_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_5_day4) {
      number_5_day4.addEventListener('keydown', enforceFormat);
      number_5_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_6_day4) {
      number_6_day4.addEventListener('keydown', enforceFormat);
      number_6_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_7_day4) {
      number_7_day4.addEventListener('keydown', enforceFormat);
      number_7_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_8_day4) {
      number_8_day4.addEventListener('keydown', enforceFormat);
      number_8_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_9_day4) {
      number_9_day4.addEventListener('keydown', enforceFormat);
      number_9_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_0_day4) {
      number_0_day4.addEventListener('keydown', enforceFormat);
      number_0_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_1_day4) {
      number_1_day4.addEventListener('keydown', enforceFormat);
      number_1_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_2_day4) {
      number_2_day4.addEventListener('keydown', enforceFormat);
      number_2_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_3_day4) {
      number_3_day4.addEventListener('keydown', enforceFormat);
      number_3_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_4_day4) {
      number_4_day4.addEventListener('keydown', enforceFormat);
      number_4_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_5_day4) {
      number_5_day4.addEventListener('keydown', enforceFormat);
      number_5_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_6_day4) {
      number_6_day4.addEventListener('keydown', enforceFormat);
      number_6_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_7_day4) {
      number_7_day4.addEventListener('keydown', enforceFormat);
      number_7_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_8_day4) {
      number_8_day4.addEventListener('keydown', enforceFormat);
      number_8_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_9_day4) {
      number_9_day4.addEventListener('keydown', enforceFormat);
      number_9_day4.addEventListener('keyup', formatToPhone);
    }
    if (number_0_day5) {
      number_0_day5.addEventListener('keydown', enforceFormat);
      number_0_day5.addEventListener('keyup', formatToPhone);
    }
    if (number_1_day5) {
      number_1_day5.addEventListener('keydown', enforceFormat);
      number_1_day5.addEventListener('keyup', formatToPhone);
    }
    if (number_2_day5) {
      number_2_day5.addEventListener('keydown', enforceFormat);
      number_2_day5.addEventListener('keyup', formatToPhone);
    }
    if (number_3_day5) {
      number_3_day5.addEventListener('keydown', enforceFormat);
      number_3_day5.addEventListener('keyup', formatToPhone);
    }
    if (number_4_day5) {
      number_4_day5.addEventListener('keydown', enforceFormat);
      number_4_day5.addEventListener('keyup', formatToPhone);
    }
    if (number_5_day5) {
      number_5_day5.addEventListener('keydown', enforceFormat);
      number_5_day5.addEventListener('keyup', formatToPhone);
    }
    if (number_6_day5) {
      number_6_day5.addEventListener('keydown', enforceFormat);
      number_6_day5.addEventListener('keyup', formatToPhone);
    }
    if (number_7_day5) {
      number_7_day5.addEventListener('keydown', enforceFormat);
      number_7_day5.addEventListener('keyup', formatToPhone);
    }
    if (number_8_day5) {
      number_8_day5.addEventListener('keydown', enforceFormat);
      number_8_day5.addEventListener('keyup', formatToPhone);
    }
    if (number_9_day5) {
      number_9_day5.addEventListener('keydown', enforceFormat);
      number_9_day5.addEventListener('keyup', formatToPhone);
    }
    if (number_0_day6) {
      number_0_day6.addEventListener('keydown', enforceFormat);
      number_0_day6.addEventListener('keyup', formatToPhone);
    }
    if (number_1_day6) {
      number_1_day6.addEventListener('keydown', enforceFormat);
      number_1_day6.addEventListener('keyup', formatToPhone);
    }
    if (number_2_day6) {
      number_2_day6.addEventListener('keydown', enforceFormat);
      number_2_day6.addEventListener('keyup', formatToPhone);
    }
    if (number_3_day6) {
      number_3_day6.addEventListener('keydown', enforceFormat);
      number_3_day6.addEventListener('keyup', formatToPhone);
    }
    if (number_4_day6) {
      number_4_day6.addEventListener('keydown', enforceFormat);
      number_4_day6.addEventListener('keyup', formatToPhone);
    }
    if (number_5_day6) {
      number_5_day6.addEventListener('keydown', enforceFormat);
      number_5_day6.addEventListener('keyup', formatToPhone);
    }
    if (number_6_day6) {
      number_6_day6.addEventListener('keydown', enforceFormat);
      number_6_day6.addEventListener('keyup', formatToPhone);
    }
    if (number_7_day6) {
      number_7_day6.addEventListener('keydown', enforceFormat);
      number_7_day6.addEventListener('keyup', formatToPhone);
    }
    if (number_8_day6) {
      number_8_day6.addEventListener('keydown', enforceFormat);
      number_8_day6.addEventListener('keyup', formatToPhone);
    }
    if (number_9_day6) {
      number_9_day6.addEventListener('keydown', enforceFormat);
      number_9_day6.addEventListener('keyup', formatToPhone);
    }
    const editnumber_0_day0 = document.getElementById('editnumber_0_day0');
    const editnumber_1_day0 = document.getElementById('editnumber_1_day0');
    const editnumber_2_day0 = document.getElementById('editnumber_2_day0');
    const editnumber_3_day0 = document.getElementById('editnumber_3_day0');
    const editnumber_4_day0 = document.getElementById('editnumber_4_day0');
    const editnumber_5_day0 = document.getElementById('editnumber_5_day0');
    const editnumber_6_day0 = document.getElementById('editnumber_6_day0');
    const editnumber_7_day0 = document.getElementById('editnumber_7_day0');
    const editnumber_8_day0 = document.getElementById('editnumber_8_day0');
    const editnumber_9_day0 = document.getElementById('editnumber_9_day0');
    const editnumber_0_day1 = document.getElementById('editnumber_0_day1');
    const editnumber_1_day1 = document.getElementById('editnumber_1_day1');
    const editnumber_2_day1 = document.getElementById('editnumber_2_day1');
    const editnumber_3_day1 = document.getElementById('editnumber_3_day1');
    const editnumber_4_day1 = document.getElementById('editnumber_4_day1');
    const editnumber_5_day1 = document.getElementById('editnumber_5_day1');
    const editnumber_6_day1 = document.getElementById('editnumber_6_day1');
    const editnumber_7_day1 = document.getElementById('editnumber_7_day1');
    const editnumber_8_day1 = document.getElementById('editnumber_8_day1');
    const editnumber_9_day1 = document.getElementById('editnumber_9_day1');
    const editnumber_0_day2 = document.getElementById('editnumber_0_day2');
    const editnumber_1_day2 = document.getElementById('editnumber_1_day2');
    const editnumber_2_day2 = document.getElementById('editnumber_2_day2');
    const editnumber_3_day2 = document.getElementById('editnumber_3_day2');
    const editnumber_4_day2 = document.getElementById('editnumber_4_day2');
    const editnumber_5_day2 = document.getElementById('editnumber_5_day2');
    const editnumber_6_day2 = document.getElementById('editnumber_6_day2');
    const editnumber_7_day2 = document.getElementById('editnumber_7_day2');
    const editnumber_8_day2 = document.getElementById('editnumber_8_day2');
    const editnumber_9_day2 = document.getElementById('editnumber_9_day2');
    const editnumber_0_day3 = document.getElementById('editnumber_0_day3');
    const editnumber_1_day3 = document.getElementById('editnumber_1_day3');
    const editnumber_2_day3 = document.getElementById('editnumber_2_day3');
    const editnumber_3_day3 = document.getElementById('editnumber_3_day3');
    const editnumber_4_day3 = document.getElementById('editnumber_4_day3');
    const editnumber_5_day3 = document.getElementById('editnumber_5_day3');
    const editnumber_6_day3 = document.getElementById('editnumber_6_day3');
    const editnumber_7_day3 = document.getElementById('editnumber_7_day3');
    const editnumber_8_day3 = document.getElementById('editnumber_8_day3');
    const editnumber_9_day3 = document.getElementById('editnumber_9_day3');
    const editnumber_0_day4 = document.getElementById('editnumber_0_day4');
    const editnumber_1_day4 = document.getElementById('editnumber_1_day4');
    const editnumber_2_day4 = document.getElementById('editnumber_2_day4');
    const editnumber_3_day4 = document.getElementById('editnumber_3_day4');
    const editnumber_4_day4 = document.getElementById('editnumber_4_day4');
    const editnumber_5_day4 = document.getElementById('editnumber_5_day4');
    const editnumber_6_day4 = document.getElementById('editnumber_6_day4');
    const editnumber_7_day4 = document.getElementById('editnumber_7_day4');
    const editnumber_8_day4 = document.getElementById('editnumber_8_day4');
    const editnumber_9_day4 = document.getElementById('editnumber_9_day4');
    const editnumber_0_day5 = document.getElementById('editnumber_0_day5');
    const editnumber_1_day5 = document.getElementById('editnumber_1_day5');
    const editnumber_2_day5 = document.getElementById('editnumber_2_day5');
    const editnumber_3_day5 = document.getElementById('editnumber_3_day5');
    const editnumber_4_day5 = document.getElementById('editnumber_4_day5');
    const editnumber_5_day5 = document.getElementById('editnumber_5_day5');
    const editnumber_6_day5 = document.getElementById('editnumber_6_day5');
    const editnumber_7_day5 = document.getElementById('editnumber_7_day5');
    const editnumber_8_day5 = document.getElementById('editnumber_8_day5');
    const editnumber_9_day5 = document.getElementById('editnumber_9_day5');
    const editnumber_0_day6 = document.getElementById('editnumber_0_day6');
    const editnumber_1_day6 = document.getElementById('editnumber_1_day6');
    const editnumber_2_day6 = document.getElementById('editnumber_2_day6');
    const editnumber_3_day6 = document.getElementById('editnumber_3_day6');
    const editnumber_4_day6 = document.getElementById('editnumber_4_day6');
    const editnumber_5_day6 = document.getElementById('editnumber_5_day6');
    const editnumber_6_day6 = document.getElementById('editnumber_6_day6');
    const editnumber_7_day6 = document.getElementById('editnumber_7_day6');
    const editnumber_8_day6 = document.getElementById('editnumber_8_day6');
    const editnumber_9_day6 = document.getElementById('editnumber_9_day6');
    if (editnumber_0_day0) {
      editnumber_0_day0.addEventListener('keydown', enforceFormat);
      editnumber_0_day0.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_1_day0) {
      editnumber_1_day0.addEventListener('keydown', enforceFormat);
      editnumber_1_day0.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_2_day0) {
      editnumber_2_day0.addEventListener('keydown', enforceFormat);
      editnumber_2_day0.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_3_day0) {
      editnumber_3_day0.addEventListener('keydown', enforceFormat);
      editnumber_3_day0.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_4_day0) {
      editnumber_4_day0.addEventListener('keydown', enforceFormat);
      editnumber_4_day0.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_5_day0) {
      editnumber_5_day0.addEventListener('keydown', enforceFormat);
      editnumber_5_day0.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_6_day0) {
      editnumber_6_day0.addEventListener('keydown', enforceFormat);
      editnumber_6_day0.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_7_day0) {
      editnumber_7_day0.addEventListener('keydown', enforceFormat);
      editnumber_7_day0.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_8_day0) {
      editnumber_8_day0.addEventListener('keydown', enforceFormat);
      editnumber_8_day0.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_9_day0) {
      editnumber_9_day0.addEventListener('keydown', enforceFormat);
      editnumber_9_day0.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_0_day1) {
      editnumber_0_day1.addEventListener('keydown', enforceFormat);
      editnumber_0_day1.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_1_day1) {
      editnumber_1_day1.addEventListener('keydown', enforceFormat);
      editnumber_1_day1.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_2_day1) {
      editnumber_2_day1.addEventListener('keydown', enforceFormat);
      editnumber_2_day1.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_3_day1) {
      editnumber_3_day1.addEventListener('keydown', enforceFormat);
      editnumber_3_day1.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_4_day1) {
      editnumber_4_day1.addEventListener('keydown', enforceFormat);
      editnumber_4_day1.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_5_day1) {
      editnumber_5_day1.addEventListener('keydown', enforceFormat);
      editnumber_5_day1.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_6_day1) {
      editnumber_6_day1.addEventListener('keydown', enforceFormat);
      editnumber_6_day1.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_7_day1) {
      editnumber_7_day1.addEventListener('keydown', enforceFormat);
      editnumber_7_day1.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_8_day1) {
      editnumber_8_day1.addEventListener('keydown', enforceFormat);
      editnumber_8_day1.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_9_day1) {
      editnumber_9_day1.addEventListener('keydown', enforceFormat);
      editnumber_9_day1.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_0_day2) {
      editnumber_0_day2.addEventListener('keydown', enforceFormat);
      editnumber_0_day2.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_1_day2) {
      editnumber_1_day2.addEventListener('keydown', enforceFormat);
      editnumber_1_day2.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_2_day2) {
      editnumber_2_day2.addEventListener('keydown', enforceFormat);
      editnumber_2_day2.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_3_day2) {
      editnumber_3_day2.addEventListener('keydown', enforceFormat);
      editnumber_3_day2.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_4_day2) {
      editnumber_4_day2.addEventListener('keydown', enforceFormat);
      editnumber_4_day2.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_5_day2) {
      editnumber_5_day2.addEventListener('keydown', enforceFormat);
      editnumber_5_day2.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_6_day2) {
      editnumber_6_day2.addEventListener('keydown', enforceFormat);
      editnumber_6_day2.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_7_day2) {
      editnumber_7_day2.addEventListener('keydown', enforceFormat);
      editnumber_7_day2.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_8_day2) {
      editnumber_8_day2.addEventListener('keydown', enforceFormat);
      editnumber_8_day2.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_9_day2) {
      editnumber_9_day2.addEventListener('keydown', enforceFormat);
      editnumber_9_day2.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_0_day3) {
      editnumber_0_day3.addEventListener('keydown', enforceFormat);
      editnumber_0_day3.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_1_day3) {
      editnumber_1_day3.addEventListener('keydown', enforceFormat);
      editnumber_1_day3.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_2_day3) {
      editnumber_2_day3.addEventListener('keydown', enforceFormat);
      editnumber_2_day3.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_3_day3) {
      editnumber_3_day3.addEventListener('keydown', enforceFormat);
      editnumber_3_day3.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_4_day3) {
      editnumber_4_day3.addEventListener('keydown', enforceFormat);
      editnumber_4_day3.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_5_day3) {
      editnumber_5_day3.addEventListener('keydown', enforceFormat);
      editnumber_5_day3.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_6_day3) {
      editnumber_6_day3.addEventListener('keydown', enforceFormat);
      editnumber_6_day3.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_7_day3) {
      editnumber_7_day3.addEventListener('keydown', enforceFormat);
      editnumber_7_day3.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_8_day3) {
      editnumber_8_day3.addEventListener('keydown', enforceFormat);
      editnumber_8_day3.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_9_day3) {
      editnumber_9_day3.addEventListener('keydown', enforceFormat);
      editnumber_9_day3.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_0_day4) {
      editnumber_0_day4.addEventListener('keydown', enforceFormat);
      editnumber_0_day4.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_1_day4) {
      editnumber_1_day4.addEventListener('keydown', enforceFormat);
      editnumber_1_day4.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_2_day4) {
      editnumber_2_day4.addEventListener('keydown', enforceFormat);
      editnumber_2_day4.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_3_day4) {
      editnumber_3_day4.addEventListener('keydown', enforceFormat);
      editnumber_3_day4.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_4_day4) {
      editnumber_4_day4.addEventListener('keydown', enforceFormat);
      editnumber_4_day4.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_5_day4) {
      editnumber_5_day4.addEventListener('keydown', enforceFormat);
      editnumber_5_day4.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_6_day4) {
      editnumber_6_day4.addEventListener('keydown', enforceFormat);
      editnumber_6_day4.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_7_day4) {
      editnumber_7_day4.addEventListener('keydown', enforceFormat);
      editnumber_7_day4.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_8_day4) {
      editnumber_8_day4.addEventListener('keydown', enforceFormat);
      editnumber_8_day4.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_9_day4) {
      editnumber_9_day4.addEventListener('keydown', enforceFormat);
      editnumber_9_day4.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_0_day5) {
      editnumber_0_day5.addEventListener('keydown', enforceFormat);
      editnumber_0_day5.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_1_day5) {
      editnumber_1_day5.addEventListener('keydown', enforceFormat);
      editnumber_1_day5.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_2_day5) {
      editnumber_2_day5.addEventListener('keydown', enforceFormat);
      editnumber_2_day5.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_3_day5) {
      editnumber_3_day5.addEventListener('keydown', enforceFormat);
      editnumber_3_day5.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_4_day5) {
      editnumber_4_day5.addEventListener('keydown', enforceFormat);
      editnumber_4_day5.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_5_day5) {
      editnumber_5_day5.addEventListener('keydown', enforceFormat);
      editnumber_5_day5.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_6_day5) {
      editnumber_6_day5.addEventListener('keydown', enforceFormat);
      editnumber_6_day5.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_7_day5) {
      editnumber_7_day5.addEventListener('keydown', enforceFormat);
      editnumber_7_day5.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_8_day5) {
      editnumber_8_day5.addEventListener('keydown', enforceFormat);
      editnumber_8_day5.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_9_day5) {
      editnumber_9_day5.addEventListener('keydown', enforceFormat);
      editnumber_9_day5.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_0_day6) {
      editnumber_0_day6.addEventListener('keydown', enforceFormat);
      editnumber_0_day6.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_1_day6) {
      editnumber_1_day6.addEventListener('keydown', enforceFormat);
      editnumber_1_day6.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_2_day6) {
      editnumber_2_day6.addEventListener('keydown', enforceFormat);
      editnumber_2_day6.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_3_day6) {
      editnumber_3_day6.addEventListener('keydown', enforceFormat);
      editnumber_3_day6.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_4_day6) {
      editnumber_4_day6.addEventListener('keydown', enforceFormat);
      editnumber_4_day6.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_5_day6) {
      editnumber_5_day6.addEventListener('keydown', enforceFormat);
      editnumber_5_day6.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_6_day6) {
      editnumber_6_day6.addEventListener('keydown', enforceFormat);
      editnumber_6_day6.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_7_day6) {
      editnumber_7_day6.addEventListener('keydown', enforceFormat);
      editnumber_7_day6.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_8_day6) {
      editnumber_8_day6.addEventListener('keydown', enforceFormat);
      editnumber_8_day6.addEventListener('keyup', formatToPhone);
    }
    if (editnumber_9_day6) {
      editnumber_9_day6.addEventListener('keydown', enforceFormat);
      editnumber_9_day6.addEventListener('keyup', formatToPhone);
    }
  }
  validatename() {
    this.moduleService.validatename(this.addFSLRules.get('name').value).subscribe(res => {
      // console.log(res); return false;
      this.isName = res;
      if (this.isName.status == 'success') {
        this.isName = "success";
      } else {
        this.isName = "fail";
      }
      // console.log(this.isName); return false;
    }
    // }
    );
  }

  getAllRuleset() {
    this.moduleService.getRules(this.currentCompany.uuid).subscribe(res => {
      // console.log(res);
      this.allrules = res.rule_data;
    });
  }
  // gettimezone(){
  //   this.moduleService.gettimezone().subscribe(
  //     res => {
  //       this.alltimezone = res;
  //       // console.log(res);
  //     }
  //   );
  // }
  increment_hrs(index) {
    let val = this.editForm.get(index).value;
    if (this.is12or24 == 0) {
      if (val < 23) {
        let fianlval = Number(val) + 1;
        this.editForm.get(index).setValue(fianlval < 10 ? "0" + fianlval : fianlval);
      }
    } else {
      if (val < 12) {
        let fianlval = Number(val) + 1;
        this.editForm.get(index).setValue(fianlval < 10 ? "0" + fianlval : fianlval);
      }
    }
  }
  decrement_hrs(index) {
    let val = this.editForm.get(index).value;
    if (val > 0) {
      let fianlval = Number(val) - 1;
      this.editForm.get(index).setValue(fianlval < 10 ? "0" + fianlval : fianlval);
    }
  }
  increment_min(index) {
    let val = this.editForm.get(index).value;
    if (val < 59) {
      let fianlval = Number(val) + 1;
      this.editForm.get(index).setValue(fianlval < 10 ? "0" + fianlval : fianlval);
    }
  }
  decrement_min(index) {
    let val = this.editForm.get(index).value;
    if (val > 0) {
      let fianlval = Number(val) - 1;
      this.editForm.get(index).setValue(fianlval < 10 ? "0" + fianlval : fianlval);
    }
  }
  appm_change(index) {
    let val = this.editForm.get(index).value;
    if (val == 0) {
      this.editForm.get(index).setValue(1);
    } else {
      this.editForm.get(index).setValue(0);
    }
  }
  getdata() {
    this.moduleService.loadcity(this.editForm.get('citystate').value).subscribe(res => {
      //  console.log(res); return false;
      this.allcity = res;
    }, error => this.error = error);
  }
  getcitystate(type, datatype) {
    this.moduleService.loadcitystate(type, datatype).subscribe(res => {
      //  console.log(res); return false;
      this.allcitystate = res;
    }, error => this.error = error);
  }
  getAllpublishers() {
    let cc = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleService.getAllpublishers(cc.uuid).subscribe(res => {
      //  console.log(res); return false;
      this.allpublisher = res;
      this.allpublisherbkp = res;
    }, error => this.error = error);
  }
  getpubfiltertype(event) {
    console.log(event.target.value);
    let filterdata = [];
    if (event.target.value == 1) {
      this.allpublisherbkp.forEach(element => {
        let obj = {
          'id': element.id,
          'itemName': element.id,
          'text': element.itemName
        };
        filterdata.push(obj);
      });
    } else {
      this.allpublisherbkp.forEach(element => {
        let obj = {
          'id': element.id,
          'itemName': element.itemName,
          'text': element.itemName
        };
        filterdata.push(obj);
      });
    }
    this.allpublisher = filterdata;
  }
  addRow(e) {
    this.addkeyword.push(e);
  }
  removeRow(e) {
    this.addkeyword.pop(e);
  }
  ngOnInit() {
    // this.showLoadingIndicator= true;
    this.ngxLoader.startLoader('customLoaderId');
    this.settings = {
      enableSearchFilter: true,
      singleSelection: true,
      showCheckbox: false,
      text: "Select Buyer"
    };
    this.getAllpublishers();
    this.getcitystate(1, 1);
    this.getalldata();
    // this.getIVRMenu().then((res)=>{
    //   this.ivrmenus = res
    // });
    // this.getAllRules().then((res)=>{
    //   this.allBuyers = res
    // })
    this.addBuyerForm = this.fb.group({
      company: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required],
      email: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required],
      password: [''],
      sub_id: [''],
      allow_buyer_to_pause_target: [''],
      allow_buyer_to_set_target_concurrency: [''],
      allow_buyer_to_dispute_call_conversions: [''],
      limit_revenue: ['']
    });
    this.editForm = this.fb.group({
      name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required],
      subid: [''],
      buyer: [''],
      settingToggleBlockCallsIfCapped: [''],
      settingToggleType: [''],
      number: [''],
      ivrMenu: [''],
      sip_address: [''],
      voice_mail: [''],
      url: [''],
      http_method: [''],
      content_type: [''],
      body: [''],
      http_headers_name: [''],
      http_headers_value: [''],
      keyword0: [''],
      keyword1: [''],
      keyword2: [''],
      // start_hrs: [''],
      // start_min: [''],
      // end_hrs: [''],
      // end_min: [''],
      // timezone: [''],
      // hoursofoperation_start_1: [''],
      // hoursofoperation_end_1: [''],
      // start_hrs_1: [''],
      // start_min_1: [''],
      // end_hrs_1: [''],
      // end_min_1: [''],
      // timezone1: [''],
      hoursofoperation_start: ['Monday'],
      hoursofoperation_end: ['Sunday'],
      start_hrs: ['00'],
      start_min: ['01'],
      end_hrs: ['11'],
      end_min: ['59'],
      timezone: [],
      default_ampm: ['0'],
      default_ampm_close: ['1'],
      start_hrs_sunday: ['00'],
      start_min_sunday: ['01'],
      end_hrs_sunday: ['11'],
      end_min_sunday: ['59'],
      sunday_ampm: ['0'],
      sunday_ampm_close: ['1'],
      start_hrs_monday: ['00'],
      start_min_monday: ['01'],
      end_hrs_monday: ['11'],
      end_min_monday: ['59'],
      monday_ampm: ['0'],
      monday_ampm_close: ['1'],
      start_hrs_tuesday: ['00'],
      start_min_tuesday: ['01'],
      end_hrs_tuesday: ['11'],
      end_min_tuesday: ['59'],
      tuesday_ampm: ['0'],
      tuesday_ampm_close: ['1'],
      start_hrs_wednesday: ['00'],
      start_min_wednesday: ['01'],
      end_hrs_wednesday: ['11'],
      end_min_wednesday: ['59'],
      wednesday_ampm: ['0'],
      wednesday_ampm_close: ['1'],
      start_hrs_thursday: ['00'],
      start_min_thursday: ['11'],
      end_hrs_thursday: ['11'],
      end_min_thursday: ['59'],
      thursday_ampm: ['0'],
      thursday_ampm_close: ['1'],
      start_hrs_friday: ['00'],
      start_min_friday: ['01'],
      end_hrs_friday: ['11'],
      end_min_friday: ['59'],
      friday_ampm: ['0'],
      friday_ampm_close: ['1'],
      start_hrs_saturday: ['00'],
      start_min_saturday: ['01'],
      end_hrs_saturday: ['11'],
      end_min_saturday: ['59'],
      saturday_ampm: ['0'],
      saturday_ampm_close: ['1'],
      // timezone: ['',Validators.required],
      // hoursofoperation_start: [''],
      // hoursofoperation_end: [''],
      capon: [''],
      global_revenuecapvalue: [''],
      monthly_revenuecapvalue: [''],
      daily_revenuecapvalue: [''],
      hourly_revenuecapvalue: [''],
      global_capvalue: [''],
      monthly_capvalue: [''],
      daily_capvalue: [''],
      hourly_capvalue: [''],
      dtmf_value: [''],
      dtmf_interval: [''],
      dtmf_percent: [''],
      maxconvalue: [''],
      hourlyconcurrencyvalue: [''],
      restrictdup: [''],
      restrictafter: [''],
      days: [''],
      settingToggleDurationval: [''],
      settingToggleDuration: [''],
      isfilter: [''],
      citystate: [''],
      cityval: [''],
      citystatetype: [''],
      iscontains: [''],
      ispubfilter: [''],
      pubvalue: [''],
      pubfiltertype: ['0'],
      pubiscontains: ['0']
    });
    // this.editForm.patchValue({
    //   citystatetype:1,
    //   citystate:""
    // });
    this.addWeekDaysForm = this.fb.group({
      start_day: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required],
      end_day: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required]
    });
    this.editWeekDaysForm = this.fb.group({
      uuid: ['', ''],
      start_day: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required],
      end_day: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required]
    });
    this.addFSLRules = this.fb.group({
      name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required],
      numberoftimeframe: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required],
      noofforwardinglocation_1: ['', ''],
      noofforwardinglocation_2: ['', ''],
      noofforwardinglocation_3: ['', ''],
      noofforwardinglocation_4: ['', ''],
      noofforwardinglocation_5: ['', ''],
      noofforwardinglocation_6: ['', ''],
      noofforwardinglocation_7: ['', ''],
      // Day 1
      day_0: ['', ''],
      start_hrs_0: ['', ''],
      start_min_0: ['', ''],
      end_hrs_0: ['', ''],
      end_min_0: ['', ''],
      PrimaryforwardType_0_day0: ['', ''],
      number_0_day0: ['', ''],
      ivrMenu_0_day0: ['', ''],
      sipAdd_0_day0: ['', ''],
      PrimaryforwardType_1_day0: ['', ''],
      number_1_day0: ['', ''],
      ivrMenu_1_day0: ['', ''],
      sipAdd_1_day0: ['', ''],
      PrimaryforwardType_2_day0: ['', ''],
      number_2_day0: ['', ''],
      ivrMenu_2_day0: ['', ''],
      sipAdd_2_day0: ['', ''],
      PrimaryforwardType_3_day0: ['', ''],
      number_3_day0: ['', ''],
      ivrMenu_3_day0: ['', ''],
      sipAdd_3_day0: ['', ''],
      PrimaryforwardType_4_day0: ['', ''],
      number_4_day0: ['', ''],
      ivrMenu_4_day0: ['', ''],
      sipAdd_4_day0: ['', ''],
      PrimaryforwardType_5_day0: ['', ''],
      number_5_day0: ['', ''],
      ivrMenu_5_day0: ['', ''],
      sipAdd_5_day0: ['', ''],
      PrimaryforwardType_6_day0: ['', ''],
      number_6_day0: ['', ''],
      ivrMenu_6_day0: ['', ''],
      sipAdd_6_day0: ['', ''],
      PrimaryforwardType_7_day0: ['', ''],
      number_7_day0: ['', ''],
      ivrMenu_7_day0: ['', ''],
      sipAdd_7_day0: ['', ''],
      PrimaryforwardType_8_day0: ['', ''],
      number_8_day0: ['', ''],
      ivrMenu_8_day0: ['', ''],
      sipAdd_8_day0: ['', ''],
      PrimaryforwardType_9_day0: ['', ''],
      number_9_day0: ['', ''],
      ivrMenu_9_day0: ['', ''],
      sipAdd_9_day0: ['', ''],
      // Day2
      day_1: ['', ''],
      start_hrs_1: ['', ''],
      start_min_1: ['', ''],
      end_hrs_1: ['', ''],
      end_min_1: ['', ''],
      PrimaryforwardType_0_day1: ['', ''],
      number_0_day1: ['', ''],
      ivrMenu_0_day1: ['', ''],
      sipAdd_0_day1: ['', ''],
      PrimaryforwardType_1_day1: ['', ''],
      number_1_day1: ['', ''],
      ivrMenu_1_day1: ['', ''],
      sipAdd_1_day1: ['', ''],
      PrimaryforwardType_2_day1: ['', ''],
      number_2_day1: ['', ''],
      ivrMenu_2_day1: ['', ''],
      sipAdd_2_day1: ['', ''],
      PrimaryforwardType_3_day1: ['', ''],
      number_3_day1: ['', ''],
      ivrMenu_3_day1: ['', ''],
      sipAdd_3_day1: ['', ''],
      PrimaryforwardType_4_day1: ['', ''],
      number_4_day1: ['', ''],
      ivrMenu_4_day1: ['', ''],
      sipAdd_4_day1: ['', ''],
      PrimaryforwardType_5_day1: ['', ''],
      number_5_day1: ['', ''],
      ivrMenu_5_day1: ['', ''],
      sipAdd_5_day1: ['', ''],
      PrimaryforwardType_6_day1: ['', ''],
      number_6_day1: ['', ''],
      ivrMenu_6_day1: ['', ''],
      sipAdd_6_day1: ['', ''],
      PrimaryforwardType_7_day1: ['', ''],
      number_7_day1: ['', ''],
      ivrMenu_7_day1: ['', ''],
      sipAdd_7_day1: ['', ''],
      PrimaryforwardType_8_day1: ['', ''],
      number_8_day1: ['', ''],
      ivrMenu_8_day1: ['', ''],
      sipAdd_8_day1: ['', ''],
      PrimaryforwardType_9_day1: ['', ''],
      number_9_day1: ['', ''],
      ivrMenu_9_day1: ['', ''],
      sipAdd_9_day1: ['', ''],
      // Day3
      day_2: ['', ''],
      start_hrs_2: ['', ''],
      start_min_2: ['', ''],
      end_hrs_2: ['', ''],
      end_min_2: ['', ''],
      PrimaryforwardType_0_day2: ['', ''],
      number_0_day2: ['', ''],
      ivrMenu_0_day2: ['', ''],
      sipAdd_0_day2: ['', ''],
      PrimaryforwardType_1_day2: ['', ''],
      number_1_day2: ['', ''],
      ivrMenu_1_day2: ['', ''],
      sipAdd_1_day2: ['', ''],
      PrimaryforwardType_2_day2: ['', ''],
      number_2_day2: ['', ''],
      ivrMenu_2_day2: ['', ''],
      sipAdd_2_day2: ['', ''],
      PrimaryforwardType_3_day2: ['', ''],
      number_3_day2: ['', ''],
      ivrMenu_3_day2: ['', ''],
      sipAdd_3_day2: ['', ''],
      PrimaryforwardType_4_day2: ['', ''],
      number_4_day2: ['', ''],
      ivrMenu_4_day2: ['', ''],
      sipAdd_4_day2: ['', ''],
      PrimaryforwardType_5_day2: ['', ''],
      number_5_day2: ['', ''],
      ivrMenu_5_day2: ['', ''],
      sipAdd_5_day2: ['', ''],
      PrimaryforwardType_6_day2: ['', ''],
      number_6_day2: ['', ''],
      ivrMenu_6_day2: ['', ''],
      sipAdd_6_day2: ['', ''],
      PrimaryforwardType_7_day2: ['', ''],
      number_7_day2: ['', ''],
      ivrMenu_7_day2: ['', ''],
      sipAdd_7_day2: ['', ''],
      PrimaryforwardType_8_day2: ['', ''],
      number_8_day2: ['', ''],
      ivrMenu_8_day2: ['', ''],
      sipAdd_8_day2: ['', ''],
      PrimaryforwardType_9_day2: ['', ''],
      number_9_day2: ['', ''],
      ivrMenu_9_day2: ['', ''],
      sipAdd_9_day2: ['', ''],
      // Day4
      day_3: ['', ''],
      start_hrs_3: ['', ''],
      start_min_3: ['', ''],
      end_hrs_3: ['', ''],
      end_min_3: ['', ''],
      PrimaryforwardType_0_day3: ['', ''],
      number_0_day3: ['', ''],
      ivrMenu_0_day3: ['', ''],
      sipAdd_0_day3: ['', ''],
      PrimaryforwardType_1_day3: ['', ''],
      number_1_day3: ['', ''],
      ivrMenu_1_day3: ['', ''],
      sipAdd_1_day3: ['', ''],
      PrimaryforwardType_2_day3: ['', ''],
      number_2_day3: ['', ''],
      ivrMenu_2_day3: ['', ''],
      sipAdd_2_day3: ['', ''],
      PrimaryforwardType_3_day3: ['', ''],
      number_3_day3: ['', ''],
      ivrMenu_3_day3: ['', ''],
      sipAdd_3_day3: ['', ''],
      PrimaryforwardType_4_day3: ['', ''],
      number_4_day3: ['', ''],
      ivrMenu_4_day3: ['', ''],
      sipAdd_4_day3: ['', ''],
      PrimaryforwardType_5_day3: ['', ''],
      number_5_day3: ['', ''],
      ivrMenu_5_day3: ['', ''],
      sipAdd_5_day3: ['', ''],
      PrimaryforwardType_6_day3: ['', ''],
      number_6_day3: ['', ''],
      ivrMenu_6_day3: ['', ''],
      sipAdd_6_day3: ['', ''],
      PrimaryforwardType_7_day3: ['', ''],
      number_7_day3: ['', ''],
      ivrMenu_7_day3: ['', ''],
      sipAdd_7_day3: ['', ''],
      PrimaryforwardType_8_day3: ['', ''],
      number_8_day3: ['', ''],
      ivrMenu_8_day3: ['', ''],
      sipAdd_8_day3: ['', ''],
      PrimaryforwardType_9_day3: ['', ''],
      number_9_day3: ['', ''],
      ivrMenu_9_day3: ['', ''],
      sipAdd_9_day3: ['', ''],
      // Day5
      day_4: ['', ''],
      start_hrs_4: ['', ''],
      start_min_4: ['', ''],
      end_hrs_4: ['', ''],
      end_min_4: ['', ''],
      PrimaryforwardType_0_day4: ['', ''],
      number_0_day4: ['', ''],
      ivrMenu_0_day4: ['', ''],
      sipAdd_0_day4: ['', ''],
      PrimaryforwardType_1_day4: ['', ''],
      number_1_day4: ['', ''],
      ivrMenu_1_day4: ['', ''],
      sipAdd_1_day4: ['', ''],
      PrimaryforwardType_2_day4: ['', ''],
      number_2_day4: ['', ''],
      ivrMenu_2_day4: ['', ''],
      sipAdd_2_day4: ['', ''],
      PrimaryforwardType_3_day4: ['', ''],
      number_3_day4: ['', ''],
      ivrMenu_3_day4: ['', ''],
      sipAdd_3_day4: ['', ''],
      PrimaryforwardType_4_day4: ['', ''],
      number_4_day4: ['', ''],
      ivrMenu_4_day4: ['', ''],
      sipAdd_4_day4: ['', ''],
      PrimaryforwardType_5_day4: ['', ''],
      number_5_day4: ['', ''],
      ivrMenu_5_day4: ['', ''],
      sipAdd_5_day4: ['', ''],
      PrimaryforwardType_6_day4: ['', ''],
      number_6_day4: ['', ''],
      ivrMenu_6_day4: ['', ''],
      sipAdd_6_day4: ['', ''],
      PrimaryforwardType_7_day4: ['', ''],
      number_7_day4: ['', ''],
      ivrMenu_7_day4: ['', ''],
      sipAdd_7_day4: ['', ''],
      PrimaryforwardType_8_day4: ['', ''],
      number_8_day4: ['', ''],
      ivrMenu_8_day4: ['', ''],
      sipAdd_8_day4: ['', ''],
      PrimaryforwardType_9_day4: ['', ''],
      number_9_day4: ['', ''],
      ivrMenu_9_day4: ['', ''],
      sipAdd_9_day4: ['', ''],
      // Day6
      day_5: ['', ''],
      start_hrs_5: ['', ''],
      start_min_5: ['', ''],
      end_hrs_5: ['', ''],
      end_min_5: ['', ''],
      PrimaryforwardType_0_day5: ['', ''],
      number_0_day5: ['', ''],
      ivrMenu_0_day5: ['', ''],
      sipAdd_0_day5: ['', ''],
      PrimaryforwardType_1_day5: ['', ''],
      number_1_day5: ['', ''],
      ivrMenu_1_day5: ['', ''],
      sipAdd_1_day5: ['', ''],
      PrimaryforwardType_2_day5: ['', ''],
      number_2_day5: ['', ''],
      ivrMenu_2_day5: ['', ''],
      sipAdd_2_day5: ['', ''],
      PrimaryforwardType_3_day5: ['', ''],
      number_3_day5: ['', ''],
      ivrMenu_3_day5: ['', ''],
      sipAdd_3_day5: ['', ''],
      PrimaryforwardType_4_day5: ['', ''],
      number_4_day5: ['', ''],
      ivrMenu_4_day5: ['', ''],
      sipAdd_4_day5: ['', ''],
      PrimaryforwardType_5_day5: ['', ''],
      number_5_day5: ['', ''],
      ivrMenu_5_day5: ['', ''],
      sipAdd_5_day5: ['', ''],
      PrimaryforwardType_6_day5: ['', ''],
      number_6_day5: ['', ''],
      ivrMenu_6_day5: ['', ''],
      sipAdd_6_day5: ['', ''],
      PrimaryforwardType_7_day5: ['', ''],
      number_7_day5: ['', ''],
      ivrMenu_7_day5: ['', ''],
      sipAdd_7_day5: ['', ''],
      PrimaryforwardType_8_day5: ['', ''],
      number_8_day5: ['', ''],
      ivrMenu_8_day5: ['', ''],
      sipAdd_8_day5: ['', ''],
      PrimaryforwardType_9_day5: ['', ''],
      number_9_day5: ['', ''],
      ivrMenu_9_day5: ['', ''],
      sipAdd_9_day5: ['', ''],
      // Day7
      day_6: ['', ''],
      start_hrs_6: ['', ''],
      start_min_6: ['', ''],
      end_hrs_6: ['', ''],
      end_min_6: ['', ''],
      PrimaryforwardType_0_day6: ['', ''],
      number_0_day6: ['', ''],
      ivrMenu_0_day6: ['', ''],
      sipAdd_0_day6: ['', ''],
      PrimaryforwardType_1_day6: ['', ''],
      number_1_day6: ['', ''],
      ivrMenu_1_day6: ['', ''],
      sipAdd_1_day6: ['', ''],
      PrimaryforwardType_2_day6: ['', ''],
      number_2_day6: ['', ''],
      ivrMenu_2_day6: ['', ''],
      sipAdd_2_day6: ['', ''],
      PrimaryforwardType_3_day6: ['', ''],
      number_3_day6: ['', ''],
      ivrMenu_3_day6: ['', ''],
      sipAdd_3_day6: ['', ''],
      PrimaryforwardType_4_day6: ['', ''],
      number_4_day6: ['', ''],
      ivrMenu_4_day6: ['', ''],
      sipAdd_4_day6: ['', ''],
      PrimaryforwardType_5_day6: ['', ''],
      number_5_day6: ['', ''],
      ivrMenu_5_day6: ['', ''],
      sipAdd_5_day6: ['', ''],
      PrimaryforwardType_6_day6: ['', ''],
      number_6_day6: ['', ''],
      ivrMenu_6_day6: ['', ''],
      sipAdd_6_day6: ['', ''],
      PrimaryforwardType_7_day6: ['', ''],
      number_7_day6: ['', ''],
      ivrMenu_7_day6: ['', ''],
      sipAdd_7_day6: ['', ''],
      PrimaryforwardType_8_day6: ['', ''],
      number_8_day6: ['', ''],
      ivrMenu_8_day6: ['', ''],
      sipAdd_8_day6: ['', ''],
      PrimaryforwardType_9_day6: ['', ''],
      number_9_day6: ['', ''],
      ivrMenu_9_day6: ['', ''],
      sipAdd_9_day6: ['', '']
    });
    this.editFSLRules = this.fb.group({
      rulename: ['', ''],
      numberoftimeframe: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required],
      noofforwardinglocation_1: ['', ''],
      noofforwardinglocation_2: ['', ''],
      noofforwardinglocation_3: ['', ''],
      noofforwardinglocation_4: ['', ''],
      noofforwardinglocation_5: ['', ''],
      noofforwardinglocation_6: ['', ''],
      noofforwardinglocation_7: ['', ''],
      // Day 1
      day_0: ['', ''],
      start_hrs_0: ['', ''],
      start_min_0: ['', ''],
      end_hrs_0: ['', ''],
      end_min_0: ['', ''],
      PrimaryforwardType_0_day0: ['', ''],
      number_0_day0: ['', ''],
      ivrMenu_0_day0: ['', ''],
      sipAdd_0_day0: ['', ''],
      PrimaryforwardType_1_day0: ['', ''],
      number_1_day0: ['', ''],
      ivrMenu_1_day0: ['', ''],
      sipAdd_1_day0: ['', ''],
      PrimaryforwardType_2_day0: ['', ''],
      number_2_day0: ['', ''],
      ivrMenu_2_day0: ['', ''],
      sipAdd_2_day0: ['', ''],
      PrimaryforwardType_3_day0: ['', ''],
      number_3_day0: ['', ''],
      ivrMenu_3_day0: ['', ''],
      sipAdd_3_day0: ['', ''],
      PrimaryforwardType_4_day0: ['', ''],
      number_4_day0: ['', ''],
      ivrMenu_4_day0: ['', ''],
      sipAdd_4_day0: ['', ''],
      PrimaryforwardType_5_day0: ['', ''],
      number_5_day0: ['', ''],
      ivrMenu_5_day0: ['', ''],
      sipAdd_5_day0: ['', ''],
      PrimaryforwardType_6_day0: ['', ''],
      number_6_day0: ['', ''],
      ivrMenu_6_day0: ['', ''],
      sipAdd_6_day0: ['', ''],
      PrimaryforwardType_7_day0: ['', ''],
      number_7_day0: ['', ''],
      ivrMenu_7_day0: ['', ''],
      sipAdd_7_day0: ['', ''],
      PrimaryforwardType_8_day0: ['', ''],
      number_8_day0: ['', ''],
      ivrMenu_8_day0: ['', ''],
      sipAdd_8_day0: ['', ''],
      PrimaryforwardType_9_day0: ['', ''],
      number_9_day0: ['', ''],
      ivrMenu_9_day0: ['', ''],
      sipAdd_9_day0: ['', ''],
      // Day2
      day_1: ['', ''],
      start_hrs_1: ['', ''],
      start_min_1: ['', ''],
      end_hrs_1: ['', ''],
      end_min_1: ['', ''],
      PrimaryforwardType_0_day1: ['', ''],
      number_0_day1: ['', ''],
      ivrMenu_0_day1: ['', ''],
      sipAdd_0_day1: ['', ''],
      PrimaryforwardType_1_day1: ['', ''],
      number_1_day1: ['', ''],
      ivrMenu_1_day1: ['', ''],
      sipAdd_1_day1: ['', ''],
      PrimaryforwardType_2_day1: ['', ''],
      number_2_day1: ['', ''],
      ivrMenu_2_day1: ['', ''],
      sipAdd_2_day1: ['', ''],
      PrimaryforwardType_3_day1: ['', ''],
      number_3_day1: ['', ''],
      ivrMenu_3_day1: ['', ''],
      sipAdd_3_day1: ['', ''],
      PrimaryforwardType_4_day1: ['', ''],
      number_4_day1: ['', ''],
      ivrMenu_4_day1: ['', ''],
      sipAdd_4_day1: ['', ''],
      PrimaryforwardType_5_day1: ['', ''],
      number_5_day1: ['', ''],
      ivrMenu_5_day1: ['', ''],
      sipAdd_5_day1: ['', ''],
      PrimaryforwardType_6_day1: ['', ''],
      number_6_day1: ['', ''],
      ivrMenu_6_day1: ['', ''],
      sipAdd_6_day1: ['', ''],
      PrimaryforwardType_7_day1: ['', ''],
      number_7_day1: ['', ''],
      ivrMenu_7_day1: ['', ''],
      sipAdd_7_day1: ['', ''],
      PrimaryforwardType_8_day1: ['', ''],
      number_8_day1: ['', ''],
      ivrMenu_8_day1: ['', ''],
      sipAdd_8_day1: ['', ''],
      PrimaryforwardType_9_day1: ['', ''],
      number_9_day1: ['', ''],
      ivrMenu_9_day1: ['', ''],
      sipAdd_9_day1: ['', ''],
      // Day3
      day_2: ['', ''],
      start_hrs_2: ['', ''],
      start_min_2: ['', ''],
      end_hrs_2: ['', ''],
      end_min_2: ['', ''],
      PrimaryforwardType_0_day2: ['', ''],
      number_0_day2: ['', ''],
      ivrMenu_0_day2: ['', ''],
      sipAdd_0_day2: ['', ''],
      PrimaryforwardType_1_day2: ['', ''],
      number_1_day2: ['', ''],
      ivrMenu_1_day2: ['', ''],
      sipAdd_1_day2: ['', ''],
      PrimaryforwardType_2_day2: ['', ''],
      number_2_day2: ['', ''],
      ivrMenu_2_day2: ['', ''],
      sipAdd_2_day2: ['', ''],
      PrimaryforwardType_3_day2: ['', ''],
      number_3_day2: ['', ''],
      ivrMenu_3_day2: ['', ''],
      sipAdd_3_day2: ['', ''],
      PrimaryforwardType_4_day2: ['', ''],
      number_4_day2: ['', ''],
      ivrMenu_4_day2: ['', ''],
      sipAdd_4_day2: ['', ''],
      PrimaryforwardType_5_day2: ['', ''],
      number_5_day2: ['', ''],
      ivrMenu_5_day2: ['', ''],
      sipAdd_5_day2: ['', ''],
      PrimaryforwardType_6_day2: ['', ''],
      number_6_day2: ['', ''],
      ivrMenu_6_day2: ['', ''],
      sipAdd_6_day2: ['', ''],
      PrimaryforwardType_7_day2: ['', ''],
      number_7_day2: ['', ''],
      ivrMenu_7_day2: ['', ''],
      sipAdd_7_day2: ['', ''],
      PrimaryforwardType_8_day2: ['', ''],
      number_8_day2: ['', ''],
      ivrMenu_8_day2: ['', ''],
      sipAdd_8_day2: ['', ''],
      PrimaryforwardType_9_day2: ['', ''],
      number_9_day2: ['', ''],
      ivrMenu_9_day2: ['', ''],
      sipAdd_9_day2: ['', ''],
      // Day4
      day_3: ['', ''],
      start_hrs_3: ['', ''],
      start_min_3: ['', ''],
      end_hrs_3: ['', ''],
      end_min_3: ['', ''],
      PrimaryforwardType_0_day3: ['', ''],
      number_0_day3: ['', ''],
      ivrMenu_0_day3: ['', ''],
      sipAdd_0_day3: ['', ''],
      PrimaryforwardType_1_day3: ['', ''],
      number_1_day3: ['', ''],
      ivrMenu_1_day3: ['', ''],
      sipAdd_1_day3: ['', ''],
      PrimaryforwardType_2_day3: ['', ''],
      number_2_day3: ['', ''],
      ivrMenu_2_day3: ['', ''],
      sipAdd_2_day3: ['', ''],
      PrimaryforwardType_3_day3: ['', ''],
      number_3_day3: ['', ''],
      ivrMenu_3_day3: ['', ''],
      sipAdd_3_day3: ['', ''],
      PrimaryforwardType_4_day3: ['', ''],
      number_4_day3: ['', ''],
      ivrMenu_4_day3: ['', ''],
      sipAdd_4_day3: ['', ''],
      PrimaryforwardType_5_day3: ['', ''],
      number_5_day3: ['', ''],
      ivrMenu_5_day3: ['', ''],
      sipAdd_5_day3: ['', ''],
      PrimaryforwardType_6_day3: ['', ''],
      number_6_day3: ['', ''],
      ivrMenu_6_day3: ['', ''],
      sipAdd_6_day3: ['', ''],
      PrimaryforwardType_7_day3: ['', ''],
      number_7_day3: ['', ''],
      ivrMenu_7_day3: ['', ''],
      sipAdd_7_day3: ['', ''],
      PrimaryforwardType_8_day3: ['', ''],
      number_8_day3: ['', ''],
      ivrMenu_8_day3: ['', ''],
      sipAdd_8_day3: ['', ''],
      PrimaryforwardType_9_day3: ['', ''],
      number_9_day3: ['', ''],
      ivrMenu_9_day3: ['', ''],
      sipAdd_9_day3: ['', ''],
      // Day5
      day_4: ['', ''],
      start_hrs_4: ['', ''],
      start_min_4: ['', ''],
      end_hrs_4: ['', ''],
      end_min_4: ['', ''],
      PrimaryforwardType_0_day4: ['', ''],
      number_0_day4: ['', ''],
      ivrMenu_0_day4: ['', ''],
      sipAdd_0_day4: ['', ''],
      PrimaryforwardType_1_day4: ['', ''],
      number_1_day4: ['', ''],
      ivrMenu_1_day4: ['', ''],
      sipAdd_1_day4: ['', ''],
      PrimaryforwardType_2_day4: ['', ''],
      number_2_day4: ['', ''],
      ivrMenu_2_day4: ['', ''],
      sipAdd_2_day4: ['', ''],
      PrimaryforwardType_3_day4: ['', ''],
      number_3_day4: ['', ''],
      ivrMenu_3_day4: ['', ''],
      sipAdd_3_day4: ['', ''],
      PrimaryforwardType_4_day4: ['', ''],
      number_4_day4: ['', ''],
      ivrMenu_4_day4: ['', ''],
      sipAdd_4_day4: ['', ''],
      PrimaryforwardType_5_day4: ['', ''],
      number_5_day4: ['', ''],
      ivrMenu_5_day4: ['', ''],
      sipAdd_5_day4: ['', ''],
      PrimaryforwardType_6_day4: ['', ''],
      number_6_day4: ['', ''],
      ivrMenu_6_day4: ['', ''],
      sipAdd_6_day4: ['', ''],
      PrimaryforwardType_7_day4: ['', ''],
      number_7_day4: ['', ''],
      ivrMenu_7_day4: ['', ''],
      sipAdd_7_day4: ['', ''],
      PrimaryforwardType_8_day4: ['', ''],
      number_8_day4: ['', ''],
      ivrMenu_8_day4: ['', ''],
      sipAdd_8_day4: ['', ''],
      PrimaryforwardType_9_day4: ['', ''],
      number_9_day4: ['', ''],
      ivrMenu_9_day4: ['', ''],
      sipAdd_9_day4: ['', ''],
      // Day6
      day_5: ['', ''],
      start_hrs_5: ['', ''],
      start_min_5: ['', ''],
      end_hrs_5: ['', ''],
      end_min_5: ['', ''],
      PrimaryforwardType_0_day5: ['', ''],
      number_0_day5: ['', ''],
      ivrMenu_0_day5: ['', ''],
      sipAdd_0_day5: ['', ''],
      PrimaryforwardType_1_day5: ['', ''],
      number_1_day5: ['', ''],
      ivrMenu_1_day5: ['', ''],
      sipAdd_1_day5: ['', ''],
      PrimaryforwardType_2_day5: ['', ''],
      number_2_day5: ['', ''],
      ivrMenu_2_day5: ['', ''],
      sipAdd_2_day5: ['', ''],
      PrimaryforwardType_3_day5: ['', ''],
      number_3_day5: ['', ''],
      ivrMenu_3_day5: ['', ''],
      sipAdd_3_day5: ['', ''],
      PrimaryforwardType_4_day5: ['', ''],
      number_4_day5: ['', ''],
      ivrMenu_4_day5: ['', ''],
      sipAdd_4_day5: ['', ''],
      PrimaryforwardType_5_day5: ['', ''],
      number_5_day5: ['', ''],
      ivrMenu_5_day5: ['', ''],
      sipAdd_5_day5: ['', ''],
      PrimaryforwardType_6_day5: ['', ''],
      number_6_day5: ['', ''],
      ivrMenu_6_day5: ['', ''],
      sipAdd_6_day5: ['', ''],
      PrimaryforwardType_7_day5: ['', ''],
      number_7_day5: ['', ''],
      ivrMenu_7_day5: ['', ''],
      sipAdd_7_day5: ['', ''],
      PrimaryforwardType_8_day5: ['', ''],
      number_8_day5: ['', ''],
      ivrMenu_8_day5: ['', ''],
      sipAdd_8_day5: ['', ''],
      PrimaryforwardType_9_day5: ['', ''],
      number_9_day5: ['', ''],
      ivrMenu_9_day5: ['', ''],
      sipAdd_9_day5: ['', ''],
      // Day7
      day_6: ['', ''],
      start_hrs_6: ['', ''],
      start_min_6: ['', ''],
      end_hrs_6: ['', ''],
      end_min_6: ['', ''],
      PrimaryforwardType_0_day6: ['', ''],
      number_0_day6: ['', ''],
      ivrMenu_0_day6: ['', ''],
      sipAdd_0_day6: ['', ''],
      PrimaryforwardType_1_day6: ['', ''],
      number_1_day6: ['', ''],
      ivrMenu_1_day6: ['', ''],
      sipAdd_1_day6: ['', ''],
      PrimaryforwardType_2_day6: ['', ''],
      number_2_day6: ['', ''],
      ivrMenu_2_day6: ['', ''],
      sipAdd_2_day6: ['', ''],
      PrimaryforwardType_3_day6: ['', ''],
      number_3_day6: ['', ''],
      ivrMenu_3_day6: ['', ''],
      sipAdd_3_day6: ['', ''],
      PrimaryforwardType_4_day6: ['', ''],
      number_4_day6: ['', ''],
      ivrMenu_4_day6: ['', ''],
      sipAdd_4_day6: ['', ''],
      PrimaryforwardType_5_day6: ['', ''],
      number_5_day6: ['', ''],
      ivrMenu_5_day6: ['', ''],
      sipAdd_5_day6: ['', ''],
      PrimaryforwardType_6_day6: ['', ''],
      number_6_day6: ['', ''],
      ivrMenu_6_day6: ['', ''],
      sipAdd_6_day6: ['', ''],
      PrimaryforwardType_7_day6: ['', ''],
      number_7_day6: ['', ''],
      ivrMenu_7_day6: ['', ''],
      sipAdd_7_day6: ['', ''],
      PrimaryforwardType_8_day6: ['', ''],
      number_8_day6: ['', ''],
      ivrMenu_8_day6: ['', ''],
      sipAdd_8_day6: ['', ''],
      PrimaryforwardType_9_day6: ['', ''],
      number_9_day6: ['', ''],
      ivrMenu_9_day6: ['', ''],
      sipAdd_9_day6: ['', '']
    });
    this.showLoadingIndicator = false;
    this.dropdownSettings = {
      singleSelection: false,
      text: "Select Associated Label",
      selectAllText: 'Select All',
      unSelectAllText: 'UnSelect All',
      enableSearchFilter: true,
      classes: "myclass custom-class"
    };
    this.ivrdropdownSettings = {
      singleSelection: true,
      text: "Select IVR Menu",
      selectAllText: 'Select All',
      unSelectAllText: 'UnSelect All',
      enableSearchFilter: true,
      classes: "myclass custom-class"
    };
    // this.getAllLabels();
    this.pageTitle = 'Edit Target';
  }
  isfilterselect() {
    this.isfilter = 1;
    this.editForm.get('isfilter').setValue(this.isfilter);
  }
  isfilterclear() {
    this.isfilter = 0;
    this.editForm.get('citystatetype').setValue(1);
    this.editForm.get('citystate').setValue('');
    this.editForm.get('cityval').setValue('');
  }
  ispubfilterselect() {
    this.ispubfilter = 1;
    this.editForm.get('ispubfilter').setValue(this.ispubfilter);
  }
  ispubfilterclear() {
    this.filterselected = [];
    this.ispubfilter = 0;
    this.editForm.get('ispubfilter').setValue(0);
    this.editForm.get('pubiscontains').setValue(0);
    this.editForm.get('pubvalue').setValue('');
  }
  addorrule() {
    let typeval = this.editForm.get('pubiscontains').value;
    let typetext;
    if (typeval == 0) {
      typetext = "Equals Single Value";
    } else if (typeval == 1) {
      typetext = "Does Not Equal Single Value";
    } else if (typeval == 2) {
      typetext = "Contains";
    } else if (typeval == 3) {
      typetext = "Does Not contain";
    } else if (typeval == 4) {
      typetext = "Begins With";
    } else {
      typetext = "Does Not Begin With";
    }
    let customObj = new filterarr();
    customObj.filteradvanced = typeval;
    customObj.filterlabel = typetext;
    if (this.editForm.get('pubfiltertype').value == 1) {
      customObj.filtertype = 1;
      customObj.containfiltertext = 'Publisher';
    }
    if (this.editForm.get('pubfiltertype').value == 2) {
      customObj.filtertype = 2;
      customObj.containfiltertext = 'Zipcode';
    }
    customObj.containfiltertype = this.editForm.get('pubfiltertype').value;
    let itemname;
    let itemuuid;
    if (typeval == 0 || typeval == 1) {
      if (this.editForm.get('pubvalue').value != undefined && this.editForm.get('pubvalue').value != '') {
        itemuuid = this.editForm.get('pubvalue').value[0]['id'];
        itemname = this.editForm.get('pubvalue').value[0]['itemName'];
      } else {
        itemname = "";
        itemuuid = "";
      }
    } else {
      itemname = this.editForm.get('pubvalue').value;
      itemuuid = "";
    }
    // console.log(this.editForm.get('pubvalue').value);
    // console.log(itemname); return
    if (itemname == "") return;
    customObj.uuid = itemuuid;
    customObj.name = itemname;
    customObj.isorand = 0;
    if (itemname != undefined) {
      this.filterselected.push(customObj);
    }
    // console.log(this.filterselected);
  }

  addandrule() {
    let typeval = this.editForm.get('pubiscontains').value;
    let typetext;
    if (typeval == 0) {
      typetext = "Equals Single Value";
    } else if (typeval == 1) {
      typetext = "Does Not Equal Single Value";
    } else if (typeval == 2) {
      typetext = "Contains";
    } else if (typeval == 3) {
      typetext = "Does Not contain";
    } else if (typeval == 4) {
      typetext = "Begins With";
    } else {
      typetext = "Does Not Begin With";
    }
    let customObj = new filterarr();
    customObj.filteradvanced = typeval;
    customObj.filterlabel = typetext;
    if (this.editForm.get('pubfiltertype').value == 1) {
      customObj.filtertype = 1;
      customObj.containfiltertext = 'Publisher';
    }
    if (this.editForm.get('pubfiltertype').value == 2) {
      customObj.filtertype = 2;
      customObj.containfiltertext = 'Zipcode';
    }
    customObj.containfiltertype = this.editForm.get('pubfiltertype').value;
    let itemname;
    let itemuuid;
    if (typeval == 0 || typeval == 1) {
      if (this.editForm.get('pubvalue').value != undefined && this.editForm.get('pubvalue').value != '') {
        itemuuid = this.editForm.get('pubvalue').value[0]['id'];
        itemname = this.editForm.get('pubvalue').value[0]['itemName'];
      } else {
        itemname = "";
        itemuuid = "";
      }
    } else {
      itemname = this.editForm.get('pubvalue').value;
      itemuuid = "";
    }
    if (itemname == "") return;
    customObj.uuid = itemuuid;
    customObj.name = itemname;
    customObj.isorand = 1;
    if (itemname != undefined) {
      this.filterselected.push(customObj);
    }
  }
  getallbuyers() {
    this.moduleService.getallbuyers(this.currentCompany.uuid).subscribe(result => {
      if (result.length > 0) {
        let text = result.filter(x => x.itemName == this.company)[0];
        if (text != undefined) {
          this.selectedItemsBuyer1 = [{
            "id": text.id,
            "itemName": text.text
          }];
        }
      }
      this.allBuyers = result;
    }, error => this.error = error);
  }
  getallzipcode(uuid) {
    this.moduleService.getallzipcode(this.currentCompany.uuid, uuid).subscribe(result => {
      if (result.length > 0) {
        this.allzipcode = result;
        let text = this.allzipcode.filter(x => x.name == this.filename)[0];
        console.log(text);
        if (text != undefined) {
          //   this.selectedItemsZip = [{"uuid":text.id,"ItemName":text.itemName}];
          this.selectedItemsZip = [{
            "id": text.id,
            "itemName": text.itemName
          }];
        }
      }
      // console.log(this.selectedItemsZip);
    }, error => this.error = error);
  }
  changetype(event) {
    // console.log(event.target.value);
    this.editForm.get('citystatetype').setValue(event.target.value);
  }
  getalldata() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    const p1 = new Promise((res, rej) => {
      this.moduleService.getIVRMenus(this.currentCompany.uuid).subscribe(result => {
        res(result);
      }, error => this.error = error);
    });
    const p2 = new Promise((res, rej) => {
      this.moduleService.getallbuyers(this.currentCompany.uuid).subscribe(result => {
        res(result);
      }, error => this.error = error);
    });
    const p3 = new Promise((res, rej) => {
      this.moduleService.gettimezone().subscribe(result => {
        res(result);
      }, error => this.error = error);
    });
    const p4 = new Promise((res, rej) => {
      const uuid = this.route.snapshot.paramMap.get('id');
      this.moduleService.getallzipcode(this.currentCompany.uuid, uuid).subscribe(result => {
        res(result);
      }, error => this.error = error);
    });
    const prm = [p1, p2, p3, p4];
    Promise.all(prm).then(results => {
      this.allBuyers = results[1];
      this.ivrmenus = results[0];
      this.alltimezone = results[2];
      this.allzipcode = results[3];
      // console.log(this.ivrmenus);return
      const uuid = this.route.snapshot.paramMap.get('id');
      this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
      if (uuid) {
        this.moduleService.getTargetdata(uuid, this.currentCompany.uuid).subscribe(res => {
          if (this.currentCompany.uuid != res[0].company_uuid) {
            sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire({
              title: 'Error!',
              html: 'This target is assigned to another company.',
              icon: 'warning',
              timer: 2000
            });
            this.router.navigate(['/target']);
          }
          this.setTitle(res[0].name + ' | Target');
          if (res[0].buyer_id != "" && res[0].buyer_id != undefined && res[0].buyer_id.length > 0) {
            let text = this.allBuyers.filter(x => x.id == res[0].buyer_id)[0];
            if (text != undefined) {
              this.selectedItemsBuyer1 = [{
                "id": res[0].buyer_id,
                "itemName": text.text
              }];
            }
          }
          this.selectedItems = res[0].assosciated_labels;
          if (res[0].max_concurrency == 1) {
            this.maxconcurrency = true;
          } else {
            this.maxconcurrency = false;
          }
          if (res[0].global_revenuecap == 1) {
            this.global_revenuecap = true;
          } else {
            this.global_revenuecap = false;
          }
          if (res[0].is_autodtmf == 1) {
            this.dtmf_auto = true;
          } else {
            this.dtmf_auto = false;
          }
          if (res[0].dtmf_zipcode_enable == 1) {
            this.dtmf_zipcode_enable = true;
          } else {
            this.dtmf_zipcode_enable = false;
          }
          if (res[0].monthly_revenuecap == 1) {
            this.monthly_revenuecap = true;
          } else {
            this.monthly_revenuecap = false;
          }
          if (res[0].daily_revenuecap == 1) {
            this.daily_revenuecap = true;
          } else {
            this.daily_revenuecap = false;
          }
          if (res[0].hourly_revenuecap == 1) {
            this.hourly_revenuecap = true;
          } else {
            this.hourly_revenuecap = false;
          }
          if (res[0].disableRecordings == 1) {
            this.disableRecordings = true;
          } else {
            this.disableRecordings = false;
          }
          this.advanced = res[0].isadded == 1 ? 'Advanced' : "Basic";
          this.is12or24 = res[0].is12or24;
          if (res[0].is_ringtree == 1) {
            this.ringtreetext = "Ringtree";
            this.ringtree = true;
            if (res[0].keywordlength == 1) {
              this.addkeyword = [0];
            }
            if (res[0].keywordlength == 2) {
              this.addkeyword = [0, 1];
            }
            if (res[0].keywordlength == 3) {
              this.addkeyword = [0, 1, 2];
            }
          } else {
            this.ringtreetext = "Simple";
            this.ringtree = false;
          }
          var days = res[0].hoursofoperationdays.split('=');
          var days_1 = res[0].hoursofoperationdays_1.split('=');
          this.settingToggleTypeval = res[0].settingToggleType;
          this.editForm.get('settingToggleType').setValue(res[0].settingToggleType);
          let starttimearray;
          let endtimearray;
          let defaultsampm = "0";
          let defaulteampm = "1";
          if (res[0].is12or24 == 1) {
            let time1 = this.convert12hrs(res[0].start_time).substring(0, 2);
            let time2 = this.convert12hrs(res[0].start_time).substring(3, 5);
            let sampmval = this.convert12hrs(res[0].start_time).substring(6, 8);
            if (sampmval == 'AM') {
              defaultsampm = "0";
            } else {
              defaultsampm = "1";
            }
            starttimearray = [time1, time2];
            let etime1 = this.convert12hrs(res[0].end_time).substring(0, 2);
            let etime2 = this.convert12hrs(res[0].end_time).substring(3, 5);
            let eampmval = this.convert12hrs(res[0].end_time).substring(6, 8);
            if (eampmval == 'AM') {
              defaulteampm = "0";
            } else {
              defaulteampm = "1";
            }
            endtimearray = [etime1, etime2];
          } else {
            starttimearray = res[0].start_time.split(':');
            endtimearray = res[0].end_time.split(':');
          }
          var starttimearray_1 = res[0].start_time_1.split(':');
          var endtimearray_1 = res[0].end_time_1.split(':');
          this.isadded = res[0].isadded;
          // console.log(res[0].ivrmenu_uuid);
          // console.log('ok');
          if (res[0].ivrmenu_arr != "") {
            let text = this.ivrmenus.filter(x => x.uuid == JSON.parse(res[0].ivrmenu_arr)[0]['uuid'])[0];
            if (text != undefined) {
              this.selected_ivr = [{
                "uuid": text.uuid,
                "id": text.id,
                "itemName": text.name
              }];
            }
            // console.log(JSON.parse(res[0].ivrmenu_arr));
            // this.editForm.patchValue({
            //   ivrMenu: JSON.parse(res[0].ivrmenu_arr)[0]['uuid'],
            // });
          }

          let http_headers_name;
          let http_headers_value;
          if (res[0].http_headers) {
            let header = JSON.parse(res[0].http_headers);
            if (header) {
              for (var key in header) {
                http_headers_name = key;
                http_headers_value = header[key];
              }
            }
          }
          this.methodtypeval = res[0].http_method;
          this.timeonehrs = starttimearray[0];
          this.timeonemin = starttimearray[1];
          this.timetwohrs = endtimearray[0];
          this.timetwomin = endtimearray[1];
          this.timeonehrs1 = starttimearray_1[0];
          this.timeonemin1 = starttimearray_1[1];
          this.timetwohrs1 = endtimearray_1[0];
          this.timetwomin1 = endtimearray_1[1];
          this.globalcap = res[0].global_cap;
          this.monthlycap = res[0].monthly_cap;
          this.dailycap = res[0].daily_cap;
          this.hourlycap = res[0].hourly_cap;
          if (res[0].isadded == 1) {
            // this.hof_alwaysopen = true;
            this.isadvanced = 1;
          }
          if (res[0].isadded == 0) {
            // this.hof_alwaysopen = true;
            this.isadvanced = 0;
          }
          if (res[0].hof_alwaysopen == 1) {
            this.hof_alwaysopen = true;
          }
          if (res[0].hof_alwaysopen == 2) {
            this.hof_alwaysopen = true;
          }
          if (res[0].jsondata && JSON.parse(res[0].jsondata).length > 0) {
            this.ispubfilter = 1;
            this.filterselected = JSON.parse(res[0].jsondata);
          }
          if (res[0].hrsofopedata.length > 0) {
            res[0].hrsofopedata.forEach((element, i) => {
              let stime;
              let etime;
              let sampm = "0";
              let eampm = "1";
              if (res[0].is12or24 == 1) {
                let time1 = this.convert12hrs(element.open_time).substring(0, 2);
                let time2 = this.convert12hrs(element.open_time).substring(3, 5);
                let sampmval = this.convert12hrs(element.open_time).substring(6, 8);
                if (sampmval == 'AM') {
                  sampm = "0";
                } else {
                  sampm = "1";
                }
                stime = [time1, time2];
                let etime1 = this.convert12hrs(element.close_time).substring(0, 2);
                let etime2 = this.convert12hrs(element.close_time).substring(3, 5);
                let eampmval = this.convert12hrs(element.close_time).substring(6, 8);
                if (eampmval == 'AM') {
                  eampm = "0";
                } else {
                  eampm = "1";
                }
                etime = [etime1, etime2];
              } else {
                stime = element.open_time.split(":");
                etime = element.close_time.split(":");
              }
              if (element.day == "Sunday") {
                this.sundayopen = Number(element.is_open);
                this.editForm.patchValue({
                  start_hrs_sunday: stime[0],
                  start_min_sunday: stime[1],
                  end_hrs_sunday: etime[0],
                  end_min_sunday: etime[1],
                  sunday_ampm: sampm,
                  sunday_ampm_close: eampm
                });
              }
              if (element.day == "Monday") {
                this.mondayopen = Number(element.is_open);
                // const stime = element.open_time.split(":");
                // const etime = element.close_time.split(":");
                this.editForm.patchValue({
                  start_hrs_monday: stime[0],
                  start_min_monday: stime[1],
                  end_hrs_monday: etime[0],
                  end_min_monday: etime[1],
                  monday_ampm: sampm,
                  monday_ampm_close: eampm
                });
              }
              if (element.day == "Tuesday") {
                this.tuesdayopen = Number(element.is_open);
                // const stime = element.open_time.split(":");
                // const etime = element.close_time.split(":");
                this.editForm.patchValue({
                  start_hrs_tuesday: stime[0],
                  start_min_tuesday: stime[1],
                  end_hrs_tuesday: etime[0],
                  end_min_tuesday: etime[1],
                  tuesday_ampm: sampm,
                  tuesday_ampm_close: eampm
                });
              }
              if (element.day == "Wednesday") {
                this.wednesdayopen = Number(element.is_open);
                // const stime = element.open_time.split(":");
                // const etime = element.close_time.split(":");
                this.editForm.patchValue({
                  start_hrs_wednesday: stime[0],
                  start_min_wednesday: stime[1],
                  end_hrs_wednesday: etime[0],
                  end_min_wednesday: etime[1],
                  wednesday_ampm: sampm,
                  wednesday_ampm_close: eampm
                });
              }
              if (element.day == "Thursday") {
                this.thursdayopen = Number(element.is_open);
                // const stime = element.open_time.split(":");
                // const etime = element.close_time.split(":");
                this.editForm.patchValue({
                  start_hrs_thursday: stime[0],
                  start_min_thursday: stime[1],
                  end_hrs_thursday: etime[0],
                  end_min_thursday: etime[1],
                  thursday_ampm: sampm,
                  thursday_ampm_close: eampm
                });
              }
              if (element.day == "Friday") {
                this.fridayopen = Number(element.is_open);
                // const stime = element.open_time.split(":");
                // const etime = element.close_time.split(":");
                this.editForm.patchValue({
                  start_hrs_friday: stime[0],
                  start_min_friday: stime[1],
                  end_hrs_friday: etime[0],
                  end_min_friday: etime[1],
                  friday_ampm: sampm,
                  friday_ampm_close: eampm
                });
              }
              if (element.day == "Saturday") {
                this.saturdayopen = Number(element.is_open);
                // const stime = element.open_time.split(":");
                // const etime = element.close_time.split(":");
                this.editForm.patchValue({
                  start_hrs_saturday: stime[0],
                  start_min_saturday: stime[1],
                  end_hrs_saturday: etime[0],
                  end_min_saturday: etime[1],
                  saturday_ampm: sampm,
                  saturday_ampm_close: eampm
                });
              }
            });
          }
          // console.log(res[0]);
          let text = this.alltimezone.filter(x => x.id == res[0].timezone)[0];
          if (text != undefined) {
            this.timezoneval = [{
              "id": text.id,
              "itemName": text.text
            }];
          }
          this.editForm.patchValue({
            name: res[0].name,
            subid: res[0].subid,
            // buyer: res[0].buyer_id,
            number: res[0].number,
            // ivrMenu: JSON.parse(res[0].ivrmenu_arr),
            sip_address: res[0].sip_address,
            voice_mail: res[0].voice_mail,
            hoursofoperation_start: days[0],
            hoursofoperation_end: days[1],
            start_hrs: starttimearray[0],
            start_min: starttimearray[1],
            end_hrs: endtimearray[0],
            end_min: endtimearray[1],
            default_ampm: defaultsampm,
            default_ampm_close: defaulteampm,
            url: res[0].url,
            http_method: res[0].http_method,
            content_type: res[0].content_type,
            body: res[0].body,
            http_headers_name: http_headers_name,
            http_headers_value: http_headers_value,
            keyword0: res[0].keyword1,
            keyword1: res[0].keyword2,
            keyword2: res[0].keyword3,
            hoursofoperation_start_1: days_1[0],
            hoursofoperation_end_1: days_1[1],
            start_hrs_1: starttimearray_1[0],
            start_min_1: starttimearray_1[1],
            end_hrs_1: endtimearray_1[0],
            end_min_1: endtimearray_1[1],
            dtmf_value: res[0].dtmf_value,
            dtmf_interval: res[0].dtmf_interval,
            dtmf_percent: res[0].dtmf_percent,
            capon: res[0].capon,
            global_capvalue: res[0].global_capvalue,
            global_revenuecapvalue: res[0].global_revenuecapvalue,
            monthly_revenuecapvalue: res[0].monthly_revenuecapvalue,
            monthly_capvalue: res[0].monthly_capvalue,
            daily_revenuecap: res[0].daily_revenuecap,
            daily_revenuecapvalue: res[0].daily_revenuecapvalue,
            daily_capvalue: res[0].daily_capvalue,
            hourly_revenuecapvalue: res[0].hourly_revenuecapvalue,
            hourly_capvalue: res[0].hourly_capvalue,
            maxconvalue: res[0].max_concurrencyval,
            isfilter: res[0].isfilter,
            citystatetype: res[0].citystatetype,
            iscontains: res[0].iscontains,
            restrictdup: res[0].restrictdup,
            restrictafter: res[0].restrictafter,
            days: res[0].days,
            settingToggleDurationval: res[0].settingToggleDurationval,
            settingToggleDuration: res[0].settingToggleDuration
          });
          this.settingToggleDurationvalue = res[0].settingToggleDurationval;
          if (res[0].isfilter == 1) {
            this.isfilter = 1;
            if (res[0].citystatetype == 0) {
              var stateval = res[0].citystate.replace(/['"]+/g, '');
              this.editForm.patchValue({
                citystate: stateval,
                cityval: JSON.parse(res[0].cityval)
              });
              this.getdata();
            }
            if (res[0].citystatetype == 1) {
              this.editForm.patchValue({
                citystate: JSON.parse(res[0].citystate)
              });
              this.getdata();
            }
          }
          this.ngxLoader.stopLoader('customLoaderId');
        });
      }
    });
  }
  // getIVRMenu(){
  //   this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
  //   return new Promise((res,rej)=>{
  //     this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
  //     this.moduleService.getIVRMenus(this.currentCompany.uuid).subscribe(
  //       result => {
  //         res(result)
  //       },
  //       error => this.error = error
  //     );
  //   })
  // }
  // getAllRules(){
  //   return new Promise((res,rej)=>{
  //     this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
  //     this.moduleService.getallbuyers(this.currentCompany.uuid).subscribe(
  //       result => {
  //         res(result)
  //       },
  //       error => this.error = error
  //     );
  //   })
  // }
  get rules() {
    return this.addFSLRules.controls;
  }
  onFSLSubmit() {
    this.FSLRulesSubmitted = true;
    // stop here if form is invalid
    if (this.addFSLRules.invalid) {
      return;
    }
    // console.log(this.addFSLRules.get('start_time_0').value._d);
    //  return false;
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    // console.log(this.addFSLRules.value); return false;
    this.moduleService.addFSLRules(this.addFSLRules.value, this.currentCompany.uuid).subscribe(res => {
      // console.log(res);
      // return false;
      // localStorage.setItem('FSLRulesInsertID', JSON.stringify(res.insertid));
      this.addFSL();
      if (res.status !== 'error') {
        this.toastrService.success('FSL Rules Added Successfully');
      } else {
        this.toastrService.error('Failed To Add');
      }
    }, error => this.error = error);
  }
  //Add Buyer
  get buyercontrol() {
    return this.addBuyerForm.controls;
  }
  onBuyerSubmit() {
    const formData = new FormData();
    this.BuyerSubmitted = true;
    if (this.addBuyerForm.invalid) {
      return;
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('company', this.addBuyerForm.get('company').value);
    formData.append('email', this.addBuyerForm.get('email').value);
    formData.append('password', this.addBuyerForm.get('password').value);
    formData.append('sub_id', this.addBuyerForm.get('sub_id').value);
    formData.append('allow_buyer_to_pause_target', this.addBuyerForm.get('allow_buyer_to_pause_target').value);
    formData.append('allow_buyer_to_set_target_concurrency', this.addBuyerForm.get('allow_buyer_to_set_target_concurrency').value);
    formData.append('allow_buyer_to_dispute_call_conversions', this.addBuyerForm.get('allow_buyer_to_dispute_call_conversions').value);
    formData.append('limit_revenue', this.addBuyerForm.get('limit_revenue').value);
    // console.log(formData); return false;
    this.moduleService.addBuyer(formData).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Buyer Added Successfully');
        // this.getAllRules();
        this.getallbuyers();
        this.BuyerSubmitted = false;
      } else {
        this.toastrService.error('Failed To Add Label');
      }
    }, error => this.error = error);
  }
  closeBuyerModal() {
    if (this.addBuyerForm.get('company').value) {
      $("#addBuyer").modal("hide");
      $(".custom-switch-input").prop('checked', false);
      this.BuyerSubmitted = false;
      setTimeout(() => {
        this.addBuyerForm.reset();
      }, 2000);
    }
  }
  selectFile(event) {
    // console.log(event.target.files);
    // this.selectedfile =  event.target.files.item(0);
    let file = event.target.files.item(0);
    this.filetype = file.type;
    // console.log(file.type); return
    if (file.type != 'text/plain') {
      sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Error!', 'Please select only TXT File.', 'error');
      return;
    }
    if (event) {
      // console.log(file.name);
      this.filename = file.name;
      //  console.log(file.size);
      //  console.log(file.type);
      //File reader method
      let reader = new FileReader();
      reader.readAsText(file);
      reader.onload = e => {
        let csv = reader.result;
        let allTextLines = [];
        allTextLines = csv.split(/[\r\n]+/);
        //  console.log(allTextLines);
        //Table Headings
        let headers = allTextLines[0].split(',');
        let data = headers;
        let tarr = [];
        for (let j = 0; j < headers.length; j++) {
          tarr.push(data[j]);
        }
        //Pusd headings to array variable
        this.lines.push(tarr);
        // Table Rows
        let tarrR = [];
        let arrl = allTextLines.length;
        let rows = [];
        for (let i = 0; i < arrl; i++) {
          rows.push(allTextLines[i].split(','));
        }
        for (let j = 0; j < arrl; j++) {
          tarrR.push(rows[j]);
        }
        //Push rows to array variable
        this.linesR.push(tarrR);
      };
    }
    //  console.log(this.linesR);
    this.selectedfiledata = this.linesR;
  }
  onZipSubmit() {
    if (this.filetype != 'text/plain') {
      sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Error!', 'Please select TXT File.', 'error');
      return;
    }
    this.closeZipModal();
    const formData = new FormData();
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    const uuid = this.route.snapshot.paramMap.get('id');
    formData.append('target_uuid', uuid);
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('filename', this.filename);
    formData.append('file', JSON.stringify(this.selectedfiledata));
    this.moduleService.addZipcode(formData, this.currentCompany.uuid).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Zipcode Added Successfully');
        this.getallzipcode(uuid);
        this.BuyerSubmitted = false;
      } else {
        this.toastrService.error('Failed To Add Label');
      }
    }, error => this.error = error);
  }
  closeZipModal() {
    $("#addZipcode").modal("hide");
  }
  get editrules() {
    return this.editFSLRules.controls;
  }
  onFSLEditSubmit() {
    this.FSLRulesEditSubmitted = true;
    // stop here if form is invalid
    if (this.editFSLRules.invalid) {
      return;
    }
    this.editFSLRules.get('rulename').setValue(this.forwarding);
    // console.log(this.editFSLRules.value);
    // return false;
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    // console.log(this.currentCompany.uuid); return false;
    this.moduleService.editFSLRules(this.editFSLRules.value, this.currentCompany.uuid).subscribe(res => {
      // console.log(res);
      // return false;
      // localStorage.setItem('FSLRulesInsertID', JSON.stringify(res.insertid));
      if (res.status !== 'error') {
        this.toastrService.success('FSL Rules Updated Successfully');
      } else {
        this.toastrService.error('Failed To Add');
      }
    }, error => this.error = error);
  }
  settingToggleType(val) {
    this.settingToggleTypeval = val;
    this.editForm.get('settingToggleType').setValue(val);
  }
  settingToggleDuration(val) {
    this.settingToggleDurationvalue = val;
    this.editForm.get('settingToggleDurationval').setValue(val);
  }
  convert24hrs(time) {
    return moment__WEBPACK_IMPORTED_MODULE_3__(time, 'h:mm A').format('HH:mm');
  }
  convert12hrs(time) {
    return moment__WEBPACK_IMPORTED_MODULE_3__(time, 'h:mm A').format('hh:mm A');
  }
  get f() {
    return this.editForm.controls;
  }
  onSubmit() {
    // console.log(this.ringtree); return false;
    const formData = new FormData();
    this.submitted = true;
    // stop here if form is invalid
    if (this.editForm.invalid) {
      return;
    }
    // if(this.timetwohrs<this.timeonehrs){
    //   this.getTimeerror()
    //   return;
    // }
    // if(this.timetwohrs==this.timeonehrs && this.timetwomin<=this.timeonemin){
    //   this.getTimeerror()
    //   return;
    // }
    // if(this.timetwohrs1<this.timeonehrs1){
    //   this.getTimeerror()
    //   return;
    // }
    // if(this.timetwohrs1==this.timeonehrs1 && this.timetwomin1<=this.timeonemin1){
    //   this.getTimeerror()
    //   return;
    // }
    this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    formData.append('user_uuid', this.currentUser.uuid);
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('name', this.editForm.get('name').value);
    formData.append('subid', this.editForm.get('subid').value);
    formData.append('buyer', JSON.stringify(this.editForm.get('buyer').value));
    // formData.append('settingToggleBlockCallsIfCapped', this.editForm.get('settingToggleBlockCallsIfCapped').value);
    formData.append('settingToggleType', this.editForm.get('settingToggleType').value);
    if (this.settingToggleTypeval == 0) {
      formData.append('number', this.editForm.get('number').value);
    }
    if (this.settingToggleTypeval == 1) {
      formData.append('ivrMenu', JSON.stringify(this.editForm.get('ivrMenu').value));
    }
    if (this.settingToggleTypeval == 2) {
      formData.append('sip_address', this.editForm.get('sip_address').value);
    }
    if (this.settingToggleTypeval == 3) {
      formData.append('voice_mail', this.editForm.get('voice_mail').value);
    }
    formData.append('ringtree', this.ringtree);
    if (this.ringtree == 1) {
      formData.append('url', this.editForm.get('url').value);
      formData.append('http_method', this.editForm.get('http_method').value);
      formData.append('content_type', this.editForm.get('content_type').value);
      formData.append('body', this.editForm.get('body').value);
      formData.append('http_headers_name', this.editForm.get('http_headers_name').value);
      formData.append('http_headers_value', this.editForm.get('http_headers_value').value);
      // formData.append('keyword', this.editForm.get('keyword').value);
      formData.append('keywordlength', this.addkeyword.length);
      formData.append('keyword0', this.editForm.get('keyword0').value);
      formData.append('keyword1', this.editForm.get('keyword1').value);
      formData.append('keyword2', this.editForm.get('keyword2').value);
    }
    // formData.append('connection_timeout', this.editForm.get('connection_timeout').value);
    // formData.append('disableRecordings', this.disableRecordings);
    // formData.append('dialivroption', this.editForm.get('dialivroption').value);
    // formData.append('timezone', this.editForm.get('timezone').value);
    formData.append('start_day', this.editForm.get('hoursofoperation_start').value);
    formData.append('end_day', this.editForm.get('hoursofoperation_end').value);
    let tid = "";
    // console.log(this.timezoneval); return
    if (this.timezoneval.length > 0) {
      tid = this.timezoneval[0].id;
    }
    formData.append('timezone', tid);
    // var starttime =  this.editForm.get('start_hrs').value+':'+this.editForm.get('start_min').value;
    // var endtime =  this.editForm.get('end_hrs').value+':'+this.editForm.get('end_min').value;
    var starttime;
    var endtime;
    let default_ampm = this.editForm.get('default_ampm').value == 0 ? "AM" : "PM";
    let default_ampm_close = this.editForm.get('default_ampm_close').value == 0 ? "AM" : "PM";
    if (this.is12or24 == 1) {
      starttime = this.convert24hrs(this.editForm.get('start_hrs').value + ':' + this.editForm.get('start_min').value + ' ' + default_ampm);
      endtime = this.convert24hrs(this.editForm.get('end_hrs').value + ':' + this.editForm.get('end_min').value + ' ' + default_ampm_close);
    } else {
      starttime = this.convert24hrs(this.editForm.get('start_hrs').value + ':' + this.editForm.get('start_min').value);
      endtime = this.convert24hrs(this.editForm.get('end_hrs').value + ':' + this.editForm.get('end_min').value);
    }
    // return
    formData.append('isadded', this.isadvanced);
    formData.append('hof_alwaysopen', this.hof_alwaysopen);
    // console.log(this.hof_alwaysopen);return
    if (this.isadvanced == 1) {
      formData.append('day_0', 'Sunday');
      formData.append('day_1', 'Monday');
      formData.append('day_2', 'Tuesday');
      formData.append('day_3', 'Wednesday');
      formData.append('day_4', 'Thursday');
      formData.append('day_5', 'Friday');
      formData.append('day_6', 'Saturday');
      formData.append('open_0', this.sundayopen);
      formData.append('open_1', this.mondayopen);
      formData.append('open_2', this.tuesdayopen);
      formData.append('open_3', this.wednesdayopen);
      formData.append('open_4', this.thursdayopen);
      formData.append('open_5', this.fridayopen);
      formData.append('open_6', this.saturdayopen);
      let sunday_ampm = this.editForm.get('sunday_ampm').value == 0 ? "AM" : "PM";
      let sunday_ampm_close = this.editForm.get('sunday_ampm_close').value == 0 ? "AM" : "PM";
      let monday_ampm = this.editForm.get('monday_ampm').value == 0 ? "AM" : "PM";
      let monday_ampm_close = this.editForm.get('monday_ampm_close').value == 0 ? "AM" : "PM";
      let tuesday_ampm = this.editForm.get('tuesday_ampm').value == 0 ? "AM" : "PM";
      let tuesday_ampm_close = this.editForm.get('tuesday_ampm_close').value == 0 ? "AM" : "PM";
      let wednesday_ampm = this.editForm.get('wednesday_ampm').value == 0 ? "AM" : "PM";
      let wednesday_ampm_close = this.editForm.get('wednesday_ampm_close').value == 0 ? "AM" : "PM";
      let thursday_ampm = this.editForm.get('thursday_ampm').value == 0 ? "AM" : "PM";
      let thursday_ampm_close = this.editForm.get('thursday_ampm_close').value == 0 ? "AM" : "PM";
      let friday_ampm = this.editForm.get('friday_ampm').value == 0 ? "AM" : "PM";
      let friday_ampm_close = this.editForm.get('friday_ampm_close').value == 0 ? "AM" : "PM";
      let saturday_ampm = this.editForm.get('saturday_ampm').value == 0 ? "AM" : "PM";
      let saturday_ampm_close = this.editForm.get('saturday_ampm_close').value == 0 ? "AM" : "PM";
      if (this.is12or24 == 1) {
        formData.append('0_open_time', this.convert24hrs(this.editForm.get('start_hrs_sunday').value + ':' + this.editForm.get('start_min_sunday').value + ' ' + sunday_ampm));
        formData.append('0_close_time', this.convert24hrs(this.editForm.get('end_hrs_sunday').value + ':' + this.editForm.get('end_min_sunday').value + ' ' + sunday_ampm_close));
        formData.append('1_open_time', this.convert24hrs(this.editForm.get('start_hrs_monday').value + ':' + this.editForm.get('start_min_monday').value + ' ' + monday_ampm));
        formData.append('1_close_time', this.convert24hrs(this.editForm.get('end_hrs_monday').value + ':' + this.editForm.get('end_min_monday').value + ' ' + monday_ampm_close));
        formData.append('2_open_time', this.convert24hrs(this.editForm.get('start_hrs_tuesday').value + ':' + this.editForm.get('start_min_tuesday').value + ' ' + tuesday_ampm));
        formData.append('2_close_time', this.convert24hrs(this.editForm.get('end_hrs_tuesday').value + ':' + this.editForm.get('end_min_tuesday').value + ' ' + tuesday_ampm_close));
        formData.append('3_open_time', this.convert24hrs(this.editForm.get('start_hrs_wednesday').value + ':' + this.editForm.get('start_min_wednesday').value + ' ' + wednesday_ampm));
        formData.append('3_close_time', this.convert24hrs(this.editForm.get('end_hrs_wednesday').value + ':' + this.editForm.get('end_min_wednesday').value + ' ' + wednesday_ampm_close));
        formData.append('4_open_time', this.convert24hrs(this.editForm.get('start_hrs_thursday').value + ':' + this.editForm.get('start_min_thursday').value + ' ' + thursday_ampm));
        formData.append('4_close_time', this.convert24hrs(this.editForm.get('end_hrs_thursday').value + ':' + this.editForm.get('end_min_thursday').value + ' ' + thursday_ampm_close));
        formData.append('5_open_time', this.convert24hrs(this.editForm.get('start_hrs_friday').value + ':' + this.editForm.get('start_min_friday').value + ' ' + friday_ampm));
        formData.append('5_close_time', this.convert24hrs(this.editForm.get('end_hrs_friday').value + ':' + this.editForm.get('end_min_friday').value + ' ' + friday_ampm_close));
        formData.append('6_open_time', this.convert24hrs(this.editForm.get('start_hrs_saturday').value + ':' + this.editForm.get('start_min_saturday').value + ' ' + saturday_ampm));
        formData.append('6_close_time', this.convert24hrs(this.editForm.get('end_hrs_saturday').value + ':' + this.editForm.get('end_min_saturday').value + ' ' + saturday_ampm_close));
      } else {
        formData.append('0_open_time', this.editForm.get('start_hrs_sunday').value + ':' + this.editForm.get('start_min_sunday').value);
        formData.append('0_close_time', this.editForm.get('end_hrs_sunday').value + ':' + this.editForm.get('end_min_sunday').value);
        formData.append('1_open_time', this.editForm.get('start_hrs_monday').value + ':' + this.editForm.get('start_min_monday').value);
        formData.append('1_close_time', this.editForm.get('end_hrs_monday').value + ':' + this.editForm.get('end_min_monday').value);
        formData.append('2_open_time', this.editForm.get('start_hrs_tuesday').value + ':' + this.editForm.get('start_min_tuesday').value);
        formData.append('2_close_time', this.editForm.get('end_hrs_tuesday').value + ':' + this.editForm.get('end_min_tuesday').value);
        formData.append('3_open_time', this.editForm.get('start_hrs_wednesday').value + ':' + this.editForm.get('start_min_wednesday').value);
        formData.append('3_close_time', this.editForm.get('end_hrs_wednesday').value + ':' + this.editForm.get('end_min_wednesday').value);
        formData.append('4_open_time', this.editForm.get('start_hrs_thursday').value + ':' + this.editForm.get('start_min_thursday').value);
        formData.append('4_close_time', this.editForm.get('end_hrs_thursday').value + ':' + this.editForm.get('end_min_thursday').value);
        formData.append('5_open_time', this.editForm.get('start_hrs_friday').value + ':' + this.editForm.get('start_min_friday').value);
        formData.append('5_close_time', this.editForm.get('end_hrs_friday').value + ':' + this.editForm.get('end_min_friday').value);
        formData.append('6_open_time', this.editForm.get('start_hrs_saturday').value + ':' + this.editForm.get('start_min_saturday').value);
        formData.append('6_close_time', this.editForm.get('end_hrs_saturday').value + ':' + this.editForm.get('end_min_saturday').value);
      }
    }
    // if(this.isadded==1){
    //   formData.append('start_day_1', this.editForm.get('hoursofoperation_start_1').value);
    //   formData.append('end_day_1', this.editForm.get('hoursofoperation_end_1').value);
    //   var starttime_1 =  this.editForm.get('start_hrs_1').value+':'+this.editForm.get('start_min_1').value;
    //   var endtime_1 =  this.editForm.get('end_hrs_1').value+':'+this.editForm.get('end_min_1').value;
    //   formData.append('start_time_1',starttime_1);
    //   formData.append('end_time_1',endtime_1);
    //   formData.append('timezone1', this.editForm.get('timezone1').value);
    // }
    formData.append('start_time', starttime);
    formData.append('end_time', endtime);
    formData.append('capon', this.editForm.get('capon').value);
    formData.append('is_autodtmf', this.dtmf_auto);
    formData.append('dtmf_zipcode_enable', this.dtmf_zipcode_enable);
    formData.append('dtmf_value', this.editForm.get('dtmf_value').value);
    formData.append('dtmf_interval', this.editForm.get('dtmf_interval').value);
    formData.append('dtmf_percent', this.editForm.get('dtmf_percent').value);
    formData.append('global_revenuecaptoggle', this.global_revenuecap);
    formData.append('global_revenuecapvalue', this.editForm.get('global_revenuecapvalue').value);
    formData.append('monthly_revenuecaptoggle', this.monthly_revenuecap);
    formData.append('monthly_revenuecapvalue', this.editForm.get('monthly_revenuecapvalue').value);
    formData.append('daily_revenuecaptoggle', this.daily_revenuecap);
    formData.append('daily_revenuecapvalue', this.editForm.get('daily_revenuecapvalue').value);
    formData.append('hourly_revenuecaptoggle', this.hourly_revenuecap);
    formData.append('hourly_revenuecapvalue', this.editForm.get('hourly_revenuecapvalue').value);
    formData.append('global_cap', this.globalcap);
    formData.append('monthly_cap', this.monthlycap);
    formData.append('daily_cap', this.dailycap);
    formData.append('hourly_cap', this.hourlycap);
    formData.append('global_capvalue', this.editForm.get('global_capvalue').value);
    formData.append('monthly_capvalue', this.editForm.get('monthly_capvalue').value);
    formData.append('daily_capvalue', this.editForm.get('daily_capvalue').value);
    formData.append('hourly_capvalue', this.editForm.get('hourly_capvalue').value);
    formData.append('addcontoggle', this.maxconcurrency);
    formData.append('maxconvalue', this.editForm.get('maxconvalue').value);
    formData.append('restrictdup', this.editForm.get('restrictdup').value);
    formData.append('restrictafter', this.editForm.get('restrictafter').value);
    formData.append('settingToggleDurationval', this.settingToggleDurationvalue);
    formData.append('days', this.editForm.get('days').value);
    if (this.isfilter == 1) {
      formData.append('isfilter', this.editForm.get('isfilter').value);
      formData.append('citystatetype', this.editForm.get('citystatetype').value);
      formData.append('iscontains', this.editForm.get('iscontains').value);
      formData.append('citystate', JSON.stringify(this.editForm.get('citystate').value));
      formData.append('cityval', JSON.stringify(this.editForm.get('cityval').value));
    }
    formData.append('filterselected', JSON.stringify(this.filterselected));
    formData.append('is12or24', this.is12or24);
    const uuid = this.route.snapshot.paramMap.get('id');
    // alert(uuid);return false;
    if (uuid) {
      this.moduleService.updateTarget(formData, uuid).subscribe(res => {
        // console.log(res); return false;
        if (res.status !== 'error') {
          this.toastrService.success('Target Updated Successfully');
          this.isTargetName = false;
          // this.router.navigate(['/numbers']);
          this.router.navigate(['/target']);
        } else {
          this.toastrService.success('Failed To Update! Please Try Again Later..');
        }
      }, error => this.error = error);
    }
  }
  validateTargetname() {
    if (this.editForm.get('name').value != '') {
      this.moduleService.validateTargetName(this.editForm.get('name').value, this.currentCompany.uuid).subscribe(res => {
        // console.log(res); return false;
        this.isTargetName = res;
        if (this.isTargetName.status == 'success') {
          this.isTargetName = "success";
        } else {
          this.isTargetName = "fail";
        }
      });
    } else {
      this.isTargetName = "";
    }
  }
  get_jklrules(event) {
    this.jklrules = event.target.checked;
  }
  clearfilter(index) {
    this.filterselected.splice(index, 1);
  }
  ringtree_toggle(event) {
    this.ringtree = event.target.checked;
    console.log(event.target.checked);
    if (event.target.checked == true) {
      this.ringtreetext = "Ring Tree";
    } else {
      this.ringtreetext = "Simple";
    }
  }
  global_revenue_cap(event) {
    this.global_revenuecap = event.target.checked;
  }
  global_cap(event) {
    this.globalcap = event.target.checked;
  }
  dtmf_auto_toggle(event) {
    this.dtmf_auto = event.target.checked;
  }
  methodtype(event) {
    this.methodtypeval = event.target.value;
  }
  hof_alwaysopen_toggle(event) {
    this.hof_alwaysopen = event.target.checked;
  }
  isadvanced_toggle(event) {
    if (event == 1) {
      this.advanced = 'Advanced';
      this.isadvanced = 1;
    }
    if (event == 0) {
      this.advanced = 'Basic';
      this.isadvanced = 0;
    }
  }
  sunday_open(event) {
    if (event.target.checked == true) {
      this.sundayopen = 1;
    } else {
      this.sundayopen = 0;
    }
  }
  monday_open(event) {
    if (event.target.checked == true) {
      this.mondayopen = 1;
    } else {
      this.mondayopen = 0;
    }
  }
  tuesday_open(event) {
    if (event.target.checked == true) {
      this.tuesdayopen = 1;
    } else {
      this.tuesdayopen = 0;
    }
  }
  wednesday_open(event) {
    if (event.target.checked == true) {
      this.wednesdayopen = 1;
    } else {
      this.wednesdayopen = 0;
    }
  }
  thursday_open(event) {
    if (event.target.checked == true) {
      this.thursdayopen = 1;
    } else {
      this.thursdayopen = 0;
    }
  }
  friday_open(event) {
    if (event.target.checked == true) {
      this.fridayopen = 1;
    } else {
      this.fridayopen = 0;
    }
  }
  saturday_open(event) {
    if (event.target.checked == true) {
      this.saturdayopen = 1;
    } else {
      this.saturdayopen = 0;
    }
  }
  dtmf_zipcode_enable_toggle(event) {
    this.dtmf_zipcode_enable = event.target.checked;
  }
  monthly_revenue_cap(event) {
    this.monthly_revenuecap = event.target.checked;
  }
  monthly_cap(event) {
    this.monthlycap = event.target.checked;
  }
  daily_revenue_cap(event) {
    this.daily_revenuecap = event.target.checked;
  }
  daily_cap(event) {
    this.dailycap = event.target.checked;
  }
  hourly_revenue_cap(event) {
    this.hourly_revenuecap = event.target.checked;
  }
  hourly_cap(event) {
    this.hourlycap = event.target.checked;
  }
  get_maxcon(event) {
    this.maxconcurrency = event.target.checked;
  }
  get_disableRecordings(event) {
    this.disableRecordings = event.target.checked;
  }
  get_hourlyconcurrency(event) {
    this.hourlyconcurrency = event.target.checked;
  }
  getTimeonehrs(event) {
    this.timeonehrs = event.target.value;
    if (this.timetwohrs < this.timeonehrs) {
      this.getTimeerror();
    }
  }
  getTimeonemin(event) {
    this.timeonemin = event.target.value;
    if (this.timetwohrs == this.timeonehrs && this.timetwomin <= this.timeonemin) {
      this.getTimeerror();
    }
  }
  getTimetwohrs(event) {
    this.timetwohrs = event.target.value;
    if (this.timetwohrs < this.timeonehrs) {
      this.getTimeerror();
    }
  }
  getTimetwomin(event) {
    this.timetwomin = event.target.value;
    if (this.timetwohrs == this.timeonehrs && this.timetwomin <= this.timeonemin) {
      this.getTimeerror();
    }
  }
  getTimetwohrs1(event) {
    this.timeonehrs1 = event.target.value;
    if (this.timetwohrs1 < this.timeonehrs1) {
      this.getTimeerror();
    }
  }
  getTimetwomin1(event) {
    this.timeonemin1 = event.target.value;
    if (this.timetwohrs1 == this.timeonehrs1 && this.timetwomin1 <= this.timeonemin1) {
      this.getTimeerror();
    }
  }
  getTimetwohrs2(event) {
    this.timetwohrs1 = event.target.value;
    if (this.timetwohrs1 < this.timeonehrs1) {
      this.getTimeerror();
    }
  }
  getTimetwomin2(event) {
    this.timetwomin1 = event.target.value;
    if (this.timetwohrs1 == this.timeonehrs1 && this.timetwomin1 <= this.timeonemin1) {
      this.getTimeerror();
    }
  }
  getTimeerror() {
    sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Error!', 'Closing Time must be greater than Opening Time.', 'error');
  }
  getFSLbyuuid(uuid) {
    // alert(uuid);
    // console.log(uuid);
    if (uuid != '') {
      this.moduleService.getFSLbyuuid(uuid).subscribe(res => {
        this.forwarding = res.forwarding[0].name;
        this.forwardingtimeframe = res.forwarding[0].nooftimeframe;
        this.noofforwarding = res.forwarding[0].nooftimeframe;
        for (let index = 0; index < res.forwarding.length; index++) {
          var start = res.forwarding[index].start_time.split(':');
          var end = res.forwarding[index].end_time.split(':');
          var starthrs = 'start_hrs_' + index;
          var startmin = 'start_min_' + index;
          var endhrs = 'end_hrs_' + index;
          var endmin = 'end_min_' + index;
          // var endkey ='end_time_'+index;
          var daykey = 'day_' + index;
          // console.log(start[0]);
          this.editFSLRules.patchValue({
            [daykey]: res.forwarding[index].timeofday,
            // [startkey]: new Date(new Date().setHours(start[0], start[1])),
            [starthrs]: start[0],
            [startmin]: start[1],
            [endhrs]: end[0],
            [endmin]: end[1]
            // [endkey]: new Date(new Date().setHours(end[0], end[1])),
          });

          for (let j = 0; j < res.forwarding[index].locations.length; j++) {
            var inc = j + 1;
            // var forlocationkey ='noofforwardinglocation_'+inc;
            var PrimaryforwardType = 'PrimaryforwardType_' + j + '_day' + index;
            var number_value = 'number_' + j + '_day' + index;
            var ivr_value = 'ivrMenu_' + j + '_day' + index;
            var sip_value = 'sipAdd_' + j + '_day' + index;
            // this.flag =res.forwarding[index].locations[j].primary_forwarding_type;
            // console.log(res.forwarding[index].locations[j].primary_forwarding_type);
            if (res.forwarding[index].locations[j].primary_forwarding_type == 0) {
              this.setPrimaryforward(0, j, index);
              this.flag = 0;
            }
            if (res.forwarding[index].locations[j].primary_forwarding_type == 1) {
              this.setPrimaryforward(1, j, index);
              this.flag = 1;
            }
            if (res.forwarding[index].locations[j].primary_forwarding_type == 2) {
              this.flag = 2;
              this.setPrimaryforward(2, j, index);
            }
            if (res.forwarding[index].locations[j].primary_forwarding_number != '') {
              var number = res.forwarding[index].locations[j].primary_forwarding_number;
              var formatted = '(' + number.substr(0, 3) + ') ' + number.substr(3, 3) + '-' + number.substr(6, 4);
            } else {
              var formatted = "";
            }
            if (index == 0) {
              this.noofforwardinglocation_1 = res.forwarding[index].locations[j].noofforwardinglocation;
              // if(this.noofforwardinglocation_1!=1)  {
              // this.noofforwardinglocation_1++;
              // }
            }
            //  console.log(res.forwarding[index].locations[j].noofforwardinglocation);
            if (index == 1) {
              this.noofforwardinglocation_2 = res.forwarding[index].locations[j].noofforwardinglocation;
              // if(res.forwarding[index].locations[j].noofforwardinglocation!=1)  {
              //   this.noofforwardinglocation_2++;
              //   }
            }

            if (index == 2) {
              this.noofforwardinglocation_3 = res.forwarding[index].locations[j].noofforwardinglocation;
              // if(res.forwarding[index].locations[j].noofforwardinglocation!=1)  {
              //   this.noofforwardinglocation_3++;
              // }
            }

            if (index == 3) {
              this.noofforwardinglocation_4 = res.forwarding[index].locations[j].noofforwardinglocation;
              // if(res.forwarding[index].locations[j].noofforwardinglocation!=1)  {
              //   this.noofforwardinglocation_4++;
              // }
            }

            if (index == 4) {
              this.noofforwardinglocation_5 = res.forwarding[index].locations[j].noofforwardinglocation;
              // if(res.forwarding[index].locations[j].noofforwardinglocation!=1)  {
              //   this.noofforwardinglocation_5++;
              // }
            }

            if (index == 5) {
              this.noofforwardinglocation_6 = res.forwarding[index].locations[j].noofforwardinglocation;
            }
            if (index == 6) {
              this.noofforwardinglocation_7 = res.forwarding[index].locations[j].noofforwardinglocation;
            }
            // console.log(index);
            this.editFSLRules.patchValue({
              // [forlocationkey]: res.forwarding[index].locations[j].noofforwardinglocation,
              [PrimaryforwardType]: this.flag,
              [number_value]: formatted,
              [ivr_value]: res.forwarding[index].locations[j].primary_forwarding_ivr,
              [sip_value]: res.forwarding[index].locations[j].primary_forwarding_sip
            });
          }
        }
      }, error => this.error = error);
    } else {
      this.allRulesbyname = [];
    }
  }
  addFSL() {
    this.FSLRulesSubmitted = false;
    this.addFSLRules.reset();
  }
  getWeekbyuuid(uuid, start_day, end_day) {
    this.editWeekDaysForm.patchValue({
      'uuid': uuid,
      'start_day': start_day,
      'end_day': end_day
    });
  }
  loadallweekdays() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleService.loadallweekdays(this.currentCompany.uuid).subscribe(res => {
      //  console.log(res); return false;
      this.allweekdays = res.data;
    }, error => this.error = error);
  }
  setPrimaryforward(id, count, day) {
    // Day0
    if (count == 0 && day == 0) {
      this.selectedPrimaryForaward_0_day0 = id;
      this.selectedPrimaryCount_0_day0 = count;
      this.selected_0_day_0 = day;
    }
    if (count == 1 && day == 0) {
      this.selectedPrimaryForaward_1_day0 = id;
      this.selectedPrimaryCount_1_day0 = count;
      this.selected_1_day_0 = day;
    }
    if (count == 2 && day == 0) {
      this.selectedPrimaryForaward_2_day0 = id;
      this.selectedPrimaryCount_2_day0 = count;
      this.selected_2_day_0 = day;
    }
    if (count == 3 && day == 0) {
      this.selectedPrimaryForaward_3_day0 = id;
      this.selectedPrimaryCount_3_day0 = count;
      this.selected_3_day_0 = day;
    }
    if (count == 4 && day == 0) {
      this.selectedPrimaryForaward_4_day0 = id;
      this.selectedPrimaryCount_4_day0 = count;
      this.selected_4_day_0 = day;
    }
    if (count == 5 && day == 0) {
      this.selectedPrimaryForaward_5_day0 = id;
      this.selectedPrimaryCount_5_day0 = count;
      this.selected_5_day_0 = day;
    }
    if (count == 6 && day == 0) {
      this.selectedPrimaryForaward_6_day0 = id;
      this.selectedPrimaryCount_6_day0 = count;
      this.selected_6_day_0 = day;
    }
    if (count == 7 && day == 0) {
      this.selectedPrimaryForaward_7_day0 = id;
      this.selectedPrimaryCount_7_day0 = count;
      this.selected_7_day_0 = day;
    }
    if (count == 8 && day == 0) {
      this.selectedPrimaryForaward_8_day0 = id;
      this.selectedPrimaryCount_8_day0 = count;
      this.selected_8_day_0 = day;
    }
    if (count == 9 && day == 0) {
      this.selectedPrimaryForaward_9_day0 = id;
      this.selectedPrimaryCount_9_day0 = count;
      this.selected_9_day_0 = day;
    }
    // Day1
    if (count == 0 && day == 1) {
      this.selectedPrimaryForaward_0_day1 = id;
      this.selectedPrimaryCount_0_day1 = count;
      this.selected_0_day_1 = day;
    }
    if (count == 1 && day == 1) {
      this.selectedPrimaryForaward_1_day1 = id;
      this.selectedPrimaryCount_1_day1 = count;
      this.selected_1_day_1 = day;
    }
    if (count == 2 && day == 1) {
      this.selectedPrimaryForaward_2_day1 = id;
      this.selectedPrimaryCount_2_day1 = count;
      this.selected_2_day_1 = day;
    }
    if (count == 3 && day == 1) {
      this.selectedPrimaryForaward_3_day1 = id;
      this.selectedPrimaryCount_3_day1 = count;
      this.selected_3_day_1 = day;
    }
    if (count == 4 && day == 1) {
      this.selectedPrimaryForaward_4_day1 = id;
      this.selectedPrimaryCount_4_day1 = count;
      this.selected_4_day_1 = day;
    }
    if (count == 5 && day == 1) {
      this.selectedPrimaryForaward_5_day1 = id;
      this.selectedPrimaryCount_5_day1 = count;
      this.selected_5_day_1 = day;
    }
    if (count == 6 && day == 1) {
      this.selectedPrimaryForaward_6_day1 = id;
      this.selectedPrimaryCount_6_day1 = count;
      this.selected_6_day_1 = day;
    }
    if (count == 7 && day == 1) {
      this.selectedPrimaryForaward_7_day1 = id;
      this.selectedPrimaryCount_7_day1 = count;
      this.selected_7_day_1 = day;
    }
    if (count == 8 && day == 1) {
      this.selectedPrimaryForaward_8_day1 = id;
      this.selectedPrimaryCount_8_day1 = count;
      this.selected_8_day_1 = day;
    }
    if (count == 9 && day == 1) {
      this.selectedPrimaryForaward_9_day1 = id;
      this.selectedPrimaryCount_9_day1 = count;
      this.selected_9_day_1 = day;
    }
    // Day2
    if (count == 0 && day == 2) {
      this.selectedPrimaryForaward_0_day2 = id;
      this.selectedPrimaryCount_0_day2 = count;
      this.selected_0_day_2 = day;
    }
    if (count == 1 && day == 2) {
      this.selectedPrimaryForaward_1_day2 = id;
      this.selectedPrimaryCount_1_day2 = count;
      this.selected_1_day_2 = day;
    }
    if (count == 2 && day == 2) {
      this.selectedPrimaryForaward_2_day2 = id;
      this.selectedPrimaryCount_2_day2 = count;
      this.selected_2_day_2 = day;
    }
    if (count == 3 && day == 2) {
      this.selectedPrimaryForaward_3_day2 = id;
      this.selectedPrimaryCount_3_day2 = count;
      this.selected_3_day_2 = day;
    }
    if (count == 4 && day == 2) {
      this.selectedPrimaryForaward_4_day2 = id;
      this.selectedPrimaryCount_4_day2 = count;
      this.selected_4_day_2 = day;
    }
    if (count == 5 && day == 2) {
      this.selectedPrimaryForaward_5_day2 = id;
      this.selectedPrimaryCount_5_day2 = count;
      this.selected_5_day_2 = day;
    }
    if (count == 6 && day == 2) {
      this.selectedPrimaryForaward_6_day2 = id;
      this.selectedPrimaryCount_6_day2 = count;
      this.selected_6_day_2 = day;
    }
    if (count == 7 && day == 2) {
      this.selectedPrimaryForaward_7_day2 = id;
      this.selectedPrimaryCount_7_day2 = count;
      this.selected_7_day_2 = day;
    }
    if (count == 8 && day == 2) {
      this.selectedPrimaryForaward_8_day2 = id;
      this.selectedPrimaryCount_8_day2 = count;
      this.selected_8_day_2 = day;
    }
    if (count == 9 && day == 2) {
      this.selectedPrimaryForaward_9_day2 = id;
      this.selectedPrimaryCount_9_day2 = count;
      this.selected_9_day_2 = day;
    }
    // Day3
    if (count == 0 && day == 3) {
      this.selectedPrimaryForaward_0_day3 = id;
      this.selectedPrimaryCount_0_day3 = count;
      this.selected_0_day_3 = day;
    }
    if (count == 1 && day == 3) {
      this.selectedPrimaryForaward_1_day3 = id;
      this.selectedPrimaryCount_1_day3 = count;
      this.selected_1_day_3 = day;
    }
    if (count == 2 && day == 3) {
      this.selectedPrimaryForaward_2_day3 = id;
      this.selectedPrimaryCount_2_day3 = count;
      this.selected_2_day_3 = day;
    }
    if (count == 3 && day == 3) {
      this.selectedPrimaryForaward_3_day3 = id;
      this.selectedPrimaryCount_3_day3 = count;
      this.selected_3_day_3 = day;
    }
    if (count == 4 && day == 3) {
      this.selectedPrimaryForaward_4_day3 = id;
      this.selectedPrimaryCount_4_day3 = count;
      this.selected_4_day_3 = day;
    }
    if (count == 5 && day == 3) {
      this.selectedPrimaryForaward_5_day3 = id;
      this.selectedPrimaryCount_5_day3 = count;
      this.selected_5_day_3 = day;
    }
    if (count == 6 && day == 3) {
      this.selectedPrimaryForaward_6_day3 = id;
      this.selectedPrimaryCount_6_day3 = count;
      this.selected_6_day_3 = day;
    }
    if (count == 7 && day == 3) {
      this.selectedPrimaryForaward_7_day3 = id;
      this.selectedPrimaryCount_7_day3 = count;
      this.selected_7_day_3 = day;
    }
    if (count == 8 && day == 3) {
      this.selectedPrimaryForaward_8_day3 = id;
      this.selectedPrimaryCount_8_day3 = count;
      this.selected_8_day_3 = day;
    }
    if (count == 9 && day == 3) {
      this.selectedPrimaryForaward_9_day3 = id;
      this.selectedPrimaryCount_9_day3 = count;
      this.selected_9_day_3 = day;
    }
    // Day4
    if (count == 0 && day == 4) {
      this.selectedPrimaryForaward_0_day4 = id;
      this.selectedPrimaryCount_0_day4 = count;
      this.selected_0_day_4 = day;
    }
    if (count == 1 && day == 4) {
      this.selectedPrimaryForaward_1_day4 = id;
      this.selectedPrimaryCount_1_day4 = count;
      this.selected_1_day_4 = day;
    }
    if (count == 2 && day == 4) {
      this.selectedPrimaryForaward_2_day4 = id;
      this.selectedPrimaryCount_2_day4 = count;
      this.selected_2_day_4 = day;
    }
    if (count == 3 && day == 4) {
      this.selectedPrimaryForaward_3_day4 = id;
      this.selectedPrimaryCount_3_day4 = count;
      this.selected_3_day_4 = day;
    }
    if (count == 4 && day == 4) {
      this.selectedPrimaryForaward_4_day4 = id;
      this.selectedPrimaryCount_4_day4 = count;
      this.selected_4_day_4 = day;
    }
    if (count == 5 && day == 4) {
      this.selectedPrimaryForaward_5_day4 = id;
      this.selectedPrimaryCount_5_day4 = count;
      this.selected_5_day_4 = day;
    }
    if (count == 6 && day == 4) {
      this.selectedPrimaryForaward_6_day4 = id;
      this.selectedPrimaryCount_6_day4 = count;
      this.selected_6_day_4 = day;
    }
    if (count == 7 && day == 4) {
      this.selectedPrimaryForaward_7_day4 = id;
      this.selectedPrimaryCount_7_day4 = count;
      this.selected_7_day_4 = day;
    }
    if (count == 8 && day == 4) {
      this.selectedPrimaryForaward_8_day4 = id;
      this.selectedPrimaryCount_8_day4 = count;
      this.selected_8_day_4 = day;
    }
    if (count == 9 && day == 4) {
      this.selectedPrimaryForaward_9_day4 = id;
      this.selectedPrimaryCount_9_day4 = count;
      this.selected_9_day_4 = day;
    }
  }
  isPrimarySelected(id, count, day) {
    // Day0
    if (count == 0 && day == 0) {
      if (this.selectedPrimaryForaward_0_day0 == id && this.selectedPrimaryCount_0_day0 === count && this.selected_0_day_0 == day) return true;else return false;
    }
    if (count == 1 && day == 0) {
      if (this.selectedPrimaryForaward_1_day0 == id && this.selectedPrimaryCount_1_day0 === count && this.selected_1_day_0 == day) return true;else return false;
    }
    if (count == 2 && day == 0) {
      if (this.selectedPrimaryForaward_2_day0 == id && this.selectedPrimaryCount_2_day0 === count && this.selected_2_day_0 == day) return true;else return false;
    }
    if (count == 3 && day == 0) {
      if (this.selectedPrimaryForaward_3_day0 == id && this.selectedPrimaryCount_3_day0 === count && this.selected_3_day_0 == day) return true;else return false;
    }
    if (count == 4 && day == 0) {
      if (this.selectedPrimaryForaward_4_day0 == id && this.selectedPrimaryCount_4_day0 === count && this.selected_4_day_0 == day) return true;else return false;
    }
    if (count == 5 && day == 0) {
      if (this.selectedPrimaryForaward_5_day0 == id && this.selectedPrimaryCount_5_day0 === count && this.selected_5_day_0 == day) return true;else return false;
    }
    if (count == 6 && day == 0) {
      if (this.selectedPrimaryForaward_6_day0 == id && this.selectedPrimaryCount_6_day0 === count && this.selected_6_day_0 == day) return true;else return false;
    }
    if (count == 7 && day == 0) {
      if (this.selectedPrimaryForaward_7_day0 == id && this.selectedPrimaryCount_7_day0 === count && this.selected_7_day_0 == day) return true;else return false;
    }
    if (count == 8 && day == 0) {
      if (this.selectedPrimaryForaward_8_day0 == id && this.selectedPrimaryCount_8_day0 === count && this.selected_8_day_0 == day) return true;else return false;
    }
    if (count == 9 && day == 0) {
      if (this.selectedPrimaryForaward_9_day0 == id && this.selectedPrimaryCount_9_day0 === count && this.selected_9_day_0 == day) return true;else return false;
    }
    // Day1
    if (count == 0 && day == 1) {
      if (this.selectedPrimaryForaward_0_day1 == id && this.selectedPrimaryCount_0_day1 === count && this.selected_0_day_1 == day) return true;else return false;
    }
    if (count == 1 && day == 1) {
      if (this.selectedPrimaryForaward_1_day1 == id && this.selectedPrimaryCount_1_day1 === count && this.selected_1_day_1 == day) return true;else return false;
    }
    if (count == 2 && day == 1) {
      if (this.selectedPrimaryForaward_2_day1 == id && this.selectedPrimaryCount_2_day1 === count && this.selected_2_day_1 == day) return true;else return false;
    }
    if (count == 3 && day == 1) {
      if (this.selectedPrimaryForaward_3_day1 == id && this.selectedPrimaryCount_3_day1 === count && this.selected_3_day_1 == day) return true;else return false;
    }
    if (count == 4 && day == 1) {
      if (this.selectedPrimaryForaward_4_day1 == id && this.selectedPrimaryCount_4_day1 === count && this.selected_4_day_1 == day) return true;else return false;
    }
    if (count == 5 && day == 1) {
      if (this.selectedPrimaryForaward_5_day1 == id && this.selectedPrimaryCount_5_day1 === count && this.selected_5_day_1 == day) return true;else return false;
    }
    if (count == 6 && day == 1) {
      if (this.selectedPrimaryForaward_6_day1 == id && this.selectedPrimaryCount_6_day1 === count && this.selected_6_day_1 == day) return true;else return false;
    }
    if (count == 7 && day == 1) {
      if (this.selectedPrimaryForaward_7_day1 == id && this.selectedPrimaryCount_7_day1 === count && this.selected_7_day_1 == day) return true;else return false;
    }
    if (count == 8 && day == 1) {
      if (this.selectedPrimaryForaward_8_day1 == id && this.selectedPrimaryCount_8_day1 === count && this.selected_8_day_1 == day) return true;else return false;
    }
    if (count == 9 && day == 1) {
      if (this.selectedPrimaryForaward_9_day1 == id && this.selectedPrimaryCount_9_day1 === count && this.selected_9_day_1 == day) return true;else return false;
    }
    // Day2
    if (count == 0 && day == 2) {
      if (this.selectedPrimaryForaward_0_day2 == id && this.selectedPrimaryCount_0_day2 === count && this.selected_0_day_2 == day) return true;else return false;
    }
    if (count == 1 && day == 2) {
      if (this.selectedPrimaryForaward_1_day2 == id && this.selectedPrimaryCount_1_day2 === count && this.selected_1_day_2 == day) return true;else return false;
    }
    if (count == 2 && day == 2) {
      if (this.selectedPrimaryForaward_2_day2 == id && this.selectedPrimaryCount_2_day2 === count && this.selected_2_day_2 == day) return true;else return false;
    }
    if (count == 3 && day == 2) {
      if (this.selectedPrimaryForaward_3_day2 == id && this.selectedPrimaryCount_3_day2 === count && this.selected_3_day_2 == day) return true;else return false;
    }
    if (count == 4 && day == 2) {
      if (this.selectedPrimaryForaward_4_day2 == id && this.selectedPrimaryCount_4_day2 === count && this.selected_4_day_2 == day) return true;else return false;
    }
    if (count == 5 && day == 2) {
      if (this.selectedPrimaryForaward_5_day2 == id && this.selectedPrimaryCount_5_day2 === count && this.selected_5_day_2 == day) return true;else return false;
    }
    if (count == 6 && day == 2) {
      if (this.selectedPrimaryForaward_6_day2 == id && this.selectedPrimaryCount_6_day2 === count && this.selected_6_day_2 == day) return true;else return false;
    }
    if (count == 7 && day == 2) {
      if (this.selectedPrimaryForaward_7_day2 == id && this.selectedPrimaryCount_7_day2 === count && this.selected_7_day_2 == day) return true;else return false;
    }
    if (count == 8 && day == 2) {
      if (this.selectedPrimaryForaward_8_day2 == id && this.selectedPrimaryCount_8_day2 === count && this.selected_8_day_2 == day) return true;else return false;
    }
    if (count == 9 && day == 2) {
      if (this.selectedPrimaryForaward_9_day2 == id && this.selectedPrimaryCount_9_day2 === count && this.selected_9_day_2 == day) return true;else return false;
    }
    // Day3
    if (count == 0 && day == 3) {
      if (this.selectedPrimaryForaward_0_day3 == id && this.selectedPrimaryCount_0_day3 === count && this.selected_0_day_3 == day) return true;else return false;
    }
    if (count == 1 && day == 3) {
      if (this.selectedPrimaryForaward_1_day3 == id && this.selectedPrimaryCount_1_day3 === count && this.selected_1_day_3 == day) return true;else return false;
    }
    if (count == 2 && day == 3) {
      if (this.selectedPrimaryForaward_2_day3 == id && this.selectedPrimaryCount_2_day3 === count && this.selected_2_day_3 == day) return true;else return false;
    }
    if (count == 3 && day == 3) {
      if (this.selectedPrimaryForaward_3_day3 == id && this.selectedPrimaryCount_3_day3 === count && this.selected_3_day_3 == day) return true;else return false;
    }
    if (count == 4 && day == 3) {
      if (this.selectedPrimaryForaward_4_day3 == id && this.selectedPrimaryCount_4_day3 === count && this.selected_4_day_3 == day) return true;else return false;
    }
    if (count == 5 && day == 3) {
      if (this.selectedPrimaryForaward_5_day3 == id && this.selectedPrimaryCount_5_day3 === count && this.selected_5_day_3 == day) return true;else return false;
    }
    if (count == 6 && day == 3) {
      if (this.selectedPrimaryForaward_6_day3 == id && this.selectedPrimaryCount_6_day3 === count && this.selected_6_day_3 == day) return true;else return false;
    }
    if (count == 7 && day == 3) {
      if (this.selectedPrimaryForaward_7_day3 == id && this.selectedPrimaryCount_7_day3 === count && this.selected_7_day_3 == day) return true;else return false;
    }
    if (count == 8 && day == 3) {
      if (this.selectedPrimaryForaward_8_day3 == id && this.selectedPrimaryCount_8_day3 === count && this.selected_8_day_3 == day) return true;else return false;
    }
    if (count == 9 && day == 3) {
      if (this.selectedPrimaryForaward_9_day3 == id && this.selectedPrimaryCount_9_day3 === count && this.selected_9_day_3 == day) return true;else return false;
    }
    // Day4
    if (count == 0 && day == 4) {
      if (this.selectedPrimaryForaward_0_day4 == id && this.selectedPrimaryCount_0_day4 === count && this.selected_0_day_4 == day) return true;else return false;
    }
    if (count == 1 && day == 4) {
      if (this.selectedPrimaryForaward_1_day4 == id && this.selectedPrimaryCount_1_day4 === count && this.selected_1_day_4 == day) return true;else return false;
    }
    if (count == 2 && day == 4) {
      if (this.selectedPrimaryForaward_2_day4 == id && this.selectedPrimaryCount_2_day4 === count && this.selected_2_day_4 == day) return true;else return false;
    }
    if (count == 3 && day == 4) {
      if (this.selectedPrimaryForaward_3_day4 == id && this.selectedPrimaryCount_3_day4 === count && this.selected_3_day_4 == day) return true;else return false;
    }
    if (count == 4 && day == 4) {
      if (this.selectedPrimaryForaward_4_day4 == id && this.selectedPrimaryCount_4_day4 === count && this.selected_4_day_4 == day) return true;else return false;
    }
    if (count == 5 && day == 4) {
      if (this.selectedPrimaryForaward_5_day4 == id && this.selectedPrimaryCount_5_day4 === count && this.selected_5_day_4 == day) return true;else return false;
    }
    if (count == 6 && day == 4) {
      if (this.selectedPrimaryForaward_6_day4 == id && this.selectedPrimaryCount_6_day4 === count && this.selected_6_day_4 == day) return true;else return false;
    }
    if (count == 7 && day == 4) {
      if (this.selectedPrimaryForaward_7_day4 == id && this.selectedPrimaryCount_7_day4 === count && this.selected_7_day_4 == day) return true;else return false;
    }
    if (count == 8 && day == 4) {
      if (this.selectedPrimaryForaward_8_day4 == id && this.selectedPrimaryCount_8_day4 === count && this.selected_8_day_4 == day) return true;else return false;
    }
    if (count == 9 && day == 4) {
      if (this.selectedPrimaryForaward_9_day4 == id && this.selectedPrimaryCount_9_day4 === count && this.selected_9_day_4 == day) return true;else return false;
    }
  }
  onReset() {
    this.submitted = false;
    this.editForm.reset();
  }
  selectednoofforwardinglocation() {
    let array = [];
    if (this.noofforwardinglocation_1 >= 10) {
      this.ite = 10;
    } else {
      this.ite = this.noofforwardinglocation_1;
    }
    for (let i = 0; i < this.ite; i++) {
      array.push(i);
    }
    return array;
  }
  selectednoofforwardinglocation_2() {
    let array = [];
    if (this.noofforwardinglocation_2 >= 10) {
      this.ite2 = 10;
    } else {
      this.ite2 = this.noofforwardinglocation_2;
    }
    for (let i = 0; i < this.ite2; i++) {
      array.push(i);
    }
    return array;
  }
  selectednoofforwardinglocation_3() {
    let array = [];
    if (this.noofforwardinglocation_3 >= 10) {
      this.ite3 = 10;
    } else {
      this.ite3 = this.noofforwardinglocation_3;
    }
    for (let i = 0; i < this.ite3; i++) {
      array.push(i);
    }
    return array;
  }
  selectednoofforwardinglocation_4() {
    let array = [];
    if (this.noofforwardinglocation_4 >= 10) {
      this.ite4 = 10;
    } else {
      this.ite4 = this.noofforwardinglocation_4;
    }
    for (let i = 0; i < this.ite4; i++) {
      array.push(i);
    }
    return array;
  }
  selectednoofforwardinglocation_5() {
    let array = [];
    if (this.noofforwardinglocation_5 >= 10) {
      this.ite5 = 10;
    } else {
      this.ite5 = this.noofforwardinglocation_5;
    }
    for (let i = 0; i < this.ite5; i++) {
      array.push(i);
    }
    return array;
  }
  selectednoofforwardinglocation_6() {
    let array = [];
    if (this.noofforwardinglocation_6 >= 10) {
      this.ite6 = 10;
    } else {
      this.ite6 = this.noofforwardinglocation_6;
    }
    for (let i = 0; i < this.ite6; i++) {
      array.push(i);
    }
    return array;
  }
  selectednoofforwardinglocation_7() {
    let array = [];
    if (this.noofforwardinglocation_7 >= 10) {
      this.ite7 = 10;
    } else {
      this.ite7 = this.noofforwardinglocation_7;
    }
    for (let i = 0; i < this.ite7; i++) {
      array.push(i);
    }
    return array;
  }
  onFSLReset() {
    this.FSLRulesSubmitted = false;
    this.addFSLRules.reset();
  }
  selected() {
    let array = [];
    for (let i = 0; i < this.noofforwarding; i++) {
      array.push(i);
    }
    return array;
  }
  Delete(id) {
    // alert(id)
    sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire({
      title: 'Are you sure?',
      text: 'You want to Delete Record!',
      showCancelButton: true,
      confirmButtonText: 'Yes, delete it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        this.moduleService.deleteFSLRulesbyname(id).subscribe(res => {
          // this.getAllRules();
          this.getalldata();
          sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Deleted!', 'FSL Deleted Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
          }, 2000);
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Cancelled', 'Your Record is safe :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
        }, 2000);
      }
    });
  }
  addremoverow(type) {
    if (type == 0) {
      this.isadded = 1;
    }
    if (type == 1) {
      this.isadded = 0;
    }
  }
  static #_ = this.ctorParameters = () => [{
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_6__.FormBuilder
  }, {
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_7__.Router
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_7__.ActivatedRoute
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_8__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_5__.HttpBackend
  }, {
    type: _angular_core__WEBPACK_IMPORTED_MODULE_9__.ChangeDetectorRef
  }, {
    type: ngx_ui_loader__WEBPACK_IMPORTED_MODULE_10__.NgxUiLoaderService
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_11__.Title
  }];
  static #_2 = this.propDecorators = {
    myInputVariable: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_9__.ViewChild,
      args: ['myInput']
    }]
  };
};
NumbereditComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_12__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_9__.Component)({
  selector: 'app-numberedit',
  template: _numberedit_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_numberedit_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], NumbereditComponent);


/***/ }),

/***/ 85351:
/*!******************************************************************************!*\
  !*** ./src/app/modules/numbers/blocked-numbers/blocked-numbers.component.ts ***!
  \******************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "BlockedNumbersComponent": () => (/* binding */ BlockedNumbersComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _blocked_numbers_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./blocked-numbers.component.html?ngResource */ 93268);
/* harmony import */ var _blocked_numbers_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./blocked-numbers.component.scss?ngResource */ 69735);
/* harmony import */ var _blocked_numbers_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_blocked_numbers_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../../module.service */ 22947);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! sweetalert2 */ 60598);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(sweetalert2__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../global */ 27266);
/* harmony import */ var ngx_csv_ngx_csv__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ngx-csv/ngx-csv */ 94551);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/platform-browser */ 34497);








//import 'sweetalert2/src/sweetalert2.scss'




class DataTablesResponse {}
let BlockedNumbersComponent = class BlockedNumbersComponent {
  constructor(moduleservice, toastrService, handler, fb, titleService) {
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.fb = fb;
    this.titleService = titleService;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_4__.GlobalVariable.BASE_API_URL;
    this.dtOptions = {};
    this.Submitted = false;
    this.ischecked = '1';
    this.data = {};
    this.block = 0;
    this.iscampaign = 0;
    this.isspecifyduration = 0;
    this.editblock = 0;
    this.editiscampaign = 0;
    this.editisspecifyduration = 0;
    this.checkboxes = [];
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_6__.HttpClient(handler);
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngOnInit() {
    this.setTitle('Block Number');
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.loadblocknumbers();
    this.addForm = this.fb.group({
      block_type: [''],
      blocked_number: [''],
      blocked_prefix: [''],
      scope: [''],
      campaign_uuid: [''],
      duration: ['']
    });
    this.addForm.get('block_type').setValue(0);
    // this.editForm.get('editblock_type').setValue(0);
    this.editForm = this.fb.group({
      uuid: [''],
      editblock_type: [''],
      blocked_number: [''],
      blocked_prefix: [''],
      scope: [''],
      campaign_uuid: [''],
      duration: ['']
    });
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleservice.getallcampain(this.currentCompany.uuid).subscribe(res => {
      // console.log(res);return false;    
      this.allcampaign = res.active;
    }, error => this.error = error);
  }
  block_numbertype(val) {
    this.block = val;
    this.addForm.get('block_type').setValue(this.block);
  }
  scopetype(val) {
    this.iscampaign = val;
    this.addForm.get('scope').setValue(this.iscampaign);
  }
  isduration(event) {
    // console.log(event.target.checked);
    if (event.target.checked == true) {
      this.editisspecifyduration = 1;
      this.isspecifyduration = 1;
    }
    if (event.target.checked == false) {
      this.editisspecifyduration = 0;
      this.isspecifyduration = 0;
    }
  }
  editblock_numbertype(val) {
    // alert(val);
    this.editblock = val;
    this.editForm.get('editblock_type').setValue(val);
  }
  editscopetype(val) {
    this.editiscampaign = val;
    this.editForm.get('scope').setValue(val);
  }
  editisduration(event) {
    // console.log(event.target.checked);
    if (event.target.checked == true) {
      this.editisspecifyduration = 1;
    }
    if (event.target.checked == false) {
      this.editisspecifyduration = 0;
    }
  }
  loadblocknumbers() {
    if ($.fn.DataTable.isDataTable(this.table.nativeElement)) {
      $(this.table.nativeElement).dataTable().fnDestroy();
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.dtOptions = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "pageLength": 20,
      "lengthMenu": [[-1, 20, 100, 500, 2000], ["All", 20, 100, 500, 2000]],
      "order": [[2, "desc"]],
      ajax: (dataTablesParameters, callback) => {
        this.http.post(this.ServerUrl + 'getblocked_numbers/' + this.currentCompany.uuid, dataTablesParameters, {}).subscribe(resp => {
          // console.log(resp.data);
          this.blocknumbers = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [{
        data: "blocked_number"
      }, {
        data: "campaign"
      }, {
        data: "blocked_until"
      }, {
        data: "created_at"
      }, {
        data: "action"
      }],
      columnDefs: [{
        "targets": [0],
        "orderable": false
      }]
    };
    this.dataTable = $(this.table.nativeElement);
    this.dataTable.dataTable(this.dtOptions);
  }
  Delete(uuid) {
    sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
      title: 'Are you sure?',
      text: 'You want to Delete Record!',
      showCancelButton: true,
      confirmButtonText: 'Yes, delete it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        this.moduleservice.deleteblckedno(uuid).subscribe(res => {
          // console.log(res);return false;
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Record Deleted Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
          this.loadblocknumbers();
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
        }, 2000);
      }
    });
  }
  //Add Labels
  get labelcontrol() {
    return this.addForm.controls;
  }
  onSubmit() {
    const formData = new FormData();
    this.Submitted = true;
    if (this.addForm.invalid) {
      return;
    }
    // alert(this.isspecifyduration);return false;
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('block_type', this.addForm.get('block_type').value);
    formData.append('blocked_number', this.addForm.get('blocked_number').value);
    formData.append('blocked_prefix', this.addForm.get('blocked_prefix').value);
    formData.append('scope', this.addForm.get('scope').value);
    formData.append('campaign_uuid', this.addForm.get('campaign_uuid').value);
    formData.append('is_duration', this.isspecifyduration);
    formData.append('duration', this.addForm.get('duration').value);
    this.moduleservice.addblockedcalls(formData, this.currentCompany.uuid).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Number Blocked Successfully');
        this.loadblocknumbers();
        this.Submitted = false;
      } else {
        this.toastrService.error('Failed To Add');
      }
    }, error => this.error = error);
  }
  closeModal() {
    $("#addLabels").modal("hide");
    if (this.addForm.get('block_type').value == 0 || this.addForm.get('block_type').value == 1 || this.addForm.get('block_type').value == 2) {
      $(".custom-switch-input").prop('checked', false);
      this.Submitted = false;
      setTimeout(() => {
        this.addForm.reset();
        this.block = 0;
        this.isspecifyduration = 0;
        this.iscampaign = 0;
        this.block_numbertype(0);
        this.scopetype(0);
      }, 2000);
    }
  }
  editcloseModal() {
    $("#editLabels").modal("hide");
    $(".custom-switch-input").prop('checked', false);
    this.Submitted = false;
  }
  // Edit data
  editdata(uuid, block_type, blocked_number, blocked_prefix, scope, campaign_uuid, is_duration, blocked_until) {
    this.editblock = block_type;
    this.editiscampaign = scope;
    // console.log(is_duration);
    // if(blocked_until!='' && blocked_until!='∞'){
    this.editisspecifyduration = is_duration;
    // }else{
    //   this.editisspecifyduration=0;
    // }
    this.editForm.patchValue({
      uuid: uuid,
      blocked_number: blocked_number,
      blocked_prefix: blocked_number,
      campaign_uuid: campaign_uuid,
      duration: blocked_until
    });
  }
  get labeleditcontrol() {
    return this.editForm.controls;
  }
  onEditSubmit() {
    const formData = new FormData();
    if (this.editForm.invalid) {
      return;
    }
    // alert(this.editForm.get('editblock_type').value);
    // alert(this.editblock)
    // alert(this.editisspecifyduration);
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('block_type', this.editForm.get('editblock_type').value);
    formData.append('blocked_number', this.editForm.get('blocked_number').value);
    formData.append('blocked_prefix', this.editForm.get('blocked_prefix').value);
    formData.append('scope', this.editForm.get('scope').value);
    formData.append('campaign_uuid', this.editForm.get('campaign_uuid').value);
    formData.append('duration', this.editForm.get('duration').value);
    formData.append('is_duration', this.editisspecifyduration);
    this.moduleservice.editblockednumbers(formData, this.editForm.get('uuid').value).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.loadblocknumbers();
        this.toastrService.success('Blocked Number data Updated Successfully');
      } else {
        this.toastrService.error('Failed To Update Data');
      }
    }, error => this.error = error);
  }
  exportdata() {
    var options = {
      fieldSeparator: ',',
      quoteStrings: '"',
      decimalseparator: '.',
      showLabels: true,
      // showTitle: true,
      // title: 'Your title',
      useBom: true,
      // noDownload: true,
      headers: ["Label Name", "Notes", "Created At"]
    };
    new ngx_csv_ngx_csv__WEBPACK_IMPORTED_MODULE_5__.ngxCsv(this.blocknumbers, 'All Blocked Numbers', options);
  }
  checkalldelete(event) {
    const checked = event.target.checked;
    this.blocknumbers.forEach(chkbox => chkbox.selected = checked);
  }
  deleteselected(event) {
    // $("#customCheck1").prop("checked", false);    
    if (event.target.checked == true) {
      if (event.target.value == 'on') {
        this.checkboxes = [];
        this.blocknumbers.forEach(lbl => {
          this.checkboxes.push(lbl.id);
        });
      } else {
        if (this.checkboxes.length + 1 == this.blocknumbers.length) {
          $("#customCheck1").prop("checked", true);
        }
        this.checkboxes.push(event.target.value);
      }
      this.ischecked = '0';
    } else {
      // console.log(this.checkboxes);      
      if (this.checkboxes.length != 0) {
        $("#customCheck1").prop("checked", false);
      }
      if (event.target.value != 'on') {
        const index = this.checkboxes.indexOf(event.target.value);
        this.checkboxes.splice(index, 1);
      } else {
        this.checkboxes = [];
      }
      this.ischecked = '1';
    }
    // console.log(this.checkboxes); 
  }

  onDeleteSubmit() {
    if (this.checkboxes.length == 0) {
      this.toastrService.error('Please Select Row To Delete');
    } else {
      // console.log(this.checkboxes);  
      sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
        title: 'Are you sure?',
        text: 'You want to Delete Selected Record!',
        showCancelButton: true,
        confirmButtonText: 'Yes, delete it!',
        cancelButtonText: 'No, keep it'
      }).then(result => {
        if (result.value) {
          this.moduleservice.deleteSelectedLabels(this.checkboxes).subscribe(res => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Records Deleted Successfully.');
            setTimeout(() => {
              sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
            }, 2000);
            this.loadblocknumbers();
          }, error => this.error = error);
        } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
        }
      });
    }
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_7__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_6__.HttpBackend
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_8__.FormBuilder
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_9__.Title
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_10__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }]
  };
};
BlockedNumbersComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_11__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_10__.Component)({
  selector: 'app-blocked-numbers',
  template: _blocked_numbers_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_blocked_numbers_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], BlockedNumbersComponent);


/***/ }),

/***/ 25700:
/*!**********************************************************************!*\
  !*** ./src/app/modules/numbers/number-pool/number-pool.component.ts ***!
  \**********************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "NumberPoolComponent": () => (/* binding */ NumberPoolComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _number_pool_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./number-pool.component.html?ngResource */ 47562);
/* harmony import */ var _number_pool_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./number-pool.component.scss?ngResource */ 50957);
/* harmony import */ var _number_pool_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_number_pool_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../../module.service */ 22947);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! sweetalert2 */ 60598);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(sweetalert2__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./../../../global */ 27266);









//import 'sweetalert2/src/sweetalert2.scss'


const router = _angular_router__WEBPACK_IMPORTED_MODULE_5__.Router;
class DataTablesResponse {}
let NumberPoolComponent = class NumberPoolComponent {
  constructor(moduleservice, toastrService, handler, fb, router, cdRef) {
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.fb = fb;
    this.router = router;
    this.cdRef = cdRef;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_4__.GlobalVariable.BASE_API_URL;
    this.dtOptions = {};
    this.ischecked = '1';
    this.labels = [];
    this.checkboxes = [];
    this.selectednumber = [];
    this.Submitted = false;
    this.editSubmitted = false;
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_6__.HttpClient(handler);
  }
  ngAfterViewChecked() {
    this.cdRef.detectChanges();
  }
  ngOnInit() {
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.loadNumberpools();
    this.addForm = this.fb.group({
      country_id: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      closed_browser_delay: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      browser_idle_limit: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      poolsize: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      allocating: [''],
      user_uuid: ['']
    });
    this.addForm.patchValue({
      country: 'United States',
      prefix: '+1'
    });
    this.editForm = this.fb.group({
      uuid: [''],
      country_id: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      closed_browser_delay: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      browser_idle_limit: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      poolsize: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      allocating: [''],
      user_uuid: ['']
    });
  }
  loadNumberpools() {
    // console.log('ok');
    // return false;
    if ($.fn.DataTable.isDataTable(this.table.nativeElement)) {
      $(this.table.nativeElement).dataTable().fnDestroy();
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.dtOptions = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "pageLength": 5000,
      "lengthMenu": [50, 100, 500, 1000, 2000, 5000],
      "order": [[1, "asc"]],
      ajax: (dataTablesParameters, callback) => {
        // this.http.post<DataTablesResponse>(
        //   this.ServerUrl+'getnumbersdata/'+this.currentCompany.uuid,
        //   dataTablesParameters, {}
        this.http.post(this.ServerUrl + 'getnumberpoolsdata/' + this.currentCompany.uuid, {
          'dataTablesParameters': dataTablesParameters
        }, {}).subscribe(resp => {
          this.numbers = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [{
        data: "checkall"
      }, {
        data: "name"
      }, {
        data: "country_id"
      }, {
        data: "closed_browser_delay"
      }, {
        data: "browser_idle_limit"
      }, {
        data: "poolsize"
      }, {
        data: "allocating"
      }, {
        data: "action"
      }],
      columnDefs: [{
        "targets": [0],
        "orderable": false
      }]
    };
    this.dataTable = $(this.table.nativeElement);
    this.dataTable.dataTable(this.dtOptions);
  }
  editdata(uuid, name, country_id, closed_browser_delay, browser_idle_limit, poolsize, allocating) {
    // alert(publisher);
    this.numberTypeadd = allocating;
    this.editForm.patchValue({
      uuid: uuid,
      name: name,
      country_id: country_id,
      closed_browser_delay: closed_browser_delay,
      browser_idle_limit: browser_idle_limit,
      poolsize: poolsize,
      allocating: allocating
    });
  }
  checkalldelete(event) {
    const checked = event.target.checked;
    this.numbers.forEach(chkbox => chkbox.selected = checked);
  }
  deleteselected(event) {
    // $("#customCheck1").prop("checked", false);    
    if (event.target.checked == true) {
      if (event.target.value == 'on') {
        this.checkboxes = [];
        this.selectednumber = [];
        this.numbers.forEach(lbl => {
          this.checkboxes.push(lbl.id);
          this.selectednumber.push(lbl.number);
        });
      } else {
        if (this.checkboxes.length + 1 == this.numbers.length) {
          $("#customCheck1").prop("checked", true);
        }
        this.checkboxes.push(event.target.value);
        this.numbers.forEach(lbl => {
          if (event.target.value == lbl.id) {
            this.selectednumber.push(lbl.number);
          }
        });
        // this.selectednumber.push(event.target.value);        
      }

      this.ischecked = '0';
    } else {
      // console.log(this.ischecked); 
      if (this.checkboxes.length != 0) {
        $("#customCheck1").prop("checked", false);
      }
      if (event.target.value != 'on') {
        const index = this.checkboxes.indexOf(event.target.value);
        this.checkboxes.splice(index, 1);
        this.selectednumber.splice(index, 1);
        // console.log('123='+this.selectednumber.length);
        if (this.selectednumber.length == 0) {
          this.ischecked = '1';
        }
      } else {
        this.checkboxes = [];
        this.selectednumber = [];
        // console.log(this.selectednumber.length);
        if (this.selectednumber.length == 0) {
          this.ischecked = '1';
        }
      }
    }
    // console.log(this.ischecked); 
  }

  onDeleteSubmit() {
    if (this.checkboxes.length == 0) {
      this.toastrService.error('Please Select Row To Delete');
    } else {
      // console.log(this.checkboxes);  
      sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
        title: 'Are you sure?',
        text: 'You want to Delete Selected Record!',
        showCancelButton: true,
        confirmButtonText: 'Yes, delete it!',
        cancelButtonText: 'No, keep it'
      }).then(result => {
        if (result.value) {
          this.moduleservice.deleteSelectedNumbers(this.checkboxes).subscribe(res => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Records Deleted Successfully.');
            setTimeout(() => {
              sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
            }, 2000);
            this.loadNumberpools();
          }, error => this.error = error);
        } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
        }
      });
    }
  }
  Delete(uuid) {
    sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
      title: 'Are you sure?',
      text: 'You want to Delete Record!',
      showCancelButton: true,
      confirmButtonText: 'Yes, delete it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        let currentUser = JSON.parse(localStorage.getItem('currentUser'));
        this.moduleservice.deleteNumberpooldata(uuid, currentUser.uuid).subscribe(res => {
          // console.log(res);return false;
          this.loadNumberpools();
          // this.toastrService.success('Number Deleted Successfully');
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Record Deleted Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
        }, 2000);
      }
    });
  }
  //Add Publisher
  get addformcontrol() {
    return this.addForm.controls;
  }
  onSubmit() {
    const formData = new FormData();
    this.Submitted = true;
    if (this.addForm.invalid) {
      return;
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    formData.append('user_uuid', currentUser.uuid);
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('country_id', this.addForm.get('country_id').value);
    formData.append('name', this.addForm.get('name').value);
    formData.append('closed_browser_delay', this.addForm.get('closed_browser_delay').value);
    formData.append('browser_idle_limit', this.addForm.get('browser_idle_limit').value);
    formData.append('poolsize', this.addForm.get('poolsize').value);
    formData.append('allocating', this.addForm.get('allocating').value);
    this.moduleservice.addNumberpooldata(formData).subscribe(res => {
      // console.log(res.status); return false;
      if (res.status == 'error') {
        this.toastrService.error('Failed To Add Number Pool');
      } else {
        this.toastrService.success('Number Pool Added Successfully');
        this.loadNumberpools();
        this.Submitted = false;
      }
    }, error => this.error = error);
  }
  numberTypeval(val) {
    this.addForm.get('allocating').setValue(val);
  }
  //Add Buyer
  get editFormcontrol() {
    return this.editForm.controls;
  }
  onEditSubmit() {
    // this.editForm.get('assosciated_labels').setValue(JSON.stringify(this.labels)); 
    // alert('ok');return false;
    const formData = new FormData();
    this.editSubmitted = true;
    if (this.editForm.invalid) {
      return;
    }
    // console.log(this.labels);return false;
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    formData.append('user_uuid', currentUser.uuid);
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('uuid', this.editForm.get('uuid').value);
    formData.append('country_id', this.editForm.get('country_id').value);
    formData.append('name', this.editForm.get('name').value);
    formData.append('closed_browser_delay', this.editForm.get('closed_browser_delay').value);
    formData.append('browser_idle_limit', this.editForm.get('browser_idle_limit').value);
    formData.append('poolsize', this.editForm.get('poolsize').value);
    formData.append('allocating', this.editForm.get('allocating').value);
    this.moduleservice.editNumberpooldata(formData).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Number Pool Updated Successfully');
        this.loadNumberpools();
        this.editSubmitted = false;
      } else {
        this.toastrService.error('Failed To Add Label');
      }
    }, error => this.error = error);
  }
  closeModal() {
    // console.log(this.addForm.get('country').value);return false;
    if (!this.addForm.invalid) {
      $("#addModel").modal("hide");
      // $(".custom-switch-input").prop('checked',false);
      this.Submitted = false;
      setTimeout(() => {
        this.addForm.reset();
      }, 2000);
    }
  }
  closeEditModal() {
    if (!this.editForm.invalid) {
      $("#editModel").modal("hide");
      this.editSubmitted = false;
      setTimeout(() => {
        this.editForm.reset();
      }, 2000);
    }
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_8__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_6__.HttpBackend
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_7__.FormBuilder
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_5__.Router
  }, {
    type: _angular_core__WEBPACK_IMPORTED_MODULE_9__.ChangeDetectorRef
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_9__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }]
  };
};
NumberPoolComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_10__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_9__.Component)({
  selector: 'app-number-pool',
  template: _number_pool_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_number_pool_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], NumberPoolComponent);


/***/ }),

/***/ 13224:
/*!******************************************************!*\
  !*** ./src/app/modules/numbers/numbers.component.ts ***!
  \******************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "NumbersComponent": () => (/* binding */ NumbersComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _numbers_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./numbers.component.html?ngResource */ 15514);
/* harmony import */ var _numbers_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./numbers.component.scss?ngResource */ 75226);
/* harmony import */ var _numbers_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_numbers_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../module.service */ 22947);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! sweetalert2 */ 60598);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(sweetalert2__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../global */ 27266);
/* harmony import */ var ngx_csv_ngx_csv__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ngx-csv/ngx-csv */ 94551);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! @angular/platform-browser */ 34497);
/* harmony import */ var ngx_ui_loader__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! ngx-ui-loader */ 36413);









//import 'sweetalert2/src/sweetalert2.scss'



const router = _angular_router__WEBPACK_IMPORTED_MODULE_6__.Router;


class DataTablesResponse {}
let NumbersComponent = class NumbersComponent {
  constructor(moduleservice, toastrService, handler, fb, router, cdRef, titleService, ngxLoader) {
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.fb = fb;
    this.router = router;
    this.cdRef = cdRef;
    this.titleService = titleService;
    this.ngxLoader = ngxLoader;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_4__.GlobalVariable.BASE_API_URL;
    this.dtOptions = {};
    this.ischecked = '1';
    this.campaigndropdownSettings = {};
    this.dropdownList = [];
    this.selectedItems = [];
    this.dropdownSettings = {
      singleSelection: false,
      text: "Select Associated Labels",
      selectAllText: 'Select All',
      unSelectAllText: 'UnSelect All',
      enableSearchFilter: true,
      classes: "myclass custom-class"
    };
    this.searchbynumbers = '';
    this.searchbycampaign = '';
    this.searchbylabels = '';
    this.role = "";
    this.useruuid = "";
    this.selectedItemspub = [];
    this.selectedItemscam = [];
    this.labels = [];
    this.checkboxes = [];
    this.selectednumber = [];
    this.payout_typevalueedit = 0;
    this.payoutedit_typevalue = 0;
    this.Submitted = false;
    this.editSubmitted = false;
    this.LabelSubmitted = false;
    this.exportNumber = {};
    this.finalexportNumber = [];
    this.url = 'https://www.wellingtonsoccer.com/lib/api/auth.cfc?returnFormat=JSON&method=Authenticate';
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_7__.HttpClient(handler);
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  getAllLabels() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleservice.getAllLabels(this.currentCompany.uuid).subscribe(res => {
      this.dropdownList = res;
      // console.log(res);
    }, error => this.error = error);
  }
  ngAfterViewChecked() {
    this.cdRef.detectChanges();
  }
  ngOnInit() {
    this.setTitle('Manage Numbers');
    var loggedinuser = JSON.parse(localStorage.getItem('currentUser'));
    if (loggedinuser != null) {
      this.role = loggedinuser.role;
      this.useruuid = loggedinuser.uuid;
    }
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.loadNumbers();
    this.getAllpublishers();
    this.getAllLabels();
    this.getAllcampaign();
    this.campaigndropdownSettings = {
      singleSelection: true,
      text: "Select Campaign",
      enableSearchFilter: true,
      classes: "myclass custom-class",
      showCheckbox: false
    };
    this.addForm = this.fb.group({
      country: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_8__.Validators.required],
      numberType: [''],
      prefix: [''],
      number: [''],
      publisher: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_8__.Validators.required],
      payout_typeedit: [''],
      payout_amount: [''],
      payout_trigger: [''],
      payout_seconds: [''],
      campain: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_8__.Validators.required],
      assosciated_labels: [''],
      user_uuid: ['']
    });
    // let prefix="";
    // if(this.addForm.get('country').value=="United Kingdom"){
    //   prefix = "+1";
    // }
    // if(this.addForm.get('country').value=="United States"){
    //   prefix = "+44";
    // }
    this.addForm.patchValue({
      country: 'United States',
      prefix: "+1"
    });
    this.editForm = this.fb.group({
      country: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_8__.Validators.required],
      uuid: [''],
      numberType: [''],
      prefix: [''],
      number: [''],
      publisher: [''],
      payout_uuid: [''],
      payout_typeedit: [''],
      payout_amount: [''],
      payout_trigger: [''],
      payout_seconds: [''],
      campain: [''],
      assosciated_labels: [''],
      user_uuid: ['']
    });
    this.addLabelForm = this.fb.group({
      name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_8__.Validators.required],
      notes: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_8__.Validators.required]
    });
  }
  getAllpublishers() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleservice.getAllpublishers(this.currentCompany.uuid).subscribe(res => {
      //  console.log(res); return false;
      this.publishers = res;
    }, error => this.error = error);
  }
  getAllcampaign() {
    this.moduleservice.getallcampaindata(this.currentCompany.uuid).subscribe(res => {
      this.getallcampain = res;
      // console.log(this.getallcampain);
    });
  }

  loadNumbers() {
    // console.log('ok');
    // return false;
    if ($.fn.DataTable.isDataTable(this.table.nativeElement)) {
      $(this.table.nativeElement).dataTable().fnDestroy();
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.dtOptions = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "pageLength": 1000,
      deferRender: true,
      scrollY: "800px",
      scrollCollapse: true,
      "lengthMenu": [50, 100, 500, 1000, 2000, 5000],
      "order": [[1, "asc"]],
      ajax: (dataTablesParameters, callback) => {
        // this.http.post<DataTablesResponse>(
        //   this.ServerUrl+'getnumbersdata/'+this.currentCompany.uuid,
        //   dataTablesParameters, {}
        this.http.post(this.ServerUrl + 'getnumbersdata/' + this.currentCompany.uuid, {
          'dataTablesParameters': dataTablesParameters,
          'number': this.searchbynumbers,
          'campaign': this.searchbycampaign,
          'labels': this.searchbylabels,
          role: this.role,
          useruuid: this.useruuid
        }, {}).subscribe(resp => {
          this.numbers = resp.data;
          // console.log(this.numbers);
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [
      // ,{data:"target"}
      {
        data: "checkall"
      }, {
        data: "number"
      }, {
        data: "campaign"
      }, {
        data: "publisher"
      }, {
        data: "status"
      }, {
        data: "created_at"
      }, {
        data: "assosciated_label"
      }, {
        data: "action"
      }],
      columnDefs: [{
        "targets": [0],
        "orderable": false
      }]
    };
    this.dataTable = $(this.table.nativeElement);
    this.dataTable.dataTable(this.dtOptions);
  }
  editdata(uuid, prefix, numberType, number, country, publisher, campaign_uuid) {
    console.log(publisher);
    if (campaign_uuid != "" || campaign_uuid != undefined) {
      let text = this.getallcampain.filter(x => x.id == campaign_uuid)[0];
      this.selectedItemscam = [{
        "id": campaign_uuid,
        "itemName": text.text
      }];
    }
    if (publisher != "" || publisher != undefined) {
      let text = this.publishers.filter(x => x.id == publisher)[0];
      this.selectedItemspub = [{
        "id": publisher,
        "itemName": text.text
      }];
    }
    // console.log(this.selectedItemscam);
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleservice.getnumberAssciatedlabels(this.currentCompany.uuid, number).subscribe(res => {
      this.labels = res;
      //  console.log(this.labels);
    }, error => this.error = error);
    this.moduleservice.getpayoutbynumberuuid(uuid).subscribe(res => {
      //  console.log(this.payoutdata);
      if (res != '') {
        this.payoutedit_typevalue = res.payout_type;
        this.editForm.get('payout_uuid').setValue(res.uuid);
        this.editForm.patchValue({
          payout_typeedit: res.payout_typeedit,
          payout_amount: res.payout_amount,
          payout_trigger: res.payout_trigger,
          payout_seconds: res.payout_seconds
        });
      }
    }, error => this.error = error);
    let editprefix = "";
    if (country == "United Kingdom") {
      editprefix = "+44";
    }
    if (country == "United States") {
      editprefix = "+1";
    }
    this.numberTypeadd = numberType;
    this.editForm.patchValue({
      uuid: uuid,
      country: country,
      numberType: numberType,
      prefix: editprefix,
      number: number
    });
  }
  checkalldelete(event) {
    const checked = event.target.checked;
    this.numbers.forEach(chkbox => chkbox.selected = checked);
  }
  deleteselected(event) {
    // $("#customCheck1").prop("checked", false);
    if (event.target.checked == true) {
      if (event.target.value == 'on') {
        this.checkboxes = [];
        this.selectednumber = [];
        this.numbers.forEach(lbl => {
          this.checkboxes.push(lbl.id);
          this.selectednumber.push(lbl.number);
        });
      } else {
        if (this.checkboxes.length + 1 == this.numbers.length) {
          $("#customCheck1").prop("checked", true);
        }
        this.checkboxes.push(event.target.value);
        this.numbers.forEach(lbl => {
          if (event.target.value == lbl.id) {
            this.selectednumber.push(lbl.number);
          }
        });
        // this.selectednumber.push(event.target.value);
      }

      this.ischecked = '0';
    } else {
      // console.log(this.ischecked);
      if (this.checkboxes.length != 0) {
        $("#customCheck1").prop("checked", false);
      }
      if (event.target.value != 'on') {
        const index = this.checkboxes.indexOf(event.target.value);
        this.checkboxes.splice(index, 1);
        this.selectednumber.splice(index, 1);
        // console.log('123='+this.selectednumber.length);
        if (this.selectednumber.length == 0) {
          this.ischecked = '1';
        }
      } else {
        this.checkboxes = [];
        this.selectednumber = [];
        // console.log(this.selectednumber.length);
        if (this.selectednumber.length == 0) {
          this.ischecked = '1';
        }
      }
    }
    // console.log(this.ischecked);
  }

  onBatchEditSubmit() {
    // console.log(this.selectednumber); return
    this.moduleservice.setNumbersdata({
      numberslist: this.selectednumber
    });
    this.router.navigate(['/batch-edit']);
  }
  onDeleteSubmit() {
    if (this.checkboxes.length == 0) {
      this.toastrService.error('Please Select Row To Delete');
    } else {
      // console.log(this.checkboxes);
      sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
        title: 'Are you sure?',
        text: 'You want to Delete Selected Record!',
        showCancelButton: true,
        confirmButtonText: 'Yes, delete it!',
        cancelButtonText: 'No, keep it'
      }).then(result => {
        if (result.value) {
          this.moduleservice.deleteSelectedNumbers(this.checkboxes).subscribe(res => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Records Deleted Successfully.');
            setTimeout(() => {
              sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
            }, 2000);
            this.loadNumbers();
          }, error => this.error = error);
        } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
        }
      });
    }
  }
  onStatusChangeSubmit() {
    // console.log(this.checkboxes);
    if (this.checkboxes.length == 0) {
      this.toastrService.error('Please Select Row To Status Change');
    } else {
      // console.log(this.checkboxes);
      sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
        title: 'Are you sure?',
        text: 'You want to Change status of selected record!',
        showCancelButton: true,
        confirmButtonText: 'Yes, Change it!',
        cancelButtonText: 'No, keep it'
      }).then(result => {
        if (result.value) {
          this.moduleservice.StatusChangeSelectedNumbers(this.checkboxes).subscribe(res => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Status Changed!', 'Status Changed Successfully.');
            setTimeout(() => {
              sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
            }, 2000);
            this.checkboxes = [];
            this.loadNumbers();
          }, error => this.error = error);
        } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
        }
      });
    }
  }
  Delete(uuid, number, company_uuid) {
    this.ngxLoader.startLoader('loader-01');
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.moduleservice.getNumberdatabyno(number, company_uuid).subscribe(res => {
      this.ngxLoader.stopLoader('loader-01');
      sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
        title: 'Are you sure?',
        html: `Hey! You're trying to delete a number that has received <span class="text-danger"><b>${res.allcalls}</b></span> calls in the past <span class="text-success"><b>7 days</b></span>, are you sure you want to delete this?`,
        showCancelButton: true,
        confirmButtonText: 'Yes, delete it!',
        cancelButtonText: 'No, keep it'
      }).then(result => {
        if (result.value) {
          this.moduleservice.deleteNumberdata(uuid, currentUser.uuid).subscribe(res => {
            // console.log(res);return false;
            this.loadNumbers();
            // this.toastrService.success('Number Deleted Successfully');
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Record Deleted Successfully.');
            setTimeout(() => {
              sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
            }, 2000);
          }, error => this.error = error);
        } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
        }
      });
    });
  }
  numberTypeval(val) {
    this.addForm.get('numberType').setValue(val);
  }
  payout_typevaledit(val) {
    this.payout_typevalueedit = val;
    this.addForm.get('payout_typeedit').setValue(val);
  }
  payoutedit_typeval(val) {
    this.payoutedit_typevalue = val;
    this.editForm.get('payout_typeedit').setValue(val);
  }
  //Add Publisher
  get addformcontrol() {
    return this.addForm.controls;
  }
  onSubmit() {
    const formData = new FormData();
    this.Submitted = true;
    if (this.addForm.invalid) {
      return;
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    formData.append('user_uuid', currentUser.uuid);
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('country', this.addForm.get('country').value);
    formData.append('numberType', this.addForm.get('numberType').value);
    formData.append('prefix', this.addForm.get('prefix').value);
    formData.append('number', this.addForm.get('number').value);
    formData.append('publisher', JSON.stringify(this.addForm.get('publisher').value));
    formData.append('payout_typeedit', this.addForm.get('payout_typeedit').value);
    formData.append('payout_amount', this.addForm.get('payout_amount').value);
    formData.append('payout_trigger', this.addForm.get('payout_trigger').value);
    formData.append('payout_seconds', this.addForm.get('payout_seconds').value);
    formData.append('campain', JSON.stringify(this.addForm.get('campain').value));
    formData.append('assosciated_labels', JSON.stringify(this.addForm.get('assosciated_labels').value));
    // console.log(formData); return false;
    this.moduleservice.addNumberdata(formData).subscribe(res => {
      // console.log(res.status); return false;
      if (res.status == 'error') {
        this.toastrService.error('Failed To Add Label');
      } else if (res.status == 'duplicate') {
        this.toastrService.error('The Number you Entered is Already Available');
      } else {
        this.toastrService.success('Number Added Successfully');
        this.loadNumbers();
        this.Submitted = false;
      }
    }, error => this.error = error);
  }
  //Add Buyer
  get editFormcontrol() {
    return this.editForm.controls;
  }
  onEditSubmit() {
    // this.editForm.get('assosciated_labels').setValue(JSON.stringify(this.labels));
    // alert('ok');return false;
    const formData = new FormData();
    this.editSubmitted = true;
    if (this.editForm.invalid) {
      return;
    }
    // console.log(this.labels);return false;
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    formData.append('user_uuid', currentUser.uuid);
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('uuid', this.editForm.get('uuid').value);
    formData.append('country', this.editForm.get('country').value);
    formData.append('numberType', this.editForm.get('numberType').value);
    formData.append('prefix', this.editForm.get('prefix').value);
    formData.append('number', this.editForm.get('number').value);
    formData.append('payout_uuid', this.editForm.get('payout_uuid').value);
    formData.append('publisher', JSON.stringify(this.editForm.get('publisher').value));
    formData.append('payout_typeedit', this.editForm.get('payout_typeedit').value);
    formData.append('payout_amount', this.editForm.get('payout_amount').value);
    formData.append('payout_trigger', this.editForm.get('payout_trigger').value);
    formData.append('payout_seconds', this.editForm.get('payout_seconds').value);
    formData.append('campain', JSON.stringify(this.editForm.get('campain').value));
    formData.append('assosciated_labels', JSON.stringify(this.labels));
    this.moduleservice.editNumberdata(formData).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Number Updated Successfully');
        this.loadNumbers();
        this.editSubmitted = false;
      } else {
        this.toastrService.error('Failed To Add Label');
      }
    }, error => this.error = error);
  }
  closeModal() {
    // console.log(this.addForm.get('country').value);return false;
    if (!this.addForm.invalid) {
      $("#addModel").modal("hide");
      // $(".custom-switch-input").prop('checked',false);
      this.Submitted = false;
      setTimeout(() => {
        this.addForm.reset();
      }, 2000);
    }
    if (this.addLabelForm.get('name').value && this.addLabelForm.get('notes').value) {
      $("#addLabels").modal("hide");
      $(".custom-switch-input").prop('checked', false);
      this.LabelSubmitted = false;
      setTimeout(() => {
        this.addLabelForm.reset();
        this.isName = "";
      }, 2000);
    }
  }
  closeEditModal() {
    if (this.editForm.get('country').value != '') {
      $("#editModel").modal("hide");
      this.editSubmitted = false;
      setTimeout(() => {
        this.editForm.reset();
      }, 2000);
    }
  }
  get labelcontrol() {
    return this.addLabelForm.controls;
  }
  onLabelSubmit() {
    const formData = new FormData();
    this.LabelSubmitted = true;
    if (this.addLabelForm.invalid) {
      return;
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('name', this.addLabelForm.get('name').value);
    formData.append('notes', this.addLabelForm.get('notes').value);
    this.moduleservice.addLabel(formData).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Label Added Successfully');
        this.getAllLabels();
        this.LabelSubmitted = false;
        this.isName = false;
      } else {
        this.toastrService.error('Failed To Add Label');
      }
    }, error => this.error = error);
  }
  validatename() {
    if (this.addLabelForm.get('name').value != '') {
      this.moduleservice.validateLabelName(this.addLabelForm.get('name').value).subscribe(res => {
        // console.log(res); return false;
        this.isName = res;
        if (this.isName.status == 'success') {
          this.isName = "success";
        } else {
          this.isName = "fail";
        }
      });
    } else {
      this.isName = "";
    }
  }
  exportdata() {
    var options = {
      fieldSeparator: ',',
      quoteStrings: '"',
      decimalseparator: '.',
      showLabels: true,
      // showTitle: true,
      // title: 'Your title',
      useBom: true,
      // noDownload: true,
      headers: ["prefix", "number", "country", "campaign", "publisher", "target", "created_at"]
    };
    this.numbers.forEach((element, index) => {
      this.exportNumber.prefix = element.prefix;
      this.exportNumber.number = element.number;
      this.exportNumber.country = element.country;
      this.exportNumber.campaign = element.campaign;
      this.exportNumber.publisher = element.publisher;
      this.exportNumber.target = element.target;
      // this.exportNumber.assosciated_labels = element.assosciated_labels;
      this.exportNumber.created_at = element.created_at;
      this.finalexportNumber[index] = this.exportNumber;
    });
    //  console.log(this.numbers);
    //  console.log(this.finalexportNumber); return;
    new ngx_csv_ngx_csv__WEBPACK_IMPORTED_MODULE_5__.ngxCsv(this.finalexportNumber, 'All Numbers', options);
  }
  addprefix(event) {
    // alert(event)
    if (event == "United Kingdom") {
      this.addForm.patchValue({
        prefix: "+44"
      });
    }
    if (event == "United States") {
      this.addForm.patchValue({
        prefix: "+1"
      });
    }
  }
  editprefix(event) {
    // alert(event)
    if (event == "United Kingdom") {
      this.editForm.patchValue({
        prefix: "+44"
      });
    }
    if (event == "United States") {
      this.editForm.patchValue({
        prefix: "+1"
      });
    }
  }
  purchase_number(event) {
    // alert(event);
    if (event == 1) {
      const headers = new _angular_common_http__WEBPACK_IMPORTED_MODULE_7__.HttpHeaders().set('cache-control', 'no-cache').set('content-type', 'application/json').set('postman-token', 'b408a67d-5f78-54fc-2fb7-00f6e9cefbd1');
      const body = {
        email: 'myemail@xyz.com',
        user_password: 'mypasss',
        token: 'my token'
      };
      this.http.post(this.url, body, {
        headers: headers
      }).subscribe(data => {
        console.log(data);
      });
    }
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_9__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_7__.HttpBackend
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_8__.FormBuilder
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_6__.Router
  }, {
    type: _angular_core__WEBPACK_IMPORTED_MODULE_10__.ChangeDetectorRef
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_11__.Title
  }, {
    type: ngx_ui_loader__WEBPACK_IMPORTED_MODULE_12__.NgxUiLoaderService
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_10__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }]
  };
};
NumbersComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_13__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_10__.Component)({
  selector: 'app-numbers',
  template: _numbers_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_numbers_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], NumbersComponent);


/***/ }),

/***/ 61312:
/*!***********************************************************************************!*\
  !*** ./src/app/modules/publishers/advertiser-terms/advertiser-terms.component.ts ***!
  \***********************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "AdvertiserTermsComponent": () => (/* binding */ AdvertiserTermsComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _advertiser_terms_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./advertiser-terms.component.html?ngResource */ 58229);
/* harmony import */ var _advertiser_terms_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./advertiser-terms.component.scss?ngResource */ 44445);
/* harmony import */ var _advertiser_terms_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_advertiser_terms_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/core */ 22560);




let AdvertiserTermsComponent = class AdvertiserTermsComponent {
  constructor() {}
  ngOnInit() {}
  static #_ = this.ctorParameters = () => [];
};
AdvertiserTermsComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_2__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_3__.Component)({
  selector: 'app-advertiser-terms',
  template: _advertiser_terms_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_advertiser_terms_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], AdvertiserTermsComponent);


/***/ }),

/***/ 80301:
/*!***************************************************************************************!*\
  !*** ./src/app/modules/publishers/publisher-settings/publisher-settings.component.ts ***!
  \***************************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "PublisherSettingsComponent": () => (/* binding */ PublisherSettingsComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _publisher_settings_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./publisher-settings.component.html?ngResource */ 22311);
/* harmony import */ var _publisher_settings_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./publisher-settings.component.scss?ngResource */ 8030);
/* harmony import */ var _publisher_settings_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_publisher_settings_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../module.service */ 22947);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./../../../global */ 27266);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @angular/platform-browser */ 34497);










const router = _angular_router__WEBPACK_IMPORTED_MODULE_4__.Router;

let PublisherSettingsComponent = class PublisherSettingsComponent {
  constructor(moduleservice, toastrService, handler, fb, titleService) {
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.fb = fb;
    this.titleService = titleService;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_3__.GlobalVariable.BASE_API_URL;
    this.BaseUrl = _global__WEBPACK_IMPORTED_MODULE_3__.GlobalVariable.BASE_URL;
    this.ispubreg = true;
    this.tcenable = true;
    this.Submitted = false;
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.Companyuuid = this.currentCompany.uuid;
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_5__.HttpClient(handler);
    this.publicregistration = true;
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngOnInit() {
    this.setTitle('Publisher Registration');
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.getAllpublisherssetting();
    this.addForm = this.fb.group({
      // , Validators.required
      user_uuid: [''],
      public_registration: [''],
      intro: [''],
      email: [''],
      terms_cond: [''],
      tc_url: ['']
    });
  }
  getAllpublisherssetting() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleservice.getAllpublisherssetting(this.currentCompany.uuid).subscribe(res => {
      //  console.log(res); return false;  
      if (res['public_registration'] == 1) {
        this.publicregistration = true;
        this.ispubreg = true;
      } else {
        this.publicregistration = false;
        this.ispubreg = false;
      }
      if (res['terms_cond'] == 1) {
        this.terms_condstatus = true;
      } else {
        this.terms_condstatus = false;
      }
      if (res['tc_url'] != '') {
        this.terms_condurl = res['tc_url'];
      } else {
        this.terms_condurl = 'https://ringlabmedia.com/publisher-terms';
      }
      this.addForm.patchValue({
        intro: res['intro'],
        email: res['email'],
        tc_url: this.terms_condurl
      });
    }, error => this.error = error);
  }
  pubreg_enable(event) {
    this.ispubreg = event.target.checked;
  }
  tc_enable(event) {
    this.tcenable = event.target.checked;
  }
  //Add Publisher
  get addformcontrol() {
    return this.addForm.controls;
  }
  onSubmit() {
    const formData = new FormData();
    this.Submitted = true;
    if (this.addForm.invalid) {
      return;
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    formData.append('user_uuid', currentUser.uuid);
    formData.append('uuid', this.currentCompany.uuid);
    formData.append('public_registration', this.ispubreg);
    formData.append('intro', this.addForm.get('intro').value);
    formData.append('email', this.addForm.get('email').value);
    formData.append('terms_cond', this.tcenable);
    formData.append('tc_url', this.addForm.get('tc_url').value);
    // console.log(formData); return false;
    this.moduleservice.addPublisherSettingdata(formData).subscribe(res => {
      // console.log(res.status); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Publisher Setting Saved Successfully');
        this.getAllpublisherssetting();
        this.Submitted = false;
      } else {
        this.toastrService.error('Failed To Add Label');
      }
    }, error => this.error = error);
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_6__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_5__.HttpBackend
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_7__.FormBuilder
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_8__.Title
  }];
};
PublisherSettingsComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_9__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_10__.Component)({
  selector: 'app-publisher-settings',
  template: _publisher_settings_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_publisher_settings_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], PublisherSettingsComponent);


/***/ }),

/***/ 75102:
/*!*********************************************************************************!*\
  !*** ./src/app/modules/publishers/publisher-terms/publisher-terms.component.ts ***!
  \*********************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "PublisherTermsComponent": () => (/* binding */ PublisherTermsComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _publisher_terms_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./publisher-terms.component.html?ngResource */ 59491);
/* harmony import */ var _publisher_terms_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./publisher-terms.component.scss?ngResource */ 29662);
/* harmony import */ var _publisher_terms_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_publisher_terms_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../module.service */ 22947);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./../../../global */ 27266);










const router = _angular_router__WEBPACK_IMPORTED_MODULE_4__.Router;
let PublisherTermsComponent = class PublisherTermsComponent {
  constructor(moduleservice, toastrService, handler, fb, router, activatedRoute) {
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.fb = fb;
    this.router = router;
    this.activatedRoute = activatedRoute;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_3__.GlobalVariable.BASE_API_URL;
    this.BaseUrl = _global__WEBPACK_IMPORTED_MODULE_3__.GlobalVariable.BASE_URL;
    this.isavail = 1;
    this.company = 1;
    this.tcenable = false;
    this.Submitted = false;
    // this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    // this.Companyuuid = this.currentCompany.uuid;
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_5__.HttpClient(handler);
    this.publicregistration = true;
    this.activatedRoute.params.subscribe(data => {
      this.checkcompanyavail(data.id);
    });
  }
  ngOnInit() {
    this.routeurl = window.location.href.replace(this.BaseUrl + 'publisher-registration/', "");
    this.checkcompanyavail(this.routeurl);
    // console.log(this.routeurl);
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    // this.getAllpublisherssetting();
    this.addForm = this.fb.group({
      // , Validators.required
      businame: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required],
      first_name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required],
      last_name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required],
      email: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required],
      phone_number: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_6__.Validators.required]
    });
  }
  checkcompanyavail(company_uuid) {
    this.moduleservice.checkcompanyavail(company_uuid).subscribe(res => {
      this.isavail = res.isavail;
      this.company = res.company;
    });
  }
  getAllpublisherssetting() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleservice.getAllpublisherssetting(this.currentCompany.uuid).subscribe(res => {
      //  console.log(res); return false;  
      this.email = res['email'];
    }, error => this.error = error);
  }
  tc_enable(event) {
    if (event.target.checked == true) {
      this.tcenable = true;
    } else {
      this.tcenable = false;
    }
  }
  //Add Publisher
  get addformcontrol() {
    return this.addForm.controls;
  }
  onSubmit() {
    const formData = new FormData();
    this.Submitted = true;
    if (this.addForm.invalid) {
      return;
    }
    // this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    formData.append('company_uuid', this.routeurl);
    formData.append('businame', this.addForm.get('businame').value);
    formData.append('first_name', this.addForm.get('first_name').value);
    formData.append('last_name', this.addForm.get('last_name').value);
    formData.append('email', this.addForm.get('email').value);
    formData.append('phone_number', this.addForm.get('phone_number').value);
    // console.log(formData); return false;
    this.moduleservice.addPublisherRegistration(formData).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Publisher Registration Successfully Done.');
        localStorage.setItem('company', this.routeurl);
        this.router.navigate(['/thank-you']);
      } else {
        this.toastrService.error('Failed To Add Label');
      }
    }, error => this.error = error);
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_7__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_5__.HttpBackend
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_6__.FormBuilder
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_4__.Router
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_4__.ActivatedRoute
  }];
};
PublisherTermsComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_8__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_9__.Component)({
  selector: 'app-publisher-terms',
  template: _publisher_terms_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_publisher_terms_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], PublisherTermsComponent);


/***/ }),

/***/ 64617:
/*!************************************************************!*\
  !*** ./src/app/modules/publishers/publishers.component.ts ***!
  \************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "PublishersComponent": () => (/* binding */ PublishersComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _publishers_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./publishers.component.html?ngResource */ 76872);
/* harmony import */ var _publishers_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./publishers.component.scss?ngResource */ 39046);
/* harmony import */ var _publishers_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_publishers_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../module.service */ 22947);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! sweetalert2 */ 60598);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(sweetalert2__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../global */ 27266);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/platform-browser */ 34497);









//import 'sweetalert2/src/sweetalert2.scss'



const router = _angular_router__WEBPACK_IMPORTED_MODULE_5__.Router;
class DataTablesResponse {}
let PublishersComponent = class PublishersComponent {
  constructor(moduleservice, toastrService, handler, fb, titleService) {
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.fb = fb;
    this.titleService = titleService;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_4__.GlobalVariable.BASE_API_URL;
    this.dtOptions = {};
    this.ischecked = '1';
    this.settingToggleAccessToRecordingsvaldata = 0;
    this.settingToggleBlockCallsIfCappeddata = 0;
    this.checkboxes = [];
    this.settingToggleBlockCallsIfCappededit = 0;
    this.settingToggleAccessToRecordingsedit = 0;
    this.Submitted = false;
    this.editSubmitted = false;
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_6__.HttpClient(handler);
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngOnInit() {
    this.setTitle('Manage Publishers');
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.loadpublishers();
    // this.loadNumbers();
    this.addForm = this.fb.group({
      name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      email: [''],
      password: [''],
      number_creation: [''],
      settingToggleBlockCallsIfCapped: [''],
      settingToggleAccessToRecordings: [''],
      user_uuid: ['']
    });
    this.editForm = this.fb.group({
      uuid: [''],
      name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      email: [''],
      password: [''],
      number_creation: [''],
      settingToggleBlockCallsIfCapped: [''],
      settingToggleAccessToRecordings: [''],
      user_uuid: [''],
      status: ['']
    });
  }
  // numberdata:any;
  // loadNumbers(){
  //   this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
  //   this.moduleservice.loadNumbersfordropdown(this.currentCompany.uuid).subscribe(
  //     res => {
  //       this.numberdata= res
  //       },
  //       error => this.error = error
  //   );
  // }
  loadpublishers() {
    // console.log('ok');
    // return false;
    if ($.fn.DataTable.isDataTable(this.table.nativeElement)) {
      $(this.table.nativeElement).dataTable().fnDestroy();
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.dtOptions = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "pageLength": 20,
      "lengthMenu": [[-1, 20, 100, 500, 2000], ["All", 20, 100, 500, 2000]],
      "order": [[0, "asc"]],
      ajax: (dataTablesParameters, callback) => {
        this.http.post(this.ServerUrl + 'getpublisher/' + this.currentCompany.uuid, dataTablesParameters, {}).subscribe(resp => {
          this.numbers = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [{
        data: "name"
      }, {
        data: "email"
      }, {
        data: "create_number"
      }, {
        data: "settingToggleBlockCallsIfCapped"
      }, {
        data: "settingToggleAccessToRecordings"
      }, {
        data: "created_at"
      }, {
        data: "status"
      }, {
        data: "action"
      }],
      columnDefs: [{
        "targets": [0],
        "orderable": false
      }]
    };
    this.dataTable = $(this.table.nativeElement);
    this.dataTable.dataTable(this.dtOptions);
  }
  editdata(uuid, name, email, create_number, settingToggleBlockCallsIfCapped, settingToggleAccessToRecordings, status) {
    this.settingToggleAccessToRecordingsvaldata = settingToggleAccessToRecordings;
    this.settingToggleBlockCallsIfCappeddata = settingToggleBlockCallsIfCapped;
    this.editForm.patchValue({
      uuid: uuid,
      name: name,
      email: email,
      number_creation: create_number,
      settingToggleBlockCallsIfCapped: settingToggleBlockCallsIfCapped,
      settingToggleAccessToRecordings: settingToggleAccessToRecordings,
      status: status
    });
  }
  checkalldelete(event) {
    const checked = event.target.checked;
    this.numbers.forEach(chkbox => chkbox.selected = checked);
  }
  deleteselected(event) {
    // $("#customCheck1").prop("checked", false);
    if (event.target.checked == true) {
      if (event.target.value == 'on') {
        this.checkboxes = [];
        this.numbers.forEach(lbl => {
          this.checkboxes.push(lbl.id);
        });
      } else {
        if (this.checkboxes.length + 1 == this.numbers.length) {
          $("#customCheck1").prop("checked", true);
        }
        this.checkboxes.push(event.target.value);
      }
      this.ischecked = '0';
    } else {
      // console.log(this.checkboxes);
      if (this.checkboxes.length != 0) {
        $("#customCheck1").prop("checked", false);
      }
      if (event.target.value != 'on') {
        const index = this.checkboxes.indexOf(event.target.value);
        this.checkboxes.splice(index, 1);
      } else {
        this.checkboxes = [];
      }
      this.ischecked = '1';
    }
    // console.log(this.checkboxes);
  }

  onDeleteSubmit() {
    if (this.checkboxes.length == 0) {
      this.toastrService.error('Please Select Row To Delete');
    } else {
      // console.log(this.checkboxes);
      sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
        title: 'Are you sure?',
        text: 'You want to Delete Selected Record!',
        showCancelButton: true,
        confirmButtonText: 'Yes, delete it!',
        cancelButtonText: 'No, keep it'
      }).then(result => {
        if (result.value) {
          this.moduleservice.deleteSelectedNumbers(this.checkboxes).subscribe(res => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Records Deleted Successfully.');
            setTimeout(() => {
              sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
            }, 2000);
            this.loadpublishers();
          }, error => this.error = error);
        } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
        }
      });
    }
  }
  Delete(id) {
    sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
      title: 'Are you sure?',
      text: 'You want to Delete Record!',
      showCancelButton: true,
      confirmButtonText: 'Yes, delete it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        let currentUser = JSON.parse(localStorage.getItem('currentUser'));
        this.moduleservice.deletePublisher(+id, currentUser.uuid).subscribe(res => {
          this.loadpublishers();
          // this.toastrService.success('Number Deleted Successfully');
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Record Deleted Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
        }, 2000);
      }
    });
  }
  settingToggleBlockCallsIfCappedval(val) {
    this.addForm.get('settingToggleBlockCallsIfCapped').setValue(val);
  }
  settingToggleAccessToRecordingsval(val) {
    this.addForm.get('settingToggleAccessToRecordings').setValue(val);
  }
  settingToggleBlockCallsIfCappedvaledit(val) {
    this.settingToggleBlockCallsIfCappededit = val;
    this.editForm.get('settingToggleBlockCallsIfCapped').setValue(val);
  }
  settingToggleAccessToRecordingsvaledit(val) {
    this.settingToggleAccessToRecordingsedit = val;
    this.editForm.get('settingToggleAccessToRecordings').setValue(val);
  }
  //Add Publisher
  get addformcontrol() {
    return this.addForm.controls;
  }
  onSubmit() {
    const formData = new FormData();
    this.Submitted = true;
    if (this.addForm.invalid) {
      return;
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    formData.append('user_uuid', currentUser.uuid);
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('name', this.addForm.get('name').value);
    formData.append('email', this.addForm.get('email').value);
    formData.append('password', this.addForm.get('password').value);
    formData.append('number_creation', this.addForm.get('number_creation').value);
    formData.append('settingToggleBlockCallsIfCapped', this.addForm.get('settingToggleBlockCallsIfCapped').value);
    formData.append('settingToggleAccessToRecordings', this.addForm.get('settingToggleAccessToRecordings').value);
    // console.log(formData); return false;
    this.moduleservice.addPublisher(formData).subscribe(res => {
      // console.log(res.status); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Publisher Added Successfully');
        this.loadpublishers();
        this.Submitted = false;
      } else {
        this.toastrService.error('Failed To Add Label');
      }
    }, error => this.error = error);
  }
  //Add Buyer
  get editFormcontrol() {
    return this.editForm.controls;
  }
  onEditSubmit() {
    // alert('ok');return false;
    const formData = new FormData();
    this.editSubmitted = true;
    if (this.editForm.invalid) {
      return;
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    formData.append('user_uuid', currentUser.uuid);
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('uuid', this.editForm.get('uuid').value);
    formData.append('name', this.editForm.get('name').value);
    formData.append('email', this.editForm.get('email').value);
    formData.append('password', this.editForm.get('password').value);
    formData.append('number_creation', this.editForm.get('number_creation').value);
    formData.append('settingToggleBlockCallsIfCapped', this.editForm.get('settingToggleBlockCallsIfCapped').value);
    formData.append('settingToggleAccessToRecordings', this.editForm.get('settingToggleAccessToRecordings').value);
    formData.append('status', this.editForm.get('status').value);
    // console.log(formData);
    this.moduleservice.editPublisher(formData).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Publisher Updated Successfully');
        this.loadpublishers();
        this.editSubmitted = false;
      } else {
        this.toastrService.error('Failed To Add Label');
      }
    }, error => this.error = error);
  }
  closeModal() {
    if (this.addForm.get('name').value != '') {
      $("#addLabels").modal("hide");
      // $(".custom-switch-input").prop('checked',false);
      this.Submitted = false;
      setTimeout(() => {
        this.addForm.reset();
      }, 2000);
    }
  }
  closeEditModal() {
    if (this.editForm.get('name').value != '') {
      $("#editLabels").modal("hide");
      this.editSubmitted = false;
      setTimeout(() => {
        this.editForm.reset();
      }, 2000);
    }
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_8__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_6__.HttpBackend
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_7__.FormBuilder
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_9__.Title
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_10__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }]
  };
};
PublishersComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_11__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_10__.Component)({
  selector: 'app-publishers',
  template: _publishers_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_publishers_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], PublishersComponent);


/***/ }),

/***/ 49377:
/*!*******************************************************************!*\
  !*** ./src/app/modules/publishers/thankyou/thankyou.component.ts ***!
  \*******************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "ThankyouComponent": () => (/* binding */ ThankyouComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _thankyou_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./thankyou.component.html?ngResource */ 33008);
/* harmony import */ var _thankyou_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./thankyou.component.scss?ngResource */ 86141);
/* harmony import */ var _thankyou_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_thankyou_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/core */ 22560);




let ThankyouComponent = class ThankyouComponent {
  constructor() {}
  ngOnInit() {
    this.company = localStorage.getItem('company');
  }
  static #_ = this.ctorParameters = () => [];
};
ThankyouComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_2__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_3__.Component)({
  selector: 'app-thankyou',
  template: _thankyou_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_thankyou_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], ThankyouComponent);


/***/ }),

/***/ 54577:
/*!************************************************************!*\
  !*** ./src/app/modules/recordings/recordings.component.ts ***!
  \************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "RecordingsComponent": () => (/* binding */ RecordingsComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _recordings_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./recordings.component.html?ngResource */ 38025);
/* harmony import */ var _recordings_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./recordings.component.scss?ngResource */ 80611);
/* harmony import */ var _recordings_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_recordings_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../module.service */ 22947);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../global */ 27266);
/* harmony import */ var ngx_csv_ngx_csv__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ngx-csv/ngx-csv */ 94551);
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! moment */ 56908);
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(moment__WEBPACK_IMPORTED_MODULE_5__);
/* harmony import */ var datatables_net__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! datatables.net */ 84375);
/* harmony import */ var datatables_net__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(datatables_net__WEBPACK_IMPORTED_MODULE_6__);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! @angular/platform-browser */ 34497);








//import 'sweetalert2/src/sweetalert2.scss'






const router = _angular_router__WEBPACK_IMPORTED_MODULE_7__.Router;
class DataTablesResponse {}
let RecordingsComponent = class RecordingsComponent {
  constructor(moduleservice, toastrService, handler, fb, titleService) {
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.fb = fb;
    this.titleService = titleService;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_3__.GlobalVariable.BASE_API_URL;
    this.numbers = '';
    this.ranges = {
      Today: [moment__WEBPACK_IMPORTED_MODULE_5__(), moment__WEBPACK_IMPORTED_MODULE_5__()],
      Yesterday: [moment__WEBPACK_IMPORTED_MODULE_5__().subtract(1, 'days'), moment__WEBPACK_IMPORTED_MODULE_5__().subtract(1, 'days')],
      'Last 7 Days': [moment__WEBPACK_IMPORTED_MODULE_5__().subtract(6, 'days'), moment__WEBPACK_IMPORTED_MODULE_5__()],
      'Last 30 Days': [moment__WEBPACK_IMPORTED_MODULE_5__().subtract(29, 'days'), moment__WEBPACK_IMPORTED_MODULE_5__()],
      'This Month': [moment__WEBPACK_IMPORTED_MODULE_5__().startOf('month'), moment__WEBPACK_IMPORTED_MODULE_5__().endOf('month')],
      'Last Month': [moment__WEBPACK_IMPORTED_MODULE_5__().subtract(1, 'month').startOf('month'), moment__WEBPACK_IMPORTED_MODULE_5__().subtract(1, 'month').endOf('month')]
    };
    this.dtOptions = {};
    this.submitted = false;
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_8__.HttpClient(handler);
    this.alwaysShowCalendars = true;
    this.keepCalendarOpeningWithRange = true;
    this.showRangeLabelOnInput = true;
    this.selected = {
      startDate: moment__WEBPACK_IMPORTED_MODULE_5__().startOf('day'),
      endDate: moment__WEBPACK_IMPORTED_MODULE_5__().endOf('day')
    };
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngOnInit() {
    this.setTitle('Recordings');
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.loadcalls();
  }
  get f() {
    return this.searchcallsform.controls;
  }
  loadcalls() {
    if ($.fn.DataTable.isDataTable(this.table.nativeElement)) {
      $(this.table.nativeElement).dataTable().fnDestroy();
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    var that = this;
    this.dtOptions = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "pageLength": 20,
      "lengthMenu": [[-1, 20, 100, 500, 2000], ["All", 20, 100, 500, 2000]],
      "order": [[2, "desc"]],
      ajax: (dataTablesParameters, callback) => {
        that.http.post(this.ServerUrl + 'getrecordings/' + this.currentCompany.uuid, {
          'dataTablesParameters': dataTablesParameters,
          'number': this.numbers,
          'date': this.selected
        }, {}).subscribe(resp => {
          // console.log(resp); return false;
          that.datas = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [{
        data: "uuid"
      }, {
        data: "did"
      }, {
        data: "incoming_number"
      }, {
        data: "call_duration"
      }, {
        data: "date_of_call"
      }, {
        data: "download"
      }]
    };
    this.dataTable = $(this.table.nativeElement);
    this.dataTable.dataTable(this.dtOptions);
  }
  exportdata() {
    var options = {
      fieldSeparator: ',',
      quoteStrings: '"',
      decimalseparator: '.',
      showLabels: true,
      useBom: true,
      headers: ["Number Called", " Caller ID", " Forwarded To", " Call Duration", "Labels", "IVR Inputs", "Date of Call", "Time of Call"]
    };
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleservice.getCallsForExport(this.currentCompany.uuid).subscribe(res => {
      new ngx_csv_ngx_csv__WEBPACK_IMPORTED_MODULE_4__.ngxCsv(res.data, 'My Report', options);
    }, error => this.error = error);
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_9__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_8__.HttpBackend
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_10__.FormBuilder
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_11__.Title
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_12__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }]
  };
};
RecordingsComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_13__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_12__.Component)({
  selector: 'app-recordings',
  template: _recordings_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_recordings_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], RecordingsComponent);


/***/ }),

/***/ 41740:
/*!****************************************************************************!*\
  !*** ./src/app/modules/reports-comparison/reports-comparison.component.ts ***!
  \****************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "ReportsComparisonComponent": () => (/* binding */ ReportsComparisonComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _reports_comparison_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./reports-comparison.component.html?ngResource */ 94624);
/* harmony import */ var _reports_comparison_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./reports-comparison.component.scss?ngResource */ 28605);
/* harmony import */ var _reports_comparison_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_reports_comparison_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../module.service */ 22947);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../global */ 27266);
/* harmony import */ var ngx_csv_ngx_csv__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ngx-csv/ngx-csv */ 94551);
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! moment */ 56908);
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(moment__WEBPACK_IMPORTED_MODULE_5__);
/* harmony import */ var datatables_net__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! datatables.net */ 84375);
/* harmony import */ var datatables_net__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(datatables_net__WEBPACK_IMPORTED_MODULE_6__);
/* harmony import */ var angular_highcharts__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! angular-highcharts */ 55199);
/* harmony import */ var highcharts_modules_exporting__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! highcharts/modules/exporting */ 43916);
/* harmony import */ var highcharts_modules_exporting__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(highcharts_modules_exporting__WEBPACK_IMPORTED_MODULE_7__);
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! highcharts */ 75972);
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_8__);
/* harmony import */ var moment_timezone__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! moment-timezone */ 92469);
/* harmony import */ var moment_timezone__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(moment_timezone__WEBPACK_IMPORTED_MODULE_9__);
/* harmony import */ var ngx_ui_loader__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(/*! ngx-ui-loader */ 36413);
/* harmony import */ var rxjs__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! rxjs */ 92218);
/* harmony import */ var rxjs_add_observable_interval__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! rxjs/add/observable/interval */ 95363);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(/*! @angular/platform-browser */ 34497);

















highcharts_modules_exporting__WEBPACK_IMPORTED_MODULE_7___default()(highcharts__WEBPACK_IMPORTED_MODULE_8__);




const router = _angular_router__WEBPACK_IMPORTED_MODULE_11__.Router;
class DataTablesResponse {}
class filterarr {}
let ReportsComparisonComponent = class ReportsComparisonComponent {
  // subscriptions : Subscription[];
  constructor(moduleservice, toastrService, handler, fb, route, router, el, ngxLoader, cdRef, titleService) {
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.fb = fb;
    this.route = route;
    this.router = router;
    this.el = el;
    this.ngxLoader = ngxLoader;
    this.cdRef = cdRef;
    this.titleService = titleService;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_3__.GlobalVariable.BASE_API_URL;
    this.numbers = '';
    this.dtOptions = {};
    this.dtTrigger = new rxjs__WEBPACK_IMPORTED_MODULE_12__.Subject();
    this.dtOptionsdetails = {};
    this.labels = 0;
    this.callsdata = [];
    this.submitted = false;
    this.event = "";
    this.expanded = {};
    this.rows = [];
    this.ranges = {
      Today: [moment__WEBPACK_IMPORTED_MODULE_5__.tz(moment__WEBPACK_IMPORTED_MODULE_5__(), "America/Phoenix").format("MM/DD/YYYY"), moment__WEBPACK_IMPORTED_MODULE_5__.tz(moment__WEBPACK_IMPORTED_MODULE_5__(), "America/Phoenix").format("MM/DD/YYYY")],
      Yesterday: [moment__WEBPACK_IMPORTED_MODULE_5__.tz(moment__WEBPACK_IMPORTED_MODULE_5__().subtract(1, 'days'), "America/Phoenix").format("MM/DD/YYYY"), moment__WEBPACK_IMPORTED_MODULE_5__.tz(moment__WEBPACK_IMPORTED_MODULE_5__().subtract(1, 'days'), "America/Phoenix").format("MM/DD/YYYY")]
    };
    this.ngxclass = "dark";
    this.ischart = 0;
    this.colorcode = '#fff';
    this.noofrecords = 500;
    this.isclick = 0;
    this.istougle = 1;
    this.filtertype = 1;
    this.filtervalue = '';
    this.filterdate = '';
    this.isadded = 1;
    this.isfiltered = 0;
    this.isselectElement = 0;
    this.filterselected = [];
    this.charttype = "Calls Per Hour";
    this.daytypeval = 1;
    $("#summarytbl").dataTable().fnDestroy();
    this.dtOptions = {
      "order": [],
      paging: false,
      searching: false,
      info: false
    };
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_13__.HttpClient(handler);
    this.router.routeReuseStrategy.shouldReuseRoute = () => false;
    this.alwaysShowCalendars = true;
    this.keepCalendarOpeningWithRange = true;
    this.showRangeLabelOnInput = true;
    this.selected = {
      startDate: moment__WEBPACK_IMPORTED_MODULE_5__.tz(moment__WEBPACK_IMPORTED_MODULE_5__(), "America/Phoenix").format("MM/DD/YYYY"),
      endDate: moment__WEBPACK_IMPORTED_MODULE_5__.tz(moment__WEBPACK_IMPORTED_MODULE_5__(), "America/Phoenix").format("MM/DD/YYYY")
    };
    this.selected_2 = {
      startDate: moment__WEBPACK_IMPORTED_MODULE_5__.tz(moment__WEBPACK_IMPORTED_MODULE_5__(), "America/Phoenix").format("MM/DD/YYYY"),
      endDate: moment__WEBPACK_IMPORTED_MODULE_5__.tz(moment__WEBPACK_IMPORTED_MODULE_5__(), "America/Phoenix").format("MM/DD/YYYY")
    };
    this.selected1 = this.selected;
    this.selected2 = this.selected;
  }
  onPage(event) {
    clearTimeout(this.timeout);
    this.timeout = setTimeout(() => {
      console.log('paged!', event);
    }, 100);
  }
  sendMenuUpdateMessage() {
    // send message to subscribers via observable subject
    this.moduleservice.sendMenuUpdateMessage('1');
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngOnInit() {
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    const uuid = this.route.snapshot.paramMap.get('id');
    this.setTitle('Comparison Reports');
    // console.log(uuid);
    if (uuid != null) {
      // this.getsavedreports(uuid);
    } else {
      // this.loadcalls("","");
      // this.loadcallsdata("","","",1);
      // this.getChartNumberOfCalls(0,0,0,2);
      // this.getsavedreports();
    }
    if ($("body").hasClass("theme-white")) {
      this.ngxclass = 'material';
    }
  }
  getChartNumberOfCalls(filterselected, date, date_2, daytype) {
    this.showLoadingIndicator = true;
    this.ngxLoader.startLoader('loader-03');
    if ($("html").hasClass("theme-light")) {
      this.bgcolorcode = 'rgb(17,19,25)';
      // this.colorcode='rgb(17,19,25)';
    }

    this.chartarg = {
      filterselected: filterselected,
      date: date,
      date_2: date_2
    };
    this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.moduleservice.getChartbyfilterforcomparison(this.currentCompany.uuid, this.chartarg, daytype, this.currentUser.timezone).subscribe(res => {
      this.showLoadingIndicator = false;
      this.ischart = 1;
      this.chart = new angular_highcharts__WEBPACK_IMPORTED_MODULE_14__.Chart({
        chart: {
          polar: true,
          type: 'line',
          backgroundColor: this.bgcolorcode
        },
        exporting: {
          enabled: true
        },
        title: {
          text: 'Comparision Report',
          style: {
            color: this.colorcode
          }
        },
        subtitle: {
          text: document.ontouchstart === undefined ? 'Click and drag in the plot area to zoom in' : 'Pinch the chart to zoom in',
          style: {
            color: this.colorcode
          }
        },
        credits: {
          enabled: false
        },
        tooltip: {
          shared: true
        },
        xAxis: {
          minRange: 0,
          gridLineWidth: 0,
          title: {
            text: 'Number Of Calls',
            style: {
              color: this.colorcode
            }
          },
          categories: res.datearr
        },
        yAxis: {
          min: 0,
          gridLineWidth: 1,
          title: {
            text: 'Number Of Calls',
            style: {
              color: this.colorcode
            }
          }
        },
        colors: ['rgb(0,198,0)', 'rgb(187,0,1)'],
        plotOptions: {
          column: {
            colorByPoint: true
          },
          line: {
            dataLabels: {
              useHTML: true,
              enabled: true,
              format: '{point.percentage:.1f} %',
              color: 'white'
            },
            enableMouseTracking: false
          }
        },
        series: [{
          data: res.chartdata,
          type: 'column',
          name: this.selecteddate.startDate.split(' ')[0] + ' | ' + this.selecteddate.endDate.split(' ')[0],
          color: 'rgb(0,198,0)'
        }, {
          data: res.chartdata_2,
          type: 'column',
          name: this.selecteddate_2.startDate.split(' ')[0] + ' | ' + this.selecteddate_2.endDate.split(' ')[0],
          color: 'rgb(187,0,1)'
        }
        // ,{
        //   name: 'Converted',
        //   color: '#F9B236',
        //   type: 'spline',
        //   data: res.converted,
        // },{
        //   name: 'Connected',
        //   type: 'spline',
        //   color: '#20bf55',
        //   data: res.connected,
        // }
        // ,{
        //   name: 'No Answer',
        //   type: 'spline',
        //   color: 'red',
        //   data: res.noanswer,
        // },{
        //   name: 'No Connect',
        //   type: 'spline',
        //   color: 'red',
        //   data: res.noconnect,
        //   }
        ]
      });

      this.ngxLoader.stopLoader('loader-03');
    }, error => this.error = error);
  }
  play(url, incomingnumber) {
    this.toastrService.show(`<audio style="width: 130px;height: 30px;" controls><source src="https://d2actkasrcrrs8.cloudfront.net/${url}" type="audio/mp3"></audio>`, 'Inbound # - ' + incomingnumber, {
      closeButton: true,
      extendedTimeOut: 0,
      timeOut: 0,
      tapToDismiss: false,
      enableHtml: true,
      positionClass: 'toast-bottom-right'
    });
  }
  loadcallsdata(filterselected, date, date_2, groupby) {
    $("#datatable1").dataTable().fnDestroy();
    // $("#summarytbl").dataTable().fnDestroy();
    this.ngxLoader.startLoader('loader-02');
    this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    // this.ngxLoader.startLoader('loader-03');
    this.http.post(this.ServerUrl + 'getcallsdataforcomparison/' + this.currentCompany.uuid, {
      'filterselected': filterselected,
      'date': date,
      'date_2': date_2,
      'timezone': this.currentUser.timezone,
      'groupby': groupby
    }, {}).subscribe(resp => {
      //
      this.callsdata = resp.data.numbers;
      // console.log(resp.data.total);
      this.totalcount = resp.data.total;
      this.totaldata = resp.data.length;
      this.dtTrigger.next();
      this.ngxLoader.stopLoader('loader-02');
    }, error => this.error = error);
  }
  exportdata() {
    var that = this;
    var options = {
      fieldSeparator: ',',
      quoteStrings: '"',
      decimalseparator: '.',
      showLabels: true,
      // showTitle: true,
      // title: 'Your title',
      useBom: true,
      // noDownload: true,
      headers: ["Number Called", "Caller ID", " Publisher", "Target", "Campaign", "Routed To", "Call Duration", "Labels", "IVR Inputs", "Date of Call", "Time of Call", "Revenue", "Payout"]
    };
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    const formData = new FormData();
    formData.append('user_uuid', currentUser.uuid);
    formData.append('role', currentUser.role);
    formData.append('timezone', this.currentUser.timezone);
    formData.append('filterselected', JSON.stringify(this.filterselected));
    formData.append('date', JSON.stringify(this.selecteddate));
    formData.append('totalrecords', this.noofrecords);
    // console.log(formData);return;
    this.showLoadingIndicator = true;
    this.moduleservice.getCalldetailsForExport(this.currentCompany.uuid, formData).subscribe(res => {
      // console.log(res);return;
      new ngx_csv_ngx_csv__WEBPACK_IMPORTED_MODULE_4__.ngxCsv(res.data, 'All Calls', options);
      this.showLoadingIndicator = false;
    }, error => this.error = error);
  }
  exportcalldata() {
    var options = {
      fieldSeparator: ',',
      quoteStrings: '"',
      decimalseparator: '.',
      showLabels: true,
      useBom: true,
      headers: ["UUID", "Name(Filter)", "Incoming", "Connected", "Qualified", "Converted", "Completed", "No Answer", "No Connect", "Payout", "Revenue", "Profit", "CR%", "RPC", "ACL", "TCL"]
    };
    new ngx_csv_ngx_csv__WEBPACK_IMPORTED_MODULE_4__.ngxCsv(this.callsdata, 'All Calls', options);
  }
  togglepanel() {
    if (this.isclick == 1) {
      this.istougle = 1;
      this.isclick = 0;
    } else {
      this.isclick = 1;
      this.istougle = 0;
    }
  }
  filterdata(type) {
    this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.filter = 0;
    this.isselectElement = 0;
    if (type == 1) {
      this.activeresultdata = [];
      this.nonactiveresultdata = [];
      this.filter = 1;
      this.filtertype = 1;
      this.filtertext = 'Select Campaign';
      this.filtervalue = "";
      this.moduleservice.getallcampain(this.currentCompany.uuid).subscribe(res => {
        this.activeresultdata = res.active;
        this.nonactiveresultdata = res.non_active;
      });
    }
    if (type == 2) {
      this.resultdata = [];
      this.filtertype = 2;
      this.filter = 1;
      this.filtertext = 'Select Target';
      this.filtervalue = "";
      this.moduleservice.getAlltarget(this.currentCompany.uuid).subscribe(res => {
        this.resultdata = res;
      });
    }
    if (type == 3) {
      this.resultdata = [];
      this.filter = 1;
      this.filtertype = 3;
      this.filtertext = 'Select Buyer';
      this.filtervalue = "";
      this.moduleservice.getallbuyers(this.currentCompany.uuid).subscribe(res => {
        this.resultdata = res;
      });
    }
    if (type == 4) {
      this.resultdata = [];
      this.filter = 1;
      this.filtertype = 4;
      this.filtertext = 'Select Publisher';
      this.filtervalue = "";
      this.moduleservice.getAllpublishers(this.currentCompany.uuid).subscribe(res => {
        this.resultdata = res;
      });
    }
    if (type == 5) {
      this.resultdata = [];
      this.filter = 1;
      this.filtertype = 5;
      this.filtertext = 'Enter Caller ID';
      this.filtervalue = "";
    }
    if (type == 6) {
      this.resultdata = [];
      this.filter = 1;
      this.filtertype = 6;
      this.filtertext = 'Enter Number Called';
      this.filtervalue = "";
    }
    if (type == 8) {
      this.resultdata = [];
      this.filter = 1;
      this.filtertype = 8;
      this.filtertext = 'Select IVR Inputs';
      this.filtervalue = "";
      this.resultdata = [{
        'id': 0,
        'text': 'No'
      }, {
        'id': 1,
        'text': 'Yes'
      }];
    }
    if (type == 9) {
      this.resultdata = [];
      this.filter = 1;
      this.filtertype = 9;
      this.filtertext = 'Select Ringtree';
      this.filtervalue = "";
      this.resultdata = [{
        'id': 0,
        'text': 'No'
      }, {
        'id': 1,
        'text': 'Yes'
      }];
    }
  }
  clearfilter(index) {
    // console.log(this.selecteddate);
    // console.log(this.selecteddate_2);
    this.filterselected.splice(index, 1);
    this.loadcallsdata(this.filterselected, this.selecteddate, this.selecteddate_2, 1);
    this.getChartNumberOfCalls(this.filterselected, this.selecteddate, this.selecteddate_2, this.daytypeval);
  }
  setdate(event, type) {
    if (event && event.startDate == null && event.endDate == null) return false;
    if (event) {
      var start = moment__WEBPACK_IMPORTED_MODULE_5__(event.startDate._d).format('MM/DD/YYYY HH:mm:ss');
      var end = moment__WEBPACK_IMPORTED_MODULE_5__(event.endDate._d).format('MM/DD/YYYY HH:mm:ss');
      this.startdate = moment__WEBPACK_IMPORTED_MODULE_5__.tz(start, 'utc').format("YYYY-MM-DD 00:00:00");
      this.enddate = moment__WEBPACK_IMPORTED_MODULE_5__.tz(end, 'utc').format("YYYY-MM-DD 23:59:59");
      this.selected1 = {
        startDate: this.startdate,
        endDate: this.enddate
      };
      this.comparisondate = this.selected1;
      // var a = moment(start);
      // var b = moment(end);
      // if(b.diff(a, 'days')>0){
      this.daytypeval = 1;
      // }else{
      //   this.daytypeval = 1;
      // }
      this.isfiltered = 1;
    } else {
      this.isselectElement = 1;
      this.isadded = 0;
      const uuid = this.route.snapshot.paramMap.get('id');
      if (uuid != null) {
        var start = moment__WEBPACK_IMPORTED_MODULE_5__(this.selected.startDate).format('MM/DD/YYYY HH:mm:ss');
        var end = moment__WEBPACK_IMPORTED_MODULE_5__(this.selected.endDate).format('MM/DD/YYYY HH:mm:ss');
      } else {
        if (this.selected1.startDate._d != undefined) {
          var start = moment__WEBPACK_IMPORTED_MODULE_5__(this.selected1.startDate._d).format('MM/DD/YYYY HH:mm:ss');
          var end = moment__WEBPACK_IMPORTED_MODULE_5__(this.selected1.endDate._d).format('MM/DD/YYYY HH:mm:ss');
        } else {
          var start = moment__WEBPACK_IMPORTED_MODULE_5__(this.selected2.startDate).format('MM/DD/YYYY HH:mm:ss');
          var end = moment__WEBPACK_IMPORTED_MODULE_5__(this.selected2.endDate).format('MM/DD/YYYY HH:mm:ss');
        }
      }
      this.startdate = moment__WEBPACK_IMPORTED_MODULE_5__.tz(start, 'utc').format("YYYY-MM-DD 00:00:00");
      this.enddate = moment__WEBPACK_IMPORTED_MODULE_5__.tz(end, 'utc').format("YYYY-MM-DD 23:59:59");
      if (this.isfiltered == 0) {
        this.selected1 = {
          startDate: this.startdate,
          endDate: this.enddate
        };
        this.comparisondate = "";
      } else {
        this.comparisondate = this.selected1;
      }
      this.daytypeval = 1;
    }
    if (type == 1) {
      this.selecteddate = this.comparisondate;
    } else {
      this.selecteddate_2 = this.comparisondate;
    }
  }
  filterval(group_by) {
    if (this.selecteddate == undefined || this.selecteddate_2 == undefined) {
      this.selecteddate = {
        startDate: moment__WEBPACK_IMPORTED_MODULE_5__.tz(moment__WEBPACK_IMPORTED_MODULE_5__(), "America/Phoenix").format("MM/DD/YYYY"),
        endDate: moment__WEBPACK_IMPORTED_MODULE_5__.tz(moment__WEBPACK_IMPORTED_MODULE_5__(), "America/Phoenix").format("MM/DD/YYYY")
      };
      this.selecteddate_2 = {
        startDate: moment__WEBPACK_IMPORTED_MODULE_5__.tz(moment__WEBPACK_IMPORTED_MODULE_5__(), "America/Phoenix").format("MM/DD/YYYY"),
        endDate: moment__WEBPACK_IMPORTED_MODULE_5__.tz(moment__WEBPACK_IMPORTED_MODULE_5__(), "America/Phoenix").format("MM/DD/YYYY")
      };
    }
    // console.log(this.selecteddate);
    // console.log(this.selecteddate_2);
    //  return false;
    // this.filterselected=[];
    let customObj = new filterarr();
    customObj.filtertype = this.filtertype;
    customObj.uuid = this.filtervalue;
    customObj.name = this.selectElementText;
    customObj.isorand = 0;
    // console.log(this.selectElementText);
    if (this.selectElementText != undefined && this.filterselected?.length == 0 && !event) {
      this.filterselected.push(customObj);
    }
    if (group_by == undefined) {
      group_by = 1;
    }
    // this.loadcalls(this.filterselected,this.selecteddate);
    // console.log(this.selecteddate);
    // console.log(this.selecteddate_2);
    this.loadcallsdata(this.filterselected, this.selecteddate, this.selecteddate_2, group_by);
    this.getChartNumberOfCalls(this.filterselected, this.selecteddate, this.selecteddate_2, 1);
  }
  calcelfilter() {
    this.isclick = 0;
    // this.filter = 0;
    // this.filtertype = 0;
    this.isselectElement = 0;
    this.filtertype = 1;
    this.filterdata(1);
    this.filtervalue = '';
    this.filterselected = [];
    this.isadded = 1;
    // this.loadcalls("","");
    // this.loadcallsdata("","","",1);
    // this.getChartNumberOfCalls(0,0,0,1);
    this.loadcallsdata(this.filterselected, this.selecteddate, this.selecteddate_2, 1);
    this.getChartNumberOfCalls(this.filterselected, this.selecteddate, this.selecteddate_2, this.daytypeval);
  }
  // gettext(event:any,type){
  //   if(type==1)
  //    this.selectElementText = event.target['options'][event.target['options'].selectedIndex].text;
  //    else
  //    this.selectElementText = event.target.value
  //   // console.log(event.target.value);
  // }
  gettext(event, type) {
    let text;
    if (this.filtertype == 1) {
      text = this.activeresultdata.filter(x => x.id == event)[0];
    } else {
      text = this.resultdata.filter(x => x.id == event)[0];
    }
    if (type == 1) {
      //  this.selectElementText = event.target['options'][event.target['options'].selectedIndex].text;
      this.selectElementText = text.text;
    } else {
      this.selectElementText = event.target.value;
    }
  }
  addorrule() {
    let customObj = new filterarr();
    customObj.filtertype = this.filtertype;
    customObj.uuid = this.filtervalue;
    customObj.name = this.selectElementText;
    customObj.isorand = 0;
    // console.log(this.selectElementText);
    if (this.selectElementText != undefined) {
      this.filterselected.push(customObj);
    }
    // console.log(this.filterselected);
  }

  addandrule() {
    let customObj = new filterarr();
    customObj.filtertype = this.filtertype;
    customObj.uuid = this.filtervalue;
    customObj.name = this.selectElementText;
    customObj.isorand = 1;
    // console.log(this.selectElementText);
    if (this.selectElementText != undefined) {
      this.filterselected.push(customObj);
    }
  }
  editfilter() {
    this.isadded = 1;
    this.isselectElement = 0;
  }
  chartby(type) {
    this.filterdate = "";
    if (type == 1) {
      this.daytypeval = 1;
      this.charttype = "Calls Per Hour";
      this.getChartNumberOfCalls(this.filterselected, this.selecteddate, this.selecteddate_2, 1);
    }
    if (type == 2) {
      this.daytypeval = 2;
      this.charttype = "Calls Per Day";
      this.getChartNumberOfCalls(this.filterselected, this.selecteddate, this.selecteddate_2, 2);
    }
    if (type == 3) {
      this.daytypeval = 3;
      this.charttype = "Calls Per Month";
      this.getChartNumberOfCalls(this.filterselected, this.selecteddate, this.selecteddate_2, 3);
    }
  }
  // savedreportsettings:any;
  // selecteddates:any;
  // isreport:any = 0;
  // getsavedreports(uuid:string){
  //   this.moduleservice.getsavedreportsbyuuid(uuid).subscribe(
  //     res => {
  //       this.labelval = res.reportlabelname;
  //       this.daytypeval = 2;
  //       if(res.filtertype!=''){
  //         this.isreport = 1;
  //         if(res.filtertype!=0){ this.isclick = 1; }
  //         this.filter = res.filtertype;
  //         let startday = res.start_date;
  //         let endday = res.end_date;
  //         const d = new Date(startday);
  //         const d1 = new Date(endday);
  //         moment(d).format('MMMM d, YYYY');
  //         moment(d1).format('MMMM d, YYYY');
  //         var start = moment(d).format('MM/DD/YYYY HH:mm:ss');
  //         var end = moment(d1).format('MM/DD/YYYY HH:mm:ss');
  //         this.startdate = moment.tz(start, 'utc').format("YYYY-MM-DD 00:00:00")
  //         this.enddate = moment.tz(end, 'utc').format("YYYY-MM-DD 23:59:59")
  //         this.selected = {startDate: d, endDate: d1};
  //         this.selecteddates = {startDate: this.startdate, endDate: this.enddate};
  //         this.filterselected = JSON.parse(res.filterarr);
  //         var a = moment(d);
  //         var b = moment(d1);
  //         if(b.diff(a, 'days')>0){
  //             this.daytypeval = 2;
  //             this.charttype = "Calls Per Day";
  //         }else{
  //             this.daytypeval = 1;
  //             this.charttype = "Calls Per Hour";
  //         }
  //       }
  //       this.filterdata(this.filter);
  //       if(res.filtervalue!=''){
  //         this.isclick = 1;
  //         this.filtervalue = res.filtervalue;
  //       }
  //       this.selectednewdates = this.selecteddates;
  //       this.loadcallsdata(this.filterselected,this.selecteddates,1);
  //       this.getChartNumberOfCalls(this.filterselected,this.selecteddates,this.daytypeval);
  //     });
  // }
  // islabelvaltext:any;
  // savelabel(){
  //   const uuid = this.route.snapshot.paramMap.get('id');
  //   if(this.labelval==undefined){
  //     this.islabelvaltext='yes';
  //     return;
  //   }
  //   this.islabelvaltext='';
  //   const formData = new FormData();
  //   if(uuid!=null){
  //     formData.append('uuid', uuid);
  //   }
  //   if(!this.selecteddate){
  //     this.selecteddate =this.selected1;
  //   }
  //   var start = moment(this.selecteddate.startDate).format('MM/DD/YYYY HH:mm:ss');
  //   var end = moment(this.selecteddate.endDate).format('MM/DD/YYYY HH:mm:ss');
  //   this.startdate = moment.tz(start, 'utc').format("YYYY-MM-DD 00:00:00")
  //   this.enddate = moment.tz(end, 'utc').format("YYYY-MM-DD 23:59:59")
  //   if(this.filtervalue==""){
  //     this.filtertype = 0;
  //   }
  //   // console.log(this.filterselected);return false;
  //   formData.append('company_uuid', this.currentCompany.uuid);
  //   formData.append('reportlabelname', this.labelval);
  //   formData.append('start_date', this.startdate);
  //   formData.append('end_date', this.enddate);
  //   formData.append('filtertype', this.filtertype);
  //   formData.append('filtervalue', this.filtervalue);
  //   formData.append('filterarr', JSON.stringify(this.filterselected));
  //   this.moduleservice.savereport(formData).subscribe(
  //     res => {
  //       if (res.status !== 'error') {
  //         if(res.isavail!=1){
  //           this.labelval="";
  //         }
  //         this.sendMenuUpdateMessage();
  //         this.toastrService.success('Report Saved Successfully');
  //       }else{
  //         this.toastrService.error('Failed To Add Label');
  //       }
  //     });
  // }
  // deletelabel(){
  //   Swal.fire({
  //     title: 'Are you sure?',
  //     text: 'You want to Delete Selected Report Name!',
  //
  //     showCancelButton: true,
  //     confirmButtonText: 'Yes, delete it!',
  //     cancelButtonText: 'No, keep it'
  //   }).then((result) => {
  //     if (result.value) {
  //       const uuid = this.route.snapshot.paramMap.get('id');
  //       this.moduleservice.deleteSelectedSavedReport(uuid).subscribe(
  //         res => {
  //             Swal.fire(
  //               'Deleted!',
  //               'Records Deleted Successfully.',
  //               'success',
  //             )
  //             this.sendMenuUpdateMessage();
  //             setTimeout(() => {
  //               Swal.close()
  //               this.router.navigate(['/reports']);
  //             }, 2000);
  //           },
  //           error => this.error = error
  //       );
  //     } else if (result.dismiss === Swal.DismissReason.cancel) {
  //       Swal.fire(
  //         'Cancelled',
  //         'Your Record is safe :)',
  //         'error'
  //       )
  //       setTimeout(() => {
  //         Swal.close()
  //       }, 2000);
  //     }
  //   });
  // }
  // groupby:any=1;
  getSummary(type) {
    if (this.selecteddate == undefined) {
      this.selecteddate = this.selected1;
    }
    // this.selecteddate = this.selected1;
    $(".tabsbtn").removeClass("btn btn-primary btn-sm activetab");
    if (type == 1) {
      $("#tabs1").addClass("activetab");
      this.filtertype = 1;
      this.loadcallsdata(this.filterselected, this.selecteddate, this.selecteddate_2, 1);
    }
    if (type == 2) {
      $("#tabs2").addClass("activetab");
      this.filtertype = 4;
      this.loadcallsdata(this.filterselected, this.selecteddate, this.selecteddate_2, 4);
    }
    if (type == 3) {
      $("#tabs3").addClass("activetab");
      this.filtertype = 2;
      this.loadcallsdata(this.filterselected, this.selecteddate, this.selecteddate_2, 2);
    }
    if (type == 4) {
      $("#tabs4").addClass("activetab");
      this.filtertype = 3;
      this.loadcallsdata(this.filterselected, this.selecteddate, this.selecteddate_2, 3);
    }
    if (type == 5) {
      $("#tabs5").addClass("activetab");
      this.filtertype = 5;
      this.loadcallsdata(this.filterselected, this.selecteddate, this.selecteddate_2, 5);
    }
    if (type == 5) {
      $("#tabs5").addClass("activetab");
      this.filtertype = 5;
    }
    if (type == 6) {
      $("#tabs6").addClass("activetab");
      this.filtertype = 6;
    }
    if (type == 7) {
      $("#tabs7").addClass("activetab");
      this.filtertype = 7;
    }
    if (type == 8) {
      $("#tabs8").addClass("activetab");
      this.filtertype = 8;
    }
  }
  scrolltoy() {
    $('datatable-body').scrollLeft(1000);
  }
  scrolltox() {
    $('datatable-body').scrollLeft(0);
  }
  filterbyvalue(uuid, value, type = 0) {
    this.istougle = 1;
    this.isclick = 1;
    this.filterdata(this.filtertype);
    let customObj = new filterarr();
    customObj.filtertype = this.filtertype;
    customObj.uuid = uuid;
    customObj.name = value;
    customObj.isorand = 1;
    customObj.isdup = type;
    if (value != "") {
      this.filterselected.push(customObj);
    }
    this.filterval(this.filtertype);
  }
  ngOnDestroy() {
    this.dtTrigger.unsubscribe();
    console.log('Report method destroyed');
    if (this.subscription) {
      this.subscription.unsubscribe();
    }
  }
  copyName(val) {
    const selBox = document.createElement('textarea');
    selBox.style.position = 'fixed';
    selBox.style.left = '0';
    selBox.style.top = '0';
    selBox.style.opacity = '0';
    selBox.value = val;
    document.body.appendChild(selBox);
    selBox.focus();
    selBox.select();
    document.execCommand('copy');
    document.body.removeChild(selBox);
  }
  filtercalldata(filtertype, uuid, no) {
    this.istougle = 1;
    this.isclick = 1;
    this.filterdata(filtertype);
    let customObj = new filterarr();
    customObj.filtertype = filtertype;
    customObj.uuid = uuid;
    customObj.name = no;
    customObj.isorand = 1;
    if (no != "") {
      this.filterselected.push(customObj);
    }
    this.filter = 1;
    this.isselectElement = 1;
    this.loadcallsdata(this.filterselected, this.selecteddate, this.selecteddate_2, 1);
    this.getChartNumberOfCalls(this.filterselected, this.selecteddate, this.selecteddate_2, this.daytypeval);
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_15__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_13__.HttpBackend
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_16__.FormBuilder
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_11__.ActivatedRoute
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_11__.Router
  }, {
    type: _angular_core__WEBPACK_IMPORTED_MODULE_17__.ElementRef
  }, {
    type: ngx_ui_loader__WEBPACK_IMPORTED_MODULE_18__.NgxUiLoaderService
  }, {
    type: _angular_core__WEBPACK_IMPORTED_MODULE_17__.ChangeDetectorRef
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_19__.Title
  }];
  static #_2 = this.propDecorators = {
    table1: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_17__.ViewChild,
      args: ['dataTable1', {
        static: true
      }]
    }],
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_17__.ViewChild,
      args: ['myTable']
    }]
  };
};
ReportsComparisonComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_20__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_17__.Component)({
  selector: 'app-reports-comparison',
  template: _reports_comparison_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_reports_comparison_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], ReportsComparisonComponent);


/***/ }),

/***/ 55761:
/*!************************************************************************!*\
  !*** ./src/app/modules/reports/report-calls/report-calls.component.ts ***!
  \************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "ReportCallsComponent": () => (/* binding */ ReportCallsComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _report_calls_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./report-calls.component.html?ngResource */ 29375);
/* harmony import */ var _report_calls_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./report-calls.component.scss?ngResource */ 13153);
/* harmony import */ var _report_calls_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_report_calls_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../../module.service */ 22947);
/* harmony import */ var angular_highcharts__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! angular-highcharts */ 55199);
/* harmony import */ var highcharts_modules_exporting__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! highcharts/modules/exporting */ 43916);
/* harmony import */ var highcharts_modules_exporting__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(highcharts_modules_exporting__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! highcharts */ 75972);
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_4__);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! moment */ 56908);
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(moment__WEBPACK_IMPORTED_MODULE_5__);
/* harmony import */ var datatables_net__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! datatables.net */ 84375);
/* harmony import */ var datatables_net__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(datatables_net__WEBPACK_IMPORTED_MODULE_6__);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../../global */ 27266);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ngx-toastr */ 94817);








highcharts_modules_exporting__WEBPACK_IMPORTED_MODULE_3___default()(highcharts__WEBPACK_IMPORTED_MODULE_4__);






class DataTablesResponse {}
let ReportCallsComponent = class ReportCallsComponent {
  constructor(moduleservice, fb, toastrService, handler) {
    this.moduleservice = moduleservice;
    this.fb = fb;
    this.toastrService = toastrService;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_7__.GlobalVariable.BASE_API_URL;
    this.event = "";
    this.numbers = '';
    this.dtOptions = {};
    this.submitted = false;
    this.ranges = {
      Today: [moment__WEBPACK_IMPORTED_MODULE_5__(), moment__WEBPACK_IMPORTED_MODULE_5__()],
      Yesterday: [moment__WEBPACK_IMPORTED_MODULE_5__().subtract(1, 'days'), moment__WEBPACK_IMPORTED_MODULE_5__().subtract(1, 'days')],
      'Last 7 Days': [moment__WEBPACK_IMPORTED_MODULE_5__().subtract(6, 'days'), moment__WEBPACK_IMPORTED_MODULE_5__()],
      'Last 30 Days': [moment__WEBPACK_IMPORTED_MODULE_5__().subtract(29, 'days'), moment__WEBPACK_IMPORTED_MODULE_5__()],
      'This Month': [moment__WEBPACK_IMPORTED_MODULE_5__().startOf('month'), moment__WEBPACK_IMPORTED_MODULE_5__().endOf('month')],
      'Last Month': [moment__WEBPACK_IMPORTED_MODULE_5__().subtract(1, 'month').startOf('month'), moment__WEBPACK_IMPORTED_MODULE_5__().subtract(1, 'month').endOf('month')]
      // 'Last 3 Month': [
      //   moment()
      //     .subtract(3, 'month')
      //     .startOf('month'),
      //   moment()
      //     .subtract(1, 'month')
      //     .endOf('month')
      // ]
    };

    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_8__.HttpClient(handler);
    this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.keepCalendarOpeningWithRange = true;
    this.showRangeLabelOnInput = true;
    this.selected = {
      startDate: moment__WEBPACK_IMPORTED_MODULE_5__().startOf('day'),
      endDate: moment__WEBPACK_IMPORTED_MODULE_5__().endOf('day')
    };
  }
  ngOnInit() {
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.CallReportForm = this.fb.group({
      date: ['', ''],
      label: ['', ''],
      duration_type: ['', ''],
      duration: ['', '']
    });
    // this.getChartNumberOfCalls(this.event);
    this.getAllLabels(this.currentUser.uuid);
  }
  get f() {
    return this.searchcallsform.controls;
  }
  getAllLabels(company_uuid) {
    this.moduleservice.getAllLabels(this.currentUser.uuid).subscribe(res => {
      this.alllabel = res;
      console.log(res);
    }, error => this.error = error);
  }
  onCallReportSubmit() {
    // console.log(this.CallReportForm.value); return false;
    this.moduleservice.getCallReports(this.CallReportForm.value, this.currentUser.uuid).subscribe(res => {
      // console.log(res.date); return false;
      this.chart = new angular_highcharts__WEBPACK_IMPORTED_MODULE_9__.Chart({
        chart: {
          type: 'column'
        },
        colors: ['#4572A7', '#AA4643', '#89A54E', '#80699B', '#3D96AE', '#DB843D', '#92A8CD', '#A47D7C', '#B5CA92'],
        title: {
          text: 'Calls By Date'
        },
        subtitle: {
          text: document.ontouchstart === undefined ? 'Click and drag in the plot area to zoom in' : 'Pinch the chart to zoom in'
        },
        accessibility: {
          announceNewData: {
            enabled: true
          }
        },
        xAxis: {
          title: {
            text: 'Date'
          },
          categories: res.date
        },
        yAxis: {
          title: {
            text: 'Number Of Calls'
          }
        },
        legend: {
          enabled: false
        },
        plotOptions: {
          series: {
            borderWidth: 0,
            dataLabels: {
              enabled: true,
              format: '{point.y} Call'
            }
          },
          column: {
            colorByPoint: true
          }
        },
        tooltip: {
          headerFormat: '<span style="font-size:11px">{series.name}</span><br>',
          pointFormat: '<span style="color:{point.color}">{point.name}</span>: <b>{point.y:.2f}%</b> of total<br/>'
        },
        series: [{
          data: res.count,
          type: 'column',
          name: "Call Count"
        }]
      });
    }, error => this.error = error);
    if ($.fn.DataTable.isDataTable(this.table.nativeElement)) {
      $(this.table.nativeElement).dataTable().fnDestroy();
    }
    this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    var that = this;
    this.dtOptions = {
      "paging": false,
      "processing": true,
      "searching": false,
      "info": false,
      "serverSide": true,
      "order": [[2, "desc"]],
      ajax: (dataTablesParameters, callback) => {
        that.http.post(this.ServerUrl + 'getdaywiseLabelSummaryReport/' + this.currentUser.uuid, {
          'dataTablesParameters': dataTablesParameters,
          'formvalue': this.CallReportForm.value
        }, {}).subscribe(resp => {
          // console.log(resp); return false;
          that.numbers = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [{
        data: "label"
      }, {
        data: "noofcalls"
      }, {
        data: "call_duration"
      }, {
        data: "id"
      }, {
        data: "ivr_inputs"
      }, {
        data: "revenue"
      }, {
        data: "created_at"
      }]
    };
    this.dataTable = $(this.table.nativeElement);
    this.dataTable.dataTable(this.dtOptions);
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_10__.FormBuilder
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_11__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_8__.HttpBackend
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_12__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }]
  };
};
ReportCallsComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_13__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_12__.Component)({
  selector: 'app-report-calls',
  template: _report_calls_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_report_calls_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], ReportCallsComponent);


/***/ }),

/***/ 4463:
/*!**************************************************************************************!*\
  !*** ./src/app/modules/reports/report-labelsummary/report-labelsummary.component.ts ***!
  \**************************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "ReportLabelsummaryComponent": () => (/* binding */ ReportLabelsummaryComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _report_labelsummary_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./report-labelsummary.component.html?ngResource */ 83128);
/* harmony import */ var _report_labelsummary_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./report-labelsummary.component.scss?ngResource */ 43792);
/* harmony import */ var _report_labelsummary_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_report_labelsummary_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../../module.service */ 22947);
/* harmony import */ var angular_highcharts__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! angular-highcharts */ 55199);
/* harmony import */ var highcharts_modules_exporting__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! highcharts/modules/exporting */ 43916);
/* harmony import */ var highcharts_modules_exporting__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(highcharts_modules_exporting__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! highcharts */ 75972);
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_4__);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! moment */ 56908);
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(moment__WEBPACK_IMPORTED_MODULE_5__);
/* harmony import */ var datatables_net__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! datatables.net */ 84375);
/* harmony import */ var datatables_net__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(datatables_net__WEBPACK_IMPORTED_MODULE_6__);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../../global */ 27266);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ngx-toastr */ 94817);








highcharts_modules_exporting__WEBPACK_IMPORTED_MODULE_3___default()(highcharts__WEBPACK_IMPORTED_MODULE_4__);






class DataTablesResponse {}
let ReportLabelsummaryComponent = class ReportLabelsummaryComponent {
  constructor(moduleservice, fb, toastrService, handler) {
    this.moduleservice = moduleservice;
    this.fb = fb;
    this.toastrService = toastrService;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_7__.GlobalVariable.BASE_API_URL;
    this.event = "";
    this.numbers = '';
    this.dtOptions = {};
    this.submitted = false;
    this.ranges = {
      Today: [moment__WEBPACK_IMPORTED_MODULE_5__(), moment__WEBPACK_IMPORTED_MODULE_5__()],
      Yesterday: [moment__WEBPACK_IMPORTED_MODULE_5__().subtract(1, 'days'), moment__WEBPACK_IMPORTED_MODULE_5__().subtract(1, 'days')],
      'Last 7 Days': [moment__WEBPACK_IMPORTED_MODULE_5__().subtract(6, 'days'), moment__WEBPACK_IMPORTED_MODULE_5__()],
      'Last 30 Days': [moment__WEBPACK_IMPORTED_MODULE_5__().subtract(29, 'days'), moment__WEBPACK_IMPORTED_MODULE_5__()],
      'This Month': [moment__WEBPACK_IMPORTED_MODULE_5__().startOf('month'), moment__WEBPACK_IMPORTED_MODULE_5__().endOf('month')],
      'Last Month': [moment__WEBPACK_IMPORTED_MODULE_5__().subtract(1, 'month').startOf('month'), moment__WEBPACK_IMPORTED_MODULE_5__().subtract(1, 'month').endOf('month')]
      // 'Last 3 Month': [
      //   moment()
      //     .subtract(3, 'month')
      //     .startOf('month'),
      //   moment()
      //     .subtract(1, 'month')
      //     .endOf('month')
      // ]
    };

    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_8__.HttpClient(handler);
    this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.keepCalendarOpeningWithRange = true;
    this.showRangeLabelOnInput = true;
    this.selected = {
      startDate: moment__WEBPACK_IMPORTED_MODULE_5__().startOf('day'),
      endDate: moment__WEBPACK_IMPORTED_MODULE_5__().endOf('day')
    };
  }
  ngOnInit() {
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.CallReportForm = this.fb.group({
      date: ['', ''],
      label: ['', ''],
      duration_type: ['', ''],
      duration: ['', '']
    });
    // this.getChartNumberOfCalls(this.event);
    this.getAllLabels(this.currentUser.uuid);
  }
  get f() {
    return this.searchcallsform.controls;
  }
  getAllLabels(company_uuid) {
    this.moduleservice.getAllLabels(this.currentUser.uuid).subscribe(res => {
      this.alllabel = res;
      console.log(res);
    }, error => this.error = error);
  }
  onCallReportSubmit() {
    // console.log(this.CallReportForm.value); return false;
    this.moduleservice.getLabelReports(this.CallReportForm.value, this.currentUser.uuid).subscribe(res => {
      // console.log(res.date); return false;
      this.chart = new angular_highcharts__WEBPACK_IMPORTED_MODULE_9__.Chart({
        chart: {
          type: 'column'
        },
        colors: ['#4572A7', '#AA4643', '#89A54E', '#80699B', '#3D96AE', '#DB843D', '#92A8CD', '#A47D7C', '#B5CA92'],
        title: {
          text: 'Calls By Labels'
        },
        subtitle: {
          text: document.ontouchstart === undefined ? 'Click and drag in the plot area to zoom in' : 'Pinch the chart to zoom in'
        },
        accessibility: {
          announceNewData: {
            enabled: true
          }
        },
        xAxis: {
          title: {
            text: 'Labels'
          },
          categories: res.labels
        },
        yAxis: {
          title: {
            text: 'Number Of Calls'
          }
        },
        legend: {
          enabled: false
        },
        plotOptions: {
          series: {
            borderWidth: 0,
            dataLabels: {
              enabled: true,
              format: '{point.y} Call'
            }
          },
          column: {
            colorByPoint: true
          }
        },
        tooltip: {
          headerFormat: '<span style="font-size:11px">{series.name}</span><br>',
          pointFormat: '<span style="color:{point.color}">{point.name}</span>: <b>{point.y:.2f}%</b> of total<br/>'
        },
        series: [{
          data: res.count,
          type: 'column',
          name: "Call Count"
        }]
      });
    }, error => this.error = error);
    if ($.fn.DataTable.isDataTable(this.table.nativeElement)) {
      $(this.table.nativeElement).dataTable().fnDestroy();
    }
    this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    var that = this;
    this.dtOptions = {
      "pagingType": 'full_numbers',
      "processing": true,
      "searching": false,
      "serverSide": true,
      "lengthMenu": [[-1, 50, 100, 500, 2000, 5000], ["All", 50, 100, 500, 2000, 5000]],
      "pageLength": 500,
      "order": [[2, "desc"]],
      ajax: (dataTablesParameters, callback) => {
        that.http.post(this.ServerUrl + 'getdaywiseLabelSummaryReport/' + this.currentUser.uuid, {
          'dataTablesParameters': dataTablesParameters,
          'formvalue': this.CallReportForm.value
        }, {}).subscribe(resp => {
          // console.log(resp.data); return false;
          that.numbers = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [{
        data: "created_at"
      }, {
        data: "label"
      }, {
        data: "noofcalls"
      }, {
        data: "avg"
      }, {
        data: "call_duration"
      }, {
        data: "ivr_inputs"
      }, {
        data: "revenue"
      }]
    };
    this.dataTable = $(this.table.nativeElement);
    this.dataTable.dataTable(this.dtOptions);
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_10__.FormBuilder
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_11__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_8__.HttpBackend
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_12__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }]
  };
};
ReportLabelsummaryComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_13__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_12__.Component)({
  selector: 'app-report-labelsummary',
  template: _report_labelsummary_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_report_labelsummary_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], ReportLabelsummaryComponent);


/***/ }),

/***/ 15574:
/*!******************************************************!*\
  !*** ./src/app/modules/reports/reports.component.ts ***!
  \******************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "ReportsComponent": () => (/* binding */ ReportsComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_22__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _reports_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./reports.component.html?ngResource */ 24187);
/* harmony import */ var _reports_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./reports.component.scss?ngResource */ 53470);
/* harmony import */ var _reports_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_reports_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../module.service */ 22947);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! sweetalert2 */ 60598);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(sweetalert2__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../global */ 27266);
/* harmony import */ var ngx_csv_ngx_csv__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ngx-csv/ngx-csv */ 94551);
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! moment */ 56908);
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(moment__WEBPACK_IMPORTED_MODULE_6__);
/* harmony import */ var datatables_net__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! datatables.net */ 84375);
/* harmony import */ var datatables_net__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(datatables_net__WEBPACK_IMPORTED_MODULE_7__);
/* harmony import */ var _swimlane_ngx_datatable__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(/*! @swimlane/ngx-datatable */ 93143);
/* harmony import */ var angular_highcharts__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(/*! angular-highcharts */ 55199);
/* harmony import */ var highcharts_modules_exporting__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! highcharts/modules/exporting */ 43916);
/* harmony import */ var highcharts_modules_exporting__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(highcharts_modules_exporting__WEBPACK_IMPORTED_MODULE_8__);
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! highcharts */ 75972);
/* harmony import */ var highcharts__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(highcharts__WEBPACK_IMPORTED_MODULE_9__);
/* harmony import */ var moment_timezone__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! moment-timezone */ 92469);
/* harmony import */ var moment_timezone__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(moment_timezone__WEBPACK_IMPORTED_MODULE_10__);
/* harmony import */ var ngx_ui_loader__WEBPACK_IMPORTED_MODULE_20__ = __webpack_require__(/*! ngx-ui-loader */ 36413);
/* harmony import */ var rxjs__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! rxjs */ 92218);
/* harmony import */ var rxjs_add_observable_interval__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! rxjs/add/observable/interval */ 95363);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_21__ = __webpack_require__(/*! @angular/platform-browser */ 34497);









//import 'sweetalert2/src/sweetalert2.scss'










highcharts_modules_exporting__WEBPACK_IMPORTED_MODULE_8___default()(highcharts__WEBPACK_IMPORTED_MODULE_9__);




const router = _angular_router__WEBPACK_IMPORTED_MODULE_12__.Router;
class DataTablesResponse {}
class filterarr {}
let ReportsComponent = class ReportsComponent {
  constructor(moduleservice, toastrService, handler, fb, route, router, el, ngxLoader, cdRef, titleService) {
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.fb = fb;
    this.route = route;
    this.router = router;
    this.el = el;
    this.ngxLoader = ngxLoader;
    this.cdRef = cdRef;
    this.titleService = titleService;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_4__.GlobalVariable.BASE_API_URL;
    this.numbers = '';
    this.currentUser = {};
    this.dtOptions = {};
    this.dtTrigger = new rxjs__WEBPACK_IMPORTED_MODULE_13__.Subject();
    this.dtOptionsdetails = {};
    this.labels = 0;
    // callsdata: any = 0;
    this.callsdata = [];
    this.submitted = false;
    this.event = "";
    this.expanded = {};
    this.rows = [];
    this.gmttime = '-07:00';
    this.alltags = [];
    this.tagselectedvalue = "";
    this.ranges = {
      Today: [moment__WEBPACK_IMPORTED_MODULE_6__().format("MM/DD/YYYY 00:00"), moment__WEBPACK_IMPORTED_MODULE_6__().format("MM/DD/YYYY 23:59")],
      Yesterday: [moment__WEBPACK_IMPORTED_MODULE_6__().subtract(1, 'days').format("MM/DD/YYYY 00:00"), moment__WEBPACK_IMPORTED_MODULE_6__().subtract(1, 'days').format("MM/DD/YYYY 23:59")],
      "Last 2 days": [moment__WEBPACK_IMPORTED_MODULE_6__().subtract(1, 'days').format("MM/DD/YYYY 00:00"), moment__WEBPACK_IMPORTED_MODULE_6__().format("MM/DD/YYYY 23:59")],
      "Last 7 days": [moment__WEBPACK_IMPORTED_MODULE_6__().subtract(6, 'days').format("MM/DD/YYYY 00:00"), moment__WEBPACK_IMPORTED_MODULE_6__().format("MM/DD/YYYY 23:59")],
      "This Week": [moment__WEBPACK_IMPORTED_MODULE_6__().startOf('week').add(1, 'days').format("MM/DD/YYYY 00:00"), moment__WEBPACK_IMPORTED_MODULE_6__().endOf('week').add(1, 'days').format("MM/DD/YYYY 23:59")],
      "Last Week": [moment__WEBPACK_IMPORTED_MODULE_6__().startOf('week').subtract(6, 'days').format("MM/DD/YYYY 00:00"), moment__WEBPACK_IMPORTED_MODULE_6__().endOf('week').subtract(6, 'days').format("MM/DD/YYYY 23:59")],
      "Last 30 days": [moment__WEBPACK_IMPORTED_MODULE_6__().subtract(30, 'days').format("MM/DD/YYYY 00:00"), moment__WEBPACK_IMPORTED_MODULE_6__().format("MM/DD/YYYY 23:59")],
      'This Month': [moment__WEBPACK_IMPORTED_MODULE_6__().startOf('month'), moment__WEBPACK_IMPORTED_MODULE_6__().endOf('month')],
      'Last Month': [moment__WEBPACK_IMPORTED_MODULE_6__().subtract(1, 'month').startOf('month'), moment__WEBPACK_IMPORTED_MODULE_6__().subtract(1, 'month').endOf('month')]
    };
    // ranges: any = {
    //   Today: [ moment.tz(moment(), "America/Phoenix").format("MM/DD/YYYY 00:00"),  moment.tz(moment(), "America/Phoenix").format("MM/DD/YYYY 23:59")],
    //   Yesterday: [moment.tz(moment().subtract(1, 'days'), "America/Phoenix").format("MM/DD/YYYY 00:00"),  moment.tz(moment().subtract(1, 'days'), "America/Phoenix").format("MM/DD/YYYY 23:59")],
    //   'This Month': [moment().startOf('month'), moment().endOf('month')],
    //   'Last Month': [
    //    moment()
    //     .subtract(1, 'month')
    //     .startOf('month')
    //     ,
    //    moment()
    //     .subtract(1, 'month')
    //     .endOf('month')
    //   ],
    // };
    this.userselectedvalue = "";
    this.allusers = [];
    this.ngxclass = "dark";
    this.result = [];
    this.colorcode = '#fff';
    this.calls = [];
    this.lists = [];
    this.ColumnMode = _swimlane_ngx_datatable__WEBPACK_IMPORTED_MODULE_14__.ColumnMode;
    this.SelectionType = _swimlane_ngx_datatable__WEBPACK_IMPORTED_MODULE_14__.SelectionType;
    this.selectedrow = [];
    this.headerHeight = 40;
    this.rowHeight = 40;
    this.pageLimit = 100;
    this.loadingIndicator = false;
    // get f() { return this.searchcallsform.controls; }
    // loadcalls(filterselected:any,date:any){
    //   if ($.fn.DataTable.isDataTable(this.table.nativeElement) ) {
    //     $(this.table.nativeElement).dataTable().fnDestroy();
    //   }
    //   this.filterselectedforexport = filterselected;
    //   this.dateforexport = date;
    //   this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    //   this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    //   var that = this;
    //   this.dtOptionsdetails = {
    //     "pagingType": 'full_numbers',
    //     "processing": true,
    //     "serverSide": true,
    //     "lengthMenu": [[-1, 50, 100, 500, 2000], ["All", 50, 100, 500, 2000]],
    //     "pageLength": 100,
    //     "order": [[ 2, "desc" ]],
    //     "searching":false,
    //     ajax: (dataTablesParameters: any, callback) => {
    //       that.http.post<DataTablesResponse>(
    //         this.ServerUrl+'getcalls/'+this.currentCompany.uuid, {'dataTablesParameters':dataTablesParameters,'filterselected':filterselected,date:date,'timezone':this.currentUser.timezone}
    //        , {}
    //       ).subscribe(resp => {
    //                 // console.log(resp); return false;
    //                 that.labels = resp.data;
    //                 callback({
    //                     recordsTotal: resp.recordsTotal,
    //                     recordsFiltered: resp.recordsFiltered,
    //                     data: [],
    //                 });
    //             });
    //     },
    //     columns: [
    //       //
    //       {data:"detail"},{data:"did"},{data:"incoming_number"},{data:"publisher"},{data:"target"},{data:"campaign"},{data:"routed_to"},{data:"call_duration"},{data:"ivr_duration"},{data:"billable_duration"},{data:"date_of_call"},{data:"assosciated_labels"},{data:"hangup_by"},{data:"revenue"},{data:"duplicate"},{data:"payout"},{data:"recording"}
    //     ],
    // };
    // this.dataTable = $(this.table.nativeElement);
    // this.dataTable.dataTable(this.dtOptionsdetails);
    // }
    // get f() { return this.searchcallsform.controls; }
    this.totaldata = [];
    this.totalcount = [];
    // loadcallsdata(filterselected:any,date:any,groupby:any){
    //   $("#datatable1").dataTable().fnDestroy();
    //   // $("#summarytbl").dataTable().fnDestroy();
    //   this.ngxLoader.startLoader('loader-02');
    //   this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    //   this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    //   // this.ngxLoader.startLoader('loader-03');
    //   this.http.post<any>(
    //             this.ServerUrl+'getcallsdata/'+this.currentCompany.uuid, {'filterselected':filterselected,'date':date,'timezone':this.currentUser.timezone,'groupby':groupby}
    //           , {}
    //           ).subscribe(resp => {
    //                 //
    //                 this.callsdata = resp.data;
    //                 this.totalcount = resp.totalarr;
    //                 this.totaldata  = resp.data.length ;
    //                 this.dtTrigger.next();
    //                 this.ngxLoader.stopLoader('loader-02');
    //               },
    //               error => this.error = error
    //           );
    // }
    // loadcallsdata(filterselected:any,date:any,groupby:any){
    //   this.ngxLoader.startLoader('loader-02');
    //   this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    //   let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    //       this.http.post<any>(
    //         this.ServerUrl+'getcallsdata/'+this.currentCompany.uuid, {'filterselected':filterselected,'date':date,'timezone':currentUser.timezone,'groupby':groupby}
    //       , {}
    //       ).subscribe(resp => {
    //           // console.log(resp);
    //           this.callsdata = resp.data;
    //           this.totalcount = resp.totalarr;
    //           this.totaldata  = resp.data.length ;
    //           this.dtTrigger.next();
    //           this.ngxLoader.stopLoader('loader-02');
    //         },
    //         error => this.error = error
    //     );
    // }
    this.isloading = false;
    // addActive(id){
    //   alert(id);
    // }
    this.ivr_info = [];
    this.noofrecords = 500;
    this.exportheader = [];
    this.header = [];
    this.isclick = 1;
    this.istougle = 1;
    this.filtertype = 1;
    this.containtext = "Equals Single Value";
    this.dropdownbkp = [];
    this.containfiltertype = 0;
    this.filteradvanced = 0;
    this.filtervalue = '';
    this.filterdate = '';
    this.isadded = 1;
    this.isfiltered = 0;
    this.isshowbyhrs = 1;
    this.isselectElement = 0;
    this.filterselected = [];
    this.charttype = "";
    this.daytypeval = 1;
    this.isreport = 0;
    this.islive = false;
    this.blockdurationval = "";
    this.blockdurationvalselected = "";
    this.adjust_revenue = "";
    this.adjust_payout = "";
    this.adjust_reason = "";
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    if (currentUser.gmttime != undefined) {
      this.gmttime = currentUser.gmttime;
    }
    this.loader = {
      loaderId: 'customLoaderId',
      loaderId1: 'customLoaderId1',
      loaderId2: 'customLoaderId2'
    };
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_15__.HttpClient(handler);
    this.router.routeReuseStrategy.shouldReuseRoute = () => false;
    this.alwaysShowCalendars = true;
    this.keepCalendarOpeningWithRange = true;
    this.showRangeLabelOnInput = true;
    // this.selected = {startDate: moment.tz(moment(), "America/Phoenix").format("MM/DD/YYYY 00:00"), endDate: moment.tz(moment(), "America/Phoenix").format("MM/DD/YYYY 23:59")};
    this.selected = {
      startDate: moment__WEBPACK_IMPORTED_MODULE_6__().format("MM/DD/YYYY 00:00"),
      endDate: moment__WEBPACK_IMPORTED_MODULE_6__().format("MM/DD/YYYY 23:59")
    };
    // console.log(this.selected);
    this.selected1 = this.selected;
    this.selected2 = this.selected;
  }
  triggerFalseClick() {
    let el = this.copyname.nativeElement;
    // el.click();
    console.log(el);
  }
  onPage(event) {
    clearTimeout(this.timeout);
    this.timeout = setTimeout(() => {
      console.log('paged!', event);
    }, 100);
  }
  toggleExpandRow(rowIndex, row) {
    this.loadingIndicator = true;
    this.table.rowDetail.toggleExpandRow(row);
    this.details(rowIndex, row);
  }
  toggleCollaspeRow(row) {
    this.table.rowDetail.collapseAllRows();
  }
  sendMenuUpdateMessage() {
    // send message to subscribers via observable subject
    this.moduleservice.sendMenuUpdateMessage('1');
  }
  getuser() {
    let role = this.userselectedvalue[0].role;
    this.loadcalls(this.filterselected, this.selecteddate, role);
    this.loadcallsdata(this.filterselected, this.selecteddate, 1, role);
    this.getChartNumberOfCalls(this.filterselected, this.selecteddate, this.daytypeval, role);
  }
  ngAfterContentChecked() {
    this.cdRef.detectChanges();
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngOnInit() {
    // this.showLoadingIndicator= true;
    // setTimeout(()=>{this.showLoadingIndicator= false; },1000);
    const uuid = this.route.snapshot.paramMap.get('id');
    // console.log(uuid);
    let currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    // console.log(currentUser);
    this.getallivr(currentCompany.uuid).then(res => {
      let tags = [{
        "id": 1,
        "uuid": 1,
        "itemName": "State",
        "name": "State",
        "category": "InboundNumber"
      }, {
        "id": 2,
        "uuid": 2,
        "itemName": "Name",
        "name": "Name",
        "category": "Ivr"
      }];
      this.result = res;
      this.alltags = tags.concat(this.result);
    });
    if (currentUser.role === 2) {
      this.userselectedvalue = [{
        "id": currentUser.uuid,
        "itemName": 'Admin'
      }];
      this.getallusers(currentCompany.uuid, currentUser.role).then(res => {
        this.allusers = res;
      });
    }
    if (currentUser.role !== 2) {
      this.userselectedvalue = [{
        "id": currentUser.uuid,
        "itemName": currentUser.first_name
      }];
      let cat = "";
      if (currentUser.role == 3) {
        cat = "Publishers";
      }
      if (currentUser.role == 4) {
        cat = "Buyers";
      }
      this.allusers = [{
        "id": currentUser.uuid,
        "itemName": currentUser.first_name,
        'category': cat
      }];
    }
    this.refresh_date = new Date();
    // console.log(this.allusers);
    if (uuid != null) {
      this.getsavedreports(uuid);
    } else {
      this.setTitle('Reports');
      this.route.queryParams.subscribe(params => {
        // console.log(params);
        if (Object.keys(params).length > 0) {
          // console.log(params);
          let customObj = new filterarr();
          customObj.filteradvanced = params.filteradvanced;
          customObj.filtertype = params.filtertype;
          customObj.filterlabel = params.filterlabel;
          customObj.containfiltertype = params.containfiltertype;
          customObj.containfiltertext = params.containfiltertext;
          customObj.uuid = params.uuid;
          customObj.name = params.name;
          customObj.isorand = 0;
          this.filterselected.push(customObj);
          this.istougle = 0;
          this.filter = 1;
          this.loadcalls(this.filterselected, this.selecteddate, this.currentUser.role);
          this.loadcallsdata(this.filterselected, this.selecteddate, 2, this.currentUser.role);
          this.getChartNumberOfCalls(this.filterselected, this.selecteddate, this.daytypeval, this.currentUser.role);
        } else {
          this.selecteddate = {
            startDate: moment__WEBPACK_IMPORTED_MODULE_6__().format("MM/DD/YYYY 00:00"),
            endDate: moment__WEBPACK_IMPORTED_MODULE_6__().format("MM/DD/YYYY 23:59")
          };
          this.loadcalls("", this.selecteddate);
          this.loadcallsdata("", this.selecteddate, 1);
          this.getChartNumberOfCalls(0, this.selecteddate, 1);
        }
      });
      // this.getsavedreports();
    }

    if ($("body").hasClass("theme-white")) {
      this.ngxclass = 'material';
    }
    // const source = interval(15000);
    // this.subscription = source.subscribe(val => this.loadlivecalls());
    // this.subscriptions.push(this.subscription);
  }

  getallivr(company_uuid) {
    return new Promise((res, rej) => {
      this.moduleservice.getIVRMenus(company_uuid).subscribe(result => {
        res(result);
      }, error => this.error = error);
    });
  }
  getallusers(company_uuid, role) {
    return new Promise((res, rej) => {
      this.moduleservice.getallusers(company_uuid, role).subscribe(result => {
        res(result);
      }, error => this.error = error);
    });
  }
  getChartNumberOfCalls(filterselected, date, daytype, role = "") {
    this.ngxLoader.startLoader('customLoaderId', 'loader-03');
    if ($("html").hasClass("theme-light")) {
      this.bgcolorcode = 'rgb(17,19,25)';
      // this.colorcode='rgb(17,19,25)';
    }

    this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    let user_uuid, selectedrole;
    if (this.userselectedvalue != "" && this.userselectedvalue[0]['category'] == 'Publisher') {
      user_uuid = this.userselectedvalue[0]['id'];
      selectedrole = 3;
    } else {
      if (role == "") {
        selectedrole = this.currentUser.role;
        user_uuid = this.currentUser.uuid;
      } else {
        selectedrole = role;
        user_uuid = this.userselectedvalue[0].id;
      }
    }
    let buyer_uuids = [];
    if (this.currentUser.role == 4) {
      buyer_uuids = this.currentUser?.companydetails.map(item => item.user_uuid);
    }
    this.chartarg = {
      filterselected: filterselected,
      date: date,
      user_uuid: user_uuid,
      role: selectedrole,
      buyer_uuids
    };
    this.moduleservice.getChartbyfilter(this.currentCompany.uuid, this.chartarg, daytype, this.currentUser.timezone).subscribe(res => {
      this.chart = new angular_highcharts__WEBPACK_IMPORTED_MODULE_16__.Chart({
        chart: {
          height: '20%',
          // polar: true,
          type: 'line',
          backgroundColor: this.bgcolorcode
        },
        exporting: {
          enabled: true
        },
        title: {
          text: '' + this.charttype,
          style: {
            color: this.colorcode
          }
        },
        subtitle: {
          text: document.ontouchstart === undefined ? 'Click and drag in the plot area to zoom in' : 'Pinch the chart to zoom in',
          style: {
            color: this.colorcode
          }
        },
        credits: {
          enabled: false
        },
        tooltip: {
          shared: true
        },
        xAxis: {
          minRange: 0,
          gridLineWidth: 0,
          title: {
            text: '' + this.charttype,
            style: {
              color: this.colorcode
            }
          },
          categories: res.cattype
        },
        yAxis: {
          min: 0,
          gridLineWidth: 1,
          title: {
            text: 'Number Of Calls',
            style: {
              color: this.colorcode
            }
          },
          gridLineColor: '#2f3031'
        },
        colors: ['rgb(58,186,244)'],
        plotOptions: {
          column: {
            colorByPoint: true
          },
          line: {
            dataLabels: {
              useHTML: true,
              enabled: true,
              format: '{point.percentage:.1f} %',
              color: 'white'
            },
            enableMouseTracking: false
          }
        },
        series: [{
          data: res.chartdata,
          type: 'column',
          name: "Call Count",
          color: '#0066FF'
        }, {
          name: 'Converted',
          color: '#F9B236',
          type: 'spline',
          data: res.converted
        }, {
          name: 'Connected',
          type: 'spline',
          color: '#20bf55',
          data: res.connected
        }, {
          name: 'No Answer',
          type: 'spline',
          color: 'red',
          data: res.noanswer
        }, {
          name: 'No Connect',
          type: 'spline',
          color: 'red',
          data: res.noconnect
        }]
      });
      this.ngxLoader.stopLoader('customLoaderId', 'loader-03');
    }, error => this.error = error);
  }
  onActivate(event) {
    console.log('Activate Event', event);
  }
  onSelect(selectedrow) {
    // console.log('Select Event',selectedrow.selected);
    // console.log('Select Event', selectedrow, this.selectedrow);
    this.selectedrow.splice(0, this.selectedrow.length);
    this.selectedrow.push(...selectedrow.selected);
    // console.log(selectedrow.selected);
  }

  loadcalls(filterselected, date, role = "") {
    // console.log(this.userselectedvalue[0]['id']);
    this.loadingIndicator = true;
    // this.ngxLoader.start();
    this.ngxLoader.startLoader('customLoaderId2');
    // this.ngxLoader.start();
    let currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    const formData = new FormData();
    formData.append('filterselected', JSON.stringify(filterselected));
    if (this.userselectedvalue != "" && this.userselectedvalue[0]['category'] == 'Publisher') {
      formData.append('user_uuid', this.userselectedvalue[0]['id']);
      formData.append('role', '3');
    } else {
      if (role == "") {
        formData.append('user_uuid', currentUser.uuid);
        formData.append('role', currentUser.role);
      } else {
        formData.append('user_uuid', this.userselectedvalue[0].id);
        formData.append('role', role);
      }
    }
    formData.append('timezone', currentUser.timezone);
    formData.append('date', JSON.stringify(date));
    if (currentUser.role == 4) {
      let buyer_uuids = currentUser?.companydetails.map(item => item.user_uuid);
      formData.append('buyer_uuids', JSON.stringify(buyer_uuids));
    }
    this.http.post(this.ServerUrl + 'getcallsdatanew/' + currentCompany.uuid, formData, {
      headers: new _angular_common_http__WEBPACK_IMPORTED_MODULE_15__.HttpHeaders()
      // .set('Pragma', 'no-cache')
      // .set('Cache-Control', 'no-cache')
    }).subscribe(resp => {
      this.calls = resp[0].Response.data;
      this.lists = resp[0].Response.data;
      this.loadingIndicator = false;
      // this.ngxLoader.stopBackground("customLoaderId2");
      this.ngxLoader.stopLoader('customLoaderId2');
      // console.log(this.blogPostsList);
    }, error => {
      // this.ngxLoader.stopBackground("customLoaderId2");
      this.ngxLoader.stopLoader('customLoaderId2');
      this.loadingIndicator = false;
    });
  }
  // livecalls = []
  // loadlivecalls(): void {
  //   this.loadingIndicator = true;
  //   this.http.post<any>(
  //     this.ServerUrl+'livecallReport/',
  //      {}
  //   ).subscribe(resp => {
  //     // console.log(resp.rows);
  //       this.livecalls = resp.rows;
  //       this.loadingIndicator = false;
  //   }, error => {
  //     this.loadingIndicator = false;
  //   });
  // }
  loaddataonscroll(limit) {
    // this.ngxLoader.start();
    this.ngxLoader.startBackground('customLoaderId2');
    this.loadingIndicator = true;
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    const formData = new FormData();
    formData.append('filterselected', JSON.stringify(this.filterselected));
    formData.append('timezone', currentUser.timezone);
    if (this.userselectedvalue != "" && this.userselectedvalue[0]['category'] == 'Publisher') {
      formData.append('user_uuid', this.userselectedvalue[0]['id']);
      formData.append('role', '3');
    } else {
      formData.append('user_uuid', currentUser.uuid);
      formData.append('role', currentUser.role);
    }
    formData.append('date', JSON.stringify(this.selected1));
    let newlimit = limit;
    let currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    if (currentUser.role == 4) {
      let buyer_uuids = currentUser?.companydetails.map(item => item.user_uuid);
      formData.append('buyer_uuids', JSON.stringify(buyer_uuids));
    }
    this.http.post(this.ServerUrl + 'getcallsdatanew/' + currentCompany.uuid + '/' + this.calls.length + '/' + newlimit, formData).subscribe(resp => {
      const rows = [...this.calls, ...resp[0].Response.data];
      this.calls = rows;
      this.lists = resp[0].Response.data;
      this.loadingIndicator = false;
      // this.ngxLoader.stop();
      this.ngxLoader.stopBackground('customLoaderId2');
      // console.log(this.blogPostsList);
    }, error => {
      this.loadingIndicator = false;
      // this.ngxLoader.stop();
      this.ngxLoader.stopBackground('customLoaderId2');
    });
  }
  onScroll(event) {
    let offsetY = event.offsetY;
    let offsetX = event.offsetX;
    // console.log(event.offsetY);return
    // if(offsetY != 125 || offsetY!=undefined){
    const viewHeight = this.el.nativeElement.getBoundingClientRect().height - this.headerHeight;
    if (offsetX == 0 && !this.loadingIndicator && offsetY + viewHeight >= this.calls.length * this.rowHeight) {
      // if (!this.loadingIndicator && offsetY + viewHeight >= this.rows.length * 100) {
      let limit = this.pageLimit;
      if (this.calls.length === 0) {
        const pageSize = Math.ceil(viewHeight / this.rowHeight);
        limit = Math.max(pageSize, this.pageLimit);
      }
      this.loaddataonscroll(limit);
    }
    // }
  }

  play(url, incomingnumber) {
    this.toastrService.show(`<audio style="width: 130px;height: 30px;" controls><source src="https://d2actkasrcrrs8.cloudfront.net/${url}" type="audio/mp3"></audio>`, 'Inbound # - ' + incomingnumber, {
      closeButton: true,
      extendedTimeOut: 0,
      timeOut: 0,
      tapToDismiss: false,
      enableHtml: true,
      positionClass: 'toast-bottom-right'
    });
  }
  loadcallsdata(filterselected, date, groupby, selerole = "") {
    this.isloading = true;
    if ($.fn.DataTable.isDataTable(this.table1.nativeElement)) {
      $(this.table1.nativeElement).dataTable().fnDestroy();
    }
    // console.log(date);
    this.ngxLoader.startLoader('customLoaderId1');
    this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    let buyer_uuids = [];
    if (this.currentUser.role == 4) {
      buyer_uuids = this.currentUser?.companydetails.map(item => item.user_uuid);
    }
    let user_uuid, role;
    if (this.userselectedvalue != "" && this.userselectedvalue[0]['category'] == 'Publisher') {
      user_uuid = this.userselectedvalue[0]['id'];
      role = 3;
    } else {
      if (selerole == "") {
        user_uuid = this.currentUser.uuid;
        role = this.currentUser.role;
      } else {
        role = selerole;
        user_uuid = this.userselectedvalue[0].id;
      }
    }
    if (this.currentUser.role == 4) {
      this.filtertype = 2;
      $("#tabs3").addClass("activetab");
      groupby = 2;
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.dtOptions = {
      pagingType: 'full_numbers',
      lengthChange: false,
      paging: false,
      searching: false
      // pageLength: 200
    };

    this.http.post(this.ServerUrl + 'getcallsdata/' + this.currentCompany.uuid, {
      'filterselected': filterselected,
      'date': date,
      'role': role,
      'user_uuid': user_uuid,
      'timezone': this.currentUser.timezone,
      'groupby': groupby,
      'tagselectedvalue': this.tagselectedvalue,
      buyer_uuids
    }, {}).subscribe(resp => {
      this.isloading = false;
      this.callsdata = resp.data;
      this.totalcount = resp.totalarr;
      this.totaldata = resp.data.length;
      if (resp.data.length > 0) {
        this.dtTrigger.next();
      }
      this.ngxLoader.stopLoader('customLoaderId1');
    }, error => this.error = error);
    // var that = this;
    // this.dtOptions = {
    //   "dom": '<"top">rt<"bottom"flp><"clear">',
    //   "pagingType": 'full_numbers',
    //   // "processing": true,
    //   // "serverSide": false,
    //   // "lengthMenu": [[-1, 50, 100, 500, 2000, 5000], ["All", 50, 100, 500, 2000, 5000 ]],
    //   // "pageLength": 100,
    //   // "order": [[ 2, "asc" ]],
    //   "searching":false,
    //   ajax: (dataTablesParameters: any, callback) => {
    //   //   that.http.post<DataTablesResponse>(
    //   //     this.ServerUrl+'getcallsdata/'+this.currentCompany.uuid, {'dataTablesParameters':dataTablesParameters,'filterselected':filterselected,'date':date,'timezone':this.currentUser.timezone,'groupby':groupby}
    //   //    , {}
    //   //   ).subscribe(resp => {
    //     this.http.post<any>(
    //               this.ServerUrl+'getcallsdata/'+this.currentCompany.uuid, {'filterselected':filterselected,'date':date,'timezone':currentUser.timezone,'groupby':groupby}
    //             , {}
    //             ).subscribe(resp => {
    //               // console.log(resp); return false;
    //               this.callsdata = resp.data;
    //               this.totalcount = resp.totalarr;
    //               this.totaldata  = resp.data.length ;
    //               // this.totaldata  = resp.data.length ;
    //               callback({
    //                   recordsTotal: resp.recordsTotal,
    //                   recordsFiltered: resp.recordsFiltered,
    //                   data: [],
    //               });
    //           });
    //   },
    //   columns: [
    //     {data:"filter"},{data:"incoming"},{data:"uniquecalls"},{data:"ivr_inputs"},{data:"reachedtobuyer"},{data:"connected"},{data:"qualified"},{data:"converted"},{data:"completed"},{data:"no_answer"},{data:"no_connect"},{data:"duplicate"},{data:"payout"},{data:"revenue"},{data:"profit"},{data:"cr_percent"},{data:"rpc"},{data:"acl"},{data:"tcl"},
    //   ],
    // };
    // this.dataTable1 = $(this.table1.nativeElement);
    // this.dataTable1.dataTable(this.dtOptions);
    // this.ngxLoader.stopLoader('loader-02');
  }

  details(i, data) {
    // console.log(data);
    // return
    // var tr = $('td.details-control').closest('tr').eq(i);
    // var divClass = $(".detailrow_"+i).eq(0).attr('class');
    // if (divClass.indexOf('shown') > -1) {
    //     $(".appendedtbl_"+i).remove();
    //       $(".detailrow_"+i).removeClass('shown');
    //   }else {
    this.ngxLoader.start();
    this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.moduleservice.getReportdetailsdata(data.uuid, this.currentUser.uuid).subscribe(res => {
      // console.log(this.gmttime);
      // Target
      this.ivr_info = res.data[0].ivr_details_info;
      let time = moment__WEBPACK_IMPORTED_MODULE_6__.utc(res.data[0].start_stamp).utcOffset(this.gmttime).format("YYYY-MM-DD HH:mm:ss");
      let endtime = moment__WEBPACK_IMPORTED_MODULE_6__.utc(res.data[0].end_stamp).utcOffset(this.gmttime).format("YYYY-MM-DD HH:mm:ss");
      this.ngxLoader.stop();
      var targetid;
      if (res.tagetdialed[0].targetid != null) {
        targetid = res.tagetdialed[0].targetid;
      } else {
        targetid = "-";
      }
      var targetname;
      if (res.tagetdialed[0].targetname != null) {
        targetname = res.tagetdialed[0].targetname;
      } else {
        targetname = "-";
      }
      var targetnumber;
      if (res.tagetdialed[0].targetnumber != null) {
        targetnumber = res.tagetdialed[0].targetnumber;
      } else {
        targetnumber = "-";
      }
      var payout;
      if (res.tagetdialed[0].payout > 0.0) {
        payout = "$" + res.tagetdialed[0].payout;
      } else {
        payout = "-";
      }
      var recording;
      if (res.data[0].recording != null) {
        // recording = "$"+res.tagetdialed[0].recording;
        recording = '<a target="_blank" style="color:white" href="https://d2actkasrcrrs8.cloudfront.net/' + res.data[0].recording + '">https://d2actkasrcrrs8.cloudfront.net/' + res.data[0].recording + '</a>';
      } else {
        recording = "-";
      }
      var hangup_by;
      if (res.data[0].hangup_by == 'User') {
        hangup_by = "Caller";
      } else if (res.data[0].hangup_by == 'System') {
        hangup_by = "System";
      } else {
        hangup_by = "-";
      }
      var plan = '<table class="routingtbl" style="width:100%">' + '<tr style="border:none">' + '<th style="border:none">Priority</th>' + '<th style="border:none">Weight</th>' + '<th style="border:none">Name</th>' + '<th style="border:none">Reason</th>' + '</tr>';
      var result = "";
      var plan1 = "";
      var result1 = "";
      for (let index = 0; index < res.routingplan_inele.length; index++) {
        const data = res.routingplan_inele[index];
        if (data.iseligible == 1) {
          plan1 = '<tr style="border:none">' + '<td style="border:none">' + data.priority + '</td>' + '<td style="border:none">' + data.weight + '</td>' + '<td style="border:none">' + data.name + '</td>' + '<td style="border:none">' + data.reson + '</td>' + '</tr>';
          result1 += result.concat(plan1);
        }
      }
      // console.log(plan); return
      var finalresult = '<span>No Data Available</span>';
      if (res.routingplan_inele.length > 0) {
        finalresult = plan.concat(result1);
        finalresult += result.concat('</table>');
      }
      var plan_ele = '<table class="routingtbl" style="width:100%">' + '<tr style="border:none">' + '<th style="border:none">Priority</th>' + '<th style="border:none">Weight</th>' + '<th style="border:none">Name</th>' + '<th style="border:none">Reason</th>' + '</tr>';
      var result_ele = "";
      var plan1 = "";
      var result2 = "";
      for (let index = 0; index < res.routingplan_ele.length; index++) {
        const data = res.routingplan_ele[index];
        if (data.iseligible == 0) {
          plan1 = '<tr style="border:none">' + '<td style="border:none">' + data.priority + '</td>' + '<td style="border:none">' + data.weight + '</td>' + '<td style="border:none">' + data.name + '</td>' + '<td style="border:none">' + data.reson + '</td>' + '</tr>';
          result2 += result.concat(plan1);
        }
      }
      // console.log(plan); return
      var finalresult_ele = '<span>No Data Available</span>';
      if (res.routingplan_ele.length > 0) {
        finalresult_ele = plan_ele.concat(result2);
        var finalresult = finalresult;
        finalresult += result_ele.concat('</table>');
        finalresult_ele += result_ele.concat('</table>');
      }
      var ivrnode = '';
      var ivrinfo = '';
      var nodeexisttime = "";
      if (res.data[0].ivr_inputs != '' && res.data[0].ivr_inputs != null) {
        if (res.data[0].ivr_details_info != "") {
          let info = res.data[0].ivr_details_info;
          let ivrinforesult = "";
          if (info && info.length > 0) {
            // console.log(info);
            for (let index = 0; index < info.length; index++) {
              const data = info[index];
              // let nodeentertime = moment.utc(data.nodeentertime, "YYYY-MM-DD HH:mm:ss").tz('America/Phoenix').format("YYYY-MM-DD HH:mm:ss")
              // let nodeexisttime = moment.utc(data.nodeexisttime, "YYYY-MM-DD HH:mm:ss").tz('America/Phoenix').format("YYYY-MM-DD HH:mm:ss")
              let nodeentertime = moment__WEBPACK_IMPORTED_MODULE_6__.utc(data.nodeentertime).utcOffset(this.gmttime).format("YYYY-MM-DD HH:mm:ss");
              nodeexisttime = moment__WEBPACK_IMPORTED_MODULE_6__.utc(data.nodeexisttime).utcOffset(this.gmttime).format("YYYY-MM-DD HH:mm:ss");
              var a = moment__WEBPACK_IMPORTED_MODULE_6__(nodeexisttime); //now
              var b = moment__WEBPACK_IMPORTED_MODULE_6__(nodeentertime);
              var hrs = moment__WEBPACK_IMPORTED_MODULE_6__.utc(a.diff(b)).format("HH");
              var min = moment__WEBPACK_IMPORTED_MODULE_6__.utc(a.diff(b)).format("mm");
              var sec = moment__WEBPACK_IMPORTED_MODULE_6__.utc(a.diff(b)).format("ss");
              let nodediffrence = [hrs, min, sec].join(':');
              // let nodediffrence = a.diff(b, 'hours')+':'+a.diff(b, 'hours')+':'+a.diff(b, 'seconds')
              // console.log(a.diff(b, 'minutes')) // 44700
              // console.log(a.diff(b, 'hours')) // 745
              // console.log(a.diff(b, 'seconds')) // 745
              ivrinfo = '<div class="activity mt-2">' + '<div class="activity-icon bg-blue text-white">' + '<i class="fas fa-info"></i>' + '</div>' + '<div class="activity-detail" style="width: 35%!important;">' + '<div class="">' + '<span class="text-job text-primary">IVR Node Enter</span>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Timestamp</div>' + '<div class="col-md-6">' + nodeentertime +
              // '<span class="ml-2" #copyname><i style="font-size: 10px;cursor: pointer;" class="fa fa-copy"></i></span></div>'+
              '</div>' + '</div>' + '<div class="row">' + '<div class="col-md-6">Node Type</div>' + '<div class="col-md-6">MenuNode</div>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Step Name</div>' + '<div class="col-md-6">' + data.ivr + '</div>' + '</div>' + '</div>' + '</div>' + '<div class="activity">' + '<div class="activity-icon bg-blue text-white">' + '<i class="fas fa-info"></i>' + '</div>' + '<div class="activity-detail" style="width: 35%!important;">' + '<div class="">' + '<span class="text-job text-primary">User Input</span>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Timestamp</div>' + '<div class="col-md-6">' + nodeexisttime + '</div>' + '</div>' + '<div class="row">' + '<div class="col-md-6">Digit</div>' + '<div class="col-md-6">' + data.dtmf + '</div>' + '</div>' + '</div>' + '</div>' + '<div class="activity">' + '<div class="activity-icon bg-blue text-white">' + '<i class="fas fa-info"></i>' + '</div>' + '<div class="activity-detail" style="width: 35%!important;">' + '<div class="">' + '<span class="text-job text-primary">IVR Node Exit</span>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Timestamp</div>' + '<div class="col-md-6">' + nodeexisttime + '</div>' + '</div>' + '<div class="row">' + '<div class="col-md-6">Node Type</div>' + '<div class="col-md-6">MenuNode</div>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Step Name</div>' + '<div class="col-md-6">' + data.ivr + '</div>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Node ' + index + 1 + ' Spent Time</div>' + '<div class="col-md-6">' + nodediffrence + '</div>' + '</div>' + '</div>' + '</div>';
              ivrinforesult += ivrinfo;
            }
          }
          ivrnode = ivrinforesult;
        } else {
          ivrnode = '<div class="activity mt-2">' + '<div class="activity-icon bg-blue text-white">' + '<i class="fas fa-info"></i>' + '</div>' + '<div class="activity-detail" style="width: 35%!important;">' + '<span class="text-job text-primary">IVR Node Enter</span>' + '<div class="row" >' + '<div class="col-md-6">Timestamp</div>' + '<div class="col-md-6">' + time + '</div>' + '</div>' + '<div class="row">' + '<div class="col-md-6">Node Type</div>' + '<div class="col-md-6">MenuNode</div>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Step Name</div>' + '<div class="col-md-6">Menu</div>' + '</div>' + '</div>' + '</div>' + '<div class="activity">' + '<div class="activity-icon bg-blue text-white">' + '<i class="fas fa-info"></i>' + '</div>' + '<div class="activity-detail" style="width: 35%!important;">' + '<div class="">' + '<span class="text-job text-primary">User Input</span>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Timestamp</div>' + '<div class="col-md-6">' + time + '</div>' + '</div>' + '<div class="row">' + '<div class="col-md-6">Digit</div>' + '<div class="col-md-6">' + res.data[0].ivr_inputs + '</div>' + '</div>' + '</div>' + '</div>' + '<div class="activity">' + '<div class="activity-icon bg-blue text-white">' + '<i class="fas fa-info"></i>' + '</div>' + '<div class="activity-detail" style="width: 35%!important;">' + '<div class="">' + '<span class="text-job text-primary">IVR Node Exit</span>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Timestamp</div>' + '<div class="col-md-6">' + time + '</div>' + '</div>' + '<div class="row">' + '<div class="col-md-6">Node Type</div>' + '<div class="col-md-6">MenuNode</div>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Step Name</div>' + '<div class="col-md-6">Menu</div>' + '</div>' + '</div>' + '</div>';
        }
      }
      // console.log(ivrnode);
      let routingtime;
      if (nodeexisttime != "") {
        routingtime = nodeexisttime;
      } else {
        routingtime = time;
      }
      if (res.routingplan_inele.length > 0) {
        if (res.routingplan_inele[0]['enter_time'] != '') {
          routingtime = res.routingplan_inele[0]['enter_time'];
          routingtime = moment__WEBPACK_IMPORTED_MODULE_6__.utc(routingtime).utcOffset(this.gmttime).format("YYYY-MM-DD HH:mm:ss");
        }
      }
      // console.log(res.routingplan_inele.length , res.routingplan_ele.length , res.data[0].is_callerid_blocked);
      var routingplan = '';
      if ((res.routingplan_inele.length > 0 || res.routingplan_ele.length > 0) && res.data[0].is_callerid_blocked == 0) {
        let st = "";
        if (res.data[0].is_predictive_routing == "1") {
          st = '<div class="row">' + '<div class="col-md-6">Is Predictive Routing</div>' + '<div class="col-md-6">Yes</div>' + '</div>';
        }
        routingplan = '<div class="activity">' + '<div class="activity-icon bg-blue text-white">' + '<i class="fas fa-info"></i>' + '</div>' + '<div class="activity-detail" style="width: 35%!important;">' + '<div class="">' + '<span class="text-job text-primary">Routing Plan</span>' + '</div>' + '<div class="row">' + '<div class="col-md-6">Timestamp</div>' + '<div class="col-md-6">' + routingtime + '</div>' + '</div>' + st + '<div class="row mt-2" >' + '<div class="col-md-6">Ineligible Targets	</div>' + '</div>' + '<div class="row">' + '<div class="col-md-4">' + finalresult + '</div>' + '</div>' + '<div class="row mt-2" >' + '<div class="col-md-6">Eligible Targets	</div>' + '</div>' + '<div class="row">' + '<div class="col-md-4">' + finalresult_ele + '</div>' + '</div>' + '</div>' + '</div>';
      } else if (res.data[0].is_callerid_blocked == 1) {
        routingplan += '<div class="activity">' + '<div class="activity-icon bg-danger text-white">' + '<i class="fas fa-exclamation"></i>' + '</div>' + '<div class="activity-detail" style="width: 35%!important;">' + '<div class="">' + '<span class="text-job text-primary">Blocked Call</span>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Timestamp</div>' + '<div class="col-md-6">' + time + '</div>' + '</div>' + '<div class="row">' + '<div class="col-md-6">Reason  </div>' + '<div class="col-md-6">Blocked By Account</div>' + '</div>' + '</div>' + '</div>' + '<div class="activity">' + '<div class="activity-icon bg-danger text-white">' + '<i class="fas fa-exclamation"></i>' + '</div>' + '<div class="activity-detail" style="width: 35%!important;">' + '<div class="">' + '<span class="text-job text-primary">NO Target Answered</span>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Timestamp</div>' + '<div class="col-md-6">' + time + '</div>' + '</div>' + '</div>' + '</div>';
      }
      var targetdialed = '';
      var connecteddata = '';
      var completeddata = '';
      var ringtree = '';
      if (res.data[0].target_dial_info != '' && res.data[0].target_dial_info != null) {
        if (res.data[0].target_dial_info != "") {
          let info = res.tagetdialed;
          let targetinforesult = "";
          if (info && info.length > 0) {
            // console.log(info);
            var targetinfo = '';
            for (let index = 0; index < info.length; index++) {
              const data = info[index];
              // console.log(data);
              let dialdate = moment__WEBPACK_IMPORTED_MODULE_6__.utc(data.dialtime).utcOffset(this.gmttime).format("YYYY-MM-DD");
              let dialtime = moment__WEBPACK_IMPORTED_MODULE_6__.utc(data.dialtime).utcOffset(this.gmttime).format("YYYY-MM-DD HH:mm:ss");
              let dialend = moment__WEBPACK_IMPORTED_MODULE_6__.utc(data.dialend).utcOffset(this.gmttime).format("YYYY-MM-DD HH:mm:ss");
              let cond;
              if (dialdate <= '2023-11-18') {
                // console.log('yes');
                cond = res.data[0].ringtree_api_response != "" && res.data[0].ringtree_api_response != null;
              } else {
                // console.log('no');
                cond = res.data[0].is_ringtree == 1;
              }
              // console.log(cond);
              if (cond) {
                // if(res.data[0].ringtree_api_response!="" && res.data[0].ringtree_api_response!=null){
                let ringtree_frwd = res.data[0].ringtree_frwd != "" ? res.data[0].ringtree_frwd : "-";
                let ringtree_api_url = res.data[0].ringtree_api_url != "" ? res.data[0].ringtree_api_url : "-";
                let ringtree_payout = res.data[0].ringtree_payout != "" ? res.data[0].ringtree_payout : "-";
                let zip_code = res.data[0].zip_code != "" ? res.data[0].zip_code : "-";
                let ringtree_billableDuration = res.data[0].ringtree_billableDuration != "" ? res.data[0].ringtree_billableDuration : "-";
                let ringtree_api_response = res.data[0].ringtree_api_response != "" ? res.data[0].ringtree_api_response : "-";
                ringtree = '<div class="activity">' + '<div class="activity-icon bg-success text-white">' + '<i class="fas fa-check"></i>' + '</div>' + '<div class="activity-detail" style="width: 70%!important;">' + '<div class="">' + '<span class="text-job text-white">Ringtree</span>' + '</div>' + '<div class="row" >' + '<div class="col-md-3">Ringtree URL</div>' + '<div class="col-md-3">' + ringtree_api_url + '</div>' + '</div>' + '<div class="row" >' + '<div class="col-md-3">Ringtree Forward</div>' + '<div class="col-md-3">' + ringtree_frwd + '</div>' + '</div>' + '<div class="row">' + '<div class="col-md-3">Ringtree Payout</div>' + '<div class="col-md-3">' + ringtree_payout + '</div>' + '</div>' + '<div class="row" >' + '<div class="col-md-3">ZIP Code</div>' + '<div class="col-md-3">' + zip_code + '</div>' + '</div>' + '<div class="row">' + '<div class="col-md-3">Ringtree Billable Duration</div>' + '<div class="col-md-3">' + ringtree_billableDuration + '</div>' + '</div>' + '<div class="row" >' + '<div class="col-md-3">Ringtree API Response</div>' + '<div class="col-md-9" style="white-space: initial;">' + ringtree_api_response + '</div>' + '</div>' + '</div>' + '</div>';
              }
              var isshowbuyer = "";
              if (this.currentUser.role != 3) {
                isshowbuyer = '<div class="row">' + '<div class="col-md-6">Buyer</div>' + '<div class="col-md-6">' + data.buyer + '</div>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Buyer ID</div>' + '<div class="col-md-6">' + data.buyerid + '</div>' + '</div>';
              }
              targetinfo = '<div class="activity">' + '<div class="activity-icon bg-success text-white">' + '<i class="fas fa-check"></i>' + '</div>' + '<div class="activity-detail" style="width: 35%!important;">' + '<div class="">' + '<span class="text-job text-primary">Target Dialed</span>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Timestamp</div>' + '<div class="col-md-6">' + dialtime + '</div>' + '</div>' + isshowbuyer + '<div class="row">' + '<div class="col-md-6">Target ID</div>' + '<div class="col-md-6">' + data.target_uuid + '</div>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Target Name</div>' + '<div class="col-md-6">' + data.target + '</div>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Routing Number</div>' + '<div class="col-md-6">' + data.dialnumber + '</div>' + '</div>' + '</div>' + '</div>';
              if (data.hangup_cause != 'SUCCESS') {
                targetinfo += '<div class="activity">' + '<div class="activity-icon bg-danger text-white">' + '<i class="fas fa-exclamation"></i>' + '</div>' + '<div class="activity-detail" style="width: 35%!important;">' + '<div class="">' + '<span class="text-job text-primary">Failed Call</span>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Timestamp</div>' + '<div class="col-md-6">' + dialend + '</div>' + '</div>' + isshowbuyer + '<div class="row">' + '<div class="col-md-6">Target ID</div>' + '<div class="col-md-6">' + data.target_uuid + '</div>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Target Name</div>' + '<div class="col-md-6">' + data.target + '</div>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Hangup Cause</div>' + '<div class="col-md-6">' + data.hangup_cause + '</div>' + '</div>' + '</div>' + '</div>';
              } else {
                connecteddata = '<div class="activity">' + '<div class="activity-icon bg-success text-white">' + '<i class="fas fa-check"></i>' + '</div>' + '<div class="activity-detail" style="width: 35%!important;">' + '<div class="">' + '<span class="text-job text-primary">Connected</span>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Timestamp</div>' + '<div class="col-md-6">' + dialtime + '</div>' + '</div>' + isshowbuyer + '<div class="row">' + '<div class="col-md-6">Target ID</div>' + '<div class="col-md-6">' + data.target_uuid + '</div>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Target Name</div>' + '<div class="col-md-6">' + data.target + '</div>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Routing Number</div>' + '<div class="col-md-6">' + data.dialnumber + '</div>' + '</div>' + '</div>' + '</div>';
                completeddata = '<div class="activity">' + '<div class="activity-icon bg-blue text-white">' + '<i class="fas fa-info"></i>' + '</div>' + '<div class="activity-detail" style="width: 35%!important;">' + '<div class="">' + '<span class="text-job text-primary">Completed</span>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Timestamp</div>' + '<div class="col-md-6">' + dialend + '</div>' + '</div>' + isshowbuyer + '<div class="row">' + '<div class="col-md-6">Target ID</div>' + '<div class="col-md-6">' + data.target_uuid + '</div>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Target Name</div>' + '<div class="col-md-6">' + data.target + '</div>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Routing Number</div>' + '<div class="col-md-6">' + data.dialnumber + '</div>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Hangup Cause</div>' + '<div class="col-md-6">' + data.hangup_cause + '</div>' + '</div>' + '</div>' + '</div>';
              }
              targetinforesult += targetinfo;
            }
          }
          targetdialed = targetinforesult;
        }
      } else {
        // console.log(data.ringtree_api_response);
        // console.log(res.data[0].is_ringtree);
        if (res.data[0].is_ringtree == 1) {
          // console.log(data);
          let ringtree_frwd = data.ringtree_frwd != "" ? data.ringtree_frwd : "-";
          let ringtree_api_url = data.ringtree_api_url != "" ? data.ringtree_api_url : "-";
          let ringtree_payout = data.ringtree_payout != "" ? data.ringtree_payout : "-";
          let zip_code = data.zip_code != "" ? data.zip_code : "-";
          let ringtree_billableDuration = data.ringtree_billableDuration != "" ? data.ringtree_billableDuration : "-";
          let ringtree_api_response = data.ringtree_api_response != "" ? data.ringtree_api_response : "-";
          ringtree = '<div class="activity">' + '<div class="activity-icon bg-success text-white">' + '<i class="fas fa-check"></i>' + '</div>' + '<div class="activity-detail" style="width: 70%!important;">' + '<div class="">' + '<span class="text-job text-white">Ringtree</span>' + '</div>' + '<div class="row" >' + '<div class="col-md-3">Ringtree URL</div>' + '<div class="col-md-3">' + ringtree_api_url + '</div>' + '</div>' + '<div class="row" >' + '<div class="col-md-3">Ringtree Forward</div>' + '<div class="col-md-3">' + ringtree_frwd + '</div>' + '</div>' + '<div class="row">' + '<div class="col-md-3">Ringtree Payout</div>' + '<div class="col-md-3">' + ringtree_payout + '</div>' + '</div>' + '<div class="row" >' + '<div class="col-md-3">ZIP Code</div>' + '<div class="col-md-3">' + zip_code + '</div>' + '</div>' + '<div class="row">' + '<div class="col-md-3">Ringtree Billable Duration</div>' + '<div class="col-md-3">' + ringtree_billableDuration + '</div>' + '</div>' + '<div class="row" >' + '<div class="col-md-3">Ringtree API Response</div>' + '<div class="col-md-9" style="white-space: initial;">' + ringtree_api_response + '</div>' + '</div>' + '</div>' + '</div>';
          // console.log(ringtree);
        }
      }
      // console.log(data.ringtree_api_response);
      // console.log(targetdialed);
      // if(res.data[0].billsec>0){
      //   targetdialed='<div class="activity">'+
      //   '<div class="activity-icon bg-success text-white">'+
      //     '<i class="fas fa-check"></i>'+
      //   '</div>'+
      //   '<div class="activity-detail" style="width: 35%!important;">'+
      //     '<div class="">'+
      //       '<span class="text-job text-primary">Target Dialed</span>'+'</div>'+
      //     '<div class="row" >'+
      //       '<div class="col-md-6">Timestamp</div>'+
      //       '<div class="col-md-6">'+time+'</div>'+
      //     '</div>'+
      //     '<div class="row">'+
      //       '<div class="col-md-6">Buyer</div>'+
      //       '<div class="col-md-6">'+res.tagetdialed[0].buyer+'</div>'+
      //     '</div>'+
      //     '<div class="row" >'+
      //       '<div class="col-md-6">Buyer ID</div>'+
      //       '<div class="col-md-6">'+res.tagetdialed[0].buyerid+'</div>'+
      //     '</div>'+
      //     '<div class="row">'+
      //       '<div class="col-md-6">Target ID</div>'+
      //       '<div class="col-md-6">'+targetid+'</div>'+
      //     '</div>'+
      //     '<div class="row" >'+
      //       '<div class="col-md-6">Target Name</div>'+
      //       '<div class="col-md-6">'+targetname+'</div>'+
      //     '</div>'+
      //     '<div class="row">'+
      //       '<div class="col-md-6">Routing Number</div>'+
      //       '<div class="col-md-6">'+res.tagetdialed[0].routedto+'</div>'+
      //     '</div>'+
      //   '</div>'+
      // '</div>';
      // }
      var isshowbuyer1 = "";
      if (this.currentUser.role != 3) {
        isshowbuyer1 = '<div class="row">' + '<div class="col-md-6">Buyer</div>' + '<div class="col-md-6">' + res.tagetdialed[0].buyer + '</div>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Buyer ID</div>' + '<div class="col-md-6">' + res.tagetdialed[0].buyerid + '</div>' + '</div>';
      }
      var converteddata = '';
      if (res.data[0].payout > 0) {
        converteddata = '<div class="activity">' + '<div class="activity-icon bg-success text-white">' + '<i class="fas fa-check"></i>' + '</div>' + '<div class="activity-detail" style="width: 35%!important;">' + '<div class="">' + '<span class="text-job text-primary">Converted</span>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Timestamp</div>' + '<div class="col-md-6">' + time + '</div>' + '</div>' + isshowbuyer1 + '<div class="row">' + '<div class="col-md-6">Payout</div>' + '<div class="col-md-6">' + res.data[0].payout + '</div>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Target ID</div>' + '<div class="col-md-6">' + res.data[0].target_id + '</div>' + '</div>' + '<div class="row">' + '<div class="col-md-6">Target Name</div>' + '<div class="col-md-6">' + res.data[0].target_name + '</div>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Routing Number</div>' + '<div class="col-md-6">' + res.data[0].routed_to + '</div>' + '</div>' + '</div>' + '</div>';
      }
      // var connecteddata ='';
      // if(res.data[0].billsec>0){
      //   connecteddata =  '<div class="activity">'+
      //   '<div class="activity-icon bg-success text-white">'+
      //     '<i class="fas fa-check"></i>'+
      //   '</div>'+
      //   '<div class="activity-detail" style="width: 35%!important;">'+
      //     '<div class="">'+
      //       '<span class="text-job text-primary">Connected</span>'+'</div>'+
      //     '<div class="row" >'+
      //       '<div class="col-md-6">Timestamp</div>'+
      //       '<div class="col-md-6">'+time+'</div>'+
      //     '</div>'+
      //     '<div class="row">'+
      //       '<div class="col-md-6">Buyer</div>'+
      //       '<div class="col-md-6">'+res.tagetdialed[0].buyer+'</div>'+
      //     '</div>'+
      //     '<div class="row" >'+
      //       '<div class="col-md-6">Buyer ID</div>'+
      //       '<div class="col-md-6">'+res.tagetdialed[0].buyerid+'</div>'+
      //     '</div>'+
      //     '<div class="row">'+
      //       '<div class="col-md-6">Connection Time</div>'+
      //       '<div class="col-md-6">'+time+'</div>'+
      //     '</div>'+
      //     '<div class="row" >'+
      //       '<div class="col-md-6">Target ID</div>'+
      //       '<div class="col-md-6">'+targetid+'</div>'+
      //     '</div>'+
      //     '<div class="row">'+
      //       '<div class="col-md-6">Target Name</div>'+
      //       '<div class="col-md-6">'+targetname+'</div>'+
      //     '</div>'+
      //     '<div class="row" >'+
      //     '<div class="col-md-6">Routing Number</div>'+
      //     '<div class="col-md-6">'+res.tagetdialed[0].routedto+'</div>'+
      //     '</div>'+
      //   '</div>'+
      // '</div>';
      // }
      // var enddata;
      // console.log(res.tagetdialed[0].end_target_id);
      // if(res.tagetdialed[0].end_target_id!='-'){
      //   enddata = '<div class="row" >'+
      //   '<div class="col-md-6">End Target ID</div>'+
      //   '<div class="col-md-6">'+res.tagetdialed[0].end_target_id+'</div>'+
      //   '</div>'+
      //   '<div class="row">'+
      //     '<div class="col-md-6">End Target Name</div>'+
      //     '<div class="col-md-6">'+res.tagetdialed[0].endtargetname+'</div>'+
      //   '</div>'+
      //   '<div class="row" >'+
      //     '<div class="col-md-6">End Buyer ID</div>'+
      //     '<div class="col-md-6">'+res.tagetdialed[0].end_buyer_id+'</div>'+
      //   '</div>'+
      //   '<div class="row">'+
      //     '<div class="col-md-6">End Buyer Name</div>'+
      //     '<div class="col-md-6">'+res.tagetdialed[0].end_buyername+'</div>'+
      //   '</div>';
      // }else{
      //   enddata="";
      // }
      // var completeddata =  '<div class="activity">'+
      //     '<div class="activity-icon bg-blue text-white">'+
      //       '<i class="fas fa-info"></i>'+
      //     '</div>'+
      //     '<div class="activity-detail" style="width: 35%!important;">'+
      //       '<div class="">'+
      //         '<span class="text-job text-primary">Completed</span>'+'</div>'+
      //       '<div class="row" >'+
      //         '<div class="col-md-6">Timestamp</div>'+
      //         '<div class="col-md-6">'+time+'</div>'+
      //       '</div>'+
      //       '<div class="row">'+
      //         '<div class="col-md-6">Buyer</div>'+
      //         '<div class="col-md-6">'+res.tagetdialed[0].buyer+'</div>'+
      //       '</div>'+
      //       '<div class="row" >'+
      //         '<div class="col-md-6">Buyer ID</div>'+
      //         '<div class="col-md-6">'+res.tagetdialed[0].buyerid+'</div>'+
      //       '</div>'+
      //       '<div class="row">'+
      //         '<div class="col-md-6">Call Length</div>'+
      //         '<div class="col-md-6">'+res.data[0].duration+'</div>'+
      //       '</div>'+
      //       '<div class="row" >'+
      //         '<div class="col-md-6">Completion Time</div>'+
      //         '<div class="col-md-6">'+endtime+'</div>'+
      //       '</div>'+
      //        enddata+
      //       '<div class="row">'+
      //         '<div class="col-md-6">Customer IP</div>'+
      //         '<div class="col-md-6">'+res.tagetdialed[0].customerip+'</div>'+
      //       '</div>'+
      //     '</div>'+
      //   '</div>';
      var payoutcall = '';
      if (res.data[0].payout > 0) {
        payoutcall = '<div class="activity">' + '<div class="activity-icon bg-success text-white">' + '<i class="fas fa-check"></i>' + '</div>' + '<div class="activity-detail" style="width: 35%!important;">' + '<div class="">' + '<span class="text-job text-white">Payout Call</span>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Timestamp</div>' + '<div class="col-md-6">' + time + '</div>' + '</div>' + '<div class="row">' + '<div class="col-md-6">Payout</div>' + '<div class="col-md-6">' + payout + '</div>' + '</div>' + '</div>' + '</div>';
      }
      var adjust_payout = '';
      let payoutdata = res.data[0].payoutdata;
      var isshowbuyer2 = "";
      if (this.currentUser.role != 3 && payoutdata && payoutdata.buyer) {
        // console.log(payoutdata.buyer);
        isshowbuyer2 = '<div class="row">' + '<div class="col-md-4">Buyer</div>' + '<div class="col-md-3">' + payoutdata.buyer + '</div>' + '</div>';
      }
      if (payoutdata != null) {
        adjust_payout += '<div class="activity">' + '<div class="activity-icon bg-success text-white">' + '<i class="fas fa-check"></i>' + '</div>' + '<div class="activity-detail" style="width: 35%!important;">' + '<div class="">' + '<span class="text-job text-white">Conversation Adjustment Requested</span>' + '</div>' + '<div class="row" >' + '<div class="col-md-4">Timestamp</div>' + '<div class="col-md-3">' + payoutdata.created_at + '</div>' + '</div>' + isshowbuyer2 + '<div class="row" >' + '<div class="col-md-4">Buyer ID</div>' + '<div class="col-md-3">' + payoutdata.user_uuid + '</div>' + '</div>' + '<div class="row">' + '<div class="col-md-4">Reason</div>' + '<div class="col-md-3">' + payoutdata.reason + '</div>' + '</div>' + '<div class="row" >' + '<div class="col-md-4">Request ID</div>' + '<div class="col-md-8" style="white-space: initial;">' + payoutdata.uuid + '</div>' + '</div>' + '<div class="row">' + '<div class="col-md-4">Requested Adjustment Revenue</div>' + '<div class="col-md-8" style="white-space: initial;">' + payoutdata.revenue + '</div>' + '</div>' + '<div class="row">' + '<div class="col-md-4">Requested Adjustment Payout</div>' + '<div class="col-md-8" style="white-space: initial;">' + payoutdata.payout + '</div>' + '</div>' + '</div>' + '</div>';
      }
      var blacklistaliance = '';
      if (res.data[0].is_blacklist_alliance_api == 1) {
        blacklistaliance = '<div class="activity mt-2">' + '<div class="activity-icon bg-blue text-white">' + '<i class="fas fa-info"></i>' + '</div>' + '<div class="activity-detail" style="width: 35%!important;">' + '<div class="">' + '<span class="text-job text-white">Blacklist Alliance API</span>' + '</div>' + '<div class="row" >' + '<div class="col-md-2">Blacklist API URL</div>' + '<div class="col-md-10" style="white-space: initial;">' + res.data[0].blacklist_api_url + '</div>' + '</div>' + '<div class="row">' + '<div class="col-md-2">Blacklist API Response</div>' + '<div class="col-md-10" style="white-space: initial;">' + res.data[0].blacklist_api_response + '</div>' + '</div>' + '<div class="row" >' + '<div class="col-md-2">Blacklist API Blocked</div>' + '<div class="col-md-3">' + res.data[0].is_blacklist_api_blocked + '</div>' + '</div>' + '</div>' + '</div>';
      }
      // console.log(recording);
      var recordingdata = '';
      if (recording != "-" && recording != null) {
        let result = res.tagetdialed.filter(s => s.hangup_cause == "SUCCESS");
        // console.log(result);
        if (result.length == 0) {
          result = res.tagetdialed[res.tagetdialed.length - 1];
        }
        let buyer = result && result.length > 0 ? result[0].buyer : '';
        let buyerid = result && result.length > 0 ? result[0].buyerid : '';
        //  console.log(result);
        var isshowbuyer3 = "";
        if (this.currentUser.role != 3) {
          isshowbuyer3 = '<div class="row">' + '<div class="col-md-2">Buyer</div>' + '<div class="col-md-8 pl-4 ml-2">' + buyer + '</div>' + '</div>' + '<div class="row" >' + '<div class="col-md-2">Buyer ID</div>' + '<div class="col-md-8 pl-4 ml-2">' + buyerid + '</div>' + '</div>';
        }
        recordingdata = '<div class="activity">' + '<div class="activity-icon bg-blue text-white">' + '<i class="fas fa-info"></i>' + '</div>' + '<div class="activity-detail" style="width: 100%!important;">' + '<div class="">' + '<span class="text-job text-primary">Recorded</span>' + '</div>' + '<div class="row" >' + '<div class="col-md-2">Timestamp</div>' + '<div class="col-md-8 pl-4 ml-2">' + routingtime + '</div>' + '</div>' + isshowbuyer3 + '<div class="row">' + '<div class="col-md-2">Recording URL</div>' + '<div class="col-md-8 pl-4 ml-2" style="white-space: initial;">' + recording + '</div>' + '</div>' + '</div>' + '</div>';
      }
      var targetnoansnofound = '';
      if (res.data[0].is_eligible_found == '0' && res.data[0].target_eligible == "" && res.data[0].is_callerid_blocked == 0) {
        targetnoansnofound = '<div class="activity">' + '<div class="activity-icon bg-danger text-white">' + '<i class="fas fa-exclamation"></i>' + '</div>' + '<div class="activity-detail" style="width: 100%!important;">' + '<div class="">' + '<span class="text-job text-primary">No Target Found</span>' + '</div>' + '<div class="row" >' + '<div class="col-md-2">Timestamp</div>' + '<div class="col-md-8 pl-4 ml-2">' + routingtime + '</div>' + '</div>' + '</div>' + '</div>' + '<div class="activity">' + '<div class="activity-icon bg-danger text-white">' + '<i class="fas fa-exclamation"></i>' + '</div>' + '<div class="activity-detail" style="width: 100%!important;">' + '<div class="">' + '<span class="text-job text-primary">No Targets Answered</span>' + '</div>' + '<div class="row" >' + '<div class="col-md-2">Timestamp</div>' + '<div class="col-md-8 pl-4 ml-2">' + routingtime + '</div>' + '</div>' + '</div>' + '</div>';
      }
      // $(".appendrow").append(payoutcall);return
      // appendrow
      // console.log(payoutcall);
      // this.table.rowDetail.toggleExpandRow(payoutcall); return false
      // $(".appendrow"+i).after(
      // console.log(res.data[0]);
      var isshowpublisher = '';
      var isshowpublisherid = '';
      if (this.currentUser.role != 4) {
        isshowpublisher = `
                <tr style="background:#1F263D!important">
                <td>Publisher</td>
                <td>${res.data[0].publisher}</td>
                </tr>`;
        isshowpublisherid = `
                <tr style="background:#1F263D!important">
                <td>Publisher</td>
                <td>${res.data[0].publisher_id}</td>
                </tr>`;
      }
      var isshowbuyer = '';
      var isshowbuyerid = '';
      if (this.currentUser.role != 3) {
        isshowbuyer = `
                <tr style="background:#1F263D!important">
                <td>Buyer</td>
                <td>${res.tagetdialed[0].buyer}</td>
                </tr>`;
        isshowbuyerid = `
                <tr style="background:#1F263D!important">
                <td>Buyer ID</td>
                <td>${res.tagetdialed[0].buyerid}</td>
                </tr>`;
      }
      var isshowpublishertag = '';
      if (this.currentUser.role != 4) {
        isshowpublishertag = '<span class="text-job text-primary">Publisher</span>' + '<table class="table table-striped targetreferencetable"><tbody>' +
        // '<tr style="background: #252d48!important;"><th>Name</th><th>Values</th></tr>'+
        '<tr style="background:#242e4e!important">' + '<td>Name</td>' + ' <td>' + res.data[0].publisher + '</td>' + '</tr>' + '<tr style="background:#1F263D!important">' + '<td>Id</td>' + ' <td>' + res.data[0].publisher_id + '</td>' + '</tr>' + '<tr style="background:#242e4e!important">' + '<td>SubId</td>' + ' <td>' + res.data[0].publisher_subid + '</td>' + '</tr>' + '</tbody></table>';
      }
      let endcallsource = '';
      if (res.data[0].is_callerid_blocked == 0) {
        endcallsource += '<div class="activity">' + '<div class="activity-icon bg-blue text-white">' + '<i class="fas fa-info"></i>' + '</div>' + '<div class="activity-detail" style="width: 35%!important;">' + '<div class="">' + '<span class="text-job text-primary">End Call Source</span>' + '</div>' + '<div class="row" >' + '<div class="col-md-6">Timestamp</div>' + '<div class="col-md-3">' + routingtime + '</div>' + '</div>' + '<div class="row">' + '<div class="col-md-6">Source</div>' + '<div class="col-md-3">' + hangup_by + '</div>' + '</div>' + '</div>' + '</div>';
      }
      var finalresult = '<div class="appendedtbl_' + i + '" style="width: 100%!important;">' + '<ul class="nav nav-tabs expandtabs">' + '<li id="eventtgl" style="" class="active"><a class="active" data-toggle="tab" href="#home_' + i + '">Event</a></li>' + '<li style=""><a  data-toggle="tab" href="#menu_' + i + '">Record</a></li>' + '<li style=""><a data-toggle="tab" href="#tag_' + i + '">Tag</a></li>' + '</ul>' + '<div class="tab-content" style="width: 50%!important;">' + '<div id="home_' + i + '" class="tab-pane fade in active show">' + '<section class="section" style="width: 0px;">' + '<div class="section-body">' + '<div class="row">' + '<div class="col-12">' + '<div class="activities">' + blacklistaliance + ivrnode + routingplan + ringtree + targetnoansnofound + targetdialed + converteddata + connecteddata + completeddata + payoutcall + recordingdata + adjust_payout + endcallsource + '</span>' + '</div>' + '</div>' + '</div>' + '</section> ' + '</div>' + '<div id="menu_' + i + '" class="tab-pane fade recorded ml-0 p-0 pt-2">' + '<table class="table  table-striped targetreferencetable"><tbody>' + '<tr style="background: #252d48!important;"><th>Name</th><th>Values</th></tr>' + '<tr style="background:#1F263D!important">' + '<td>Campaign</td>' + ' <td>' + res.data[0].campaign + '</td>' + '</tr>' + isshowpublisher + '<tr style="background:#1F263D!important">' + '<td>Target</td>' + ' <td>' + res.data[0].target_name + '</td>' + '</tr>' + '<tr style="background:#1F263D!important">' + '<td>Target Number</td>' + ' <td>' + res.data[0].routed_to + '</td>' + '</tr>' + '<tr style="background:#1F263D!important">' + isshowbuyer + '<tr style="background:#1F263D!important">' + '<td>Campaign ID</td>' + ' <td>' + res.data[0].campaign_id + '</td>' + '</tr>' + '<tr style="background:#1F263D!important">' + isshowpublisherid + '<tr style="background:#1F263D!important">' + '<td>Target ID</td>' + ' <td>' + res.data[0].target_id + '</td>' + '</tr>' + '<tr style="background:#1F263D!important">' + isshowbuyerid + '<tr style="background:#1F263D!important">' + '<td>Call Date</td>' + ' <td>' + time + '</td>' + '</tr>' + '<tr style="background:#1F263D!important">' + '<td>Caller ID</td>' + ' <td>' + res.data[0].uuid + '</td>' + '</tr>' + '<tr style="background:#1F263D!important">' + '<td>Dialed #</td>' + ' <td>' + res.data[0].did + '</td>' + '</tr>' + '<tr style="background:#1F263D!important">' + '<td>Time To Call</td>' + ' <td>' + res.data[0].duration + '</td>' + '</tr>' + '<tr style="background:#1F263D!important">' + '<td>Call Complete Timestamp</td>' + ' <td>' + endtime + '</td>' + '</tr>' + '<tr style="background:#1F263D!important">' + '<td>Call Connected Timestamp</td>' + ' <td>' + time + '</td>' + '</tr>' + '<tr style="background:#1F263D!important">' + '<td>Duration</td>' + ' <td>' + res.data[0].duration + '</td>' + '</tr>' + '<tr style="background:#1F263D!important">' + '<td>Connected Call Length</td>' + ' <td>' + res.data[0].billsec + '</td>' + '</tr>' + '<tr style="background:#1F263D!important">' + '<td>Hangup</td>' + ' <td>' + res.data[0].billsec + '</td>' + '</tr>' + '<tr style="background:#1F263D!important">' + '<td>Connected</td>' + ' <td>' + res.data[0].connected + '</td>' + '</tr>' + '<tr style="background:#1F263D!important">' + '<td>Paid Out</td>' + ' <td>' + res.data[0].paidout + '</td>' + '</tr>' + '<tr style="background:#1F263D!important">' + '<td>Revenue</td>' + ' <td>' + res.data[0].revenue + '</td>' + '</tr>' + '<tr style="background:#1F263D!important">' + '<td>Payout</td>' + ' <td>' + res.tagetdialed[0].payout + '</td>' + '</tr>' + '<tr style="background:#1F263D!important">' + '<td>Recording</td>' + ' <td>' + recording + '</td>' + '</tr>' + '</tbody></table>' + '</div>' + '<div id="tag_' + i + '" class="tab-pane fade">' + '<span class="text-job text-primary">Time</span>' + '<table class="table table-striped targetreferencetable"><tbody>' +
      // '<tr style="background: #252d48!important;"><th>Name</th><th>Values</th></tr>'+
      '<tr style="background:#242e4e!important">' + '<td>UTC Hour</td>' + ' <td>' + res.tags[0].UTCHour + '</td>' + '</tr>' + '<tr style="background:#1F263D!important">' + '<td>UTC Minute</td>' + ' <td>' + res.tags[0].UTCMinute + '</td>' + '</tr>' + '<tr style="background:#242e4e!important">' + '<td>UTC Second</td>' + ' <td>' + res.tags[0].UTCSecond + '</td>' + '</tr>' + '<tr style="background:#1F263D!important">' + '<td>UTC Offset</td>' + ' <td>' + res.tags[0].UTCOffset + '</td>' + '</tr>' + '<tr style="background:#242e4e!important">' + '<td>Hour</td>' + ' <td>' + res.tags[0].Hour + '</td>' + '</tr>' + '<tr style="background:#1F263D!important">' + '<td>Minute</td>' + ' <td>' + res.tags[0].Minute + '</td>' + '</tr>' + '<tr style="background:#242e4e!important">' + '<td>Second</td>' + ' <td>' + res.tags[0].Second + '</td>' + '</tr>' + '</tbody></table>' + '<span class="text-job text-primary">Date</span>' + '<table class="table table-striped targetreferencetable"><tbody>' +
      // '<tr style="background: #252d48!important;"><th>Name</th><th>Values</th></tr>'+
      '<tr style="background:#242e4e!important">' + '<td>UTC Hour</td>' + ' <td>' + res.tags[0].UTCWeekDay + '</td>' + '</tr>' + '<tr style="background:#1F263D!important">' + '<td>UTC Day</td>' + ' <td>' + res.tags[0].UTCDay + '</td>' + '</tr>' + '<tr style="background:#242e4e!important">' + '<td>UTC Month</td>' + ' <td>' + res.tags[0].UTCMonth + '</td>' + '</tr>' + '<tr style="background:#1F263D!important">' + '<td>UTC Year</td>' + ' <td>' + res.tags[0].UTCYear + '</td>' + '</tr>' + '<tr style="background:#242e4e!important">' + '<td>Week Day</td>' + ' <td>' + res.tags[0].WeekDay + '</td>' + '</tr>' + '<tr style="background:#1F263D!important">' + '<td>Day</td>' + ' <td>' + res.tags[0].Day + '</td>' + '</tr>' + '<tr style="background:#242e4e!important">' + '<td>Month</td>' + ' <td>' + res.tags[0].Month + '</td>' + '</tr>' + '<tr style="background:#1F263D!important">' + '<td>Year</td>' + ' <td>' + res.tags[0].Year + '</td>' + '</tr>' + '<tr style="background:#242e4e!important">' + '<td>Time Zone</td>' + ' <td>' + res.tags[0].TimeZone + '</td>' + '</tr>' + '</tbody></table>' + '<span class="text-job text-primary">Campaign</span>' + '<table class="table table-striped targetreferencetable"><tbody>' +
      // '<tr style="background: #252d48!important;"><th>Name</th><th>Values</th></tr>'+
      '<tr style="background:#242e4e!important">' + '<td>Name</td>' + ' <td>' + res.data[0].campaign + '</td>' + '</tr>' + '<tr style="background:#1F263D!important">' + '<td>Id</td>' + ' <td>' + res.data[0].campaign_id + '</td>' + '</tr>' + '</tbody></table>' + isshowpublishertag + '<span class="text-job text-primary">Dialed Number</span>' + '<table class="table table-striped targetreferencetable"><tbody>' +
      // '<tr style="background: #252d48!important;"><th>Name</th><th>Values</th></tr>'+
      '<tr style="background:#242e4e!important">' + '<td>Number</td>' + ' <td>' + res.data[0].did + '</td>' + '</tr>' + '</tbody></table>' + '<span class="text-job text-primary">Call Length</span>' + '<table class="table table-striped targetreferencetable"><tbody>' +
      // '<tr style="background: #252d48!important;"><th>Name</th><th>Values</th></tr>'+
      '<tr style="background:#242e4e!important">' + '<td>Total</td>' + ' <td>' + res.data[0].billsec + '</td>' + '</tr>' + '</tbody></table>' + '</div>' + '</div>';
      // );
      $('.appendData').append(finalresult);
      // tr.addClass('shown');
    }, error => this.error = error);
    // }
  }

  exportdata() {
    if (this.currentUser.role == 3) {
      this.exportheader = ["Number Called", "Caller ID", "Campaign", "Call Duration", "Date of Call", "Time of Call", "Payout"];
    } else if (this.currentUser.role == 4) {
      this.exportheader = ["Number Called", "Caller ID", "Target", "Call Duration", "Date of Call", "Time of Call", "Revenue"];
    } else {
      this.exportheader = ["Number Called", "Caller ID", " Publisher", "Target", "Campaign", "Routed To", "Call Duration", "IVR Inputs", "Date of Call", "Time of Call", "Revenue", "Payout", "Recording URL"];
    }
    var that = this;
    var options = {
      fieldSeparator: ',',
      quoteStrings: '"',
      decimalseparator: '.',
      showLabels: true,
      // showTitle: true,
      // title: 'Your title',
      useBom: true,
      // noDownload: true,
      headers: this.exportheader
    };
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    const formData = new FormData();
    formData.append('role', currentUser.role);
    formData.append('user_uuid', currentUser.uuid);
    formData.append('timezone', this.currentUser.timezone);
    formData.append('filterselected', JSON.stringify(this.filterselected));
    formData.append('date', JSON.stringify(this.selecteddate));
    formData.append('totalrecords', '5000');
    // console.log(formData);return;
    this.showLoadingIndicator = true;
    this.moduleservice.getCalldetailsForExport(this.currentCompany.uuid, formData).subscribe(res => {
      let finalarr = [];
      if (this.currentUser.role == 3) {
        let newarr = res.data.map(element => {
          // delete element.campaign;
          // delete element.duplicate;
          delete element.publisher;
          delete element.target;
          delete element.routed_to;
          delete element.ivr_inputs;
          delete element.ivr_duration;
          delete element.revenue;
          delete element.recording;
          delete element.assosciated_labels;
          return element;
        });
        finalarr = newarr;
      } else if (this.currentUser.role == 4) {
        let newarr = res.data.map(element => {
          delete element.campaign;
          delete element.duplicate;
          delete element.publisher;
          delete element.routed_to;
          delete element.ivr_inputs;
          delete element.ivr_duration;
          delete element.payout;
          delete element.recording;
          delete element.assosciated_labels;
          return element;
        });
        finalarr = newarr;
      } else {
        let newarr = res.data.map(element => {
          delete element.assosciated_labels;
          return element;
        });
        finalarr = newarr;
      }
      // console.log(res.data);return;
      new ngx_csv_ngx_csv__WEBPACK_IMPORTED_MODULE_5__.ngxCsv(finalarr, 'All Calls', options);
      this.showLoadingIndicator = false;
    }, error => this.error = error);
  }
  exportcalldata() {
    // let spliced = this.callsdata.splice(1, 1);
    if (this.currentUser.role == 3) {
      let newarr = this.callsdata.map(element => {
        delete element.profit;
        delete element.reachedtobuyer;
        delete element.revenue;
        delete element.ivr_agent;
        delete element.ivr_inputs;
        delete element.hour;
        return element;
      });
      this.callsdata = newarr;
      this.header = ["UUID", "Name(Filter)", "Incoming", "Unique Calls", "Connected", "Qualified", "Converted", "Completed", "No Answer", "No Connect", "Duplicate", "Blocked", "Payout", "CR%", "RPC", "ACL", "TCL"];
    } else if (this.currentUser.role == 4) {
      let newarr = this.callsdata.map(element => {
        delete element.profit;
        delete element.reachedtobuyer;
        delete element.payout;
        delete element.ivr_agent;
        delete element.ivr_inputs;
        delete element.hour;
        return element;
      });
      this.callsdata = newarr;
      this.header = ["UUID", "Name(Filter)", "Incoming", "Unique Calls", "Connected", "Qualified", "Converted", "Completed", "No Answer", "No Connect", "Duplicate", "Blocked", "Revenue", "CR%", "RPC", "ACL", "TCL"];
    } else {
      let newarr = this.callsdata.map(element => {
        delete element.hour;
        return element;
      });
      this.callsdata = newarr;
      this.header = ["UUID", "Name(Filter)", "Incoming", "IVR Inputs", "IVR Agent", "Reached To Buyer", "Unique Calls", "Connected", "Qualified", "Converted", "Completed", "No Answer", "No Connect", "Duplicate", "Blocked", "Payout", "Revenue", "Profit", "CR%", "RPC", "ACL", "TCL"];
    }
    // console.log(this.callsdata);
    // console.log(spliced);
    // return
    var options = {
      fieldSeparator: ',',
      quoteStrings: '"',
      decimalseparator: '.',
      showLabels: true,
      useBom: true,
      headers: this.header
    };
    new ngx_csv_ngx_csv__WEBPACK_IMPORTED_MODULE_5__.ngxCsv(this.callsdata, 'All Calls', options);
  }
  togglepanel() {
    if (this.isclick == 1) {
      this.istougle = 1;
      this.isclick = 0;
    } else {
      this.isclick = 1;
      this.istougle = 0;
    }
  }
  filterdata(type) {
    this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.filter = 0;
    this.isclick = 0;
    this.isselectElement = 0;
    if (type == 1) {
      this.resultdata = [];
      this.nonactiveresultdata = [];
      this.filter = 1;
      this.filtertype = 1;
      this.filtertext = 'Select Campaign';
      this.filterlabel = 'Campaign';
      this.filtervalue = "";
      this.filteradvanced = 0;
      this.ngxLoader.startLoader('loader-04');
      this.moduleservice.getallcampain(this.currentCompany.uuid).subscribe(res => {
        this.resultdata = res.active;
        this.dropdownbkp = res.active;
        this.nonactiveresultdata = res.non_active;
        this.ngxLoader.stopLoader('loader-04');
      });
    }
    if (type == 2) {
      this.resultdata = [];
      this.filtertype = 2;
      this.filter = 1;
      this.filtertext = 'Select Target';
      this.filterlabel = 'Target';
      this.filtervalue = "";
      this.filteradvanced = 0;
      this.ngxLoader.startLoader('loader-04');
      let buyer_uuids = [];
      if (this.currentUser.role == 4) {
        buyer_uuids = this.currentUser?.companydetails.map(item => item.user_uuid);
      }
      this.moduleservice.getAlltargetbybuyer(this.currentCompany.uuid, this.currentUser.role, this.currentUser.uuid, buyer_uuids).subscribe(res => {
        this.resultdata = res;
        this.dropdownbkp = res;
        this.ngxLoader.stopLoader('loader-04');
      });
    }
    if (type == 3) {
      this.resultdata = [];
      this.filter = 1;
      this.filtertype = 3;
      this.filtertext = 'Select Buyer';
      this.filterlabel = 'Buyer';
      this.filtervalue = "";
      this.ngxLoader.startLoader('loader-04');
      this.moduleservice.getallbuyers(this.currentCompany.uuid).subscribe(res => {
        this.resultdata = res;
        this.dropdownbkp = res;
        this.ngxLoader.stopLoader('loader-04');
      });
    }
    if (type == 4) {
      this.resultdata = [];
      this.filter = 1;
      this.filtertype = 4;
      this.filtertext = 'Select Publisher';
      this.filterlabel = 'Publisher';
      this.filtervalue = "";
      this.ngxLoader.startLoader('loader-04');
      this.moduleservice.getAllpublishers(this.currentCompany.uuid).subscribe(res => {
        this.resultdata = res;
        this.dropdownbkp = res;
        this.ngxLoader.stopLoader('loader-04');
      });
    }
    if (type == 5) {
      this.resultdata = [];
      this.dropdownbkp = [];
      this.filter = 1;
      this.filtertype = 5;
      this.filtertext = 'Enter Caller ID';
      this.filterlabel = 'Caller ID';
      this.filtervalue = "";
    }
    if (type == 6) {
      this.resultdata = [];
      this.dropdownbkp = [];
      this.filter = 1;
      this.filtertype = 6;
      this.filtertext = 'Enter Number Called';
      this.filterlabel = 'Number Called';
      this.filtervalue = "";
    }
    if (type == 8) {
      this.resultdata = [];
      this.filter = 1;
      this.filtertype = 8;
      this.filtertext = 'Select IVR Inputs';
      this.filterlabel = 'IVR Inputs';
      this.filtervalue = "";
      this.resultdata = [{
        'id': 0,
        'text': 'No',
        'itemName': 'No'
      }, {
        'id': 1,
        'text': 'Yes',
        'itemName': 'Yes'
      }];
    }
    this.dropdownbkp = this.resultdata;
    if (type == 9) {
      this.resultdata = [];
      this.filter = 1;
      this.filtertype = 9;
      this.filtertext = 'Select Ringtree';
      this.filterlabel = 'Ringtree';
      this.filtervalue = "";
      this.resultdata = [{
        'id': 0,
        'text': 'No',
        'itemName': 'No'
      }, {
        'id': 1,
        'text': 'Yes',
        'itemName': 'Yes'
      }];
    }
    if (type == 10) {
      this.filteradvanced = 6;
      this.resultdata = [];
      this.filter = 1;
      this.filtertype = 10;
      this.filtertext = 'Select Duration';
      this.containtext = 'Greater Than';
      this.filterlabel = 'Duration';
      this.filtervalue = "";
    }
    this.dropdownbkp = this.resultdata;
  }
  clearfilter(index) {
    // this.isselectElement = 0;
    this.filterselected.splice(index, 1);
    if (this.filterselected.length === 0) {
      this.isclick = 1;
    }
    this.loadcalls(this.filterselected, this.selecteddate);
    this.loadcallsdata(this.filterselected, this.selecteddate, 1);
    this.getChartNumberOfCalls(this.filterselected, this.selecteddate, this.daytypeval);
  }
  getadvancedfilter(e, type) {
    // console.log(e.target.options[e.target.selectedIndex].text);
    this.containtext = e.target.options[e.target.selectedIndex].text;
    // this.filteradvanced = e.target.value;
  }

  getcontainfilter(e, type) {
    let filterdata = [];
    if (e.target.value == 1) {
      this.dropdownbkp.forEach(element => {
        let obj = {
          'id': element.id,
          'itemName': element.id,
          'text': element.id
        };
        filterdata.push(obj);
      });
    } else {
      this.dropdownbkp.forEach(element => {
        let obj = {
          'id': element.id,
          'itemName': element.itemName,
          'text': element.text
        };
        filterdata.push(obj);
      });
    }
    // if(this.filtertype==1){
    //   this.activeresultdata = filterdata;
    // }else{
    this.resultdata = filterdata;
    // }
    // this.filteradvanced = e.target.value;
  }

  filterval(event, group_by) {
    // console.log(this.filtervalue[0]['itemName']); return false;
    // console.log(this.filteradvanced); return
    this.refresh_date = new Date();
    let itemuuid;
    let itemname;
    if ((this.filteradvanced == 0 || this.filteradvanced == 1) && this.filtertype != 5 && this.filtertype != 6) {
      if (this.filtervalue != undefined && this.filtervalue != '') {
        itemuuid = this.filtervalue[0]['id'];
        itemname = this.filtervalue[0]['itemName'];
      } else {
        itemuuid = "";
        itemname = "";
      }
    } else {
      itemname = this.filtervalue;
      itemuuid = "";
    }
    // Invalid filter LESS_THAN for column isDuplicate
    // if(this.filteradvanced==6 || this.filteradvanced==7){
    //   Swal.fire(
    //     'Error!',
    //     'Invalid filter Command.',
    //   );
    //   return
    // }
    if (itemname != undefined && itemname != '') {
      let customObj = new filterarr();
      customObj.filteradvanced = this.filteradvanced;
      customObj.filtertype = this.filtertype;
      customObj.filterlabel = this.filterlabel;
      customObj.containfiltertype = this.containfiltertype;
      customObj.containfiltertext = this.containtext;
      customObj.uuid = itemuuid;
      customObj.name = itemname;
      // customObj.name = [0]['itemName']this.selectElementText;
      customObj.isorand = 0;
      // console.log(customObj); return
      if (itemname != undefined && this.filterselected?.length == 0 && !event) {
        this.filterselected.push(customObj);
      }
      if (itemname != undefined && this.filterselected?.length == 1 && !event) {
        this.filterselected = [];
        this.filterselected.push(customObj);
      }
    }
    // console.log(this.filterselected);
    if (event && event.startDate == null && event.endDate == null) return false;
    if (event) {
      var start = moment__WEBPACK_IMPORTED_MODULE_6__(event.startDate._d).format('MM/DD/YYYY HH:mm:ss');
      var end = moment__WEBPACK_IMPORTED_MODULE_6__(event.endDate._d).format('MM/DD/YYYY HH:mm:ss');
      // console.log(this.startdate);
      // console.log(this.enddate);return false;
      this.startdate = moment__WEBPACK_IMPORTED_MODULE_6__.tz(start, 'utc').format("YYYY-MM-DD HH:mm:ss");
      this.enddate = moment__WEBPACK_IMPORTED_MODULE_6__.tz(end, 'utc').format("YYYY-MM-DD HH:mm:ss");
      // this.diff = this.enddate.diff(this.startdate, 'days');
      // console.log(this.startdate);
      this.selected1 = {
        startDate: this.startdate,
        endDate: this.enddate
      };
      this.selecteddate = this.selected1;
      var a = moment__WEBPACK_IMPORTED_MODULE_6__(start);
      var b = moment__WEBPACK_IMPORTED_MODULE_6__(end);
      if (b.diff(a, 'days') > 0) {
        this.daytypeval = 2;
        this.isshowbyhrs = 0;
      } else {
        this.daytypeval = 1;
        this.isshowbyhrs = 1;
      }
      this.isfiltered = 1;
    } else {
      this.isselectElement = 1;
      this.isadded = 0;
      const uuid = this.route.snapshot.paramMap.get('id');
      if (uuid != null) {
        var start = moment__WEBPACK_IMPORTED_MODULE_6__(this.selected.startDate).format('MM/DD/YYYY HH:mm:ss');
        var end = moment__WEBPACK_IMPORTED_MODULE_6__(this.selected.endDate).format('MM/DD/YYYY HH:mm:ss');
      } else {
        // console.log(this.selected1.startDate._d);
        if (this.selected1.startDate._d != undefined) {
          var start = moment__WEBPACK_IMPORTED_MODULE_6__(this.selected1.startDate._d).format('MM/DD/YYYY HH:mm:ss');
          var end = moment__WEBPACK_IMPORTED_MODULE_6__(this.selected1.endDate._d).format('MM/DD/YYYY HH:mm:ss');
        } else {
          // console.log(this.selected2);
          var start = moment__WEBPACK_IMPORTED_MODULE_6__(this.selected2.startDate).format('MM/DD/YYYY HH:mm:ss');
          var end = moment__WEBPACK_IMPORTED_MODULE_6__(this.selected2.endDate).format('MM/DD/YYYY HH:mm:ss');
        }
      }
      // console.log(this.selected1);return
      // console.log(this.startdate);return false;
      this.startdate = moment__WEBPACK_IMPORTED_MODULE_6__.tz(start, 'utc').format("YYYY-MM-DD HH:mm:ss");
      this.enddate = moment__WEBPACK_IMPORTED_MODULE_6__.tz(end, 'utc').format("YYYY-MM-DD HH:mm:ss");
      if (this.isfiltered == 0) {
        this.selected1 = {
          startDate: this.startdate,
          endDate: this.enddate
        };
        this.selecteddate = "";
      } else {
        this.selecteddate = this.selected1;
      }
      // console.log(this.selecteddate);
      this.daytypeval = 2;
    }
    // console.log(this.selecteddate);
    // return false
    // this.diff = this.startdate.getTime() - this.enddate.getTime();
    //getTime() function used to convert a date into milliseconds. This is needed in order to perform calculations.
    //  this.days = Math.round(Math.abs(this.diff/(1000*60*60*24)))
    // console.log('ok');
    // console.log(this.filterselected);
    // console.log(this.selecteddate);
    // console.log(this.daytypeval);
    // return;
    // console.log(group_by);
    // console.log(group_by);      
    if (group_by == undefined) {
      group_by = this.filtertype;
      // console.log(this.filtertype);      
    }
    // this.filtertype = 1;
    // $(".tabsbtn").removeClass("btn btn-primary btn-sm activetab");
    // $("#tabs1").addClass("activetab");
    let role = this.currentUser.role;
    if (this.userselectedvalue && this.userselectedvalue[0].role) {
      role = this.userselectedvalue[0].role;
    }
    this.loadcalls(this.filterselected, this.selecteddate, role);
    this.loadcallsdata(this.filterselected, this.selecteddate, group_by, role);
    this.getChartNumberOfCalls(this.filterselected, this.selecteddate, this.daytypeval, role);
  }
  reload() {
    this.refresh_date = new Date();
    this.loadcalls(this.filterselected, this.selecteddate);
    this.loadcallsdata(this.filterselected, this.selecteddate, 1);
    this.getChartNumberOfCalls(this.filterselected, this.selecteddate, this.daytypeval);
  }
  calcelfilter() {
    // this.filtertype = 0;
    this.isselectElement = 0;
    this.filtertype = 1;
    this.filterdata(1);
    this.filtervalue = '';
    this.filteradvanced = 0;
    this.filterselected = [];
    this.containtext = "Equals Single Value";
    // this.loadcalls("","");
    // this.loadcallsdata("","",1);
    // this.getChartNumberOfCalls(0,0,1);
    // if(this.isadded==0){
    this.loadcalls("", this.selecteddate);
    this.loadcallsdata("", this.selecteddate, 1);
    this.getChartNumberOfCalls("", this.selecteddate, this.daytypeval);
    // }
    this.isadded = 1;
    this.isclick = 1;
    this.filter = 0;
  }
  gettext(event, type) {
    let text;
    // if(this.filtertype==1){
    //   text =  this.activeresultdata.filter(x => x.id == event)[0];
    // }else{
    text = this.resultdata.filter(x => x.id == event)[0];
    // }
    if (type == 1) {
      //  this.selectElementText = event.target['options'][event.target['options'].selectedIndex].text;
      this.selectElementText = text.text;
    } else {
      this.selectElementText = event.target.value;
    }
    //  this.selectElementText = event.target.value
    // console.log(event);
  }

  addorrule() {
    // if(this.filteradvanced==6 || this.filteradvanced==7){
    //   Swal.fire(
    //     'Error!',
    //     'Invalid filter Command.',
    //   );
    //   return
    // }
    let customObj = new filterarr();
    customObj.filteradvanced = this.filteradvanced;
    customObj.filterlabel = this.filterlabel;
    customObj.filtertype = this.filtertype;
    customObj.containfiltertext = this.containtext;
    customObj.containfiltertype = this.containfiltertype;
    // customObj.uuid = this.filtervalue;
    // customObj.name = this.selectElementText;
    let itemname;
    let itemuuid;
    if ((this.filteradvanced == 0 || this.filteradvanced == 1) && this.filtertype != 5 && this.filtertype != 6) {
      if (this.filtervalue != undefined && this.filtervalue != '') {
        itemuuid = this.filtervalue[0]['id'];
        itemname = this.filtervalue[0]['itemName'];
      } else {
        itemname = "";
        itemuuid = "";
      }
    } else {
      itemname = this.filtervalue;
      itemuuid = "";
    }
    // console.log(itemname);
    customObj.uuid = itemuuid;
    customObj.name = itemname;
    customObj.isorand = 0;
    if (itemname != undefined) {
      this.filterselected.push(customObj);
    }
    // console.log(this.filterselected);
  }

  addandrule() {
    // if(this.filteradvanced==6 || this.filteradvanced==7){
    //   Swal.fire(
    //     'Error!',
    //     'Invalid filter Command.',
    //   );
    //   return
    // }
    let itemname;
    let itemuuid;
    if ((this.filteradvanced == 0 || this.filteradvanced == 1) && this.filtertype != 5 && this.filtertype != 6) {
      if (this.filtervalue != undefined && this.filtervalue != '') {
        itemname = this.filtervalue[0]['itemName'];
        itemuuid = this.filtervalue[0]['id'];
      } else {
        itemname = "";
        itemuuid = "";
      }
    } else {
      itemname = this.filtervalue;
      itemuuid = "";
    }
    let customObj = new filterarr();
    customObj.filtertype = this.filtertype;
    customObj.filterlabel = this.filterlabel;
    customObj.filteradvanced = this.filteradvanced;
    customObj.containfiltertext = this.containtext;
    customObj.containfiltertype = this.containfiltertype;
    // customObj.uuid = this.filtervalue;
    // customObj.name = this.selectElementText;
    customObj.uuid = itemuuid;
    customObj.name = itemname;
    customObj.isorand = 1;
    // console.log(this.selectElementText);
    if (itemname != undefined) {
      this.filterselected.push(customObj);
    }
  }
  editfilter() {
    this.isadded = 1;
    this.isselectElement = 0;
    if (this.filtertype == 10) {
      this.containtext = 'Greater Than';
      this.filteradvanced = 6;
      this.filterlabel = 'Duration';
    } else {
      this.containtext = 'Equals Single Value';
      this.filteradvanced = 0;
      this.filterlabel = 'Campaign';
    }
  }
  chartby(type) {
    this.filterdate = "";
    if (type == 1) {
      this.daytypeval = 1;
      this.charttype = "";
      this.getChartNumberOfCalls(this.filterselected, this.selecteddate, this.daytypeval);
    }
    if (type == 2) {
      this.daytypeval = 2;
      this.charttype = "";
      this.getChartNumberOfCalls(this.filterselected, this.selecteddate, this.daytypeval);
    }
    if (type == 3) {
      this.daytypeval = 3;
      this.charttype = "";
      this.getChartNumberOfCalls(this.filterselected, this.selecteddate, this.daytypeval);
    }
  }
  getsavedreports(uuid) {
    this.moduleservice.getsavedreportsbyuuid(uuid).subscribe(res => {
      console.log(res);
      this.labelval = res.reportlabelname;
      this.setTitle(this.labelval + ' | Report');
      this.daytypeval = 2;
      if (res.filtertype != '') {
        this.isreport = 1;
        if (res.filtertype != 0) {
          this.isclick = 1;
        }
        this.filter = res.filtertype;
        let startday = res.start_date;
        let endday = res.end_date;
        const d = new Date(startday);
        const d1 = new Date(endday);
        moment__WEBPACK_IMPORTED_MODULE_6__(d).format('MMMM d, YYYY');
        moment__WEBPACK_IMPORTED_MODULE_6__(d1).format('MMMM d, YYYY');
        var start = moment__WEBPACK_IMPORTED_MODULE_6__(d).format('MM/DD/YYYY HH:mm:ss');
        var end = moment__WEBPACK_IMPORTED_MODULE_6__(d1).format('MM/DD/YYYY HH:mm:ss');
        this.startdate = moment__WEBPACK_IMPORTED_MODULE_6__.tz(start, 'utc').format("YYYY-MM-DD 00:00:00");
        this.enddate = moment__WEBPACK_IMPORTED_MODULE_6__.tz(end, 'utc').format("YYYY-MM-DD 23:59:59");
        // console.log(this.filter);
        // console.log(this.filtervalue);
        // console.log(this.selected);
        this.selected = {
          startDate: d,
          endDate: d1
        };
        this.selecteddates = {
          startDate: this.startdate,
          endDate: this.enddate
        };
        this.filterselected = JSON.parse(res.filterarr);
        var a = moment__WEBPACK_IMPORTED_MODULE_6__(d);
        var b = moment__WEBPACK_IMPORTED_MODULE_6__(d1);
        if (b.diff(a, 'days') > 0) {
          this.daytypeval = 2;
          this.charttype = "Calls Per Day";
        } else {
          this.daytypeval = 1;
          this.charttype = "Calls Per Hour";
        }
      }
      if (res.filterarr == "") {
        this.filterdata(this.filter);
      }
      if (res.filtervalue != '') {
        this.isclick = 1;
        this.filtervalue = res.filtervalue;
      }
      if (res.filteradvanced != '') {
        this.isclick = 1;
        this.filteradvanced = res.filteradvanced;
      }
      this.selectednewdates = this.selecteddates;
      if (res.filterarr != "") {
        this.isclick = 0;
        this.filter = 1;
        this.filterselected = JSON.parse(res.filterarr);
        if (this.filterselected.length > 0 && this.filterselected.length == 1) {
          this.filterdata(this.filterselected[0].filtertype);
          // this.filteradvanced = this.filterselected[0].filteradvanced;
          // this.filtervalue = this.filterselected[0].uuid;
        } else if (this.filterselected.length > 0) {
          // this.filterdata(this.filter);
          this.filterdata(this.filterselected[this.filterselected.length - 1].filtertype);
        }
        // this.filtertype= 1;
        console.log(this.filterselected);
      }
      // localStorage.setItem('selectedDates',JSON.stringify(this.selecteddates));
      // console.log(localStorage.getItem('selectedDates'));return
      // console.log(this.selectednewdates);
      this.loadcalls(this.filterselected, this.selecteddates);
      this.loadcallsdata(this.filterselected, this.selecteddates, 1);
      this.getChartNumberOfCalls(this.filterselected, this.selecteddates, this.daytypeval);
    });
  }
  savelabel() {
    // console.log(this.labelval);
    // console.log(this.selected.startDate._d);
    // console.log(this.filtertype);
    // console.log(this.filtervalue);
    const uuid = this.route.snapshot.paramMap.get('id');
    // console.log(this.selected1);
    // return false;
    if (this.labelval == undefined) {
      this.islabelvaltext = 'yes';
      sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Error!', 'Please enter report name', 'error');
      return;
    }
    this.islabelvaltext = '';
    const formData = new FormData();
    if (uuid != null) {
      formData.append('uuid', uuid);
    }
    if (!this.selecteddate) {
      this.selecteddate = this.selected1;
    }
    var start = moment__WEBPACK_IMPORTED_MODULE_6__(this.selecteddate.startDate).format('MM/DD/YYYY HH:mm:ss');
    var end = moment__WEBPACK_IMPORTED_MODULE_6__(this.selecteddate.endDate).format('MM/DD/YYYY HH:mm:ss');
    this.startdate = moment__WEBPACK_IMPORTED_MODULE_6__.tz(start, 'utc').format("YYYY-MM-DD 00:00:00");
    this.enddate = moment__WEBPACK_IMPORTED_MODULE_6__.tz(end, 'utc').format("YYYY-MM-DD 23:59:59");
    // console.log(this.filtertype);
    // console.log(this.startdate);
    // console.log(this.enddate);
    // return false;
    if (this.filtervalue == "") {
      this.filtertype = 0;
    }
    if (this.filteradvanced == "") {
      this.filteradvanced = 0;
    }
    // console.log(this.filterselected);return false;
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('reportlabelname', this.labelval);
    formData.append('start_date', this.startdate);
    formData.append('end_date', this.enddate);
    formData.append('filtertype', this.filtertype);
    formData.append('filtervalue', this.filtervalue);
    formData.append('filteradvanced', this.filteradvanced);
    formData.append('filterarr', JSON.stringify(this.filterselected));
    this.moduleservice.savereport(formData).subscribe(res => {
      if (res.status !== 'error') {
        if (res.isavail != 1) {
          this.labelval = "";
        }
        this.sendMenuUpdateMessage();
        this.toastrService.success('Report Saved Successfully');
      } else {
        this.toastrService.error('Failed To Add Label');
      }
    });
  }
  deletelabel() {
    sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
      title: 'Are you sure?',
      text: 'You want to Delete Selected Report Name!',
      showCancelButton: true,
      confirmButtonText: 'Yes, delete it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        const uuid = this.route.snapshot.paramMap.get('id');
        this.moduleservice.deleteSelectedSavedReport(uuid).subscribe(res => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Records Deleted Successfully.');
          this.sendMenuUpdateMessage();
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
            this.router.navigate(['/reports']);
          }, 2000);
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
        }, 2000);
      }
    });
  }
  // groupby:any=1;
  getSummary(type) {
    // console.log(type);
    // this.filterselected=[];
    // console.log(this.selecteddate); return
    this.tagselectedvalue = "";
    if (this.selecteddate == undefined) {
      this.selecteddate = this.selected1;
    }
    // this.selecteddate = this.selected1;
    $(".tabsbtn").removeClass("btn btn-primary btn-sm activetab");
    if (type == 1) {
      $("#tabs1").addClass("activetab");
      this.filtertype = 1;
      this.loadcallsdata(this.filterselected, this.selecteddate, 1);
    }
    if (type == 2) {
      $("#tabs2").addClass("activetab");
      this.filtertype = 4;
      this.loadcallsdata(this.filterselected, this.selecteddate, 4);
    }
    if (type == 3) {
      $("#tabs3").addClass("activetab");
      this.filtertype = 2;
      this.loadcallsdata(this.filterselected, this.selecteddate, 2);
    }
    if (type == 4) {
      $("#tabs4").addClass("activetab");
      this.filtertype = 3;
      this.loadcallsdata(this.filterselected, this.selecteddate, 3);
    }
    if (type == 5) {
      $("#tabs5").addClass("activetab");
      this.filtertype = 5;
      this.loadcallsdata(this.filterselected, this.selecteddate, 5);
    }
    if (type == 7) {
      $("#tabs7").addClass("activetab");
      this.filtertype = 7;
      this.loadcallsdata(this.filterselected, this.selecteddate, 7);
    }
    if (type == 8) {
      $("#tabs8").addClass("activetab");
      this.filtertype = 8;
      this.loadcallsdata(this.filterselected, this.selecteddate, 8);
    }
    // if(type==5){ $("#tabs5").addClass("activetab");this.filtertype=5;}
    // if(type==6){ $("#tabs6").addClass("activetab");this.filtertype=6;}
    // if(type==7){ $("#tabs7").addClass("activetab");this.filtertype=7;}
    // if(type==8){ $("#tabs8").addClass("activetab");this.filtertype=8;}
    // if(type==8){ $("#tabs8").addClass("activetab");this.filtertype=8;}
  }

  getcallDetails(type) {
    // alert(type);
    this.filterselected = [];
    $(".tabsbtn").removeClass("btn btn-primary btn-sm activetab");
    if (type == 1) {
      this.islive = false;
      $("#calltabs1").addClass("activetab");
      this.filtertype = 1;
      this.loadcalls(this.filterselected, this.selecteddate);
    }
    if (type == 2) {
      this.islive = true;
      $("#calltabs2").addClass("activetab");
      this.filtertype = 4;
      //  this.loadlivecalls();
    }
  }

  scrolltoy() {
    $('datatable-body').scrollLeft(1000);
    // $('datatable-body').scrollLeft += 800;
    // this.bodyComponent.updateOffsetY(50);
    // document.getElementByClass('datatable-body').scrollLeft += 800;
  }

  scrolltox() {
    $('datatable-body').scrollLeft(0);
    // document.getElementById('datatable-body.datatable-body').scrollLeft -= 800;
  }

  filterbyvalue(uuid, value, type = 0) {
    // console.log(this.filtertype);
    // console.log(value); return false;
    // this.togglepanel();
    this.istougle = 1;
    this.isclick = 1;
    // if(type == 0 || type == 1){
    this.filterdata(this.filtertype);
    let customObj = new filterarr();
    customObj.filtertype = this.filtertype;
    customObj.filterlabel = this.filterlabel;
    customObj.containfiltertext = this.containtext;
    customObj.containfiltertype = this.containfiltertype;
    customObj.uuid = uuid;
    customObj.name = value;
    customObj.isorand = 1;
    customObj.isdup = type;
    // console.log(this.selectElementText);
    if (value != "") {
      this.filterselected.push(customObj);
    }
    // }
    // console.log(this.filterselected);
    this.filterval('', this.filtertype);
  }
  ngOnDestroy() {
    this.dtTrigger.unsubscribe();
    // this.subscription.unsubscribe();
    console.log('Report method destroyed');
  }
  copyName(val) {
    console.log(val);
    const selBox = document.createElement('textarea');
    selBox.style.position = 'fixed';
    selBox.style.left = '0';
    selBox.style.top = '0';
    selBox.style.opacity = '0';
    selBox.value = val;
    document.body.appendChild(selBox);
    selBox.focus();
    selBox.select();
    document.execCommand('copy');
    document.body.removeChild(selBox);
  }
  filtercalldata(filtertype, uuid, no) {
    this.istougle = 1;
    this.isclick = 1;
    this.isadded = 0;
    this.filterdata(filtertype);
    let customObj = new filterarr();
    customObj.filtertype = filtertype;
    customObj.filterlabel = this.filterlabel;
    customObj.filteradvanced = this.filteradvanced;
    customObj.containfiltertext = this.containtext;
    customObj.containfiltertype = this.containfiltertype;
    customObj.uuid = uuid;
    customObj.name = no;
    customObj.isorand = 1;
    // console.log(this.selectElementText);
    if (no != "") {
      this.filterselected.push(customObj);
    }
    // this.filter = 1;
    this.isselectElement = 1;
    // this.daytypeval=2;
    // console.log(this.filterselected);
    // console.log(this.selecteddate);
    this.loadcalls(this.filterselected, this.selecteddate);
    this.loadcallsdata(this.filterselected, this.selecteddate, 1);
    this.getChartNumberOfCalls(this.filterselected, this.selecteddate, this.daytypeval);
  }
  blockno(campaign, campaign_uuid, blocked_number) {
    this.selectedcampaign = campaign;
    this.selectedcampaign_uuid = campaign_uuid;
    this.blocked_number = blocked_number;
  }
  blockselectedno() {
    if (this.selectedrow.length == 0) {
      sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Error!', 'Please select number', 'error');
      return;
    } else {
      $('#blockselectedno').modal('show');
    }
  }
  submitblockno(type) {
    if (this.blockdurationval == "" && type == 0 || this.blockdurationvalselected == "" && type == 1) {
      sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Error!', 'Please enter required value', 'error');
      return;
    }
    const formData = new FormData();
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('type', type);
    formData.append('block_type', "0");
    if (type == 0) {
      formData.append('blocked_number', this.blocked_number);
      formData.append('duration', this.blockdurationval);
    } else {
      formData.append('selectedrow', JSON.stringify(this.selectedrow));
      formData.append('duration', this.blockdurationvalselected);
    }
    formData.append('blocked_prefix', "");
    formData.append('scope', '1');
    formData.append('campaign_uuid', this.selectedcampaign_uuid);
    formData.append('is_duration', '1');
    this.ngxLoader.startLoader('loader-04');
    this.moduleservice.addblockedcalls(formData, this.currentCompany.uuid).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        // this.toastrService.w('Number Blocked Successfully');
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Success!', 'Number Blocked Successfully');
      } else {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Error!', 'Error occured please try again');
      }
      this.ngxLoader.stopLoader('loader-04');
    }, error => this.error = error);
  }
  adjustcall(uuid, freeswitch_call_uuid, payoutdata) {
    if (payoutdata != null) {
      this.calleruuid = payoutdata.call_uuid;
      this.freeswitch_call_uuid = payoutdata.freeswitch_call_uuid;
      if (payoutdata.revenue != 0) {
        this.adjust_revenue = payoutdata.revenue;
      } else {
        this.adjust_revenue = "";
      }
      if (payoutdata.payout != 0) {
        this.adjust_payout = payoutdata.payout;
      } else {
        this.adjust_payout = "";
      }
      if (payoutdata.reason != "") {
        this.adjust_reason = payoutdata.reason;
      } else {
        this.adjust_reason = "";
      }
    } else {
      this.calleruuid = uuid;
      this.freeswitch_call_uuid = freeswitch_call_uuid;
      this.adjust_reason = "";
    }
  }
  adjustcallselectedno() {
    if (this.selectedrow.length == 0) {
      sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Error!', 'Please select number', 'error');
      return;
    } else {
      $('#adjustcallselected').modal('show');
    }
  }
  gettags() {
    $(".tabsbtn").removeClass("btn btn-primary btn-sm activetab");
    if (this.tagselectedvalue.length > 0) {
      // console.log(this.tagselectedvalue[0].name);
      this.tagselectedvalue[0].itemName = 'Tag: ' + this.tagselectedvalue[0].name;
      // console.log(this.tagselectedvalue);
      $("#tabs9").addClass("activetab");
      this.filtertype = 9;
      this.loadcallsdata(this.filterselected, this.selecteddate, 9);
    }
    // else{
    //   $("#tabs1").addClass("activetab");this.filtertype=1;
    //   this.loadcallsdata(this.filterselected,this.selecteddate,1);
    // }
  }

  adjustcallsubmit(type) {
    if (this.currentUser.role == 4) {
      if (this.adjust_payout == "") {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Error!', 'Please enter required value', 'error');
        return;
      }
    } else if (this.currentUser.role == 3) {
      if (this.adjust_revenue == "") {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Error!', 'Please enter required value', 'error');
        return;
      }
    } else {
      if (this.adjust_payout == "" || this.adjust_revenue == "") {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Error!', 'Please enter required value', 'error');
        return;
      }
    }
    // console.log(this.adjust_revenue);
    // return
    const formData = new FormData();
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    formData.append('user_uuid', this.currentUser.uuid);
    formData.append('role', this.currentUser.role);
    formData.append('call_uuid', this.calleruuid);
    formData.append('freeswitch_call_uuid', this.freeswitch_call_uuid);
    formData.append('type', type);
    if (type == 1) {
      formData.append('selectedrow', JSON.stringify(this.selectedrow));
    }
    if (this.adjust_revenue == "") {
      formData.append('is_revenue', "0");
    } else {
      formData.append('is_revenue', "1");
    }
    if (this.adjust_payout == "") {
      formData.append('is_payout', "0");
    } else {
      formData.append('is_payout', "1");
    }
    formData.append('revenue', this.adjust_revenue);
    formData.append('payout', this.adjust_payout);
    formData.append('reason', this.adjust_reason);
    this.moduleservice.adjust_call(formData, this.currentCompany.uuid).subscribe(res => {
      if (res.status !== 'error') {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Success!', 'Call adjust request successfully done');
        this.loadcalls(this.filterselected, this.selecteddate);
      } else {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Error!', 'Error occured please try again');
      }
    }, error => this.error = error);
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_17__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_15__.HttpBackend
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_18__.FormBuilder
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_12__.ActivatedRoute
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_12__.Router
  }, {
    type: _angular_core__WEBPACK_IMPORTED_MODULE_19__.ElementRef
  }, {
    type: ngx_ui_loader__WEBPACK_IMPORTED_MODULE_20__.NgxUiLoaderService
  }, {
    type: _angular_core__WEBPACK_IMPORTED_MODULE_19__.ChangeDetectorRef
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_21__.Title
  }];
  static #_2 = this.propDecorators = {
    table1: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_19__.ViewChild,
      args: ['dataTable1', {
        static: true
      }]
    }],
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_19__.ViewChild,
      args: ['myTable']
    }],
    copyname: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_19__.ViewChild,
      args: ['copyname']
    }]
  };
};
ReportsComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_22__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_19__.Component)({
  selector: 'app-reports',
  template: _reports_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_19__.ViewEncapsulation.None,
  styles: [(_reports_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], ReportsComponent);


/***/ }),

/***/ 46315:
/*!**************************************************!*\
  !*** ./src/app/modules/rules/rules.component.ts ***!
  \**************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "RulesComponent": () => (/* binding */ RulesComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _rules_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./rules.component.html?ngResource */ 66425);
/* harmony import */ var _rules_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./rules.component.scss?ngResource */ 30392);
/* harmony import */ var _rules_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_rules_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../module.service */ 22947);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var _angular_http__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/http */ 83702);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! sweetalert2 */ 60598);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(sweetalert2__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../global */ 27266);









//import 'sweetalert2/src/sweetalert2.scss'


let requestOptions = new _angular_http__WEBPACK_IMPORTED_MODULE_5__.RequestOptions({
  headers: null,
  withCredentials: true
});
const router = _angular_router__WEBPACK_IMPORTED_MODULE_6__.Router;
class DataTablesResponse {}
const ParseHeaders = {
  headers: new _angular_common_http__WEBPACK_IMPORTED_MODULE_7__.HttpHeaders({
    'Content-Type': 'application/x-www-form-urlencoded'
  })
};
let RulesComponent = class RulesComponent {
  constructor(moduleservice, toastrService, handler) {
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_4__.GlobalVariable.BASE_API_URL;
    this.dtOptions = {};
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_7__.HttpClient(handler);
  }
  ngOnInit() {
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.loadRules();
  }
  loadRules() {
    if ($.fn.DataTable.isDataTable(this.table.nativeElement)) {
      $(this.table.nativeElement).dataTable().fnDestroy();
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    var that = this;
    this.dtOptions = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "pageLength": 20,
      "order": [[2, "desc"]],
      ajax: (dataTablesParameters, callback) => {
        that.http.post(this.ServerUrl + 'getrules/' + this.currentCompany.uuid, dataTablesParameters, {}).subscribe(resp => {
          that.rules = resp.data;
          // console.log(that.numbers);
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [{
        data: "name"
      }, {
        data: "created_at"
      }, {
        data: "action"
      }]
    };
    this.dataTable = $(this.table.nativeElement);
    this.dataTable.dataTable(this.dtOptions);
  }
  Delete(uuid) {
    // alert(uuid);return false;
    sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
      title: 'Are you sure?',
      text: 'You want to Delete Record!',
      showCancelButton: true,
      confirmButtonText: 'Yes, delete it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        this.moduleservice.deleteRuleset(uuid).subscribe(res => {
          // console.log(res);return false;
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Record Deleted Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
          this.loadRules();
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
        }, 2000);
      }
    });
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_8__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_7__.HttpBackend
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_9__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }]
  };
};
RulesComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_10__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_9__.Component)({
  selector: 'app-rules',
  template: _rules_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_rules_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], RulesComponent);


/***/ }),

/***/ 34904:
/*!**************************************************************!*\
  !*** ./src/app/modules/rules/rulesadd/rulesadd.component.ts ***!
  \**************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "RulesaddComponent": () => (/* binding */ RulesaddComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _rulesadd_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./rulesadd.component.html?ngResource */ 99993);
/* harmony import */ var _rulesadd_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./rulesadd.component.scss?ngResource */ 12725);
/* harmony import */ var _rulesadd_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_rulesadd_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../../module.service */ 22947);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/router */ 60124);








let RulesaddComponent = class RulesaddComponent {
  constructor(fb, toastrService, moduleService, router) {
    this.fb = fb;
    this.toastrService = toastrService;
    this.moduleService = moduleService;
    this.router = router;
    this.controlEnabled = true;
    this.submitted = false;
  }
  ngOnInit() {
    this.addForm = this.fb.group({
      name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_3__.Validators.required],
      itemRows: this.fb.array([this.initItemRow()])
    });
  }
  get f() {
    return this.addForm.controls;
  }
  onSubmit() {
    // const formData = new FormData();      
    this.submitted = true;
    if (this.addForm.invalid) {
      return;
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    // console.log(this.addForm.value);
    this.moduleService.addRuleSet(this.addForm.value, this.currentCompany.uuid).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Rule Set Added Successfully');
        this.router.navigate(['/rules']);
      } else {
        this.toastrService.error('Failed To Add');
      }
    }, error => this.error = error);
  }
  initItemRow() {
    return this.fb.group({
      ifval: ['NUMBER', ''],
      isval: ['', ''],
      thenval: ['FORWARD_TO', ''],
      thentxt: ['', ''],
      andval: ['STOP', '']
    });
  }
  addRow() {
    // alert('ok');
    const control = this.addForm.controls['itemRows'];
    control.push(this.initItemRow());
  }
  deleteRow(index) {
    const control = this.addForm.controls['itemRows'];
    if (control != null) {
      this.totalrow = control.value.length;
    }
    if (this.totalrow > 1) {
      control.removeAt(index);
    } else {
      this.toastrService.error('One Record is Mendatory');
      // alert('One Record is Mendatory');
      return false;
    }
  }
  _keyPress(event) {
    const isNumericInput = event => {
      const key = event.keyCode;
      return key >= 48 && key <= 57 ||
      // Allow number line
      key >= 96 && key <= 105 // Allow number pad
      ;
    };

    const isModifierKey = event => {
      const key = event.keyCode;
      return event.shiftKey === true || key === 35 || key === 36 ||
      // Allow Shift, Home, End
      key === 8 || key === 9 || key === 13 || key === 46 ||
      // Allow Backspace, Tab, Enter, Delete
      key > 36 && key < 41 ||
      // Allow left, up, right, down

      // Allow Ctrl/Command + A,C,V,X,Z
      (event.ctrlKey === true || event.metaKey === true) && (key === 65 || key === 67 || key === 86 || key === 88 || key === 90);
    };
    const enforceFormat = event => {
      // Input must be of a valid number format or a modifier key, and not longer than ten digits
      if (!isNumericInput(event) && !isModifierKey(event)) {
        event.preventDefault();
      }
    };
    const formatToPhone = event => {
      if (isModifierKey(event)) {
        return;
      }
      const target = event.target;
      const input = event.target.value.replace(/\D/g, '').substring(0, 10); // First ten digits of input only
      const zip = input.substring(0, 3);
      const middle = input.substring(3, 6);
      const last = input.substring(6, 10);
      if (input.length > 6) {
        target.value = `(${zip}) ${middle}-${last}`;
      } else if (input.length > 3) {
        target.value = `(${zip}) ${middle}`;
      } else if (input.length > 0) {
        target.value = `(${zip}`;
      }
    };
    // const inputElement = document.getElementById('number');
    const inputElement = document.getElementsByClassName('number');
    if (inputElement) {
      for (let i = 0; i < inputElement.length; i++) {
        inputElement[i].addEventListener('keydown', enforceFormat);
        inputElement[i].addEventListener('keyup', formatToPhone);
      }
    }
  }
  static #_ = this.ctorParameters = () => [{
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_3__.FormBuilder
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_4__.ToastrService
  }, {
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_5__.Router
  }];
};
RulesaddComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_6__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_7__.Component)({
  selector: 'app-rulesadd',
  template: _rulesadd_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_rulesadd_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], RulesaddComponent);


/***/ }),

/***/ 73692:
/*!****************************************************************!*\
  !*** ./src/app/modules/rules/rulesedit/rulesedit.component.ts ***!
  \****************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "RuleseditComponent": () => (/* binding */ RuleseditComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _rulesedit_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./rulesedit.component.html?ngResource */ 77216);
/* harmony import */ var _rulesedit_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./rulesedit.component.scss?ngResource */ 15063);
/* harmony import */ var _rulesedit_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_rulesedit_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../../module.service */ 22947);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/router */ 60124);








let RuleseditComponent = class RuleseditComponent {
  constructor(fb, toastrService, route, moduleService, router) {
    this.fb = fb;
    this.toastrService = toastrService;
    this.route = route;
    this.moduleService = moduleService;
    this.router = router;
    this.controlEnabled = true;
    this.submitted = false;
  }
  ngOnInit() {
    this.editForm = this.fb.group({
      name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_3__.Validators.required],
      itemRows: this.fb.array([])
    });
    const uuid = this.route.snapshot.paramMap.get('id');
    // alert(uuid);
    if (uuid) {
      this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
      this.moduleService.getruledata(uuid, this.currentCompany.uuid).subscribe(res => {
        this.editForm.patchValue({
          name: res.ruleset_data.name
        });
        // console.log(res);
        const control = this.editForm.controls['itemRows'];
        for (let index = 0; index < res.rule_data.length; index++) {
          control.push(this.initItemRow());
          control.controls[index].get('ifval').setValue(res.rule_data[index].rule_condition_type);
          control.controls[index].get('isval').setValue(res.rule_data[index].rule_condition_is_value);
          control.controls[index].get('thenval').setValue(res.rule_data[index].then_condition_action);
          control.controls[index].get('thentxt').setValue(res.rule_data[index].then_condition_value);
        }
      });
    }
  }
  get f() {
    return this.editForm.controls;
  }
  onSubmit() {
    // const formData = new FormData();      
    this.submitted = true;
    if (this.editForm.invalid) {
      return;
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    const uuid = this.route.snapshot.paramMap.get('id');
    // console.log(this.editForm.value);
    this.moduleService.editRuleSet(this.editForm.value, this.currentCompany.uuid, uuid).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Rule Set Updated Successfully');
        this.router.navigate(['/rules']);
      } else {
        this.toastrService.error('Failed To Add');
      }
    }, error => this.error = error);
  }
  initItemRow() {
    return this.fb.group({
      ifval: ['NUMBER', ''],
      isval: ['', ''],
      thenval: ['FORWARD_TO', ''],
      thentxt: ['', ''],
      andval: ['STOP', '']
    });
  }
  addRow() {
    // console.log(this.editForm.controls['itemRows']);
    const control = this.editForm.controls['itemRows'];
    control.push(this.initItemRow());
  }
  deleteRow(index) {
    const control = this.editForm.controls['itemRows'];
    if (control != null) {
      this.totalrow = control.value.length;
    }
    if (this.totalrow > 1) {
      control.removeAt(index);
    } else {
      this.toastrService.error('One Record is Mendatory');
      // alert('One Record is Mendatory');
      return false;
    }
  }
  _keyPress(event) {
    const isNumericInput = event => {
      const key = event.keyCode;
      return key >= 48 && key <= 57 ||
      // Allow number line
      key >= 96 && key <= 105 // Allow number pad
      ;
    };

    const isModifierKey = event => {
      const key = event.keyCode;
      return event.shiftKey === true || key === 35 || key === 36 ||
      // Allow Shift, Home, End
      key === 8 || key === 9 || key === 13 || key === 46 ||
      // Allow Backspace, Tab, Enter, Delete
      key > 36 && key < 41 ||
      // Allow left, up, right, down

      // Allow Ctrl/Command + A,C,V,X,Z
      (event.ctrlKey === true || event.metaKey === true) && (key === 65 || key === 67 || key === 86 || key === 88 || key === 90);
    };
    const enforceFormat = event => {
      // Input must be of a valid number format or a modifier key, and not longer than ten digits
      if (!isNumericInput(event) && !isModifierKey(event)) {
        event.preventDefault();
      }
    };
    const formatToPhone = event => {
      if (isModifierKey(event)) {
        return;
      }
      const target = event.target;
      const input = event.target.value.replace(/\D/g, '').substring(0, 10); // First ten digits of input only
      const zip = input.substring(0, 3);
      const middle = input.substring(3, 6);
      const last = input.substring(6, 10);
      if (input.length > 6) {
        target.value = `(${zip}) ${middle}-${last}`;
      } else if (input.length > 3) {
        target.value = `(${zip}) ${middle}`;
      } else if (input.length > 0) {
        target.value = `(${zip}`;
      }
    };
    // const inputElement = document.getElementById('number');
    const inputElement = document.getElementsByClassName('number');
    if (inputElement) {
      for (let i = 0; i < inputElement.length; i++) {
        inputElement[i].addEventListener('keydown', enforceFormat);
        inputElement[i].addEventListener('keyup', formatToPhone);
      }
    }
  }
  static #_ = this.ctorParameters = () => [{
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_3__.FormBuilder
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_4__.ToastrService
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_5__.ActivatedRoute
  }, {
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_5__.Router
  }];
};
RuleseditComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_6__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_7__.Component)({
  selector: 'app-rulesedit',
  template: _rulesedit_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_rulesedit_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], RuleseditComponent);


/***/ }),

/***/ 32279:
/*!***************************************************************************************!*\
  !*** ./src/app/modules/settings/alert-configuration/alert-configuration.component.ts ***!
  \***************************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "AlertConfigurationComponent": () => (/* binding */ AlertConfigurationComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _alert_configuration_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./alert-configuration.component.html?ngResource */ 42400);
/* harmony import */ var _alert_configuration_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./alert-configuration.component.scss?ngResource */ 50486);
/* harmony import */ var _alert_configuration_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_alert_configuration_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../module.service */ 22947);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./../../../global */ 27266);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/platform-browser */ 34497);










const router = _angular_router__WEBPACK_IMPORTED_MODULE_4__.Router;

let AlertConfigurationComponent = class AlertConfigurationComponent {
  constructor(moduleservice, toastrService, handler, fb, cdRef, titleService) {
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.fb = fb;
    this.cdRef = cdRef;
    this.titleService = titleService;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_3__.GlobalVariable.BASE_API_URL;
    this.BaseUrl = _global__WEBPACK_IMPORTED_MODULE_3__.GlobalVariable.BASE_URL;
    this.dropdownSettings = {};
    this.isdontuselabel = false;
    this.Submitted = false;
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.Companyuuid = this.currentCompany.uuid;
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_5__.HttpClient(handler);
    this.publicregistration = true;
  }
  ngAfterViewChecked() {
    this.cdRef.detectChanges();
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngOnInit() {
    this.setTitle('Alert Configuration');
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.getAllLabels();
    this.addForm = this.fb.group({
      // , Validators.required
      user_uuid: [''],
      nameofalert: [''],
      labelname: [''],
      calllength: [''],
      onetimealert: [''],
      systemalert: ['']
    });
  }
  getAllLabels() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleservice.getAllLabels(this.currentCompany.uuid).subscribe(res => {
      this.dropdownSettings = {
        singleSelection: false,
        text: "Select Label Name",
        selectAllText: 'Select All',
        unSelectAllText: 'UnSelect All',
        enableSearchFilter: true,
        classes: "myclass custom-class"
      };
      this.alllabels = res;
      //  console.log(res); return false;                    
    }, error => this.error = error);
  }
  dontuselabel(event) {
    this.isdontuselabel = event.target.checked;
  }
  //Add Publisher
  get addformcontrol() {
    return this.addForm.controls;
  }
  onSubmit() {
    const formData = new FormData();
    // this.Submitted = true;
    // if (this.addForm.invalid) {
    //     return;
    // }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    formData.append('user_uuid', currentUser.uuid);
    formData.append('uuid', this.currentCompany.uuid);
    formData.append('public_registration', "");
    // formData.append('intro', this.addForm.get('intro').value);
    // formData.append('email', this.addForm.get('email').value);    
    formData.append('terms_cond', "");
    formData.append('tc_url', this.addForm.get('tc_url').value);
    // console.log(formData); return false;
    this.moduleservice.addPublisherSettingdata(formData).subscribe(res => {
      // console.log(res.status); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Publisher Setting Saved Successfully');
        this.getAllLabels();
        this.Submitted = false;
      } else {
        this.toastrService.error('Failed To Add Label');
      }
    }, error => this.error = error);
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_6__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_5__.HttpBackend
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_7__.FormBuilder
  }, {
    type: _angular_core__WEBPACK_IMPORTED_MODULE_8__.ChangeDetectorRef
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_9__.Title
  }];
};
AlertConfigurationComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_10__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_8__.Component)({
  selector: 'app-alert-configuration',
  template: _alert_configuration_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_alert_configuration_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], AlertConfigurationComponent);


/***/ }),

/***/ 76251:
/*!***************************************************************************!*\
  !*** ./src/app/modules/settings/basic-setting/basic-setting.component.ts ***!
  \***************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "BasicSettingComponent": () => (/* binding */ BasicSettingComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _basic_setting_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./basic-setting.component.html?ngResource */ 54610);
/* harmony import */ var _basic_setting_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./basic-setting.component.scss?ngResource */ 52526);
/* harmony import */ var _basic_setting_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_basic_setting_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../module.service */ 22947);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! sweetalert2 */ 60598);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(sweetalert2__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./../../../global */ 27266);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/platform-browser */ 34497);









//import 'sweetalert2/src/sweetalert2.scss'


const router = _angular_router__WEBPACK_IMPORTED_MODULE_5__.Router;

let BasicSettingComponent = class BasicSettingComponent {
  constructor(moduleservice, toastrService, handler, fb, titleService) {
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.fb = fb;
    this.titleService = titleService;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_4__.GlobalVariable.BASE_API_URL;
    this.allBuyers = [];
    this.selectedItems = [];
    this.xyzrules = true;
    this.isaddemail = 0;
    this.Submitted = false;
    this.addemailval = "";
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.Companyuuid = this.currentCompany.uuid;
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_6__.HttpClient(handler);
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngOnInit() {
    this.setTitle('Forwarding Number Directory');
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.getAllbasicsetting();
    this.addForm = this.fb.group({
      // , Validators.required
      googlesheetlink: [''],
      xyzrules: [''],
      email: ['']
    });
  }
  getAllbasicsetting() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentUser'));
    const p1 = new Promise((result, rej) => {
      this.moduleservice.getAllbasicsetting(this.currentCompany.uuid).subscribe(res => {
        result(res);
        //  console.log(res); return false;           
      }, error => this.error = error);
    });
    const prm = [p1];
    Promise.all(prm).then(results => {
      // console.log(results);
      this.allBuyers = results[0]['emails'];
      if (results[0]['xyz_rules'] == 1) {
        this.xyzrules = true;
      } else {
        this.xyzrules = false;
      }
      // // this.allBuyers = res['emails'];
      if (results[0]['emails'].length > 0) {
        let text = results[0]['emails'].filter(x => x.uuid == results[0]['email'])[0];
        if (text != undefined) {
          this.selectedItems = [{
            "id": text.uuid,
            "itemName": text.itemName
          }];
        }
      }
      this.addForm.patchValue({
        googlesheetlink: results[0]['google_sheet_link'],
        xyzrules: this.xyzrules
      });
    });
  }
  xyzrules_enable(event) {
    this.xyzrules = event.target.checked;
  }
  isaddemailfun(type) {
    this.isaddemail = type;
  }
  //Add Publisher
  get addformcontrol() {
    return this.addForm.controls;
  }
  onSubmit() {
    // console.log(this.addemailval);retu
    const formData = new FormData();
    this.Submitted = true;
    if (this.addForm.invalid) {
      return;
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentUser'));
    formData.append('user_uuid', this.currentCompany.uuid);
    formData.append('google_sheet_link', this.addForm.get('googlesheetlink').value);
    formData.append('email', JSON.stringify(this.addForm.get('email').value));
    formData.append('xyz_rules', this.xyzrules);
    // console.log(formData); return false;
    this.moduleservice.addBasicSettingdata(formData).subscribe(res => {
      // console.log(res.status); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Basic Setting Saved Successfully');
        this.getAllbasicsetting();
        this.Submitted = false;
      } else {
        this.toastrService.error('Failed To Save Settings');
      }
    }, error => this.error = error);
  }
  addnewemail() {
    if (this.addemailval == "") {
      sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Error!', 'Please add email value');
      return;
    }
    this.moduleservice.addemail(this.addemailval, this.currentCompany.uuid).subscribe(res => {
      // console.log(res.status); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Email added successfully');
        this.getAllbasicsetting();
        this.isaddemail = 0;
        this.addemailval = "";
      } else {
        this.toastrService.error('Failed To add email.');
      }
    }, error => this.error = error);
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_7__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_6__.HttpBackend
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_8__.FormBuilder
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_9__.Title
  }];
};
BasicSettingComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_10__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_11__.Component)({
  selector: 'app-basic-setting',
  template: _basic_setting_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_basic_setting_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], BasicSettingComponent);


/***/ }),

/***/ 78376:
/*!*****************************************************************************!*\
  !*** ./src/app/modules/settings/manage-company/manage-company.component.ts ***!
  \*****************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "ManageCompanyComponent": () => (/* binding */ ManageCompanyComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _manage_company_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./manage-company.component.html?ngResource */ 86446);
/* harmony import */ var _manage_company_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./manage-company.component.scss?ngResource */ 56862);
/* harmony import */ var _manage_company_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_manage_company_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../../module.service */ 22947);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! sweetalert2 */ 60598);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(sweetalert2__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../global */ 27266);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/platform-browser */ 34497);









//import 'sweetalert2/src/sweetalert2.scss'


// import { ngxCsv } from 'ngx-csv/ngx-csv';

const router = _angular_router__WEBPACK_IMPORTED_MODULE_5__.Router;
class DataTablesResponse {}
let ManageCompanyComponent = class ManageCompanyComponent {
  constructor(moduleservice, toastrService, handler, fb, titleService) {
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.fb = fb;
    this.titleService = titleService;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_4__.GlobalVariable.BASE_API_URL;
    this.dtOptions = {};
    this.ischecked = '1';
    this.checkboxes = [];
    this.Submitted = false;
    this.editSubmitted = false;
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_6__.HttpClient(handler);
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngOnInit() {
    this.setTitle('Manage Companies');
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.loadcompanies();
    this.addForm = this.fb.group({
      company_name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      phone: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      city: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      state: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      country: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      postal_code: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required]
    });
    this.editForm = this.fb.group({
      uuid: [''],
      company_name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      phone: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      city: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      state: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      country: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      postal_code: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required]
    });
  }
  loadcompanies() {
    if ($.fn.DataTable.isDataTable(this.table.nativeElement)) {
      $(this.table.nativeElement).dataTable().fnDestroy();
    }
    this.currentUser = JSON.parse(localStorage.getItem('currentCompany'));
    this.dtOptions = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "pageLength": 25,
      "order": [[5, "desc"]],
      ajax: (dataTablesParameters, callback) => {
        this.http.post(this.ServerUrl + 'getcompanies/' + this.currentUser.uuid, dataTablesParameters, {}).subscribe(resp => {
          this.numbers = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [{
        data: "name"
      }, {
        data: "phone"
      }, {
        data: "city"
      }, {
        data: "state"
      }, {
        data: "country"
      }, {
        data: "postal_code"
      }, {
        data: "created_at"
      }, {
        data: "action"
      }],
      columnDefs: [{
        "targets": [0],
        "orderable": false
      }]
    };
    this.dataTable = $(this.table.nativeElement);
    this.dataTable.dataTable(this.dtOptions);
  }
  editdata(uuid, name, phone, city, state, country, postal_code) {
    this.editForm.patchValue({
      uuid: uuid,
      company_name: name,
      phone: phone,
      city: city,
      state: state,
      country: country,
      postal_code: postal_code
    });
  }
  checkalldelete(event) {
    const checked = event.target.checked;
    this.numbers.forEach(chkbox => chkbox.selected = checked);
  }
  deleteselected(event) {
    // $("#customCheck1").prop("checked", false);    
    if (event.target.checked == true) {
      if (event.target.value == 'on') {
        this.checkboxes = [];
        this.numbers.forEach(lbl => {
          this.checkboxes.push(lbl.id);
        });
      } else {
        if (this.checkboxes.length + 1 == this.numbers.length) {
          $("#customCheck1").prop("checked", true);
        }
        this.checkboxes.push(event.target.value);
      }
      this.ischecked = '0';
    } else {
      // console.log(this.checkboxes);      
      if (this.checkboxes.length != 0) {
        $("#customCheck1").prop("checked", false);
      }
      if (event.target.value != 'on') {
        const index = this.checkboxes.indexOf(event.target.value);
        this.checkboxes.splice(index, 1);
      } else {
        this.checkboxes = [];
      }
      this.ischecked = '1';
    }
    // console.log(this.checkboxes); 
  }

  onDeleteSubmit() {
    if (this.checkboxes.length == 0) {
      this.toastrService.error('Please Select Row To Delete');
    } else {
      // console.log(this.checkboxes);  
      sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
        title: 'Are you sure?',
        text: 'You want to Delete Selected Record!',
        showCancelButton: true,
        confirmButtonText: 'Yes, delete it!',
        cancelButtonText: 'No, keep it'
      }).then(result => {
        if (result.value) {
          this.moduleservice.deleteSelectedNumbers(this.checkboxes).subscribe(res => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Records Deleted Successfully.');
            setTimeout(() => {
              sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
            }, 2000);
            this.loadcompanies();
          }, error => this.error = error);
        } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
        }
      });
    }
  }
  Delete(id) {
    sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
      title: 'Are you sure?',
      text: 'You want to Delete Record!',
      showCancelButton: true,
      confirmButtonText: 'Yes, delete it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        this.moduleservice.deleteCompany(+id).subscribe(res => {
          // return false;
          this.loadcompanies();
          // this.toastrService.success('Number Deleted Successfully');
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Record Deleted Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
        }, 2000);
      }
    });
  }
  //Add Buyer
  get addcontrol() {
    return this.addForm.controls;
  }
  onSubmit() {
    const formData = new FormData();
    this.Submitted = true;
    if (this.addForm.invalid) {
      return;
    }
    // this.currentUser = JSON.parse(localStorage.getItem('currentCompany'));
    // formData.append('company_uuid', this.currentUser.uuid);
    formData.append('company_name', this.addForm.get('company_name').value);
    formData.append('phone', this.addForm.get('phone').value);
    formData.append('city', this.addForm.get('city').value);
    formData.append('state', this.addForm.get('state').value);
    formData.append('country', this.addForm.get('country').value);
    formData.append('postal_code', this.addForm.get('postal_code').value);
    this.moduleservice.addCompany(formData).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Comapny Added Successfully');
        this.loadcompanies();
        this.Submitted = false;
      } else {
        this.toastrService.error('Failed To Add Label');
      }
    }, error => this.error = error);
  }
  closeModal() {
    if (!this.addForm.invalid) {
      $("#addLabels").modal("hide");
      this.Submitted = false;
      setTimeout(() => {
        this.addForm.reset();
      }, 2000);
    }
  }
  //Add Buyer
  get editcontrol() {
    return this.editForm.controls;
  }
  onEditSubmit() {
    // alert('ok');return false;
    const formData = new FormData();
    this.editSubmitted = true;
    if (this.editForm.invalid) {
      return;
    }
    this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    formData.append('company_uuid', this.currentUser.uuid);
    // formData.append('uuid', this.editForm.get('uuid').value);
    formData.append('company_name', this.editForm.get('company_name').value);
    formData.append('phone', this.editForm.get('phone').value);
    formData.append('city', this.editForm.get('city').value);
    formData.append('state', this.editForm.get('state').value);
    formData.append('country', this.editForm.get('country').value);
    formData.append('postal_code', this.editForm.get('postal_code').value);
    // console.log(formData); 
    this.moduleservice.editCompany(formData, this.editForm.get('uuid').value).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Company Details Updated Successfully');
        this.loadcompanies();
        this.editSubmitted = false;
      } else {
        this.toastrService.error('Failed To Updated Company Details');
      }
    }, error => this.error = error);
  }
  closeEditModal() {
    if (!this.editForm.invalid) {
      $("#editLabels").modal("hide");
      this.editSubmitted = false;
      setTimeout(() => {
        this.editForm.reset();
      }, 2000);
    }
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_8__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_6__.HttpBackend
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_7__.FormBuilder
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_9__.Title
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_10__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }]
  };
};
ManageCompanyComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_11__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_10__.Component)({
  selector: 'app-manage-company',
  template: _manage_company_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_manage_company_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], ManageCompanyComponent);


/***/ }),

/***/ 57632:
/*!*************************************************************************!*\
  !*** ./src/app/modules/settings/manage-users/manage-users.component.ts ***!
  \*************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "ManageUsersComponent": () => (/* binding */ ManageUsersComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _manage_users_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./manage-users.component.html?ngResource */ 70265);
/* harmony import */ var _manage_users_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./manage-users.component.scss?ngResource */ 38179);
/* harmony import */ var _manage_users_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_manage_users_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../../module.service */ 22947);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! sweetalert2 */ 60598);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(sweetalert2__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../global */ 27266);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/platform-browser */ 34497);









//import 'sweetalert2/src/sweetalert2.scss'


// import { ngxCsv } from 'ngx-csv/ngx-csv';

const router = _angular_router__WEBPACK_IMPORTED_MODULE_5__.Router;
class DataTablesResponse {}
let ManageUsersComponent = class ManageUsersComponent {
  constructor(moduleservice, toastrService, handler, fb, titleService) {
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.fb = fb;
    this.titleService = titleService;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_4__.GlobalVariable.BASE_API_URL;
    this.dtOptions = {};
    this.ischecked = '1';
    this.checkboxes = [];
    this.Submitted = false;
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_6__.HttpClient(handler);
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngOnInit() {
    this.setTitle('Manage Users');
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.loadusers();
    this.addForm = this.fb.group({
      first_name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      last_name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      email: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      role: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      user_uuid: ['']
    });
    this.editForm = this.fb.group({
      uuid: [''],
      company: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required],
      sub_id: [''],
      allow_buyer_to_pause_target: [''],
      allow_buyer_to_set_target_concurrency: [''],
      allow_buyer_to_dispute_call_conversions: [''],
      limit_revenue: [''],
      user_uuid: ['']
    });
  }
  loadusers() {
    // console.log('ok');
    // return false;
    if ($.fn.DataTable.isDataTable(this.table.nativeElement)) {
      $(this.table.nativeElement).dataTable().fnDestroy();
    }
    this.currentUser = JSON.parse(localStorage.getItem('currentCompany'));
    this.dtOptions = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "pageLength": 20,
      "lengthMenu": [[-1, 20, 100, 500, 2000], ["All", 20, 100, 500, 2000]],
      "order": [[5, "desc"]],
      ajax: (dataTablesParameters, callback) => {
        this.http.post(this.ServerUrl + 'getusers/' + this.currentUser.uuid, dataTablesParameters, {}).subscribe(resp => {
          this.numbers = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [
      // {data:"checkall"},
      // {data:"hour"},{data:"day"},{data:"month"},{data:"total"},
      // ,{data:"status"}
      {
        data: "first_name"
      }, {
        data: "last_name"
      }, {
        data: "email"
      }, {
        data: "role"
      }, {
        data: "invitation"
      }, {
        data: "created_at"
      }, {
        data: "action"
      }],
      columnDefs: [{
        "targets": [0],
        "orderable": false
      }]
    };
    this.dataTable = $(this.table.nativeElement);
    this.dataTable.dataTable(this.dtOptions);
  }
  editdata(uuid, company, sub_id, allow_buyer_to_pause_target, allow_buyer_to_set_target_concurrency, allow_buyer_to_dispute_call_conversions, limit_revenue) {
    this.editForm.patchValue({
      uuid: uuid,
      company: company,
      sub_id: sub_id,
      allow_buyer_to_pause_target: allow_buyer_to_pause_target,
      allow_buyer_to_set_target_concurrency: allow_buyer_to_set_target_concurrency,
      allow_buyer_to_dispute_call_conversions: allow_buyer_to_dispute_call_conversions,
      limit_revenue: limit_revenue
    });
  }
  checkalldelete(event) {
    const checked = event.target.checked;
    this.numbers.forEach(chkbox => chkbox.selected = checked);
  }
  deleteselected(event) {
    // $("#customCheck1").prop("checked", false);    
    if (event.target.checked == true) {
      if (event.target.value == 'on') {
        this.checkboxes = [];
        this.numbers.forEach(lbl => {
          this.checkboxes.push(lbl.id);
        });
      } else {
        if (this.checkboxes.length + 1 == this.numbers.length) {
          $("#customCheck1").prop("checked", true);
        }
        this.checkboxes.push(event.target.value);
      }
      this.ischecked = '0';
    } else {
      // console.log(this.checkboxes);      
      if (this.checkboxes.length != 0) {
        $("#customCheck1").prop("checked", false);
      }
      if (event.target.value != 'on') {
        const index = this.checkboxes.indexOf(event.target.value);
        this.checkboxes.splice(index, 1);
      } else {
        this.checkboxes = [];
      }
      this.ischecked = '1';
    }
    // console.log(this.checkboxes); 
  }

  onDeleteSubmit() {
    if (this.checkboxes.length == 0) {
      this.toastrService.error('Please Select Row To Delete');
    } else {
      // console.log(this.checkboxes);  
      sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
        title: 'Are you sure?',
        text: 'You want to Delete Selected Record!',
        showCancelButton: true,
        confirmButtonText: 'Yes, delete it!',
        cancelButtonText: 'No, keep it'
      }).then(result => {
        if (result.value) {
          this.moduleservice.deleteSelectedNumbers(this.checkboxes).subscribe(res => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Records Deleted Successfully.');
            setTimeout(() => {
              sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
            }, 2000);
            this.loadusers();
          }, error => this.error = error);
        } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
        }
      });
    }
  }
  Delete(id) {
    sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
      title: 'Are you sure?',
      text: 'You want to Delete Record!',
      showCancelButton: true,
      confirmButtonText: 'Yes, delete it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        let currentUser = JSON.parse(localStorage.getItem('currentUser'));
        this.moduleservice.deleteUser(+id, currentUser.uuid).subscribe(res => {
          // return false;
          this.loadusers();
          // this.toastrService.success('Number Deleted Successfully');
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Record Deleted Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
        }, 2000);
      }
    });
  }
  //Add Buyer
  get buyercontrol() {
    return this.addForm.controls;
  }
  onSubmit() {
    const formData = new FormData();
    this.Submitted = true;
    if (this.addForm.invalid) {
      return;
    }
    this.currentUser = JSON.parse(localStorage.getItem('currentCompany'));
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    formData.append('user_uuid', currentUser.uuid);
    formData.append('company_uuid', this.currentUser.uuid);
    formData.append('first_name', this.addForm.get('first_name').value);
    formData.append('last_name', this.addForm.get('last_name').value);
    formData.append('email', this.addForm.get('email').value);
    formData.append('role', this.addForm.get('role').value);
    // console.log(this.currentUser); return false;
    this.moduleservice.addUser(formData).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('User Added Successfully');
        this.loadusers();
        this.Submitted = false;
      } else {
        this.toastrService.error('Failed To Add Label');
      }
    }, error => this.error = error);
  }
  closeModal() {
    if (this.addForm.get('first_name').value && this.addForm.get('last_name').value) {
      $("#addLabels").modal("hide");
      this.Submitted = false;
      setTimeout(() => {
        this.addForm.reset();
      }, 2000);
    }
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_8__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_6__.HttpBackend
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_7__.FormBuilder
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_9__.Title
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_10__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }]
  };
};
ManageUsersComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_11__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_10__.Component)({
  selector: 'app-manage-users',
  template: _manage_users_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_manage_users_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], ManageUsersComponent);


/***/ }),

/***/ 64943:
/*!******************************************************************************************!*\
  !*** ./src/app/modules/settings/predictive-routing/add-routing/add-routing.component.ts ***!
  \******************************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "AddRoutingComponent": () => (/* binding */ AddRoutingComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _add_routing_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./add-routing.component.html?ngResource */ 97653);
/* harmony import */ var _add_routing_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./add-routing.component.scss?ngResource */ 81995);
/* harmony import */ var _add_routing_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_add_routing_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../../../module.service */ 22947);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @angular/platform-browser */ 34497);










let AddRoutingComponent = class AddRoutingComponent {
  constructor(fb, moduleService, router, route, toastrService, handler, cdRef, titleService) {
    this.fb = fb;
    this.moduleService = moduleService;
    this.router = router;
    this.route = route;
    this.toastrService = toastrService;
    this.cdRef = cdRef;
    this.titleService = titleService;
    this.msbapTitle = 'Audio Title';
    this.msbapAudioUrl = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/fsdffsdf.mp3';
    this.msbapDisplayTitle = false;
    this.msbapDisplayVolumeControls = true;
    this.allBuyers = [];
    this.settings = {};
    this.submitted = false;
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_3__.HttpClient(handler);
  }
  ngAfterContentChecked() {
    this.cdRef.detectChanges();
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngOnInit() {
    this.setTitle('Add Predictive Routing');
    // this.showLoadingIndicator= true;
    // setTimeout(()=>{this.showLoadingIndicator= false; },1000);
    this.addForm = this.fb.group({
      user_uuid: [''],
      name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_4__.Validators.required],
      count_attempts: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_4__.Validators.required],
      track_conversions_by: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_4__.Validators.required],
      minimum_numberofCalls: [''],
      desired_numberofCalls: [''],
      minimum_numberofHours: [''],
      desired_numberofHours: [''],
      skip_latest_hours: [''],
      new_targets: [''],
      underperforming_targets: ['']
    });
    this.addForm.patchValue({
      count_attempts: '0',
      track_conversions_by: '0',
      minimum_numberofCalls: '15',
      desired_numberofCalls: '75',
      desired_numberofHours: '720'
    });
  }
  get f() {
    return this.addForm.controls;
  }
  onSubmit() {
    // const formData = new FormData();      
    this.submitted = true;
    if (this.addForm.invalid) {
      return;
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.addForm.get("user_uuid").setValue(currentUser.uuid);
    // console.log(this.buyername); return
    // this.addForm.get("buyer").setValue(this.buyername);
    this.moduleService.addPredictiveRouting(this.addForm.value, this.currentCompany.uuid).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Predictive Routing Configuration Created Successfully');
        this.router.navigate(['/predictive-routing']);
      } else {
        this.toastrService.error('Failed To Add');
      }
    }, error => this.error = error);
  }
  static #_ = this.ctorParameters = () => [{
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_4__.FormBuilder
  }, {
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_5__.Router
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_5__.ActivatedRoute
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_6__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_3__.HttpBackend
  }, {
    type: _angular_core__WEBPACK_IMPORTED_MODULE_7__.ChangeDetectorRef
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_8__.Title
  }];
};
AddRoutingComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_9__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_7__.Component)({
  selector: 'app-add-routing',
  template: _add_routing_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_add_routing_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], AddRoutingComponent);


/***/ }),

/***/ 57977:
/*!********************************************************************************************!*\
  !*** ./src/app/modules/settings/predictive-routing/edit-routing/edit-routing.component.ts ***!
  \********************************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "EditRoutingComponent": () => (/* binding */ EditRoutingComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _edit_routing_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./edit-routing.component.html?ngResource */ 61192);
/* harmony import */ var _edit_routing_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./edit-routing.component.scss?ngResource */ 10321);
/* harmony import */ var _edit_routing_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_edit_routing_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../../../module.service */ 22947);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @angular/platform-browser */ 34497);










let EditRoutingComponent = class EditRoutingComponent {
  constructor(fb, moduleService, router, route, toastrService, handler, cdRef, titleService) {
    this.fb = fb;
    this.moduleService = moduleService;
    this.router = router;
    this.route = route;
    this.toastrService = toastrService;
    this.cdRef = cdRef;
    this.titleService = titleService;
    this.msbapTitle = 'Audio Title';
    this.msbapAudioUrl = 'https://d2actkasrcrrs8.cloudfront.net/ivr-audio/fsdffsdf.mp3';
    this.msbapDisplayTitle = false;
    this.msbapDisplayVolumeControls = true;
    this.allBuyers = [];
    this.settings = {};
    this.submitted = false;
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_3__.HttpClient(handler);
  }
  ngAfterContentChecked() {
    this.cdRef.detectChanges();
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngOnInit() {
    this.setTitle('Edit Predictive Routing');
    this.getalldata();
    // this.showLoadingIndicator= true;
    // setTimeout(()=>{this.showLoadingIndicator= false; },1000);
    this.addForm = this.fb.group({
      user_uuid: [''],
      name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_4__.Validators.required],
      count_attempts: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_4__.Validators.required],
      track_conversions_by: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_4__.Validators.required],
      minimum_numberofCalls: [''],
      desired_numberofCalls: [''],
      minimum_numberofHours: [''],
      desired_numberofHours: [''],
      skip_latest_hours: [''],
      new_targets: [''],
      underperforming_targets: ['']
    });
    // this.addForm.patchValue({
    //   count_attempts: '0',     
    //   track_conversions_by: '0',     
    //   minimum_numberofCalls: '15',     
    //   desired_numberofCalls: '75',     
    //   desired_numberofHours: '720',     
    // });  
  }

  getalldata() {
    const uuid = this.route.snapshot.paramMap.get('id');
    if (uuid) {
      this.moduleService.getpredictiveroutingdata(uuid).subscribe(res => {
        this.setTitle(res.name + ' | Predictive Routing');
        this.addForm.patchValue({
          name: res.name,
          count_attempts: res.count_attempts,
          track_conversions_by: res.track_conversions_by,
          minimum_numberofCalls: res.minimum_numberofCalls,
          desired_numberofCalls: res.desired_numberofCalls,
          minimum_numberofHours: res.minimum_numberofHours,
          desired_numberofHours: res.desired_numberofHours,
          skip_latest_hours: res.skip_latest_hours,
          new_targets: res.new_targets,
          underperforming_targets: res.underperforming_targets
        });
      });
      // this.ngxLoader.stopLoader('customLoaderId');
    }
  }

  get f() {
    return this.addForm.controls;
  }
  onSubmit() {
    // const formData = new FormData();      
    this.submitted = true;
    if (this.addForm.invalid) {
      return;
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    let currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.addForm.get("user_uuid").setValue(currentUser.uuid);
    // console.log(this.buyername); return
    // this.addForm.get("buyer").setValue(this.buyername);
    const uuid = this.route.snapshot.paramMap.get('id');
    this.moduleService.updatePredictiveRouting(uuid, this.currentCompany.uuid, this.addForm.value).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Predictive Routing Configuration Updated Successfully');
        this.router.navigate(['/predictive-routing']);
      } else {
        this.toastrService.error('Failed To Add');
      }
    }, error => this.error = error);
  }
  static #_ = this.ctorParameters = () => [{
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_4__.FormBuilder
  }, {
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_5__.Router
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_5__.ActivatedRoute
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_6__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_3__.HttpBackend
  }, {
    type: _angular_core__WEBPACK_IMPORTED_MODULE_7__.ChangeDetectorRef
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_8__.Title
  }];
};
EditRoutingComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_9__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_7__.Component)({
  selector: 'app-edit-routing',
  template: _edit_routing_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_edit_routing_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], EditRoutingComponent);


/***/ }),

/***/ 74982:
/*!*************************************************************************************!*\
  !*** ./src/app/modules/settings/predictive-routing/predictive-routing.component.ts ***!
  \*************************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "PredictiveRoutingComponent": () => (/* binding */ PredictiveRoutingComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _predictive_routing_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./predictive-routing.component.html?ngResource */ 59514);
/* harmony import */ var _predictive_routing_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./predictive-routing.component.scss?ngResource */ 9281);
/* harmony import */ var _predictive_routing_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_predictive_routing_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../../module.service */ 22947);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! sweetalert2 */ 60598);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(sweetalert2__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../global */ 27266);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @angular/platform-browser */ 34497);








//import 'sweetalert2/src/sweetalert2.scss'



const router = _angular_router__WEBPACK_IMPORTED_MODULE_5__.Router;
class DataTablesResponse {}
class IVRMenus {}
let PredictiveRoutingComponent = class PredictiveRoutingComponent {
  constructor(moduleservice, toastrService, handler, router, titleService) {
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.router = router;
    this.titleService = titleService;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_4__.GlobalVariable.BASE_API_URL;
    this.dtOptions = {};
    this.ischecked = '1';
    this.checkboxes = [];
    this.filter = [];
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_6__.HttpClient(handler);
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngOnInit() {
    this.setTitle('Predictive Routing');
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.loadIVRMenus();
  }
  loadIVRMenus() {
    if ($.fn.DataTable.isDataTable(this.table.nativeElement)) {
      $(this.table.nativeElement).dataTable().fnDestroy();
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    var that = this;
    this.dtOptions = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "pageLength": 20,
      "lengthMenu": [[-1, 20, 100, 500, 2000], ["All", 20, 100, 500, 2000]],
      "order": [[1, "asc"]],
      ajax: (dataTablesParameters, callback) => {
        that.http.post(this.ServerUrl + 'getPredictiveRouting/' + this.currentCompany.uuid, dataTablesParameters, {}).subscribe(resp => {
          that.IVRMenus = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [{
        data: "name"
      }, {
        data: "created_at"
      }, {
        data: "action"
      }],
      columnDefs: [{
        "targets": [0, 1],
        "orderable": false
      }]
    };
    this.dataTable = $(this.table.nativeElement);
    this.dataTable.dataTable(this.dtOptions);
  }
  checkalldelete(event) {
    const checked = event.target.checked;
    this.IVRMenus.forEach(chkbox => chkbox.selected = checked);
  }
  deleteselected(event) {
    // $("#customCheck1").prop("checked", false);    
    if (event.target.checked == true) {
      if (event.target.value == 'on') {
        this.checkboxes = [];
        this.IVRMenus.forEach(lbl => {
          this.checkboxes.push(lbl.id);
        });
      } else {
        if (this.checkboxes.length + 1 == this.IVRMenus.length) {
          $("#customCheck1").prop("checked", true);
        }
        this.checkboxes.push(event.target.value);
      }
      this.ischecked = '0';
    } else {
      // console.log(this.checkboxes);      
      if (this.checkboxes.length != 0) {
        $("#customCheck1").prop("checked", false);
      }
      if (event.target.value != 'on') {
        const index = this.checkboxes.indexOf(event.target.value);
        this.checkboxes.splice(index, 1);
      } else {
        this.checkboxes = [];
      }
      this.ischecked = '1';
    }
    // console.log(this.checkboxes); 
  }

  onDeleteSubmit() {
    if (this.checkboxes.length == 0) {
      this.toastrService.error('Please Select Row To Delete');
    } else {
      // console.log(this.checkboxes);  
      sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
        title: 'Are you sure?',
        text: 'You want to Delete Selected Record!',
        showCancelButton: true,
        confirmButtonText: 'Yes, delete it!',
        cancelButtonText: 'No, keep it'
      }).then(result => {
        if (result.value) {
          this.moduleservice.deleteSelectedIVR(this.checkboxes).subscribe(res => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Records Deleted Successfully.');
            setTimeout(() => {
              sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
            }, 2000);
            this.loadIVRMenus();
          }, error => this.error = error);
        } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
        }
      });
    }
  }
  Delete(uuid) {
    // alert(uuid);return false;
    sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
      title: 'Are you sure?',
      text: 'You want to Delete Record!',
      showCancelButton: true,
      confirmButtonText: 'Yes, delete it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        let currentUser = JSON.parse(localStorage.getItem('currentUser'));
        this.moduleservice.deletePredictiveRouting(uuid, currentUser.uuid).subscribe(res => {
          // console.log(res);return false;
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Record Deleted Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
          this.loadIVRMenus();
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
        }, 2000);
      }
    });
  }
  Clone(id) {
    sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
      title: 'Are you sure?',
      text: 'You want to clone this IVR Menu!',
      showCancelButton: true,
      confirmButtonText: 'Yes, clone it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        let currentUser = JSON.parse(localStorage.getItem('currentUser'));
        this.moduleservice.cloneIVR(id, currentUser.uuid).subscribe(res => {
          this.filter = [res];
          if (this.filter[0]['status'] == 'success') {
            this.loadIVRMenus();
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Success!', 'IVR Menu Clone Successfully.');
            setTimeout(() => {
              sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
            }, 2000);
            this.router.navigate(['/edit-ivr/' + this.filter[0]['uuid']]);
          } else {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Error', 'IVR Menu Clone failed.', 'error');
          }
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', '', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
        }, 2000);
      }
    });
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_7__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_6__.HttpBackend
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_5__.Router
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_8__.Title
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_9__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }]
  };
};
PredictiveRoutingComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_10__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_9__.Component)({
  selector: 'app-predictive-routing',
  template: _predictive_routing_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_predictive_routing_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], PredictiveRoutingComponent);


/***/ }),

/***/ 26516:
/*!**********************************************************!*\
  !*** ./src/app/modules/shortlist/shortlist.component.ts ***!
  \**********************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "ShortlistComponent": () => (/* binding */ ShortlistComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _shortlist_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./shortlist.component.html?ngResource */ 7693);
/* harmony import */ var _shortlist_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./shortlist.component.scss?ngResource */ 72746);
/* harmony import */ var _shortlist_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_shortlist_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../module.service */ 22947);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../global */ 27266);
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! moment */ 56908);
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(moment__WEBPACK_IMPORTED_MODULE_4__);
/* harmony import */ var datatables_net__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! datatables.net */ 84375);
/* harmony import */ var datatables_net__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(datatables_net__WEBPACK_IMPORTED_MODULE_5__);











const router = _angular_router__WEBPACK_IMPORTED_MODULE_6__.Router;
class DataTablesResponse {}
let ShortlistComponent = class ShortlistComponent {
  constructor(moduleservice, handler, fb) {
    this.moduleservice = moduleservice;
    this.fb = fb;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_3__.GlobalVariable.BASE_API_URL;
    this.numbers = '';
    this.ranges = {
      Today: [moment__WEBPACK_IMPORTED_MODULE_4__(), moment__WEBPACK_IMPORTED_MODULE_4__()],
      Yesterday: [moment__WEBPACK_IMPORTED_MODULE_4__().subtract(1, 'days'), moment__WEBPACK_IMPORTED_MODULE_4__().subtract(1, 'days')],
      'Last 7 Days': [moment__WEBPACK_IMPORTED_MODULE_4__().subtract(6, 'days'), moment__WEBPACK_IMPORTED_MODULE_4__()],
      'Last 30 Days': [moment__WEBPACK_IMPORTED_MODULE_4__().subtract(29, 'days'), moment__WEBPACK_IMPORTED_MODULE_4__()],
      'This Month': [moment__WEBPACK_IMPORTED_MODULE_4__().startOf('month'), moment__WEBPACK_IMPORTED_MODULE_4__().endOf('month')],
      'Last Month': [moment__WEBPACK_IMPORTED_MODULE_4__().subtract(1, 'month').startOf('month'), moment__WEBPACK_IMPORTED_MODULE_4__().subtract(1, 'month').endOf('month')]
    };
    this.dtOptions = {};
    this.submitted = false;
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_7__.HttpClient(handler);
    this.alwaysShowCalendars = true;
    this.keepCalendarOpeningWithRange = true;
    this.showRangeLabelOnInput = true;
    this.selected = {
      startDate: moment__WEBPACK_IMPORTED_MODULE_4__().startOf('day'),
      endDate: moment__WEBPACK_IMPORTED_MODULE_4__().endOf('day')
    };
  }
  ngOnInit() {
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.loadcalls();
  }
  get f() {
    return this.searchcallsform.controls;
  }
  loadcalls() {
    if ($.fn.DataTable.isDataTable(this.table.nativeElement)) {
      $(this.table.nativeElement).dataTable().fnDestroy();
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.dtOptions = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "pageLength": 20,
      "order": [[1, "desc"]],
      ajax: (dataTablesParameters, callback) => {
        this.http.post(this.ServerUrl + 'getshortlonglistnumbers/' + this.currentCompany.uuid + '/0', {
          'dataTablesParameters': dataTablesParameters,
          'number': this.numbers,
          'date': this.selected
        }, {}).subscribe(resp => {
          // console.log(resp); return false;
          this.alldata = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [{
        data: "number"
      }, {
        data: "forward_to"
      }, {
        data: "created_at"
      }]
    };
    this.dataTable = $(this.table.nativeElement);
    this.dataTable.dataTable(this.dtOptions);
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_7__.HttpBackend
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_8__.FormBuilder
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_9__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }]
  };
};
ShortlistComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_10__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_9__.Component)({
  selector: 'app-shortlist',
  template: _shortlist_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_shortlist_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], ShortlistComponent);


/***/ }),

/***/ 44321:
/*!**********************************************!*\
  !*** ./src/app/modules/sms/sms.component.ts ***!
  \**********************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "SmsComponent": () => (/* binding */ SmsComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _sms_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./sms.component.html?ngResource */ 275);
/* harmony import */ var _sms_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./sms.component.scss?ngResource */ 54633);
/* harmony import */ var _sms_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_sms_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../module.service */ 22947);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../global */ 27266);
/* harmony import */ var ngx_csv_ngx_csv__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ngx-csv/ngx-csv */ 94551);
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! moment */ 56908);
/* harmony import */ var moment__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(moment__WEBPACK_IMPORTED_MODULE_5__);
/* harmony import */ var datatables_net__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! datatables.net */ 84375);
/* harmony import */ var datatables_net__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(datatables_net__WEBPACK_IMPORTED_MODULE_6__);









//import 'sweetalert2/src/sweetalert2.scss'




const router = _angular_router__WEBPACK_IMPORTED_MODULE_7__.Router;
class DataTablesResponse {}
let SmsComponent = class SmsComponent {
  constructor(moduleservice, toastrService, handler, fb) {
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.fb = fb;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_3__.GlobalVariable.BASE_API_URL;
    this.sms = '';
    this.ranges = {
      Today: [moment__WEBPACK_IMPORTED_MODULE_5__(), moment__WEBPACK_IMPORTED_MODULE_5__()],
      Yesterday: [moment__WEBPACK_IMPORTED_MODULE_5__().subtract(1, 'days'), moment__WEBPACK_IMPORTED_MODULE_5__().subtract(1, 'days')],
      'Last 7 Days': [moment__WEBPACK_IMPORTED_MODULE_5__().subtract(6, 'days'), moment__WEBPACK_IMPORTED_MODULE_5__()],
      'Last 30 Days': [moment__WEBPACK_IMPORTED_MODULE_5__().subtract(29, 'days'), moment__WEBPACK_IMPORTED_MODULE_5__()],
      'This Month': [moment__WEBPACK_IMPORTED_MODULE_5__().startOf('month'), moment__WEBPACK_IMPORTED_MODULE_5__().endOf('month')],
      'Last Month': [moment__WEBPACK_IMPORTED_MODULE_5__().subtract(1, 'month').startOf('month'), moment__WEBPACK_IMPORTED_MODULE_5__().subtract(1, 'month').endOf('month')]
    };
    this.dtOptions = {};
    this.submitted = false;
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_8__.HttpClient(handler);
    this.alwaysShowCalendars = true;
    this.keepCalendarOpeningWithRange = true;
    this.showRangeLabelOnInput = true;
    this.selected = {
      startDate: moment__WEBPACK_IMPORTED_MODULE_5__().startOf('day'),
      endDate: moment__WEBPACK_IMPORTED_MODULE_5__().endOf('day')
    };
  }
  ngOnInit() {
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.loadcalls();
  }
  get f() {
    return this.searchcallsform.controls;
  }
  loadcalls() {
    if ($.fn.DataTable.isDataTable(this.table.nativeElement)) {
      $(this.table.nativeElement).dataTable().fnDestroy();
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    var that = this;
    this.dtOptions = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "pageLength": 20,
      "order": [[2, "desc"]],
      ajax: (dataTablesParameters, callback) => {
        that.http.post(this.ServerUrl + 'getsms/' + this.currentCompany.uuid, {
          'dataTablesParameters': dataTablesParameters,
          'sms': this.sms,
          'date': this.selected
        }, {}).subscribe(resp => {
          that.smses = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [{
        data: "sms_from"
      }, {
        data: "sms_to"
      }, {
        data: "time"
      }, {
        data: "message"
      }, {
        data: "source_network"
      }, {
        data: "date_received"
      }]
    };
    this.dataTable = $(this.table.nativeElement);
    this.dataTable.dataTable(this.dtOptions);
  }
  exportdata() {
    var options = {
      fieldSeparator: ',',
      quoteStrings: '"',
      decimalseparator: '.',
      showLabels: true,
      useBom: true,
      headers: ["From", "To", "Time", "Message", "Source Network", "Date Received"]
    };
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleservice.getsmsForExport(this.currentCompany.uuid).subscribe(res => {
      new ngx_csv_ngx_csv__WEBPACK_IMPORTED_MODULE_4__.ngxCsv(res.data, 'SMS Logs', options);
    }, error => this.error = error);
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_9__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_8__.HttpBackend
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_10__.FormBuilder
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_11__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }]
  };
};
SmsComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_12__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_11__.Component)({
  selector: 'app-sms',
  template: _sms_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_sms_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], SmsComponent);


/***/ }),

/***/ 5601:
/*!**************************************************!*\
  !*** ./src/app/modules/tasks/tasks.component.ts ***!
  \**************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "TasksComponent": () => (/* binding */ TasksComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _tasks_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./tasks.component.html?ngResource */ 13562);
/* harmony import */ var _tasks_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./tasks.component.scss?ngResource */ 16298);
/* harmony import */ var _tasks_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_tasks_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../../global */ 27266);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./../module.service */ 22947);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! sweetalert2 */ 60598);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(sweetalert2__WEBPACK_IMPORTED_MODULE_4__);
/* harmony import */ var rxjs__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! rxjs */ 92218);
/* harmony import */ var ngx_ui_loader__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! ngx-ui-loader */ 36413);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! @angular/platform-browser */ 34497);














class DataTablesResponse {}
let TasksComponent = class TasksComponent {
  constructor(renderer, moduleservice, toastrService, handler, fb, router, route, cdRef, ngxLoader, titleService) {
    this.renderer = renderer;
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.fb = fb;
    this.router = router;
    this.route = route;
    this.cdRef = cdRef;
    this.ngxLoader = ngxLoader;
    this.titleService = titleService;
    this.dtTrigger = new rxjs__WEBPACK_IMPORTED_MODULE_5__.Subject();
    this.dtOptions = {};
    this.dtOptionsPending = {
      dom: 'rt'
    };
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_2__.GlobalVariable.BASE_API_URL;
    this.pendingdata = [];
    this.completed = [];
    this.opendata = [];
    this.pfiltertype = 0;
    this.selecteddata = [];
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_6__.HttpClient(handler);
    window.addEventListener("click", event => {
      const el = document.getElementById('adjust_status');
      if (el) {
        let btn = document.getElementById("adjust_status");
        btn.addEventListener("click", e => this.adjust_status(0));
      }
      const el1 = document.getElementById('adjust_status_rej');
      if (el1) {
        let btn = document.getElementById("adjust_status_rej");
        btn.addEventListener("click", e => this.adjust_status(1));
      }
    });
    this.loader = {
      loaderId: 'customLoaderId',
      loaderId1: 'customLoaderId1'
    };
  }
  ngOnInit() {
    this.loadtasks();
  }
  loadtasks() {
    // if ($.fn.DataTable.isDataTable(this.table) ) {
    //   $($('.dt').dataTable().fnDestroy());
    // }    
    this.ngxLoader.startLoader('customLoaderId');
    this.ngxLoader.startLoader('customLoaderId1');
    let currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.http.post(this.ServerUrl + 'loadtasks/' + currentCompany.uuid, {}).subscribe(resp => {
      const result = resp.data.filter(s => s.status == 0);
      const result1 = resp.data.filter(s => s.status == 1 || s.status == 2);
      const result2 = resp.data.filter(s => s.status == 3);
      // this.pendingdata = result;             
      this.completed = result1;
      this.opendata = result;
      this.dtTrigger.next();
      this.ngxLoader.stopLoader('customLoaderId');
      this.ngxLoader.stopLoader('customLoaderId1');
    }, error => this.error = error);
  }
  getParticipationType(type) {
    $('.appendedtable').remove();
    if (type == 0) {
      $("#tabs2").removeClass("btn btn-primary btn-sm camactivetab");
      $("#tabs3").removeClass("btn btn-primary btn-sm camactivetab");
      $("#tabs1").addClass("camactivetab");
      this.pfiltertype = 0;
      this.loadtasks();
    }
    if (type == 1) {
      $("#tabs1").removeClass("btn btn-primary btn-sm camactivetab");
      $("#tabs3").removeClass("btn btn-primary btn-sm camactivetab");
      $("#tabs2").addClass("camactivetab");
      this.pfiltertype = 1;
      this.loadtasks();
    }
    if (type == 2) {
      $("#tabs1").removeClass("btn btn-primary btn-sm camactivetab");
      $("#tabs2").removeClass("btn btn-primary btn-sm camactivetab");
      $("#tabs3").addClass("camactivetab");
      this.pfiltertype = 2;
      this.loadtasks();
    }
  }
  reqdata(details) {
    this.parreqdata = details;
  }
  adjust_status(i) {
    // console.log(this.selecteddata);
    let currentuser = JSON.parse(localStorage.getItem('currentUser'));
    let status;
    if (i == 0) {
      status = "Approve";
    }
    if (i == 1) {
      status = "Reject";
    }
    sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire({
      title: 'Are you sure ?',
      text: 'You want to ' + status + ' request to adjust conversion',
      showCancelButton: true,
      confirmButtonText: 'Yes, ' + status + ' it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        this.moduleservice.approvepayoutstatus(this.selecteddata, currentuser.uuid, i).subscribe(res => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Approved!', 'Payout request ' + status + ' successfully.');
          this.loadtasks();
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
          }, 2000);
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().fire('Cancelled', 'Your Record is safe :)');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_4___default().close();
        }, 2000);
      }
    });
  }
  details(i, data) {
    this.selecteddata = data;
    let calldata = JSON.parse(data.calldata);
    var date = new Date(0);
    date.setSeconds(calldata.duration);
    var timeString = date.toISOString().substring(11, 19);
    // console.log(timeString)
    var tr = $('details-control').closest('tr').eq(i);
    // var divClass = $(".detailrow_"+i).eq(0).attr('class'); 
    var divClass1 = $('#home_' + i).attr('class');
    $('.appendedtable').remove();
    // console.log(divClass1);
    // if (divClass.indexOf('shown') > -1) {
    if (divClass1 != undefined) {
      $(".appendedtbl_" + i).remove();
      $(".detailrow_" + i).removeClass('shown');
    } else {
      var actions = '';
      if (data.status == 0) {
        actions += '<div class="">' + '<button id="adjust_status" class="btn btn-sm btn-primary">Approve</button>' + '<button id="adjust_status_rej" class="ml-2 btn btn-sm btn-danger">Reject</button>' + '</div>';
      }
      var payout = "-";
      if (data.payout != "") {
        payout = '$' + data.payout;
      }
      var revenue = "-";
      if (data.revenue != "") {
        revenue = '$' + data.revenue;
      }
      let recording = "-";
      if (calldata.recording != null) {
        recording = "";
        recording += '<audio style="width: 130px;height: 30px;" controls muted loop><source src="https://d2actkasrcrrs8.cloudfront.net/' + calldata.recording + '" type="audio/mp3"></audio>';
      }
      var campaignsdata = '<div class="">' + '<div class="mt-2 mb-2">' + '<div class="row" style="border-bottom: 1px solid #403f3f;">' + '<div class="col-md-2">' + '<h6 style="font-size:13px;padding: 2px;">Task Details</h6>' + '</div>' + '<div class="col-md-9"></div>' + '<div class="col-md-1 text-right">' +
      // '<button class="btn btn-sm btn-danger" onClick="closeref('+i+')">Close</button>'+
      '</div>' + '</div>' + '</div>' + '<table class="table  table-striped targetreferencetable" style="width: 50%;">' + '<tr style="background: #24293a!important;">' + '<th>Requested Payout</th>' + '<th>Requested Revenue</th>' + '<th>Reason For Request</th>' + '</tr>' + '<tr style="background: #252d48!important;">' + '<td>' + payout + '</td>' + '<td>' + revenue + '</td>' + '<td>' + data.reason + '</td>' + '</tr>' + '</table>' + '<div class="mt-2 mb-2" style="border-bottom: 1px solid #403f3f;">' + '<h6 style="font-size:13px;padding: 2px;">Call Details</h6>' + '</div>' + '<table class="table table-striped targetreferencetable">' + '<tr style="background: #24293a!important;">' + '<th>Call Date</th>' + '<th>Campaign</th>' + '<th>Caller ID</th>' + '<th>Buyer</th>' + '<th>Target</th>' + '<th>Call Revenue</th>' + '<th>Publisher</th>' + '<th>Call Payout</th>' + '<th>Call Duration</th>' + '<th>Recording</th>' + '</tr>' + '<tr style="background: #252d48!important;">' + '<td>' + calldata.start_stamp + '</td>' + '<td>' + calldata.campaign_name + '</td>' + '<td>' + calldata.caller_id_number + '</td>' + '<td>' + calldata.buyer_name + '</td>' + '<td>' + calldata.target_name + '</td>' + '<td>' + calldata.revenue + '</td>' + '<td>' + calldata.publisher_name + '</td>' + '<td>' + calldata.payout + '</td>' + '<td>' + timeString + '</td>' + '<td>' + recording + '</td>' + '</tr>' + '</table>' + actions + '</div>';
      var taskhistory = "";
      if (data.status == 1 || data.status == 2) {
        taskhistory += '<section class="section" style="width:0"><div class="section-body"><div class="mt-4" style="border-bottom:1px solid #403f3f"><h6 style="font-size:13px;padding:2px">Task History</h6></div><div class="row"><div class="col-12"><div class="activities"><div class="activity mt-2"><div class="activity-icon bg-blue text-white"><i class="fas fa-info"></i></div><div class="activity-detail" style="width:35%!important"><span class="">' + data.created_at + '</span><br><span class="text-primary">Request started by ' + data.from + '</span><div class="row" style="background:#192034!important"><div class="col-md-6">Conversion Payout Adjustment Requested</div><div class="col-md-6">' + data.payout + '</div></div><div class="row"><div class="col-md-6">Conversion Revenue Adjustment Requested</div><div class="col-md-6">' + data.revenue + '</div></div><div class="row" style="background:#192034!important"><div class="col-md-6" >Reason</div><div class="col-md-6">' + data.reason + '</div></div><div class="row"><div class="col-md-6">Call Conversion Payout Amount</div><div class="col-md-6">' + Number(calldata.payout) + '</div></div><div class="row" style="background:#192034!important"><div class="col-md-6">Call Conversion Revenue Amount</div><div class="col-md-6">' + Number(calldata.revenue) + '</div></div></div></div><div class="activity"><div class="activity-icon bg-success text-white"><i class="fas fa-check"></i></div><div class="activity-detail" style="width:35%!important"><div class="mb-2"><span class="">' + data.approved_at + '</span><br><span class="text-primary">Request to adjust revenue is approved by ' + data.approver + '</span></div><div class="row" style="background:#192034!important"><div class="col-md-6">Revenue Adjusted</div><div class="col-md-6">' + Number(calldata.revenue) + '</div></div><div class="row"><div class="col-md-6">Payout Adjusted</div><div class="col-md-6">' + Number(calldata.payout) + '</div></div></div></div></div></div></div></div></section>';
      }
      $(".detailrow_" + i).after('<div class="appendedtable appendedtbl_' + i + '">' + '<div class="tab-content">' + '<div id="home_' + i + '" class="tab-pane fade in active show">' + '<section class="section" style="width: 0px;">' + '<div class="section-body">' + '<div class="activities1" style="margin-left: 11px;display: block;width: 1553px!important;">' + campaignsdata + taskhistory + '</span>' + '</div>' + '</section> ' + '</div>' + '</div>' + '</div>');
      tr.addClass('shown');
    }
  }
  static #_ = this.ctorParameters = () => [{
    type: _angular_core__WEBPACK_IMPORTED_MODULE_7__.Renderer2
  }, {
    type: _module_service__WEBPACK_IMPORTED_MODULE_3__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_8__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_6__.HttpBackend
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_9__.FormBuilder
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_10__.Router
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_10__.ActivatedRoute
  }, {
    type: _angular_core__WEBPACK_IMPORTED_MODULE_7__.ChangeDetectorRef
  }, {
    type: ngx_ui_loader__WEBPACK_IMPORTED_MODULE_11__.NgxUiLoaderService
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_12__.Title
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_7__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }]
  };
};
TasksComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_13__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_7__.Component)({
  selector: 'app-tasks',
  template: _tasks_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_tasks_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], TasksComponent);


/***/ }),

/***/ 21178:
/*!**************************************************************************************!*\
  !*** ./src/app/modules/verification-management/verification-management.component.ts ***!
  \**************************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "VerificationManagementComponent": () => (/* binding */ VerificationManagementComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _verification_management_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./verification-management.component.html?ngResource */ 29389);
/* harmony import */ var _verification_management_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./verification-management.component.scss?ngResource */ 58232);
/* harmony import */ var _verification_management_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_verification_management_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../module.service */ 22947);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/router */ 60124);








let VerificationManagementComponent = class VerificationManagementComponent {
  constructor(fb, toastrService, moduleService, router) {
    this.fb = fb;
    this.toastrService = toastrService;
    this.moduleService = moduleService;
    this.router = router;
    this.controlEnabled = true;
    this.show = false;
    this.data = {};
    this.thenvalue = 'FORWARD_TO';
    this.rowcount = 0;
    this.submitted = false;
    this.EmailSubmitted = false;
    this.editEmailSubmitted = false;
    // WildCard Add Model
    this.WildcardSubmitted = false;
    this.editWildcardSubmitted = false;
  }
  ngOnInit() {
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    // console.log(this.initItemRow());
    this.addForm = this.fb.group({
      name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_3__.Validators.required],
      itemRows: this.fb.array([])
    });
    this.addEmailForm = this.fb.group({
      email: ['', [_angular_forms__WEBPACK_IMPORTED_MODULE_3__.Validators.required, _angular_forms__WEBPACK_IMPORTED_MODULE_3__.Validators.email]]
    });
    this.editEmailForm = this.fb.group({
      uuid: ['', ''],
      email: ['', [_angular_forms__WEBPACK_IMPORTED_MODULE_3__.Validators.required, _angular_forms__WEBPACK_IMPORTED_MODULE_3__.Validators.email]]
    });
    this.addWildcardForm = this.fb.group({
      name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_3__.Validators.required],
      notes: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_3__.Validators.required]
    });
    this.editWildcardForm = this.fb.group({
      uuid: ['', ''],
      name: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_3__.Validators.required],
      notes: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_3__.Validators.required]
    });
    // $('#thenselect_0').hide();
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleService.getRules(this.currentCompany.uuid).subscribe(res => {
      this.rulesdata = res.rule_data;
    }, error => this.error = error);
    this.moduleService.GetIVRnamedata(this.currentCompany.uuid).subscribe(res => {
      this.ivrnamedata = res.ivr_data;
    }, error => this.error = error);
    if (this.currentCompany.uuid) {
      this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
      this.moduleService.getverificationruledata(this.currentCompany.uuid).subscribe(res => {
        const control = this.addForm.controls['itemRows'];
        for (let index = 0; index < res.ruleset_data.length; index++) {
          control.push(this.initItemRow());
          control.controls[index].get('ifval').setValue(res.ruleset_data[index].rule_condition_type);
          control.controls[index].get('isval').setValue(res.ruleset_data[index].rule_condition_is_value);
          if (res.ruleset_data[index].then_condition_action == 'FORWARD_TO_IVR_MENU') {
            control.controls[index].get('thenselect').setValue(res.ruleset_data[index].then_condition_value);
            this.data[index] = 'FORWARD_TO_IVR_MENU';
          } else {
            control.controls[index].get('thentxt').setValue(res.ruleset_data[index].then_condition_value);
            this.data[index] = 'FORWARD_TO';
          }
          // control.controls[index].get('thenval').setValue(res.ruleset_data[index].then_condition_action);    
        }

        console.log(res);
        this.result = res.ruleset_data;
      });
    }
    this.getEmail();
    this.getWildcard();
  }
  editWildcard(uuid, name, notes) {
    this.editWildcardForm.patchValue({
      uuid: uuid,
      name: name,
      notes: notes
    });
  }
  editEmail(uuid, email) {
    this.editEmailForm.patchValue({
      uuid: uuid,
      email: email
    });
  }
  getEmail() {
    this.moduleService.GetEmails(this.currentCompany.uuid).subscribe(res => {
      this.emaildata = res.email_data;
      //  console.log(res); return false;
    }, error => this.error = error);
  }
  getWildcard() {
    this.moduleService.getWildcard(this.currentCompany.uuid).subscribe(res => {
      this.wildcarddata = res.data;
      //  console.log(res); return false;
    }, error => this.error = error);
  }
  thenval(event, count) {
    if (event.target.value == 'FORWARD_TO_IVR_MENU') {
      $('#thentxt_' + count).hide();
      $('#thenselect_' + count).show();
      this.thenvalue = event.target.value;
    } else {
      $('#thentxt_' + count).show();
      $('#thenselect_' + count).hide();
    }
  }
  get f() {
    return this.addForm.controls;
  }
  onSubmit() {
    this.submitted = true;
    // if (this.addForm.invalid) {
    //     return;
    // }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    // console.log(this.addForm.value);return false;
    this.moduleService.addVerificationRuleSet(this.addForm.value, this.currentCompany.uuid).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Verification Rules Saved Successfully');
      } else {
        this.toastrService.error('Failed To Add');
      }
    }, error => this.error = error);
  }
  initItemRow() {
    return this.fb.group({
      ifval: ['NUMBER', ''],
      isval: ['', ''],
      thenval: ['FORWARD_TO', ''],
      thentxt: ['', ''],
      thenselect: ['', ''],
      andval: ['STOP', '']
    });
  }
  addRow(length) {
    // alert(length);
    // length = length-1;
    const control = this.addForm.controls['itemRows'];
    control.push(this.initItemRow());
    this.data[length] = 'FORWARD_TO';
    // this.data[length]='FORWARD_TO'; 
    // $('#thenselect_'+length).hide();
    // alert($('#thenselect_0').val());    
  }

  deleteRow(index) {
    const control = this.addForm.controls['itemRows'];
    if (control != null) {
      this.totalrow = control.value.length;
    }
    if (this.totalrow) {
      control.removeAt(index);
    }
  }
  get Emailcontrol() {
    return this.addEmailForm.controls;
  }
  onEmailSubmit() {
    // const formData = new FormData();      
    this.EmailSubmitted = true;
    if (this.addEmailForm.invalid) {
      return;
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleService.addEmail(this.addEmailForm.value, this.currentCompany.uuid).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Email Added Successfully');
        this.getEmail();
      } else {
        this.toastrService.error('Failed To Add');
      }
    }, error => this.error = error);
  }
  get editEmailcontrol() {
    return this.editEmailForm.controls;
  }
  oneditEmailSubmit() {
    this.editEmailSubmitted = true;
    if (this.editEmailForm.invalid) {
      return;
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleService.editEmail(this.editEmailForm.value, this.currentCompany.uuid).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Email Updated Successfully');
        this.getEmail();
      } else {
        this.toastrService.error('Failed To Add');
      }
    }, error => this.error = error);
  }
  closeModal() {
    if (this.addWildcardForm.get('name').value && this.addWildcardForm.get('notes').value) {
      $("#addWildcard").modal("hide");
      setTimeout(() => {
        this.WildcardSubmitted = false;
        this.addWildcardForm.reset();
      }, 2000);
    }
    if (this.editWildcardForm.get('name').value && this.editWildcardForm.get('notes').value) {
      $("#editwildcard").modal("hide");
      setTimeout(() => {
        this.editWildcardSubmitted = false;
        this.editWildcardForm.reset();
      }, 1000);
    }
    if (this.addEmailForm.get('email').value) {
      $("#addLabels").modal("hide");
      setTimeout(() => {
        this.EmailSubmitted = false;
        this.addEmailForm.reset();
      }, 2000);
    }
    if (this.editEmailForm.get('email').value) {
      $("#editmail").modal("hide");
      setTimeout(() => {
        this.editEmailSubmitted = false;
        this.editEmailForm.reset();
      }, 2000);
    }
  }
  get wildcardcontrol() {
    return this.addWildcardForm.controls;
  }
  onwildcardSubmit() {
    // const formData = new FormData();      
    this.WildcardSubmitted = true;
    if (this.addWildcardForm.invalid) {
      return;
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleService.addWildcard(this.addWildcardForm.value, this.currentCompany.uuid).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('New Verification Wildcard Added Successfully');
        this.getWildcard();
      } else {
        this.toastrService.error('Failed To Add');
      }
    }, error => this.error = error);
  }
  get editwildcardcontrol() {
    return this.editWildcardForm.controls;
  }
  onupdatewildcardSubmit() {
    // const formData = new FormData();      
    this.editWildcardSubmitted = true;
    if (this.editWildcardForm.invalid) {
      return;
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleService.editWildcard(this.editWildcardForm.value, this.currentCompany.uuid).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Verification Wildcard Updated Successfully');
        this.getWildcard();
      } else {
        this.toastrService.error('Failed To Add');
      }
    }, error => this.error = error);
  }
  _keyPress(event) {
    const isNumericInput = event => {
      const key = event.keyCode;
      return key >= 48 && key <= 57 ||
      // Allow number line
      key >= 96 && key <= 105 // Allow number pad
      ;
    };

    const isModifierKey = event => {
      const key = event.keyCode;
      return event.shiftKey === true || key === 35 || key === 36 ||
      // Allow Shift, Home, End
      key === 8 || key === 9 || key === 13 || key === 46 ||
      // Allow Backspace, Tab, Enter, Delete
      key > 36 && key < 41 ||
      // Allow left, up, right, down

      // Allow Ctrl/Command + A,C,V,X,Z
      (event.ctrlKey === true || event.metaKey === true) && (key === 65 || key === 67 || key === 86 || key === 88 || key === 90);
    };
    const enforceFormat = event => {
      // Input must be of a valid number format or a modifier key, and not longer than ten digits
      if (!isNumericInput(event) && !isModifierKey(event)) {
        event.preventDefault();
      }
    };
    const formatToPhone = event => {
      if (isModifierKey(event)) {
        return;
      }
      const target = event.target;
      const input = event.target.value.replace(/\D/g, '').substring(0, 10); // First ten digits of input only
      const zip = input.substring(0, 3);
      const middle = input.substring(3, 6);
      const last = input.substring(6, 10);
      if (input.length > 6) {
        target.value = `(${zip}) ${middle} - ${last}`;
      } else if (input.length > 3) {
        target.value = `(${zip}) ${middle}`;
      } else if (input.length > 0) {
        target.value = `(${zip}`;
      }
    };
    // const inputElement = document.getElementById('number');
    const inputElement = document.getElementsByClassName('number');
    if (inputElement) {
      for (let i = 0; i < inputElement.length; i++) {
        inputElement[i].addEventListener('keydown', enforceFormat);
        inputElement[i].addEventListener('keyup', formatToPhone);
      }
    }
  }
  static #_ = this.ctorParameters = () => [{
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_3__.FormBuilder
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_4__.ToastrService
  }, {
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_5__.Router
  }];
};
VerificationManagementComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_6__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_7__.Component)({
  selector: 'app-verification-management',
  template: _verification_management_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_verification_management_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], VerificationManagementComponent);


/***/ }),

/***/ 29032:
/*!**********************************************************!*\
  !*** ./src/app/modules/voicemail/voicemail.component.ts ***!
  \**********************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "VoicemailComponent": () => (/* binding */ VoicemailComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _voicemail_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./voicemail.component.html?ngResource */ 35200);
/* harmony import */ var _voicemail_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./voicemail.component.scss?ngResource */ 59923);
/* harmony import */ var _voicemail_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_voicemail_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../module.service */ 22947);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! sweetalert2 */ 60598);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(sweetalert2__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../global */ 27266);
/* harmony import */ var ngx_csv_ngx_csv__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ngx-csv/ngx-csv */ 94551);
/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/platform-browser */ 34497);








//import 'sweetalert2/src/sweetalert2.scss'




const router = _angular_router__WEBPACK_IMPORTED_MODULE_6__.Router;
class DataTablesResponse {}
let VoicemailComponent = class VoicemailComponent {
  constructor(moduleservice, toastrService, router, handler, titleService) {
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.router = router;
    this.titleService = titleService;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_4__.GlobalVariable.BASE_API_URL;
    this.SiteUrl = _global__WEBPACK_IMPORTED_MODULE_4__.GlobalVariable.BASE_URL;
    this.dtOptions = {};
    this.ischecked = '1';
    this.checkboxes = [];
    this.filter = [];
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_7__.HttpClient(handler);
  }
  setTitle(newTitle) {
    this.titleService.setTitle(newTitle);
  }
  ngOnInit() {
    this.setTitle('Voicemail');
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.loadTargets();
  }
  loadTargets() {
    // console.log('ok');
    // return false;
    if ($.fn.DataTable.isDataTable(this.table.nativeElement)) {
      $(this.table.nativeElement).dataTable().fnDestroy();
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentUser'));
    this.currentUser = JSON.parse(localStorage.getItem('currentUser'));
    this.dtOptions = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "pageLength": 20,
      "lengthMenu": [[-1, 20, 50, 100, 500, 2000, 5000], ["All", 20, 50, 100, 500, 2000, 5000]],
      "order": [[1, "asc"]],
      ajax: (dataTablesParameters, callback) => {
        this.http.post(this.ServerUrl + 'getvoicemails/' + this.currentCompany.uuid + '/' + this.currentUser.timezone, dataTablesParameters, {}).subscribe(resp => {
          this.numbers = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [{
        data: "created_epoch"
      }, {
        data: "cid_number"
      }, {
        data: "file_path"
      }, {
        data: "campaign"
      }]
    };
    this.dataTable = $(this.table.nativeElement);
    this.dataTable.dataTable(this.dtOptions);
  }
  checkalldelete(event) {
    const checked = event.target.checked;
    this.numbers.forEach(chkbox => chkbox.selected = checked);
  }
  deleteselected(event) {
    // $("#customCheck1").prop("checked", false);    
    if (event.target.checked == true) {
      if (event.target.value == 'on') {
        this.checkboxes = [];
        this.numbers.forEach(lbl => {
          this.checkboxes.push(lbl.id);
        });
      } else {
        if (this.checkboxes.length + 1 == this.numbers.length) {
          $("#customCheck1").prop("checked", true);
        }
        this.checkboxes.push(event.target.value);
      }
      this.ischecked = '0';
    } else {
      // console.log(this.checkboxes);      
      if (this.checkboxes.length != 0) {
        $("#customCheck1").prop("checked", false);
      }
      if (event.target.value != 'on') {
        const index = this.checkboxes.indexOf(event.target.value);
        this.checkboxes.splice(index, 1);
      } else {
        this.checkboxes = [];
      }
      this.ischecked = '1';
    }
    // console.log(this.checkboxes); 
  }

  onDeleteSubmit() {
    if (this.checkboxes.length == 0) {
      this.toastrService.error('Please Select Row To Delete');
    } else {
      // console.log(this.checkboxes);  
      sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
        title: 'Are you sure?',
        text: 'You want to Delete Selected Record!',
        showCancelButton: true,
        confirmButtonText: 'Yes, delete it!',
        cancelButtonText: 'No, keep it'
      }).then(result => {
        if (result.value) {
          this.moduleservice.deleteSelectedNumbers(this.checkboxes).subscribe(res => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Records Deleted Successfully.');
            setTimeout(() => {
              sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
            }, 2000);
            this.loadTargets();
          }, error => this.error = error);
        } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
        }
      });
    }
  }
  Delete(id) {
    sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
      title: 'Are you sure?',
      text: 'You want to Delete Record!',
      showCancelButton: true,
      confirmButtonText: 'Yes, delete it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        let currentUser = JSON.parse(localStorage.getItem('currentUser'));
        this.moduleservice.deleteNumber(id, currentUser.uuid).subscribe(res => {
          this.loadTargets();
          // this.toastrService.success('Number Deleted Successfully');
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Record Deleted Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
        }, 2000);
      }
    });
  }
  Clone(id) {
    sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
      title: 'Are you sure?',
      text: 'You want to clone this target!',
      showCancelButton: true,
      confirmButtonText: 'Yes, clone it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        let currentUser = JSON.parse(localStorage.getItem('currentUser'));
        let currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
        this.moduleservice.cloneNumber(id, currentUser.uuid, currentCompany.uuid).subscribe(res => {
          this.filter = [res];
          if (this.filter[0]['status'] == 'success') {
            this.loadTargets();
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Success!', 'Target Clone Successfully.');
            setTimeout(() => {
              sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
            }, 2000);
            this.router.navigate(['/edit-numbers/' + this.filter[0]['uuid']]);
          } else {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Error', 'Target Clone failed.', 'error');
          }
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', '', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
        }, 2000);
      }
    });
  }
  exportdata() {
    var options = {
      fieldSeparator: ',',
      quoteStrings: '"',
      decimalseparator: '.',
      showLabels: true,
      // showTitle: true,
      // title: 'Your title',
      useBom: true,
      // noDownload: true,
      headers: ["Number", "FSL Rule Name", "Rule Set", "Note", "Associated abel", "Created At"]
    };
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleservice.getNumberForExport(this.currentCompany.uuid, "all").subscribe(res => {
      console.log(res);
      new ngx_csv_ngx_csv__WEBPACK_IMPORTED_MODULE_5__.ngxCsv(res, 'All Targets', options);
    }, error => this.error = error);
  }
  change_status(event, tagetUuid) {
    this.status = event.target.checked;
    let activestatus, activestring;
    if (this.status == true) {
      activestatus = 1;
      activestring = "Activate";
    } else {
      activestatus = 0;
      activestring = "De-activate";
    }
    // alert(activestatus); return
    sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
      title: 'Are you sure?',
      text: 'You want to ' + activestring + ' Target!',
      showCancelButton: true,
      confirmButtonText: 'Yes, ' + activestring + ' it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        let currentUser = JSON.parse(localStorage.getItem('currentUser'));
        this.moduleservice.changeTargetStatus(activestatus, currentUser.uuid, tagetUuid).subscribe(res => {
          this.loadTargets();
          // this.toastrService.success('Number Deleted Successfully');
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Changed!', 'Target ' + activestring + ' Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
        }, 2000);
        this.loadTargets();
        return;
      }
    });
  }
  play(url, incomingnumber) {
    this.toastrService.show(`<audio style="width: 232px;height: 30px;" controls><source src="${url}" type="audio/mp3"></audio>`, 'Callerid Number # - ' + incomingnumber, {
      closeButton: true,
      extendedTimeOut: 0,
      timeOut: 0,
      tapToDismiss: false,
      enableHtml: true,
      positionClass: 'toast-bottom-right'
    });
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_8__.ToastrService
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_6__.Router
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_7__.HttpBackend
  }, {
    type: _angular_platform_browser__WEBPACK_IMPORTED_MODULE_9__.Title
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_10__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }]
  };
};
VoicemailComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_11__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_10__.Component)({
  selector: 'app-voicemail',
  template: _voicemail_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_voicemail_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], VoicemailComponent);


/***/ }),

/***/ 45520:
/*!**********************************************************!*\
  !*** ./src/app/modules/whitelist/whitelist.component.ts ***!
  \**********************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "WhitelistComponent": () => (/* binding */ WhitelistComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _whitelist_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./whitelist.component.html?ngResource */ 569);
/* harmony import */ var _whitelist_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./whitelist.component.scss?ngResource */ 25153);
/* harmony import */ var _whitelist_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_whitelist_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/forms */ 2508);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _module_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./../module.service */ 22947);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var ngx_toastr__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ngx-toastr */ 94817);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! sweetalert2 */ 60598);
/* harmony import */ var sweetalert2__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(sweetalert2__WEBPACK_IMPORTED_MODULE_3__);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../global */ 27266);









//import 'sweetalert2/src/sweetalert2.scss'


const router = _angular_router__WEBPACK_IMPORTED_MODULE_5__.Router;
class DataTablesResponse {}
let WhitelistComponent = class WhitelistComponent {
  constructor(moduleservice, toastrService, handler, fb) {
    this.moduleservice = moduleservice;
    this.toastrService = toastrService;
    this.fb = fb;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_4__.GlobalVariable.BASE_API_URL;
    this.dtOptions = {};
    this.ischecked = '1';
    this.numberSubmitted = false;
    this.numbereditSubmitted = false;
    this.checkboxes = [];
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_6__.HttpClient(handler);
  }
  ngOnInit() {
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
    this.loadnumbers();
    this.addNumberForm = this.fb.group({
      number: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required]
    });
    this.editNumberForm = this.fb.group({
      uuid: ['', ''],
      number: ['', _angular_forms__WEBPACK_IMPORTED_MODULE_7__.Validators.required]
    });
  }
  loadnumbers() {
    if ($.fn.DataTable.isDataTable(this.table.nativeElement)) {
      $(this.table.nativeElement).dataTable().fnDestroy();
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    var that = this;
    this.dtOptions = {
      "pagingType": 'full_numbers',
      "processing": true,
      "serverSide": true,
      "pageLength": 20,
      "order": [[0, "desc"]],
      ajax: (dataTablesParameters, callback) => {
        that.http.post(this.ServerUrl + 'getlistnumbers/1/' + this.currentCompany.uuid, dataTablesParameters, {}).subscribe(resp => {
          // console.log(resp);
          that.numbers = resp.data;
          callback({
            recordsTotal: resp.recordsTotal,
            recordsFiltered: resp.recordsFiltered,
            data: []
          });
        });
      },
      columns: [{
        data: "checkall"
      }, {
        data: "number"
      }, {
        data: "created_at"
      }, {
        data: "action"
      }],
      columnDefs: [{
        "targets": [0, 3],
        "orderable": false
      }]
    };
    this.dataTable = $(this.table.nativeElement);
    this.dataTable.dataTable(this.dtOptions);
  }
  Delete(uuid) {
    // alert(uuid);
    sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
      title: 'Are you sure?',
      text: 'You want to Delete Record!',
      showCancelButton: true,
      confirmButtonText: 'Yes, delete it!',
      cancelButtonText: 'No, keep it'
    }).then(result => {
      if (result.value) {
        this.moduleservice.deleteListNumber(uuid, 1).subscribe(res => {
          // console.log(res);return false;
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Record Deleted Successfully.');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
          this.loadnumbers();
        }, error => this.error = error);
      } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
        sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
        setTimeout(() => {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
        }, 2000);
      }
    });
  }
  //Add Labels
  get numbercontrol() {
    return this.addNumberForm.controls;
  }
  onNumberSubmit() {
    const formData = new FormData();
    this.numberSubmitted = true;
    if (this.addNumberForm.invalid) {
      return;
    }
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    // console.log(this.currentCompany); return false;
    formData.append('company_uuid', this.currentCompany.uuid);
    formData.append('number', this.addNumberForm.get('number').value);
    formData.append('type', '1');
    this.moduleservice.addNumberlist(formData).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Number Added Successfully');
      } else {
        this.toastrService.error('Failed To Add Label');
      }
    }, error => this.error = error);
  }
  closeModal() {
    //  alert(this.addLabelForm.get('name').value);
    if (this.addNumberForm.get('number').value) {
      $("#addNumber").modal("hide");
      this.loadnumbers();
      setTimeout(() => {
        // this.addLabelForm.reset();
        this.numberSubmitted = false;
        this.addNumberForm.reset();
        // $(this).find('#addLabel').trigger('reset');
      }, 2000);
    }
    if (this.editNumberForm.get('number').value) {
      $("#editNumber").modal("hide");
      setTimeout(() => {
        this.numbereditSubmitted = false;
        this.editNumberForm.reset();
        this.loadnumbers();
      }, 2000);
    }
  }
  // Edit Label
  editNumber(uuid, number) {
    this.editNumberForm.patchValue({
      uuid: uuid,
      number: number
    });
  }
  get numbereditcontrol() {
    return this.editNumberForm.controls;
  }
  onNumberEditSubmit() {
    const formData = new FormData();
    this.numbereditSubmitted = true;
    if (this.editNumberForm.invalid) {
      return;
    }
    formData.append('number', this.editNumberForm.get('number').value);
    formData.append('type', '1');
    this.moduleservice.editNumberList(formData, this.editNumberForm.get('uuid').value).subscribe(res => {
      // console.log(res); return false;
      if (res.status !== 'error') {
        this.toastrService.success('Black List Number Saved Successfully');
      } else {
        this.toastrService.error('Failed To Save Black List Number Data');
      }
    }, error => this.error = error);
  }
  _keyPress(event) {
    const isNumericInput = event => {
      const key = event.keyCode;
      return key >= 48 && key <= 57 ||
      // Allow number line
      key >= 96 && key <= 105 // Allow number pad
      ;
    };

    const isModifierKey = event => {
      const key = event.keyCode;
      return event.shiftKey === true || key === 35 || key === 36 ||
      // Allow Shift, Home, End
      key === 8 || key === 9 || key === 13 || key === 46 ||
      // Allow Backspace, Tab, Enter, Delete
      key > 36 && key < 41 ||
      // Allow left, up, right, down

      // Allow Ctrl/Command + A,C,V,X,Z
      (event.ctrlKey === true || event.metaKey === true) && (key === 65 || key === 67 || key === 86 || key === 88 || key === 90);
    };
    const enforceFormat = event => {
      // Input must be of a valid number format or a modifier key, and not longer than ten digits
      if (!isNumericInput(event) && !isModifierKey(event)) {
        event.preventDefault();
      }
    };
    const formatToPhone = event => {
      if (isModifierKey(event)) {
        return;
      }
      const target = event.target;
      const input = event.target.value.replace(/\D/g, '').substring(0, 10); // First ten digits of input only
      const zip = input.substring(0, 3);
      const middle = input.substring(3, 6);
      const last = input.substring(6, 10);
      if (input.length > 6) {
        target.value = `(${zip}) ${middle} - ${last}`;
      } else if (input.length > 3) {
        target.value = `(${zip}) ${middle}`;
      } else if (input.length > 0) {
        target.value = `(${zip}`;
      }
    };
    const number = document.getElementById('number');
    const editnumber = document.getElementById('editnumber');
    if (number) {
      number.addEventListener('keydown', enforceFormat);
      number.addEventListener('keyup', formatToPhone);
    }
    if (editnumber) {
      editnumber.addEventListener('keydown', enforceFormat);
      editnumber.addEventListener('keyup', formatToPhone);
    }
  }
  // Check Delete
  checkalldelete(event) {
    const checked = event.target.checked;
    this.numbers.forEach(chkbox => chkbox.selected = checked);
  }
  deleteselected(event) {
    if (event.target.checked == true) {
      if (event.target.value == 'on') {
        this.checkboxes = [];
        this.numbers.forEach(lbl => {
          this.checkboxes.push(lbl.id);
        });
      } else {
        if (this.checkboxes.length + 1 == this.numbers.length) {
          $("#customCheck1").prop("checked", true);
        }
        this.checkboxes.push(event.target.value);
      }
      this.ischecked = '0';
    } else {
      // console.log(this.checkboxes);      
      if (this.checkboxes.length != 0) {
        $("#customCheck1").prop("checked", false);
      }
      if (event.target.value != 'on') {
        const index = this.checkboxes.indexOf(event.target.value);
        this.checkboxes.splice(index, 1);
      } else {
        this.checkboxes = [];
      }
      this.ischecked = '1';
    }
    // console.log(this.checkboxes); 
  }

  onDeleteSubmit() {
    if (this.checkboxes.length == 0) {
      this.toastrService.error('Please Select Row To Delete');
    } else {
      // console.log(this.checkboxes);  
      sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire({
        title: 'Are you sure?',
        text: 'You want to Delete Selected Record!',
        showCancelButton: true,
        confirmButtonText: 'Yes, delete it!',
        cancelButtonText: 'No, keep it'
      }).then(result => {
        if (result.value) {
          this.moduleservice.deletewbSelectedNumbers(this.checkboxes, 1).subscribe(res => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Deleted!', 'Records Deleted Successfully.');
            setTimeout(() => {
              sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
            }, 2000);
            this.loadnumbers();
          }, error => this.error = error);
        } else if (result.dismiss === (sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().DismissReason.cancel)) {
          sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().fire('Cancelled', 'Your Record is safe :)', 'error');
          setTimeout(() => {
            sweetalert2__WEBPACK_IMPORTED_MODULE_3___default().close();
          }, 2000);
        }
      });
    }
  }
  static #_ = this.ctorParameters = () => [{
    type: _module_service__WEBPACK_IMPORTED_MODULE_2__.ModuleService
  }, {
    type: ngx_toastr__WEBPACK_IMPORTED_MODULE_8__.ToastrService
  }, {
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_6__.HttpBackend
  }, {
    type: _angular_forms__WEBPACK_IMPORTED_MODULE_7__.FormBuilder
  }];
  static #_2 = this.propDecorators = {
    table: [{
      type: _angular_core__WEBPACK_IMPORTED_MODULE_9__.ViewChild,
      args: ['dataTable', {
        static: true
      }]
    }]
  };
};
WhitelistComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_10__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_9__.Component)({
  selector: 'app-whitelist',
  template: _whitelist_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_whitelist_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], WhitelistComponent);


/***/ }),

/***/ 94588:
/*!********************************************************************************!*\
  !*** ./src/app/page-not-found-component/page-not-found-component.component.ts ***!
  \********************************************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "PageNotFoundComponentComponent": () => (/* binding */ PageNotFoundComponentComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _page_not_found_component_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./page-not-found-component.component.html?ngResource */ 71170);
/* harmony import */ var _page_not_found_component_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./page-not-found-component.component.scss?ngResource */ 53703);
/* harmony import */ var _page_not_found_component_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_page_not_found_component_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @angular/router */ 60124);





let PageNotFoundComponentComponent = class PageNotFoundComponentComponent {
  constructor(router) {
    this.router = router;
  }
  ngOnInit() {
    this.router.navigate(['/404']);
    this.showLoadingIndicator = true;
    setTimeout(() => {
      this.showLoadingIndicator = false;
    }, 1000);
  }
  static #_ = this.ctorParameters = () => [{
    type: _angular_router__WEBPACK_IMPORTED_MODULE_2__.Router
  }];
};
PageNotFoundComponentComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_3__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_4__.Component)({
  selector: 'app-page-not-found-component',
  template: _page_not_found_component_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_page_not_found_component_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], PageNotFoundComponentComponent);


/***/ }),

/***/ 43019:
/*!********************************************************!*\
  !*** ./src/app/pagenotfound/pagenotfound.component.ts ***!
  \********************************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "PagenotfoundComponent": () => (/* binding */ PagenotfoundComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _pagenotfound_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./pagenotfound.component.html?ngResource */ 25689);
/* harmony import */ var _pagenotfound_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./pagenotfound.component.scss?ngResource */ 91030);
/* harmony import */ var _pagenotfound_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_pagenotfound_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/core */ 22560);




let PagenotfoundComponent = class PagenotfoundComponent {
  constructor() {}
  ngOnInit() {}
  static #_ = this.ctorParameters = () => [];
};
PagenotfoundComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_2__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_3__.Component)({
  selector: 'app-pagenotfound',
  template: _pagenotfound_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_pagenotfound_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], PagenotfoundComponent);


/***/ }),

/***/ 6804:
/*!**********************************************!*\
  !*** ./src/app/sidebar/sidebar.component.ts ***!
  \**********************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "SidebarComponent": () => (/* binding */ SidebarComponent)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _sidebar_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./sidebar.component.html?ngResource */ 28945);
/* harmony import */ var _sidebar_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./sidebar.component.scss?ngResource */ 71729);
/* harmony import */ var _sidebar_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_sidebar_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1__);
/* harmony import */ var _sidebar_service__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./sidebar.service */ 13414);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_router__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/router */ 60124);
/* harmony import */ var _modules_module_service__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../modules/module.service */ 22947);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./../global */ 27266);








let SidebarComponent = class SidebarComponent {
  constructor(route, sidebarservice, moduleservice, router) {
    this.route = route;
    this.sidebarservice = sidebarservice;
    this.moduleservice = moduleservice;
    this.router = router;
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_4__.GlobalVariable.BASE_URL;
    this.role = "";
    // subscribe to sender component messages
    this.subscriptionName = this.moduleservice.getUpdate().subscribe(message => {
      if (message.text == 1) {
        this.ngOnInit();
      }
    });
    this.routerurl = window.location.href.replace(this.ServerUrl, "");
  }
  ngOnDestroy() {
    this.subscriptionName.unsubscribe();
  }
  ngOnInit() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentUser'));
    // console.log(this.currentCompany); return
    if (this.currentCompany == null) {
      return;
    }
    var loggedinuser = JSON.parse(localStorage.getItem('currentUser'));
    var loggedincompany = JSON.parse(localStorage.getItem('currentCompany'));
    // console.log(loggedinuser.role)
    if (loggedinuser != null) {
      this.role = loggedinuser.role;
      if (loggedinuser) {
        this.firstName = loggedinuser.first_name;
        this.lastName = loggedinuser.last_name;
        this.companyName = loggedincompany.name;
      }
      const allParams = this.route.snapshot.params; // allParams is an object
      const param1 = allParams.param1; // retrieve the parameter "param1"
      // this.sidebarservice.getMenu().subscribe((data)=>{
      // console.log(loggedinuser);      
      // },    
      //   error => this.error = error
      // );
      //   (Menu: any) => {
      //     // console.log(Menu)
      //     // location.reload()
      // }, 
      // (error: any) => {
      //     // console.log(error)
      // } 
    }

    this.getAllbasicsetting();
    this.getAllsavedreport();
    this.getmenu(loggedinuser.role);
    // console.log(this.routerurl)
  }

  getmenu(role) {
    this.sidebarservice.getMenu(role).subscribe(data => this.menu = data, error => this.error = error);
  }
  getAllbasicsetting() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentUser'));
    this.moduleservice.getAllbasicsetting(this.currentCompany.uuid).subscribe(res => {
      //  console.log(res); return false;  
      this.google_sheet_link = res['google_sheet_link'];
    }, error => this.error = error);
  }
  getAllsavedreport() {
    this.currentCompany = JSON.parse(localStorage.getItem('currentCompany'));
    this.moduleservice.getAllsavedreport(this.currentCompany.uuid).subscribe(res => {
      this.allsavedreports = res;
      //  console.log(res); return false;  
      // this.google_sheet_link = res['google_sheet_link'];
    }, error => this.error = error);
  }
  showSubmenu(id) {
    if (id == 0) {
      // if($(".target-item").hasClass("show")){
      //   $('.target-item').removeClass("show"); 
      // }      
      $('.target-item').fadeToggle("show");
    }
    if (id == 1) {
      // $('.report-item').removeClass("show");      
      $('.report-item').fadeToggle("show");
    }
    if (id == 2) {
      // $('.report-item').removeClass("show");      
      $('.blocklist-item').fadeToggle("show");
    }
    if (id == 3) {
      // $('.report-item').removeClass("show");      
      $('.numbers-item').fadeToggle("show");
    }
    if (id == 4) {
      // $('.report-item').removeClass("show");      
      $('.settings-item').fadeToggle("show");
    }
    if (id == 5) {
      // $('.report-item').removeClass("show");      
      $('.ivr-item').fadeToggle("show");
    }
  }
  static #_ = this.ctorParameters = () => [{
    type: _angular_router__WEBPACK_IMPORTED_MODULE_5__.ActivatedRoute
  }, {
    type: _sidebar_service__WEBPACK_IMPORTED_MODULE_2__.SidebarService
  }, {
    type: _modules_module_service__WEBPACK_IMPORTED_MODULE_3__.ModuleService
  }, {
    type: _angular_router__WEBPACK_IMPORTED_MODULE_5__.Router
  }];
};
SidebarComponent = (0,tslib__WEBPACK_IMPORTED_MODULE_6__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_7__.Component)({
  selector: 'app-sidebar',
  template: _sidebar_component_html_ngResource__WEBPACK_IMPORTED_MODULE_0__,
  styles: [(_sidebar_component_scss_ngResource__WEBPACK_IMPORTED_MODULE_1___default())]
})], SidebarComponent);


/***/ }),

/***/ 13414:
/*!********************************************!*\
  !*** ./src/app/sidebar/sidebar.service.ts ***!
  \********************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "SidebarService": () => (/* binding */ SidebarService)
/* harmony export */ });
/* harmony import */ var tslib__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! tslib */ 34929);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_common_http__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/common/http */ 58987);
/* harmony import */ var rxjs__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! rxjs */ 66587);
/* harmony import */ var rxjs_operators__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! rxjs/operators */ 47418);
/* harmony import */ var _global__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! .././global */ 27266);






let SidebarService = class SidebarService {
  constructor(handler) {
    this.ServerUrl = _global__WEBPACK_IMPORTED_MODULE_0__.GlobalVariable.BASE_API_URL;
    this.httpOptions = {
      headers: new _angular_common_http__WEBPACK_IMPORTED_MODULE_1__.HttpHeaders({
        'Content-Type': 'application/json'
      })
    };
    this.http = new _angular_common_http__WEBPACK_IMPORTED_MODULE_1__.HttpClient(handler);
  }
  getMenu(role) {
    return this.http.get(this.ServerUrl + 'getmenu/' + role).pipe((0,rxjs_operators__WEBPACK_IMPORTED_MODULE_2__.catchError)(this.handleError));
  }
  handleError(error) {
    if (error.error instanceof ErrorEvent) {
      console.error('An error occurred:', error.error.message);
    } else {
      console.error(`Backend returned code ${error.status}, ` + `body was: ${error.error}`);
    }
    this.errorData = {
      errorTitle: 'Oops! Request for document failed',
      errorDesc: 'Something bad happened. Please try again later.'
    };
    return (0,rxjs__WEBPACK_IMPORTED_MODULE_3__.throwError)(this.errorData);
  }
  static #_ = this.ctorParameters = () => [{
    type: _angular_common_http__WEBPACK_IMPORTED_MODULE_1__.HttpBackend
  }];
};
SidebarService = (0,tslib__WEBPACK_IMPORTED_MODULE_4__.__decorate)([(0,_angular_core__WEBPACK_IMPORTED_MODULE_5__.Injectable)({
  providedIn: 'root'
})], SidebarService);


/***/ }),

/***/ 92340:
/*!*****************************************!*\
  !*** ./src/environments/environment.ts ***!
  \*****************************************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   "environment": () => (/* binding */ environment)
/* harmony export */ });
/* harmony import */ var zone_js_dist_zone_error__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! zone.js/dist/zone-error */ 30771);
/* harmony import */ var zone_js_dist_zone_error__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(zone_js_dist_zone_error__WEBPACK_IMPORTED_MODULE_0__);
// This file can be replaced during build by using the `fileReplacements` array.
// `ng build --prod` replaces `environment.ts` with `environment.prod.ts`.
// The list of file replacements can be found in `angular.json`.

const environment = {
  production: false,
  firebase: {
    apiKey: "AIzaSyAvHImEhL4UsyJs8uWYe8JnMn5m1QnHg9s",
    authDomain: "dialdigits.firebaseapp.com",
    projectId: "dialdigits",
    storageBucket: "dialdigits.appspot.com",
    messagingSenderId: "875423843515",
    appId: "1:875423843515:web:9f54d32e66ed8fde03159e",
    measurementId: "G-DB124KD6P6"
  }
};
/*
 * For easier debugging in development mode, you can import the following file
 * to ignore zone related error stack frames such as `zone.run`, `zoneDelegate.invokeTask`.
 *
 * This import should be commented out in production mode because it will have a negative impact
 * on performance if an error is thrown.
 */
// import 'zone.js/dist/zone-error';  // Included with Angular CLI.

/***/ }),

/***/ 14431:
/*!*********************!*\
  !*** ./src/main.ts ***!
  \*********************/
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @angular/core */ 22560);
/* harmony import */ var _angular_platform_browser_dynamic__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/platform-browser-dynamic */ 76057);
/* harmony import */ var _app_app_module__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./app/app.module */ 36747);
/* harmony import */ var _environments_environment__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./environments/environment */ 92340);




if (_environments_environment__WEBPACK_IMPORTED_MODULE_1__.environment.production) {
  (0,_angular_core__WEBPACK_IMPORTED_MODULE_2__.enableProdMode)();
}
(0,_angular_platform_browser_dynamic__WEBPACK_IMPORTED_MODULE_3__.platformBrowserDynamic)().bootstrapModule(_app_app_module__WEBPACK_IMPORTED_MODULE_0__.AppModule).catch(err => console.error(err));

/***/ }),

/***/ 4594:
/*!***********************************************!*\
  !*** ./src/app/app.component.scss?ngResource ***!
  \***********************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 92650:
/*!********************************************************************************!*\
  !*** ./src/app/auth/login-componunt/login-componunt.component.scss?ngResource ***!
  \********************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "@media only screen and (min-device-width: 320px) and (max-device-width: 480px) and (-webkit-min-device-pixel-ratio: 2) {\n  .login {\n    width: 101% !important;\n  }\n}\n@media only screen and (min-device-width: 480px) and (max-device-width: 1400px) {\n  .login {\n    margin-left: 0px !important;\n    width: 101% !important;\n  }\n  .card .card-header {\n    padding: 12px 0px 0px 73px;\n  }\n}\n@media only screen and (min-device-width: 1400px) and (max-device-width: 2200px) {\n  .login {\n    width: 101% !important;\n    min-height: 558px !important;\n    padding-top: 100px !important;\n  }\n  .card .card-header {\n    padding: 9px 0px 0px 66px;\n  }\n}\n.card.card-primary.logincard {\n  background: #0d1735 !important;\n}\n\nfooter.footer {\n  background: #1F263D;\n  color: white;\n  border-top: 1px solid #535660;\n}\n\n.fas, .far, .fab, .fal {\n  font-size: 20px;\n}", "",{"version":3,"sources":["webpack://./src/app/auth/login-componunt/login-componunt.component.scss"],"names":[],"mappings":"AAAA;EAII;IAII,sBAAA;EALN;AACF;AAQA;EAGK;IAGG,2BAAA;IACA,sBAAA;EAVN;EAYE;IACI,0BAAA;EAVN;AACF;AAYA;EAII;IAGI,sBAAA;IACA,4BAAA;IACA,6BAAA;EAfN;EAoBE;IACI,yBAAA;EAlBN;AACF;AAqBA;EACI,8BAAA;AAnBJ;;AAwBA;EAEI,mBAAA;EACA,YAAA;EAEA,6BAAA;AAvBJ;;AAyBA;EACI,eAAA;AAtBJ","sourcesContent":["@media only screen \n  and (min-device-width: 320px) \n  and (max-device-width: 480px)\n  and (-webkit-min-device-pixel-ratio: 2) {\n    .login{\n        // padding-top: 93px;\n        // padding-bottom: 140px;\n        // padding-right: 155px;\n        width: 101%!important;\n    }\n}\n\n@media only screen \n  and (min-device-width: 480px) \n  and (max-device-width: 1400px)\n {   .login{\n        // padding-top: 150px;\n        // padding-bottom: 130px;\n        margin-left: 0px!important;\n        width: 101%!important;\n    }\n    .card .card-header {\n        padding: 12px 0px 0px 73px;\n    }\n}\n@media only screen \n  and (min-device-width: 1400px) \n  and (max-device-width: 2200px)\n  {\n    .login{\n        // padding-top: 127px!important;\n        // padding-bottom: 340px!important;\n        width: 101% !important;\n        min-height: 558px!important;\n        padding-top: 100px!important;                \n    }\n    // .logincol{\n    //     margin-left: 40px!important;\n    // }\n    .card .card-header {\n        padding: 9px 0px 0px 66px\n    }\n}\n\n.card.card-primary.logincard {\n    background: #0d1735!important;\n}\n\n//large\n\nfooter.footer {\n    // background: #22235f;\n    background: #1F263D;\n    color: white;\n    // border-top: 1px solid #463c95;\n    border-top: 1px solid #535660;\n}\n.fas, .far, .fab, .fal {\n    font-size: 20px;\n}"],"sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 12274:
/*!****************************************************************!*\
  !*** ./src/app/auth/profile/profile.component.scss?ngResource ***!
  \****************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 92152:
/*!*********************************************************!*\
  !*** ./src/app/footer/footer.component.scss?ngResource ***!
  \*********************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 50779:
/*!*********************************************************!*\
  !*** ./src/app/header/header.component.scss?ngResource ***!
  \*********************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, ".media-body {\n  padding-left: 7px !important;\n  font-size: 13px;\n}\n\nh6.media-heading {\n  margin-bottom: -2px;\n  margin-top: -4px;\n  color: lightgreen;\n}\n\nh6.media-heading-completed {\n  margin-bottom: -2px;\n  margin-top: -4px;\n  color: lightgreen;\n}\n\n@media (min-width: 1281px) {\n  ul.navbar-nav.navbar-right {\n    padding-top: 3px;\n  }\n}\n@media (min-width: 1281px) {\n  .sidebartogglebtn {\n    display: none;\n  }\n}", "",{"version":3,"sources":["webpack://./src/app/header/header.component.scss"],"names":[],"mappings":"AAQA;EACI,4BAAA;EACA,eAAA;AAPJ;;AASA;EACI,mBAAA;EACA,gBAAA;EACA,iBAAA;AANJ;;AAQA;EACI,mBAAA;EACA,gBAAA;EACA,iBAAA;AALJ;;AAaA;EACA;IACI,gBAAA;EAVF;AACF;AAYA;EACA;IACI,aAAA;EAVF;AACF","sourcesContent":["// .phone{\n// font-size: 33px!important;\n// color: green;\n// }\n// .phone-completed{\n// font-size: 33px!important;\n// color: #3c94d6;\n// }\n.media-body {\n    padding-left: 7px!important;\n    font-size: 13px;\n}\nh6.media-heading{\n    margin-bottom: -2px;\n    margin-top: -4px;\n    color: lightgreen;\n}\nh6.media-heading-completed{\n    margin-bottom: -2px;\n    margin-top: -4px;\n    color: lightgreen;\n}\n\n// ul.navbar-nav.mr-3 {\n//     margin-top: 19px;\n// }\n\n// }\n@media (min-width:1281px) { \nul.navbar-nav.navbar-right {\n    padding-top: 3px;\n}\n}\n@media (min-width:1281px) { \n.sidebartogglebtn{\n    display: none;\n}\n}"],"sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 42314:
/*!*****************************************************************************!*\
  !*** ./src/app/modules/audible-ring/audible-ring.component.scss?ngResource ***!
  \*****************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "::-webkit-scrollbar {\n  width: 1px;\n}\n\n::-webkit-scrollbar-track {\n  -webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.3);\n  border-radius: 10px;\n}\n\n::-webkit-scrollbar-thumb {\n  border-radius: 10px;\n  background: rgba(192, 192, 192, 0.3);\n  -webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.5);\n}\n\n::-webkit-scrollbar-thumb:window-inactive {\n  background: rgba(255, 0, 0, 0.4);\n}\n\ninput.form-control {\n  padding: 7px 15px !important;\n}", "",{"version":3,"sources":["webpack://./src/app/modules/audible-ring/audible-ring.component.scss"],"names":[],"mappings":"AACA;EACI,UAAA;AAAJ;;AAIA;EACI,oDAAA;EAEA,mBAAA;AADJ;;AAIA;EAEI,mBAAA;EACA,oCAAA;EACA,oDAAA;AADJ;;AAGA;EACI,gCAAA;AAAJ;;AAGA;EACI,4BAAA;AAAJ","sourcesContent":["\n::-webkit-scrollbar {\n    width: 1px;\n}\n\n\n::-webkit-scrollbar-track {\n    -webkit-box-shadow: inset 0 0 6px rgba(0,0,0,0.3); \n    -webkit-border-radius: 10px;\n    border-radius: 10px;\n}\n\n::-webkit-scrollbar-thumb {\n    -webkit-border-radius: 10px;\n    border-radius: 10px;\n    background: rgba(192,192,192,0.3);\n    -webkit-box-shadow: inset 0 0 6px rgba(0,0,0,0.5); \n}\n::-webkit-scrollbar-thumb:window-inactive {\n    background: rgba(255,0,0,0.4); \n}\n\ninput.form-control {\n    padding: 7px 15px!important;\n}"],"sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 51720:
/*!***********************************************************************!*\
  !*** ./src/app/modules/blacklist/blacklist.component.scss?ngResource ***!
  \***********************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 94672:
/*!*********************************************************************************************!*\
  !*** ./src/app/modules/campaigns/campaign-create/campaign-create.component.scss?ngResource ***!
  \*********************************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "input#option1, input#option2, input#option3 {\n  display: none;\n}\n\n.btn-group.form-control {\n  height: 60px;\n}\n\n.mat-step-header {\n  background: #6777ef !important;\n  color: white !important;\n  padding: 4px !important;\n  border-radius: 5px !important;\n  margin: 7px !important;\n  height: 43px !important;\n}\n\nlabel.btn.btn-primary.form-check-label {\n  font-size: 12px;\n  margin-top: 5px;\n}", "",{"version":3,"sources":["webpack://./src/app/modules/campaigns/campaign-create/campaign-create.component.scss"],"names":[],"mappings":"AAAA;EACI,aAAA;AACJ;;AACA;EACI,YAAA;AAEJ;;AACA;EACI,8BAAA;EACA,uBAAA;EACA,uBAAA;EACA,6BAAA;EACA,sBAAA;EACA,uBAAA;AAEJ;;AACA;EACI,eAAA;EACA,eAAA;AAEJ","sourcesContent":["input#option1, input#option2, input#option3{\n    display: none;\n}    \n.btn-group.form-control {\n    height: 60px;\n}\n\n.mat-step-header {\n    background: #6777ef!important;\n    color: white!important;\n    padding: 4px!important;\n    border-radius: 5px!important;\n    margin: 7px!important;\n    height: 43px!important;\n}\n\nlabel.btn.btn-primary.form-check-label {\n    font-size: 12px;\n    margin-top: 5px;\n}\n\n// ::ng-deep .mat-form-field {\n//     .mat-input-element {\n//         color: slategray;\n//     }\n//     .mat-form-field-label {\n//         color: slategray;\n//     }\n//     .mat-form-field-underline {\n//         background-color: slategray;\n//     }\n//     .mat-form-field-ripple {\n//         background-color: slategray;\n//     }\n//     .mat-form-field-required-marker {\n//         color: slategray;\n//     }\n// }\n\n// ::ng-deep .mat-form-field.mat-focused {\n//     .mat-form-field-label {\n//         color: #ff884d;\n//     }\n//     .mat-form-field-ripple {\n//         background-color: #ff884d;\n//     }\n//     .mat-form-field-required-marker {\n//         color: #ff884d;\n//     }\n//     .mat-input-element {\n//         color: #ff884d;\n//     }\n// }\n// .mat-input-wrapper {\n//     background: gray;\n// }\n\n"],"sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 59483:
/*!*****************************************************************************************!*\
  !*** ./src/app/modules/campaigns/campaign-edit/campaign-edit.component.scss?ngResource ***!
  \*****************************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "input#option1, input#option2, input#option3 {\n  display: none;\n}\n\n.btn-group.form-control {\n  height: 55px;\n}\n\n.mat-step-header {\n  background: #6777ef !important;\n  color: white !important;\n  padding: 4px !important;\n  border-radius: 5px !important;\n  margin: 7px !important;\n  height: 43px !important;\n}\n\nng-select2.ng-star-inserted {\n  pointer-events: none !important;\n  touch-action: none !important;\n  color: #e9ecef !important;\n}\n\nfieldset.scheduler-border {\n  border: 1px groove #ddd !important;\n  padding: 0 1.4em 1.4em 1.4em !important;\n  margin: 0 0 1.5em 0 !important;\n  box-shadow: 0px 0px 0px 0px #000;\n  border-radius: 10px !important;\n}\n\nlegend.scheduler-border {\n  font-size: 1em !important;\n  font-weight: bold !important;\n  text-align: left !important;\n  width: auto;\n  padding: 0 10px;\n  border-bottom: none;\n}\n\nlabel.btn.btn-primary.form-check-label {\n  font-size: 11px;\n}\n\nstrong {\n  font-size: 11px;\n}\n\ninput[type=number]::-webkit-inner-spin-button,\ninput[type=number]::-webkit-outer-spin-button {\n  opacity: 1 !important;\n}\n\ninput[type=number] {\n  border: none;\n  border-bottom: 1px solid;\n  border-radius: 0;\n  padding: 10px !important;\n}", "",{"version":3,"sources":["webpack://./src/app/modules/campaigns/campaign-edit/campaign-edit.component.scss"],"names":[],"mappings":"AAAA;EACI,aAAA;AACJ;;AACA;EACI,YAAA;AAEJ;;AACA;EACI,8BAAA;EACA,uBAAA;EACA,uBAAA;EACA,6BAAA;EACA,sBAAA;EACA,uBAAA;AAEJ;;AACA;EACI,+BAAA;EACA,6BAAA;EACA,yBAAA;AAEJ;;AAAA;EACI,kCAAA;EACA,uCAAA;EACA,8BAAA;EAEQ,gCAAA;EACR,8BAAA;AAGJ;;AAAA;EACI,yBAAA;EACA,4BAAA;EACA,2BAAA;EACA,WAAA;EACA,eAAA;EACA,mBAAA;AAGJ;;AAAA;EACI,eAAA;AAGJ;;AAQA;EACI,eAAA;AALJ;;AAQA;;EAEE,qBAAA;AALF;;AAOA;EACI,YAAA;EACA,wBAAA;EACA,gBAAA;EACA,wBAAA;AAJJ","sourcesContent":["input#option1, input#option2, input#option3{\n    display: none;\n}\n.btn-group.form-control {\n    height: 55px;\n}\n\n.mat-step-header {\n    background: #6777ef!important;\n    color: white!important;\n    padding: 4px!important;\n    border-radius: 5px!important;\n    margin: 7px!important;\n    height: 43px!important;\n}\n\nng-select2.ng-star-inserted {\n    pointer-events: none!important;\n    touch-action: none!important;\n    color: #e9ecef!important;\n}\nfieldset.scheduler-border {\n    border: 1px groove #ddd !important;\n    padding: 0 1.4em 1.4em 1.4em !important;\n    margin: 0 0 1.5em 0 !important;\n    -webkit-box-shadow:  0px 0px 0px 0px #000;\n            box-shadow:  0px 0px 0px 0px #000;\n    border-radius: 10px!important;\n}\n\nlegend.scheduler-border {\n    font-size: 1.0em !important;\n    font-weight: bold !important;\n    text-align: left !important;\n    width:auto;\n    padding:0 10px;\n    border-bottom:none;\n}\n\nlabel.btn.btn-primary.form-check-label {\n    font-size: 11px;\n}\n\n// th,td{\n//     padding: 0px 10px 0px 10px!important;\n//     height: 46px!important;\n//     background: #2ea2d6;\n//     vertical-align: middle;\n//     color: white;\n//     border-radius: 1px;\n// }\nstrong {\n    font-size: 11px;\n}\n\ninput[type=number]::-webkit-inner-spin-button,\ninput[type=number]::-webkit-outer-spin-button {\n  opacity: 1!important;\n}\ninput[type=number]{\n    border: none;\n    border-bottom: 1px solid;\n    border-radius: 0;\n    padding: 10px!important;\n}\n\n\n"],"sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 70771:
/*!*****************************************************************************************!*\
  !*** ./src/app/modules/campaigns/campaign-view/campaign-view.component.scss?ngResource ***!
  \*****************************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "input#option1, input#option2, input#option3 {\n  display: none;\n}\n\n.btn-group.form-control {\n  height: 55px;\n}\n\n.mat-step-header {\n  background: #6777ef !important;\n  color: white !important;\n  padding: 4px !important;\n  border-radius: 5px !important;\n  margin: 7px !important;\n  height: 43px !important;\n}\n\nng-select2.ng-star-inserted {\n  pointer-events: none !important;\n  touch-action: none !important;\n  color: #e9ecef !important;\n}\n\nfieldset.scheduler-border {\n  border: 1px groove #ddd !important;\n  padding: 0 1.4em 1.4em 1.4em !important;\n  margin: 0 0 1.5em 0 !important;\n  box-shadow: 0px 0px 0px 0px #000;\n  border-radius: 10px !important;\n}\n\nlegend.scheduler-border {\n  font-size: 1em !important;\n  font-weight: bold !important;\n  text-align: left !important;\n  width: auto;\n  padding: 0 10px;\n  border-bottom: none;\n}\n\nlabel.btn.btn-primary.form-check-label {\n  font-size: 11px;\n}\n\nstrong {\n  font-size: 11px;\n}\n\ninput[type=number]::-webkit-inner-spin-button,\ninput[type=number]::-webkit-outer-spin-button {\n  opacity: 1 !important;\n}\n\ninput[type=number] {\n  border: none;\n  border-bottom: 1px solid;\n  border-radius: 0;\n  padding: 10px !important;\n}", "",{"version":3,"sources":["webpack://./src/app/modules/campaigns/campaign-view/campaign-view.component.scss"],"names":[],"mappings":"AAAA;EACI,aAAA;AACJ;;AACA;EACI,YAAA;AAEJ;;AACA;EACI,8BAAA;EACA,uBAAA;EACA,uBAAA;EACA,6BAAA;EACA,sBAAA;EACA,uBAAA;AAEJ;;AACA;EACI,+BAAA;EACA,6BAAA;EACA,yBAAA;AAEJ;;AAAA;EACI,kCAAA;EACA,uCAAA;EACA,8BAAA;EAEQ,gCAAA;EACR,8BAAA;AAGJ;;AAAA;EACI,yBAAA;EACA,4BAAA;EACA,2BAAA;EACA,WAAA;EACA,eAAA;EACA,mBAAA;AAGJ;;AAAA;EACI,eAAA;AAGJ;;AAQA;EACI,eAAA;AALJ;;AAQA;;EAEE,qBAAA;AALF;;AAOA;EACI,YAAA;EACA,wBAAA;EACA,gBAAA;EACA,wBAAA;AAJJ","sourcesContent":["input#option1, input#option2, input#option3{\n    display: none;\n}\n.btn-group.form-control {\n    height: 55px;\n}\n\n.mat-step-header {\n    background: #6777ef!important;\n    color: white!important;\n    padding: 4px!important;\n    border-radius: 5px!important;\n    margin: 7px!important;\n    height: 43px!important;\n}\n\nng-select2.ng-star-inserted {\n    pointer-events: none!important;\n    touch-action: none!important;\n    color: #e9ecef!important;\n}\nfieldset.scheduler-border {\n    border: 1px groove #ddd !important;\n    padding: 0 1.4em 1.4em 1.4em !important;\n    margin: 0 0 1.5em 0 !important;\n    -webkit-box-shadow:  0px 0px 0px 0px #000;\n            box-shadow:  0px 0px 0px 0px #000;\n    border-radius: 10px!important;\n}\n\nlegend.scheduler-border {\n    font-size: 1.0em !important;\n    font-weight: bold !important;\n    text-align: left !important;\n    width:auto;\n    padding:0 10px;\n    border-bottom:none;\n}\n\nlabel.btn.btn-primary.form-check-label {\n    font-size: 11px;\n}\n\n// th,td{\n//     padding: 0px 10px 0px 10px!important;\n//     height: 46px!important;\n//     background: #2ea2d6;\n//     vertical-align: middle;\n//     color: white;\n//     border-radius: 1px;\n// }\nstrong {\n    font-size: 11px;\n}\n\ninput[type=number]::-webkit-inner-spin-button,\ninput[type=number]::-webkit-outer-spin-button {\n  opacity: 1!important;\n}\ninput[type=number]{\n    border: none;\n    border-bottom: 1px solid;\n    border-radius: 0;\n    padding: 10px!important;\n}\n\n\n"],"sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 79315:
/*!***********************************************************************!*\
  !*** ./src/app/modules/campaigns/campaigns.component.scss?ngResource ***!
  \***********************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "input#option1, input#option2, input#option3 {\n  display: none;\n}\n\n.btn-group.form-control {\n  height: auto;\n  border: none;\n  padding: 0;\n}\n\n.appleinput {\n  width: 63px;\n  border: none;\n  border-bottom: 1px solid;\n  border-radius: 0;\n  background: none !important;\n}", "",{"version":3,"sources":["webpack://./src/app/modules/campaigns/campaigns.component.scss"],"names":[],"mappings":"AAAA;EACI,aAAA;AACJ;;AACA;EACI,YAAA;EACA,YAAA;EACA,UAAA;AAEJ;;AACA;EACI,WAAA;EACA,YAAA;EACA,wBAAA;EACA,gBAAA;EACA,2BAAA;AAEJ","sourcesContent":["input#option1, input#option2, input#option3{\n    display: none;\n}    \n.btn-group.form-control {\n    height: auto;\n    border: none;\n    padding: 0;\n}\n\n.appleinput{\n    width: 63px;\n    border: none;\n    border-bottom: 1px solid;\n    border-radius: 0;\n    background: none!important;\n}\n\n"],"sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 36080:
/*!***********************************************************************!*\
  !*** ./src/app/modules/changelog/changelog.component.scss?ngResource ***!
  \***********************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 32399:
/*!***********************************************************************!*\
  !*** ./src/app/modules/dashboard/dashboard.component.scss?ngResource ***!
  \***********************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, ".card .card-statistic-3 {\n  position: relative;\n  color: #fff;\n  overflow: hidden;\n  padding-bottom: 55px !important;\n  padding-top: 15px !important;\n  border-radius: 10px !important;\n}\n\n.card {\n  border-radius: 9px;\n}\n\nh6.mb-0 {\n  font-size: 17px;\n}", "",{"version":3,"sources":["webpack://./src/app/modules/dashboard/dashboard.component.scss"],"names":[],"mappings":"AAAA;EACI,kBAAA;EACA,WAAA;EACA,gBAAA;EACA,+BAAA;EACA,4BAAA;EACA,8BAAA;AACJ;;AAEA;EAEI,kBAAA;AAAJ;;AAIA;EACI,eAAA;AADJ","sourcesContent":[".card .card-statistic-3 {\n    position: relative;\n    color: #fff;\n    overflow: hidden;\n    padding-bottom: 55px!important;\n    padding-top: 15px!important;\n    border-radius: 10px!important;    \n}\n\n.card {\n    // padding: 10px !important;\n    border-radius: 9px;\n\n}\n\nh6.mb-0 {\n    font-size: 17px;\n}\n\n"],"sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 68834:
/*!***************************************************************************************!*\
  !*** ./src/app/modules/dynamic-parameter/dynamic-parameter.component.scss?ngResource ***!
  \***************************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 36178:
/*!*************************************************************************************!*\
  !*** ./src/app/modules/ivr-menus/add-ivrmenu/add-ivrmenu.component.scss?ngResource ***!
  \*************************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, ".form-control {\n  font-size: 12px !important;\n}\n\ntable.dataTable tbody th, table.dataTable tbody td {\n  padding: 6px 6px !important;\n}", "",{"version":3,"sources":["webpack://./src/app/modules/ivr-menus/add-ivrmenu/add-ivrmenu.component.scss"],"names":[],"mappings":"AAAA;EAGI,0BAAA;AADJ;;AAMA;EACI,2BAAA;AAHJ","sourcesContent":[".form-control {\n    // width: auto !important;\n    // height: auto !important;\n    font-size: 12px !important;\n}\n// .flex-fill.pl-1.ngx-basic-audio-player-slider {\n//     display: none!important;\n// }\ntable.dataTable tbody th, table.dataTable tbody td {\n    padding: 6px 6px!important;\n}"],"sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 60489:
/*!***************************************************************************************!*\
  !*** ./src/app/modules/ivr-menus/edit-ivrmenu/edit-ivrmenu.component.scss?ngResource ***!
  \***************************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 99757:
/*!***********************************************************************!*\
  !*** ./src/app/modules/ivr-menus/ivr-menus.component.scss?ngResource ***!
  \***********************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 75027:
/*!*************************************************************************************************!*\
  !*** ./src/app/modules/ivr-menus/ivr-routing-plans/add-plan/add-plan.component.scss?ngResource ***!
  \*************************************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "input#option1, input#option2, input#option3 {\n  display: none;\n}\n\n.btn-group.form-control {\n  height: 60px;\n}\n\n.mat-step-header {\n  background: #6777ef !important;\n  color: white !important;\n  padding: 4px !important;\n  border-radius: 5px !important;\n  margin: 7px !important;\n  height: 43px !important;\n}\n\nng-select2.ng-star-inserted {\n  pointer-events: none !important;\n  touch-action: none !important;\n  color: #e9ecef !important;\n}\n\nfieldset.scheduler-border {\n  border: 1px groove #ddd !important;\n  padding: 0 1.4em 1.4em 1.4em !important;\n  margin: 0 0 1.5em 0 !important;\n  box-shadow: 0px 0px 0px 0px #000;\n  border-radius: 10px !important;\n}\n\nlegend.scheduler-border {\n  font-size: 1.2em !important;\n  font-weight: bold !important;\n  text-align: left !important;\n  width: auto;\n  padding: 0 10px;\n  border-bottom: none;\n}\n\nstrong {\n  font-size: 11px;\n}", "",{"version":3,"sources":["webpack://./src/app/modules/ivr-menus/ivr-routing-plans/add-plan/add-plan.component.scss"],"names":[],"mappings":"AAAA;EACI,aAAA;AACJ;;AACA;EACI,YAAA;AAEJ;;AACA;EACI,8BAAA;EACA,uBAAA;EACA,uBAAA;EACA,6BAAA;EACA,sBAAA;EACA,uBAAA;AAEJ;;AACA;EACI,+BAAA;EACA,6BAAA;EACA,yBAAA;AAEJ;;AAAA;EACI,kCAAA;EACA,uCAAA;EACA,8BAAA;EAEQ,gCAAA;EACR,8BAAA;AAGJ;;AAAA;EACI,2BAAA;EACA,4BAAA;EACA,2BAAA;EACA,WAAA;EACA,eAAA;EACA,mBAAA;AAGJ;;AAQA;EACI,eAAA;AALJ","sourcesContent":["input#option1, input#option2, input#option3{\n    display: none;\n}\n.btn-group.form-control {\n    height: 60px;\n}\n\n.mat-step-header {\n    background: #6777ef!important;\n    color: white!important;\n    padding: 4px!important;\n    border-radius: 5px!important;\n    margin: 7px!important;\n    height: 43px!important;\n}\n\nng-select2.ng-star-inserted {\n    pointer-events: none!important;\n    touch-action: none!important;\n    color: #e9ecef!important;\n}\nfieldset.scheduler-border {\n    border: 1px groove #ddd !important;\n    padding: 0 1.4em 1.4em 1.4em !important;\n    margin: 0 0 1.5em 0 !important;\n    -webkit-box-shadow:  0px 0px 0px 0px #000;\n            box-shadow:  0px 0px 0px 0px #000;\n    border-radius: 10px!important;\n}\n\nlegend.scheduler-border {\n    font-size: 1.2em !important;\n    font-weight: bold !important;\n    text-align: left !important;\n    width:auto;\n    padding:0 10px;\n    border-bottom:none;\n}\n\n// th,td{\n//     padding: 0px 10px 0px 10px!important;\n//     height: 46px!important;\n//     background: #2ea2d6;\n//     vertical-align: middle;\n//     color: white;\n//     border-radius: 1px;\n// }\nstrong {\n    font-size: 11px;\n}\n"],"sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 97089:
/*!***************************************************************************************************!*\
  !*** ./src/app/modules/ivr-menus/ivr-routing-plans/edit-plan/edit-plan.component.scss?ngResource ***!
  \***************************************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "input#option1, input#option2, input#option3 {\n  display: none;\n}\n\n.btn-group.form-control {\n  height: 60px;\n}\n\n.mat-step-header {\n  background: #6777ef !important;\n  color: white !important;\n  padding: 4px !important;\n  border-radius: 5px !important;\n  margin: 7px !important;\n  height: 43px !important;\n}\n\nng-select2.ng-star-inserted {\n  pointer-events: none !important;\n  touch-action: none !important;\n  color: #e9ecef !important;\n}\n\nfieldset.scheduler-border {\n  border: 1px groove #ddd !important;\n  padding: 0 1.4em 1.4em 1.4em !important;\n  margin: 0 0 1.5em 0 !important;\n  box-shadow: 0px 0px 0px 0px #000;\n  border-radius: 10px !important;\n}\n\nlegend.scheduler-border {\n  font-size: 1.2em !important;\n  font-weight: bold !important;\n  text-align: left !important;\n  width: auto;\n  padding: 0 10px;\n  border-bottom: none;\n}\n\nstrong {\n  font-size: 11px;\n}", "",{"version":3,"sources":["webpack://./src/app/modules/ivr-menus/ivr-routing-plans/edit-plan/edit-plan.component.scss"],"names":[],"mappings":"AAAA;EACI,aAAA;AACJ;;AACA;EACI,YAAA;AAEJ;;AACA;EACI,8BAAA;EACA,uBAAA;EACA,uBAAA;EACA,6BAAA;EACA,sBAAA;EACA,uBAAA;AAEJ;;AACA;EACI,+BAAA;EACA,6BAAA;EACA,yBAAA;AAEJ;;AAAA;EACI,kCAAA;EACA,uCAAA;EACA,8BAAA;EAEQ,gCAAA;EACR,8BAAA;AAGJ;;AAAA;EACI,2BAAA;EACA,4BAAA;EACA,2BAAA;EACA,WAAA;EACA,eAAA;EACA,mBAAA;AAGJ;;AAQA;EACI,eAAA;AALJ","sourcesContent":["input#option1, input#option2, input#option3{\n    display: none;\n}\n.btn-group.form-control {\n    height: 60px;\n}\n\n.mat-step-header {\n    background: #6777ef!important;\n    color: white!important;\n    padding: 4px!important;\n    border-radius: 5px!important;\n    margin: 7px!important;\n    height: 43px!important;\n}\n\nng-select2.ng-star-inserted {\n    pointer-events: none!important;\n    touch-action: none!important;\n    color: #e9ecef!important;\n}\nfieldset.scheduler-border {\n    border: 1px groove #ddd !important;\n    padding: 0 1.4em 1.4em 1.4em !important;\n    margin: 0 0 1.5em 0 !important;\n    -webkit-box-shadow:  0px 0px 0px 0px #000;\n            box-shadow:  0px 0px 0px 0px #000;\n    border-radius: 10px!important;\n}\n\nlegend.scheduler-border {\n    font-size: 1.2em !important;\n    font-weight: bold !important;\n    text-align: left !important;\n    width:auto;\n    padding:0 10px;\n    border-bottom:none;\n}\n\n// th,td{\n//     padding: 0px 10px 0px 10px!important;\n//     height: 46px!important;\n//     background: #2ea2d6;\n//     vertical-align: middle;\n//     color: white;\n//     border-radius: 1px;\n// }\nstrong {\n    font-size: 11px;\n}\n"],"sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 20447:
/*!*************************************************************************************************!*\
  !*** ./src/app/modules/ivr-menus/ivr-routing-plans/ivr-routing-plans.component.scss?ngResource ***!
  \*************************************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 79195:
/*!*******************************************************************************!*\
  !*** ./src/app/modules/label/label-view/label-view.component.scss?ngResource ***!
  \*******************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 50928:
/*!***************************************************************!*\
  !*** ./src/app/modules/label/label.component.scss?ngResource ***!
  \***************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "fieldset.scheduler-border {\n  border: 1px groove #ddd !important;\n  padding: 0 1.4em 1.4em 1.4em !important;\n  margin: 0 0 1.5em 0 !important;\n  box-shadow: 0px 0px 0px 0px #000;\n  border-radius: 10px !important;\n}\n\nlegend.scheduler-border {\n  font-size: 1.2em !important;\n  font-weight: bold !important;\n  text-align: left !important;\n  width: auto;\n  padding: 0 10px;\n  border-bottom: none;\n}\n\ninput#option1, input#option2, input#option3 {\n  display: none;\n}\n\n.btn-group.form-control {\n  height: 60px;\n}\n\n.modal-dialog.model-lg {\n  max-width: 783px;\n}", "",{"version":3,"sources":["webpack://./src/app/modules/label/label.component.scss"],"names":[],"mappings":"AAAA;EACI,kCAAA;EACA,uCAAA;EACA,8BAAA;EAEQ,gCAAA;EACR,8BAAA;AACJ;;AAEA;EACI,2BAAA;EACA,4BAAA;EACA,2BAAA;EACA,WAAA;EACA,eAAA;EACA,mBAAA;AACJ;;AAEA;EACA,aAAA;AACA;;AACA;EACI,YAAA;AAEJ;;AAAA;EACI,gBAAA;AAGJ","sourcesContent":["fieldset.scheduler-border {\n    border: 1px groove #ddd !important;\n    padding: 0 1.4em 1.4em 1.4em !important;\n    margin: 0 0 1.5em 0 !important;\n    -webkit-box-shadow:  0px 0px 0px 0px #000;\n            box-shadow:  0px 0px 0px 0px #000;\n    border-radius: 10px!important;\n}\n\nlegend.scheduler-border {\n    font-size: 1.2em !important;\n    font-weight: bold !important;\n    text-align: left !important;\n    width:auto;\n    padding:0 10px;\n    border-bottom:none;\n}\n\ninput#option1, input#option2, input#option3{\ndisplay: none;\n}\n.btn-group.form-control {\n    height: 60px;\n}\n.modal-dialog.model-lg {\n    max-width: 783px;\n}\n"],"sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 4023:
/*!*************************************************************************!*\
  !*** ./src/app/modules/label/ngxdemo/ngxdemo.component.scss?ngResource ***!
  \*************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 55925:
/*!*********************************************************************!*\
  !*** ./src/app/modules/longlist/longlist.component.scss?ngResource ***!
  \*********************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 54211:
/*!***************************************************************************************!*\
  !*** ./src/app/modules/mail-verification/mail-verification.component.scss?ngResource ***!
  \***************************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 59361:
/*!***************************************************************!*\
  !*** ./src/app/modules/notes/notes.component.scss?ngResource ***!
  \***************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "textarea.form-control {\n  height: auto !important;\n}", "",{"version":3,"sources":["webpack://./src/app/modules/notes/notes.component.scss"],"names":[],"mappings":"AAAA;EACI,uBAAA;AACJ","sourcesContent":["textarea.form-control {\n    height: auto!important;\n}"],"sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 10111:
/*!************************************************************************************************!*\
  !*** ./src/app/modules/number/number-addfslrules/number-addfslrules.component.scss?ngResource ***!
  \************************************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 55471:
/*!********************************************************************************************!*\
  !*** ./src/app/modules/number/number-batchedit/number-batchedit.component.scss?ngResource ***!
  \********************************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, ".myclass.custom-class {\n  padding: 0px !important;\n  height: 40px !important;\n}\n\ninput#option1, input#option2, input#option3 {\n  display: none;\n}\n\n.btn-group.form-control {\n  height: 60px;\n}", "",{"version":3,"sources":["webpack://./src/app/modules/number/number-batchedit/number-batchedit.component.scss"],"names":[],"mappings":"AAAA;EACI,uBAAA;EACA,uBAAA;AACJ;;AACA;EACI,aAAA;AAEJ;;AAAA;EACI,YAAA;AAGJ","sourcesContent":[".myclass.custom-class{\n    padding: 0px!important;\n    height: 40px !important;\n}\ninput#option1, input#option2, input#option3{\n    display: none;\n}    \n.btn-group.form-control {\n    height: 60px;\n}\n"],"sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 38052:
/*!************************************************************************************!*\
  !*** ./src/app/modules/number/number-buyer/number-buyer.component.scss?ngResource ***!
  \************************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 44559:
/*!**************************************************************************************!*\
  !*** ./src/app/modules/number/number-upload/number-upload.component.scss?ngResource ***!
  \**************************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, ".myclass.custom-class {\n  padding: 0px !important;\n  height: 40px !important;\n}\n\ninput#option1, input#option2, input#option3 {\n  display: none;\n}\n\n.btn-group.form-control {\n  height: 60px;\n}", "",{"version":3,"sources":["webpack://./src/app/modules/number/number-upload/number-upload.component.scss"],"names":[],"mappings":"AAAA;EACI,uBAAA;EACA,uBAAA;AACJ;;AACA;EACI,aAAA;AAEJ;;AAAA;EACI,YAAA;AAGJ","sourcesContent":[".myclass.custom-class{\n    padding: 0px!important;\n    height: 40px !important;\n}\ninput#option1, input#option2, input#option3{\n    display: none;\n}    \n.btn-group.form-control {\n    height: 60px;\n}\n"],"sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 94111:
/*!*****************************************************************!*\
  !*** ./src/app/modules/number/number.component.scss?ngResource ***!
  \*****************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, ".buttons-print {\n  margin-right: 33px !important;\n}\n\ntable td, table th {\n  font-size: 11px;\n}", "",{"version":3,"sources":["webpack://./src/app/modules/number/number.component.scss"],"names":[],"mappings":"AAAA;EACI,6BAAA;AACJ;;AAEA;EACI,eAAA;AACJ","sourcesContent":[".buttons-print{\n    margin-right: 33px!important;\n}\n\ntable td,table th {\n    font-size: 11px;\n}\n"],"sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 43969:
/*!******************************************************************************!*\
  !*** ./src/app/modules/number/numberadd/numberadd.component.scss?ngResource ***!
  \******************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "tbody tr th, td {\n  border-bottom: 1px solid #c7c7c7;\n}\n\nfieldset.scheduler-border {\n  border: 1px groove #ddd !important;\n  padding: 0 1.4em 1.4em 1.4em !important;\n  margin: 0 0 1.5em 0 !important;\n  box-shadow: 0px 0px 0px 0px #000;\n  border-radius: 10px !important;\n}\n\nlegend.scheduler-border {\n  font-size: 1.2em !important;\n  font-weight: bold !important;\n  text-align: left !important;\n  width: auto;\n  padding: 0 10px;\n  border-bottom: none;\n}\n\nth, td {\n  padding: 0px 10px 0px 10px !important;\n  height: 46px !important;\n  background: #2ea2d6;\n  vertical-align: middle;\n  color: white;\n  border-radius: 1px;\n  width: 310px;\n}\n\ninput#option1, input#option2, input#option3 {\n  display: none;\n}\n\n.btn-group.form-control {\n  height: 60px;\n}\n\n.formcontrol {\n  border: none;\n  border-bottom: 1px solid #ced4da;\n  border-radius: 0;\n  margin-top: -25px;\n}\n\n.formcontrolwithouticon {\n  border: none;\n  border-bottom: 1px solid #ced4da;\n  border-radius: 0;\n}\n\n.control-label {\n  font-size: 11px;\n}\n\ninput.form-control, select {\n  font-size: 11px !important;\n}\n\n@media (min-width: 320px) {\n  .form-check-label {\n    font-size: 11px;\n    margin-top: 7px;\n  }\n}\n.hofnumber {\n  width: 60px;\n  border: none;\n  background: #252d43 !important;\n  border-bottom: 1px solid gray;\n  border-radius: 0;\n}\n\ninput[type=number]::-webkit-inner-spin-button, input[type=number]::-webkit-outer-spin-button {\n  -webkit-appearance: none;\n  appearance: none;\n  margin: 0;\n}", "",{"version":3,"sources":["webpack://./src/app/modules/number/numberadd/numberadd.component.scss"],"names":[],"mappings":"AAcA;EACI,gCAAA;AAbJ;;AAeA;EACI,kCAAA;EACA,uCAAA;EACA,8BAAA;EAEA,gCAAA;EACA,8BAAA;AAZJ;;AAeA;EACI,2BAAA;EACA,4BAAA;EACA,2BAAA;EACA,WAAA;EACA,eAAA;EACA,mBAAA;AAZJ;;AAcA;EACI,qCAAA;EACA,uBAAA;EACA,mBAAA;EACA,sBAAA;EACA,YAAA;EACA,kBAAA;EACA,YAAA;AAXJ;;AAaA;EACI,aAAA;AAVJ;;AAYA;EACI,YAAA;AATJ;;AAWA;EACI,YAAA;EACA,gCAAA;EACA,gBAAA;EACA,iBAAA;AARJ;;AAUA;EACI,YAAA;EACA,gCAAA;EACA,gBAAA;AAPJ;;AASA;EACI,eAAA;AANJ;;AAQA;EACI,0BAAA;AALJ;;AAQA;EACG;IACK,eAAA;IACA,eAAA;EALN;AACF;AAOA;EACI,WAAA;EACA,YAAA;EACA,8BAAA;EACA,6BAAA;EACA,gBAAA;AALJ;;AAQA;EACI,wBAAA;EAEA,gBAAA;EACA,SAAA;AALJ","sourcesContent":["// .fortbl td{\n//     width: 28%!important;\n//     // padding-left: 85px!important;\n//     // padding-right: 85px!important;\n// }\n// .fortbl{\n// width: 132%!important;\n// }\n// .fortbl th{\n//     width: 28%!important;\n//     font-size: 13px;\n//     // padding-left: 85px!important;\n//     // padding-right: 85px!important;\n// }\ntbody tr th, td {\n    border-bottom: 1px solid #c7c7c7\n}\nfieldset.scheduler-border {\n    border: 1px groove #ddd !important;\n    padding: 0 1.4em 1.4em 1.4em !important;\n    margin: 0 0 1.5em 0 !important;\n    -webkit-box-shadow:  0px 0px 0px 0px #000;\n    box-shadow:  0px 0px 0px 0px #000;\n    border-radius: 10px!important;\n}\n\nlegend.scheduler-border {\n    font-size: 1.2em !important;\n    font-weight: bold !important;\n    text-align: left !important;\n    width:auto;\n    padding:0 10px;\n    border-bottom:none;\n}\nth,td{\n    padding: 0px 10px 0px 10px!important;\n    height: 46px!important;\n    background: #2ea2d6;\n    vertical-align: middle;\n    color: white;\n    border-radius: 1px;\n    width: 310px;\n}\ninput#option1, input#option2, input#option3{\n    display: none;\n}\n.btn-group.form-control {\n    height: 60px;\n}\n.formcontrol {\n    border: none;\n    border-bottom: 1px solid #ced4da;\n    border-radius: 0;\n    margin-top: -25px;\n}\n.formcontrolwithouticon {\n    border: none;\n    border-bottom: 1px solid #ced4da;\n    border-radius: 0;\n}\n.control-label {\n    font-size: 11px;\n}\ninput.form-control,select {\n    font-size: 11px!important;\n}\n\n@media (min-width:320px)  {\n   .form-check-label {\n        font-size: 11px;\n        margin-top: 7px;\n    }\n}\n.hofnumber{\n    width: 60px;\n    border: none;\n    background: #252d43!important;\n    border-bottom: 1px solid gray;\n    border-radius: 0;\n}\n\ninput[type=number]::-webkit-inner-spin-button, input[type=number]::-webkit-outer-spin-button {\n    -webkit-appearance: none;\n    -moz-appearance: none;\n    appearance: none;\n    margin: 0;\n}\n"],"sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 76803:
/*!********************************************************************************!*\
  !*** ./src/app/modules/number/numberedit/numberedit.component.scss?ngResource ***!
  \********************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "tbody tr th, td {\n  border-bottom: 1px solid #c7c7c7;\n}\n\nfieldset.scheduler-border {\n  border: 1px groove #ddd !important;\n  padding: 0 1.4em 1.4em 1.4em !important;\n  margin: 0 0 1.5em 0 !important;\n  box-shadow: 0px 0px 0px 0px #000;\n  border-radius: 10px !important;\n}\n\nlegend.scheduler-border {\n  font-size: 1.2em !important;\n  font-weight: bold !important;\n  text-align: left !important;\n  width: auto;\n  padding: 0 10px;\n  border-bottom: none;\n}\n\nth, td {\n  padding: 0px 10px 0px 10px !important;\n  height: 46px !important;\n  background: #2ea2d6;\n  vertical-align: middle;\n  color: white;\n  border-radius: 1px;\n}\n\ninput#option1, input#option2, input#option3 {\n  display: none;\n}\n\n.btn-group.form-control {\n  height: 60px;\n}\n\n.formcontrol {\n  border: none;\n  border-bottom: 1px solid #ced4da;\n  border-radius: 0;\n  margin-top: -25px;\n}\n\n.formcontrolwithouticon {\n  border: none;\n  border-bottom: 1px solid #ced4da;\n  border-radius: 0;\n}\n\n.control-label {\n  font-size: 11px;\n}\n\ninput.form-control, select {\n  font-size: 11px !important;\n}\n\n@media (min-width: 320px) {\n  .form-check-label {\n    font-size: 11px;\n    margin-top: 7px;\n  }\n}", "",{"version":3,"sources":["webpack://./src/app/modules/number/numberedit/numberedit.component.scss"],"names":[],"mappings":"AAAA;EACI,gCAAA;AACJ;;AACA;EACI,kCAAA;EACA,uCAAA;EACA,8BAAA;EAEA,gCAAA;EACA,8BAAA;AAEJ;;AACA;EACI,2BAAA;EACA,4BAAA;EACA,2BAAA;EACA,WAAA;EACA,eAAA;EACA,mBAAA;AAEJ;;AAAA;EACI,qCAAA;EACA,uBAAA;EACA,mBAAA;EACA,sBAAA;EACA,YAAA;EACA,kBAAA;AAGJ;;AADA;EACI,aAAA;AAIJ;;AAFA;EACI,YAAA;AAKJ;;AAHA;EACI,YAAA;EACA,gCAAA;EACA,gBAAA;EACA,iBAAA;AAMJ;;AAJA;EACI,YAAA;EACA,gCAAA;EACA,gBAAA;AAOJ;;AALA;EACI,eAAA;AAQJ;;AANA;EACI,0BAAA;AASJ;;AAPA;EACI;IACK,eAAA;IACA,eAAA;EAUP;AACF","sourcesContent":["tbody tr th, td {\n    border-bottom: 1px solid #c7c7c7\n}\nfieldset.scheduler-border {\n    border: 1px groove #ddd !important;\n    padding: 0 1.4em 1.4em 1.4em !important;\n    margin: 0 0 1.5em 0 !important;\n    -webkit-box-shadow:  0px 0px 0px 0px #000;\n    box-shadow:  0px 0px 0px 0px #000;\n    border-radius: 10px!important;\n}\n\nlegend.scheduler-border {\n    font-size: 1.2em !important;\n    font-weight: bold !important;\n    text-align: left !important;\n    width:auto;\n    padding:0 10px;\n    border-bottom:none;\n}\nth,td{\n    padding: 0px 10px 0px 10px!important;\n    height: 46px!important;\n    background: #2ea2d6;\n    vertical-align: middle;\n    color: white;\n    border-radius: 1px;\n}\ninput#option1, input#option2, input#option3{\n    display: none;\n}\n.btn-group.form-control {\n    height: 60px;\n}\n.formcontrol {\n    border: none;\n    border-bottom: 1px solid #ced4da;\n    border-radius: 0;\n    margin-top: -25px;\n}\n.formcontrolwithouticon {\n    border: none;\n    border-bottom: 1px solid #ced4da;\n    border-radius: 0;\n}\n.control-label {\n    font-size: 11px;\n}\ninput.form-control,select {\n    font-size: 11px!important;\n}\n@media (min-width:320px)  {\n    .form-check-label {\n         font-size: 11px;\n         margin-top: 7px;\n     }\n }\n"],"sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 69735:
/*!*******************************************************************************************!*\
  !*** ./src/app/modules/numbers/blocked-numbers/blocked-numbers.component.scss?ngResource ***!
  \*******************************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "fieldset.scheduler-border {\n  border: 1px groove #ddd !important;\n  padding: 0 1.4em 1.4em 1.4em !important;\n  margin: 0 0 1.5em 0 !important;\n  box-shadow: 0px 0px 0px 0px #000;\n  border-radius: 10px !important;\n}\n\nlegend.scheduler-border {\n  font-size: 1.2em !important;\n  font-weight: bold !important;\n  text-align: left !important;\n  width: auto;\n  padding: 0 10px;\n  border-bottom: none;\n}\n\ninput#option1, input#option2, input#option3 {\n  display: none;\n}\n\n.btn-group.form-control {\n  height: 60px;\n}\n\n.modal-dialog.model-lg {\n  max-width: 783px;\n}", "",{"version":3,"sources":["webpack://./src/app/modules/numbers/blocked-numbers/blocked-numbers.component.scss"],"names":[],"mappings":"AAAA;EACI,kCAAA;EACA,uCAAA;EACA,8BAAA;EAEQ,gCAAA;EACR,8BAAA;AACJ;;AAEA;EACI,2BAAA;EACA,4BAAA;EACA,2BAAA;EACA,WAAA;EACA,eAAA;EACA,mBAAA;AACJ;;AAEA;EACA,aAAA;AACA;;AACA;EACI,YAAA;AAEJ;;AAAA;EACI,gBAAA;AAGJ","sourcesContent":["fieldset.scheduler-border {\n    border: 1px groove #ddd !important;\n    padding: 0 1.4em 1.4em 1.4em !important;\n    margin: 0 0 1.5em 0 !important;\n    -webkit-box-shadow:  0px 0px 0px 0px #000;\n            box-shadow:  0px 0px 0px 0px #000;\n    border-radius: 10px!important;\n}\n\nlegend.scheduler-border {\n    font-size: 1.2em !important;\n    font-weight: bold !important;\n    text-align: left !important;\n    width:auto;\n    padding:0 10px;\n    border-bottom:none;\n}\n\ninput#option1, input#option2, input#option3{\ndisplay: none;\n}\n.btn-group.form-control {\n    height: 60px;\n}\n.modal-dialog.model-lg {\n    max-width: 783px;\n}\n"],"sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 50957:
/*!***********************************************************************************!*\
  !*** ./src/app/modules/numbers/number-pool/number-pool.component.scss?ngResource ***!
  \***********************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "input#option1, input#option2, input#option3 {\n  display: none;\n}\n\n.btn-group.form-control {\n  height: 60px;\n}", "",{"version":3,"sources":["webpack://./src/app/modules/numbers/number-pool/number-pool.component.scss"],"names":[],"mappings":"AAAA;EACI,aAAA;AACJ;;AACA;EACI,YAAA;AAEJ","sourcesContent":["input#option1, input#option2, input#option3{\n    display: none;\n}    \n.btn-group.form-control {\n    height: 60px;\n}"],"sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 75226:
/*!*******************************************************************!*\
  !*** ./src/app/modules/numbers/numbers.component.scss?ngResource ***!
  \*******************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "input#option1, input#option2, input#option3 {\n  display: none;\n}\n\n.btn-group.form-control {\n  height: 60px;\n}\n\ntable.dataTable img {\n  border: 1px solid #ffffff !important;\n}", "",{"version":3,"sources":["webpack://./src/app/modules/numbers/numbers.component.scss"],"names":[],"mappings":"AAAA;EACI,aAAA;AACJ;;AACA;EACI,YAAA;AAEJ;;AAOA;EACI,oCAAA;AAJJ","sourcesContent":["input#option1, input#option2, input#option3{\n    display: none;\n}    \n.btn-group.form-control {\n    height: 60px;\n}\n\n// .dropdown-list {\n//     position: absolute!important;\n//     padding-top: 14px;\n//     width: 100%;\n//     z-index: 99999;\n// }\ntable.dataTable img {\n    border: 1px solid #ffffff!important; \n}"],"sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 44445:
/*!************************************************************************************************!*\
  !*** ./src/app/modules/publishers/advertiser-terms/advertiser-terms.component.scss?ngResource ***!
  \************************************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 8030:
/*!****************************************************************************************************!*\
  !*** ./src/app/modules/publishers/publisher-settings/publisher-settings.component.scss?ngResource ***!
  \****************************************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 29662:
/*!**********************************************************************************************!*\
  !*** ./src/app/modules/publishers/publisher-terms/publisher-terms.component.scss?ngResource ***!
  \**********************************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "input.form-control {\n  border: none;\n  background: #1d2b4e;\n  border-bottom: 1px solid white;\n  border-radius: 0;\n  color: #888888;\n}\n\n.btn-primary {\n  background-color: #031131 !important;\n  border-color: transparent !important;\n  color: #fff !important;\n  box-shadow: none !important;\n}\n\n.custom-switch-indicator {\n  background: #3b74ad;\n}", "",{"version":3,"sources":["webpack://./src/app/modules/publishers/publisher-terms/publisher-terms.component.scss"],"names":[],"mappings":"AAAA;EACI,YAAA;EACA,mBAAA;EACA,8BAAA;EACA,gBAAA;EACA,cAAA;AACJ;;AACA;EACI,oCAAA;EACA,oCAAA;EACA,sBAAA;EACA,2BAAA;AAEJ;;AAAA;EACI,mBAAA;AAGJ","sourcesContent":["input.form-control {\n    border: none;\n    background: #1d2b4e;\n    border-bottom: 1px solid white;\n    border-radius: 0;\n    color: #888888;\n}\n.btn-primary {\n    background-color: #031131!important;\n    border-color: transparent !important;\n    color: #fff!important;\n    box-shadow: none!important;\n}\n.custom-switch-indicator {\n    background: #3b74ad;\n}"],"sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 39046:
/*!*************************************************************************!*\
  !*** ./src/app/modules/publishers/publishers.component.scss?ngResource ***!
  \*************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "input#option1, input#option2, input#option3 {\n  display: none;\n}\n\n.btn-group.form-control {\n  height: 60px;\n}", "",{"version":3,"sources":["webpack://./src/app/modules/publishers/publishers.component.scss"],"names":[],"mappings":"AAAA;EACI,aAAA;AACJ;;AACA;EACI,YAAA;AAEJ","sourcesContent":["input#option1, input#option2, input#option3{\n    display: none;\n}    \n.btn-group.form-control {\n    height: 60px;\n}"],"sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 86141:
/*!********************************************************************************!*\
  !*** ./src/app/modules/publishers/thankyou/thankyou.component.scss?ngResource ***!
  \********************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 80611:
/*!*************************************************************************!*\
  !*** ./src/app/modules/recordings/recordings.component.scss?ngResource ***!
  \*************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 28605:
/*!*****************************************************************************************!*\
  !*** ./src/app/modules/reports-comparison/reports-comparison.component.scss?ngResource ***!
  \*****************************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "i {\n  font-size: 14px;\n}\n\nspan.badge.badge-transparent {\n  font-size: 7px;\n  background: no-repeat;\n}\n\nbutton.btn.btn-primary.btn-icon.icon-left.mr-2 {\n  font-size: 15px;\n}\n\n/*Bhavik Patel*/\n.ngx-datatable .datatable-header {\n  display: block;\n  overflow: hidden;\n}\n\n.card .card-header .btn:not(.note-btn) {\n  border-radius: 4px;\n  width: 72px;\n  font-size: 10px;\n}\n\nbutton.btn.btn-primary.btn-icon.icon-left.mr-2 {\n  font-size: 12px;\n}\n\n.card .card-header .form-control {\n  width: auto !important;\n  border-radius: 0px !important;\n  height: 32px !important;\n}\n\nlabel.input-group-btn {\n  border: 1px solid #ced4da;\n  border-left: none;\n}\n\ntable td, table th {\n  font-size: 11px;\n}\n\n.error {\n  color: red;\n  font-size: 10px;\n}\n\nselect.form-control {\n  height: 38px !important;\n  font-size: 12px !important;\n  padding: 10px !important;\n}\n\nbutton.btn.btn-primary.btn-icon.icon-left.mr-2 {\n  font-size: 10px !important;\n}\n\ni.fa.fa-filter {\n  font-size: 8px;\n}\n\n.separator {\n  display: flex;\n  align-items: center;\n  text-align: center;\n}\n\n.separator::before,\n.separator::after {\n  content: \"\";\n  flex: 1;\n  border-bottom: 1px solid #000;\n}\n\n.separator:not(:empty)::before {\n  margin-right: 0.25em;\n}\n\n.separator:not(:empty)::after {\n  margin-left: 0.25em;\n}\n\nul.nav.nav-tabs li {\n  padding: 5px;\n  border: 1px solid #dee2e6;\n  border-bottom: none;\n  border-radius: 3px;\n}\n\n.tab-pane.fade.recorded.active.show {\n  font-size: 10px !important;\n}\n\n.nav-tabs {\n  border-bottom: 1px solid #3e4b75 !important;\n}\n\n.col-md-1 {\n  padding: 3px;\n  text-align: center !important;\n}\n\n.datatable-row-detail {\n  display: flex;\n}\n\nngb-tooltip-window .tooltip-inner {\n  pointer-events: auto;\n  width: 60px;\n  display: flex;\n  margin-top: 20px !important;\n}\n\n.material-icons {\n  font-size: 14px;\n}\n\n@media (max-width: 641px) {\n  .buttons_input {\n    text-align: start;\n  }\n}\n.buttons_input button {\n  padding: 3px !important;\n}\n\n#toast-container > div {\n  box-shadow: 0 4px 25px 0 rgba(0, 0, 0, 0.1);\n  padding: 13px 20px 10px 0px;\n  opacity: 1;\n  background: #ffffff;\n  border-radius: 8px;\n}\n\naudio::-webkit-media-controls-play-button,\naudio::-webkit-media-controls-panel {\n  background-color: #ffffff;\n  color: #000;\n}\n\n.toast-title {\n  font-weight: bold;\n  padding-left: 19px;\n  color: #000;\n}\n\nbutton.toast-close-button {\n  color: black;\n}\n\n.dark .ngx-datatable.fixed-header .datatable-header .datatable-header-inner .datatable-header-cell {\n  background: #111319;\n  color: white;\n}\n\n.dark .ngx-datatable .datatable-footer .datatable-footer-inner {\n  color: #ffffff;\n  background: #111319;\n}\n\n.dark .ngx-datatable.material .datatable-footer .datatable-pager a {\n  color: rgba(255, 255, 255, 0.54);\n}\n\n.dark .ngx-datatable.material .datatable-body .datatable-row-detail {\n  background: #111319;\n  padding: 10px;\n  color: white;\n}\n\n.dark .ngx-datatable.material {\n  background: #111319;\n}\n\n.dark .ngx-datatable.material .datatable-body .datatable-body-row .datatable-body-cell {\n  color: rgba(255, 255, 255, 0.87) !important;\n  background: #111319 !important;\n}", "",{"version":3,"sources":["webpack://./src/app/modules/reports-comparison/reports-comparison.component.scss"],"names":[],"mappings":"AAAA;EACI,eAAA;AACJ;;AACA;EACI,cAAA;EACA,qBAAA;AAEJ;;AACA;EAGA,eAAA;AAAA;;AAGA,eAAA;AACA;EACI,cAAA;EACA,gBAAA;AAAJ;;AAEA;EACI,kBAAA;EACA,WAAA;EACA,eAAA;AACJ;;AACA;EACI,eAAA;AAEJ;;AAAA;EACI,sBAAA;EACA,6BAAA;EAEA,uBAAA;AAEJ;;AACA;EACI,yBAAA;EACA,iBAAA;AAEJ;;AAAA;EACI,eAAA;AAGJ;;AAAA;EACI,UAAA;EACA,eAAA;AAGJ;;AADA;EACI,uBAAA;EACA,0BAAA;EACA,wBAAA;AAIJ;;AAFA;EACI,0BAAA;AAKJ;;AAHA;EACI,cAAA;AAMJ;;AAHA;EACI,aAAA;EACA,mBAAA;EACA,kBAAA;AAMJ;;AAHE;;EAEE,WAAA;EACA,OAAA;EACA,6BAAA;AAMJ;;AAHE;EACE,oBAAA;AAMJ;;AAHE;EACE,mBAAA;AAMJ;;AAHE;EAAoB,YAAA;EAClB,yBAAA;EACA,mBAAA;EACA,kBAAA;AAOJ;;AALA;EACI,0BAAA;AAQJ;;AANA;EACI,2CAAA;AASJ;;AALA;EACI,YAAA;EACA,6BAAA;AAQJ;;AAJA;EACI,aAAA;AAOJ;;AALA;EACI,oBAAA;EACA,WAAA;EACA,aAAA;EACA,2BAAA;AAQJ;;AAFA;EACI,eAAA;AAKJ;;AAHA;EACA;IACI,iBAAA;EAMF;AACF;AAJA;EACI,uBAAA;AAMJ;;AAgCA;EACI,2CAAA;EACA,2BAAA;EACA,UAAA;EACA,mBAAA;EACA,kBAAA;AA7BJ;;AA+BI;;EAEA,yBAAA;EACA,WAAA;AA5BJ;;AA+BI;EACA,iBAAA;EACA,kBAAA;EACA,WAAA;AA5BJ;;AA+BA;EACI,YAAA;AA5BJ;;AA+BA;EACI,mBAAA;EACA,YAAA;AA5BJ;;AA+BA;EACI,cAAA;EACA,mBAAA;AA5BJ;;AA8BA;EACI,gCAAA;AA3BJ;;AA8BA;EACI,mBAAA;EACA,aAAA;EACA,YAAA;AA3BJ;;AA8BA;EACI,mBAAA;AA3BJ;;AA6BA;EACI,2CAAA;EACA,8BAAA;AA1BJ","sourcesContent":["i{\n    font-size: 14px;\n}\nspan.badge.badge-transparent {\n    font-size: 7px;\n    background: no-repeat;\n}\n\nbutton.btn.btn-primary.btn-icon.icon-left.mr-2{\n// width: 164px;\n// height: 67px;\nfont-size: 15px;\n\n}\n/*Bhavik Patel*/\n.ngx-datatable .datatable-header {\n    display: block;\n    overflow: hidden;\n}\n.card .card-header .btn:not(.note-btn) {\n    border-radius: 4px;\n    width: 72px;\n    font-size: 10px;\n}\nbutton.btn.btn-primary.btn-icon.icon-left.mr-2{\n    font-size: 12px;\n}\n.card .card-header .form-control {\n    width: auto!important;\n    border-radius: 0px!important;\n    // border-right: none;\n    height: 32px!important;    \n}\n\nlabel.input-group-btn {\n    border: 1px solid #ced4da;\n    border-left: none;\n}\ntable td,table th {\n    font-size: 11px;\n}\n\n.error{\n    color:red;\n    font-size: 10px;\n}\nselect.form-control{\n    height: 38px!important;\n    font-size: 12px!important;\n    padding: 10px!important;\n}\nbutton.btn.btn-primary.btn-icon.icon-left.mr-2{\n    font-size: 10px!important;\n}\ni.fa.fa-filter {\n    font-size: 8px;\n}\n\n.separator {\n    display: flex;\n    align-items: center;\n    text-align: center;\n  }\n  \n  .separator::before,\n  .separator::after {\n    content: '';\n    flex: 1;\n    border-bottom: 1px solid #000;\n  }\n  \n  .separator:not(:empty)::before {\n    margin-right: .25em;\n  }\n  \n  .separator:not(:empty)::after {\n    margin-left: .25em;\n  }\n  \n  ul.nav.nav-tabs li {padding: 5px;\n    border: 1px solid #dee2e6;\n    border-bottom: none;\n    border-radius: 3px;\n}\n.tab-pane.fade.recorded.active.show {\n    font-size: 10px!important;\n}\n.nav-tabs {\n    border-bottom: 1px solid #3e4b75!important;\n}\n\n\n.col-md-1{\n    padding: 3px;\n    text-align: center!important;\n}\n\n\n.datatable-row-detail {\n    display: flex;\n}\nngb-tooltip-window .tooltip-inner {\n    pointer-events: auto;\n    width: 60px;\n    display: flex;\n    margin-top: 20px!important;\n}\ndatatable-body.datatable-body {\n    // padding-top: 17px;\n}\n\n.material-icons {\n    font-size: 14px;    \n}\n@media (max-width:641px)  {\n.buttons_input {\n    text-align: start;        \n}\n}\n.buttons_input button{\n    padding: 3px!important;\n}\n\n\n\n// @media only screen \n//   and (min-device-width: 1400px) \n//   and (max-device-width: 2000px)\n// {\n// #wrapper {\n//     width: 1530px;\n//   overflow-x: scroll;\n//   }\n  \n//   #content {\n//     width: 2500px;    \n//   }\n// }\n\n// @media only screen \n//   and (min-device-width: 300px) \n//   and (max-device-width: 1400px)\n// {\n//  #wrapper {\n//     width: 1000px;\n//   overflow-x: scroll;\n//  }\n  \n//   #content {\n//     width: 2500px;    \n//   }\n// }\n\n// .ngx-datatable {\n//     border-left: 1px solid #EEEEEE;\n//   }\n\n\n#toast-container>div {\n    box-shadow: 0 4px 25px 0 rgb(0 0 0 / 10%);\n    padding: 13px 20px 10px 0px;\n    opacity: 1;\n    background: #ffffff;\n    border-radius: 8px;\n    }\n    audio::-webkit-media-controls-play-button,\n    audio::-webkit-media-controls-panel {\n    background-color: #ffffff;\n    color: #000;\n    }\n\n    .toast-title {\n    font-weight: bold;\n    padding-left: 19px;\n    color: #000;\n}\n\nbutton.toast-close-button {\n    color: black;\n}\n\n.dark .ngx-datatable.fixed-header .datatable-header .datatable-header-inner .datatable-header-cell {\n    background: #111319;\n    color: white;\n}\n\n.dark .ngx-datatable .datatable-footer .datatable-footer-inner {\n    color: #ffffff;\n    background: #111319;\n}\n.dark .ngx-datatable.material .datatable-footer .datatable-pager a {\n    color: rgb(255 255 255 / 54%); \n}\n\n.dark .ngx-datatable.material .datatable-body .datatable-row-detail {\n    background: #111319;\n    padding: 10px;\n    color: white;\n}\n\n.dark .ngx-datatable.material{\n    background: #111319;\n}\n.dark .ngx-datatable.material .datatable-body .datatable-body-row .datatable-body-cell {\n    color: rgb(255 255 255 / 87%)!important;\n    background: #111319!important;\n}\n\n\n"],"sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 13153:
/*!*************************************************************************************!*\
  !*** ./src/app/modules/reports/report-calls/report-calls.component.scss?ngResource ***!
  \*************************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 43792:
/*!***************************************************************************************************!*\
  !*** ./src/app/modules/reports/report-labelsummary/report-labelsummary.component.scss?ngResource ***!
  \***************************************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 53470:
/*!*******************************************************************!*\
  !*** ./src/app/modules/reports/reports.component.scss?ngResource ***!
  \*******************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "i {\n  font-size: 14px;\n}\n\nspan.badge.badge-transparent {\n  font-size: 7px;\n  background: no-repeat;\n}\n\n/*Bhavik Patel*/\n.ngx-datatable .datatable-header {\n  display: block;\n  overflow: hidden;\n}\n\n.card .card-header .btn:not(.note-btn) {\n  border-radius: 4px;\n  width: 72px;\n  font-size: 10px;\n}\n\nbutton.btn.btn-primary.btn-icon.icon-left.mr-2 {\n  font-size: 10px !important;\n  border: 1px solid #3a3a3a !important;\n}\n\n.card .card-header .form-control {\n  border-radius: 0px !important;\n  height: 36px !important;\n}\n\nlabel.input-group-btn {\n  border: 1px solid #ced4da;\n  border-left: none;\n}\n\ntable td, table th {\n  font-size: 11px;\n}\n\n.error {\n  color: red;\n  font-size: 10px;\n}\n\nselect.form-control {\n  height: 38px !important;\n  font-size: 12px !important;\n  padding: 10px !important;\n}\n\nbutton.btn.btn-primary {\n  font-size: 10px !important;\n  background: #262b42;\n}\n\ni.fa.fa-filter {\n  font-size: 8px;\n}\n\n.separator {\n  display: flex;\n  align-items: center;\n  text-align: center;\n}\n\n.separator::before,\n.separator::after {\n  content: \"\";\n  flex: 1;\n  border-bottom: 1px solid #000;\n}\n\n.separator:not(:empty)::before {\n  margin-right: 0.25em;\n}\n\n.separator:not(:empty)::after {\n  margin-left: 0.25em;\n}\n\nul.nav.nav-tabs li {\n  padding: 5px;\n  border: 1px solid #dee2e6;\n  border-bottom: none;\n  border-radius: 3px;\n}\n\n.tab-pane.fade.recorded.active.show {\n  font-size: 10px !important;\n}\n\n.nav-tabs {\n  border-bottom: 1px solid #3e4b75 !important;\n}\n\n.col-md-1 {\n  padding: 3px;\n  text-align: center !important;\n}\n\n.datatable-row-detail {\n  display: flex;\n}\n\nngb-tooltip-window .tooltip-inner {\n  pointer-events: auto;\n  width: 60px;\n  display: flex;\n  margin-top: 20px !important;\n}\n\n.material-icons {\n  font-size: 14px;\n}\n\n@media (max-width: 641px) {\n  .buttons_input {\n    text-align: start;\n  }\n}\n.buttons_input button {\n  padding: 3px !important;\n}\n\n#toast-container > div {\n  box-shadow: 0 4px 25px 0 rgba(0, 0, 0, 0.1);\n  opacity: 1;\n  border-radius: 8px;\n}\n\naudio::-webkit-media-controls-play-button,\naudio::-webkit-media-controls-panel {\n  background-color: #ffffff;\n  color: #000;\n}\n\n.toast-title {\n  font-weight: bold;\n  padding-left: 19px;\n  color: #000;\n}\n\nbutton.toast-close-button {\n  color: black;\n}\n\n.dark .ngx-datatable.fixed-header .datatable-header .datatable-header-inner .datatable-header-cell {\n  background: #111319;\n  color: white;\n}\n\n.dark .ngx-datatable .datatable-footer .datatable-footer-inner {\n  color: #ffffff;\n  background: #111319;\n}\n\n.dark .ngx-datatable.material .datatable-footer .datatable-pager a {\n  color: rgba(255, 255, 255, 0.54);\n}\n\n.dark .ngx-datatable.material .datatable-body .datatable-row-detail {\n  background: #111319;\n  padding: 10px;\n  color: white;\n}\n\n.dark .ngx-datatable.material {\n  background: #111319;\n}\n\n.dark .ngx-datatable.material .datatable-body .datatable-body-row .datatable-body-cell {\n  color: rgba(255, 255, 255, 0.87) !important;\n  background: #111319 !important;\n}\n\n.md-drppicker.drops-down-auto.ltr.shown.double {\n  top: 43px !important;\n  width: 615px !important;\n  left: 0px !important;\n}\n\n.md-drppicker.drops-down-auto.ltr.shown {\n  top: 43px !important;\n  left: 0px !important;\n}\n\nselect.form-control {\n  height: 37px !important;\n}\n\n.daterangepicker {\n  padding: 17px !important;\n  border-radius: 2px 0 0 2px !important;\n}\n\n.dark select.form-control {\n  background: #3E4464 !important;\n  border: none;\n}\n\n.formcontrol {\n  border: none;\n  border-bottom: 1px solid #ced4da;\n  border-radius: 0;\n}\n\n.filterdd .selected-list .c-btn {\n  background: #3e4464 !important;\n  border: none;\n}\n\n.filterdd .dark .list-area {\n  background: #2c3354 !important;\n}\n\n.dark .list-filter input {\n  background: #353d62 !important;\n  color: white !important;\n}\n\n.filterdd .list-filter {\n  border-bottom: 1px solid #707070;\n  background: #353d62 !important;\n}\n\n.dark .list-area {\n  border: none !important;\n  background: #353d62 !important;\n}\n\n.nodata-label {\n  color: white;\n}\n\ninput.form-control.daterangepicker {\n  background: #3e4464 !important;\n  border: none;\n}\n\n.leftborder {\n  padding: 11px;\n  margin: 9px 0;\n  border-left: 1px solid #3858e7;\n  border-left-width: 7px;\n  border-radius: 3px;\n  border-right: 1px solid #2f3031 !important;\n  border-top: 1px solid #2f3031 !important;\n  border-bottom: 1px solid #2f3031 !important;\n}\n\n.tab-content td {\n  width: 30% !important;\n}\n\n.whitestatusarrow {\n  position: absolute;\n  top: 0;\n  left: 0;\n  width: 0;\n  height: 0;\n  border-style: solid;\n  border-width: 8px 8px 0 0;\n  border-color: white transparent transparent transparent;\n}\n\n.yellowstatusarrow {\n  position: absolute;\n  top: 0;\n  left: 0;\n  width: 0;\n  height: 0;\n  border-style: solid;\n  border-width: 8px 8px 0 0;\n  border-color: #b78c0b transparent transparent transparent;\n}\n\n.redstatusarrow {\n  position: absolute;\n  top: 0;\n  left: 0;\n  width: 0;\n  height: 0;\n  border-style: solid;\n  border-width: 8px 8px 0 0;\n  border-color: #933132 transparent transparent transparent;\n}\n\n.greenstatusarrow {\n  position: absolute;\n  top: 0;\n  left: 0;\n  width: 0;\n  height: 0;\n  border-style: solid;\n  border-width: 8px 8px 0 0;\n  border-color: green transparent transparent transparent;\n}\n\n.ng-trigger.ng-trigger-flyInOut.ngx-toastr {\n  background-color: white !important;\n  color: black;\n}\n\n#toast-container > div {\n  padding: 20px 20px 20px 5px !important;\n}\n\n.bg-blue {\n  background-color: #375ee2 !important;\n}\n\n.filtertags .selected-list .c-btn {\n  border: none;\n  border-radius: 0 !important;\n  width: auto;\n  font-size: 10px;\n  margin: -4px;\n  min-width: 60px;\n  padding-right: 25px !important;\n}\n\n.filtertags .list-area {\n  background: #2c3354 !important;\n  width: 536px !important;\n}\n\n.filtertags .list-filter input {\n  background: #353d62 !important;\n  color: white !important;\n  width: 500px;\n}\n\n.filtertags .nodata-label {\n  width: 536px;\n  background: #353e60;\n}\n\n.filtertags .list-filter {\n  border-bottom: 1px solid #707070;\n  background: #353d62 !important;\n}\n\n.filtertags .clear-all {\n  right: 10px !important;\n}\n\n.filtertags .clear-all svg {\n  fill: white !important;\n}\n\nangular2-multiselect#tabs9 {\n  padding: 0 !important;\n}\n\ndatatable-body-row.datatable-body-row.active {\n  opacity: 0.3 !important;\n}\n\n.datatable-row-wrapper.datatable-row-wrapper {\n  background-color: #3858E7 !important;\n}\n\n.ngx-datatable.material.single-selection .datatable-body-row.active,\n.ngx-datatable.material.single-selection .datatable-body-row.active .datatable-row-group,\n.ngx-datatable.material.multi-selection .datatable-body-row.active,\n.ngx-datatable.material.multi-selection .datatable-body-row.active .datatable-row-group, .ngx-datatable.material.multi-click-selection .datatable-body-row.active,\n.ngx-datatable.material.multi-click-selection .datatable-body-row.active .datatable-row-group {\n  background-color: inherit !important;\n}\n\n.ngx-datatable.material.single-selection .datatable-body-row.active:hover,\n.ngx-datatable.material.single-selection .datatable-body-row.active:hover .datatable-row-group, .ngx-datatable.material.multi-selection .datatable-body-row.active:hover,\n.ngx-datatable.material.multi-selection .datatable-body-row.active:hover .datatable-row-group, .ngx-datatable.material.multi-click-selection .datatable-body-row.active:hover,\n.ngx-datatable.material.multi-click-selection .datatable-body-row.active:hover .datatable-row-group {\n  background-color: inherit !important;\n}", "",{"version":3,"sources":["webpack://./src/app/modules/reports/reports.component.scss"],"names":[],"mappings":"AAAA;EACI,eAAA;AACJ;;AACA;EACI,cAAA;EACA,qBAAA;AAEJ;;AACA,eAAA;AACA;EACI,cAAA;EACA,gBAAA;AAEJ;;AAAA;EACI,kBAAA;EACA,WAAA;EACA,eAAA;AAGJ;;AADA;EACI,0BAAA;EACA,oCAAA;AAIJ;;AAFA;EAEI,6BAAA;EAEA,uBAAA;AAGJ;;AAAA;EACI,yBAAA;EACA,iBAAA;AAGJ;;AADA;EACI,eAAA;AAIJ;;AADA;EACI,UAAA;EACA,eAAA;AAIJ;;AAFA;EACI,uBAAA;EACA,0BAAA;EACA,wBAAA;AAKJ;;AAHA;EACI,0BAAA;EACA,mBAAA;AAMJ;;AAJA;EACI,cAAA;AAOJ;;AAJA;EACI,aAAA;EACA,mBAAA;EACA,kBAAA;AAOJ;;AAJE;;EAEE,WAAA;EACA,OAAA;EACA,6BAAA;AAOJ;;AAJE;EACE,oBAAA;AAOJ;;AAJE;EACE,mBAAA;AAOJ;;AAJE;EAAoB,YAAA;EAClB,yBAAA;EACA,mBAAA;EACA,kBAAA;AAQJ;;AANA;EACI,0BAAA;AASJ;;AAPA;EACI,2CAAA;AAUJ;;AANA;EACI,YAAA;EACA,6BAAA;AASJ;;AALA;EACI,aAAA;AAQJ;;AANA;EACI,oBAAA;EACA,WAAA;EACA,aAAA;EACA,2BAAA;AASJ;;AAHA;EACI,eAAA;AAMJ;;AAJA;EACA;IACI,iBAAA;EAOF;AACF;AALA;EACI,uBAAA;AAOJ;;AA+BA;EACI,2CAAA;EAEA,UAAA;EAEA,kBAAA;AA9BJ;;AAgCI;;EAEA,yBAAA;EACA,WAAA;AA7BJ;;AAgCI;EACA,iBAAA;EACA,kBAAA;EACA,WAAA;AA7BJ;;AAgCA;EACI,YAAA;AA7BJ;;AAgCA;EACI,mBAAA;EACA,YAAA;AA7BJ;;AAgCA;EACI,cAAA;EACA,mBAAA;AA7BJ;;AA+BA;EACI,gCAAA;AA5BJ;;AA+BA;EACI,mBAAA;EACA,aAAA;EACA,YAAA;AA5BJ;;AA+BA;EACI,mBAAA;AA5BJ;;AA8BA;EACI,2CAAA;EACA,8BAAA;AA3BJ;;AA8BA;EACI,oBAAA;EACA,uBAAA;EACA,oBAAA;AA3BJ;;AA8BA;EACI,oBAAA;EACA,oBAAA;AA3BJ;;AA+BA;EACI,uBAAA;AA5BJ;;AA8BA;EACI,wBAAA;EACA,qCAAA;AA3BJ;;AA6BA;EACI,8BAAA;EACA,YAAA;AA1BJ;;AA4BA;EACI,YAAA;EACA,gCAAA;EACA,gBAAA;AAzBJ;;AA+BA;EACI,8BAAA;EACA,YAAA;AA5BJ;;AA8BC;EACG,8BAAA;AA3BJ;;AA8BA;EACI,8BAAA;EACA,uBAAA;AA3BJ;;AA8BA;EACI,gCAAA;EACA,8BAAA;AA3BJ;;AA8BA;EACI,uBAAA;EACA,8BAAA;AA3BJ;;AA6BA;EACI,YAAA;AA1BJ;;AA4BA;EACI,8BAAA;EACA,YAAA;AAzBJ;;AA4BA;EACI,aAAA;EACA,aAAA;EACA,8BAAA;EACA,sBAAA;EACA,kBAAA;EACA,0CAAA;EACA,wCAAA;EACA,2CAAA;AAzBJ;;AA4BA;EACI,qBAAA;AAzBJ;;AA6BA;EACI,kBAAA;EACA,MAAA;EACA,OAAA;EACA,QAAA;EACA,SAAA;EACA,mBAAA;EACA,yBAAA;EACA,uDAAA;AA1BJ;;AA4BA;EACI,kBAAA;EACA,MAAA;EACA,OAAA;EACA,QAAA;EACA,SAAA;EACA,mBAAA;EACA,yBAAA;EACA,yDAAA;AAzBJ;;AA2BA;EACI,kBAAA;EACA,MAAA;EACA,OAAA;EACA,QAAA;EACA,SAAA;EACA,mBAAA;EACA,yBAAA;EACA,yDAAA;AAxBJ;;AA0BA;EACI,kBAAA;EACA,MAAA;EACA,OAAA;EACA,QAAA;EACA,SAAA;EACA,mBAAA;EACA,yBAAA;EACA,uDAAA;AAvBJ;;AA0BA;EACI,kCAAA;EACA,YAAA;AAvBJ;;AAyBA;EACI,sCAAA;AAtBJ;;AAyBA;EACI,oCAAA;AAtBJ;;AA0BA;EAEI,YAAA;EACA,2BAAA;EACA,WAAA;EACA,eAAA;EACA,YAAA;EACA,eAAA;EACA,8BAAA;AAxBJ;;AA0BC;EACG,8BAAA;EACA,uBAAA;AAvBJ;;AA0BA;EACI,8BAAA;EACA,uBAAA;EACA,YAAA;AAvBJ;;AA0BA;EACI,YAAA;EACA,mBAAA;AAvBJ;;AA0BA;EACI,gCAAA;EACA,8BAAA;AAvBJ;;AA6BA;EACI,sBAAA;AA1BJ;;AA4BA;EACI,sBAAA;AAzBJ;;AA4BA;EACI,qBAAA;AAzBJ;;AA6BA;EACE,uBAAA;AA1BF;;AAuCA;EACE,oCAAA;AApCF;;AAuCA;;;;;EAKI,oCAAA;AApCJ;;AAsCA;;;;EAII,oCAAA;AAnCJ","sourcesContent":["i{\n    font-size: 14px;\n}\nspan.badge.badge-transparent {\n    font-size: 7px;\n    background: no-repeat;\n}\n\n/*Bhavik Patel*/\n.ngx-datatable .datatable-header {\n    display: block;\n    overflow: hidden;\n}\n.card .card-header .btn:not(.note-btn) {\n    border-radius: 4px;\n    width: 72px;\n    font-size: 10px;\n}\nbutton.btn.btn-primary.btn-icon.icon-left.mr-2{\n    font-size: 10px!important;\n    border: 1px solid #3a3a3a!important;\n}\n.card .card-header .form-control {\n    // width: auto!important;\n    border-radius: 0px!important;\n    // border-right: none;\n    height: 36px!important;\n}\n\nlabel.input-group-btn {\n    border: 1px solid #ced4da;\n    border-left: none;\n}\ntable td,table th {\n    font-size: 11px;\n}\n\n.error{\n    color:red;\n    font-size: 10px;\n}\nselect.form-control{\n    height: 38px!important;\n    font-size: 12px!important;\n    padding: 10px!important;\n}\nbutton.btn.btn-primary{\n    font-size: 10px!important;\n    background: #262b42;\n}\ni.fa.fa-filter {\n    font-size: 8px;\n}\n\n.separator {\n    display: flex;\n    align-items: center;\n    text-align: center;\n  }\n\n  .separator::before,\n  .separator::after {\n    content: '';\n    flex: 1;\n    border-bottom: 1px solid #000;\n  }\n\n  .separator:not(:empty)::before {\n    margin-right: .25em;\n  }\n\n  .separator:not(:empty)::after {\n    margin-left: .25em;\n  }\n\n  ul.nav.nav-tabs li {padding: 5px;\n    border: 1px solid #dee2e6;\n    border-bottom: none;\n    border-radius: 3px;\n}\n.tab-pane.fade.recorded.active.show {\n    font-size: 10px!important;\n}\n.nav-tabs {\n    border-bottom: 1px solid #3e4b75!important;\n}\n\n\n.col-md-1{\n    padding: 3px;\n    text-align: center!important;\n}\n\n\n.datatable-row-detail {\n    display: flex;\n}\nngb-tooltip-window .tooltip-inner {\n    pointer-events: auto;\n    width: 60px;\n    display: flex;\n    margin-top: 20px!important;\n}\ndatatable-body.datatable-body {\n    // padding-top: 17px;\n}\n\n.material-icons {\n    font-size: 14px;\n}\n@media (max-width:641px)  {\n.buttons_input {\n    text-align: start;\n}\n}\n.buttons_input button{\n    padding: 3px!important;\n}\n\n\n\n// @media only screen\n//   and (min-device-width: 1400px)\n//   and (max-device-width: 2000px)\n// {\n// #wrapper {\n//     width: 1530px;\n//   overflow-x: scroll;\n//   }\n\n//   #content {\n//     width: 2500px;\n//   }\n// }\n\n// @media only screen\n//   and (min-device-width: 300px)\n//   and (max-device-width: 1400px)\n// {\n//  #wrapper {\n//     width: 1000px;\n//   overflow-x: scroll;\n//  }\n\n//   #content {\n//     width: 2500px;\n//   }\n// }\n\n// .ngx-datatable {\n//     border-left: 1px solid #EEEEEE;\n//   }\n\n\n#toast-container>div {\n    box-shadow: 0 4px 25px 0 rgb(0 0 0 / 10%);\n    // padding: 13px 20px 10px 0px;\n    opacity: 1;\n    // background: #ffffff;\n    border-radius: 8px;\n    }\n    audio::-webkit-media-controls-play-button,\n    audio::-webkit-media-controls-panel {\n    background-color: #ffffff;\n    color: #000;\n    }\n\n    .toast-title {\n    font-weight: bold;\n    padding-left: 19px;\n    color: #000;\n}\n\nbutton.toast-close-button {\n    color: black;\n}\n\n.dark .ngx-datatable.fixed-header .datatable-header .datatable-header-inner .datatable-header-cell {\n    background: #111319;\n    color: white;\n}\n\n.dark .ngx-datatable .datatable-footer .datatable-footer-inner {\n    color: #ffffff;\n    background: #111319;\n}\n.dark .ngx-datatable.material .datatable-footer .datatable-pager a {\n    color: rgb(255 255 255 / 54%);\n}\n\n.dark .ngx-datatable.material .datatable-body .datatable-row-detail {\n    background: #111319;\n    padding: 10px;\n    color: white;\n}\n\n.dark .ngx-datatable.material{\n    background: #111319;\n}\n.dark .ngx-datatable.material .datatable-body .datatable-body-row .datatable-body-cell {\n    color: rgb(255 255 255 / 87%)!important;\n    background: #111319!important;\n}\n\n.md-drppicker.drops-down-auto.ltr.shown.double{\n    top: 43px!important;\n    width: 615px!important;\n    left: 0px!important;\n}\n\n.md-drppicker.drops-down-auto.ltr.shown{\n    top: 43px!important;\n    left: 0px!important;\n}\n\n\nselect.form-control {\n    height: 37px!important;\n}\n.daterangepicker{\n    padding: 17px!important;\n    border-radius: 2px 0 0 2px!important;\n}\n.dark select.form-control{\n    background: #3E4464!important;\n    border: none;\n}\n.formcontrol {\n    border: none;\n    border-bottom: 1px solid #ced4da;\n    border-radius: 0;\n}\n// li.pure-checkbox {\n//     padding: 0px 0px 0px 12px !important;\n//     border-bottom: none;\n// }\n.filterdd .selected-list .c-btn{\n    background: #3e4464!important;\n    border: none;\n }\n .filterdd .dark .list-area {\n    background: #2c3354 !important;\n}\n\n.dark .list-filter input {\n    background: #353d62 !important;\n    color: white !important;\n}\n\n.filterdd .list-filter{\n    border-bottom: 1px solid #707070;\n    background: #353d62 !important;\n}\n\n.dark .list-area{\n    border: none!important;\n    background: #353d62 !important;\n}\n.nodata-label {\n    color: white;\n}\ninput.form-control.daterangepicker {\n    background: #3e4464!important;\n    border: none;\n}\n\n.leftborder {\n    padding: 11px;\n    margin: 9px 0;\n    border-left: 1px solid #3858e7;\n    border-left-width: 7px;\n    border-radius: 3px;\n    border-right: 1px solid #2f3031!important;\n    border-top: 1px solid #2f3031!important;\n    border-bottom: 1px solid #2f3031!important;\n}\n\n.tab-content td {\n    width: 30%!important;\n}\n\n\n.whitestatusarrow {\n    position: absolute;\n    top: 0;\n    left: 0;\n    width: 0;\n    height: 0;\n    border-style: solid;\n    border-width: 8px 8px 0 0;\n    border-color: white transparent transparent transparent;\n}\n.yellowstatusarrow {\n    position: absolute;\n    top: 0;\n    left: 0;\n    width: 0;\n    height: 0;\n    border-style: solid;\n    border-width: 8px 8px 0 0;\n    border-color: #b78c0b transparent transparent transparent;\n}\n.redstatusarrow {\n    position: absolute;\n    top: 0;\n    left: 0;\n    width: 0;\n    height: 0;\n    border-style: solid;\n    border-width: 8px 8px 0 0;\n    border-color: #933132 transparent transparent transparent;\n}\n.greenstatusarrow {\n    position: absolute;\n    top: 0;\n    left: 0;\n    width: 0;\n    height: 0;\n    border-style: solid;\n    border-width: 8px 8px 0 0;\n    border-color: green transparent transparent transparent;\n}\n\n.ng-trigger.ng-trigger-flyInOut.ngx-toastr{\n    background-color: white!important;\n    color: black;\n}\n#toast-container>div {\n    padding: 20px 20px 20px 5px!important;\n}\n\n.bg-blue {\n    background-color: #375ee2 !important;\n}\n\n\n.filtertags .selected-list .c-btn {\n    // background: #30353e !important;\n    border: none;\n    border-radius: 0!important;\n    width: auto;\n    font-size: 10px;\n    margin: -4px;\n    min-width: 60px;\n    padding-right: 25px!important;\n}\n .filtertags .list-area {\n    background: #2c3354 !important;\n    width: 536px!important;\n}\n\n.filtertags .list-filter input {\n    background: #353d62 !important;\n    color: white !important;\n    width: 500px;\n}\n\n.filtertags .nodata-label {\n    width: 536px;\n    background: #353e60;\n}\n\n.filtertags .list-filter{\n    border-bottom: 1px solid #707070;\n    background: #353d62 !important;\n}\n\n// .filtertags .selected-list .c-angle-down, .selected-list .c-angle-up{\n//     display: none;\n// }\n.filtertags .clear-all{\n    right: 10px!important;\n}\n.filtertags .clear-all svg{\n    fill: white!important;\n}\n\nangular2-multiselect#tabs9 {\n    padding: 0!important;\n}\n\n\ndatatable-body-row.datatable-body-row.active {\n  opacity: 0.3!important;\n}\n\n// datatable-row-wrapper.datatable-row-wrapper{\n//   // :has(datatable-body-row.datatable-body-row.active) {\n//     background: #375ee2!important;\n//     color: white;\n//   }\n\n// .datatable-body-row.active {\n//   background-color: #ffcccb; /* Change this color to your desired active row background color */\n// }\n\n.datatable-row-wrapper.datatable-row-wrapper{\n  background-color: #3858E7!important;\n}\n\n.ngx-datatable.material.single-selection .datatable-body-row.active,\n.ngx-datatable.material.single-selection .datatable-body-row.active .datatable-row-group,\n.ngx-datatable.material.multi-selection .datatable-body-row.active,\n.ngx-datatable.material.multi-selection .datatable-body-row.active .datatable-row-group, .ngx-datatable.material.multi-click-selection .datatable-body-row.active,\n.ngx-datatable.material.multi-click-selection .datatable-body-row.active .datatable-row-group {\n    background-color: inherit !important;\n}\n.ngx-datatable.material.single-selection .datatable-body-row.active:hover,\n.ngx-datatable.material.single-selection .datatable-body-row.active:hover .datatable-row-group, .ngx-datatable.material.multi-selection .datatable-body-row.active:hover,\n.ngx-datatable.material.multi-selection .datatable-body-row.active:hover .datatable-row-group, .ngx-datatable.material.multi-click-selection .datatable-body-row.active:hover,\n.ngx-datatable.material.multi-click-selection .datatable-body-row.active:hover .datatable-row-group {\n    background-color: inherit !important;\n}\n"],"sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 30392:
/*!***************************************************************!*\
  !*** ./src/app/modules/rules/rules.component.scss?ngResource ***!
  \***************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 12725:
/*!***************************************************************************!*\
  !*** ./src/app/modules/rules/rulesadd/rulesadd.component.scss?ngResource ***!
  \***************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, ".rule-input {\n  width: 76%;\n  display: inline-block;\n}\n\n.rule-text-block {\n  width: 15%;\n  display: inline-block;\n  margin-right: 9%;\n  font-size: 13px;\n  font-weight: 500;\n}\n\n.btn-primary {\n  font-size: 12px !important;\n}\n\n.trashbtn {\n  font-size: 13px;\n}", "",{"version":3,"sources":["webpack://./src/app/modules/rules/rulesadd/rulesadd.component.scss"],"names":[],"mappings":"AAAA;EACI,UAAA;EACA,qBAAA;AACJ;;AACA;EACI,UAAA;EACA,qBAAA;EACA,gBAAA;EACA,eAAA;EACA,gBAAA;AAEJ;;AAAA;EACI,0BAAA;AAGJ;;AADA;EACI,eAAA;AAIJ","sourcesContent":[".rule-input {\n    width: 76%;\n    display: inline-block;\n}\n.rule-text-block {\n    width: 15%;\n    display: inline-block;\n    margin-right: 9%;\n    font-size: 13px;\n    font-weight: 500;\n}\n.btn-primary {\n    font-size: 12px!important;\n}\n.trashbtn{\n    font-size: 13px;\n}"],"sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 15063:
/*!*****************************************************************************!*\
  !*** ./src/app/modules/rules/rulesedit/rulesedit.component.scss?ngResource ***!
  \*****************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, ".rule-input {\n  width: 82%;\n  display: inline-block;\n}\n\n.rule-text-block {\n  width: 15%;\n  display: inline-block;\n  margin-right: 3%;\n  font-size: 12px;\n  font-weight: 500;\n}\n\n.btn-primary {\n  font-size: 12px !important;\n}\n\n.trashbtn {\n  font-size: 13px;\n}", "",{"version":3,"sources":["webpack://./src/app/modules/rules/rulesedit/rulesedit.component.scss"],"names":[],"mappings":"AAAA;EACI,UAAA;EACA,qBAAA;AACJ;;AACA;EACI,UAAA;EACA,qBAAA;EACA,gBAAA;EACA,eAAA;EACA,gBAAA;AAEJ;;AAAA;EACI,0BAAA;AAGJ;;AADA;EACI,eAAA;AAIJ","sourcesContent":[".rule-input {\n    width: 82%;\n    display: inline-block;\n}\n.rule-text-block {\n    width: 15%;\n    display: inline-block;\n    margin-right: 3%;\n    font-size: 12px;\n    font-weight: 500;\n}\n.btn-primary {\n    font-size: 12px!important;\n}\n.trashbtn{\n    font-size: 13px;\n}"],"sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 50486:
/*!****************************************************************************************************!*\
  !*** ./src/app/modules/settings/alert-configuration/alert-configuration.component.scss?ngResource ***!
  \****************************************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 52526:
/*!****************************************************************************************!*\
  !*** ./src/app/modules/settings/basic-setting/basic-setting.component.scss?ngResource ***!
  \****************************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 56862:
/*!******************************************************************************************!*\
  !*** ./src/app/modules/settings/manage-company/manage-company.component.scss?ngResource ***!
  \******************************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 38179:
/*!**************************************************************************************!*\
  !*** ./src/app/modules/settings/manage-users/manage-users.component.scss?ngResource ***!
  \**************************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 81995:
/*!*******************************************************************************************************!*\
  !*** ./src/app/modules/settings/predictive-routing/add-routing/add-routing.component.scss?ngResource ***!
  \*******************************************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 10321:
/*!*********************************************************************************************************!*\
  !*** ./src/app/modules/settings/predictive-routing/edit-routing/edit-routing.component.scss?ngResource ***!
  \*********************************************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 9281:
/*!**************************************************************************************************!*\
  !*** ./src/app/modules/settings/predictive-routing/predictive-routing.component.scss?ngResource ***!
  \**************************************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 72746:
/*!***********************************************************************!*\
  !*** ./src/app/modules/shortlist/shortlist.component.scss?ngResource ***!
  \***********************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 54633:
/*!***********************************************************!*\
  !*** ./src/app/modules/sms/sms.component.scss?ngResource ***!
  \***********************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 16298:
/*!***************************************************************!*\
  !*** ./src/app/modules/tasks/tasks.component.scss?ngResource ***!
  \***************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 58232:
/*!***************************************************************************************************!*\
  !*** ./src/app/modules/verification-management/verification-management.component.scss?ngResource ***!
  \***************************************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, ".rule-input {\n  width: 76%;\n  display: inline-block;\n}\n\n.rule-text-block {\n  width: 15%;\n  display: inline-block;\n  margin-right: 9%;\n  font-size: 13px;\n  font-weight: 500;\n}\n\n.btn-primary {\n  font-size: 12px !important;\n}\n\n.trashbtn {\n  font-size: 13px;\n}", "",{"version":3,"sources":["webpack://./src/app/modules/verification-management/verification-management.component.scss"],"names":[],"mappings":"AAAA;EACI,UAAA;EACA,qBAAA;AACJ;;AACA;EACI,UAAA;EACA,qBAAA;EACA,gBAAA;EACA,eAAA;EACA,gBAAA;AAEJ;;AAAA;EACI,0BAAA;AAGJ;;AADA;EACI,eAAA;AAIJ","sourcesContent":[".rule-input {\n    width: 76%;\n    display: inline-block;\n}\n.rule-text-block {\n    width: 15%;\n    display: inline-block;\n    margin-right: 9%;\n    font-size: 13px;\n    font-weight: 500;\n}\n.btn-primary {\n    font-size: 12px!important;\n}\n.trashbtn{\n    font-size: 13px;\n}"],"sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 59923:
/*!***********************************************************************!*\
  !*** ./src/app/modules/voicemail/voicemail.component.scss?ngResource ***!
  \***********************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "#toast-container > div {\n  box-shadow: 0 4px 25px 0 rgba(0, 0, 0, 0.1) !important;\n  padding: 13px 5px 5px 0px !important;\n  opacity: 1 !important;\n  background: #ffffff !important;\n  border-radius: 8px !important;\n  width: 317px !important;\n}\n\naudio::-webkit-media-controls-play-button,\naudio::-webkit-media-controls-panel {\n  background-color: #ffffff !important;\n  color: #000 !important;\n}\n\n.toast-title {\n  font-weight: bold !important;\n  padding-left: 19px !important;\n  color: #000 !important;\n}", "",{"version":3,"sources":["webpack://./src/app/modules/voicemail/voicemail.component.scss"],"names":[],"mappings":"AAAA;EACI,sDAAA;EACA,oCAAA;EACA,qBAAA;EACA,8BAAA;EACA,6BAAA;EACA,uBAAA;AACJ;;AACI;;EAEA,oCAAA;EACA,sBAAA;AAEJ;;AAEI;EACA,4BAAA;EACA,6BAAA;EACA,sBAAA;AACJ","sourcesContent":["#toast-container>div {\n    box-shadow: 0 4px 25px 0 rgb(0 0 0 / 10%)!important;\n    padding: 13px 5px 5px 0px!important;\n    opacity: 1!important;\n    background: #ffffff!important;\n    border-radius: 8px!important;\n    width: 317px!important;\n    }\n    audio::-webkit-media-controls-play-button,\n    audio::-webkit-media-controls-panel {\n    background-color: #ffffff!important;\n    color: #000!important;\n    \n    }\n\n    .toast-title {\n    font-weight: bold!important;\n    padding-left: 19px!important;\n    color: #000!important;\n}"],"sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 25153:
/*!***********************************************************************!*\
  !*** ./src/app/modules/whitelist/whitelist.component.scss?ngResource ***!
  \***********************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 53703:
/*!*********************************************************************************************!*\
  !*** ./src/app/page-not-found-component/page-not-found-component.component.scss?ngResource ***!
  \*********************************************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 91030:
/*!*********************************************************************!*\
  !*** ./src/app/pagenotfound/pagenotfound.component.scss?ngResource ***!
  \*********************************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, "", "",{"version":3,"sources":[],"names":[],"mappings":"","sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 71729:
/*!***********************************************************!*\
  !*** ./src/app/sidebar/sidebar.component.scss?ngResource ***!
  \***********************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

// Imports
var ___CSS_LOADER_API_SOURCEMAP_IMPORT___ = __webpack_require__(/*! ../../../node_modules/css-loader/dist/runtime/sourceMaps.js */ 49579);
var ___CSS_LOADER_API_IMPORT___ = __webpack_require__(/*! ../../../node_modules/css-loader/dist/runtime/api.js */ 60931);
var ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);
// Module
___CSS_LOADER_EXPORT___.push([module.id, ".main-sidebar.sidebar-style-2:hover {\n  overflow-y: scroll !important;\n}\n\n::-webkit-scrollbar {\n  width: 2px; /* for vertical scrollbars */\n  height: 2px !important; /* for horizontal scrollbars */\n}\n\n::-webkit-scrollbar-track {\n  background: rgba(0, 0, 0, 0.1);\n}\n\n::-webkit-scrollbar-thumb {\n  background: rgba(0, 0, 0, 0.2);\n}\n\n.main-sidebar .sidebar-menu li a span {\n  font-weight: 500;\n}", "",{"version":3,"sources":["webpack://./src/app/sidebar/sidebar.component.scss"],"names":[],"mappings":"AAGA;EACE,6BAAA;AAFF;;AAIA;EAEE,UAAA,EAAA,4BAAA;EACA,sBAAA,EAAA,8BAAA;AAFF;;AAKA;EAEE,8BAAA;AAHF;;AAMA;EAEE,8BAAA;AAJF;;AAOA;EACC,gBAAA;AAJD","sourcesContent":["// .main-sidebar.sidebar-style-2{\n//     overflow-y: scroll!important;\n// }\n.main-sidebar.sidebar-style-2:hover{\n  overflow-y: scroll!important;\n}\n::-webkit-scrollbar\n{\n  width: 2px;  /* for vertical scrollbars */\n  height: 2px!important; /* for horizontal scrollbars */\n}\n\n::-webkit-scrollbar-track\n{\n  background: rgba(0, 0, 0, 0.1);\n}\n\n::-webkit-scrollbar-thumb\n{\n  background: rgba(0, 0, 0, 0.2);\n}\n\n.main-sidebar .sidebar-menu li a span {\n font-weight: 500; \n}\n"],"sourceRoot":""}]);
// Exports
module.exports = ___CSS_LOADER_EXPORT___.toString();


/***/ }),

/***/ 46700:
/*!***************************************************!*\
  !*** ./node_modules/moment/locale/ sync ^\.\/.*$ ***!
  \***************************************************/
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {

var map = {
	"./af": 58685,
	"./af.js": 58685,
	"./ar": 254,
	"./ar-dz": 4312,
	"./ar-dz.js": 4312,
	"./ar-kw": 32614,
	"./ar-kw.js": 32614,
	"./ar-ly": 18630,
	"./ar-ly.js": 18630,
	"./ar-ma": 28674,
	"./ar-ma.js": 28674,
	"./ar-sa": 49032,
	"./ar-sa.js": 49032,
	"./ar-tn": 24730,
	"./ar-tn.js": 24730,
	"./ar.js": 254,
	"./az": 53052,
	"./az.js": 53052,
	"./be": 60150,
	"./be.js": 60150,
	"./bg": 63069,
	"./bg.js": 63069,
	"./bm": 13466,
	"./bm.js": 13466,
	"./bn": 18516,
	"./bn-bd": 90557,
	"./bn-bd.js": 90557,
	"./bn.js": 18516,
	"./bo": 26273,
	"./bo.js": 26273,
	"./br": 9588,
	"./br.js": 9588,
	"./bs": 19815,
	"./bs.js": 19815,
	"./ca": 83331,
	"./ca.js": 83331,
	"./cs": 21320,
	"./cs.js": 21320,
	"./cv": 72219,
	"./cv.js": 72219,
	"./cy": 68266,
	"./cy.js": 68266,
	"./da": 66427,
	"./da.js": 66427,
	"./de": 67435,
	"./de-at": 52871,
	"./de-at.js": 52871,
	"./de-ch": 12994,
	"./de-ch.js": 12994,
	"./de.js": 67435,
	"./dv": 82357,
	"./dv.js": 82357,
	"./el": 95649,
	"./el.js": 95649,
	"./en-au": 59961,
	"./en-au.js": 59961,
	"./en-ca": 19878,
	"./en-ca.js": 19878,
	"./en-gb": 3924,
	"./en-gb.js": 3924,
	"./en-ie": 70864,
	"./en-ie.js": 70864,
	"./en-il": 91579,
	"./en-il.js": 91579,
	"./en-in": 30940,
	"./en-in.js": 30940,
	"./en-nz": 16181,
	"./en-nz.js": 16181,
	"./en-sg": 44301,
	"./en-sg.js": 44301,
	"./eo": 85291,
	"./eo.js": 85291,
	"./es": 54529,
	"./es-do": 53764,
	"./es-do.js": 53764,
	"./es-mx": 12584,
	"./es-mx.js": 12584,
	"./es-us": 63425,
	"./es-us.js": 63425,
	"./es.js": 54529,
	"./et": 35203,
	"./et.js": 35203,
	"./eu": 70678,
	"./eu.js": 70678,
	"./fa": 83483,
	"./fa.js": 83483,
	"./fi": 96262,
	"./fi.js": 96262,
	"./fil": 52521,
	"./fil.js": 52521,
	"./fo": 99486,
	"./fo.js": 99486,
	"./fr": 63131,
	"./fr-ca": 88239,
	"./fr-ca.js": 88239,
	"./fr-ch": 21702,
	"./fr-ch.js": 21702,
	"./fr.js": 63131,
	"./fy": 267,
	"./fy.js": 267,
	"./ga": 23821,
	"./ga.js": 23821,
	"./gd": 71753,
	"./gd.js": 71753,
	"./gl": 4074,
	"./gl.js": 4074,
	"./gom-deva": 92762,
	"./gom-deva.js": 92762,
	"./gom-latn": 5969,
	"./gom-latn.js": 5969,
	"./gu": 82809,
	"./gu.js": 82809,
	"./he": 45402,
	"./he.js": 45402,
	"./hi": 315,
	"./hi.js": 315,
	"./hr": 10410,
	"./hr.js": 10410,
	"./hu": 38288,
	"./hu.js": 38288,
	"./hy-am": 67928,
	"./hy-am.js": 67928,
	"./id": 71334,
	"./id.js": 71334,
	"./is": 86959,
	"./is.js": 86959,
	"./it": 34864,
	"./it-ch": 51124,
	"./it-ch.js": 51124,
	"./it.js": 34864,
	"./ja": 36141,
	"./ja.js": 36141,
	"./jv": 29187,
	"./jv.js": 29187,
	"./ka": 42136,
	"./ka.js": 42136,
	"./kk": 94332,
	"./kk.js": 94332,
	"./km": 18607,
	"./km.js": 18607,
	"./kn": 84305,
	"./kn.js": 84305,
	"./ko": 70234,
	"./ko.js": 70234,
	"./ku": 16003,
	"./ku.js": 16003,
	"./ky": 75061,
	"./ky.js": 75061,
	"./lb": 32786,
	"./lb.js": 32786,
	"./lo": 66183,
	"./lo.js": 66183,
	"./lt": 50029,
	"./lt.js": 50029,
	"./lv": 24169,
	"./lv.js": 24169,
	"./me": 68577,
	"./me.js": 68577,
	"./mi": 68177,
	"./mi.js": 68177,
	"./mk": 50337,
	"./mk.js": 50337,
	"./ml": 65260,
	"./ml.js": 65260,
	"./mn": 52325,
	"./mn.js": 52325,
	"./mr": 14695,
	"./mr.js": 14695,
	"./ms": 75334,
	"./ms-my": 37151,
	"./ms-my.js": 37151,
	"./ms.js": 75334,
	"./mt": 63570,
	"./mt.js": 63570,
	"./my": 97963,
	"./my.js": 97963,
	"./nb": 88028,
	"./nb.js": 88028,
	"./ne": 86638,
	"./ne.js": 86638,
	"./nl": 50302,
	"./nl-be": 66782,
	"./nl-be.js": 66782,
	"./nl.js": 50302,
	"./nn": 33501,
	"./nn.js": 33501,
	"./oc-lnc": 50563,
	"./oc-lnc.js": 50563,
	"./pa-in": 50869,
	"./pa-in.js": 50869,
	"./pl": 65302,
	"./pl.js": 65302,
	"./pt": 49687,
	"./pt-br": 74884,
	"./pt-br.js": 74884,
	"./pt.js": 49687,
	"./ro": 79107,
	"./ro.js": 79107,
	"./ru": 33627,
	"./ru.js": 33627,
	"./sd": 30355,
	"./sd.js": 30355,
	"./se": 83427,
	"./se.js": 83427,
	"./si": 11848,
	"./si.js": 11848,
	"./sk": 54590,
	"./sk.js": 54590,
	"./sl": 20184,
	"./sl.js": 20184,
	"./sq": 56361,
	"./sq.js": 56361,
	"./sr": 78965,
	"./sr-cyrl": 81287,
	"./sr-cyrl.js": 81287,
	"./sr.js": 78965,
	"./ss": 25456,
	"./ss.js": 25456,
	"./sv": 70451,
	"./sv.js": 70451,
	"./sw": 77558,
	"./sw.js": 77558,
	"./ta": 51356,
	"./ta.js": 51356,
	"./te": 73693,
	"./te.js": 73693,
	"./tet": 21243,
	"./tet.js": 21243,
	"./tg": 42500,
	"./tg.js": 42500,
	"./th": 55768,
	"./th.js": 55768,
	"./tk": 77761,
	"./tk.js": 77761,
	"./tl-ph": 35780,
	"./tl-ph.js": 35780,
	"./tlh": 29590,
	"./tlh.js": 29590,
	"./tr": 33807,
	"./tr.js": 33807,
	"./tzl": 93857,
	"./tzl.js": 93857,
	"./tzm": 60654,
	"./tzm-latn": 8806,
	"./tzm-latn.js": 8806,
	"./tzm.js": 60654,
	"./ug-cn": 30845,
	"./ug-cn.js": 30845,
	"./uk": 19232,
	"./uk.js": 19232,
	"./ur": 47052,
	"./ur.js": 47052,
	"./uz": 77967,
	"./uz-latn": 32233,
	"./uz-latn.js": 32233,
	"./uz.js": 77967,
	"./vi": 98615,
	"./vi.js": 98615,
	"./x-pseudo": 12320,
	"./x-pseudo.js": 12320,
	"./yo": 31313,
	"./yo.js": 31313,
	"./zh-cn": 64490,
	"./zh-cn.js": 64490,
	"./zh-hk": 55910,
	"./zh-hk.js": 55910,
	"./zh-mo": 98262,
	"./zh-mo.js": 98262,
	"./zh-tw": 44223,
	"./zh-tw.js": 44223
};


function webpackContext(req) {
	var id = webpackContextResolve(req);
	return __webpack_require__(id);
}
function webpackContextResolve(req) {
	if(!__webpack_require__.o(map, req)) {
		var e = new Error("Cannot find module '" + req + "'");
		e.code = 'MODULE_NOT_FOUND';
		throw e;
	}
	return map[req];
}
webpackContext.keys = function webpackContextKeys() {
	return Object.keys(map);
};
webpackContext.resolve = webpackContextResolve;
module.exports = webpackContext;
webpackContext.id = 46700;

/***/ }),

/***/ 33383:
/*!***********************************************!*\
  !*** ./src/app/app.component.html?ngResource ***!
  \***********************************************/
/***/ ((module) => {

"use strict";
module.exports = "<app-header *ngIf=\"!(router.url === '/login' || router.url === '/register'|| router.url === '/thank-you' || router.url === '/404' || router.url.startsWith('/publisher-registration/')   || router.url === '/verify-email/'+emailurl)\"></app-header>\n<app-sidebar *ngIf=\"!(router.url === '/login' || router.url === '/register' || router.url === '/thank-you' || router.url === '/404' || router.url.startsWith('/publisher-registration/')  || router.url === '/verify-email/'+emailurl)\"></app-sidebar>\n<router-outlet></router-outlet>\n<app-footer *ngIf=\"!(router.url === '/login' || router.url === '/register' || router.url === '/thank-you' || router.url === '/404' || router.url.startsWith('/publisher-registration/')  || router.url === '/verify-email/'+emailurl)\"></app-footer>";

/***/ }),

/***/ 28899:
/*!********************************************************************************!*\
  !*** ./src/app/auth/login-componunt/login-componunt.component.html?ngResource ***!
  \********************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "    <div class=\"loader\" style=\"display: none;\"></div>\n    <!-- <div id=\"app\" style=\"width: 98%!important;\"> -->\n    <!-- <section class=\"section\"> -->\n    <div id=\"app\">\n      <div class=\"main-wrapper main-wrapper-1\">\n        <div class=\"section-login__header\">\n          <!-- url('assets/img/back.jpg')  -->\n          <div style=\"padding-top: 10px;\n          border-bottom: 1px solid #535660;background: #1F263D;\">\n            <div class=\"loginv2-container container\">\n              <h1 class=\"title md-title title--ringba\">\n                <span class=\"text-white\">Welcome to Dialdigits</span>\n              </h1>\n              <p class=\"subtitle\"><span class=\"login-welcome-sub-message\">Lets grow together</span></p>\n            </div>\n          </div>\n        </div>\n\n        <div class=\"row justify-content-center login p-2 m-0\" style=\"background: #1F263D;\">\n          <div class=\"col-12 col-sm-8 offset-sm-2 col-md-6 offset-md-3 col-lg-6 offset-lg-2 col-xl-3 p-0 offset-xl-5 m-3 \"\n            >\n            <center>\n              <div class=\"card card-primary\">\n                <div class=\"card-header\">\n                  <img alt=\"image\" width=\"180px\" src=\"assets/img/logo.png\" class=\"header-logo\">\n                </div>\n                <div class=\"card-body\">\n                  <form [formGroup]=\"loginForm\" (ngSubmit)=\"onSubmit()\">\n                    <div class=\"form-group text-left\">\n                      <label for=\"email\">Email</label>\n                      <!-- <input id=\"email\" type=\"email\" class=\"form-control\" name=\"email\" tabindex=\"1\" required=\"\" autofocus=\"\"> -->\n                      <input type=\"email\" formControlName=\"username\" class=\"form-control\" placeholder=\"Username\"\n                        required>\n\n                      <div *ngIf=\"username.invalid && (username.dirty || username.touched)\" class=\"error\">\n                        <div *ngIf=\"username.errors\">\n                          Username is required.\n                        </div>\n                      </div>\n                    </div>\n                    <div class=\"form-group text-left\">\n                      <div class=\"d-block\">\n                        <label for=\"password\" class=\"control-label\">Password</label>\n                      </div>\n                      <input type=\"password\" formControlName=\"password\" class=\"form-control\" placeholder=\"Password\"\n                        required>\n\n                      <div *ngIf=\"password.invalid && (password.dirty || password.touched)\" class=\"error\">\n                        <div *ngIf=\"password.errors\">\n                          Password is required.\n                        </div>\n                      </div>\n                    </div>\n                    <!-- <div class=\"form-group text-left\">\n                      <div class=\"custom-control custom-checkbox\">\n                        <input type=\"checkbox\" name=\"remember\" class=\"custom-control-input\" tabindex=\"3\" id=\"remember-me\">\n                        <label class=\"custom-control-label\" for=\"remember-me\">Remember Me</!                       </div>\n                    </div> -->\n                    <!-- <div class=\"float-right\">\n                        <a routerLink=\"/forgot-password\" class=\"text-small\">\n                          Forgot Password?\n                        </a>\n                      </div> -->\n                    <div class=\"form-group text-left\">\n                      <button type=\"submit\" [disabled]=\"!loginForm.valid\" class=\"btn btn-primary\">Log In</button>\n\n                    </div>\n                  </form>\n                  <div class=\"alert alert-danger\" *ngIf=\"loginError\">\n                    {{loginError}}\n                  </div>\n                </div>\n              </div>\n            </center>\n\n            <!-- <div class=\"mt-5 text-muted text-center\">\n                Don't have an account?<a routerLink=\"/register\" routerLinkActive=\"active\">Create One</a>\n                </div> -->\n          </div>\n          <!-- </div>\n        </section> -->\n          <br>\n        </div>\n\n        <footer class=\"footer\">\n          <div class=\"container footer__container \" style=\"padding-top: 20px;\"><a href=\"/\"\n              class=\"logo logo--footer\"></a>\n            <div class=\"row\">\n              <div class=\"col-md-2\" style=\"margin-top: 30px;\">\n                <img alt=\"image\" width=\"180px\" src=\"assets/img/logo.png\" class=\"header-logo mb-2\">\n              </div>\n              <div class=\"col-md-2\">\n                <nav class=\"footer-menu__wrap hidden-xs hidden-sm hidden-md\">\n                  <ul class=\"footer-menu__list column\">\n                    <li class=\"footer-menu__item\"><a href=\"#\" target=\"_BLANK\"\n                        class=\"footer-text text-uppercase footer-menu__item__link\">Support</a></li>\n                    <li class=\"footer-menu__item\"><a href=\"#\" target=\"_BLANK\"\n                        class=\"footer-text text-uppercase footer-menu__item__link\">Glossary</a></li>\n                    <li class=\"footer-menu__item\"><a href=\"#\" target=\"_BLANK\"\n                        class=\"footer-text text-uppercase footer-menu__item__link\">Blog</a></li>\n                    <li class=\"footer-menu__item\"><a href=\"#\" target=\"_BLANK\"\n                        class=\"footer-text text-uppercase footer-menu__item__link\">Developers</a></li>\n\n                  </ul>\n                </nav>\n              </div>\n              <div class=\"col-md-2\">\n                <nav class=\"footer-menu__wrap hidden-xs hidden-sm hidden-md\">\n                  <ul class=\"footer-menu__list column\">\n                    <li class=\"footer-menu__item\"><a href=\"#\" target=\"_BLANK\"\n                        class=\"footer-text text-uppercase footer-menu__item__link\">System Status</a></li>\n                    <li class=\"footer-menu__item\"><a href=\"#\" target=\"_BLANK\"\n                        class=\"footer-text text-uppercase footer-menu__item__link\">Terms</a></li>\n                    <li class=\"footer-menu__item\"><a href=\"#\" target=\"_BLANK\"\n                        class=\"footer-text text-uppercase footer-menu__item__link\">Privacy</a></li>\n                    <li class=\"footer-menu__item\"><a href=\"#\" target=\"_BLANK\"\n                        class=\"footer-text text-uppercase footer-menu__item__link\">Abuse</a></li>\n                  </ul>\n                </nav>\n              </div>\n              <div class=\"col-md-3\">\n                <div class=\"contact__wrap\">\n                  <h4 class=\"footer-text text-uppercase hidden-xs \">\n                    Call us\n                  </h4> <a href=\"tel:+18445339911\" class=\"call__link\">(844) 533-9911</a>\n                </div>\n              </div>\n              <div class=\"col-md-3\">\n                <div class=\"social__wrap\">\n                  <h4 class=\"footer-text text-uppercase hidden-xs\">\n                    Follow us\n                  </h4>\n                  <div class=\"social-list\">\n                    <a style=\"padding: 10px;\" href=\"#\" target=\"_BLANK\" title=\"facebook\" class=\"social-item\"><i\n                        class=\"fab fa-facebook \"></i></a>\n                    <a style=\"padding: 10px;\" href=\"#\" target=\"_BLANK\" title=\"twitter\" class=\"social-item\"><i\n                        class=\"fab fa-twitter\"></i></a>\n                    <a style=\"padding: 10px;\" href=\"#\" target=\"_BLANK\" title=\"youtube\" class=\"social-item\"><i\n                        class=\"fab fa-youtube\"></i></a>\n                    <a style=\"padding: 10px;\" href=\"#\" target=\"_BLANK\" title=\"linkedin\" class=\"social-item\"><i\n                        class=\"fab fa-linkedin\"></i></a>\n                  </div>\n                </div>\n              </div>\n\n            </div>\n\n\n\n          </div>\n        </footer>\n      </div>\n    </div>";

/***/ }),

/***/ 36911:
/*!****************************************************************!*\
  !*** ./src/app/auth/profile/profile.component.html?ngResource ***!
  \****************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n\n<div class=\"main-content\">\n       <section class=\"section\">\n         <div class=\"section-body\">\n           <div class=\"row\">\n             <div class=\"col-12 col-md-12 col-lg-12\">\n               <form [formGroup]=\"profileForm\" (ngSubmit)=\"onSubmit()\">\n               <div class=\"card\">\n                 <div class=\"card-header\">\n                   <h4>Edit Profile</h4>\n                 </div>\n                 <div class=\"card-body\">                    \n                   <div class=\"form-group\">\n                     <label *ngIf=\"currentCompany && currentCompany.role!=4\">Firstname</label>\n                     <label *ngIf=\"currentCompany && currentCompany.role==4\">Company</label>\n                     <input type=\"text\" formControlName=\"firstname\" [ngClass]=\"{ 'is-invalid': submitted && f.firstname.errors }\" class=\"form-control\">\n                     <div *ngIf=\"submitted && f.firstname.errors\" class=\"invalid-feedback\">\n                        <div *ngIf=\"f.firstname.errors.required\">Firstname is required</div>\n                    </div>\n\n                   </div>\n                   <div class=\"form-group\" *ngIf=\"currentCompany && currentCompany.role!=4\">\n                     <label>Lastname</label>\n                     <input type=\"text\" formControlName=\"lastname\" [ngClass]=\"{ 'is-invalid': submitted && f.lastname.errors }\" class=\"form-control\">\n                     <div *ngIf=\"submitted && f.lastname.errors\" class=\"invalid-feedback\">\n                         <div *ngIf=\"f.lastname.errors.required\">Lastname is required</div>\n                     </div> \n                   </div>\n                   <div class=\"form-group\">\n                     <label>Password</label>\n                     <input type=\"password\" formControlName=\"password\" class=\"form-control\">\n                   </div>\n                   <div class=\"form-group\">\n                     <label>Select Your Timezone</label>\n                      <select name=\"timezone\" formControlName=\"timezone\" id=\"\" [value]=\"''\" class=\"form-control\">\n                          <option value=\"\">Select Timezone</option>\n                          <option value=\"{{item.id}}\" *ngFor=\"let item of alltimezone\">{{item.gmtzone}}</option>\n                      </select>\n                   </div>\n                   <!-- <div class=\"form-group\">\n                    <div class=\"control-label\">Recording</div>\n                    <label class=\"custom-switch mt-2 pl-0\">\n                      <input type=\"checkbox\" [checked]=\"recordingval==1\" (change)=\"get_recordingstatus($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                      <span class=\"custom-switch-indicator\"></span>                     \n                    </label>\n                  </div> -->\n                 </div>\n                 <div class=\"card-footer text-right\">\n                    <button  class=\"btn btn-primary btn-sm p-2\" type=\"submit\"><i class=\"fa fa-save\"></i> Update Profile</button>\n                </div>\n               </div>\n             </form>\n\n   </div>\n\n";

/***/ }),

/***/ 82811:
/*!*********************************************************!*\
  !*** ./src/app/footer/footer.component.html?ngResource ***!
  \*********************************************************/
/***/ ((module) => {

"use strict";
module.exports = "<!-- <div class=\"settingSidebar\" (click)=\"show()\" [ngClass]=\"{'showSettingPanel': count==1}\">\n  <a href=\"javascript:void(0)\" class=\"settingPanelToggle\" [ngClass]=\"{'showSettingPanel': count==1}\"> <i class=\"fa fa-spin fa-cog\"></i>\n  </a>\n  <div class=\"settingSidebar-body ps-container ps-theme-default\">\n    <div class=\" fade show active\">\n      <div class=\"setting-panel-header\">Setting Panel\n      </div>\n      <div class=\"p-15 border-bottom\">\n        <h6 class=\"font-medium m-b-10\">Select Layout</h6>\n        <div class=\"selectgroup layout-color w-50\">\n          <label class=\"selectgroup-item\">\n            <input type=\"radio\" name=\"value\" value=\"1\" class=\"selectgroup-input select-layout\" checked>\n            <span class=\"selectgroup-button\">Light</span>\n          </label>\n          <label class=\"selectgroup-item\">\n            <input type=\"radio\" name=\"value\" value=\"2\" class=\"selectgroup-input select-layout\">\n            <span class=\"selectgroup-button\">Dark</span>\n          </label>\n        </div>\n      </div>\n      <div class=\"p-15 border-bottom\">\n        <h6 class=\"font-medium m-b-10\">Sidebar Color</h6>\n        <div class=\"selectgroup selectgroup-pills sidebar-color\">\n          <label class=\"selectgroup-item\">\n            <input type=\"radio\" name=\"icon-input\" value=\"1\" class=\"selectgroup-input select-sidebar\">\n            <span class=\"selectgroup-button selectgroup-button-icon\" data-toggle=\"tooltip\"\n              data-original-title=\"Light Sidebar\"><i class=\"fas fa-sun\"></i></span>\n          </label>\n          <label class=\"selectgroup-item\">\n            <input type=\"radio\" name=\"icon-input\" value=\"2\" class=\"selectgroup-input select-sidebar\" checked>\n            <span class=\"selectgroup-button selectgroup-button-icon\" data-toggle=\"tooltip\"\n              data-original-title=\"Dark Sidebar\"><i class=\"fas fa-moon\"></i></span>\n          </label>\n        </div>\n      </div>\n      <div class=\"p-15 border-bottom\">\n        <h6 class=\"font-medium m-b-10\">Color Theme</h6>\n        <div class=\"theme-setting-options\">\n          <ul class=\"choose-theme list-unstyled mb-0\">\n            <li title=\"white\" class=\"active\">\n              <div class=\"white\"></div>\n            </li>\n            <li title=\"cyan\">\n              <div class=\"cyan\"></div>\n            </li>\n            <li title=\"black\">\n              <div class=\"black\"></div>\n            </li>\n            <li title=\"purple\">\n              <div class=\"purple\"></div>\n            </li>\n            <li title=\"orange\">\n              <div class=\"orange\"></div>\n            </li>\n            <li title=\"green\">\n              <div class=\"green\"></div>\n            </li>\n            <li title=\"red\">\n              <div class=\"red\"></div>\n            </li>\n          </ul>\n        </div>\n      </div>\n      <div class=\"p-15 border-bottom\">\n        <div class=\"theme-setting-options\">\n          <label>\n            <span class=\"control-label p-r-20\">Mini Sidebar</span>\n            <input type=\"checkbox\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\"\n              id=\"mini_sidebar_setting\">\n            <span class=\"custom-switch-indicator\"></span>\n          </label>\n        </div>\n      </div>      \n      <div class=\"mt-4 mb-4 p-3 align-center rt-sidebar-last-ele\">\n        <a href=\"#\" class=\"btn btn-icon icon-left btn-primary btn-restore-theme\">\n          <i class=\"fas fa-undo\"></i> Restore Default\n        </a>\n      </div>\n    </div>\n  </div>\n</div> -->\n<!-- \n<div class=\"settingSidebar\" (click)=\"show()\" [ngClass]=\"{'showSettingPanel': count==1}\">\n  <a href=\"javascript:void(0)\" class=\"settingPanelToggle\" [ngClass]=\"{'showSettingPanel': count==1}\"> <i class=\"fa fa-spin fa-cog\"></i>\n  </a>\n  <div class=\"settingSidebar-body ps-container ps-theme-default\">\n    <div class=\" fade show active\">\n      <div class=\"setting-panel-header\">Setting Panel\n      </div>\n      <div class=\"p-15 border-bottom\">\n        <h6 class=\"font-medium m-b-10\">Select Layout</h6>\n        <div class=\"selectgroup layout-color w-50\">\n          <label class=\"selectgroup-item\">\n            <input type=\"radio\" name=\"value\" value=\"1\" class=\"selectgroup-input select-layout\" checked>\n            <span class=\"selectgroup-button\">Light</span>\n          </label>\n          <label class=\"selectgroup-item\">\n            <input type=\"radio\" name=\"value\" value=\"2\" class=\"selectgroup-input select-layout\">\n            <span class=\"selectgroup-button\">Dark</span>\n          </label>\n        </div>\n      </div> -->\n      <!-- <div class=\"p-15 border-bottom\">\n        <h6 class=\"font-medium m-b-10\">Sidebar Color</h6>\n        <div class=\"selectgroup selectgroup-pills sidebar-color\">\n          <label class=\"selectgroup-item\">\n            <input type=\"radio\" name=\"icon-input\" value=\"1\" class=\"selectgroup-input select-sidebar\">\n            <span class=\"selectgroup-button selectgroup-button-icon\" data-toggle=\"tooltip\"\n              data-original-title=\"Light Sidebar\"><i class=\"fas fa-sun\"></i></span>\n          </label>\n          <label class=\"selectgroup-item\">\n            <input type=\"radio\" name=\"icon-input\" value=\"2\" class=\"selectgroup-input select-sidebar\" checked>\n            <span class=\"selectgroup-button selectgroup-button-icon\" data-toggle=\"tooltip\"\n              data-original-title=\"Dark Sidebar\"><i class=\"fas fa-moon\"></i></span>\n          </label>\n        </div>\n      </div> -->\n      <!-- <div class=\"p-15 border-bottom\">\n        <h6 class=\"font-medium m-b-10\">Color Theme</h6>\n        <div class=\"theme-setting-options\">\n          <ul class=\"choose-theme list-unstyled mb-0\">\n            <li title=\"white\" class=\"active\">\n              <div class=\"white\"></div>\n            </li>\n            <li title=\"cyan\">\n              <div class=\"cyan\"></div>\n            </li>\n            <li title=\"black\">\n              <div class=\"black\"></div>\n            </li>\n            <li title=\"purple\">\n              <div class=\"purple\"></div>\n            </li>\n            <li title=\"orange\">\n              <div class=\"orange\"></div>\n            </li>\n            <li title=\"green\">\n              <div class=\"green\"></div>\n            </li>\n            <li title=\"red\">\n              <div class=\"red\"></div>\n            </li>\n          </ul>\n        </div>\n      </div> -->\n      <!-- <div class=\"p-15 border-bottom\">\n        <div class=\"theme-setting-options\">\n          <label>\n            <span class=\"control-label p-r-20\">Mini Sidebar</span>\n            <input type=\"checkbox\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\"\n              id=\"mini_sidebar_setting\">\n            <span class=\"custom-switch-indicator\"></span>\n          </label>\n        </div>\n      </div>       -->\n      <!-- <div class=\"mt-4 mb-4 p-3 align-center rt-sidebar-last-ele\">\n        <a href=\"#\" class=\"btn btn-icon icon-left btn-primary btn-restore-theme\">\n          <i class=\"fas fa-undo\"></i> Restore Default\n        </a>\n      </div>\n    </div>\n  </div>\n</div> -->\n<footer class=\"main-footer\">\n    <div class=\"footer-left\">\n      Copyright &copy; {{getyear}} <div class=\"bullet\"></div> Design By <a href=\"#\">Dail-Digits</a>\n    </div>\n    <div class=\"footer-right\">\n    </div>\n  </footer>";

/***/ }),

/***/ 46727:
/*!*********************************************************!*\
  !*** ./src/app/header/header.component.html?ngResource ***!
  \*********************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n<div id=\"app\">\n  <div class=\"main-wrapper main-wrapper-1\">\n    <div class=\"navbar-bg\"></div>\n    <nav class=\"navbar navbar-expand-lg main-navbar \">\n        <div class=\"form-inline mr-auto\">\n          <ul class=\"navbar-nav mr-3\">\n            <!-- data-toggle=\"sidebar\" -->\n            <li><a href=\"#\" class=\"nav-link nav-link-lg\n                  collapse-btn pull-right sidebartogglebtn\"  data-toggle=\"sidebar\"  (click)=\"getSidebar()\"> <svg xmlns=\"http://www.w3.org/2000/svg\" width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" class=\"feather feather-align-justify\"><line x1=\"21\" y1=\"10\" x2=\"3\" y2=\"10\"></line><line x1=\"21\" y1=\"6\" x2=\"3\" y2=\"6\"></line><line x1=\"21\" y1=\"14\" x2=\"3\" y2=\"14\"></line><line x1=\"21\" y1=\"18\" x2=\"3\" y2=\"18\"></line></svg></a>\n            </li>\n            <li><a class=\"nav-link nav-link-lg fullscreen-btn\">\n                <svg xmlns=\"http://www.w3.org/2000/svg\" width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" class=\"feather feather-maximize\"><path d=\"M8 3H5a2 2 0 0 0-2 2v3m18 0V5a2 2 0 0 0-2-2h-3m0 18h3a2 2 0 0 0 2-2v-3M3 16v3a2 2 0 0 0 2 2h3\"></path></svg>\n              </a></li>\n            <!-- <li><a class=\"nav-link nav-link-lg\">\n              <div class=\"post-footer-comment-wrapper\">\n                <div class=\"comment\">\n                     <div class=\"media\">\n                       <div class=\"media-left\">\n\n                          <img src=\"assets/img/live_call_icon.png\" width=\"40px\" alt=\"\" srcset=\"\">\n                       </div>\n                       <div class=\"media-body\">\n                         <h6 class=\"media-heading\">0</h6>\n                         <p>Live</p>\n                       </div>\n                     </div>\n                </div>\n            </div>\n              </a>\n            </li> -->\n            <!-- <i class=\"material-icons phone\">phone</i> -->\n\n            <!-- <li>\n                <form class=\"form-inline mr-auto\">\n                    <div class=\"search-element\">\n                      <input class=\"form-control\" type=\"search\" placeholder=\"Search\" aria-label=\"Search\" data-width=\"200\" style=\"width: 200px;\">\n                      <button class=\"btn\" type=\"submit\">\n                        <i class=\"fas fa-search\"></i>\n                      </button>\n                    </div>\n                  </form>\n            </li> -->\n          </ul>\n        </div>\n        <ul class=\"navbar-nav navbar-right\">\n\n\n          <li><a class=\"nav-link nav-link-lg\">\n            <div class=\"post-footer-comment-wrapper\">\n              <div class=\"comment\">\n                   <div class=\"media\">\n                     <div class=\"media-left\">\n\n                        <img src=\"assets/img/live_call_icon.png\" width=\"40px\" alt=\"\" srcset=\"\">\n                     </div>\n                     <div class=\"media-body\">\n                       <h6 class=\"media-heading\">{{livecall}}</h6>\n                       <p>Live</p>\n                     </div>\n                   </div>\n              </div>\n          </div>\n            </a>\n          </li>\n\n          <li><a class=\"nav-link nav-link-lg\">\n            <div class=\"post-footer-comment-wrapper\">\n              <div class=\"comment\">\n                   <div class=\"media\">\n                     <div class=\"media-left\">\n                        <!-- <i class=\"material-icons phone-completed\">phone</i> -->\n                        <img src=\"assets/img/completed_call.png\" width=\"40px\" alt=\"\" srcset=\"\">\n                     </div>\n                     <div class=\"media-body\">\n                       <h6 class=\"media-heading-completed\">{{completedcalls}}</h6>\n                       <p>Completed</p>\n                     </div>\n                   </div>\n              </div>\n          </div>\n            </a>\n          </li>\n\n          <li class=\"dropdown mt-2\">\n            <a href=\"#\" data-toggle=\"dropdown\" class=\"nav-link dropdown-toggle nav-link-lg nav-link-user\">\n              <img alt=\"image\" src=\"assets/img/user.png\" class=\"user-img-radious-style\">\n               <span class=\"d-sm-none d-lg-inline-block\"></span>\n            </a>\n          <div class=\"dropdown-menu dropdown-menu-right pullDown\">\n            <div *ngIf=\"role!=2\">\n              <div class=\"dropdown-title\" >Hello {{firstName}} {{lastName}}</div>\n              <a routerLink=\"/profile\" routerLinkActive=\"router-link-active\" class=\"dropdown-item has-icon\"> <i class=\"far\n                    fa-user\"></i> Profile\n              </a>\n            </div>\n            <div *ngIf=\"(role==0 || role==2) && companies?.length>0\">\n              <div class=\"dropdown-title\">Switch Account</div>\n              <div *ngFor=\"let item of companies\">\n              <a href=\"#\" (click)=\"switchcompany(item,0)\" class=\"dropdown-item has-icon\">\n                <i *ngIf=\"item.uuid == currentcompany\" style=\"color: #6777ef;\" class=\"fas fa-check-square\"></i>\n                <i *ngIf=\"item.uuid != currentcompany\" class=\"fas fa-caret-right\"></i>\n                <div *ngIf=\"item.uuid == currentcompany\" style=\"color: #6777ef;\">\n                {{item.name}}\n                </div>\n                <div *ngIf=\"item.uuid != currentcompany\">\n                {{item.name}}\n                </div>\n              </a>\n              </div>\n              <div class=\"dropdown-divider\"></div>\n              <a routerLink=\"/profile\" routerLinkActive=\"router-link-active\" class=\"dropdown-item has-icon\"> <i class=\"far\n                fa-user\"></i> Profile\n              </a>\n            </div>\n\n            <div *ngIf=\"(role==4) && companies?.length>0\">\n              <!-- <div class=\"dropdown-title\">Switch Account</div>\n              <div *ngFor=\"let item of companies\">\n              <a href=\"#\" (click)=\"switchcompany(item,4)\" class=\"dropdown-item has-icon\">\n                <i *ngIf=\"item.uuid == currentcompany && currentUser.uuid == item.user_uuid\" style=\"color: #6777ef;\" class=\"fas fa-check-square\"></i>\n                <i *ngIf=\"item.uuid != currentcompany  || currentUser.uuid != item.user_uuid\" class=\"fas fa-caret-right\"></i>\n                <div *ngIf=\"item.uuid == currentcompany  && currentUser.uuid == item.user_uuid\" style=\"color: #6777ef;\">\n                {{item.name}}\n                </div>\n                <div *ngIf=\"item.uuid != currentcompany  || currentUser.uuid != item.user_uuid\">\n                {{item.name}}\n                </div>\n              </a>\n              </div> -->\n              <!-- <div class=\"dropdown-divider\"></div>\n              <a routerLink=\"/profile\" routerLinkActive=\"router-link-active\" class=\"dropdown-item has-icon\"> <i class=\"far\n                fa-user\"></i> Profile\n              </a> -->\n            </div>\n            <div class=\"dropdown-divider\"></div>\n            <a routerLink=\"/logout\" routerLinkActive=\"router-link-active\"  (click)='logout()' class=\"dropdown-item has-icon text-danger\"> <i class=\"fas fa-sign-out-alt\"></i>\n              Logout\n            </a>\n          </div>\n        </li>\n        </ul>\n      </nav>\n    <!-- Main Content -->\n\n  </div>\n</div>\n";

/***/ }),

/***/ 59010:
/*!*****************************************************************************!*\
  !*** ./src/app/modules/audible-ring/audible-ring.component.html?ngResource ***!
  \*****************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n\n    <!-- Add Label Modal -->\n    <div class=\"modal  fade\" id=\"addLabels\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n     aria-hidden=\"true\">\n     <div class=\"modal-dialog\" role=\"document\">\n       <div class=\"modal-content\">\n         <div class=\"modal-header\">\n           <h5 class=\"modal-title\" id=\"formModal\">Add New Exception Number</h5>\n           <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n             <span aria-hidden=\"true\">&times;</span>\n           </button>\n         </div>\n         <div class=\"modal-body\">\n           <form id=\"addLabel\" [formGroup]=\"addLabelForm\" (ngSubmit)=\"onLabelSubmit()\">\n             <div class=\"form-group\">\n                 <label>Number</label>\n                 <select formControlName=\"number\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': LabelSubmitted && labelcontrol.number.errors }\" [value]=\"''\">\n                   <option value=\"\">Select a Number</option>\n                   <option *ngFor=\"let data of allnumbers\" value=\"{{data.number}}\">{{data.number}}</option>\n                 </select>\n                 <div *ngIf=\"LabelSubmitted && labelcontrol.number.errors\" class=\"invalid-feedback\">\n                     <div *ngIf=\"labelcontrol.number.errors.required\">Number is required</div>\n                 </div>\n              </div>\n\n               <div class=\"form-group\">\n                 <label  class=\"d-block\">Notes:</label>\n                 <textarea formControlName=\"notes\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': LabelSubmitted && labelcontrol.notes.errors }\"></textarea>\n                 <div *ngIf=\"LabelSubmitted && labelcontrol.notes.errors\" class=\"invalid-feedback\">\n                    <div *ngIf=\"labelcontrol.notes.errors.required\">Notes is required</div>\n                </div>\n               </div>\n\n             <div class=\"modal-footer\" style=\"padding: 0;\">\n                <button [disabled]=\"!addLabelForm.valid\" (click)=\"closeModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Add Exception</button>\n                <button  type=\"button\" data-dismiss=\"modal\" aria-label=\"Close\" class=\"btn btn-secondary m-t-15 waves-effect\">Close</button>\n               </div>\n           </form>\n         </div>\n       </div>\n     </div>\n     </div>\n\n      <div class=\"main-content\">\n\n        <section class=\"section\">\n          <div class=\"section-body\">\n            <div class=\"row\">\n              <div class=\"col-12\">\n                <div class=\"card\">\n                    <div class=\"card-body\">\n                      <h6>Audible Ring</h6>\n                      <label>In this section you can set an audible ring, and exclude numbers from the ring.</label>\n\n                    <div class=\"row\" style=\"margin-top: 20px;\">\n                          <div class=\"col-12\">\n                            <div class=\"form-group\">\n                                <label>Number</label>\n                                <input (change)=\"selectFile($event)\" type=\"file\" name=\"\" class=\"form-control\" id=\"\">\n                             </div>\n                             <br>\n                          </div>\n                          <ul>\n                            <li *ngFor=\"let item of audiblering\">{{item.original_filename}}</li>\n                          </ul>\n                    </div>\n                    </div>\n                    <div class=\"row\" style=\"margin-top: 20px;\">\n                        <div class=\"col-9\">\n                            <div class=\"card-header\">\n                            <h4>Numbers to exclude</h4></div>\n                        </div>\n                        <div class=\"col-3 text-right mt-2\">\n                            <div class=\"form-group\"  style=\"margin-right: 28px;padding: 3px;font-size: 14px;\">\n                               <button data-toggle=\"modal\" data-target=\"#addLabels\" class=\"btn btn-primary daterange-btn icon-left btn-sm btn-icon p-2\"><i class=\"fa fa-plus\"></i> Exclude a Number\n                                </button>\n                              </div>\n                        </div>\n\n                    </div>\n\n                  <div class=\"card-body\">\n                    <div class=\"table-responsive\">\n                    <table #dataTable class=\"table table-striped dataTable no-footer row-border hover\">\n                        <thead>\n                          <tr>\n                            <th>Number</th>\n                            <th>Notes</th>\n                            <th>Created Date</th>\n                            <th>Action</th>\n                          </tr>\n                        </thead>\n                        <tbody *ngIf=\"labels?.length != 0\">\n                            <tr *ngFor=\"let label of labels\">\n                                <td>{{ label.number }}</td>\n                                <td>{{ label.notes }}</td>\n                                <td>{{ label.created_at }}</td>\n                                <!-- routerLink=\"/edit-label/{{ label.uuid }}\"  -->\n                                <td><div (click)=\"Delete((label.uuid))\" class=\"actiondelete\"><i class=\"fas fa-trash\"></i></div></td>\n                            </tr>\n                        </tbody>\n                        <tbody *ngIf=\"labels?.length == 0\">\n                          <tr>\n                            <td colspan=\"8\" class=\"no-data-available\">No data Available!</td>\n                          </tr>\n                        <tbody>\n                      </table>\n                    </div>\n                  </div>\n                </div>\n              </div>\n            </div>\n          </div>\n        </section>\n\n      </div>\n";

/***/ }),

/***/ 94436:
/*!***********************************************************************!*\
  !*** ./src/app/modules/blacklist/blacklist.component.html?ngResource ***!
  \***********************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "<!--  -->\n    \n    <!-- Add Number Modal -->\n    <div class=\"modal  fade\" id=\"addNumber\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n     aria-hidden=\"true\">\n     <div class=\"modal-dialog\" role=\"document\">\n       <div class=\"modal-content\">\n         <div class=\"modal-header\">\n           <h5 class=\"modal-title\" id=\"formModal\">Add Number</h5>\n           <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n             <span aria-hidden=\"true\">&times;</span>\n           </button>\n         </div>\n         <div class=\"modal-body\">\n           <form id=\"addNumber\" [formGroup]=\"addNumberForm\" (ngSubmit)=\"onNumberSubmit()\">\n             <div class=\"form-group\">\n                 <label>Number</label>\n                 <input formControlName=\"number\" id=\"number\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': numberSubmitted && numbercontrol.number.errors }\" (keypress)=_keyPress($event) placeholder=\"(000) 000 - 0000\" maxlength=\"16\">\n                 <div *ngIf=\"numberSubmitted && numbercontrol.number.errors\" class=\"invalid-feedback\">\n                     <div *ngIf=\"numbercontrol.number.errors.required\">Number is required</div>\n                 </div>                           \n              </div>\n    \n              <div class=\"modal-footer\" style=\"padding: 0;\">\n                <button (click)=\"closeModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Create Number</button>\n                <button  type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\">Reset</button>\n               </div>\n           </form>\n         </div>\n       </div>\n     </div>\n     </div>   \n    \n    <!-- Edit Number Modal -->\n    <div class=\"modal  fade\" id=\"editNumber\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n     aria-hidden=\"true\">\n     <div class=\"modal-dialog\" role=\"document\">\n       <div class=\"modal-content\">\n         <div class=\"modal-header\">\n           <h5 class=\"modal-title\" id=\"formModal\">Save Number</h5>\n           <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n             <span aria-hidden=\"true\">&times;</span>\n           </button>\n         </div>\n         <div class=\"modal-body\">\n           <form [formGroup]=\"editNumberForm\" (ngSubmit)=\"onNumberEditSubmit()\">\n             <div class=\"form-group\">\n                 <label>Number</label>\n                 <input type=\"hidden\" name=\"uuid\" formControlName=\"uuid\">\n                 <input formControlName=\"number\" id=\"editnumber\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': numbereditSubmitted && numbereditcontrol.number.errors }\" (keypress)=_keyPress($event) placeholder=\"(000) 000 - 0000\" maxlength=\"16\">\n                 <div *ngIf=\"numbereditSubmitted && numbereditcontrol.number.errors\" class=\"invalid-feedback\">\n                     <div *ngIf=\"numbereditcontrol.number.errors.required\">Number is required</div>\n                 </div>           \n               </div>\n               \n             <div class=\"modal-footer\" style=\"padding: 0;\">\n                <button (click)=\"closeModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Save Number</button>\n                <button type=\"button\" class=\"btn btn-secondary m-t-15 waves-effect\" data-dismiss=\"modal\" aria-label=\"Close\">\n                  Close\n                </button>\n               </div>\n           </form>\n         </div>\n       </div>\n     </div>\n     </div>    \n    \n      <div class=\"main-content\">\n      \n        <section class=\"section\">\n          <div class=\"section-body\">\n            <div class=\"row\">\n              <div class=\"col-12\">\n                <div class=\"card\">\n                    <div class=\"row\" style=\"margin-top: 20px;\n                    \">\n                        <div class=\"col-8\">\n                            <div class=\"card-header\">\n                            <h4>Blacklist Numbers</h4></div>\n                        </div>\n                        <div class=\"col-4 text-right mt-2\">\n                            <div class=\"form-group\"  style=\"margin-right: 28px;padding: 3px;font-size: 14px;\">\n                               <button data-toggle=\"modal\" data-target=\"#addNumber\" class=\"btn btn-primary daterange-btn icon-left btn-sm btn-icon p-2 mr-2\"><i class=\"fa fa-plus\"></i> Add Number\n                                </button>\n                                <button [disabled]=\"ischecked === '1'\" (click)=\"onDeleteSubmit()\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-2\"><i class=\"fa fa-trash\"></i> Delete Selected\n                                </button>\n                              </div>                       \n                        </div>\n                  \n                    </div>            \n                    \n                  <div class=\"card-body\">\n                    <div class=\"table-responsive\">\n                    <table #dataTable class=\"table table-striped dataTable no-footer row-border hover\">\n                        <thead>\n                          <tr>\n                            <th style=\"padding: 10px;\">\n                              <div class=\"custom-control custom-checkbox\" *ngIf=\"numbers?.length != 0\">\n                              <input type=\"checkbox\" class=\"custom-control-input\" id=\"customCheck1\" (change)=\"checkalldelete($event)\" (click)=\"deleteselected($event)\">\n                              <label class=\"custom-control-label\" for=\"customCheck1\"></label>\n                              </div>\n                            </th>\n                            <th>Number</th>\n                            <th>Created Date</th>\n                            <th>Action</th>\n                          </tr>\n                        </thead>\n                        <tbody *ngIf=\"numbers?.length != 0\">\n                            <tr *ngFor=\"let number of numbers\">\n                                <td>\n                                  <div class=\"custom-control custom-checkbox\">\n                                  <input type=\"checkbox\" (click)=\"deleteselected($event)\" class=\"custom-control-input\" id=\"customCheck_{{number.uuid}}\"  [checked]=\"number.selected\" [value]=\"number.id\" >\n                                  <label class=\"custom-control-label\" for=\"customCheck_{{number.uuid}}\"></label>\n                                  </div>                                \n                                </td>\n                                <td>{{ number.number }}</td>\n                                <td>{{ number.created_at }}</td>\n                                <td><button (click)=\"editNumber(number.uuid,number.number)\" data-toggle=\"modal\" data-target=\"#editNumber\" class=\"btn btn-primary btn-sm actionedit\"><i class=\"far fa-edit\"></i></button>&nbsp;<button (click)=\"Delete((number.uuid))\" class=\"btn btn-danger btn-sm actiondelete\"><i class=\"fas fa-trash\"></i></button></td>\n                            </tr>\n                        </tbody>\n                        <tbody *ngIf=\"numbers?.length == 0\">\n                          <tr>\n                            <td colspan=\"8\" class=\"no-data-available\">No data Available!</td>\n                          </tr>\n                        <tbody>\n                      </table>\n                    </div>\n                  </div>\n                </div>\n              </div>\n            </div>\n          </div>\n        </section>\n        \n      </div>  ";

/***/ }),

/***/ 16079:
/*!*********************************************************************************************!*\
  !*** ./src/app/modules/campaigns/campaign-create/campaign-create.component.html?ngResource ***!
  \*********************************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "<div class=\"main-content\">\n    <section class=\"section\">\n      <div class=\"section-body\">\n        <div class=\"row\">\n          <div class=\"col-12 col-md-12 col-lg-12\">\n            <form [formGroup]=\"addForm\" (ngSubmit)=\"onSubmit()\">\n            <div class=\"card\" >\n              <div class=\"card-header\">\n                <h4> Setup Your Campaign</h4>\n              </div>\n              <div class=\"card-body\" >\n                \n                 <!-- <mat-horizontal-stepper>\n                    <mat-step *ngFor=\"let step of steps; let index = index; let last = last;\">\n                      <ng-template matStepLabel> <label class=\"col-sm-2 col-form-label\">{{ step.label }}</label></ng-template>\n                      <formly-form\n                        [form]=\"form.at(index)\"\n                        [model]=\"model\"\n                        [fields]=\"step.fields\"\n                        [options]=\"options[index]\">\n                      </formly-form>\n                \n                      <div>\n                        <button *ngIf=\"index !== 0\" matStepperPrevious class=\"btn btn-primary\" type=\"button\" (click)=\"prevStep(index)\">Back</button>\n                        <button *ngIf=\"!last\" matStepperNext class=\"btn btn-primary\" type=\"button\" [disabled]=\"!form.at(index).valid\" (click)=\"nextStep(index)\">Next</button>\n                        <button *ngIf=\"last\" class=\"btn btn-primary\" [disabled]=\"!form.valid\" type=\"submit\">Submit</button>\n                      </div>\n                    </mat-step>\n                  </mat-horizontal-stepper> -->\n                \n                  <mat-horizontal-stepper #stepper>\n                    <mat-step >\n                        <ng-template matStepLabel>Setup Your Campaign</ng-template>\n                      \n\n                        <section>\n                          <strong>Name your Campaign and choose your country.</strong>\n                          <hr>\n                              <div class=\"form-group row\">\n                                <div class=\"col-sm-2\"></div>  \n                                <label class=\"col-sm-2 col-form-label\">Campaign Name</label>\n                                <div class=\"col-sm-5\">\n                                  <input formControlName=\"campaignName\" type=\"text\" class=\"form-control\"  [ngClass]=\"{ 'is-invalid': Submitted && addFormcontrol.campaignName.errors }\" (input)=\"validatename()\">\n                                  <div *ngIf=\"Submitted && addFormcontrol.campaignName.errors\" class=\"invalid-feedback\">\n                                    <div *ngIf=\"addFormcontrol.campaignName.errors.required\">Campaign Name is required</div>\n                                </div> \n                                \n                                <div *ngIf=\"isName == 'success'  && isName != ''\" style=\"color:green;\">\n                                  Name Is Available\n                                </div> \n                                 <div *ngIf=\"isName == 'fail' && isName != ''\" style=\"color:red;\">\n                                  Name Is Not Available\n                                </div>   \n\n                                </div>\n                              </div>\n                            \n                              <div class=\"form-group row\">\n                                <div class=\"col-sm-2\"></div>  \n                                <label class=\"col-sm-2 col-form-label\">Country</label>\n                                <div class=\"col-sm-5\">\n                                  <select formControlName=\"country\" class=\"form-control\" >\n                                      <option value=\"\">Select Country</option>\n                                      <option value=\"United States\">United States</option>\n                                      <option value=\"United Kingdom\">United Kingdom</option>\n                                  </select>\n                                </div>\n                              </div>\n                        </section>\n                        <div class=\"text-right\"><br>\n                          <button [disabled]=\"isName == 'fail'\" class=\"btn btn-primary\" type=\"button\" matStepperNext>Next</button>\n                        </div>\n                   </mat-step>\n\n\n                    <mat-step>\n                        <ng-template matStepLabel>Get a Tracking Number</ng-template>\n                         <section>\n                    <strong>Get a unique Tracking Number where you or your partners can send calls or use for advertising.</strong><hr>\n                    <strong>Purchase or select an existing number to track this Campaign's calls on the Ringba platform. If you will be purchasing calls from a publisher, then assign this number to a publisher, otherwise, assign the number to yourself.</strong><hr>\n                    \n                    <div class=\"form-group row\">\n                      <div class=\"col-sm-2\"></div>  \n                      <label class=\"col-sm-2 col-form-label\"></label>\n                      <div class=\"col-sm-5\">\n                        <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                          <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': numberIsFor==0}\" (click)=\"numberIsForval(0)\"> \n                              <input class=\"form-check-input\" name=\"numberIsFor\" formControlName=\"numberIsFor\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                              Me\n                            </label>\n                            <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': numberIsFor==1}\" (click)=\"numberIsForval(1)\">\n                              <input class=\"form-check-input\" name=\"numberIsFor\" formControlName=\"numberIsFor\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                                Publisher\n                            </label>                 \n                          </div>               \n                      </div>\n                    </div>\n\n                    <div class=\"form-group row\" *ngIf=\"numberIsFor==1\">\n                      <div class=\"col-sm-2\"></div>  \n                      <label class=\"col-sm-2 col-form-label\">Publisher</label>\n                      <div class=\"col-sm-5\">\n                        <!-- <ng-select2  [data]=\"publisherdata\" formControlName=\"publisher\" [width]=\"370\">\n                        </ng-select2> -->\n                        <angular2-multiselect  [(ngModel)]=\"selectedpub\" (ngModelChange)=\"getPublisher($event)\" [data]=\"publisherdata\"[settings]=\n                        \"{\n                          enableSearchFilter: true,\n                          classes: 'filterdd',\n                          showCheckbox:false,\n                          singleSelection: true, text:'Select Publisher'}\" [ngModelOptions]=\"{standalone: true}\"></angular2-multiselect>\n                      </div>                      \n                    </div>\n                    \n                    <div class=\"form-group row\" *ngIf=\"numberIsFor==1\">\n                      <div class=\"col-sm-2\"></div>  \n                      <label class=\"col-sm-2 col-form-label\">Payout Type</label>\n                      <div class=\"col-sm-5\">\n                        <div class=\"control-group\">\n                          <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                          <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editpayout_typeval==0}\" (click)=\"payout_typevaledit(0)\"> \n                                <input class=\"form-check-input\" name=\"payout_typeedit\" formControlName=\"payout_typeedit\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                                None\n                              </label>\n                              <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editpayout_typeval==1}\" (click)=\"payout_typevaledit(1)\">\n                                <input class=\"form-check-input\" name=\"payout_typeedit\" formControlName=\"payout_typeedit\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                                Fixed Payout\n                              </label>\n                              <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editpayout_typeval==2}\" (click)=\"payout_typevaledit(2)\">\n                                <input class=\"form-check-input\" name=\"payout_typeedit\" formControlName=\"payout_typeedit\" type=\"radio\" id=\"option3\" [value]=\"2\">\n                                Revenue %\n                              </label>\n                            </div>\n                            <div *ngIf=\"Submitted && editFormcontrol.payout_typeedit.errors\" class=\"invalid-feedback\">\n                              <div *ngIf=\"editFormcontrol.payout_typeedit.errors.required\">Payout Type is required</div>\n                          </div>   \n                        </div>\n                      </div>                      \n                    </div>\n\n                    <div *ngIf=\"payout_typevalueedit != 0 && numberIsFor==1\">\n                    <div class=\"form-group row\">\n                      <div class=\"col-sm-2\"></div>  \n                      <label class=\"col-sm-2 col-form-label\">Payout Amount :</label>\n                      <div class=\"col-sm-5\">\n                          <div class=\"input-group\">\n                            <div class=\"input-group-prepend\">\n                              <div class=\"input-group-text\" id=\"btnGroupAddon\">$</div>\n                            </div>\n                            <input type=\"text\" formControlName=\"payout_amount\" class=\"form-control\" placeholder=\"Enter Payout Amount\" aria-label=\"Enter Payout Amount\" aria-describedby=\"btnGroupAddon\">\n                          </div>           \n                      </div>                      \n                    </div>\n                  \n                    <div class=\"form-group row\" *ngIf=\"numberIsFor==1\">\n                      <div class=\"col-sm-2\"></div>  \n                      <label class=\"col-sm-2 col-form-label\">Payout Trigger :</label>\n                      <div class=\"col-sm-5\">\n                         <select class=\"form-control\" formControlName=\"payout_trigger\" [value]=\"'0'\">\n                          <option value=\"0\">Inbound Call</option>\n                          <option value=\"1\">Call Length</option>\n                          <option value=\"2\">Call Successfully Connected</option>\n                        </select>     \n                      </div>                      \n                    </div>\n                    \n                    <div class=\"form-group row\" *ngIf=\"this.addForm.get('payout_trigger').value == 1 && numberIsFor==1\">\n                      <div class=\"col-sm-2\"></div>  \n                      <label class=\"col-sm-2 col-form-label\">Enter Seconds :</label>\n                      <div class=\"col-sm-5\">\n                        <input type=\"text\"  class=\"form-control\" type=\"text\" formControlName=\"payout_seconds\" placeholder=\"Enter Seconds\" />         \n                      </div>                      \n                    </div>\n\n                  </div>\n                  </section>\n\n                      <div class=\"text-right\">\n                        <button class=\"btn btn-primary mr-2\" type=\"button\" matStepperPrevious>Back</button>\n                        <button class=\"btn btn-primary\" type=\"button\" matStepperNext>Next</button>\n                      </div>\n                      <!-- </form> -->\n                    </mat-step>\n\n\n                    <mat-step>\n                      <ng-template matStepLabel>Add a Target</ng-template>\n                      <section>\n                        <strong>Forward your calls to buyers, call centers, or anywhere you'd like them to go.</strong><hr>\n                        <div class=\"form-group row\">\n                          <div class=\"col-sm-2\"></div>  \n                          <label class=\"col-sm-2 col-form-label\">Select Target</label>\n                          <div class=\"col-sm-5\">\n                            <!-- <select class=\"form-control\" formControlName=\"target\">\n                                <option value=\"\">Select Target</option>\n                                <option *ngFor=\"let item of targetdata\" value=\"{{item.uuid}}\">{{item.name}}</option>\n                            </select> -->\n                            <!-- <ng-select2  [data]=\"targetdata\" formControlName=\"target\" [width]=\"370\">\n                            </ng-select2> -->\n                            <angular2-multiselect [(ngModel)]=\"selectedtarget\" (ngModelChange)=\"getTarget($event)\" [data]=\"targetdata\" [settings]=\n                            \"{\n                              enableSearchFilter: true,\n                              classes: 'filterdd',\n                              showCheckbox:false,\n                              singleSelection: true, text:'Select Target'}\" [ngModelOptions]=\"{standalone: true}\"></angular2-multiselect>\n                          </div>\n                        </div>\n                       \n                        <div class=\"form-group row\">\n                          <div class=\"col-sm-2\"></div>  \n                          <label class=\"col-sm-2 col-form-label\">Conversation Revenue</label>\n                          <div class=\"col-sm-5\">\n                            <div class=\"input-group\">\n                              <div class=\"input-group-prepend\">\n                                <div class=\"input-group-text\" id=\"btnGroupAddon\" style=\"font-size: 12px;\">$</div>\n                              </div>\n                              <input style=\"height: 38px;\" type=\"text\" formControlName=\"conversation_revenue\" class=\"form-control\" placeholder=\"Enter Conversation Revenue\" aria-label=\"Enter Conversation Revenue\" aria-describedby=\"btnGroupAddon\" [ngClass]=\"{ 'is-invalid': submitted && f.conversation_revenue.errors }\">\n                              <div *ngIf=\"submitted && f.conversation_revenue.errors\" class=\"invalid-feedback\">\n                                <div *ngIf=\"f.conversation_revenue.errors.required\">Conversation Revenue is required</div>\n                            </div>   \n                            </div>        \n                          </div>\n                        </div>\n                       \n                        <div class=\"form-group row\">\n                          <div class=\"col-sm-2\"></div>  \n                          <label class=\"col-sm-2 col-form-label\">Conversation Event</label>\n                          <div class=\"col-sm-5\">\n                            <select formControlName=\"conversation_event\" class=\"form-control\"  [ngClass]=\"{ 'is-invalid': submitted && f.conversation_event.errors }\">\n                              <option value=\"0\">Call Length</option>\n                              <option value=\"1\">Call Successfully Connected</option>\n                            </select>  \n                            <!-- {{this.addLabelForm.get('conversation_event').value}} -->\n                            <div *ngIf=\"submitted && f.conversation_event.errors\" class=\"invalid-feedback\">\n                             <div *ngIf=\"f.conversation_event.errors.required\">Conversation Event is required</div>\n                           </div>       \n                          </div>\n                        </div>\n                        \n                        <div class=\"form-group row\" *ngIf=\"this.addForm.get('conversation_event').value == 0\">\n                          <div class=\"col-sm-2\"></div>  \n                          <label class=\"col-sm-2 col-form-label\">Enter Seconds</label>\n                          <div class=\"col-sm-5\">\n                            <input type=\"text\" formControlName=\"conversation_seconds\" class=\"form-control\" type=\"text\" placeholder=\"Enter Seconds\" />                  \n                          </div>\n                        </div>\n\n                          <div class=\"form-group row\">\n                            <div class=\"col-sm-2\"></div>  \n                            <div class=\"col-sm-2 control-label mt-2\">Recording</div>\n                            <div class=\"col-sm-5\">\n                            <label class=\"custom-switch mt-2 pl-0\">\n                              <input type=\"checkbox\" checked (change)=\"get_recordingstatus($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                              <span class=\"custom-switch-indicator\"></span>                     \n                            </label>\n                            </div>                        \n                          </div>                        \n                      </section>                     \n                      <div class=\"text-right\"><br>\n                        <button class=\"btn btn-primary mr-2\" type=\"button\" matStepperPrevious>Back</button>\n                        <button class=\"btn btn-primary\" type=\"button\" matStepperNext>Next</button>\n                      </div>\n                   </mat-step>\n                    \n                   <mat-step>\n                      <ng-template matStepLabel>Set it Live!</ng-template>\n                      <section>\n                        <strong>Test your Tracking Number to see DialDigits operate in real-time.</strong>\n                        <hr>\n                        <div class=\"form-group row\">\n                          <div class=\"col-sm-2\"></div>  \n                          <label class=\"col-sm-2 col-form-label\">Campaign Name</label>\n                          <div class=\"col-sm-5\">                           \n                            <input type=\"text\" [value]=\"this.addForm.get('campaignName').value\" class=\"form-control\" readonly>                           \n                          </div>\n                        </div>\n                      \n                        <div class=\"form-group row\">\n                          <div class=\"col-sm-2\"></div>  \n                          <label class=\"col-sm-2 col-form-label\">Country</label>\n                          <div class=\"col-sm-5\">\n                            <select class=\"form-control\" readonly [value]=\"this.addForm.get('country').value\">\n                                <option value=\"\">Select Country</option>\n                                <option value=\"United States\">United States</option>\n                            </select>\n                          </div>\n                        </div>\n    \n                        <!-- <div class=\"form-group row\">\n                          <div class=\"col-sm-2\"></div>  \n                          <label class=\"col-sm-2 col-form-label\">Choose Option</label>\n                          <div class=\"col-sm-5\">\n                            <div class=\"control-group\">\n                              <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                              <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': this.addForm.get('option').value==0}\"> \n                                  <input class=\"form-check-input\" readonly name=\"numberType\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                                  Select Existing \n                                </label>\n                                <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': this.addForm.get('option').value==1}\">\n                                  <input class=\"form-check-input\" readonly name=\"numberType\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                                    Create New\n                                </label>                 \n                              </div>                \n                          </div>        \n                          </div>\n                        </div> -->\n    \n                        <!-- <div class=\"form-group row\">\n                          <div class=\"col-sm-2\"></div>  \n                          <label class=\"col-sm-2 col-form-label\">Select Existing Number</label>\n                          <div class=\"col-sm-5\">\n                            <select class=\"form-control\" readonly [value]=\"this.addForm.get('number').value\">\n                                <option value=\"\">Select Number</option>\n                                <option *ngFor=\"let item of numberdata\" value=\"{{item.id}}\">{{item.text}}</option>\n                            </select>\n\n                             <ng-select2  [data]=\"numberdata\"\n                            [width]=\"370\"  [value]=\"this.addForm.get('number').value\" class=\"disabled\">\n                            </ng-select2>\n                          </div>\n                        </div> -->\n                       \n                        <div class=\"form-group row\">\n                          <div class=\"col-sm-2\"></div>  \n                          <label class=\"col-sm-2 col-form-label\">This number is for</label>\n                          <div class=\"col-sm-5\">\n                            <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                              <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': numberIsFor==0}\"> \n                                  <input class=\"form-check-input\" readonly name=\"numberIsFor\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                                  Me\n                                </label>\n                                <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': numberIsFor==1}\">\n                                  <input class=\"form-check-input\" readonly name=\"numberIsFor\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                                    Publisher\n                                </label>                 \n                              </div>               \n                          </div>\n                        </div>\n    \n                        <div class=\"form-group row\" *ngIf=\"numberIsFor==1\">\n                          <div class=\"col-sm-2\"></div>  \n                          <label class=\"col-sm-2 col-form-label\">Publisher</label>\n                          <div class=\"col-sm-5\">\n                            <!-- {{this.addForm.get('publisher').value[0]['id'] | json}} -->\n                            <select class=\"form-control\" readonly [value]=\"this.addForm.get('publisher').value\">\n                                <option value=\"\">Select Publisher</option>\n                                <option *ngFor=\"let item of publisherdata\" value=\"{{item.id}}\">{{item.text}}</option>\n                            </select>\n\n                            <!-- <ng-select2  [data]=\"publisherdata\"\n                            [width]=\"370\"  [value]=\"this.addForm.get('publisher').value\">\n                            </ng-select2> -->\n\n                          </div>\n                        </div>\n    \n                        <div class=\"form-group row\">\n                          <div class=\"col-sm-2\"></div>  \n                          <label class=\"col-sm-2 col-form-label\">Select Target</label>\n                          <div class=\"col-sm-5\">\n                            <select class=\"form-control\" readonly [value]=\"this.addForm.get('target').value\">\n                                <option value=\"\">Select Target</option>    \n                                <option *ngFor=\"let item of targetdata\" value=\"{{item.id}}\">{{item.text}}</option>                      \n                            </select>\n\n                            <!-- <ng-select2  [data]=\"targetdata\"\n                            [width]=\"370\"  [value]=\"this.addForm.get('target').value\">\n                            </ng-select2> -->\n\n                          </div>\n                        </div>\n    \n                      </section>            \n                      <div class=\"text-right\"><br>\n                        <button class=\"btn btn-success mr-2\" type=\"submit\">Make it Live</button>\n                        <button class=\"btn btn-primary mr-2\" type=\"button\" matStepperPrevious>Back</button>                        \n                      </div>\n                   </mat-step>\n                  </mat-horizontal-stepper>  \n\n               \n              </div>\n              <div class=\"card-footer text-right\">\n                    <!-- <button style=\"margin-right: 4px;\" type=\"submit\" class=\"btn btn-primary\">Submit</button> -->\n                    <button style=\"margin-right: 4px;\" routerLink=\"/campaigns\" class=\"btn btn-primary\">Back To All Campaigns</button>                    \n                  </div>\n            </div>\n          </form>\n\n</div>\n";

/***/ }),

/***/ 51159:
/*!*****************************************************************************************!*\
  !*** ./src/app/modules/campaigns/campaign-edit/campaign-edit.component.html?ngResource ***!
  \*****************************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "<!-- Add numbers -->\n<div class=\"modal fade\" id=\"addNumber\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\naria-hidden=\"true\">\n<div class=\"modal-dialog\" role=\"document\">\n  <div class=\"modal-content\">\n    <div class=\"modal-header\">\n      <b class=\"modal-title\" id=\"formModal\">Add Number</b>\n      <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n        <span aria-hidden=\"true\">&times;</span>\n      </button>\n    </div>\n    <div class=\"modal-body\">\n      <form id=\"addLabel\" [formGroup]=\"numberForm\" (ngSubmit)=\"onAddNoSubmit()\">\n        <div class=\"row\">\n         <div class=\"col-md-12\">\n          <div class=\"control-group\">\n            <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n            <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editpayout_typeval==0}\" (click)=\"notype_toggle(0)\">\n                  <input class=\"form-check-input\" formControlName=\"notype\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                  Add Existing Numbers\n                </label>\n                <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editpayout_typeval==1}\" (click)=\"notype_toggle(1)\">\n                  <input class=\"form-check-input\" formControlName=\"notype\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                  Purchase Number\n                </label>\n              </div>\n            </div>\n            <div *ngIf=\"notype==0\">\n              <div class=\"control-group mt-2\">\n                <label class=\"control-label input-label\" for=\"startTime\">Select Number :</label>\n                <angular2-multiselect [ngModelOptions]=\"{standalone: true}\" [data]=\"numberdata\"  [settings]=\"dropdownSettings\" [(ngModel)]=\"selectedExistingNumber\"></angular2-multiselect>\n              </div>\n            </div>\n             <div *ngIf=\"notype==1\">\n             <div class=\"control-group mt-2\">\n             <label class=\"control-label input-label\" for=\"startTime\">Number Type :</label>\n             <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n             <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editpayout_typeval==0}\" (click)=\"istollfreenotype_toggle(0)\">\n                   <input class=\"form-check-input\" formControlName=\"notype\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                   Toll Free\n                 </label>\n                 <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editpayout_typeval==1}\" (click)=\"istollfreenotype_toggle(1)\">\n                   <input class=\"form-check-input\" formControlName=\"notype\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                   Local\n                 </label>\n               </div>\n               <div *ngIf=\"addnoSubmitted && addnoFormcontrol.notype.errors\" class=\"invalid-feedback\">\n                 <div *ngIf=\"addnoFormcontrol.notype.errors.required\">Number Type is required</div>\n             </div>\n             </div>\n               <div class=\"control-group mt-2\">\n                   <label class=\"control-label input-label\" for=\"startTime\">Prefix :</label>\n                   <input type=\"number\" maxlength=\"3\"\n                   oninput=\"javascript: if (this.value.length > this.maxLength) this.value = this.value.slice(0, this.maxLength);\"\n                   class=\"form-control\" formControlName=\"prefix\" placeholder=\"Optional\" />\n               </div>\n              </div>\n\n         </div>\n\n     </div>\n\n        <div class=\"modal-footer mt-4\" style=\"padding: 0;\"> <br><br>\n           <button (click)=\"closeModal()\" type=\"submit\" class=\"btn btn-sm btn-primary m-t-15 waves-effect\">Add</button>\n           <button data-dismiss=\"modal\" aria-label=\"Close\" type=\"reset\" class=\"btn btn-sm btn-secondary m-t-15 waves-effect\">Close</button>\n          </div>\n      </form>\n    </div>\n  </div>\n</div>\n</div>\n\n\n<!-- Add Payout Modal -->\n<div class=\"modal fade\" id=\"addLabels\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n aria-hidden=\"true\">\n <div class=\"modal-dialog\" role=\"document\">\n   <div class=\"modal-content\">\n     <div class=\"modal-header\">\n       <h5 class=\"modal-title\" id=\"formModal\">Add Publisher Payout</h5>\n       <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n         <span aria-hidden=\"true\">&times;</span>\n       </button>\n     </div>\n     <div class=\"modal-body\">\n        <ngx-ui-loader [loaderId]=\"'loader-10'\"></ngx-ui-loader>\n       <form id=\"addLabel\" [formGroup]=\"payoutForm\" (ngSubmit)=\"onPayoutSubmit()\">\n         <div class=\"row\">\n          <div class=\"col-md-12\">\n            <fieldset class=\"scheduler-border\">\n              <legend class=\"scheduler-border\">Publisher Payout Conversation</legend>\n              <div class=\"control-group\">\n              <label class=\"control-label input-label\" for=\"startTime\">Payout Type :</label>\n              <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n              <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editpayout_typeval==0}\" (click)=\"payout_typevaledit(0)\">\n                    <input class=\"form-check-input\" name=\"payout_typeedit\" formControlName=\"payout_typeedit\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                    None\n                  </label>\n                  <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editpayout_typeval==1}\" (click)=\"payout_typevaledit(1)\">\n                    <input class=\"form-check-input\" name=\"payout_typeedit\" formControlName=\"payout_typeedit\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                    Fixed Payout\n                  </label>\n                  <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editpayout_typeval==2}\" (click)=\"payout_typevaledit(2)\">\n                    <input class=\"form-check-input\" name=\"payout_typeedit\" formControlName=\"payout_typeedit\" type=\"radio\" id=\"option3\" [value]=\"2\">\n                    Revenue %\n                  </label>\n                </div>\n                <div *ngIf=\"payoutSubmitted && payoutFormcontrol.payout_typeedit.errors\" class=\"invalid-feedback\">\n                  <div *ngIf=\"payoutFormcontrol.payout_typeedit.errors.required\">Payout Type is required</div>\n              </div>\n              </div>\n                <div *ngIf=\"payout_typevalueedit != 0\">\n                <div class=\"control-group mt-2\">\n                  <label class=\"control-label input-label\" *ngIf=\"payout_typevalueedit==1\" for=\"startTime\">Payout Amount :</label>\n                  <label class=\"control-label input-label\" *ngIf=\"payout_typevalueedit==2\" for=\"startTime\">Payout % :</label>\n                      <div class=\"input-group\">\n                        <div class=\"input-group-prepend\">\n                          <div class=\"input-group-text font-10\" *ngIf=\"payout_typevalueedit==1\" id=\"btnGroupAddon\">$</div>\n                          <div class=\"input-group-text font-10\" *ngIf=\"payout_typevalueedit==2\" id=\"btnGroupAddon\">%</div>\n                        </div>\n                        <input type=\"text\" style=\"height: 38px;\" formControlName=\"payout_amount\" class=\"form-control\" placeholder=\"Enter Payout\" aria-label=\"Enter Payout\" aria-describedby=\"btnGroupAddon\">\n                      </div>\n                </div>\n\n                <div class=\"control-group mt-2\">\n                  <label class=\"control-label input-label\" for=\"startTime\">Payout Trigger :</label>\n                    <select class=\"form-control\" formControlName=\"payout_trigger\" [value]=\"0\">\n                      <option value=\"0\">Inbound Call</option>\n                      <option value=\"1\">Call Length</option>\n                      <option value=\"2\">Call Successfully Connected</option>\n                    </select>\n                </div>\n                <div class=\"control-group mt-2\" *ngIf=\"this.payoutForm.get('payout_trigger').value == 1\">\n                    <label class=\"control-label input-label\" for=\"startTime\">Enter Seconds :</label>\n                    <input type=\"text\"  class=\"form-control\" type=\"text\" formControlName=\"payout_seconds\" placeholder=\"Enter Seconds\" />\n                </div>\n\n              </div>\n              </fieldset>\n          </div>\n\n      </div>\n\n         <div class=\"modal-footer\" style=\"padding: 0;\">\n          <!-- !addLabelForm.valid || -->\n            <button (click)=\"closeModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Create Publisher Payout</button>\n            <button data-dismiss=\"modal\" aria-label=\"Close\" type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\">Close</button>\n           </div>\n       </form>\n     </div>\n   </div>\n </div>\n </div>\n\n  <!-- Add campaignpayout Modal -->\n<div class=\"modal fade\" id=\"addcampaignpayout\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\naria-hidden=\"true\">\n<div class=\"modal-dialog\" role=\"document\">\n  <div class=\"modal-content\">\n    <div class=\"modal-header\">\n      <h5 class=\"modal-title\" id=\"formModal\">Default Payout Settings </h5>\n      <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n        <span aria-hidden=\"true\">&times;</span>\n      </button>\n    </div>\n    <div class=\"modal-body\">\n      <form id=\"addLabel\" [formGroup]=\"defaultpayoutForm\" (ngSubmit)=\"ondpayoutSubmit()\">\n        <div class=\"row\">\n         <div class=\"col-md-12\">\n           <fieldset class=\"scheduler-border\">\n             <legend class=\"scheduler-border\">Payout Setting</legend>\n               <div class=\"control-group mt-2\">\n                 <label class=\"control-label input-label\" for=\"startTime\">Payout Type :</label><br>\n                 <div class=\"btn-group w-100\" data-toggle=\"buttons\">\n                 <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': dpayout_type==0}\" (click)=\"payout_typeedit(0)\">\n                       <input class=\"form-check-input\" formControlName=\"payout_type\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                       None\n                     </label>\n                     <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': dpayout_type==1}\" (click)=\"payout_typeedit(1)\">\n                       <input class=\"form-check-input\" formControlName=\"payout_type\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                       Fixed Payout\n                     </label>\n                     <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': dpayout_type==2}\" (click)=\"payout_typeedit(2)\">\n                       <input class=\"form-check-input\" formControlName=\"payout_type\" type=\"radio\" id=\"option3\" [value]=\"2\">\n                       Revenue %\n                     </label>\n                   </div>\n                   <div *ngIf=\"dpSubmitted && defaultpayoutFormcontrol.payout_type.errors\" class=\"invalid-feedback\">\n                     <div *ngIf=\"defaultpayoutFormcontrol.payout_type.errors.required\">Payout Type is required</div>\n                 </div>\n                 </div>\n                   <div *ngIf=\"dpayout_type != 0\">\n                   <div class=\"control-group mt-2\">\n                       <label class=\"control-label input-label\" *ngIf=\"dpayout_type==1\" for=\"startTime\">Payout Amount :</label>\n                       <label class=\"control-label input-label\" *ngIf=\"dpayout_type==2\" for=\"startTime\">Payout % :</label>\n                         <div class=\"input-group\">\n                           <div class=\"input-group-prepend\">\n                             <div class=\"input-group-text font-10\" *ngIf=\"dpayout_type==1\" id=\"btnGroupAddon\">$</div>\n                             <div class=\"input-group-text font-10\" *ngIf=\"dpayout_type==2\" id=\"btnGroupAddon\">%</div>\n                           </div>\n                           <input type=\"text\" formControlName=\"payout_amount\" class=\"form-control\" placeholder=\"Enter Payout\" aria-label=\"Enter Payout\" aria-describedby=\"btnGroupAddon\">\n                         </div>\n                   </div>\n\n                 <div class=\"control-group mt-2\">\n                   <label class=\"control-label input-label\" for=\"startTime\">Payout Trigger :</label>\n                     <select class=\"form-control\" formControlName=\"payout_trigger\" style=\"height: 35px;padding: 7px;\">\n                       <option value=\"0\">Inbound Call</option>\n                       <option value=\"1\">Call Length</option>\n                       <option value=\"2\">Call Successfully Connected</option>\n                     </select>\n                 </div>\n                 <div class=\"control-group mt-2\" *ngIf=\"this.defaultpayoutForm.get('payout_trigger').value == 1\">\n                     <label class=\"control-label input-label\" for=\"startTime\">Enter Seconds :</label>\n                     <input type=\"text\"  class=\"form-control\" type=\"text\" formControlName=\"payout_seconds\" placeholder=\"Enter Seconds\" />\n                 </div>\n                 </div>\n             </fieldset>\n         </div>\n\n     </div>\n\n        <div class=\"modal-footer\" style=\"padding: 0;border: none;\">\n           <button (click)=\"closedpayoutModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect font-10\">Submit Payout</button>\n           <button data-dismiss=\"modal\" aria-label=\"Close\" type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect font-10\">Close</button>\n          </div>\n      </form>\n    </div>\n  </div>\n</div>\n</div>\n\n <!-- Add Publisher Modal -->\n<div class=\"modal fade\" id=\"addpublisher\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n aria-hidden=\"true\">\n <div class=\"modal-dialog\" role=\"document\">\n   <div class=\"modal-content\">\n     <div class=\"modal-header\">\n       <h5 class=\"modal-title\" id=\"formModal\">Add Publisher To Campaign</h5>\n       <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n         <span aria-hidden=\"true\">&times;</span>\n       </button>\n     </div>\n     <div class=\"modal-body\">\n       <form id=\"addLabel\" [formGroup]=\"publishtertocampaignForm\" (ngSubmit)=\"onpublisherSubmit()\">\n         <div class=\"row\">\n          <div class=\"col-md-12\">\n            <fieldset class=\"scheduler-border\">\n              <legend class=\"scheduler-border\">Add Publisher</legend>\n                <div class=\"control-group mt-2\">\n                    <label class=\"control-label input-label\" for=\"startTime\">Publisher :</label>\n                    <angular2-multiselect [ngModelOptions]=\"{standalone: true}\" [data]=\"publisherdata\"  [settings]=\"pubdropdownSettings\" [(ngModel)]=\"publisherselected\"></angular2-multiselect>\n                </div>\n\n                <!-- <div class=\"control-group mt-2\">\n                  <label class=\"control-label input-label\" for=\"startTime\">Payout Type :</label>\n                  <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                  <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editpayout_typeval==0}\" (click)=\"payout_typevaledit(0)\">\n                        <input class=\"form-check-input\" name=\"payout_typeedit\" formControlName=\"payout_typeedit\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                        None\n                      </label>\n                      <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editpayout_typeval==1}\" (click)=\"payout_typevaledit(1)\">\n                        <input class=\"form-check-input\" name=\"payout_typeedit\" formControlName=\"payout_typeedit\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                        Fixed Payout\n                      </label>\n                      <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editpayout_typeval==2}\" (click)=\"payout_typevaledit(2)\">\n                        <input class=\"form-check-input\" name=\"payout_typeedit\" formControlName=\"payout_typeedit\" type=\"radio\" id=\"option3\" [value]=\"2\">\n                        Revenue %\n                      </label>\n                    </div>\n                    <div *ngIf=\"publisherSubmitted && publisherFormcontrol.payout_typeedit.errors\" class=\"invalid-feedback\">\n                      <div *ngIf=\"publisherFormcontrol.payout_typeedit.errors.required\">Payout Type is required</div>\n                  </div>\n                  </div>\n                    <div *ngIf=\"payout_typevalueedit != 0\">\n                    <div class=\"control-group mt-2\">\n                        <label class=\"control-label input-label\" *ngIf=\"payout_typevalueedit==1\" for=\"startTime\">Payout Amount :</label>\n                       <label class=\"control-label input-label\" *ngIf=\"payout_typevalueedit==2\" for=\"startTime\">Payout % :</label>\n                          <div class=\"input-group\">\n                            <div class=\"input-group-prepend\">\n                              <div class=\"input-group-text font-10\" *ngIf=\"payout_typevalueedit==1\" id=\"btnGroupAddon\">$</div>\n                             <div class=\"input-group-text font-10\" *ngIf=\"payout_typevalueedit==2\" id=\"btnGroupAddon\">%</div>\n                            </div>\n                            <input type=\"text\" formControlName=\"payout_amount\" class=\"form-control\" placeholder=\"Enter Payout\" aria-label=\"Enter Payout\" aria-describedby=\"btnGroupAddon\">\n                          </div>\n                    </div>\n\n                  <div class=\"control-group mt-2\">\n                    <label class=\"control-label input-label\" for=\"startTime\">Payout Trigger :</label>\n                      <select class=\"form-control\" formControlName=\"payout_trigger\">\n                        <option value=\"0\">Inbound Call</option>\n                        <option value=\"1\">Call Length</option>\n                        <option value=\"2\">Call Successfully Connected</option>\n                      </select>\n                  </div>\n                  <div class=\"control-group mt-2\" *ngIf=\"this.publishtertocampaignForm.get('payout_trigger').value == 1\">\n                      <label class=\"control-label input-label\" for=\"startTime\">Enter Seconds :</label>\n                      <input type=\"text\"  class=\"form-control\" type=\"text\" formControlName=\"payout_seconds\" placeholder=\"Enter Seconds\" />\n                  </div>\n                  </div> -->\n\n                  <div class=\"control-group mt-2\">\n                    <label class=\"control-label input-label\" for=\"startTime\">Select Number :</label>\n                    <angular2-multiselect [ngModelOptions]=\"{standalone: true}\" [data]=\"numberdata\"  [settings]=\"dropdownSettings\" [(ngModel)]=\"publisherNumber\"></angular2-multiselect>\n                  </div>\n\n              </fieldset>\n          </div>\n\n      </div>\n\n         <div class=\"modal-footer\" style=\"padding: 0;\">\n          <!-- !addLabelForm.valid || -->\n            <button type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Add Publisher</button>\n            <button data-dismiss=\"modal\" aria-label=\"Close\" type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\">Close</button>\n           </div>\n       </form>\n     </div>\n   </div>\n </div>\n </div>\n\n<!-- Edit Routing Modal -->\n<div class=\"modal fade\" id=\"editRouting\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\naria-hidden=\"true\">\n<div class=\"modal-dialog\" role=\"document\">\n  <div class=\"modal-content\">\n    <div class=\"modal-header\" style=\"border-bottom: none;\">\n      <h5 class=\"modal-title\" id=\"formModal\">Edit Routing Plan</h5>\n      <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n        <span aria-hidden=\"true\">&times;</span>\n      </button>\n    </div>\n    <div class=\"modal-header pt-0\">\n      <h6 class=\"modal-title\" id=\"formModal\">{{targetname}}</h6>\n    </div>\n    <div class=\"modal-body\">\n      <form id=\"addLabel\" [formGroup]=\"editRoutingForm\" (ngSubmit)=\"oneditRoutingSubmit()\">\n          <fieldset class=\"scheduler-border\">\n             <legend class=\"scheduler-border\">Update Routing Plan</legend>\n               <div class=\"control-group mt-2\">\n                 <input type=\"hidden\" name=\"\" formControlName=\"uuid\">\n                <label class=\"control-label input-label\" for=\"startTime\">Pririty :</label>\n                <input type=\"number\" formControlName=\"priority\" class=\"form-control\"/>\n              </div>\n\n              <div class=\"control-group mt-2\">\n                <label class=\"control-label input-label\" for=\"startTime\">Weight :</label>\n                <input type=\"number\" formControlName=\"weight\" class=\"form-control\"/>\n              </div>\n\n               <div class=\"control-group mt-2\">\n                   <label class=\"control-label input-label\">Conversation Revenue :</label>\n                   <div class=\"input-group\">\n                    <div class=\"input-group-prepend\">\n                      <div class=\"input-group-text font-10\" id=\"btnGroupAddon\">$</div>\n                    </div>\n                    <input type=\"text\" formControlName=\"conversation_revenue\" class=\"form-control\" placeholder=\"Enter Conversation Revenue\" aria-label=\"Enter Conversation Revenue\" aria-describedby=\"btnGroupAddon\" [ngClass]=\"{ 'is-invalid': submitted && f.conversation_revenue.errors }\">\n                    <div *ngIf=\"submitted && f.conversation_revenue.errors\" class=\"invalid-feedback\">\n                      <div *ngIf=\"f.conversation_revenue.errors.required\">Conversation Revenue is required</div>\n                  </div>\n                  </div>\n               </div>\n\n               <div class=\"control-group mt-2\">\n                   <label class=\"control-label input-label\" for=\"startTime\">Conversation Event :</label>\n                   <select formControlName=\"conversation_event\" class=\"form-control\"  [ngClass]=\"{ 'is-invalid': submitted && f.conversation_event.errors }\">\n                    <option value=\"0\">Call Length</option>\n                    <option value=\"1\">Call Successfully Connected</option>\n                  </select>\n                   <div *ngIf=\"submitted && f.conversation_event.errors\" class=\"invalid-feedback\">\n                       <div *ngIf=\"f.conversation_event.errors.required\">Conversation Event is required</div>\n                  </div>\n               </div>\n\n                 <div class=\"control-group mt-2\"  *ngIf=\"this.editRoutingForm.get('conversation_event').value==0\">\n                   <label class=\"control-label input-label\" for=\"startTime\">Enter Seconds :</label>\n                   <input type=\"text\" formControlName=\"conversation_seconds\" class=\"form-control\" type=\"text\" placeholder=\"Enter Seconds\" />\n\n                 </div>\n\n\n                 <div class=\"control-group mt-2\">\n                  <label>Restrict Duplicate</label>\n                  <select #restrictdup formControlName=\"restrictdup\" name=\"restrictdup\" id=\"restrictdup\" class=\"form-control\">\n                    <option value=\"0\">Buyer Settings (Do not Restrict)</option>\n                    <option value=\"1\">Do not Restrict</option>\n                    <option value=\"2\">By Campaign - Individual Target</option>\n                  </select>\n               </div>\n               <div *ngIf=\"restrictdup.value==2\">\n               <div class=\"control-group mt-2\">\n                  <label>Restrict After</label>\n                  <select formControlName=\"restrictafter\" name=\"restrictafter\" id=\"restrictafter\" class=\"form-control\">\n                    <option value=\"0\">Converted</option>\n                    <option value=\"1\">Connected</option>\n                  </select>\n               </div>\n                <div class=\"control-group\">\n                    <label class=\"control-label input-label\" for=\"startTime\">Duration:</label>\n                    <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                    <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': settingToggleDurationvalue==0}\" (click)=\"settingToggleDuration(0)\">\n                          <input class=\"form-check-input\" name=\"settingToggleDuration\" formControlName=\"settingToggleDuration\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                          Always\n                    </label>\n                    <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': settingToggleDurationvalue==1}\" (click)=\"settingToggleDuration(1)\">\n                      <input class=\"form-check-input\" name=\"settingToggleDuration\" formControlName=\"settingToggleDuration\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                      Time Limit\n                    </label>\n                      </div>\n               </div>\n                <br>\n                <div class=\"control-group row mt-2\" *ngIf=\"this.editRoutingForm.get('settingToggleDurationval').value==1\">\n                  <div class=\"col-3\"><input  formControlName=\"days\" style=\"width: 80px;\" type=\"number\"  class=\"form-control formcontrol\" name=\"\" id=\"\"></div>\n                  <div class=\"col-2 mt-2\"><span>Days</span></div>\n                </div>\n                </div>\n\n             </fieldset>\n\n        <div class=\"modal-footer\" style=\"padding: 0;\">\n         <!-- !addLabelForm.valid || -->\n           <button (click)=\"closeroutingModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Edit Routing Plan</button>\n           <button data-dismiss=\"modal\" aria-label=\"Close\" type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\">Close</button>\n          </div>\n      </form>\n\n</div>\n</div>\n</div>\n</div>\n\n<!-- Approve offer details -->\n<div class=\"modal fade\" id=\"approveoffermodel\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\naria-hidden=\"true\">\n<div class=\"modal-dialog\" role=\"document\">\n  <div class=\"modal-content\">\n    <div class=\"modal-header\">\n      <b class=\"modal-title\" id=\"formModal\">Task Details</b>\n      <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n        <span aria-hidden=\"true\">&times;</span>\n      </button>\n    </div>\n    <div class=\"modal-body\">\n      <div class=\"row\">\n        <div class=\"col-md-3 font-12\">Publisher Name</div>\n        <div class=\"col-md-9 font-12\">{{parreqdata ? parreqdata.from:null}}</div>\n      </div> <br>\n\n      <div class=\"row\">\n        <div class=\"col-md-3 font-12\">Campaign Name</div>\n        <div class=\"col-md-9 font-12\">{{parreqdata ? parreqdata.campaign:null}}</div>\n      </div><br>\n\n      <div class=\"row\">\n        <div class=\"col-md-3 font-12\">Description</div>\n        <div class=\"col-md-9 font-12\">{{parreqdata ? parreqdata.content:null}}</div>\n      </div><br> <hr style=\"background: #606060;\" class=\"mt-2\">\n\n      <div class=\"row\">\n        <div class=\"col-md-12 d-flex\">\n          <input type=\"button\" (click)=\"approverejoffer(2)\" value=\"Approve\" class=\"w-auto btn btn-primary btn-sm\" style=\"background: #3858E7;\">\n          <input type=\"button\" (click)=\"approverejoffer(3)\" value=\"Reject\" class=\"ml-2 w-auto btn btn-danger btn-sm\">\n          <input type=\"button\" value=\"Close\" data-dismiss=\"modal\" aria-label=\"Close\" class=\"w-auto ml-2 btn btn-primary btn-sm\">\n        </div>\n      </div>\n\n    </div>\n  </div>\n</div>\n</div>\n\n<div class=\"main-content\">\n    <section class=\"section\">\n      <div class=\"section-body\">\n        <div class=\"row\">\n          <div class=\"col-12 col-md-12 col-lg-12\">\n            <div style=\"border-top: 1px solid #2f3031\"></div>\n              <div class=\"row\">\n                <div class=\"col-12 col-md-12 col-lg-12\">\n                <div class=\"input-group\" style=\"background: #111319;padding-bottom: 11px;\">\n                  <button id=\"tabs1\" (click)=\"getType(1,0)\" class=\"camtabsbtn camactivetab\"><i class=\"fa fa-cog m-r-5 f-s-14\"></i> Campaign Settings</button>\n                  <button id=\"tabs2\" (click)=\"getType(2,0)\" class=\"camtabsbtn\"><i class=\"fa fa-users m-r-5 f-s-14\"></i> Offer <i *ngIf=\"offerdetails && offerdetails.status==1\" class=\"fa fa-circle text-success\"></i></button>\n                  <button id=\"tabs3\" (click)=\"getType(3,0)\" class=\"camtabsbtn\"><i class=\"fa fa-chart-bar font-14\"></i> Performance Summary</button>\n                </div>\n              </div>\n            </div>\n            <div class=\"row\" [style.display]=\"filtertype == 1?'block':'none'\">\n              <div class=\"col-12 col-md-12 col-lg-12\">\n              <form [formGroup]=\"editForm\" (ngSubmit)=\"onSubmit()\" >\n              <div class=\"card\" >\n                <div class=\"card-body\" >\n\n                  <fieldset class=\"scheduler-border\">\n                  <legend class=\"scheduler-border\">Setup Your Campaign</legend>\n                  <section>\n                    <strong>Name your Campaign and choose your country.</strong>\n                    <hr>\n                    <div class=\"form-group row\">\n                      <div class=\"col-sm-2\"></div>\n                      <label class=\"col-sm-2 col-form-label\">Campaign Name</label>\n                      <div class=\"col-sm-5\">\n                        <input formControlName=\"campaignName\" type=\"text\" class=\"form-control\"  [ngClass]=\"{ 'is-invalid': Submitted && editFormcontrol.campaignName.errors }\" (input)=\"validatename()\">\n                        <div *ngIf=\"Submitted && editFormcontrol.campaignName.errors\" class=\"invalid-feedback\">\n                          <div *ngIf=\"editFormcontrol.campaignName.errors.required\">Campaign Name is required</div>\n                      </div>\n                      <div *ngIf=\"isName == 'success'  && isName != ''\" style=\"color:green;\">\n                        Name Is Available\n                      </div>\n                      <div *ngIf=\"isName == 'fail' && isName != ''\" style=\"color:red;\">\n                        Name Is Not Available\n                      </div>\n\n                      </div>\n                    </div>\n\n                    <div class=\"form-group row\">\n                      <div class=\"col-sm-2\"></div>\n                      <label class=\"col-sm-2 col-form-label\">Country</label>\n                      <div class=\"col-sm-5\">\n                        <select formControlName=\"country\" class=\"form-control\">\n                            <option value=\"\">Select Country</option>\n                            <option value=\"United States\">United States</option>\n                            <option value=\"United Kingdom\">United Kingdom</option>\n                        </select>\n                      </div>\n                    </div>\n                  </section>\n          </fieldset>\n\n          <fieldset class=\"scheduler-border\" >\n            <legend class=\"scheduler-border\">Default Payout Settings</legend>\n            <section>\n             <div class=\"dps\" #targetDiv>\n          <input type=\"button\" *ngIf=\"defaultconf==''\" data-toggle=\"modal\" data-target=\"#addcampaignpayout\" value=\"+ ADD CAMPAIGN PAYOUT SETTINGS\" class=\"btn btn-primary btn-sm p-1 mb-3\">\n          <div style=\"border-left: 4px solid #3858e7 !important;left: 16px;background: #13161f;padding: 8px\" *ngIf=\"defaultconf!=''\">\n            <div class=\"row\" >\n              <div class=\"col-md-10 font-13\"><span style=\"color: gray;\">1 | </span> {{defaultconf}}</div>\n              <div class=\"col-md-2 text-right pr-4 font-13\" style=\"cursor: pointer;\"><i class=\"fa fa-edit\" data-toggle=\"modal\" data-target=\"#addcampaignpayout\"></i> <i (click)=\"Deletedefaultpayout()\" class=\"ml-2 mr-2 fa fa-trash\"></i></div>\n            </div>\n          </div>\n        </div>\n        </section>\n        </fieldset>\n\n          <fieldset class=\"scheduler-border\">\n            <legend class=\"scheduler-border\">Predicate Routing Settings</legend>\n          <div class=\"form-group\">\n            <div class=\"control-label mt-2\">Enable Predicate Routing</div>\n            <label class=\"custom-switch mt-2 pl-0\">\n              <input type=\"checkbox\" [checked]=\"ispredicaterouting==1\" (change)=\"get_predicaterouting($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n              <span class=\"custom-switch-indicator\"></span>\n            </label>\n          </div>\n          <!-- {{this.editForm.get('enable_predicaterouting').value}} -->\n            <!-- <fieldset class=\"scheduler-border\"> -->\n              <!-- <legend class=\"scheduler-border\">Predicate Routing Settings</legend> -->\n            <div class=\"form-group\" *ngIf=\"this.editForm.get('enable_predicaterouting').value == 1\">\n              <div class=\"control-label mt-2\">Select Predicate Routing</div>\n              <select name=\"\" id=\"\" class=\"form-control\" formControlName=\"predicate_routing\">\n                <option value=\"\">Select Predicate Routing</option>\n                <option value=\"{{item.id}}\" *ngFor=\"let item of PredicateRouting\">{{item.text}}</option>\n              </select>\n            </div>\n          <!-- </fieldset> -->\n        </fieldset>\n\n\n          <fieldset class=\"scheduler-border\">\n              <legend class=\"scheduler-border\">Publishers</legend>\n              <section>\n\n            <input type=\"button\"  data-toggle=\"modal\" data-target=\"#addpublisher\" value=\"+ ADD PUBLISHER TO CAMPAIGN\" class=\"btn btn-primary btn-sm p-1 mb-3\">\n            <button (click)=\"exportdata()\" type=\"button\" class=\"btn btn-primary ml-2 waves-effect btn-sm p-1 mb-3\">Export</button>\n            <ngx-ui-loader [loaderId]=\"'loader-04'\"></ngx-ui-loader>\n            <table #dataTable class=\"table table-striped dataTable no-footer row-border hover\" style=\"width: 100%;\">\n              <thead>\n                <tr>\n                  <th>Enabled</th>\n                  <th>Publisher</th>\n                  <th>Number</th>\n                  <!-- <th>Associated Label</th> -->\n                  <th>Configuration Overrides</th>\n                  <th>Status</th>\n                  <th>Actions</th>\n                </tr>\n              </thead>\n              <tbody *ngIf=\"campaignpublisher?.length != 0\">\n                  <tr *ngFor=\"let data of campaignpublisher\">\n                      <td>\n                        <div *ngIf=\"data.enabled==1\" class=\"badge badge-success\">Yes</div>\n                        <div *ngIf=\"data.enabled==0\" class=\"badge badge-danger\">No</div>\n                      </td>\n                      <td>{{data.publisher}}</td>\n                      <!-- <td>{{data.phoneno==\"\"?'None':data.phoneno}}</td> -->\n                      <td>\n\n                        <span *ngFor=\"let nodata of data.phoneno\">\n                          <p *ngIf=\"nodata.number!=''\">{{nodata.number}} <i title=\"Release Number\" *ngIf=\"data.phoneno.length>1\" style=\"cursor:pointer\" (click)=\"DeletePayoutNo(nodata.uuid,nodata.number_uuid)\" class=\"fas-1x fas fa-trash ml-2\"></i></p>\n                        </span>\n                        <p *ngIf=\"data.phoneno.length==0\">-</p>\n                      </td>\n                      <!-- <td>\n                        <span *ngFor=\"let labels of data.labels?.split(',')\">\n                            <span class=\"badge badge-primary p-1 ml-1\">{{labels}}</span><br>\n                        </span>\n                      </td> -->\n                      <td>{{data.conf}}</td>\n                      <td>\n                        <div *ngIf=\"data.status==1\" class=\"fa fa-circle text-success\"></div>\n                        <div *ngIf=\"data.status==0\" class=\"fa fa-circle text-danger\"></div>\n                      </td>\n                      <td><div title=\"Edit Numbers\" data-toggle=\"modal\" (click)=\"getpayoutdata(data.publisher_uuid,data.phoneno,data.number_uuid)\" data-target=\"#addLabels\" class=\"btn btn-primary btn-sm actionedit\"><i class=\"far fa-edit\"></i></div>&nbsp;\n                        <div (click)=\"setuuid(data.uuid)\" title=\"Add Numbers\" class=\"w-auto btn btn-primary btn-sm\" data-toggle=\"modal\" data-target=\"#addNumber\" style=\"border: 1px solid green!important\"><i class=\"fa fa-plus\"></i></div>&nbsp;\n                        <div title=\"Delete Numbers\" (click)=\"DeletePublisherPayout((data.uuid))\" class=\"btn btn-danger btn-sm actiondelete\"><i class=\"fas fa-trash\"></i></div>\n                      </td>\n                  </tr>\n              </tbody>\n              <tbody *ngIf=\"campaignpublisher?.length == 0\">\n                <tr>\n                  <td colspan=\"6\" class=\"no-data-available\">No data Available!</td>\n                </tr>\n              <tbody>\n            </table>\n          </section>\n          </fieldset>\n\n          <fieldset class=\"scheduler-border\">\n          <legend class=\"scheduler-border\">Target</legend>\n          <section>\n\n          <div class=\"row\">\n            <div class=\"col-md-6\">\n              <strong>Forward your calls to buyers, call centers, or anywhere you'd like them to go.</strong><hr>\n            <!-- <input type=\"button\" style=\"width: 100px;\" data-toggle=\"modal\" data-target=\"#addTarget\" value=\"+ NEW\" class=\"btn btn-primary btn-sm p-1 mb-3\"> -->\n              <div class=\"table-responsive\">\n              <table #dataTableTarget class=\"table table-striped  dataTable no-footer row-border hover\" style=\"width: 100%;\">\n              <thead>\n                <tr>\n                  <th>Name</th>\n                  <th>Destination</th>\n                  <th>Status</th>\n                  <th>Add</th>\n                </tr>\n              </thead>\n              <tbody *ngIf=\"allTargets?.length != 0\">\n                  <tr *ngFor=\"let data of allTargets\">\n                      <td>{{data.name}}</td>\n                      <!-- <td>{{data.valtype}} - {{data.typeval}}</td> -->\n                      <td *ngIf=\"data.valtype =='IVR Menu'\"><a style=\"color: white;text-decoration: underline;\" routerLink=\"/edit-ivr/{{ data.ivrmenu_uuid }}\" >{{data.valtype}} - {{data.typeval}}</a></td>\n                      <td *ngIf=\"data.valtype !='IVR Menu'\">{{data.valtype}} - {{data.typeval}}</td>\n                      <!-- <td>\n                        <div *ngIf=\"data.active_status==1\" class=\"fa fa-circle text-success\"></div>\n                        <div *ngIf=\"data.active_status==0\" class=\"fa fa-circle text-danger\"></div>\n                      </td> -->\n                      <td>\n                        <div title=\"Active\" *ngIf=\"data.hrsofopestatus==1\" class=\"fa fa-circle text-success\"></div>\n                        <div title=\"Inactive\" *ngIf=\"data.hrsofopestatus==0\" class=\"fa fa-circle text-danger\"></div>\n                        <div title=\"Outof hours\" *ngIf=\"data.hrsofopestatus==2\" class=\"fa fa-circle text-warning\"></div>\n                      </td>\n\n                      <td *ngIf=\"data.isavailinpayout==0\"><div (click)=\"setRouting(data.uuid)\" class=\"btn btn-primary btn-sm actionedit\"><i class=\"fa fa-arrow-right\"></i></div>\n                      </td>\n                      <td *ngIf=\"data.isavailinpayout!=0\">\n                        <span class=\"badge badge-success\">Added</span>\n                      </td>\n                  </tr>\n              </tbody>\n              <tbody *ngIf=\"allTargets?.length == 0\">\n                <tr>\n                  <td colspan=\"5\" class=\"no-data-available\">No data Available!</td>\n                </tr>\n              <tbody>\n            </table>\n          </div>\n          </div>\n          <div class=\"col-md-6\">\n            <strong>Routing Plan</strong><hr>\n            <div class=\"table-responsive\">\n            <table #dataTableRouting class=\"table table-striped dataTable no-footer row-border hover\" style=\"width: 100%;\">\n            <thead>\n              <tr>\n                <th>Priority</th>\n                <th>Weight</th>\n                <th>Name</th>\n                <th>Destination</th>\n                <!-- <th>Type</th>                                         -->\n                <th>Revenue</th>\n                <th>Status</th>\n                <!-- <th>Status</th>                                         -->\n                <th>Action</th>\n              </tr>\n            </thead>\n            <tbody *ngIf=\"allRoutingPlan?.length != 0\">\n                <tr *ngFor=\"let data of allRoutingPlan;let i = index;\">\n                  <!-- <td *ngIf=\"data.priority==0\">{{i+1}}</td> -->\n                  <!-- <td *ngIf=\"data.priority!=0\">{{data.priority}}</td> -->\n                  <td><input type=\"number\" style=\"font-size:12px\" (change)=\"changeVal(data.uuid,$event.target.value,1)\" class=\"form-control\" value=\"{{data.priority}}\" />    </td>\n                  <td><input type=\"number\" style=\"font-size:12px\" (change)=\"changeVal(data.uuid,$event.target.value,0)\" class=\"form-control\" value=\"{{data.weight}}\" />    </td>\n                  <!-- <td>{{data.weight}}</td> -->\n                  <td *ngIf=\"data.destinationtype ==1\"><a style=\"color: white;text-decoration: underline;\" routerLink=\"/edit-ivr/{{ data.destinationuuid }}\" >\n                    {{data.name}}</a></td>\n                  <td *ngIf=\"data.destinationtype !=1\">\n                    <a style=\"color: white;text-decoration: underline;\" routerLink=\"/edit-numbers/{{data.target_uuid }}\" >\n                    {{data.name}}\n                    </a>\n                  </td>\n\n                  <td *ngIf=\"data.destinationtype ==1\"><a style=\"color: white;text-decoration: underline;\" routerLink=\"/edit-ivr/{{ data.destinationuuid }}\" >\n                    {{data.destination}}</a></td>\n                  <td *ngIf=\"data.destinationtype !=1\">\n                    <a style=\"color: white;text-decoration: underline;\" routerLink=\"/edit-numbers/{{data.target_uuid }}\" >\n                    {{data.destination}}\n                    </a>\n                  </td>\n                  <td>{{data.revenue}}</td>\n                  <td>\n                    <div title=\"Active\" *ngIf=\"data.status==1\" class=\"fa fa-circle text-success\"></div>\n                    <div title=\"Inactive\" *ngIf=\"data.status==0\" class=\"fa fa-circle text-danger\"></div>\n                    <div title=\"Outof hours\" *ngIf=\"data.status==2\" class=\"fa fa-circle text-warning\"></div>\n                  </td>\n                  <!-- <td>\n                  <div *ngIf=\"data.status==0\" class=\"fa fa-circle text-success\"></div>\n                  <div *ngIf=\"data.status==1\" class=\"fa fa-circle text-danger\"></div>\n                </td> -->\n                  <td><div (click) =\"editRoutingdata(data.uuid,data.priority,data.weight,data.revenuevalue,data.type,data.seconds,data.restrictdup,data.restrictafter,data.settingToggleDurationval,data.days,data.name)\" data-toggle=\"modal\" data-target=\"#editRouting\" class=\"btn btn-primary btn-sm actionedit\"><i class=\"fa fa-edit\"></i></div>&nbsp;<div (click)=\"DeleteRoutingPlan((data.uuid))\" class=\"btn btn-danger btn-sm actiondelete\"><i class=\"fas fa-trash\"></i></div>\n                </td>\n                </tr>\n            </tbody>\n            <tbody *ngIf=\"allRoutingPlan?.length == 0\">\n              <tr>\n                <td colspan=\"6\" class=\"no-data-available\">No data Available!</td>\n              </tr>\n            <tbody>\n          </table>\n          </div>\n          </div>\n        </div>\n          </section>\n          </fieldset>\n\n          <div class=\"row\">\n            <div class=\"col-md-3\">\n              <fieldset class=\"scheduler-border\">\n                <legend class=\"scheduler-border\">Recording Settings</legend>\n              <div class=\"form-group\">\n                <div class=\"control-label mt-2\">Recording</div>\n                <label class=\"custom-switch mt-2 pl-0\">\n                  <input type=\"checkbox\" [checked]=\"isrecording==1\" (change)=\"get_recordingstatus($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                  <span class=\"custom-switch-indicator\"></span>\n                </label>\n              </div>\n            </fieldset>\n            </div>\n\n            <div class=\"col-md-3\">\n              <fieldset class=\"scheduler-border\">\n                <legend class=\"scheduler-border\">Blacklist Alliance Settings</legend>\n              <div class=\"form-group\">\n                <div class=\"control-label mt-2\">Enable Blacklist Alliance API</div>\n                <label class=\"custom-switch mt-2 pl-0\">\n                  <input type=\"checkbox\" [checked]=\"isblacklistaliance==1\" (change)=\"get_blacklistAliance($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                  <span class=\"custom-switch-indicator\"></span>\n                </label>\n              </div>\n            </fieldset>\n            </div>\n\n            <div class=\"col-md-3\">\n              <fieldset class=\"scheduler-border\">\n                <legend class=\"scheduler-border\">Enable Offer Settings</legend>\n              <div class=\"form-group\">\n                <div class=\"control-label mt-2\">Enable Offer for this campaign</div>\n                <label class=\"custom-switch mt-2 pl-0\">\n                  <input type=\"checkbox\" *ngIf=\"getdata && getdata.is_enable_offer==0\" (change)=\"is_enable_offer_toggle($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                  <input type=\"checkbox\" *ngIf=\"getdata && getdata.is_enable_offer==1\" [checked]=\"true\" (change)=\"is_enable_offer_toggle($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                  <span class=\"custom-switch-indicator\"></span>\n                </label>\n              </div>\n            </fieldset>\n            </div>\n\n\n\n\n          </div>\n\n                  <br>\n                  <button class=\"btn btn-primary btn-sm p-1 mr-2\" type=\"submit\">Update</button>\n                  <button style=\"margin-right: 4px;\" routerLink=\"/campaigns\" class=\"btn btn-sm p-1 btn-primary\">Back To All Campaigns</button>\n\n                </div>\n              </div>\n              </form>\n              </div>\n            </div>\n\n            <div class=\"row\" [style.display]=\"filtertype == 2?'block':'none'\">\n              <div class=\"col-12 col-md-12 col-lg-12\">\n                <div class=\"card\" >\n                  <div class=\"card-body\" >\n\n                    <fieldset class=\"scheduler-border\" style=\"border-left: 4px solid #3858e7 !important;\" *ngIf=\"isshowmessage\">\n                    <section class=\"pt-4\" >\n                      <h6>An Offer is a convenient way to present the campaign to your publishers. It is a public representation of the campaign that allows publishers to quickly decide whether they want to send calls to a campaign and whether their calls meet the requirements.</h6>\n                      <input type=\"button\" value=\"Hide\" class=\"btn btn-primary btn-sm p-1 mb-3\" (click)=\"isshowmessagetoggle()\" >\n                      <!-- <input type=\"button\" value=\"Don't show this again\" class=\"ml-1 btn btn-primary btn-sm p-1 mb-3\"> -->\n                    </section>\n                    </fieldset>\n                    <div *ngIf=\"campaignoffers?.length>0\">\n                        <fieldset class=\"scheduler-border\">\n                            <legend class=\"scheduler-border\">Your Offer is Published! Here are some next steps.</legend>\n                            <section class=\"p-2\">\n                              <div class=\"row mt-2\">\n                                <div class=\"col-md-3\">\n                                  <div class=\"thumbnail text-center\"> <img width=\"130\" src=\"./assets/img/call-tracking.png\"> <div class=\"caption text-center mt-2\"> <p><strong class=\"font-14\">1. Configure Payouts Settings</strong></p> <p class=\"font-12\">Payout Settings allow you to define default payout settings for all Offer Publishers.</p> </div> <br>\n                                  <br><input (click)=\"getType(1,1)\" type=\"button\" value=\"Configure Payouts\" class=\"btn btn-primary font-13\" style=\"background-color: #3858e7;\">\n                                  </div>\n                                </div>\n\n                                <div class=\"col-md-3\">\n                                  <div class=\"thumbnail text-center\"> <img width=\"130\" src=\"./assets/img/payout.png\"> <div class=\"caption text-center mt-2\"> <p><strong class=\"font-14\">2. Invite Some Publishers</strong></p> <p class=\"font-12\">Invite your Publishers to participate in your new Offer. If your offer visibility is set to \"Account\", any Publisher in this account will be able to join this Offer.</p> </div> <br>\n                                  <input type=\"button\" (click)=\"getType(1,2)\" value=\"Invite Publishers\" class=\"btn btn-primary font-13\" style=\"background-color: #3858e7;\">\n                                  </div>\n                                </div>\n\n                                <div class=\"col-md-3\">\n                                  <div class=\"thumbnail text-center\"> <img width=\"130\" src=\"./assets/img/url-tracking.png\"> <div class=\"caption text-center mt-2\"> <p><strong class=\"font-14\">3. Refine Offer Details</strong></p> <p class=\"font-12\">Communicate Offer details and restrictions in the Offer \"Description\" and \"Notes\" to ensure only the best Publishers for this Offer participate.</p> </div> <br>\n                                  <input type=\"button\" [scrollTo]=\"'#place1'\" [scrollDuration]=\"1000\" [scrollOffset]=\"-100\" value=\"Add Details\" class=\"btn btn-primary font-13\" style=\"background-color: #3858e7;\">\n                                  </div>\n                                </div>\n\n                                <div class=\"col-md-3\">\n                                  <div class=\"thumbnail text-center\"> <img width=\"130\" src=\"./assets/img/optimize.png\"> <div class=\"caption text-center mt-2\"> <p><strong class=\"font-14\">4. Configure Number Restrictions</strong></p> <p class=\"font-12\">Override Offer number restrictions to allow specific participating Publishers more flexibility for allocating numbers.</p> </div> <br>\n                                <br> <input type=\"button\" value=\"Override Restrictions\" class=\"btn btn-primary font-13\" style=\"background-color: #3858e7;\">\n                                  </div>\n                                </div>\n\n                            </div>\n                            </section>\n                        </fieldset>\n\n                      <div *ngIf=\"offerdetails && offerdetails.status==1\" style=\"background: #252C44;padding: 15px;\">\n                          <h6>Participation Requests</h6>\n                          <div class=\"row\">\n                            <div class=\"col-12 col-md-12 col-lg-12\">\n                              <div class=\"input-group\" style=\"background: #111319;padding-bottom: 11px;\">\n                                <button id=\"tabs3\" style=\"width: 50%;height: 41px;\" (click)=\"getParticipationType(1)\" class=\"camactivetab camtabsbtn\">Pending Requests <span class=\"badge badge-danger\" *ngIf=\"pendingdata?.length>0\">{{pendingdata?.length}}</span></button>\n                                <button style=\"width: 50%;height: 41px;\" id=\"tabs4\" (click)=\"getParticipationType(2)\" class=\"camtabsbtn\">Request History <span class=\"badge badge-success\" *ngIf=\"completed?.length>0\">{{completed?.length}}</span></button>\n                              </div>\n                            </div>\n                          </div>\n\n                          <div class=\"row\" [style.display]=\"pfiltertype == 1?'block':'none'\">\n                          <div class=\"col-12 col-md-12 col-lg-12\">\n\n                              <div>\n                                <ngx-ui-loader [loaderId]=\"'loader-03'\"></ngx-ui-loader>\n                                <div class=\"table-responsive\">\n                                  <table class=\"table table-striped dataTable no-footer row-border hover\" datatable [dtOptionsPending]=\"dtOptionsPending\" [dtTrigger]=\"dtTrigger\">\n\n                                    <thead>\n                                      <tr>\n                                        <th>Description</th>\n                                        <th>From</th>\n                                        <th>Status</th>\n                                        <th>Created</th>\n                                      </tr>\n                                    </thead>\n                                    <tbody *ngIf=\"pendingdata?.length != 0\">\n                                      <tr *ngFor=\"let data of pendingdata\" style=\"cursor:pointer\">\n                                          <td data-toggle=\"modal\" data-target=\"#approveoffermodel\" (click)=\"reqdata(data)\">{{data.description}} <br>\n                                          {{data.subdescription}}\n                                          </td>\n                                          <td data-toggle=\"modal\" data-target=\"#approveoffermodel\" (click)=\"reqdata(data)\">{{data.from}}</td>\n                                          <td data-toggle=\"modal\" data-target=\"#approveoffermodel\" (click)=\"reqdata(data)\"><span class=\"badge badge-primary\">Open</span></td>\n                                          <td>{{data.created_at}}</td>\n                                      </tr>\n                                  </tbody>\n                                    <tbody *ngIf=\"pendingdata?.length == 0\">\n                                      <tr>\n                                        <td colspan=\"4\" class=\"no-data-available\">No data Available!</td>\n                                      </tr>\n                                    <tbody>\n                                  </table>\n                                </div>\n                              </div>\n\n                            </div>\n                          </div>\n\n                          <div class=\"row\" [style.display]=\"pfiltertype == 2?'block':'none'\">\n                          <div class=\"col-12 col-md-12 col-lg-12\">\n\n                              <div class=\"\">\n                                <ngx-ui-loader [loaderId]=\"'loader-03'\"></ngx-ui-loader>\n                                <div class=\"table-responsive\">\n                                  <table class=\"table table-striped dataTable no-footer row-border hover\" datatable [dtOptionsPending]=\"dtOptionsPending\" [dtTrigger]=\"dtTrigger\">\n\n                                    <thead>\n                                      <tr>\n                                        <th>Description</th>\n                                        <th>From</th>\n                                        <th>Status</th>\n                                        <th>Completed</th>\n                                      </tr>\n                                    </thead>\n                                    <tbody *ngIf=\"completed?.length != 0\">\n                                      <tr *ngFor=\"let data of completed\">\n                                          <td>{{data.description}} <br>\n                                          {{data.subdescription}}\n                                          </td>\n                                          <td>{{data.from}}</td>\n                                          <td><span class=\"badge badge-success\">Completed</span></td>\n                                          <td>{{data.updated_at}}</td>\n                                      </tr>\n                                  </tbody>\n                                    <tbody *ngIf=\"completed?.length == 0\">\n                                      <tr>\n                                        <td colspan=\"4\" class=\"no-data-available\">No data Available!</td>\n                                      </tr>\n                                    <tbody>\n                                  </table>\n                                </div>\n                              </div>\n\n                            </div>\n                          </div>\n                          <!-- <br/>\n                          <div *ngIf=\"diffdays!=0\" [ngClass]=\"{'text-danger': diffdays<5, 'text-success': diffdays>5}\" class=\"text-right font-15\">{{offerdetails ? offerdetails.exp_date:null}} ({{diffdays}} Days Left)</div>\n                          <div *ngIf=\"diffdays==0\" [ngClass]=\"{'text-danger': diffdays<5, 'text-success': diffdays>5}\" class=\"text-right font-15\">{{offerdetails ? offerdetails.exp_date:null}} (Plan Expired)</div> -->\n                      </div>\n                        <br>\n                        <div *ngIf=\"(offerdetails) || (isadded)\">\n                        <h6>Published Offer</h6>\n                        <hr style=\"background: green;\" class=\"mt-1\">\n\n                        <div class=\"row\">\n                          <div class=\"col-md-3 font-12\">Offer Title</div>\n                          <div class=\"col-md-3 font-12\">{{offerdetails ? offerdetails.name:null}}</div>\n                        </div>\n                        <div class=\"row mt-3\">\n                          <div class=\"col-md-3 font-12\">Description</div>\n                          <div class=\"col-md-3 font-12\">\n                            <div [innerHTML]=\"offerdetails ? offerdetails.description:null\"></div>\n                          </div>\n                        </div>\n                        <div class=\"row mt-3\">\n                          <div class=\"col-md-3 font-12\">Payout</div>\n                          <div class=\"col-md-3 font-12\">{{offerdetails ? offerdetails.payout:null}}</div>\n                        </div>\n                        <div class=\"row mt-3\">\n                          <div class=\"col-md-3 font-12\">Duration</div>\n                          <div class=\"col-md-3 font-12\">{{offerdetails ? offerdetails.duration:null}}</div>\n                        </div>\n                        <div class=\"row mt-3\">\n                          <div class=\"col-md-3 font-12\">Hours Of Operation</div>\n                          <div class=\"col-md-3 font-12\">{{offerdetails ? offerdetails.hoursofoperation:null}}</div>\n                        </div>\n                        <div class=\"row mt-3\">\n                          <div class=\"col-md-3 font-12\">Expiry Date</div>\n                          <div class=\"col-md-3 font-12\">{{offerdetails ? offerdetails.exp_date:null}}</div>\n                        </div>\n                        <div class=\"row mt-3\">\n                          <div class=\"col-md-3 font-12\">Require Approval</div>\n                          <div class=\"col-md-3 font-12\" *ngIf=\"offerdetails && offerdetails.req_approval==1\"><i class=\"fa fa-check\"></i></div>\n                          <div class=\"col-md-3 font-12\" *ngIf=\"offerdetails && offerdetails.req_approval==0\"><i class=\"fa fa-times\"></i></div>\n                        </div>\n                        <br>\n                        <!-- <strong class=\"font-15\">Publisher Number Limits</strong>\n                        <div class=\"row mt-3\">\n                          <div class=\"col-md-3 font-12\">Max Numbers Per Publisher</div>\n                          <div class=\"col-md-3 font-12\">{{offerdetails ? offerdetails.max_no_per_publisher:null}}</div>\n                        </div>\n                        <div class=\"row mt-3\">\n                          <div class=\"col-md-3 font-12\">Allow Toll-Free Number</div>\n                          <div class=\"col-md-3 font-12\" *ngIf=\"offerdetails && offerdetails.allow_tollfree_no==1\"><i class=\"fa fa-check\"></i></div>\n                          <div class=\"col-md-3 font-12\" *ngIf=\"offerdetails && offerdetails.allow_tollfree_no==0\"><i class=\"fa fa-times\"></i></div>\n                        </div>\n                        <div class=\"row mt-3 mb-4\">\n                          <div class=\"col-md-3 font-12\">Allow DID Numbers</div>\n                          <div class=\"col-md-3 font-12\" *ngIf=\"offerdetails && offerdetails.allow_did_no==1\"><i class=\"fa fa-check\"></i></div>\n                          <div class=\"col-md-3 font-12\" *ngIf=\"offerdetails && offerdetails.allow_did_no==0\"><i class=\"fa fa-times\"></i></div>\n                        </div>    -->\n\n                        <button class=\"w-auto btn btn-primary btn-sm\" (click)=\"isedittoggle()\"><i class=\"fa fa-edit\"></i> Edit</button>\n\n                        <button *ngIf=\"(offerdetails && offerdetails.status==2)\" class=\"ml-2 w-auto btn btn-primary btn-sm\" (click)=\"changeofferstatus(1)\" style=\"background: #3858E7;\"><i class=\"fa fa-pause\"></i> Resume Offer</button>\n\n                        <button *ngIf=\"(offerdetails && offerdetails.status!=2)\" class=\"ml-2 w-auto btn btn-primary btn-sm\" (click)=\"changeofferstatus(2)\" style=\"background: #3858E7;\"><i class=\"fa fa-pause\"></i> Pause Offer</button>\n\n                        <button class=\"w-auto ml-2 btn btn-primary btn-sm\" (click)=\"changeofferstatus(3)\" style=\"border: 1px solid red!important\"><i class=\"fa fa-power-off\"></i> End Offer</button>\n                        <!-- <button *ngIf=\"getdata.is_enable_offer==0\" style=\"background: #3858E7;\" class=\"w-auto ml-2 btn btn-primary btn-sm\" (click)=\"changeofferstatus(4)\"><i class=\"fa fa-toggle-on\"></i> Enable Offer</button>\n                        <button *ngIf=\"getdata.is_enable_offer==1\" style=\"border: 1px solid red!important\" class=\"w-auto ml-2 btn btn-primary btn-sm\" (click)=\"changeofferstatus(5)\"><i class=\"fa fa-toggle-on\"></i> Disable Offer</button> -->\n                        <br>\n                        <br>\n\n                        </div>\n\n\n                    </div>\n\n                    <div *ngIf=\"campaignoffers?.length==0 || isedit\" id=\"editdiv\" class=\"editdiv\" #place1>\n                        <input *ngIf=\"!iscreateoffer && !offerdetails\" type=\"button\" (click)=\"iscreateoffertoggle()\" value=\"+ Create Offer\" class=\"btn btn-primary font-13 p-2 mb-3\" style=\"border: 1px solid green!important\">\n\n                        <div *ngIf=\"iscreateoffer\">\n\n                        <div class=\"row mt-2 mb-0 pb-0\">\n                          <div class=\"col-md-12 font-16\" *ngIf=\"!isedit\">New Offer</div>\n                          <div class=\"col-md-12 font-16\" *ngIf=\"isedit\">Draft</div>\n                        </div>\n                          <hr style=\"background: #606060;\" class=\"mt-2\">\n\n                          <form id=\"addoffer\" [formGroup]=\"addofferForm\" (ngSubmit)=\"onAddOfferSubmit(buttonType)\">\n                          <div class=\"row\">\n                            <div class=\"col-md-3 font-13 text-right\" >Display Name  <i class=\"fa fa-question-circle\" data-toggle=\"tooltip\" data-placement=\"right\" title=\"The hours of operation where your publisher should be credited for calls.\"></i></div>\n                            <div class=\"col-md-5 font-13\" >\n                                <input formControlName=\"name\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': addofferSubmitted && addOfferFormcontrol.name.errors }\" required>\n                                <div *ngIf=\"addofferSubmitted && addOfferFormcontrol.name.errors\" class=\"invalid-feedback\">\n                                    <div *ngIf=\"addOfferFormcontrol.name.errors.required\">Name is required</div>\n                                </div>\n                            </div>\n\n                          </div><br>\n\n                          <div class=\"row\">\n                            <div class=\"col-md-3 font-13 text-right\">Description  <i class=\"fa fa-question-circle\" data-toggle=\"tooltip\" data-placement=\"right\" title=\"The hours of operation where your publisher should be credited for calls.\"></i></div>\n                            <div class=\"col-md-5 font-13\" >\n                                  <!-- <input type=\"text\" formControlName=\"description\" class=\"form-control\">                                 -->\n                                  <!-- <editor [init]=\"{\n                                    apiKey:'qagffr3pkuv17a8on1afax661irst1hbr4e6tbv888sz91jc',\n                                    height: 500,\n                                    skin: 'borderless',\n                                    menubar: false,\n                                  }\"></editor> -->\n                                  <editor\n                                  apiKey=\"qagffr3pkuv17a8on1afax661irst1hbr4e6tbv888sz91jc\"\n                                  class=\"mat-elevation-z1\"\n                                  formControlName=\"description\"\n                                  [init]=\"{\n                                    icons: 'material',\n                                    skin: 'oxide-dark',\n                                    content_css: 'dark',\n                                    min_height: 150,\n                                    plugins: [\n                                      'advlist', 'autolink', 'lists', 'link', 'image', 'charmap', 'preview',\n                                      'anchor', 'searchreplace', 'visualblocks', 'code', 'fullscreen',\n                                      'insertdatetime', 'media', 'table', 'help', 'wordcount'\n                                    ],\n                                    toolbar: 'undo redo | blocks | ' +\n                                    'bold italic backcolor | alignleft aligncenter ' +\n                                    'alignright alignjustify | bullist numlist outdent indent | ' +\n                                    'removeformat | help',\n                                    content_style: 'body { font-family:Helvetica,Arial,sans-serif; font-size:16px }'\n                                  }\"\n                                ></editor>\n\n                                  <!-- <tinymce [(ngModel)]=\"html\" [config]=\"config\"></tinymce> -->\n                            </div>\n                          </div><br>\n\n                          <div class=\"row\">\n                            <div class=\"col-md-3 font-13 text-right\">Hours of Operation  <i class=\"fa fa-question-circle\" data-toggle=\"tooltip\" data-placement=\"right\" title=\"The hours of operation where your publisher should be credited for calls.\"></i></div>\n                            <div class=\"col-md-5 font-13\" >\n                                  <input type=\"text\" formControlName=\"hoursofoperation\" class=\"form-control\">\n                            </div>\n                          </div><br>\n\n\n                          <div class=\"row\">\n                            <div class=\"col-md-3 font-13 text-right\" >Expiration Timezone  <i class=\"fa fa-question-circle\" data-toggle=\"tooltip\" data-placement=\"right\" title=\"The hours of operation where your publisher should be credited for calls.\"></i></div>\n                            <div class=\"col-md-5 font-13\" >\n                                  <select name=\"\" id=\"\" class=\"form-control\" formControlName=\"exp_timezone\">\n                                    <option value=\"\">Select Timezone</option>\n                                    <option value=\"{{item.id}}\" *ngFor=\"let item of alltimezone\">{{item.gmtzone}}</option>\n                                  </select>\n                            </div>\n                          </div><br>\n\n                          <div class=\"row\">\n                            <div class=\"col-md-3 font-13 text-right\" >Expiration Date <i class=\"fa fa-question-circle\" data-toggle=\"tooltip\" data-placement=\"right\" title=\"The hours of operation where your publisher should be credited for calls.\"></i></div>\n                            <div class=\"col-md-3 font-13\" >\n                                  <input type=\"date\" formControlName=\"exp_date\" [(ngModel)]=\"today\" class=\"form-control\" id=\"\">\n                            </div>\n                            <div class=\"col-md-2 font-13\" >\n                                <div  style=\"display:-webkit-inline-box\">\n                                  <div class=\"form-group\">\n                                      <input style=\"width:68px\" formControlName=\"start_hrs\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                                  </div>\n                                  <div class=\"pt-2\">\n                                    :\n                                  </div>\n                                <div class=\"text-left\">\n                                    <div class=\"form-group\">\n                                        <input style=\"width:68px\" formControlName=\"start_min\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                                    </div>\n                                </div>\n                              </div>\n                            </div>\n                          </div><br>\n<!--\n                          <div class=\"row\">\n                            <div class=\"col-md-3 font-13 text-right\" >Offer Visibility <i class=\"fa fa-question-circle\" data-toggle=\"tooltip\" data-placement=\"right\" title=\"The hours of operation where your publisher should be credited for calls.\"></i></div>\n                            <div class=\"col-md-5 font-13\" >\n                                  <select name=\"\" id=\"\" class=\"form-control\" formControlName=\"offer_\">\n                                    <option value=\"\">Private</option>\n                                    <option value=\"\">Account</option>\n                                  </select>\n                            </div>\n                          </div><br> -->\n\n                          <div class=\"row\">\n                            <div class=\"col-md-3 font-13 text-right\" >Require Approval <i class=\"fa fa-question-circle\" data-toggle=\"tooltip\" data-placement=\"right\" title=\"The hours of operation where your publisher should be credited for calls.\"></i></div>\n                            <div class=\"col-md-5 font-13\" >\n                              <div class=\"form-group\">\n                                <label class=\"custom-switch pl-0\">\n                                  <input type=\"checkbox\" [checked]=\"is_approval==1\" (change)=\"is_approvaltoggle($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                                  <span class=\"custom-switch-indicator\"></span>\n                                </label>\n                              </div>\n                            </div>\n                          </div><br>\n\n                          <div class=\"row mt-2 mb-0 pb-0\">\n                            <div class=\"col-md-12 font-16\">Publisher Number Limits</div>\n                          </div>\n                          <hr style=\"background: #606060;\" class=\"mt-2\">\n\n                          <div class=\"row\">\n                            <div class=\"col-md-3 font-13 text-right\" >Max Numbers Per Publisher  <i class=\"fa fa-question-circle\" data-toggle=\"tooltip\" data-placement=\"right\" title=\"The hours of operation where your publisher should be credited for calls.\"></i></div>\n                            <div class=\"col-md-5 font-13 d-flex\" >\n                                <input type=\"number\" formControlName=\"max_no_per_publisher\" class=\"form-control appleinput\" >\n                            </div>\n                          </div><br>\n\n                          <div class=\"row\">\n                            <div class=\"col-md-3 font-13 text-right\" >Allow Toll-Free Numbers <i class=\"fa fa-question-circle\" data-toggle=\"tooltip\" data-placement=\"right\" title=\"The hours of operation where your publisher should be credited for calls.\"></i></div>\n                            <div class=\"col-md-5 font-13\" >\n                              <div class=\"form-group\">\n                                <label class=\"custom-switch pl-0\">\n                                  <input type=\"checkbox\" [checked]=\"isallow_tollfree_no==1\" (change)=\"allow_tollfree_notoggle($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                                  <span class=\"custom-switch-indicator\"></span>\n                                </label>\n                              </div>\n                            </div>\n                          </div><br>\n\n                          <div class=\"row\">\n                            <div class=\"col-md-3 font-13 text-right\" >Allow DID Numbers <i class=\"fa fa-question-circle\" data-toggle=\"tooltip\" data-placement=\"right\" title=\"The hours of operation where your publisher should be credited for calls.\"></i></div>\n                            <div class=\"col-md-5 font-13\" >\n                              <div class=\"form-group\">\n                                <label class=\"custom-switch pl-0\">\n                                  <input type=\"checkbox\" [checked]=\"allow_did_no==1\" (change)=\"is_allow_did_notoggle($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                                  <span class=\"custom-switch-indicator\"></span>\n                                </label>\n                              </div>\n                            </div>\n                          </div><br>\n                          <br>\n                          <div class=\"row\">\n                            <div class=\"col-md-3\"></div>\n                            <div class=\"col-md-5 d-flex\">\n                              <input type=\"button\" (click)=\"onAddOfferSubmit(0)\" value=\"Save As Draft\" class=\"w-auto btn btn-primary btn-sm\" style=\"background: #3858E7;\">\n                              <input type=\"button\" (click)=\"onAddOfferSubmit(1)\" value=\"Save & Publish\" class=\"w-auto btn btn-primary ml-2 btn-sm\" style=\"border: 1px solid green!important\">\n                              <input type=\"button\" value=\"Cancel\"  (click)=\"iscreateoffertoggle()\" style=\"border: 1px solid red!important\" class=\"w-auto ml-2 btn btn-primary btn-sm\">\n                            </div>\n                          </div>\n                        </form>\n\n\n\n<!--\n                          <div class=\"row\">\n                            <div class=\"col-md-2\"></div>\n                            <div class=\"col-md-3 font-13 text-right\">Payout Type <i class=\"fa fa-question-circle\" data-toggle=\"tooltip\" data-placement=\"right\" title=\"Payouts are a fixed price or a percentage of revenue.\"></i></div>\n                            <div class=\"col-md-5 font-13\" >\n                              <div class=\"control-group\">\n                                <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                                    <label class=\"btn btn-primary form-check-label font-10\" [ngClass]=\"{'active': editpayout_typeval==1}\" (click)=\"payout_typevaledit(1)\">\n                                      <input class=\"form-check-input\" name=\"payout_typeedit\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                                      Fixed Amount\n                                    </label>\n                                    <label class=\"btn btn-primary form-check-label font-10\" [ngClass]=\"{'active': editpayout_typeval==2}\" (click)=\"payout_typevaledit(2)\">\n                                      <input class=\"form-check-input\" name=\"payout_typeedit\" type=\"radio\" id=\"option3\" [value]=\"2\">\n                                      Revshare Percentage\n                                    </label>\n                                  </div>\n                                  <div *ngIf=\"publisherSubmitted && publisherFormcontrol.payout_typeedit.errors\" class=\"invalid-feedback\">\n                                    <div *ngIf=\"publisherFormcontrol.payout_typeedit.errors.required\">Payout Type is required</div>\n                                  </div>\n                                </div>\n                            </div>\n                          </div> <br>\n                          <div class=\"row\">\n                            <div class=\"col-md-2\"></div>\n                            <div class=\"col-md-3 font-13 text-right\" >Duplicate Payouts <i class=\"fa fa-question-circle\" data-toggle=\"tooltip\" data-placement=\"right\" title=\"When enabled the publisher will be credited on duplicate or repeat calls. Disabling this option will prevent them from being paid multiple times. Time limits allow for duplicate payouts after a specific length of time.\"></i></div>\n                            <div class=\"col-md-5 font-13\" >\n                              <div class=\"control-group\">\n                                <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                                    <label class=\"btn btn-primary form-check-label font-10\" [ngClass]=\"{'active': editpayout_typeval==1}\" (click)=\"payout_typevaledit(1)\">\n                                      <input class=\"form-check-input\" name=\"payout_typeedit\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                                      Disable\n                                    </label>\n                                    <label class=\"btn btn-primary form-check-label font-10\" [ngClass]=\"{'active': editpayout_typeval==2}\" (click)=\"payout_typevaledit(2)\">\n                                      <input class=\"form-check-input\" name=\"payout_typeedit\" type=\"radio\" id=\"option3\" [value]=\"2\">\n                                      Enable\n                                    </label>\n                                    <label class=\"btn btn-primary form-check-label font-10\" [ngClass]=\"{'active': editpayout_typeval==2}\" (click)=\"payout_typevaledit(2)\">\n                                      <input class=\"form-check-input\" name=\"payout_typeedit\" type=\"radio\" id=\"option3\" [value]=\"2\">\n                                      Time Limit\n                                    </label>\n                                  </div>\n\n                                </div>\n                            </div>\n                          </div> -->\n                          <!--\n                          <div class=\"row\">\n                            <div class=\"col-md-2\"></div>\n                            <div class=\"col-md-3 font-13 text-right\" >Limit Payout <i class=\"fa fa-question-circle\" data-toggle=\"tooltip\" data-placement=\"right\" title=\"Set caps to payouts based on calls, amount, and concurrency\"></i> </div>\n                            <div class=\"col-md-3 font-13\">\n                              <div class=\"form-group\">\n                                <label class=\"custom-switch pl-0\">\n                                  <input type=\"checkbox\" [checked]=\"isrecording==1\" (change)=\"get_recordingstatus($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                                  <span class=\"custom-switch-indicator\"></span>\n                                </label>\n                              </div>\n                            </div>\n                          </div><br>\n                          <div class=\"row mt-2 mt-2 mb-0 pb-0\">\n                            <div class=\"col-md-12 font-13\">Tag Filters for Payout <i class=\"fa fa-question-circle\" data-toggle=\"tooltip\" data-placement=\"right\" title=\"Specify Tag Filters to give payout only if the call satisfies the filters.\"></i></div>\n                          </div> -->\n\n\n                        </div>\n                    </div>\n\n\n\n                  </div>\n                </div>\n              </div>\n            </div>\n\n            <div class=\"row\" [style.display]=\"filtertype == 3?'block':'none'\">\n              <div class=\"col-12 col-md-12 col-lg-12\">\n              <section>\n                <div class=\"card\">\n                      <div class=\"card-header\">\n                        <h6><i class=\"material-icons\">show_chart</i> Performance Summary</h6>\n                    </div>\n\n                  <div class=\"card-body\">\n                    <div [chart]=\"chart\"></div>\n                    <hr>\n                    <div class=\"table-responsive\">\n                    <table #PerdataTable class=\"table table-striped dataTable no-footer row-border hover\" style=\"width: 100%;\">\n                      <thead>\n                        <tr>\n\n                           <th>-</th>\n                           <th>Incoming</th>\n                           <th>Not Connected</th>\n                           <th>Completed</th>\n                           <th>Converted</th>\n                           <th>No Answer</th>\n                           <th>Revenue</th>\n                           <th>Payout</th>\n                        </tr>\n                      </thead>\n                      <tbody *ngIf=\"labels?.length != 0\">\n                          <tr *ngFor=\"let data of labels;let i=index\">\n                              <!-- <th>-</th> -->\n                              <td style=\"width:10%\">{{data.date}}<br>{{data.day}}</td>\n                              <!-- <th>{{labels[1].date}}<br>{{labels[1].day}}</th>\n                              <th>{{labels[2].date}}<br>{{labels[2].day}}</th>\n                              <th>{{labels[3].date}}<br>{{labels[3].day}}</th>\n                              <th>{{labels[4].date}}<br>{{labels[4].day}}</th>\n                              <th>{{labels[5].date}}<br>{{labels[5].day}}</th>\n                              <th>{{labels[6].date}}<br>{{labels[6].day}}</th> -->\n\n                              <td>{{ data.incoming}}</td>\n                              <td>{{ data.connected}}</td>\n                              <td>{{ data.completed}}</td>\n                              <td>{{ data.converted}}</td>\n                              <td>{{ data.noanswer}}</td>\n                              <td style=\"width:13%\">{{ data.revenue}}</td>\n                              <td style=\"width:13%\">{{ data.payout }}</td>\n                          </tr>\n                      </tbody>\n                      <tbody *ngIf=\"labels?.length == 0\">\n                        <tr>\n                          <td colspan=\"15\" class=\"no-data-available\">No data Available!</td>\n                        </tr>\n                      <tbody>\n                    </table>\n                    </div>\n                  </div>\n                </div>\n              </section>\n            </div>\n            </div>\n      </div>\n      </div>\n      </div>\n    </section>\n</div>\n";

/***/ }),

/***/ 63681:
/*!*****************************************************************************************!*\
  !*** ./src/app/modules/campaigns/campaign-view/campaign-view.component.html?ngResource ***!
  \*****************************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "  <!-- Approve offer details -->\n  <div class=\"modal fade\" id=\"addNumber\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n  aria-hidden=\"true\">\n  <div class=\"modal-dialog\" role=\"document\">\n    <div class=\"modal-content\">\n      <div class=\"modal-header\">\n        <b class=\"modal-title\" id=\"formModal\">Add Number</b>\n        <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n          <span aria-hidden=\"true\">&times;</span>\n        </button>\n      </div>\n      <div class=\"modal-body\">\n        <form id=\"addLabel\" [formGroup]=\"numberForm\" (ngSubmit)=\"onAddNoSubmit()\">\n          <div class=\"row\">\n           <div class=\"col-md-12\">\n               <div class=\"control-group\">\n               <label class=\"control-label input-label\" for=\"startTime\">Number Type :</label>\n               <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n               <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editpayout_typeval==0}\" (click)=\"payout_typevaledit(0)\">\n                     <input class=\"form-check-input\" formControlName=\"notype\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                     Toll Free\n                   </label>\n                   <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editpayout_typeval==1}\" (click)=\"payout_typevaledit(1)\">\n                     <input class=\"form-check-input\" formControlName=\"notype\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                     Local\n                   </label>\n                 </div>\n                 <div *ngIf=\"addnoSubmitted && addnoFormcontrol.notype.errors\" class=\"invalid-feedback\">\n                   <div *ngIf=\"addnoFormcontrol.notype.errors.required\">Number Type is required</div>\n               </div>\n               </div>\n                 <div class=\"control-group mt-2\">\n                     <label class=\"control-label input-label\" for=\"startTime\">Prefix :</label>\n                     <input type=\"number\" maxlength=\"3\"\n                     oninput=\"javascript: if (this.value.length > this.maxLength) this.value = this.value.slice(0, this.maxLength);\"\n                     class=\"form-control\" formControlName=\"prefix\" placeholder=\"Optional\" />\n                 </div>\n\n           </div>\n\n       </div>\n\n          <div class=\"modal-footer mt-4\" style=\"padding: 0;\"> <br><br>\n             <button (click)=\"closeModal()\" type=\"submit\" class=\"btn btn-sm btn-primary m-t-15 waves-effect\">Add</button>\n             <button data-dismiss=\"modal\" aria-label=\"Close\" type=\"reset\" class=\"btn btn-sm btn-secondary m-t-15 waves-effect\">Close</button>\n            </div>\n        </form>\n      </div>\n    </div>\n  </div>\n  </div>\n\n  <div class=\"main-content\">\n      <section class=\"section\">\n        <div class=\"section-body\">\n          <div class=\"row\">\n            <div class=\"col-12 col-md-12 col-lg-12\">\n              <div style=\"border-top: 1px solid #2f3031\"></div>\n                <div class=\"row\">\n                  <div class=\"col-12 col-md-12 col-lg-12\">\n                  <div class=\"input-group\" style=\"background: #111319;padding-bottom: 11px;\">\n                    <button id=\"tabs1\" (click)=\"getType(1,0)\" class=\"camtabsbtn camactivetab\"><i class=\"fa fa-cog m-r-5 f-s-14\"></i> Campaign Settings</button>\n                    <button id=\"tabs2\" (click)=\"getType(2,0)\" class=\"camtabsbtn\"><i class=\"fa fa-users m-r-5 f-s-14\"></i> Offer <i *ngIf=\"offerdetails && offerdetails.status==1\" class=\"fa fa-circle text-success\"></i></button>\n                    <button id=\"tabs3\" (click)=\"getType(3,0)\" class=\"camtabsbtn\"><i class=\"fa fa-chart-bar font-14\"></i> Performance Summary</button>\n                  </div>\n                </div>\n              </div>\n\n              <div class=\"row\" [style.display]=\"filtertype == 1?'block':'none'\">\n                <div class=\"col-12 col-md-12 col-lg-12\">\n\n                <div class=\"card\" >\n                  <div class=\"card-body\" >\n\n                    <fieldset class=\"scheduler-border\">\n                    <legend class=\"scheduler-border\">General Info</legend>\n                    <section>\n                      <div class=\"form-group row\">\n                        <div class=\"col-sm-2\"></div>\n                        <label class=\"col-sm-2 col-form-label\">Campaign ID</label>\n                        <div class=\"col-sm-5\">\n                          {{getdata && getdata.uuid}}\n                        </div>\n                      </div>\n\n                      <div class=\"form-group row\">\n                        <div class=\"col-sm-2\"></div>\n                        <label class=\"col-sm-2 col-form-label\">Campaign Name</label>\n                        <div class=\"col-sm-5\">\n                          {{getdata && getdata.name}}\n                        </div>\n                      </div>\n\n                      <div class=\"form-group row\">\n                        <div class=\"col-sm-2\"></div>\n                        <label class=\"col-sm-2 col-form-label\">Country</label>\n                        <div class=\"col-sm-5\">\n                          {{getdata && getdata.country}}\n                        </div>\n                      </div>\n                    </section>\n            </fieldset>\n\n            <fieldset class=\"scheduler-border\">\n              <legend class=\"scheduler-border\">Default Payout Settings</legend>\n              <section>\n               <div class=\"dps\">\n                  <div style=\"border-left: 4px solid #3858e7 !important;left: 16px;background: #13161f;padding: 8px\" >\n                    <div class=\"row\" >\n                      <div class=\"col-md-10 font-13\" *ngIf=\"defaultconf!=''\"><span style=\"color: gray;\">1 | </span> {{defaultconf}}</div>\n                      <div class=\"col-md-10 font-13\" *ngIf=\"defaultconf==''\">Not Set</div>\n                    </div>\n                  </div>\n              </div>\n              </section>\n          </fieldset>\n\n\n            <fieldset class=\"scheduler-border\">\n              <legend class=\"scheduler-border\">Numbers</legend>\n              <section>\n              <div class=\"mb-4\">\n                <button *ngIf=\"campaignpublisher?.length == 0\" class=\"w-auto btn btn-primary btn-sm\" data-toggle=\"modal\" data-target=\"#addNumber\" style=\"border: 1px solid green!important\"><i class=\"fa fa-plus\"></i> Add Number</button>\n                <span *ngIf=\"campaignpublisher?.length > 0\"> 1 of 1 Offer Numbers available</span>\n              </div>\n              <ngx-ui-loader [loaderId]=\"'loader-04'\"></ngx-ui-loader>\n              <table #dataTable class=\"table table-striped dataTable no-footer row-border hover\" style=\"width: 100%;\">\n                <thead>\n                  <tr>\n                    <th>Number</th>\n                    <th>Actions</th>\n                  </tr>\n                </thead>\n                <tbody *ngIf=\"campaignpublisher?.length != 0\">\n                    <tr *ngFor=\"let data of campaignpublisher\">\n                        <td>{{data.phoneno}}</td>\n                        <td>\n                          <!-- <div data-toggle=\"modal\" (click)=\"getpayoutdata(data.publisher_uuid,data.phoneno,data.number_uuid)\" data-target=\"#addLabels\" class=\"btn btn-primary btn-sm actionedit\"><i class=\"far fa-edit\"></i></div>&nbsp; -->\n                          <div (click)=\"DeleteNumber(data.phoneno, data.number_uuid)\" class=\"btn btn-danger btn-sm actiondelete\"><i class=\"fas fa-trash\"></i></div>\n                        </td>\n                        <!-- <td>-</td> -->\n                    </tr>\n                </tbody>\n                <tbody *ngIf=\"campaignpublisher?.length == 0\">\n                  <tr>\n                    <td colspan=\"2\" class=\"no-data-available\">No data Available!</td>\n                  </tr>\n                <tbody>\n              </table>\n            </section>\n            </fieldset>\n\n                  </div>\n                </div>\n                </div>\n              </div>\n\n              <div class=\"row\" [style.display]=\"filtertype == 2?'block':'none'\">\n                <div class=\"col-12 col-md-12 col-lg-12\">\n                  <div class=\"card\" >\n                    <div class=\"card-body\" >\n                      <div>\n                          <fieldset class=\"scheduler-border\">\n                              <legend class=\"scheduler-border\">You are participating in this Offer!</legend>\n                              <section class=\"p-2\">\n                                <div class=\"row mt-2\">\n                                  <div class=\"col-md-4\">\n                                    <div class=\"thumbnail text-center\"> <img width=\"130\" src=\"./assets/img/call-tracking.png\"> <div class=\"caption text-center mt-2\"> <p><strong class=\"font-14\">1. Add Offer Numbers</strong></p> <p class=\"font-12\">Add numbers to start sending calls to this Offer. You can add numbers up to the limit specified in the Offer number restrictions.</p> </div>\n                                    <br><input (click)=\"getType(1,1)\" type=\"button\" value=\"Add Numbers\" class=\"btn btn-primary font-13\" style=\"background-color: #3858e7;\">\n                                    </div>\n                                  </div>\n\n                                  <div class=\"col-md-4\">\n                                    <div class=\"thumbnail text-center\"> <img width=\"130\" src=\"./assets/img/payout.png\"> <div class=\"caption text-center mt-2\"> <p><strong class=\"font-14\">2. Review Offer Payout Details</strong></p> <p class=\"font-12\">Offer payout rules can be complex, review the payout details to ensure that you are maximizing your earnings!</p> </div> <br>\n                                    <input type=\"button\" (click)=\"getType(1,2)\" value=\"Review Payout Details\" class=\"btn btn-primary font-13\" style=\"background-color: #3858e7;\">\n                                    </div>\n                                  </div>\n\n                                  <div class=\"col-md-4\">\n                                    <div class=\"thumbnail text-center\"> <img width=\"130\" src=\"./assets/img/url-tracking.png\"> <div class=\"caption text-center mt-2\"> <p><strong class=\"font-14\">3. Review Offer Restrictions</strong></p> <p class=\"font-12\">Familiarize yourself with the rules and restrictions outlined in the Offer description and notes.</p> </div> <br>\n                                    <input type=\"button\" [scrollTo]=\"'#place1'\" [scrollDuration]=\"1000\" [scrollOffset]=\"-100\" value=\"Review Offer\" class=\"btn btn-primary font-13\" style=\"background-color: #3858e7;\">\n                                    </div>\n                                  </div>\n                              </div>\n                              </section>\n                          </fieldset>\n\n\n                          <div *ngIf=\"(offerdetails) || (isadded)\">\n                          <h6>Offer Details</h6>\n                          <hr style=\"background: green;\" class=\"mt-1\">\n\n                          <div class=\"row\">\n                            <div class=\"col-md-3 font-12\">Offer Title</div>\n                            <div class=\"col-md-3 font-12\">{{offerdetails ? offerdetails.name:null}}</div>\n                          </div>\n                          <div class=\"row mt-3\">\n                            <div class=\"col-md-3 font-12\">Description</div>\n                            <div class=\"col-md-3 font-12\">\n                              <div [innerHTML]=\"offerdetails ? offerdetails.description:null\"></div>\n                            </div>\n\n                          </div>\n                          <div class=\"row mt-3\">\n                            <div class=\"col-md-3 font-12\">Payout</div>\n                            <div class=\"col-md-3 font-12\">{{offerdetails ? offerdetails.payout:null}}</div>\n                          </div>\n                          <div class=\"row mt-3\">\n                            <div class=\"col-md-3 font-12\">Duration</div>\n                            <div class=\"col-md-3 font-12\">{{offerdetails ? offerdetails.duration:null}}</div>\n                          </div>\n                          <div class=\"row mt-3\">\n                            <div class=\"col-md-3 font-12\">Hours Of Operation</div>\n                            <div class=\"col-md-3 font-12\">{{offerdetails ? offerdetails.hoursofoperation:null}}</div>\n                          </div>\n                          <div class=\"row mt-3\">\n                            <div class=\"col-md-3 font-12\">Expiry Date</div>\n                            <div class=\"col-md-3 font-12\">{{offerdetails ? offerdetails.exp_date:null}}</div>\n                          </div>\n                          <div class=\"row mt-3\">\n                            <div class=\"col-md-3 font-12\">Require Approval</div>\n                            <div class=\"col-md-3 font-12\" *ngIf=\"offerdetails && offerdetails.req_approval==1\"><i class=\"fa fa-check\"></i></div>\n                            <div class=\"col-md-3 font-12\" *ngIf=\"offerdetails && offerdetails.req_approval==0\"><i class=\"fa fa-times\"></i></div>\n                          </div>\n                          <br>\n                          <strong class=\"font-15\">Publisher Number Limits</strong>\n                          <div class=\"row mt-3\">\n                            <div class=\"col-md-3 font-12\">Max Numbers Per Publisher</div>\n                            <div class=\"col-md-3 font-12\">{{offerdetails ? offerdetails.max_no_per_publisher:null}}</div>\n                          </div>\n                          <div class=\"row mt-3\">\n                            <div class=\"col-md-3 font-12\">Allow Toll-Free Number</div>\n                            <div class=\"col-md-3 font-12\" *ngIf=\"offerdetails && offerdetails.allow_tollfree_no==1\"><i class=\"fa fa-check\"></i></div>\n                            <div class=\"col-md-3 font-12\" *ngIf=\"offerdetails && offerdetails.allow_tollfree_no==0\"><i class=\"fa fa-times\"></i></div>\n                          </div>\n                          <div class=\"row mt-3 mb-4\">\n                            <div class=\"col-md-3 font-12\">Allow DID Numbers</div>\n                            <div class=\"col-md-3 font-12\" *ngIf=\"offerdetails && offerdetails.allow_did_no==1\"><i class=\"fa fa-check\"></i></div>\n                            <div class=\"col-md-3 font-12\" *ngIf=\"offerdetails && offerdetails.allow_did_no==0\"><i class=\"fa fa-times\"></i></div>\n                          </div>\n\n\n\n                          <button class=\"w-auto ml-2 btn btn-primary btn-sm\" (click)=\"offer_hide(2)\" style=\"border: 1px solid red!important\"><i class=\"fa fa-power-off\"></i> Leave Offer</button>\n\n                          <br>\n                          <br>\n\n                          </div>\n\n\n                      </div>\n\n\n\n\n                    </div>\n                  </div>\n                </div>\n              </div>\n\n              <div class=\"row\" [style.display]=\"filtertype == 3?'block':'none'\">\n                <div class=\"col-12 col-md-12 col-lg-12\">\n                <section>\n                  <div class=\"card\">\n                        <div class=\"card-header\">\n                          <h6><i class=\"material-icons\">show_chart</i> Performance Summary</h6>\n                      </div>\n\n                    <div class=\"card-body\">\n                      <div [chart]=\"chart\"></div>\n                      <hr>\n                      <div class=\"table-responsive\">\n                      <table #PerdataTable class=\"table table-striped dataTable no-footer row-border hover\" style=\"width: 100%;\">\n                        <thead>\n                          <tr>\n\n                             <th>-</th>\n                             <th>Incoming</th>\n                             <th>Not Connected</th>\n                             <th>Completed</th>\n                             <th>Converted</th>\n                             <th>No Answer</th>\n                             <th>Revenue</th>\n                             <th>Payout</th>\n                          </tr>\n                        </thead>\n                        <tbody *ngIf=\"labels?.length != 0\">\n                            <tr *ngFor=\"let data of labels;let i=index\">\n                                <!-- <th>-</th> -->\n                                <td style=\"width:10%\">{{data.date}}<br>{{data.day}}</td>\n                                <!-- <th>{{labels[1].date}}<br>{{labels[1].day}}</th>\n                                <th>{{labels[2].date}}<br>{{labels[2].day}}</th>\n                                <th>{{labels[3].date}}<br>{{labels[3].day}}</th>\n                                <th>{{labels[4].date}}<br>{{labels[4].day}}</th>\n                                <th>{{labels[5].date}}<br>{{labels[5].day}}</th>\n                                <th>{{labels[6].date}}<br>{{labels[6].day}}</th> -->\n\n                                <td>{{ data.incoming}}</td>\n                                <td>{{ data.connected}}</td>\n                                <td>{{ data.completed}}</td>\n                                <td>{{ data.converted}}</td>\n                                <td>{{ data.noanswer}}</td>\n                                <td style=\"width:13%\">{{ data.revenue}}</td>\n                                <td style=\"width:13%\">{{ data.payout }}</td>\n                            </tr>\n                        </tbody>\n                        <tbody *ngIf=\"labels?.length == 0\">\n                          <tr>\n                            <td colspan=\"15\" class=\"no-data-available\">No data Available!</td>\n                          </tr>\n                        <tbody>\n                      </table>\n                      </div>\n                    </div>\n                  </div>\n                </section>\n              </div>\n              </div>\n        </div>\n        </div>\n        </div>\n      </section>\n  </div>\n";

/***/ }),

/***/ 70517:
/*!***********************************************************************!*\
  !*** ./src/app/modules/campaigns/campaigns.component.html?ngResource ***!
  \***********************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n\n   <!-- offer details -->\n<div class=\"modal fade\" id=\"addpublisher\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\naria-hidden=\"true\">\n<div class=\"modal-dialog modal-lg\" role=\"document\">\n  <div class=\"modal-content\">\n    <div class=\"modal-header\">\n      <b class=\"modal-title\" id=\"formModal\">Offer Details</b>\n      <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n        <span aria-hidden=\"true\">&times;</span>\n      </button>\n    </div>\n    <div class=\"modal-body\">\n      <div class=\"row\">\n        <div class=\"col-md-3 font-12\">Offer Title</div>\n        <div class=\"col-md-3 font-12\">{{offerdetails ? offerdetails.name:null}}</div>\n      </div>\n      <div class=\"row mt-2\">\n        <div class=\"col-md-3 font-12\">Campaign Name</div>\n        <div class=\"col-md-3 font-12\">{{campaign ? campaign:null}}</div>\n      </div>\n      <div class=\"row mt-2\">\n        <div class=\"col-md-3 font-12\">Description</div>\n        <div class=\"col-md-3 font-12\">\n          <div [innerHTML]=\"offerdetails ? offerdetails.description:null\"></div>\n          </div>\n      </div>\n      <div class=\"row mt-2\">\n        <div class=\"col-md-3 font-12\">Payout</div>\n        <div class=\"col-md-3 font-12\">{{offerdetails ? offerdetails.payout:null}}</div>\n      </div>\n      <div class=\"row mt-2\">\n        <div class=\"col-md-3 font-12\">Duration</div>\n        <div class=\"col-md-3 font-12\">{{offerdetails ? offerdetails.duration:null}}</div>\n      </div>\n      <div class=\"row mt-2\">\n        <div class=\"col-md-3 font-12\">Hours Of Operation</div>\n        <div class=\"col-md-3 font-12\">{{offerdetails ? offerdetails.hoursofoperation:null}}</div>\n      </div>\n      <div class=\"row mt-2\">\n        <div class=\"col-md-3 font-12\">Expiry Date</div>\n        <div class=\"col-md-3 font-12\">{{offerdetails ? offerdetails.exp_date:null}}</div>\n      </div>\n      <div class=\"row mt-2\">\n        <div class=\"col-md-3 font-12\">Require Approval</div>\n        <div class=\"col-md-3 font-12\" *ngIf=\"offerdetails && offerdetails.req_approval==1\"><i class=\"fa fa-check\"></i></div>\n        <div class=\"col-md-3 font-12\" *ngIf=\"offerdetails && offerdetails.req_approval==0\"><i class=\"fa fa-times\"></i></div>\n      </div>\n      <br>\n      <strong class=\"font-15\">Publisher Number Limits</strong>\n      <div class=\"row mt-2\">\n        <div class=\"col-md-3 font-12\">Max Numbers Per Publisher</div>\n        <div class=\"col-md-3 font-12\">{{offerdetails ? offerdetails.max_no_per_publisher:null}}</div>\n      </div>\n      <div class=\"row mt-2\">\n        <div class=\"col-md-3 font-12\">Allow Toll-Free Number</div>\n        <div class=\"col-md-3 font-12\" *ngIf=\"offerdetails && offerdetails.allow_tollfree_no==1\"><i class=\"fa fa-check\"></i></div>\n        <div class=\"col-md-3 font-12\" *ngIf=\"offerdetails && offerdetails.allow_tollfree_no==0\"><i class=\"fa fa-times\"></i></div>\n      </div>\n      <div class=\"row mt-2\">\n        <div class=\"col-md-3 font-12\">Allow DID Numbers</div>\n        <div class=\"col-md-3 font-12\" *ngIf=\"offerdetails && offerdetails.allow_did_no==1\"><i class=\"fa fa-check\"></i></div>\n        <div class=\"col-md-3 font-12\" *ngIf=\"offerdetails && offerdetails.allow_did_no==0\"><i class=\"fa fa-times\"></i></div>\n      </div>\n      <br>\n\n      <div class=\"row mt-2\" *ngIf=\"!payoutdata && conf!='-'\">\n        <div class=\"col-md-3 font-12\">Offer Payouts</div>\n        <div class=\"col-md-5 font-12\"><span style=\"color: gray;\">1 | </span> {{conf}}</div>\n      </div>\n\n      <div *ngIf=\"payoutdata && payoutdata.length>0\">\n      <!-- <div class=\"row mt-2 mb-0 pb-0\">\n        <div class=\"col-md-12 font-16\">Real Time Bidding is not available for this Campaign.</div>\n      </div> -->\n      <hr style=\"background: #606060;\" class=\"mt-2\" >\n      <div class=\"row\" (click)=\"isofferpayout()\">\n        <div class=\"col-md-10 font-16\">Offer Payouts</div>\n        <div class=\"col-md-2 text-right pr-4 font-16\" ><i class=\"fa fa-angle-down\"></i></div>\n\n      </div>\n      <hr style=\"background: #606060;\" class=\"mt-1\">\n\n      <div style=\"border-left: 4px solid #3858e7 !important;left: 16px;background: #13161f;padding: 8px\" *ngIf=\"isoffer\">\n        <div class=\"row\" (click)=\"isrevsharepertg()\">\n          <div class=\"col-md-10 font-13\" *ngIf=\"payoutdata && payoutdata.length>0\"><span style=\"color: gray;\">1 | {{conf}}</span> </div>\n          <div class=\"col-md-10 font-13\" *ngIf=\"!payoutdata\"><span style=\"color: gray;\">1 | </span> Revshare Percentage</div>\n          <div class=\"col-md-2 text-right pr-4 font-13\" ><i class=\"fa fa-angle-down\"></i></div>\n        </div>\n        <div *ngIf=\"isrevshareper\">\n        <div class=\"row mt-2 mt-2 mb-0 pb-0\">\n          <div class=\"col-md-12 font-13\">Payout Setting</div>\n        </div>\n        <hr style=\"background: #606060;\" class=\"mt-2\">\n        <div class=\"row\">\n          <div class=\"col-md-2\"></div>\n          <div class=\"col-md-3 font-13 text-right\">Payout Type</div>\n          <div class=\"col-md-5 font-13\" >\n            <div class=\"control-group\">\n              <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                  <label class=\"btn btn-primary form-check-label font-10\" [ngClass]=\"{'active': payoutdata && payoutdata[0].payout_type==1}\" >\n                    <input class=\"form-check-input\" name=\"payout_typeedit\" type=\"radio\" id=\"option2\" [value]=\"1\" >\n                    None\n                  </label>\n                  <label class=\"btn btn-primary form-check-label font-10\" [ngClass]=\"{'active': payoutdata && payoutdata[0].payout_type==1}\" >\n                    <input class=\"form-check-input\" name=\"payout_typeedit\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                    Fixed Amount\n                  </label>\n                  <label class=\"btn btn-primary form-check-label font-10\" [ngClass]=\"{'active': payoutdata && payoutdata[0].payout_type==2}\" >\n                    <input class=\"form-check-input\" name=\"payout_typeedit\" type=\"radio\" id=\"option3\" [value]=\"2\">\n                    Revenue %\n                  </label>\n                </div>\n              </div>\n          </div>\n        </div> <br>\n        <div *ngIf=\"payoutdata && payoutdata[0].payout_type!=0\">\n        <div class=\"row control-group mt-2 mb-4\">\n           <div class=\"col-md-2\"></div>\n          <div class=\"col-md-3 font-13 text-right\">Payout Amount</div>\n          <div class=\"col-md-5 font-13\" >\n\n              <div class=\"input-group\">\n                <div class=\"input-group-prepend\">\n                  <div class=\"input-group-text\" id=\"btnGroupAddon\">$</div>\n                </div>\n                <input type=\"text\" class=\"form-control\" [disabled]=\"true\" [value]=\"payoutdata && payoutdata[0].payout_amount\" placeholder=\"Enter Payout Amount\" aria-label=\"Enter Payout Amount\" aria-describedby=\"btnGroupAddon\">\n              </div>\n            </div>\n        </div>\n\n        <div class=\"row control-group mt-2 mb-4\">\n           <div class=\"col-md-2\"></div>\n          <div class=\"col-md-3 font-13 text-right\">Payout Trigger</div>\n          <div class=\"col-md-5 font-13\" >\n            <select class=\"form-control\" formControlName=\"payout_trigger\" [value]=\"payoutdata && payoutdata[0].payout_trigger\" [disabled]=\"true\">\n              <option value=\"0\">Inbound Call</option>\n              <option value=\"1\">Call Length</option>\n              <option value=\"2\">Call Successfully Connected</option>\n            </select>\n          </div>\n        </div>\n        </div>\n\n        <div class=\"row control-group mt-2 mb-4\" *ngIf=\"payoutdata && payoutdata[0].payout_trigger==1\">\n           <div class=\"col-md-2\"></div>\n          <div class=\"col-md-3 font-13 text-right\">Enter Seconds</div>\n          <div class=\"col-md-5 font-13\" >\n            <input type=\"text\"  class=\"form-control\" type=\"text\" [disabled]=\"true\" [value]=\"payoutdata && payoutdata[0].payout_seconds\" placeholder=\"Enter Seconds\" />\n          </div>\n        </div>\n      </div>\n        <!-- <div class=\"row\">\n          <div class=\"col-md-2\"></div>\n          <div class=\"col-md-3 font-13 text-right\" >Duplicate Payouts <i class=\"fa fa-question-circle\" data-toggle=\"tooltip\" data-placement=\"right\" title=\"When enabled the publisher will be credited on duplicate or repeat calls. Disabling this option will prevent them from being paid multiple times. Time limits allow for duplicate payouts after a specific length of time.\"></i></div>\n          <div class=\"col-md-5 font-13\" >\n            <div class=\"control-group\">\n              <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                  <label class=\"btn btn-primary form-check-label font-10\" [ngClass]=\"{'active': editpayout_typeval==1}\" (click)=\"payout_typevaledit(1)\">\n                    <input class=\"form-check-input\" name=\"payout_typeedit\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                    Disable\n                  </label>\n                  <label class=\"btn btn-primary form-check-label font-10\" [ngClass]=\"{'active': editpayout_typeval==2}\" (click)=\"payout_typevaledit(2)\">\n                    <input class=\"form-check-input\" name=\"payout_typeedit\" type=\"radio\" id=\"option3\" [value]=\"2\">\n                    Enable\n                  </label>\n                  <label class=\"btn btn-primary form-check-label font-10\" [ngClass]=\"{'active': editpayout_typeval==2}\" (click)=\"payout_typevaledit(2)\">\n                    <input class=\"form-check-input\" name=\"payout_typeedit\" type=\"radio\" id=\"option3\" [value]=\"2\">\n                    Time Limit\n                  </label>\n                </div>\n\n              </div>\n          </div>\n        </div>\n        <div class=\"row\">\n          <div class=\"col-md-5\"></div>\n          <div class=\"col-md-2 font-13 d-flex\" >\n              <input type=\"number\" class=\"form-control appleinput\" >\n              <label for=\"\" class=\"mt-3\">Days</label>\n          </div>\n          <div class=\"col-md-2 font-13 d-flex\" >\n              <input type=\"number\" class=\"form-control appleinput\" >\n              <label for=\"\" class=\"mt-3\">Hours</label>\n          </div>\n        </div><br>\n        <div class=\"row\">\n          <div class=\"col-md-2\"></div>\n          <div class=\"col-md-3 font-13 text-right\" >Payout Hours <i class=\"fa fa-question-circle\" data-toggle=\"tooltip\" data-placement=\"right\" title=\"The hours of operation where your publisher should be credited for calls.\"></i></div>\n          <div class=\"col-md-3 font-13\" >\n            <div class=\"form-group\">\n              <label class=\"custom-switch pl-0\">\n                <input type=\"checkbox\" [checked]=\"isrecording==1\" (change)=\"get_recordingstatus($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                <span class=\"custom-switch-indicator\"></span>\n              </label>\n            </div>\n          </div>\n        </div><br>\n        <div class=\"row\">\n          <div class=\"col-md-2\"></div>\n          <div class=\"col-md-3 font-13 text-right\" >Limit Payout <i class=\"fa fa-question-circle\" data-toggle=\"tooltip\" data-placement=\"right\" title=\"Set caps to payouts based on calls, amount, and concurrency\"></i> </div>\n          <div class=\"col-md-3 font-13\">\n            <div class=\"form-group\">\n              <label class=\"custom-switch pl-0\">\n                <input type=\"checkbox\" [checked]=\"isrecording==1\" (change)=\"get_recordingstatus($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                <span class=\"custom-switch-indicator\"></span>\n              </label>\n            </div>\n          </div>\n        </div><br>\n        <div class=\"row mt-2 mt-2 mb-0 pb-0\">\n          <div class=\"col-md-12 font-13\">Tag Filters for Payout <i class=\"fa fa-question-circle\" data-toggle=\"tooltip\" data-placement=\"right\" title=\"Specify Tag Filters to give payout only if the call satisfies the filters.\"></i></div>\n        </div>\n        <hr style=\"background: #606060;\" class=\"mt-2\">\n        <p>No Tag Filters</p> -->\n\n        <input (click)=\"isrevsharepertg()\" type=\"button\" value=\"Close\" class=\"btn btn-primary btn-sm\">\n        </div>\n      </div>\n      <br>\n      <div class=\"row\">\n        <div class=\"col-md-12 d-flex\">\n          <input type=\"button\" *ngIf=\"offer_apply_status==0\" onclick=\"$('#addpublisher').modal('hide');\"  data-toggle=\"modal\" data-target=\"#offer_apply\" value=\"Apply\" class=\"w-auto btn btn-primary btn-sm\" style=\"background: #3858E7;\">\n          <input type=\"button\" *ngIf=\"offer_apply_status==0\" (click)=\"offer_hide(offerdetails ? offerdetails.campaign_uuid:null,1)\" value=\"Hide Offer\" class=\"w-auto ml-2 btn btn-primary btn-sm\">\n        </div>\n      </div>\n    </div>\n  </div>\n</div>\n</div>\n\n\n<!-- offer apply -->\n<div class=\"modal fade\" id=\"offer_apply\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\naria-hidden=\"true\">\n<div class=\"modal-dialog\" role=\"document\">\n  <div class=\"modal-content\">\n    <div class=\"modal-header\">\n      <b class=\"modal-title\" id=\"formModal\">Apply to join Offer: {{offerdetails ? offerdetails.name:null}}?</b>\n      <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n        <span aria-hidden=\"true\">&times;</span>\n      </button>\n    </div>\n    <div class=\"modal-body\">\n      <div class=\"row mt-2\">\n        <div class=\"col-md-12 font-12\">Describe why you decided to participate in the offer (optional)\n          <i class=\"fa fa-question-circle\" data-toggle=\"tooltip\" data-placement=\"right\" title=\"Your notes will be included into the notification to the offer administrator. This can be a good way to initiate a business conversation with an administrator or provide notes about your traffic. If the offer requires participation approval, make sure to provide enough information for the administrator to make a decision.\"></i></div>\n        <div class=\"col-md-12 mt-2 font-12\">\n          <input type=\"text\" class=\"form-control\"  [(ngModel)]=\"apply_message\"/>\n        </div>\n      </div><br>\n      <div class=\"row\">\n        <div class=\"col-md-12 d-flex\">\n          <input type=\"button\"  (click)=\"apply_offer()\" value=\"Apply\" class=\"w-auto btn btn-primary btn-sm\" style=\"background: #3858E7;\">\n          <input type=\"button\" class=\"close\" data-dismiss=\"modal\"  value=\"Cancel\" class=\"w-auto ml-2 btn btn-primary btn-sm\">\n        </div>\n      </div>\n    </div>\n  </div>\n</div>\n</div>\n\n\n  <div class=\"main-content\">\n    <section class=\"section\">\n      <div class=\"section-body\">\n        <div class=\"row\">\n          <div class=\"col-12\">\n            <div class=\"card\">\n                <div class=\"row\">\n                    <div class=\"col-3\">\n                        <div class=\"card-header\">\n                        <h4> Manage Campaigns</h4></div>\n                    </div>\n                    <div class=\"col-9 text-right mt-2\">\n                        <div class=\"form-group\"  style=\"margin-right: 28px;padding: 3px;font-size: 14px;\" *ngIf=\"currentUser.role!=3\">\n                          <a [routerLink]=\"['/campaign-wizard']\" routerLinkActive=\"router-link-active\"  class=\"btn btn-primary daterange-btn icon-left btn-sm btn-icon mr-2 p-2\"><i class=\"fa fa-plus\"></i> Create Campaign\n                          </a>\n                          <!-- <button [disabled]=\"ischecked === '1'\" (click)=\"onDeleteSubmit()\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-2\"><i class=\"fas fa-file-export\"></i> Delete Selected\n                          </button>                          -->\n\n                          </div>\n                    </div>\n\n                </div>\n\n              <div class=\"card-body\">\n                <!-- <ngx-ui-loader [loaderId]=\"loader.loaderId\"></ngx-ui-loader> -->\n                <ng-template #foregroundSpinner>\n                  <div class=\"sk-chase\">\n                    <div class=\"sk-chase-dot customLoaderId\"></div>\n                  </div>\n                </ng-template>\n                <ngx-ui-loader\n                  [loaderId]=\"loader.loaderId\"\n                  [fgsTemplate]=\"foregroundSpinner\"\n                ></ngx-ui-loader>\n\n                <div class=\"table-responsive\" >\n\n                <!-- <table #dataTable class=\"table table-striped dataTable no-footer row-border hover\" style=\"width: 100%;\"> -->\n                  <table *ngIf=\"currentUser.role!=3\" id=\"campaigntbl\" class=\"table table-striped dataTable no-footer row-border hover\" datatable [dtOptions]=\"dtOptions\" [dtTrigger]=\"dtTrigger\">\n\n                    <thead>\n                      <tr>\n                        <!-- <th style=\"padding: 10px;width: 1px;\">\n                            <div class=\"custom-control custom-checkbox\" *ngIf=\"numbers?.length != 0\">\n                            <input type=\"checkbox\" class=\"custom-control-input\" id=\"customCheck1\" (change)=\"checkalldelete($event)\" (click)=\"deleteselected($event)\">\n                            <label class=\"custom-control-label\" for=\"customCheck1\"></label>\n                            </div>\n                        </th> -->\n                        <th>Status</th>\n                        <th>Name</th>\n                        <th>Offer Name</th>\n                        <th>Country</th>\n                        <th>Hour</th>\n                        <th>Day</th>\n                        <th>Month</th>\n                        <th>Total</th>\n                        <th>Recording</th>\n                        <th>Created At</th>\n                        <th>Action</th>\n                      </tr>\n                    </thead>\n                    <tbody *ngIf=\"numbers?.length != 0\">\n                        <tr *ngFor=\"let number of numbers\">\n                              <!-- <td>\n                                <div class=\"custom-control custom-checkbox\">\n                                <input type=\"checkbox\" (click)=\"deleteselected($event)\" class=\"custom-control-input\" id=\"customCheck_{{number.uuid}}\"  [checked]=\"number.selected\" [value]=\"number.id\" >\n                                <label class=\"custom-control-label\" for=\"customCheck_{{number.uuid}}\"></label>\n                                </div>\n                            </td> -->\n                            <td *ngIf=\"currentUser.role!=3\">\n                              <div title=\"Accepting Calls\" *ngIf=\"number.status==1\" class=\"badge badge-success\">Live</div>\n                              <div title=\"Not Accepting Calls\" *ngIf=\"number.status==0\" class=\"badge badge-warning\">Paused</div>\n                            </td>\n                            <td *ngIf=\"currentUser.role==3\">\n                              <div *ngIf=\"number.offer_apply_status=='0'\" title=\"Apply to run offer\" data-toggle=\"modal\" data-target=\"#addpublisher\" class=\"btn btn-primary font-10 btn-sm text-white\" (click)=\"applyoffer(number.conf, number.payoutdata,number.offerdetails,number.name,number.offer_apply_status)\">Apply</div>\n                              <div *ngIf=\"number.offer_apply_status=='1'\" title=\"Application Pending\" class=\"btn btn-warning font-10 btn-sm text-white\">Pending</div>\n                              <div *ngIf=\"number.offer_apply_status=='2'\" title=\"Application Live\" class=\"btn btn-success font-10 btn-sm text-white\">Live</div>\n                              <div *ngIf=\"number.offer_apply_status=='3'\" title=\"Application Rejected\" class=\"btn btn-danger font-10 btn-sm text-white\">Rejected</div>\n                              <div *ngIf=\"number.offer_apply_status=='4'\" title=\"Application Live\" class=\"btn btn-success font-10 btn-sm text-white\">No Number</div>\n                            </td>\n                            <td *ngIf=\"currentUser.role!=3\" style=\"width: 100px;\"><a href=\"#\" routerLink=\"/edit-campaign/{{number.uuid}}\" routerLinkActive=\"router-link-active\"  class=\"text-white actionedit\">{{ number.name }}</a></td>\n                            <td *ngIf=\"currentUser.role==3\" style=\"width: 100px;\">{{ number.name }}</td>\n                            <td>{{ number.offername }}</td>\n                            <td>{{ number.country }}</td>\n                            <td *ngIf=\"currentUser.role!=3\">{{ number.byhour }}</td>\n                            <td *ngIf=\"currentUser.role!=3\">{{ number.byday }}</td>\n                            <td *ngIf=\"currentUser.role!=3\">{{ number.bymonth }}</td>\n                            <td *ngIf=\"currentUser.role!=3\">{{ number.total }}</td>\n\n                            <td>\n                              <div *ngIf=\"number.is_recording==1\" class=\"badge badge-success\">Yes</div>\n                              <div *ngIf=\"number.is_recording==0\" class=\"badge badge-danger\">No</div>\n                            </td>\n                            <td>{{ number.created_at }}</td>\n                            <td>\n                              <div *ngIf=\"currentUser.role!=3\" class=\"d-flex\" style=\"cursor:pointer;\">\n                              <a href=\"#\" routerLink=\"/edit-campaign/{{number.uuid}}\" routerLinkActive=\"router-link-active\"  class=\"actionedit\"><i class=\"far fa-edit\"></i></a>&nbsp;&nbsp;&nbsp;<div (click)=\"Delete((number.id))\" class=\"actiondelete\"><i class=\"fas fa-trash\"></i></div>&nbsp;&nbsp;\n                              <div title=\"Pause Campaign\" (click)=\"Status(number.id,1)\" *ngIf=\"number.status==0\" class=\"\"><i class=\"fa fa-pause\"></i></div>&nbsp;&nbsp;\n                              <div title=\"Pause Campaign\" (click)=\"Status(number.id,0)\" *ngIf=\"number.status==1\" class=\"\"><i class=\"fa fa-pause\"></i></div>\n                              </div>\n                              <div *ngIf=\"currentUser.role==3\" class=\"d-flex\" style=\"cursor:pointer;\">\n                                <div title=\"Hide Offer\" *ngIf=\"number.offer_apply_status==0\" (click)=\"offer_hide(number.uuid,1)\" class=\"\"><i class=\"fa fa-eye\"></i></div>&nbsp;&nbsp;\n                                <div title=\"View Details\" *ngIf=\"number.offer_apply_status==0 || number.offer_apply_status==1 || number.offer_apply_status==2\" data-toggle=\"modal\" data-target=\"#addpublisher\" (click)=\"applyoffer(number.conf, number.payoutdata, number.offerdetails,number.name,number.offer_apply_status)\" class=\"\"><i class=\"fa fa-list\"></i></div>\n\n                                <a *ngIf=\"number.offer_apply_status==4\" href=\"#\" routerLink=\"/view-campaign/{{number.uuid}}\" routerLinkActive=\"router-link-active\"  class=\" actionedit\"><i class=\"fa fa-list\"></i></a>\n\n                                <!-- <a href=\"#\" *ngIf=\"number.offer_apply_status=='4' || number.offer_apply_status=='2'\" routerLink=\"/view-campaign/{{number.uuid}}\" routerLinkActive=\"router-link-active\"  class=\"btn btn-primary btn-sm actionedit\"><i class=\"fa fa-list\"></i></a> -->\n                                <!-- <div *ngIf=\"number.offer_apply_status!='1' && number.offer_apply_status!=0\">-</div> -->\n                              </div>\n                            </td>\n                        </tr>\n                    </tbody>\n                    <tbody *ngIf=\"numbers?.length == 0\">\n                      <tr>\n                        <td colspan=\"11\" class=\"no-data-available\">No data Available!</td>\n                      </tr>\n                    <tbody>\n                  </table>\n\n                  <table *ngIf=\"currentUser.role==3\" id=\"campaigntbl\" class=\"table table-striped dataTable no-footer row-border hover\" datatable [dtOptions]=\"dtOptions\" [dtTrigger]=\"dtTrigger\">\n\n                    <thead>\n                      <tr>\n                        <!-- <th style=\"padding: 10px;width: 1px;\">\n                            <div class=\"custom-control custom-checkbox\" *ngIf=\"numbers?.length != 0\">\n                            <input type=\"checkbox\" class=\"custom-control-input\" id=\"customCheck1\" (change)=\"checkalldelete($event)\" (click)=\"deleteselected($event)\">\n                            <label class=\"custom-control-label\" for=\"customCheck1\"></label>\n                            </div>\n                        </th> -->\n                        <th>Status</th>\n                        <th>Name</th>\n                        <th>Offer Name</th>\n                        <th>Country</th>\n\n                        <th>Recording</th>\n                        <th>Created At</th>\n                        <th>Action</th>\n                      </tr>\n                    </thead>\n                    <tbody *ngIf=\"numbers?.length != 0\">\n                        <tr *ngFor=\"let number of numbers\">\n                              <!-- <td>\n                                <div class=\"custom-control custom-checkbox\">\n                                <input type=\"checkbox\" (click)=\"deleteselected($event)\" class=\"custom-control-input\" id=\"customCheck_{{number.uuid}}\"  [checked]=\"number.selected\" [value]=\"number.id\" >\n                                <label class=\"custom-control-label\" for=\"customCheck_{{number.uuid}}\"></label>\n                                </div>\n                            </td> -->\n                            <td *ngIf=\"currentUser.role!=3\">\n                              <div title=\"Accepting Calls\" *ngIf=\"number.status==1\" class=\"badge badge-success\">Live</div>\n                              <div title=\"Not Accepting Calls\" *ngIf=\"number.status==0\" class=\"badge badge-warning\">Paused</div>\n                            </td>\n                            <td *ngIf=\"currentUser.role==3\">\n                              <div *ngIf=\"number.offer_apply_status=='0'\" title=\"Apply to run offer\" data-toggle=\"modal\" data-target=\"#addpublisher\" class=\"btn btn-primary font-10 btn-sm text-white\" (click)=\"applyoffer(number.conf, number.payoutdata,number.offerdetails,number.name,number.offer_apply_status)\">Apply</div>\n                              <div *ngIf=\"number.offer_apply_status=='1'\" title=\"Application Pending\" class=\"btn btn-warning font-10 btn-sm text-white\">Pending</div>\n                              <div *ngIf=\"number.offer_apply_status=='2'\" title=\"Application Live\" class=\"btn btn-success font-10 btn-sm text-white\">Live</div>\n                              <div *ngIf=\"number.offer_apply_status=='3'\" title=\"Application Rejected\" class=\"btn btn-danger font-10 btn-sm text-white\">Rejected</div>\n                              <div *ngIf=\"number.offer_apply_status=='4'\" title=\"Application Live\" class=\"btn btn-success font-10 btn-sm text-white\">No Number</div>\n                            </td>\n                            <td *ngIf=\"currentUser.role!=3\" style=\"width: 100px;\"><a href=\"#\" routerLink=\"/edit-campaign/{{number.uuid}}\" routerLinkActive=\"router-link-active\"  class=\"text-white actionedit\">{{ number.name }}</a></td>\n                            <td *ngIf=\"currentUser.role==3\" style=\"width: 100px;\">{{ number.name }}</td>\n                            <td>{{ number.offername }}</td>\n                            <td>{{ number.country }}</td>\n                            <td *ngIf=\"currentUser.role!=3\">{{ number.byhour }}</td>\n                            <td *ngIf=\"currentUser.role!=3\">{{ number.byday }}</td>\n                            <td *ngIf=\"currentUser.role!=3\">{{ number.bymonth }}</td>\n                            <td *ngIf=\"currentUser.role!=3\">{{ number.total }}</td>\n\n                            <td>\n                              <div *ngIf=\"number.is_recording==1\" class=\"badge badge-success\">Yes</div>\n                              <div *ngIf=\"number.is_recording==0\" class=\"badge badge-danger\">No</div>\n                            </td>\n                            <td>{{ number.created_at }}</td>\n                            <td>\n                              <div *ngIf=\"currentUser.role!=3\" class=\"d-flex\" style=\"cursor:pointer;\">\n                              <a href=\"#\" routerLink=\"/edit-campaign/{{number.uuid}}\" routerLinkActive=\"router-link-active\"  class=\"actionedit\"><i class=\"far fa-edit\"></i></a>&nbsp;&nbsp;&nbsp;<div (click)=\"Delete((number.id))\" class=\"actiondelete\"><i class=\"fas fa-trash\"></i></div>&nbsp;&nbsp;\n                              <div title=\"Pause Campaign\" (click)=\"Status(number.id,1)\" *ngIf=\"number.status==0\" class=\"\"><i class=\"fa fa-pause\"></i></div>&nbsp;&nbsp;\n                              <div title=\"Pause Campaign\" (click)=\"Status(number.id,0)\" *ngIf=\"number.status==1\" class=\"\"><i class=\"fa fa-pause\"></i></div>\n                              </div>\n                              <div *ngIf=\"currentUser.role==3\" class=\"d-flex\" style=\"cursor:pointer;\">\n                                <div title=\"Hide Offer\" *ngIf=\"number.offer_apply_status==0\" (click)=\"offer_hide(number.uuid,1)\" class=\"\"><i class=\"fa fa-eye\"></i></div>&nbsp;&nbsp;\n                                <div title=\"View Details\" *ngIf=\"number.offer_apply_status==0 || number.offer_apply_status==1 || number.offer_apply_status==2\" data-toggle=\"modal\" data-target=\"#addpublisher\" (click)=\"applyoffer(number.conf, number.payoutdata, number.offerdetails,number.name,number.offer_apply_status)\" class=\"\"><i class=\"fa fa-list\"></i></div>\n\n                                <a *ngIf=\"number.offer_apply_status==4\" href=\"#\" routerLink=\"/view-campaign/{{number.uuid}}\" routerLinkActive=\"router-link-active\"  class=\" actionedit\"><i class=\"fa fa-list\"></i></a>\n\n                                <!-- <a href=\"#\" *ngIf=\"number.offer_apply_status=='4' || number.offer_apply_status=='2'\" routerLink=\"/view-campaign/{{number.uuid}}\" routerLinkActive=\"router-link-active\"  class=\"btn btn-primary btn-sm actionedit\"><i class=\"fa fa-list\"></i></a> -->\n                                <!-- <div *ngIf=\"number.offer_apply_status!='1' && number.offer_apply_status!=0\">-</div> -->\n                              </div>\n                            </td>\n                        </tr>\n                    </tbody>\n                    <tbody *ngIf=\"numbers?.length == 0\">\n                      <tr>\n                        <td colspan=\"11\" class=\"no-data-available\">No data Available!</td>\n                      </tr>\n                    <tbody>\n                  </table>\n                </div>\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n    </section>\n\n  </div>\n";

/***/ }),

/***/ 23635:
/*!***********************************************************************!*\
  !*** ./src/app/modules/changelog/changelog.component.html?ngResource ***!
  \***********************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n\n  <div class=\"main-content\">\n    <section class=\"section\">\n      <div class=\"section-body\">\n        <div class=\"row\">\n          <div class=\"col-12\">\n            <div class=\"card\">\n                <div class=\"row\">\n                    <div class=\"col-3\">\n                        <div class=\"card-header\">\n                        <h4>Change Logs</h4></div>\n                    </div>\n                    <div class=\"col-9 text-right mt-2\">\n                        <div class=\"form-group\"  style=\"margin-right: 28px;padding: 3px;font-size: 14px;\">\n                          <!-- <button routerLink=\"/add-target\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-1\"><i class=\"fa fa-plus\"></i> New Target\n                          </button>\n                          <button [disabled]=\"ischecked === '1'\" (click)=\"onDeleteSubmit()\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-2\"><i class=\"fas fa-file-export\"></i> Delete Selected\n                          </button>                          -->\n\n                          </div>\n                    </div>\n\n                </div>\n\n              <div class=\"card-body\">\n                <div class=\"table-responsive\">\n                <table #dataTable class=\"table table-striped dataTable no-footer row-border hover\" style=\"width: 100%;\">\n                    <thead>\n                      <tr>\n                        <!-- <th style=\"padding: 10px;width: 1px;\">\n                            <div class=\"custom-control custom-checkbox\" *ngIf=\"numbers?.length != 0\">\n                            <input type=\"checkbox\" class=\"custom-control-input\" id=\"customCheck1\" (change)=\"checkalldelete($event)\" (click)=\"deleteselected($event)\">\n                            <label class=\"custom-control-label\" for=\"customCheck1\"></label>\n                            </div>\n                        </th> -->\n                        <th>User</th>\n                        <th>Module Name</th>\n                        <th>Operation Type</th>\n                        <th>Description</th>\n                        <th>Log Date</th>\n                        <!-- <th>Action</th>                     -->\n                      </tr>\n                    </thead>\n                    <tbody *ngIf=\"numbers?.length != 0\">\n                        <tr *ngFor=\"let data of numbers\">\n                            <!-- <td>\n                                <div class=\"custom-control custom-checkbox\">\n                                <input type=\"checkbox\" (click)=\"deleteselected($event)\" class=\"custom-control-input\" id=\"customCheck_{{data.uuid}}\"  [checked]=\"data.selected\" [value]=\"data.id\" >\n                                <label class=\"custom-control-label\" for=\"customCheck_{{data.uuid}}\"></label>\n                                </div>\n                            </td> -->\n                            <td>{{ data.user }}</td>\n                            <td>{{ data.modulename }}</td>\n                            <td>{{ data.operation_type }}</td>\n                            <td>{{ data.description_string }}</td>\n                            <td>{{ data.created_at }}</td>\n                            <!-- <td><a routerLink=\"/edit-numbers/{{ data.uuid }}\" class=\"btn btn-primary btn-sm actionedit\"><i class=\"far fa-edit\"></i></a>&nbsp;<button (click)=\"Delete((data.uuid))\" class=\"btn btn-danger btn-sm actiondelete\"><i class=\"fas fa-trash\"></i></button></td> -->\n                        </tr>\n                    </tbody>\n                    <tbody *ngIf=\"numbers?.length == 0\">\n                      <tr>\n                        <td colspan=\"9\" class=\"no-data-available\">No data Available!</td>\n                      </tr>\n                    <tbody>\n                  </table>\n                </div>\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n    </section>\n\n  </div>\n";

/***/ }),

/***/ 19250:
/*!***********************************************************************!*\
  !*** ./src/app/modules/dashboard/dashboard.component.html?ngResource ***!
  \***********************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n  \n<div class=\"main-content pt-0\">\n    <!-- <section class=\"section\">\n      <div class=\"row \">\n        <div class=\"col-xl-3 col-lg-6\">\n          <div class=\"card l-bg-green-dark\">\n            <div class=\"card-statistic-3\">\n              <div class=\"card-icon card-icon-large\"><i class=\"fa fa-phone\"></i></div>\n              <div class=\"card-content\">\n                <h6 class=\"mb-0\">Today's Call</h6>\n                <span class=\"font-weight-bold mb-0 font-20\">{{NumberOfCalls}}</span>               \n              </div>\n            </div>\n          </div>\n          \n        </div>\n\n        <div class=\"col-xl-3 col-lg-6\">\n          <div class=\"card l-bg-orange-dark\">\n            <div class=\"card-statistic-3\">\n              <div class=\"card-icon card-icon-large\"><i class=\"fa fa-envelope\"></i></div>\n              <div class=\"card-content\">\n                <h6 class=\"mb-0\">Successful Calls</h6>\n                <span class=\"font-weight-bold mb-0 font-20\">{{NumberOfSMS}}</span>               \n              </div>\n            </div>\n          </div>\n        </div>\n\n        <div class=\"col-xl-3 col-lg-6\">\n          <div class=\"card l-bg-cyan-dark\">\n            <div class=\"card-statistic-3\">\n              <div class=\"card-icon card-icon-large\"><i class=\"fa fa-user\"></i></div>\n              <div class=\"card-content\">\n                <h6 class=\"mb-0\">Total IVR</h6>\n                <span class=\"font-weight-bold mb-0 font-20\">{{NumberOfIVR}}</span>\n              </div>\n            </div>\n          </div>\n        </div>\n        <div class=\"col-xl-3 col-lg-6\">\n          <div class=\"card l-bg-purple-dark\">\n            <div class=\"card-statistic-3\">\n              <div class=\"card-icon card-icon-large\"><i class=\"fa fa-phone\"></i></div>\n              <div class=\"card-content\">\n                <h6 class=\"mb-0\">Total Numbers</h6>\n                <span class=\"font-weight-bold mb-0 font-20\">{{NumberOfNumbers}}</span>              \n              </div>\n            </div>\n          </div>\n        </div>\n        \n      </div>\n           \n    </section> -->\n\n    <div class=\"row pt-0 mt-0\">\n      <div class=\"col-md-8 pt-2\">\n        <section>\n          <div class=\"card\">\n                <div class=\"card-header\">\n                  <h6><i class=\"material-icons\">show_chart</i> Performance Summary</h6>\n                <!-- <div class=\"col-md-4 text-right\" style=\"display: -webkit-inline-box;left: 48px;\">\n                  <label for=\"\">Select Date: &nbsp;&nbsp;</label>\n                  <input style=\"width: auto;\" type=\"text\" class=\"form-control\" ngxDaterangepickerMd\n                  [singleDatePicker]=\"true\" (change)=\"getChartNumberOfCalls($event)\"\n                  [autoApply]=\"true\" \n                   class=\"form-control\"\n                  placeholder=\"Select please...\" [value]=\"currentDate | date:'MM/dd/yyyy'\" />\n                </div> -->\n              </div>\n              \n            <div class=\"card-body\">\n              <div [chart]=\"chart\"></div>\n              <!-- <hr> -->\n              <div class=\"table-responsive\">\n              <table #dataTable class=\"table table-striped dataTable no-footer row-border hover\" style=\"width: 100%;\">\n                <thead>\n                  <tr>\n                 \n                     <th>-</th>\n                     <th>Incoming</th>\n                     <th>Not Connected</th>\n                     <th>Completed</th>\n                     <th>Converted</th>\n                     <th>No Answer</th>\n                     <th>Revenue</th>\n                     <th>Payout</th>\n                  </tr>\n                </thead>\n                <tbody *ngIf=\"labels?.length != 0\">\n                    <tr *ngFor=\"let data of labels;let i=index\">\n                        <!-- <th>-</th> -->\n                        <td style=\"width:10%\">{{data.date}}<br>{{data.day}}</td>\n                        <!-- <th>{{labels[1].date}}<br>{{labels[1].day}}</th>\n                        <th>{{labels[2].date}}<br>{{labels[2].day}}</th>\n                        <th>{{labels[3].date}}<br>{{labels[3].day}}</th>\n                        <th>{{labels[4].date}}<br>{{labels[4].day}}</th>\n                        <th>{{labels[5].date}}<br>{{labels[5].day}}</th>\n                        <th>{{labels[6].date}}<br>{{labels[6].day}}</th> -->\n    \n                        <td>{{ data.incoming}}</td>\n                        <td>{{ data.connected}}</td>\n                        <td>{{ data.completed}}</td>\n                        <td>{{ data.converted}}</td>\n                        <td>{{ data.noanswer}}</td>\n                        <td style=\"width:13%\">{{ data.revenue}}</td>\n                        <td style=\"width:13%\">{{ data.payout }}</td>                    \n                    </tr>\n                </tbody>\n                <tbody *ngIf=\"labels?.length == 0\">\n                  <tr>\n                    <td colspan=\"15\" class=\"no-data-available\">No data Available!</td>\n                  </tr>\n                <tbody>\n              </table>\n              </div>\n            </div>\n          </div>      \n        </section>\n        <div style=\"background: #111319;\n        padding: 11px;\n        color: white;\">\n          <h6>Top Performers</h6>\n        </div>\n        <div class=\"input-group\" style=\"background: #111319;\">\n          <button id=\"tabs1\" style=\"width: 33.33%;height: 41px;\" (click)=\"getParticipationType(0)\" class=\"camactivetab camtabsbtn\">Publishers</button>\n          <button id=\"tabs2\" style=\"width: 33.33%;height: 41px;\" (click)=\"getParticipationType(1)\" class=\"camtabsbtn\">Targets</button>\n          <button style=\"width: 33.33%;height: 41px;\" id=\"tabs3\" (click)=\"getParticipationType(2)\" class=\"camtabsbtn\">Campaigns </button>                                \n        </div>\n\n        <div class=\"row\" [style.display]=\"pfiltertype == 0?'block':'none'\" >\n          <div class=\"col-12 col-md-12 col-lg-12\">                        \n              <div style=\"position: relative\">\n                <!-- <ngx-ui-loader [loaderId]=\"'loader-01'\"></ngx-ui-loader> -->\n                <ng-template #foregroundSpinner>\n                  <div class=\"sk-chase\">\n                    <div class=\"sk-chase-dot customLoaderId\"></div>\n                  </div>\n                </ng-template>                \n                <ngx-ui-loader\n                  [loaderId]=\"loader.loaderId\"\n                  [fgsTemplate]=\"foregroundSpinner\"\n                  [bgsTemplate]=\"backgroundSpinner\"\n                  [fgsSize]=\"loader.fgsSize\"\n                  [bgsSize]=\"loader.bgsSize\"\n                  [text]=\"loader.text\"\n                  [gap]=\"loader.gap\"\n                ></ngx-ui-loader>\n                <div class=\"table-responsive\" >\n                  <!-- #dataTable_top [dtOptions]=\"dtOptionsTop\" [dtTrigger]=\"dtTrigger\" -->\n                  <table class=\"table table-striped dataTable no-footer row-border hover\"  id=\"dt\" >\n\n                    <thead>\n                      <tr>\n                        <th>Name</th>\n                        <th>Hour</th>\n                        <th>Calls</th>           \n                        <th>Revenue</th>           \n                        <th>Payout</th>           \n                        <th>Profit</th>           \n                        <th>Actions</th>           \n                      </tr>\n                    </thead>\n                    <tbody *ngIf=\"top_performer?.length != 0\">\n                          <tr *ngFor=\"let data of top_performer;let i = index;\" style=\"cursor:pointer\" class=\"detailrow_{{i}}\">\n                              <td><a style=\"font-size: 12px;\" placement=\"bottom\" ngbTooltip=\"Edit Publisher\" routerLink=\"/publishers\" class=\"actionedit\">{{data.filter}}</a></td>\n                              <td>{{data.hour}}</td>\n                              <td>{{data.incoming}}</td>\n                              <td>${{data.revenue}}</td>\n                              <td>${{data.payout}}</td>\n                              <td>${{data.profit}}</td>\n                              <td>\n                                <a style=\"font-size: 12px;\" placement=\"bottom\" ngbTooltip=\"Edit Publisher\" routerLink=\"/publishers\" class=\"actionedit\"><i class=\"far fa-edit\"></i></a>\n                                <a style=\"font-size: 12px;\" placement=\"bottom\" ngbTooltip=\"View Report\" routerLink=\"/reports\" [queryParams]=\"{filteradvanced: 0, filtertype:4,filterlabel:'Publisher', 'containfiltertype':0, containfiltertext:'Equals Single Value',uuid:data.uuid, name:data.filter}\" class=\"ml-2 actionedit\"><i class=\"fa fa-chart-pie\"></i></a>\n                              </td>\n                          </tr>\n                      </tbody>\n                      <tbody *ngIf=\"top_performer?.length == 0\">\n                          <tr>\n                          <td colspan=\"7\" class=\"no-data-available\">No data Available!</td>\n                          </tr>\n                      <tbody>\n                  </table>\n                </div>\n              </div>\n            \n            </div>              \n        </div>  \n        \n        <div class=\"row\" [style.display]=\"pfiltertype == 1?'block':'none'\" >\n          <div class=\"col-12 col-md-12 col-lg-12\">                        \n              <div style=\"position: relative\">\n                <!-- <ngx-ui-loader [loaderId]=\"'loader-02'\"></ngx-ui-loader> -->\n                <ng-template #foregroundSpinner>\n                  <div class=\"sk-chase\">\n                    <div class=\"sk-chase-dot customLoaderId\"></div>\n                  </div>\n                </ng-template>                \n                <ngx-ui-loader\n                  [loaderId]=\"loader.loaderId1\"\n                  [fgsTemplate]=\"foregroundSpinner\"\n                  [bgsTemplate]=\"backgroundSpinner\"\n                  [fgsSize]=\"loader.fgsSize\"\n                  [bgsSize]=\"loader.bgsSize\"\n                  [text]=\"loader.text\"\n                  [gap]=\"loader.gap\"\n                ></ngx-ui-loader>\n                <div class=\"table-responsive\" >\n                  <!-- #dataTable_top [dtOptions]=\"dtOptions_top\" [dtTrigger]=\"dtTrigger\" -->\n                  <table class=\"table table-striped dataTable no-footer row-border hover\"  id=\"dt\">\n\n                    <thead>\n                      <tr>\n                        <th>Name</th>\n                        <th>Hour</th>\n                        <th>Calls</th>           \n                        <th>Revenue</th>           \n                        <th>Payout</th>           \n                        <th>Profit</th>           \n                        <th>Actions</th>           \n                      </tr>\n                    </thead>\n                    <tbody *ngIf=\"top_target?.length != 0\">\n                          <tr *ngFor=\"let data of top_target;let i = index;\" style=\"cursor:pointer\" class=\"detailrow_{{i}}\">\n                              <td><a style=\"font-size: 12px;\" placement=\"bottom\" ngbTooltip=\"Edit Target\" routerLink=\"/edit-numbers/{{data.uuid}}\" class=\"actionedit\">{{data.filter}}</a></td>\n                              <td>{{data.hour}}</td>\n                              <td>{{data.incoming}}</td>\n                              <td>${{data.revenue}}</td>\n                              <td>${{data.payout}}</td>\n                              <td>${{data.profit}}</td>\n                              <td>\n                                <a style=\"font-size: 12px;\" placement=\"bottom\" ngbTooltip=\"Edit Target\" routerLink=\"/edit-numbers/{{data.uuid}}\" class=\"actionedit\"><i class=\"far fa-edit\"></i></a>\n                                <a style=\"font-size: 12px;\" placement=\"bottom\" ngbTooltip=\"View Report\" routerLink=\"/reports\" [queryParams]=\"{filteradvanced: 0, filtertype:2,filterlabel:'Target', 'containfiltertype':0, containfiltertext:'Equals Single Value',uuid:data.uuid, name:data.filter}\" class=\"ml-2 actionedit\"><i class=\"fa fa-chart-pie\"></i></a>\n                              </td>\n                          </tr>\n                      </tbody>\n                      <tbody *ngIf=\"top_target?.length == 0\">\n                          <tr>\n                          <td colspan=\"7\" class=\"no-data-available\">No data Available!</td>\n                          </tr>\n                      <tbody>\n                  </table>\n                </div>\n              </div>\n            \n            </div>              \n        </div>  \n      \n        <div class=\"row\" [style.display]=\"pfiltertype == 2?'block':'none'\" >\n          <div class=\"col-12 col-md-12 col-lg-12\">                        \n              <div style=\"position: relative\">\n                <!-- <ngx-ui-loader [loaderId]=\"'loader-03'\"></ngx-ui-loader> -->\n                <ng-template #foregroundSpinner>\n                  <div class=\"sk-chase\">\n                    <div class=\"sk-chase-dot customLoaderId\"></div>\n                  </div>\n                </ng-template>                \n                <ngx-ui-loader\n                  [loaderId]=\"loader.loaderId2\"\n                  [fgsTemplate]=\"foregroundSpinner\"\n                  [bgsTemplate]=\"backgroundSpinner\"\n                  [fgsSize]=\"loader.fgsSize\"\n                  [bgsSize]=\"loader.bgsSize\"\n                  [text]=\"loader.text\"\n                  [gap]=\"loader.gap\"\n                ></ngx-ui-loader>\n                <div class=\"table-responsive\" >\n                  <!-- #dataTable_top [dtOptions]=\"dtOptions_top\" [dtTrigger]=\"dtTrigger\" -->\n                  <table class=\"table table-striped dataTable no-footer row-border hover\"  id=\"dt\" >\n\n                    <thead>\n                      <tr>\n                        <th>Name</th>\n                        <th>Hour</th>\n                        <th>Calls</th>           \n                        <th>Revenue</th>           \n                        <th>Payout</th>           \n                        <th>Profit</th>           \n                        <th>Actions</th>           \n                      </tr>\n                    </thead>\n                    <tbody *ngIf=\"top_campaign?.length != 0\">\n                          <tr *ngFor=\"let data of top_campaign;let i = index;\" style=\"cursor:pointer\" class=\"detailrow_{{i}}\">\n                              <td><a style=\"font-size: 12px;\" placement=\"bottom\" ngbTooltip=\"Edit Campaign\" routerLink=\"/edit-campaign/{{data.uuid}}\" class=\"actionedit\">{{data.filter}}</a></td>\n                              <td>{{data.hour}}</td>\n                              <td>{{data.incoming}}</td>\n                              <td>${{data.revenue}}</td>\n                              <td>${{data.payout}}</td>\n                              <td>${{data.profit}}</td>\n                              <td>\n                                <a style=\"font-size: 12px;\" placement=\"bottom\" ngbTooltip=\"Edit Campaign\" routerLink=\"/edit-campaign/{{data.uuid}}\" class=\"actionedit\"><i class=\"far fa-edit\"></i></a>\n                                <a style=\"font-size: 12px;\" placement=\"bottom\" ngbTooltip=\"View Report\" routerLink=\"/reports\" [queryParams]=\"{filteradvanced: 0, filtertype:1,filterlabel:'Campaign', 'containfiltertype':0, containfiltertext:'Equals Single Value',uuid:data.uuid, name:data.filter}\" class=\"ml-2 actionedit\"><i class=\"fa fa-chart-pie\"></i></a>\n                              </td>\n                          </tr>\n                      </tbody>\n                      <tbody *ngIf=\"top_campaign?.length == 0\">\n                          <tr>\n                          <td colspan=\"7\" class=\"no-data-available\">No data Available!</td>\n                          </tr>\n                      <tbody>\n                  </table>\n                </div>\n              </div>\n            \n            </div>              \n        </div>  \n\n\n      </div>\n\n      <div class=\"col-md-4 ml-0 pl-0 pt-2\">\n        <section>\n          <div class=\"card\">\n            <div class=\"card-header\">\n                <h6><span class=\"fa fa-dot-circle text-white mr-2\"></span> Monthly Static Targets</h6>               \n            </div>\n              \n            <div class=\"card-body pt-0\">\n              <div class=\"table-responsive\">\n                <table #datatable_target class=\"table table-striped dataTable no-footer row-border hover\" style=\"width: 100%;\">\n                    <thead>\n                      <tr>\n                        <th>Name</th>\n                        <th>Hour</th>\n                        <th>Active</th>\n                        <th>Action</th>\n                      </tr>\n                    </thead>\n                    <tbody *ngIf=\"numbers?.length != 0\">\n                        <tr *ngFor=\"let number of numbers;let i = index;\" class=\"detailrow_{{i}}\">\n                            <td><a routerLink=\"/edit-numbers/{{ number.uuid }}\" class=\"text-white\">{{ number.name }}</a></td>\n                            <td>{{ number.hour}} <span style=\"color: #5b5d66;\" *ngIf=\"number.hourly_revenuecapvalue!=0\">/ {{number.hourly_revenuecapvalue}}</span></td>\n                            <td>\n                              <span *ngIf=\"number.active_status==1\"><i class=\"fa fa-solid fa-circle text-success\"></i></span>                             \n                              <span *ngIf=\"number.active_status==0\"><i class=\"fa fa-solid fa-circle text-danger\"></i></span>                                                           \n                            </td>\n                            <td style=\"cursor:pointer;\" >\n                              <a style=\"font-size: 12px;\" placement=\"bottom\" ngbTooltip=\"Edit Target\" routerLink=\"/edit-numbers/{{ number.uuid }}\" class=\"actionedit\"><i class=\"far fa-edit\"></i></a>\n                              <a style=\"font-size: 12px;\" placement=\"bottom\" ngbTooltip=\"View Report\" routerLink=\"/reports\" [queryParams]=\"{filteradvanced: 0, filtertype:2,filterlabel:'Target', 'containfiltertype':0, containfiltertext:'Equals Single Value',uuid:number.uuid, name:number.name}\" class=\"ml-2 actionedit\"><i class=\"fa fa-chart-pie\"></i></a>\n                            </td>                            \n                        </tr>\n                    </tbody>\n                    <tbody *ngIf=\"numbers?.length == 0\">\n                      <tr>\n                        <td colspan=\"4\" class=\"no-data-available\">No data Available!</td>\n                      </tr>\n                    <tbody>\n                  </table>\n                </div>\n            </div>\n          </div>      \n        </section>\n      </div>\n    </div>\n\n\n    \n  </div>\n  ";

/***/ }),

/***/ 67145:
/*!***************************************************************************************!*\
  !*** ./src/app/modules/dynamic-parameter/dynamic-parameter.component.html?ngResource ***!
  \***************************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n<div class=\"main-content\">\n        <section class=\"section\">\n          <div class=\"section-body\">\n            <div class=\"row\">\n              <div class=\"col-12 col-md-12 col-lg-12\">\n                <form [formGroup]=\"addparaForm\" (ngSubmit)=\"onSubmit()\">\n                <div class=\"card\">\n                  <div class=\"card-header\">\n                    <h4>Dynamic Forwarding Parameters</h4>\n                  </div>\n                  <div class=\"card-body\">                    \n                    <div class=\"form-group\">\n                      <label>XYZ Call Time Span</label>\n                      <input type=\"text\" formControlName=\"xyzcalltimespan\" class=\"form-control\" >\n                      </div>\n\n                    <div class=\"form-group\">\n                            <label>Default Rule</label>\n                            <input type=\"text\" formControlName=\"default_rule\" class=\"form-control\">\n                    </div>\n\n                    <div class=\"form-group\">\n                            <label>ABC Rule Expiration</label>\n                            <input type=\"text\" formControlName=\"abc_rule_expiration\" class=\"form-control\">\n                    </div>\n\n                    <div class=\"form-group\">\n                            <label>Shortlist Release Period</label>\n                            <input type=\"text\" formControlName=\"sho_rel_period\" class=\"form-control\">\n                    </div>\n                    <div class=\"form-group\">\n                            <label>Longlist Release Period</label>\n                            <input type=\"text\" formControlName=\"long_rel_period\" class=\"form-control\">\n                    </div>\n                    <div class=\"form-group\">\n                            <label>Shortlist Call Time Window</label>\n                            <input type=\"text\" formControlName=\"short_call_time_win\" class=\"form-control\">\n                    </div>\n                    <div class=\"form-group\">\n                            <label>Call Threshold</label>\n                            <input type=\"text\" formControlName=\"call_threshold\" class=\"form-control\">\n                    </div>\n                  </div>\n                  <div class=\"card-footer text-right\">\n                     <button  class=\"btn btn-primary mr-1\" type=\"submit\"><i class=\"fa fa-save\"></i> Save Parameters</button>\n                 </div>\n                </div>\n              </form>\n \n    </div>\n \n ";

/***/ }),

/***/ 58632:
/*!*************************************************************************************!*\
  !*** ./src/app/modules/ivr-menus/add-ivrmenu/add-ivrmenu.component.html?ngResource ***!
  \*************************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n<div class=\"main-content\">\n       <div class=\"section\">\n         <div class=\"section-body\">\n           <div class=\"row\">\n             <div class=\"col-12 col-md-12 col-lg-12\">\n               <form method=\"post\" [formGroup]=\"addIVRMenuForm\" (ngSubmit)=\"onSubmit()\">\n               <div class=\"card\">\n                 <div class=\"card-header\">\n                   <h4>Create New IVR Menu</h4>\n                 </div>\n                 <div class=\"card-body\">                    \n                   <div class=\"form-group\">\n                     <label>Name</label>\n                     <div class=\"input-group\">\n                       <input formControlName=\"name\" id=\"name\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': submitted && f.name.errors }\"> \n                       <div *ngIf=\"submitted && f.name.errors\" class=\"invalid-feedback\">\n                           <div *ngIf=\"f.name.errors.required\">Name is required</div>          \n                       </div>                      \n                       </div>  \n                   </div>\n\n                   <div class=\"form-group\">\n                      <label>Number Of Retries</label>\n                      <div class=\"input-group\">\n                        <input formControlName=\"noofretries\" id=\"noofretries\" type=\"number\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': submitted && f.noofretries.errors }\" min=\"0\"> \n                        <div *ngIf=\"submitted && f.noofretries.errors\" class=\"invalid-feedback\">\n                            <div *ngIf=\"f.noofretries.errors.required\">Number Of Retries is required</div>                            \n                        </div>                      \n                        </div>  \n                    </div>                    \n\n                  <div class=\"form-group\">\n                    <label>Timeout</label>\n                    <div class=\"input-group\">\n                      <input formControlName=\"timeout\" id=\"timeout\" type=\"number\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': submitted && f.timeout.errors }\" min=\"0\"> \n                      <div *ngIf=\"submitted && f.timeout.errors\" class=\"invalid-feedback\">\n                          <div *ngIf=\"f.timeout.errors.required\">Timeout is required</div>    \n                      </div>                      \n                      </div>  \n                  </div>\n                  \n                  <div class=\"form-group\">\n                      <label>How many options in the IVR (1-9)</label>\n                      <select  formControlName=\"ivr_options\" class=\"form-control\" (change)=\"IVR_Options($event)\">\n                        <option value=\"0\">0</option>\n                        <option value=\"1\">1</option>\n                        <option value=\"2\">2</option>\n                        <option value=\"3\">3</option>\n                        <option value=\"4\">4</option>\n                        <option value=\"5\">5</option>\n                        <option value=\"6\">6</option>\n                        <option value=\"7\">7</option>\n                        <option value=\"8\">8</option>\n                        <option value=\"9\">9</option>\n                      </select>\n                  </div>\n                 \n                    <div class=\"form-group\" *ngIf=\"selectedIVR_Options!=''\">\n                      <label>Default response if no response by caller</label>\n                      <select formControlName=\"default_response\" class=\"form-control\" >\n                        <option disabled>Select default option for no response</option>\n                        <option *ngFor=\"let in of selectedIVR();let i = index\" [value]=\"in+1\">\n                           {{in+1}}\n                          </option>                  \n                      </select>\n                    </div>\n                 \n                    <div class=\"form-group\">\n                      <label>Buyer</label>\n                      <!-- <select formControlName=\"buyer\" class=\"form-control\" value=\"''\">\n                        <option value=\"\" selected>Select Buyer</option>\n                        <option *ngFor=\"let buyers of allBuyers;\" [value]=\"buyers.id\">\n                            {{buyers.text}}\n                          </option> -->\n                      <!-- </select> -->\n                      <angular2-multiselect [data]=\"allBuyers\" formControlName=\"buyer\" [settings]=\"settings\"></angular2-multiselect>       \n                    </div>\n\n                    <table style=\"font-size: 13px;\" class=\"table table-striped dataTable no-footer\">\n                      <thead>\n                          <tr>\n                              <th></th>\n                              <th>Link to File</th>\n                              <th>Select Audio</th>\n                              <th>Upload <br>Audio File</th>\n                              <th>Forward to Number or IVR Menu</th>\n                          </tr>\n                      </thead>\n                      <tbody>\n                          <tr style=\"background: #fff;\">\n                              <td>Opening Menu Recording</td>\n                              <td>\n                                  <audio *ngIf=\"url_0!==''\" style=\"width: 147px;\" controls>\n                                    <source src=\"{{url_0}}\" type=\"audio/mp3\">\n                                  </audio> \n                                   <!-- {{url_0}} -->\n                                  <!-- <mat-basic-audio-player *ngIf=\"url_0!==''\" [audioUrl]=\"url_0\"></mat-basic-audio-player> -->\n                                                               \n                              </td>\n                              <td>\n                                  <select class=\"form-control\" name='audio_uuid_0' formControlName=\"audio_uuid_0\" (change)=\"audiochange($event,0)\">\n                                    <option value=\"\" selected=\"\">No audio file</option>\n                                    <option *ngFor=\"let aud of audio;\" [value]=\"aud.uuid\">\n                                        {{aud.original_filename}}\n                                    </option>\n                                  </select>\n                              </td>\n                              <td>\n                                <div class=\"qq-upload-button-selector btn btn-primary pull-left\" style=\"position: relative; overflow: hidden; direction: ltr;font-size: 12px;width: 39px;\">\n                                  <div><i class=\"fa fa-upload\"></i></div>\n                                  <input (change)=\"selectFile($event,0)\" formControlName=\"upload_audio_0\" title=\"file input\"  type=\"file\" style=\"position: absolute; right: 0px; top: 0px; font-family: Arial; font-size: 118px; margin: 0px; padding: 0px; cursor: pointer; opacity: 0; height: 100%;\">\n                                </div><br><br>                            \n                              </td>\n                              <td>\n                                  <div class=\"row\">\n                                      <div class=\"col-md-6\">\n                                        <select formControlName=\"forward_to_0\" class=\"form-control\" (change)=\"forward_to($event,0)\" [value]=\"'FORWARD_TO_NUMBER'\">\n                                          <option value=\"CONTINUE\">Continue</option>\n                                            <option value=\"FORWARD_TO_NUMBER\">Forward to Phone Number</option>\n                                          </select>\n                                      </div>\n                                      <div class=\"col-md-6\" *ngIf=\"forward_0 == 'FORWARD_TO_NUMBER'\">\n                                        <input formControlName=\"forwardto_phone_0\" placeholder=\"(000) 000-000\" class=\"form-control\" id=\"forwardto_phone_0\" (keypress)=_keyPress($event) maxlength=\"14\">\n                                      </div>\n                                  </div>\n                              </td>\n                              </tr>\n                          \n                              <tr style=\"background: #fff;\">\n                              <td>#</td>\n                              <td>\n                                  <audio *ngIf=\"url_1!==''\" style=\"width: 147px;\" controls>\n                                    <source src=\"{{url_1}}\" type=\"audio/mp3\">\n                                  </audio>                                 \n                              </td>\n                              <td>\n                                  <select class=\"form-control\" name='audio_uuid_1' formControlName=\"audio_uuid_1\" (change)=\"audiochange($event,1)\">\n                                    <option value=\"\" selected=\"\">No audio file</option>\n                                    <option *ngFor=\"let aud of audio;\" [value]=\"aud.uuid\">\n                                        {{aud.original_filename}}\n                                    </option>\n                                  </select>\n                              </td>\n                              <td>\n                                <div class=\"qq-upload-button-selector btn btn-primary pull-left\" style=\"position: relative; overflow: hidden; direction: ltr;font-size: 12px;width: 39px;\">\n                                  <div><i class=\"fa fa-upload\"></i></div>\n                                  <input (change)=\"selectFile($event,1)\" formControlName=\"upload_audio_1\" title=\"file input\"  type=\"file\" style=\"position: absolute; right: 0px; top: 0px; font-family: Arial; font-size: 118px; margin: 0px; padding: 0px; cursor: pointer; opacity: 0; height: 100%;\">\n                                </div><br><br>                            \n                              </td>\n                              <td>\n                                  <div class=\"row\">\n                                      <div class=\"col-md-6\">\n                                        <select formControlName=\"forward_to_1\" class=\"form-control\" (change)=\"forward_to($event,1)\" [value]=\"'FORWARD_TO_NUMBER'\">\n                                          <option value=\"CONTINUE\">Continue</option>\n                                            <option value=\"FORWARD_TO_NUMBER\">Forward to Phone Number</option>\n                                          </select>\n                                      </div>\n                                      <div class=\"col-md-6\" *ngIf=\"forward_1 == 'FORWARD_TO_NUMBER'\">\n                                        <input formControlName=\"forwardto_phone_1\" placeholder=\"(000) 000-000\" class=\"form-control\" id=\"forwardto_phone_1\" (keypress)=_keyPress($event) maxlength=\"14\">\n                                      </div>\n                                  </div>\n                              </td>\n                              </tr>\n\n                              <tr *ngFor=\"let i of selectedIVR();\" style=\"background: #fff;\">\n                                      <td>Press {{i+1}} Recording</td>\n                                      <td>\n                                          <!-- <div *ngIf=\"url_1!=='' && i+1==1\">\n                                            <audio style=\"width: 147px;\" controls>\n                                              <source src=\"{{url_1}}\" type=\"audio/mp3\">\n                                            </audio>\n                                          </div> -->\n                                          <div *ngIf=\"url_2!=='' && i+2==2\">\n                                              <audio style=\"width: 147px;\" controls>\n                                                <source src=\"{{url_2}}\" type=\"audio/mp3\">\n                                              </audio>\n                                          </div>\n                                          <div *ngIf=\"url_3!=='' && i+2==3\">\n                                              <audio style=\"width: 147px;\" controls>\n                                                <source src=\"{{url_3}}\" type=\"audio/mp3\">\n                                              </audio>\n                                          </div>\n                                          <div *ngIf=\"url_4!=='' && i+2==4\">\n                                              <audio style=\"width: 147px;\" controls>\n                                                <source src=\"{{url_4}}\" type=\"audio/mp3\">\n                                              </audio>\n                                          </div>\n                                          <div *ngIf=\"url_5!=='' && i+2==5\">\n                                              <audio style=\"width: 147px;\" controls>\n                                                <source src=\"{{url_5}}\" type=\"audio/mp3\">\n                                              </audio>\n                                          </div>\n                                          <div *ngIf=\"url_6!=='' && i+2==6\">\n                                              <audio style=\"width: 147px;\" controls>\n                                                <source src=\"{{url_6}}\" type=\"audio/mp3\">\n                                              </audio>\n                                          </div>\n                                          <div *ngIf=\"url_7!=='' && i+2==7\">\n                                              <audio style=\"width: 147px;\" controls>\n                                                <source src=\"{{url_7}}\" type=\"audio/mp3\">\n                                              </audio>\n                                          </div>\n                                          <div *ngIf=\"url_8!=='' && i+2==8\">\n                                              <audio style=\"width: 147px;\" controls>\n                                                <source src=\"{{url_8}}\" type=\"audio/mp3\">\n                                              </audio>\n                                          </div>\n                                          <div *ngIf=\"url_9!=='' && i+2==9\">\n                                              <audio style=\"width: 147px;\" controls>\n                                                <source src=\"{{url_9}}\" type=\"audio/mp3\">\n                                              </audio>\n                                          </div>\n                                          <div *ngIf=\"url_10!=='' && i+2==10\">\n                                              <audio style=\"width: 147px;\" controls>\n                                                <source src=\"{{url_10}}\" type=\"audio/mp3\">\n                                              </audio>\n                                          </div>\n                                      </td>\n                                      <td>\n                                      <select class=\"form-control\" formControlName=\"audio_uuid_{{i+2}}\" (change)=\"audiochange($event,i+2)\">\n                                        <option value=\"\" selected=\"\">No audio file</option>\n                                        <option *ngFor=\"let aud of audio;\" [value]=\"aud.uuid\">\n                                            {{aud.original_filename}}\n                                        </option>\n                                      </select>\n                                    </td>\n                                    <td>\n                                    <div>\n                                        <div class=\"btn btn-primary pull-left\" style=\"position: relative; overflow: hidden; direction: ltr;font-size: 12px;width: 39px;\">\n                                        <div><i class=\"fa fa-upload\"></i></div>\n                                        <input (change)=\"selectFile($event,i+2)\" formControlName=\"upload_audio_{{i+2}}\" title=\"file input\" type=\"file\"  style=\"position: absolute; right: 0px; top: 0px; font-family: Arial; font-size: 118px; margin: 0px; padding: 0px; cursor: pointer; opacity: 0; height: 100%;\">\n                                        </div>                     \n                                    </div>\n                                    </td>\n                                    <td>\n                                        <div class=\"row\">\n                                            <div class=\"col-md-6\">\n                                                <select formControlName=\"forward_to_{{i+2}}\" class=\"form-control\" (change)=\"forward_to($event,i+2)\" [value]=\"'FORWARD_TO_NUMBER'\">\n                                                  <option value=\"FORWARD_TO_IVR\">Forward to IVR</option>\n                                                  <option value=\"FORWARD_TO_ROUTING\">Forward to Targets</option>\n                                                  <option value=\"FORWARD_TO_IVRROUTING\">Forward to IVR Routing</option>\n                                                  <option value=\"FORWARD_TO_NUMBER\">Forward to Phone Number</option>\n                                                  <!-- <option *ngFor=\"let name of menuname;\" [value]=\"name.id\">\n                                                      {{name.name}}\n                                                  </option> -->\n                                                </select>\n                                            </div>                                     \n\n                                            <div class=\"col-md-6\" >\n                                                <div *ngIf=\"i==0 && forward_2 == 'FORWARD_TO_NUMBER'\">\n                                                  <input id=\"forwardto_phone_2\" formControlName=\"forwardto_phone_2\" placeholder=\"(000) 000-000\" class=\"form-control\" (keypress)=_keyPress($event) maxlength=\"14\">\n                                                </div>\n                                                <div *ngIf=\"i==1 && forward_3 == 'FORWARD_TO_NUMBER'\">\n                                                    <input formControlName=\"forwardto_phone_3\" id=\"forwardto_phone_3\" placeholder=\"(000) 000-000\" class=\"form-control\" (keypress)=_keyPress($event) maxlength=\"14\">\n                                                </div>\n                                                <div *ngIf=\"i==2 && forward_4 == 'FORWARD_TO_NUMBER'\">\n                                                    <input id=\"forwardto_phone_4\" formControlName=\"forwardto_phone_4\" placeholder=\"(000) 000-000\" class=\"form-control\" (keypress)=_keyPress($event) maxlength=\"14\">\n                                                </div>\n                                                <div *ngIf=\"i==3 && forward_5 == 'FORWARD_TO_NUMBER'\">\n                                                    <input id=\"forwardto_phone_5\" formControlName=\"forwardto_phone_5\" placeholder=\"(000) 000-000\" class=\"form-control\" (keypress)=_keyPress($event) maxlength=\"14\">\n                                                </div>\n                                                <div *ngIf=\"i==4 && forward_6 == 'FORWARD_TO_NUMBER'\">\n                                                    <input id=\"forwardto_phone_6\" formControlName=\"forwardto_phone_6\" placeholder=\"(000) 000-000\" class=\"form-control\" (keypress)=_keyPress($event) maxlength=\"14\">\n                                                </div>\n                                                <div *ngIf=\"i==5 && forward_7 == 'FORWARD_TO_NUMBER'\">\n                                                    <input id=\"forwardto_phone_7\" formControlName=\"forwardto_phone_7\" placeholder=\"(000) 000-000\" class=\"form-control\" (keypress)=_keyPress($event) maxlength=\"14\">\n                                                </div>\n                                                <div *ngIf=\"i==6 && forward_8 == 'FORWARD_TO_NUMBER'\">\n                                                    <input id=\"forwardto_phone_8\" formControlName=\"forwardto_phone_8\" placeholder=\"(000) 000-000\" class=\"form-control\" (keypress)=_keyPress($event) maxlength=\"14\">\n                                                </div>\n                                                <div *ngIf=\"i==7 && forward_9 == 'FORWARD_TO_NUMBER'\">\n                                                    <input id=\"forwardto_phone_9\" formControlName=\"forwardto_phone_9\" placeholder=\"(000) 000-000\" class=\"form-control\" (keypress)=_keyPress($event) maxlength=\"14\">\n                                                </div>\n                                                <div *ngIf=\"i==8 && forward_10 == 'FORWARD_TO_NUMBER'\">\n                                                    <input id=\"forwardto_phone_10\" formControlName=\"forwardto_phone_10\" placeholder=\"(000) 000-000\" class=\"form-control\" (keypress)=_keyPress($event) maxlength=\"14\">\n                                                </div>  \n                                                \n<!--                                                 \n                                                <div *ngIf=\"i==0 && forward_2 == 'FORWARD_TO_IVR'\">\n                                                  <select formControlName=\"forwardto_ivr_2\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Menu</option>\n                                                    <option *ngFor=\"let name of menuname;\" [value]=\"name.id\">\n                                                        {{name.name}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==1 && forward_3 == 'FORWARD_TO_IVR'\">\n                                                  <select formControlName=\"forwardto_ivr_3\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Menu</option>\n                                                    <option *ngFor=\"let name of menuname;\" [value]=\"name.id\">\n                                                        {{name.name}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==2 && forward_4 == 'FORWARD_TO_IVR'\">\n                                                  <select formControlName=\"forwardto_ivr_4\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Menu</option>\n                                                    <option *ngFor=\"let name of menuname;\" [value]=\"name.id\">\n                                                        {{name.name}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==3 && forward_5 == 'FORWARD_TO_IVR'\">\n                                                  <select formControlName=\"forwardto_ivr_5\" class=\"form-control\" >\n                                                    <option value=\"\">Select IVR Menu</option>\n                                                    <option *ngFor=\"let name of menuname;\" [value]=\"name.id\">\n                                                        {{name.name}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==4 && forward_6 == 'FORWARD_TO_IVR'\">\n                                                  <select formControlName=\"forwardto_ivr_6\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Menu</option>\n                                                    <option *ngFor=\"let name of menuname;\" [value]=\"name.id\">\n                                                        {{name.name}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==5 && forward_7 == 'FORWARD_TO_IVR'\">\n                                                  <select formControlName=\"forwardto_ivr_7\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Menu</option>\n                                                    <option *ngFor=\"let name of menuname;\" [value]=\"name.id\">\n                                                        {{name.name}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==6 && forward_8 == 'FORWARD_TO_IVR'\">\n                                                  <select formControlName=\"forwardto_ivr_8\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Menu</option>\n                                                    <option *ngFor=\"let name of menuname;\" [value]=\"name.id\">\n                                                        {{name.name}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==7 && forward_9 == 'FORWARD_TO_IVR'\">\n                                                  <select formControlName=\"forwardto_ivr_9\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Menu</option>\n                                                    <option *ngFor=\"let name of menuname;\" [value]=\"name.id\">\n                                                        {{name.name}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==8 && forward_10 == 'FORWARD_TO_IVR'\">\n                                                  <select formControlName=\"forwardto_ivr_10\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Menu</option>\n                                                    <option *ngFor=\"let name of menuname;\" [value]=\"name.id\">\n                                                        {{name.name}}\n                                                    </option>\n                                                  </select>\n                                                </div>                                                  -->\n\n\n                                                <div *ngIf=\"i==0 && forward_2 == 'FORWARD_TO_IVR'\">\n                                                  <!-- <select formControlName=\"forwardto_ivr_2\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Menu</option>\n                                                    <option *ngFor=\"let name of menuname;\" [value]=\"name.id\">\n                                                        {{name.name}}\n                                                    </option>\n                                                  </select> -->\n                                                  <angular2-multiselect [data]=\"menuname\" [(ngModel)]=\"forwardto_ivr_2\" formControlName=\"forwardto_ivr_2\" [settings]=\n                                                  \"{\n                                                    enableSearchFilter: true,\n                                                    showCheckbox:false,\n                                                    singleSelection: true, text:'Select IVR'}\"></angular2-multiselect> \n                                                    <a *ngIf=\"forwardto_ivr_2\" target=\"_blank\" routerLink=\"/edit-ivr/{{forwardto_ivr_2[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Edit</a>\n                                                </div>\n                                                <div *ngIf=\"i==1 && forward_3 == 'FORWARD_TO_IVR'\">\n                                                  <!-- <select formControlName=\"forwardto_ivr_3\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Menu</option>\n                                                    <option *ngFor=\"let name of menuname;\" [value]=\"name.id\">\n                                                        {{name.name}}\n                                                    </option>\n                                                  </select> -->\n                                                  <angular2-multiselect [data]=\"menuname\" [(ngModel)]=\"forwardto_ivr_3\" formControlName=\"forwardto_ivr_3\" [settings]=\n                                                  \"{\n                                                    enableSearchFilter: true,\n                                                    showCheckbox:false,\n                                                    singleSelection: true, text:'Select IVR'}\"></angular2-multiselect> \n                                                    <a *ngIf=\"forwardto_ivr_3\" target=\"_blank\" routerLink=\"/edit-ivr/{{forwardto_ivr_3[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Edit</a>\n                                                </div>\n                                                <div *ngIf=\"i==2 && forward_4 == 'FORWARD_TO_IVR'\">\n                                                  <!-- <select formControlName=\"forwardto_ivr_4\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Menu</option>\n                                                    <option *ngFor=\"let name of menuname;\" [value]=\"name.id\">\n                                                        {{name.name}}\n                                                    </option>\n                                                  </select> -->\n                                                  <angular2-multiselect [data]=\"menuname\" [(ngModel)]=\"forwardto_ivr_4\" formControlName=\"forwardto_ivr_4\" [settings]=\n                                                  \"{\n                                                    enableSearchFilter: true,\n                                                    showCheckbox:false,\n                                                    singleSelection: true, text:'Select IVR'}\"></angular2-multiselect>\n                                                    <a *ngIf=\"forwardto_ivr_4\" target=\"_blank\" routerLink=\"/edit-ivr/{{forwardto_ivr_4[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Edit</a> \n                                                </div>\n                                                <div *ngIf=\"i==3 && forward_5 == 'FORWARD_TO_IVR'\">\n                                                  <!-- <select formControlName=\"forwardto_ivr_5\" class=\"form-control\" >\n                                                    <option value=\"\">Select IVR Menu</option>\n                                                    <option *ngFor=\"let name of menuname;\" [value]=\"name.id\">\n                                                        {{name.name}}\n                                                    </option>\n                                                  </select> -->\n                                                  <angular2-multiselect [data]=\"menuname\" [(ngModel)]=\"forwardto_ivr_5\" formControlName=\"forwardto_ivr_5\" [settings]=\n                                                  \"{\n                                                    enableSearchFilter: true,\n                                                    showCheckbox:false,\n                                                    singleSelection: true, text:'Select IVR'}\"></angular2-multiselect> \n                                                    <a *ngIf=\"forwardto_ivr_5\" target=\"_blank\" routerLink=\"/edit-ivr/{{forwardto_ivr_5[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Edit</a>\n                                                </div>\n                                                <div *ngIf=\"i==4 && forward_6 == 'FORWARD_TO_IVR'\">\n                                                  <!-- <select formControlName=\"forwardto_ivr_6\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Menu</option>\n                                                    <option *ngFor=\"let name of menuname;\" [value]=\"name.id\">\n                                                        {{name.name}}\n                                                    </option>\n                                                  </select> -->\n                                                  <angular2-multiselect [data]=\"menuname\" [(ngModel)]=\"forwardto_ivr_6\" formControlName=\"forwardto_ivr_6\" [settings]=\n                                                  \"{\n                                                    enableSearchFilter: true,\n                                                    showCheckbox:false,\n                                                    singleSelection: true, text:'Select IVR'}\"></angular2-multiselect> \n                                                    <a *ngIf=\"forwardto_ivr_6\" target=\"_blank\" routerLink=\"/edit-ivr/{{forwardto_ivr_6[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Edit</a>\n                                                </div>\n                                                <div *ngIf=\"i==5 && forward_7 == 'FORWARD_TO_IVR'\">\n                                                  <!-- <select formControlName=\"forwardto_ivr_7\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Menu</option>\n                                                    <option *ngFor=\"let name of menuname;\" [value]=\"name.id\">\n                                                        {{name.name}}\n                                                    </option>\n                                                  </select> -->\n                                                  <angular2-multiselect [data]=\"menuname\" [(ngModel)]=\"forwardto_ivr_7\" formControlName=\"forwardto_ivr_7\" [settings]=\n                                                  \"{\n                                                    enableSearchFilter: true,\n                                                    showCheckbox:false,\n                                                    singleSelection: true, text:'Select IVR'}\"></angular2-multiselect> \n                                                    <a *ngIf=\"forwardto_ivr_7\" target=\"_blank\" routerLink=\"/edit-ivr/{{forwardto_ivr_7[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Edit</a>\n                                                </div>\n                                                <div *ngIf=\"i==6 && forward_8 == 'FORWARD_TO_IVR'\">\n                                                  <!-- <select formControlName=\"forwardto_ivr_8\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Menu</option>\n                                                    <option *ngFor=\"let name of menuname;\" [value]=\"name.id\">\n                                                        {{name.name}}\n                                                    </option>\n                                                  </select> -->\n                                                  <angular2-multiselect [data]=\"menuname\" [(ngModel)]=\"forwardto_ivr_8\" formControlName=\"forwardto_ivr_8\" [settings]=\n                                                  \"{\n                                                    enableSearchFilter: true,\n                                                    showCheckbox:false,\n                                                    singleSelection: true, text:'Select IVR'}\"></angular2-multiselect> \n                                                    <a *ngIf=\"forwardto_ivr_8\" target=\"_blank\" routerLink=\"/edit-ivr/{{forwardto_ivr_8[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Edit</a>\n                                                </div>\n                                                <div *ngIf=\"i==7 && forward_9 == 'FORWARD_TO_IVR'\">\n                                                  <!-- <select formControlName=\"forwardto_ivr_9\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Menu</option>\n                                                    <option *ngFor=\"let name of menuname;\" [value]=\"name.id\">\n                                                        {{name.name}}\n                                                    </option>\n                                                  </select> -->\n                                                  <angular2-multiselect [data]=\"menuname\" [(ngModel)]=\"forwardto_ivr_9\" formControlName=\"forwardto_ivr_9\" [settings]=\n                                                  \"{\n                                                    enableSearchFilter: true,\n                                                    showCheckbox:false,\n                                                    singleSelection: true, text:'Select IVR'}\"></angular2-multiselect> \n                                                    <a *ngIf=\"forwardto_ivr_9\" target=\"_blank\" routerLink=\"/edit-ivr/{{forwardto_ivr_9[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Edit</a>\n                                                </div>\n                                                <div *ngIf=\"i==8 && forward_10 == 'FORWARD_TO_IVR'\">\n                                                  <!-- <select formControlName=\"forwardto_ivr_10\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Menu</option>\n                                                    <option *ngFor=\"let name of menuname;\" [value]=\"name.id\">\n                                                        {{name.name}}\n                                                    </option>\n                                                  </select> -->\n                                                  <angular2-multiselect [data]=\"menuname\" [(ngModel)]=\"forwardto_ivr_10\" formControlName=\"forwardto_ivr_10\" [settings]=\n                                                  \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select IVR'}\">\n                                                  </angular2-multiselect> \n                                                  <a *ngIf=\"forwardto_ivr_10\" target=\"_blank\" routerLink=\"/edit-ivr/{{forwardto_ivr_10[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Edit</a>\n                                                </div>   \n\n  \n                                                <!-- <div *ngIf=\"i==0 && forward_2 == 'FORWARD_TO_ROUTING'\">\n                                                  <select formControlName=\"forwardto_routing_2\" class=\"form-control\">\n                                                    <option value=\"\">Select Targets</option>\n                                                    <option *ngFor=\"let name of alltarget;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==1 && forward_3 == 'FORWARD_TO_ROUTING'\">\n                                                  <select formControlName=\"forwardto_routing_3\" class=\"form-control\">\n                                                    <option value=\"\">Select Targets</option>\n                                                    <option *ngFor=\"let name of alltarget;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==2 && forward_4 == 'FORWARD_TO_ROUTING'\">\n                                                  <select formControlName=\"forwardto_routing_4\" class=\"form-control\">\n                                                    <option value=\"\">Select Targets</option>\n                                                    <option *ngFor=\"let name of alltarget;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==3 && forward_5 == 'FORWARD_TO_ROUTING'\">\n                                                  <select formControlName=\"forwardto_routing_5\" class=\"form-control\" >\n                                                    <option value=\"\">Select Targets</option>\n                                                    <option *ngFor=\"let name of alltarget;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==4 && forward_6 == 'FORWARD_TO_ROUTING'\">\n                                                  <select formControlName=\"forwardto_routing_6\" class=\"form-control\">\n                                                    <option value=\"\">Select Targets</option>\n                                                    <option *ngFor=\"let name of alltarget;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==5 && forward_7 == 'FORWARD_TO_ROUTING'\">\n                                                  <select formControlName=\"forwardto_routing_7\" class=\"form-control\">\n                                                    <option value=\"\">Select Targets</option>\n                                                    <option *ngFor=\"let name of alltarget;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==6 && forward_8 == 'FORWARD_TO_ROUTING'\">\n                                                  <select formControlName=\"forwardto_routing_8\" class=\"form-control\">\n                                                    <option value=\"\">Select Targets</option>\n                                                    <option *ngFor=\"let name of alltarget;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==7 && forward_9 == 'FORWARD_TO_ROUTING'\">\n                                                  <select formControlName=\"forwardto_routing_9\" class=\"form-control\">\n                                                    <option value=\"\">Select Targets</option>\n                                                    <option *ngFor=\"let name of alltarget;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==8 && forward_10 == 'FORWARD_TO_ROUTING'\">\n                                                  <select formControlName=\"forwardto_routing_10\" class=\"form-control\">\n                                                    <option value=\"\">Select Targets</option>\n                                                    <option *ngFor=\"let name of alltarget;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select>\n                                                </div>    -->\n\n                                                <div *ngIf=\"i==0 && forward_2 == 'FORWARD_TO_ROUTING'\">\n                                                  <!-- <select formControlName=\"forwardto_routing_2\" class=\"form-control\">\n                                                    <option value=\"\">Select Targets</option>\n                                                    <option *ngFor=\"let name of alltarget;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select> -->\n                                                  <angular2-multiselect [data]=\"alltarget\" [(ngModel)]=\"forwardto_routing_2\" formControlName=\"forwardto_routing_2\" [settings]=\n                                                  \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select Target'}\">\n                                                  </angular2-multiselect> \n                                                  <a *ngIf=\"forwardto_routing_2\" target=\"_blank\" routerLink=\"/edit-numbers/{{forwardto_routing_2[0].uuid}}\" style=\"color: #3abaf4;\">Go To Target Edit</a>\n                                                </div>\n                                                <div *ngIf=\"i==1 && forward_3 == 'FORWARD_TO_ROUTING'\">\n                                                  <!-- <select formControlName=\"forwardto_routing_3\" class=\"form-control\">\n                                                    <option value=\"\">Select Targets</option>\n                                                    <option *ngFor=\"let name of alltarget;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select> -->\n                                                  <angular2-multiselect [data]=\"alltarget\" [(ngModel)]=\"forwardto_routing_3\" formControlName=\"forwardto_routing_3\" [settings]=\n                                                  \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select Target'}\">\n                                                  </angular2-multiselect> \n                                                  <a *ngIf=\"forwardto_routing_3\" target=\"_blank\" routerLink=\"/edit-numbers/{{forwardto_routing_3[0].uuid}}\" style=\"color: #3abaf4;\">Go To Target Edit</a>\n                                                </div>\n                                                <div *ngIf=\"i==2 && forward_4 == 'FORWARD_TO_ROUTING'\">\n                                                  <!-- <select formControlName=\"forwardto_routing_4\" class=\"form-control\">\n                                                    <option value=\"\">Select Targets</option>\n                                                    <option *ngFor=\"let name of alltarget;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select> -->\n                                                  <angular2-multiselect [data]=\"alltarget\" [(ngModel)]=\"forwardto_routing_4\" formControlName=\"forwardto_routing_4\" [settings]=\n                                                  \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select Target'}\">\n                                                  </angular2-multiselect> \n                                                  <a *ngIf=\"forwardto_routing_4\" target=\"_blank\" routerLink=\"/edit-numbers/{{forwardto_routing_4[0].uuid}}\" style=\"color: #3abaf4;\">Go To Target Edit</a>\n                                                </div>\n                                                <div *ngIf=\"i==3 && forward_5 == 'FORWARD_TO_ROUTING'\">\n                                                  <!-- <select formControlName=\"forwardto_routing_5\" class=\"form-control\" >\n                                                    <option value=\"\">Select Targets</option>\n                                                    <option *ngFor=\"let name of alltarget;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select> -->\n                                                  <angular2-multiselect [data]=\"alltarget\" [(ngModel)]=\"forwardto_routing_5\" formControlName=\"forwardto_routing_5\" [settings]=\n                                                  \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select Target'}\">\n                                                  </angular2-multiselect> \n                                                  <a *ngIf=\"forwardto_routing_5\" target=\"_blank\" routerLink=\"/edit-numbers/{{forwardto_routing_5[0].uuid}}\" style=\"color: #3abaf4;\">Go To Target Edit</a>\n                                                </div>\n                                                <div *ngIf=\"i==4 && forward_6 == 'FORWARD_TO_ROUTING'\">\n                                                  <!-- <select formControlName=\"forwardto_routing_6\" class=\"form-control\">\n                                                    <option value=\"\">Select Targets</option>\n                                                    <option *ngFor=\"let name of alltarget;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select> -->\n                                                  <angular2-multiselect [data]=\"alltarget\" [(ngModel)]=\"forwardto_routing_6\" formControlName=\"forwardto_routing_6\" [settings]=\n                                                  \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select Target'}\">\n                                                  </angular2-multiselect> \n                                                  <a *ngIf=\"forwardto_routing_6\" target=\"_blank\" routerLink=\"/edit-numbers/{{forwardto_routing_6[0].uuid}}\" style=\"color: #3abaf4;\">Go To Target Edit</a>\n                                                </div>\n                                                <div *ngIf=\"i==5 && forward_7 == 'FORWARD_TO_ROUTING'\">\n                                                  <!-- <select formControlName=\"forwardto_routing_7\" class=\"form-control\">\n                                                    <option value=\"\">Select Targets</option>\n                                                    <option *ngFor=\"let name of alltarget;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select> -->\n                                                  <angular2-multiselect [data]=\"alltarget\" [(ngModel)]=\"forwardto_routing_7\" formControlName=\"forwardto_routing_7\" [settings]=\n                                                  \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select Target'}\">\n                                                  </angular2-multiselect> \n                                                  <a *ngIf=\"forwardto_routing_7\" target=\"_blank\" routerLink=\"/edit-numbers/{{forwardto_routing_7[0].uuid}}\" style=\"color: #3abaf4;\">Go To Target Edit</a>\n                                                </div>\n                                                <div *ngIf=\"i==6 && forward_8 == 'FORWARD_TO_ROUTING'\">\n                                                  <!-- <select formControlName=\"forwardto_routing_8\" class=\"form-control\">\n                                                    <option value=\"\">Select Targets</option>\n                                                    <option *ngFor=\"let name of alltarget;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select> -->\n                                                  <angular2-multiselect [data]=\"alltarget\" [(ngModel)]=\"forwardto_routing_8\" formControlName=\"forwardto_routing_8\" [settings]=\n                                                  \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select Target'}\">\n                                                  </angular2-multiselect> \n                                                  <a *ngIf=\"forwardto_routing_8\" target=\"_blank\" routerLink=\"/edit-numbers/{{forwardto_routing_8[0].uuid}}\" style=\"color: #3abaf4;\">Go To Target Edit</a>\n                                                </div>\n                                                <div *ngIf=\"i==7 && forward_9 == 'FORWARD_TO_ROUTING'\">\n                                                  <!-- <select formControlName=\"forwardto_routing_9\" class=\"form-control\">\n                                                    <option value=\"\">Select Targets</option>\n                                                    <option *ngFor=\"let name of alltarget;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select> -->\n                                                  <angular2-multiselect [data]=\"alltarget\" [(ngModel)]=\"forwardto_routing_9\" formControlName=\"forwardto_routing_9\" [settings]=\n                                                  \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select Target'}\">\n                                                  </angular2-multiselect> \n                                                  <a *ngIf=\"forwardto_routing_9\" target=\"_blank\" routerLink=\"/edit-numbers/{{forwardto_routing_9[0].uuid}}\" style=\"color: #3abaf4;\">Go To Target Edit</a>\n                                                </div>\n                                                <div *ngIf=\"i==8 && forward_10 == 'FORWARD_TO_ROUTING'\">\n                                                  <!-- <select formControlName=\"forwardto_routing_10\" class=\"form-control\">\n                                                    <option value=\"\">Select Targets</option>\n                                                    <option *ngFor=\"let name of alltarget;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select> -->\n                                                  <angular2-multiselect [data]=\"alltarget\" [(ngModel)]=\"forwardto_routing_10\" formControlName=\"forwardto_routing_10\" [settings]=\n                                                  \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select Target'}\">\n                                                  </angular2-multiselect> \n                                                  <a *ngIf=\"forwardto_routing_10\" target=\"_blank\" routerLink=\"/edit-numbers/{{forwardto_routing_10[0].uuid}}\" style=\"color: #3abaf4;\">Go To Target Edit</a>\n                                                </div>   \n\n\n\n\n                                                <!-- <div *ngIf=\"i==0 && forward_2 == 'FORWARD_TO_IVRROUTING'\">\n                                                  <select formControlName=\"forwardto_ivrrouting_2\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Routing</option>\n                                                    <option *ngFor=\"let name of allivrroutingplan;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==1 && forward_3 == 'FORWARD_TO_IVRROUTING'\">\n                                                  <select formControlName=\"forwardto_ivrrouting_3\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Routing</option>\n                                                    <option *ngFor=\"let name of allivrroutingplan;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==2 && forward_4 == 'FORWARD_TO_IVRROUTING'\">\n                                                  <select formControlName=\"forwardto_ivrrouting_4\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Routing</option>\n                                                    <option *ngFor=\"let name of allivrroutingplan;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==3 && forward_5 == 'FORWARD_TO_IVRROUTING'\">\n                                                  <select formControlName=\"forwardto_ivrrouting_5\" class=\"form-control\" >\n                                                    <option value=\"\">Select IVR Routing</option>\n                                                    <option *ngFor=\"let name of allivrroutingplan;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==4 && forward_6 == 'FORWARD_TO_IVRROUTING'\">\n                                                  <select formControlName=\"forwardto_ivrrouting_6\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Routing</option>\n                                                    <option *ngFor=\"let name of allivrroutingplan;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==5 && forward_7 == 'FORWARD_TO_IVRROUTING'\">\n                                                  <select formControlName=\"forwardto_ivrrouting_7\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Routing</option>\n                                                    <option *ngFor=\"let name of allivrroutingplan;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==6 && forward_8 == 'FORWARD_TO_IVRROUTING'\">\n                                                  <select formControlName=\"forwardto_ivrrouting_8\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Routing</option>\n                                                    <option *ngFor=\"let name of allivrroutingplan;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==7 && forward_9 == 'FORWARD_TO_IVRROUTING'\">\n                                                  <select formControlName=\"forwardto_ivrrouting_9\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Routing</option>\n                                                    <option *ngFor=\"let name of allivrroutingplan;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==8 && forward_10 == 'FORWARD_TO_IVRROUTING'\">\n                                                  <select formControlName=\"forwardto_ivrrouting_10\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Routing</option>\n                                                    <option *ngFor=\"let name of allivrroutingplan;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select>\n                                                </div>    -->\n\n\n                                                <div *ngIf=\"i==0 && forward_2 == 'FORWARD_TO_IVRROUTING'\">\n                                                  <!-- <select formControlName=\"forwardto_ivrrouting_2\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Routing</option>\n                                                    <option *ngFor=\"let name of allivrroutingplan;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select> -->\n                                                  <angular2-multiselect [data]=\"allivrroutingplan\" [(ngModel)]=\"forwardto_ivrrouting_2\" formControlName=\"forwardto_ivrrouting_2\" [settings]=\n                                                  \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select IVR Routing'}\">\n                                                  </angular2-multiselect> \n                                                  <a *ngIf=\"forwardto_ivrrouting_2\" target=\"_blank\" routerLink=\"/ivrplan-edit/{{forwardto_ivrrouting_2[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Plan Edit</a>\n                                                </div>\n                                                <div *ngIf=\"i==1 && forward_3 == 'FORWARD_TO_IVRROUTING'\">\n                                                  <!-- <select formControlName=\"forwardto_ivrrouting_3\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Routing</option>\n                                                    <option *ngFor=\"let name of allivrroutingplan;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select> -->\n                                                  <angular2-multiselect [data]=\"allivrroutingplan\" [(ngModel)]=\"forwardto_ivrrouting_3\"  formControlName=\"forwardto_ivrrouting_3\" [settings]=\n                                                  \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select IVR Routing'}\">\n                                                  </angular2-multiselect>\n                                                  <a *ngIf=\"forwardto_ivrrouting_3\" target=\"_blank\" routerLink=\"/ivrplan-edit/{{forwardto_ivrrouting_3[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Plan Edit</a>\n                                                </div>\n                                                <div *ngIf=\"i==2 && forward_4 == 'FORWARD_TO_IVRROUTING'\">\n                                                  <!-- <select formControlName=\"forwardto_ivrrouting_4\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Routing</option>\n                                                    <option *ngFor=\"let name of allivrroutingplan;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select> -->\n                                                  <angular2-multiselect [data]=\"allivrroutingplan\" [(ngModel)]=\"forwardto_ivrrouting_4\" formControlName=\"forwardto_ivrrouting_4\" [settings]=\n                                                  \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select IVR Routing'}\">\n                                                  </angular2-multiselect>\n                                                  <a *ngIf=\"forwardto_ivrrouting_4\" target=\"_blank\" routerLink=\"/ivrplan-edit/{{forwardto_ivrrouting_4[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Plan Edit</a>\n                                                </div>\n                                                <div *ngIf=\"i==3 && forward_5 == 'FORWARD_TO_IVRROUTING'\">\n                                                  <!-- <select formControlName=\"forwardto_ivrrouting_5\" class=\"form-control\" >\n                                                    <option value=\"\">Select IVR Routing</option>\n                                                    <option *ngFor=\"let name of allivrroutingplan;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select> -->\n                                                  <angular2-multiselect [data]=\"allivrroutingplan\" [(ngModel)]=\"forwardto_ivrrouting_5\" formControlName=\"forwardto_ivrrouting_5\" [settings]=\n                                                  \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select IVR Routing'}\">\n                                                  </angular2-multiselect>\n                                                  <a *ngIf=\"forwardto_ivrrouting_5\" target=\"_blank\" routerLink=\"/ivrplan-edit/{{forwardto_ivrrouting_5[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Plan Edit</a>\n                                                </div>\n                                                <div *ngIf=\"i==4 && forward_6 == 'FORWARD_TO_IVRROUTING'\">\n                                                  <!-- <select formControlName=\"forwardto_ivrrouting_6\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Routing</option>\n                                                    <option *ngFor=\"let name of allivrroutingplan;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select> -->\n                                                  <angular2-multiselect [data]=\"allivrroutingplan\" [(ngModel)]=\"forwardto_ivrrouting_6\" formControlName=\"forwardto_ivrrouting_6\" [settings]=\n                                                  \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select IVR Routing'}\">\n                                                  </angular2-multiselect>\n                                                  <a *ngIf=\"forwardto_ivrrouting_6\" target=\"_blank\" routerLink=\"/ivrplan-edit/{{forwardto_ivrrouting_6[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Plan Edit</a>\n                                                </div>\n                                                <div *ngIf=\"i==5 && forward_7 == 'FORWARD_TO_IVRROUTING'\">\n                                                  <!-- <select formControlName=\"forwardto_ivrrouting_7\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Routing</option>\n                                                    <option *ngFor=\"let name of allivrroutingplan;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select> -->\n                                                  <angular2-multiselect [data]=\"allivrroutingplan\" [(ngModel)]=\"forwardto_ivrrouting_7\" formControlName=\"forwardto_ivrrouting_7\" [settings]=\n                                                  \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select IVR Routing'}\">\n                                                  </angular2-multiselect>\n                                                  <a *ngIf=\"forwardto_ivrrouting_7\" target=\"_blank\" routerLink=\"/ivrplan-edit/{{forwardto_ivrrouting_7[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Plan Edit</a>\n                                                </div>\n                                                <div *ngIf=\"i==6 && forward_8 == 'FORWARD_TO_IVRROUTING'\">\n                                                  <!-- <select formControlName=\"forwardto_ivrrouting_8\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Routing</option>\n                                                    <option *ngFor=\"let name of allivrroutingplan;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select> -->\n                                                  <angular2-multiselect [data]=\"allivrroutingplan\" [(ngModel)]=\"forwardto_ivrrouting_8\" formControlName=\"forwardto_ivrrouting_8\" [settings]=\n                                                  \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select IVR Routing'}\">\n                                                  </angular2-multiselect>\n                                                  <a *ngIf=\"forwardto_ivrrouting_8\" target=\"_blank\" routerLink=\"/ivrplan-edit/{{forwardto_ivrrouting_8[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Plan Edit</a>\n                                                </div>\n                                                <div *ngIf=\"i==7 && forward_9 == 'FORWARD_TO_IVRROUTING'\">\n                                                  <!-- <select formControlName=\"forwardto_ivrrouting_9\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Routing</option>\n                                                    <option *ngFor=\"let name of allivrroutingplan;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select> -->\n                                                  <angular2-multiselect [data]=\"allivrroutingplan\" [(ngModel)]=\"forwardto_ivrrouting_9\" formControlName=\"forwardto_ivrrouting_9\" [settings]=\n                                                  \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select IVR Routing'}\">\n                                                  </angular2-multiselect>\n                                                  <a *ngIf=\"forwardto_ivrrouting_9\" target=\"_blank\" routerLink=\"/ivrplan-edit/{{forwardto_ivrrouting_9[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Plan Edit</a>\n                                                </div>\n                                                <div *ngIf=\"i==8 && forward_10 == 'FORWARD_TO_IVRROUTING'\">\n                                                  <!-- <select formControlName=\"forwardto_ivrrouting_10\" class=\"form-control\">\n                                                    <option value=\"\">Select IVR Routing</option>\n                                                    <option *ngFor=\"let name of allivrroutingplan;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select> -->\n                                                  <angular2-multiselect [data]=\"allivrroutingplan\" [(ngModel)]=\"forwardto_ivrrouting_10\" formControlName=\"forwardto_ivrrouting_10\" [settings]=\n                                                  \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select IVR Routing'}\">\n                                                  </angular2-multiselect>\n                                                  <a *ngIf=\"forwardto_ivrrouting_10\" target=\"_blank\" routerLink=\"/ivrplan-edit/{{forwardto_ivrrouting_10[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Plan Edit</a>\n                                                </div>   \n\n                                                \n                                                <!-- {{forward_2}} -->\n                                                <!-- <div *ngIf=\"i==0 && forward_2 == 'FORWARD_TO_CAMPAIGN'\">\n                                                  <select formControlName=\"forwardto_campaign_2\" class=\"form-control\">\n                                                    <option value=\"\">Select Campaign</option>\n                                                    <option *ngFor=\"let name of campaigns;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==1 && forward_3 == 'FORWARD_TO_CAMPAIGN'\">\n                                                  <select formControlName=\"forwardto_campaign_3\" class=\"form-control\">\n                                                    <option value=\"\">Select Campaign</option>\n                                                    <option *ngFor=\"let name of campaigns;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==2 && forward_4 == 'FORWARD_TO_CAMPAIGN'\">\n                                                  <select formControlName=\"forwardto_campaign_4\" class=\"form-control\">\n                                                    <option value=\"\">Select Campaign</option>\n                                                    <option *ngFor=\"let name of campaigns;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==3 && forward_5 == 'FORWARD_TO_CAMPAIGN'\">\n                                                  <select formControlName=\"forwardto_campaign_5\" class=\"form-control\" >\n                                                    <option value=\"\">Select Campaign</option>\n                                                    <option *ngFor=\"let name of campaigns;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==4 && forward_6 == 'FORWARD_TO_CAMPAIGN'\">\n                                                  <select formControlName=\"forwardto_campaign_6\" class=\"form-control\">\n                                                    <option value=\"\">Select Campaign</option>\n                                                    <option *ngFor=\"let name of campaigns;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==5 && forward_7 == 'FORWARD_TO_CAMPAIGN'\">\n                                                  <select formControlName=\"forwardto_campaign_7\" class=\"form-control\">\n                                                    <option value=\"\">Select Campaign</option>\n                                                    <option *ngFor=\"let name of campaigns;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==6 && forward_8 == 'FORWARD_TO_CAMPAIGN'\">\n                                                  <select formControlName=\"forwardto_campaign_8\" class=\"form-control\">\n                                                    <option value=\"\">Select Campaign</option>\n                                                    <option *ngFor=\"let name of campaigns;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==7 && forward_9 == 'FORWARD_TO_CAMPAIGN'\">\n                                                  <select formControlName=\"forwardto_campaign_9\" class=\"form-control\">\n                                                    <option value=\"\">Select Campaign</option>\n                                                    <option *ngFor=\"let name of campaigns;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select>\n                                                </div>\n                                                <div *ngIf=\"i==8 && forward_10 == 'FORWARD_TO_CAMPAIGN'\">\n                                                  <select formControlName=\"forwardto_campaign_10\" class=\"form-control\">\n                                                    <option value=\"\">Select Campaign</option>\n                                                    <option *ngFor=\"let name of campaigns;\" [value]=\"name.id\">\n                                                        {{name.text}}\n                                                    </option>\n                                                  </select>\n                                                </div>    -->\n                                            </div>\n                                        </div>\n                                      </td>\n                                 </tr>\n                          </tbody>\n                      </table>\n                \n                 </div>\n                 <div class=\"card-footer text-right\">\n                       <button  class=\"btn btn-primary mr-1 btn-sm  p-2\" type=\"submit\">Create IVR Menu</button>\n                       <button style=\"margin-right: 4px;\" routerLink=\"/ivr-menu\" class=\"btn btn-primary btn-sm  p-2\">Back To IVR Menus</button>\n                       <button class=\"btn btn-secondary btn-sm p-2\" type=\"reset\">Reset</button>\n                     </div>\n               </div>\n             </form>\n\n   </div>\n";

/***/ }),

/***/ 23404:
/*!***************************************************************************************!*\
  !*** ./src/app/modules/ivr-menus/edit-ivrmenu/edit-ivrmenu.component.html?ngResource ***!
  \***************************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n<!-- <div *ngIf=\"showLoadingIndicator\">\n  <div class=\"loader\"></div>\n</div> -->\n<div class=\"main-content\"  style=\"position: relative\">\n  <div class=\"section\">\n    <ng-template #foregroundSpinner>\n      <div class=\"sk-chase\">\n        <div class=\"sk-chase-dot customLoaderId\"></div>\n      </div>\n    </ng-template>                \n    <ngx-ui-loader\n      [loaderId]=\"loader.loaderId\"\n      [fgsTemplate]=\"foregroundSpinner\"\n    ></ngx-ui-loader>\n    <div class=\"section-body\">\n      <div class=\"row\">\n        <div class=\"col-12 col-md-12 col-lg-12\">\n          <form method=\"post\" [formGroup]=\"editIVRMenuForm\" (ngSubmit)=\"onSubmit()\">\n          <div class=\"card\">\n            <div class=\"card-header\">\n              <h4>Edit IVR Menu</h4>\n            </div>\n            <div class=\"card-body\">                    \n              <div class=\"form-group\">\n                <label>Name</label>\n                <div class=\"input-group\">\n                  <input formControlName=\"name\" id=\"name\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': submitted && f.name.errors }\"> \n                  <div *ngIf=\"submitted && f.name.errors\" class=\"invalid-feedback\">\n                      <div *ngIf=\"f.name.errors.required\">Name is required</div>          \n                  </div>                      \n                  </div>  \n              </div>\n\n              <div class=\"form-group\">\n                 <label>Number Of Retries</label>\n                 <div class=\"input-group\">\n                   <input formControlName=\"noofretries\" id=\"noofretries\" type=\"number\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': submitted && f.noofretries.errors }\" min=\"0\"> \n                   <div *ngIf=\"submitted && f.noofretries.errors\" class=\"invalid-feedback\">\n                       <div *ngIf=\"f.noofretries.errors.required\">Number Of Retries is required</div>                            \n                   </div>                      \n                   </div>  \n               </div>                    \n\n             <div class=\"form-group\">\n               <label>Timeout</label>\n               <div class=\"input-group\">\n                 <input formControlName=\"timeout\" id=\"timeout\" type=\"number\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': submitted && f.timeout.errors }\" min=\"0\"> \n                 <div *ngIf=\"submitted && f.timeout.errors\" class=\"invalid-feedback\">\n                     <div *ngIf=\"f.timeout.errors.required\">Timeout is required</div>    \n                 </div>                      \n                 </div>  \n             </div>\n             \n             <div class=\"form-group\">\n                 <label>How many options in the IVR (1-9)</label>\n                 <select formControlName=\"ivr_options\" class=\"form-control\" (change)=\"IVR_Options($event)\">\n                   <option value=\"0\">0</option>\n                   <option value=\"1\" selected>1</option>\n                   <option value=\"2\">2</option>\n                   <option value=\"3\">3</option>\n                   <option value=\"4\">4</option>\n                   <option value=\"5\">5</option>\n                   <option value=\"6\">6</option>\n                   <option value=\"7\">7</option>\n                   <option value=\"8\">8</option>\n                   <option value=\"9\">9</option>\n                 </select>\n                \n               </div>\n            \n             <div class=\"form-group\" *ngIf=\"selectedIVR_Options!=''\">\n                 <label>Default response if no response by caller</label>\n                 <select formControlName=\"default_response\" class=\"form-control\" >\n                   <option disabled>Select default option for no response</option>\n                   <option *ngFor=\"let in of selectedIVR();let i = index\" [value]=\"in+1\">\n                      {{in+1}}\n                     </option>                  \n                 </select>\n               </div>\n\n               \n              <div class=\"form-group\" *ngIf=\"allBuyers?.length>0\">\n                <label>Buyer</label>\n                <!-- <select formControlName=\"buyer\" class=\"form-control\" value=\"''\">\n                  <option value=\"\" selected>Select Buyer</option>\n                  <option *ngFor=\"let buyers of allBuyers;\" [value]=\"buyers.id\">\n                      {{buyers.text}}\n                    </option>\n                </select> -->\n                <angular2-multiselect [data]=\"allBuyers\" [(ngModel)]=\"selectedItems\" formControlName=\"buyer\" [settings]=\"settings\"></angular2-multiselect>       \n              </div>\n\n               <table style=\"font-size: 13px;\" class=\"table table-striped dataTable no-footer\">\n                 <thead>\n                     <tr>\n                         <th></th>\n                         <th>Link to File</th>\n                         <th>Select Audio</th>\n                         <th>Upload Audio File</th>\n                         <th>Forward to IVR or Routing</th>\n                     </tr>\n                 </thead>\n                 <tbody>\n                     <tr style=\"background: #fff;\">\n                         <td>Opening Menu Recording</td>\n                         <td>\n                             <audio *ngIf=\"url_0!==''\" style=\"width: 147px;\" controls>\n                               <source src=\"{{url_0}}\" type=\"audio/mp3\">\n                             </audio>\n                         </td>\n                         <td>\n                             <select class=\"form-control\" name='audio_uuid_0' formControlName=\"audio_uuid_0\" (change)=\"audiochange($event,0)\">\n                               <option value=\"\" selected=\"\">No audio file</option>\n                               <option *ngFor=\"let aud of audio;\" [value]=\"aud.uuid\">\n                                   {{aud.original_filename}}\n                               </option>\n                             </select>\n                         </td>\n                         <td>\n                           <div class=\"qq-upload-button-selector btn btn-primary pull-left\" style=\"position: relative; overflow: hidden; direction: ltr;font-size: 12px;width: 39px;\">\n                             <div><i class=\"fa fa-upload\"></i></div>\n                             <input (change)=\"selectFile($event,0)\" formControlName=\"upload_audio_0\" title=\"file input\"  type=\"file\" style=\"position: absolute; right: 0px; top: 0px; font-family: Arial; font-size: 118px; margin: 0px; padding: 0px; cursor: pointer; opacity: 0; height: 100%;\">\n                           </div><br><br>\n                           <!-- <div *ngIf=\"currentFileUpload\" class=\"progress\">\n                               <div class=\"progress-bar progress-bar-info progress-bar-striped\" \n                               role=\"progressbar\" attr.aria-valuenow=\"{{progress.percentage}}\"\n                                 aria-valuemin=\"0\" aria-valuemax=\"100\" [ngStyle]=\"{width:progress.percentage+'%'}\">\n                                 {{progress.percentage}}%</div>\n                             </div> -->\n                         </td>\n                           <td>\n                               <div class=\"row\">\n                                   <div class=\"col-md-6\">\n                                     <select formControlName=\"forward_to_0\" class=\"form-control\" (change)=\"forward_to($event,0)\" [value]=\"'FORWARD_TO_NUMBER'\">\n                                        <option value=\"CONTINUE\">Continue</option>\n                                        <option value=\"FORWARD_TO_NUMBER\">Forward to Phone Number</option>\n                                         <!-- <option *ngFor=\"let name of menuname;\" [value]=\"name.id\">\n                                             {{name.name}} \n                                         </option> -->\n                                       </select>\n                                   </div>\n                                   <div class=\"col-md-6\" *ngIf=\"forward_0 == 'FORWARD_TO_NUMBER'\">\n                                     <input formControlName=\"forwardto_phone_0\" placeholder=\"(000) 000-000\" class=\"form-control\" id=\"forwardto_phone_0\" (keypress)=_keyPress($event) maxlength=\"14\">\n                                   </div>\n                               </div>\n                           </td>\n                           </tr>\n                          \n                           <tr style=\"background: #fff;\">\n                            <td>#</td>\n                            <td>\n                                <audio *ngIf=\"url_1!==''\" style=\"width: 147px;\" controls>\n                                  <source src=\"{{url_1}}\" type=\"audio/mp3\">\n                                </audio>                                 \n                            </td>\n                            <td>\n                                <select class=\"form-control\" name='audio_uuid_1' formControlName=\"audio_uuid_1\" (change)=\"audiochange($event,1)\">\n                                  <option value=\"\" selected=\"\">No audio file</option>\n                                  <option *ngFor=\"let aud of audio;\" [value]=\"aud.uuid\">\n                                      {{aud.original_filename}}\n                                  </option>\n                                </select>\n                            </td>\n                            <td>\n                              <div class=\"qq-upload-button-selector btn btn-primary pull-left\" style=\"position: relative; overflow: hidden; direction: ltr;font-size: 12px;width: 39px;\">\n                                <div><i class=\"fa fa-upload\"></i></div>\n                                <input (change)=\"selectFile($event,1)\" formControlName=\"upload_audio_1\" title=\"file input\"  type=\"file\" style=\"position: absolute; right: 0px; top: 0px; font-family: Arial; font-size: 118px; margin: 0px; padding: 0px; cursor: pointer; opacity: 0; height: 100%;\">\n                              </div><br><br>                            \n                            </td>\n                            <td>\n                                <div class=\"row\">\n                                    <div class=\"col-md-6\">\n                                      <select formControlName=\"forward_to_1\" class=\"form-control\" (change)=\"forward_to($event,1)\" [value]=\"'FORWARD_TO_NUMBER'\">\n                                        <option value=\"CONTINUE\">Continue</option>\n                                          <option value=\"FORWARD_TO_NUMBER\">Forward to Phone Number</option>\n                                        </select>\n                                    </div>\n                                    <div class=\"col-md-6\" *ngIf=\"forward_1 == 'FORWARD_TO_NUMBER'\">\n                                      <input formControlName=\"forwardto_phone_1\" placeholder=\"(000) 000-000\" class=\"form-control\" id=\"forwardto_phone_1\" (keypress)=_keyPress($event) maxlength=\"14\">\n                                    </div>\n                                </div>\n                            </td>\n                            </tr>\n                             \n                           <tr *ngFor=\"let i of selectedIVR();\" style=\"background: #fff;\">\n                                 <td>Press {{i+1}} Recording</td>\n                                 <td>\n                                     <div *ngIf=\"url_1!=='' && i+2==1\">\n                                       <audio style=\"width: 147px;\" controls>\n                                         <source src=\"{{url_1}}\" type=\"audio/mp3\">\n                                       </audio>\n                                     </div>\n                                     <div *ngIf=\"url_2!=='' && i+2==2\">\n                                         <audio style=\"width: 147px;\" controls>\n                                           <source src=\"{{url_2}}\" type=\"audio/mp3\">\n                                         </audio>\n                                     </div>\n                                     <div *ngIf=\"url_3!=='' && i+2==3\">\n                                         <audio style=\"width: 147px;\" controls>\n                                           <source src=\"{{url_3}}\" type=\"audio/mp3\">\n                                         </audio>\n                                     </div>\n                                     <div *ngIf=\"url_4!=='' && i+2==4\">\n                                         <audio style=\"width: 147px;\" controls>\n                                           <source src=\"{{url_4}}\" type=\"audio/mp3\">\n                                         </audio>\n                                     </div>\n                                     <div *ngIf=\"url_5!=='' && i+2==5\">\n                                         <audio style=\"width: 147px;\" controls>\n                                           <source src=\"{{url_5}}\" type=\"audio/mp3\">\n                                         </audio>\n                                     </div>\n                                     <div *ngIf=\"url_6!=='' && i+2==6\">\n                                         <audio style=\"width: 147px;\" controls>\n                                           <source src=\"{{url_6}}\" type=\"audio/mp3\">\n                                         </audio>\n                                     </div>\n                                     <div *ngIf=\"url_7!=='' && i+2==7\">\n                                         <audio style=\"width: 147px;\" controls>\n                                           <source src=\"{{url_7}}\" type=\"audio/mp3\">\n                                         </audio>\n                                     </div>\n                                     <div *ngIf=\"url_8!=='' && i+2==8\" id=\"url_8\">\n                                         <audio style=\"width: 147px;\" controls>\n                                           <source src=\"{{url_8}}\" type=\"audio/mp3\">\n                                         </audio>\n                                     </div>\n                                     <div *ngIf=\"url_9!=='' && i+2==9\" id=\"url_9\" >\n                                         <audio style=\"width: 147px;\" controls>\n                                           <source src=\"{{url_9}}\" type=\"audio/mp3\">\n                                         </audio>\n                                     </div>\n                                     <div *ngIf=\"url_10!=='' && i+2==10\" id=\"url_10\" >\n                                         <audio style=\"width: 147px;\" controls>\n                                           <source src=\"{{url_10}}\" type=\"audio/mp3\">\n                                         </audio>\n                                     </div>\n                                 </td>\n                                 <td>\n                                 <select class=\"form-control\" formControlName=\"audio_uuid_{{i+2}}\" (change)=\"audiochange($event,i+2)\">\n                                   <option value=\"\" selected=\"\" >No audio file</option>\n                                   <option *ngFor=\"let aud of audio;\" [value]=\"aud.uuid\">\n                                       {{aud.original_filename}}\n                                   </option>\n                                 </select>\n                               </td>\n                               <td>\n                               <div>\n                                   <div class=\"btn btn-primary pull-left\" style=\"position: relative; overflow: hidden; direction: ltr;font-size: 12px;width: 39px;\">\n                                   <div><i class=\"fa fa-upload\"></i></div>\n                                   <input (change)=\"selectFile($event,i+2)\" formControlName=\"upload_audio_{{i+2}}\" title=\"file input\" type=\"file\"  style=\"position: absolute; right: 0px; top: 0px; font-family: Arial; font-size: 118px; margin: 0px; padding: 0px; cursor: pointer; opacity: 0; height: 100%;\">\n                                   </div>                     \n                               </div>\n                               </td>\n                               <td>\n                                   <div class=\"row\">\n                                       <div class=\"col-md-6\">\n                                           <select formControlName=\"forward_to_{{i+2}}\" class=\"form-control\" (change)=\"forward_to($event,i+2)\">\n                                              <option value=\"FORWARD_TO_IVR\">Forward to IVR</option>\n                                              <option value=\"FORWARD_TO_ROUTING\">Forward to Targets</option>\n                                              <option value=\"FORWARD_TO_IVRROUTING\">Forward to IVR Routing</option>\n                                              <option value=\"FORWARD_TO_NUMBER\">Forward to Phone Number</option>\n                                              <!-- <option value=\"FORWARD_TO_CAMPAIGN\">Forward to Campaign</option> -->\n                                              <!-- <option *ngFor=\"let name of menuname;\" [value]=\"name.id\">\n                                                 {{name.name}}\n                                             </option> -->\n                                           </select>\n                                       </div>                                     \n\n                                       <div class=\"col-md-6\" >\n                                        <div *ngIf=\"i==0 && forward_2 == 'FORWARD_TO_NUMBER'\">\n                                          <input id=\"forwardto_phone_2\" formControlName=\"forwardto_phone_2\" placeholder=\"(000) 000-000\" class=\"form-control\" (keypress)=_keyPress($event) maxlength=\"14\">\n                                        </div>\n                                        <div *ngIf=\"i==1 && forward_3 == 'FORWARD_TO_NUMBER'\">\n                                            <input formControlName=\"forwardto_phone_3\" id=\"forwardto_phone_3\" placeholder=\"(000) 000-000\" class=\"form-control\" (keypress)=_keyPress($event) maxlength=\"14\">\n                                        </div>\n                                        <div *ngIf=\"i==2 && forward_4 == 'FORWARD_TO_NUMBER'\">\n                                            <input id=\"forwardto_phone_4\" formControlName=\"forwardto_phone_4\" placeholder=\"(000) 000-000\" class=\"form-control\" (keypress)=_keyPress($event) maxlength=\"14\">\n                                        </div>\n                                        <div *ngIf=\"i==3 && forward_5 == 'FORWARD_TO_NUMBER'\">\n                                            <input id=\"forwardto_phone_5\" formControlName=\"forwardto_phone_5\" placeholder=\"(000) 000-000\" class=\"form-control\" (keypress)=_keyPress($event) maxlength=\"14\">\n                                        </div>\n                                        <div *ngIf=\"i==4 && forward_6 == 'FORWARD_TO_NUMBER'\">\n                                            <input id=\"forwardto_phone_6\" formControlName=\"forwardto_phone_6\" placeholder=\"(000) 000-000\" class=\"form-control\" (keypress)=_keyPress($event) maxlength=\"14\">\n                                        </div>\n                                        <div *ngIf=\"i==5 && forward_7 == 'FORWARD_TO_NUMBER'\">\n                                            <input id=\"forwardto_phone_7\" formControlName=\"forwardto_phone_7\" placeholder=\"(000) 000-000\" class=\"form-control\" (keypress)=_keyPress($event) maxlength=\"14\">\n                                        </div>\n                                        <div *ngIf=\"i==6 && forward_8 == 'FORWARD_TO_NUMBER'\">\n                                            <input id=\"forwardto_phone_8\" formControlName=\"forwardto_phone_8\" placeholder=\"(000) 000-000\" class=\"form-control\" (keypress)=_keyPress($event) maxlength=\"14\">\n                                        </div>\n                                        <div *ngIf=\"i==7 && forward_9 == 'FORWARD_TO_NUMBER'\">\n                                            <input id=\"forwardto_phone_9\" formControlName=\"forwardto_phone_9\" placeholder=\"(000) 000-000\" class=\"form-control\" (keypress)=_keyPress($event) maxlength=\"14\">\n                                        </div>\n                                        <div *ngIf=\"i==8 && forward_10 == 'FORWARD_TO_NUMBER'\">\n                                            <input id=\"forwardto_phone_10\" formControlName=\"forwardto_phone_10\" placeholder=\"(000) 000-000\" class=\"form-control\" (keypress)=_keyPress($event) maxlength=\"14\">\n                                        </div>  \n                                        \n                                       \n                                        <div *ngIf=\"i==0 && forward_2 == 'FORWARD_TO_IVR'\">\n                                          <!-- <select formControlName=\"forwardto_ivr_2\" class=\"form-control\">\n                                            <option value=\"\">Select IVR Menu</option>\n                                            <option *ngFor=\"let name of menuname;\" [value]=\"name.id\">\n                                                {{name.name}}\n                                            </option>\n                                          </select> -->\n                                          <angular2-multiselect [data]=\"menuname\" [(ngModel)]=\"forwardto_ivr_2\" formControlName=\"forwardto_ivr_2\" [settings]=\n                                          \"{\n                                            enableSearchFilter: true,\n                                            showCheckbox:false,\n                                            singleSelection: true, text:'Select IVR'}\"></angular2-multiselect> \n                                            \n                                            <a *ngIf=\"forwardto_ivr_2\" target=\"_blank\" routerLink=\"/edit-ivr/{{forwardto_ivr_2[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Edit</a>\n                                        </div>\n                                        <div *ngIf=\"i==1 && forward_3 == 'FORWARD_TO_IVR'\">\n                                          <!-- <select formControlName=\"forwardto_ivr_3\" class=\"form-control\">\n                                            <option value=\"\">Select IVR Menu</option>\n                                            <option *ngFor=\"let name of menuname;\" [value]=\"name.id\">\n                                                {{name.name}}\n                                            </option>\n                                          </select> -->\n                                          <angular2-multiselect [data]=\"menuname\" class=\"pb-2\" [(ngModel)]=\"forwardto_ivr_3\" formControlName=\"forwardto_ivr_3\" [settings]=\n                                          \"{\n                                            enableSearchFilter: true,\n                                            showCheckbox:false,\n                                            singleSelection: true, text:'Select IVR'}\"></angular2-multiselect> \n                                            <a *ngIf=\"forwardto_ivr_3\" target=\"_blank\" routerLink=\"/edit-ivr/{{forwardto_ivr_3[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Edit</a>\n\n                                        </div>\n                                        <div *ngIf=\"i==2 && forward_4 == 'FORWARD_TO_IVR'\">\n                                          <!-- <select formControlName=\"forwardto_ivr_4\" class=\"form-control\">\n                                            <option value=\"\">Select IVR Menu</option>\n                                            <option *ngFor=\"let name of menuname;\" [value]=\"name.id\">\n                                                {{name.name}}\n                                            </option>\n                                          </select> -->\n                                          <angular2-multiselect [data]=\"menuname\" [(ngModel)]=\"forwardto_ivr_4\" formControlName=\"forwardto_ivr_4\" [settings]=\n                                          \"{\n                                            enableSearchFilter: true,\n                                            showCheckbox:false,\n                                            singleSelection: true, text:'Select IVR'}\"></angular2-multiselect> \n                                            <a *ngIf=\"forwardto_ivr_4\" target=\"_blank\" routerLink=\"/edit-ivr/{{forwardto_ivr_4[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Edit</a>\n                                        </div>\n                                        <div *ngIf=\"i==3 && forward_5 == 'FORWARD_TO_IVR'\">\n                                          <!-- <select formControlName=\"forwardto_ivr_5\" class=\"form-control\" >\n                                            <option value=\"\">Select IVR Menu</option>\n                                            <option *ngFor=\"let name of menuname;\" [value]=\"name.id\">\n                                                {{name.name}}\n                                            </option>\n                                          </select> -->\n                                          <angular2-multiselect [data]=\"menuname\" [(ngModel)]=\"forwardto_ivr_5\" formControlName=\"forwardto_ivr_5\" [settings]=\n                                          \"{\n                                            enableSearchFilter: true,\n                                            showCheckbox:false,\n                                            singleSelection: true, text:'Select IVR'}\"></angular2-multiselect> \n                                            <a *ngIf=\"forwardto_ivr_5\" target=\"_blank\" routerLink=\"/edit-ivr/{{forwardto_ivr_5[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Edit</a>\n                                        </div>\n                                        <div *ngIf=\"i==4 && forward_6 == 'FORWARD_TO_IVR'\">\n                                          <!-- <select formControlName=\"forwardto_ivr_6\" class=\"form-control\">\n                                            <option value=\"\">Select IVR Menu</option>\n                                            <option *ngFor=\"let name of menuname;\" [value]=\"name.id\">\n                                                {{name.name}}\n                                            </option>\n                                          </select> -->\n                                          <angular2-multiselect [data]=\"menuname\" [(ngModel)]=\"forwardto_ivr_6\" formControlName=\"forwardto_ivr_6\" [settings]=\n                                          \"{\n                                            enableSearchFilter: true,\n                                            showCheckbox:false,\n                                            singleSelection: true, text:'Select IVR'}\"></angular2-multiselect> \n                                            <a *ngIf=\"forwardto_ivr_6\" target=\"_blank\" routerLink=\"/edit-ivr/{{forwardto_ivr_6[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Edit</a>\n                                        </div>\n                                        <div *ngIf=\"i==5 && forward_7 == 'FORWARD_TO_IVR'\">\n                                          <!-- <select formControlName=\"forwardto_ivr_7\" class=\"form-control\">\n                                            <option value=\"\">Select IVR Menu</option>\n                                            <option *ngFor=\"let name of menuname;\" [value]=\"name.id\">\n                                                {{name.name}}\n                                            </option>\n                                          </select> -->\n                                          <angular2-multiselect [data]=\"menuname\" [(ngModel)]=\"forwardto_ivr_7\" formControlName=\"forwardto_ivr_7\" [settings]=\n                                          \"{\n                                            enableSearchFilter: true,\n                                            showCheckbox:false,\n                                            singleSelection: true, text:'Select IVR'}\"></angular2-multiselect> \n                                            <a *ngIf=\"forwardto_ivr_7\" target=\"_blank\" routerLink=\"/edit-ivr/{{forwardto_ivr_7[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Edit</a>\n                                        </div>\n                                        <div *ngIf=\"i==6 && forward_8 == 'FORWARD_TO_IVR'\">\n                                          <!-- <select formControlName=\"forwardto_ivr_8\" class=\"form-control\">\n                                            <option value=\"\">Select IVR Menu</option>\n                                            <option *ngFor=\"let name of menuname;\" [value]=\"name.id\">\n                                                {{name.name}}\n                                            </option>\n                                          </select> -->\n                                          <angular2-multiselect [data]=\"menuname\" [(ngModel)]=\"forwardto_ivr_8\" formControlName=\"forwardto_ivr_8\" [settings]=\n                                          \"{\n                                            enableSearchFilter: true,\n                                            showCheckbox:false,\n                                            singleSelection: true, text:'Select IVR'}\"></angular2-multiselect> \n                                            <a *ngIf=\"forwardto_ivr_8\" target=\"_blank\" routerLink=\"/edit-ivr/{{forwardto_ivr_8[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Edit</a>\n                                        </div>\n                                        <div *ngIf=\"i==7 && forward_9 == 'FORWARD_TO_IVR'\">\n                                          <!-- <select formControlName=\"forwardto_ivr_9\" class=\"form-control\">\n                                            <option value=\"\">Select IVR Menu</option>\n                                            <option *ngFor=\"let name of menuname;\" [value]=\"name.id\">\n                                                {{name.name}}\n                                            </option>\n                                          </select> -->\n                                          <angular2-multiselect [data]=\"menuname\" [(ngModel)]=\"forwardto_ivr_9\" formControlName=\"forwardto_ivr_9\" [settings]=\n                                          \"{\n                                            enableSearchFilter: true,\n                                            showCheckbox:false,\n                                            singleSelection: true, text:'Select IVR'}\"></angular2-multiselect> \n                                            <a *ngIf=\"forwardto_ivr_9\" target=\"_blank\" routerLink=\"/edit-ivr/{{forwardto_ivr_9[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Edit</a>\n                                        </div>\n                                        <div *ngIf=\"i==8 && forward_10 == 'FORWARD_TO_IVR'\">\n                                          <!-- <select formControlName=\"forwardto_ivr_10\" class=\"form-control\">\n                                            <option value=\"\">Select IVR Menu</option>\n                                            <option *ngFor=\"let name of menuname;\" [value]=\"name.id\">\n                                                {{name.name}}\n                                            </option>\n                                          </select> -->\n                                          <angular2-multiselect [data]=\"menuname\" [(ngModel)]=\"forwardto_ivr_10\" formControlName=\"forwardto_ivr_10\" [settings]=\n                                          \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select IVR'}\">\n                                          </angular2-multiselect> \n                                          <a *ngIf=\"forwardto_ivr_10\" target=\"_blank\" routerLink=\"/edit-ivr/{{forwardto_ivr_10[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Edit</a>\n                                        </div>   \n                                       \n\n\n\n                                        <div *ngIf=\"i==0 && forward_2 == 'FORWARD_TO_ROUTING'\">\n                                          <!-- <select formControlName=\"forwardto_routing_2\" class=\"form-control\">\n                                            <option value=\"\">Select Targets</option>\n                                            <option *ngFor=\"let name of alltarget;\" [value]=\"name.id\">\n                                                {{name.text}}\n                                            </option>\n                                          </select> -->\n                                          <angular2-multiselect [data]=\"alltarget\" [(ngModel)]=\"forwardto_routing_2\" formControlName=\"forwardto_routing_2\" [settings]=\n                                          \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select Target'}\">\n                                          </angular2-multiselect> \n                                          <a *ngIf=\"forwardto_routing_2\" target=\"_blank\" routerLink=\"/edit-numbers/{{forwardto_routing_2[0].uuid}}\" style=\"color: #3abaf4;\">Go To Target Edit</a>\n                                        </div>\n                                        <div *ngIf=\"i==1 && forward_3 == 'FORWARD_TO_ROUTING'\">\n                                          <!-- <select formControlName=\"forwardto_routing_3\" class=\"form-control\">\n                                            <option value=\"\">Select Targets</option>\n                                            <option *ngFor=\"let name of alltarget;\" [value]=\"name.id\">\n                                                {{name.text}}\n                                            </option>\n                                          </select> -->\n                                          <angular2-multiselect [data]=\"alltarget\" [(ngModel)]=\"forwardto_routing_3\" formControlName=\"forwardto_routing_3\" [settings]=\n                                          \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select Target'}\">\n                                          </angular2-multiselect> \n                                          <a *ngIf=\"forwardto_routing_3\" target=\"_blank\" routerLink=\"/edit-numbers/{{forwardto_routing_3[0].uuid}}\" style=\"color: #3abaf4;\">Go To Target Edit</a>\n                                        </div>\n                                        <div *ngIf=\"i==2 && forward_4 == 'FORWARD_TO_ROUTING'\">\n                                          <!-- <select formControlName=\"forwardto_routing_4\" class=\"form-control\">\n                                            <option value=\"\">Select Targets</option>\n                                            <option *ngFor=\"let name of alltarget;\" [value]=\"name.id\">\n                                                {{name.text}}\n                                            </option>\n                                          </select> -->\n                                          <angular2-multiselect [data]=\"alltarget\" [(ngModel)]=\"forwardto_routing_4\" formControlName=\"forwardto_routing_4\" [settings]=\n                                          \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select Target'}\">\n                                          </angular2-multiselect> \n                                          <a *ngIf=\"forwardto_routing_4\" target=\"_blank\" routerLink=\"/edit-numbers/{{forwardto_routing_4[0].uuid}}\" style=\"color: #3abaf4;\">Go To Target Edit</a>\n                                        </div>\n                                        <div *ngIf=\"i==3 && forward_5 == 'FORWARD_TO_ROUTING'\">\n                                          <!-- <select formControlName=\"forwardto_routing_5\" class=\"form-control\" >\n                                            <option value=\"\">Select Targets</option>\n                                            <option *ngFor=\"let name of alltarget;\" [value]=\"name.id\">\n                                                {{name.text}}\n                                            </option>\n                                          </select> -->\n                                          <angular2-multiselect [data]=\"alltarget\" [(ngModel)]=\"forwardto_routing_5\" formControlName=\"forwardto_routing_5\" [settings]=\n                                          \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select Target'}\">\n                                          </angular2-multiselect> \n                                          <a *ngIf=\"forwardto_routing_5\" target=\"_blank\" routerLink=\"/edit-numbers/{{forwardto_routing_5[0].uuid}}\" style=\"color: #3abaf4;\">Go To Target Edit</a>\n                                        </div>\n                                        <div *ngIf=\"i==4 && forward_6 == 'FORWARD_TO_ROUTING'\">\n                                          <!-- <select formControlName=\"forwardto_routing_6\" class=\"form-control\">\n                                            <option value=\"\">Select Targets</option>\n                                            <option *ngFor=\"let name of alltarget;\" [value]=\"name.id\">\n                                                {{name.text}}\n                                            </option>\n                                          </select> -->\n                                          <angular2-multiselect [data]=\"alltarget\" [(ngModel)]=\"forwardto_routing_6\" formControlName=\"forwardto_routing_6\" [settings]=\n                                          \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select Target'}\">\n                                          </angular2-multiselect> \n                                          <a *ngIf=\"forwardto_routing_6\" target=\"_blank\" routerLink=\"/edit-numbers/{{forwardto_routing_6[0].uuid}}\" style=\"color: #3abaf4;\">Go To Target Edit</a>\n                                        </div>\n                                        <div *ngIf=\"i==5 && forward_7 == 'FORWARD_TO_ROUTING'\">\n                                          <!-- <select formControlName=\"forwardto_routing_7\" class=\"form-control\">\n                                            <option value=\"\">Select Targets</option>\n                                            <option *ngFor=\"let name of alltarget;\" [value]=\"name.id\">\n                                                {{name.text}}\n                                            </option>\n                                          </select> -->\n                                          <angular2-multiselect [data]=\"alltarget\" [(ngModel)]=\"forwardto_routing_7\" formControlName=\"forwardto_routing_7\" [settings]=\n                                          \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select Target'}\">\n                                          </angular2-multiselect> \n                                          <a *ngIf=\"forwardto_routing_7\" target=\"_blank\" routerLink=\"/edit-numbers/{{forwardto_routing_7[0].uuid}}\" style=\"color: #3abaf4;\">Go To Target Edit</a>\n                                        </div>\n                                        <div *ngIf=\"i==6 && forward_8 == 'FORWARD_TO_ROUTING'\">\n                                          <!-- <select formControlName=\"forwardto_routing_8\" class=\"form-control\">\n                                            <option value=\"\">Select Targets</option>\n                                            <option *ngFor=\"let name of alltarget;\" [value]=\"name.id\">\n                                                {{name.text}}\n                                            </option>\n                                          </select> -->\n                                          <angular2-multiselect [data]=\"alltarget\" [(ngModel)]=\"forwardto_routing_8\" formControlName=\"forwardto_routing_8\" [settings]=\n                                          \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select Target'}\">\n                                          </angular2-multiselect> \n                                          <a *ngIf=\"forwardto_routing_8\" target=\"_blank\" routerLink=\"/edit-numbers/{{forwardto_routing_8[0].uuid}}\" style=\"color: #3abaf4;\">Go To Target Edit</a>\n                                        </div>\n                                        <div *ngIf=\"i==7 && forward_9 == 'FORWARD_TO_ROUTING'\">\n                                          <!-- <select formControlName=\"forwardto_routing_9\" class=\"form-control\">\n                                            <option value=\"\">Select Targets</option>\n                                            <option *ngFor=\"let name of alltarget;\" [value]=\"name.id\">\n                                                {{name.text}}\n                                            </option>\n                                          </select> -->\n                                          <angular2-multiselect [data]=\"alltarget\" [(ngModel)]=\"forwardto_routing_9\" formControlName=\"forwardto_routing_9\" [settings]=\n                                          \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select Target'}\">\n                                          </angular2-multiselect> \n                                          <a *ngIf=\"forwardto_routing_9\" target=\"_blank\" routerLink=\"/edit-numbers/{{forwardto_routing_9[0].uuid}}\" style=\"color: #3abaf4;\">Go To Target Edit</a>\n                                        </div>\n                                        <div *ngIf=\"i==8 && forward_10 == 'FORWARD_TO_ROUTING'\">\n                                          <!-- <select formControlName=\"forwardto_routing_10\" class=\"form-control\">\n                                            <option value=\"\">Select Targets</option>\n                                            <option *ngFor=\"let name of alltarget;\" [value]=\"name.id\">\n                                                {{name.text}}\n                                            </option>\n                                          </select> -->\n                                          <angular2-multiselect [data]=\"alltarget\" [(ngModel)]=\"forwardto_routing_10\" formControlName=\"forwardto_routing_10\" [settings]=\n                                          \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select Target'}\">\n                                          </angular2-multiselect> \n                                          <a *ngIf=\"forwardto_routing_10\" target=\"_blank\" routerLink=\"/edit-numbers/{{forwardto_routing_10[0].uuid}}\" style=\"color: #3abaf4;\">Go To Target Edit</a>\n                                        </div>   \n\n\n\n                                        \n                                        \n                                        <div *ngIf=\"i==0 && forward_2 == 'FORWARD_TO_IVRROUTING'\">\n                                          <!-- <select formControlName=\"forwardto_ivrrouting_2\" class=\"form-control\">\n                                            <option value=\"\">Select IVR Routing</option>\n                                            <option *ngFor=\"let name of allivrroutingplan;\" [value]=\"name.id\">\n                                                {{name.text}}\n                                            </option>\n                                          </select> -->\n                                          <angular2-multiselect [data]=\"allivrroutingplan\" [(ngModel)]=\"forwardto_ivrrouting_2\" formControlName=\"forwardto_ivrrouting_2\" [settings]=\n                                          \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select IVR Routing'}\">\n                                          </angular2-multiselect> \n                                          <a *ngIf=\"forwardto_ivrrouting_2\" target=\"_blank\" routerLink=\"/ivrplan-edit/{{forwardto_ivrrouting_2[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Plan Edit</a>\n                                        </div>\n                                        <div *ngIf=\"i==1 && forward_3 == 'FORWARD_TO_IVRROUTING'\">\n                                          <!-- <select formControlName=\"forwardto_ivrrouting_3\" class=\"form-control\">\n                                            <option value=\"\">Select IVR Routing</option>\n                                            <option *ngFor=\"let name of allivrroutingplan;\" [value]=\"name.id\">\n                                                {{name.text}}\n                                            </option>\n                                          </select> -->\n                                          <angular2-multiselect [data]=\"allivrroutingplan\" [(ngModel)]=\"forwardto_ivrrouting_3\" formControlName=\"forwardto_ivrrouting_3\" [settings]=\n                                          \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select IVR Routing'}\">\n                                          </angular2-multiselect>\n                                          <a *ngIf=\"forwardto_ivrrouting_3\" target=\"_blank\" routerLink=\"/ivrplan-edit/{{forwardto_ivrrouting_3[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Plan Edit</a>\n                                        </div>\n                                        <div *ngIf=\"i==2 && forward_4 == 'FORWARD_TO_IVRROUTING'\">\n                                          <!-- <select formControlName=\"forwardto_ivrrouting_4\" class=\"form-control\">\n                                            <option value=\"\">Select IVR Routing</option>\n                                            <option *ngFor=\"let name of allivrroutingplan;\" [value]=\"name.id\">\n                                                {{name.text}}\n                                            </option>\n                                          </select> -->\n                                          <angular2-multiselect [data]=\"allivrroutingplan\" [(ngModel)]=\"forwardto_ivrrouting_4\" formControlName=\"forwardto_ivrrouting_4\" [settings]=\n                                          \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select IVR Routing'}\">\n                                          </angular2-multiselect>\n                                          <a *ngIf=\"forwardto_ivrrouting_4\" target=\"_blank\" routerLink=\"/ivrplan-edit/{{forwardto_ivrrouting_4[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Plan Edit</a>\n                                        </div>\n                                        <div *ngIf=\"i==3 && forward_5 == 'FORWARD_TO_IVRROUTING'\">\n                                          <!-- <select formControlName=\"forwardto_ivrrouting_5\" class=\"form-control\" >\n                                            <option value=\"\">Select IVR Routing</option>\n                                            <option *ngFor=\"let name of allivrroutingplan;\" [value]=\"name.id\">\n                                                {{name.text}}\n                                            </option>\n                                          </select> -->\n                                          <angular2-multiselect [data]=\"allivrroutingplan\" [(ngModel)]=\"forwardto_ivrrouting_5\" formControlName=\"forwardto_ivrrouting_5\" [settings]=\n                                          \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select IVR Routing'}\">\n                                          </angular2-multiselect>\n                                          <a *ngIf=\"forwardto_ivrrouting_5\" target=\"_blank\" routerLink=\"/ivrplan-edit/{{forwardto_ivrrouting_5[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Plan Edit</a>\n                                        </div>\n                                        <div *ngIf=\"i==4 && forward_6 == 'FORWARD_TO_IVRROUTING'\">\n                                          <!-- <select formControlName=\"forwardto_ivrrouting_6\" class=\"form-control\">\n                                            <option value=\"\">Select IVR Routing</option>\n                                            <option *ngFor=\"let name of allivrroutingplan;\" [value]=\"name.id\">\n                                                {{name.text}}\n                                            </option>\n                                          </select> -->\n                                          <angular2-multiselect [data]=\"allivrroutingplan\" [(ngModel)]=\"forwardto_ivrrouting_6\" formControlName=\"forwardto_ivrrouting_6\" [settings]=\n                                          \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select IVR Routing'}\">\n                                          </angular2-multiselect>\n                                          <a *ngIf=\"forwardto_ivrrouting_6\" target=\"_blank\" routerLink=\"/ivrplan-edit/{{forwardto_ivrrouting_6[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Plan Edit</a>\n                                        </div>\n                                        <div *ngIf=\"i==5 && forward_7 == 'FORWARD_TO_IVRROUTING'\">\n                                          <!-- <select formControlName=\"forwardto_ivrrouting_7\" class=\"form-control\">\n                                            <option value=\"\">Select IVR Routing</option>\n                                            <option *ngFor=\"let name of allivrroutingplan;\" [value]=\"name.id\">\n                                                {{name.text}}\n                                            </option>\n                                          </select> -->\n                                          <angular2-multiselect [data]=\"allivrroutingplan\" [(ngModel)]=\"forwardto_ivrrouting_7\" formControlName=\"forwardto_ivrrouting_7\" [settings]=\n                                          \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select IVR Routing'}\">\n                                          </angular2-multiselect>\n                                          <a *ngIf=\"forwardto_ivrrouting_7\" target=\"_blank\" routerLink=\"/ivrplan-edit/{{forwardto_ivrrouting_7[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Plan Edit</a>\n                                        </div>\n                                        <div *ngIf=\"i==6 && forward_8 == 'FORWARD_TO_IVRROUTING'\">\n                                          <!-- <select formControlName=\"forwardto_ivrrouting_8\" class=\"form-control\">\n                                            <option value=\"\">Select IVR Routing</option>\n                                            <option *ngFor=\"let name of allivrroutingplan;\" [value]=\"name.id\">\n                                                {{name.text}}\n                                            </option>\n                                          </select> -->\n                                          <angular2-multiselect [data]=\"allivrroutingplan\" [(ngModel)]=\"forwardto_ivrrouting_8\" formControlName=\"forwardto_ivrrouting_8\" [settings]=\n                                          \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select IVR Routing'}\">\n                                          </angular2-multiselect>\n                                          <a *ngIf=\"forwardto_ivrrouting_8\" target=\"_blank\" routerLink=\"/ivrplan-edit/{{forwardto_ivrrouting_8[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Plan Edit</a>\n                                        </div>\n                                        <div *ngIf=\"i==7 && forward_9 == 'FORWARD_TO_IVRROUTING'\">\n                                          <!-- <select formControlName=\"forwardto_ivrrouting_9\" class=\"form-control\">\n                                            <option value=\"\">Select IVR Routing</option>\n                                            <option *ngFor=\"let name of allivrroutingplan;\" [value]=\"name.id\">\n                                                {{name.text}}\n                                            </option>\n                                          </select> -->\n                                          <angular2-multiselect [data]=\"allivrroutingplan\" [(ngModel)]=\"forwardto_ivrrouting_9\" formControlName=\"forwardto_ivrrouting_9\" [settings]=\n                                          \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select IVR Routing'}\">\n                                          </angular2-multiselect>\n                                          <a *ngIf=\"forwardto_ivrrouting_9\" target=\"_blank\" routerLink=\"/ivrplan-edit/{{forwardto_ivrrouting_9[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Plan Edit</a>\n                                        </div>\n                                        <div *ngIf=\"i==8 && forward_10 == 'FORWARD_TO_IVRROUTING'\">\n                                          <!-- <select formControlName=\"forwardto_ivrrouting_10\" class=\"form-control\">\n                                            <option value=\"\">Select IVR Routing</option>\n                                            <option *ngFor=\"let name of allivrroutingplan;\" [value]=\"name.id\">\n                                                {{name.text}}\n                                            </option>\n                                          </select> -->\n                                          <angular2-multiselect [data]=\"allivrroutingplan\" [(ngModel)]=\"forwardto_ivrrouting_10\" formControlName=\"forwardto_ivrrouting_10\" [settings]=\n                                          \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select IVR Routing'}\">\n                                          </angular2-multiselect>\n                                          <a *ngIf=\"forwardto_ivrrouting_10\" target=\"_blank\" routerLink=\"/ivrplan-edit/{{forwardto_ivrrouting_10[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Plan Edit</a>\n                                        </div>   \n\n                                        <!-- <div *ngIf=\"i==0 && forward_2 == 'FORWARD_TO_CAMPAIGN'\">\n                                          <select formControlName=\"forwardto_campaign_2\" class=\"form-control\">\n                                            <option value=\"\">Select Campaign</option>\n                                            <option *ngFor=\"let name of campaigns;\" [value]=\"name.id\">\n                                                {{name.text}}\n                                            </option>\n                                          </select>\n                                        </div>\n                                        <div *ngIf=\"i==1 && forward_3 == 'FORWARD_TO_CAMPAIGN'\">\n                                          <select formControlName=\"forwardto_campaign_3\" class=\"form-control\">\n                                            <option value=\"\">Select Campaign</option>\n                                            <option *ngFor=\"let name of campaigns;\" [value]=\"name.id\">\n                                                {{name.text}}\n                                            </option>\n                                          </select>\n                                        </div>\n                                        <div *ngIf=\"i==2 && forward_4 == 'FORWARD_TO_CAMPAIGN'\">\n                                          <select formControlName=\"forwardto_campaign_4\" class=\"form-control\">\n                                            <option value=\"\">Select Campaign</option>\n                                            <option *ngFor=\"let name of campaigns;\" [value]=\"name.id\">\n                                                {{name.text}}\n                                            </option>\n                                          </select>\n                                        </div>\n                                        <div *ngIf=\"i==3 && forward_5 == 'FORWARD_TO_CAMPAIGN'\">\n                                          <select formControlName=\"forwardto_campaign_5\" class=\"form-control\" >\n                                            <option value=\"\">Select Campaign</option>\n                                            <option *ngFor=\"let name of campaigns;\" [value]=\"name.id\">\n                                                {{name.text}}\n                                            </option>\n                                          </select>\n                                        </div>\n                                        <div *ngIf=\"i==4 && forward_6 == 'FORWARD_TO_CAMPAIGN'\">\n                                          <select formControlName=\"forwardto_campaign_6\" class=\"form-control\">\n                                            <option value=\"\">Select Campaign</option>\n                                            <option *ngFor=\"let name of campaigns;\" [value]=\"name.id\">\n                                                {{name.text}}\n                                            </option>\n                                          </select>\n                                        </div>\n                                        <div *ngIf=\"i==5 && forward_7 == 'FORWARD_TO_CAMPAIGN'\">\n                                          <select formControlName=\"forwardto_campaign_7\" class=\"form-control\">\n                                            <option value=\"\">Select Campaign</option>\n                                            <option *ngFor=\"let name of campaigns;\" [value]=\"name.id\">\n                                                {{name.text}}\n                                            </option>\n                                          </select>\n                                        </div>\n                                        <div *ngIf=\"i==6 && forward_8 == 'FORWARD_TO_CAMPAIGN'\">\n                                          <select formControlName=\"forwardto_campaign_8\" class=\"form-control\">\n                                            <option value=\"\">Select Campaign</option>\n                                            <option *ngFor=\"let name of campaigns;\" [value]=\"name.id\">\n                                                {{name.text}}\n                                            </option>\n                                          </select>\n                                        </div>\n                                        <div *ngIf=\"i==7 && forward_9 == 'FORWARD_TO_CAMPAIGN'\">\n                                          <select formControlName=\"forwardto_campaign_9\" class=\"form-control\">\n                                            <option value=\"\">Select Campaign</option>\n                                            <option *ngFor=\"let name of campaigns;\" [value]=\"name.id\">\n                                                {{name.text}}\n                                            </option>\n                                          </select>\n                                        </div>\n                                        <div *ngIf=\"i==8 && forward_10 == 'FORWARD_TO_CAMPAIGN'\">\n                                          <select formControlName=\"forwardto_campaign_10\" class=\"form-control\">\n                                            <option value=\"\">Select Campaign</option>\n                                            <option *ngFor=\"let name of campaigns;\" [value]=\"name.id\">\n                                                {{name.text}}\n                                            </option>\n                                          </select>\n                                        </div>    -->\n                                    </div>\n                                   </div>\n                                 </td>\n                            </tr>\n                     </tbody>\n                 </table>\n           \n            </div>\n            <div class=\"card-footer text-right\">\n                  <button  class=\"btn btn-primary mr-1 btn-sm p-2\" type=\"submit\"><i class=\"fa fa-save\"></i> Update IVR Menu</button>\n                  <button style=\"margin-right: 4px;\" routerLink=\"/ivr-menu\" class=\"btn btn-primary btn-sm p-2\"><i class=\"fa fa-arrow-left\" aria-hidden=\"true\"></i>\n                    Back To IVR Menus</button>\n                </div>\n          </div>\n        </form>\n\n</div>\n";

/***/ }),

/***/ 20388:
/*!***********************************************************************!*\
  !*** ./src/app/modules/ivr-menus/ivr-menus.component.html?ngResource ***!
  \***********************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n\n      <div class=\"main-content\">\n\n        <section class=\"section\">\n          <div class=\"section-body\">\n            <div class=\"row\">\n              <div class=\"col-12\">\n                <div class=\"card\">\n                    <div class=\"row\">\n                        <div class=\"col-8\">\n                            <div class=\"card-header\">\n                            <h4>IVR Menus</h4></div>\n                        </div>\n                        <div class=\"col-4 text-right mt-2\">\n                            <div class=\"form-group\"  style=\"margin-right: 28px;padding: 3px;font-size: 14px;\">\n                               <button routerLink=\"/new-ivr-menu\" class=\"btn btn-primary daterange-btn icon-left btn-sm btn-icon p-2 mr-2\"><i class=\"fa fa-plus\"></i> New Menu\n                                </button>\n                                <!-- <button [disabled]=\"ischecked === '1'\" (click)=\"onDeleteSubmit()\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-2\"><i class=\"fas fa-file-export\"        ></i> Delete Selected\n                                </button> -->\n                              </div>\n                        </div>\n                    </div>\n\n                  <div class=\"card-body\">\n                    <div class=\"table-responsive\">\n                    <table #dataTable class=\"table table-striped dataTable no-footer row-border hover\">\n                        <thead>\n                          <tr>\n                            <!-- <th style=\"padding: 10px;\">\n                              <div class=\"custom-control custom-checkbox\" *ngIf=\"IVRMenus?.length != 0\">\n                              <input type=\"checkbox\" class=\"custom-control-input\" id=\"customCheck1\" (change)=\"checkalldelete($event)\" (click)=\"deleteselected($event)\">\n                              <label class=\"custom-control-label\" for=\"customCheck1\"></label>\n                              </div>\n                          </th> -->\n                            <th>Name</th>\n                            <th>Buyer</th>\n                            <th>Created Date</th>\n                            <th>Action</th>\n                          </tr>\n                        </thead>\n                        <tbody *ngIf=\"IVRMenus?.length != 0\">\n                            <tr *ngFor=\"let IVRMenu of IVRMenus\">\n                                <!-- <td>\n                                    <div class=\"custom-control custom-checkbox\">\n                                    <input type=\"checkbox\" (click)=\"deleteselected($event)\" class=\"custom-control-input\" id=\"customCheck_{{IVRMenu.uuid}}\"  [checked]=\"IVRMenu.selected\" [value]=\"IVRMenu.id\" >\n                                    <label class=\"custom-control-label\" for=\"customCheck_{{IVRMenu.uuid}}\"></label>\n                                    </div>\n                                </td> -->\n                                <td><a routerLink=\"/edit-ivr/{{ IVRMenu.uuid }}\" class=\"text-white actionedit\">{{ IVRMenu.name }}</a></td>\n                                <td>{{ IVRMenu.buyer }}</td>\n                                <td>{{ IVRMenu.created_at }}</td>\n                                <!-- <td>\n                                  <button (click)=\"Clone(IVRMenu.uuid)\" class=\"btn btn-primary btn-sm actionedit\"><i class=\"far fa-clone\"></i></button>&nbsp;\n                                  <a routerLink=\"/edit-ivr/{{ IVRMenu.uuid }}\" class=\"btn btn-primary btn-sm actionedit\"><i class=\"far fa-edit\"></i></a>&nbsp;<button (click)=\"Delete((IVRMenu.uuid))\" class=\"btn btn-danger btn-sm actiondelete\"><i class=\"fas fa-trash\"></i></button>\n                                </td> -->\n                                <td style=\"cursor:pointer;\">\n                                  <i style=\"font-size: 12px;\" placement=\"bottom\" ngbTooltip=\"Duplicate Target\" (click)=\"Clone(IVRMenu.uuid)\" class=\"far fa-clone\"></i>&nbsp;&nbsp;\n                                  <a style=\"font-size: 12px;\" placement=\"bottom\" ngbTooltip=\"Edit Target\" routerLink=\"/edit-ivr/{{ IVRMenu.uuid }}\" class=\"actionedit\"><i class=\"far fa-edit\"></i></a>&nbsp;&nbsp;\n                                  <i style=\"font-size: 12px;\" placement=\"bottom\" ngbTooltip=\"Delete Target\" (click)=\"Delete((IVRMenu.uuid))\" class=\"fas fa-trash\"></i>\n                                </td>\n                            </tr>\n                        </tbody>\n                        <tbody *ngIf=\"IVRMenus?.length == 0\">\n                          <tr>\n                            <td colspan=\"8\" class=\"no-data-available\">No data Available!</td>\n                          </tr>\n                        <tbody>\n                      </table>\n                    </div>\n                  </div>\n                </div>\n              </div>\n            </div>\n          </div>\n        </section>\n\n      </div>\n";

/***/ }),

/***/ 48952:
/*!*************************************************************************************************!*\
  !*** ./src/app/modules/ivr-menus/ivr-routing-plans/add-plan/add-plan.component.html?ngResource ***!
  \*************************************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n\n  <!-- Edit Routing Modal -->\n  <div class=\"modal fade\" id=\"editRouting\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n  aria-hidden=\"true\">\n  <div class=\"modal-dialog\" role=\"document\">\n    <div class=\"modal-content\">\n      <div class=\"modal-header\">\n        <h5 class=\"modal-title\" id=\"formModal\">Edit Routing Plan</h5>\n        <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n          <span aria-hidden=\"true\">&times;</span>\n        </button>\n      </div>\n      <div class=\"modal-body\">\n        <form id=\"addLabel\" [formGroup]=\"editRoutingForm\" (ngSubmit)=\"oneditRoutingSubmit()\">\n            <fieldset class=\"scheduler-border\">\n               <legend class=\"scheduler-border\">Update Routing Plan</legend>\n                 <div class=\"control-group mt-2\">\n                   <input type=\"hidden\" name=\"\" formControlName=\"uuid\">\n                  <label class=\"control-label input-label\" for=\"startTime\">Pririty :</label>\n                  <input type=\"number\" formControlName=\"priority\" class=\"form-control\"/>\n                </div>\n\n                <div class=\"control-group mt-2\">\n                  <label class=\"control-label input-label\" for=\"startTime\">Weight :</label>\n                  <input type=\"number\" formControlName=\"weight\" class=\"form-control\"/>\n                </div>\n\n                 <div class=\"control-group mt-2\">\n                     <label class=\"control-label input-label\">Conversation Revenue :</label>\n                     <div class=\"input-group\">\n                      <div class=\"input-group-prepend\">\n                        <div class=\"input-group-text\" id=\"btnGroupAddon\">$</div>\n                      </div>\n                      <input type=\"text\" formControlName=\"conversation_revenue\" class=\"form-control\" placeholder=\"Enter Conversation Revenue\" aria-label=\"Enter Conversation Revenue\" aria-describedby=\"btnGroupAddon\" [ngClass]=\"{ 'is-invalid': submitted && f.conversation_revenue.errors }\">\n                      <div *ngIf=\"submitted && f.conversation_revenue.errors\" class=\"invalid-feedback\">\n                        <div *ngIf=\"f.conversation_revenue.errors.required\">Conversation Revenue is required</div>\n                    </div>\n                    </div>\n                 </div>\n\n                 <div class=\"control-group mt-2\">\n                     <label class=\"control-label input-label\" for=\"startTime\">Conversation Event :</label>\n                     <select formControlName=\"conversation_event\" class=\"form-control\"  [ngClass]=\"{ 'is-invalid': submitted && f.conversation_event.errors }\">\n                      <option value=\"0\">Call Length</option>\n                      <option value=\"1\">Call Successfully Connected</option>\n                    </select>\n                     <div *ngIf=\"submitted && f.conversation_event.errors\" class=\"invalid-feedback\">\n                         <div *ngIf=\"f.conversation_event.errors.required\">Conversation Event is required</div>\n                    </div>\n                 </div>\n\n                   <div class=\"control-group mt-2\" *ngIf=\"this.editRoutingForm.get('conversation_event').value==0\">\n                     <label class=\"control-label input-label\" for=\"startTime\">Enter Seconds :</label>\n                     <input type=\"text\" formControlName=\"conversation_seconds\" class=\"form-control\" type=\"text\" placeholder=\"Enter Seconds\" />\n\n                   </div>\n\n\n                   <div class=\"control-group mt-2\">\n                    <label>Restrict Duplicate</label>\n                    <select #restrictdup formControlName=\"restrictdup\" name=\"restrictdup\" id=\"restrictdup\" class=\"form-control\">\n                      <option value=\"0\">Buyer Settings (Do not Restrict)</option>\n                      <option value=\"1\">Do not Restrict</option>\n                      <option value=\"2\">By Campaign - Individual Target</option>\n                    </select>\n                 </div>\n                 <div *ngIf=\"restrictdup.value==2\">\n                 <div class=\"control-group mt-2\">\n                    <label>Restrict After</label>\n                    <select formControlName=\"restrictafter\" name=\"restrictafter\" id=\"restrictafter\" class=\"form-control\">\n                      <option value=\"0\">Converted</option>\n                      <option value=\"1\">Connected</option>\n                    </select>\n                 </div>\n                  <div class=\"control-group\">\n                      <label class=\"control-label input-label\" for=\"startTime\">Duration:</label>\n                      <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                      <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': settingToggleDurationvalue==0}\" (click)=\"settingToggleDuration(0)\">\n                            <input class=\"form-check-input\" name=\"settingToggleDuration\" formControlName=\"settingToggleDuration\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                            Always\n                      </label>\n                      <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': settingToggleDurationvalue==1}\" (click)=\"settingToggleDuration(1)\">\n                        <input class=\"form-check-input\" name=\"settingToggleDuration\" formControlName=\"settingToggleDuration\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                        Time Limit\n                      </label>\n                        </div>\n                 </div>\n                  <br>\n                  <div class=\"control-group row mt-2\" *ngIf=\"this.editRoutingForm.get('settingToggleDurationval').value==1\">\n                    <div class=\"col-3\"><input  formControlName=\"days\" style=\"width: 80px;\" type=\"number\"  class=\"form-control formcontrol\" name=\"\" id=\"\"></div>\n                    <div class=\"col-2 mt-2\"><span>Days</span></div>\n                  </div>\n                  </div>\n\n               </fieldset>\n\n          <div class=\"modal-footer\" style=\"padding: 0;\">\n           <!-- !addLabelForm.valid || -->\n             <button (click)=\"closeroutingModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Edit Routing Plan</button>\n             <button data-dismiss=\"modal\" aria-label=\"Close\" type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\">Close</button>\n            </div>\n        </form>\n\n  </div>\n  </div>\n  </div>\n  </div>\n\n  <div class=\"main-content\">\n      <section class=\"section\">\n        <div class=\"section-body\">\n          <div class=\"row\">\n            <div class=\"col-12 col-md-12 col-lg-12\">\n              <form [formGroup]=\"editForm\" (ngSubmit)=\"onSubmit()\">\n              <div class=\"card\" >\n                <div class=\"card-header\">\n                  <h4> Setup Your IVR Routing Plan</h4>\n                </div>\n                <div class=\"card-body\" >\n\n            <fieldset class=\"scheduler-border\">\n            <legend class=\"scheduler-border\">Setup Your Routing Plan</legend>\n            <section>\n              <strong>Name your Routing Plan.</strong>\n              <hr>\n              <div class=\"form-group row\">\n                <div class=\"col-sm-2\"></div>\n                <label class=\"col-sm-1 col-form-label\">Name</label>\n                <div class=\"col-sm-5\" *ngIf=\"nameadded==0\">\n                  <input formControlName=\"name\" type=\"text\" class=\"form-control\"  [ngClass]=\"{ 'is-invalid': Submitted && editFormcontrol.name.errors }\">\n                  <div *ngIf=\"Submitted && editFormcontrol.name.errors\" class=\"invalid-feedback\">\n                    <div *ngIf=\"editFormcontrol.name.errors.required\">Name is required</div>\n                </div>\n                </div>\n                <div class=\"col-sm-5\" *ngIf=\"nameadded==1\">\n                  <input formControlName=\"name\" type=\"text\" class=\"form-control\"  value=\"namvalue\" readonly>\n                </div>\n                <div class=\"col-sm-2\" *ngIf=\"nameadded==0\">\n                  <button class=\"btn btn-primary mr-2 btn-sm p-2\" type=\"submit\">Submit</button>\n                </div>\n              </div>\n            </section>\n            </fieldset>\n\n          <fieldset class=\"scheduler-border\">\n           <legend class=\"scheduler-border\">Target</legend>\n           <section>\n\n          <div class=\"row\">\n            <div class=\"col-md-6\">\n              <strong>Forward your calls to buyers, call centers, or anywhere you'd like them to go.</strong><hr>\n\n              <table #dataTableTarget class=\"table table-striped  dataTable no-footer row-border hover\" style=\"width: 100%;\">\n              <thead>\n                <tr>\n                  <th>Name</th>\n                  <th>Destination</th>\n                  <th>Add</th>\n                </tr>\n              </thead>\n              <tbody *ngIf=\"allTargets?.length != 0\">\n                  <tr *ngFor=\"let data of allTargets\">\n                       <td>{{data.name}}</td>\n                       <td *ngIf=\"data.valtype =='IVR Menu'\"><a class=\"text-white\" routerLink=\"/edit-ivr/{{ data.ivrmenu_uuid }}\" >{{data.valtype}} - {{data.typeval}}</a></td>\n                       <td *ngIf=\"data.valtype !='IVR Menu'\">{{data.valtype}} - {{data.typeval}}</td>\n                       <td *ngIf=\"data.isavailinpayout==0\"><div (click)=\"setRouting(data.uuid)\" class=\"btn btn-primary btn-sm actionedit\"><i class=\"fa fa-arrow-right\"></i></div>\n                      </td>\n                       <td *ngIf=\"data.isavailinpayout!=0\">\n                         <span class=\"badge badge-success\">Added</span>\n                      </td>\n                  </tr>\n              </tbody>\n              <tbody *ngIf=\"allTargets?.length == 0\">\n                <tr>\n                  <td colspan=\"5\" class=\"no-data-available\">No data Available!</td>\n                </tr>\n              <tbody>\n            </table>\n          </div>\n          <div class=\"col-md-6\">\n            <strong>Routing Plan</strong><hr>\n            <table #dataTableRouting class=\"table table-striped table-responsive dataTable no-footer row-border hover\" style=\"width: 100%;\">\n            <thead>\n              <tr>\n                <th>Priority</th>\n                <th>Name</th>\n                <th>Destination</th>\n                <th>Revenue</th>\n                <th>Status</th>\n                <th>Action</th>\n              </tr>\n            </thead>\n            <tbody *ngIf=\"allRoutingPlan?.length != 0\">\n                <tr *ngFor=\"let data of allRoutingPlan;let i = index;\">\n                  <td>{{data.priority}}</td>\n                  <td *ngIf=\"data.destinationtype ==1\"><a class=\"text-white\" routerLink=\"/edit-ivr/{{ data.destinationuuid }}\" >\n                    {{data.name}}</a></td>\n                  <td *ngIf=\"data.destinationtype !=1\">{{data.name}}</td>\n\n                  <td *ngIf=\"data.destinationtype ==1\">IVR Menu -<a class=\"text-white\" routerLink=\"/edit-ivr/{{ data.destinationuuid }}\" >\n                    {{data.destination}}</a></td>\n                  <td *ngIf=\"data.destinationtype ==0\">Number - {{data.destination}}</td>\n                  <td *ngIf=\"data.destinationtype ==2\">SIP - {{data.destination}}</td>\n\n                  <td>{{data.revenue}}</td>\n                  <td>\n                    <div *ngIf=\"data.status==1\" class=\"fa fa-circle text-success\"></div>\n                    <div *ngIf=\"data.status==0\" class=\"fa fa-circle text-danger\"></div>\n                  </td>\n                  <td><div (click) =\"editRoutingdata(data.uuid,data.priority,data.weight,data.revenuevalue,data.type,data.seconds,data.restrictdup,data.restrictafter,data.settingToggleDurationval,data.days)\" data-toggle=\"modal\" data-target=\"#editRouting\" class=\"btn btn-primary btn-sm actionedit\"><i class=\"fa fa-edit\"></i></div>&nbsp;<div (click)=\"DeleteRoutingPlan((data.uuid))\" class=\"btn btn-danger btn-sm actiondelete\"><i class=\"fas fa-trash\"></i></div>\n                 </td>\n                </tr>\n            </tbody>\n            <tbody *ngIf=\"allRoutingPlan?.length == 0\">\n              <tr>\n                <td colspan=\"6\" class=\"no-data-available\">No data Available!</td>\n              </tr>\n            <tbody>\n          </table>\n          </div>\n        </div>\n           </section>\n           </fieldset>\n\n           <br>\n                <!-- <button class=\"btn btn-primary mr-2 btn-sm p-2\" type=\"submit\">Submit</button> -->\n                <button style=\"margin-right: 4px;\" routerLink=\"/ivr-routing-plans\" class=\"btn btn-primary  btn-sm p-2\">Back To All Plans</button>\n\n                </div>\n              </div>\n            </form>\n\n  </div>\n";

/***/ }),

/***/ 76799:
/*!***************************************************************************************************!*\
  !*** ./src/app/modules/ivr-menus/ivr-routing-plans/edit-plan/edit-plan.component.html?ngResource ***!
  \***************************************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n\n  <!-- Edit Routing Modal -->\n  <div class=\"modal fade\" id=\"editRouting\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n  aria-hidden=\"true\">\n  <div class=\"modal-dialog\" role=\"document\">\n    <div class=\"modal-content\">\n      <div class=\"modal-header\">\n        <h5 class=\"modal-title\" id=\"formModal\">Edit Routing Plan</h5>\n        <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n          <span aria-hidden=\"true\">&times;</span>\n        </button>\n      </div>\n      <div class=\"modal-body\">\n        <form id=\"addLabel\" [formGroup]=\"editRoutingForm\" (ngSubmit)=\"oneditRoutingSubmit()\">\n            <fieldset class=\"scheduler-border\">\n               <legend class=\"scheduler-border\">Update Routing Plan</legend>\n                 <div class=\"control-group mt-2\">\n                   <input type=\"hidden\" name=\"\" formControlName=\"uuid\">\n                  <label class=\"control-label input-label\" for=\"startTime\">Pririty :</label>\n                  <input type=\"number\" formControlName=\"priority\" class=\"form-control\"/>\n                </div>\n\n                <div class=\"control-group mt-2\">\n                  <label class=\"control-label input-label\" for=\"startTime\">Weight :</label>\n                  <input type=\"number\" formControlName=\"weight\" class=\"form-control\"/>\n                </div>\n\n                 <div class=\"control-group mt-2\">\n                     <label class=\"control-label input-label\">Conversation Revenue :</label>\n                     <div class=\"input-group\">\n                      <div class=\"input-group-prepend\">\n                        <div class=\"input-group-text\" id=\"btnGroupAddon\">$</div>\n                      </div>\n                      <input type=\"text\" formControlName=\"conversation_revenue\" class=\"form-control\" placeholder=\"Enter Conversation Revenue\" aria-label=\"Enter Conversation Revenue\" aria-describedby=\"btnGroupAddon\" [ngClass]=\"{ 'is-invalid': submitted && f.conversation_revenue.errors }\">\n                      <div *ngIf=\"submitted && f.conversation_revenue.errors\" class=\"invalid-feedback\">\n                        <div *ngIf=\"f.conversation_revenue.errors.required\">Conversation Revenue is required</div>\n                    </div>\n                    </div>\n                 </div>\n\n                 <div class=\"control-group mt-2\">\n                     <label class=\"control-label input-label\" for=\"startTime\">Conversation Event :</label>\n                     <select formControlName=\"conversation_event\" class=\"form-control\"  [ngClass]=\"{ 'is-invalid': submitted && f.conversation_event.errors }\">\n                      <option value=\"0\">Call Length</option>\n                      <option value=\"1\">Call Successfully Connected</option>\n                    </select>\n                     <div *ngIf=\"submitted && f.conversation_event.errors\" class=\"invalid-feedback\">\n                         <div *ngIf=\"f.conversation_event.errors.required\">Conversation Event is required</div>\n                    </div>\n                 </div>\n\n                   <div class=\"control-group mt-2\" *ngIf=\"this.editRoutingForm.get('conversation_event').value==0\">\n                     <label class=\"control-label input-label\" for=\"startTime\">Enter Seconds :</label>\n                     <input type=\"text\" formControlName=\"conversation_seconds\" class=\"form-control\" type=\"text\" placeholder=\"Enter Seconds\" />\n\n                   </div>\n\n\n                   <div class=\"control-group mt-2\">\n                    <label>Restrict Duplicate</label>\n                    <select #restrictdup formControlName=\"restrictdup\" name=\"restrictdup\" id=\"restrictdup\" class=\"form-control\">\n                      <option value=\"0\">Buyer Settings (Do not Restrict)</option>\n                      <option value=\"1\">Do not Restrict</option>\n                      <option value=\"2\">By Campaign - Individual Target</option>\n                    </select>\n                 </div>\n                 <div *ngIf=\"restrictdup.value==2\">\n                 <div class=\"control-group mt-2\">\n                    <label>Restrict After</label>\n                    <select formControlName=\"restrictafter\" name=\"restrictafter\" id=\"restrictafter\" class=\"form-control\">\n                      <option value=\"0\">Converted</option>\n                      <option value=\"1\">Connected</option>\n                    </select>\n                 </div>\n                 <div class=\"control-group\">\n                  <label class=\"control-label input-label\" for=\"startTime\">Duration:</label>\n                  <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                  <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': getsettingToggleDurationval==0}\" (click)=\"settingToggleDuration(0)\">\n                        <input class=\"form-check-input\" name=\"settingToggleDuration\" formControlName=\"settingToggleDuration\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                        Always\n                  </label>\n                  <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': getsettingToggleDurationval==1}\" (click)=\"settingToggleDuration(1)\">\n                    <input class=\"form-check-input\" name=\"settingToggleDuration\" formControlName=\"settingToggleDuration\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                    Time Limit\n                  </label>\n                    </div>\n             </div>\n              <br>\n              <div class=\"control-group row mt-2\" *ngIf=\"this.getsettingToggleDurationval==1\">\n                <div class=\"col-3\"><input  formControlName=\"days\" style=\"width: 80px;\" type=\"number\"  class=\"form-control formcontrol\" name=\"\" id=\"\"></div>\n                <div class=\"col-2 mt-2\"><span>Days</span></div>\n              </div>\n              </div>\n\n\n               </fieldset>\n\n          <div class=\"modal-footer\" style=\"padding: 0;\">\n           <!-- !addLabelForm.valid || -->\n             <button (click)=\"closeroutingModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Edit Routing Plan</button>\n             <button data-dismiss=\"modal\" aria-label=\"Close\" type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\">Close</button>\n            </div>\n        </form>\n\n  </div>\n  </div>\n  </div>\n  </div>\n\n  <div class=\"main-content\">\n      <section class=\"section\">\n        <div class=\"section-body\">\n          <div class=\"row\">\n            <div class=\"col-12 col-md-12 col-lg-12\">\n              <form [formGroup]=\"editForm\" (ngSubmit)=\"onSubmit()\">\n              <div class=\"card\" >\n                <div class=\"card-header\">\n                  <h4> Setup Your IVR Routing Plan</h4>\n                </div>\n                <div class=\"card-body\" >\n\n            <fieldset class=\"scheduler-border\">\n            <legend class=\"scheduler-border\">Setup Your Routing Plan</legend>\n            <section>\n              <strong>Name your Routing Plan.</strong>\n              <hr>\n              <div class=\"form-group row\">\n                <div class=\"col-sm-2\"></div>\n                <label class=\"col-sm-1 col-form-label\">Name</label>\n                <div class=\"col-sm-5\" *ngIf=\"nameadded==0\">\n                  <input formControlName=\"name\" type=\"text\" class=\"form-control\"  [ngClass]=\"{ 'is-invalid': Submitted && editFormcontrol.name.errors }\">\n                  <div *ngIf=\"Submitted && editFormcontrol.name.errors\" class=\"invalid-feedback\">\n                    <div *ngIf=\"editFormcontrol.name.errors.required\">Name is required</div>\n                </div>\n                </div>\n                <div class=\"col-sm-5\" *ngIf=\"nameadded==1\">\n                  <input formControlName=\"name\" type=\"text\" class=\"form-control\"  value=\"namvalue\" readonly>\n                </div>\n                <div class=\"col-sm-2\" *ngIf=\"nameadded==0\">\n                  <button class=\"btn btn-primary mr-2 btn-sm p-2\" type=\"submit\">Update</button>\n                </div>\n              </div>\n            </section>\n            </fieldset>\n\n          <fieldset class=\"scheduler-border\">\n           <legend class=\"scheduler-border\">Target</legend>\n           <section>\n\n          <div class=\"row\">\n            <div class=\"col-md-6 table-responsive\">\n              <strong>Forward your calls to buyers, call centers, or anywhere you'd like them to go.</strong><hr>\n\n              <table #dataTableTarget class=\"table table-striped  dataTable no-footer row-border hover\" style=\"width: 100%;\">\n              <thead>\n                <tr>\n                  <th>Name</th>\n                  <th>Destination</th>\n                  <th>Add</th>\n                </tr>\n              </thead>\n              <tbody *ngIf=\"allTargets?.length != 0\">\n                  <tr *ngFor=\"let data of allTargets\">\n                       <td>{{data.name}}</td>\n                       <td *ngIf=\"data.valtype =='IVR Menu'\"><a class=\"text-white\" routerLink=\"/edit-ivr/{{ data.ivrmenu_uuid }}\" >{{data.valtype}} - {{data.typeval}}</a></td>\n                       <td *ngIf=\"data.valtype !='IVR Menu'\">{{data.valtype}} - {{data.typeval}}</td>\n                       <td *ngIf=\"data.isavailinpayout==0\"><div (click)=\"setRouting(data.uuid)\" class=\"btn btn-primary btn-sm actionedit\"><i class=\"fa fa-arrow-right\"></i></div>\n                      </td>\n                       <td *ngIf=\"data.isavailinpayout!=0\">\n                         <span class=\"badge badge-success\">Added</span>\n                      </td>\n                  </tr>\n              </tbody>\n              <tbody *ngIf=\"allTargets?.length == 0\">\n                <tr>\n                  <td colspan=\"5\" class=\"no-data-available\">No data Available!</td>\n                </tr>\n              <tbody>\n            </table>\n          </div>\n          <div class=\"col-md-6\">\n            <strong>Routing Plan</strong><hr>\n            <div class=\"table-responsive\">\n            <table #dataTableRouting class=\"table table-striped  dataTable no-footer row-border hover\" style=\"width: 100%;\">\n            <thead>\n              <tr>\n                <th>Priority</th>\n                <th>Name</th>\n                <th>Destination</th>\n                <th>Revenue</th>\n                <th>Status</th>\n                <th>Action</th>\n              </tr>\n            </thead>\n            <tbody *ngIf=\"allRoutingPlan?.length != 0\">\n                <tr *ngFor=\"let data of allRoutingPlan;let i = index;\">\n                  <td>{{data.priority}}</td>\n                  <td *ngIf=\"data.destinationtype ==1\"><a class=\"text-white\" routerLink=\"/edit-ivr/{{ data.destinationuuid }}\" >\n                    {{data.name}}</a></td>\n                  <td *ngIf=\"data.destinationtype !=1\">{{data.name}}</td>\n\n                  <td *ngIf=\"data.destinationtype ==1\">IVR Menu -<a class=\"text-white\" routerLink=\"/edit-ivr/{{ data.destinationuuid }}\" >\n                    {{data.destination}}</a></td>\n                  <td *ngIf=\"data.destinationtype ==0\">Number - {{data.destination}}</td>\n                  <td *ngIf=\"data.destinationtype ==2\">SIP - {{data.destination}}</td>\n\n                  <td>{{data.revenue}}</td>\n                  <td>\n                    <div *ngIf=\"data.status==1\" class=\"fa fa-circle text-success\"></div>\n                    <div *ngIf=\"data.status==0\" class=\"fa fa-circle text-danger\"></div>\n                  </td>\n                  <td><div (click) =\"editRoutingdata(data.uuid,data.priority,data.weight,data.revenuevalue,data.type,data.seconds,data.restrictdup,data.restrictafter,data.settingToggleDurationval,data.days)\" data-toggle=\"modal\" data-target=\"#editRouting\" class=\"btn btn-primary btn-sm actionedit\"><i class=\"fa fa-edit\"></i></div>&nbsp;<div (click)=\"DeleteRoutingPlan((data.uuid))\" class=\"btn btn-danger btn-sm actiondelete\"><i class=\"fas fa-trash\"></i></div>\n                 </td>\n                </tr>\n            </tbody>\n            <tbody *ngIf=\"allRoutingPlan?.length == 0\">\n              <tr>\n                <td colspan=\"6\" class=\"no-data-available\">No data Available!</td>\n              </tr>\n            <tbody>\n            </table>\n          </div>\n          </div>\n        </div>\n           </section>\n           </fieldset>\n\n           <br>\n                <!-- <button class=\"btn btn-primary mr-2 btn-sm p-2\" type=\"submit\">Submit</button> -->\n                <button style=\"margin-right: 4px;\" routerLink=\"/ivr-routing-plans\" class=\"btn btn-primary  btn-sm p-2\">Back To All Plans</button>\n\n                </div>\n              </div>\n            </form>\n\n  </div>\n";

/***/ }),

/***/ 74437:
/*!*************************************************************************************************!*\
  !*** ./src/app/modules/ivr-menus/ivr-routing-plans/ivr-routing-plans.component.html?ngResource ***!
  \*************************************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n\n  <div class=\"main-content\">\n    <section class=\"section\">\n      <div class=\"section-body\">\n        <div class=\"row\">\n          <div class=\"col-12\">\n            <div class=\"card\">\n                <div class=\"row\">\n                    <div class=\"col-3\">\n                        <div class=\"card-header\">\n                        <h4 class=\"text-white\"> Manage Routing Plans\n                        </h4></div>\n                    </div>\n                    <div class=\"col-9 text-right mt-2\">\n                        <div class=\"form-group\"  style=\"margin-right: 28px;padding: 3px;font-size: 14px;\">\n                          <a [routerLink]=\"['/ivrplan-add']\" routerLinkActive=\"router-link-active\"  class=\"btn btn-primary daterange-btn icon-left btn-sm btn-icon mr-2 p-2\"><i class=\"fa fa-plus\"></i> Create Routing Plan\n                          </a>\n                          </div>\n                    </div>\n\n                </div>\n\n              <div class=\"card-body\">\n                <div class=\"table-responsive\">\n                <table #dataTable class=\"table table-striped dataTable no-footer row-border hover\" style=\"width: 100%;\">\n                    <thead>\n                      <tr>\n                        <th>Name</th>\n                        <th>Created At</th>\n                        <th>Action</th>\n                      </tr>\n                    </thead>\n                    <tbody *ngIf=\"numbers?.length != 0\">\n                        <tr *ngFor=\"let data of numbers\">\n                            <td><a href=\"#\" routerLink=\"/ivrplan-edit/{{data.uuid}}\" routerLinkActive=\"router-link-active\"  class=\"text-white actionedit\">{{ data.name }}</a></td>\n                            <td>{{ data.created_at }}</td>\n                            <td style=\"cursor:pointer;\" class=\"d-flex\">\n                              <i style=\"font-size: 12px;\" placement=\"bottom\" ngbTooltip=\"Duplicate Routing Plan\" (click)=\"Clone(data.uuid)\" class=\"mt-1 far fa-clone\"></i>&nbsp;&nbsp;\n                              <a href=\"#\" placement=\"bottom\" ngbTooltip=\"Edit Routing Plan\" routerLink=\"/ivrplan-edit/{{data.uuid}}\" routerLinkActive=\"router-link-active\"  class=\"actionedit\"><i class=\"far fa-edit\"></i></a>&nbsp;&nbsp;&nbsp;<div placement=\"bottom\" ngbTooltip=\"Delete Routing Plan\" (click)=\"Delete((data.uuid))\" class=\"actiondelete\"><i class=\"fas fa-trash\"></i></div>\n                            </td>\n                        </tr>\n                    </tbody>\n                    <tbody *ngIf=\"numbers?.length == 0\">\n                      <tr>\n                        <td colspan=\"8\" class=\"no-data-available\">No data Available!</td>\n                      </tr>\n                    <tbody>\n                  </table>\n                </div>\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n    </section>\n\n  </div>\n";

/***/ }),

/***/ 69822:
/*!*******************************************************************************!*\
  !*** ./src/app/modules/label/label-view/label-view.component.html?ngResource ***!
  \*******************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n\n  <div class=\"main-content\">\n    <section class=\"section\">\n      <div class=\"section-body\">\n        <div class=\"row\">\n          <div class=\"col-12\">\n            <div class=\"card\">\n                <div class=\"row\" style=\"margin-top: 20px;\n                \">\n                    <div class=\"col-3\">\n                        <div class=\"card-header\">\n                        <h4>Number Data</h4></div>\n                    </div>\n                    <div class=\"col-9 text-right mt-2\">\n                        <div class=\"form-group\"  style=\"margin-right: 28px;padding: 3px;font-size: 14px;\">\n                           <button (click)=\"exportdata()\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-1\"><i class=\"fas fa-file-export\"></i> Export\n                          </button>\n                          <button [disabled]=\"ischecked === '1'\" (click)=\"onDeleteSubmit()\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-2\"><i class=\"fas fa-file-export\"        ></i> Delete Selected\n                          </button>\n                          </div>\n                    </div>\n\n                </div>\n\n              <div class=\"card-body\">\n                <div class=\"table-responsive\">\n                <table #dataTable class=\"table table-striped dataTable no-footer row-border hover\" style=\"width: 100%;\">\n                    <thead>\n                      <tr>\n                        <th style=\"padding: 10px;\">\n                          <div class=\"custom-control custom-checkbox\" *ngIf=\"numbers?.length != 0\">\n                          <input type=\"checkbox\" class=\"custom-control-input\" id=\"customCheck1\" (change)=\"checkalldelete($event)\" (click)=\"deleteselected($event)\">\n                          <label class=\"custom-control-label\" for=\"customCheck1\"></label>\n                          </div>\n                        </th>\n                        <th>Number</th>\n                        <th>Campaign</th>\n                        <th>Publisher</th>\n                        <th>Status</th>\n                        <th>Associated Label</th>\n                        <th>Allocated</th>\n                        <th>Action</th>\n                      </tr>\n                    </thead>\n                    <tbody *ngIf=\"numbers?.length != 0\">\n                        <tr *ngFor=\"let number of numbers\">\n                            <td>\n                                <div class=\"custom-control custom-checkbox\">\n                                <input type=\"checkbox\" (click)=\"deleteselected($event)\" class=\"custom-control-input\" id=\"customCheck_{{number.uuid}}\"  [checked]=\"number.selected\" [value]=\"number.id\" >\n                                <label class=\"custom-control-label\" for=\"customCheck_{{number.uuid}}\"></label>\n                                </div>\n                            </td>\n                            <td>{{ number.number }}</td>\n                            <td><a routerLink=\"/edit-campaign/{{number.campaign_uuid}}\"  routerLinkActive=\"router-link-active\">{{ number.campaign }}</a></td>\n                            <td>{{ number.publisher }}</td>\n                            <td *ngIf=\"number.status==1\">\n                              <span class=\"badge badge-success\">Enabled</span>\n                            </td>\n                            <td *ngIf=\"number.status==0\">\n                              <span class=\"badge badge-danger p-1\">Disabled</span>\n                            </td>\n                            <td>\n                              <span *ngFor=\"let assosciated_label of number.assosciated_labels?.split(',')\">\n                                  <span class=\"badge badge-primary p-1 ml-1\">{{assosciated_label }}</span><br>\n                              </span>\n                            </td>\n\n                            <td>{{ number.created_at }}</td>\n                            <td>\n                              <!-- <a href=\"#\" (click)=\"editdata(number.uuid,number.prefix,number.number_type,number.number,number.country,number.publisher_uuid,number.campaign_uuid)\"  data-toggle=\"modal\" data-target=\"#editModel\" class=\"btn btn-primary btn-sm actionedit\"><i class=\"far fa-edit\"></i></a>&nbsp; -->\n                              <button (click)=\"Delete((number.uuid))\" class=\"btn btn-danger btn-sm actiondelete\"><i class=\"fas fa-trash\"></i></button></td>\n                        </tr>\n                    </tbody>\n                    <tbody *ngIf=\"numbers?.length == 0\">\n                      <tr>\n                        <td colspan=\"8\" class=\"no-data-available\">No data Available!</td>\n                      </tr>\n                    <tbody>\n                  </table>\n                </div>\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n    </section>\n\n  </div>\n";

/***/ }),

/***/ 31994:
/*!***************************************************************!*\
  !*** ./src/app/modules/label/label.component.html?ngResource ***!
  \***************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n\n<!-- Add Label Modal -->\n<div class=\"modal fade\" id=\"addLabels\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n aria-hidden=\"true\">\n <div class=\"modal-dialog\" role=\"document\">\n   <div class=\"modal-content\">\n     <div class=\"modal-header\">\n       <h5 class=\"modal-title\" id=\"formModal\">Create Label</h5>\n       <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n         <span aria-hidden=\"true\">&times;</span>\n       </button>\n     </div>\n     <div class=\"modal-body\">\n       <form id=\"addLabel\" [formGroup]=\"addLabelForm\" (ngSubmit)=\"onLabelSubmit()\">\n         <div class=\"row\">\n           <div class=\"col-md-12\">\n\n        <!-- <fieldset class=\"scheduler-border\">\n          <legend class=\"scheduler-border\">Label Settings</legend> -->\n         <div class=\"form-group\">\n             <label>Label Name</label>\n             <input formControlName=\"name\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': LabelSubmitted && labelcontrol.name.errors }\" (input)=\"validatename()\">\n             <div *ngIf=\"LabelSubmitted && labelcontrol.name.errors\" class=\"invalid-feedback\">\n                 <div *ngIf=\"labelcontrol.name.errors.required\">Name is required</div>\n             </div>\n             <div *ngIf=\"isName == 'success'  && isName != ''\" style=\"color:green;\">\n                Name Is Available\n              </div>\n               <div *ngIf=\"isName == 'fail' && isName != ''\" style=\"color:red;\">\n                Name Is Not Available\n              </div>\n          </div>\n\n           <div class=\"form-group\">\n             <label  class=\"d-block\">Notes:</label>\n             <textarea formControlName=\"notes\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': LabelSubmitted && labelcontrol.notes.errors }\"></textarea>\n             <div *ngIf=\"LabelSubmitted && labelcontrol.notes.errors\" class=\"invalid-feedback\">\n                <div *ngIf=\"labelcontrol.notes.errors.required\">Notes is required</div>\n            </div>\n           </div>\n\n           <!-- </fieldset> -->\n\n          </div>\n          <!-- <div class=\"col-md-6\"> -->\n          <!-- <fieldset class=\"scheduler-border\">\n            <legend class=\"scheduler-border\">Conversation Setting</legend>\n            <div class=\"control-group\">\n                <label class=\"control-label input-label\" for=\"startTime\">Conversation Revenue :</label>\n                <div class=\"input-group\">\n                  <div class=\"input-group-prepend\">\n                    <div class=\"input-group-text\" id=\"btnGroupAddon\">$</div>\n                  </div>\n                  <input type=\"text\" formControlName=\"conversation_revenue\" class=\"form-control\" placeholder=\"Enter Conversation Revenue\" aria-label=\"Enter Conversation Revenue\" aria-describedby=\"btnGroupAddon\">\n                  <div *ngIf=\"LabelSubmitted && labelcontrol.conversation_revenue.errors\" class=\"invalid-feedback\">\n                    <div *ngIf=\"labelcontrol.conversation_revenue.errors.required\">Conversation Revenue is required</div>\n                </div>\n                </div>\n            </div>\n            <div class=\"control-group mt-2\">\n                <label class=\"control-label input-label\" for=\"startTime\">Conversation Event :</label>\n                   <select formControlName=\"conversation_event\" [value]=\"0\" class=\"form-control\">\n                     <option value=\"0\">Call Length</option>\n                     <option value=\"1\">Call Successfully Connected</option>\n                   </select>\n                   <div *ngIf=\"LabelSubmitted && labelcontrol.conversation_event.errors\" class=\"invalid-feedback\">\n                    <div *ngIf=\"labelcontrol.conversation_event.errors.required\">Conversation Event is required</div>\n                  </div>\n            </div>\n            <div class=\"control-group mt-2\" *ngIf=\"this.addLabelForm.get('conversation_event').value == 0\">\n                <label class=\"control-label input-label\" for=\"startTime\">Enter Seconds :</label>\n                <input type=\"text\" formControlName=\"conversation_seconds\" class=\"form-control\" type=\"text\" name=\"startTime\" placeholder=\"Start Time\" />\n            </div>\n          </fieldset> -->\n        <!-- </div> -->\n      </div>\n      <div class=\"row\">\n        <div class=\"col-md-12\">\n          <!-- <fieldset class=\"scheduler-border\">\n            <legend class=\"scheduler-border\">Publisher Payout Conversation</legend>\n            <div class=\"control-group\">\n                      <label class=\"control-label input-label\" for=\"startTime\">Payout Type :</label>\n                      <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                      <label class=\"btn btn-primary form-check-label active\" (click)=\"payout_typeval(0)\">\n                            <input class=\"form-check-input\" name=\"payout_type\" formControlName=\"payout_type\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                            None\n                          </label>\n                          <label class=\"btn btn-primary form-check-label\" (click)=\"payout_typeval(1)\">\n                            <input class=\"form-check-input\" name=\"payout_type\" formControlName=\"payout_type\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                             Fixed Payout\n                          </label>\n                          <label class=\"btn btn-primary form-check-label\" (click)=\"payout_typeval(2)\">\n                            <input class=\"form-check-input\" name=\"payout_type\" formControlName=\"payout_type\" type=\"radio\" id=\"option3\" [value]=\"2\">\n                             Revenue %\n                          </label>\n                        </div>\n                        <div *ngIf=\"LabelSubmitted && labelcontrol.payout_type.errors\" class=\"invalid-feedback\">\n                          <div *ngIf=\"labelcontrol.payout_type.errors.required\">Payout Type is required</div>\n                      </div>\n          </div>\n\n            <div *ngIf=\"payout_typevalue != 0\">\n            <div class=\"control-group mt-2\">\n                <label class=\"control-label input-label\" for=\"startTime\">Payout Amount :</label>\n                  <div class=\"input-group\">\n                    <div class=\"input-group-prepend\">\n                      <div class=\"input-group-text\" id=\"btnGroupAddon\">$</div>\n                    </div>\n                    <input type=\"text\" formControlName=\"payout_amount\" class=\"form-control\" placeholder=\"Enter Payout Amount\" aria-label=\"Enter Payout Amount\" aria-describedby=\"btnGroupAddon\">\n                  </div>\n            </div>\n\n            <div class=\"control-group mt-2\">\n              <label class=\"control-label input-label\" for=\"startTime\">Payout Trigger :</label>\n                 <select class=\"form-control\" [value]=\"0\" formControlName=\"payout_trigger\">\n                   <option value=\"0\">Inbound Call</option>\n                   <option value=\"1\">Call Length</option>\n                   <option value=\"2\">Call Successfully Connected</option>\n                 </select>\n            </div>\n            <div class=\"control-group mt-2\" *ngIf=\"this.addLabelForm.get('payout_trigger').value == 1\">\n                <label class=\"control-label input-label\" for=\"startTime\">Enter Seconds :</label>\n                <input type=\"text\"  class=\"form-control\" type=\"text\" formControlName=\"payout_seconds\" placeholder=\"Enter Seconds\" />\n            </div>\n          </div>\n          </fieldset> -->\n        </div>\n        <!-- <div class=\"col-md-4\">\n          <fieldset class=\"scheduler-border\">\n            <legend class=\"scheduler-border\">Recording Settings</legend>\n            <div class=\"form-group\">\n              <div class=\"control-label\">Recording</div>\n              <label class=\"custom-switch mt-2 pl-0\">\n                <input type=\"checkbox\" (change)=\"get_recordingstatus($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                <span class=\"custom-switch-indicator\"></span>\n              </label>\n            </div>\n          </fieldset>\n        </div> -->\n        </div>\n         <div class=\"modal-footer\" style=\"padding: 0;\">\n          <!-- !addLabelForm.valid || -->\n            <button [disabled]=\"isName == 'fail'\" (click)=\"closeModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Create Label</button>\n            <button  type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\">Reset</button>\n           </div>\n       </form>\n     </div>\n   </div>\n </div>\n </div>\n\n<!-- Edit Label Modal -->\n<div class=\"modal  fade\" id=\"editLabels\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n aria-hidden=\"true\">\n <div class=\"modal-dialog model-lg\" role=\"document\">\n   <div class=\"modal-content\">\n     <div class=\"modal-header\">\n       <h5 class=\"modal-title\" id=\"formModal\">Save Label</h5>\n       <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n         <span aria-hidden=\"true\">&times;</span>\n       </button>\n     </div>\n     <div class=\"modal-body\">\n       <form [formGroup]=\"editLabelForm\" (ngSubmit)=\"onLabelEditSubmit()\">\n         <div class=\"row\">\n           <div class=\"col-md-12\">\n\n        <!-- <fieldset class=\"scheduler-border\">\n          <legend class=\"scheduler-border\">Label Settings</legend> -->\n         <div class=\"form-group\">\n             <label>Label Name</label>\n             <input type=\"hidden\" name=\"uuid\" formControlName=\"uuid\">\n             <input formControlName=\"name\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': LabelSubmitted && labelcontrol.name.errors }\" (input)=\"validatename()\" readonly>\n             <div *ngIf=\"LabelSubmitted && labelcontrol.name.errors\" class=\"invalid-feedback\">\n                 <div *ngIf=\"labelcontrol.name.errors.required\">Name is required</div>\n             </div>\n             <div *ngIf=\"isName == 'success'  && isName != ''\" style=\"color:green;\">\n                Name Is Available\n              </div>\n             <div *ngIf=\"isName == 'fail' && isName != ''\" style=\"color:red;\">\n                Name Is Not Available\n              </div>\n           </div>\n\n           <div class=\"form-group\">\n             <label  class=\"d-block\">Notes:</label>\n             <textarea formControlName=\"notes\" class=\"form-control\"></textarea>\n             <div *ngIf=\"LabelSubmitted && labelcontrol.notes.errors\" class=\"invalid-feedback\">\n                <div *ngIf=\"labelcontrol.notes.errors.required\">Notes is required</div>\n            </div>\n           </div>\n\n        <!-- </fieldset> -->\n\n      </div>\n      <!-- <div class=\"col-md-6\">\n\n          <fieldset class=\"scheduler-border\">\n            <legend class=\"scheduler-border\">Conversation Setting</legend>\n            <div class=\"control-group\">\n                <label class=\"control-label input-label\" for=\"startTime\">Conversation Revenue :</label>\n                <div class=\"input-group\">\n                  <div class=\"input-group-prepend\">\n                    <div class=\"input-group-text\" id=\"btnGroupAddon\">$</div>\n                  </div>\n                  <input type=\"text\" formControlName=\"conversation_revenue\" class=\"form-control\" placeholder=\"Enter Conversation Revenue\" aria-label=\"Enter Conversation Revenue\" aria-describedby=\"btnGroupAddon\">\n                  <div *ngIf=\"LabelSubmitted && labelcontrol.conversation_revenue.errors\" class=\"invalid-feedback\">\n                    <div *ngIf=\"labelcontrol.conversation_revenue.errors.required\">Conversation Revenue is required</div>\n                </div>\n                </div>\n            </div>\n            <div class=\"control-group mt-2\">\n                <label class=\"control-label input-label\" for=\"startTime\">Conversation Event :</label>\n                   <select formControlName=\"conversation_event\" class=\"form-control\">\n                     <option value=\"0\">Call Length</option>\n                     <option value=\"1\">Call Successfully Connected</option>\n                   </select>\n                   <div *ngIf=\"LabelSubmitted && labelcontrol.conversation_event.errors\" class=\"invalid-feedback\">\n                    <div *ngIf=\"labelcontrol.conversation_event.errors.required\">Conversation Event is required</div>\n                  </div>\n            </div>\n            <div class=\"control-group mt-2\" *ngIf=\"this.editLabelForm.get('conversation_event').value == 0\">\n                <label class=\"control-label input-label\" for=\"startTime\">Enter Seconds :</label>\n                <input type=\"text\" formControlName=\"conversation_seconds\" class=\"form-control\" type=\"text\" placeholder=\"Start Time\" />\n            </div>\n          </fieldset>\n\n      </div>       -->\n    </div>\n    <div class=\"row\">\n      <div class=\"col-md-12\">\n          <!-- <fieldset class=\"scheduler-border\">\n            <legend class=\"scheduler-border\">Publisher Payout Conversation</legend>\n            <div class=\"control-group\">\n                      <label class=\"control-label input-label\" for=\"startTime\">Payout Type :</label>\n                      <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                      <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editpayout_typeval==0}\" (click)=\"payout_typevaledit(0)\">\n                            <input class=\"form-check-input\" name=\"payout_typeedit\" formControlName=\"payout_typeedit\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                            None\n                          </label>\n                          <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editpayout_typeval==1}\" (click)=\"payout_typevaledit(1)\">\n                            <input class=\"form-check-input\" name=\"payout_typeedit\" formControlName=\"payout_typeedit\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                             Fixed Payout\n                          </label>\n                          <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editpayout_typeval==2}\" (click)=\"payout_typevaledit(2)\">\n                            <input class=\"form-check-input\" name=\"payout_typeedit\" formControlName=\"payout_typeedit\" type=\"radio\" id=\"option3\" [value]=\"2\">\n                             Revenue %\n                          </label>\n                        </div>\n                        <div *ngIf=\"LabelSubmitted && labelcontrol.payout_type.errors\" class=\"invalid-feedback\">\n                          <div *ngIf=\"labelcontrol.payout_type.errors.required\">Payout Type is required</div>\n                      </div>\n          </div>\n            <div *ngIf=\"payout_typevalueedit != 0\">\n            <div class=\"control-group mt-2\">\n                <label class=\"control-label input-label\" for=\"startTime\">Payout Amount :</label>\n                  <div class=\"input-group\">\n                    <div class=\"input-group-prepend\">\n                      <div class=\"input-group-text\" id=\"btnGroupAddon\">$</div>\n                    </div>\n                    <input type=\"text\" formControlName=\"payout_amount\" class=\"form-control\" placeholder=\"Enter Payout Amount\" aria-label=\"Enter Payout Amount\" aria-describedby=\"btnGroupAddon\">\n                  </div>\n            </div>\n\n            <div class=\"control-group mt-2\">\n              <label class=\"control-label input-label\" for=\"startTime\">Payout Trigger :</label>\n                 <select class=\"form-control\" formControlName=\"payout_trigger\">\n                   <option value=\"0\">Inbound Call</option>\n                   <option value=\"1\">Call Length</option>\n                   <option value=\"2\">Call Successfully Connected</option>\n                 </select>\n            </div>\n            <div class=\"control-group mt-2\" *ngIf=\"this.editLabelForm.get('payout_trigger').value == 1\">\n                <label class=\"control-label input-label\" for=\"startTime\">Enter Seconds :</label>\n                <input type=\"text\"  class=\"form-control\" type=\"text\" formControlName=\"payout_seconds\" placeholder=\"Enter Seconds\" />\n            </div>\n          </div>\n          </fieldset> -->\n      </div>\n      <!-- <div class=\"col-md-4\">\n          <fieldset class=\"scheduler-border\">\n            <legend class=\"scheduler-border\">Recording Settings</legend>\n            <div class=\"form-group\">\n              <div class=\"control-label\">Recording</div>\n              <label class=\"custom-switch mt-2 pl-0\">\n                <input type=\"checkbox\" [checked]=\"recordingval==1\" (change)=\"get_recordingstatus($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                <span class=\"custom-switch-indicator\"></span>\n              </label>\n            </div>\n          </fieldset>\n        </div>       -->\n      </div>\n\n      <!-- <div class=\"row\">\n      <div class=\"col-md-6\">\n          <fieldset class=\"scheduler-border\">\n            <legend class=\"scheduler-border\">Cap Settings </legend>\n\n            <div class=\"control-group mt-2\">\n              <div class=\"row\">\n                <div class=\"col-3 mt-2\">\n                  <label class=\"control-label input-label\" for=\"startTime\">Cap On :</label>\n                </div>\n                <div class=\"col-9\">\n                  <select class=\"form-control\" formControlName=\"payout_trigger\">\n                    <option value=\"0\">Conversion</option>\n                    <option value=\"1\">Connection</option>\n                  </select>\n                </div>\n              </div>\n            </div>\n\n            <div class=\"control-group mt-2\">\n              <div class=\"row\">\n                <div class=\"col-3 mt-2\">\n                  <label class=\"control-label input-label\" for=\"startTime\">Monthly Cap :</label>\n                </div>\n                <div class=\"col-9\">\n                  <label class=\"custom-switch mt-2 pl-0\">\n                    <input type=\"checkbox\" (change)=\"get_jklrules($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                    <span class=\"custom-switch-indicator\"></span>\n                  </label>\n                </div>\n              </div>\n            </div>\n\n          </fieldset>\n      </div>\n      <div class=\"col-md-4\">\n          <fieldset class=\"scheduler-border\">\n            <legend class=\"scheduler-border\">Recording Settings</legend>\n            <div class=\"form-group\">\n              <div class=\"control-label\">Recording</div>\n              <label class=\"custom-switch mt-2 pl-0\">\n                <input type=\"checkbox\" [checked]=\"recordingval==1\" (change)=\"get_recordingstatus($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                <span class=\"custom-switch-indicator\"></span>\n              </label>\n            </div>\n          </fieldset>\n        </div>\n      </div>       -->\n         <div class=\"modal-footer\" style=\"padding: 0;\">\n            <button (click)=\"closeModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Save Label</button>\n            <button type=\"button\" class=\"btn btn-secondary m-t-15 waves-effect\" data-dismiss=\"modal\" aria-label=\"Close\">\n              Close\n            </button>\n           </div>\n       </form>\n     </div>\n   </div>\n </div>\n </div>\n\n  <div class=\"main-content\">\n\n    <section class=\"section\">\n      <div class=\"section-body\">\n        <div class=\"row\">\n          <div class=\"col-12\">\n            <div class=\"card\">\n                <div class=\"row\">\n                    <div class=\"col-4\">\n                        <div class=\"card-header\">\n                        <h4>Label Data</h4></div>\n                    </div>\n                    <div class=\"col-8 text-right mt-2\">\n                        <div class=\"form-group\" style=\"margin-right: 28px;padding: 3px;font-size: 14px;\">\n                           <button type=\"button\" data-toggle=\"modal\" data-target=\"#addLabels\" class=\"btn btn-primary daterange-btn icon-left btn-sm btn-icon mr-2 p-2\"><i class=\"fa fa-plus\"></i> Create Label\n                            </button>\n                            <button type=\"button\" (click)=\"exportdata()\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-2\"><i class=\"fas fa-file-export\"></i> Export\n                            </button>\n                            <button [disabled]=\"ischecked === '1'\" (click)=\"onDeleteSubmit()\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-2\"><i class=\"fas fa-file-export\"></i> Delete Selected\n                            </button>\n                          </div>\n                    </div>\n                </div>\n\n              <div class=\"card-body\">\n\n                <!-- <ngx-datatable [rows]=\"rows\"\n                class=\"material\"\n                [headerHeight]=\"50\"\n                [footerHeight]=\"50\"\n                rowHeight=\"auto\"\n                [limit]=\"10\"\n                 [columns]=\"columns\"> </ngx-datatable> -->\n\n\n\n                <div class=\"table-responsive\">\n                <table #dataTable class=\"table table-striped dataTable no-footer row-border hover\">\n                    <thead>\n                      <tr>\n                        <th style=\"padding: 10px;\">\n                            <div class=\"custom-control custom-checkbox\" *ngIf=\"labels?.length != 0\">\n                            <input type=\"checkbox\" class=\"custom-control-input\" id=\"customCheck1\" (change)=\"checkalldelete($event)\" (click)=\"deleteselected($event)\">\n                            <label class=\"custom-control-label\" for=\"customCheck1\"></label>\n                            </div>\n                        </th>\n                        <th>Label</th>\n                        <th>Notes</th>\n                        <th>Number Of Numbers</th>\n                        <th>Created Date</th>\n                        <th>Action</th>\n                      </tr>\n                    </thead>\n                    <tbody *ngIf=\"labels?.length != 0\" >\n                        <tr *ngFor=\"let label of labels;let i=index\">\n                            <td>\n                                <div class=\"custom-control custom-checkbox\">\n                                <input type=\"checkbox\" (click)=\"deleteselected($event)\" class=\"custom-control-input\" id=\"customCheck_{{label.uuid}}\"  [checked]=\"label.selected\" [value]=\"label.id\" >\n                                <label class=\"custom-control-label\" for=\"customCheck_{{label.uuid}}\"></label>\n                                </div>\n                            </td>\n                            <td><a class=\"text-white\" routerLink=\"/labels/view/{{ label.permalink }}\" routerLinkActive=\"router-link-active\" >{{ label.name }} </a>\n                            </td>\n                            <td data-original-title=\"999\" data-container=\"body\"\n                            data-toggle=\"tooltip\" data-placement=\"bottom\" title=\"{{label.notes}}\" >\n                            <div *ngIf=\"label.notes.length >= 15\">\n                              {{ label.notes.substring(0,15) }}..\n                            </div>\n                            <div *ngIf=\"label.notes.length <= 15\">\n                              {{ label.notes}}\n                            </div>\n                            </td>\n                            <td>{{ label.noofnos }}</td>\n                            <td>{{ label.created_at }}</td>\n                            <td style=\"cursor:pointer;\" class=\"d-flex\">\n                              <div (click)=\"editLabel(label.uuid,label.is_recording,label.name,label.notes,label.conversation_revenue,label.conversation_event,label.conversation_seconds,label.payout_type,label.payout_amount,label.payout_trigger,label.payout_seconds)\" data-toggle=\"modal\" data-target=\"#editLabels\" class=\"actionedit\"><i class=\"far fa-edit\"></i></div>\n                              &nbsp;&nbsp;&nbsp;&nbsp;\n                              <div (click)=\"Delete((label.uuid))\" class=\"actiondelete\"><i class=\"fas fa-trash\"></i></div>\n                            </td>\n                        </tr>\n                    </tbody>\n                    <tbody *ngIf=\"labels?.length == 0\">\n                      <tr>\n                        <td colspan=\"8\" class=\"no-data-available\">No data Available!</td>\n                      </tr>\n                    <tbody>\n                  </table>\n                </div>\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n    </section>\n\n  </div>\n";

/***/ }),

/***/ 16890:
/*!*************************************************************************!*\
  !*** ./src/app/modules/label/ngxdemo/ngxdemo.component.html?ngResource ***!
  \*************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "<div class=\"main-content\">  \n    <section class=\"section\">\n      <div class=\"section-body\">\n        <div class=\"card\">\n<div class=\"row\">\n\n    <div class=\"col-1 p-3\">\n        <!-- <select style=\"width: 98px;\" class=\"form-control\" (change)=\"getpage($event)\">\n            <option value=\"10\">10</option>\n            <option value=\"25\">25</option>\n            <option value=\"50\">50</option>\n            <option value=\"100\">100</option>\n            <option value=\"500\">500</option>\n            <option value=\"1000\">1000</option>\n            <option value=\"5000\">5000</option>\n            <option value=\"10000\">10000</option>\n        </select> -->\n    </div>\n    <div class=\"col-8\"></div>\n    <div class=\"col-3 p-3\">\n        <input\n        type=\"text\"\n        placeholder=\"Type to filter the name column...\"\n        (keyup)=\"updateFilter($event)\"\n        class=\"form-control\"\n      />\n    </div>\n    <div class=\"col-12\">\n        \n        <ngx-datatable #table1\n            class=\"dark striped\"\n            [rows]=\"blogPostsList\"\n            [columnMode]=\"ColumnMode.force\"\n            [loadingIndicator]=\"loadingIndicator\"\n            [headerHeight]=\"50\"\n            [footerHeight]=\"50\"\n            [scrollbarV]=\"true\"\n            (scroll)=\"onScroll($event.offsetY)\"\n            [rowHeight]=\"50\"            \n            [messages]=\"{emptyMessage: 'No Record Found'}\">\n\n            <ngx-datatable-column name=\"Incoming Number\">\n                <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                    <span>{{row.incoming_number}}</span>\n                </ng-template>                                      \n            </ngx-datatable-column>                                                                     \n            <ngx-datatable-column name=\"Publisher\">\n                <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                    <span>{{row.publisher}}</span>\n                </ng-template>                                      \n            </ngx-datatable-column>                                                                     \n            <ngx-datatable-column name=\"Target\">\n                <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                    <span>{{row.target}}</span>\n                </ng-template>                                      \n            </ngx-datatable-column>                                                                     \n            <ngx-datatable-column name=\"Campaign\">\n                <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                    <span>{{row.campaign}}</span>\n                </ng-template>                                      \n            </ngx-datatable-column>                                                                     \n            <ngx-datatable-column name=\"Billable Duration\">\n                <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                    <span>{{row.billable_duration}}</span>\n                </ng-template>                                      \n            </ngx-datatable-column>                                                                     \n            <ngx-datatable-column name=\"Call Duration\">\n                <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                    <span>{{row.call_duration}}</span>\n                </ng-template>                                      \n            </ngx-datatable-column>                                                                     \n            <ngx-datatable-column name=\"IVR Duration\">\n                <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                    <span>{{row.ivr_duration}}</span>\n                </ng-template>                                      \n            </ngx-datatable-column>                                                                     \n\n            <!-- <ngx-datatable-column name=\"Post Image\" [sortable]=\"false\">\n                <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                    <img *ngIf=\"row.country\" src=\"\" style=\"width:50px\">\n                </ng-template>\n            </ngx-datatable-column> -->\n\n            <!-- <ngx-datatable-column name=\"Status\">\n                <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                    <span>{{row?.status === '1' ? 'Active' : 'In-Active'}}</span>\n                </ng-template>\n            </ngx-datatable-column> -->\n\n            <ngx-datatable-column name=\"Action\" [width]=\"100\" [resizeable]=\"false\" [sortable]=\"false\" [draggable]=\"false\"\n                [canAutoResize]=\"false\">\n                <ng-template ngx-datatable-cell-template let-value=\"value\" let-row=\"row\">\n                    <button type=\"button\" class=\"btn shadow-none btn-icon-sm btn-icon p-0 mr-2\" placement=\"top\" ngbTooltip=\"Edit\"\n                        triggers=\"hover:blur\" container=\"body\" (click)=\"openAddBlogPostPopup(row)\">\n                        <i class=\"fa fa-edit text-primary fa-lg\"> </i>\n                    </button>\n            \n                    <button type=\"button\" class=\"btn shadow-none btn-icon-xs btn-icon p-0\" placement=\"top\" ngbTooltip=\"Delete\"\n                        triggers=\"hover:blur\" container=\"body\" (click)=\"openDeleteBlogPopup(row)\">\n                        <i class=\"fa fa-trash-o text-danger fa-lg\"></i>\n                    </button>\n                </ng-template>\n            </ngx-datatable-column>\n        </ngx-datatable>\n    </div>\n</div>\n<ngx-ui-loader></ngx-ui-loader>\n<!-- <ngx-ui-loader [loaderId]=\"'loadingIndicator'\"></ngx-ui-loader> -->\n</div>\n</div>\n</section>\n</div>";

/***/ }),

/***/ 36766:
/*!*********************************************************************!*\
  !*** ./src/app/modules/longlist/longlist.component.html?ngResource ***!
  \*********************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n      <div class=\"main-content\">  \n        <section class=\"section\">\n          <div class=\"section-body\">\n            <div class=\"row\">\n              <div class=\"col-12\">\n                <div class=\"card\">\n                  <div class=\"row\" style=\"margin-top: 20px;\n                  \">\n                      <div class=\"col-9\">\n                          <div class=\"card-header\">\n                          <h4>All LongList Numbers</h4></div>\n                      </div>\n                  </div> \n                  <form  (ngSubmit)=\"loadcalls()\">\n                  <div class=\"row\" style=\"margin-top: 10px;margin-left: 11px;\" > \n                  <div class=\"col-3\">\n                    <input type=\"text\" [(ngModel)]=\"numbers\" [ngModelOptions]=\"{standalone: true}\" class=\"form-control\" placeholder=\"Search Call Records\" >\n                  </div>                  \n                  <div class=\"col-8\">\n                    <input type=\"text\"\n                    ngxDaterangepickerMd\n                    [(ngModel)]=\"selected\" [ngModelOptions]=\"{standalone: true}\"\n                    [showCustomRangeLabel]=\"true\"\n                    [alwaysShowCalendars]=\"alwaysShowCalendars\"\n                    [ranges]=\"ranges\"                \n                    [showCancel]=\"true\"                   \n                    [linkedCalendars]=\"true\"                    \n                    [locale]=\"{applyLabel: 'Done'}\"\n                    [keepCalendarOpeningWithRange]=\"keepCalendarOpeningWithRange\"\n                    [showRangeLabelOnInput]=\"showRangeLabelOnInput\"\n                    class=\"form-control\"\n                    placeholder=\"Select please...\"/>\n                  </div>\n                  \n                  <div class=\"col-1\" style=\"margin-left: -22px;\">\n                    <button type=\"submit\" class=\"btn btn-success btn-lg\"><i class=\"fas fa-search\"></i></button>\n                  </div>\n                </div>\n                </form>         \n    \n              <div class=\"card-body\">\n                <div class=\"table-responsive\">\n                <table #dataTable class=\"table table-striped dataTable no-footer row-border hover\">\n                    <thead>\n                      <tr>\n                        <th>Number</th>\n                        <th>Forwarded To\t</th>\n                        <th>Created Date</th>                                                                     \n                      </tr>\n                    </thead>\n                    <tbody *ngIf=\"alldata?.length != 0\">\n                        <tr *ngFor=\"let data of alldata\">\n                            <td>{{ data.number }}</td>\n                            <td>{{ data.forward_to }}</td>\n                            <td>{{ data.created_at }}</td>                            \n                        </tr>\n                    </tbody>\n                    <tbody *ngIf=\"alldata?.length == 0\">\n                      <tr>\n                        <td colspan=\"8\" class=\"no-data-available\">No data Available!</td>\n                      </tr>\n                    <tbody>\n                  </table>\n                </div>\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n    </section>\n</div>  ";

/***/ }),

/***/ 934:
/*!***************************************************************************************!*\
  !*** ./src/app/modules/mail-verification/mail-verification.component.html?ngResource ***!
  \***************************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "<div class=\"bg-black\">\n    <div class=\"container\" style=\"background: #1d2b4e;height: 750px;\">\n      <div class=\"row text-center\">\n        <div class=\"col-md-12 mt-5\">\n          <img alt=\"image\" width=\"250px\" src=\"assets/img/logo.png\" class=\"header-logo mb-2  mt-10 mb-10\">\n          <h3>Verify Your Account</h3>\n          <P>Welcome to Ringlab Media! <br>\n            you need to verify your accounts.</P><br>\n          <p>Please Click on below button to verify your accounts</p>\n          <input type=\"button\" (click)=\"onSubmit()\" value=\"Click To Verify\" class=\"btn btn-primary\" style=\"width:300px\">\n          <!-- <a [routerLink]=\"['/login']\" routerLinkActive=\"router-link-active\"> Click Here to Go To Login</a> -->\n        </div>\n      </div>\n    \n    </div>\n  </div>";

/***/ }),

/***/ 82174:
/*!***************************************************************!*\
  !*** ./src/app/modules/notes/notes.component.html?ngResource ***!
  \***************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n\n<div class=\"main-content\">\n       <section class=\"section\">\n         <div class=\"section-body\">\n           <div class=\"row\">\n             <div class=\"col-12 col-md-12 col-lg-12\">\n               <form [formGroup]=\"addNotesForm\" (ngSubmit)=\"onSubmit()\">\n               <div class=\"card\">\n                 <div class=\"card-header\">\n                   <h4>Add Notes</h4>\n                 </div>\n                 <div class=\"card-body\">                    \n                   <div class=\"form-group\">\n                     <label>Note</label>\n                     <textarea formControlName=\"note\" cols=\"30\" rows=\"20\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': submitted && f.note.errors }\"></textarea>\n                     <div *ngIf=\"submitted && f.note.errors\" class=\"invalid-feedback\">\n                         <div *ngIf=\"f.note.errors.required\">Note is required</div>\n                     </div> \n                   </div>\n                 </div>\n                 <div class=\"card-footer text-right\">\n                    <button  class=\"btn btn-primary mr-1\" type=\"submit\">Save Note</button>\n                </div>\n               </div>\n             </form>\n\n   </div>\n\n";

/***/ }),

/***/ 49539:
/*!************************************************************************************************!*\
  !*** ./src/app/modules/number/number-addfslrules/number-addfslrules.component.html?ngResource ***!
  \************************************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n\n<!-- Weekday Modal -->\n<div class=\"modal fade\" id=\"addWeekDays\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\" aria-hidden=\"true\">\n <div class=\"modal-dialog\" role=\"document\">\n   <div class=\"modal-content\">\n     <div class=\"modal-header\">\n       <h5 class=\"modal-title\" id=\"formModal\">Create Weekdays</h5>\n       <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n         <span aria-hidden=\"true\">&times;</span>\n       </button>\n     </div>\n     <div class=\"modal-body\">\n       <form id=\"addWeekDaysfrm\" [formGroup]=\"addWeekDaysForm\" (ngSubmit)=\"onWeekdaySubmit()\">\n         <div class=\"row\">\n           <div class=\"col-6\">\n            <div class=\"form-group\">\n              <label>Start Day</label>\n              <select formControlName=\"start_day\" name=\"start_day\" id=\"start_day\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': daysSubmitted && daycontrol.start_day.errors }\" [value]=\"''\">\n                <option value=\"\">Select Start Day</option>\n                <option value=\"Monday\">Monday</option>\n                <option value=\"Tuesday\">Tuesday</option>\n                <option value=\"Wednesday\">Wednesday</option>\n                <option value=\"Thursday\">Thursday</option>\n                <option value=\"Friday\">Friday</option>\n                <option value=\"Saturday\">Saturday</option>\n                <option value=\"Sunday\">Sunday</option>\n              </select>\n              <div *ngIf=\"daysSubmitted && daycontrol.start_day.errors\" class=\"invalid-feedback\">\n                  <div *ngIf=\"daycontrol.start_day.errors.required\">Start Day is required</div>\n              </div>\n\n           </div>\n           </div>\n           <div class=\"col-6\">\n            <div class=\"form-group\">\n              <label>End Day</label>\n              <select formControlName=\"end_day\" name=\"end_day\" id=\"end_day\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': daysSubmitted && daycontrol.end_day.errors }\" [value]=\"''\">\n                <option value=\"\">Select End Day</option>\n                <option value=\"Monday\">Monday</option>\n                <option value=\"Tuesday\">Tuesday</option>\n                <option value=\"Wednesday\">Wednesday</option>\n                <option value=\"Thursday\">Thursday</option>\n                <option value=\"Friday\">Friday</option>\n                <option value=\"Saturday\">Saturday</option>\n                <option value=\"Sunday\">Sunday</option>\n              </select>\n              <div *ngIf=\"daysSubmitted && daycontrol.end_day.errors\" class=\"invalid-feedback\">\n                  <div *ngIf=\"daycontrol.end_day.errors.required\">End Day is required</div>\n              </div>\n           </div>\n           </div>\n         </div>\n\n         <div class=\"modal-footer\" style=\"padding: 0;\">\n            <button (click)=\"addweekcloseModal()\"  type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Create Weekday</button>\n            <button type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\">Reset</button>\n           </div>\n       </form>\n     </div>\n   </div>\n </div>\n </div>\n\n <div class=\"modal fade\" id=\"editweekdays\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\" aria-hidden=\"true\">\n <div class=\"modal-dialog\" role=\"document\">\n   <div class=\"modal-content\">\n     <div class=\"modal-header\">\n       <h5 class=\"modal-title\" id=\"formModal\">Edit Weekdays</h5>\n       <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n         <span aria-hidden=\"true\">&times;</span>\n       </button>\n     </div>\n     <div class=\"modal-body\">\n       <form id=\"editWeekDaysfrm\" [formGroup]=\"editWeekDaysForm\" (ngSubmit)=\"oneditWeekdaySubmit()\">\n        <input formControlName=\"uuid\" type=\"hidden\" class=\"form-control\">\n         <div class=\"row\">\n           <div class=\"col-6\">\n            <div class=\"form-group\">\n              <label>Start Day</label>\n              <select formControlName=\"start_day\" name=\"start_day\" id=\"start_day\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': daysEditSubmitted && dayeditcontrol.start_day.errors }\">\n                <option value=\"\">Select Start Day</option>\n                <option value=\"Monday\">Monday</option>\n                <option value=\"Tuesday\">Tuesday</option>\n                <option value=\"Wednesday\">Wednesday</option>\n                <option value=\"Thursday\">Thursday</option>\n                <option value=\"Friday\">Friday</option>\n                <option value=\"Saturday\">Saturday</option>\n                <option value=\"Sunday\">Sunday</option>\n              </select>\n              <div *ngIf=\"daysEditSubmitted && dayeditcontrol.start_day.errors\" class=\"invalid-feedback\">\n                  <div *ngIf=\"dayeditcontrol.start_day.errors.required\">Start Day is required</div>\n              </div>\n\n           </div>\n           </div>\n           <div class=\"col-6\">\n            <div class=\"form-group\">\n              <label>End Day</label>\n              <select formControlName=\"end_day\" name=\"end_day\" id=\"end_day\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': daysEditSubmitted && dayeditcontrol.end_day.errors }\">\n                <option value=\"\">Select End Day</option>\n                <option value=\"Monday\">Monday</option>\n                <option value=\"Tuesday\">Tuesday</option>\n                <option value=\"Wednesday\">Wednesday</option>\n                <option value=\"Thursday\">Thursday</option>\n                <option value=\"Friday\">Friday</option>\n                <option value=\"Saturday\">Saturday</option>\n                <option value=\"Sunday\">Sunday</option>\n              </select>\n              <div *ngIf=\"daysEditSubmitted && dayeditcontrol.end_day.errors\" class=\"invalid-feedback\">\n                  <div *ngIf=\"dayeditcontrol.end_day.errors.required\">End Day is required</div>\n              </div>\n           </div>\n           </div>\n         </div>\n\n         <div class=\"modal-footer\" style=\"padding: 0;\">\n            <button (click)=\"editweekcloseModal()\"  type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Save Weekday</button>\n            <button type=\"button\" class=\"btn btn-secondary m-t-15 waves-effect\"  data-dismiss=\"modal\" aria-label=\"Close\">Close</button>\n           </div>\n       </form>\n     </div>\n   </div>\n </div>\n </div>\n\n<!-- End Model -->\n\n\n\n\n  <div class=\"main-content\">\n    <section class=\"section\">\n      <div class=\"section-body\">\n        <div class=\"row\">\n          <!-- <div class=\"col-6\">\n            <div class=\"card\">\n                <div class=\"row\" style=\"margin-top: 20px;\n                \">\n                    <div class=\"col-6\">\n                        <div class=\"card-header\">\n                        <h4>FSL Rule Data</h4></div>\n                    </div>\n                    <div class=\"col-6 text-right mt-2\">\n                        <div class=\"form-group\"  style=\"margin-right: 28px;padding: 3px;font-size: 14px;\">\n                        <button  data-toggle=\"modal\" data-target=\"#addFSLRules\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-1\" (click)=\"addFSL()\"><i class=\"fa fa-plus\"></i> Add New FSL Rules\n                        </button>\n                        </div>\n                    </div>\n\n                </div>\n\n              <div class=\"card-body\">\n                <div class=\"table-responsive\">\n                <table #dataTable class=\"table table-striped dataTable no-footer row-border hover\" style=\"width: 100%;\">\n                    <thead>\n                      <tr>\n                        <th>Name</th>\n                        <th>Created Date</th>\n                        <th>Action</th>\n                      </tr>\n                    </thead>\n\n                    <tbody *ngIf=\"numbers?.length != 0\">\n                        <tr *ngFor=\"let number of numbers\">\n                            <td>{{ number.name }}</td>\n                            <td>{{ number.created_at }}</td>\n                            <td><button data-toggle=\"modal\" data-target=\"#editFSLRules\"  class=\"btn btn-primary btn-sm actionedit\" (click)=\"getFSLbyuuid(number.uuid)\"><i class=\"far fa-edit\"></i></button>&nbsp;<button (click)=\"Delete((number.fsl_rules_uniqueid))\" class=\"btn btn-danger btn-sm actiondelete\"><i class=\"fas fa-trash\"></i></button></td>\n                        </tr>\n                    </tbody>\n                    <tbody *ngIf=\"numbers?.length == 0\">\n                      <tr>\n                        <td colspan=\"3\" class=\"no-data-available\">No data Available!</td>\n                      </tr>\n                    <tbody>\n                  </table>\n                </div>\n              </div>\n            </div>\n          </div> -->\n          <div class=\"col-12\">\n            <div class=\"card\">\n              <div class=\"row\" style=\"margin-top: 20px;\n              \">\n                  <div class=\"col-6\">\n                      <div class=\"card-header\">\n                      <h4>Week Days</h4></div>\n                  </div>\n                  <div class=\"col-6 text-right mt-2\">\n                      <div class=\"form-group\"  style=\"margin-right: 28px;padding: 3px;font-size: 14px;\">\n                      <button  data-toggle=\"modal\" data-target=\"#addWeekDays\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-1\"><i class=\"fa fa-plus\"></i> Add Week Days\n                      </button>\n                      </div>\n                  </div>\n\n              </div>\n\n            <div class=\"card-body\">\n              <div class=\"table-responsive\">\n              <table #daysdataTable class=\"table table-striped dataTable no-footer row-border hover\" style=\"width: 100%;\">\n                  <thead>\n                    <tr>\n                      <th>Start Day</th>\n                      <th>End Day</th>\n                      <th>Created Date</th>\n                      <th>Action</th>\n                    </tr>\n                  </thead>\n\n                  <tbody *ngIf=\"days?.length != 0\">\n                      <tr *ngFor=\"let day of days\">\n                          <td>{{ day.start_day }}</td>\n                          <td>{{ day.end_day }}</td>\n                          <td>{{ day.created_at }}</td>\n                          <td><button data-toggle=\"modal\" data-target=\"#editweekdays\"  class=\"btn btn-primary btn-sm actionedit\" (click)=\"getWeekbyuuid(day.uuid,day.start_day,day.end_day)\"><i class=\"far fa-edit\"></i></button>&nbsp;<button (click)=\"DeleteWeekDay((day.uuid))\" class=\"btn btn-danger btn-sm actiondelete\"><i class=\"fas fa-trash\"></i></button></td>\n                      </tr>\n                  </tbody>\n                  <tbody *ngIf=\"days?.length == 0\">\n                    <tr>\n                      <td colspan=\"4\" class=\"no-data-available\">No data Available!</td>\n                    </tr>\n                  <tbody>\n                </table>\n              </div>\n            </div>\n          </div>\n          </div>\n        </div>\n      </div>\n    </section>\n\n  </div>\n";

/***/ }),

/***/ 77188:
/*!********************************************************************************************!*\
  !*** ./src/app/modules/number/number-batchedit/number-batchedit.component.html?ngResource ***!
  \********************************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n\n\n  <!-- Add Label Modal -->\n  <div class=\"modal fade\" id=\"addLabels\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n  aria-hidden=\"true\">\n  <div class=\"modal-dialog\" role=\"document\">\n    <div class=\"modal-content\">\n      <div class=\"modal-header\">\n        <h5 class=\"modal-title\" id=\"formModal\">Create Label</h5>\n        <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n          <span aria-hidden=\"true\">&times;</span>\n        </button>\n      </div>\n      <div class=\"modal-body\">\n        <form id=\"addLabel\" [formGroup]=\"addLabelForm\" (ngSubmit)=\"onLabelSubmit()\">\n          <div class=\"row\">\n            <div class=\"col-md-12\">\n             <div class=\"form-group\">\n              <label>Label Name</label>\n              <input formControlName=\"name\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': LabelSubmitted && labelcontrol.name.errors }\" (input)=\"validatename()\">\n              <div *ngIf=\"LabelSubmitted && labelcontrol.name.errors\" class=\"invalid-feedback\">\n                  <div *ngIf=\"labelcontrol.name.errors.required\">Name is required</div>\n              </div>   \n              <div *ngIf=\"isName == 'success'  && isName != ''\" style=\"color:green;\">\n                 Name Is Available\n               </div> \n                <div *ngIf=\"isName == 'fail' && isName != ''\" style=\"color:red;\">\n                 Name Is Not Available\n               </div>           \n           </div>\n  \n            <div class=\"form-group\">\n              <label  class=\"d-block\">Notes:</label>\n              <textarea formControlName=\"notes\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': LabelSubmitted && labelcontrol.notes.errors }\"></textarea>                   \n              <div *ngIf=\"LabelSubmitted && labelcontrol.notes.errors\" class=\"invalid-feedback\">\n                 <div *ngIf=\"labelcontrol.notes.errors.required\">Notes is required</div>\n             </div>         \n            </div>\n  \n              </div>     \n      </div>  \n     \n          <div class=\"modal-footer\" style=\"padding: 0;\">\n             <button [disabled]=\"isName == 'fail'\" (click)=\"closeModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Create Label</button>\n             <button  type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\">Reset</button>\n            </div>\n        </form>\n      </div>\n    </div>\n  </div>\n  </div>      \n<div class=\"main-content\">\n        <section class=\"section\">\n          <div class=\"section-body\">\n            <div class=\"row\">\n              <div class=\"col-12 col-md-12 col-lg-12\">\n                <form [formGroup]=\"addForm\" (ngSubmit)=\"onSubmit()\">\n                <div class=\"card\">\n                  <div class=\"card-header\">\n                    <h4>Batch Edit</h4>\n                  </div>\n                  <div class=\"card-body\">                    \n                    <!-- <div class=\"form-group\">\n                      <label>Select CSV File</label>\n                      <div class=\"custom-file\">\n                          <input formControlName=\"number\" type=\"file\" class=\"custom-file-input\" id=\"customFile\" [ngClass]=\"{ 'is-invalid': submitted && f.number.errors }\" (change)=\"onFileChange($event)\">\n                          <label class=\"custom-file-label\" for=\"customFile\">Choose file</label>\n                          <small *ngIf=\"filename\">Selected File: {{filename}}</small><br>\n                          <div *ngIf=\"submitted && f.number.errors\" class=\"invalid-feedback\">\n                              <div *ngIf=\"f.number.errors.required\">File is required</div>\n                          </div> \n                          <small class=\"text-danger\">Note : File should be in .csv format and file have only numbers.</small><br>\n                          &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<small class=\"text-danger\">: You can upload Maximum 1000 Numbers</small>\n                      </div>                        \n                    </div> -->\n\n                    <div class=\"form-group\">\n                      <label>Enter Number</label>\n                          <textarea [ngClass]=\"{ 'is-invalid': submitted && f.number.errors }\" formControlName=\"number\" class=\"form-control\" name=\"\" id=\"\" cols=\"30\" rows=\"4\"></textarea>\n                          <div *ngIf=\"submitted && f.number.errors\" class=\"invalid-feedback\">\n                              <div *ngIf=\"f.number.errors.required\">Numbers is required</div>\n                          </div> \n                          <!-- <small class=\"text-danger\">Note : File should be in .csv format and file have only numbers.</small><br>\n                          &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<small class=\"text-danger\">: You can upload Maximum 1000 Numbers</small> -->\n                    </div>\n                    <!-- <label style=\"font-weight: 600;color: #34395e;font-size: 12px;letter-spacing: 0.5px;\">Select FSL Rules:</label> -->\n                    <!-- <div class=\"form-group\">\n                            <select formControlName=\"fslrulesname\" class=\"form-control\" (change)=\"getRulesByName($event.target.value)\" [ngClass]=\"{ 'is-invalid': submitted && f.fslrulesname.errors }\">\n                              <option value=\"\" selected>Select FSL Rules</option>\n                              <option *ngFor=\"let rules of allRulesData;\" [value]=\"rules.name\">\n                                  {{rules.name}}\n                                </option>\n                            </select>\n                            <div *ngIf=\"submitted && f.fslrulesname.errors\" class=\"invalid-feedback\">\n                                <div *ngIf=\"f.fslrulesname.errors.required\">FSL Rules Name is required</div>\n                            </div>                          \n                        \n                          <div class=\"row\" *ngIf=\"allRulesbyname?.length > 0\" >\n                            <div class=\"col-md-12\">\n                                <div class=\"card\">\n                                  <div class=\"card-body\">\n                                    <div class=\"table-responsive\">\n                                      <table class=\"table table-striped\">\n                                        <tbody><tr style=\"font-size: 13px;\">\n                                          <th style=\"width:15%;\">Name</th>\n                                          <th style=\"width:15%;\">Day</th>\n                                          <th style=\"width:15%;\">Start Time</th>\n                                          <th style=\"width:15%;\">End Time</th>\n                                        </tr>\n                                        <div style=\"display: contents!important;\" *ngFor =\"let rules of allRulesbyname;\">\n                                        <tr style=\"font-size: 13px;\">\n                                          <td>\n                                              {{rules.name}}\n                                          </td>\n                                          <td>\n                                              <div *ngIf=\"rules.timeofday == 1\">\n                                                  Monday to Friday\n                                                </div>\n                                                <div *ngIf=\"rules.timeofday == 2\">\n                                                  Monday to Saturday\n                                                </div>\n                                                <div *ngIf=\"rules.timeofday == 3\">\n                                                  Monday to Monday\n                                                </div>\n                                                <div *ngIf=\"rules.timeofday == 4\">\n                                                  Friday to Monday\n                                                </div>\n                                                <div *ngIf=\"rules.timeofday == 5\">\n                                                  Saturday to Monday\n                                                </div>\n                                          </td>\n                                          <td>\n                                              {{rules.start_time}}\n                                          </td>\n                                          <td>\n                                              {{rules.end_time}}\n                                             \n                                          </td>\n                                             \n                                        </tr>\n                                        <tr><br>\n                                          <td colspan=\"4\" style=\"display: contents;width: 168%;\">\n                                              <table class=\"table fortbl table-striped\">\n                                              <tbody>\n                                                <tr style=\"display: -webkit-box;\">\n                                                  <th>Location Index</th>\n                                                  <th>Primary Location Type</th>\n                                                  <th>Primary Location Value</th>\n                                                </tr>\n                                                <tr>\n                                                    <div *ngFor='let key of  [0,1,2,3,4,5,6,7,8,9,10]; let i = index'>\n                                                        <div *ngIf='rules.noofforwardinglocation>=key' style=\"width: 100%;display: inline-table;\">\n                                                          <tr style=\"font-size: 13px;width: 100%;\">\n                                                            <td>{{key+1}}</td>\n                                                            <td>\n                                                                <span *ngIf=\"rules[i].primary_forwarding_type == 0 || rules[i].primary_forwarding_type == null\">\n                                                                    Number\n                                                                  </span>\n                                                                <span *ngIf=\"rules[i].primary_forwarding_type == 1\">\n                                                                  IVR Menu                            </span>\n                                                                <span *ngIf=\"rules[i].primary_forwarding_type == 2\">\n                                                                  SIP (IP Address)\n                                                                </span>\n                                                            </td>\n                                                            <td>\n                                                                <p *ngIf=\"rules[i].primary_forwarding_type == 0 || rules[i].primary_forwarding_type == null\">\n                                                                    {{rules[i].primary_forwarding_number}}\n                                                                  </p>\n                                                                <p *ngIf=\"rules[i].primary_forwarding_type == 1\">\n                                                                  {{rules[i].primary_forwarding_ivr}}\n                                                                </p>\n                                                                <p *ngIf=\"rules[i].primary_forwarding_type == 2\">\n                                                                  {{rules[i].primary_forwarding_sip}}\n                                                                </p>\n                                                            </td>\n                                                          \n                                                      \n                                                        </tr>\n                                                        </div>\n                                                      </div> \n                                                    </tr>\n\n                                              </tbody>\n                                              </table>\n                                              <br>\n                                          </td>\n                                        </tr> \n                                      </div>                                       \n                                      </tbody></table>\n                                    </div>\n                                  </div>\n                                </div>\n                              </div>\n                        </div>\n                     \n                    </div> -->\n                  \n                  <!-- <div class=\"form-group\">\n                      <div class=\"control-label\">JKL Rules</div>\n                      <label class=\"custom-switch mt-2 pl-0\">\n                        <input type=\"checkbox\" (change)=\"get_jklrules($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                        <span class=\"custom-switch-indicator\"></span>                     \n                      </label>\n                  </div>   -->\n\n                  <div class=\"form-group\">\n                    <div class=\"control-label\">Update Campaign </div>\n                      <label class=\"custom-switch mt-2 pl-0\">\n                        <input type=\"checkbox\" (change)=\"get_campaign($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input labelnumber\">\n                        <span class=\"custom-switch-indicator\"></span>                     \n                      </label>\n                  </div>\n\n                  <div class=\"form-group\" *ngIf=\"iscampaign==true\">\n                    <label>Select Campaign</label>\n                    <!-- [ngClass]=\"{ 'is-invalid': submitted && f.campaign.errors }\" -->\n                    <!-- <select formControlName=\"campaign\" class=\"form-control\" [value]=\"\">\n                      <option value=\"\">Select Campaign</option>\n                      <option value=\"{{data.id}}\" *ngFor=\"let data of getallcampain\">{{data.text}}</option>\n                    </select> -->\n\n                    <angular2-multiselect [data]=\"getallcampain\" formControlName=\"campaign\" [settings]=\n                    \"{\n                      enableSearchFilter: true,\n                      showCheckbox:false,\n                      singleSelection: true, text:'Assign Campaign'}\">\n                  </angular2-multiselect> \n                    \n                    <!-- <ng-select2 formControlName=\"campaign\" [placeholder]=\"'Please select a Campaign'\"  [ngClass]=\"{ 'is-invalid': submitted && f.campaign.errors }\"  [options]=\"options\" [data]=\"getallcampain\" [width]=\"1000\">\n                    </ng-select2> -->\n                    <!-- <div *ngIf=\"submitted && f.campaign.errors\" class=\"invalid-feedback\">\n                      <div *ngIf=\"f.campaign.errors.required\">Campaign is required</div>\n                  </div>  -->\n                  </div>\n\n                  <div class=\"form-group\">\n                    <div class=\"control-label\">Update Publisher </div>\n                      <label class=\"custom-switch mt-2 pl-0\">\n                        <input type=\"checkbox\" (change)=\"get_publishter($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input labelnumber\">\n                        <span class=\"custom-switch-indicator\"></span>                     \n                      </label>\n                  </div>\n                 \n                  <div class=\"form-group\" *ngIf=\"ispublisher==true\">\n                    <label>Select Publisher</label><br>\n                    <!-- <select formControlName=\"publisher\" class=\"form-control\" [value]=\"\">\n                      <option value=\"\">Select Publisher</option>\n                      <option value=\"{{data.id}}\" *ngFor=\"let data of Allpublisher\">{{data.text}}</option>\n                    </select> -->\n\n                    <angular2-multiselect [data]=\"Allpublisher\" formControlName=\"publisher\" [settings]=\n                    \"{\n                      enableSearchFilter: true,\n                      showCheckbox:false,\n                      singleSelection: true, text:'Assign Publisher'}\">\n                  </angular2-multiselect>\n                    \n                    \n                  <div class=\"control-group mt-2\" *ngIf=\"this.addForm.get('publisher').value!=''\">\n                    <label class=\"control-label input-label\" for=\"startTime\">Payout Type :</label>\n                    <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                    <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editpayout_typeval==0}\" (click)=\"payout_typevaledit(0)\"> \n                          <input class=\"form-check-input\" name=\"payout_typeedit\" formControlName=\"payout_typeedit\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                          None\n                        </label>\n                        <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editpayout_typeval==1}\" (click)=\"payout_typevaledit(1)\">\n                          <input class=\"form-check-input\" name=\"payout_typeedit\" formControlName=\"payout_typeedit\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                          Fixed Payout\n                        </label>\n                        <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editpayout_typeval==2}\" (click)=\"payout_typevaledit(2)\">\n                          <input class=\"form-check-input\" name=\"payout_typeedit\" formControlName=\"payout_typeedit\" type=\"radio\" id=\"option3\" [value]=\"2\">\n                          Revenue %\n                        </label>\n                      </div>\n                      <div *ngIf=\"publisherSubmitted && publisherFormcontrol.payout_typeedit.errors\" class=\"invalid-feedback\">\n                        <div *ngIf=\"publisherFormcontrol.payout_typeedit.errors.required\">Payout Type is required</div>\n                    </div>   \n                    </div>\n                    <div *ngIf=\"payout_typevalueedit != 0\">\n                      <div class=\"control-group mt-2\">\n                        <label class=\"control-label input-label\" *ngIf=\"payout_typevalueedit==1\" for=\"startTime\">Payout Amount :</label>\n                        <label class=\"control-label input-label\" *ngIf=\"payout_typevalueedit==2\" for=\"startTime\">Payout % :</label>                            <div class=\"input-group\">\n                              <div class=\"input-group-prepend\">\n                                <div class=\"input-group-text font-10\" *ngIf=\"payout_typevalueedit==1\" id=\"btnGroupAddon\">$</div>\n                                <div class=\"input-group-text font-10\" *ngIf=\"payout_typevalueedit==2\" id=\"btnGroupAddon\">%</div>                              </div>\n                              <input type=\"text\" formControlName=\"payout_amount\" class=\"form-control\" placeholder=\"Enter Payout Amount\" aria-label=\"Enter Payout Amount\" aria-describedby=\"btnGroupAddon\">\n                            </div>                 \n                      </div>\n                      \n                    <div class=\"control-group mt-2\">\n                      <label class=\"control-label input-label\" for=\"startTime\">Payout Trigger :</label>\n                        <select class=\"form-control\" formControlName=\"payout_trigger\">\n                          <option value=\"0\">Inbound Call</option>\n                          <option value=\"1\">Call Length</option>\n                          <option value=\"2\">Call Successfully Connected</option>\n                        </select>              \n                    </div>\n                    <div class=\"control-group mt-2\" *ngIf=\"this.addForm.get('payout_trigger').value == 1\">\n                        <label class=\"control-label input-label\" for=\"startTime\">Enter Seconds :</label>\n                        <input type=\"text\"  class=\"form-control\" type=\"text\" formControlName=\"payout_seconds\" placeholder=\"Enter Seconds\" />         \n                    </div>\n                  </div>\n               \n\n                  </div>\n                  <hr>\n                  <div class=\"form-group\">\n                    <div class=\"control-label\">Add Associated Label </div>\n                      <label class=\"custom-switch mt-2 pl-0\">\n                        <input type=\"checkbox\" (change)=\"get_label($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input labelnumber\">\n                        <span class=\"custom-switch-indicator\"></span>                     \n                      </label>\n                  </div>\n\n                  <div class=\"form-group\" *ngIf=\"islabel==true\">\n                       <label>Select Label</label>\n                        <angular2-multiselect [data]=\"dropdownList\" formControlName=\"add_assosciated_labels\" [settings]=\"dropdownSettings\" ></angular2-multiselect>\n                      <small><a href=\"#\" class=\"\" data-toggle=\"modal\" data-target=\"#addLabels\">Add New Label</a></small>\n                  </div>\n                  <hr>\n                  <div class=\"form-group\">\n                    <div class=\"control-label\">Remove Associated Label </div>\n                      <label class=\"custom-switch mt-2 pl-0\">\n                        <input type=\"checkbox\" (change)=\"get_removelabel($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input labelnumber\">\n                        <span class=\"custom-switch-indicator\"></span>                     \n                      </label>\n                  </div>\n\n                  <div class=\"form-group\" *ngIf=\"isremovelabel==true\">\n                       <label>Select Label</label>\n                        <angular2-multiselect [data]=\"dropdownList\" formControlName=\"remove_assosciated_labels\" [settings]=\"dropdownSettings\" ></angular2-multiselect>\n                      <small><a href=\"#\" class=\"\" data-toggle=\"modal\" data-target=\"#addLabels\">Add New Label</a></small>\n                  </div>\n                    \n                 \n                  </div>\n                  <div class=\"card-footer text-right\">\n                        <button  class=\"btn btn-primary mr-1\" type=\"submit\">Update Numbers</button>\n                        <button style=\"margin-right: 4px;\" routerLink=\"/numbers\" class=\"btn btn-primary\">Back To Numbers</button>\n                        <!-- <button (click)=\"onReset()\" class=\"btn btn-secondary\" type=\"reset\">Reset</button> -->\n                  </div>\n                </div>\n              </form>\n\n    </div>\n";

/***/ }),

/***/ 88453:
/*!************************************************************************************!*\
  !*** ./src/app/modules/number/number-buyer/number-buyer.component.html?ngResource ***!
  \************************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n\n  <div class=\"main-content\">\n    <section class=\"section\">\n      <div class=\"section-body\">\n        <div class=\"row\">\n          <div class=\"col-12\">\n            <div class=\"card\">\n                <div class=\"row\">\n                    <div class=\"col-3\">\n                        <div class=\"card-header\">\n                        <h4> Manage Buyers</h4></div>\n                    </div>\n                    <div class=\"col-9 text-right mt-2\">\n                        <div class=\"form-group\"  style=\"margin-right: 28px;padding: 3px;font-size: 14px;\">\n                          <button type=\"button\" data-toggle=\"modal\" data-target=\"#addLabels\" class=\"btn btn-primary daterange-btn icon-left btn-sm btn-icon mr-2 p-2\"><i class=\"fa fa-plus\"></i> Create Buyer\n                          </button>\n                          <!-- <button [disabled]=\"ischecked === '1'\" (click)=\"onDeleteSubmit()\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-2\"><i class=\"fas fa-file-export\"></i> Delete Selected\n                          </button>                          -->\n\n                          </div>\n                    </div>\n\n                </div>\n\n              <div class=\"card-body\">\n                <div class=\"table-responsive\">\n                <table #dataTable class=\"table table-striped dataTable no-footer row-border hover\" style=\"width: 100%;\">\n                    <thead>\n                      <tr>\n                        <!-- <th style=\"padding: 10px;width: 1px;\">\n                            <div class=\"custom-control custom-checkbox\" *ngIf=\"numbers?.length != 0\">\n                            <input type=\"checkbox\" class=\"custom-control-input\" id=\"customCheck1\" (change)=\"checkalldelete($event)\" (click)=\"deleteselected($event)\">\n                            <label class=\"custom-control-label\" for=\"customCheck1\"></label>\n                            </div>\n                        </th> -->\n                        <th>Company Name</th>\n                        <th>Email ID</th>\n                        <th>Sub Id</th>\n                        <th>Can Pause Targets</th>\n                        <!-- <th>Can Set Target Concurrency</th>\n                        <th>Can Dispute Conversions</th> -->\n                        <!-- <th>Hour</th>\n                        <th>Day</th>\n                        <th>Month</th>\n                        <th>Total</th>                         -->\n                        <!-- <th>Status</th>                         -->\n                        <th>Created At</th>\n                        <th>Action</th>\n                      </tr>\n                    </thead>\n                    <tbody *ngIf=\"numbers?.length != 0\">\n                        <tr *ngFor=\"let number of numbers\">\n                              <!-- <td>\n                                <div class=\"custom-control custom-checkbox\">\n                                <input type=\"checkbox\" (click)=\"deleteselected($event)\" class=\"custom-control-input\" id=\"customCheck_{{number.uuid}}\"  [checked]=\"number.selected\" [value]=\"number.id\" >\n                                <label class=\"custom-control-label\" for=\"customCheck_{{number.uuid}}\"></label>\n                                </div>\n                            </td> -->\n                            <td><a (click)=\"editdata(number.uuid,number.company,number.sub_id,number.allow_buyer_to_pause_target,number.allow_buyer_to_set_target_concurrency,number.allow_buyer_to_dispute_call_conversions,number.limit_revenue,number.email)\" href=\"#\" data-toggle=\"modal\" data-target=\"#editLabels\" class=\"text-white actionedit\">{{ number.company }}</a></td>\n                            <td>{{ number.email }}</td>\n                            <td>{{ number.sub_id }}</td>\n                            <td>\n                                <div *ngIf=\"number.allow_buyer_to_pause_target==0\" class=\"badge badge-danger\">No</div>\n                                <div *ngIf=\"number.allow_buyer_to_pause_target==1\" class=\"badge badge-success\">Yes</div>\n                            </td>\n                            <!-- <td>\n                                <div *ngIf=\"number.allow_buyer_to_set_target_concurrency==0\" class=\"badge badge-danger\">No</div>\n                                <div *ngIf=\"number.allow_buyer_to_set_target_concurrency==1\" class=\"badge badge-success\">Yes</div>\n                            </td>\n                            <td>\n                                <div *ngIf=\"number.allow_buyer_to_dispute_call_conversions==0\" class=\"badge badge-danger\">No</div>\n                                <div *ngIf=\"number.allow_buyer_to_dispute_call_conversions==1\" class=\"badge badge-success\">Yes</div>\n                            </td> -->\n                            <!-- <td>{{ number.hour }}</td>\n                            <td>{{ number.day }}</td>\n                            <td>{{ number.month }}</td>\n                            <td>{{ number.total }}</td> -->\n                            <!-- <td>\n                              <div *ngIf=\"number.status==0\" class=\"badge badge-danger\">In-Active</div>\n                              <div *ngIf=\"number.status==1\" class=\"badge badge-success\">Active</div>\n                            </td> -->\n                            <td>{{ number.created_at }}</td>\n                            <!-- <td><a (click)=\"editdata(number.uuid,number.company,number.sub_id,number.allow_buyer_to_pause_target,number.allow_buyer_to_set_target_concurrency,number.allow_buyer_to_dispute_call_conversions,number.limit_revenue)\" href=\"#\" data-toggle=\"modal\" data-target=\"#editLabels\" class=\"btn btn-primary btn-sm actionedit\"><i class=\"far fa-edit\"></i></a>&nbsp;<button (click)=\"Delete((number.id))\" class=\"btn btn-danger btn-sm actiondelete\"><i class=\"fas fa-trash\"></i></button></td> -->\n                            <td style=\"cursor:pointer;\">\n                              <a (click)=\"editdata(number.uuid,number.company,number.sub_id,number.allow_buyer_to_pause_target,number.allow_buyer_to_set_target_concurrency,number.allow_buyer_to_dispute_call_conversions,number.limit_revenue,number.email)\" href=\"#\" data-toggle=\"modal\" data-target=\"#editLabels\" ><i class=\"far fa-edit\"></i></a>&nbsp;&nbsp;\n                              <i style=\"font-size: 12px;\" placement=\"bottom\" ngbTooltip=\"Delete Buyer\" (click)=\"Delete((number.id))\" class=\"fas fa-trash\"></i>&nbsp;&nbsp;\n                            </td>\n                        </tr>\n                    </tbody>\n                    <tbody *ngIf=\"numbers?.length == 0\">\n                      <tr>\n                        <td colspan=\"8\" class=\"no-data-available\">No data Available!</td>\n                      </tr>\n                    <tbody>\n                  </table>\n                </div>\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n    </section>\n\n  </div>\n\n\n  <!-- Add Label Modal -->\n<div class=\"modal fade\" id=\"addLabels\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\naria-hidden=\"true\">\n<div class=\"modal-dialog model-lg\" role=\"document\">\n  <div class=\"modal-content\">\n    <div class=\"modal-header\">\n      <h5 class=\"modal-title\" id=\"formModal\">Create Buyer</h5>\n      <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n        <span aria-hidden=\"true\">&times;</span>\n      </button>\n    </div>\n    <div class=\"modal-body\">\n      <form id=\"addLabel\" [formGroup]=\"addForm\" (ngSubmit)=\"onSubmit()\">\n        <div class=\"row\">\n          <div class=\"col-md-12\">\n        <div class=\"form-group\">\n            <label>Company</label>\n            <input formControlName=\"company\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && buyercontrol.company.errors }\">\n            <div *ngIf=\"Submitted && buyercontrol.company.errors\" class=\"invalid-feedback\">\n                <div *ngIf=\"buyercontrol.company.errors.required\">Company is required</div>\n            </div>\n         </div>\n\n         <div class=\"form-group\">\n            <label>Email ID</label>\n            <input formControlName=\"email\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && buyercontrol.email.errors }\">\n            <div *ngIf=\"Submitted && buyercontrol.email.errors\" class=\"invalid-feedback\">\n                <div *ngIf=\"buyercontrol.email.errors.required\">Email is required</div>\n            </div>\n         </div>\n\n         <div class=\"form-group\">\n            <label>Password</label>\n            <input formControlName=\"password\" type=\"password\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && buyercontrol.password.errors }\">\n            <div *ngIf=\"Submitted && buyercontrol.password.errors\" class=\"invalid-feedback\">\n                <div *ngIf=\"buyercontrol.password.errors.required\">Password is required</div>\n            </div>\n         </div>\n\n          <div class=\"form-group\">\n            <label  class=\"d-block\">Sub Id  :</label>\n            <input formControlName=\"sub_id\" type=\"text\" class=\"form-control\">\n          </div>\n\n          <div class=\"form-group\">\n            <label  class=\"d-block\">Allow Buyer To Pause Targets :</label>\n            <label class=\"custom-switch mt-2 pl-0\">\n              <input type=\"checkbox\" formControlName=\"allow_buyer_to_pause_target\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n              <span class=\"custom-switch-indicator\"></span>\n            </label>\n          </div>\n\n          <!-- <div class=\"form-group\">\n            <label  class=\"d-block\">Allow Buyer To Set Target Concurrency :</label>\n            <label class=\"custom-switch mt-2 pl-0\">\n              <input type=\"checkbox\" formControlName=\"allow_buyer_to_set_target_concurrency\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n              <span class=\"custom-switch-indicator\"></span>\n            </label>\n          </div>\n\n          <div class=\"form-group\">\n            <label  class=\"d-block\">Allow Buyer To Dispute Call Conversions :</label>\n            <label class=\"custom-switch mt-2 pl-0\">\n              <input type=\"checkbox\" formControlName=\"allow_buyer_to_dispute_call_conversions\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n              <span class=\"custom-switch-indicator\"></span>\n            </label>\n          </div>\n\n          <div class=\"form-group\">\n            <label  class=\"d-block\">Limit Revenue : </label>\n            <label class=\"custom-switch mt-2 pl-0\">\n              <input type=\"checkbox\" formControlName=\"limit_revenue\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n              <span class=\"custom-switch-indicator\"></span>\n            </label>\n          </div> -->\n\n         </div>\n     </div>\n        <div class=\"modal-footer\" style=\"padding: 0;\">\n         <!-- !addLabelForm.valid || -->\n           <button type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Create Buyer</button>\n           <button  type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\">Reset</button>\n          </div>\n      </form>\n    </div>\n  </div>\n</div>\n</div>\n\n<!-- Edit Label Modal -->\n<div class=\"modal fade\" id=\"editLabels\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\naria-hidden=\"true\">\n<div class=\"modal-dialog model-lg\" role=\"document\">\n  <div class=\"modal-content\">\n    <div class=\"modal-header\">\n      <h5 class=\"modal-title\" id=\"formModal\">Update Buyer</h5>\n      <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n        <span aria-hidden=\"true\">&times;</span>\n      </button>\n    </div>\n    <div class=\"modal-body\">\n      <form id=\"editLabel\" [formGroup]=\"editForm\" (ngSubmit)=\"onEditSubmit()\">\n        <div class=\"row\">\n          <div class=\"col-md-12\">\n        <div class=\"form-group\">\n            <label>Company</label>\n            <input type=\"hidden\" name=\"uuid\" formControlName=\"uuid\">\n            <input formControlName=\"company\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': editSubmitted && editbuyercontrol.company.errors }\">\n            <div *ngIf=\"editSubmitted && editbuyercontrol.company.errors\" class=\"invalid-feedback\">\n                <div *ngIf=\"editbuyercontrol.company.errors.required\">Company is required</div>\n            </div>\n         </div>\n\n         <div class=\"form-group\">\n          <label>Email ID</label>\n          <input formControlName=\"email\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && buyercontrol.email.errors }\">\n          <div *ngIf=\"Submitted && buyercontrol.email.errors\" class=\"invalid-feedback\">\n              <div *ngIf=\"buyercontrol.email.errors.required\">Email is required</div>\n          </div>\n       </div>\n\n       <div class=\"form-group\">\n        <label>Password</label>\n        <input formControlName=\"password\" type=\"password\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && buyercontrol.password.errors }\">\n        <div *ngIf=\"Submitted && buyercontrol.password.errors\" class=\"invalid-feedback\">\n            <div *ngIf=\"buyercontrol.password.errors.required\">Password is required</div>\n        </div>\n     </div>\n\n          <div class=\"form-group\">\n            <label  class=\"d-block\">Sub Id  :</label>\n            <input formControlName=\"sub_id\" type=\"text\" class=\"form-control\">\n          </div>\n\n          <div class=\"form-group\">\n            <label  class=\"d-block\">Allow Buyer To Pause Targets :</label>\n            <label class=\"custom-switch mt-2 pl-0\">\n              <input type=\"checkbox\" formControlName=\"allow_buyer_to_pause_target\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n              <span class=\"custom-switch-indicator\"></span>\n            </label>\n          </div>\n\n          <!-- <div class=\"form-group\">\n            <label  class=\"d-block\">Allow Buyer To Set Target Concurrency :</label>\n            <label class=\"custom-switch mt-2 pl-0\">\n              <input type=\"checkbox\" formControlName=\"allow_buyer_to_set_target_concurrency\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n              <span class=\"custom-switch-indicator\"></span>\n            </label>\n          </div>\n\n          <div class=\"form-group\">\n            <label  class=\"d-block\">Allow Buyer To Dispute Call Conversions :</label>\n            <label class=\"custom-switch mt-2 pl-0\">\n              <input type=\"checkbox\" formControlName=\"allow_buyer_to_dispute_call_conversions\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n              <span class=\"custom-switch-indicator\"></span>\n            </label>\n          </div>\n\n          <div class=\"form-group\">\n            <label  class=\"d-block\">Limit Revenue : </label>\n            <label class=\"custom-switch mt-2 pl-0\">\n              <input type=\"checkbox\" formControlName=\"limit_revenue\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n              <span class=\"custom-switch-indicator\"></span>\n            </label>\n          </div> -->\n\n         </div>\n     </div>\n        <div class=\"modal-footer\" style=\"padding: 0;\">\n         <!-- !addLabelForm.valid || -->\n           <button (click)=\"closeEditModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Update Buyer</button>\n           <button  type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\">Reset</button>\n          </div>\n      </form>\n    </div>\n  </div>\n</div>\n</div>\n";

/***/ }),

/***/ 25751:
/*!**************************************************************************************!*\
  !*** ./src/app/modules/number/number-upload/number-upload.component.html?ngResource ***!
  \**************************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n\n\n  <!-- Add Label Modal -->\n  <div class=\"modal fade\" id=\"addLabels\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n  aria-hidden=\"true\">\n  <div class=\"modal-dialog\" role=\"document\">\n    <div class=\"modal-content\">\n      <div class=\"modal-header\">\n        <h5 class=\"modal-title\" id=\"formModal\">Create Label</h5>\n        <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n          <span aria-hidden=\"true\">&times;</span>\n        </button>\n      </div>\n      <div class=\"modal-body\">\n        <form id=\"addLabel\" [formGroup]=\"addLabelForm\" (ngSubmit)=\"onLabelSubmit()\">\n          <div class=\"row\">\n            <div class=\"col-md-12\">\n             <div class=\"form-group\">\n              <label>Label Name</label>\n              <input formControlName=\"name\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': LabelSubmitted && labelcontrol.name.errors }\" (input)=\"validatename()\">\n              <div *ngIf=\"LabelSubmitted && labelcontrol.name.errors\" class=\"invalid-feedback\">\n                  <div *ngIf=\"labelcontrol.name.errors.required\">Name is required</div>\n              </div>   \n              <div *ngIf=\"isName == 'success'  && isName != ''\" style=\"color:green;\">\n                 Name Is Available\n               </div> \n                <div *ngIf=\"isName == 'fail' && isName != ''\" style=\"color:red;\">\n                 Name Is Not Available\n               </div>           \n           </div>\n  \n            <div class=\"form-group\">\n              <label  class=\"d-block\">Notes:</label>\n              <textarea formControlName=\"notes\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': LabelSubmitted && labelcontrol.notes.errors }\"></textarea>                   \n              <div *ngIf=\"LabelSubmitted && labelcontrol.notes.errors\" class=\"invalid-feedback\">\n                 <div *ngIf=\"labelcontrol.notes.errors.required\">Notes is required</div>\n             </div>         \n            </div>\n  \n              </div>     \n      </div>  \n     \n          <div class=\"modal-footer\" style=\"padding: 0;\">\n             <button [disabled]=\"isName == 'fail'\" (click)=\"closeModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Create Label</button>\n             <button  type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\">Reset</button>\n            </div>\n        </form>\n      </div>\n    </div>\n  </div>\n  </div>      \n<div class=\"main-content\">\n        <section class=\"section\">\n          <div class=\"section-body\">\n            <div class=\"row\">\n              <div class=\"col-12 col-md-12 col-lg-12\">\n                <form [formGroup]=\"addForm\" (ngSubmit)=\"onSubmit()\">\n                <div class=\"card\">\n                  <div class=\"card-header\">\n                    <h4>{{pageTitle}}</h4>\n                  </div>\n                  <div class=\"card-body\">                    \n                    <!-- <div class=\"form-group\">\n                      <label>Select CSV File</label>\n                      <div class=\"custom-file\">\n                          <input formControlName=\"number\" type=\"file\" class=\"custom-file-input\" id=\"customFile\" [ngClass]=\"{ 'is-invalid': submitted && f.number.errors }\" (change)=\"onFileChange($event)\">\n                          <label class=\"custom-file-label\" for=\"customFile\">Choose file</label>\n                          <small *ngIf=\"filename\">Selected File: {{filename}}</small><br>\n                          <div *ngIf=\"submitted && f.number.errors\" class=\"invalid-feedback\">\n                              <div *ngIf=\"f.number.errors.required\">File is required</div>\n                          </div> \n                          <small class=\"text-danger\">Note : File should be in .csv format and file have only numbers.</small><br>\n                          &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<small class=\"text-danger\">: You can upload Maximum 1000 Numbers</small>\n                      </div>                        \n                    </div> -->\n\n                    <div class=\"form-group\">\n                      <label>Enter Number</label>\n                          <textarea [ngClass]=\"{ 'is-invalid': submitted && f.number.errors }\" formControlName=\"number\" class=\"form-control\" name=\"\" id=\"\" cols=\"30\" rows=\"4\"></textarea>\n                          <div *ngIf=\"submitted && f.number.errors\" class=\"invalid-feedback\">\n                              <div *ngIf=\"f.number.errors.required\">File is required</div>\n                          </div> \n                          <!-- <small class=\"text-danger\">Note : File should be in .csv format and file have only numbers.</small><br>\n                          &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<small class=\"text-danger\">: You can upload Maximum 1000 Numbers</small> -->\n                    </div>\n                    <!-- <label style=\"font-weight: 600;color: #34395e;font-size: 12px;letter-spacing: 0.5px;\">Select FSL Rules:</label> -->\n                    <!-- <div class=\"form-group\">\n                            <select formControlName=\"fslrulesname\" class=\"form-control\" (change)=\"getRulesByName($event.target.value)\" [ngClass]=\"{ 'is-invalid': submitted && f.fslrulesname.errors }\">\n                              <option value=\"\" selected>Select FSL Rules</option>\n                              <option *ngFor=\"let rules of allRulesData;\" [value]=\"rules.name\">\n                                  {{rules.name}}\n                                </option>\n                            </select>\n                            <div *ngIf=\"submitted && f.fslrulesname.errors\" class=\"invalid-feedback\">\n                                <div *ngIf=\"f.fslrulesname.errors.required\">FSL Rules Name is required</div>\n                            </div>                          \n                        \n                          <div class=\"row\" *ngIf=\"allRulesbyname?.length > 0\" >\n                            <div class=\"col-md-12\">\n                                <div class=\"card\">\n                                  <div class=\"card-body\">\n                                    <div class=\"table-responsive\">\n                                      <table class=\"table table-striped\">\n                                        <tbody><tr style=\"font-size: 13px;\">\n                                          <th style=\"width:15%;\">Name</th>\n                                          <th style=\"width:15%;\">Day</th>\n                                          <th style=\"width:15%;\">Start Time</th>\n                                          <th style=\"width:15%;\">End Time</th>\n                                        </tr>\n                                        <div style=\"display: contents!important;\" *ngFor =\"let rules of allRulesbyname;\">\n                                        <tr style=\"font-size: 13px;\">\n                                          <td>\n                                              {{rules.name}}\n                                          </td>\n                                          <td>\n                                              <div *ngIf=\"rules.timeofday == 1\">\n                                                  Monday to Friday\n                                                </div>\n                                                <div *ngIf=\"rules.timeofday == 2\">\n                                                  Monday to Saturday\n                                                </div>\n                                                <div *ngIf=\"rules.timeofday == 3\">\n                                                  Monday to Monday\n                                                </div>\n                                                <div *ngIf=\"rules.timeofday == 4\">\n                                                  Friday to Monday\n                                                </div>\n                                                <div *ngIf=\"rules.timeofday == 5\">\n                                                  Saturday to Monday\n                                                </div>\n                                          </td>\n                                          <td>\n                                              {{rules.start_time}}\n                                          </td>\n                                          <td>\n                                              {{rules.end_time}}\n                                             \n                                          </td>\n                                             \n                                        </tr>\n                                        <tr><br>\n                                          <td colspan=\"4\" style=\"display: contents;width: 168%;\">\n                                              <table class=\"table fortbl table-striped\">\n                                              <tbody>\n                                                <tr style=\"display: -webkit-box;\">\n                                                  <th>Location Index</th>\n                                                  <th>Primary Location Type</th>\n                                                  <th>Primary Location Value</th>\n                                                </tr>\n                                                <tr>\n                                                    <div *ngFor='let key of  [0,1,2,3,4,5,6,7,8,9,10]; let i = index'>\n                                                        <div *ngIf='rules.noofforwardinglocation>=key' style=\"width: 100%;display: inline-table;\">\n                                                          <tr style=\"font-size: 13px;width: 100%;\">\n                                                            <td>{{key+1}}</td>\n                                                            <td>\n                                                                <span *ngIf=\"rules[i].primary_forwarding_type == 0 || rules[i].primary_forwarding_type == null\">\n                                                                    Number\n                                                                  </span>\n                                                                <span *ngIf=\"rules[i].primary_forwarding_type == 1\">\n                                                                  IVR Menu                            </span>\n                                                                <span *ngIf=\"rules[i].primary_forwarding_type == 2\">\n                                                                  SIP (IP Address)\n                                                                </span>\n                                                            </td>\n                                                            <td>\n                                                                <p *ngIf=\"rules[i].primary_forwarding_type == 0 || rules[i].primary_forwarding_type == null\">\n                                                                    {{rules[i].primary_forwarding_number}}\n                                                                  </p>\n                                                                <p *ngIf=\"rules[i].primary_forwarding_type == 1\">\n                                                                  {{rules[i].primary_forwarding_ivr}}\n                                                                </p>\n                                                                <p *ngIf=\"rules[i].primary_forwarding_type == 2\">\n                                                                  {{rules[i].primary_forwarding_sip}}\n                                                                </p>\n                                                            </td>\n                                                          \n                                                      \n                                                        </tr>\n                                                        </div>\n                                                      </div> \n                                                    </tr>\n\n                                              </tbody>\n                                              </table>\n                                              <br>\n                                          </td>\n                                        </tr> \n                                      </div>                                       \n                                      </tbody></table>\n                                    </div>\n                                  </div>\n                                </div>\n                              </div>\n                        </div>\n                     \n                    </div> -->\n                  \n                  <!-- <div class=\"form-group\">\n                      <div class=\"control-label\">JKL Rules</div>\n                      <label class=\"custom-switch mt-2 pl-0\">\n                        <input type=\"checkbox\" (change)=\"get_jklrules($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                        <span class=\"custom-switch-indicator\"></span>                     \n                      </label>\n                  </div>   -->\n\n                  <div class=\"form-group\">\n                    <label>Select Campaign</label>\n                    <!-- [ngClass]=\"{ 'is-invalid': submitted && f.campaign.errors }\" -->\n                    <!-- <select formControlName=\"campaign\" class=\"form-control\" [value]=\"\">\n                      <option value=\"\">Select Campaign</option>\n                      <option value=\"{{data.id}}\" *ngFor=\"let data of getallcampain\">{{data.text}}</option>\n                    </select> -->\n                    <angular2-multiselect [data]=\"getallcampain\" formControlName=\"campaign\" [settings]=\n                    \"{\n                      enableSearchFilter: true,\n                      showCheckbox:false,\n                      singleSelection: true, text:'Assign Campaign'}\">\n                  </angular2-multiselect> \n\n                    <!-- <ng-select2 formControlName=\"campaign\" [placeholder]=\"'Please select a Campaign'\"  [ngClass]=\"{ 'is-invalid': submitted && f.campaign.errors }\"  [options]=\"options\" [data]=\"getallcampain\" [width]=\"1000\">\n                    </ng-select2> -->\n                    <!-- <div *ngIf=\"submitted && f.campaign.errors\" class=\"invalid-feedback\">\n                      <div *ngIf=\"f.campaign.errors.required\">Campaign is required</div>\n                  </div>  -->\n                  </div>\n                 \n                  <div class=\"form-group\">\n                    <label>Select Publisher</label><br>\n                    <angular2-multiselect [data]=\"Allpublisher\" [ngClass]=\"{ 'is-invalid': submitted && f.publisher.errors }\"  formControlName=\"publisher\" [settings]=\n                    \"{\n                      enableSearchFilter: true,\n                      showCheckbox:false,\n                      singleSelection: true, text:'Assign Publisher'}\">\n                  </angular2-multiselect>\n                    <!-- <select formControlName=\"publisher\" [ngClass]=\"{ 'is-invalid': submitted && f.publisher.errors }\" class=\"form-control\" [value]=\"\">\n                      <option value=\"\">Select Publisher</option>\n                      <option value=\"{{data.id}}\" *ngFor=\"let data of Allpublisher\">{{data.text}}</option>\n                    </select> -->\n                    <!-- <ng-select2 formControlName=\"publisher\" [placeholder]=\"'Please select a Publisher'\"  [ngClass]=\"{ 'is-invalid': submitted && f.publisher.errors }\"  [options]=\"options\" [data]=\"Allpublisher\" [width]=\"1000\">\n                        </ng-select2> -->\n                    <div *ngIf=\"submitted && f.publisher.errors\" class=\"invalid-feedback\">\n                      <div *ngIf=\"f.publisher.errors.required\">Publisher is required</div>\n                    </div> \n                  </div>\n\n                  <div class=\"control-group mt-2\" *ngIf=\"this.addForm.get('publisher').value!=''\">\n                    <label class=\"control-label input-label\" for=\"startTime\">Payout Type :</label>\n                    <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                    <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editpayout_typeval==0}\" (click)=\"payout_typevaledit(0)\"> \n                          <input class=\"form-check-input\" name=\"payout_typeedit\" formControlName=\"payout_typeedit\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                          None\n                        </label>\n                        <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editpayout_typeval==1}\" (click)=\"payout_typevaledit(1)\">\n                          <input class=\"form-check-input\" name=\"payout_typeedit\" formControlName=\"payout_typeedit\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                          Fixed Payout\n                        </label>\n                        <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editpayout_typeval==2}\" (click)=\"payout_typevaledit(2)\">\n                          <input class=\"form-check-input\" name=\"payout_typeedit\" formControlName=\"payout_typeedit\" type=\"radio\" id=\"option3\" [value]=\"2\">\n                          Revenue %\n                        </label>\n                      </div>\n                      <div *ngIf=\"publisherSubmitted && publisherFormcontrol.payout_typeedit.errors\" class=\"invalid-feedback\">\n                        <div *ngIf=\"publisherFormcontrol.payout_typeedit.errors.required\">Payout Type is required</div>\n                    </div>   \n                    </div>\n                    <div *ngIf=\"payout_typevalueedit != 0\">\n                      <div class=\"control-group mt-2\">\n                        <label class=\"control-label input-label\" *ngIf=\"payout_typevalueedit==1\" for=\"startTime\">Payout Amount :</label>\n                        <label class=\"control-label input-label\" *ngIf=\"payout_typevalueedit==2\" for=\"startTime\">Payout % :</label>    \n                            <div class=\"input-group\">\n                              <div class=\"input-group-prepend\">\n                                <div class=\"input-group-text font-10\" *ngIf=\"payout_typevalueedit==1\" id=\"btnGroupAddon\">$</div>\n                                <div class=\"input-group-text font-10\" *ngIf=\"payout_typevalueedit==2\" id=\"btnGroupAddon\">%</div> \n                              </div>\n                              <input type=\"text\" formControlName=\"payout_amount\" class=\"form-control\" placeholder=\"Enter Payout Amount\" aria-label=\"Enter Payout Amount\" aria-describedby=\"btnGroupAddon\">\n                            </div>                 \n                      </div>\n                      \n                    <div class=\"control-group mt-2\">\n                      <label class=\"control-label input-label\" for=\"startTime\">Payout Trigger :</label>\n                        <select class=\"form-control\" formControlName=\"payout_trigger\">\n                          <option value=\"0\">Inbound Call</option>\n                          <option value=\"1\">Call Length</option>\n                          <option value=\"2\">Call Successfully Connected</option>\n                        </select>              \n                    </div>\n                    <div class=\"control-group mt-2\" *ngIf=\"this.addForm.get('payout_trigger').value == 1\">\n                        <label class=\"control-label input-label\" for=\"startTime\">Enter Seconds :</label>\n                        <input type=\"text\"  class=\"form-control\" type=\"text\" formControlName=\"payout_seconds\" placeholder=\"Enter Seconds\" />         \n                    </div>\n                  </div>\n               \n\n                  <div class=\"form-group\">\n                       <label>Associated Label</label>\n                        <angular2-multiselect [data]=\"dropdownList\" formControlName=\"assosciated_labels\" [settings]=\"dropdownSettings\" ></angular2-multiselect>\n                        <!-- [ngClass]=\"{ 'is-invalid': submitted && f.assosciated_labels.errors }\"  -->\n                        <!-- <div *ngIf=\"submitted && f.assosciated_labels.errors\" class=\"invalid-feedback\">\n                          <div *ngIf=\"f.assosciated_labels.errors.required\">Assosciated Labels is required</div>\n                      </div>  -->\n                      <small><a href=\"#\" class=\"\" data-toggle=\"modal\" data-target=\"#addLabels\">Add New Label</a></small>\n                    </div>\n                    \n                 \n                  </div>\n                  <div class=\"card-footer text-right\">\n                        <button  class=\"btn btn-primary mr-1\" type=\"submit\">Import Numbers</button>\n                        <button style=\"margin-right: 4px;\" routerLink=\"/numbers\" class=\"btn btn-primary\">Back To Numbers</button>\n                        <!-- <button (click)=\"onReset()\" class=\"btn btn-secondary\" type=\"reset\">Reset</button> -->\n                  </div>\n                </div>\n              </form>\n\n    </div>\n";

/***/ }),

/***/ 26022:
/*!*****************************************************************!*\
  !*** ./src/app/modules/number/number.component.html?ngResource ***!
  \*****************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n\n<div class=\"main-content\">\n  <section class=\"section\">\n    <div class=\"section-body\">\n      <div class=\"row\">\n        <div class=\"col-12\">\n          <div class=\"card\">\n              <div class=\"row\">\n                  <div class=\"col-3\">\n                      <div class=\"card-header\">\n                      <!-- <h4>Number Data</h4></div> -->\n                      <h4>Manage Targets</h4></div>\n                  </div>\n                  <div class=\"col-9 text-right mt-2\">\n                      <div class=\"form-group\"  style=\"margin-right: 28px;padding: 3px;font-size: 14px;\">\n                        <button routerLink=\"/add-target\" *ngIf=\"role!=4\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-1\"><i class=\"fa fa-plus\"></i> New Target\n                        </button>\n                        <!-- <button routerLink=\"/numbers/batch-edit\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-1\"><i class=\"fa fa-tasks\"></i> Batch Edit</button>\n                        <button routerLink=\"/numbers-import\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-1\"><i class=\"fa fa-plus\"></i> Import </button> -->\n                         <!-- <button (click)=\"exportdata()\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-1\"><i class=\"fas fa-file-export\"></i> Export -->\n                        <!-- </button> -->\n                        <!-- <button [disabled]=\"ischecked === '1'\" (click)=\"onDeleteSubmit()\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-2\"><i class=\"fas fa-file-export\"></i> Delete Selected\n                        </button>                          -->\n\n                        </div>\n                  </div>\n\n              </div>\n\n            <div class=\"card-body\">\n              <div class=\"table-responsive\" style=\"position: relative\">\n                <ngx-ui-loader [loaderId]=\"'loader-01'\"></ngx-ui-loader>\n              <table #dataTable class=\"table table-striped dataTable no-footer row-border hover\" style=\"width: 100%;\">\n                  <thead>\n                    <tr>\n                      <!-- <th></th> -->\n                      <!-- <th style=\"padding: 10px;width: 1px;\">\n                          <div class=\"custom-control custom-checkbox\" *ngIf=\"numbers?.length != 0\">\n                          <input type=\"checkbox\" class=\"custom-control-input\" id=\"customCheck1\" (change)=\"checkalldelete($event)\" (click)=\"deleteselected($event)\">\n                          <label class=\"custom-control-label\" for=\"customCheck1\"></label>\n                          </div>\n                      </th>                       -->\n                      <th>Name</th>\n                      <th>Buyer</th>\n                      <th>Type</th>\n                      <th>Type Value</th>\n                      <!-- <th>Connection Timeout</th>\n                      <th>Dial IVR Option</th>-->\n                      <!-- <th>Is Ringtree</th>  -->\n                      <th>Hour</th>\n                      <th>Day</th>\n                      <th>Month</th>\n                      <th>Total</th>\n                      <th>Created Date</th>\n                      <th>Active</th>\n                      <th>Action</th>\n                      <!-- <th>Action</th> -->\n                    </tr>\n                  </thead>\n                  <tbody *ngIf=\"numbers?.length != 0\">\n                      <tr *ngFor=\"let number of numbers;let i = index;\" class=\"detailrow_{{i}}\">\n                          <!-- <td (click)='details(i,number)' class=\"details-control\"></td> -->\n                          <!-- <td>\n                              <div class=\"custom-control custom-checkbox\">\n                              <input type=\"checkbox\" (click)=\"deleteselected($event)\" class=\"custom-control-input\" id=\"customCheck_{{number.uuid}}\"  [checked]=\"number.selected\" [value]=\"number.id\" >\n                              <label class=\"custom-control-label\" for=\"customCheck_{{number.uuid}}\"></label>\n                              </div>\n                          </td>                           -->\n                          <td *ngIf=\"role==4\">{{ number.name }}</td>\n                          <td *ngIf=\"role!=4\"><a routerLink=\"/edit-numbers/{{ number.uuid }}\" class=\"text-white\">{{ number.name }}</a></td>\n                          <td>{{ number.buyers }}</td>\n                          <td>{{ number.valtype }}</td>\n                          <td *ngIf=\"number.valtype =='IVR Menu' && number.is_ringtree!=1\"><a style=\"color: white;text-decoration: underline;\" routerLink=\"/edit-ivr/{{ number.ivrmenu_uuid }}\" >{{ number.typeval }}</a></td>\n                          <td *ngIf=\"number.valtype !='IVR Menu' && number.is_ringtree!=1\">{{ number.typeval }}</td>\n                          <td *ngIf=\"number.is_ringtree ==1\"><a target=\"_blank\" [href]=\"number.typeval\" style=\"color: white;\">URL</a> </td>\n                          <!-- <td>{{ number.connection_timeout }}</td>\n                          <td>{{ number.dialivroption }}</td>\n                          <td>\n                            <span *ngIf=\"number.disableRecordings==1\" class=\"badge badge-success\">Yes</span>\n                            <span *ngIf=\"number.disableRecordings==0\" class=\"badge badge-danger p-1\">No</span>\n                          </td> -->\n                          <!-- <td>\n                            <div style=\"font-size: 10px;\" *ngIf=\"number.is_ringtree==1\" class=\"badge badge-success\">Yes</div>\n                            <div style=\"font-size: 10px;\" *ngIf=\"number.is_ringtree==0\" class=\"badge badge-danger\">No</div>\n                          </td> -->\n                          <td>{{ number.hour}} <span style=\"color: #5b5d66;\" *ngIf=\"number.hourly_revenuecapvalue!=0\">/ {{number.hourly_revenuecapvalue}}</span></td>\n                          <td>{{ number.day }} <span style=\"color: #5b5d66;\" *ngIf=\"number.daily_revenuecapvalue!=0\">/ {{number.daily_revenuecapvalue}}</span> </td>\n                          <td>{{ number.month }} <span style=\"color: #5b5d66;\" *ngIf=\"number.monthly_revenuecapvalue!=0\">/ {{number.monthly_revenuecapvalue}}</span></td>\n                          <td>{{ number.total }}</td>\n\n                          <td>{{ number.created_at }}</td>\n                          <td>\n                            <label class=\"custom-switch mt-2 pl-0\" *ngIf=\"role!=4\">\n                              <input type=\"checkbox\" *ngIf=\"number.active_status==1\" checked (change)=\"change_status($event,number.uuid)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n\n                              <input type=\"checkbox\" *ngIf=\"number.active_status==0\" (change)=\"change_status($event,number.uuid)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                              <span class=\"custom-switch-indicator\"></span>\n                            </label>\n                            <label class=\"custom-switch mt-2 pl-0\" *ngIf=\"role==4 && number.ispause==1\">\n                              <input type=\"checkbox\" *ngIf=\"number.active_status==1\" checked (change)=\"change_status($event,number.uuid)\"  name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n\n                              <input type=\"checkbox\" *ngIf=\"number.active_status==0\" (change)=\"change_status($event,number.uuid)\"  name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                              <span class=\"custom-switch-indicator\"></span>\n                            </label>\n                            <span *ngIf=\"role==4 && number.ispause==0\">-</span>\n                          </td>\n                          <td style=\"cursor:pointer;\" *ngIf=\"role!=4\">\n                            <i style=\"font-size: 12px;\" placement=\"bottom\" ngbTooltip=\"Duplicate Target\" (click)=\"Clone(number.uuid)\" class=\"far fa-clone\"></i>&nbsp;&nbsp;\n                            <a style=\"font-size: 12px;\" placement=\"bottom\" ngbTooltip=\"Edit Target\" routerLink=\"/edit-numbers/{{ number.uuid }}\" class=\"actionedit\"><i class=\"far fa-edit\"></i></a>&nbsp;&nbsp;\n                            <i style=\"font-size: 12px;\" placement=\"bottom\" ngbTooltip=\"Delete Target\" (click)=\"Delete(number.uuid,number.valtype,number.typeval,number.company_uuid)\" class=\"fas fa-trash\"></i>&nbsp;&nbsp;\n                            <i style=\"font-size: 12px;\" placement=\"bottom\" ngbTooltip=\"Show References\" (click)='details(i,number)' class=\"fas fa-anchor\"></i>\n                          </td>\n                          <td style=\"cursor:pointer;\" *ngIf=\"role==4\">\n                            -\n                          </td>\n                      </tr>\n                  </tbody>\n                  <tbody *ngIf=\"numbers?.length == 0\">\n                    <tr>\n                      <td colspan=\"9\" class=\"no-data-available\">No data Available!</td>\n                    </tr>\n                  <tbody>\n                </table>\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n    </div>\n  </section>\n\n</div>\n";

/***/ }),

/***/ 51489:
/*!******************************************************************************!*\
  !*** ./src/app/modules/number/numberadd/numberadd.component.html?ngResource ***!
  \******************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "<!-- FSL Modal -->\n<div class=\"modal  fade\" id=\"addFSLRules\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\naria-hidden=\"true\">\n<div class=\"modal-dialog modal-lg\" role=\"document\">\n  <div class=\"modal-content\">\n    <div class=\"modal-header\">\n      <h5 class=\"modal-title\" id=\"formModal\">Add New Target</h5>\n      <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n        <span aria-hidden=\"true\">&times;</span>\n      </button>\n    </div>\n    <div class=\"modal-body\">\n\n      <form [formGroup]=\"addFSLRules\" (ngSubmit)=\"onFSLSubmit()\">\n        <div class=\"form-group\">\n            <label>Name</label>\n            <input formControlName=\"name\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': FSLRulesSubmitted && rules.name.errors }\" (input)=\"validatename()\">\n            <div *ngIf=\"FSLRulesSubmitted && rules.name.errors\" class=\"invalid-feedback\">\n                <div *ngIf=\"rules.name.errors.required\">Name is required</div>\n            </div>\n            <div *ngIf=\"isName == 'success'  && isName != ''\" style=\"color:green;\">\n             Name Is Available\n           </div>\n            <div *ngIf=\"isName == 'fail' && isName != ''\" style=\"color:red;\">\n             Name Is Not Available\n           </div>\n          </div>\n\n          <div class=\"form-group\">\n            <label  class=\"d-block\">Number of Time Frames:</label>\n            <input formControlName=\"numberoftimeframe\"  oninput=\"javascript: if (this.value.length > this.maxLength) this.value = this.value.slice(0, this.maxLength);\"\n            type = \"number\" maxlength = \"1\" [(ngModel)]=\"noofforwarding\" type=\"number\" class=\"form-control phone-number\" [ngClass]=\"{ 'is-invalid': FSLRulesSubmitted && rules.numberoftimeframe.errors }\" min=\"1\" max=\"7\">\n            <div *ngIf=\"FSLRulesSubmitted && rules.numberoftimeframe.errors\" class=\"invalid-feedback\">\n              <div *ngIf=\"rules.numberoftimeframe.errors.required\">Number of Time Frames is required</div>\n          </div>\n          </div>\n\n          <br>\n          <!-- Day 1 -->\n          <div class=\"groupborder\" *ngIf=\"noofforwarding>=1\">\n            <div >\n              <div class=\"form-group\">\n                  <label>Select Timeframe - 1</label>\n                  <select formControlName=\"day_0\" name=\"day-0\" id=\"day-0\" class=\"form-control\" [value]=\"0\">\n                    <option value=\"0\">Select Day</option>\n                    <option *ngFor=\"let item of allweekdays\" value=\"{{item.id}}\">{{item.start_day}} to {{item.end_day}}</option>\n                  </select>\n                </div>\n              <div class=\"row\">\n              <div class=\"col-md-12\">\n              <!-- <div class=\"row\">\n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                        <label>Start Time</label>\n                        <input formControlName=\"start_time_0\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\" placeholder=\"Ex :00:00\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time>\n                    </div>\n                </div>\n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                        <label>End Time</label>\n                        <input formControlName=\"end_time_0\" [owlDateTimeTrigger]=\"dt1\" class=\"form-control\" [owlDateTime]=\"dt1\" placeholder=\"Ex :00:00\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt1></owl-date-time>\n                    </div>\n                </div>\n              </div>                   -->\n\n\n              <div class=\"row\">\n                <div class=\"col-md-3\">\n                    <label>Start Time (HH:MM)</label><br>\n                      <div  style=\"display:-webkit-inline-box\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"start_hrs_0\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                      </div>\n                      <div class=\"pt-2\">\n                        :\n                      </div>\n                    <div class=\"text-left\">\n                        <div class=\"form-group\">\n                            <input style=\"width:68px\" formControlName=\"start_min_0\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                        </div>\n                    </div>\n                  </div>\n                </div>\n\n                <div class=\"col-md-4\">\n                  <label>End Time (HH:MM)</label><br>\n                    <div  style=\"display:-webkit-inline-box\">\n                    <div class=\"form-group\">\n                        <input style=\"width:68px\" formControlName=\"end_hrs_0\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                    </div>\n                    <div class=\"pt-2\">\n                      :\n                    </div>\n                  <div class=\"text-left\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"end_min_0\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                      </div>\n                  </div>\n                </div>\n                </div>\n              </div>\n\n              <div>\n\n               <div class=\"form-group\">\n                   <label  class=\"d-block\">Enter Number Of Forwarding Location:</label>\n                   <input formControlName=\"noofforwardinglocation_1\" [(ngModel)]=\"noofforwardinglocation_1\" type=\"text\" class=\"form-control phone-number\">\n               </div>\n\n               <div class=\"groupborder\" *ngFor='let in of selectednoofforwardinglocation();let i = index'>\n                 <div class=\"form-group\">\n                     <label class=\"d-block\">Primary Forwarding Location - {{i+1}}</label>\n                     <div class=\"form-check form-check-inline\">\n                         <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day0\" name=\"PrimaryforwardType_{{i}}_day0\" class=\"with-gap number\" [value]='0' (click)=\"setPrimaryforward(0,i,0)\" [checked]=\"true\">\n\n                       <label class=\"form-check-label\" for=\"inlineradio1\">Number</label>\n                     </div>\n                     <div class=\"form-check form-check-inline\">\n                         <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day0\" name=\"PrimaryforwardType_{{i}}_day0\" (click)=\"setPrimaryforward(1,i,0)\" class=\"with-gap\" [value]=\"1\">\n                       <label class=\"form-check-label\" for=\"inlineradio2\">IVR Menu</label>\n                     </div>\n                     <div class=\"form-check form-check-inline\">\n                         <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day0\" name=\"PrimaryforwardType_{{i}}_day0\" class=\"with-gap\" (click)=\"setPrimaryforward(2,i,0)\" [value]=\"2\">\n                       <label class=\"form-check-label\" for=\"inlineCheckbox3\">SIP (IP Address)</label>\n                     </div>\n                   </div>\n                   <div class=\"form-group\" *ngIf=\"!isPrimarySelected(1,i,0) && !isPrimarySelected(2,i,0)\">\n                         <label  class=\"d-block\">Number:</label>\n                         <input type=\"text\" formControlName=\"number_{{i}}_day0\" id=\"number_{{i}}_day0\" class=\"form-control phone-number\" placeholder=\"(000) 000-000\"  maxlength=\"16\" (keypress)=_keyPress($event)>\n                   </div>\n                   <div class=\"form-group\" *ngIf=\"isPrimarySelected(1,i,0)\">\n                         <label  class=\"d-block\">IVR Menu:</label>\n                           <!-- <input type=\"text\" formControlName=\"ivrMenu_{{i}}_day0\" class=\"form-control phone-number\">   -->\n\n                           <select formControlName=\"ivrMenu_{{i}}_day0\" class=\"form-control\" [value] = \"\">\n                               <option value=\"\">Select IVR Menu</option>\n                               <option *ngFor=\"let data of ivrmenus;\" [value]=\"data.uuid\">\n                                   {{data.name}}\n                                 </option>\n                             </select>\n                     </div>\n                     <div class=\"form-group\" *ngIf=\"isPrimarySelected(2,i,0)\">\n                           <label  class=\"d-block\">SIP (IP Address):</label>\n                           <input  formControlName=\"sipAdd_{{i}}_day0\" type=\"text\" class=\"form-control phone-number\">\n                     </div>\n               </div>\n               </div>\n\n           </div>\n           </div>\n        </div>\n           </div>\n\n          <!-- Day 2 -->\n           <div class=\"groupborder\" *ngIf=\"noofforwarding>=2\">\n            <div >\n              <div class=\"form-group\">\n                  <label>Select Timeframe - 2</label>\n                  <select formControlName=\"day_1\" class=\"form-control\" [value]=\"0\" >\n                    <option value=\"0\">Select Day</option>\n                    <option *ngFor=\"let item of allweekdays\" value=\"{{item.id}}\">{{item.start_day}} to {{item.end_day}}</option>\n                    </select>\n                </div>\n              <div class=\"row\">\n              <div class=\"col-md-12\">\n              <!-- <div class=\"row\">\n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                        <label>Start Time</label>\n                        <input formControlName=\"start_time_1\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\" placeholder=\"Ex :00:00\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time>\n                    </div>\n                </div>\n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                        <label>End Time</label>\n                        <input formControlName=\"end_time_1\" [owlDateTimeTrigger]=\"dt1\" class=\"form-control\" [owlDateTime]=\"dt1\" placeholder=\"Ex :00:00\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt1></owl-date-time>\n                    </div>\n                </div>\n              </div>  -->\n\n\n              <div class=\"row\">\n                <div class=\"col-md-3\">\n                    <label>Start Time (HH:MM)</label><br>\n                      <div  style=\"display:-webkit-inline-box\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"start_hrs_1\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                          <!-- <input formControlName=\"start_time_0\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time> -->\n                      </div>\n                      <div class=\"pt-2\">\n                        :\n                      </div>\n                    <div class=\"text-left\">\n                        <div class=\"form-group\">\n                            <input style=\"width:68px\" formControlName=\"start_min_1\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                        </div>\n                    </div>\n                  </div>\n                </div>\n\n                <div class=\"col-md-4\">\n                  <label>End Time (HH:MM)</label><br>\n                    <div  style=\"display:-webkit-inline-box\">\n                    <div class=\"form-group\">\n                        <input style=\"width:68px\" formControlName=\"end_hrs_1\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                    </div>\n                    <div class=\"pt-2\">\n                      :\n                    </div>\n                  <div class=\"text-left\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"end_min_1\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                      </div>\n                  </div>\n                </div>\n                </div>\n              </div>\n\n              <div class=\"form-group\">\n               <label  class=\"d-block\">Enter Number Of Forwarding Location:</label>\n               <input formControlName=\"noofforwardinglocation_2\" [(ngModel)]=\"noofforwardinglocation_2\" type=\"text\" class=\"form-control phone-number\" >\n           </div>\n\n           <div class=\"groupborder\" *ngFor='let in of selectednoofforwardinglocation_2();let i = index'>\n             <div class=\"form-group\">\n                 <label class=\"d-block\">Primary Forwarding Location - {{i+1}}</label>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day1\" name=\"PrimaryforwardType_{{i}}_day1\" class=\"with-gap\" [value]='0' (click)=\"setPrimaryforward(0,i,1)\" [checked]=\"true\">\n\n                   <label class=\"form-check-label\" for=\"inlineradio1\">Number</label>\n                 </div>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day1\" name=\"PrimaryforwardType_{{i}}_day1\" (click)=\"setPrimaryforward(1,i,1)\" class=\"with-gap\" [value]=\"1\">\n                   <label class=\"form-check-label\" for=\"inlineradio2\">IVR Menu</label>\n                 </div>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day1\" name=\"PrimaryforwardType_{{i}}_day1\" class=\"with-gap\" (click)=\"setPrimaryforward(2,i,1)\" [value]=\"2\">\n                   <label class=\"form-check-label\" for=\"inlineCheckbox3\">SIP (IP Address)</label>\n                 </div>\n               </div>\n               <div class=\"form-group\" *ngIf=\"!isPrimarySelected(1,i,1) && !isPrimarySelected(2,i,1)\">\n                     <label  class=\"d-block\">Number:</label>\n                     <input type=\"text\" formControlName=\"number_{{i}}_day1\" id=\"number_{{i}}_day1\" class=\"form-control phone-number\" placeholder=\"(000) 000-000\"  maxlength=\"16\" (keypress)=_keyPress($event)>\n               </div>\n               <div class=\"form-group\" *ngIf=\"isPrimarySelected(1,i,1)\">\n                     <label  class=\"d-block\">IVR Menu:</label>\n                       <select formControlName=\"ivrMenu_{{i}}_day1\" class=\"form-control\" [value] = \"\">\n                           <option value=\"\">Select IVR Menu</option>\n                           <option *ngFor=\"let data of ivrmenus;\" [value]=\"data.uuid\">\n                               {{data.name}}\n                             </option>\n                         </select>\n                 </div>\n                 <div class=\"form-group\" *ngIf=\"isPrimarySelected(2,i,1)\">\n                       <label  class=\"d-block\">SIP (IP Address):</label>\n                       <input  formControlName=\"sipAdd_{{i}}_day1\" type=\"text\" class=\"form-control phone-number\">\n                 </div>\n           </div>\n            </div>\n           </div>\n        </div>\n            </div>\n\n          <!-- Day 3 -->\n          <div class=\"groupborder\" *ngIf=\"noofforwarding>=3\">\n            <div >\n              <div class=\"form-group\">\n                  <label>Select Timeframe - 3</label>\n                  <select formControlName=\"day_2\" class=\"form-control\" [value]=\"0\" >\n                    <option value=\"0\">Select Day</option>\n                    <option *ngFor=\"let item of allweekdays\" value=\"{{item.id}}\">{{item.start_day}} to {{item.end_day}}</option>\n                    </select>\n\n                </div>\n              <div class=\"row\">\n              <div class=\"col-md-12\">\n              <!-- <div class=\"row\">\n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                        <label>Start Time</label>\n                        <input formControlName=\"start_time_2\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\" placeholder=\"Ex :00:00\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time>\n                    </div>\n                </div>\n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                        <label>End Time</label>\n                        <input formControlName=\"end_time_2\" [owlDateTimeTrigger]=\"dt1\" class=\"form-control\" [owlDateTime]=\"dt1\" placeholder=\"Ex :00:00\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt1></owl-date-time>\n                    </div>\n                </div>\n              </div>  -->\n\n\n              <div class=\"row\">\n                <div class=\"col-md-3\">\n                    <label>Start Time (HH:MM)</label><br>\n                      <div  style=\"display:-webkit-inline-box\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"start_hrs_2\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                          <!-- <input formControlName=\"start_time_0\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time> -->\n                      </div>\n                      <div class=\"pt-2\">\n                        :\n                      </div>\n                    <div class=\"text-left\">\n                        <div class=\"form-group\">\n                            <input style=\"width:68px\" formControlName=\"start_min_2\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                        </div>\n                    </div>\n                  </div>\n                </div>\n\n                <div class=\"col-md-4\">\n                  <label>End Time (HH:MM)</label><br>\n                    <div  style=\"display:-webkit-inline-box\">\n                    <div class=\"form-group\">\n                        <input style=\"width:68px\" formControlName=\"end_hrs_2\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                    </div>\n                    <div class=\"pt-2\">\n                      :\n                    </div>\n                  <div class=\"text-left\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"end_min_2\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                      </div>\n                  </div>\n                </div>\n                </div>\n              </div>\n\n              <div class=\"form-group\">\n               <label  class=\"d-block\">Enter Number Of Forwarding Location:</label>\n               <input formControlName=\"noofforwardinglocation_3\" [(ngModel)]=\"noofforwardinglocation_3\" type=\"text\" class=\"form-control phone-number\">\n           </div>\n\n           <div class=\"groupborder\" *ngFor='let in of selectednoofforwardinglocation_3();let i = index'>\n             <div class=\"form-group\">\n                 <label class=\"d-block\">Primary Forwarding Location - {{i+1}}</label>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day2\" name=\"PrimaryforwardType_{{i}}_day2\" class=\"with-gap\" [value]='0' (click)=\"setPrimaryforward(0,i,2)\" [checked]=\"true\">\n\n                   <label class=\"form-check-label\" for=\"inlineradio1\">Number</label>\n                 </div>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day2\" name=\"PrimaryforwardType_{{i}}_day2\" (click)=\"setPrimaryforward(1,i,2)\" class=\"with-gap\" [value]=\"1\">\n                   <label class=\"form-check-label\" for=\"inlineradio2\">IVR Menu</label>\n                 </div>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day2\" name=\"PrimaryforwardType_{{i}}_day2\" class=\"with-gap\" (click)=\"setPrimaryforward(2,i,2)\" [value]=\"2\">\n                   <label class=\"form-check-label\" for=\"inlineCheckbox3\">SIP (IP Address)</label>\n                 </div>\n               </div>\n               <div class=\"form-group\" *ngIf=\"!isPrimarySelected(1,i,2) && !isPrimarySelected(2,i,2)\">\n                     <label  class=\"d-block\">Number:</label>\n                     <input type=\"text\" formControlName=\"number_{{i}}_day2\" id=\"number_{{i}}_day2\" class=\"form-control phone-number\" placeholder=\"(000) 000-000\"  maxlength=\"16\" (keypress)=_keyPress($event)>\n               </div>\n               <div class=\"form-group\" *ngIf=\"isPrimarySelected(1,i,2)\">\n                     <label  class=\"d-block\">IVR Menu:</label>\n                      <select formControlName=\"ivrMenu_{{i}}_day2\" class=\"form-control\" [value] = \"\">\n                           <option value=\"\">Select IVR Menu</option>\n                           <option *ngFor=\"let data of ivrmenus;\" [value]=\"data.uuid\">\n                               {{data.name}}\n                             </option>\n                         </select>\n                 </div>\n                 <div class=\"form-group\" *ngIf=\"isPrimarySelected(2,i,2)\">\n                       <label  class=\"d-block\">SIP (IP Address):</label>\n                       <input  formControlName=\"sipAdd_{{i}}_day2\" type=\"text\" class=\"form-control phone-number\">\n                 </div>\n           </div>\n            </div>\n            </div>\n        </div>\n          </div>\n\n          <!-- Day 4 -->\n          <div class=\"groupborder\" *ngIf=\"noofforwarding>=4\">\n              <div >\n                <div class=\"form-group\">\n                    <label>Select Timeframe - 4</label>\n                    <select formControlName=\"day_3\" class=\"form-control\" [value]=\"0\" >\n                      <option value=\"0\">Select Day</option>\n                      <option *ngFor=\"let item of allweekdays\" value=\"{{item.id}}\">{{item.start_day}} to {{item.end_day}}</option>\n                      </select>\n\n                  </div>\n                <div class=\"row\">\n                <div class=\"col-md-12\">\n                <!-- <div class=\"row\">\n                  <div class=\"col-md-6\">\n                      <div class=\"form-group\">\n                          <label>Start Time</label>\n                          <input formControlName=\"start_time_3\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\" placeholder=\"Ex :00:00\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time>\n                      </div>\n                  </div>\n                  <div class=\"col-md-6\">\n                      <div class=\"form-group\">\n                          <label>End Time</label>\n                          <input formControlName=\"end_time_3\" [owlDateTimeTrigger]=\"dt1\" class=\"form-control\" [owlDateTime]=\"dt1\" placeholder=\"Ex :00:00\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt1></owl-date-time>\n                      </div>\n                  </div>\n                </div>   -->\n\n\n              <div class=\"row\">\n                <div class=\"col-md-3\">\n                    <label>Start Time (HH:MM)</label><br>\n                      <div  style=\"display:-webkit-inline-box\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"start_hrs_3\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                          <!-- <input formControlName=\"start_time_0\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time> -->\n                      </div>\n                      <div class=\"pt-2\">\n                        :\n                      </div>\n                    <div class=\"text-left\">\n                        <div class=\"form-group\">\n                            <input style=\"width:68px\" formControlName=\"start_min_3\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                        </div>\n                    </div>\n                  </div>\n                </div>\n\n                <div class=\"col-md-4\">\n                  <label>End Time (HH:MM)</label><br>\n                    <div  style=\"display:-webkit-inline-box\">\n                    <div class=\"form-group\">\n                        <input style=\"width:68px\" formControlName=\"end_hrs_3\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                    </div>\n                    <div class=\"pt-2\">\n                      :\n                    </div>\n                  <div class=\"text-left\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"end_min_3\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                      </div>\n                  </div>\n                </div>\n                </div>\n              </div>\n\n                <div class=\"form-group\">\n                 <label  class=\"d-block\">Enter Number Of Forwarding Location:</label>\n                 <input formControlName=\"noofforwardinglocation_4\" [(ngModel)]=\"noofforwardinglocation_4\" type=\"text\" class=\"form-control phone-number\">\n             </div>\n\n             <div class=\"groupborder\" *ngFor='let in of selectednoofforwardinglocation_4();let i = index'>\n               <div class=\"form-group\">\n                   <label class=\"d-block\">Primary Forwarding Location - {{i+1}}</label>\n                   <div class=\"form-check form-check-inline\">\n                       <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day3\" name=\"PrimaryforwardType_{{i}}_day3\" class=\"with-gap\" [value]='0' (click)=\"setPrimaryforward(0,i,3)\" [checked]=\"true\">\n\n                     <label class=\"form-check-label\" for=\"inlineradio1\">Number</label>\n                   </div>\n                   <div class=\"form-check form-check-inline\">\n                       <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day3\" name=\"PrimaryforwardType_{{i}}_day3\" (click)=\"setPrimaryforward(1,i,3)\" class=\"with-gap\" [value]=\"1\">\n                     <label class=\"form-check-label\" for=\"inlineradio2\">IVR Menu</label>\n                   </div>\n                   <div class=\"form-check form-check-inline\">\n                       <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day3\" name=\"PrimaryforwardType_{{i}}_day3\" class=\"with-gap\" (click)=\"setPrimaryforward(2,i,3)\" [value]=\"2\">\n                     <label class=\"form-check-label\" for=\"inlineCheckbox3\">SIP (IP Address)</label>\n                   </div>\n                 </div>\n                 <div class=\"form-group\" *ngIf=\"!isPrimarySelected(1,i,3) && !isPrimarySelected(2,i,3)\">\n                       <label  class=\"d-block\">Number:</label>\n                       <input type=\"text\" formControlName=\"number_{{i}}_day3\" id=\"number_{{i}}_day3\" class=\"form-control phone-number\" placeholder=\"(000) 000-000\"  maxlength=\"16\" (keypress)=_keyPress($event)>\n                 </div>\n                 <div class=\"form-group\" *ngIf=\"isPrimarySelected(1,i,3)\">\n                       <label  class=\"d-block\">IVR Menu:</label>\n                        <select formControlName=\"ivrMenu_{{i}}_day3\" class=\"form-control\" [value] = \"\">\n                             <option value=\"\">Select IVR Menu</option>\n                             <option *ngFor=\"let data of ivrmenus;\" [value]=\"data.uuid\">\n                                 {{data.name}}\n                               </option>\n                           </select>\n                   </div>\n                   <div class=\"form-group\" *ngIf=\"isPrimarySelected(2,i,3)\">\n                         <label  class=\"d-block\">SIP (IP Address):</label>\n                         <input  formControlName=\"sipAdd_{{i}}_day3\" type=\"text\" class=\"form-control phone-number\">\n                   </div>\n             </div>\n              </div>\n              </div>\n          </div>\n          </div>\n\n          <!-- Day 5 -->\n          <div class=\"groupborder\" *ngIf=\"noofforwarding>=5\">\n              <div >\n                <div class=\"form-group\">\n                    <label>Select Timeframe - 5</label>\n                    <select formControlName=\"day_4\" class=\"form-control\" [value]=\"0\" >\n                      <option value=\"0\">Select Day</option>\n                      <option *ngFor=\"let item of allweekdays\" value=\"{{item.id}}\">{{item.start_day}} to {{item.end_day}}</option>\n                      </select>\n\n                  </div>\n                <div class=\"row\">\n                <div class=\"col-md-12\">\n                <!-- <div class=\"row\">\n                  <div class=\"col-md-6\">\n                      <div class=\"form-group\">\n                          <label>Start Time</label>\n                          <input formControlName=\"start_time_4\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\" placeholder=\"Ex :00:00\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time>\n                      </div>\n                  </div>\n                  <div class=\"col-md-6\">\n                      <div class=\"form-group\">\n                          <label>End Time</label>\n                          <input formControlName=\"end_time_4\" [owlDateTimeTrigger]=\"dt1\" class=\"form-control\" [owlDateTime]=\"dt1\" placeholder=\"Ex :00:00\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt1></owl-date-time>\n                      </div>\n                  </div>\n                </div>                  -->\n\n\n              <div class=\"row\">\n                <div class=\"col-md-3\">\n                    <label>Start Time (HH:MM)</label><br>\n                      <div  style=\"display:-webkit-inline-box\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"start_hrs_4\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                          <!-- <input formControlName=\"start_time_0\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time> -->\n                      </div>\n                      <div class=\"pt-2\">\n                        :\n                      </div>\n                    <div class=\"text-left\">\n                        <div class=\"form-group\">\n                            <input style=\"width:68px\" formControlName=\"start_min_4\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                        </div>\n                    </div>\n                  </div>\n                </div>\n\n                <div class=\"col-md-4\">\n                  <label>End Time (HH:MM)</label><br>\n                    <div  style=\"display:-webkit-inline-box\">\n                    <div class=\"form-group\">\n                        <input style=\"width:68px\" formControlName=\"end_hrs_4\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                    </div>\n                    <div class=\"pt-2\">\n                      :\n                    </div>\n                  <div class=\"text-left\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"end_min_4\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                      </div>\n                  </div>\n                </div>\n                </div>\n              </div>\n                <div class=\"form-group\">\n                 <label  class=\"d-block\">Enter Number Of Forwarding Location:</label>\n                 <input formControlName=\"noofforwardinglocation_5\" [(ngModel)]=\"noofforwardinglocation_5\" type=\"text\" class=\"form-control phone-number\">\n             </div>\n\n             <div class=\"groupborder\" *ngFor='let in of selectednoofforwardinglocation_5();let i = index'>\n               <div class=\"form-group\">\n                   <label class=\"d-block\">Primary Forwarding Location - {{i+1}}</label>\n                   <div class=\"form-check form-check-inline\">\n                       <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day4\" name=\"PrimaryforwardType_{{i}}_day4\" class=\"with-gap\" [value]='0' (click)=\"setPrimaryforward(0,i,4)\" [checked]=\"true\">\n\n                     <label class=\"form-check-label\" for=\"inlineradio1\">Number</label>\n                   </div>\n                   <div class=\"form-check form-check-inline\">\n                       <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day4\" name=\"PrimaryforwardType_{{i}}_day4\" (click)=\"setPrimaryforward(1,i,4)\" class=\"with-gap\" [value]=\"1\">\n                     <label class=\"form-check-label\" for=\"inlineradio2\">IVR Menu</label>\n                   </div>\n                   <div class=\"form-check form-check-inline\">\n                       <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day4\" name=\"PrimaryforwardType_{{i}}_day4\" class=\"with-gap\" (click)=\"setPrimaryforward(2,i,4)\" [value]=\"2\">\n                     <label class=\"form-check-label\" for=\"inlineCheckbox3\">SIP (IP Address)</label>\n                   </div>\n                 </div>\n                 <div class=\"form-group\" *ngIf=\"!isPrimarySelected(1,i,4) && !isPrimarySelected(2,i,4)\">\n                       <label  class=\"d-block\">Number:</label>\n                       <input type=\"text\" formControlName=\"number_{{i}}_day4\" id=\"number_{{i}}_day4\" class=\"form-control phone-number\" placeholder=\"(000) 000-000\"  maxlength=\"16\" (keypress)=_keyPress($event)>\n                 </div>\n                 <div class=\"form-group\" *ngIf=\"isPrimarySelected(1,i,4)\">\n                       <label  class=\"d-block\">IVR Menu:</label>\n                        <select formControlName=\"ivrMenu_{{i}}_day4\" class=\"form-control\" [value] = \"\">\n                             <option value=\"\">Select IVR Menu</option>\n                             <option *ngFor=\"let data of ivrmenus;\" [value]=\"data.uuid\">\n                                 {{data.name}}\n                               </option>\n                           </select>\n                   </div>\n                   <div class=\"form-group\" *ngIf=\"isPrimarySelected(2,i,4)\">\n                         <label  class=\"d-block\">SIP (IP Address):</label>\n                         <input  formControlName=\"sipAdd_{{i}}_day4\" type=\"text\" class=\"form-control phone-number\">\n                   </div>\n             </div>\n              </div>\n              </div>\n          </div>\n          </div>\n\n          <!-- Day 6 -->\n          <div class=\"groupborder\" *ngIf=\"noofforwarding>=6\">\n            <div >\n              <div class=\"form-group\">\n                  <label>Select Timeframe - 6</label>\n                  <select formControlName=\"day_5\" class=\"form-control\" [value]=\"0\" >\n                    <option value=\"0\">Select Day</option>\n                    <option *ngFor=\"let item of allweekdays\" value=\"{{item.id}}\">{{item.start_day}} to {{item.end_day}}</option>\n                    </select>\n\n                </div>\n              <div class=\"row\">\n              <div class=\"col-md-12\">\n              <!-- <div class=\"row\">\n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                        <label>Start Time</label>\n                        <input formControlName=\"start_time_5\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\" placeholder=\"Ex :00:00\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time>\n                    </div>\n                </div>\n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                        <label>End Time</label>\n                        <input formControlName=\"end_time_5\" [owlDateTimeTrigger]=\"dt1\" class=\"form-control\" [owlDateTime]=\"dt1\" placeholder=\"Ex :00:00\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt1></owl-date-time>\n                    </div>\n                </div>\n              </div>  -->\n\n\n              <div class=\"row\">\n                <div class=\"col-md-3\">\n                    <label>Start Time (HH:MM)</label><br>\n                      <div  style=\"display:-webkit-inline-box\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"start_hrs_5\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                          <!-- <input formControlName=\"start_time_0\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time> -->\n                      </div>\n                      <div class=\"pt-2\">\n                        :\n                      </div>\n                    <div class=\"text-left\">\n                        <div class=\"form-group\">\n                            <input style=\"width:68px\" formControlName=\"start_min_5\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                        </div>\n                    </div>\n                  </div>\n                </div>\n\n                <div class=\"col-md-4\">\n                  <label>End Time (HH:MM)</label><br>\n                    <div  style=\"display:-webkit-inline-box\">\n                    <div class=\"form-group\">\n                        <input style=\"width:68px\" formControlName=\"end_hrs_5\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                    </div>\n                    <div class=\"pt-2\">\n                      :\n                    </div>\n                  <div class=\"text-left\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"end_min_5\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                      </div>\n                  </div>\n                </div>\n                </div>\n              </div>\n              <div class=\"form-group\">\n               <label  class=\"d-block\">Enter Number Of Forwarding Location:</label>\n               <input formControlName=\"noofforwardinglocation_6\" [(ngModel)]=\"noofforwardinglocation_6\" type=\"text\" class=\"form-control phone-number\">\n           </div>\n\n           <div class=\"groupborder\" *ngFor='let in of selectednoofforwardinglocation_6();let i = index'>\n             <div class=\"form-group\">\n                 <label class=\"d-block\">Primary Forwarding Location - {{i+1}}</label>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day5\" name=\"PrimaryforwardType_{{i}}_day5\" class=\"with-gap\" [value]='0' (click)=\"setPrimaryforward(0,i,5)\" [checked]=\"true\">\n\n                   <label class=\"form-check-label\" for=\"inlineradio1\">Number</label>\n                 </div>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day5\" name=\"PrimaryforwardType_{{i}}_day5\" (click)=\"setPrimaryforward(1,i,5)\" class=\"with-gap\" [value]=\"1\">\n                   <label class=\"form-check-label\" for=\"inlineradio2\">IVR Menu</label>\n                 </div>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day5\" name=\"PrimaryforwardType_{{i}}_day5\" class=\"with-gap\" (click)=\"setPrimaryforward(2,i,5)\" [value]=\"2\">\n                   <label class=\"form-check-label\" for=\"inlineCheckbox3\">SIP (IP Address)</label>\n                 </div>\n               </div>\n               <div class=\"form-group\" *ngIf=\"!isPrimarySelected(1,i,5) && !isPrimarySelected(2,i,5)\">\n                     <label  class=\"d-block\">Number:</label>\n                     <input type=\"text\" formControlName=\"number_{{i}}_day5\" id=\"number_{{i}}_day5\" class=\"form-control phone-number\" placeholder=\"(000) 000-000\"  maxlength=\"16\" (keypress)=_keyPress($event)>\n               </div>\n               <div class=\"form-group\" *ngIf=\"isPrimarySelected(1,i,5)\">\n                     <label  class=\"d-block\">IVR Menu:</label>\n                      <select formControlName=\"ivrMenu_{{i}}_day5\" class=\"form-control\" [value] = \"\">\n                           <option value=\"\">Select IVR Menu</option>\n                           <option *ngFor=\"let data of ivrmenus;\" [value]=\"data.uuid\">\n                               {{data.name}}\n                             </option>\n                         </select>\n                 </div>\n                 <div class=\"form-group\" *ngIf=\"isPrimarySelected(2,i,5)\">\n                       <label  class=\"d-block\">SIP (IP Address):</label>\n                       <input  formControlName=\"sipAdd_{{i}}_day5\" type=\"text\" class=\"form-control phone-number\">\n                 </div>\n           </div>\n            </div>\n            </div>\n        </div>\n        </div>\n\n        <!-- Day 7 -->\n        <div class=\"groupborder\" *ngIf=\"noofforwarding>=7\">\n          <div >\n            <div class=\"form-group\">\n                <label>Select Timeframe - 7</label>\n                <select formControlName=\"day_6\" class=\"form-control\" [value]=\"0\" >\n                  <option value=\"0\">Select Day</option>\n                  <option *ngFor=\"let item of allweekdays\" value=\"{{item.id}}\">{{item.start_day}} to {{item.end_day}}</option>\n                  </select>\n\n              </div>\n            <div class=\"row\">\n            <div class=\"col-md-12\">\n            <!-- <div class=\"row\">\n              <div class=\"col-md-6\">\n                  <div class=\"form-group\">\n                      <label>Start Time</label>\n                      <input formControlName=\"start_time_6\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\" placeholder=\"Ex :00:00\">\n                      <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time>\n                  </div>\n              </div>\n              <div class=\"col-md-6\">\n                  <div class=\"form-group\">\n                      <label>End Time</label>\n                      <input formControlName=\"end_time_6\" [owlDateTimeTrigger]=\"dt1\" class=\"form-control\" [owlDateTime]=\"dt1\" placeholder=\"Ex :00:00\">\n                      <owl-date-time [pickerType]=\"'timer'\" #dt1></owl-date-time>\n                  </div>\n              </div>\n            </div>               -->\n\n\n            <div class=\"row\">\n              <div class=\"col-md-3\">\n                  <label>Start Time (HH:MM)</label><br>\n                    <div  style=\"display:-webkit-inline-box\">\n                    <div class=\"form-group\">\n                        <input style=\"width:68px\" formControlName=\"start_hrs_6\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                        <!-- <input formControlName=\"start_time_0\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time> -->\n                    </div>\n                    <div class=\"pt-2\">\n                      :\n                    </div>\n                  <div class=\"text-left\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"start_min_6\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                      </div>\n                  </div>\n                </div>\n              </div>\n\n              <div class=\"col-md-4\">\n                <label>End Time (HH:MM)</label><br>\n                  <div  style=\"display:-webkit-inline-box\">\n                  <div class=\"form-group\">\n                      <input style=\"width:68px\" formControlName=\"end_hrs_6\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                  </div>\n                  <div class=\"pt-2\">\n                    :\n                  </div>\n                <div class=\"text-left\">\n                    <div class=\"form-group\">\n                        <input style=\"width:68px\" formControlName=\"end_min_6\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                    </div>\n                </div>\n              </div>\n              </div>\n            </div>\n            <div class=\"form-group\">\n             <label  class=\"d-block\">Enter Number Of Forwarding Location:</label>\n             <input formControlName=\"noofforwardinglocation_7\" [(ngModel)]=\"noofforwardinglocation_7\" type=\"text\" class=\"form-control phone-number\">\n         </div>\n\n         <div class=\"groupborder\" *ngFor='let in of selectednoofforwardinglocation_7();let i = index'>\n           <div class=\"form-group\">\n               <label class=\"d-block\">Primary Forwarding Location - {{i+1}}</label>\n               <div class=\"form-check form-check-inline\">\n                   <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day6\" name=\"PrimaryforwardType_{{i}}_day6\" class=\"with-gap\" [value]='0' (click)=\"setPrimaryforward(0,i,6)\" [checked]=\"true\">\n\n                 <label class=\"form-check-label\" for=\"inlineradio1\">Number</label>\n               </div>\n               <div class=\"form-check form-check-inline\">\n                   <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day6\" name=\"PrimaryforwardType_{{i}}_day6\" (click)=\"setPrimaryforward(1,i,6)\" class=\"with-gap\" [value]=\"1\">\n                 <label class=\"form-check-label\" for=\"inlineradio2\">IVR Menu</label>\n               </div>\n               <div class=\"form-check form-check-inline\">\n                   <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day6\" name=\"PrimaryforwardType_{{i}}_day6\" class=\"with-gap\" (click)=\"setPrimaryforward(2,i,6)\" [value]=\"2\">\n                 <label class=\"form-check-label\" for=\"inlineCheckbox3\">SIP (IP Address)</label>\n               </div>\n             </div>\n             <div class=\"form-group\" *ngIf=\"!isPrimarySelected(1,i,6) && !isPrimarySelected(2,i,6)\">\n                   <label  class=\"d-block\">Number:</label>\n                   <input type=\"text\" formControlName=\"number_{{i}}_day6\" id=\"number_{{i}}_day6\" class=\"form-control phone-number\" placeholder=\"(000) 000-000\"  maxlength=\"16\" (keypress)=_keyPress($event)>\n             </div>\n             <div class=\"form-group\" *ngIf=\"isPrimarySelected(1,i,6)\">\n                   <label  class=\"d-block\">IVR Menu:</label>\n                    <select formControlName=\"ivrMenu_{{i}}_day6\" class=\"form-control\" [value] = \"\">\n                         <option value=\"\">Select IVR Menu</option>\n                         <option *ngFor=\"let data of ivrmenus;\" [value]=\"data.uuid\">\n                             {{data.name}}\n                           </option>\n                       </select>\n               </div>\n               <div class=\"form-group\" *ngIf=\"isPrimarySelected(2,i,6)\">\n                     <label  class=\"d-block\">SIP (IP Address):</label>\n                     <input  formControlName=\"sipAdd_{{i}}_day6\" type=\"text\" class=\"form-control phone-number\">\n               </div>\n         </div>\n          </div>\n          </div>\n      </div>\n      </div>\n\n        <div class=\"modal-footer\" style=\"padding: 0;\">\n           <button [disabled]=\"isName == 'fail'\" type=\"submit\" (click)=\"closeModal()\" class=\"btn btn-primary m-t-15 waves-effect\">Create New Target</button>\n           <button (click)=\"onFSLReset()\" type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\">Reset</button>\n        </div>\n      </form>\n    </div>\n  </div>\n</div>\n</div>\n\n<div class=\"modal  fade\" id=\"editFSLRules\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\" aria-hidden=\"true\" *ngIf=\"forwarding?.length != 0\">\n<div class=\"modal-dialog modal-lg\" role=\"document\">\n  <div class=\"modal-content\">\n    <div class=\"modal-header\">\n      <h5 class=\"modal-title\" id=\"formModal\">Edit Target</h5>\n      <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n        <span aria-hidden=\"true\">&times;</span>\n      </button>\n    </div>\n    <div class=\"modal-body\">\n      <form class=\"\"  [formGroup]=\"editFSLRules\" (ngSubmit)=\"onFSLEditSubmit()\">\n\n        <div class=\"form-group\">\n            <label>Name</label>\n            <input formControlName=\"rulename\" type=\"text\" class=\"form-control\" [value] =\"forwarding\" readonly>\n        </div>\n\n          <div class=\"form-group\">\n            <label  class=\"d-block\">Number of Time Frames:</label>\n            <input formControlName=\"numberoftimeframe\"  oninput=\"javascript: if (this.value.length > this.maxLength) this.value = this.value.slice(0, this.maxLength);\"\n            type = \"number\" maxlength = \"1\" [(ngModel)]=\"noofforwarding\" type=\"number\" class=\"form-control phone-number\" [ngClass]=\"{ 'is-invalid': FSLRulesEditSubmitted && editrules.numberoftimeframe.errors }\" [value] =\"forwardingtimeframe\">\n            <div *ngIf=\"FSLRulesEditSubmitted && editrules.numberoftimeframe.errors\" class=\"invalid-feedback\">\n              <div *ngIf=\"editrules.numberoftimeframe.errors.required\">Number of Time Frames is required</div>\n          </div>\n          </div>\n\n          <br>\n          <!-- Day 1 -->\n          <div class=\"groupborder\" *ngIf=\"noofforwarding>=1\">\n            <div >\n              <div class=\"form-group\">\n                  <label>Select Timeframe - 1</label>\n                  <select formControlName=\"day_0\" name=\"day-0\" id=\"day-0\" class=\"form-control\" >\n                    <option value=\"0\">Select Day</option>\n                    <option *ngFor=\"let item of allweekdays\" value=\"{{item.id}}\">{{item.start_day}} to {{item.end_day}}</option>\n                  </select>\n                </div>\n              <div class=\"row\">\n              <div class=\"col-md-12\">\n\n              <div class=\"row\">\n                <div class=\"col-md-3\">\n                    <label>Start Time (HH:MM)</label><br>\n                      <div  style=\"display:-webkit-inline-box\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"start_hrs_0\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                          <!-- <input formControlName=\"start_time_0\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time> -->\n                      </div>\n                      <div class=\"pt-2\">\n                        :\n                      </div>\n                    <div class=\"text-left\">\n                        <div class=\"form-group\">\n                            <input style=\"width:68px\" formControlName=\"start_min_0\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                        </div>\n                    </div>\n                  </div>\n                </div>\n\n                <div class=\"col-md-4\">\n                  <label>End Time (HH:MM)</label><br>\n                    <div  style=\"display:-webkit-inline-box\">\n                    <div class=\"form-group\">\n                        <input style=\"width:68px\" formControlName=\"end_hrs_0\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                    </div>\n                    <div class=\"pt-2\">\n                      :\n                    </div>\n                  <div class=\"text-left\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"end_min_0\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                      </div>\n                  </div>\n                </div>\n                </div>\n              </div>\n\n              <div>\n\n               <div class=\"form-group\">\n                   <label  class=\"d-block\">Enter Number Of Forwarding Location:</label>\n                   <input formControlName=\"noofforwardinglocation_1\" type=\"text\" class=\"form-control phone-number\" [(ngModel)]=\"noofforwardinglocation_1\">\n               </div>\n\n               <div class=\"groupborder\" *ngFor='let in of selectednoofforwardinglocation();let i = index'>\n                 <div class=\"form-group\">\n                     <label class=\"d-block\">Primary Forwarding Location - {{i+1}}</label>\n                     <div class=\"form-check form-check-inline\">\n                         <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day0\" name=\"PrimaryforwardType_{{i}}_day0\" class=\"with-gap\" [value]='0' (click)=\"setPrimaryforward(0,i,0)\">\n                        <label class=\"form-check-label\" for=\"inlineradio1\">Number</label>\n                     </div>\n                     <div class=\"form-check form-check-inline\">\n                         <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day0\" name=\"PrimaryforwardType_{{i}}_day0\" (click)=\"setPrimaryforward(1,i,0)\" class=\"with-gap\" [value]=\"1\">\n                       <label class=\"form-check-label\" for=\"\">IVR Menu</label>\n                     </div>\n                     <div class=\"form-check form-check-inline\">\n                         <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day0\" name=\"PrimaryforwardType_{{i}}_day0\" class=\"with-gap\" (click)=\"setPrimaryforward(2,i,0)\" [value]=\"2\">\n                       <label class=\"form-check-label\" for=\"\">SIP (IP Address)</label>\n                     </div>\n                   </div>\n                   <div class=\"form-group\" *ngIf=\"!isPrimarySelected(1,i,0) && !isPrimarySelected(2,i,0)\">\n                         <label  class=\"d-block\">Number:</label>\n                         <input type=\"text\" formControlName=\"number_{{i}}_day0\" id=\"editnumber_{{i}}_day0\" class=\"form-control phone-number numbers\" placeholder=\"(000) 000-000\"  maxlength=\"16\" (keypress)=_keyPress($event)>\n                   </div>\n                   <div class=\"form-group\" *ngIf=\"isPrimarySelected(1,i,0)\">\n                         <label  class=\"d-block\">IVR Menu:</label>\n                           <select formControlName=\"ivrMenu_{{i}}_day0\" class=\"form-control\" [value] = \"\">\n                               <option value=\"\">Select IVR Menu</option>\n                               <option *ngFor=\"let data of ivrmenus;\" [value]=\"data.uuid\">\n                                   {{data.name}}\n                                 </option>\n                          </select>\n                     </div>\n                     <div class=\"form-group\" *ngIf=\"isPrimarySelected(2,i,0)\">\n                           <label  class=\"d-block\">SIP (IP Address):</label>\n                           <input  formControlName=\"sipAdd_{{i}}_day0\" type=\"text\" class=\"form-control phone-number\">\n                     </div>\n               </div>\n               </div>\n\n           </div>\n           </div>\n        </div>\n           </div>\n\n          <!-- Day 2 -->\n           <div class=\"groupborder\" *ngIf=\"noofforwarding>=2\">\n            <div >\n              <div class=\"form-group\">\n                  <label>Select Timeframe - 2</label>\n                  <select formControlName=\"day_1\" class=\"form-control\">\n                    <option value=\"0\">Select Day</option>\n                    <option *ngFor=\"let item of allweekdays\" value=\"{{item.id}}\">{{item.start_day}} to {{item.end_day}}</option>\n                    </select>\n                </div>\n              <div class=\"row\">\n              <div class=\"col-md-12\">\n              <!-- <div class=\"row\">\n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                        <label>Start Time</label>\n                        <input formControlName=\"start_time_1\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\" placeholder=\"Ex :00:00\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time>\n                    </div>\n                </div>\n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                        <label>End Time</label>\n                        <input formControlName=\"end_time_1\" [owlDateTimeTrigger]=\"dt1\" class=\"form-control\" [owlDateTime]=\"dt1\" placeholder=\"Ex :00:00\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt1></owl-date-time>\n                    </div>\n                </div>\n              </div>  -->\n\n              <div class=\"row\">\n                <div class=\"col-md-3\">\n                    <label>Start Time (HH:MM)</label><br>\n                      <div  style=\"display:-webkit-inline-box\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"start_hrs_1\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                          <!-- <input formControlName=\"start_time_0\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time> -->\n                      </div>\n                      <div class=\"pt-2\">\n                        :\n                      </div>\n                    <div class=\"text-left\">\n                        <div class=\"form-group\">\n                            <input style=\"width:68px\" formControlName=\"start_min_1\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                        </div>\n                    </div>\n                  </div>\n                </div>\n\n                <div class=\"col-md-4\">\n                  <label>End Time (HH:MM)</label><br>\n                    <div  style=\"display:-webkit-inline-box\">\n                    <div class=\"form-group\">\n                        <input style=\"width:68px\" formControlName=\"end_hrs_1\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                    </div>\n                    <div class=\"pt-2\">\n                      :\n                    </div>\n                  <div class=\"text-left\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"end_min_1\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                      </div>\n                  </div>\n                </div>\n                </div>\n              </div>\n\n              <div class=\"form-group\">\n               <label  class=\"d-block\">Enter Number Of Forwarding Location:</label>\n               <input formControlName=\"noofforwardinglocation_2\" type=\"text\" class=\"form-control phone-number\" [(ngModel)]=\"noofforwardinglocation_2\">\n           </div>\n\n           <div class=\"groupborder\" *ngFor='let in of selectednoofforwardinglocation_2();let i = index'>\n             <div class=\"form-group\">\n                 <label class=\"d-block\">Primary Forwarding Location - {{i+1}}</label>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day1\" name=\"PrimaryforwardType_{{i}}_day1\" id=\"PrimaryforwardType_{{i}}_day1\" class=\"with-gap\" [value]='0' (click)=\"setPrimaryforward(0,i,1)\">\n\n                   <label class=\"form-check-label\" for=\"inlineradio1\">Number</label>\n                 </div>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day1\" name=\"PrimaryforwardType_{{i}}_day1\" (click)=\"setPrimaryforward(1,i,1)\" class=\"with-gap\" [value]=\"1\">\n                   <label class=\"form-check-label\" for=\"inlineradio2\">IVR Menu</label>\n                 </div>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day1\" name=\"PrimaryforwardType_{{i}}_day1\" class=\"with-gap\" (click)=\"setPrimaryforward(2,i,1)\" [value]=\"2\">\n                   <label class=\"form-check-label\" for=\"inlineCheckbox3\">SIP (IP Address)</label>\n                 </div>\n               </div>\n               <div class=\"form-group\" *ngIf=\"!isPrimarySelected(1,i,1) && !isPrimarySelected(2,i,1)\">\n                     <label  class=\"d-block\">Number:</label>\n                     <input type=\"text\" formControlName=\"number_{{i}}_day1\" id=\"editnumber_{{i}}_day1\" class=\"form-control phone-number\" placeholder=\"(000) 000-000\"  maxlength=\"16\" (keypress)=_keyPress($event)>\n               </div>\n               <div class=\"form-group\" *ngIf=\"isPrimarySelected(1,i,1)\">\n                     <label  class=\"d-block\">IVR Menu:</label>\n                       <select formControlName=\"ivrMenu_{{i}}_day1\" class=\"form-control\" [value] = \"\">\n                           <option value=\"\">Select IVR Menu</option>\n                           <option *ngFor=\"let data of ivrmenus;\" [value]=\"data.uuid\">\n                               {{data.name}}\n                             </option>\n                         </select>\n                 </div>\n                 <div class=\"form-group\" *ngIf=\"isPrimarySelected(2,i,1)\">\n                       <label  class=\"d-block\">SIP (IP Address):</label>\n                       <input  formControlName=\"sipAdd_{{i}}_day1\" type=\"text\" class=\"form-control phone-number\">\n                 </div>\n           </div>\n            </div>\n           </div>\n        </div>\n            </div>\n\n          <!-- Day 3 -->\n          <div class=\"groupborder\" *ngIf=\"noofforwarding>=3\">\n            <div >\n              <div class=\"form-group\">\n                  <label>Select Timeframe - 3</label>\n                  <select formControlName=\"day_2\" class=\"form-control\" >\n                    <option value=\"0\">Select Day</option>\n                    <option *ngFor=\"let item of allweekdays\" value=\"{{item.id}}\">{{item.start_day}} to {{item.end_day}}</option>\n                    </select>\n\n                </div>\n              <div class=\"row\">\n              <div class=\"col-md-12\">\n              <!-- <div class=\"row\">\n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                        <label>Start Time</label>\n                        <input formControlName=\"start_time_2\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\" placeholder=\"Ex :00:00\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time>\n                    </div>\n                </div>\n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                        <label>End Time</label>\n                        <input formControlName=\"end_time_2\" [owlDateTimeTrigger]=\"dt1\" class=\"form-control\" [owlDateTime]=\"dt1\" placeholder=\"Ex :00:00\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt1></owl-date-time>\n                    </div>\n                </div>\n              </div>   -->\n\n              <div class=\"row\">\n                <div class=\"col-md-3\">\n                    <label>Start Time (HH:MM)</label><br>\n                      <div  style=\"display:-webkit-inline-box\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"start_hrs_2\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                          <!-- <input formControlName=\"start_time_0\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time> -->\n                      </div>\n                      <div class=\"pt-2\">\n                        :\n                      </div>\n                    <div class=\"text-left\">\n                        <div class=\"form-group\">\n                            <input style=\"width:68px\" formControlName=\"start_min_2\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                        </div>\n                    </div>\n                  </div>\n                </div>\n\n                <div class=\"col-md-4\">\n                  <label>End Time (HH:MM)</label><br>\n                    <div  style=\"display:-webkit-inline-box\">\n                    <div class=\"form-group\">\n                        <input style=\"width:68px\" formControlName=\"end_hrs_2\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                    </div>\n                    <div class=\"pt-2\">\n                      :\n                    </div>\n                  <div class=\"text-left\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"end_min_2\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                      </div>\n                  </div>\n                </div>\n                </div>\n              </div>\n              <div class=\"form-group\">\n               <label  class=\"d-block\">Enter Number Of Forwarding Location:</label>\n               <input formControlName=\"noofforwardinglocation_3\" type=\"text\" class=\"form-control phone-number\" [(ngModel)]=\"noofforwardinglocation_3\">\n           </div>\n\n           <div class=\"groupborder\" *ngFor='let in of selectednoofforwardinglocation_3();let i = index'>\n             <div class=\"form-group\">\n                 <label class=\"d-block\">Primary Forwarding Location - {{i+1}}</label>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day2\" name=\"PrimaryforwardType_{{i}}_day2\" class=\"with-gap\" [value]='0' (click)=\"setPrimaryforward(0,i,2)\">\n\n                   <label class=\"form-check-label\" for=\"inlineradio1\">Number</label>\n                 </div>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day2\" name=\"PrimaryforwardType_{{i}}_day2\"  (click)=\"setPrimaryforward(1,i,2)\" class=\"with-gap\" [value]=\"1\">\n                   <label class=\"form-check-label\" for=\"inlineradio2\">IVR Menu</label>\n                 </div>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day2\" name=\"PrimaryforwardType_{{i}}_day2\" class=\"with-gap\" (click)=\"setPrimaryforward(2,i,2)\" [value]=\"2\">\n                   <label class=\"form-check-label\" for=\"inlineCheckbox3\">SIP (IP Address)</label>\n                 </div>\n               </div>\n               <div class=\"form-group\" *ngIf=\"!isPrimarySelected(1,i,2) && !isPrimarySelected(2,i,2)\">\n                     <label  class=\"d-block\">Number:</label>\n                     <input type=\"text\" formControlName=\"number_{{i}}_day2\" id=\"editnumber_{{i}}_day2\" class=\"form-control phone-number\" placeholder=\"(000) 000-000\"  maxlength=\"16\" (keypress)=_keyPress($event)>\n               </div>\n               <div class=\"form-group\" *ngIf=\"isPrimarySelected(1,i,2)\">\n                     <label  class=\"d-block\">IVR Menu:</label>\n                       <select formControlName=\"ivrMenu_{{i}}_day2\" class=\"form-control\" [value] = \"\">\n                           <option\n                            value=\"\">Select IVR Menu</option\n                            >\n                           <option *ngFor=\"let data of ivrmenus;\" [value]=\"data.uuid\">\n                               {{data.name}}\n                             </option>\n                         </select>\n                 </div>\n                 <div class=\"form-group\" *ngIf=\"isPrimarySelected(2,i,2)\">\n                       <label  class=\"d-block\">SIP (IP Address):</label>\n                       <input  formControlName=\"sipAdd_{{i}}_day2\" type=\"text\" class=\"form-control phone-number\">\n                 </div>\n           </div>\n            </div>\n            </div>\n        </div>\n          </div>\n\n          <!-- Day 4 -->\n          <div class=\"groupborder\" *ngIf=\"noofforwarding>=4\">\n              <div >\n                <div class=\"form-group\">\n                    <label>Select Timeframe - 4</label>\n                    <select formControlName=\"day_3\" class=\"form-control\">\n                      <option value=\"0\">Select Day</option>\n                      <option *ngFor=\"let item of allweekdays\" value=\"{{item.id}}\">{{item.start_day}} to {{item.end_day}}</option>\n                      </select>\n\n                  </div>\n                <div class=\"row\">\n                <div class=\"col-md-12\">\n                <!-- <div class=\"row\">\n                  <div class=\"col-md-6\">\n                      <div class=\"form-group\">\n                          <label>Start Time</label>\n                          <input formControlName=\"start_time_3\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\" placeholder=\"Ex :00:00\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time>\n                      </div>\n                  </div>\n                  <div class=\"col-md-6\">\n                      <div class=\"form-group\">\n                          <label>End Time</label>\n                          <input formControlName=\"end_time_3\" [owlDateTimeTrigger]=\"dt1\" class=\"form-control\" [owlDateTime]=\"dt1\" placeholder=\"Ex :00:00\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt1></owl-date-time>\n                      </div>\n                  </div>\n                </div>   -->\n                <div class=\"row\">\n                  <div class=\"col-md-3\">\n                      <label>Start Time (HH:MM)</label><br>\n                        <div  style=\"display:-webkit-inline-box\">\n                        <div class=\"form-group\">\n                            <input style=\"width:68px\" formControlName=\"start_hrs_3\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                            <!-- <input formControlName=\"start_time_0\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\">\n                            <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time> -->\n                        </div>\n                        <div class=\"pt-2\">\n                          :\n                        </div>\n                      <div class=\"text-left\">\n                          <div class=\"form-group\">\n                              <input style=\"width:68px\" formControlName=\"start_min_3\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                          </div>\n                      </div>\n                    </div>\n                  </div>\n\n                  <div class=\"col-md-4\">\n                    <label>End Time (HH:MM)</label><br>\n                      <div  style=\"display:-webkit-inline-box\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"end_hrs_3\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                      </div>\n                      <div class=\"pt-2\">\n                        :\n                      </div>\n                    <div class=\"text-left\">\n                        <div class=\"form-group\">\n                            <input style=\"width:68px\" formControlName=\"end_min_3\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                        </div>\n                    </div>\n                  </div>\n                  </div>\n                </div>\n                <div class=\"form-group\">\n                 <label  class=\"d-block\">Enter Number Of Forwarding Location:</label>\n                 <input formControlName=\"noofforwardinglocation_4\" type=\"text\" class=\"form-control phone-number\" [(ngModel)]=\"noofforwardinglocation_4\">\n             </div>\n\n             <div class=\"groupborder\" *ngFor='let in of selectednoofforwardinglocation_4();let i = index'>\n               <div class=\"form-group\">\n                   <label class=\"d-block\">Primary Forwarding Location - {{i+1}}</label>\n                   <div class=\"form-check form-check-inline\">\n                       <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day3\" name=\"PrimaryforwardType_{{i}}_day3\" class=\"with-gap\" [value]='0' (click)=\"setPrimaryforward(0,i,3)\">\n\n                     <label class=\"form-check-label\" for=\"inlineradio1\">Number</label>\n                   </div>\n                   <div class=\"form-check form-check-inline\">\n                       <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day3\" name=\"PrimaryforwardType_{{i}}_day3\" (click)=\"setPrimaryforward(1,i,3)\" class=\"with-gap\" [value]=\"1\">\n                     <label class=\"form-check-label\" for=\"inlineradio2\">IVR Menu</label>\n                   </div>\n                   <div class=\"form-check form-check-inline\">\n                       <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day3\" name=\"PrimaryforwardType_{{i}}_day3\" class=\"with-gap\" (click)=\"setPrimaryforward(2,i,3)\" [value]=\"2\">\n                     <label class=\"form-check-label\" for=\"inlineCheckbox3\">SIP (IP Address)</label>\n                   </div>\n                 </div>\n                 <div class=\"form-group\" *ngIf=\"!isPrimarySelected(1,i,3) && !isPrimarySelected(2,i,3)\">\n                       <label  class=\"d-block\">Number:</label>\n                       <input type=\"text\" formControlName=\"number_{{i}}_day3\" id=\"editnumber_{{i}}_day3\" class=\"form-control phone-number\" placeholder=\"(000) 000-000\"  maxlength=\"16\" (keypress)=_keyPress($event)>\n                 </div>\n                 <div class=\"form-group\" *ngIf=\"isPrimarySelected(1,i,3)\">\n                       <label  class=\"d-block\">IVR Menu:</label>\n                         <select formControlName=\"ivrMenu_{{i}}_day3\" class=\"form-control\" [value] = \"\">\n                             <option value=\"\">Select IVR Menu</option>\n                             <option *ngFor=\"let data of ivrmenus;\" [value]=\"data.uuid\">\n                                 {{data.name}}\n                               </option>\n                           </select>\n                   </div>\n                   <div class=\"form-group\" *ngIf=\"isPrimarySelected(2,i,3)\">\n                         <label  class=\"d-block\">SIP (IP Address):</label>\n                         <input  formControlName=\"sipAdd_{{i}}_day3\" type=\"text\" class=\"form-control phone-number\">\n                   </div>\n             </div>\n              </div>\n              </div>\n          </div>\n          </div>\n\n          <!-- Day 5 -->\n          <div class=\"groupborder\" *ngIf=\"noofforwarding>=5\">\n              <div >\n                <div class=\"form-group\">\n                    <label>Select Timeframe - 5</label>\n                    <select formControlName=\"day_4\" class=\"form-control\">\n                      <option value=\"0\">Select Day</option>\n                      <option value=\"1\">Monday to Friday</option>\n                      <option value=\"2\">Monday to Saturday</option>\n                      <option value=\"3\">Monday to Monday</option>\n                      <option value=\"4\">Friday to Monday</option>\n                      <option value=\"5\">Saturday to Monday</option>\n                      </select>\n\n                  </div>\n                <div class=\"row\">\n                <div class=\"col-md-12\">\n                <!-- <div class=\"row\">\n                  <div class=\"col-md-6\">\n                      <div class=\"form-group\">\n                          <label>Start Time</label>\n                          <input formControlName=\"start_time_4\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\" placeholder=\"Ex :00:00\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time>\n                      </div>\n                  </div>\n                  <div class=\"col-md-6\">\n                      <div class=\"form-group\">\n                          <label>End Time</label>\n                          <input formControlName=\"end_time_4\" [owlDateTimeTrigger]=\"dt1\" class=\"form-control\" [owlDateTime]=\"dt1\" placeholder=\"Ex :00:00\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt1></owl-date-time>\n                      </div>\n                  </div>\n                </div>  -->\n\n                <div class=\"row\">\n                  <div class=\"col-md-3\">\n                      <label>Start Time (HH:MM)</label><br>\n                        <div  style=\"display:-webkit-inline-box\">\n                        <div class=\"form-group\">\n                            <input style=\"width:68px\" formControlName=\"start_hrs_4\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                            <!-- <input formControlName=\"start_time_0\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\">\n                            <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time> -->\n                        </div>\n                        <div class=\"pt-2\">\n                          :\n                        </div>\n                      <div class=\"text-left\">\n                          <div class=\"form-group\">\n                              <input style=\"width:68px\" formControlName=\"start_min_4\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                          </div>\n                      </div>\n                    </div>\n                  </div>\n\n                  <div class=\"col-md-4\">\n                    <label>End Time (HH:MM)</label><br>\n                      <div  style=\"display:-webkit-inline-box\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"end_hrs_4\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                      </div>\n                      <div class=\"pt-2\">\n                        :\n                      </div>\n                    <div class=\"text-left\">\n                        <div class=\"form-group\">\n                            <input style=\"width:68px\" formControlName=\"end_min_4\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                        </div>\n                    </div>\n                  </div>\n                  </div>\n                </div>\n                <div class=\"form-group\">\n                 <label  class=\"d-block\">Enter Number Of Forwarding Location:</label>\n                 <input formControlName=\"noofforwardinglocation_5\" type=\"text\" class=\"form-control phone-number\" [(ngModel)]=\"noofforwardinglocation_5\">\n             </div>\n\n             <div class=\"groupborder\" *ngFor='let in of selectednoofforwardinglocation_5();let i = index'>\n               <div class=\"form-group\">\n                   <label class=\"d-block\">Primary Forwarding Location - {{i+1}}</label>\n                   <div class=\"form-check form-check-inline\">\n                       <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day4\" name=\"PrimaryforwardType_{{i}}_day4\" class=\"with-gap\" [value]='0' (click)=\"setPrimaryforward(0,i,4)\">\n\n                     <label class=\"form-check-label\" for=\"inlineradio1\">Number</label>\n                   </div>\n                   <div class=\"form-check form-check-inline\">\n                       <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day4\" name=\"PrimaryforwardType_{{i}}_day4\" (click)=\"setPrimaryforward(1,i,4)\" class=\"with-gap\" [value]=\"1\">\n                     <label class=\"form-check-label\" for=\"inlineradio2\">IVR Menu</label>\n                   </div>\n                   <div class=\"form-check form-check-inline\">\n                       <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day4\" name=\"PrimaryforwardType_{{i}}_day4\" class=\"with-gap\" (click)=\"setPrimaryforward(2,i,4)\" [value]=\"2\">\n                     <label class=\"form-check-label\" for=\"inlineCheckbox3\">SIP (IP Address)</label>\n                   </div>\n                 </div>\n                 <div class=\"form-group\" *ngIf=\"!isPrimarySelected(1,i,4) && !isPrimarySelected(2,i,4)\">\n                       <label  class=\"d-block\">Number:</label>\n                       <input type=\"text\" formControlName=\"number_{{i}}_day4\" id=\"editnumber_{{i}}_day4\" class=\"form-control phone-number\" placeholder=\"(000) 000-000\"  maxlength=\"16\" (keypress)=_keyPress($event)>\n                 </div>\n                 <div class=\"form-group\" *ngIf=\"isPrimarySelected(1,i,4)\">\n                       <label  class=\"d-block\">IVR Menu:</label>\n                         <select formControlName=\"ivrMenu_{{i}}_day4\" class=\"form-control\" [value] = \"\">\n                             <option value=\"\">Select IVR Menu</option>\n                             <option *ngFor=\"let data of ivrmenus;\" [value]=\"data.uuid\">\n                                 {{data.name}}\n                               </option>\n                           </select>\n                   </div>\n                   <div class=\"form-group\" *ngIf=\"isPrimarySelected(2,i,4)\">\n                         <label  class=\"d-block\">SIP (IP Address):</label>\n                         <input  formControlName=\"sipAdd_{{i}}_day4\" type=\"text\" class=\"form-control phone-number\">\n                   </div>\n             </div>\n              </div>\n              </div>\n          </div>\n          </div>\n\n          <!-- Day 6 -->\n          <div class=\"groupborder\" *ngIf=\"noofforwarding>=6\">\n            <div >\n              <div class=\"form-group\">\n                  <label>Select Timeframe - 6</label>\n                  <select formControlName=\"day_5\" class=\"form-control\">\n                    <option value=\"0\">Select Day</option>\n                    <option *ngFor=\"let item of allweekdays\" value=\"{{item.id}}\">{{item.start_day}} to {{item.end_day}}</option>\n                    </select>\n\n                </div>\n              <div class=\"row\">\n              <div class=\"col-md-12\">\n              <!-- <div class=\"row\">\n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                        <label>Start Time</label>\n                        <input formControlName=\"start_time_5\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\" placeholder=\"Ex :00:00\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time>\n                    </div>\n                </div>\n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                        <label>End Time</label>\n                        <input formControlName=\"end_time_5\" [owlDateTimeTrigger]=\"dt1\" class=\"form-control\" [owlDateTime]=\"dt1\" placeholder=\"Ex :00:00\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt1></owl-date-time>\n                    </div>\n                </div>\n              </div>  -->\n              <div class=\"row\">\n                <div class=\"col-md-3\">\n                    <label>Start Time (HH:MM)</label><br>\n                      <div  style=\"display:-webkit-inline-box\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"start_hrs_5\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                          <!-- <input formControlName=\"start_time_0\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time> -->\n                      </div>\n                      <div class=\"pt-2\">\n                        :\n                      </div>\n                    <div class=\"text-left\">\n                        <div class=\"form-group\">\n                            <input style=\"width:68px\" formControlName=\"start_min_5\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                        </div>\n                    </div>\n                  </div>\n                </div>\n\n                <div class=\"col-md-4\">\n                  <label>End Time (HH:MM)</label><br>\n                    <div  style=\"display:-webkit-inline-box\">\n                    <div class=\"form-group\">\n                        <input style=\"width:68px\" formControlName=\"end_hrs_5\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                    </div>\n                    <div class=\"pt-2\">\n                      :\n                    </div>\n                  <div class=\"text-left\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"end_min_5\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                      </div>\n                  </div>\n                </div>\n                </div>\n              </div>\n              <div class=\"form-group\">\n               <label  class=\"d-block\">Enter Number Of Forwarding Location:</label>\n               <input formControlName=\"noofforwardinglocation_6\" type=\"text\" class=\"form-control phone-number\" [(ngModel)]=\"noofforwardinglocation_6\">\n           </div>\n\n           <div class=\"groupborder\" *ngFor='let in of selectednoofforwardinglocation_6();let i = index'>\n             <div class=\"form-group\">\n                 <label class=\"d-block\">Primary Forwarding Location - {{i+1}}</label>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day5\" name=\"PrimaryforwardType_{{i}}_day5\" class=\"with-gap\" [value]='0' (click)=\"setPrimaryforward(0,i,5)\">\n\n                   <label class=\"form-check-label\" for=\"inlineradio1\">Number</label>\n                 </div>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day5\" name=\"PrimaryforwardType_{{i}}_day5\" (click)=\"setPrimaryforward(1,i,5)\" class=\"with-gap\" [value]=\"1\">\n                   <label class=\"form-check-label\" for=\"inlineradio2\">IVR Menu</label>\n                 </div>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day5\" name=\"PrimaryforwardType_{{i}}_day5\" class=\"with-gap\" (click)=\"setPrimaryforward(2,i,5)\" [value]=\"2\">\n                   <label class=\"form-check-label\" for=\"inlineCheckbox3\">SIP (IP Address)</label>\n                 </div>\n               </div>\n               <div class=\"form-group\" *ngIf=\"!isPrimarySelected(1,i,5) && !isPrimarySelected(2,i,5)\">\n                     <label  class=\"d-block\">Number:</label>\n                     <input type=\"text\" formControlName=\"number_{{i}}_day5\" id=\"editnumber_{{i}}_day5\" class=\"form-control phone-number\" placeholder=\"(000) 000-000\"  maxlength=\"16\" (keypress)=_keyPress($event)>\n               </div>\n               <div class=\"form-group\" *ngIf=\"isPrimarySelected(1,i,5)\">\n                     <label  class=\"d-block\">IVR Menu:</label>\n                       <select formControlName=\"ivrMenu_{{i}}_day5\" class=\"form-control\" [value] = \"\">\n                           <option value=\"\">Select IVR Menu</option>\n                           <option *ngFor=\"let data of ivrmenus;\" [value]=\"data.uuid\">\n                               {{data.name}}\n                             </option>\n                         </select>\n                 </div>\n                 <div class=\"form-group\" *ngIf=\"isPrimarySelected(2,i,5)\">\n                       <label  class=\"d-block\">SIP (IP Address):</label>\n                       <input  formControlName=\"sipAdd_{{i}}_day5\" type=\"text\" class=\"form-control phone-number\">\n                 </div>\n           </div>\n            </div>\n            </div>\n        </div>\n        </div>\n\n        <!-- Day 7 -->\n        <div class=\"groupborder\" *ngIf=\"noofforwarding>=7\">\n          <div >\n            <div class=\"form-group\">\n                <label>Select Timeframe - 7</label>\n                <select formControlName=\"day_6\" class=\"form-control\">\n                  <option value=\"0\">Select Day</option>\n                  <option *ngFor=\"let item of allweekdays\" value=\"{{item.id}}\">{{item.start_day}} to {{item.end_day}}</option>\n                  </select>\n\n              </div>\n            <div class=\"row\">\n            <div class=\"col-md-12\">\n            <!-- <div class=\"row\">\n              <div class=\"col-md-6\">\n                  <div class=\"form-group\">\n                      <label>Start Time</label>\n                      <input formControlName=\"start_time_6\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\" placeholder=\"Ex :00:00\">\n                      <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time>\n                  </div>\n              </div>\n              <div class=\"col-md-6\">\n                  <div class=\"form-group\">\n                      <label>End Time</label>\n                      <input formControlName=\"end_time_6\" [owlDateTimeTrigger]=\"dt1\" class=\"form-control\" [owlDateTime]=\"dt1\" placeholder=\"Ex :00:00\">\n                      <owl-date-time [pickerType]=\"'timer'\" #dt1></owl-date-time>\n                  </div>\n              </div>\n            </div>  -->\n\n            <div class=\"row\">\n              <div class=\"col-md-3\">\n                  <label>Start Time (HH:MM)</label><br>\n                    <div  style=\"display:-webkit-inline-box\">\n                    <div class=\"form-group\">\n                        <input style=\"width:68px\" formControlName=\"start_hrs_6\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                        <!-- <input formControlName=\"start_time_0\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time> -->\n                    </div>\n                    <div class=\"pt-2\">\n                      :\n                    </div>\n                  <div class=\"text-left\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"start_min_6\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                      </div>\n                  </div>\n                </div>\n              </div>\n\n              <div class=\"col-md-4\">\n                <label>End Time (HH:MM)</label><br>\n                  <div  style=\"display:-webkit-inline-box\">\n                  <div class=\"form-group\">\n                      <input style=\"width:68px\" formControlName=\"end_hrs_6\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                  </div>\n                  <div class=\"pt-2\">\n                    :\n                  </div>\n                <div class=\"text-left\">\n                    <div class=\"form-group\">\n                        <input style=\"width:68px\" formControlName=\"end_min_6\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                    </div>\n                </div>\n              </div>\n              </div>\n            </div>\n\n            <div class=\"form-group\">\n             <label  class=\"d-block\">Enter Number Of Forwarding Location:</label>\n             <input formControlName=\"noofforwardinglocation_7\" type=\"text\" class=\"form-control phone-number\" [(ngModel)]=\"noofforwardinglocation_7\">\n         </div>\n\n         <div class=\"groupborder\" *ngFor='let in of selectednoofforwardinglocation_7();let i = index'>\n           <div class=\"form-group\">\n               <label class=\"d-block\">Primary Forwarding Location - {{i+1}}</label>\n               <div class=\"form-check form-check-inline\">\n                   <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day6\" name=\"PrimaryforwardType_{{i}}_day6\" class=\"with-gap\" [value]='0' (click)=\"setPrimaryforward(0,i,6)\">\n\n                 <label class=\"form-check-label\" for=\"inlineradio1\">Number</label>\n               </div>\n               <div class=\"form-check form-check-inline\">\n                   <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day6\" name=\"PrimaryforwardType_{{i}}_day6\" (click)=\"setPrimaryforward(1,i,6)\" class=\"with-gap\" [value]=\"1\">\n                 <label class=\"form-check-label\" for=\"inlineradio2\">IVR Menu</label>\n               </div>\n               <div class=\"form-check form-check-inline\">\n                   <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day6\" name=\"PrimaryforwardType_{{i}}_day6\" class=\"with-gap\" (click)=\"setPrimaryforward(2,i,6)\" [value]=\"2\">\n                 <label class=\"form-check-label\" for=\"inlineCheckbox3\">SIP (IP Address)</label>\n               </div>\n             </div>\n             <div class=\"form-group\" *ngIf=\"!isPrimarySelected(1,i,6) && !isPrimarySelected(2,i,6)\">\n                   <label  class=\"d-block\">Number:</label>\n                   <input type=\"text\" formControlName=\"number_{{i}}_day6\" id=\"editnumber_{{i}}_day4\" class=\"form-control phone-number\" placeholder=\"(000) 000-000\"  maxlength=\"16\" (keypress)=_keyPress($event)>\n             </div>\n             <div class=\"form-group\" *ngIf=\"isPrimarySelected(1,i,6)\">\n                   <label  class=\"d-block\">IVR Menu:</label>\n                     <select formControlName=\"ivrMenu_{{i}}_day6\" class=\"form-control\" [value] = \"\">\n                         <option value=\"\">Select IVR Menu</option>\n                         <option *ngFor=\"let data of ivrmenus;\" [value]=\"data.uuid\">\n                             {{data.name}}\n                           </option>\n                       </select>\n               </div>\n               <div class=\"form-group\" *ngIf=\"isPrimarySelected(2,i,6)\">\n                     <label  class=\"d-block\">SIP (IP Address):</label>\n                     <input  formControlName=\"sipAdd_{{i}}_day6\" type=\"text\" class=\"form-control phone-number\">\n               </div>\n         </div>\n          </div>\n          </div>\n      </div>\n      </div>\n\n        <div class=\"modal-footer\" style=\"padding: 0;\">\n           <button [disabled]=\"isName == 'fail'\" type=\"submit\" (click)=\"editcloseModal()\" class=\"btn btn-primary m-t-15 waves-effect\">Edit Target</button>\n           <button data-dismiss=\"modal\" class=\"btn btn-secondary m-t-15 waves-effect\">Close</button>\n         </div>\n      </form>\n    </div>\n  </div>\n</div>\n</div>\n\n\n  <!-- Add Label Modal -->\n  <div class=\"modal fade\" id=\"addBuyer\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n  aria-hidden=\"true\">\n  <div class=\"modal-dialog model-lg\" role=\"document\">\n    <div class=\"modal-content\">\n      <div class=\"modal-header\">\n        <h5 class=\"modal-title\" id=\"formModal\">Create Buyer</h5>\n        <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n          <span aria-hidden=\"true\">&times;</span>\n        </button>\n      </div>\n      <div class=\"modal-body\">\n        <form id=\"addLabel\" [formGroup]=\"addBuyerForm\" (ngSubmit)=\"onBuyerSubmit()\">\n          <div class=\"row\">\n            <div class=\"col-md-12\">\n          <div class=\"form-group\">\n              <label>Company</label>\n              <input formControlName=\"company\" [(ngModel)]=\"company\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': BuyerSubmitted && buyercontrol.company.errors }\">\n              <div *ngIf=\"BuyerSubmitted && buyercontrol.company.errors\" class=\"invalid-feedback\">\n                  <div *ngIf=\"buyercontrol.company.errors.required\">Company is required</div>\n              </div>\n           </div>\n\n          <div class=\"form-group\">\n            <label>Email ID</label>\n            <input formControlName=\"email\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && buyercontrol.email.errors }\">\n            <div *ngIf=\"Submitted && buyercontrol.email.errors\" class=\"invalid-feedback\">\n                <div *ngIf=\"buyercontrol.email.errors.required\">Email is required</div>\n            </div>\n          </div>\n\n          <div class=\"form-group\">\n            <label>Password</label>\n            <input formControlName=\"password\" type=\"password\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && buyercontrol.password.errors }\">\n            <div *ngIf=\"Submitted && buyercontrol.password.errors\" class=\"invalid-feedback\">\n                <div *ngIf=\"buyercontrol.password.errors.required\">Password is required</div>\n            </div>\n         </div>\n\n            <div class=\"form-group\">\n              <label  class=\"d-block\">Sub Id  :</label>\n              <input formControlName=\"sub_id\" type=\"text\" class=\"form-control\">\n            </div>\n\n            <div class=\"form-group\">\n              <label  class=\"d-block\">Allow Buyer To Pause Targets :</label>\n              <label class=\"custom-switch mt-2 pl-0\">\n                <input type=\"checkbox\" formControlName=\"allow_buyer_to_pause_target\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                <span class=\"custom-switch-indicator\"></span>\n              </label>\n            </div>\n\n            <div class=\"form-group\">\n              <label  class=\"d-block\">Allow Buyer To Set Target Concurrency :</label>\n              <label class=\"custom-switch mt-2 pl-0\">\n                <input type=\"checkbox\" formControlName=\"allow_buyer_to_set_target_concurrency\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                <span class=\"custom-switch-indicator\"></span>\n              </label>\n            </div>\n\n            <div class=\"form-group\">\n              <label  class=\"d-block\">Allow Buyer To Dispute Call Conversions :</label>\n              <label class=\"custom-switch mt-2 pl-0\">\n                <input type=\"checkbox\" formControlName=\"allow_buyer_to_dispute_call_conversions\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                <span class=\"custom-switch-indicator\"></span>\n              </label>\n            </div>\n\n            <div class=\"form-group\">\n              <label  class=\"d-block\">Limit Revenue : </label>\n              <label class=\"custom-switch mt-2 pl-0\">\n                <input type=\"checkbox\" formControlName=\"limit_revenue\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                <span class=\"custom-switch-indicator\"></span>\n              </label>\n            </div>\n\n           </div>\n       </div>\n          <div class=\"modal-footer\" style=\"padding: 0;\">\n           <!-- !addLabelForm.valid || -->\n             <button (click)=\"closeBuyerModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Create Buyer</button>\n             <button  type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\">Reset</button>\n            </div>\n        </form>\n      </div>\n    </div>\n  </div>\n  </div>\n\n  <div class=\"modal fade\" id=\"addZipcode\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n  aria-hidden=\"true\">\n  <div class=\"modal-dialog model-lg\" role=\"document\">\n    <div class=\"modal-content\">\n      <div class=\"modal-header\">\n        <h5 class=\"modal-title\" id=\"formModal\">Upload Zipcode</h5>\n        <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n          <span aria-hidden=\"true\">&times;</span>\n        </button>\n      </div>\n      <div class=\"modal-body\">\n          <div class=\"row\">\n            <div class=\"col-md-12\">\n             <div class=\"form-group\">\n                <label>Upload CSV</label>\n                <input (change)=\"selectFile($event)\" [(ngModel)]=\"selectedfile\" type=\"file\" class=\"form-control p-0 p-1\">\n            </div>\n           </div>\n       </div>\n          <div class=\"modal-footer\" style=\"padding: 0;\">\n             <button (click)=\"onZipSubmit()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Submit</button>\n             <button data-dismiss=\"modal\" aria-label=\"Close\" type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\">Cancel</button>\n            </div>\n      </div>\n    </div>\n  </div>\n  </div>\n\n<div class=\"main-content\">\n        <section class=\"section\">\n          <div class=\"section-body\">\n            <div class=\"row\">\n              <div class=\"col-md-12 col-md-12 col-md-lg-12\">\n                <form [formGroup]=\"addForm\" (ngSubmit)=\"onSubmit()\">\n                <div class=\"card\">\n                  <div class=\"card-header\">\n                    <h4>Add Target</h4>\n                  </div>\n                  <div class=\"card-body\">\n\n                    <fieldset class=\"scheduler-border\">\n                      <legend class=\"scheduler-border\">Target Settings</legend>\n                      <div class=\"form-group\">\n                        <label>Name</label>\n                        <div class=\"input-group\">\n                          <input formControlName=\"name\" id=\"name\" type=\"text\" class=\"form-control\"  [ngClass]=\"{ 'is-invalid': submitted && f.name.errors }\" placeholder=\"\" (input)=\"validateTargetname()\">\n                          <div *ngIf=\"submitted && f.name.errors\" class=\"invalid-feedback\">\n                              <div *ngIf=\"f.name.errors.required\">Name is required</div>\n                          </div>\n                          </div>\n                          <div *ngIf=\"isTargetName == 'success'  && isTargetName != ''\" style=\"color:green;\">\n                            Name Is Available\n                          </div>\n                           <div *ngIf=\"isTargetName == 'fail' && isTargetName != ''\" style=\"color:red;\">\n                            Name Is Not Available\n                          </div>\n                      </div>\n\n                     <div class=\"form-group\">\n                        <label>Sub Id</label>\n                        <div class=\"input-group\">\n                          <input formControlName=\"subid\" id=\"subid\" type=\"text\" class=\"form-control\" placeholder=\"\">\n                          <!-- <div *ngIf=\"submitted && f.subid.errors\" class=\"invalid-feedback\">\n                              <div *ngIf=\"f.subid.errors.required\">Sub Id is required</div>\n                          </div>                                            -->\n                          </div>\n                      </div>\n\n                    <div class=\"row\">\n                      <div class=\"col-md-6\">\n                        <div class=\"form-group\">\n                          <label>Buyer</label>\n                          <!-- <select formControlName=\"buyer\" class=\"form-control\" value=\"''\">\n                            <option value=\"\" selected>Select Buyer</option>\n                            <option *ngFor=\"let buyers of allBuyers;\" [value]=\"buyers.uuid\">\n                                {{buyers.company}}\n                              </option>\n                          </select> -->\n                          <!-- <ng-select2 [data]=\"allBuyers\" [width]=\"200\">\n                          </ng-select2> -->\n\n                          <angular2-multiselect [data]=\"allBuyers\" [(ngModel)]=\"selectedItems\" formControlName=\"buyer\" [settings]=\"settings\"></angular2-multiselect>\n                          <!-- <div  class=\"invalid-feedback\">\n                            <div *ngIf=\"f.buyer.errors.required\">Buyer is required</div>\n                          </div>            -->\n                        </div>\n                      </div>\n                      <div class=\"col-md-2 mt-4 pt-1\">\n                        <button type=\"button\" data-toggle=\"modal\" data-target=\"#addBuyer\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-1\"><i class=\"fa fa-plus\"></i> Add New Buyer\n                        </button>\n                      </div>\n                    </div>\n\n                    <div class=\"row\">\n                      <div class=\"col-md-2\">\n                         <div class=\"control-group mt-2\">\n                           <div class=\"control-label\">{{ringtreetext}}</div>\n                           <label class=\"custom-switch mt-2 pl-0\">\n                             <input type=\"checkbox\" (change)=\"ringtree_toggle($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                             <span class=\"custom-switch-indicator\"></span>\n                           </label>\n                         </div>\n                      </div>\n                    </div>\n\n                    <fieldset class=\"scheduler-border\">\n                      <legend class=\"scheduler-border\">{{ringtreetext}}</legend>\n\n                       <div *ngIf=\"ringtree==false\">\n\n                        <div class=\"row\">\n                          <div class=\"col-md-5\">\n                            <div class=\"form-group\">\n                              <div class=\"control-group\">\n                                  <label class=\"control-label input-label\" for=\"startTime\">Type:</label>\n                                  <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                                  <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': settingToggleTypeval==0}\" (click)=\"settingToggleType(0)\">\n                                        <input class=\"form-check-input\" name=\"settingToggleBlockCallsIfCapped\" formControlName=\"settingToggleBlockCallsIfCapped\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                                        Number\n                                  </label>\n                                  <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': settingToggleTypeval==1}\" (click)=\"settingToggleType(1)\">\n                                    <input class=\"form-check-input\" name=\"settingToggleBlockCallsIfCapped\" formControlName=\"settingToggleBlockCallsIfCapped\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                                    IVR Menu\n                                  </label>\n                                  <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': settingToggleTypeval==2}\" (click)=\"settingToggleType(2)\">\n                                    <input class=\"form-check-input\" name=\"settingToggleBlockCallsIfCapped\" formControlName=\"settingToggleBlockCallsIfCapped\" type=\"radio\" id=\"option2\" [value]=\"2\">\n                                    SIP\n                                  </label>\n                                  <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': settingToggleTypeval==2}\" (click)=\"settingToggleType(3)\">\n                                    <input class=\"form-check-input\" name=\"settingToggleBlockCallsIfCapped\" formControlName=\"settingToggleBlockCallsIfCapped\" type=\"radio\" id=\"option2\" [value]=\"3\">\n                                    Voicemail\n                                  </label>\n                                    </div>\n                            </div>\n                            </div>\n                          </div>\n                        </div>\n\n                        <div class=\"control-group mt-2\" *ngIf=\"settingToggleTypeval==0\">\n                            <label class=\"control-label input-label\" for=\"startTime\">Number :</label>\n                            <input type=\"text\" formControlName=\"number\" class=\"form-control\" type=\"text\" placeholder=\"Enter Number\" [ngClass]=\"{ 'is-invalid': submitted && f.number.errors }\" />\n                            <div *ngIf=\"submitted && f.number.errors\" class=\"invalid-feedback\">\n                              <div *ngIf=\"f.number.errors.required\">Number is required</div>\n                            </div>\n                        </div>\n                      <div *ngIf=\"settingToggleTypeval==1\">\n                          <div class=\"control-group mt-2\">\n                              <label class=\"control-label input-label\" for=\"startTime\">Select IVR Menu:</label>\n                              <!-- <select formControlName=\"ivrMenu\" class=\"form-control\" [value] =\"\"> -->\n                                <!-- <option value=\"\">Select IVR Menu</option>\n                                <option *ngFor=\"let data of ivrmenus;\" [value]=\"data.uuid\">\n                                    {{data.name}}\n                                  </option> -->\n\n                                <angular2-multiselect [data]=\"ivrmenus\" [(ngModel)]=\"forwardto_ivrrouting_10\"  formControlName=\"ivrMenu\" [settings]=\n                                \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select IVR '}\"></angular2-multiselect>\n                                <a *ngIf=\"forwardto_ivrrouting_10\" target=\"_blank\" routerLink=\"/edit-ivr/{{forwardto_ivrrouting_10[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Edit</a>\n                                <!-- </select> -->\n                          </div>\n                      </div>\n                      <div *ngIf=\"settingToggleTypeval==2\">\n                          <div class=\"control-group mt-2\">\n                              <label class=\"control-label input-label\" for=\"startTime\">SIP (IP Address):</label>\n                              <input type=\"text\" formControlName=\"sip_address\" class=\"form-control\" type=\"text\" [ngClass]=\"{ 'is-invalid': submitted && f.sip_address.errors }\"/>\n                              <div *ngIf=\"submitted && f.sip_address.errors\" class=\"invalid-feedback\">\n                                <div *ngIf=\"f.sip_address.errors.required\">SIP Address is required</div>\n                              </div>\n                          </div>\n                      </div>\n                      <div class=\"control-group mt-2\" *ngIf=\"settingToggleTypeval==3\">\n                          <label class=\"control-label input-label\" for=\"startTime\">Voicemail :</label>\n                          <input type=\"text\" formControlName=\"voice_mail\" class=\"form-control\" type=\"text\" placeholder=\"Enter Voicemail\" [ngClass]=\"{ 'is-invalid': submitted && f.voice_mail.errors }\" />\n                          <div *ngIf=\"submitted && f.voice_mail.errors\" class=\"invalid-feedback\">\n                            <div *ngIf=\"f.voice_mail.errors.required\">Voicemail is required</div>\n                          </div>\n                      </div>\n\n                      </div>\n\n\n                      <div *ngIf=\"ringtree==true\">\n\n                        <div class=\"row\">\n                          <div class=\"col-md-2\">\n                             <div class=\"control-group mt-2\">\n                               <div class=\"control-label\">URL</div>\n                             </div>\n                          </div>\n                          <div class=\"col-md-5 mt-4\">\n                             <div class=\"form-group\">\n                               <input formControlName=\"url\" type=\"text\" class=\"form-control formcontrol\" id=\"\">\n                             </div>\n                          </div>\n                        </div>\n\n                        <div class=\"row\">\n                          <div class=\"col-md-2\">\n                             <div class=\"control-group mt-4\">\n                               <div class=\"control-label\">HTTP Method</div>\n                             </div>\n                          </div>\n                          <div class=\"col-md-2\">\n                             <div class=\"form-group mt-2\">\n                              <select formControlName=\"http_method\" name=\"http_method\" id=\"http_method\" class=\"form-control\" (change)=\"methodtype($event)\">\n                                <option value=\"0\">GET</option>\n                                <option value=\"1\">POST</option>\n                                <option value=\"2\">PUT</option>\n                                <option value=\"3\">PATCH</option>\n                                <option value=\"4\">DELETE</option>\n                              </select>\n                             </div>\n                          </div>\n                        </div>\n\n                        <div class=\"row\" *ngIf=\"methodtypeval != 0 && methodtypeval != 4\">\n                          <div class=\"col-md-2\">\n                             <div class=\"control-group mt-4\">\n                               <div class=\"control-label\">Content Type</div>\n                             </div>\n                          </div>\n                          <div class=\"col-md-2\">\n                             <div class=\"form-group mt-2\">\n                              <select formControlName=\"content_type\" name=\"content_type\" id=\"content_type\" class=\"form-control\">\n                                <option value=\"0\">application/json</option>\n                                <option value=\"1\">application/xml</option>\n                                <option value=\"2\">application/x-www-form-urlencoded</option>\n                                <option value=\"3\">plain/text</option>\n                              </select>\n                             </div>\n                          </div>\n                        </div>\n\n                        <div class=\"row\" *ngIf=\"methodtypeval != 0 && methodtypeval != 4\">\n                          <div class=\"col-md-2\">\n                             <div class=\"control-group mt-4\">\n                               <div class=\"control-label\">Body</div>\n                             </div>\n                          </div>\n                          <div class=\"col-md-5\">\n                             <div class=\"form-group mt-2\">\n                              <textarea formControlName=\"body\" cols=\"30\" rows=\"10\" class=\"form-control\"></textarea>\n                             </div>\n                          </div>\n                        </div>\n\n\n                        <div class=\"row\">\n                          <div class=\"col-md-2\">\n                             <div class=\"control-group mt-2\">\n                               <div class=\"control-label\">HTTP Headers</div>\n                             </div>\n                          </div>\n                          <div class=\"col-md-2 mt-4\">\n                             <div class=\"form-group\">\n                               <input formControlName=\"http_headers_name\" type=\"text\" class=\"form-control formcontrol\" placeholder=\"Header Name\" id=\"\">\n                             </div>\n                          </div>\n                          <div class=\"mt-2\">:</div>\n                          <div class=\"col-md-2 mt-4 text-left\">\n                             <div class=\"form-group\">\n                               <input formControlName=\"http_headers_value\" type=\"text\" class=\"form-control formcontrol\" placeholder=\" Value\"  id=\"\">\n                             </div>\n                          </div>\n                        </div>\n\n                        <div *ngFor=\"let keywords of addkeyword; let i = index;\">\n                          <div class=\"row\">\n                            <div class=\"col-md-2\">\n                              <div class=\"control-group mt-2\">\n                                <div class=\"control-label\">Keyword {{i+1}}</div>\n                              </div>\n                            </div>\n                            <div class=\"col-md-5 mt-4\">\n                              <div class=\"form-group\">\n                                <input formControlName=\"keyword{{i}}\" type=\"text\" class=\"form-control formcontrol\" id=\"\">\n                              </div>\n                            </div>\n                            <div class=\"col-md-1\" *ngIf=\"i+1 == addkeyword.length && addkeyword.length!=3\">\n                              <input type=\"button\" value=\"+\" class=\"btn btn-info btn-sm\" (click)=\"addRow(i+1)\">\n                            </div>\n                            <div class=\"col-md-1\" *ngIf=\"i+1 == addkeyword.length && addkeyword.length>=2\">\n                              <input type=\"button\" value=\"-\" class=\"btn btn-danger btn-sm\" (click)=\"removeRow(i)\">\n                            </div>\n                          </div>\n                        </div>\n\n\n                      </div>\n\n                  </fieldset>\n\n                  </fieldset>\n\n                  <fieldset class=\"scheduler-border\">\n                  <legend class=\"scheduler-border\">Hours of Operation</legend>\n\n                  <div class=\"form-group\">\n                    <angular2-multiselect [data]=\"alltimezone\" [(ngModel)]=\"timezoneval\"  formControlName=\"timezone\" [settings]=\n                                \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select Timezone '}\"></angular2-multiselect>\n                  </div>\n\n                  <div class=\"row\">\n                    <div class=\"col-md-2\">\n                      <label class=\"custom-switch mt-2 pl-0\">\n                        <input type=\"checkbox\" (change)=\"hof_alwaysopen_toggle($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                        <span class=\"custom-switch-indicator\"></span>\n                      </label>\n                    </div>\n                    <div class=\"col-md-6\">\n                      <span *ngIf=\"!hof_alwaysopen\">Always Open</span>\n                      <span *ngIf=\"hof_alwaysopen\">\n                        <!-- <input type=\"button\" (click)=\"iscreateoffertoggle()\" value=\"12 / 24\" class=\"btn btn-primary font-12 btn-sm mr-2 p-1 mb-3 \" style=\"border: 1px solid green!important\"> -->\n\n                        <input type=\"button\" (click)=\"is12or24_toggle(!is12or24)\" value=\"12/24\" class=\"btn btn-primary font-12 btn-sm p-1 mb-3 mr-2\" style=\"border: 1px solid green!important; background: #0266c8;\" *ngIf=\"is12or24 == 1\">\n\n                        <input type=\"button\" (click)=\"is12or24_toggle(!is12or24)\" *ngIf=\"is12or24 == 0\" value=\"12/24\" class=\"btn btn-primary font-12 btn-sm p-1 mb-3 mr-2\" style=\"border: 1px solid green!important\">\n\n\n                        <input type=\"button\" (click)=\"isadvanced_toggle(!isadvanced)\" [value]=\"advanced\" class=\"btn btn-primary font-12 btn-sm p-1 mb-3\" style=\"border: 1px solid green!important\">\n                      </span>\n                    </div>\n                  </div>\n                  <div class=\"row\" *ngIf=\"hof_alwaysopen\">\n                    <div class=\"col-md-12\">\n                        <div class=\"table-reponsive\" *ngIf=\"isadvanced==0\">\n                          <table style=\"width:60%\" class=\"table table-striped\">\n                            <thead>\n                            <tr>\n                              <th style=\"background: #1a1d2c!important;width: 14%;\"></th>\n                              <th style=\"background: #1a1d2c!important;width: 20%;\">Open</th>\n                              <th style=\"background: #1a1d2c!important;width: 20%;\">Close</th>\n                              <!-- <th style=\"background: #1a1d2c!important;\">Timezone</th> -->\n                            </tr>\n                          </thead>\n                          <tbody>\n                            <tr>\n                              <td style=\"background: #252c44!important;\"> <span>Monday - Sunday</span></td>\n                              <td style=\"background: #252c44!important;\">\n                                <!-- <label>Opening Time (HH:MM)</label><br> -->\n                                  <div  style=\"display:-webkit-inline-box\" class=\"pt-1\">\n                                  <div class=\"form-group text-center\">\n                                      <div (click)=\"increment_hrs('start_hrs')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 pb-1\"></span>\n                                      </div>\n                                      <input style=\"background: #22283b!important;\" formControlName=\"start_hrs\"  type=\"number\" min=\"0\" max=\"12\"  class=\"form-control hofnumber\">\n                                      <div (click)=\"decrement_hrs('start_hrs')\" style=\"cursor: pointer;\">\n                                      <span class=\"fa fa-angle-down font-16 pt-1\"></span>\n                                      </div>\n                                  </div>\n                                  <div class=\"pt-4 mt-1\">\n                                    :\n                                  </div>\n                                  <div class=\"text-left\">\n                                      <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_min('start_min')\" style=\"cursor: pointer;\">\n                                        <span class=\"fa fa-angle-up font-16 pb-1\"></span></div>\n                                          <input style=\"background: #22283b!important;\" formControlName=\"start_min\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                          <div (click)=\"decrement_min('start_min')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                      </div>\n                                  </div>\n                                  <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                    <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('default_ampm')\">\n                                      {{this.addForm.get('default_ampm').value==0?\"AM\":\"PM\"}}\n                                    </button>\n                                  </div>\n                                </div>\n                              </td>\n                              <td style=\"background: #252c44!important;\">\n                                <div style=\"display:-webkit-inline-box\" >\n                                    <div class=\"form-group text-center\">\n                                      <div (click)=\"increment_hrs('end_hrs')\" style=\"cursor: pointer;\">\n                                        <span class=\"fa fa-angle-up font-16 pb-1\"></span></div>\n                                        <input style=\"background: #22283b!important;\" formControlName=\"end_hrs\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control hofnumber\">\n                                        <div (click)=\"decrement_hrs('end_hrs')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                    </div>\n                                    <div class=\"pt-4 mt-1\">\n                                      :\n                                    </div>\n                                  <div class=\"text-left\">\n                                      <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_min('end_min')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 pb-1\"></span></div>\n                                          <input style=\"background: #22283b!important;\" formControlName=\"end_min\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                          <div (click)=\"decrement_min('end_min')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                      </div>\n                                  </div>\n                                  <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                    <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('default_ampm_close')\">\n                                      {{this.addForm.get('default_ampm_close').value==0?\"AM\":\"PM\"}}\n                                    </button>\n                                  </div>\n                                </div>\n                              </td>\n                              <!-- <td style=\"background: #252c44!important;\"> -->\n                                <!-- <select formControlName=\"timezone\" class=\"form-control\" [value]=\"\">\n                                  <option value=\"\">Select Timezone</option>\n                                  <option value=\"{{item.id}}\" *ngFor=\"let item of alltimezone\">{{item.gmtzone}}</option>\n                                </select>   -->\n                                <!-- <angular2-multiselect [data]=\"alltimezone\" [(ngModel)]=\"timezoneval\"  formControlName=\"timezone\" [settings]=\n                                \"{enableSearchFilter: true,classes: 'filterdd',showCheckbox:false,singleSelection: true, text:'Select Timezone '}\"></angular2-multiselect>\n                              </td> -->\n                            </tr>\n                          </tbody>\n                          </table>\n                        </div>\n\n                        <!-- advanced -->\n                        <div class=\"table-reponsive\" *ngIf=\"isadvanced==1\">\n                          <table style=\"width:60%\" class=\"table table-striped\">\n                            <thead>\n                            <tr>\n                              <th style=\"background: #1a1d2c!important;\"></th>\n                              <th style=\"background: #1a1d2c!important;\">Open</th>\n                              <th style=\"background: #1a1d2c!important;\">Open</th>\n                              <th style=\"background: #1a1d2c!important;\">Close</th>\n                            </tr>\n                          </thead>\n                          <tbody>\n                            <tr>\n                              <td style=\"background: #22273c!important;border-bottom: none;\"> <span>Sunday</span></td>\n                              <td style=\"background: #22273c!important;border-bottom: none\">\n                                <label class=\"custom-switch mt-2 pl-0\">\n                                  <input type=\"checkbox\" (change)=\"sunday_open($event)\" checked name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                                  <span class=\"custom-switch-indicator\"></span>\n                                </label>\n                              </td>\n                              <td style=\"background: #22273c!important;border-bottom: none\">\n                                <!-- <label>Opening Time (HH:MM)</label><br> -->\n                                  <div  style=\"display:-webkit-inline-box\" class=\"pt-2\">\n                                  <div class=\"form-group text-center\">\n                                      <div (click)=\"increment_hrs('start_hrs_sunday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 \"></span>\n                                      </div>\n                                      <input style=\"background: #22283b!important;\" formControlName=\"start_hrs_sunday\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control hofnumber\">\n                                      <div (click)=\"decrement_hrs('start_hrs_sunday')\" style=\"cursor: pointer;\">\n                                      <span class=\"fa fa-angle-down font-16 pt-1\"></span>\n                                      </div>\n                                  </div>\n                                  <div class=\"pt-4 mt-1\">\n                                    :\n                                  </div>\n                                  <div class=\"text-left\">\n                                      <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_min('start_min_sunday')\" style=\"cursor: pointer;\">\n                                        <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                          <input style=\"background: #22283b!important;\" formControlName=\"start_min_sunday\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                          <div (click)=\"decrement_min('start_min_sunday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                      </div>\n                                  </div>\n                                  <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                    <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('sunday_ampm')\">\n                                      {{this.addForm.get('sunday_ampm').value==0?\"AM\":\"PM\"}}\n                                    </button>\n                                  </div>\n                                </div>\n                              </td>\n                              <td style=\"background: #22273c!important;border-bottom: none\">\n                                <div style=\"display:-webkit-inline-box\" >\n                                    <div class=\"form-group text-center\">\n                                      <div (click)=\"increment_hrs('end_hrs_sunday')\" style=\"cursor: pointer;\">\n                                        <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                        <input style=\"background: #22283b!important;\" formControlName=\"end_hrs_sunday\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control hofnumber\">\n                                        <div (click)=\"decrement_hrs('end_hrs_sunday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                    </div>\n                                    <div class=\"pt-4 mt-1\">\n                                      :\n                                    </div>\n                                  <div class=\"text-left\">\n                                      <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_min('end_min_sunday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                          <input style=\"background: #22283b!important;\" formControlName=\"end_min_sunday\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                          <div (click)=\"decrement_min('end_min_sunday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                      </div>\n                                  </div>\n                                  <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                    <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('sunday_ampm_close')\">\n                                      {{this.addForm.get('sunday_ampm_close').value==0?\"AM\":\"PM\"}}\n                                    </button>\n                                  </div>\n                                </div>\n                              </td>\n                            </tr>\n\n                            <tr>\n                              <td style=\"background: #252c44!important;border-bottom: none\"> <span>Monday</span></td>\n                              <td style=\"background: #252c44!important;border-bottom: none\">\n                                <label class=\"custom-switch mt-2 pl-0\">\n                                  <input type=\"checkbox\" (change)=\"monday_open($event)\" checked name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                                  <span class=\"custom-switch-indicator\"></span>\n                                </label>\n                              </td>\n                              <td style=\"background: #252c44!important;border-bottom: none\">\n                                <!-- <label>Opening Time (HH:MM)</label><br> -->\n                                  <div  style=\"display:-webkit-inline-box\" class=\"pt-2\">\n                                  <div class=\"form-group text-center\">\n                                      <div (click)=\"increment_hrs('start_hrs_monday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 \"></span>\n                                      </div>\n                                      <input style=\"background: #22283b!important;\" formControlName=\"start_hrs_monday\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control hofnumber\">\n                                      <div (click)=\"decrement_hrs('start_hrs_monday')\" style=\"cursor: pointer;\">\n                                      <span class=\"fa fa-angle-down font-16 pt-1\"></span>\n                                      </div>\n                                  </div>\n                                  <div class=\"pt-4 mt-1\">\n                                    :\n                                  </div>\n                                  <div class=\"text-left\">\n                                      <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_min('start_min_monday')\" style=\"cursor: pointer;\">\n                                        <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                          <input style=\"background: #22283b!important;\" formControlName=\"start_min_monday\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                          <div (click)=\"decrement_min('start_min_monday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                      </div>\n                                  </div>\n                                  <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                    <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('monday_ampm')\">\n                                      {{this.addForm.get('monday_ampm').value==0?\"AM\":\"PM\"}}\n                                    </button>\n                                  </div>\n                                </div>\n                              </td>\n                              <td style=\"background: #252c44!important;border-bottom: none\">\n                                <div style=\"display:-webkit-inline-box\" >\n                                    <div class=\"form-group text-center\">\n                                      <div (click)=\"increment_hrs('end_hrs_monday')\" style=\"cursor: pointer;\">\n                                        <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                        <input style=\"background: #22283b!important;\" formControlName=\"end_hrs_monday\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control hofnumber\">\n                                        <div (click)=\"decrement_hrs('end_hrs_monday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                    </div>\n                                    <div class=\"pt-4 mt-1\">\n                                      :\n                                    </div>\n                                  <div class=\"text-left\">\n                                      <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_min('end_min_monday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                          <input style=\"background: #22283b!important;\" formControlName=\"end_min_monday\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                          <div (click)=\"decrement_min('end_min_monday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                      </div>\n                                  </div>\n                                  <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                    <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('monday_ampm_close')\">\n                                      {{this.addForm.get('monday_ampm_close').value==0?\"AM\":\"PM\"}}\n                                    </button>\n                                  </div>\n                                </div>\n                              </td>\n                            </tr>\n\n                            <tr>\n                              <td style=\"background: #22273c!important;border-bottom: none\"> <span>Tuesday </span></td>\n                              <td style=\"background: #22273c!important;border-bottom: none\">\n                                <label class=\"custom-switch mt-2 pl-0\">\n                                  <input type=\"checkbox\" (change)=\"tuesday_open($event)\" checked name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                                  <span class=\"custom-switch-indicator\"></span>\n                                </label>\n                              </td>\n                              <td style=\"background: #22273c!important;border-bottom: none\">\n                                <!-- <label>Opening Time (HH:MM)</label><br> -->\n                                  <div  style=\"display:-webkit-inline-box\" class=\"pt-2\">\n                                  <div class=\"form-group text-center\">\n                                      <div (click)=\"increment_hrs('start_hrs_tuesday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 \"></span>\n                                      </div>\n                                      <input style=\"background: #22283b!important;\" formControlName=\"start_hrs_tuesday\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control hofnumber\">\n                                      <div (click)=\"decrement_hrs('start_hrs_tuesday')\" style=\"cursor: pointer;\">\n                                      <span class=\"fa fa-angle-down font-16 pt-1\"></span>\n                                      </div>\n                                  </div>\n                                  <div class=\"pt-4 mt-1\">\n                                    :\n                                  </div>\n                                  <div class=\"text-left\">\n                                      <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_min('start_min_tuesday')\" style=\"cursor: pointer;\">\n                                        <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                          <input style=\"background: #22283b!important;\" formControlName=\"start_min_tuesday\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                          <div (click)=\"decrement_min('start_min_tuesday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                      </div>\n                                  </div>\n                                  <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                    <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('tuesday_ampm')\">\n                                      {{this.addForm.get('tuesday_ampm').value==0?\"AM\":\"PM\"}}\n                                    </button>\n                                  </div>\n                                </div>\n                              </td>\n                              <td style=\"background: #22273c!important;border-bottom: none\">\n                                <div style=\"display:-webkit-inline-box\" >\n                                    <div class=\"form-group text-center\">\n                                      <div (click)=\"increment_hrs('end_hrs_tuesday')\" style=\"cursor: pointer;\">\n                                        <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                        <input style=\"background: #22283b!important;\" formControlName=\"end_hrs_tuesday\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control hofnumber\">\n                                        <div (click)=\"decrement_hrs('end_hrs_tuesday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                    </div>\n                                    <div class=\"pt-4 mt-1\">\n                                      :\n                                    </div>\n                                  <div class=\"text-left\">\n                                      <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_min('end_min_tuesday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                          <input style=\"background: #22283b!important;\" formControlName=\"end_min_tuesday\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                          <div (click)=\"decrement_min('end_min_tuesday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                      </div>\n                                  </div>\n                                  <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                    <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('tuesday_ampm_close')\">\n                                      {{this.addForm.get('tuesday_ampm_close').value==0?\"AM\":\"PM\"}}\n                                    </button>\n                                  </div>\n                                </div>\n                              </td>\n                            </tr>\n\n                            <tr>\n                              <td style=\"background: #252c44!important;border-bottom: none\"> <span>Wednesday </span></td>\n                              <td style=\"background: #252c44!important;border-bottom: none\">\n                                <label class=\"custom-switch mt-2 pl-0\">\n                                  <input type=\"checkbox\" (change)=\"wednesday_open($event)\" checked name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                                  <span class=\"custom-switch-indicator\"></span>\n                                </label>\n                              </td>\n                              <td style=\"background: #252c44!important;border-bottom: none\">\n                                <!-- <label>Opening Time (HH:MM)</label><br> -->\n                                  <div  style=\"display:-webkit-inline-box\" class=\"pt-2\">\n                                  <div class=\"form-group text-center\">\n                                      <div (click)=\"increment_hrs('start_hrs_wednesday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 \"></span>\n                                      </div>\n                                      <input style=\"background: #22283b!important;\" formControlName=\"start_hrs_wednesday\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control hofnumber\">\n                                      <div (click)=\"decrement_hrs('start_hrs_wednesday')\" style=\"cursor: pointer;\">\n                                      <span class=\"fa fa-angle-down font-16 pt-1\"></span>\n                                      </div>\n                                  </div>\n                                  <div class=\"pt-4 mt-1\">\n                                    :\n                                  </div>\n                                  <div class=\"text-left\">\n                                      <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_min('start_min_wednesday')\" style=\"cursor: pointer;\">\n                                        <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                          <input style=\"background: #22283b!important;\" formControlName=\"start_min_wednesday\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                          <div (click)=\"decrement_min('start_min_wednesday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                      </div>\n                                  </div>\n                                  <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                    <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('wednesday_ampm')\">\n                                      {{this.addForm.get('wednesday_ampm').value==0?\"AM\":\"PM\"}}\n                                    </button>\n                                  </div>\n                                </div>\n                              </td>\n                              <td style=\"background: #252c44!important;border-bottom: none\">\n                                <div style=\"display:-webkit-inline-box\" >\n                                    <div class=\"form-group text-center\">\n                                      <div (click)=\"increment_hrs('end_hrs_wednesday')\" style=\"cursor: pointer;\">\n                                        <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                        <input style=\"background: #22283b!important;\" formControlName=\"end_hrs_wednesday\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control hofnumber\">\n                                        <div (click)=\"decrement_hrs('end_hrs_wednesday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                    </div>\n                                    <div class=\"pt-4 mt-1\">\n                                      :\n                                    </div>\n                                  <div class=\"text-left\">\n                                      <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_min('end_min_wednesday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                          <input style=\"background: #22283b!important;\" formControlName=\"end_min_wednesday\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                          <div (click)=\"decrement_min('end_min_wednesday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                      </div>\n                                  </div>\n                                  <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                    <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('wednesday_ampm_close')\">\n                                      {{this.addForm.get('wednesday_ampm_close').value==0?\"AM\":\"PM\"}}\n                                    </button>\n                                  </div>\n                                </div>\n                              </td>\n                            </tr>\n\n                            <tr>\n                              <td style=\"background: #22273c!important;border-bottom: none\"> <span>Thursday </span></td>\n                              <td style=\"background: #22273c!important;border-bottom: none\">\n                                <label class=\"custom-switch mt-2 pl-0\">\n                                  <input type=\"checkbox\" (change)=\"thursday_open($event)\" checked name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                                  <span class=\"custom-switch-indicator\"></span>\n                                </label>\n                              </td>\n                              <td style=\"background: #22273c!important;border-bottom: none\">\n                                <!-- <label>Opening Time (HH:MM)</label><br> -->\n                                  <div  style=\"display:-webkit-inline-box\" class=\"pt-2\">\n                                  <div class=\"form-group text-center\">\n                                      <div (click)=\"increment_hrs('start_hrs_thursday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 \"></span>\n                                      </div>\n                                      <input style=\"background: #22283b!important;\" formControlName=\"start_hrs_thursday\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control hofnumber\">\n                                      <div (click)=\"decrement_hrs('start_hrs_thursday')\" style=\"cursor: pointer;\">\n                                      <span class=\"fa fa-angle-down font-16 pt-1\"></span>\n                                      </div>\n                                  </div>\n                                  <div class=\"pt-4 mt-1\">\n                                    :\n                                  </div>\n                                  <div class=\"text-left\">\n                                      <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_min('start_min_thursday')\" style=\"cursor: pointer;\">\n                                        <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                          <input style=\"background: #22283b!important;\" formControlName=\"start_min_thursday\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                          <div (click)=\"decrement_min('start_min_thursday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                      </div>\n                                  </div>\n                                  <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                    <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('thursday_ampm')\">\n                                      {{this.addForm.get('thursday_ampm').value==0?\"AM\":\"PM\"}}\n                                    </button>\n                                  </div>\n                                </div>\n                              </td>\n                              <td style=\"background: #22273c!important;border-bottom: none\">\n                                <div style=\"display:-webkit-inline-box\" >\n                                    <div class=\"form-group text-center\">\n                                      <div (click)=\"increment_hrs('end_hrs_thursday')\" style=\"cursor: pointer;\">\n                                        <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                        <input style=\"background: #22283b!important;\" formControlName=\"end_hrs_thursday\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control hofnumber\">\n                                        <div (click)=\"decrement_hrs('end_hrs_thursday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                    </div>\n                                    <div class=\"pt-4 mt-1\">\n                                      :\n                                    </div>\n                                  <div class=\"text-left\">\n                                      <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_min('end_min_thursday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                          <input style=\"background: #22283b!important;\" formControlName=\"end_min_thursday\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                          <div (click)=\"decrement_min('end_min_thursday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                      </div>\n                                  </div>\n                                  <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                    <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('thursday_ampm_close')\">\n                                      {{this.addForm.get('thursday_ampm_close').value==0?\"AM\":\"PM\"}}\n                                    </button>\n                                  </div>\n                                </div>\n                              </td>\n                            </tr>\n\n                            <tr>\n                              <td style=\"background: #252c44!important;border-bottom: none\"> <span>Friday</span></td>\n                              <td style=\"background: #252c44!important;border-bottom: none\">\n                                <label class=\"custom-switch mt-2 pl-0\">\n                                  <input type=\"checkbox\" (change)=\"friday_open($event)\" checked name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                                  <span class=\"custom-switch-indicator\"></span>\n                                </label>\n                              </td>\n                              <td style=\"background: #252c44!important;border-bottom: none\">\n                                <!-- <label>Opening Time (HH:MM)</label><br> -->\n                                  <div  style=\"display:-webkit-inline-box\" class=\"pt-2\">\n                                  <div class=\"form-group text-center\">\n                                      <div (click)=\"increment_hrs('start_hrs_friday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 \"></span>\n                                      </div>\n                                      <input style=\"background: #22283b!important;\" formControlName=\"start_hrs_friday\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control hofnumber\">\n                                      <div (click)=\"decrement_hrs('start_hrs_friday')\" style=\"cursor: pointer;\">\n                                      <span class=\"fa fa-angle-down font-16 pt-1\"></span>\n                                      </div>\n                                  </div>\n                                  <div class=\"pt-4 mt-1\">\n                                    :\n                                  </div>\n                                  <div class=\"text-left\">\n                                      <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_min('start_min_friday')\" style=\"cursor: pointer;\">\n                                        <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                          <input style=\"background: #22283b!important;\" formControlName=\"start_min_friday\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                          <div (click)=\"decrement_min('start_min_friday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                      </div>\n                                  </div>\n                                  <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                    <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('friday_ampm')\">\n                                      {{this.addForm.get('friday_ampm').value==0?\"AM\":\"PM\"}}\n                                    </button>\n                                  </div>\n                                </div>\n                              </td>\n                              <td style=\"background: #252c44!important;border-bottom: none\">\n                                <div style=\"display:-webkit-inline-box\" >\n                                    <div class=\"form-group text-center\">\n                                      <div (click)=\"increment_hrs('end_hrs_friday')\" style=\"cursor: pointer;\">\n                                        <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                        <input style=\"background: #22283b!important;\" formControlName=\"end_hrs_friday\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control hofnumber\">\n                                        <div (click)=\"decrement_hrs('end_hrs_friday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                    </div>\n                                    <div class=\"pt-4 mt-1\">\n                                      :\n                                    </div>\n                                  <div class=\"text-left\">\n                                      <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_min('end_min_friday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                          <input style=\"background: #22283b!important;\" formControlName=\"end_min_friday\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                          <div (click)=\"decrement_min('end_min_friday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                      </div>\n                                  </div>\n                                  <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                    <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('friday_ampm_close')\">\n                                      {{this.addForm.get('friday_ampm_close').value==0?\"AM\":\"PM\"}}\n                                    </button>\n                                  </div>\n                                </div>\n                              </td>\n                            </tr>\n\n                            <tr>\n                              <td style=\"background: #22273c!important;border-bottom: none\"> <span>Saturday </span></td>\n                              <td style=\"background: #22273c!important;border-bottom: none\">\n                                <label class=\"custom-switch mt-2 pl-0\">\n                                  <input type=\"checkbox\" (change)=\"saturday_open($event)\" checked name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                                  <span class=\"custom-switch-indicator\"></span>\n                                </label>\n                              </td>\n                              <td style=\"background: #22273c!important;border-bottom: none\">\n                                <!-- <label>Opening Time (HH:MM)</label><br> -->\n                                  <div  style=\"display:-webkit-inline-box\" class=\"pt-2\">\n                                  <div class=\"form-group text-center\">\n                                      <div (click)=\"increment_hrs('start_hrs_saturday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 \"></span>\n                                      </div>\n                                      <input style=\"background: #22283b!important;\" formControlName=\"start_hrs_saturday\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control hofnumber\">\n                                      <div (click)=\"decrement_hrs('start_hrs_saturday')\" style=\"cursor: pointer;\">\n                                      <span class=\"fa fa-angle-down font-16 pt-1\"></span>\n                                      </div>\n                                  </div>\n                                  <div class=\"pt-4 mt-1\">\n                                    :\n                                  </div>\n                                  <div class=\"text-left\">\n                                      <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_min('start_min_saturday')\" style=\"cursor: pointer;\">\n                                        <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                          <input style=\"background: #22283b!important;\" formControlName=\"start_min_saturday\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                          <div (click)=\"decrement_min('start_min_saturday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                      </div>\n                                  </div>\n                                  <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                    <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('saturday_ampm')\">\n                                      {{this.addForm.get('saturday_ampm').value==0?\"AM\":\"PM\"}}\n                                    </button>\n                                  </div>\n                                </div>\n                              </td>\n                              <td style=\"background: #22273c!important;border-bottom: none\">\n                                <div style=\"display:-webkit-inline-box\" >\n                                    <div class=\"form-group text-center\">\n                                      <div (click)=\"increment_hrs('end_hrs_saturday')\" style=\"cursor: pointer;\">\n                                        <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                        <input style=\"background: #22283b!important;\" formControlName=\"end_hrs_saturday\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control hofnumber\">\n                                        <div (click)=\"decrement_hrs('end_hrs_saturday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                    </div>\n                                    <div class=\"pt-4 mt-1\">\n                                      :\n                                    </div>\n                                  <div class=\"text-left\">\n                                      <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_min('end_min_saturday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                          <input style=\"background: #22283b!important;\" formControlName=\"end_min_saturday\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                          <div (click)=\"decrement_min('end_min_saturday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                      </div>\n                                  </div>\n                                  <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                    <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('saturday_ampm_close')\">\n                                      {{this.addForm.get('saturday_ampm_close').value==0?\"AM\":\"PM\"}}\n                                    </button>\n                                  </div>\n                                </div>\n                              </td>\n                            </tr>\n                          </tbody>\n                          </table>\n                        </div>\n                    </div>\n\n                  </div>\n\n                  </fieldset>\n\n\n                  <fieldset class=\"scheduler-border\">\n                    <legend class=\"scheduler-border\">DTMF Settings</legend>\n                    <div class=\"row\">\n                     <div class=\"col-md-2\">\n                        <div class=\"control-group mt-2\">\n                          <div class=\"control-label\">DTMF Auto</div>\n                        </div>\n                     </div>\n                     <div class=\"col-md-2\">\n                      <label class=\"custom-switch mt-2 pl-0\">\n                        <input type=\"checkbox\" (change)=\"dtmf_auto_toggle($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                        <span class=\"custom-switch-indicator\"></span>\n                      </label>\n                     </div>\n                   </div>\n\n                   <div class=\"row mt-2\" *ngIf=\"dtmf_auto==true\">\n                     <div class=\"col-md-2\">\n                        <div class=\"control-group mt-3\">\n                          <div class=\"control-label\">DTMF Value</div>\n                        </div>\n                     </div>\n                     <div class=\"col-md-2 mt-4\">\n                       <div class=\"form-group\">\n                        <!-- <span class=\"currency currency-with-toggle ng-scope\">$</span> -->\n                        <input formControlName=\"dtmf_value\" type=\"text\" class=\"form-control formcontrol\" id=\"\">\n                      </div>\n                     </div>\n                   </div>\n\n                   <div class=\"row mt-2\" *ngIf=\"dtmf_auto==true\">\n                     <div class=\"col-md-2\">\n                        <div class=\"control-group mt-3\">\n                          <div class=\"control-label\">DTMF Interval (Seconds)</div>\n                        </div>\n                     </div>\n                     <div class=\"col-md-2 mt-4\">\n                       <div class=\"form-group\">\n                        <input formControlName=\"dtmf_interval\" type=\"text\" class=\"form-control formcontrol\" id=\"\">\n                      </div>\n                     </div>\n                   </div>\n\n                   <div class=\"row mt-2\" *ngIf=\"dtmf_auto==true\">\n                     <div class=\"col-md-2\">\n                        <div class=\"control-group mt-3\">\n                          <div class=\"control-label\">DTMF Percentage</div>\n                        </div>\n                     </div>\n                     <div class=\"col-md-2\">\n                       <div class=\"form-group\">\n                        <select formControlName=\"dtmf_percent\" class=\"form-control\">\n                          <!-- <option value=\"1\">10%</option>\n                          <option value=\"3\">25%</option>\n                          <option value=\"5\">50%</option>\n                          <option value=\"10\">100%</option> -->\n                          <option value=\"1\">10%</option>\n                          <option value=\"2\">20%</option>\n                          <option value=\"3\">30%</option>\n                          <option value=\"4\">40%</option>\n                          <option value=\"5\">50%</option>\n                          <option value=\"6\">60%</option>\n                          <option value=\"7\">70%</option>\n                          <option value=\"8\">80%</option>\n                          <option value=\"9\">90%</option>\n                          <option value=\"10\">100%</option>\n                        </select>\n                      </div>\n                     </div>\n                   </div>\n\n                   <div class=\"row mt-2\" *ngIf=\"dtmf_auto==true\">\n                    <div class=\"col-md-2\">\n                       <div class=\"control-group mt-3\">\n                         <div class=\"control-label\">Identify zipcode</div>\n                       </div>\n                    </div>\n                    <div class=\"col-md-2\">\n                      <label class=\"custom-switch mt-2 pl-0\">\n                        <input type=\"checkbox\" (change)=\"dtmf_zipcode_enable_toggle($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                        <span class=\"custom-switch-indicator\"></span>\n                      </label>\n                     </div>\n                  </div>\n\n                  </fieldset>\n\n\n                    <fieldset class=\"scheduler-border\">\n                      <legend class=\"scheduler-border\">Cap Settings</legend>\n                      <div class=\"control-group mt-2\">\n                        <label>Cap On</label>\n                        <select formControlName=\"capon\" name=\"capon\" id=\"capon\" class=\"form-control\" [value]=\"0\">\n                          <option value=\"0\">Conversion</option>\n                          <option value=\"1\">Connection</option>\n                          <option value=\"2\">Revenue</option>\n                        </select>\n                     </div>\n\n                     <div class=\"row\" *ngIf=\"this.addForm.get('capon').value!=2\">\n                      <div class=\"col-md-2\">\n                         <div class=\"control-group mt-2\">\n                           <div class=\"control-label\">Global Cap</div>\n                           <label class=\"custom-switch mt-2 pl-0\">\n                             <input type=\"checkbox\" [checked]=\"globalcap==true\" (change)=\"global_cap($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                             <span class=\"custom-switch-indicator\"></span>\n                           </label>\n                         </div>\n                      </div>\n                      <div class=\"col-md-2 mt-4\">\n                         <div class=\"form-group\" *ngIf=\"globalcap==true\">\n                          <span class=\"currency currency-with-toggle ng-scope\"><br/></span>\n                           <input formControlName=\"global_capvalue\" type=\"text\" class=\"form-control formcontrol\" id=\"\">\n                         </div>\n                         <div class=\"form-group mt-2\" *ngIf=\"globalcap!=true\">\n                           <span>None</span>\n                         </div>\n                      </div>\n                    </div>\n\n                    <div class=\"row\" *ngIf=\"this.addForm.get('capon').value==2\">\n                      <div class=\"col-md-2\">\n                         <div class=\"control-group mt-2\">\n                           <div class=\"control-label\">Global Revenue Cap</div>\n                           <label class=\"custom-switch mt-2 pl-0\">\n                             <input type=\"checkbox\" [checked]=\"global_revenuecap==true\" (change)=\"global_revenue_cap($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                             <span class=\"custom-switch-indicator\"></span>\n                           </label>\n                         </div>\n                      </div>\n                      <div class=\"col-md-2 mt-4\">\n                         <div class=\"form-group\" *ngIf=\"global_revenuecap==true\">\n                           <span class=\"currency currency-with-toggle ng-scope\">$</span>\n                           <input formControlName=\"global_revenuecapvalue\" type=\"text\" class=\"form-control formcontrol\" id=\"\">\n                         </div>\n                         <div class=\"form-group mt-2\" *ngIf=\"global_revenuecap!=true\">\n                           <span>None</span>\n                         </div>\n                      </div>\n                    </div>\n\n                    <div class=\"row\" *ngIf=\"this.addForm.get('capon').value==2\">\n                      <div class=\"col-md-2\">\n                         <div class=\"control-group mt-2\">\n                           <div class=\"control-label\" >Monthly Revenue Cap</div>\n                           <label class=\"custom-switch mt-2 pl-0\">\n                             <input type=\"checkbox\" [checked]=\"monthly_revenuecap==true\" (change)=\"monthly_revenue_cap($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                             <span class=\"custom-switch-indicator\"></span>\n                           </label>\n                         </div>\n                      </div>\n                      <div class=\"col-md-2 mt-4\">\n                         <div class=\"form-group\" *ngIf=\"monthly_revenuecap==true\">\n                           <span class=\"currency currency-with-toggle ng-scope\">$</span>\n                           <input formControlName=\"monthly_revenuecapvalue\" type=\"text\" class=\"form-control formcontrol\" id=\"\">\n                         </div>\n                         <div class=\"form-group mt-2\" *ngIf=\"monthly_revenuecap!=true\">\n                           <span>None</span>\n                         </div>\n                      </div>\n                    </div>\n\n                    <div class=\"row\" *ngIf=\"this.addForm.get('capon').value!=2\">\n                      <div class=\"col-md-2\">\n                         <div class=\"control-group mt-2\">\n                           <div class=\"control-label\" >Monthly Cap</div>\n                           <label class=\"custom-switch mt-2 pl-0\">\n                             <input type=\"checkbox\" [checked]=\"monthlycap==true\" (change)=\"monthly_cap($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                             <span class=\"custom-switch-indicator\"></span>\n                           </label>\n                         </div>\n                      </div>\n                      <div class=\"col-md-2 mt-4\">\n                         <div class=\"form-group\" *ngIf=\"monthlycap==true\">\n                          <span class=\"currency currency-with-toggle ng-scope\"><br/></span>\n                           <input formControlName=\"monthly_capvalue\" type=\"text\" class=\"form-control formcontrol\" id=\"\">\n                         </div>\n                         <div class=\"form-group mt-2\" *ngIf=\"monthlycap!=true\">\n                           <span>None</span>\n                         </div>\n                      </div>\n                    </div>\n\n                    <div class=\"row\" *ngIf=\"this.addForm.get('capon').value==2\">\n                      <div class=\"col-md-2\">\n                         <div class=\"control-group mt-2\">\n                           <div class=\"control-label\" >Daily Revenue Cap</div>\n                           <label class=\"custom-switch mt-2 pl-0\">\n                             <input type=\"checkbox\" [checked]=\"daily_revenuecap==true\" (change)=\"daily_revenue_cap($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                             <span class=\"custom-switch-indicator\"></span>\n                           </label>\n                         </div>\n                      </div>\n                      <div class=\"col-md-2 mt-4\">\n                         <div class=\"form-group\" *ngIf=\"daily_revenuecap==true\">\n                          <span class=\"currency currency-with-toggle ng-scope\">$</span>\n                           <input formControlName=\"daily_revenuecapvalue\" type=\"text\" class=\"form-control formcontrol\" id=\"\">\n                         </div>\n                         <div class=\"form-group mt-2\" *ngIf=\"daily_revenuecap!=true\">\n                           <span>None</span>\n                         </div>\n                      </div>\n                    </div>\n\n                    <div class=\"row\" *ngIf=\"this.addForm.get('capon').value!=2\">\n                      <div class=\"col-md-2\">\n                         <div class=\"control-group mt-2\">\n                           <div class=\"control-label\" >Daily Cap</div>\n                           <label class=\"custom-switch mt-2 pl-0\">\n                             <input type=\"checkbox\" [checked]=\"dailycap==true\" (change)=\"daily_cap($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                             <span class=\"custom-switch-indicator\"></span>\n                           </label>\n                         </div>\n                      </div>\n                      <div class=\"col-md-2 mt-4\">\n                         <div class=\"form-group\" *ngIf=\"dailycap==true\">\n                          <span class=\"currency currency-with-toggle ng-scope\"><br/></span>\n                           <input formControlName=\"daily_capvalue\" type=\"text\" class=\"form-control formcontrol\" id=\"\">\n                         </div>\n                         <div class=\"form-group mt-2\" *ngIf=\"dailycap!=true\">\n                           <span>None</span>\n                         </div>\n                      </div>\n                    </div>\n\n                    <div class=\"row\" *ngIf=\"this.addForm.get('capon').value==2\">\n                      <div class=\"col-md-2\">\n                         <div class=\"control-group mt-2\">\n                           <div class=\"control-label\">Hourly Revenue Cap</div>\n                           <label class=\"custom-switch mt-2 pl-0\">\n                             <input type=\"checkbox\" [checked]=\"hourly_revenuecap==true\"  (change)=\"hourly_revenue_cap($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                             <span class=\"custom-switch-indicator\"></span>\n                           </label>\n                         </div>\n                      </div>\n                      <div class=\"col-md-2 mt-4\">\n                         <div class=\"form-group\" *ngIf=\"hourly_revenuecap==true\">\n                           <span class=\"currency currency-with-toggle ng-scope\">$</span>\n                           <input formControlName=\"hourly_revenuecapvalue\" type=\"text\" class=\"form-control formcontrol\" id=\"\">\n                         </div>\n                         <div class=\"form-group mt-2\" *ngIf=\"hourly_revenuecap!=true\">\n                           <span>None</span>\n                         </div>\n                      </div>\n                    </div>\n\n                    <div class=\"row\" *ngIf=\"this.addForm.get('capon').value!=2\">\n                      <div class=\"col-md-2\">\n                         <div class=\"control-group mt-2\">\n                           <div class=\"control-label\">Hourly Cap</div>\n                           <label class=\"custom-switch mt-2 pl-0\">\n                             <input type=\"checkbox\" [checked]=\"hourlycap==true\"  (change)=\"hourly_cap($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                             <span class=\"custom-switch-indicator\"></span>\n                           </label>\n                         </div>\n                      </div>\n                      <div class=\"col-md-2 mt-4\">\n                         <div class=\"form-group\" *ngIf=\"hourlycap==true\">\n                          <span class=\"currency currency-with-toggle ng-scope\"><br/></span>\n                           <input formControlName=\"hourly_capvalue\" type=\"text\" class=\"form-control formcontrol\" id=\"\">\n                         </div>\n                         <div class=\"form-group mt-2\" *ngIf=\"hourlycap!=true\">\n                           <span>None</span>\n                         </div>\n                      </div>\n                    </div>\n\n\n                     <!-- <div class=\"row\">\n                       <div class=\"col-md-2\">\n                          <div class=\"control-group mt-2\">\n                            <div class=\"control-label\">Global Revenue Cap</div>\n                            <label class=\"custom-switch mt-2 pl-0\">\n                              <input type=\"checkbox\" (change)=\"global_revenue_cap($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                              <span class=\"custom-switch-indicator\"></span>\n                            </label>\n                          </div>\n                       </div>\n                       <div class=\"col-md-2 mt-4\">\n                          <div class=\"form-group\" *ngIf=\"global_revenuecap==true\">\n                            <span class=\"currency currency-with-toggle ng-scope\">$</span>\n                            <input formControlName=\"global_revenuecapvalue\" type=\"text\" class=\"form-control formcontrol\" id=\"\">\n                          </div>\n                          <div class=\"form-group mt-2\" *ngIf=\"global_revenuecap!=true\">\n                            <span>None</span>\n                          </div>\n                       </div>\n                     </div>\n\n                     <div class=\"row\">\n                       <div class=\"col-md-2\">\n                          <div class=\"control-group mt-2\">\n                            <div class=\"control-label\">Monthly Revenue Cap</div>\n                            <label class=\"custom-switch mt-2 pl-0\">\n                              <input type=\"checkbox\" (change)=\"monthly_revenue_cap($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                              <span class=\"custom-switch-indicator\"></span>\n                            </label>\n                          </div>\n                       </div>\n                       <div class=\"col-md-2 mt-4\">\n                          <div class=\"form-group\" *ngIf=\"monthly_revenuecap==true\">\n                            <span class=\"currency currency-with-toggle ng-scope\">$</span>\n                            <input formControlName=\"monthly_revenuecapvalue\" type=\"text\" class=\"form-control formcontrol\" id=\"\">\n                          </div>\n                          <div class=\"form-group mt-2\" *ngIf=\"monthly_revenuecap!=true\">\n                            <span>None</span>\n                          </div>\n                       </div>\n                     </div>\n\n                     <div class=\"row\">\n                       <div class=\"col-md-2\">\n                          <div class=\"control-group mt-2\">\n                            <div class=\"control-label\">Daily Revenue Cap</div>\n                            <label class=\"custom-switch mt-2 pl-0\">\n                              <input type=\"checkbox\" (change)=\"daily_revenue_cap($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                              <span class=\"custom-switch-indicator\"></span>\n                            </label>\n                          </div>\n                       </div>\n                       <div class=\"col-md-2 mt-4\">\n                          <div class=\"form-group\" *ngIf=\"daily_revenuecap==true\">\n                            <span class=\"currency currency-with-toggle ng-scope\">$</span>\n                            <input formControlName=\"daily_revenuecapvalue\" type=\"text\" class=\"form-control formcontrol\" id=\"\">\n                          </div>\n                          <div class=\"form-group mt-2\" *ngIf=\"daily_revenuecap!=true\">\n                            <span>None</span>\n                          </div>\n                       </div>\n                     </div>\n\n                     <div class=\"row\">\n                       <div class=\"col-md-2\">\n                          <div class=\"control-group mt-2\">\n                            <div class=\"control-label\">Hourly Revenue Cap</div>\n                            <label class=\"custom-switch mt-2 pl-0\">\n                              <input type=\"checkbox\" (change)=\"hourly_revenue_cap($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                              <span class=\"custom-switch-indicator\"></span>\n                            </label>\n                          </div>\n                       </div>\n                       <div class=\"col-md-2 mt-4\">\n                          <div class=\"form-group\" *ngIf=\"hourly_revenuecap==true\">\n                            <span class=\"currency currency-with-toggle ng-scope\">$</span>\n                            <input formControlName=\"hourly_revenuecapvalue\" type=\"text\" class=\"form-control formcontrol\" id=\"\">\n                          </div>\n                          <div class=\"form-group mt-2\" *ngIf=\"hourly_revenuecap!=true\">\n                            <span>None</span>\n                          </div>\n                       </div>\n                     </div>\n                     -->\n                    </fieldset>\n\n                    <fieldset class=\"scheduler-border\">\n                      <legend class=\"scheduler-border\">Concurrency Settings</legend>\n\n                      <div class=\"row\">\n                        <div class=\"col-md-2\">\n                           <div class=\"control-group mt-2\">\n                             <div class=\"control-label\">Max Concurrency</div>\n                             <label class=\"custom-switch mt-2 pl-0\">\n                               <input type=\"checkbox\" (change)=\"get_maxcon($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                               <span class=\"custom-switch-indicator\"></span>\n                             </label>\n                           </div>\n                        </div>\n                        <div class=\"col-md-2 mt-4\">\n                           <div class=\"form-group\" *ngIf=\"maxconcurrency==true\">\n                             <input formControlName=\"maxconvalue\" type=\"text\" class=\"form-control formcontrolwithouticon\" id=\"\">\n                           </div>\n                           <div class=\"form-group mt-2\" *ngIf=\"maxconcurrency!=true\">\n                             <span>None</span>\n                           </div>\n                        </div>\n                      </div>\n                    </fieldset>\n\n                    <fieldset class=\"scheduler-border\">\n                      <legend class=\"scheduler-border\">Restrict Duplicate Calls Settings</legend>\n\n                      <div class=\"control-group mt-2\">\n                        <label>Restrict Duplicate</label>\n                        <select #restrictdup formControlName=\"restrictdup\" name=\"restrictdup\" id=\"restrictdup\" class=\"form-control\">\n                          <option value=\"0\">Buyer Settings (Do not Restrict)</option>\n                          <option value=\"1\">Do not Restrict</option>\n                          <option value=\"2\">By Campaign - Individual Target</option>\n                        </select>\n                     </div>\n                     <div *ngIf=\"restrictdup.value==2\">\n                     <div class=\"control-group mt-2\">\n                        <label>Restrict After</label>\n                        <select formControlName=\"restrictafter\" name=\"restrictafter\" id=\"restrictafter\" class=\"form-control\">\n                          <option value=\"0\">Converted</option>\n                          <option value=\"1\">Connected</option>\n                        </select>\n                     </div>\n\n                      <div class=\"control-group\">\n                          <label class=\"control-label input-label\" for=\"startTime\">Duration:</label>\n                          <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                          <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': settingToggleDurationvalue==0}\" (click)=\"settingToggleDuration(0)\">\n                                <input class=\"form-check-input\" name=\"settingToggleDuration\" formControlName=\"settingToggleDuration\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                                Always\n                          </label>\n                          <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': settingToggleDurationvalue==1}\" (click)=\"settingToggleDuration(1)\">\n                            <input class=\"form-check-input\" name=\"settingToggleDuration\" formControlName=\"settingToggleDuration\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                            Time Limit\n                          </label>\n                            </div>\n                     </div>\n                      <br>\n                      <div class=\"control-group row mt-2\" *ngIf=\"this.addForm.get('settingToggleDurationval').value==1\">\n                        <div class=\"col-md-1 mt-2\"><input  formControlName=\"days\" style=\"width: 80px;\" type=\"number\"  class=\"form-control formcontrol\" name=\"\" id=\"\"></div>\n                        <div class=\"col-md-1\"><span>Days</span></div>\n                      </div>\n                      </div>\n                    </fieldset>\n\n                    <fieldset class=\"scheduler-border\">\n                      <legend class=\"scheduler-border\">Publisher Tag Routing Filters</legend>\n                      <div class=\"row\" *ngIf=\"ispubfilter==0\">\n                        <div class=\"col-md-2 mt-2\">\n                          <input type=\"button\" (click)=\"ispubfilterselect()\" value=\"+ ADD FILTER\" class=\"btn btn-primary btn-sm\">\n                        </div>\n                      </div>\n\n\n                      <div  *ngIf=\"ispubfilter==1\" style=\"display: flex;flex-wrap: wrap;\">\n                        <div class=\"mt-2\" *ngFor=\"let item of filterselected;let i=index\" style=\"padding: 4px;\">\n                          <button type=\"button\" *ngIf=\"item.isorand==0 && i!=0\" class=\"btn btn-primary btn-sm\" style=\"font-size: 11px; margin-right: 7px;\">OR</button>\n                          <button type=\"button\" *ngIf=\"item.isorand==1 && i!=0\" class=\"btn btn-primary btn-sm\" style=\"font-size: 11px;margin-right: 7px;\">AND</button>\n                          <button type=\"button\" (click)=\"clearfilter(i)\" class=\"btn btn-secondary btn-sm\" style=\"font-size: 11px;    background: #232840;\n                          padding: 6px 12px;\n                          border: none;\">\n                            <span *ngIf=\"item.containfiltertype==0\">Filter - Name -</span> {{item.filterlabel}} - <small>{{item.containfiltertext}}</small>&nbsp;&nbsp; <b>{{item.name}}</b>&nbsp; <span class=\"fa fa-times\"></span>\n                            <span *ngIf=\"item.containfiltertype==1\">Filter - ID - {{item.filterlabel}} - <small>{{item.containfiltertext}}</small>&nbsp;&nbsp; <b>{{item.name}}</b>&nbsp; <span class=\"fa fa-times\"></span></span>\n                            <!-- <span *ngIf=\"item.containfiltertype==2\">Filter - Zipcode - {{item.filterlabel}} - <small>{{item.containfiltertext}}</small>&nbsp;&nbsp; <b>{{item.name}}</b>&nbsp; <span class=\"fa fa-times\"></span></span> -->\n                          </button>\n                        </div>\n                      </div>\n\n                      <div class=\"row\" *ngIf=\"ispubfilter==1\">\n                        <div class=\"col-md-2 mt-2\">\n                          <select formControlName=\"pubfiltertype\" class=\"form-control\" (change)=\"getpubfiltertype($event)\">\n                            <option value=\"0\">Filter - Name - Publisher</option>\n                            <option value=\"1\">Filter - ID - Publisher</option>\n                            <!-- <option value=\"2\">Filter - ID - Zipcode</option>                             -->\n                          </select>\n                        </div>\n                        <div class=\"col-md-2 mt-2\">\n                          <select [value]=\"0\" formControlName=\"pubiscontains\" class=\"form-control\">\n                            <option value=\"2\" >Contains</option>\n                            <option value=\"3\" >Does Not contain</option>\n                            <option value=\"4\" >Begins With</option>\n                            <option value=\"5\" >Does Not Begin With</option>\n                            <!-- <option value=\"6\" >Greater Than</option>\n                            <option value=\"7\" >Less Than</option>     -->\n                            <option value=\"0\" >Equals Single Value</option>\n                            <option value=\"1\" >Does Not Equal Single Value</option>\n                          </select>\n                        </div>\n                        <div class=\"col-md-5 mt-2\" >\n                          <div  *ngIf=\"this.addForm.get('pubfiltertype').value!=2\">\n                          <angular2-multiselect  *ngIf=\"this.addForm.get('pubiscontains').value==0 || this.addForm.get('pubiscontains').value==1\" [data]=\"allpublisher\" formControlName=\"pubvalue\" [settings]=\n                          \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select Publisher '}\" ></angular2-multiselect>\n\n                          <div class=\"form-group mt-2\" *ngIf=\"this.addForm.get('pubiscontains').value>1\">\n                            <input formControlName=\"pubvalue\" type=\"text\" class=\"form-control formcontrolwithouticon\" id=\"\">\n                          </div>\n                        </div>\n                          <div class=\"form-group\" *ngIf=\"this.addForm.get('pubfiltertype').value==2\" >\n                            <angular2-multiselect  *ngIf=\"this.addForm.get('pubiscontains').value==0 || this.addForm.get('pubiscontains').value==1\" [data]=\"allzipcode\" formControlName=\"pubvalue\" [settings]=\n                            \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select File '}\" ></angular2-multiselect>\n                            <!-- <input type=\"file\" formControlName=\"pubvalue\"> -->\n                            <!-- <input formControlName=\"pubvalue\" type=\"text\" class=\"form-control formcontrolwithouticon\" id=\"\"> -->\n                          </div>\n                        </div>\n                        <div class=\"col-md-1 pt-3\" *ngIf=\"this.addForm.get('pubfiltertype').value==2\" >\n                          <i data-toggle=\"modal\" data-target=\"#addZipcode\" class=\"fa fa-upload\" style=\"background: #0266c8;\n                          color: white;\n                          padding: 6px;\n                          border-radius: 5px;\"></i>\n                        </div>\n                        <div class=\"col-md-1 pt-2\">\n                          <input type=\"button\" (click)=\"ispubfilterclear()\" value=\"Clear\" class=\"btn btn-danger\">\n                        </div>\n                      </div>\n\n                      <div class=\"row mt-2\" *ngIf=\"ispubfilter==1\">\n                        <div class=\"col-md-12\">\n                          <button type=\"button\" style=\"width: 100px;font-size: 8px;height: 32px;background: #3858e7;border: none;\" (click)=\"addorrule()\" class=\"btn btn-primary btn-sm\"><i class=\"fa fa-plus\" style=\"font-size: 9px;\"></i>  OR RULE</button>\n                          <button type=\"button\" style=\"margin-left:5px;width: 100px;font-size: 8px;height: 32px;border: none;background: #3858e7;\" (click)=\"addandrule()\" class=\"btn btn-primary btn-sm\"><i class=\"fa fa-plus\" style=\"font-size: 9px;\"></i>  AND RULE</button>\n                        </div>\n                      </div>\n                    </fieldset>\n\n                      <fieldset class=\"scheduler-border\">\n                      <legend class=\"scheduler-border\">Tag Routing Filters</legend>\n                      <div class=\"row\" *ngIf=\"isfilter==0\">\n                        <div class=\"col-md-2 mt-2\">\n                          <input type=\"button\" (click)=\"isfilterselect()\" value=\"+ ADD FILTER\" class=\"btn btn-primary btn-sm\">\n                        </div>\n                      </div>\n                      <div class=\"row\" *ngIf=\"isfilter==1\">\n                        <div class=\"col-md-2 mt-2\">\n                          <label for=\"\">Select City/State</label>\n                          <select formControlName=\"citystatetype\" class=\"form-control\">\n                            <option value=\"0\">City</option>\n                            <option value=\"1\">States</option>\n                          </select>\n                        </div>\n                        <div class=\"col-md-2 mt-2\">\n                          <label for=\"\">Select Is Contains?</label>\n                          <select [value]=\"0\" formControlName=\"iscontains\" (change)=\"changetype($event)\" class=\"form-control\">\n                            <option value=\"0\">Contains</option>\n                            <option value=\"1\">Not Contains</option>\n                          </select>\n                        </div>\n                        <div class=\"col-md-2 mt-2\" >\n                        <!-- <div class=\"col-md-2 mt-2\" *ngIf=\"this.addForm.get('citystatetype').value==0\"> -->\n                          <label for=\"\">Select State</label>\n                          <angular2-multiselect *ngIf=\"this.addForm.get('citystatetype').value==1\" [data]=\"allcitystate\" formControlName=\"citystate\" [settings]=\n                          \"{enableSearchFilter: true,showCheckbox:false,singleSelection: false, text:'Select State '}\" ></angular2-multiselect>\n\n                          <select *ngIf=\"this.addForm.get('citystatetype').value==0\" formControlName=\"citystate\" (change)='getdata()' class=\"form-control\" [value]=\"\">\n                            <option value=\"\">Select State</option>\n                            <option value=\"{{item.id}}\" *ngFor=\"let item of allcitystate\">{{item.text}}</option>\n                          </select>\n                        </div>\n                          <div class=\"col-md-6 mt-2\" *ngIf=\"this.addForm.get('citystatetype').value==0\">\n                          <label for=\"\">Select City</label>\n                          <!-- <label for=\"\" *ngIf=\"this.addForm.get('citystate').value==1\">Select State</label> -->\n                          <!-- <select formControlName=\"citystate\" class=\"form-control\" [value]=\"0\">\n                            <option value=\"0\">City</option>\n                            <option value=\"1\">States</option>\n                          </select>      -->\n                          <angular2-multiselect [data]=\"allcity\" formControlName=\"cityval\" [settings]=\n                          \"{enableSearchFilter: true,showCheckbox:false,singleSelection: false, text:'Select City '}\" ></angular2-multiselect>\n                          </div>\n                        <div class=\"col-md-1 mt-4 pt-3\">\n                          <input type=\"button\" (click)=\"isfilterclear()\" value=\"Clear\" class=\"btn btn-danger\">\n                        </div>\n                      </div>\n                    </fieldset>\n\n                  </div>\n                  <div class=\"card-footer text-left\">\n                        <button *ngIf=\"!loader\" [disabled]=\"isTargetName == 'fail'\"  class=\"btn btn-primary btn-sm p-2 mr-1\" type=\"submit\">Create Target</button>\n                        <button *ngIf=\"loader\" class=\"btn btn-primary btn-sm p-2 mr-1\" type=\"button\">Creating Target...</button>\n                        <button style=\"margin-right: 4px;\" routerLink=\"/target\" class=\"btn btn-sm btn-primary p-2\">Back To Targets</button>\n                        <button (click)=\"onReset()\" class=\"btn btn-secondary btn-sm p-2\" type=\"reset\">Reset</button>\n                      </div>\n                </div>\n              </form>\n\n    </div>\n";

/***/ }),

/***/ 16385:
/*!********************************************************************************!*\
  !*** ./src/app/modules/number/numberedit/numberedit.component.html?ngResource ***!
  \********************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n<!-- FSL Modal -->\n<div class=\"modal  fade\" id=\"addFSLRules\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\naria-hidden=\"true\">\n<div class=\"modal-dialog modal-lg\" role=\"document\">\n  <div class=\"modal-content\">\n    <div class=\"modal-header\">\n      <h5 class=\"modal-title\" id=\"formModal\">Add New Target</h5>\n      <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n        <span aria-hidden=\"true\">&times;</span>\n      </button>\n    </div>\n    <div class=\"modal-body\">\n\n      <form [formGroup]=\"addFSLRules\" (ngSubmit)=\"onFSLSubmit()\">\n        <div class=\"form-group\">\n            <label>Name</label>\n            <input formControlName=\"name\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': FSLRulesSubmitted && rules.name.errors }\" (input)=\"validatename()\">\n            <div *ngIf=\"FSLRulesSubmitted && rules.name.errors\" class=\"invalid-feedback\">\n                <div *ngIf=\"rules.name.errors.required\">Name is required</div>\n            </div>\n            <div *ngIf=\"isName == 'success'  && isName != ''\" style=\"color:green;\">\n             Name Is Available\n           </div>\n            <div *ngIf=\"isName == 'fail' && isName != ''\" style=\"color:red;\">\n             Name Is Not Available\n           </div>\n          </div>\n\n          <div class=\"form-group\">\n            <label  class=\"d-block\">Number of Time Frames:</label>\n            <input formControlName=\"numberoftimeframe\"  oninput=\"javascript: if (this.value.length > this.maxLength) this.value = this.value.slice(0, this.maxLength);\"\n            type = \"number\" maxlength = \"1\" [(ngModel)]=\"noofforwarding\" type=\"number\" class=\"form-control phone-number\" [ngClass]=\"{ 'is-invalid': FSLRulesSubmitted && rules.numberoftimeframe.errors }\" min=\"1\" max=\"7\">\n            <div *ngIf=\"FSLRulesSubmitted && rules.numberoftimeframe.errors\" class=\"invalid-feedback\">\n              <div *ngIf=\"rules.numberoftimeframe.errors.required\">Number of Time Frames is required</div>\n          </div>\n          </div>\n\n          <br>\n          <!-- Day 1 -->\n          <div class=\"groupborder\" *ngIf=\"noofforwarding>=1\">\n            <div >\n              <div class=\"form-group\">\n                  <label>Select Timeframe - 1</label>\n                  <select formControlName=\"day_0\" name=\"day-0\" id=\"day-0\" class=\"form-control\" [value]=\"0\">\n                    <option value=\"0\">Select Day</option>\n                    <option *ngFor=\"let item of allweekdays\" value=\"{{item.id}}\">{{item.start_day}} to {{item.end_day}}</option>\n                  </select>\n                </div>\n              <div class=\"row\">\n              <div class=\"col-md-12\">\n              <!-- <div class=\"row\">\n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                        <label>Start Time</label>\n                        <input formControlName=\"start_time_0\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\" placeholder=\"Ex :00:00\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time>\n                    </div>\n                </div>\n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                        <label>End Time</label>\n                        <input formControlName=\"end_time_0\" [owlDateTimeTrigger]=\"dt1\" class=\"form-control\" [owlDateTime]=\"dt1\" placeholder=\"Ex :00:00\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt1></owl-date-time>\n                    </div>\n                </div>\n              </div>                   -->\n\n\n              <div class=\"row\">\n                <div class=\"col-md-3\">\n                    <label>Start Time (HH:MM)</label><br>\n                      <div  style=\"display:-webkit-inline-box\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"start_hrs_0\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                          <!-- <input formControlName=\"start_time_0\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time> -->\n                      </div>\n                      <div class=\"pt-2\">\n                        :\n                      </div>\n                    <div class=\"text-left\">\n                        <div class=\"form-group\">\n                            <input style=\"width:68px\" formControlName=\"start_min_0\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                        </div>\n                    </div>\n                  </div>\n                </div>\n\n                <div class=\"col-md-4\">\n                  <label>End Time (HH:MM)</label><br>\n                    <div  style=\"display:-webkit-inline-box\">\n                    <div class=\"form-group\">\n                        <input style=\"width:68px\" formControlName=\"end_hrs_0\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                    </div>\n                    <div class=\"pt-2\">\n                      :\n                    </div>\n                  <div class=\"text-left\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"end_min_0\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                      </div>\n                  </div>\n                </div>\n                </div>\n              </div>\n\n              <div>\n\n               <div class=\"form-group\">\n                   <label  class=\"d-block\">Enter Number Of Forwarding Location:</label>\n                   <input formControlName=\"noofforwardinglocation_1\" [(ngModel)]=\"noofforwardinglocation_1\" type=\"text\" class=\"form-control phone-number\">\n               </div>\n\n               <div class=\"groupborder\" *ngFor='let in of selectednoofforwardinglocation();let i = index'>\n                 <div class=\"form-group\">\n                     <label class=\"d-block\">Primary Forwarding Location - {{i+1}}</label>\n                     <div class=\"form-check form-check-inline\">\n                         <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day0\" name=\"PrimaryforwardType_{{i}}_day0\" class=\"with-gap number\" [value]='0' (click)=\"setPrimaryforward(0,i,0)\" [checked]=\"true\">\n\n                       <label class=\"form-check-label\" for=\"inlineradio1\">Number</label>\n                     </div>\n                     <div class=\"form-check form-check-inline\">\n                         <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day0\" name=\"PrimaryforwardType_{{i}}_day0\" (click)=\"setPrimaryforward(1,i,0)\" class=\"with-gap\" [value]=\"1\">\n                       <label class=\"form-check-label\" for=\"inlineradio2\">IVR Menu</label>\n                     </div>\n                     <div class=\"form-check form-check-inline\">\n                         <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day0\" name=\"PrimaryforwardType_{{i}}_day0\" class=\"with-gap\" (click)=\"setPrimaryforward(2,i,0)\" [value]=\"2\">\n                       <label class=\"form-check-label\" for=\"inlineCheckbox3\">SIP (IP Address)</label>\n                     </div>\n                   </div>\n                   <div class=\"form-group\" *ngIf=\"!isPrimarySelected(1,i,0) && !isPrimarySelected(2,i,0)\">\n                         <label  class=\"d-block\">Number:</label>\n                         <input type=\"text\" formControlName=\"number_{{i}}_day0\" id=\"number_{{i}}_day0\" class=\"form-control phone-number\" placeholder=\"(000) 000-000\"  maxlength=\"16\" (keypress)=_keyPress($event)>\n                   </div>\n                   <div class=\"form-group\" *ngIf=\"isPrimarySelected(1,i,0)\">\n                         <label  class=\"d-block\">IVR Menu:</label>\n                           <!-- <input type=\"text\" formControlName=\"ivrMenu_{{i}}_day0\" class=\"form-control phone-number\">   -->\n\n                           <select formControlName=\"ivrMenu_{{i}}_day0\" class=\"form-control\" [value] = \"\">\n                               <option value=\"\">Select IVR Menu</option>\n                               <option *ngFor=\"let data of ivrmenus;\" [value]=\"data.uuid\">\n                                   {{data.name}}\n                                 </option>\n                             </select>\n                     </div>\n                     <div class=\"form-group\" *ngIf=\"isPrimarySelected(2,i,0)\">\n                           <label  class=\"d-block\">SIP (IP Address):</label>\n                           <input  formControlName=\"sipAdd_{{i}}_day0\" type=\"text\" class=\"form-control phone-number\">\n                     </div>\n               </div>\n               </div>\n\n           </div>\n           </div>\n        </div>\n           </div>\n\n          <!-- Day 2 -->\n           <div class=\"groupborder\" *ngIf=\"noofforwarding>=2\">\n            <div >\n              <div class=\"form-group\">\n                  <label>Select Timeframe - 2</label>\n                  <select formControlName=\"day_1\" class=\"form-control\" [value]=\"0\" >\n                    <option value=\"0\">Select Day</option>\n                    <option *ngFor=\"let item of allweekdays\" value=\"{{item.id}}\">{{item.start_day}} to {{item.end_day}}</option>\n                    </select>\n                </div>\n              <div class=\"row\">\n              <div class=\"col-md-12\">\n              <!-- <div class=\"row\">\n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                        <label>Start Time</label>\n                        <input formControlName=\"start_time_1\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\" placeholder=\"Ex :00:00\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time>\n                    </div>\n                </div>\n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                        <label>End Time</label>\n                        <input formControlName=\"end_time_1\" [owlDateTimeTrigger]=\"dt1\" class=\"form-control\" [owlDateTime]=\"dt1\" placeholder=\"Ex :00:00\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt1></owl-date-time>\n                    </div>\n                </div>\n              </div>  -->\n\n\n              <div class=\"row\">\n                <div class=\"col-md-3\">\n                    <label>Start Time (HH:MM)</label><br>\n                      <div  style=\"display:-webkit-inline-box\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"start_hrs_1\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                          <!-- <input formControlName=\"start_time_0\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time> -->\n                      </div>\n                      <div class=\"pt-2\">\n                        :\n                      </div>\n                    <div class=\"text-left\">\n                        <div class=\"form-group\">\n                            <input style=\"width:68px\" formControlName=\"start_min_1\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                        </div>\n                    </div>\n                  </div>\n                </div>\n\n                <div class=\"col-md-4\">\n                  <label>End Time (HH:MM)</label><br>\n                    <div  style=\"display:-webkit-inline-box\">\n                    <div class=\"form-group\">\n                        <input style=\"width:68px\" formControlName=\"end_hrs_1\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                    </div>\n                    <div class=\"pt-2\">\n                      :\n                    </div>\n                  <div class=\"text-left\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"end_min_1\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                      </div>\n                  </div>\n                </div>\n                </div>\n              </div>\n\n              <div class=\"form-group\">\n               <label  class=\"d-block\">Enter Number Of Forwarding Location:</label>\n               <input formControlName=\"noofforwardinglocation_2\" [(ngModel)]=\"noofforwardinglocation_2\" type=\"text\" class=\"form-control phone-number\" >\n           </div>\n\n           <div class=\"groupborder\" *ngFor='let in of selectednoofforwardinglocation_2();let i = index'>\n             <div class=\"form-group\">\n                 <label class=\"d-block\">Primary Forwarding Location - {{i+1}}</label>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day1\" name=\"PrimaryforwardType_{{i}}_day1\" class=\"with-gap\" [value]='0' (click)=\"setPrimaryforward(0,i,1)\" [checked]=\"true\">\n\n                   <label class=\"form-check-label\" for=\"inlineradio1\">Number</label>\n                 </div>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day1\" name=\"PrimaryforwardType_{{i}}_day1\" (click)=\"setPrimaryforward(1,i,1)\" class=\"with-gap\" [value]=\"1\">\n                   <label class=\"form-check-label\" for=\"inlineradio2\">IVR Menu</label>\n                 </div>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day1\" name=\"PrimaryforwardType_{{i}}_day1\" class=\"with-gap\" (click)=\"setPrimaryforward(2,i,1)\" [value]=\"2\">\n                   <label class=\"form-check-label\" for=\"inlineCheckbox3\">SIP (IP Address)</label>\n                 </div>\n               </div>\n               <div class=\"form-group\" *ngIf=\"!isPrimarySelected(1,i,1) && !isPrimarySelected(2,i,1)\">\n                     <label  class=\"d-block\">Number:</label>\n                     <input type=\"text\" formControlName=\"number_{{i}}_day1\" id=\"number_{{i}}_day1\" class=\"form-control phone-number\" placeholder=\"(000) 000-000\"  maxlength=\"16\" (keypress)=_keyPress($event)>\n               </div>\n               <div class=\"form-group\" *ngIf=\"isPrimarySelected(1,i,1)\">\n                     <label  class=\"d-block\">IVR Menu:</label>\n                       <select formControlName=\"ivrMenu_{{i}}_day1\" class=\"form-control\" [value] = \"\">\n                           <option value=\"\">Select IVR Menu</option>\n                           <option *ngFor=\"let data of ivrmenus;\" [value]=\"data.uuid\">\n                               {{data.name}}\n                             </option>\n                         </select>\n                 </div>\n                 <div class=\"form-group\" *ngIf=\"isPrimarySelected(2,i,1)\">\n                       <label  class=\"d-block\">SIP (IP Address):</label>\n                       <input  formControlName=\"sipAdd_{{i}}_day1\" type=\"text\" class=\"form-control phone-number\">\n                 </div>\n           </div>\n            </div>\n           </div>\n        </div>\n            </div>\n\n          <!-- Day 3 -->\n          <div class=\"groupborder\" *ngIf=\"noofforwarding>=3\">\n            <div >\n              <div class=\"form-group\">\n                  <label>Select Timeframe - 3</label>\n                  <select formControlName=\"day_2\" class=\"form-control\" [value]=\"0\" >\n                    <option value=\"0\">Select Day</option>\n                    <option *ngFor=\"let item of allweekdays\" value=\"{{item.id}}\">{{item.start_day}} to {{item.end_day}}</option>\n                    </select>\n\n                </div>\n              <div class=\"row\">\n              <div class=\"col-md-12\">\n              <!-- <div class=\"row\">\n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                        <label>Start Time</label>\n                        <input formControlName=\"start_time_2\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\" placeholder=\"Ex :00:00\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time>\n                    </div>\n                </div>\n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                        <label>End Time</label>\n                        <input formControlName=\"end_time_2\" [owlDateTimeTrigger]=\"dt1\" class=\"form-control\" [owlDateTime]=\"dt1\" placeholder=\"Ex :00:00\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt1></owl-date-time>\n                    </div>\n                </div>\n              </div>  -->\n\n\n              <div class=\"row\">\n                <div class=\"col-md-3\">\n                    <label>Start Time (HH:MM)</label><br>\n                      <div  style=\"display:-webkit-inline-box\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"start_hrs_2\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                          <!-- <input formControlName=\"start_time_0\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time> -->\n                      </div>\n                      <div class=\"pt-2\">\n                        :\n                      </div>\n                    <div class=\"text-left\">\n                        <div class=\"form-group\">\n                            <input style=\"width:68px\" formControlName=\"start_min_2\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                        </div>\n                    </div>\n                  </div>\n                </div>\n\n                <div class=\"col-md-4\">\n                  <label>End Time (HH:MM)</label><br>\n                    <div  style=\"display:-webkit-inline-box\">\n                    <div class=\"form-group\">\n                        <input style=\"width:68px\" formControlName=\"end_hrs_2\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                    </div>\n                    <div class=\"pt-2\">\n                      :\n                    </div>\n                  <div class=\"text-left\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"end_min_2\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                      </div>\n                  </div>\n                </div>\n                </div>\n              </div>\n\n              <div class=\"form-group\">\n               <label  class=\"d-block\">Enter Number Of Forwarding Location:</label>\n               <input formControlName=\"noofforwardinglocation_3\" [(ngModel)]=\"noofforwardinglocation_3\" type=\"text\" class=\"form-control phone-number\">\n           </div>\n\n           <div class=\"groupborder\" *ngFor='let in of selectednoofforwardinglocation_3();let i = index'>\n             <div class=\"form-group\">\n                 <label class=\"d-block\">Primary Forwarding Location - {{i+1}}</label>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day2\" name=\"PrimaryforwardType_{{i}}_day2\" class=\"with-gap\" [value]='0' (click)=\"setPrimaryforward(0,i,2)\" [checked]=\"true\">\n\n                   <label class=\"form-check-label\" for=\"inlineradio1\">Number</label>\n                 </div>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day2\" name=\"PrimaryforwardType_{{i}}_day2\" (click)=\"setPrimaryforward(1,i,2)\" class=\"with-gap\" [value]=\"1\">\n                   <label class=\"form-check-label\" for=\"inlineradio2\">IVR Menu</label>\n                 </div>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day2\" name=\"PrimaryforwardType_{{i}}_day2\" class=\"with-gap\" (click)=\"setPrimaryforward(2,i,2)\" [value]=\"2\">\n                   <label class=\"form-check-label\" for=\"inlineCheckbox3\">SIP (IP Address)</label>\n                 </div>\n               </div>\n               <div class=\"form-group\" *ngIf=\"!isPrimarySelected(1,i,2) && !isPrimarySelected(2,i,2)\">\n                     <label  class=\"d-block\">Number:</label>\n                     <input type=\"text\" formControlName=\"number_{{i}}_day2\" id=\"number_{{i}}_day2\" class=\"form-control phone-number\" placeholder=\"(000) 000-000\"  maxlength=\"16\" (keypress)=_keyPress($event)>\n               </div>\n               <div class=\"form-group\" *ngIf=\"isPrimarySelected(1,i,2)\">\n                     <label  class=\"d-block\">IVR Menu:</label>\n                      <select formControlName=\"ivrMenu_{{i}}_day2\" class=\"form-control\" [value] = \"\">\n                           <option value=\"\">Select IVR Menu</option>\n                           <option *ngFor=\"let data of ivrmenus;\" [value]=\"data.uuid\">\n                               {{data.name}}\n                             </option>\n                         </select>\n                 </div>\n                 <div class=\"form-group\" *ngIf=\"isPrimarySelected(2,i,2)\">\n                       <label  class=\"d-block\">SIP (IP Address):</label>\n                       <input  formControlName=\"sipAdd_{{i}}_day2\" type=\"text\" class=\"form-control phone-number\">\n                 </div>\n           </div>\n            </div>\n            </div>\n        </div>\n          </div>\n\n          <!-- Day 4 -->\n          <div class=\"groupborder\" *ngIf=\"noofforwarding>=4\">\n              <div >\n                <div class=\"form-group\">\n                    <label>Select Timeframe - 4</label>\n                    <select formControlName=\"day_3\" class=\"form-control\" [value]=\"0\" >\n                      <option value=\"0\">Select Day</option>\n                      <option *ngFor=\"let item of allweekdays\" value=\"{{item.id}}\">{{item.start_day}} to {{item.end_day}}</option>\n                      </select>\n\n                  </div>\n                <div class=\"row\">\n                <div class=\"col-md-12\">\n                <!-- <div class=\"row\">\n                  <div class=\"col-md-6\">\n                      <div class=\"form-group\">\n                          <label>Start Time</label>\n                          <input formControlName=\"start_time_3\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\" placeholder=\"Ex :00:00\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time>\n                      </div>\n                  </div>\n                  <div class=\"col-md-6\">\n                      <div class=\"form-group\">\n                          <label>End Time</label>\n                          <input formControlName=\"end_time_3\" [owlDateTimeTrigger]=\"dt1\" class=\"form-control\" [owlDateTime]=\"dt1\" placeholder=\"Ex :00:00\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt1></owl-date-time>\n                      </div>\n                  </div>\n                </div>   -->\n\n\n              <div class=\"row\">\n                <div class=\"col-md-3\">\n                    <label>Start Time (HH:MM)</label><br>\n                      <div  style=\"display:-webkit-inline-box\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"start_hrs_3\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                          <!-- <input formControlName=\"start_time_0\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time> -->\n                      </div>\n                      <div class=\"pt-2\">\n                        :\n                      </div>\n                    <div class=\"text-left\">\n                        <div class=\"form-group\">\n                            <input style=\"width:68px\" formControlName=\"start_min_3\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                        </div>\n                    </div>\n                  </div>\n                </div>\n\n                <div class=\"col-md-4\">\n                  <label>End Time (HH:MM)</label><br>\n                    <div  style=\"display:-webkit-inline-box\">\n                    <div class=\"form-group\">\n                        <input style=\"width:68px\" formControlName=\"end_hrs_3\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                    </div>\n                    <div class=\"pt-2\">\n                      :\n                    </div>\n                  <div class=\"text-left\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"end_min_3\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                      </div>\n                  </div>\n                </div>\n                </div>\n              </div>\n\n                <div class=\"form-group\">\n                 <label  class=\"d-block\">Enter Number Of Forwarding Location:</label>\n                 <input formControlName=\"noofforwardinglocation_4\" [(ngModel)]=\"noofforwardinglocation_4\" type=\"text\" class=\"form-control phone-number\">\n             </div>\n\n             <div class=\"groupborder\" *ngFor='let in of selectednoofforwardinglocation_4();let i = index'>\n               <div class=\"form-group\">\n                   <label class=\"d-block\">Primary Forwarding Location - {{i+1}}</label>\n                   <div class=\"form-check form-check-inline\">\n                       <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day3\" name=\"PrimaryforwardType_{{i}}_day3\" class=\"with-gap\" [value]='0' (click)=\"setPrimaryforward(0,i,3)\" [checked]=\"true\">\n\n                     <label class=\"form-check-label\" for=\"inlineradio1\">Number</label>\n                   </div>\n                   <div class=\"form-check form-check-inline\">\n                       <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day3\" name=\"PrimaryforwardType_{{i}}_day3\" (click)=\"setPrimaryforward(1,i,3)\" class=\"with-gap\" [value]=\"1\">\n                     <label class=\"form-check-label\" for=\"inlineradio2\">IVR Menu</label>\n                   </div>\n                   <div class=\"form-check form-check-inline\">\n                       <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day3\" name=\"PrimaryforwardType_{{i}}_day3\" class=\"with-gap\" (click)=\"setPrimaryforward(2,i,3)\" [value]=\"2\">\n                     <label class=\"form-check-label\" for=\"inlineCheckbox3\">SIP (IP Address)</label>\n                   </div>\n                 </div>\n                 <div class=\"form-group\" *ngIf=\"!isPrimarySelected(1,i,3) && !isPrimarySelected(2,i,3)\">\n                       <label  class=\"d-block\">Number:</label>\n                       <input type=\"text\" formControlName=\"number_{{i}}_day3\" id=\"number_{{i}}_day3\" class=\"form-control phone-number\" placeholder=\"(000) 000-000\"  maxlength=\"16\" (keypress)=_keyPress($event)>\n                 </div>\n                 <div class=\"form-group\" *ngIf=\"isPrimarySelected(1,i,3)\">\n                       <label  class=\"d-block\">IVR Menu:</label>\n                        <select formControlName=\"ivrMenu_{{i}}_day3\" class=\"form-control\" [value] = \"\">\n                             <option value=\"\">Select IVR Menu</option>\n                             <option *ngFor=\"let data of ivrmenus;\" [value]=\"data.uuid\">\n                                 {{data.name}}\n                               </option>\n                           </select>\n                   </div>\n                   <div class=\"form-group\" *ngIf=\"isPrimarySelected(2,i,3)\">\n                         <label  class=\"d-block\">SIP (IP Address):</label>\n                         <input  formControlName=\"sipAdd_{{i}}_day3\" type=\"text\" class=\"form-control phone-number\">\n                   </div>\n             </div>\n              </div>\n              </div>\n          </div>\n          </div>\n\n          <!-- Day 5 -->\n          <div class=\"groupborder\" *ngIf=\"noofforwarding>=5\">\n              <div >\n                <div class=\"form-group\">\n                    <label>Select Timeframe - 5</label>\n                    <select formControlName=\"day_4\" class=\"form-control\" [value]=\"0\" >\n                      <option value=\"0\">Select Day</option>\n                      <option *ngFor=\"let item of allweekdays\" value=\"{{item.id}}\">{{item.start_day}} to {{item.end_day}}</option>\n                      </select>\n\n                  </div>\n                <div class=\"row\">\n                <div class=\"col-md-12\">\n                <!-- <div class=\"row\">\n                  <div class=\"col-md-6\">\n                      <div class=\"form-group\">\n                          <label>Start Time</label>\n                          <input formControlName=\"start_time_4\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\" placeholder=\"Ex :00:00\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time>\n                      </div>\n                  </div>\n                  <div class=\"col-md-6\">\n                      <div class=\"form-group\">\n                          <label>End Time</label>\n                          <input formControlName=\"end_time_4\" [owlDateTimeTrigger]=\"dt1\" class=\"form-control\" [owlDateTime]=\"dt1\" placeholder=\"Ex :00:00\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt1></owl-date-time>\n                      </div>\n                  </div>\n                </div>                  -->\n\n\n              <div class=\"row\">\n                <div class=\"col-md-3\">\n                    <label>Start Time (HH:MM)</label><br>\n                      <div  style=\"display:-webkit-inline-box\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"start_hrs_4\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                          <!-- <input formControlName=\"start_time_0\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time> -->\n                      </div>\n                      <div class=\"pt-2\">\n                        :\n                      </div>\n                    <div class=\"text-left\">\n                        <div class=\"form-group\">\n                            <input style=\"width:68px\" formControlName=\"start_min_4\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                        </div>\n                    </div>\n                  </div>\n                </div>\n\n                <div class=\"col-md-4\">\n                  <label>End Time (HH:MM)</label><br>\n                    <div  style=\"display:-webkit-inline-box\">\n                    <div class=\"form-group\">\n                        <input style=\"width:68px\" formControlName=\"end_hrs_4\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                    </div>\n                    <div class=\"pt-2\">\n                      :\n                    </div>\n                  <div class=\"text-left\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"end_min_4\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                      </div>\n                  </div>\n                </div>\n                </div>\n              </div>\n                <div class=\"form-group\">\n                 <label  class=\"d-block\">Enter Number Of Forwarding Location:</label>\n                 <input formControlName=\"noofforwardinglocation_5\" [(ngModel)]=\"noofforwardinglocation_5\" type=\"text\" class=\"form-control phone-number\">\n             </div>\n\n             <div class=\"groupborder\" *ngFor='let in of selectednoofforwardinglocation_5();let i = index'>\n               <div class=\"form-group\">\n                   <label class=\"d-block\">Primary Forwarding Location - {{i+1}}</label>\n                   <div class=\"form-check form-check-inline\">\n                       <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day4\" name=\"PrimaryforwardType_{{i}}_day4\" class=\"with-gap\" [value]='0' (click)=\"setPrimaryforward(0,i,4)\" [checked]=\"true\">\n\n                     <label class=\"form-check-label\" for=\"inlineradio1\">Number</label>\n                   </div>\n                   <div class=\"form-check form-check-inline\">\n                       <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day4\" name=\"PrimaryforwardType_{{i}}_day4\" (click)=\"setPrimaryforward(1,i,4)\" class=\"with-gap\" [value]=\"1\">\n                     <label class=\"form-check-label\" for=\"inlineradio2\">IVR Menu</label>\n                   </div>\n                   <div class=\"form-check form-check-inline\">\n                       <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day4\" name=\"PrimaryforwardType_{{i}}_day4\" class=\"with-gap\" (click)=\"setPrimaryforward(2,i,4)\" [value]=\"2\">\n                     <label class=\"form-check-label\" for=\"inlineCheckbox3\">SIP (IP Address)</label>\n                   </div>\n                 </div>\n                 <div class=\"form-group\" *ngIf=\"!isPrimarySelected(1,i,4) && !isPrimarySelected(2,i,4)\">\n                       <label  class=\"d-block\">Number:</label>\n                       <input type=\"text\" formControlName=\"number_{{i}}_day4\" id=\"number_{{i}}_day4\" class=\"form-control phone-number\" placeholder=\"(000) 000-000\"  maxlength=\"16\" (keypress)=_keyPress($event)>\n                 </div>\n                 <div class=\"form-group\" *ngIf=\"isPrimarySelected(1,i,4)\">\n                       <label  class=\"d-block\">IVR Menu:</label>\n                        <select formControlName=\"ivrMenu_{{i}}_day4\" class=\"form-control\" [value] = \"\">\n                             <option value=\"\">Select IVR Menu</option>\n                             <option *ngFor=\"let data of ivrmenus;\" [value]=\"data.uuid\">\n                                 {{data.name}}\n                               </option>\n                           </select>\n                   </div>\n                   <div class=\"form-group\" *ngIf=\"isPrimarySelected(2,i,4)\">\n                         <label  class=\"d-block\">SIP (IP Address):</label>\n                         <input  formControlName=\"sipAdd_{{i}}_day4\" type=\"text\" class=\"form-control phone-number\">\n                   </div>\n             </div>\n              </div>\n              </div>\n          </div>\n          </div>\n\n          <!-- Day 6 -->\n          <div class=\"groupborder\" *ngIf=\"noofforwarding>=6\">\n            <div >\n              <div class=\"form-group\">\n                  <label>Select Timeframe - 6</label>\n                  <select formControlName=\"day_5\" class=\"form-control\" [value]=\"0\" >\n                    <option value=\"0\">Select Day</option>\n                    <option *ngFor=\"let item of allweekdays\" value=\"{{item.id}}\">{{item.start_day}} to {{item.end_day}}</option>\n                    </select>\n\n                </div>\n              <div class=\"row\">\n              <div class=\"col-md-12\">\n              <!-- <div class=\"row\">\n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                        <label>Start Time</label>\n                        <input formControlName=\"start_time_5\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\" placeholder=\"Ex :00:00\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time>\n                    </div>\n                </div>\n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                        <label>End Time</label>\n                        <input formControlName=\"end_time_5\" [owlDateTimeTrigger]=\"dt1\" class=\"form-control\" [owlDateTime]=\"dt1\" placeholder=\"Ex :00:00\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt1></owl-date-time>\n                    </div>\n                </div>\n              </div>  -->\n\n\n              <div class=\"row\">\n                <div class=\"col-md-3\">\n                    <label>Start Time (HH:MM)</label><br>\n                      <div  style=\"display:-webkit-inline-box\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"start_hrs_5\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                          <!-- <input formControlName=\"start_time_0\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time> -->\n                      </div>\n                      <div class=\"pt-2\">\n                        :\n                      </div>\n                    <div class=\"text-left\">\n                        <div class=\"form-group\">\n                            <input style=\"width:68px\" formControlName=\"start_min_5\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                        </div>\n                    </div>\n                  </div>\n                </div>\n\n                <div class=\"col-md-4\">\n                  <label>End Time (HH:MM)</label><br>\n                    <div  style=\"display:-webkit-inline-box\">\n                    <div class=\"form-group\">\n                        <input style=\"width:68px\" formControlName=\"end_hrs_5\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                    </div>\n                    <div class=\"pt-2\">\n                      :\n                    </div>\n                  <div class=\"text-left\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"end_min_5\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                      </div>\n                  </div>\n                </div>\n                </div>\n              </div>\n              <div class=\"form-group\">\n               <label  class=\"d-block\">Enter Number Of Forwarding Location:</label>\n               <input formControlName=\"noofforwardinglocation_6\" [(ngModel)]=\"noofforwardinglocation_6\" type=\"text\" class=\"form-control phone-number\">\n           </div>\n\n           <div class=\"groupborder\" *ngFor='let in of selectednoofforwardinglocation_6();let i = index'>\n             <div class=\"form-group\">\n                 <label class=\"d-block\">Primary Forwarding Location - {{i+1}}</label>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day5\" name=\"PrimaryforwardType_{{i}}_day5\" class=\"with-gap\" [value]='0' (click)=\"setPrimaryforward(0,i,5)\" [checked]=\"true\">\n\n                   <label class=\"form-check-label\" for=\"inlineradio1\">Number</label>\n                 </div>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day5\" name=\"PrimaryforwardType_{{i}}_day5\" (click)=\"setPrimaryforward(1,i,5)\" class=\"with-gap\" [value]=\"1\">\n                   <label class=\"form-check-label\" for=\"inlineradio2\">IVR Menu</label>\n                 </div>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day5\" name=\"PrimaryforwardType_{{i}}_day5\" class=\"with-gap\" (click)=\"setPrimaryforward(2,i,5)\" [value]=\"2\">\n                   <label class=\"form-check-label\" for=\"inlineCheckbox3\">SIP (IP Address)</label>\n                 </div>\n               </div>\n               <div class=\"form-group\" *ngIf=\"!isPrimarySelected(1,i,5) && !isPrimarySelected(2,i,5)\">\n                     <label  class=\"d-block\">Number:</label>\n                     <input type=\"text\" formControlName=\"number_{{i}}_day5\" id=\"number_{{i}}_day5\" class=\"form-control phone-number\" placeholder=\"(000) 000-000\"  maxlength=\"16\" (keypress)=_keyPress($event)>\n               </div>\n               <div class=\"form-group\" *ngIf=\"isPrimarySelected(1,i,5)\">\n                     <label  class=\"d-block\">IVR Menu:</label>\n                      <select formControlName=\"ivrMenu_{{i}}_day5\" class=\"form-control\" [value] = \"\">\n                           <option value=\"\">Select IVR Menu</option>\n                           <option *ngFor=\"let data of ivrmenus;\" [value]=\"data.uuid\">\n                               {{data.name}}\n                             </option>\n                         </select>\n                 </div>\n                 <div class=\"form-group\" *ngIf=\"isPrimarySelected(2,i,5)\">\n                       <label  class=\"d-block\">SIP (IP Address):</label>\n                       <input  formControlName=\"sipAdd_{{i}}_day5\" type=\"text\" class=\"form-control phone-number\">\n                 </div>\n           </div>\n            </div>\n            </div>\n        </div>\n        </div>\n\n        <!-- Day 7 -->\n        <div class=\"groupborder\" *ngIf=\"noofforwarding>=7\">\n          <div >\n            <div class=\"form-group\">\n                <label>Select Timeframe - 7</label>\n                <select formControlName=\"day_6\" class=\"form-control\" [value]=\"0\" >\n                  <option value=\"0\">Select Day</option>\n                  <option *ngFor=\"let item of allweekdays\" value=\"{{item.id}}\">{{item.start_day}} to {{item.end_day}}</option>\n                  </select>\n\n              </div>\n            <div class=\"row\">\n            <div class=\"col-md-12\">\n            <!-- <div class=\"row\">\n              <div class=\"col-md-6\">\n                  <div class=\"form-group\">\n                      <label>Start Time</label>\n                      <input formControlName=\"start_time_6\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\" placeholder=\"Ex :00:00\">\n                      <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time>\n                  </div>\n              </div>\n              <div class=\"col-md-6\">\n                  <div class=\"form-group\">\n                      <label>End Time</label>\n                      <input formControlName=\"end_time_6\" [owlDateTimeTrigger]=\"dt1\" class=\"form-control\" [owlDateTime]=\"dt1\" placeholder=\"Ex :00:00\">\n                      <owl-date-time [pickerType]=\"'timer'\" #dt1></owl-date-time>\n                  </div>\n              </div>\n            </div>               -->\n\n\n            <div class=\"row\">\n              <div class=\"col-md-3\">\n                  <label>Start Time (HH:MM)</label><br>\n                    <div  style=\"display:-webkit-inline-box\">\n                    <div class=\"form-group\">\n                        <input style=\"width:68px\" formControlName=\"start_hrs_6\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                        <!-- <input formControlName=\"start_time_0\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time> -->\n                    </div>\n                    <div class=\"pt-2\">\n                      :\n                    </div>\n                  <div class=\"text-left\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"start_min_6\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                      </div>\n                  </div>\n                </div>\n              </div>\n\n              <div class=\"col-md-4\">\n                <label>End Time (HH:MM)</label><br>\n                  <div  style=\"display:-webkit-inline-box\">\n                  <div class=\"form-group\">\n                      <input style=\"width:68px\" formControlName=\"end_hrs_6\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                  </div>\n                  <div class=\"pt-2\">\n                    :\n                  </div>\n                <div class=\"text-left\">\n                    <div class=\"form-group\">\n                        <input style=\"width:68px\" formControlName=\"end_min_6\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                    </div>\n                </div>\n              </div>\n              </div>\n            </div>\n            <div class=\"form-group\">\n             <label  class=\"d-block\">Enter Number Of Forwarding Location:</label>\n             <input formControlName=\"noofforwardinglocation_7\" [(ngModel)]=\"noofforwardinglocation_7\" type=\"text\" class=\"form-control phone-number\">\n         </div>\n\n         <div class=\"groupborder\" *ngFor='let in of selectednoofforwardinglocation_7();let i = index'>\n           <div class=\"form-group\">\n               <label class=\"d-block\">Primary Forwarding Location - {{i+1}}</label>\n               <div class=\"form-check form-check-inline\">\n                   <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day6\" name=\"PrimaryforwardType_{{i}}_day6\" class=\"with-gap\" [value]='0' (click)=\"setPrimaryforward(0,i,6)\" [checked]=\"true\">\n\n                 <label class=\"form-check-label\" for=\"inlineradio1\">Number</label>\n               </div>\n               <div class=\"form-check form-check-inline\">\n                   <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day6\" name=\"PrimaryforwardType_{{i}}_day6\" (click)=\"setPrimaryforward(1,i,6)\" class=\"with-gap\" [value]=\"1\">\n                 <label class=\"form-check-label\" for=\"inlineradio2\">IVR Menu</label>\n               </div>\n               <div class=\"form-check form-check-inline\">\n                   <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day6\" name=\"PrimaryforwardType_{{i}}_day6\" class=\"with-gap\" (click)=\"setPrimaryforward(2,i,6)\" [value]=\"2\">\n                 <label class=\"form-check-label\" for=\"inlineCheckbox3\">SIP (IP Address)</label>\n               </div>\n             </div>\n             <div class=\"form-group\" *ngIf=\"!isPrimarySelected(1,i,6) && !isPrimarySelected(2,i,6)\">\n                   <label  class=\"d-block\">Number:</label>\n                   <input type=\"text\" formControlName=\"number_{{i}}_day6\" id=\"number_{{i}}_day6\" class=\"form-control phone-number\" placeholder=\"(000) 000-000\"  maxlength=\"16\" (keypress)=_keyPress($event)>\n             </div>\n             <div class=\"form-group\" *ngIf=\"isPrimarySelected(1,i,6)\">\n                   <label  class=\"d-block\">IVR Menu:</label>\n                    <select formControlName=\"ivrMenu_{{i}}_day6\" class=\"form-control\" [value] = \"\">\n                         <option value=\"\">Select IVR Menu</option>\n                         <option *ngFor=\"let data of ivrmenus;\" [value]=\"data.uuid\">\n                             {{data.name}}\n                           </option>\n                       </select>\n               </div>\n               <div class=\"form-group\" *ngIf=\"isPrimarySelected(2,i,6)\">\n                     <label  class=\"d-block\">SIP (IP Address):</label>\n                     <input  formControlName=\"sipAdd_{{i}}_day6\" type=\"text\" class=\"form-control phone-number\">\n               </div>\n         </div>\n          </div>\n          </div>\n      </div>\n      </div>\n\n        <div class=\"modal-footer\" style=\"padding: 0;\">\n           <button [disabled]=\"isName == 'fail'\" type=\"submit\" (click)=\"closeModal()\" class=\"btn btn-primary m-t-15 waves-effect\">Create New Target</button>\n           <button (click)=\"onFSLReset()\" type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\">Reset</button>\n        </div>\n      </form>\n    </div>\n  </div>\n</div>\n</div>\n\n<div class=\"modal  fade\" id=\"editFSLRules\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\" aria-hidden=\"true\" *ngIf=\"forwarding?.length != 0\">\n<div class=\"modal-dialog modal-lg\" role=\"document\">\n  <div class=\"modal-content\">\n    <div class=\"modal-header\">\n      <h5 class=\"modal-title\" id=\"formModal\">Edit Target</h5>\n      <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n        <span aria-hidden=\"true\">&times;</span>\n      </button>\n    </div>\n    <div class=\"modal-body\">\n      <form class=\"\"  [formGroup]=\"editFSLRules\" (ngSubmit)=\"onFSLEditSubmit()\">\n\n        <div class=\"form-group\">\n            <label>Name</label>\n            <input formControlName=\"rulename\" type=\"text\" class=\"form-control\" [value] =\"forwarding\" readonly>\n        </div>\n\n          <div class=\"form-group\">\n            <label  class=\"d-block\">Number of Time Frames:</label>\n            <input formControlName=\"numberoftimeframe\"  oninput=\"javascript: if (this.value.length > this.maxLength) this.value = this.value.slice(0, this.maxLength);\"\n            type = \"number\" maxlength = \"1\" [(ngModel)]=\"noofforwarding\" type=\"number\" class=\"form-control phone-number\" [ngClass]=\"{ 'is-invalid': FSLRulesEditSubmitted && editrules.numberoftimeframe.errors }\" [value] =\"forwardingtimeframe\">\n            <div *ngIf=\"FSLRulesEditSubmitted && editrules.numberoftimeframe.errors\" class=\"invalid-feedback\">\n              <div *ngIf=\"editrules.numberoftimeframe.errors.required\">Number of Time Frames is required</div>\n          </div>\n          </div>\n\n          <br>\n          <!-- Day 1 -->\n          <div class=\"groupborder\" *ngIf=\"noofforwarding>=1\">\n            <div >\n              <div class=\"form-group\">\n                  <label>Select Timeframe - 1</label>\n                  <select formControlName=\"day_0\" name=\"day-0\" id=\"day-0\" class=\"form-control\" >\n                    <option value=\"0\">Select Day</option>\n                    <option *ngFor=\"let item of allweekdays\" value=\"{{item.id}}\">{{item.start_day}} to {{item.end_day}}</option>\n                  </select>\n                </div>\n              <div class=\"row\">\n              <div class=\"col-md-12\">\n\n              <div class=\"row\">\n                <div class=\"col-md-3\">\n                    <label>Start Time (HH:MM)</label><br>\n                      <div  style=\"display:-webkit-inline-box\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"start_hrs_0\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                          <!-- <input formControlName=\"start_time_0\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time> -->\n                      </div>\n                      <div class=\"pt-2\">\n                        :\n                      </div>\n                    <div class=\"text-left\">\n                        <div class=\"form-group\">\n                            <input style=\"width:68px\" formControlName=\"start_min_0\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                        </div>\n                    </div>\n                  </div>\n                </div>\n\n                <div class=\"col-md-4\">\n                  <label>End Time (HH:MM)</label><br>\n                    <div  style=\"display:-webkit-inline-box\">\n                    <div class=\"form-group\">\n                        <input style=\"width:68px\" formControlName=\"end_hrs_0\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                    </div>\n                    <div class=\"pt-2\">\n                      :\n                    </div>\n                  <div class=\"text-left\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"end_min_0\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                      </div>\n                  </div>\n                </div>\n                </div>\n              </div>\n\n              <div>\n\n               <div class=\"form-group\">\n                   <label  class=\"d-block\">Enter Number Of Forwarding Location:</label>\n                   <input formControlName=\"noofforwardinglocation_1\" type=\"text\" class=\"form-control phone-number\" [(ngModel)]=\"noofforwardinglocation_1\">\n               </div>\n\n               <div class=\"groupborder\" *ngFor='let in of selectednoofforwardinglocation();let i = index'>\n                 <div class=\"form-group\">\n                     <label class=\"d-block\">Primary Forwarding Location - {{i+1}}</label>\n                     <div class=\"form-check form-check-inline\">\n                         <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day0\" name=\"PrimaryforwardType_{{i}}_day0\" class=\"with-gap\" [value]='0' (click)=\"setPrimaryforward(0,i,0)\">\n                        <label class=\"form-check-label\" for=\"inlineradio1\">Number</label>\n                     </div>\n                     <div class=\"form-check form-check-inline\">\n                         <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day0\" name=\"PrimaryforwardType_{{i}}_day0\" (click)=\"setPrimaryforward(1,i,0)\" class=\"with-gap\" [value]=\"1\">\n                       <label class=\"form-check-label\" for=\"\">IVR Menu</label>\n                     </div>\n                     <div class=\"form-check form-check-inline\">\n                         <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day0\" name=\"PrimaryforwardType_{{i}}_day0\" class=\"with-gap\" (click)=\"setPrimaryforward(2,i,0)\" [value]=\"2\">\n                       <label class=\"form-check-label\" for=\"\">SIP (IP Address)</label>\n                     </div>\n                   </div>\n                   <div class=\"form-group\" *ngIf=\"!isPrimarySelected(1,i,0) && !isPrimarySelected(2,i,0)\">\n                         <label  class=\"d-block\">Number:</label>\n                         <input type=\"text\" formControlName=\"number_{{i}}_day0\" id=\"editnumber_{{i}}_day0\" class=\"form-control phone-number numbers\" placeholder=\"(000) 000-000\"  maxlength=\"16\" (keypress)=_keyPress($event)>\n                   </div>\n                   <div class=\"form-group\" *ngIf=\"isPrimarySelected(1,i,0)\">\n                         <label  class=\"d-block\">IVR Menu:</label>\n                           <select formControlName=\"ivrMenu_{{i}}_day0\" class=\"form-control\" [value] = \"\">\n                               <option value=\"\">Select IVR Menu</option>\n                               <option *ngFor=\"let data of ivrmenus;\" [value]=\"data.uuid\">\n                                   {{data.name}}\n                                 </option>\n                          </select>\n                     </div>\n                     <div class=\"form-group\" *ngIf=\"isPrimarySelected(2,i,0)\">\n                           <label  class=\"d-block\">SIP (IP Address):</label>\n                           <input  formControlName=\"sipAdd_{{i}}_day0\" type=\"text\" class=\"form-control phone-number\">\n                     </div>\n               </div>\n               </div>\n\n           </div>\n           </div>\n        </div>\n           </div>\n\n          <!-- Day 2 -->\n           <div class=\"groupborder\" *ngIf=\"noofforwarding>=2\">\n            <div >\n              <div class=\"form-group\">\n                  <label>Select Timeframe - 2</label>\n                  <select formControlName=\"day_1\" class=\"form-control\">\n                    <option value=\"0\">Select Day</option>\n                    <option *ngFor=\"let item of allweekdays\" value=\"{{item.id}}\">{{item.start_day}} to {{item.end_day}}</option>\n                    </select>\n                </div>\n              <div class=\"row\">\n              <div class=\"col-md-12\">\n              <!-- <div class=\"row\">\n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                        <label>Start Time</label>\n                        <input formControlName=\"start_time_1\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\" placeholder=\"Ex :00:00\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time>\n                    </div>\n                </div>\n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                        <label>End Time</label>\n                        <input formControlName=\"end_time_1\" [owlDateTimeTrigger]=\"dt1\" class=\"form-control\" [owlDateTime]=\"dt1\" placeholder=\"Ex :00:00\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt1></owl-date-time>\n                    </div>\n                </div>\n              </div>  -->\n\n              <div class=\"row\">\n                <div class=\"col-md-3\">\n                    <label>Start Time (HH:MM)</label><br>\n                      <div  style=\"display:-webkit-inline-box\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"start_hrs_1\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                          <!-- <input formControlName=\"start_time_0\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time> -->\n                      </div>\n                      <div class=\"pt-2\">\n                        :\n                      </div>\n                    <div class=\"text-left\">\n                        <div class=\"form-group\">\n                            <input style=\"width:68px\" formControlName=\"start_min_1\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                        </div>\n                    </div>\n                  </div>\n                </div>\n\n                <div class=\"col-md-4\">\n                  <label>End Time (HH:MM)</label><br>\n                    <div  style=\"display:-webkit-inline-box\">\n                    <div class=\"form-group\">\n                        <input style=\"width:68px\" formControlName=\"end_hrs_1\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                    </div>\n                    <div class=\"pt-2\">\n                      :\n                    </div>\n                  <div class=\"text-left\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"end_min_1\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                      </div>\n                  </div>\n                </div>\n                </div>\n              </div>\n\n              <div class=\"form-group\">\n               <label  class=\"d-block\">Enter Number Of Forwarding Location:</label>\n               <input formControlName=\"noofforwardinglocation_2\" type=\"text\" class=\"form-control phone-number\" [(ngModel)]=\"noofforwardinglocation_2\">\n           </div>\n\n           <div class=\"groupborder\" *ngFor='let in of selectednoofforwardinglocation_2();let i = index'>\n             <div class=\"form-group\">\n                 <label class=\"d-block\">Primary Forwarding Location - {{i+1}}</label>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day1\" name=\"PrimaryforwardType_{{i}}_day1\" id=\"PrimaryforwardType_{{i}}_day1\" class=\"with-gap\" [value]='0' (click)=\"setPrimaryforward(0,i,1)\">\n\n                   <label class=\"form-check-label\" for=\"inlineradio1\">Number</label>\n                 </div>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day1\" name=\"PrimaryforwardType_{{i}}_day1\" (click)=\"setPrimaryforward(1,i,1)\" class=\"with-gap\" [value]=\"1\">\n                   <label class=\"form-check-label\" for=\"inlineradio2\">IVR Menu</label>\n                 </div>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day1\" name=\"PrimaryforwardType_{{i}}_day1\" class=\"with-gap\" (click)=\"setPrimaryforward(2,i,1)\" [value]=\"2\">\n                   <label class=\"form-check-label\" for=\"inlineCheckbox3\">SIP (IP Address)</label>\n                 </div>\n               </div>\n               <div class=\"form-group\" *ngIf=\"!isPrimarySelected(1,i,1) && !isPrimarySelected(2,i,1)\">\n                     <label  class=\"d-block\">Number:</label>\n                     <input type=\"text\" formControlName=\"number_{{i}}_day1\" id=\"editnumber_{{i}}_day1\" class=\"form-control phone-number\" placeholder=\"(000) 000-000\"  maxlength=\"16\" (keypress)=_keyPress($event)>\n               </div>\n               <div class=\"form-group\" *ngIf=\"isPrimarySelected(1,i,1)\">\n                     <label  class=\"d-block\">IVR Menu:</label>\n                       <select formControlName=\"ivrMenu_{{i}}_day1\" class=\"form-control\" [value] = \"\">\n                           <option value=\"\">Select IVR Menu</option>\n                           <option *ngFor=\"let data of ivrmenus;\" [value]=\"data.uuid\">\n                               {{data.name}}\n                             </option>\n                         </select>\n                 </div>\n                 <div class=\"form-group\" *ngIf=\"isPrimarySelected(2,i,1)\">\n                       <label  class=\"d-block\">SIP (IP Address):</label>\n                       <input  formControlName=\"sipAdd_{{i}}_day1\" type=\"text\" class=\"form-control phone-number\">\n                 </div>\n           </div>\n            </div>\n           </div>\n        </div>\n            </div>\n\n          <!-- Day 3 -->\n          <div class=\"groupborder\" *ngIf=\"noofforwarding>=3\">\n            <div >\n              <div class=\"form-group\">\n                  <label>Select Timeframe - 3</label>\n                  <select formControlName=\"day_2\" class=\"form-control\" >\n                    <option value=\"0\">Select Day</option>\n                    <option *ngFor=\"let item of allweekdays\" value=\"{{item.id}}\">{{item.start_day}} to {{item.end_day}}</option>\n                    </select>\n\n                </div>\n              <div class=\"row\">\n              <div class=\"col-md-12\">\n              <!-- <div class=\"row\">\n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                        <label>Start Time</label>\n                        <input formControlName=\"start_time_2\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\" placeholder=\"Ex :00:00\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time>\n                    </div>\n                </div>\n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                        <label>End Time</label>\n                        <input formControlName=\"end_time_2\" [owlDateTimeTrigger]=\"dt1\" class=\"form-control\" [owlDateTime]=\"dt1\" placeholder=\"Ex :00:00\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt1></owl-date-time>\n                    </div>\n                </div>\n              </div>   -->\n\n              <div class=\"row\">\n                <div class=\"col-md-3\">\n                    <label>Start Time (HH:MM)</label><br>\n                      <div  style=\"display:-webkit-inline-box\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"start_hrs_2\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                          <!-- <input formControlName=\"start_time_0\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time> -->\n                      </div>\n                      <div class=\"pt-2\">\n                        :\n                      </div>\n                    <div class=\"text-left\">\n                        <div class=\"form-group\">\n                            <input style=\"width:68px\" formControlName=\"start_min_2\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                        </div>\n                    </div>\n                  </div>\n                </div>\n\n                <div class=\"col-md-4\">\n                  <label>End Time (HH:MM)</label><br>\n                    <div  style=\"display:-webkit-inline-box\">\n                    <div class=\"form-group\">\n                        <input style=\"width:68px\" formControlName=\"end_hrs_2\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                    </div>\n                    <div class=\"pt-2\">\n                      :\n                    </div>\n                  <div class=\"text-left\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"end_min_2\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                      </div>\n                  </div>\n                </div>\n                </div>\n              </div>\n              <div class=\"form-group\">\n               <label  class=\"d-block\">Enter Number Of Forwarding Location:</label>\n               <input formControlName=\"noofforwardinglocation_3\" type=\"text\" class=\"form-control phone-number\" [(ngModel)]=\"noofforwardinglocation_3\">\n           </div>\n\n           <div class=\"groupborder\" *ngFor='let in of selectednoofforwardinglocation_3();let i = index'>\n             <div class=\"form-group\">\n                 <label class=\"d-block\">Primary Forwarding Location - {{i+1}}</label>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day2\" name=\"PrimaryforwardType_{{i}}_day2\" class=\"with-gap\" [value]='0' (click)=\"setPrimaryforward(0,i,2)\">\n\n                   <label class=\"form-check-label\" for=\"inlineradio1\">Number</label>\n                 </div>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day2\" name=\"PrimaryforwardType_{{i}}_day2\"  (click)=\"setPrimaryforward(1,i,2)\" class=\"with-gap\" [value]=\"1\">\n                   <label class=\"form-check-label\" for=\"inlineradio2\">IVR Menu</label>\n                 </div>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day2\" name=\"PrimaryforwardType_{{i}}_day2\" class=\"with-gap\" (click)=\"setPrimaryforward(2,i,2)\" [value]=\"2\">\n                   <label class=\"form-check-label\" for=\"inlineCheckbox3\">SIP (IP Address)</label>\n                 </div>\n               </div>\n               <div class=\"form-group\" *ngIf=\"!isPrimarySelected(1,i,2) && !isPrimarySelected(2,i,2)\">\n                     <label  class=\"d-block\">Number:</label>\n                     <input type=\"text\" formControlName=\"number_{{i}}_day2\" id=\"editnumber_{{i}}_day2\" class=\"form-control phone-number\" placeholder=\"(000) 000-000\"  maxlength=\"16\" (keypress)=_keyPress($event)>\n               </div>\n               <div class=\"form-group\" *ngIf=\"isPrimarySelected(1,i,2)\">\n                     <label  class=\"d-block\">IVR Menu:</label>\n                       <select formControlName=\"ivrMenu_{{i}}_day2\" class=\"form-control\" [value] = \"\">\n                           <option\n                            value=\"\">Select IVR Menu</option\n                            >\n                           <option *ngFor=\"let data of ivrmenus;\" [value]=\"data.uuid\">\n                               {{data.name}}\n                             </option>\n                         </select>\n                 </div>\n                 <div class=\"form-group\" *ngIf=\"isPrimarySelected(2,i,2)\">\n                       <label  class=\"d-block\">SIP (IP Address):</label>\n                       <input  formControlName=\"sipAdd_{{i}}_day2\" type=\"text\" class=\"form-control phone-number\">\n                 </div>\n           </div>\n            </div>\n            </div>\n        </div>\n          </div>\n\n          <!-- Day 4 -->\n          <div class=\"groupborder\" *ngIf=\"noofforwarding>=4\">\n              <div >\n                <div class=\"form-group\">\n                    <label>Select Timeframe - 4</label>\n                    <select formControlName=\"day_3\" class=\"form-control\">\n                      <option value=\"0\">Select Day</option>\n                      <option *ngFor=\"let item of allweekdays\" value=\"{{item.id}}\">{{item.start_day}} to {{item.end_day}}</option>\n                      </select>\n\n                  </div>\n                <div class=\"row\">\n                <div class=\"col-md-12\">\n                <!-- <div class=\"row\">\n                  <div class=\"col-md-6\">\n                      <div class=\"form-group\">\n                          <label>Start Time</label>\n                          <input formControlName=\"start_time_3\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\" placeholder=\"Ex :00:00\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time>\n                      </div>\n                  </div>\n                  <div class=\"col-md-6\">\n                      <div class=\"form-group\">\n                          <label>End Time</label>\n                          <input formControlName=\"end_time_3\" [owlDateTimeTrigger]=\"dt1\" class=\"form-control\" [owlDateTime]=\"dt1\" placeholder=\"Ex :00:00\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt1></owl-date-time>\n                      </div>\n                  </div>\n                </div>   -->\n                <div class=\"row\">\n                  <div class=\"col-md-3\">\n                      <label>Start Time (HH:MM)</label><br>\n                        <div  style=\"display:-webkit-inline-box\">\n                        <div class=\"form-group\">\n                            <input style=\"width:68px\" formControlName=\"start_hrs_3\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                            <!-- <input formControlName=\"start_time_0\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\">\n                            <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time> -->\n                        </div>\n                        <div class=\"pt-2\">\n                          :\n                        </div>\n                      <div class=\"text-left\">\n                          <div class=\"form-group\">\n                              <input style=\"width:68px\" formControlName=\"start_min_3\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                          </div>\n                      </div>\n                    </div>\n                  </div>\n\n                  <div class=\"col-md-4\">\n                    <label>End Time (HH:MM)</label><br>\n                      <div  style=\"display:-webkit-inline-box\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"end_hrs_3\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                      </div>\n                      <div class=\"pt-2\">\n                        :\n                      </div>\n                    <div class=\"text-left\">\n                        <div class=\"form-group\">\n                            <input style=\"width:68px\" formControlName=\"end_min_3\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                        </div>\n                    </div>\n                  </div>\n                  </div>\n                </div>\n                <div class=\"form-group\">\n                 <label  class=\"d-block\">Enter Number Of Forwarding Location:</label>\n                 <input formControlName=\"noofforwardinglocation_4\" type=\"text\" class=\"form-control phone-number\" [(ngModel)]=\"noofforwardinglocation_4\">\n             </div>\n\n             <div class=\"groupborder\" *ngFor='let in of selectednoofforwardinglocation_4();let i = index'>\n               <div class=\"form-group\">\n                   <label class=\"d-block\">Primary Forwarding Location - {{i+1}}</label>\n                   <div class=\"form-check form-check-inline\">\n                       <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day3\" name=\"PrimaryforwardType_{{i}}_day3\" class=\"with-gap\" [value]='0' (click)=\"setPrimaryforward(0,i,3)\">\n\n                     <label class=\"form-check-label\" for=\"inlineradio1\">Number</label>\n                   </div>\n                   <div class=\"form-check form-check-inline\">\n                       <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day3\" name=\"PrimaryforwardType_{{i}}_day3\" (click)=\"setPrimaryforward(1,i,3)\" class=\"with-gap\" [value]=\"1\">\n                     <label class=\"form-check-label\" for=\"inlineradio2\">IVR Menu</label>\n                   </div>\n                   <div class=\"form-check form-check-inline\">\n                       <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day3\" name=\"PrimaryforwardType_{{i}}_day3\" class=\"with-gap\" (click)=\"setPrimaryforward(2,i,3)\" [value]=\"2\">\n                     <label class=\"form-check-label\" for=\"inlineCheckbox3\">SIP (IP Address)</label>\n                   </div>\n                 </div>\n                 <div class=\"form-group\" *ngIf=\"!isPrimarySelected(1,i,3) && !isPrimarySelected(2,i,3)\">\n                       <label  class=\"d-block\">Number:</label>\n                       <input type=\"text\" formControlName=\"number_{{i}}_day3\" id=\"editnumber_{{i}}_day3\" class=\"form-control phone-number\" placeholder=\"(000) 000-000\"  maxlength=\"16\" (keypress)=_keyPress($event)>\n                 </div>\n                 <div class=\"form-group\" *ngIf=\"isPrimarySelected(1,i,3)\">\n                       <label  class=\"d-block\">IVR Menu:</label>\n                         <select formControlName=\"ivrMenu_{{i}}_day3\" class=\"form-control\" [value] = \"\">\n                             <option value=\"\">Select IVR Menu</option>\n                             <option *ngFor=\"let data of ivrmenus;\" [value]=\"data.uuid\">\n                                 {{data.name}}\n                               </option>\n                           </select>\n                   </div>\n                   <div class=\"form-group\" *ngIf=\"isPrimarySelected(2,i,3)\">\n                         <label  class=\"d-block\">SIP (IP Address):</label>\n                         <input  formControlName=\"sipAdd_{{i}}_day3\" type=\"text\" class=\"form-control phone-number\">\n                   </div>\n             </div>\n              </div>\n              </div>\n          </div>\n          </div>\n\n          <!-- Day 5 -->\n          <div class=\"groupborder\" *ngIf=\"noofforwarding>=5\">\n              <div >\n                <div class=\"form-group\">\n                    <label>Select Timeframe - 5</label>\n                    <select formControlName=\"day_4\" class=\"form-control\">\n                      <option value=\"0\">Select Day</option>\n                      <option value=\"1\">Monday to Friday</option>\n                      <option value=\"2\">Monday to Saturday</option>\n                      <option value=\"3\">Monday to Monday</option>\n                      <option value=\"4\">Friday to Monday</option>\n                      <option value=\"5\">Saturday to Monday</option>\n                      </select>\n\n                  </div>\n                <div class=\"row\">\n                <div class=\"col-md-12\">\n                <!-- <div class=\"row\">\n                  <div class=\"col-md-6\">\n                      <div class=\"form-group\">\n                          <label>Start Time</label>\n                          <input formControlName=\"start_time_4\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\" placeholder=\"Ex :00:00\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time>\n                      </div>\n                  </div>\n                  <div class=\"col-md-6\">\n                      <div class=\"form-group\">\n                          <label>End Time</label>\n                          <input formControlName=\"end_time_4\" [owlDateTimeTrigger]=\"dt1\" class=\"form-control\" [owlDateTime]=\"dt1\" placeholder=\"Ex :00:00\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt1></owl-date-time>\n                      </div>\n                  </div>\n                </div>  -->\n\n                <div class=\"row\">\n                  <div class=\"col-md-3\">\n                      <label>Start Time (HH:MM)</label><br>\n                        <div  style=\"display:-webkit-inline-box\">\n                        <div class=\"form-group\">\n                            <input style=\"width:68px\" formControlName=\"start_hrs_4\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                            <!-- <input formControlName=\"start_time_0\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\">\n                            <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time> -->\n                        </div>\n                        <div class=\"pt-2\">\n                          :\n                        </div>\n                      <div class=\"text-left\">\n                          <div class=\"form-group\">\n                              <input style=\"width:68px\" formControlName=\"start_min_4\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                          </div>\n                      </div>\n                    </div>\n                  </div>\n\n                  <div class=\"col-md-4\">\n                    <label>End Time (HH:MM)</label><br>\n                      <div  style=\"display:-webkit-inline-box\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"end_hrs_4\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                      </div>\n                      <div class=\"pt-2\">\n                        :\n                      </div>\n                    <div class=\"text-left\">\n                        <div class=\"form-group\">\n                            <input style=\"width:68px\" formControlName=\"end_min_4\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                        </div>\n                    </div>\n                  </div>\n                  </div>\n                </div>\n                <div class=\"form-group\">\n                 <label  class=\"d-block\">Enter Number Of Forwarding Location:</label>\n                 <input formControlName=\"noofforwardinglocation_5\" type=\"text\" class=\"form-control phone-number\" [(ngModel)]=\"noofforwardinglocation_5\">\n             </div>\n\n             <div class=\"groupborder\" *ngFor='let in of selectednoofforwardinglocation_5();let i = index'>\n               <div class=\"form-group\">\n                   <label class=\"d-block\">Primary Forwarding Location - {{i+1}}</label>\n                   <div class=\"form-check form-check-inline\">\n                       <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day4\" name=\"PrimaryforwardType_{{i}}_day4\" class=\"with-gap\" [value]='0' (click)=\"setPrimaryforward(0,i,4)\">\n\n                     <label class=\"form-check-label\" for=\"inlineradio1\">Number</label>\n                   </div>\n                   <div class=\"form-check form-check-inline\">\n                       <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day4\" name=\"PrimaryforwardType_{{i}}_day4\" (click)=\"setPrimaryforward(1,i,4)\" class=\"with-gap\" [value]=\"1\">\n                     <label class=\"form-check-label\" for=\"inlineradio2\">IVR Menu</label>\n                   </div>\n                   <div class=\"form-check form-check-inline\">\n                       <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day4\" name=\"PrimaryforwardType_{{i}}_day4\" class=\"with-gap\" (click)=\"setPrimaryforward(2,i,4)\" [value]=\"2\">\n                     <label class=\"form-check-label\" for=\"inlineCheckbox3\">SIP (IP Address)</label>\n                   </div>\n                 </div>\n                 <div class=\"form-group\" *ngIf=\"!isPrimarySelected(1,i,4) && !isPrimarySelected(2,i,4)\">\n                       <label  class=\"d-block\">Number:</label>\n                       <input type=\"text\" formControlName=\"number_{{i}}_day4\" id=\"editnumber_{{i}}_day4\" class=\"form-control phone-number\" placeholder=\"(000) 000-000\"  maxlength=\"16\" (keypress)=_keyPress($event)>\n                 </div>\n                 <div class=\"form-group\" *ngIf=\"isPrimarySelected(1,i,4)\">\n                       <label  class=\"d-block\">IVR Menu:</label>\n                         <select formControlName=\"ivrMenu_{{i}}_day4\" class=\"form-control\" [value] = \"\">\n                             <option value=\"\">Select IVR Menu</option>\n                             <option *ngFor=\"let data of ivrmenus;\" [value]=\"data.uuid\">\n                                 {{data.name}}\n                               </option>\n                           </select>\n                   </div>\n                   <div class=\"form-group\" *ngIf=\"isPrimarySelected(2,i,4)\">\n                         <label  class=\"d-block\">SIP (IP Address):</label>\n                         <input  formControlName=\"sipAdd_{{i}}_day4\" type=\"text\" class=\"form-control phone-number\">\n                   </div>\n             </div>\n              </div>\n              </div>\n          </div>\n          </div>\n\n          <!-- Day 6 -->\n          <div class=\"groupborder\" *ngIf=\"noofforwarding>=6\">\n            <div >\n              <div class=\"form-group\">\n                  <label>Select Timeframe - 6</label>\n                  <select formControlName=\"day_5\" class=\"form-control\">\n                    <option value=\"0\">Select Day</option>\n                    <option *ngFor=\"let item of allweekdays\" value=\"{{item.id}}\">{{item.start_day}} to {{item.end_day}}</option>\n                    </select>\n\n                </div>\n              <div class=\"row\">\n              <div class=\"col-md-12\">\n              <!-- <div class=\"row\">\n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                        <label>Start Time</label>\n                        <input formControlName=\"start_time_5\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\" placeholder=\"Ex :00:00\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time>\n                    </div>\n                </div>\n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                        <label>End Time</label>\n                        <input formControlName=\"end_time_5\" [owlDateTimeTrigger]=\"dt1\" class=\"form-control\" [owlDateTime]=\"dt1\" placeholder=\"Ex :00:00\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt1></owl-date-time>\n                    </div>\n                </div>\n              </div>  -->\n              <div class=\"row\">\n                <div class=\"col-md-3\">\n                    <label>Start Time (HH:MM)</label><br>\n                      <div  style=\"display:-webkit-inline-box\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"start_hrs_5\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                          <!-- <input formControlName=\"start_time_0\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\">\n                          <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time> -->\n                      </div>\n                      <div class=\"pt-2\">\n                        :\n                      </div>\n                    <div class=\"text-left\">\n                        <div class=\"form-group\">\n                            <input style=\"width:68px\" formControlName=\"start_min_5\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                        </div>\n                    </div>\n                  </div>\n                </div>\n\n                <div class=\"col-md-4\">\n                  <label>End Time (HH:MM)</label><br>\n                    <div  style=\"display:-webkit-inline-box\">\n                    <div class=\"form-group\">\n                        <input style=\"width:68px\" formControlName=\"end_hrs_5\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                    </div>\n                    <div class=\"pt-2\">\n                      :\n                    </div>\n                  <div class=\"text-left\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"end_min_5\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                      </div>\n                  </div>\n                </div>\n                </div>\n              </div>\n              <div class=\"form-group\">\n               <label  class=\"d-block\">Enter Number Of Forwarding Location:</label>\n               <input formControlName=\"noofforwardinglocation_6\" type=\"text\" class=\"form-control phone-number\" [(ngModel)]=\"noofforwardinglocation_6\">\n           </div>\n\n           <div class=\"groupborder\" *ngFor='let in of selectednoofforwardinglocation_6();let i = index'>\n             <div class=\"form-group\">\n                 <label class=\"d-block\">Primary Forwarding Location - {{i+1}}</label>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day5\" name=\"PrimaryforwardType_{{i}}_day5\" class=\"with-gap\" [value]='0' (click)=\"setPrimaryforward(0,i,5)\">\n\n                   <label class=\"form-check-label\" for=\"inlineradio1\">Number</label>\n                 </div>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day5\" name=\"PrimaryforwardType_{{i}}_day5\" (click)=\"setPrimaryforward(1,i,5)\" class=\"with-gap\" [value]=\"1\">\n                   <label class=\"form-check-label\" for=\"inlineradio2\">IVR Menu</label>\n                 </div>\n                 <div class=\"form-check form-check-inline\">\n                     <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day5\" name=\"PrimaryforwardType_{{i}}_day5\" class=\"with-gap\" (click)=\"setPrimaryforward(2,i,5)\" [value]=\"2\">\n                   <label class=\"form-check-label\" for=\"inlineCheckbox3\">SIP (IP Address)</label>\n                 </div>\n               </div>\n               <div class=\"form-group\" *ngIf=\"!isPrimarySelected(1,i,5) && !isPrimarySelected(2,i,5)\">\n                     <label  class=\"d-block\">Number:</label>\n                     <input type=\"text\" formControlName=\"number_{{i}}_day5\" id=\"editnumber_{{i}}_day5\" class=\"form-control phone-number\" placeholder=\"(000) 000-000\"  maxlength=\"16\" (keypress)=_keyPress($event)>\n               </div>\n               <div class=\"form-group\" *ngIf=\"isPrimarySelected(1,i,5)\">\n                     <label  class=\"d-block\">IVR Menu:</label>\n                       <select formControlName=\"ivrMenu_{{i}}_day5\" class=\"form-control\" [value] = \"\">\n                           <option value=\"\">Select IVR Menu</option>\n                           <option *ngFor=\"let data of ivrmenus;\" [value]=\"data.uuid\">\n                               {{data.name}}\n                             </option>\n                         </select>\n                 </div>\n                 <div class=\"form-group\" *ngIf=\"isPrimarySelected(2,i,5)\">\n                       <label  class=\"d-block\">SIP (IP Address):</label>\n                       <input  formControlName=\"sipAdd_{{i}}_day5\" type=\"text\" class=\"form-control phone-number\">\n                 </div>\n           </div>\n            </div>\n            </div>\n        </div>\n        </div>\n\n        <!-- Day 7 -->\n        <div class=\"groupborder\" *ngIf=\"noofforwarding>=7\">\n          <div >\n            <div class=\"form-group\">\n                <label>Select Timeframe - 7</label>\n                <select formControlName=\"day_6\" class=\"form-control\">\n                  <option value=\"0\">Select Day</option>\n                  <option *ngFor=\"let item of allweekdays\" value=\"{{item.id}}\">{{item.start_day}} to {{item.end_day}}</option>\n                  </select>\n\n              </div>\n            <div class=\"row\">\n            <div class=\"col-md-12\">\n            <!-- <div class=\"row\">\n              <div class=\"col-md-6\">\n                  <div class=\"form-group\">\n                      <label>Start Time</label>\n                      <input formControlName=\"start_time_6\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\" placeholder=\"Ex :00:00\">\n                      <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time>\n                  </div>\n              </div>\n              <div class=\"col-md-6\">\n                  <div class=\"form-group\">\n                      <label>End Time</label>\n                      <input formControlName=\"end_time_6\" [owlDateTimeTrigger]=\"dt1\" class=\"form-control\" [owlDateTime]=\"dt1\" placeholder=\"Ex :00:00\">\n                      <owl-date-time [pickerType]=\"'timer'\" #dt1></owl-date-time>\n                  </div>\n              </div>\n            </div>  -->\n\n            <div class=\"row\">\n              <div class=\"col-md-3\">\n                  <label>Start Time (HH:MM)</label><br>\n                    <div  style=\"display:-webkit-inline-box\">\n                    <div class=\"form-group\">\n                        <input style=\"width:68px\" formControlName=\"start_hrs_6\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                        <!-- <input formControlName=\"start_time_0\" [owlDateTimeTrigger]=\"dt2\" class=\"form-control\" [owlDateTime]=\"dt2\">\n                        <owl-date-time [pickerType]=\"'timer'\" #dt2></owl-date-time> -->\n                    </div>\n                    <div class=\"pt-2\">\n                      :\n                    </div>\n                  <div class=\"text-left\">\n                      <div class=\"form-group\">\n                          <input style=\"width:68px\" formControlName=\"start_min_6\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                      </div>\n                  </div>\n                </div>\n              </div>\n\n              <div class=\"col-md-4\">\n                <label>End Time (HH:MM)</label><br>\n                  <div  style=\"display:-webkit-inline-box\">\n                  <div class=\"form-group\">\n                      <input style=\"width:68px\" formControlName=\"end_hrs_6\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                  </div>\n                  <div class=\"pt-2\">\n                    :\n                  </div>\n                <div class=\"text-left\">\n                    <div class=\"form-group\">\n                        <input style=\"width:68px\" formControlName=\"end_min_6\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                    </div>\n                </div>\n              </div>\n              </div>\n            </div>\n\n            <div class=\"form-group\">\n             <label  class=\"d-block\">Enter Number Of Forwarding Location:</label>\n             <input formControlName=\"noofforwardinglocation_7\" type=\"text\" class=\"form-control phone-number\" [(ngModel)]=\"noofforwardinglocation_7\">\n         </div>\n\n         <div class=\"groupborder\" *ngFor='let in of selectednoofforwardinglocation_7();let i = index'>\n           <div class=\"form-group\">\n               <label class=\"d-block\">Primary Forwarding Location - {{i+1}}</label>\n               <div class=\"form-check form-check-inline\">\n                   <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day6\" name=\"PrimaryforwardType_{{i}}_day6\" class=\"with-gap\" [value]='0' (click)=\"setPrimaryforward(0,i,6)\">\n\n                 <label class=\"form-check-label\" for=\"inlineradio1\">Number</label>\n               </div>\n               <div class=\"form-check form-check-inline\">\n                   <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day6\" name=\"PrimaryforwardType_{{i}}_day6\" (click)=\"setPrimaryforward(1,i,6)\" class=\"with-gap\" [value]=\"1\">\n                 <label class=\"form-check-label\" for=\"inlineradio2\">IVR Menu</label>\n               </div>\n               <div class=\"form-check form-check-inline\">\n                   <input type=\"radio\" formControlName=\"PrimaryforwardType_{{i}}_day6\" name=\"PrimaryforwardType_{{i}}_day6\" class=\"with-gap\" (click)=\"setPrimaryforward(2,i,6)\" [value]=\"2\">\n                 <label class=\"form-check-label\" for=\"inlineCheckbox3\">SIP (IP Address)</label>\n               </div>\n             </div>\n             <div class=\"form-group\" *ngIf=\"!isPrimarySelected(1,i,6) && !isPrimarySelected(2,i,6)\">\n                   <label  class=\"d-block\">Number:</label>\n                   <input type=\"text\" formControlName=\"number_{{i}}_day6\" id=\"editnumber_{{i}}_day4\" class=\"form-control phone-number\" placeholder=\"(000) 000-000\"  maxlength=\"16\" (keypress)=_keyPress($event)>\n             </div>\n             <div class=\"form-group\" *ngIf=\"isPrimarySelected(1,i,6)\">\n                   <label  class=\"d-block\">IVR Menu:</label>\n                     <select formControlName=\"ivrMenu_{{i}}_day6\" class=\"form-control\" [value] = \"\">\n                         <option value=\"\">Select IVR Menu</option>\n                         <option *ngFor=\"let data of ivrmenus;\" [value]=\"data.uuid\">\n                             {{data.name}}\n                           </option>\n                       </select>\n               </div>\n               <div class=\"form-group\" *ngIf=\"isPrimarySelected(2,i,6)\">\n                     <label  class=\"d-block\">SIP (IP Address):</label>\n                     <input  formControlName=\"sipAdd_{{i}}_day6\" type=\"text\" class=\"form-control phone-number\">\n               </div>\n         </div>\n          </div>\n          </div>\n      </div>\n      </div>\n\n        <div class=\"modal-footer\" style=\"padding: 0;\">\n           <button [disabled]=\"isName == 'fail'\" type=\"submit\" (click)=\"editcloseModal()\" class=\"btn btn-primary m-t-15 waves-effect\">Edit Target</button>\n           <button data-dismiss=\"modal\" class=\"btn btn-secondary m-t-15 waves-effect\">Close</button>\n         </div>\n      </form>\n    </div>\n  </div>\n</div>\n</div>\n\n<!-- Add Label Modal -->\n<div class=\"modal fade\" id=\"addBuyer\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\naria-hidden=\"true\">\n<div class=\"modal-dialog model-lg\" role=\"document\">\n  <div class=\"modal-content\">\n    <div class=\"modal-header\">\n      <h5 class=\"modal-title\" id=\"formModal\">Create Buyer</h5>\n      <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n        <span aria-hidden=\"true\">&times;</span>\n      </button>\n    </div>\n    <div class=\"modal-body\">\n      <form id=\"addLabel\" [formGroup]=\"addBuyerForm\" (ngSubmit)=\"onBuyerSubmit()\">\n        <div class=\"row\">\n          <div class=\"col-md-12\">\n        <div class=\"form-group\">\n            <label>Company</label>\n            <input formControlName=\"company\" [(ngModel)]=\"company\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': BuyerSubmitted && buyercontrol.company.errors }\">\n            <div *ngIf=\"BuyerSubmitted && buyercontrol.company.errors\" class=\"invalid-feedback\">\n                <div *ngIf=\"buyercontrol.company.errors.required\">Company is required</div>\n            </div>\n         </div>\n\n        <div class=\"form-group\">\n          <label>Email ID</label>\n          <input formControlName=\"email\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && buyercontrol.email.errors }\">\n          <div *ngIf=\"Submitted && buyercontrol.email.errors\" class=\"invalid-feedback\">\n              <div *ngIf=\"buyercontrol.email.errors.required\">Email is required</div>\n          </div>\n        </div>\n\n        <div class=\"form-group\">\n          <label>Password</label>\n          <input formControlName=\"password\" type=\"password\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && buyercontrol.password.errors }\">\n          <div *ngIf=\"Submitted && buyercontrol.password.errors\" class=\"invalid-feedback\">\n              <div *ngIf=\"buyercontrol.password.errors.required\">Password is required</div>\n          </div>\n       </div>\n\n          <div class=\"form-group\">\n            <label  class=\"d-block\">Sub Id  :</label>\n            <input formControlName=\"sub_id\" type=\"text\" class=\"form-control\">\n          </div>\n\n          <div class=\"form-group\">\n            <label  class=\"d-block\">Allow Buyer To Pause Targets :</label>\n            <label class=\"custom-switch mt-2 pl-0\">\n              <input type=\"checkbox\" formControlName=\"allow_buyer_to_pause_target\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n              <span class=\"custom-switch-indicator\"></span>\n            </label>\n          </div>\n\n          <div class=\"form-group\">\n            <label  class=\"d-block\">Allow Buyer To Set Target Concurrency :</label>\n            <label class=\"custom-switch mt-2 pl-0\">\n              <input type=\"checkbox\" formControlName=\"allow_buyer_to_set_target_concurrency\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n              <span class=\"custom-switch-indicator\"></span>\n            </label>\n          </div>\n\n          <div class=\"form-group\">\n            <label  class=\"d-block\">Allow Buyer To Dispute Call Conversions :</label>\n            <label class=\"custom-switch mt-2 pl-0\">\n              <input type=\"checkbox\" formControlName=\"allow_buyer_to_dispute_call_conversions\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n              <span class=\"custom-switch-indicator\"></span>\n            </label>\n          </div>\n\n          <div class=\"form-group\">\n            <label  class=\"d-block\">Limit Revenue : </label>\n            <label class=\"custom-switch mt-2 pl-0\">\n              <input type=\"checkbox\" formControlName=\"limit_revenue\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n              <span class=\"custom-switch-indicator\"></span>\n            </label>\n          </div>\n\n         </div>\n     </div>\n        <div class=\"modal-footer\" style=\"padding: 0;\">\n         <!-- !addLabelForm.valid || -->\n           <button (click)=\"closeBuyerModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Create Buyer</button>\n           <button  type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\">Reset</button>\n          </div>\n      </form>\n    </div>\n  </div>\n</div>\n</div>\n\n<div class=\"modal fade\" id=\"addZipcode\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\naria-hidden=\"true\">\n<div class=\"modal-dialog model-lg\" role=\"document\">\n  <div class=\"modal-content\">\n    <div class=\"modal-header\">\n      <h5 class=\"modal-title\" id=\"formModal\">Upload Zipcode</h5>\n      <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n        <span aria-hidden=\"true\">&times;</span>\n      </button>\n    </div>\n    <div class=\"modal-body\">\n        <div class=\"row\">\n          <div class=\"col-md-12\">\n           <div class=\"form-group\">\n              <label>Upload TXT</label>\n              <input #myInput (change)=\"selectFile($event)\" [(ngModel)]=\"selectedfile\" type=\"file\" class=\"form-control p-0 p-1\">\n              <p class=\"text-danger\">Note: Only TXT File allowed</p>\n          </div>\n         </div>\n     </div>\n        <div class=\"modal-footer\" style=\"padding: 0;\">\n           <button (click)=\"onZipSubmit()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Submit</button>\n           <button data-dismiss=\"modal\" aria-label=\"Close\" type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\">Cancel</button>\n          </div>\n    </div>\n  </div>\n</div>\n</div>\n\n\n<!-- <div *ngIf=\"showLoadingIndicator\">\n  <div class=\"loader\"></div>\n</div> -->\n\n<div class=\"main-content\">\n        <section class=\"section\" style=\"position: relative\">\n          <!-- <ngx-ui-loader [loaderId]=\"'loader-01'\"></ngx-ui-loader> -->\n          <ng-template #foregroundSpinner>\n            <div class=\"sk-chase\">\n              <div class=\"sk-chase-dot customLoaderId\"></div>\n            </div>\n          </ng-template>\n          <ngx-ui-loader\n            [loaderId]=\"loader.loaderId\"\n            [fgsTemplate]=\"foregroundSpinner\"\n          ></ngx-ui-loader>\n\n          <div class=\"section-body\">\n            <div class=\"row\">\n              <div class=\"col-md-12 col-md-12 col-md-lg-12\">\n                <form [formGroup]=\"editForm\" (ngSubmit)=\"onSubmit()\">\n                <div class=\"card\">\n                  <div class=\"card-header\">\n                    <h4>Edit Target</h4>\n                  </div>\n                  <div class=\"card-body\">\n                    <fieldset class=\"scheduler-border\">\n                    <legend class=\"scheduler-border\">Target Settings</legend>\n                    <div class=\"form-group\">\n                        <label>Name</label>\n                        <input formControlName=\"name\" id=\"name\" type=\"text\" class=\"form-control\"  [ngClass]=\"{ 'is-invalid': submitted && f.name.errors }\" placeholder=\"\" (input)=\"validateTargetname()\">\n                        <div *ngIf=\"submitted && f.name.errors\" class=\"invalid-feedback\" >\n                            <div *ngIf=\"f.name.errors.required\">Name is required</div>\n\n                        </div>\n                        <div *ngIf=\"isTargetName == 'success'  && isTargetName != ''\" style=\"color:green;\">\n                          Name Is Available\n                        </div>\n                         <div *ngIf=\"isTargetName == 'fail' && isTargetName != ''\" style=\"color:red;\">\n                          Name Is Not Available\n                        </div>\n                    </div>\n\n                    <div class=\"form-group\">\n                      <label>Sub Id</label>\n                      <div class=\"input-group\">\n                        <input formControlName=\"subid\" id=\"subid\" type=\"text\" class=\"form-control\" placeholder=\"\">\n                        </div>\n                    </div>\n\n                    <div class=\"row\">\n                      <div class=\"col-md-6\">\n                        <div class=\"form-group\">\n                          <label>Buyer</label>\n                          <!-- <select formControlName=\"buyer\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': submitted && f.fslrulesname.errors }\">\n                            <option value=\"\">Select Buyer</option>\n                            <option *ngFor=\"let buyers of allBuyers;\" [value]=\"buyers.uuid\">\n                                {{buyers.company}}\n                              </option>\n                          </select> -->\n\n\n                          <!-- <div *ngIf=\"submitted && f.buyer.errors\" class=\"invalid-feedback\">\n                            <div *ngIf=\"f.buyer.errors.required\">Buyer is required</div>\n                          </div>     -->\n                          <angular2-multiselect [data]=\"allBuyers\" [(ngModel)]=\"selectedItemsBuyer1\" formControlName=\"buyer\" [settings]=\"settings\"></angular2-multiselect>\n                        </div>\n                      </div>\n                      <div class=\"col-md-2 mt-4 pt-1\">\n                        <button type=\"button\" data-toggle=\"modal\" data-target=\"#addBuyer\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-1\"><i class=\"fa fa-plus\"></i> Add New Buyer\n                        </button>\n                      </div>\n                    </div>\n\n                    <div class=\"row\">\n                      <div class=\"col-md-2\">\n                         <div class=\"control-group mt-2\">\n                           <div class=\"control-label\">{{ringtreetext}}</div>\n                           <label class=\"custom-switch mt-2 pl-0\">\n                             <input type=\"checkbox\" [checked]=\"ringtree==true\" (change)=\"ringtree_toggle($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                             <span class=\"custom-switch-indicator\"></span>\n                           </label>\n                         </div>\n                      </div>\n                    </div>\n\n                    <fieldset class=\"scheduler-border\">\n                      <legend class=\"scheduler-border\">{{ringtreetext}}</legend>\n\n                       <div *ngIf=\"ringtree==false\">\n\n                        <div class=\"row\">\n                          <div class=\"col-md-5\">\n                            <div class=\"form-group\">\n                              <div class=\"control-group\">\n                                  <label class=\"control-label input-label\" for=\"startTime\">Type:</label>\n                                  <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                                  <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': settingToggleTypeval==0}\" (click)=\"settingToggleType(0)\">\n                                        <input class=\"form-check-input\" name=\"settingToggleBlockCallsIfCapped\" formControlName=\"settingToggleBlockCallsIfCapped\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                                        Number\n                                  </label>\n                                  <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': settingToggleTypeval==1}\" (click)=\"settingToggleType(1)\">\n                                    <input class=\"form-check-input\" name=\"settingToggleBlockCallsIfCapped\" formControlName=\"settingToggleBlockCallsIfCapped\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                                    IVR Menu\n                                  </label>\n                                  <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': settingToggleTypeval==2}\" (click)=\"settingToggleType(2)\">\n                                    <input class=\"form-check-input\" name=\"settingToggleBlockCallsIfCapped\" formControlName=\"settingToggleBlockCallsIfCapped\" type=\"radio\" id=\"option2\" [value]=\"2\">\n                                    SIP\n                                  </label>\n\n                                  <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': settingToggleTypeval==3}\" (click)=\"settingToggleType(3)\">\n                                    <input class=\"form-check-input\" name=\"settingToggleBlockCallsIfCapped\" formControlName=\"settingToggleBlockCallsIfCapped\" type=\"radio\" id=\"option2\" [value]=\"3\">\n                                    Voicemail\n                                  </label>\n\n                                    </div>\n                             </div>\n                            </div>\n                          </div>\n                        </div>\n\n                        <div class=\"control-group mt-2\" *ngIf=\"settingToggleTypeval==0\">\n                            <label class=\"control-label input-label\" for=\"startTime\">Number :</label>\n                            <input type=\"text\" formControlName=\"number\" class=\"form-control\" type=\"text\" placeholder=\"Enter Number\" [ngClass]=\"{ 'is-invalid': submitted && f.number.errors }\" />\n                            <div *ngIf=\"submitted && f.number.errors\" class=\"invalid-feedback\">\n                              <div *ngIf=\"f.number.errors.required\">Number is required</div>\n                            </div>\n                        </div>\n                       <div *ngIf=\"settingToggleTypeval==1\">\n                          <div class=\"control-group mt-2\">\n                              <label class=\"control-label input-label\" for=\"startTime\">Select IVR Menu:</label>\n                              <!-- <select formControlName=\"ivrMenu\" class=\"form-control\" >\n                                <option value=\"\">Select IVR Menu</option>\n                                <option *ngFor=\"let data of ivrmenus;\" [value]=\"data.uuid\">\n                                    {{data.name}}\n                                  </option>\n                              </select>   -->\n                              <angular2-multiselect [data]=\"ivrmenus\" [(ngModel)]=\"selected_ivr\" formControlName=\"ivrMenu\" [settings]=\n                              \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select IVR '}\"></angular2-multiselect>\n                              <!-- <a *ngIf=\"selected_ivr\" target=\"_blank\" routerLink=\"/edit-ivr/{{selected_ivr[0].uuid}}\" style=\"color: #3abaf4;\">Go To IVR Edit</a>     -->\n                          </div>\n                      </div>\n                       <div *ngIf=\"settingToggleTypeval==2\">\n                          <div class=\"control-group mt-2\">\n                              <label class=\"control-label input-label\" for=\"startTime\">SIP (IP Address):</label>\n                              <input type=\"text\" formControlName=\"sip_address\" class=\"form-control\" type=\"text\" [ngClass]=\"{ 'is-invalid': submitted && f.sip_address.errors }\"/>\n                              <div *ngIf=\"submitted && f.sip_address.errors\" class=\"invalid-feedback\">\n                                <div *ngIf=\"f.sip_address.errors.required\">SIP Address is required</div>\n                              </div>\n                          </div>\n                      </div>\n                      <div class=\"control-group mt-2\" *ngIf=\"settingToggleTypeval==3\">\n                        <label class=\"control-label input-label\" for=\"startTime\">Voicemail :</label>\n                        <input type=\"text\" formControlName=\"voice_mail\" class=\"form-control\" type=\"text\" placeholder=\"Enter Voicemail\" [ngClass]=\"{ 'is-invalid': submitted && f.voice_mail.errors }\" />\n                        <div *ngIf=\"submitted && f.voice_mail.errors\" class=\"invalid-feedback\">\n                          <div *ngIf=\"f.voice_mail.errors.required\">Voicemail is required</div>\n                        </div>\n                    </div>\n\n\n                      </div>\n\n\n                      <div *ngIf=\"ringtree==true\">\n\n                        <div class=\"row\">\n                          <div class=\"col-md-2\">\n                             <div class=\"control-group mt-2\">\n                               <div class=\"control-label\">URL</div>\n                             </div>\n                          </div>\n                          <div class=\"col-md-5 mt-4\">\n                             <div class=\"form-group\">\n                               <input formControlName=\"url\" type=\"text\" class=\"form-control formcontrol\" id=\"\">\n                             </div>\n                          </div>\n                        </div>\n\n                        <div class=\"row\">\n                          <div class=\"col-md-2\">\n                             <div class=\"control-group mt-4\">\n                               <div class=\"control-label\">HTTP Method</div>\n                             </div>\n                          </div>\n                          <div class=\"col-md-2\">\n                             <div class=\"form-group mt-2\">\n                              <select formControlName=\"http_method\" name=\"http_method\" id=\"http_method\" class=\"form-control\" (change)=\"methodtype($event)\">\n                                <option value=\"0\">GET</option>\n                                <option value=\"1\">POST</option>\n                                <option value=\"2\">PUT</option>\n                                <option value=\"3\">PATCH</option>\n                                <option value=\"4\">DELETE</option>\n                              </select>\n                             </div>\n                          </div>\n                        </div>\n\n                        <div class=\"row\" *ngIf=\"methodtypeval != 0 && methodtypeval != 4\">\n                          <div class=\"col-md-2\">\n                             <div class=\"control-group mt-4\">\n                               <div class=\"control-label\">Content Type</div>\n                             </div>\n                          </div>\n                          <div class=\"col-md-2\">\n                             <div class=\"form-group mt-2\">\n                              <select formControlName=\"content_type\" name=\"content_type\" id=\"content_type\" class=\"form-control\">\n                                <option value=\"0\">application/json</option>\n                                <option value=\"1\">application/xml</option>\n                                <option value=\"2\">application/x-www-form-urlencoded</option>\n                                <option value=\"3\">plain/text</option>\n                              </select>\n                             </div>\n                          </div>\n                        </div>\n\n                        <div class=\"row\" *ngIf=\"methodtypeval != 0 && methodtypeval != 4\">\n                          <div class=\"col-md-2\">\n                             <div class=\"control-group mt-4\">\n                               <div class=\"control-label\">Body</div>\n                             </div>\n                          </div>\n                          <div class=\"col-md-5\">\n                             <div class=\"form-group mt-2\">\n                              <textarea formControlName=\"body\" cols=\"30\" rows=\"10\" class=\"form-control\"></textarea>\n                             </div>\n                          </div>\n                        </div>\n\n\n                        <div class=\"row\">\n                          <div class=\"col-md-2\">\n                             <div class=\"control-group mt-2\">\n                               <div class=\"control-label\">HTTP Headers</div>\n                             </div>\n                          </div>\n                          <div class=\"col-md-2 mt-4\">\n                             <div class=\"form-group\">\n                               <input formControlName=\"http_headers_name\" type=\"text\" class=\"form-control formcontrol\" placeholder=\"Header Name\" id=\"\">\n                             </div>\n                          </div>\n                          <div class=\"mt-2\">:</div>\n                          <div class=\"col-md-2 mt-4 text-left\">\n                             <div class=\"form-group\">\n                               <input formControlName=\"http_headers_value\" type=\"text\" class=\"form-control formcontrol\" placeholder=\" Value\"  id=\"\">\n                             </div>\n                          </div>\n                        </div>\n\n                        <!-- <div class=\"row\">\n                          <div class=\"col-md-2\">\n                             <div class=\"control-group mt-2\">\n                               <div class=\"control-label\">Keyword</div>\n                             </div>\n                          </div>\n                          <div class=\"col-md-5 mt-4\">\n                             <div class=\"form-group\">\n                               <input formControlName=\"keyword\" type=\"text\" class=\"form-control formcontrol\" id=\"\">\n                             </div>\n                          </div>\n                        </div> -->\n\n                        <div *ngFor=\"let keywords of addkeyword; let i = index;\">\n                          <div class=\"row\">\n                            <div class=\"col-md-2\">\n                              <div class=\"control-group mt-2\">\n                                <div class=\"control-label\">Keyword {{i+1}}</div>\n                              </div>\n                            </div>\n                            <div class=\"col-md-5 mt-4\">\n                              <div class=\"form-group\">\n                                <input formControlName=\"keyword{{i}}\" type=\"text\" class=\"form-control formcontrol\" id=\"\">\n                              </div>\n                            </div>\n                            <div class=\"col-md-1\" *ngIf=\"i+1 == addkeyword.length && addkeyword.length!=3\">\n                              <input type=\"button\" value=\"+\" class=\"btn btn-info btn-sm\" (click)=\"addRow(i+1)\">\n                            </div>\n                            <div class=\"col-md-1\" *ngIf=\"i+1 == addkeyword.length && addkeyword.length>=2\">\n                              <input type=\"button\" value=\"-\" class=\"btn btn-danger btn-sm\" (click)=\"removeRow(i)\">\n                            </div>\n                          </div>\n                        </div>\n\n\n                      </div>\n\n                  </fieldset>\n\n\n\n                  </fieldset>\n\n                  <fieldset class=\"scheduler-border\">\n                    <legend class=\"scheduler-border\">Hours of Operation</legend>\n\n                    <div class=\"form-group\">\n                      <angular2-multiselect [data]=\"alltimezone\" [(ngModel)]=\"timezoneval\"  formControlName=\"timezone\" [settings]=\n                                  \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select Timezone '}\"></angular2-multiselect>\n                    </div>\n                    <div class=\"row\">\n                      <div class=\"col-md-2\">\n                        <label class=\"custom-switch mt-2 pl-0\">\n                          <input type=\"checkbox\" (change)=\"hof_alwaysopen_toggle($event)\" [checked]=\"hof_alwaysopen\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                          <span class=\"custom-switch-indicator\"></span>\n                        </label>\n                      </div>\n                      <div class=\"col-md-6\">\n                        <span *ngIf=\"!hof_alwaysopen\">Always Open</span>\n                        <span *ngIf=\"hof_alwaysopen\">\n                          <input type=\"button\" (click)=\"is12or24_toggle(0)\" value=\"12/24\" class=\"btn btn-primary font-12 btn-sm p-1 mb-3 mr-2\" style=\"border: 1px solid green!important; background: #0266c8;\" *ngIf=\"is12or24 == 1\">\n\n                        <input type=\"button\" (click)=\"is12or24_toggle(1)\" *ngIf=\"is12or24 == 0\" value=\"12/24\" class=\"btn btn-primary font-12 btn-sm p-1 mb-3 mr-2\" style=\"border: 1px solid green!important\">\n                          <!-- <input type=\"button\" (click)=\"iscreateoffertoggle()\" value=\"12 / 24\" class=\"btn btn-primary font-12 btn-sm mr-2 p-1 mb-3 \" style=\"border: 1px solid green!important\"> -->\n                          <input type=\"button\" (click)=\"isadvanced_toggle(!isadvanced)\" [value]=\"advanced\" class=\"btn btn-primary font-12 btn-sm p-1 mb-3\" style=\"border: 1px solid green!important\">\n                        </span>\n                      </div>\n                    </div>\n                    <div class=\"row\" *ngIf=\"hof_alwaysopen\">\n                      <div class=\"col-md-12\">\n                          <div class=\"table-reponsive\" *ngIf=\"isadvanced==0\">\n                            <table style=\"width:60%\" class=\"table table-striped\">\n                              <thead>\n                              <tr>\n                                <th style=\"background: #1a1d2c!important;width: 14%;\"></th>\n                                <th style=\"background: #1a1d2c!important;width: 20%;\">Open</th>\n                                <th style=\"background: #1a1d2c!important;width: 20%;\">Close</th>\n                                <!-- <th style=\"background: #1a1d2c!important;\">Timezone</th> -->\n                              </tr>\n                            </thead>\n                            <tbody>\n                              <tr>\n                                <td style=\"background: #252c44!important;\"> <span>Monday - Sunday</span></td>\n                                <td style=\"background: #252c44!important;\">\n                                  <!-- <label>Opening Time (HH:MM)</label><br> -->\n                                    <div  style=\"display:-webkit-inline-box\" class=\"pt-1\">\n                                    <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_hrs('start_hrs')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-up font-16 pb-1\"></span>\n                                        </div>\n                                        <input style=\"background: #22283b!important;\" formControlName=\"start_hrs\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control hofnumber\">\n                                        <div (click)=\"decrement_hrs('start_hrs')\" style=\"cursor: pointer;\">\n                                        <span class=\"fa fa-angle-down font-16 pt-1\"></span>\n                                        </div>\n                                    </div>\n                                    <div class=\"pt-4 mt-1\">\n                                      :\n                                    </div>\n                                    <div class=\"text-left\">\n                                        <div class=\"form-group text-center\">\n                                          <div (click)=\"increment_min('start_min')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 pb-1\"></span></div>\n                                            <input style=\"background: #22283b!important;\" formControlName=\"start_min\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                            <div (click)=\"decrement_min('start_min')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                        </div>\n                                    </div>\n                                    <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                      <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('default_ampm')\">\n                                        {{this.editForm.get('default_ampm').value==0?\"AM\":\"PM\"}}\n                                      </button>\n                                    </div>\n                                  </div>\n                                </td>\n                                <td style=\"background: #252c44!important;\">\n                                  <div style=\"display:-webkit-inline-box\" >\n                                      <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_hrs('end_hrs')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 pb-1\"></span></div>\n                                          <input style=\"background: #22283b!important;\" formControlName=\"end_hrs\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control hofnumber\">\n                                          <div (click)=\"decrement_hrs('end_hrs')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                      </div>\n                                      <div class=\"pt-4 mt-1\">\n                                        :\n                                      </div>\n                                    <div class=\"text-left\">\n                                        <div class=\"form-group text-center\">\n                                          <div (click)=\"increment_min('end_min')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-up font-16 pb-1\"></span></div>\n                                            <input style=\"background: #22283b!important;\" formControlName=\"end_min\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                            <div (click)=\"decrement_min('end_min')\" style=\"cursor: pointer;\">\n                                              <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                        </div>\n                                    </div>\n                                    <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                      <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('default_ampm_close')\">\n                                        {{this.editForm.get('default_ampm_close').value==0?\"AM\":\"PM\"}}\n                                      </button>\n                                    </div>\n                                  </div>\n                                </td>\n                                <!-- <td style=\"background: #252c44!important;\"> -->\n                                  <!-- <select formControlName=\"timezone\" class=\"form-control\" [value]=\"\">\n                                    <option value=\"\">Select Timezone</option>\n                                    <option value=\"{{item.id}}\" *ngFor=\"let item of alltimezone\">{{item.gmtzone}}</option>\n                                  </select>   -->\n                                  <!-- <angular2-multiselect [data]=\"alltimezone\" [(ngModel)]=\"timezoneval\"  formControlName=\"timezone\" [settings]=\n                                  \"{enableSearchFilter: true,classes: 'filterdd',showCheckbox:false,singleSelection: true, text:'Select Timezone '}\"></angular2-multiselect>\n                                </td> -->\n                              </tr>\n                            </tbody>\n                            </table>\n                          </div>\n\n                          <!-- advanced -->\n                          <div class=\"table-reponsive\" *ngIf=\"isadvanced==1\">\n                            <table style=\"width:60%\" class=\"table table-striped\">\n                              <thead>\n                              <tr>\n                                <th style=\"background: #1a1d2c!important;\"></th>\n                                <th style=\"background: #1a1d2c!important;\">Open</th>\n                                <th style=\"background: #1a1d2c!important;\">Open</th>\n                                <th style=\"background: #1a1d2c!important;\">Close</th>\n                              </tr>\n                            </thead>\n                            <tbody>\n                              <tr>\n                                <td style=\"background: #22273c!important;border-bottom: none;\"> <span>Sunday</span></td>\n                                <td style=\"background: #22273c!important;border-bottom: none\">\n                                  <label class=\"custom-switch mt-2 pl-0\">\n                                    <input type=\"checkbox\" (change)=\"sunday_open($event)\" [checked]=\"sundayopen\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                                    <span class=\"custom-switch-indicator\"></span>\n                                  </label>\n                                </td>\n                                <td style=\"background: #22273c!important;border-bottom: none\">\n                                  <!-- <label>Opening Time (HH:MM)</label><br> -->\n                                    <div  style=\"display:-webkit-inline-box\" class=\"pt-2\">\n                                    <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_hrs('start_hrs_sunday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-up font-16 \"></span>\n                                        </div>\n                                        <input style=\"background: #22283b!important;\" formControlName=\"start_hrs_sunday\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control hofnumber\">\n                                        <div (click)=\"decrement_hrs('start_hrs_sunday')\" style=\"cursor: pointer;\">\n                                        <span class=\"fa fa-angle-down font-16 pt-1\"></span>\n                                        </div>\n                                    </div>\n                                    <div class=\"pt-4 mt-1\">\n                                      :\n                                    </div>\n                                    <div class=\"text-left\">\n                                        <div class=\"form-group text-center\">\n                                          <div (click)=\"increment_min('start_min_sunday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                            <input style=\"background: #22283b!important;\" formControlName=\"start_min_sunday\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                            <div (click)=\"decrement_min('start_min_sunday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                        </div>\n                                    </div>\n                                    <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                      <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('sunday_ampm')\">\n                                        {{this.editForm.get('sunday_ampm').value==0?\"AM\":\"PM\"}}\n                                      </button>\n                                    </div>\n                                  </div>\n                                </td>\n                                <td style=\"background: #22273c!important;border-bottom: none\">\n                                  <div style=\"display:-webkit-inline-box\" >\n                                      <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_hrs('end_hrs_sunday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                          <input style=\"background: #22283b!important;\" formControlName=\"end_hrs_sunday\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control hofnumber\">\n                                          <div (click)=\"decrement_hrs('end_hrs_sunday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                      </div>\n                                      <div class=\"pt-4 mt-1\">\n                                        :\n                                      </div>\n                                    <div class=\"text-left\">\n                                        <div class=\"form-group text-center\">\n                                          <div (click)=\"increment_min('end_min_sunday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                            <input style=\"background: #22283b!important;\" formControlName=\"end_min_sunday\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                            <div (click)=\"decrement_min('end_min_sunday')\" style=\"cursor: pointer;\">\n                                              <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                        </div>\n                                    </div>\n                                    <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                      <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('sunday_ampm_close')\">\n                                        {{this.editForm.get('sunday_ampm_close').value==0?\"AM\":\"PM\"}}\n                                      </button>\n                                    </div>\n                                  </div>\n                                </td>\n                              </tr>\n\n                              <tr>\n                                <td style=\"background: #252c44!important;border-bottom: none\"> <span>Monday</span></td>\n                                <td style=\"background: #252c44!important;border-bottom: none\">\n                                  <label class=\"custom-switch mt-2 pl-0\">\n                                    <input type=\"checkbox\" (change)=\"monday_open($event)\" [checked]=\"mondayopen\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                                    <span class=\"custom-switch-indicator\"></span>\n                                  </label>\n                                </td>\n                                <td style=\"background: #252c44!important;border-bottom: none\">\n                                  <!-- <label>Opening Time (HH:MM)</label><br> -->\n                                    <div  style=\"display:-webkit-inline-box\" class=\"pt-2\">\n                                    <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_hrs('start_hrs_monday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-up font-16 \"></span>\n                                        </div>\n                                        <input style=\"background: #22283b!important;\" formControlName=\"start_hrs_monday\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control hofnumber\">\n                                        <div (click)=\"decrement_hrs('start_hrs_monday')\" style=\"cursor: pointer;\">\n                                        <span class=\"fa fa-angle-down font-16 pt-1\"></span>\n                                        </div>\n                                    </div>\n                                    <div class=\"pt-4 mt-1\">\n                                      :\n                                    </div>\n                                    <div class=\"text-left\">\n                                        <div class=\"form-group text-center\">\n                                          <div (click)=\"increment_min('start_min_monday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                            <input style=\"background: #22283b!important;\" formControlName=\"start_min_monday\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                            <div (click)=\"decrement_min('start_min_monday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                        </div>\n                                    </div>\n                                    <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                      <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('monday_ampm')\">\n                                        {{this.editForm.get('monday_ampm').value==0?\"AM\":\"PM\"}}\n                                      </button>\n                                    </div>\n                                  </div>\n                                </td>\n                                <td style=\"background: #252c44!important;border-bottom: none\">\n                                  <div style=\"display:-webkit-inline-box\" >\n                                      <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_hrs('end_hrs_monday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                          <input style=\"background: #22283b!important;\" formControlName=\"end_hrs_monday\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control hofnumber\">\n                                          <div (click)=\"decrement_hrs('end_hrs_monday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                      </div>\n                                      <div class=\"pt-4 mt-1\">\n                                        :\n                                      </div>\n                                    <div class=\"text-left\">\n                                        <div class=\"form-group text-center\">\n                                          <div (click)=\"increment_min('end_min_monday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                            <input style=\"background: #22283b!important;\" formControlName=\"end_min_monday\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                            <div (click)=\"decrement_min('end_min_monday')\" style=\"cursor: pointer;\">\n                                              <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                        </div>\n                                    </div>\n                                    <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                      <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('monday_ampm_close')\">\n                                        {{this.editForm.get('monday_ampm_close').value==0?\"AM\":\"PM\"}}\n                                      </button>\n                                    </div>\n                                  </div>\n                                </td>\n                              </tr>\n\n                              <tr>\n                                <td style=\"background: #22273c!important;border-bottom: none\"> <span>Tuesday </span></td>\n                                <td style=\"background: #22273c!important;border-bottom: none\">\n                                  <label class=\"custom-switch mt-2 pl-0\">\n                                    <input type=\"checkbox\" (change)=\"tuesday_open($event)\" [checked]=\"tuesdayopen\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                                    <span class=\"custom-switch-indicator\"></span>\n                                  </label>\n                                </td>\n                                <td style=\"background: #22273c!important;border-bottom: none\">\n                                  <!-- <label>Opening Time (HH:MM)</label><br> -->\n                                    <div  style=\"display:-webkit-inline-box\" class=\"pt-2\">\n                                    <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_hrs('start_hrs_tuesday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-up font-16 \"></span>\n                                        </div>\n                                        <input style=\"background: #22283b!important;\" formControlName=\"start_hrs_tuesday\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control hofnumber\">\n                                        <div (click)=\"decrement_hrs('start_hrs_tuesday')\" style=\"cursor: pointer;\">\n                                        <span class=\"fa fa-angle-down font-16 pt-1\"></span>\n                                        </div>\n                                    </div>\n                                    <div class=\"pt-4 mt-1\">\n                                      :\n                                    </div>\n                                    <div class=\"text-left\">\n                                        <div class=\"form-group text-center\">\n                                          <div (click)=\"increment_min('start_min_tuesday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                            <input style=\"background: #22283b!important;\" formControlName=\"start_min_tuesday\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                            <div (click)=\"decrement_min('start_min_tuesday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                        </div>\n                                    </div>\n                                    <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                      <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('tuesday_ampm')\">\n                                        {{this.editForm.get('tuesday_ampm').value==0?\"AM\":\"PM\"}}\n                                      </button>\n                                    </div>\n                                  </div>\n                                </td>\n                                <td style=\"background: #22273c!important;border-bottom: none\">\n                                  <div style=\"display:-webkit-inline-box\" >\n                                      <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_hrs('end_hrs_tuesday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                          <input style=\"background: #22283b!important;\" formControlName=\"end_hrs_tuesday\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control hofnumber\">\n                                          <div (click)=\"decrement_hrs('end_hrs_tuesday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                      </div>\n                                      <div class=\"pt-4 mt-1\">\n                                        :\n                                      </div>\n                                    <div class=\"text-left\">\n                                        <div class=\"form-group text-center\">\n                                          <div (click)=\"increment_min('end_min_tuesday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                            <input style=\"background: #22283b!important;\" formControlName=\"end_min_tuesday\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                            <div (click)=\"decrement_min('end_min_tuesday')\" style=\"cursor: pointer;\">\n                                              <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                        </div>\n                                    </div>\n                                    <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                      <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('tuesday_ampm_close')\">\n                                        {{this.editForm.get('tuesday_ampm_close').value==0?\"AM\":\"PM\"}}\n                                      </button>\n                                    </div>\n                                  </div>\n                                </td>\n                              </tr>\n\n                              <tr>\n                                <td style=\"background: #252c44!important;border-bottom: none\"> <span>Wednesday </span></td>\n                                <td style=\"background: #252c44!important;border-bottom: none\">\n                                  <label class=\"custom-switch mt-2 pl-0\">\n                                    <input type=\"checkbox\" (change)=\"wednesday_open($event)\" [checked]=\"wednesdayopen\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                                    <span class=\"custom-switch-indicator\"></span>\n                                  </label>\n                                </td>\n                                <td style=\"background: #252c44!important;border-bottom: none\">\n                                  <!-- <label>Opening Time (HH:MM)</label><br> -->\n                                    <div  style=\"display:-webkit-inline-box\" class=\"pt-2\">\n                                    <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_hrs('start_hrs_wednesday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-up font-16 \"></span>\n                                        </div>\n                                        <input style=\"background: #22283b!important;\" formControlName=\"start_hrs_wednesday\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control hofnumber\">\n                                        <div (click)=\"decrement_hrs('start_hrs_wednesday')\" style=\"cursor: pointer;\">\n                                        <span class=\"fa fa-angle-down font-16 pt-1\"></span>\n                                        </div>\n                                    </div>\n                                    <div class=\"pt-4 mt-1\">\n                                      :\n                                    </div>\n                                    <div class=\"text-left\">\n                                        <div class=\"form-group text-center\">\n                                          <div (click)=\"increment_min('start_min_wednesday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                            <input style=\"background: #22283b!important;\" formControlName=\"start_min_wednesday\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                            <div (click)=\"decrement_min('start_min_wednesday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                        </div>\n                                    </div>\n                                    <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                      <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('wednesday_ampm')\">\n                                        {{this.editForm.get('wednesday_ampm').value==0?\"AM\":\"PM\"}}\n                                      </button>\n                                    </div>\n                                  </div>\n                                </td>\n                                <td style=\"background: #252c44!important;border-bottom: none\">\n                                  <div style=\"display:-webkit-inline-box\" >\n                                      <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_hrs('end_hrs_wednesday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                          <input style=\"background: #22283b!important;\" formControlName=\"end_hrs_wednesday\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control hofnumber\">\n                                          <div (click)=\"decrement_hrs('end_hrs_wednesday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                      </div>\n                                      <div class=\"pt-4 mt-1\">\n                                        :\n                                      </div>\n                                    <div class=\"text-left\">\n                                        <div class=\"form-group text-center\">\n                                          <div (click)=\"increment_min('end_min_wednesday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                            <input style=\"background: #22283b!important;\" formControlName=\"end_min_wednesday\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                            <div (click)=\"decrement_min('end_min_wednesday')\" style=\"cursor: pointer;\">\n                                              <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                        </div>\n                                    </div>\n                                    <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                      <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('wednesday_ampm_close')\">\n                                        {{this.editForm.get('wednesday_ampm_close').value==0?\"AM\":\"PM\"}}\n                                      </button>\n                                    </div>\n                                  </div>\n                                </td>\n                              </tr>\n\n                              <tr>\n                                <td style=\"background: #22273c!important;border-bottom: none\"> <span>Thursday </span></td>\n                                <td style=\"background: #22273c!important;border-bottom: none\">\n                                  <label class=\"custom-switch mt-2 pl-0\">\n                                    <input type=\"checkbox\" (change)=\"thursday_open($event)\" [checked]=\"thursdayopen\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                                    <span class=\"custom-switch-indicator\"></span>\n                                  </label>\n                                </td>\n                                <td style=\"background: #22273c!important;border-bottom: none\">\n                                  <!-- <label>Opening Time (HH:MM)</label><br> -->\n                                    <div  style=\"display:-webkit-inline-box\" class=\"pt-2\">\n                                    <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_hrs('start_hrs_thursday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-up font-16 \"></span>\n                                        </div>\n                                        <input style=\"background: #22283b!important;\" formControlName=\"start_hrs_thursday\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control hofnumber\">\n                                        <div (click)=\"decrement_hrs('start_hrs_thursday')\" style=\"cursor: pointer;\">\n                                        <span class=\"fa fa-angle-down font-16 pt-1\"></span>\n                                        </div>\n                                    </div>\n                                    <div class=\"pt-4 mt-1\">\n                                      :\n                                    </div>\n                                    <div class=\"text-left\">\n                                        <div class=\"form-group text-center\">\n                                          <div (click)=\"increment_min('start_min_thursday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                            <input style=\"background: #22283b!important;\" formControlName=\"start_min_thursday\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                            <div (click)=\"decrement_min('start_min_thursday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                        </div>\n                                    </div>\n                                    <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                      <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('thursday_ampm')\">\n                                        {{this.editForm.get('thursday_ampm').value==0?\"AM\":\"PM\"}}\n                                      </button>\n                                    </div>\n                                  </div>\n                                </td>\n                                <td style=\"background: #22273c!important;border-bottom: none\">\n                                  <div style=\"display:-webkit-inline-box\" >\n                                      <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_hrs('end_hrs_thursday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                          <input style=\"background: #22283b!important;\" formControlName=\"end_hrs_thursday\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control hofnumber\">\n                                          <div (click)=\"decrement_hrs('end_hrs_thursday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                      </div>\n                                      <div class=\"pt-4 mt-1\">\n                                        :\n                                      </div>\n                                    <div class=\"text-left\">\n                                        <div class=\"form-group text-center\">\n                                          <div (click)=\"increment_min('end_min_thursday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                            <input style=\"background: #22283b!important;\" formControlName=\"end_min_thursday\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                            <div (click)=\"decrement_min('end_min_thursday')\" style=\"cursor: pointer;\">\n                                              <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                        </div>\n                                    </div>\n                                    <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                      <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('thursday_ampm_close')\">\n                                        {{this.editForm.get('thursday_ampm_close').value==0?\"AM\":\"PM\"}}\n                                      </button>\n                                    </div>\n                                  </div>\n                                </td>\n                              </tr>\n\n                              <tr>\n                                <td style=\"background: #252c44!important;border-bottom: none\"> <span>Friday</span></td>\n                                <td style=\"background: #252c44!important;border-bottom: none\">\n                                  <label class=\"custom-switch mt-2 pl-0\">\n                                    <input type=\"checkbox\" (change)=\"friday_open($event)\" [checked]=\"fridayopen\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                                    <span class=\"custom-switch-indicator\"></span>\n                                  </label>\n                                </td>\n                                <td style=\"background: #252c44!important;border-bottom: none\">\n                                  <!-- <label>Opening Time (HH:MM)</label><br> -->\n                                    <div  style=\"display:-webkit-inline-box\" class=\"pt-2\">\n                                    <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_hrs('start_hrs_friday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-up font-16 \"></span>\n                                        </div>\n                                        <input style=\"background: #22283b!important;\" formControlName=\"start_hrs_friday\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control hofnumber\">\n                                        <div (click)=\"decrement_hrs('start_hrs_friday')\" style=\"cursor: pointer;\">\n                                        <span class=\"fa fa-angle-down font-16 pt-1\"></span>\n                                        </div>\n                                    </div>\n                                    <div class=\"pt-4 mt-1\">\n                                      :\n                                    </div>\n                                    <div class=\"text-left\">\n                                        <div class=\"form-group text-center\">\n                                          <div (click)=\"increment_min('start_min_friday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                            <input style=\"background: #22283b!important;\" formControlName=\"start_min_friday\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                            <div (click)=\"decrement_min('start_min_friday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                        </div>\n                                    </div>\n                                    <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                      <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('friday_ampm')\">\n                                        {{this.editForm.get('friday_ampm').value==0?\"AM\":\"PM\"}}\n                                      </button>\n                                    </div>\n                                  </div>\n                                </td>\n                                <td style=\"background: #252c44!important;border-bottom: none\">\n                                  <div style=\"display:-webkit-inline-box\" >\n                                      <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_hrs('end_hrs_friday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                          <input style=\"background: #22283b!important;\" formControlName=\"end_hrs_friday\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control hofnumber\">\n                                          <div (click)=\"decrement_hrs('end_hrs_friday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                      </div>\n                                      <div class=\"pt-4 mt-1\">\n                                        :\n                                      </div>\n                                    <div class=\"text-left\">\n                                        <div class=\"form-group text-center\">\n                                          <div (click)=\"increment_min('end_min_friday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                            <input style=\"background: #22283b!important;\" formControlName=\"end_min_friday\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                            <div (click)=\"decrement_min('end_min_friday')\" style=\"cursor: pointer;\">\n                                              <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                        </div>\n                                    </div>\n                                    <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                      <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('friday_ampm_close')\">\n                                        {{this.editForm.get('friday_ampm_close').value==0?\"AM\":\"PM\"}}\n                                      </button>\n                                    </div>\n                                  </div>\n                                </td>\n                              </tr>\n\n                              <tr>\n                                <td style=\"background: #22273c!important;border-bottom: none\"> <span>Saturday </span></td>\n                                <td style=\"background: #22273c!important;border-bottom: none\">\n                                  <label class=\"custom-switch mt-2 pl-0\">\n                                    <input type=\"checkbox\" (change)=\"saturday_open($event)\" [checked]=\"saturdayopen\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                                    <span class=\"custom-switch-indicator\"></span>\n                                  </label>\n                                </td>\n                                <td style=\"background: #22273c!important;border-bottom: none\">\n                                  <!-- <label>Opening Time (HH:MM)</label><br> -->\n                                    <div  style=\"display:-webkit-inline-box\" class=\"pt-2\">\n                                    <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_hrs('start_hrs_saturday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-up font-16 \"></span>\n                                        </div>\n                                        <input style=\"background: #22283b!important;\" formControlName=\"start_hrs_saturday\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control hofnumber\">\n                                        <div (click)=\"decrement_hrs('start_hrs_saturday')\" style=\"cursor: pointer;\">\n                                        <span class=\"fa fa-angle-down font-16 pt-1\"></span>\n                                        </div>\n                                    </div>\n                                    <div class=\"pt-4 mt-1\">\n                                      :\n                                    </div>\n                                    <div class=\"text-left\">\n                                        <div class=\"form-group text-center\">\n                                          <div (click)=\"increment_min('start_min_saturday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                            <input style=\"background: #22283b!important;\" formControlName=\"start_min_saturday\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                            <div (click)=\"decrement_min('start_min_saturday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                        </div>\n                                    </div>\n                                    <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                      <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('saturday_ampm')\">\n                                        {{this.editForm.get('saturday_ampm').value==0?\"AM\":\"PM\"}}\n                                      </button>\n                                    </div>\n                                  </div>\n                                </td>\n                                <td style=\"background: #22273c!important;border-bottom: none\">\n                                  <div style=\"display:-webkit-inline-box\" >\n                                      <div class=\"form-group text-center\">\n                                        <div (click)=\"increment_hrs('end_hrs_saturday')\" style=\"cursor: pointer;\">\n                                          <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                          <input style=\"background: #22283b!important;\" formControlName=\"end_hrs_saturday\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control hofnumber\">\n                                          <div (click)=\"decrement_hrs('end_hrs_saturday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                      </div>\n                                      <div class=\"pt-4 mt-1\">\n                                        :\n                                      </div>\n                                    <div class=\"text-left\">\n                                        <div class=\"form-group text-center\">\n                                          <div (click)=\"increment_min('end_min_saturday')\" style=\"cursor: pointer;\">\n                                            <span class=\"fa fa-angle-up font-16 \"></span></div>\n                                            <input style=\"background: #22283b!important;\" formControlName=\"end_min_saturday\"   type=\"number\" min=\"0\" max=\"59\"  class=\"form-control hofnumber\">\n                                            <div (click)=\"decrement_min('end_min_saturday')\" style=\"cursor: pointer;\">\n                                              <span class=\"fa fa-angle-down font-16 pt-1\"></span></div>\n                                        </div>\n                                    </div>\n                                    <div class=\"mt-4\" *ngIf=\"is12or24==1\">\n                                      <button type=\"button\" class=\"ml-2 btn btn-primary btn-sm\" (click)=\"appm_change('saturday_ampm_close')\">\n                                        {{this.editForm.get('saturday_ampm_close').value==0?\"AM\":\"PM\"}}\n                                      </button>\n                                    </div>\n                                  </div>\n                                </td>\n                              </tr>\n                            </tbody>\n                            </table>\n                          </div>\n                      </div>\n                      <!-- <div class=\"col-md-1 mt-4 pt-3\"> -->\n\n                       <!-- <div class=\"control-group mt-2\">\n                        <label>Hours of Operation   </label>\n                         <select formControlName=\"hoursofoperation_start\" name=\"hoursofoperation_start\" id=\"hoursofoperation_start\" class=\"form-control\" [value]=\"''\">\n                           <option value=\"\">Select Start Day</option>\n                           <option value=\"Monday\">Monday</option>\n                           <option value=\"Tuesday\">Tuesday</option>\n                           <option value=\"Wednesday\">Wednesday</option>\n                           <option value=\"Thursday\">Thursday</option>\n                           <option value=\"Friday\">Friday</option>\n                           <option value=\"Saturday\">Saturday</option>\n                           <option value=\"Sunday\">Sunday</option>\n                         </select>\n                      </div> -->\n                      <!-- </div> -->\n                      <!-- <div class=\"col-md-2\">\n                       <div class=\"control-group mt-4 pt-2\">\n                         <select formControlName=\"hoursofoperation_end\" name=\"hoursofoperation_end\" id=\"hoursofoperation_end\" class=\"form-control\" [value]=\"''\">\n                           <option value=\"\">Select End Day</option>\n                           <option value=\"Monday\">Monday</option>\n                           <option value=\"Tuesday\">Tuesday</option>\n                           <option value=\"Wednesday\">Wednesday</option>\n                           <option value=\"Thursday\">Thursday</option>\n                           <option value=\"Friday\">Friday</option>\n                           <option value=\"Saturday\">Saturday</option>\n                           <option value=\"Sunday\">Sunday</option>\n                         </select>\n                      </div>\n                      </div> -->\n\n                      <!-- <div class=\"col-md-2 mt-2\">\n\n                    </div>\n\n                    <div class=\"col-md-2 mt-2\">\n                      <label>Closing Time (HH:MM)</label><br>\n\n                    </div>\n\n                    <div class=\"col-md-3 mt-2\"><br>\n\n                    </div> -->\n\n                    <!-- <div class=\"col-md-1\"><br><br>\n                      <input type=\"button\" (click)=\"addremoverow(0)\" value=\"+\" class=\"btn btn-info btn-sm\" *ngIf=\"isadded==0\">\n                    </div> -->\n                    </div>\n\n                    <!-- <div *ngIf=\"isadded==1\">\n                      <hr style=\"border-bottom: 1px solid #979DA6;\">\n                    <div class=\"row\">\n                      <div class=\"col-md-2\">\n                       <div class=\"control-group mt-2\">\n                        <label>Hours of Operation   </label>\n                         <select formControlName=\"hoursofoperation_start_1\" name=\"hoursofoperation_start_1\" id=\"hoursofoperation_start_1\" class=\"form-control\" [value]=\"''\">\n                           <option value=\"\">Select Start Day</option>\n                           <option value=\"Monday\">Monday</option>\n                           <option value=\"Tuesday\">Tuesday</option>\n                           <option value=\"Wednesday\">Wednesday</option>\n                           <option value=\"Thursday\">Thursday</option>\n                           <option value=\"Friday\">Friday</option>\n                           <option value=\"Saturday\">Saturday</option>\n                           <option value=\"Sunday\">Sunday</option>\n                         </select>\n                      </div>\n                      </div>\n                      <div class=\"col-md-2 mt-2\">\n                       <div class=\"control-group mt-4 pt-1\">\n                         <select formControlName=\"hoursofoperation_end_1\" name=\"hoursofoperation_end_1\" id=\"hoursofoperation_end_1\" class=\"form-control\" [value]=\"''\">\n                           <option value=\"\">Select End Day</option>\n                           <option value=\"Monday\">Monday</option>\n                           <option value=\"Tuesday\">Tuesday</option>\n                           <option value=\"Wednesday\">Wednesday</option>\n                           <option value=\"Thursday\">Thursday</option>\n                           <option value=\"Friday\">Friday</option>\n                           <option value=\"Saturday\">Saturday</option>\n                           <option value=\"Sunday\">Sunday</option>\n                         </select>\n                      </div>\n                      </div>\n\n                      <div class=\"col-md-2 mt-3\">\n                        <label>Opening Time (HH:MM)</label><br>\n                          <div  style=\"display:-webkit-inline-box\">\n                          <div class=\"form-group\">\n                              <input style=\"width:68px\" formControlName=\"start_hrs_1\" (change)=\"getTimetwohrs1($event)\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                          </div>\n                          <div class=\"pt-2\">\n                            :\n                          </div>\n                        <div class=\"text-left\">\n                            <div class=\"form-group\">\n                                <input style=\"width:68px\" formControlName=\"start_min_1\"  (change)=\"getTimetwomin1($event)\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                            </div>\n                        </div>\n                      </div>\n                    </div>\n\n                    <div class=\"col-md-2 mt-3\">\n                      <label>Closing Time (HH:MM)</label><br>\n                        <div  style=\"display:-webkit-inline-box\">\n                        <div class=\"form-group\">\n                            <input style=\"width:68px\" formControlName=\"end_hrs_1\" (change)=\"getTimetwohrs2($event)\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                        </div>\n                        <div class=\"pt-2\">\n                          :\n                        </div>\n                      <div class=\"text-left\">\n                          <div class=\"form-group\">\n                              <input style=\"width:68px\" formControlName=\"end_min_1\"  (change)=\"getTimetwomin2($event)\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                          </div>\n                      </div>\n                    </div>\n                    </div>\n\n                    <div class=\"col-md-3 mt-2\"><br>\n                      <select formControlName=\"timezone1\" class=\"form-control\" [value]=\"\">\n                        <option value=\"\">Select Timezone</option>\n                        <option value=\"{{item.id}}\" *ngFor=\"let item of alltimezone\">{{item.gmtzone}}</option>\n                      </select>\n                    </div>\n\n                    <div class=\"col-md-1\"><br><br>\n                      <input type=\"button\" (click)=\"addremoverow(1)\" value=\"-\" class=\"btn btn-danger btn-sm\">\n                    </div>\n\n                    </div>\n\n                    <div class=\"row mt-2\" >\n\n                    </div>\n                    </div> -->\n                    </fieldset>\n\n                  <!-- <fieldset class=\"scheduler-border\">\n                    <legend class=\"scheduler-border\">Hours</legend>\n                    <div class=\"row\">\n                      <div class=\"col-md-6\">\n                       <div class=\"control-group mt-2\">\n                        <label>Hours of Operation   </label>\n                         <select formControlName=\"hoursofoperation_start\" name=\"hoursofoperation_start\" id=\"hoursofoperation_start\" class=\"form-control\" [value]=\"''\">\n                           <option value=\"\">Select Start Day</option>\n                           <option value=\"Monday\">Monday</option>\n                           <option value=\"Tuesday\">Tuesday</option>\n                           <option value=\"Wednesday\">Wednesday</option>\n                           <option value=\"Thursday\">Thursday</option>\n                           <option value=\"Friday\">Friday</option>\n                           <option value=\"Saturday\">Saturday</option>\n                           <option value=\"Sunday\">Sunday</option>\n                         </select>\n                      </div>\n                      </div>\n                      <div class=\"col-md-5\">\n                       <div class=\"control-group mt-4 pt-2\">\n                         <select formControlName=\"hoursofoperation_end\" name=\"hoursofoperation_end\" id=\"hoursofoperation_end\" class=\"form-control\" [value]=\"''\">\n                           <option value=\"\">Select End Day</option>\n                           <option value=\"Monday\">Monday</option>\n                           <option value=\"Tuesday\">Tuesday</option>\n                           <option value=\"Wednesday\">Wednesday</option>\n                           <option value=\"Thursday\">Thursday</option>\n                           <option value=\"Friday\">Friday</option>\n                           <option value=\"Saturday\">Saturday</option>\n                           <option value=\"Sunday\">Sunday</option>\n                         </select>\n                      </div>\n                      </div>\n\n                    </div>\n\n                    <div class=\"row mt-2\">\n                      <div class=\"col-md-3\">\n                          <label>Opening Time (HH:MM)</label><br>\n                            <div  style=\"display:-webkit-inline-box\">\n                            <div class=\"form-group\">\n                                <input style=\"width:68px\" formControlName=\"start_hrs\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                            </div>\n                            <div class=\"pt-2\">\n                              :\n                            </div>\n                          <div class=\"text-left\">\n                              <div class=\"form-group\">\n                                  <input style=\"width:68px\" formControlName=\"start_min\"  type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                              </div>\n                          </div>\n                        </div> <br>\n                        <span style=\"color: #8080ff;\">Note: Please use 24 hours format</span>\n                      </div>\n\n                      <div class=\"col-md-3\">\n                        <label>Closing Time (HH:MM)</label><br>\n                          <div  style=\"display:-webkit-inline-box\">\n                          <div class=\"form-group\">\n                              <input style=\"width:68px\" formControlName=\"end_hrs\"  type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                          </div>\n                          <div class=\"pt-2\">\n                            :\n                          </div>\n                        <div class=\"text-left\">\n                            <div class=\"form-group\">\n                                <input style=\"width:68px\" formControlName=\"end_min\"  type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                            </div>\n                        </div>\n                      </div>\n                      </div>\n\n                      <div class=\"col-md-5\"><br>\n                        <select formControlName=\"timezone\" class=\"form-control\" [value]=\"\">\n                          <option value=\"\">Select Timezone</option>\n                          <option value=\"{{item.id}}\" *ngFor=\"let item of alltimezone\">{{item.gmtzone}}</option>\n                        </select>\n                      </div>\n\n                      <div class=\"col-md-1\"><br><br>\n                        <input type=\"button\" (click)=\"addremoverow(0)\" value=\"+\" class=\"btn btn-info btn-sm\" *ngIf=\"isadded==0\">\n                      </div>\n                    </div>\n\n                    <div *ngIf=\"isadded==1\">\n                      <hr style=\"border-bottom: 1px solid #979DA6;\">\n                    <div class=\"row\">\n                      <div class=\"col-md-6\">\n                       <div class=\"control-group mt-2\">\n                        <label>Hours of Operation   </label>\n                         <select formControlName=\"hoursofoperation_start_1\" name=\"hoursofoperation_start_1\" id=\"hoursofoperation_start_1\" class=\"form-control\" [value]=\"''\">\n                           <option value=\"\">Select Start Day</option>\n                           <option value=\"Monday\">Monday</option>\n                           <option value=\"Tuesday\">Tuesday</option>\n                           <option value=\"Wednesday\">Wednesday</option>\n                           <option value=\"Thursday\">Thursday</option>\n                           <option value=\"Friday\">Friday</option>\n                           <option value=\"Saturday\">Saturday</option>\n                           <option value=\"Sunday\">Sunday</option>\n                         </select>\n                      </div>\n                      </div>\n                      <div class=\"col-md-5\">\n                       <div class=\"control-group mt-4 pt-2\">\n                         <select formControlName=\"hoursofoperation_end_1\" name=\"hoursofoperation_end_1\" id=\"hoursofoperation_end_1\" class=\"form-control\" [value]=\"''\">\n                           <option value=\"\">Select End Day</option>\n                           <option value=\"Monday\">Monday</option>\n                           <option value=\"Tuesday\">Tuesday</option>\n                           <option value=\"Wednesday\">Wednesday</option>\n                           <option value=\"Thursday\">Thursday</option>\n                           <option value=\"Friday\">Friday</option>\n                           <option value=\"Saturday\">Saturday</option>\n                           <option value=\"Sunday\">Sunday</option>\n                         </select>\n                      </div>\n                      </div>\n\n                    </div>\n\n                    <div class=\"row mt-2\" >\n                      <div class=\"col-md-3\">\n                          <label>Opening Time (HH:MM)</label><br>\n                            <div  style=\"display:-webkit-inline-box\">\n                            <div class=\"form-group\">\n                                <input style=\"width:68px\" formControlName=\"start_hrs_1\" (change)=\"getTimetwohrs1($event)\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                            </div>\n                            <div class=\"pt-2\">\n                              :\n                            </div>\n                          <div class=\"text-left\">\n                              <div class=\"form-group\">\n                                  <input style=\"width:68px\" formControlName=\"start_min_1\" (change)=\"getTimetwomin1($event)\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                              </div>\n                          </div>\n                        </div>\n                      </div>\n\n                      <div class=\"col-md-3\">\n                        <label>Closing Time (HH:MM)</label><br>\n                          <div  style=\"display:-webkit-inline-box\">\n                          <div class=\"form-group\">\n                              <input style=\"width:68px\" formControlName=\"end_hrs_1\" (change)=\"getTimetwohrs2($event)\" type=\"number\" min=\"0\" max=\"23\"  class=\"form-control\">\n                          </div>\n                          <div class=\"pt-2\">\n                            :\n                          </div>\n                        <div class=\"text-left\">\n                            <div class=\"form-group\">\n                                <input style=\"width:68px\" formControlName=\"end_min_1\" (change)=\"getTimetwomin2($event)\" type=\"number\" min=\"0\" max=\"59\"  class=\"form-control\">\n                            </div>\n                        </div>\n                      </div>\n                      </div>\n\n                      <div class=\"col-md-5\"><br>\n                        <select formControlName=\"timezone1\" class=\"form-control\" [value]=\"\">\n                          <option value=\"\">Select Timezone</option>\n                          <option value=\"{{item.id}}\" *ngFor=\"let item of alltimezone\">{{item.gmtzone}}</option>\n                        </select>\n                      </div>\n\n                      <div class=\"col-md-1\"><br><br>\n                        <input type=\"button\" (click)=\"addremoverow(1)\" value=\"-\" class=\"btn btn-danger btn-sm\">\n                      </div>\n                    </div>\n                    </div>\n\n                    </fieldset> -->\n\n\n                    <fieldset class=\"scheduler-border\">\n                      <legend class=\"scheduler-border\">DTMF Settings</legend>\n                      <div class=\"row\">\n                       <div class=\"col-md-2\">\n                          <div class=\"control-group mt-2\">\n                            <div class=\"control-label\">DTMF Auto</div>\n                          </div>\n                       </div>\n                       <div class=\"col-md-2\">\n                        <label class=\"custom-switch mt-2 pl-0\">\n                          <input type=\"checkbox\" [checked]=\"dtmf_auto==true\" (change)=\"dtmf_auto_toggle($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                          <span class=\"custom-switch-indicator\"></span>\n                        </label>\n                       </div>\n                     </div>\n\n                     <div class=\"row mt-2\" *ngIf=\"dtmf_auto==true\">\n                       <div class=\"col-md-2\">\n                          <div class=\"control-group mt-3\">\n                            <div class=\"control-label\">DTMF Value</div>\n                          </div>\n                       </div>\n                       <div class=\"col-md-2 mt-4\">\n                         <div class=\"form-group\">\n                          <!-- <span class=\"currency currency-with-toggle ng-scope\">$</span> -->\n                          <input formControlName=\"dtmf_value\" type=\"text\" class=\"form-control formcontrol\" id=\"\">\n                        </div>\n                       </div>\n                     </div>\n\n                     <div class=\"row mt-2\" *ngIf=\"dtmf_auto==true\">\n                       <div class=\"col-md-2\">\n                          <div class=\"control-group mt-3\">\n                            <div class=\"control-label\">DTMF Interval (Seconds)</div>\n                          </div>\n                       </div>\n                       <div class=\"col-md-2 mt-4\">\n                         <div class=\"form-group\">\n                          <input formControlName=\"dtmf_interval\" type=\"text\" class=\"form-control formcontrol\" id=\"\">\n                        </div>\n                       </div>\n                     </div>\n\n                     <div class=\"row mt-2\" *ngIf=\"dtmf_auto==true\">\n                      <div class=\"col-md-2\">\n                         <div class=\"control-group mt-3\">\n                           <div class=\"control-label\">DTMF Percentage</div>\n                         </div>\n                      </div>\n                      <div class=\"col-md-2\">\n                        <div class=\"form-group\">\n                         <select formControlName=\"dtmf_percent\" class=\"form-control\">\n                           <!-- <option value=\"1\">10%</option>\n                           <option value=\"3\">25%</option>\n                           <option value=\"5\">50%</option>\n                           <option value=\"10\">100%</option> -->\n                          <option value=\"1\">10%</option>\n                          <option value=\"2\">20%</option>\n                          <option value=\"3\">30%</option>\n                          <option value=\"4\">40%</option>\n                          <option value=\"5\">50%</option>\n                          <option value=\"6\">60%</option>\n                          <option value=\"7\">70%</option>\n                          <option value=\"8\">80%</option>\n                          <option value=\"9\">90%</option>\n                          <option value=\"10\">100%</option>\n                         </select>\n                       </div>\n                      </div>\n                    </div>\n\n                    <div class=\"row mt-2\" *ngIf=\"dtmf_auto==true\">\n                      <div class=\"col-md-2\">\n                         <div class=\"control-group mt-3\">\n                           <div class=\"control-label\">Identify zipcode</div>\n                         </div>\n                      </div>\n                      <div class=\"col-md-2\">\n                        <label class=\"custom-switch mt-2 pl-0\">\n                          <input type=\"checkbox\" [checked]=\"dtmf_zipcode_enable==true\" (change)=\"dtmf_zipcode_enable_toggle($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                          <span class=\"custom-switch-indicator\"></span>\n                        </label>\n                       </div>\n                    </div>\n\n                    </fieldset>\n\n\n                    <fieldset class=\"scheduler-border\">\n                      <legend class=\"scheduler-border\">Cap Settings</legend>\n                      <div class=\"control-group mt-2\">\n                        <label>Cap On</label>\n                        <select formControlName=\"capon\" name=\"capon\" id=\"capon\" class=\"form-control\">\n                          <option value=\"0\">Conversion</option>\n                          <option value=\"1\">Connection</option>\n                          <option value=\"2\">Revenue</option>\n                        </select>\n                     </div>\n                     <div class=\"row\" *ngIf=\"this.editForm.get('capon').value!=2\">\n                       <div class=\"col-md-2\">\n                          <div class=\"control-group mt-2\">\n                            <div class=\"control-label\">Global Cap</div>\n                            <label class=\"custom-switch mt-2 pl-0\">\n                              <input type=\"checkbox\" [checked]=\"globalcap==true\" (change)=\"global_cap($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                              <span class=\"custom-switch-indicator\"></span>\n                            </label>\n                          </div>\n                       </div>\n                       <div class=\"col-md-2 mt-4\">\n                          <div class=\"form-group\" *ngIf=\"globalcap==true\">\n                            <span class=\"currency currency-with-toggle ng-scope\"><br/></span>\n                            <input formControlName=\"global_capvalue\" type=\"text\" class=\"form-control formcontrol\" id=\"\">\n                          </div>\n                          <div class=\"form-group mt-2\" *ngIf=\"globalcap!=true\">\n                            <span>None</span>\n                          </div>\n                       </div>\n                     </div>\n\n                     <div class=\"row\" *ngIf=\"this.editForm.get('capon').value==2\">\n                       <div class=\"col-md-2\">\n                          <div class=\"control-group mt-2\">\n                            <div class=\"control-label\">Global Revenue Cap</div>\n                            <label class=\"custom-switch mt-2 pl-0\">\n                              <input type=\"checkbox\" [checked]=\"global_revenuecap==true\" (change)=\"global_revenue_cap($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                              <span class=\"custom-switch-indicator\"></span>\n                            </label>\n                          </div>\n                       </div>\n                       <div class=\"col-md-2 mt-4\">\n                          <div class=\"form-group\" *ngIf=\"global_revenuecap==true\">\n                            <span class=\"currency currency-with-toggle ng-scope\">$</span>\n                            <input formControlName=\"global_revenuecapvalue\" type=\"text\" class=\"form-control formcontrol\" id=\"\">\n                          </div>\n                          <div class=\"form-group mt-2\" *ngIf=\"global_revenuecap!=true\">\n                            <span>None</span>\n                          </div>\n                       </div>\n                     </div>\n\n                     <div class=\"row\" *ngIf=\"this.editForm.get('capon').value==2\">\n                       <div class=\"col-md-2\">\n                          <div class=\"control-group mt-2\">\n                            <div class=\"control-label\" >Monthly Revenue Cap</div>\n                            <label class=\"custom-switch mt-2 pl-0\">\n                              <input type=\"checkbox\" [checked]=\"monthly_revenuecap==true\" (change)=\"monthly_revenue_cap($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                              <span class=\"custom-switch-indicator\"></span>\n                            </label>\n                          </div>\n                       </div>\n                       <div class=\"col-md-2 mt-4\">\n                          <div class=\"form-group\" *ngIf=\"monthly_revenuecap==true\">\n                            <span class=\"currency currency-with-toggle ng-scope\">$</span>\n                            <input formControlName=\"monthly_revenuecapvalue\" type=\"text\" class=\"form-control formcontrol\" id=\"\">\n                          </div>\n                          <div class=\"form-group mt-2\" *ngIf=\"monthly_revenuecap!=true\">\n                            <span>None</span>\n                          </div>\n                       </div>\n                     </div>\n\n                     <div class=\"row\" *ngIf=\"this.editForm.get('capon').value!=2\">\n                       <div class=\"col-md-2\">\n                          <div class=\"control-group mt-2\">\n                            <div class=\"control-label\" >Monthly Cap</div>\n                            <label class=\"custom-switch mt-2 pl-0\">\n                              <input type=\"checkbox\" [checked]=\"monthlycap==true\" (change)=\"monthly_cap($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                              <span class=\"custom-switch-indicator\"></span>\n                            </label>\n                          </div>\n                       </div>\n                       <div class=\"col-md-2 mt-4\">\n                          <div class=\"form-group\" *ngIf=\"monthlycap==true\">\n                            <span class=\"currency currency-with-toggle ng-scope\"><br/></span>\n                            <input formControlName=\"monthly_capvalue\" type=\"text\" class=\"form-control formcontrol\" id=\"\">\n                          </div>\n                          <div class=\"form-group mt-2\" *ngIf=\"monthlycap!=true\">\n                            <span>None</span>\n                          </div>\n                       </div>\n                     </div>\n\n                     <div class=\"row\" *ngIf=\"this.editForm.get('capon').value==2\">\n                       <div class=\"col-md-2\">\n                          <div class=\"control-group mt-2\">\n                            <div class=\"control-label\" >Daily Revenue Cap</div>\n                            <label class=\"custom-switch mt-2 pl-0\">\n                              <input type=\"checkbox\" [checked]=\"daily_revenuecap==true\" (change)=\"daily_revenue_cap($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                              <span class=\"custom-switch-indicator\"></span>\n                            </label>\n                          </div>\n                       </div>\n                       <div class=\"col-md-2 mt-4\">\n                          <div class=\"form-group\" *ngIf=\"daily_revenuecap==true\">\n                            <span class=\"currency currency-with-toggle ng-scope\">$</span>\n                            <input formControlName=\"daily_revenuecapvalue\" type=\"text\" class=\"form-control formcontrol\" id=\"\">\n                          </div>\n                          <div class=\"form-group mt-2\" *ngIf=\"daily_revenuecap!=true\">\n                            <span>None</span>\n                          </div>\n                       </div>\n                     </div>\n\n                     <div class=\"row\" *ngIf=\"this.editForm.get('capon').value!=2\">\n                       <div class=\"col-md-2\">\n                          <div class=\"control-group mt-2\">\n                            <div class=\"control-label\" >Daily Cap</div>\n                            <label class=\"custom-switch mt-2 pl-0\">\n                              <input type=\"checkbox\" [checked]=\"dailycap==true\" (change)=\"daily_cap($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                              <span class=\"custom-switch-indicator\"></span>\n                            </label>\n                          </div>\n                       </div>\n                       <div class=\"col-md-2 mt-4\">\n                          <div class=\"form-group\" *ngIf=\"dailycap==true\">\n                            <span class=\"currency currency-with-toggle ng-scope\"><br/></span>\n                            <input formControlName=\"daily_capvalue\" type=\"text\" class=\"form-control formcontrol\" id=\"\">\n                          </div>\n                          <div class=\"form-group mt-2\" *ngIf=\"dailycap!=true\">\n                            <span>None</span>\n                          </div>\n                       </div>\n                     </div>\n\n                     <div class=\"row\" *ngIf=\"this.editForm.get('capon').value==2\">\n                       <div class=\"col-md-2\">\n                          <div class=\"control-group mt-2\">\n                            <div class=\"control-label\">Hourly Revenue Cap</div>\n                            <label class=\"custom-switch mt-2 pl-0\">\n                              <input type=\"checkbox\" [checked]=\"hourly_revenuecap==true\"  (change)=\"hourly_revenue_cap($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                              <span class=\"custom-switch-indicator\"></span>\n                            </label>\n                          </div>\n                       </div>\n                       <div class=\"col-md-2 mt-4\">\n                          <div class=\"form-group\" *ngIf=\"hourly_revenuecap==true\">\n                            <span class=\"currency currency-with-toggle ng-scope\">$</span>\n                            <input formControlName=\"hourly_revenuecapvalue\" type=\"text\" class=\"form-control formcontrol\" id=\"\">\n                          </div>\n                          <div class=\"form-group mt-2\" *ngIf=\"hourly_revenuecap!=true\">\n                            <span>None</span>\n                          </div>\n                       </div>\n                     </div>\n\n                     <div class=\"row\" *ngIf=\"this.editForm.get('capon').value!=2\">\n                       <div class=\"col-md-2\">\n                          <div class=\"control-group mt-2\">\n                            <div class=\"control-label\">Hourly Cap</div>\n                            <label class=\"custom-switch mt-2 pl-0\">\n                              <input type=\"checkbox\" [checked]=\"hourlycap==true\"  (change)=\"hourly_cap($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                              <span class=\"custom-switch-indicator\"></span>\n                            </label>\n                          </div>\n                       </div>\n                       <div class=\"col-md-2 mt-4\">\n                          <div class=\"form-group\" *ngIf=\"hourlycap==true\">\n                            <span class=\"currency currency-with-toggle ng-scope\"><br/></span>\n                            <input formControlName=\"hourly_capvalue\" type=\"text\" class=\"form-control formcontrol\" id=\"\">\n                          </div>\n                          <div class=\"form-group mt-2\" *ngIf=\"hourlycap!=true\">\n                            <span>None</span>\n                          </div>\n                       </div>\n                     </div>\n\n                    </fieldset>\n\n                    <fieldset class=\"scheduler-border\">\n                      <legend class=\"scheduler-border\">Concurrency Settings</legend>\n\n                      <div class=\"row\">\n                        <div class=\"col-md-2\">\n                           <div class=\"control-group mt-2\">\n                             <div class=\"control-label\">Max Concurrency</div>\n                             <label class=\"custom-switch mt-2 pl-0\">\n                               <input type=\"checkbox\" [checked]=\"maxconcurrency==true\" (change)=\"get_maxcon($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                               <span class=\"custom-switch-indicator\"></span>\n                             </label>\n                           </div>\n                        </div>\n                        <div class=\"col-md-2 mt-4\">\n                           <div class=\"form-group\" *ngIf=\"maxconcurrency==true\">\n                             <input formControlName=\"maxconvalue\" type=\"text\" class=\"form-control formcontrolwithouticon\" id=\"\">\n                           </div>\n                           <div class=\"form-group mt-2\" *ngIf=\"maxconcurrency!=true\">\n                             <span>None</span>\n                           </div>\n                        </div>\n                      </div>\n\n                    </fieldset>\n\n\n                    <fieldset class=\"scheduler-border\">\n                      <legend class=\"scheduler-border\">Restrict Duplicate Calls Settings</legend>\n\n                      <div class=\"control-group mt-2\">\n                        <label>Restrict Duplicate</label>\n                        <select #restrictdup formControlName=\"restrictdup\" name=\"restrictdup\" id=\"restrictdup\" class=\"form-control\">\n                          <option value=\"0\">Buyer Settings (Do not Restrict)</option>\n                          <option value=\"1\">Do not Restrict</option>\n                          <option value=\"2\">By Campaign - Individual Target</option>\n                        </select>\n                     </div>\n                     <div *ngIf=\"restrictdup.value==2\">\n                     <div class=\"control-group mt-2\">\n                        <label>Restrict After</label>\n                        <select formControlName=\"restrictafter\" name=\"restrictafter\" id=\"restrictafter\" class=\"form-control\">\n                          <option value=\"0\">Converted</option>\n                          <option value=\"1\">Connected</option>\n                        </select>\n                     </div>\n                      <div class=\"control-group\">\n                          <label class=\"control-label input-label\" for=\"startTime\">Duration:</label>\n                          <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                          <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': settingToggleDurationvalue==0}\" (click)=\"settingToggleDuration(0)\">\n                                <input class=\"form-check-input\" name=\"settingToggleDuration\" formControlName=\"settingToggleDuration\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                                Always\n                          </label>\n                          <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': settingToggleDurationvalue==1}\" (click)=\"settingToggleDuration(1)\">\n                            <input class=\"form-check-input\" name=\"settingToggleDuration\" formControlName=\"settingToggleDuration\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                            Time Limit\n                          </label>\n                            </div>\n                     </div>\n                      <br>\n                      <div class=\"control-group row mt-2\" *ngIf=\"this.editForm.get('settingToggleDurationval').value==1\">\n                        <div class=\"col-md-1 mt-2\"><input  formControlName=\"days\" style=\"width: 80px;\" type=\"number\"  class=\"form-control formcontrol\" name=\"\" id=\"\"></div>\n                        <div class=\"col-md-1\"><span>Days</span></div>\n                      </div>\n                      </div>\n                    </fieldset>\n\n\n                    <fieldset class=\"scheduler-border\">\n                      <legend class=\"scheduler-border\">Publisher/Zip Tag Routing Filters</legend>\n                      <div class=\"row\" *ngIf=\"ispubfilter==0\">\n                        <div class=\"col-md-2 mt-2\">\n                          <input type=\"button\" (click)=\"ispubfilterselect()\" value=\"+ ADD FILTER\" class=\"btn btn-primary btn-sm\">\n                        </div>\n                      </div>\n\n\n                      <div  *ngIf=\"ispubfilter==1\" style=\"display: flex;flex-wrap: wrap;\">\n                        <div class=\"mt-2\" *ngFor=\"let item of filterselected;let i=index\" style=\"padding: 4px;\">\n                          <button type=\"button\" *ngIf=\"item.isorand==0 && i!=0\" class=\"btn btn-primary btn-sm\" style=\"font-size: 11px; margin-right: 7px;\">OR</button>\n                          <button type=\"button\" *ngIf=\"item.isorand==1 && i!=0\" class=\"btn btn-primary btn-sm\" style=\"font-size: 11px;margin-right: 7px;\">AND</button>\n                          <button type=\"button\" (click)=\"clearfilter(i)\" class=\"btn btn-secondary btn-sm\" style=\"font-size: 11px;    background: #232840;\n                          padding: 6px 12px;\n                          border: none;\">\n                            <span *ngIf=\"item.containfiltertype==0\">Filter - Name -</span> {{item.filterlabel}} - <small>{{item.containfiltertext}}</small>&nbsp;&nbsp; <b>{{item.name}}</b>&nbsp; <span class=\"fa fa-times\"></span>\n                            <span *ngIf=\"item.containfiltertype==1\">Filter - ID - {{item.filterlabel}} - <small>{{item.containfiltertext}}</small>&nbsp;&nbsp; <b>{{item.name}}</b>&nbsp; <span class=\"fa fa-times\"></span></span>\n                          </button>\n                        </div>\n                      </div>\n\n                      <div class=\"row\" *ngIf=\"ispubfilter==1\">\n                        <div class=\"col-md-2 mt-2\">\n                          <select formControlName=\"pubfiltertype\" class=\"form-control\" (change)=\"getpubfiltertype($event)\">\n                            <option value=\"0\">Filter - Name - Publisher</option>\n                            <option value=\"1\">Filter - ID - Publisher</option>\n                            <option value=\"2\">Filter - ID - Zipcode</option>\n                          </select>\n                        </div>\n                        <div class=\"col-md-2 mt-2\">\n                          <select [value]=\"0\" formControlName=\"pubiscontains\" class=\"form-control\">\n                            <option value=\"2\" >Contains</option>\n                            <option value=\"3\" >Does Not contain</option>\n                            <option value=\"4\" >Begins With</option>\n                            <option value=\"5\" >Does Not Begin With</option>\n                            <!-- <option value=\"6\" >Greater Than</option>\n                            <option value=\"7\" >Less Than</option>     -->\n                            <option value=\"0\" >Equals Single Value</option>\n                            <option value=\"1\" >Does Not Equal Single Value</option>\n                          </select>\n                        </div>\n                        <div class=\"col-md-3 mt-2\" >\n                          <angular2-multiselect  *ngIf=\"(this.editForm.get('pubiscontains').value==0 || this.editForm.get('pubiscontains').value==1) && this.editForm.get('pubfiltertype').value!=2\" [data]=\"allpublisher\" formControlName=\"pubvalue\" [settings]=\n                          \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select Publisher '}\" ></angular2-multiselect>\n\n                          <div class=\"form-group mt-2\" *ngIf=\"this.editForm.get('pubiscontains').value>1\">\n                            <input formControlName=\"pubvalue\" type=\"text\" class=\"form-control formcontrolwithouticon\" id=\"\">\n                          </div>\n\n                          <div class=\"form-group\" *ngIf=\"this.editForm.get('pubfiltertype').value==2\" >\n                            <angular2-multiselect *ngIf=\"this.editForm.get('pubiscontains').value==0 || this.editForm.get('pubiscontains').value==1\" [data]=\"allzipcode\" [(ngModel)]=\"selectedItemsZip\" formControlName=\"pubvalue\" [settings]=\n                            \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select File'}\" ></angular2-multiselect>\n                            <!-- <input type=\"file\" formControlName=\"pubvalue\"> -->\n                            <!-- <input formControlName=\"pubvalue\" type=\"text\" class=\"form-control formcontrolwithouticon\" id=\"\"> -->\n                          </div>\n\n                        </div>\n                        <div class=\"col-md-1 pt-3\" style=\"cursor: pointer\" *ngIf=\"this.editForm.get('pubfiltertype').value==2\" >\n                          <i data-toggle=\"modal\" data-target=\"#addZipcode\" class=\"fa fa-upload\" style=\"background: #0266c8;\n                          color: white;\n                          padding: 6px;\n                          border-radius: 5px;\"></i>\n                        </div>\n                        <div class=\"col-md-1 pt-2\">\n                          <input type=\"button\" (click)=\"ispubfilterclear()\" value=\"Clear\" class=\"btn btn-danger\">\n                        </div>\n                      </div>\n\n                      <div class=\"row mt-2\" *ngIf=\"ispubfilter==1\">\n                        <div class=\"col-md-12\">\n                          <button type=\"button\" style=\"width: 100px;font-size: 8px;height: 32px;background: #3858e7;border: none;\" (click)=\"addorrule()\" class=\"btn btn-primary btn-sm\"><i class=\"fa fa-plus\" style=\"font-size: 9px;\"></i>  OR RULE</button>\n                          <button type=\"button\" style=\"margin-left:5px;width: 100px;font-size: 8px;height: 32px;border: none;background: #3858e7;\" (click)=\"addandrule()\" class=\"btn btn-primary btn-sm\"><i class=\"fa fa-plus\" style=\"font-size: 9px;\"></i>  AND RULE</button>\n                        </div>\n                      </div>\n                    </fieldset>\n\n                    <fieldset class=\"scheduler-border\">\n                      <legend class=\"scheduler-border\">Tag Routing Filters</legend>\n                      <div class=\"row\" *ngIf=\"isfilter==0\">\n                        <div class=\"col-md-2 mt-2\">\n                          <input type=\"button\" (click)=\"isfilterselect()\" value=\"+ ADD FILTER\" class=\"btn btn-primary btn-sm\">\n                        </div>\n                      </div>\n                      <div class=\"row\" *ngIf=\"isfilter==1\">\n                        <div class=\"col-md-2 mt-2\">\n                          <label for=\"\">Select City/State</label>\n                          <select formControlName=\"citystatetype\" (change)=\"changetype($event)\" class=\"form-control\">\n                            <option value=\"0\">City</option>\n                            <option value=\"1\">States</option>\n                          </select>\n                        </div>\n                        <div class=\"col-md-2 mt-2\">\n                          <label for=\"\">Select Is Contains?</label>\n                          <select formControlName=\"iscontains\" (change)=\"changetype($event)\" class=\"form-control\">\n                            <option value=\"0\">Contains</option>\n                            <option value=\"1\">Not Contains</option>\n                          </select>\n                        </div>\n                        <div class=\"col-md-2 mt-2\" >\n                          <label for=\"\">Select State</label>\n                          <div *ngIf=\"this.editForm.get('citystatetype').value==1\">\n                            <angular2-multiselect  [data]=\"allcitystate\" formControlName=\"citystate\" [settings]=\n                            \"{enableSearchFilter: true,showCheckbox:false,singleSelection: false, text:'Select State '}\" ></angular2-multiselect>\n                          </div>\n                          <div *ngIf=\"this.editForm.get('citystatetype').value==0\">\n                            <select formControlName=\"citystate\" (change)='getdata()' class=\"form-control\">\n                              <option value=\"\">Select State</option>\n                              <option value=\"{{item.id}}\" *ngFor=\"let item of allcitystate\">{{item.text}}</option>\n                            </select>\n                          </div>\n                        </div>\n                          <div class=\"col-md-6 mt-2\" *ngIf=\"this.editForm.get('citystatetype').value==0\">\n                          <label for=\"\">Select City</label>\n                          <!-- <label for=\"\" *ngIf=\"this.editForm.get('citystate').value==1\">Select State</label> -->\n                          <!-- <select formControlName=\"citystate\" class=\"form-control\" [value]=\"0\">\n                            <option value=\"0\">City</option>\n                            <option value=\"1\">States</option>\n                          </select>      -->\n                          <angular2-multiselect [data]=\"allcity\" formControlName=\"cityval\" [settings]=\n                          \"{enableSearchFilter: true,showCheckbox:false,singleSelection: false, text:'Select City '}\"  ></angular2-multiselect>\n                          </div>\n                        <div class=\"col-md-2 mt-4 pt-3\">\n                          <input type=\"button\" (click)=\"isfilterclear()\" value=\"Clear\" class=\"btn btn-danger\">\n                        </div>\n                      </div>\n                    </fieldset>\n\n                  </div>\n                  <div class=\"card-footer text-right\">\n                        <button class=\"btn btn-primary mr-1\" type=\"submit\">Save Target</button>\n                        <button style=\"margin-right: 4px;\" routerLink=\"/target\" class=\"btn btn-primary\">Back To Target</button>\n                      </div>\n                </div>\n              </form>\n\n    </div>\n";

/***/ }),

/***/ 93268:
/*!*******************************************************************************************!*\
  !*** ./src/app/modules/numbers/blocked-numbers/blocked-numbers.component.html?ngResource ***!
  \*******************************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n\n<!-- Add Label Modal -->\n<div class=\"modal fade\" id=\"addLabels\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n aria-hidden=\"true\">\n <div class=\"modal-dialog\" role=\"document\">\n   <div class=\"modal-content\">\n     <div class=\"modal-header\">\n       <h5 class=\"modal-title\" id=\"formModal\">Block a Number</h5>\n       <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n         <span aria-hidden=\"true\">&times;</span>\n       </button>\n     </div>\n     <div class=\"modal-body\">\n       <form id=\"addLabel\" [formGroup]=\"addForm\" (ngSubmit)=\"onSubmit()\">\n      <div class=\"row\">\n        <div class=\"col-md-12\">\n          <fieldset class=\"scheduler-border\">\n            <legend class=\"scheduler-border\">Block Number</legend>\n            <div class=\"control-group\">\n                      <label class=\"control-label input-label\" for=\"startTime\">Block :</label>\n                      <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                          <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': block==0}\" (click)=\"block_numbertype(0)\">\n                            <input class=\"form-check-input\" name=\"block_type\" formControlName=\"block_type\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                            Number\n                          </label>\n                          <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': block==1}\" (click)=\"block_numbertype(1)\">\n                            <input class=\"form-check-input\" name=\"block_type\" formControlName=\"block_type\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                             Anonymous\n                          </label>\n                          <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': block==2}\" (click)=\"block_numbertype(2)\">\n                            <input class=\"form-check-input\" name=\"block_type\" formControlName=\"block_type\" type=\"radio\" id=\"option3\" [value]=\"2\">\n                             Prefix\n                          </label>\n                        </div>\n                        <div *ngIf=\"Submitted && labelcontrol.block_type.errors\" class=\"invalid-feedback\">\n                          <div *ngIf=\"labelcontrol.block_type.errors.required\">Block is required</div>\n                      </div>\n          </div>\n\n            <div *ngIf=\"block == 0\">\n                <div class=\"control-group mt-2\">\n                <label class=\"control-label input-label\">Enter Number  :</label>\n                <input type=\"text\" formControlName=\"blocked_number\" class=\"form-control\" placeholder=\"Enter Number\" aria-label=\"Enter Number\">\n                </div>\n           </div>\n            <div *ngIf=\"block == 2\">\n                <div class=\"control-group mt-2\">\n                <label class=\"control-label input-label numeric\">Enter Prefix  :</label>\n                <input type=\"text\" formControlName=\"blocked_prefix\" class=\"form-control\" placeholder=\"Enter Prefix\" aria-label=\"Enter Prefix\">\n                </div>\n           </div>\n\n           <div class=\"control-group mt-2\">\n            <label class=\"control-label input-label\" for=\"startTime\">Scope:</label>\n            <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': iscampaign==0}\" (click)=\"scopetype(0)\">\n                  <input class=\"form-check-input\" name=\"scope\" formControlName=\"scope\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                  All Campaign\n                </label>\n                <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': iscampaign==1}\" (click)=\"scopetype(1)\">\n                  <input class=\"form-check-input\" name=\"scope\" formControlName=\"scope\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                   Select Campaign\n                </label>\n              </div>\n              <div *ngIf=\"Submitted && labelcontrol.scope.errors\" class=\"invalid-feedback\">\n                <div *ngIf=\"labelcontrol.scope.errors.required\">Scope is required</div>\n              </div>\n            </div>\n\n           <div class=\"control-group mt-2\" *ngIf=\"iscampaign == 1\">\n            <label class=\"control-label input-label\">Campaign</label>\n               <select class=\"form-control\" formControlName=\"campaign_uuid\" [value]=\"''\">\n                 <option value=\"\">Select Campaign</option>\n                 <option [value]=\"item.id\" *ngFor=\"let item of allcampaign\">{{item.text}}</option>\n               </select>\n          </div>\n\n          <div class=\"form-group mt-2\">\n            <label  class=\"d-block\">Specify Duration :</label>\n            <label class=\"custom-switch mt-2 pl-0\">\n              <input type=\"checkbox\" (change)=\"isduration($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n              <span class=\"custom-switch-indicator\"></span>\n            </label>\n          </div>\n\n          <div *ngIf=\"isspecifyduration == 1\">\n            <div class=\"control-group mt-2\">\n            <label class=\"control-label input-label\">Enter Hours To block Number  :</label>\n            <input type=\"text\" formControlName=\"duration\" class=\"form-control\" placeholder=\"Enter Hours To block Number\" aria-label=\"Enter Hours To block Number\">\n            </div>\n           </div>\n\n          </fieldset>\n        </div>\n        </div>\n         <div class=\"modal-footer\" style=\"padding: 0;\">\n            <button (click)=\"closeModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Block Number</button>\n            <button  type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\">Reset</button>\n           </div>\n       </form>\n     </div>\n   </div>\n </div>\n </div>\n\n<!-- Edit Label Modal -->\n<div class=\"modal  fade\" id=\"editLabels\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n aria-hidden=\"true\">\n <div class=\"modal-dialog\" role=\"document\">\n   <div class=\"modal-content\">\n     <div class=\"modal-header\">\n       <h5 class=\"modal-title\" id=\"formModal\">Update Blocked Numbers</h5>\n       <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n         <span aria-hidden=\"true\">&times;</span>\n       </button>\n     </div>\n     <div class=\"modal-body\">\n       <form [formGroup]=\"editForm\" (ngSubmit)=\"onEditSubmit()\">\n        <div class=\"row\">\n            <div class=\"col-md-12\">\n              <fieldset class=\"scheduler-border\">\n                <legend class=\"scheduler-border\">Block Number</legend>\n                <div class=\"control-group\">\n                          <input type=\"hidden\" formControlName=\"uuid\">\n                          <label class=\"control-label input-label\" for=\"startTime\">Block:</label>\n                          <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                              <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editblock==0}\" (click)=\"editblock_numbertype(0)\">\n                                <input class=\"form-check-input\" name=\"editblock_type\" formControlName=\"editblock_type\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                                Number\n                              </label>\n                              <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editblock==1}\" (click)=\"editblock_numbertype(1)\">\n                                <input class=\"form-check-input\" name=\"editblock_type\" formControlName=\"editblock_type\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                                 Anonymous\n                              </label>\n                              <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editblock==2}\" (click)=\"editblock_numbertype(2)\">\n                                <input class=\"form-check-input\" name=\"editblock_type\" formControlName=\"editblock_type\" type=\"radio\" id=\"option3\" [value]=\"2\">\n                                 Prefix\n                              </label>\n                            </div>\n                            <div *ngIf=\"Submitted && labelcontrol.block_type.errors\" class=\"invalid-feedback\">\n                              <div *ngIf=\"labelcontrol.block_type.errors.required\">Block is required</div>\n                          </div>\n              </div>\n                <div *ngIf=\"editblock == 0\">\n                    <div class=\"control-group mt-2\">\n                    <label class=\"control-label input-label\">Enter Number  :</label>\n                    <input type=\"text\" formControlName=\"blocked_number\" class=\"form-control\" placeholder=\"Enter Number\" aria-label=\"Enter Number\">\n                    </div>\n               </div>\n                <div *ngIf=\"editblock == 2\">\n                    <div class=\"control-group mt-2\">\n                    <label class=\"control-label input-label numeric\">Enter Prefix  :</label>\n                    <input type=\"text\" formControlName=\"blocked_prefix\" class=\"form-control\" placeholder=\"Enter Prefix\" aria-label=\"Enter Prefix\">\n                    </div>\n               </div>\n\n               <div class=\"control-group mt-2\">\n                <label class=\"control-label input-label\" for=\"startTime\">Scope:</label>\n                <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                    <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editiscampaign==0}\" (click)=\"editscopetype(0)\">\n                      <input class=\"form-check-input\" name=\"scope\" formControlName=\"scope\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                      All Campaign\n                    </label>\n                    <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editiscampaign==1}\" (click)=\"editscopetype(1)\">\n                      <input class=\"form-check-input\" name=\"scope\" formControlName=\"scope\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                       Select Campaign\n                    </label>\n                  </div>\n                  <div *ngIf=\"Submitted && labelcontrol.scope.errors\" class=\"invalid-feedback\">\n                    <div *ngIf=\"labelcontrol.scope.errors.required\">Scope is required</div>\n                  </div>\n                </div>\n\n               <div class=\"control-group mt-2\" *ngIf=\"editiscampaign == 1\">\n                <label class=\"control-label input-label\">Campaign</label>\n                   <select class=\"form-control\" formControlName=\"campaign_uuid\" [value]=\"''\">\n                     <option value=\"\">Select Campaign</option>\n                     <option [value]=\"item.id\" *ngFor=\"let item of allcampaign\">{{item.text}}</option>\n                   </select>\n              </div>\n\n              <div class=\"form-group mt-2\">\n                <label  class=\"d-block\">Specify Duration :</label>\n                <label class=\"custom-switch mt-2 pl-0\">\n                  <input [checked]=\"editisspecifyduration==1\" type=\"checkbox\" (change)=\"isduration($event)\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                  <span class=\"custom-switch-indicator\"></span>\n                </label>\n              </div>\n\n              <div *ngIf=\"editisspecifyduration == 1\">\n                <div class=\"control-group mt-2\">\n                <label class=\"control-label input-label\">Enter Hours To block Number  :</label>\n                <input type=\"text\" formControlName=\"duration\" class=\"form-control\" placeholder=\"Enter Hours To block Number\" aria-label=\"Enter Hours To block Number\">\n                </div>\n               </div>\n\n              </fieldset>\n            </div>\n            </div>\n         <div class=\"modal-footer\" style=\"padding: 0;\">\n            <button (click)=\"editcloseModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Update</button>\n            <button type=\"button\" class=\"btn btn-secondary m-t-15 waves-effect\" data-dismiss=\"modal\" aria-label=\"Close\">\n              Close\n            </button>\n           </div>\n       </form>\n     </div>\n   </div>\n </div>\n </div>\n\n  <div class=\"main-content\">\n\n    <section class=\"section\">\n      <div class=\"section-body\">\n        <div class=\"row\">\n          <div class=\"col-12\">\n            <div class=\"card\">\n                <div class=\"row\">\n                    <div class=\"col-4\">\n                        <div class=\"card-header\">\n                        <h4>Block a Number</h4></div>\n                    </div>\n                    <div class=\"col-8 text-right mt-2\">\n                        <div class=\"form-group\" style=\"margin-right: 28px;padding: 3px;font-size: 14px;\">\n                           <button type=\"button\" data-toggle=\"modal\" data-target=\"#addLabels\" class=\"btn btn-primary daterange-btn icon-left btn-sm btn-icon mr-2 p-2\"><i class=\"fa fa-plus\"></i> Block Number\n                            </button>\n                            <!-- <button type=\"button\" (click)=\"exportdata()\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-2\"><i class=\"fas fa-file-export\"></i> Export\n                            </button>\n                            <button [disabled]=\"ischecked === '1'\" (click)=\"onDeleteSubmit()\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-2\"><i class=\"fas fa-file-export\"></i> Delete Selected\n                            </button> -->\n                          </div>\n                    </div>\n                </div>\n\n              <div class=\"card-body\">\n                <div class=\"table-responsive\">\n                <table #dataTable class=\"table table-striped dataTable no-footer row-border hover\" style=\"width: 100%;\">\n                    <thead>\n                      <tr>\n                        <!-- <th style=\"padding: 10px;\">\n                            <div class=\"custom-control custom-checkbox\" *ngIf=\"blocknumbers?.length != 0\">\n                            <input type=\"checkbox\" class=\"custom-control-input\" id=\"customCheck1\" (change)=\"checkalldelete($event)\" (click)=\"deleteselected($event)\">\n                            <label class=\"custom-control-label\" for=\"customCheck1\"></label>\n                            </div>\n                        </th> -->\n                        <th>Blocked Number</th>\n                        <th>Campaign</th>\n                        <th>Blocked Until(Hrs)</th>\n                        <th>Created Date</th>\n                        <th>Action</th>\n                      </tr>\n                    </thead>\n                    <tbody *ngIf=\"blocknumbers?.length != 0\" >\n                        <tr *ngFor=\"let data of blocknumbers;let i=index\">\n                            <!-- <td>\n                                <div class=\"custom-control custom-checkbox\">\n                                <input type=\"checkbox\" (click)=\"deleteselected($event)\" class=\"custom-control-input\" id=\"customCheck_{{data.uuid}}\"  [checked]=\"data.selected\" [value]=\"data.id\" >\n                                <label class=\"custom-control-label\" for=\"customCheck_{{data.uuid}}\"></label>\n                                </div>\n                            </td> -->\n                            <td><a (click)=\"editdata(data.uuid,data.block_type,data.blocked_number,data.blocked_prefix,data.scope,data.campaign_uuid,data.is_duration,data.blocked_until)\" data-toggle=\"modal\" data-target=\"#editLabels\" class=\"text-white actionedit\">{{ data.blocked_number }}</a></td>\n                            <td>{{ data.campaign }}</td>\n                            <td>{{ data.blocked_until }}</td>\n                            <td>{{ data.created_at }}</td>\n                            <td class=\"d-flex\" style=\"cursor:pointer;\"><div (click)=\"editdata(data.uuid,data.block_type,data.blocked_number,data.blocked_prefix,data.scope,data.campaign_uuid,data.is_duration,data.blocked_until)\" data-toggle=\"modal\" data-target=\"#editLabels\" class=\"actionedit\"><i class=\"far fa-edit\"></i></div>&nbsp;&nbsp;&nbsp;<div (click)=\"Delete((data.uuid))\" class=\"actiondelete\"><i class=\"fas fa-trash\"></i></div></td>\n                        </tr>\n                    </tbody>\n                    <tbody *ngIf=\"blocknumbers?.length == 0\">\n                      <tr>\n                        <td colspan=\"8\" class=\"no-data-available\">No data Available!</td>\n                      </tr>\n                    <tbody>\n                  </table>\n                </div>\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n    </section>\n\n  </div>\n";

/***/ }),

/***/ 47562:
/*!***********************************************************************************!*\
  !*** ./src/app/modules/numbers/number-pool/number-pool.component.html?ngResource ***!
  \***********************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "  <!-- Add  Modal -->\n  <div class=\"modal fade\" id=\"addModel\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n  aria-hidden=\"true\">\n  <div class=\"modal-dialog model-lg\" role=\"document\">\n    <div class=\"modal-content\">\n      <div class=\"modal-header\">\n        <h5 class=\"modal-title\" id=\"formModal\">Create Number Pool</h5>\n        <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n          <span aria-hidden=\"true\">&times;</span>\n        </button>\n      </div>\n      <div class=\"modal-body\">\n        <form id=\"addLabel\" [formGroup]=\"addForm\" (ngSubmit)=\"onSubmit()\">\n          <div class=\"row\">\n            <div class=\"col-md-12\">\n          <div class=\"form-group\">\n              <label>Country</label>\n              <select formControlName=\"country_id\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && addformcontrol.country_id.errors }\" [value]=\"''\">\n                <option value=\"\">Select Country</option>\n                <option value=\"United States\">United States</option>\n              </select>\n              <div *ngIf=\"Submitted && addformcontrol.country_id.errors\" class=\"invalid-feedback\">\n                  <div *ngIf=\"addformcontrol.country_id.errors.required\">Country is required</div>\n              </div>\n           </div>\n\n           <div class=\"row\">\n            <div class=\"col-md-12\">\n              <div class=\"form-group\">\n                <label  class=\"d-block\">Name :</label>\n                <input formControlName=\"name\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && addformcontrol.name.errors }\">\n              </div>\n              <div *ngIf=\"Submitted && addformcontrol.name.errors\" class=\"invalid-feedback\">\n                <div *ngIf=\"addformcontrol.name.errors.required\">Name is required</div>\n              </div>\n            </div>\n          </div>\n\n          <div class=\"row\">\n            <div class=\"col-md-12\">\n              <div class=\"form-group\">\n                <label  class=\"d-block\">Closed Browser Delay :</label>\n                <input formControlName=\"closed_browser_delay\" placeholder=\"30\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && addformcontrol.closed_browser_delay.errors }\">\n              </div>\n              <div *ngIf=\"Submitted && addformcontrol.closed_browser_delay.errors\" class=\"invalid-feedback\">\n                <div *ngIf=\"addformcontrol.closed_browser_delay.errors.required\">Closed Browser Delay is required</div>\n              </div>\n            </div>\n          </div>\n\n          <div class=\"row\">\n            <div class=\"col-md-12\">\n              <div class=\"form-group\">\n                <label  class=\"d-block\">Idle Limit :</label>\n                <input formControlName=\"browser_idle_limit\" placeholder=\"300\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && addformcontrol.browser_idle_limit.errors }\">\n              </div>\n              <div *ngIf=\"Submitted && addformcontrol.browser_idle_limit.errors\" class=\"invalid-feedback\">\n                <div *ngIf=\"addformcontrol.browser_idle_limit.errors.required\">Idle Limit is required</div>\n              </div>\n            </div>\n          </div>\n\n          <div class=\"row\">\n            <div class=\"col-md-12\">\n              <div class=\"form-group\">\n                <label  class=\"d-block\">Pool Size :</label>\n                <input formControlName=\"poolsize\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && addformcontrol.poolsize.errors }\">\n              </div>\n              <div *ngIf=\"Submitted && addformcontrol.poolsize.errors\" class=\"invalid-feedback\">\n                <div *ngIf=\"addformcontrol.poolsize.errors.required\">Pool Size is required</div>\n              </div>\n            </div>\n          </div>\n\n           <div class=\"form-group\">\n            <div class=\"control-group\">\n                <label class=\"control-label input-label\" for=\"startTime\">Number Type:</label>\n                <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': numberTypeadd==0}\" (click)=\"numberTypeval(0)\">\n                      <input class=\"form-check-input\" name=\"allocating\" formControlName=\"allocating\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                      Toll Free\n                    </label>\n                    <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': numberTypeadd==1}\" (click)=\"numberTypeval(1)\">\n                      <input class=\"form-check-input\" name=\"allocating\" formControlName=\"allocating\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                       Local\n                    </label>\n                  </div>\n            </div>\n          </div>\n           </div>\n       </div>\n          <div class=\"modal-footer\" style=\"padding: 0;\">\n             <button (click)=\"closeModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Create Number Pool</button>\n             <button  type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\">Reset</button>\n            </div>\n        </form>\n      </div>\n    </div>\n  </div>\n  </div>\n\n\n  <div class=\"modal fade\" id=\"editModel\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n  aria-hidden=\"true\">\n  <div class=\"modal-dialog model-lg\" role=\"document\">\n    <div class=\"modal-content\">\n      <div class=\"modal-header\">\n        <h5 class=\"modal-title\" id=\"formModal\">Update Number</h5>\n        <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n          <span aria-hidden=\"true\">&times;</span>\n        </button>\n      </div>\n      <div class=\"modal-body\">\n        <form id=\"editLabel\" [formGroup]=\"editForm\" (ngSubmit)=\"onEditSubmit()\">\n          <div class=\"row\">\n            <div class=\"col-md-12\">\n          <div class=\"form-group\">\n              <label>Country</label>\n              <input type=\"hidden\" name=\"uuid\" formControlName=\"uuid\" >\n              <select formControlName=\"country_id\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': editSubmitted && editFormcontrol.country_id.errors }\" [value]=\"''\">\n                <option value=\"\">Select Country</option>\n                <option value=\"United States\">United States</option>\n              </select>\n              <div *ngIf=\"editSubmitted && editFormcontrol.country_id.errors\" class=\"invalid-feedback\">\n                  <div *ngIf=\"editFormcontrol.country_id.errors.required\">Country is required</div>\n              </div>\n           </div>\n\n           <div class=\"row\">\n            <div class=\"col-md-12\">\n              <div class=\"form-group\">\n                <label  class=\"d-block\">Name :</label>\n                <input formControlName=\"name\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': editSubmitted && editFormcontrol.name.errors }\">\n              </div>\n              <div *ngIf=\"editSubmitted && editFormcontrol.name.errors\" class=\"invalid-feedback\">\n                <div *ngIf=\"editFormcontrol.name.errors.required\">Name is required</div>\n              </div>\n            </div>\n          </div>\n\n          <div class=\"row\">\n            <div class=\"col-md-12\">\n              <div class=\"form-group\">\n                <label  class=\"d-block\">Closed Browser Delay :</label>\n                <input formControlName=\"closed_browser_delay\" placeholder=\"30\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': editSubmitted && editFormcontrol.closed_browser_delay.errors }\">\n              </div>\n              <div *ngIf=\"editSubmitted && editFormcontrol.closed_browser_delay.errors\" class=\"invalid-feedback\">\n                <div *ngIf=\"editFormcontrol.closed_browser_delay.errors.required\">Closed Browser Delay is required</div>\n              </div>\n            </div>\n          </div>\n\n          <div class=\"row\">\n            <div class=\"col-md-12\">\n              <div class=\"form-group\">\n                <label  class=\"d-block\">Idle Limit :</label>\n                <input formControlName=\"browser_idle_limit\" placeholder=\"300\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': editSubmitted && editFormcontrol.browser_idle_limit.errors }\">\n              </div>\n              <div *ngIf=\"editSubmitted && editFormcontrol.browser_idle_limit.errors\" class=\"invalid-feedback\">\n                <div *ngIf=\"editFormcontrol.browser_idle_limit.errors.required\">Idle Limit is required</div>\n              </div>\n            </div>\n          </div>\n\n          <div class=\"row\">\n            <div class=\"col-md-12\">\n              <div class=\"form-group\">\n                <label  class=\"d-block\">Pool Size :</label>\n                <input formControlName=\"poolsize\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': editSubmitted && editFormcontrol.poolsize.errors }\">\n              </div>\n              <div *ngIf=\"editSubmitted && editFormcontrol.poolsize.errors\" class=\"invalid-feedback\">\n                <div *ngIf=\"editFormcontrol.poolsize.errors.required\">Pool Size is required</div>\n              </div>\n            </div>\n          </div>\n\n           <div class=\"form-group\">\n            <div class=\"control-group\">\n                <label class=\"control-label input-label\" for=\"startTime\">Number Type:</label>\n                <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': numberTypeadd==0}\" (click)=\"numberTypeval(0)\">\n                      <input class=\"form-check-input\" name=\"allocating\" formControlName=\"allocating\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                      Toll Free\n                    </label>\n                    <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': numberTypeadd==1}\" (click)=\"numberTypeval(1)\">\n                      <input class=\"form-check-input\" name=\"allocating\" formControlName=\"allocating\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                       Local\n                    </label>\n                  </div>\n            </div>\n          </div>\n\n           </div>\n       </div>\n          <div class=\"modal-footer\" style=\"padding: 0;\">\n             <button (click)=\"closeEditModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Update Number Pool</button>\n             <button  type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\">Reset</button>\n            </div>\n        </form>\n      </div>\n    </div>\n  </div>\n  </div>\n\n\n\n  <div class=\"main-content\">\n    <section class=\"section\">\n      <div class=\"section-body\">\n        <div class=\"row\">\n          <div class=\"col-12\">\n            <div class=\"card\">\n                <div class=\"row\">\n                    <div class=\"col-3\">\n                        <div class=\"card-header\">\n                        <h4>Manage Pools</h4></div>\n                    </div>\n                    <div class=\"col-9 text-right mt-2\">\n                        <div class=\"form-group\"  style=\"margin-right: 28px;padding: 3px;font-size: 14px;\">\n                          <button  data-toggle=\"modal\" data-target=\"#addModel\"  class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-1\"><i class=\"fa fa-plus\"></i> Create Number Pool\n                          </button>\n                          <button [disabled]=\"ischecked === '1'\" (click)=\"onDeleteSubmit()\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-2\"><i class=\"fas fa-file-export\"></i> Delete Selected\n                          </button>\n                          </div>\n                    </div>\n\n                </div>\n              <div class=\"card-body\">\n                <div class=\"table-responsive\">\n                <table #dataTable class=\"table table-striped dataTable no-footer row-border hover\" style=\"width: 100%;\">\n                    <thead>\n                      <tr>\n                        <th style=\"padding: 10px;width: 1px;\">\n                            <div class=\"custom-control custom-checkbox\" *ngIf=\"numbers?.length != 0\">\n                            <input type=\"checkbox\" class=\"custom-control-input\" id=\"customCheck1\" (change)=\"checkalldelete($event)\" (click)=\"deleteselected($event)\">\n                            <label class=\"custom-control-label\" for=\"customCheck1\"></label>\n                            </div>\n                        </th>\n                        <th>Name</th>\n                        <th>Country</th>\n                        <th>Closed Browser Delay</th>\n                        <th>Browser Idle Limit</th>\n                        <th>Pool Size</th>\n                        <th>Allocating</th>\n                        <th>Action</th>\n                      </tr>\n                    </thead>\n                    <tbody *ngIf=\"numbers?.length != 0\">\n                        <tr *ngFor=\"let number of numbers\">\n                              <td>\n                                <div class=\"custom-control custom-checkbox\">\n                                <input type=\"checkbox\" (click)=\"deleteselected($event)\" class=\"custom-control-input\" id=\"customCheck_{{number.uuid}}\"  [checked]=\"number.selected\" [value]=\"number.id\" >\n                                <label class=\"custom-control-label\" for=\"customCheck_{{number.uuid}}\"></label>\n                                </div>\n                            </td>\n\n                            <td><a href=\"#\" (click)=\"editdata(number.uuid,number.name,number.country_id,number.closed_browser_delay,number.browser_idle_limit,number.poolsize,number.allocating)\"  data-toggle=\"modal\" data-target=\"#editModel\" class=\"text-white actionedit\">{{ number.name }}</a></td>\n                            <td>{{ number.country_id }}</td>\n                            <td>{{ number.closed_browser_delay }}</td>\n                            <td>{{ number.browser_idle_limit }}</td>\n                            <td>{{ number.poolsize }}</td>\n                            <td *ngIf=\"number.allocating==0\"><div class=\"badge badge-primary\">Toll Free</div> </td>\n                            <td *ngIf=\"number.allocating==1\"><div class=\"badge badge-primary\">Local</div> </td>\n                            <td class=\"d-flex\" style=\"cursor:pointer;\"><a href=\"#\" (click)=\"editdata(number.uuid,number.name,number.country_id,number.closed_browser_delay,number.browser_idle_limit,number.poolsize,number.allocating)\"  data-toggle=\"modal\" data-target=\"#editModel\" class=\"actionedit\"><i class=\"far fa-edit\"></i></a>&nbsp;&nbsp;&nbsp;<div (click)=\"Delete((number.uuid))\" class=\" actiondelete\"><i class=\"fas fa-trash\"></i></div></td>\n                        </tr>\n                    </tbody>\n                    <tbody *ngIf=\"numbers?.length == 0\">\n                      <tr>\n                        <td colspan=\"8\" class=\"no-data-available\">No data Available!</td>\n                      </tr>\n                    <tbody>\n                  </table>\n                </div>\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n    </section>\n\n  </div>\n";

/***/ }),

/***/ 15514:
/*!*******************************************************************!*\
  !*** ./src/app/modules/numbers/numbers.component.html?ngResource ***!
  \*******************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "<div *ngIf=\"showLoadingIndicator\">\n  <div class=\"loader\"></div>\n</div>\n<!-- Add  Modal -->\n  <div class=\"modal fade\" id=\"addModel\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n  aria-hidden=\"true\">\n  <div class=\"modal-dialog model-lg\" role=\"document\">\n    <div class=\"modal-content\">\n      <div class=\"modal-header\">\n        <h5 class=\"modal-title\" id=\"formModal\">Create Number</h5>\n        <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n          <span aria-hidden=\"true\">&times;</span>\n        </button>\n      </div>\n      <div class=\"modal-body\">\n        <form id=\"addLabel\" [formGroup]=\"addForm\" (ngSubmit)=\"onSubmit()\">\n          <div class=\"row\">\n            <div class=\"col-md-12\">\n          <div class=\"form-group\">\n              <label>Country</label>\n              <select formControlName=\"country\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && addformcontrol.country.errors }\" [value]=\"''\" (change)=\"addprefix($event.target.value)\">\n                <option value=\"\">Select Country</option>\n                <option value=\"United States\">United States</option>\n                <option value=\"United Kingdom\">United Kingdom</option>\n              </select>\n              <div *ngIf=\"Submitted && addformcontrol.country.errors\" class=\"invalid-feedback\">\n                  <div *ngIf=\"addformcontrol.country.errors.required\">Country is required</div>\n              </div>\n           </div>\n\n           <div class=\"form-group\">\n            <div class=\"control-group\">\n                <label class=\"control-label input-label\" for=\"startTime\">Number Type:</label>\n                <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': numberTypeadd==0}\" (click)=\"numberTypeval(0)\">\n                      <input class=\"form-check-input\" name=\"numberType\" formControlName=\"numberType\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                      Toll Free\n                    </label>\n                    <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': numberTypeadd==1}\" (click)=\"numberTypeval(1)\">\n                      <input class=\"form-check-input\" name=\"numberType\" formControlName=\"numberType\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                       Local\n                    </label>\n                  </div>\n            </div>\n          </div>\n\n            <!-- <div class=\"row\">\n              <div class=\"col-md-12\">\n                <div class=\"form-group\">\n                  <label  class=\"d-block\">Select Number/Purchase Number :</label>\n                  <select #numbertype class=\"form-control\" formControlName=\"select_numbertype\" [value]=\"0\" (change)=\"purchase_number($event.target.value)\">\n                    <option value=\"0\">Enter Number</option>\n                    <option value=\"1\">Purchase Number</option>\n                  </select>\n                </div>\n              </div>\n            </div>            -->\n            <!-- {{numbertype.value}} -->\n            <div class=\"row\">\n              <div class=\"col-md-6\">\n                <div class=\"form-group\">\n                  <label  class=\"d-block\">Prefix :</label>\n                  <input formControlName=\"prefix\" type=\"text\" class=\"form-control\">\n                </div>\n              </div>\n              <!-- *ngIf=\"numbertype.value==0\" -->\n              <div class=\"col-md-6\"  >\n                <div class=\"form-group\">\n                  <label  class=\"d-block\">Number :</label>\n                  <input formControlName=\"number\" type=\"text\" class=\"form-control\">\n                </div>\n              </div>\n            </div>\n\n            <div class=\"form-group\">\n              <label  class=\"d-block\">Assign Publisher :</label>\n              <!-- <select formControlName=\"publisher\" class=\"form-control\" [value]=\"''\" [ngClass]=\"{ 'is-invalid': Submitted && addformcontrol.publisher.errors }\">\n                <option value=\"\">Select Publisher</option>\n                <option *ngFor=\"let publisher of publishers;\" [value]=\"publisher.id\">{{publisher.text}}</option>\n              </select>  -->\n              <angular2-multiselect [data]=\"publishers\" [ngClass]=\"{ 'is-invalid': Submitted && addformcontrol.publisher.errors }\" formControlName=\"publisher\" [settings]=\n                \"{\n                  enableSearchFilter: true,\n                  showCheckbox:false,\n                  singleSelection: true, text:'Assign Publisher'}\">\n              </angular2-multiselect>\n              <div *ngIf=\"Submitted && addformcontrol.publisher.errors\" class=\"invalid-feedback\">\n                <div *ngIf=\"addformcontrol.publisher.errors.required\">Publisher is required</div>\n            </div>\n            </div>\n\n            <div class=\"control-group mt-2\" *ngIf=\"this.addForm.get('publisher').value!=''\">\n              <label class=\"control-label input-label\" for=\"startTime\">Payout Type :</label>\n              <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n              <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editpayout_typeval==0}\" (click)=\"payout_typevaledit(0)\">\n                    <input class=\"form-check-input\" name=\"payout_typeedit\" formControlName=\"payout_typeedit\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                    None\n                  </label>\n                  <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editpayout_typeval==1}\" (click)=\"payout_typevaledit(1)\">\n                    <input class=\"form-check-input\" name=\"payout_typeedit\" formControlName=\"payout_typeedit\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                    Fixed Payout\n                  </label>\n                  <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editpayout_typeval==2}\" (click)=\"payout_typevaledit(2)\">\n                    <input class=\"form-check-input\" name=\"payout_typeedit\" formControlName=\"payout_typeedit\" type=\"radio\" id=\"option3\" [value]=\"2\">\n                    Revenue %\n                  </label>\n                </div>\n                <div *ngIf=\"publisherSubmitted && publisherFormcontrol.payout_typeedit.errors\" class=\"invalid-feedback\">\n                  <div *ngIf=\"publisherFormcontrol.payout_typeedit.errors.required\">Payout Type is required</div>\n              </div>\n              </div>\n              <div *ngIf=\"payout_typevalueedit != 0\">\n                <div class=\"control-group mt-2\">\n                  <label class=\"control-label input-label\" *ngIf=\"payout_typevalueedit==1\" for=\"startTime\">Payout Amount :</label>\n                  <label class=\"control-label input-label\" *ngIf=\"payout_typevalueedit==2\" for=\"startTime\">Payout % :</label>    \n                      <div class=\"input-group\">\n                        <div class=\"input-group-prepend\">\n                          <div class=\"input-group-text font-10\" *ngIf=\"payout_typevalueedit==1\" id=\"btnGroupAddon\">$</div>\n                          <div class=\"input-group-text font-10\" *ngIf=\"payout_typevalueedit==2\" id=\"btnGroupAddon\">%</div> \n                        </div>\n                        <input type=\"text\" formControlName=\"payout_amount\" class=\"form-control\" placeholder=\"Enter Payout Amount\" aria-label=\"Enter Payout Amount\" aria-describedby=\"btnGroupAddon\">\n                      </div>\n                </div>\n\n              <div class=\"control-group mt-2\">\n                <label class=\"control-label input-label\" for=\"startTime\">Payout Trigger :</label>\n                  <select class=\"form-control\" formControlName=\"payout_trigger\">\n                    <option value=\"0\">Inbound Call</option>\n                    <option value=\"1\">Call Length</option>\n                    <option value=\"2\">Call Successfully Connected</option>\n                  </select>\n              </div>\n              <div class=\"control-group mt-2\" *ngIf=\"this.addForm.get('payout_trigger').value == 1\">\n                  <label class=\"control-label input-label\" for=\"startTime\">Enter Seconds :</label>\n                  <input type=\"text\"  class=\"form-control\" type=\"text\" formControlName=\"payout_seconds\" placeholder=\"Enter Seconds\" />\n              </div>\n            </div>\n\n            <div class=\"form-group\">\n              <label  class=\"d-block\">Select Campaign :</label>\n              <!-- <select formControlName=\"campain\" class=\"form-control\" [value]=\"''\" [ngClass]=\"{ 'is-invalid': Submitted && addformcontrol.campain.errors }\">\n                <option value=\"\">Select Campaign</option>\n                <option *ngFor=\"let campain of getallcampain;\" [value]=\"campain.id\">{{campain.text}}</option>\n              </select>    -->\n              <angular2-multiselect [data]=\"getallcampain\" [ngClass]=\"{ 'is-invalid': Submitted && addformcontrol.campain.errors }\" formControlName=\"campain\" [settings]=\n                \"{\n                  enableSearchFilter: true,\n                  showCheckbox:false,\n                  singleSelection: true, text:'Assign Campaign'}\">\n              </angular2-multiselect>\n              <div *ngIf=\"Submitted && addformcontrol.campain.errors\" class=\"invalid-feedback\">\n                <div *ngIf=\"addformcontrol.campain.errors.required\">Campaign is required</div>\n            </div>\n            </div>\n\n            <div class=\"form-group\">\n              <label>Associated Label</label>\n               <angular2-multiselect [data]=\"dropdownList\" formControlName=\"assosciated_labels\" [settings]=\"dropdownSettings\" [ngClass]=\"{ 'is-invalid': submitted && f.assosciated_labels.errors }\" ></angular2-multiselect>\n               <div *ngIf=\"submitted && f.assosciated_labels.errors\" class=\"invalid-feedback\">\n                 <div *ngIf=\"f.assosciated_labels.errors.required\">Assosciated Labels is required</div>\n             </div>\n            </div>\n\n           </div>\n       </div>\n          <div class=\"modal-footer\" style=\"padding: 0;\">\n             <button (click)=\"closeModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Create Number</button>\n             <button  type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\">Reset</button>\n            </div>\n        </form>\n      </div>\n    </div>\n  </div>\n  </div>\n\n\n  <div class=\"modal fade\" id=\"editModel\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n  aria-hidden=\"true\">\n  <div class=\"modal-dialog model-lg\" role=\"document\">\n    <div class=\"modal-content\">\n      <div class=\"modal-header\">\n        <h5 class=\"modal-title\" id=\"formModal\">Update Number</h5>\n        <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n          <span aria-hidden=\"true\">&times;</span>\n        </button>\n      </div>\n      <div class=\"modal-body\">\n        <form id=\"editLabel\" [formGroup]=\"editForm\" (ngSubmit)=\"onEditSubmit()\">\n          <div class=\"row\">\n            <div class=\"col-md-12\">\n          <div class=\"form-group\">\n              <label>Country</label>\n              <input type=\"hidden\" name=\"uuid\" formControlName=\"uuid\" >\n              <select formControlName=\"country\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && addformcontrol.country.errors }\" [value]=\"''\" (change)=\"editprefix($event.target.value)\">\n                <option value=\"\">Select Country</option>\n                <option value=\"United States\">United States</option>\n                <option value=\"United Kingdom\">United Kingdom</option>\n              </select>\n              <div *ngIf=\"Submitted && addformcontrol.country.errors\" class=\"invalid-feedback\">\n                  <div *ngIf=\"addformcontrol.country.errors.required\">Country is required</div>\n              </div>\n           </div>\n\n           <div class=\"form-group\">\n            <div class=\"control-group\">\n                <label class=\"control-label input-label\" for=\"startTime\">Number Type:</label>\n                <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': numberTypeadd==0}\" (click)=\"numberTypeval(0)\">\n                      <input class=\"form-check-input\" name=\"numberType\" formControlName=\"numberType\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                      Toll Free\n                    </label>\n                    <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': numberTypeadd==1}\" (click)=\"numberTypeval(1)\">\n                      <input class=\"form-check-input\" name=\"numberType\" formControlName=\"numberType\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                       Local\n                    </label>\n                  </div>\n            </div>\n          </div>\n\n            <div class=\"row\">\n              <div class=\"col-md-6\">\n                <div class=\"form-group\">\n                  <label  class=\"d-block\">Prefix :</label>\n                  <input formControlName=\"prefix\" type=\"text\" class=\"form-control\">\n                </div>\n              </div>\n              <div class=\"col-md-6\">\n                <div class=\"form-group\">\n                  <label  class=\"d-block\">Number :</label>\n                  <input formControlName=\"number\" type=\"text\" class=\"form-control\">\n                </div>\n              </div>\n            </div>\n\n            <div class=\"form-group\">\n              <label  class=\"d-block\">Assign Publisher :</label>\n              <!-- <select formControlName=\"publisher\" class=\"form-control\" [value]=\"''\">\n                <option value=\"\">Select Publisher</option>\n                <option *ngFor=\"let publisher of publishers;\" [value]=\"publisher.id\">{{publisher.text}}</option>\n              </select>                                  -->\n              <angular2-multiselect [data]=\"publishers\" [(ngModel)]=\"selectedItemspub\" [ngClass]=\"{ 'is-invalid': Submitted && addformcontrol.publisher.errors }\" formControlName=\"publisher\" [settings]=\n              \"{\n                enableSearchFilter: true,\n                showCheckbox:false,\n                singleSelection: true, text:'Assign Publisher'}\">\n            </angular2-multiselect>\n            </div>\n\n\n            <div class=\"control-group mt-2\" *ngIf=\"this.editForm.get('publisher').value!=''\">\n              <label class=\"control-label input-label\" for=\"startTime\">Payout Type :</label>\n              <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n              <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editpayout_typeval==0}\" (click)=\"payoutedit_typeval(0)\">\n                    <input class=\"form-check-input\" name=\"payout_typeedit\" formControlName=\"payout_typeedit\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                    None\n                  </label>\n                  <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editpayout_typeval==1}\" (click)=\"payoutedit_typeval(1)\">\n                    <input class=\"form-check-input\" name=\"payout_typeedit\" formControlName=\"payout_typeedit\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                    Fixed Payout\n                  </label>\n                  <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': editpayout_typeval==2}\" (click)=\"payoutedit_typeval(2)\">\n                    <input class=\"form-check-input\" name=\"payout_typeedit\" formControlName=\"payout_typeedit\" type=\"radio\" id=\"option3\" [value]=\"2\">\n                    Revenue %\n                  </label>\n                </div>\n                <!-- <div *ngIf=\"publisherSubmitted && publisherFormcontrol.payout_typeedit.errors\" class=\"invalid-feedback\">\n                  <div *ngIf=\"publisherFormcontrol.payout_typeedit.errors.required\">Payout Type is required</div>\n              </div>    -->\n              </div>\n\n              <div *ngIf=\"payoutedit_typevalue != 0\">\n                <div class=\"control-group mt-2\">\n                  <label class=\"control-label input-label\" *ngIf=\"payout_typevalueedit==1\" for=\"startTime\">Payout Amount :</label>\n                  <label class=\"control-label input-label\" *ngIf=\"payout_typevalueedit==2\" for=\"startTime\">Payout % :</label>                          <div class=\"input-group\">\n                        <div class=\"input-group-prepend\">\n                          <label class=\"control-label input-label\" *ngIf=\"payout_typevalueedit==1\" for=\"startTime\">Payout Amount :</label>\n                        <label class=\"control-label input-label\" *ngIf=\"payout_typevalueedit==2\" for=\"startTime\">Payout % :</label>    \n                        </div>\n                        <input type=\"text\" formControlName=\"payout_amount\" class=\"form-control\" placeholder=\"Enter Payout Amount\" aria-label=\"Enter Payout Amount\" aria-describedby=\"btnGroupAddon\">\n                      </div>\n                </div>\n\n              <div class=\"control-group mt-2\">\n                <label class=\"control-label input-label\" for=\"startTime\">Payout Trigger1 :</label>\n                  <select class=\"form-control\" formControlName=\"payout_trigger\">\n                    <option value=\"0\">Inbound Call</option>\n                    <option value=\"1\">Call Length</option>\n                    <option value=\"2\">Call Successfully Connected</option>\n                  </select>\n              </div>\n              <div class=\"control-group mt-2\" *ngIf=\"this.editForm.get('payout_trigger').value == 1\">\n                  <label class=\"control-label input-label\" for=\"startTime\">Enter Seconds :</label>\n                  <input type=\"text\"  class=\"form-control\" type=\"text\" formControlName=\"payout_seconds\" placeholder=\"Enter Seconds\" />\n              </div>\n            </div>\n\n\n            <div class=\"form-group mt-2\">\n              <label  class=\"d-block\">Select Campaign :</label>\n              <!-- <select formControlName=\"campain\" class=\"form-control\">\n                <option value=\"\">Select Campaign</option>\n                <option *ngFor=\"let campain of getallcampain;\" [value]=\"campain.id\">{{campain.text}}</option>\n              </select>                                             -->\n              <angular2-multiselect [data]=\"getallcampain\" [(ngModel)]=\"selectedItemscam\" [ngClass]=\"{ 'is-invalid': Submitted && addformcontrol.campain.errors }\" formControlName=\"campain\" [settings]=\n                \"{\n                  enableSearchFilter: true,\n                  showCheckbox:false,\n                  singleSelection: true, text:'Assign Campaign'}\">\n              </angular2-multiselect>\n            </div>\n\n            <div class=\"form-group\">\n              <label>Associated Label</label>\n               <angular2-multiselect [ngModelOptions]=\"{standalone: true}\" [(ngModel)]=\"labels\" [data]=\"dropdownList\"  [settings]=\"dropdownSettings\"></angular2-multiselect>\n               <!-- <div *ngIf=\"submitted && f.assosciated_labels.errors\" class=\"invalid-feedback\">\n                 <div *ngIf=\"f.assosciated_labels.errors.required\">Assosciated Labels is required</div>\n             </div>  -->\n              <small><a href=\"#\" class=\"\" data-toggle=\"modal\" data-target=\"#addLabels\">Add New Label</a></small>\n           </div>\n\n           </div>\n       </div>\n          <div class=\"modal-footer\" style=\"padding: 0;\">\n             <button (click)=\"closeEditModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Update Number</button>\n             <button  type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\">Reset</button>\n            </div>\n        </form>\n      </div>\n    </div>\n  </div>\n  </div>\n\n\n  <!-- Add Label Modal -->\n<div class=\"modal fade\" id=\"addLabels\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\naria-hidden=\"true\">\n<div class=\"modal-dialog\" role=\"document\">\n  <div class=\"modal-content\">\n    <div class=\"modal-header\">\n      <h5 class=\"modal-title\" id=\"formModal\">Create Label</h5>\n      <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n        <span aria-hidden=\"true\">&times;</span>\n      </button>\n    </div>\n    <div class=\"modal-body\">\n      <form id=\"addLabel\" [formGroup]=\"addLabelForm\" (ngSubmit)=\"onLabelSubmit()\">\n        <div class=\"row\">\n          <div class=\"col-md-12\">\n           <div class=\"form-group\">\n            <label>Label Name</label>\n            <input formControlName=\"name\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': LabelSubmitted && labelcontrol.name.errors }\" (input)=\"validatename()\">\n            <div *ngIf=\"LabelSubmitted && labelcontrol.name.errors\" class=\"invalid-feedback\">\n                <div *ngIf=\"labelcontrol.name.errors.required\">Name is required</div>\n            </div>\n            <div *ngIf=\"isName == 'success'  && isName != ''\" style=\"color:green;\">\n               Name Is Available\n             </div>\n              <div *ngIf=\"isName == 'fail' && isName != ''\" style=\"color:red;\">\n               Name Is Not Available\n             </div>\n         </div>\n\n          <div class=\"form-group\">\n            <label  class=\"d-block\">Notes:</label>\n            <textarea formControlName=\"notes\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': LabelSubmitted && labelcontrol.notes.errors }\"></textarea>\n            <div *ngIf=\"LabelSubmitted && labelcontrol.notes.errors\" class=\"invalid-feedback\">\n               <div *ngIf=\"labelcontrol.notes.errors.required\">Notes is required</div>\n           </div>\n          </div>\n\n            </div>\n    </div>\n\n        <div class=\"modal-footer\" style=\"padding: 0;\">\n           <button [disabled]=\"isName == 'fail'\" (click)=\"closeModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Create Label</button>\n           <button  type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\">Reset</button>\n          </div>\n      </form>\n    </div>\n  </div>\n</div>\n</div>\n\n\n  <div class=\"main-content\">\n    <section class=\"section\">\n      <div class=\"section-body\">\n        <div class=\"row\">\n          <div class=\"col-12\">\n            <div class=\"card\">\n                <div class=\"row\">\n                    <div class=\"col-3\">\n                        <div class=\"card-header\">\n                        <!-- <h4>Number Data</h4></div> -->\n                        <h4>Manage Numbers</h4></div>\n                    </div>\n                    <div class=\"col-9 text-right mt-2\" *ngIf=\"role!=3\">\n                        <div class=\"form-group\"  style=\"margin-right: 28px;padding: 3px;font-size: 14px;\">\n                          <button  data-toggle=\"modal\" data-target=\"#addModel\"  class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-1\"><i class=\"fa fa-plus\"></i> Create Number\n                          </button>\n                          <!-- [disabled]=\"ischecked === '1'\" -->\n                          <button (click)=\"onBatchEditSubmit()\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-1\"><i class=\"fa fa-tasks\"></i> Batch Edit</button>\n                          <button routerLink=\"/numbers-import/2\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-1\"><i class=\"fa fa-plus\"></i> Import </button>\n                           <button (click)=\"exportdata()\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-1\"><i class=\"fas fa-file-export\"></i> Export\n                          </button>\n                          <button [disabled]=\"ischecked === '1'\" (click)=\"onDeleteSubmit()\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-2\"><i class=\"fas fa-file-export\"></i> Delete Selected\n                          </button>\n\n                          <button [disabled]=\"ischecked === '1'\" (click)=\"onStatusChangeSubmit()\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-2\"><i class=\"fas fa-file-export\"></i> Selected Status Change\n                          </button>\n\n                          </div>\n                    </div>\n\n                </div>\n\n            <div class=\"row\">\n              <div class=\"col-md-12\">\n                <form  (ngSubmit)=\"loadNumbers()\">\n                  <div class=\"row\" style=\"margin-top: 10px;margin-left: 11px;\" >\n\n                  <div class=\"col-2\">\n                    <div class=\"form-group\">\n                      <label  class=\"d-block\">Search By Number :</label>\n                      <input type=\"text\" [(ngModel)]=\"searchbynumbers\" [ngModelOptions]=\"{standalone: true}\" class=\"form-control\" placeholder=\"Search Number\" >\n                    </div>\n                  </div>\n\n                  <div class=\"col-2\" *ngIf=\"role!=3\">\n                    <div class=\"form-group\">\n                      <label  class=\"d-block\">Search By Campaign :</label>\n                      <!-- <select class=\"form-control\" [value]=\"''\" [(ngModel)]=\"searchbycampaign\" [ngModelOptions]=\"{standalone: true}\" >\n                        <option value=\"\">Select Campaign</option>\n                        <option *ngFor=\"let campain of getallcampain;\" [value]=\"campain.id\">{{campain.text}}</option>\n                      </select>    -->\n                      <angular2-multiselect [ngModelOptions]=\"{standalone: true}\" [(ngModel)]=\"searchbycampaign\" [data]=\"getallcampain\"  [settings]=\"campaigndropdownSettings\"></angular2-multiselect>\n                    </div>\n                  </div>\n\n                  <div class=\"col-2\" *ngIf=\"role!=3\">\n                    <div class=\"form-group\">\n                      <label class=\"d-block\">Search By Label :</label>\n                      <!-- <select class=\"form-control\" [value]=\"''\"  [(ngModel)]=\"searchbylabels\" [ngModelOptions]=\"{standalone: true}\" >\n                        <option value=\"\">Select Label</option>\n                        <option *ngFor=\"let label of dropdownList;\" [value]=\"label.id\">{{label.itemName}}</option>\n                      </select>                                             -->\n\n                      <angular2-multiselect [ngModelOptions]=\"{standalone: true}\" [(ngModel)]=\"searchbylabels\" [data]=\"dropdownList\"  [settings]=\"dropdownSettings\"></angular2-multiselect>\n\n                    </div>\n                  </div>\n                  <!-- <div class=\"col-1\"></div> -->\n                  <div class=\"col-1 mt-4\" style=\"margin-top: 5px;\">\n                    <button type=\"submit\" class=\"btn btn-success btn-lg\"><i class=\"fas fa-search\"></i></button>\n                  </div>\n                </div>\n                </form>\n\n              </div>\n            </div>\n\n              <div class=\"card-body\">\n                <div class=\"table-responsive\" style=\"position: relative\">\n                  <ngx-ui-loader [loaderId]=\"'loader-01'\"></ngx-ui-loader>\n\n                <table #dataTable class=\"table table-striped dataTable no-footer row-border hover\" style=\"width: 100%;\">\n                    <thead>\n                      <tr>\n                        <th style=\"padding: 10px;width: 1px;\" >\n                            <div class=\"custom-control custom-checkbox\" *ngIf=\"numbers?.length != 0\">\n                            <div *ngIf=\"role!=3\">\n                              <input type=\"checkbox\" class=\"custom-control-input\" id=\"customCheck1\" (change)=\"checkalldelete($event)\" (click)=\"deleteselected($event)\">\n                              <label class=\"custom-control-label\" for=\"customCheck1\"></label>\n                            </div>\n                            <div *ngIf=\"role==3\">\n\n                            </div>\n                            </div>\n                        </th>\n                        <th>Number</th>\n                        <th>Campaign</th>\n                        <!-- <th>Target</th>                         -->\n                        <th>Publisher</th>\n                        <th>Status</th>\n                        <th>Associated Label</th>\n                        <th>Allocated</th>\n                        <th>Action</th>\n                      </tr>\n                    </thead>\n                    <tbody *ngIf=\"numbers?.length != 0\">\n                        <tr *ngFor=\"let number of numbers\">\n                            <td *ngIf=\"role!=3\">\n                                <div class=\"custom-control custom-checkbox\">\n                                <input type=\"checkbox\" (click)=\"deleteselected($event)\" class=\"custom-control-input\" id=\"customCheck_{{number.uuid}}\"  [checked]=\"number.selected\" [value]=\"number.id\" >\n                                <label class=\"custom-control-label\" for=\"customCheck_{{number.uuid}}\"></label>\n                                </div>\n                            </td>\n                            <td *ngIf=\"role==3\">-</td>\n                            <td *ngIf=\"role!=3\"><a href=\"#\" (click)=\"editdata(number.uuid,number.prefix,number.number_type,number.number,number.country,number.publisher_uuid,number.campaign_uuid)\"  data-toggle=\"modal\" data-target=\"#editModel\" class=\"text-white actionedit\">\n\n                              <img *ngIf=\"number.country=='United States'\" src=\"../../../assets/img/us.png\" width=\"20px\" alt=\"\" srcset=\"\">\n                              <img *ngIf=\"number.country=='United Kingdom'\" src=\"../../../assets/img/uk.png\" width=\"20px\" alt=\"\" srcset=\"\">\n\n                              {{ number.number }}</a></td>\n\n                            <td *ngIf=\"role==3\">\n                              <img *ngIf=\"number.country=='United States'\" src=\"../../../assets/img/us.png\" width=\"20px\" alt=\"\" srcset=\"\">\n                              <img *ngIf=\"number.country=='United Kingdom'\" src=\"../../../assets/img/uk.png\" width=\"20px\" alt=\"\" srcset=\"\">\n\n                              {{ number.number }}</td>\n\n                            <td *ngIf=\"role!=3\"><a routerLink=\"/edit-campaign/{{number.campaign_uuid}}\"  routerLinkActive=\"router-link-active\">{{ number.campaign }}</a></td>\n                            <td *ngIf=\"role==3\">{{ number.campaign }}</td>\n                            <td>{{ number.publisher }}</td>\n                            <td *ngIf=\"number.status==1\">\n                              <span class=\"badge badge-success\">Enabled</span>\n                            </td>\n                            <td *ngIf=\"number.status==0\">\n                              <span class=\"badge badge-danger p-1\">Disabled</span>\n                            </td>\n\n                            <td>\n                              <span *ngFor=\"let assosciated_label of number.assosciated_labels?.split(',')\">\n                                  <span class=\"badge badge-primary p-1 ml-1\">{{assosciated_label }}</span><br>\n                              </span>\n                            </td>\n\n                            <td>{{ number.created_at }}</td>\n                            <td style=\"cursor:pointer;\" class=\"d-flex\" *ngIf=\"role!=3\"><a href=\"#\" (click)=\"editdata(number.uuid,number.prefix,number.number_type,number.number,number.country,number.publisher_uuid,number.campaign_uuid)\"  data-toggle=\"modal\" data-target=\"#editModel\" class=\"actionedit\"><i class=\"far fa-edit\"></i></a>&nbsp;&nbsp;<div (click)=\"Delete(number.uuid,number.number,number.company_uuid)\" class=\"actiondelete\"><i class=\"fas fa-trash\"></i></div></td>\n                            <td *ngIf=\"role==3\">-</td>\n                        </tr>\n                    </tbody>\n                    <tbody *ngIf=\"numbers?.length == 0\">\n                      <tr>\n                        <td colspan=\"8\" class=\"no-data-available\">No data Available!</td>\n                      </tr>\n                    <tbody>\n                  </table>\n                </div>\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n    </section>\n\n  </div>\n";

/***/ }),

/***/ 58229:
/*!************************************************************************************************!*\
  !*** ./src/app/modules/publishers/advertiser-terms/advertiser-terms.component.html?ngResource ***!
  \************************************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "<div class=\"bg-black\">\n    <div class=\"container\">\n      <div class=\"row\">\n        <div class=\"col-md-12\">\n          <img alt=\"image\" width=\"250px\" src=\"assets/img/logo.png\" class=\"header-logo mb-2  mt-10\">\n        </div>\n      </div>\n    \n      <div class=\"row text-center\">\n        <div class=\"col-md-12\">\n          <h1>ADVERTISER TERMS</h1>\n        </div>\n      </div>\n      <div class=\"row\">\n        <div class=\"col-md-2\"></div>\n        <div class=\"col-md-8\">\n          <b>TERMS AND CONDITIONS</b>\n          <p class=\"text-justify\">This Ringlab Affiliate Network Advertiser Agreement (\"Advertiser Agreement\") governs the relationship between Ringlab Affiliate Network (\"Ringlab Affiliate Network\" or \"we\") and the entity accepting these terms (\"Advertiser\"), whereby Advertiser may obtain access to registered third party affiliates (\"Affiliates\") and publishers (\"Publishers\"), and related technology and software (\"Ad Server\"), to market customized advertisements and links provided by Advertiser and/or Ringlab Affiliate Network (\"Ads,\" as further defined below). The Ringlab Affiliate Network, as well as the services provided by Ringlab Affiliate Network in connection therewith (collectively \"Services\"), are further described in the Insertion Order (\"IO\") incorporated herein by reference (the IO, together with this Advertiser Agreement, the \"Agreement\"). The terms of the IO shall supersede all contrary terms set forth in this Advertiser Agreement, unless expressly set forth to the contrary. In any instance where Advertiser is an agency entering into the Agreement on behalf of a client, any reference to \"Advertiser\" shall refer jointly to Advertiser as well as the applicable underlying client.\n            </p>\n            <b>Ringlab Affiliate Network/Services\n            </b>\n          <p class=\"text-justify\">In connection with the Services set forth in the Agreement, Ringlab Affiliate Network shall undertake marketing campaigns with Advertiser (each an \"Ad Campaign\") whereby Ringlab Affiliate Network will distribute Advertiser's proprietary advertising materials including, without limitation, banners, buttons, text-links, clicks, co-registrations, pop-ups, pop-unders, e-mail, graphic files and similar online media (collectively, \"Advertiser Ads\") and/or, where applicable, Ringlab Affiliate Network Ads (as defined below) through the Ringlab Affiliate Network either: on Publisher websites via the Ad Server for impressions-based Ad Campaigns (\"CPM\"); or by Affiliates via e-mail based marketing, search engine marketing, website based marketing and/or other online marketing means. In connection with such Ad Campaigns, Advertiser shall pay Ringlab Affiliate Network commissions depending on the number of valid clicks, impressions, sales/actions (\"CPA\"), applications and leads (\"Leads\"), and/or such other compensable activities generated on behalf of Advertiser as set forth in the subject IO (collectively, \"Actions\"). The applicable Actions, the fees due to Ringlab Affiliate Network for each Action and other applicable terms and conditions of the Ad Campaigns entered into hereunder shall be specified in each IO. Ringlab Affiliate Network shall not be held liable or responsible for any actions or inactions of its Publishers or Affiliates.\n\n        </p>\n        <b>Account        </b>\n          <p class=\"text-justify\">Upon the execution of the Agreement, Advertiser must register on the Ringlab Affiliate Network website and create a unique, password-protected account (\"Account\"). Advertiser will be responsible for safeguarding and maintaining the confidentiality of its Account and associated password. Advertiser shall remain fully and solely responsibility for any and all actions taken under Advertiser's Account , whether authorized by Advertiser or not. Advertiser must immediately notify Ringlab Affiliate Network of any unauthorized use of Advertiser's Account. Advertiser is responsible for keeping its Account information current, complete and accurate, and Advertiser acknowledges and agrees that Ringlab Affiliate Network will have no responsibility or liability, directly or indirectly, for failure to deliver notices as a result of inaccurate Account information.\n        </p>\n        <b>Ads</b>\n          <p class=\"text-justify\">Unless stated otherwise in an IO, Advertiser shall develop all aspects of the Advertiser Ads, other than where the parties agree that Ringlab Affiliate Network shall assist in the development of Ads . The parties understand and agree that Advertiser is the sole owner of any and all intellectual property rights associated with any Advertiser Ads; other than those portions that Ringlab Affiliate Network prepares on Advertiser's behalf (such portions hereinafter referred to as, the \"Ringlab Affiliate Network Ads\" and together with the Advertiser Ads, the \"Ads\"). The parties understand and agree that Ringlab Affiliate Network is the sole owner of any and all intellectual property rights associated with the Ringlab Affiliate Network Ads, other than Advertiser's trademarks , logos, copyrights and other pre-existing Advertiser intellectual property incorporated in the Ringlab Affiliate Network Ads.  Under no circumstances shall Ringlab Affiliate Network be authorized to use the Ads other than in connection with Advertiser's Ad Campaigns as set forth in the IO(s). Advertiser shall submit all Advertiser Ads to Ringlab Affiliate Network for approval prior to the commencement of the subject Ad Campaign set forth in the applicable IO. After the applicable Ad has been approved by Ringlab Affiliate Network, Advertiser shall not alter, modify or otherwise change the Ads, or any other Ads-related feature, in any manner whatsoever, without obtaining Ringlab Affiliate Network's prior express written consent. Notwithstanding the foregoing, Ringlab Affiliate Network shall have sole discretion with respect to the creation of the \"subject\" and \"from\" lines used in its e-mailing of any Ads.  Ringlab Affiliate Network reserves the right, in its sole discretion and without liability, to:change any of its Ad Guidelines at any time; and reject, omit, exclude or terminate any Ad for any reason at any time, with subsequent notice to the Advertiser, whether or not such Ad was previously acknowledged, accepted or published by Ringlab Affiliate Network. Such reasons for rejection, omission or exclusion of Ads include, but are not limited to, Ringlab Affiliate Network's determination, in its sole discretion, that the Ads, including the applicable products and/or services promoted by such Ads (\"Advertiser Products\"), and any website linked to from such Ads, are in violation of any applicable law, rule, regulation or other judicial or administrative order or where the content thereof may tend to bring disparagement, ridicule or scorn upon Ringlab Affiliate Network or any of its Publishers and/or Affiliates.    Advertiser reserves the right to reject, omit, exclude, terminate or request a change to the Ads at any time and Ringlab Affiliate Network shall, subject to the provisions set forth herein, comply with such request as soon as practical but in no event later than three (3) business days after its receipt thereof. Advertiser may cancel or suspend a CPM-based Ad Campaign, or an Ad associated with such a CPM-based Ad Campaign, effective within approximately twenty-four (24) business hours of Ringlab Affiliate Network's receipt of Advertiser's cancellation notice, which Advertiser can deliver by logging into its Account and following the instructions on the applicable menu.</p>\n    \n          <p class=\"text-justify\">4.) Creative Changes: Editing of Ringlab Media’s Creative is strictly prohibited, without prior written\n            approval from Ringlab Media. Creative includes, but is not limited to, text ads, graphic ads, from and subject\n            line, any copy associated with the campaign including survey questions and answers. Any changes to Creative,\n            without prior written permission will result in the loss of payment of Leads.</p>\n           <b>Placement</b>\n          <p class=\"text-justify\">The positioning, placement, frequency and other editorial decisions related to Ads shall be made by Ringlab Affiliate Network and/or its Affiliates and Publishers, as applicable, in their respective sole discretion. The applicable IO may set forth the particular place(s) where Ads may appear and/or be distributed. Advertiser agrees that in a case where no points of placement or distributions are set forth in the applicable IO or, in cases where \"Run of Affiliate Network\" or similar designation is specified in the applicable IO, the Ads may appear at any point of placement and/or distribution that Ringlab Affiliate Network and/or its Affiliates and Publishers may determine, in their respective sole discretion.\n        </p>\n\n        <b>Ad Codes\n\n        </b>\n    \n          <p class=\"text-justify\">6.) Advertising Guidelines: PUBLISHER may, in its complete discretion, reject, cancel or remove at any time any\n            Advertisement from the service for any reason without prior notice to Ringlab Media. PUBLISHER must notify\n            Ringlab Media following the rejection, cancellation or removal of any Advertisement from the service within 24\n            hours.</p>\n    \n          <p class=\"text-justify\">7.) Term & Target Launch: Term will be one (1) month from the target launch of the initial campaign as noted in\n            the Insertion Order. Agreement may continue thereafter by mutual consent but may be terminated by either party\n            for any reason whatsoever. All legitimate moneys due to PUBLISHER will be paid during the next billing cycle. If\n            PUBLISHER defrauds the system, then payment is revoked as determined solely by Ringlab Media.</p>\n    \n          <p class=\"text-justify\">8.) Payment: PUBLISHER will invoice Ringlab Media on a monthly basis at the payout rates reflected in the\n            Insertion Order. The invoice will reflect delivery of final Qualified Lead numbers that are based upon numbers\n            reported by Ringlab Media to PUBLISHER pursuant to the terms of this Agreement. In the event Ringlab Media does\n            not receive payment from its ADVERTISER for reasons that directly relate to PUBLISHER’s traffic quality or\n            fraudulent issues that can be proven by the Advertiser, and that PUBLISHER’s traffic or proven fraud is a direct\n            result for non-payment, Ringlab Media shall have no obligation to make payment to PUBLISHER.</p>\n    \n          <p class=\"text-justify\">9.) Payment Term: Ringlab Media shall make all payments to PUBLISHER within 30 days of the Invoice Date. All\n            payments made to PUBLISHER do not include, and PUBLISHER shall pay, any sales, use or similar tax associated\n            with such payment. All past due amounts shall accrue interest at the rate of one and one-half percent (1.5%) per\n            month or the maximum rate allowed by law, whichever is greater. Parties shall keep, maintain and preserve, for\n            the term of this Agreement and for one (1) year thereafter, accurate records relating to amounts due hereunder\n            (the “Relevant Records”). Either party shall have a right at least once per calendar year to audit the Relevant\n            Records of the other party for the purpose of verifying fulfillment of party’s payment obligations pursuant to\n            this Agreement. Each audit will be conducted at a place agreed to by the parties, during the normal business\n            hours, with at least ten (10) business days prior written notice to party to be audited. Auditing party shall\n            pay the fees and expenses of the audit, unless the audit reveals a payment discrepancy of more than ten percent\n            (10%) of all payments due in any consecutive six (6) month period, in which case audited party shall pay the\n            reasonable fees and expenses of the audit, and shall immediately pay to auditing party all amounts found to be\n            due.\n          </p>\n    \n          <p class=\"text-justify\">10. Ringlab Media Representations and Warranties. The execution, delivery, and performance of this Agreement by\n            Ringlab Media has been duly approved by its board of directors or managing partners/members, and no further\n            corporate action is necessary on the part of Ringlab Media to consummate the transactions contemplated by this\n            Agreement.\n    \n          </p>\n    \n          <p class=\"text-justify\">11.) PUBLISHER Representations and Warranties: Publisher represents and warrants that: (1) the recipients of\n            all email addresses used by PUBLISHER in connection with this Agreement have manifested affirmative consent to\n            receive commercial emails from PUBLISHER and none of the email addresses were obtained through email harvesting\n            or dictionary attacks; (2) PUBLISHER will not fraudulently add leads or clicks or inflate leads or clicks by\n            fraudulent traffic generation (as determined solely by Ringlab Media, such as pre-population of forms or\n            mechanisms not approved by Ringlab Media); (3) PUBLISHER will not attempt in any way to alter, modify,\n            eliminate, conceal, or otherwise render inoperable or ineffective the Site tags, source codes, links, pixels,\n            modules or other data provided by or obtained from Ringlab Media that allows Ringlab Media to measure ad\n            performance and provide its services and (4) all of PUBLISHER’s efforts associated with this Agreement comply\n            with the laws of the United States, and any other laws of any other jurisdictions which are applicable to\n            PUBLISHER. PUBLISHER will not engage in or promote any illegal activities of any kind in association with this\n            Agreement.\n          </p>\n          <p class=\"text-justify\">12.) Other Obligations: PUBLISHER shall: NOT PROVIDE Incentivized traffic. This includes but is not limited to\n            any spoofing, redirecting or trafficking from adult related websites in an effort to gain traffic or websites\n            that are point, lottery, coupon or rewards based and encourage users to click on Advertisements or use\n            Advertisements to generate revenue for users to win points, get rewards, or other any other incentive.\n    \n          </p>\n          <p class=\"text-justify\">NOT PROVIDE leads generated from content, email or websites that are not subject matter related to the category\n            of the Advertisement represented. Such websites must be content-based (not a list of links or advertisements),\n            be written in English, receive a minimum of unique page views per month, have a top-level name and must not\n            infringe on any personal, intellectual property or copyrights. This can be waived only by SPECIFICALLY providing\n            the name of the proposed website to Ringlab Media.\n          </p>\n          <p class=\"text-justify\">Be able to provide the name of the Website where the lead was generated. This information is only delivered to\n            Ringlab Media upon request, but MUST be made available in case there is a dispute or problem with the lead.\n    \n          </p>\n    \n          <p class=\"text-justify\">NOT PROVIDE inappropriate content, which includes, but is not limited to, content that (i) promotes the use of\n            alcohol, tobacco or illegal substances, nudity, sex, pornography adult-oriented content such as phone sex or\n            escort services, expletives or inappropriate language, (ii) promotes violence or the use of illegal substances\n            or activities such as how to build a bomb, counterfeiting money and software pirating (iii) promotes illegal or\n            unethical activity, racism, hate, \"spam\", mail fraud, gambling, sweepstakes, pyramid schemes, or illegal advice\n            (iv) is otherwise prohibited by Federal or state law; and/or (v) will bring Ringlab Media and/or its associated\n            Advertisers negative publicity.\n    \n          </p>\n    \n          <p class=\"text-justify\">At no time, engage in, disseminate, promote or otherwise distribute any Advertisement through the use of\n            contextual media, specifically downloadable software (also called adware, pop-up/pop-under technologies,\n            plug-ins, and other names as applicable) </p>\n    \n          <p class=\"text-justify\">Email Campaigns. PUBLISHER further represents and warrants that with respect to email campaigns transmitted by\n            PUBLISHER for Ringlab Media, PUBLISHER shall at all times only use the Ringlab Media email creative provided by\n            Ringlab Media, maintain strict compliance with the Controlling the Assault on Non-solicited Pornography and\n            Marketing Act of 2003 (CAN-SPAM) and any amendments and modifications thereto. </p>\n    \n          <p class=\"text-justify\">13.) Confidentiality: The terms of this Agreement are confidential and shall not be disclosed to any third\n            party except where required by law. All information submitted by end-user customers pursuant to this Agreement\n            is proprietary to and owned by Ringlab Media. Such customer information is confidential and may not be disclosed\n            by Ringlab Media or PUBLISHER. In addition, the parties acknowledge that all non-public information, data and\n            reports received from the Disclosing Party hereunder or as part of the services hereunder is proprietary to and\n            owned by the Disclosing Party. (“Confidential Information”). The parties agree not to disclose the terms of this\n            Agreement, including the CPA value, to any third party without the express written consent of the Disclosing\n            Party, and that such constitutes Confidential Information. All Confidential Information is or may be protected\n            by copyright, trademark, trade secret and other intellectual property law, as appropriate. The parties agree not\n            to reproduce, disseminate, sell, distribute or commercially exploit any proprietary or Confidential Information\n            in any manner. These non-disclosure obligations shall survive the termination of this Agreement for a period of\n            five (5) years. This section does not bind Ringlab Media or PUBLISHER in the event such information is required\n            to be disclosed by operation of law. If a request is made of either party to disclose such information, the\n            Disclosing Party must immediately inform the other party via written notice sufficiently promptly to allow the\n            non-Disclosing Party to seek a Protective Order prior to the time commanded to produce or disclose such\n            Confidential Information, and each party agrees to cooperate in whatever way either party requests to attempt to\n            protect that information from disclosure by operation of law. Subject to prior approval, either party may\n            publicly announce its contractual relationship under this Agreement, which includes being on a listing of\n            Ringlab Media publishers in general corporate materials and in industry standard press releases.\n    \n          </p>\n    \n          <p class=\"text-justify\">14. DISCLAIMER OF WARRANTIES: Ringlab Media PROVIDES ITS SITES AND THE SITES OF ITS AFFILIATES AND PARTNERS,\n            AND ALL ITS SERVICES AND THE SERVICES OF ITS AFFILIATES AND PARTNERS, AS PERFORMED HEREUNDER, ON AN \"AS IS,\"\n            “WHERE IS” AND \"AS AVAILABLE\" BASIS. Ringlab Media DISCLAIMS ALL WARRANTIES OF ANY KIND, WHETHER EXPRESS OR\n            IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR\n            PURPOSE AND IMPLIED WARRANTIES ARISING FROM COURSE OF DEALING OR COURSE OF PERFORMANCE.\n    \n          </p>\n    \n          <p class=\"text-justify\">15. LIMITATIONS OF LIABILITY: IN NO EVENT SHALL EITHER PARTY BE LIABLE FOR ANY SPECIAL, INDIRECT, INCIDENTAL OR\n            CONSEQUENTIAL DAMAGES (INCLUDING, WITHOUT LIMITATION, FOR BREACH OF CONTRACT, WARRANTY, NEGLIGENCE OR STRICT\n            LIABILITY), OR FOR INTERRUPTED COMMUNICATIONS, LOSS OF USE, LOST BUSINESS, LOST DATA OR LOST PROFITS, ARISING\n            OUT OF OR IN CONNECTION WITH THIS AGREEMENT. UNDER NO CIRCUMSTANCES SHALL EITHER PARTY BE LIABLE TO THE OTHER OR\n            ANY THIRD PARTIES FOR AN AMOUNT GREATER THAN THE AMOUNTS PAID BY Ringlab Media TO PUBLISHER DURING THE PRIOR\n            THREE MONTHS.\n    \n          </p>\n    \n          <p class=\"text-justify\">16.) Indemnification: Each party agrees to indemnify, defend and hold harmless the other party and its\n            employees, agents, officers and directors, against any and all claims, causes of actions, judgments, demands,\n            damages, losses or liabilities, including costs and expenses (including reasonable attorneys fees and costs of\n            suit), arising out of or relating to (a) any claim based upon infringement of copyright, trademark, patent, or\n            trade secret or other intellectual property right of any third party; (b) any claim, representation, or\n            statement made in the Advertisement; (c) any breach of any representation or warranty contained in this\n            Agreement.\n    \n          </p>\n    \n          <p class=\"text-justify\">17. Dispute Resolution: If any dispute arises under this Agreement, the Parties agree to first try to resolve\n            the dispute with the help of a mutually agreed upon mediator in the following location: State of Florida,\n            Sarasota Count. Any costs and fees other than attorneys’ fees associated with the mediation shall be shared\n            equally by the parties. If it proves impossible to arrive at a mutually satisfactory solution through mediation,\n            the Parties agree to submit the dispute to binding arbitration in the following location: State of California,\n            Los Angeles County. The Parties agree that the binding arbitration will be conducted under the rules of the\n            American Arbitration Association. Judgment upon the award rendered by the arbitrator may be entered in any court\n            with proper jurisdiction. If any litigation or arbitration is absolutely necessary to enforce this Agreement or\n            the terms thereof, the prevailing Party shall be entitled to reimbursement by the other Party for reasonable\n            attorneys’ fees, costs and expenses. This Agreement will be governed by the laws of the State of AZ\n    \n          </p>\n    \n          <p class=\"text-justify\">18. No Assignment: Neither Party shall have the right to assign or otherwise transfer its rights and\n            obligations under this Agreement except with the prior written consent of the other Party; provided, however,\n            that a successor in interest by merger, by operation of law, assignment, purchase or otherwise of all or\n            substantially all the business of a Party may acquire its rights and obligations hereunder. Any prohibited\n            assignment shall be null and void.\n    \n          </p>\n    \n          <p class=\"text-justify\">19. Independent Contractor: Each party is an independent contractor. Except as set forth in this Agreement,\n            neither party is authorized or empowered to obligate the other or incur any costs on behalf of the other without\n            the party’s prior written consent.\n    \n          </p>\n    \n          <p class=\"text-justify\">20. Severability: If any term, provision, covenant, or condition of this Agreement is held by a court of\n            competent jurisdiction to be invalid or unenforceable, the remainder of the Agreement shall remain in full force\n            and effect and shall in no way be affected or invalidated.\n    \n          </p>\n          <p class=\"text-justify\">21. Entire Agreement; Modification: This constitutes the entire agreement between the parties and supersedes\n            any prior or inconsistent agreements, negotiations, representations and promises, written or oral, regarding the\n            subject matter. No modification, course of conduct, amendment, supplement to or waiver of this Agreement or any\n            provisions hereof shall be binding upon the parties unless made in writing and duly signed by both parties.\n          </p>\n    \n          <p class=\"text-justify\">22. Agreement in Counterparts: This agreement may be signed by Ringlab Media and PUBLISHER in counterparts, and\n            facsimile signatures shall have the same force and effect as an original signature.</p>\n    \n        </div>\n        <div class=\"col-md-2\"></div>\n      </div>\n    \n      <div class=\"row\">\n          <div class=\"col-md-12\">\n              <p>Copyright © 2020 Ringlab Media LLC - All Rights Reserved.</p>\n          </div>\n          <div class=\"col-md-12 text-center mb-3\">\n              <a [routerLink]=\"['/publisher-terms']\" routerLinkActive=\"router-link-active\" >Publisher Terms</a> <span class=\"mr-4\"></span>\n              <a [routerLink]=\"['/advertiser-terms']\" routerLinkActive=\"router-link-active\"  href=\"\">Advertiser Terms</a>\n          </div>\n      </div>\n    \n    </div>\n    </div>";

/***/ }),

/***/ 22311:
/*!****************************************************************************************************!*\
  !*** ./src/app/modules/publishers/publisher-settings/publisher-settings.component.html?ngResource ***!
  \****************************************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n  \n  <div class=\"main-content\">  \n    <section class=\"section\">\n      <div class=\"section-body\">\n        <div class=\"row\">\n          <div class=\"col-12\">\n            <div class=\"card\">\n                <div class=\"row\" style=\"margin-top: 20px;\">\n                    <div class=\"col-3\">\n                        <div class=\"card-header\">\n                        <h4>  Publisher Registration</h4></div>\n                    </div>                   \n                </div>            \n                \n              <div class=\"card-body\">\n                <form id=\"addLabel\" [formGroup]=\"addForm\" (ngSubmit)=\"onSubmit()\">\n                    <div class=\"row\">\n                      <div class=\"col-md-12\">\n                    <div class=\"form-group\">\n                        <label  class=\"d-block\">Public publisher Registraton enabled :</label>\n                        <label class=\"custom-switch mt-2 pl-0\">\n                            <input type=\"checkbox\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\" (change)=\"pubreg_enable($event)\"  [checked]=\"publicregistration==true\">\n                            <span class=\"custom-switch-indicator\"></span>                     \n                        </label>      \n                    </div>   \n                    <div *ngIf=\"ispubreg==true\">\n                    <div class=\"form-group\">\n                        <label  class=\"d-block\">Introduction :</label>\n                        <label class=\"custom-switch mt-2 pl-0\">\n                            <textarea formControlName=\"intro\" name=\"\" id=\"\" cols=\"190\" rows=\"10\" class=\"form-control\"></textarea>                            \n                        </label>                                    \n                    </div>   \n                    \n                    <div class=\"form-group\">\n                        <label  class=\"d-block\">Contact email :</label>\n                        <input formControlName=\"email\" type=\"text\" class=\"form-control\">           \n                    </div>   \n\n                    <div class=\"form-group\">\n                        <label  class=\"d-block\">Terms and Conditions :</label>\n                        <label class=\"custom-switch mt-2 pl-0\">\n                            <input type=\"checkbox\" [checked]=\"terms_condstatus==true\" formControlName=\"terms_cond\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\" (change)=\"tc_enable($event)\">\n                            <span class=\"custom-switch-indicator\"></span>                     \n                        </label>                                    \n                    </div>\n                 \n                    <div class=\"form-group\">\n                        <label  class=\"d-block\">Terms and Conditions URL :</label>\n                        <input formControlName=\"tc_url\"  type=\"text\" class=\"form-control\">           \n                    </div>   \n                   \n                    <div class=\"form-group\">\n                        <label  class=\"d-block\">URL :</label>\n                        <a href=\"{{BaseUrl}}publisher-registration/{{Companyuuid}}\" target=\"_blank\">{{BaseUrl}}publisher-registration/{{Companyuuid}}</a>                        \n                    </div>   \n                    </div>       \n                    </div>       \n                 </div>\n                    <div class=\"modal-footer\" style=\"padding: 0;\">\n                       <button  type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Save</button>                       \n                      </div>\n                  </form>\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n    </section>\n    \n  </div>\n";

/***/ }),

/***/ 59491:
/*!**********************************************************************************************!*\
  !*** ./src/app/modules/publishers/publisher-terms/publisher-terms.component.html?ngResource ***!
  \**********************************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "<div class=\"bg-black\" *ngIf=\"isavail==1\">\n  <div class=\"container\" style=\"background: #1d2b4e;\">\n    <div class=\"row text-center\">\n      <div class=\"col-md-12 mt-5\">\n        <img alt=\"image\" width=\"250px\" src=\"assets/img/logo.png\" class=\"header-logo mb-2  mt-10 mb-10\">\n        <h3>PUBLISHER REGISTRATION</h3>\n        <P>Welcome to {{company}}! <br>\n          Please review and accept the Publisher Terms and Conditions below and proceed to your application.<br>\n          Someone from our office will contact you within 24 hours.</P><br>\n        <p>Please share some details about you and your business to register as a publisher</p>\n      </div>\n    </div>\n    <div class=\"row\">\n      <div class=\"col-md-2\"></div>\n      <div class=\"col-md-8\">\n        <form id=\"addLabel\" [formGroup]=\"addForm\" (ngSubmit)=\"onSubmit()\">\n          <div class=\"row\">\n            <div class=\"col-md-12\">\n              <div class=\"form-group\">\n                <label class=\"d-block text-white\">Business Name :</label>\n                <input type=\"text\" placeholder=\"My Company Name\" formControlName=\"businame\" name=\"\" id=\"\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && addformcontrol.businame.errors }\">                \n                <div *ngIf=\"Submitted && addformcontrol.businame.errors\" class=\"invalid-feedback\">\n                  <div *ngIf=\"addformcontrol.businame.errors.required\">Business Name is required</div>\n                </div>       \n              </div>\n              \n              <div class=\"form-group\">\n                <label class=\"d-block text-white\">First Name :</label>\n                <input type=\"text\" placeholder=\"John\" formControlName=\"first_name\" name=\"\" id=\"\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && addformcontrol.first_name.errors }\">  \n                <div *ngIf=\"Submitted && addformcontrol.first_name.errors\" class=\"invalid-feedback\">\n                  <div *ngIf=\"addformcontrol.first_name.errors.required\">First Name is required</div>\n                </div>                \n              </div>\n              \n              <div class=\"form-group\">\n                <label class=\"d-block text-white\">Last Name  :</label>\n                <input type=\"text\" placeholder=\"Smith\" formControlName=\"last_name\" name=\"\" id=\"\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && addformcontrol.last_name.errors }\">  \n                <div *ngIf=\"Submitted && addformcontrol.last_name.errors\" class=\"invalid-feedback\">\n                  <div *ngIf=\"addformcontrol.last_name.errors.required\">Last Name is required</div>\n                </div>                \n              </div>\n              <div class=\"form-group\">\n                <label class=\"d-block text-white\">Email :</label>\n                <input placeholder=\"alias@server.com\" formControlName=\"email\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && addformcontrol.email.errors }\">\n                <div *ngIf=\"Submitted && addformcontrol.email.errors\" class=\"invalid-feedback\">\n                  <div *ngIf=\"addformcontrol.email.errors.required\">Email is required</div>\n                </div>  \n              </div>\n\n              <div class=\"form-group\">\n                <label class=\"d-block text-white\">Phone Number :</label>\n                <input placeholder=\"+18081231234\" type=\"text\" formControlName=\"phone_number\" name=\"\" id=\"\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && addformcontrol.phone_number.errors }\">       \n                <div *ngIf=\"Submitted && addformcontrol.phone_number.errors\" class=\"invalid-feedback\">\n                  <div *ngIf=\"addformcontrol.phone_number.errors.required\">Phone Number is required</div>\n                </div>           \n              </div>\n\n              <div class=\"form-group\">\n                <label class=\"d-block text-white\">I agree to the  Terms and Conditions :</label>\n                <label class=\"custom-switch mt-2 pl-0\">\n                  <input type=\"checkbox\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\" (change)=\"tc_enable($event)\">\n                  <span class=\"custom-switch-indicator\"></span>\n                </label>\n              </div>              \n            </div>\n          </div>\n          <div class=\"row text-center\">\n            <div class=\"col-md-12\">\n              <button type=\"submit\" [disabled]=\"tcenable!=true\" class=\"btn btn-primary\">Register As Publisher</button>\n            </div>\n          </div>\n          \n          <br><br>\n          <p>Please forward any questions or concerns regarding publisher registration to {{email}}</p>\n          <br><br>\n        </form>\n      </div>\n      <div class=\"col-md-2\"></div>\n    </div>\n\n    <!-- <div class=\"row\">\n      <div class=\"col-md-12\">\n        <p>Copyright © 2020 Ringlab Media LLC - All Rights Reserved.</p>\n      </div>\n      <div class=\"col-md-12 text-center mb-3\">\n        <a [routerLink]=\"['/publisher-terms']\" routerLinkActive=\"router-link-active\">Publisher Terms</a> <span\n          class=\"mr-4\"></span>\n        <a [routerLink]=\"['/advertiser-terms']\" routerLinkActive=\"router-link-active\" href=\"\">Advertiser Terms</a>\n      </div>\n    </div> -->\n\n  </div>\n</div>\n\n\n<div class=\"mt-5\" *ngIf=\"isavail==0\">\n  <div class=\"container\" >\n    <div class=\"row text-center\">\n      <div class=\"col-md-12 mt-5\">\n        <img alt=\"image\" width=\"250px\" src=\"./assets/img/logo.png\" class=\"header-logo mb-5  mt-5 mb-0\">\n        <h6 class=\"text-white\">Publisher Registration is closed at the moment, please react out to the person who have provided you with the link.</h6>\n        <h6 class=\"text-white\">Visit dialdigit.com to learn more about Dialdigits</h6>\n      </div>\n    </div>\n\n  </div>\n</div>";

/***/ }),

/***/ 76872:
/*!*************************************************************************!*\
  !*** ./src/app/modules/publishers/publishers.component.html?ngResource ***!
  \*************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n  <div class=\"main-content\">\n    <section class=\"section\">\n      <div class=\"section-body\">\n        <div class=\"row\">\n          <div class=\"col-12\">\n            <div class=\"card\">\n                <div class=\"row\">\n                    <div class=\"col-3\">\n                        <div class=\"card-header\">\n                        <h4> Manage Publishers</h4></div>\n                    </div>\n                    <div class=\"col-9 text-right mt-2\">\n                        <div class=\"form-group\"  style=\"margin-right: 28px;padding: 3px;font-size: 14px;\">\n                          <button type=\"button\" data-toggle=\"modal\" data-target=\"#addLabels\" class=\"btn btn-primary daterange-btn icon-left btn-sm btn-icon mr-2 p-2\"><i class=\"fa fa-plus\"></i> Create Publisher\n                          </button>\n                          <!-- <button [disabled]=\"ischecked === '1'\" (click)=\"onDeleteSubmit()\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-2\"><i class=\"fas fa-file-export\"></i> Delete Selected\n                          </button>                          -->\n\n                          </div>\n                    </div>\n\n                </div>\n\n              <div class=\"card-body\">\n                <div class=\"table-responsive\">\n                <table #dataTable class=\"table table-striped dataTable no-footer row-border hover\" style=\"width: 100%;\">\n                    <thead>\n                      <tr>\n                        <!-- <th style=\"padding: 10px;width: 1px;\">\n                            <div class=\"custom-control custom-checkbox\" *ngIf=\"numbers?.length != 0\">\n                            <input type=\"checkbox\" class=\"custom-control-input\" id=\"customCheck1\" (change)=\"checkalldelete($event)\" (click)=\"deleteselected($event)\">\n                            <label class=\"custom-control-label\" for=\"customCheck1\"></label>\n                            </div>\n                        </th> -->\n                        <th>Name</th>\n                        <th>Email ID</th>\n                        <th>Create Numbers</th>\n                        <th>Block Incoming Calls<br> After Cap Is Reached</th>\n                        <th>Access To Recordings</th>\n                        <th>Created At</th>\n                        <th>Status</th>\n                        <th>Action</th>\n                      </tr>\n                    </thead>\n                    <tbody *ngIf=\"numbers?.length != 0\">\n                        <tr *ngFor=\"let number of numbers\">\n                              <!-- <td>\n                                <div class=\"custom-control custom-checkbox\">\n                                <input type=\"checkbox\" (click)=\"deleteselected($event)\" class=\"custom-control-input\" id=\"customCheck_{{number.uuid}}\"  [checked]=\"number.selected\" [value]=\"number.id\" >\n                                <label class=\"custom-control-label\" for=\"customCheck_{{number.uuid}}\"></label>\n                                </div>\n                            </td> -->\n                            <td><a (click)=\"editdata(number.uuid,number.name,number.email,number.create_number,number.settingToggleBlockCallsIfCapped,number.settingToggleAccessToRecordings, number.status)\" href=\"#\" data-toggle=\"modal\" data-target=\"#editLabels\" class=\"text-white actionedit\">{{ number.name }}</a></td>\n                            <td>{{ number.email }}</td>\n                            <td>\n                              <div *ngIf=\"number.create_number==0\" class=\"badge badge-danger\">No</div>\n                              <div *ngIf=\"number.create_number==1\" class=\"badge badge-success\">Yes</div>\n                            </td>\n                            <td>\n                              <div *ngIf=\"number.settingToggleBlockCallsIfCapped==0\" class=\"badge badge-primary\">Global</div>\n                              <div *ngIf=\"number.settingToggleBlockCallsIfCapped==1\" class=\"badge badge-primary\">Allow</div>\n                              <div *ngIf=\"number.settingToggleBlockCallsIfCapped==2\" class=\"badge badge-primary\">Block</div>\n                            </td>\n                            <td>\n                              <div *ngIf=\"number.settingToggleAccessToRecordings==0\" class=\"badge badge-primary\">Global</div>\n                              <div *ngIf=\"number.settingToggleAccessToRecordings==1\" class=\"badge badge-primary\">Enabled</div>\n                              <div *ngIf=\"number.settingToggleAccessToRecordings==2\" class=\"badge badge-primary\">Disabled</div>\n                            </td>\n                            <td>{{ number.created_at }}</td>\n                            <td>\n                              <div *ngIf=\"number.status==1\" class=\"badge badge-success\">Active</div>\n                              <div *ngIf=\"number.status==0\" class=\"badge badge-danger\">In-Active</div>\n                            </td>\n                            <td class=\"d-flex\" style=\"cursor:pointer;\">\n                              <a (click)=\"editdata(number.uuid,number.name,number.email,number.create_number,number.settingToggleBlockCallsIfCapped,number.settingToggleAccessToRecordings, number.status)\" href=\"#\" data-toggle=\"modal\" data-target=\"#editLabels\" class=\"actionedit\"><i class=\"far fa-edit\"></i></a>&nbsp;&nbsp;\n                              <div (click)=\"Delete((number.id))\" class=\"actiondelete\"><i class=\"fas fa-trash\"></i></div></td>\n                        </tr>\n                    </tbody>\n                    <!-- <tbody *ngIf=\"numbers?.length == 0\">\n                      <tr>\n                        <td colspan=\"8\" class=\"no-data-available\">No data Available!</td>\n                      </tr>\n                    <tbody> -->\n                  </table>\n                </div>\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n    </section>\n\n  </div>\n\n\n  <!-- Add  Modal -->\n<div class=\"modal fade\" id=\"addLabels\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\naria-hidden=\"true\">\n<div class=\"modal-dialog model-lg\" role=\"document\">\n  <div class=\"modal-content\">\n    <div class=\"modal-header\">\n      <h5 class=\"modal-title\" id=\"formModal\">Create Publisher</h5>\n      <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n        <span aria-hidden=\"true\">&times;</span>\n      </button>\n    </div>\n    <div class=\"modal-body\">\n      <form id=\"addLabel\" [formGroup]=\"addForm\" (ngSubmit)=\"onSubmit()\">\n        <div class=\"row\">\n          <div class=\"col-md-12\">\n        <div class=\"form-group\">\n            <label>Name</label>\n            <input formControlName=\"name\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && addformcontrol.name.errors }\">\n            <div *ngIf=\"Submitted && addformcontrol.name.errors\" class=\"invalid-feedback\">\n                <div *ngIf=\"addformcontrol.name.errors.required\">Name is required</div>\n            </div>\n         </div>\n\n         <div class=\"form-group\">\n          <label  class=\"d-block\">Email Id  :</label>\n          <input formControlName=\"email\" type=\"text\" class=\"form-control\">\n        </div>\n\n\n         <div class=\"form-group\">\n            <label>Password</label>\n            <input type=\"password\" formControlName=\"password\" class=\"form-control\">\n          </div>\n\n\n          <div class=\"form-group\">\n            <label  class=\"d-block\">Number Creation  :</label>\n            <label class=\"custom-switch mt-2 pl-0\">\n              <input type=\"checkbox\" formControlName=\"number_creation\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n              <span class=\"custom-switch-indicator\"></span>\n            </label>\n          </div>\n\n          <div class=\"form-group\">\n            <div class=\"control-group\">\n                <label class=\"control-label input-label\" for=\"startTime\">Block Incoming Calls After Cap Is Reached:</label>\n                <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': settingToggleBlockCallsIfCappededit==0}\" (click)=\"settingToggleBlockCallsIfCappedval(0)\">\n                      <input class=\"form-check-input\" name=\"settingToggleBlockCallsIfCapped\" formControlName=\"settingToggleBlockCallsIfCapped\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                      Global\n                    </label>\n                    <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': settingToggleBlockCallsIfCappededit==1}\" (click)=\"settingToggleBlockCallsIfCappedval(1)\">\n                      <input class=\"form-check-input\" name=\"settingToggleBlockCallsIfCapped\" formControlName=\"settingToggleBlockCallsIfCapped\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                       Allow\n                    </label>\n                    <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': settingToggleBlockCallsIfCappededit==2}\" (click)=\"settingToggleBlockCallsIfCappedval(2)\">\n                      <input class=\"form-check-input\" name=\"settingToggleBlockCallsIfCapped\" formControlName=\"settingToggleBlockCallsIfCapped\" type=\"radio\" id=\"option3\" [value]=\"2\">\n                       Block\n                    </label>\n                  </div>\n         </div>\n          </div>\n\n          <div class=\"form-group\">\n          <div class=\"control-group\">\n                <label class=\"control-label input-label\" for=\"startTime\">Access To Recordings:</label>\n                <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': settingToggleAccessToRecordingsedit==0}\" (click)=\"settingToggleAccessToRecordingsval(0)\">\n                      <input class=\"form-check-input\" name=\"settingToggleAccessToRecordings\" formControlName=\"settingToggleAccessToRecordings\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                      Global\n                    </label>\n                    <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': settingToggleAccessToRecordingsedit==1}\" (click)=\"settingToggleAccessToRecordingsval(1)\">\n                      <input class=\"form-check-input\" name=\"settingToggleAccessToRecordings\" formControlName=\"settingToggleAccessToRecordings\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                       Enabled\n                    </label>\n                    <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': settingToggleAccessToRecordingsedit==2}\" (click)=\"settingToggleAccessToRecordingsval(2)\">\n                      <input class=\"form-check-input\" name=\"settingToggleAccessToRecordings\" formControlName=\"settingToggleAccessToRecordings\" type=\"radio\" id=\"option3\" [value]=\"2\">\n                       Disabled\n                    </label>\n                  </div>\n    </div>\n          </div>\n         </div>\n     </div>\n        <div class=\"modal-footer\" style=\"padding: 0;\">\n           <button (click)=\"closeModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Create Publisher</button>\n           <button  type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\">Reset</button>\n          </div>\n      </form>\n    </div>\n  </div>\n</div>\n</div>\n\n<!-- Edit  Modal -->\n<div class=\"modal fade\" id=\"editLabels\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\naria-hidden=\"true\">\n<div class=\"modal-dialog model-lg\" role=\"document\">\n  <div class=\"modal-content\">\n    <div class=\"modal-header\">\n      <h5 class=\"modal-title\" id=\"formModal\">Update Publisher</h5>\n      <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n        <span aria-hidden=\"true\">&times;</span>\n      </button>\n    </div>\n    <div class=\"modal-body\">\n      <form id=\"editLabel\" [formGroup]=\"editForm\" (ngSubmit)=\"onEditSubmit()\">\n        <div class=\"row\">\n          <div class=\"col-md-12\">\n            <div class=\"form-group\">\n                <label>Name</label>\n                <input formControlName=\"name\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && editFormcontrol.name.errors }\">\n                <div *ngIf=\"Submitted && editFormcontrol.name.errors\" class=\"invalid-feedback\">\n                    <div *ngIf=\"editFormcontrol.name.errors.required\">Name is required</div>\n                </div>\n             </div>\n\n              <div class=\"form-group\">\n                <label  class=\"d-block\">Email Id  :</label>\n                <input formControlName=\"email\" type=\"text\" class=\"form-control\">\n              </div>\n\n              <div class=\"form-group\">\n                <label>Password</label>\n                <input type=\"password\" formControlName=\"password\" class=\"form-control\">\n              </div>\n\n              <div class=\"form-group\">\n                <label  class=\"d-block\">Number Creation  :</label>\n                <label class=\"custom-switch mt-2 pl-0\">\n                  <input type=\"checkbox\" formControlName=\"number_creation\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n                  <span class=\"custom-switch-indicator\"></span>\n                </label>\n              </div>\n\n              <div class=\"form-group\">\n                <div class=\"control-group\">\n                    <label class=\"control-label input-label\" for=\"startTime\">Block Incoming Calls After Cap Is Reached:</label>\n                    <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                    <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': settingToggleBlockCallsIfCappeddata==0}\" (click)=\"settingToggleBlockCallsIfCappedvaledit(0)\">\n                          <input class=\"form-check-input\" name=\"settingToggleBlockCallsIfCapped\" formControlName=\"settingToggleBlockCallsIfCapped\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                          Global\n                        </label>\n                        <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': settingToggleBlockCallsIfCappeddata==1}\" (click)=\"settingToggleBlockCallsIfCappedvaledit(1)\">\n                          <input class=\"form-check-input\" name=\"settingToggleBlockCallsIfCapped\" formControlName=\"settingToggleBlockCallsIfCapped\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                           Allow\n                        </label>\n                        <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': settingToggleBlockCallsIfCappeddata==2}\" (click)=\"settingToggleBlockCallsIfCappedvaledit(2)\">\n                          <input class=\"form-check-input\" name=\"settingToggleBlockCallsIfCapped\" formControlName=\"settingToggleBlockCallsIfCapped\" type=\"radio\" id=\"option3\" [value]=\"2\">\n                           Block\n                        </label>\n                      </div>\n             </div>\n              </div>\n\n              <div class=\"form-group\">\n              <div class=\"control-group\">\n                    <label class=\"control-label input-label\" for=\"startTime\">Access To Recordings:</label>\n                    <div class=\"btn-group form-control\" data-toggle=\"buttons\">\n                    <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': settingToggleAccessToRecordingsvaldata==0}\" (click)=\"settingToggleAccessToRecordingsvaledit(0)\">\n                          <input class=\"form-check-input\" name=\"settingToggleAccessToRecordings\" formControlName=\"settingToggleAccessToRecordings\" type=\"radio\" id=\"option1\" [value]=\"0\">\n                          Global\n                        </label>\n                        <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': settingToggleAccessToRecordingsvaldata==1}\" (click)=\"settingToggleAccessToRecordingsvaledit(1)\">\n                          <input class=\"form-check-input\" name=\"settingToggleAccessToRecordings\" formControlName=\"settingToggleAccessToRecordings\" type=\"radio\" id=\"option2\" [value]=\"1\">\n                           Enabled\n                        </label>\n                        <label class=\"btn btn-primary form-check-label\" [ngClass]=\"{'active': settingToggleAccessToRecordingsvaldata==2}\" (click)=\"settingToggleAccessToRecordingsvaledit(2)\">\n                          <input class=\"form-check-input\" name=\"settingToggleAccessToRecordings\" formControlName=\"settingToggleAccessToRecordings\" type=\"radio\" id=\"option3\" [value]=\"2\">\n                           Disabled\n                        </label>\n                      </div>\n              </div>\n\n              <div class=\"control-group mt-2\">\n                <label>Status</label>\n                 <select formControlName=\"status\" name=\"status\" id=\"status\" class=\"form-control\" [value]=\"''\">\n                   <option value=\"1\">Active</option>\n                   <option value=\"0\">In-Active</option>\n                 </select>\n              </div>\n\n              </div>\n             </div>\n     </div>\n        <div class=\"modal-footer\" style=\"padding: 0;\">\n         <!-- !addLabelForm.valid || -->\n           <button (click)=\"closeEditModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Update Publisher</button>\n           <button data-dismiss=\"modal\" aria-label=\"Close\" class=\"btn btn-secondary m-t-15 waves-effect\">Close</button>\n          </div>\n      </form>\n    </div>\n  </div>\n</div>\n</div>\n";

/***/ }),

/***/ 33008:
/*!********************************************************************************!*\
  !*** ./src/app/modules/publishers/thankyou/thankyou.component.html?ngResource ***!
  \********************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "<div class=\"mt-5\">\n    <div class=\"container\" >\n      <div class=\"row text-center\">\n        <div class=\"col-md-12 mt-5\">\n          <img alt=\"image\" width=\"250px\" src=\"./assets/img/logo.png\" class=\"header-logo mb-5  mt-5 mb-0\">\n          <h6 class=\"text-white\">Thank you for Publisher Registration, Please check your mail.</h6>\n          <h6 class=\"text-white\">Visit dialdigit.com to learn more about Dialdigits</h6>\n          <div class=\"mt-5\">\n            <h6><a [routerLink]=\"'/publisher-registration/'+company\" routerLinkActive=\"router-link-active\" class=\"btn btn-primary\" >Back to Publisher Registration</a></h6>\n          </div>\n        </div>\n      </div>\n  \n    </div>\n  </div>";

/***/ }),

/***/ 38025:
/*!*************************************************************************!*\
  !*** ./src/app/modules/recordings/recordings.component.html?ngResource ***!
  \*************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n      <div class=\"main-content\">  \n        <section class=\"section\">\n          <div class=\"section-body\">\n            <div class=\"row\">\n              <div class=\"col-12\">\n                <div class=\"card\">\n                  <div class=\"row\">\n                      <div class=\"col-9\">\n                          <div class=\"card-header\">\n                          <h4>All Recordings</h4></div>\n                      </div>\n                      <div class=\"col-3 text-right mt-2\">\n                         <div class=\"form-group\"  style=\"margin-right: 28px;padding: 3px;font-size: 14px;\">\n                          <button (click)=\"exportdata()\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-2\"><i class=\"fas fa-file-export\"></i> Export\n                          </button>                     \n                            </div>                       \n                      </div>\n                \n                  </div> \n                  <form  (ngSubmit)=\"loadcalls()\">\n                  <div class=\"row\" style=\"margin-top: 10px;margin-left: 11px;\" > \n                  <div class=\"col-3\">\n                    <input type=\"text\" [(ngModel)]=\"numbers\" [ngModelOptions]=\"{standalone: true}\" class=\"form-control\" placeholder=\"Search Call Records\" >\n               \n                  </div>               \n                  <div class=\"col-8\">\n                    <input type=\"text\"\n                    ngxDaterangepickerMd\n                    [(ngModel)]=\"selected\" [ngModelOptions]=\"{standalone: true}\"\n                    [showCustomRangeLabel]=\"true\"\n                    [alwaysShowCalendars]=\"alwaysShowCalendars\"\n                    [ranges]=\"ranges\"                \n                    [showCancel]=\"true\"\n                    [linkedCalendars]=\"true\"\n                    [locale]=\"{applyLabel: 'Done'}\"                \n                    [keepCalendarOpeningWithRange]=\"keepCalendarOpeningWithRange\"\n                    [showRangeLabelOnInput]=\"showRangeLabelOnInput\"\n                    class=\"form-control\"\n                    placeholder=\"Select please...\"/>\n                  </div>\n                  \n                  <div class=\"col-1\" style=\"margin-left: -22px;\">\n                    <button type=\"submit\" class=\"btn btn-success btn-lg\"><i class=\"fas fa-search\"></i></button>\n                  </div>\n                </div>\n                </form>         \n    \n                  <div class=\"card-body\">\n                    <div class=\"table-responsive\">\n                    <table #dataTable class=\"table table-striped dataTable no-footer row-border hover\">\n                        <thead>\n                          <tr>\n                            <th>ID</th>\n                            <th>Local Number</th>\n                            <th>Remote Number</th>\n                            <th>Duration</th>\n                            <th>Recording Date</th>\n                            <th>Download</th>                                                                                    \n                          </tr>\n                        </thead>\n                        <tbody *ngIf=\"datas?.length != 0\">\n                            <tr *ngFor=\"let data of datas\">\n                                <td>{{ data.uuid }}</td>\n                                <td>{{ data.did }}</td>\n                                <td>{{ data.incoming_number }}</td>\n                                <td>{{ data.call_duration }}</td>\n                                <td>{{ data.date_of_call }}</td>  \n                                <td>download</td>                             \n                            </tr>\n                        </tbody>\n                        <tbody *ngIf=\"datas?.length == 0\">\n                          <tr>\n                            <td colspan=\"6\" class=\"no-data-available\">No data Available!</td>\n                          </tr>\n                        <tbody>\n                      </table>\n                    </div>\n                  </div>\n                </div>\n              </div>\n            </div>\n          </div>\n        </section>\n        \n      </div>  ";

/***/ }),

/***/ 94624:
/*!*****************************************************************************************!*\
  !*** ./src/app/modules/reports-comparison/reports-comparison.component.html?ngResource ***!
  \*****************************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n\n<div class=\"modal fade\" id=\"addLabels\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n aria-hidden=\"true\">\n <div class=\"modal-dialog\" role=\"document\">\n   <div class=\"modal-content\">\n     <div class=\"modal-header\">\n       <h5 class=\"modal-title\" id=\"formModal\">Export Call Details</h5>\n       <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n         <span aria-hidden=\"true\">&times;</span>\n       </button>\n     </div>\n     <div class=\"modal-body\">\n         <div class=\"row\">\n           <div class=\"col-md-12\">\n          <div class=\"form-group\">\n             <label>Select Number of Record you want to export</label>\n             <select name=\"\" [(ngModel)]=\"noofrecords\" id=\"\" class=\"form-control\">\n               <option value=\"500\">500</option>\n               <option value=\"1000\" selected>1000</option>\n               <option value=\"5000\">5000</option>\n               <option value=\"10000\">10000</option>\n             </select>\n          </div>\n\n      </div>\n        </div>\n    \n         <div class=\"modal-footer\" style=\"padding: 0;\">\n            <button (click)=\"exportdata()\" type=\"button\" class=\"btn btn-primary m-t-15 waves-effect\">Export</button>\n            <button  type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\" data-dismiss=\"modal\" aria-label=\"Close\">Close</button>\n          </div>\n     </div>\n   </div>\n </div>\n </div>   \n\n<div class=\"main-content\">  \n\n    <section class=\"pb-0\">\n          \n    </section>\n  \n    <section>\n      <div class=\"card\">\n        <div class=\"\">\n          <div class=\"row\">\n            <div class=\"card-header pb-0 border-bottom-0\">\n            <div class=\"col-md-1 col-sm-1\">\n              <h6 (click)=\"togglepanel()\" style=\"font-size: 14px;\"><i class=\"material-icons\" >settings</i> <span>Today</span></h6>\n            </div>\n            <div class=\"col-md-3 text-right\" style=\"display: -webkit-inline-box;\">\n                <div class=\"input-group\">\n                <input type=\"text\" ngxDaterangepickerMd\n                      (datesUpdated)=\"setdate($event,1)\"\n                      [(ngModel)]=\"selected\"\n                      [ngModelOptions]=\"{getterSetter: true, updateOn: 'blur',timezone: 'utc'}\"\n                      [showCustomRangeLabel]=\"true\"\n                      [alwaysShowCalendars]=\"alwaysShowCalendars\"\n                      [ranges]=\"ranges\"    \n                      [showCancel]=\"true\"\n                      [linkedCalendars]=\"true\"\n                      [locale]=\"{applyLabel: 'Done'}\"                \n                      [keepCalendarOpeningWithRange]=\"keepCalendarOpeningWithRange\"\n                      class=\"form-control\"\n                      placeholder=\"Select please...\"/>\n                      <label class=\"input-group-btn\" for=\"txtDate\" style=\"padding: 0 14px 0 14px;\">\n                      <span class=\"fas fa-calendar\"></span>                      \n                      </label>\n              </div>\n            </div>\n           \n            <div class=\"col-md-3 text-right\" style=\"display: -webkit-inline-box;\">\n                <div class=\"input-group\">\n                <input type=\"text\" ngxDaterangepickerMd\n                      (datesUpdated)=\"setdate($event,2)\"\n                      [(ngModel)]=\"selected_2\"\n                      [ngModelOptions]=\"{getterSetter: true, updateOn: 'blur',timezone: 'utc'}\"\n                      [showCustomRangeLabel]=\"true\"\n                      [alwaysShowCalendars]=\"alwaysShowCalendars\"\n                      [ranges]=\"ranges\"    \n                      [showCancel]=\"true\"\n                      [linkedCalendars]=\"true\"\n                      [locale]=\"{applyLabel: 'Done'}\"                \n                      [keepCalendarOpeningWithRange]=\"keepCalendarOpeningWithRange\"\n                      class=\"form-control\"\n                      placeholder=\"Select please...\"/>\n                      <label class=\"input-group-btn\" for=\"txtDate\" style=\"padding: 0 14px 0 14px;\">\n                      <span class=\"fas fa-calendar\"></span>                      \n                      </label>\n              </div>              \n            </div>\n\n            <div class=\"col-md-1\">\n                <input type=\"button\" (click)=\"filterval(1)\" class=\"btn btn-primary\" style=\"height: 31px;display: inline-grid;margin-bottom: 7px;\" value=\"Submit\">\n            </div>\n            <!-- <div class=\"col-md-4\">\n              <div class=\"input-group\">\n                <input type=\"text\" name=\"\" [(ngModel)]=\"labelval\" [ngModelOptions]=\"{standalone: true}\" style=\"margin-top: -6px;\" class=\"form-control\" id=\"\" placeholder=\"Enter Report Name\">\n                <span class=\"error\" *ngIf=\"islabelvaltext=='yes'\">Please Select Report Name</span>\n                <button style=\"margin-top: -7px;\n                width: 34px;\n                padding: 0;\n                height: 32px;\" (click)=\"savelabel()\" class=\"btn btn-primary\"><i class=\"fa fa-save\"></i></button>\n                <button *ngIf=\"isreport==1\" style=\"margin-top: -7px;\n                width: 34px;\n                padding: 0;\n                height: 32px;\" (click)=\"deletelabel()\" class=\"btn btn-danger\"><i class=\"fa fa-trash\"></i></button>\n              </div>\n            </div> -->\n            <!-- <div class=\"col-md-1\"></div> -->\n            <div class=\"col-md-1 text-right\">\n              <p (click)=\"togglepanel()\"><i  class=\"fas fa-filter\"></i> Filters</p>\n        \n            </div>\n          </div>\n          \n        </div>\n        <div class=\"card-body\" *ngIf=\"isclick==1\" style=\"border-top: 1px solid #f0f1f1;\">\n          <button type=\"button\" class=\"btn btn-primary btn-icon icon-left mr-2\" (click)=\"filterdata(1)\">\n            <i class=\"fa fa-filter\"></i> Campaign <span class=\"badge badge-transparent\">Click To Apply</span>\n          </button>\n          <button type=\"button\" class=\"btn btn-primary btn-icon icon-left mr-2\" (click)=\"filterdata(2)\">\n            <i class=\"fa fa-filter\"></i> Target <span class=\"badge badge-transparent\">Click To Apply</span>\n          </button>\n          <button type=\"button\" class=\"btn btn-primary btn-icon icon-left mr-2\" (click)=\"filterdata(3)\">\n            <i class=\"fa fa-filter\"></i> Buyer <span class=\"badge badge-transparent\">Click To Apply</span>\n          </button>\n          <button type=\"button\" class=\"btn btn-primary btn-icon icon-left mr-2\" (click)=\"filterdata(4)\">\n            <i class=\"fa fa-filter\"></i> Publisher <span class=\"badge badge-transparent\">Click To Apply</span>\n          </button>\n          <button type=\"button\" class=\"btn btn-primary btn-icon icon-left mr-2\" (click)=\"filterdata(5)\">\n            <i class=\"fa fa-filter\"></i> Caller ID <span class=\"badge badge-transparent\">Click To Apply</span>\n          </button>\n          <button type=\"button\" class=\"btn btn-primary btn-icon icon-left mr-2\" (click)=\"filterdata(6)\">\n            <i class=\"fa fa-filter\"></i> Number Called <span class=\"badge badge-transparent\">Click To Apply</span>\n          </button>\n          <button type=\"button\" class=\"btn btn-primary btn-icon icon-left mr-2\" (click)=\"filterdata(8)\">\n            <i class=\"fa fa-filter\"></i> IVR Input <span class=\"badge badge-transparent\">Click To Apply</span>\n          </button>\n          \n          <button type=\"button\" class=\"btn btn-primary btn-icon icon-left mr-2\" (click)=\"filterdata(9)\">\n            <i class=\"fa fa-filter\"></i> Ringtree <span class=\"badge badge-transparent\">Click To Apply</span>\n          </button>\n                  \n         <form  (ngSubmit)=\"filterval()\">\n\n          <div class=\"mt-2\" *ngIf=\"filter==1\" style=\"display: flex;\">\n            <div *ngFor=\"let item of filterselected;let i=index\" style=\"padding: 4px;\">\n            \n              <button type=\"button\" *ngIf=\"item.isorand==0 && i!=0\" class=\"btn btn-primary btn-sm\" style=\"font-size: 11px; margin-right: 7px;\">OR</button>             \n\n              <button type=\"button\" *ngIf=\"item.isorand==1 && i!=0\" class=\"btn btn-primary btn-sm\" style=\"font-size: 11px;margin-right: 7px;\">AND</button>             \n\n              <button type=\"button\" (click)=\"clearfilter(i)\" class=\"btn btn-secondary btn-sm\" style=\"font-size: 11px;\">\n                <span *ngIf=\"item.filtertype==1\">Campaign is: </span>\n                <span *ngIf=\"item.filtertype==2\">Target is: </span>\n                <span *ngIf=\"item.filtertype==3\">Buyer is: </span>\n                <span *ngIf=\"item.filtertype==4\">Publisher is: </span>\n                \n                <span *ngIf=\"item.filtertype==5\">Caller ID is: </span>\n                <span *ngIf=\"item.filtertype==6\">Number Called is: </span>\n                {{item.name}} <span class=\"fa fa-times\"></span>\n              </button>               \n            </div>                                  \n          </div>                  \n\n          <div class=\"row mt-2\" *ngIf=\"filter==1\">\n            <div class=\"col-md-3\" *ngIf=\"filtertype==1 && isselectElement==0\">\n              <!-- <select class=\"form-control\" [(ngModel)]=\"filtervalue\" (change)=\"gettext($event,1)\" [ngModelOptions]=\"{standalone: true}\">\n                <option value=\"\">{{filtertext}}</option>\n                <optgroup label=\"Active\">\n                  <option *ngFor=\"let item of activeresultdata\" [value]=\"item.id\">{{item.text}}</option>\n                </optgroup>\n                <optgroup label=\"In-Active\">\n                  <option *ngFor=\"let item of nonactiveresultdata\" [value]=\"item.id\">{{item.text}}</option>\n                </optgroup>\n              </select>   -->\n              <ng-select2  [data]=\"activeresultdata\" [width]=\"330\" [placeholder]=\"filtertext\"  [(ngModel)]=\"filtervalue\" (valueChanged)=\"gettext($event,1)\" [ngModelOptions]=\"{standalone: true}\">\n              </ng-select2>\n            </div>           \n            <div class=\"col-md-3\" *ngIf=\"filtertype!=1 && filtertype!=5 && filtertype!=6 && isselectElement==0\">\n              <!-- <select class=\"form-control\" [(ngModel)]=\"filtervalue\" (change)=\"gettext($event,1)\" [ngModelOptions]=\"{standalone: true}\">\n                <option value=\"\">{{filtertext}}</option>\n                <option *ngFor=\"let item of resultdata\" [value]=\"item.id\">{{item.text}}</option>\n              </select>        -->\n              <ng-select2  [data]=\"resultdata\" [width]=\"330\" [placeholder]=\"filtertext\" [(ngModel)]=\"filtervalue\" (valueChanged)=\"gettext($event,1)\" [ngModelOptions]=\"{standalone: true}\">\n              </ng-select2>\n            </div>\n          \n            <div class=\"col-md-3\" *ngIf=\"(filtertype==6 || filtertype==5) && isselectElement==0\">\n              <input type=\"text\" name=\"filtervalue\" class=\"form-control\" id=\"\" [(ngModel)]=\"filtervalue\" (change)=\"gettext($event,2)\">\n            </div>\n\n            <div class=\"col-md-3\" *ngIf=\"isselectElement==0\">\n              <button type=\"button\" style=\"width: 83px;font-size: 8px;height: 32px;\" (click)=\"addorrule()\" class=\"btn btn-primary btn-sm\">ADD OR RULE</button>     \n              <button type=\"button\" style=\"margin-left:5px;width: 83px;font-size: 8px;height: 32px;\" (click)=\"addandrule()\" class=\"btn btn-primary btn-sm\">ADD AND RULE</button>     \n            </div>            \n          </div>\n          \n          <div class=\"row mt-2 border-top\" *ngIf=\"filter==1\">\n            <div class=\"col-md-1\" style=\"margin-top: 13px;\">\n              <button *ngIf=\"isadded==1\" style=\"width: 83px;\" type=\"submit\" class=\"btn btn-primary btn-sm\">Add Filter</button>\n              <button type=\"button\" *ngIf=\"isadded==0\" (click)=\"editfilter()\" style=\"width: 83px;\" type=\"submit\" class=\"btn btn-primary btn-sm\">Edit Filter</button>\n            </div>\n            <div class=\"col-md-2\" style=\"margin-top: 15px;\">\n              <button style=\"width: 82px;\" (click)=\"calcelfilter()\" class=\"btn btn-outline-danger btn-sm\">Clear Filter</button>\n            </div>\n          </div>\n          </form>\n        \n        </div>\n      </div>  \n         \n         <div class=\"card-body\" style=\"border-top: 1px solid #2f3031\">\n            \n          <!-- Chart -->\n          <div class=\"\" style=\"position: relative\">\n            <ngx-ui-loader [loaderId]=\"'loader-03'\"></ngx-ui-loader>\n\n            <div class=\"row\"  *ngIf=\"ischart == 1\">\n              <div class=\"col-md-9 col-sm-9\">\n                <h6>Reporting</h6>\n              </div>          \n              <div class=\"col-md-3 col-sm-3 text-right\">\n                  <button (click)=\"chartby(1)\" class=\"tabsbtn\" [ngClass]=\"{'activetab': daytypeval === 1}\"\n                  >By Hour</button>            \n                  <button (click)=\"chartby(2)\" class=\"tabsbtn\" [ngClass]=\"{'activetab': daytypeval === 2}\">By Date</button>            \n                \n            </div>            \n          </div>\n\n            <div [chart]=\"chart\"></div>\n          </div>\n\n          \n\n          <div style=\"position: relative\">\n            <ngx-ui-loader [loaderId]=\"'loader-02'\"></ngx-ui-loader>\n            <div *ngIf=\"callsdata?.length != 0\">\n          <div style=\"border-top: 1px solid #2f3031\"></div>\n          <h6 class=\"pt-2 pb-2\">Summary</h6>\n          <div class=\"p-0 border-top-1\" >\n            \n              <div class=\"row\">\n                <div class=\"col-md-12 col-sm-12\" style=\"display: inherit;\">\n                  <div class=\"input-group\">\n\n                  <input type=\"button\" value=\"Campaign\" id=\"tabs1\" (click)=\"getSummary(1)\" class=\"tabsbtn activetab\">  \n                  <input type=\"button\" value=\"Publisher\" id=\"tabs2\" (click)=\"getSummary(2)\" class=\"tabsbtn\">  \n                  <input type=\"button\" value=\"Target\" id=\"tabs3\" (click)=\"getSummary(3)\" class=\"tabsbtn\">  \n                  <input type=\"button\" value=\"Buyer\" id=\"tabs4\" (click)=\"getSummary(4)\" class=\"tabsbtn\">  \n                  <input type=\"button\" value=\"Dialed #\" id=\"tabs5\" (click)=\"getSummary(5)\" class=\"tabsbtn\">  \n                 \n                </div>\n                 <div class=\"input-group float-right\" style=\"display: contents;\" >\n                  <button (click)=\"exportcalldata()\" class=\"tabsbtn \"><i class=\"fas fa-file-export\"></i> Export\n                  </button>                     \n                    </div>        \n                </div>\n              </div>\n        \n                      <div class=\"table-responsive\">\n                      \n                     \n                        <table  id=\"datatable1\" datatable [dtOptions]=\"dtOptions\" [dtTrigger]=\"dtTrigger\" class=\"table table-striped dataTable no-footer row-border hover\">\n                     \n                          <thead>\n                            <tr>     \n                              <th>\n                                <span *ngIf='filtertype==1'>Campaign</span>\n                                <span *ngIf='filtertype==2'>Target</span>\n                                <span *ngIf='filtertype==3'>Buyer</span>\n                                <span *ngIf='filtertype==4'>Publisher</span>\n                                <span *ngIf='filtertype==5'>Dialed #</span>\n                                <span *ngIf='filtertype==6'>Number Pool</span>\n                                <span *ngIf='filtertype==7'>Date</span>\n                                <span *ngIf='filtertype==8'>Duplicate</span>\n                              </th>\n                              <th style=\"width: 6%;\">Incoming</th>\n                              <th style=\"width: 6%;\">Unique Calls</th>\n                              <th style=\"width: 6%;\">IVR Input</th>\n                              <th style=\"width: 5%;\">Connected</th>\n                              <th style=\"width: 5%;\">Qualified</th>\n                              <th style=\"width: 5%;\">Converted</th>\n                              <th style=\"width: 5%;\">Completed</th>\n                              <th style=\"width: 5%;\">No Answer</th>\n                              <th style=\"width: 5%;\">No Connect</th>\n                              <th style=\"width: 5%;\">Duplicate</th>\n                              <th>Payout</th>                                                                     \n                              <th>Revenue</th>                                                                     \n                              <th>Profit</th>\n                              <th>CR%</th>\n                              <th>RPC</th>\n                              <th>ACL</th>\n                              <th title=\"Average Call Length\">TCL</th>\n                            </tr>\n                          </thead>\n                          <tbody *ngIf=\"callsdata?.length != 0\">\n                              <tr *ngFor=\"let data of callsdata;let i=index\" [style.background-color]=\"i == totaldata-1 ? '' : ''\" [style.color]=\"i == totaldata-1 ? '' : ''\">\n                                  <td><span style=\"cursor: pointer;\" (click)=\"filterbyvalue(data.uuid,data.filter)\">{{ data.filter}}</span></td>\n                                  <td>{{ data.incoming}}</td>\n                                  <td>{{ data.uniquecalls}}</td>\n                                  <td>{{ data.ivr_inputs}}</td>\n                                  <td>{{ data.connected}}</td>\n                                  <td>{{ data.qualified}}</td>\n                                  <td>{{ data.converted}}</td>\n                                  <td>{{ data.completed}}</td>\n                                  <td>{{ data.no_answer }}</td>\n                                  <td>{{ data.no_connect }}</td>\n                                  <td>\n                                    <span *ngIf=\"data.duplicate=='0 | 0 | 0'\">{{ data.duplicate }}</span>                              \n                                    <span *ngIf=\"data.duplicate!='0 | 0 | 0'\" style=\"cursor: pointer;\" (click)=\"filterbyvalue(data.uuid,data.filter,1)\">{{ data.duplicate }}</span>                              \n                                  </td>\n                                  <td>$ {{ data.payout }}</td>\n                                  <td>$ {{ data.revenue }}</td>\n                                  <td>$ {{ data.profit }}</td>\n                                  <td>{{ data.cr_percent }}</td>\n                                  <td>$ {{ data.rpc }}</td>\n                                  <td title=\"Average Call Length\">{{ data.acl }}</td>\n                                  <td>{{ data.tcl }}</td>                                                    \n                              </tr>\n                          </tbody>\n                          <!-- *ngIf=\"totalcount?.length != 0\" -->\n                          <tfoot  style=\"background: #3858E7;color: white;\">\n                            <tr>\n                               <td>{{totalcount.filter}}</td>\n                               <td>{{ totalcount.incoming}}</td>\n                               <td>{{ totalcount.uniquecalls}}</td>\n                               <td>{{ totalcount.ivr_inputs}}</td>\n                               <td>{{ totalcount.connected}}</td>\n                               <td>{{ totalcount.qualified}}</td>\n                               <td>{{ totalcount.converted}}</td>\n                               <td>{{ totalcount.completed}}</td>\n                               <td>{{ totalcount.no_answer }}</td>\n                               <td>{{ totalcount.no_connect }}</td>\n                               <td>{{ totalcount.duplicate }}</td>\n                               <td>$ {{ totalcount.payout }}</td>\n                               <td>$ {{ totalcount.revenue }}</td>\n                               <td>$ {{ totalcount.profit }}</td>\n                               <td>{{ totalcount.cr_percent }}</td>\n                               <td>$ {{ totalcount.rpc }}</td>\n                               <td title=\"Average Call Length\">{{ totalcount.acl }}</td>\n                               <td>{{ totalcount.tcl }}</td>                 \n                               \n                            </tr>\n                          </tfoot>\n                          \n                          <tbody *ngIf=\"callsdata?.length == 0\">\n                            <tr>\n                              <td >No data!</td>\n                        \n                              <td style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>                              \n                            </tr>\n                          <tbody>\n                        </table>\n                      </div>\n                  \n          </div>\n\n          \n          </div>\n          <div *ngIf=\"callsdata?.length == 0\">\n            No Data\n            </div>\n        </div>\n        </div>\n\n      </div>      \n    </section>\n\n  </div>  \n\n\n";

/***/ }),

/***/ 29375:
/*!*************************************************************************************!*\
  !*** ./src/app/modules/reports/report-calls/report-calls.component.html?ngResource ***!
  \*************************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n      <div class=\"main-content\">  \n        <section class=\"section\">\n          <div class=\"section-body\">\n            <div class=\"row\">\n              <div class=\"col-12\">\n                <div class=\"card\">\n                  <form [formGroup]=\"CallReportForm\" (ngSubmit)=\"onCallReportSubmit()\">\n                  <div class=\"row\" style=\"margin-top: 20px;\n                  \">\n                      <div class=\"col-2\">\n                          <div class=\"card-header\">\n                          <h4>Call Reports</h4></div>\n                      </div>\n                      <!-- <div class=\"col-md-2\">\n                        <input type=\"text\" class=\"form-control\" ngxDaterangepickerMd\n                        [singleDatePicker]=\"true\" formControlName=\"start_date\"\n                        [autoApply]=\"true\" \n                         class=\"form-control\"\n                        placeholder=\"Select Start Date...\" />\n                      </div>\n                      <div class=\"col-md-2\">\n                        <input type=\"text\" class=\"form-control\" ngxDaterangepickerMd\n                        [singleDatePicker]=\"true\" formControlName=\"end_date\"\n                        [autoApply]=\"true\" \n                         class=\"form-control\"\n                        placeholder=\"Select End Date...\" />\n                      </div> -->\n                     \n                      <div class=\"col-3\">\n                        <input type=\"text\"\n                        formControlName=\"date\"\n                        ngxDaterangepickerMd\n                        [ranges]=\"ranges\"                \n                        class=\"form-control\"\n                        placeholder=\"Select please...\"/>\n                      </div>\n\n                      <div class=\"col-md-2\">\n                        <select formControlName=\"label\" class=\"form-control\">\n                            <option value=\"\">Select Label</option>\n                            <option *ngFor=\"let data of alllabel\" value=\"{{data.itemName}}\">{{data.itemName}}</option>\n                        </select>\n                      </div>\n                      <div class=\"col-md-2\">\n                        <button class=\"btn btn-primary\" type=\"submit\">Get Chart</button>\n                      </div>\n                     \n                      <!-- <div class=\"col-md-2 mt-3\">\n                        <a class=\"pl-5\" href=\"#\" data-toggle=\"collapse\" data-target=\"#collapseExample\" aria-expanded=\"false\" aria-controls=\"collapseExample\">\n                           More Option\n                          </a>\n                      </div> -->\n                  </div>    \n            <div class=\"collapse\" id=\"collapseExample\">\n            <hr>\n            <div class=\"p-2\">\n               <div class=\"row\">\n                  <div class=\"col-md-2\">\n                    <select formControlName=\"duration_type\" class=\"form-control\">\n                        <option value=\"\">Select Type</option>\n                        <option value=\">\">Greater Than</option>\n                        <option value=\"<\">Less Than</option>\n                        <option value=\"=\">Equal To</option>                        \n                    </select>\n                  </div>\n                  <div class=\"col-md-2\">\n                    <input formControlName=\"duration\" type=\"text\" class=\"form-control\" class=\"form-control\" placeholder=\"Enter Duration...\" />\n                  </div>\n               </div>\n            </div>\n            <hr>\n            </div>        \n            </form>     \n              <div class=\"card-body\">\n                <br>\n                <div [chart]=\"chart\"></div>\n                <br>\n                <table #dataTable class=\"table table-striped dataTable no-footer row-border hover\">\n                  <thead>\n                    <tr>\n                      <th>Call Date</th>    \n                      <th>Label Name\t</th>\n                      <th># of Calls</th>\n                      <th>Total Duration</th>\n                      <th>Avg Duration</th>\n                      <th>IVR key press</th>\n                      <th>Revenue</th>\n                    </tr>\n                  </thead>\n                  <tbody *ngIf=\"numbers?.length != 0\">\n                      <tr *ngFor=\"let data of numbers\">\n                        <td>{{ data.created_at}}</td>                         \n                        <td>{{ data.label }}</td>\n                        <td>{{ data.noofcalls }}</td>\n                        <td>{{ data.call_duration }}</td>\n                        <td>{{ data.avg }}</td>\n                        <td>{{ data.ivr_inputs }}</td>                         \n                        <td>{{ data.revenue }}</td>                         \n                    \n                      </tr>\n                  </tbody>\n                  <tbody *ngIf=\"numbers?.length == 0\">\n                    <tr>\n                      <td colspan=\"8\" class=\"no-data-available\">No data Available!</td>\n                    </tr>\n                  <tbody>\n                </table>\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n    </section>\n</div>  ";

/***/ }),

/***/ 83128:
/*!***************************************************************************************************!*\
  !*** ./src/app/modules/reports/report-labelsummary/report-labelsummary.component.html?ngResource ***!
  \***************************************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n      <div class=\"main-content\">  \n        <section class=\"section\">\n          <div class=\"section-body\">\n            <div class=\"row\">\n              <div class=\"col-12\">\n                <div class=\"card\">\n                  <form [formGroup]=\"CallReportForm\" (ngSubmit)=\"onCallReportSubmit()\">\n                  <div class=\"row\" style=\"margin-top: 20px;\n                  \">\n                      <div class=\"col-2\">\n                          <div class=\"card-header\">\n                          <h4>Call Reports</h4></div>\n                      </div>\n                      <!-- <div class=\"col-md-2\">\n                        <input type=\"text\" class=\"form-control\" ngxDaterangepickerMd\n                        [singleDatePicker]=\"true\" formControlName=\"start_date\"\n                        [autoApply]=\"true\" \n                         class=\"form-control\"\n                        placeholder=\"Select Start Date...\" />\n                      </div>\n                      <div class=\"col-md-2\">\n                        <input type=\"text\" class=\"form-control\" ngxDaterangepickerMd\n                        [singleDatePicker]=\"true\" formControlName=\"end_date\"\n                        [autoApply]=\"true\" \n                         class=\"form-control\"\n                        placeholder=\"Select End Date...\" />\n                      </div> -->\n                      <div class=\"col-3\">\n                        <input type=\"text\"\n                        formControlName=\"date\"\n                        ngxDaterangepickerMd\n                        [ranges]=\"ranges\"                \n                        class=\"form-control\"\n                        placeholder=\"Select please...\"/>\n                      </div>\n\n                      <div class=\"col-md-2\">\n                        <select formControlName=\"label\" class=\"form-control\">\n                            <option value=\"\">Select Label</option>\n                            <option *ngFor=\"let data of alllabel\" value=\"{{data.itemName}}\">{{data.itemName}}</option>\n                        </select>\n                      </div>\n                      <div class=\"col-md-2\">\n                        <button class=\"btn btn-primary\" type=\"submit\">Get Chart</button>\n                      </div>\n                     \n                      <!-- <div class=\"col-md-2 mt-3\">\n                        <a class=\"pl-5\" href=\"#\" data-toggle=\"collapse\" data-target=\"#collapseExample\" aria-expanded=\"false\" aria-controls=\"collapseExample\">\n                           More Option\n                          </a>\n                      </div> -->\n                  </div>    \n            <div class=\"collapse\" id=\"collapseExample\">\n            <hr>\n            <div class=\"p-2\">\n               <div class=\"row\">\n                  <div class=\"col-md-2\">\n                    <select formControlName=\"duration_type\" class=\"form-control\">\n                        <option value=\"\">Select Type</option>\n                        <option value=\">\">Greater Than</option>\n                        <option value=\"<\">Less Than</option>\n                        <option value=\"=\">Equal To</option>                        \n                    </select>\n                  </div>\n                  <div class=\"col-md-2\">\n                    <input formControlName=\"duration\" type=\"text\" class=\"form-control\" class=\"form-control\" placeholder=\"Enter Duration...\" />\n                  </div>\n               </div>\n            </div>\n            <hr>\n            </div>        \n            </form>     \n              <div class=\"card-body\">\n                <br>\n                <div [chart]=\"chart\"></div>\n                <br>\n                <table #dataTable class=\"table table-striped dataTable no-footer row-border hover\">\n                  <thead>\n                    <tr>\n                      <th>Call Date</th>\n                      <th>Label Name\t</th>\n                      <th># of Calls</th>\n                      <th>Total Duration</th>\n                      <th>Avg Duration</th>\n                      <th>IVR key press</th> \n                      <th>Revenue</th>                     \n                    </tr>\n                  </thead>\n                  <tbody *ngIf=\"numbers?.length != 0\">\n                      <tr *ngFor=\"let data of numbers\">\n                          <td>{{ data.created_at}}</td>\n                          <td>{{ data.label }}</td>\n                          <td>{{ data.noofcalls }}</td>\n                          <td>{{ data.call_duration }}</td>\n                          <td>{{ data.avg }}</td>\n                          <td>{{ data.ivr_inputs }}</td>  \n                          <td>{{ data.revenue }}</td>                        \n                      </tr>\n                  </tbody>\n                  <tbody *ngIf=\"numbers?.length == 0\">\n                    <tr>\n                      <td colspan=\"8\" class=\"no-data-available\">No data Available!</td>\n                    </tr>\n                  <tbody>\n                </table>\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n    </section>\n</div>  ";

/***/ }),

/***/ 24187:
/*!*******************************************************************!*\
  !*** ./src/app/modules/reports/reports.component.html?ngResource ***!
  \*******************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "<div *ngIf=\"showLoadingIndicator\">\n  <div class=\"loader\"></div>\n</div>\n\n<div class=\"modal fade\" id=\"addLabels\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n aria-hidden=\"true\">\n <div class=\"modal-dialog\" role=\"document\">\n   <div class=\"modal-content\">\n     <div class=\"modal-header\">\n       <h5 class=\"modal-title\" id=\"formModal\">Export Call Details</h5>\n       <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n         <span aria-hidden=\"true\">&times;</span>\n       </button>\n     </div>\n     <div class=\"modal-body\">\n         <div class=\"row\">\n           <div class=\"col-md-12\">\n          <div class=\"form-group\">\n             <label>Select Number of Record you want to export</label>\n             <select name=\"\" [(ngModel)]=\"noofrecords\" id=\"\" class=\"form-control\">\n               <option value=\"500\">500</option>\n               <option value=\"1000\" selected>1000</option>\n               <option value=\"5000\">5000</option>\n               <option value=\"10000\">10000</option>\n               <option value=\"30000\">30000</option>\n               <option value=\"50000\">50000</option>\n               <option value=\"100000\">100000</option>\n             </select>\n          </div>\n\n      </div>\n        </div>\n\n         <div class=\"modal-footer\" style=\"padding: 0;\">\n          <!-- !addLabelForm.valid || -->\n            <button (click)=\"exportdata()\"  data-dismiss=\"modal\" aria-label=\"Close\" type=\"button\" class=\"btn btn-primary m-t-15 waves-effect\">Export</button>\n            <!-- <button  type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\" data-dismiss=\"modal\" aria-label=\"Close\">Close</button> -->\n           </div>\n     </div>\n   </div>\n </div>\n </div>\n\n <div class=\"modal fade\" id=\"blockno\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n aria-hidden=\"true\">\n <div class=\"modal-dialog\" role=\"document\">\n   <div class=\"modal-content\">\n     <div class=\"modal-header\">\n       <h5 class=\"modal-title\" id=\"formModal\">Block Number</h5>\n       <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n         <span aria-hidden=\"true\">&times;</span>\n       </button>\n     </div>\n     <div class=\"modal-body\">\n         <div class=\"row\">\n           <div class=\"col-md-12\">\n            <div class=\"form-group\">\n              <label>Campaign <i title=\"Block the caller on this campaign\" class=\"fa fa-question-circle font-12\"></i></label>\n              <input type=\"text\" name=\"\" class=\"form-control\" id=\"\" readonly [value]=\"selectedcampaign\">\n            </div>\n          </div>\n        </div>\n         <div class=\"row\">\n           <div class=\"col-md-12\">\n            <div class=\"form-group\">\n              <label>Specify Duration(<span class=\"text-danger\">*</span>) <i title=\"Block the caller for a specific time period\" class=\"fa fa-question-circle font-12\"></i></label>\n              <input type=\"text\" name=\"\" class=\"form-control\" id=\"\" [(ngModel)]=\"blockdurationval\" [ngModelOptions]=\"{standalone: true}\">\n            </div>\n          </div>\n        </div>\n\n         <div class=\"modal-footer\" style=\"padding: 0;\">\n            <button (click)=\"submitblockno(0)\"  data-dismiss=\"modal\" aria-label=\"Close\" type=\"button\" class=\"btn btn-primary m-t-15 waves-effect\">Block Number</button>\n            <button  type=\"reset\" class=\"btn btn-primary m-t-15 waves-effect\" data-dismiss=\"modal\" aria-label=\"Close\">Close</button>\n           </div>\n     </div>\n   </div>\n </div>\n </div>\n\n <div class=\"modal fade\" id=\"blockselectedno\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n aria-hidden=\"true\">\n <div class=\"modal-dialog\" role=\"document\" style=\"min-width: 679px;\">\n   <div class=\"modal-content\">\n     <div class=\"modal-header\">\n       <h5 class=\"modal-title\" id=\"formModal\">Block Selected Numbers</h5>\n       <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n         <span aria-hidden=\"true\">&times;</span>\n       </button>\n     </div>\n     <div class=\"modal-body\">\n         <div class=\"row\">\n           <div class=\"col-md-12\">\n            <div class=\"form-group\">\n                <div class=\"table-responsive\">\n                  <table class=\"table table-bordered\">\n                    <tr style=\"background: #1b2f71;\">\n                      <th style=\"height: 37px;\">Date Time</th>\n                      <th style=\"height: 37px;\">Campaign</th>\n                      <th style=\"height: 37px;\">Number Called</th>\n                      <th style=\"height: 37px;\">Caller ID</th>\n                      <th style=\"height: 37px;\">Revenue</th>\n                      <th style=\"height: 37px;\">Payout</th>\n                    </tr>\n\n                    <tr *ngFor=\"let data of selectedrow;let i=index\">\n                      <td>{{ data.date_of_call + data.time_of_call}}</td>\n                      <td>{{ data.campaign}}</td>\n                      <td>{{ data.did}}</td>\n                      <td>{{ data.incoming_number}}</td>\n                      <td>{{ data.revenue}}</td>\n                      <td>{{ data.payout}}</td>\n                    </tr>\n                  </table>\n              </div>\n            </div>\n          </div>\n        </div>\n\n        <div class=\"row\">\n          <div class=\"col-md-12\">\n           <div class=\"form-group\">\n             <label>Specify Duration(<span class=\"text-danger\">*</span>) <i title=\"Block the caller for a specific time period\" class=\"fa fa-question-circle font-12\"></i></label>\n             <input type=\"text\" name=\"\" class=\"form-control\" id=\"\" [(ngModel)]=\"blockdurationvalselected\" [ngModelOptions]=\"{standalone: true}\">\n           </div>\n         </div>\n       </div>\n         <!-- <div class=\"row\">\n           <div class=\"col-md-12\">\n            <div class=\"form-group\">\n              <label>Specify Duration(<span class=\"text-danger\">*</span>) <i title=\"Block the caller for a specific time period\" class=\"fa fa-question-circle font-12\"></i></label>\n              <input type=\"text\" name=\"\" class=\"form-control\" id=\"\" [(ngModel)]=\"blockdurationval\" [ngModelOptions]=\"{standalone: true}\">\n            </div>\n          </div>\n        </div> -->\n\n         <div class=\"modal-footer\" style=\"padding: 0;\">\n            <button (click)=\"submitblockno(1)\"  data-dismiss=\"modal\" aria-label=\"Close\" type=\"button\" class=\"btn btn-primary m-t-15 waves-effect\">Block Selected Numbers</button>\n            <button  type=\"reset\" class=\"btn btn-primary m-t-15 waves-effect\" data-dismiss=\"modal\" aria-label=\"Close\">Close</button>\n           </div>\n     </div>\n   </div>\n </div>\n </div>\n\n\n <div class=\"modal fade\" id=\"adjustcall\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n aria-hidden=\"true\">\n <div class=\"modal-dialog\" role=\"document\">\n   <div class=\"modal-content\">\n     <div class=\"modal-header\">\n       <h5 class=\"modal-title\" id=\"formModal\">Adjust 0 call(s)</h5>\n       <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n         <span aria-hidden=\"true\">&times;</span>\n       </button>\n     </div>\n     <div class=\"modal-body\">\n         <div class=\"row\" *ngIf=\"currentUser.role!=4\">\n           <div class=\"col-md-12\">\n            <div class=\"form-group\">\n              <label *ngIf=\"currentUser.role!=3\">Revenue(<span class=\"text-danger\">*</span>) <i title=\"Please provide the amount to override the revenue amount.\" class=\"fa fa-question-circle font-12\"></i></label>\n              <label *ngIf=\"currentUser.role==3\">Payout(<span class=\"text-danger\">*</span>) <i title=\"Please provide the amount to override the revenue amount.\" class=\"fa fa-question-circle font-12\"></i></label>\n              <input type=\"text\" name=\"\" class=\"form-control\" id=\"\" [(ngModel)]=\"adjust_revenue\" [ngModelOptions]=\"{standalone: true}\">\n            </div>\n          </div>\n        </div>\n         <div class=\"row\" *ngIf=\"currentUser.role!=3\">\n           <div class=\"col-md-12\">\n            <div class=\"form-group\">\n              <label *ngIf=\"currentUser.role==4\">Revenue(<span class=\"text-danger\">*</span>) <i title=\"Please provide an optional amount to override the payout of this call.\" class=\"fa fa-question-circle font-12\"></i></label>\n              <label *ngIf=\"currentUser.role!=4\">Payout(<span class=\"text-danger\">*</span>) <i title=\"Please provide an optional amount to override the payout of this call.\" class=\"fa fa-question-circle font-12\"></i></label>\n              <input type=\"text\" name=\"\" class=\"form-control\" id=\"\" [(ngModel)]=\"adjust_payout\" [ngModelOptions]=\"{standalone: true}\">\n            </div>\n          </div>\n        </div>\n         <div class=\"row\">\n           <div class=\"col-md-12\">\n            <div class=\"form-group\">\n              <label>Reason</label>\n              <!-- <input type=\"text\" name=\"\" class=\"form-control\" id=\"\" [(ngModel)]=\"adjust_payout\" [ngModelOptions]=\"{standalone: true}\"> -->\n              <textarea name=\"\" id=\"\" cols=\"30\" class=\"form-control\" rows=\"5\" [(ngModel)]=\"adjust_reason\" [ngModelOptions]=\"{standalone: true}\"></textarea>\n            </div>\n          </div>\n        </div>\n\n         <div class=\"modal-footer\" style=\"padding: 0;\">\n            <button (click)=\"adjustcallsubmit(0)\"  data-dismiss=\"modal\" aria-label=\"Close\" type=\"button\" class=\"btn btn-primary m-t-15 waves-effect\">Update Payout/Revenue</button>\n            <button  type=\"reset\" class=\"btn btn-primary m-t-15 waves-effect\" data-dismiss=\"modal\" aria-label=\"Close\">Close</button>\n           </div>\n     </div>\n   </div>\n </div>\n </div>\n\n\n <div class=\"modal fade\" id=\"adjustcallselected\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n aria-hidden=\"true\">\n <div class=\"modal-dialog\" role=\"document\">\n   <div class=\"modal-content\">\n     <div class=\"modal-header\">\n       <h5 class=\"modal-title\" id=\"formModal\">Adjust 0 call(s)</h5>\n       <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n         <span aria-hidden=\"true\">&times;</span>\n       </button>\n     </div>\n     <div class=\"modal-body\">\n         <div class=\"row\" *ngIf=\"currentUser.role!=4\">\n           <div class=\"col-md-12\">\n            <div class=\"form-group\">\n              <div class=\"table-responsive\">\n                <table class=\"table table-bordered\">\n                  <tr style=\"background: #1b2f71;\">\n                    <th style=\"height: 37px;\">Campaign</th>\n                    <th style=\"height: 37px;\">Publisher</th>\n                    <th style=\"height: 37px;\">Number Called</th>\n                    <th style=\"height: 37px;\">Caller ID</th>\n                    <th style=\"height: 37px;\">Revenue</th>\n                    <th style=\"height: 37px;\">Payout</th>\n                  </tr>\n\n                  <tr *ngFor=\"let data of selectedrow;let i=index\">\n                    <td>{{ data.campaign}}</td>\n                    <td>{{ data.publisher}}</td>\n                    <td>{{ data.did}}</td>\n                    <td>{{ data.incoming_number}}</td>\n                    <td>{{ data.revenue}}</td>\n                    <td>{{ data.payout}}</td>\n                  </tr>\n                </table>\n            </div>\n          </div>\n            </div>\n           <div class=\"col-md-12\">\n            <div class=\"form-group\">\n              <label *ngIf=\"currentUser.role!=3\">Revenue(<span class=\"text-danger\">*</span>) <i title=\"Please provide the amount to override the revenue amount.\" class=\"fa fa-question-circle font-12\"></i></label>\n              <label *ngIf=\"currentUser.role==3\">Payout(<span class=\"text-danger\">*</span>) <i title=\"Please provide the amount to override the revenue amount.\" class=\"fa fa-question-circle font-12\"></i></label>\n              <input type=\"text\" name=\"\" class=\"form-control\" id=\"\" [(ngModel)]=\"adjust_revenue\" [ngModelOptions]=\"{standalone: true}\">\n            </div>\n          </div>\n        </div>\n         <div class=\"row\" *ngIf=\"currentUser.role!=3\">\n           <div class=\"col-md-12\">\n            <div class=\"form-group\">\n              <label *ngIf=\"currentUser.role==4\">Revenue(<span class=\"text-danger\">*</span>) <i title=\"Please provide an optional amount to override the payout of this call.\" class=\"fa fa-question-circle font-12\"></i></label>\n              <label *ngIf=\"currentUser.role!=4\">Payout(<span class=\"text-danger\">*</span>) <i title=\"Please provide an optional amount to override the payout of this call.\" class=\"fa fa-question-circle font-12\"></i></label>\n              <input type=\"text\" name=\"\" class=\"form-control\" id=\"\" [(ngModel)]=\"adjust_payout\" [ngModelOptions]=\"{standalone: true}\">\n            </div>\n          </div>\n        </div>\n         <div class=\"row\">\n           <div class=\"col-md-12\">\n            <div class=\"form-group\">\n              <label>Reason</label>\n              <!-- <input type=\"text\" name=\"\" class=\"form-control\" id=\"\" [(ngModel)]=\"adjust_payout\" [ngModelOptions]=\"{standalone: true}\"> -->\n              <textarea name=\"\" id=\"\" cols=\"30\" class=\"form-control\" rows=\"5\" [(ngModel)]=\"adjust_reason\" [ngModelOptions]=\"{standalone: true}\"></textarea>\n            </div>\n          </div>\n        </div>\n\n         <div class=\"modal-footer\" style=\"padding: 0;\">\n            <button (click)=\"adjustcallsubmit(1)\"  data-dismiss=\"modal\" aria-label=\"Close\" type=\"button\" class=\"btn btn-primary m-t-15 waves-effect\">Update Payout/Revenue</button>\n            <button  type=\"reset\" class=\"btn btn-primary m-t-15 waves-effect\" data-dismiss=\"modal\" aria-label=\"Close\">Close</button>\n           </div>\n     </div>\n   </div>\n </div>\n </div>\n\n<div class=\"main-content pt-0\">\n\n    <section class=\"pb-0\">\n\n    </section>\n\n    <section>\n      <div class=\"card\">\n        <div class=\"\">\n          <div style=\"background: #0f121a;\">\n            <div class=\"card-header pb-0 border-bottom-0\">\n            <!-- <div class=\"col-md-1 col-sm-1\">\n              <h6 (click)=\"togglepanel()\" style=\"font-size: 14px;\"><i class=\"material-icons\" >settings</i> <span>Today</span></h6>\n            </div> -->\n            <div class=\"col-md-3 pl-0\">\n                <!-- <label for=\"\">Select Date </label> -->\n                <!-- [timePicker]=\"true\" -->\n                <!-- style=\"width: max-content;\" -->\n                <div class=\"input-group mb-2\" >\n                  <input type=\"text\" style=\"padding: 17px;color: white;\" class=\"form-control formcontrol\" placeholder=\"Please enter report name\" [(ngModel)]=\"labelval\" [ngModelOptions]=\"{standalone: true}\">\n                  <div class=\"input-group-append\">\n                    <span (click)=\"savelabel()\" class=\"input-group-text ml-2\" style=\"font-size: 12px;\n                    background: #3858E7;border: none;\n                    color: white;cursor: pointer;\">\n                      <span class=\"\">Save</span>\n                       <!-- <i *ngIf=\"isreport==1\" (click)=\"deletelabel()\" class=\"fa fa-trash\"></i> -->\n                    </span>\n                  </div>\n                  <button *ngIf=\"isreport==1\" class=\"btn btn-danger btn-sm ml-2\" style=\"width: 30px; padding: 0;\">\n                    <i (click)=\"deletelabel()\" class=\"fa fa-trash\"></i>\n                  </button>\n                </div>\n                <!-- <span class=\"error\" *ngIf=\"islabelvaltext=='yes'\">Please Select Report Name</span>  -->\n\n\n\n            </div>\n            <div class=\"col-md-3 col-sm-6\" style=\"display: contents;\">\n\n              <div class=\"input-group\">\n                <input type=\"text\" ngxDaterangepickerMd\n                      [timePicker]=\"true\"\n                      [timePicker24Hour]=\"true\"\n                      (datesUpdated)=\"filterval($event)\"\n                      [(ngModel)]=\"selected\"\n                      [ngModelOptions]=\"{getterSetter: true, updateOn: 'blur',timezone: 'utc'}\"\n                      [showCustomRangeLabel]=\"true\"\n                      [alwaysShowCalendars]=\"false\"\n                      [ranges]=\"ranges\"\n                      [showCancel]=\"true\"\n                      [disabled]=\"isloading\"\n                      [linkedCalendars]=\"true\"\n                      [locale]=\"{applyLabel: 'Apply', format: 'MM-DD-YYYY HH:mm'}\"\n                      [keepCalendarOpeningWithRange]=\"true\"\n                      class=\"form-control daterangepicker\"\n                      placeholder=\"Select please...\"\n                      [the]\n                      />\n                      <label class=\"input-group-btn\" for=\"txtDate\" style=\"padding: 4px 9px 2px 9px;background: #3e4464;\n                      border: none;\">\n                      <span class=\"fas fa-calendar\"></span>\n                      </label>\n              </div>\n\n              <!-- <div class=\"input-group\"> -->\n            <!-- <div class=\"row\">\n              <div class=\"col-md-6\"> -->\n                <!-- <input type=\"text\" name=\"\" [(ngModel)]=\"labelval\" [ngModelOptions]=\"{standalone: true}\" style=\"margin-top: -6px;\" class=\"form-control\" id=\"\" placeholder=\"Enter Report Name\">\n                <span class=\"error\" *ngIf=\"islabelvaltext=='yes'\">Please Select Report Name</span> -->\n              <!-- </div>\n              <div class=\"col-md-6\"> -->\n                <!-- <input type=\"button\" style=\"font-size: 15px;margin-top: -11px;\" (click)=\"savelabel()\" value=\"Save\" class=\"btn btn-primary\"> -->\n\n\n                    <!-- <input *ngIf=\"isreport==1\" type=\"button\" style=\"font-size: 15px;margin-top: -11px;margin-left: 5px;\" (click)=\"deletelabel()\" value=\"Delete\" class=\"btn btn-danger\"> -->\n\n              <!-- </div> -->\n              <!-- </div> -->\n            </div>\n            <div class=\"col-md-3 mb-1 p-0 p-md-2\" style=\"bottom: 2px;\">\n\n              <angular2-multiselect  [data]=\"allusers\" [(ngModel)]=\"userselectedvalue\" (ngModelChange)=\"getuser()\" [settings]=\n              \"{\n                enableSearchFilter: true,\n                classes: 'filterdd',\n                showCheckbox:false,\n                singleSelection: true, text:'Select User',groupBy:'category'}\" [ngModelOptions]=\"{standalone: true}\"></angular2-multiselect>\n            </div>\n\n            <div class=\"col-md-1 d-flex\">\n              <button class=\"btn btn-primary btn-sm\" placement=\"right\" ngbTooltip=\"Reload\" (click)=\"reload()\" style=\"width: fit-content;\n              padding: 7px;\n              background: #3858e7;\n              margin-top: -8px;\">\n                <i class=\"material-icons\">refresh</i>\n              </button>\n              <button class=\"btn btn-primary btn-sm ml-2 \" placement=\"right\" ngbTooltip=\"Start Tour\" style=\"width: fit-content;\n              padding: 7px;\n              background: #3858e7;\n              margin-top: -8px;\">\n                <i style=\"font-size: 10px;\" class=\"fa fa-graduation-cap\"></i>\n              </button>\n\n            </div>\n            <div class=\"col-md-2\">\n              Updated  <span>{{refresh_date | timeAgo}}</span>\n            </div>\n\n            <!-- <div class=\"col-md-1\"></div>\n            <div class=\"col-md-1 text-right\">\n              <p (click)=\"togglepanel()\"><i  class=\"fas fa-filter\"></i> Filters</p>\n\n            </div> -->\n          </div>\n\n        </div>\n\n        <!-- <span class=\"badge badge-transparent\">Click To Apply</span> -->\n\n        <div class=\"card-body\" *ngIf=\"isclick==1\" style=\"border-top: 1px solid #2c2c2c;padding-top: 10px;padding-bottom: 10px;background: #0f121a;\">\n          <button type=\"button\" class=\"btn btn-primary btn-icon icon-left mr-2 mb-1\" (click)=\"filterdata(1)\" *ngIf=\"currentUser.role!=4\">\n            <i class=\"fa fa-filter\"></i> CAMPAIGN\n          </button>\n          <button type=\"button\" class=\"btn btn-primary btn-icon icon-left mr-2 mb-1\" (click)=\"filterdata(2)\">\n            <i class=\"fa fa-filter\"></i> TARGET\n          </button>\n          <button type=\"button\" class=\"btn btn-primary btn-icon icon-left mr-2 mb-1\" (click)=\"filterdata(3)\" *ngIf=\"currentUser.role!=4 && currentUser.role!=3\">\n            <i class=\"fa fa-filter\"></i> BUYER\n          </button>\n          <button type=\"button\" class=\"btn btn-primary btn-icon icon-left mr-2 mb-1\" (click)=\"filterdata(4)\" *ngIf=\"currentUser.role!=4 && currentUser.role!=3\">\n            <i class=\"fa fa-filter\"></i> PUBLISHER\n          </button>\n          <button type=\"button\" class=\"btn btn-primary btn-icon icon-left mr-2 mb-1\" (click)=\"filterdata(5)\" *ngIf=\"currentUser.role!=3\">\n            <i class=\"fa fa-filter\"></i> CALLER ID\n          </button>\n          <button type=\"button\" class=\"btn btn-primary btn-icon icon-left mr-2 mb-1\" (click)=\"filterdata(6)\" *ngIf=\"currentUser.role!=4\">\n            <i class=\"fa fa-filter\"></i> NUMBER CALLED\n          </button>\n          <button type=\"button\" class=\"btn btn-primary btn-icon icon-left mr-2 mb-1\" (click)=\"filterdata(8)\" *ngIf=\"currentUser.role!=4 && currentUser.role!=3\">\n            <i class=\"fa fa-filter\"></i> IVR INPUT\n          </button>\n\n          <button type=\"button\" class=\"btn btn-primary btn-icon icon-left mr-2 mb-1\" (click)=\"filterdata(9)\" *ngIf=\"currentUser.role!=4 && currentUser.role!=3\">\n            <i class=\"fa fa-filter\"></i> RINGTREE\n          </button>\n\n          <button type=\"button\" class=\"btn btn-primary btn-icon icon-left mr-2 mb-1\" (click)=\"filterdata(10)\" *ngIf=\"currentUser.role!=4 && currentUser.role!=3\">\n            <i class=\"fa fa-filter\"></i> DURATION\n          </button>\n\n          <!-- <button type=\"button\" class=\"btn btn-primary btn-icon icon-left mr-2\" (click)=\"togglepanel()\">\n            <i class=\"fa fa-filter\"></i> Filter\n          </button> -->\n        </div>\n        <div class=\"card-body\" *ngIf=\"isclick==0 || istougle==0\" style=\"border-top: 1px solid #2c2c2c;padding-top: 0px;padding-bottom: 0px;background: #0f121a;\">          \n         <form  (ngSubmit)=\"filterval()\">\n\n          <div  *ngIf=\"filter==1\" style=\"display: flex;flex-wrap: wrap;\">\n            <div class=\"mt-2\" *ngFor=\"let item of filterselected;let i=index\" style=\"padding: 4px;\">\n              <!-- <div *ngIf=\"item.isorand==0 && i!=0\" class=\"separator\">OR</div>\n              <div *ngIf=\"item.isorand==1 && i!=0\" class=\"separator\">AND</div> -->\n\n              <button type=\"button\" *ngIf=\"item.isorand==0 && i!=0\" class=\"btn btn-primary btn-sm\" style=\"font-size: 11px; margin-right: 7px;\">OR</button>\n\n              <button type=\"button\" *ngIf=\"item.isorand==1 && i!=0\" class=\"btn btn-primary btn-sm\" style=\"font-size: 11px;margin-right: 7px;\">AND</button>\n\n              <button type=\"button\" (click)=\"clearfilter(i)\" class=\"btn btn-secondary btn-sm\" style=\"font-size: 11px;    background: #232840;\n              padding: 6px 12px;\n              border: none;\">\n                <!-- <span *ngIf=\"item.filtertype==1\">Campaign is: </span>\n                <span *ngIf=\"item.filtertype==2\">Target is: </span>\n                <span *ngIf=\"item.filtertype==3\">Buyer is: </span>\n                <span *ngIf=\"item.filtertype==4\">Publisher is: </span>\n\n                <span *ngIf=\"item.filtertype==5\">Caller ID is: </span>\n                <span *ngIf=\"item.filtertype==6\">Number Called is: </span>\n                {{item.name}} <span class=\"fa fa-times\"></span> -->\n                <span *ngIf=\"item.containfiltertype==0\">Filter - <span *ngIf=\"filtertype!=10\">Name -</span> {{item.filterlabel}} - <small>{{item.containfiltertext}}</small>&nbsp;&nbsp; <b>{{item.name}}</b>&nbsp; <span class=\"fa fa-times\"></span></span>\n                <span *ngIf=\"item.containfiltertype==1\">Filter - ID - {{item.filterlabel}} - <small>{{item.containfiltertext}}</small>&nbsp;&nbsp; <b>{{item.name}}</b>&nbsp; <span class=\"fa fa-times\"></span></span>\n              </button>\n            </div>\n          </div>\n          <div class=\"leftborder pb-1 pb-3\" *ngIf=\"filter==1 && isselectElement==0\" style=\"position: relative\">\n          <ngx-ui-loader [loaderId]=\"'loader-04'\"></ngx-ui-loader>\n          <div class=\"row\" >\n             <!-- <select class=\"form-control\" [(ngModel)]=\"filtervalue\" (change)=\"gettext($event,1)\" [ngModelOptions]=\"{standalone: true}\">\n                <option value=\"\">{{filtertext}}</option>\n                <optgroup label=\"Active\">\n                  <option *ngFor=\"let item of activeresultdata\" [value]=\"item.id\">{{item.text}}</option>\n                </optgroup>\n                <optgroup label=\"In-Active\">\n                  <option *ngFor=\"let item of nonactiveresultdata\" [value]=\"item.id\">{{item.text}}</option>\n                </optgroup>\n              </select>   -->\n\n              <!-- <ng-select2  [data]=\"activeresultdata\" [width]=\"330\" [placeholder]=\"filtertext\"  [(ngModel)]=\"filtervalue\" (valueChanged)=\"gettext($event,1)\" [ngModelOptions]=\"{standalone: true}\">\n              </ng-select2> -->\n           <!-- <select class=\"form-control\" [(ngModel)]=\"filtervalue\" (change)=\"gettext($event,1)\" [ngModelOptions]=\"{standalone: true}\">\n                <option value=\"\">{{filtertext}}</option>\n                <option *ngFor=\"let item of resultdata\" [value]=\"item.id\">{{item.text}}</option>\n              </select>    -->\n\n              <!-- <ng-select2  [data]=\"resultdata\" [width]=\"330\" [placeholder]=\"filtertext\" [(ngModel)]=\"filtervalue\" (valueChanged)=\"gettext($event,1)\" [ngModelOptions]=\"{standalone: true}\"> -->\n              <!-- </ng-select2> -->\n            <!-- (filtertype==1 || filtertype==2) &&  -->\n\n            <div class=\"col-md-4 pb-1\" *ngIf=\"isselectElement==0\">\n              <select class=\"form-control\" [(ngModel)]=\"containfiltertype\" (change)=\"getcontainfilter($event,1)\" [ngModelOptions]=\"{standalone: true}\">\n                <option value=\"0\">Filter - <span *ngIf=\"filtertype!=10\">Name -</span> {{filterlabel}}</option>\n                <option value=\"1\" *ngIf=\"filtertype!=10\">Filter - ID - {{filterlabel}}</option>\n              </select>\n            </div>\n            <div class=\"col-md-4 pb-1\" *ngIf=\"isselectElement==0\">\n              <select class=\"form-control\" [(ngModel)]=\"filteradvanced\" (change)=\"getadvancedfilter($event,1)\" [ngModelOptions]=\"{standalone: true}\">\n                <option value=\"2\" *ngIf=\"filtertype!=10\">Contains</option>\n                <option value=\"3\" *ngIf=\"filtertype!=10\">Does Not contain</option>\n                <option value=\"4\" *ngIf=\"filtertype!=10\">Begins With</option>\n                <option value=\"5\" *ngIf=\"filtertype!=10\">Does Not Begin With</option>\n                <option value=\"6\" *ngIf=\"filtertype==10\">Greater Than</option>\n                <option value=\"7\" *ngIf=\"filtertype==10\">Less Than</option>\n                <option value=\"0\" *ngIf=\"filtertype!=10\">Equals Single Value</option>\n                <option value=\"1\" *ngIf=\"filtertype!=10\">Does Not Equal Single Value</option>\n              </select>\n            </div>\n\n            <div class=\"col-md-4 pb-1\" *ngIf=\"filtertype!=6 && filtertype!=5 && filtertype!=10 && filtertype==1 && isselectElement==0 && (filteradvanced==0 || filteradvanced==1)\">\n              <angular2-multiselect [data]=\"resultdata\" [(ngModel)]=\"filtervalue\" [settings]=\n              \"{\n                enableSearchFilter: true,\n                classes: 'filterdd',\n                showCheckbox:false,\n                singleSelection: true, text:filtertext}\" [ngModelOptions]=\"{standalone: true}\"></angular2-multiselect>\n            </div>\n\n            <div class=\"col-md-4 pb-1\" *ngIf=\"filtertype!=6 && filtertype!=5 && filtertype!=10 && filtertype!=1 && isselectElement==0 && (filteradvanced==0 || filteradvanced==1)\">\n              <angular2-multiselect [data]=\"resultdata\"   [(ngModel)]=\"filtervalue\" [settings]=\n              \"{\n                enableSearchFilter: true,\n                classes: 'filterdd',\n                showCheckbox:false,\n                singleSelection: true, text:filtertext}\" [ngModelOptions]=\"{standalone: true}\"></angular2-multiselect>\n            </div>\n\n            <div class=\"col-md-4 pb-1\" *ngIf=\"filtertype==6 || filtertype==5 || filtertype==10 || (isselectElement==0  && (filteradvanced!=0 && filteradvanced!=1))\">\n              <input type=\"text\" placeholder=\"Enter Value\" name=\"filtervalue\" class=\"form-control formcontrol\" id=\"\" [(ngModel)]=\"filtervalue\" (change)=\"gettext($event,2)\">\n            </div>\n\n            <!-- <div class=\"col-md-3\" *ngIf=\"filtertype==1 && isselectElement==0\">\n              <angular2-multiselect [data]=\"activeresultdata\" [(ngModel)]=\"filtervalue\" [settings]=\n              \"{\n                enableSearchFilter: true,\n                classes: 'myclass custom-class-example',\n                showCheckbox:false,\n                singleSelection: true, text:filtertext}\" [ngModelOptions]=\"{standalone: true}\"></angular2-multiselect>\n            </div>\n\n            <div class=\"col-md-3\" *ngIf=\"filtertype!=1 && filtertype!=5 && filtertype!=6 && isselectElement==0\">\n              <angular2-multiselect [data]=\"resultdata\"   [(ngModel)]=\"filtervalue\" [settings]=\n              \"{\n                enableSearchFilter: true,\n                classes: 'myclass custom-class-example',\n                showCheckbox:false,\n                singleSelection: true, text:filtertext}\" [ngModelOptions]=\"{standalone: true}\"></angular2-multiselect>\n            </div>\n\n            <div class=\"col-md-3\" *ngIf=\"(filtertype==6 || filtertype==5) && isselectElement==0\">\n              <input type=\"text\" name=\"filtervalue\" class=\"form-control\" id=\"\" [(ngModel)]=\"filtervalue\" (change)=\"gettext($event,2)\">\n            </div> -->\n          </div>\n\n          <div class=\"row mt-1\">\n            <div class=\"col-md-12\" *ngIf=\"isselectElement==0\">\n              <button type=\"button\" style=\"width: 100px;font-size: 8px;height: 32px;background: #3858e7;border: none;\" (click)=\"addorrule()\" class=\"btn btn-primary btn-sm\"><i class=\"fa fa-plus\" style=\"font-size: 9px;\"></i>  OR RULE</button>\n              <button type=\"button\" style=\"margin-left:5px;width: 100px;font-size: 8px;height: 32px;border: none;background: #3858e7;\" (click)=\"addandrule()\" class=\"btn btn-primary btn-sm\"><i class=\"fa fa-plus\" style=\"font-size: 9px;\"></i>  AND RULE</button>\n              <button type=\"button\" style=\"margin-left:5px;width: 100px;font-size: 8px;height: 32px;border: none;\" (click)=\"togglepanel()\" class=\"btn btn-primary btn-sm\"><i class=\"fa fa-plus\" style=\"font-size: 9px;\"></i>  Filter</button>\n            </div>\n          </div>\n        </div>\n          <div class=\"row mt-1 mb-1\" *ngIf=\"filter==1\">\n            <div class=\"col-md-4 d-flex pb-1\">\n              <button [disabled]=\"filtervalue==''\" *ngIf=\"isadded==1 && filtervalue==''\" style=\"width: 160px;font-size: 11px!important;cursor: not-allowed;border: 1px solid green!important;\" type=\"submit\" class=\"btn btn-primary btn-sm\">APPLY UPDATED FILTERS</button>\n              <button *ngIf=\"isadded==1 && filtervalue!=''\" style=\"width: 160px;font-size: 11px!important;\" type=\"submit\" class=\"btn btn-primary btn-sm\">APPLY UPDATED FILTERS</button>\n              <button type=\"button\" *ngIf=\"isadded==0\" (click)=\"editfilter()\" style=\"width: 120px;\" type=\"submit\" class=\"btn btn-primary btn-sm\">EDIT FILTERS</button>\n              <button style=\"width: 140px;\" (click)=\"calcelfilter()\" class=\"ml-2 btn btn-outline-danger btn-sm\">CLEAR FILTERS</button>\n            </div>\n          </div>\n          </form>\n        </div>\n\n      </div>\n\n        <div class=\"card-body\" style=\"border-top: 1px solid #2f3031\">\n          <!-- Chart -->\n          <div class=\"\" style=\"position: relative\">\n            <!-- <ngx-ui-loader [loaderId]=\"'loader-03'\"></ngx-ui-loader> -->\n            <ng-template #foregroundSpinner>\n              <div class=\"sk-chase\">\n                <div class=\"sk-chase-dot customLoaderId\"></div>\n              </div>\n            </ng-template>\n            <ngx-ui-loader\n              [loaderId]=\"loader.loaderId\"\n              [fgsTemplate]=\"foregroundSpinner\"\n              [bgsTemplate]=\"backgroundSpinner\"\n              [fgsSize]=\"loader.fgsSize\"\n              [bgsSize]=\"loader.bgsSize\"\n              [text]=\"loader.text\"\n              [gap]=\"loader.gap\"\n            ></ngx-ui-loader>\n\n            <div class=\"row\">\n              <div class=\"col-md-9 col-sm-6\">\n                <h6>Reporting</h6>\n              </div>\n              <div class=\"col-md-3 col-sm-6 text-right\">\n                  <button *ngIf=\"isshowbyhrs==1\" (click)=\"chartby(1)\" class=\"tabsbtn\" [ngClass]=\"{'activetab': daytypeval === 1}\"\n                  >By Hour</button>\n                  <button (click)=\"chartby(2)\" class=\"tabsbtn\" [ngClass]=\"{'activetab': daytypeval === 2}\">By Day</button>\n\n            </div>\n          </div>\n\n            <div [chart]=\"chart\"></div>\n          </div>\n\n          <h6>Summary</h6>\n          <!-- summary -->\n          <div class=\"p-0 border-top-1\" style=\"position: relative\">\n              <!-- <ngx-ui-loader [loaderId]=\"'loader-02'\"></ngx-ui-loader> -->\n              <ng-template #foregroundSpinner1>\n                <div class=\"sk-chase\">\n                  <div class=\"sk-chase-dot customLoaderId\"></div>\n                </div>\n              </ng-template>\n              <ngx-ui-loader\n                [loaderId]=\"loader.loaderId1\"\n                [fgsTemplate]=\"foregroundSpinner1\"\n              ></ngx-ui-loader>\n              <div class=\"row\">\n                <div class=\"col-md-12 col-sm-12\" style=\"display: inherit;\">\n                  <div class=\"input-group\">\n                  <input *ngIf=\"currentUser.role!=4\" type=\"button\" value=\"Campaign\" id=\"tabs1\" (click)=\"getSummary(1)\" class=\"tabsbtn activetab\">\n                  <input *ngIf=\"currentUser.role!=4 && currentUser.role!=3\" type=\"button\" value=\"Publisher\" id=\"tabs2\" (click)=\"getSummary(2)\" class=\"tabsbtn\">\n                  <input *ngIf=\"currentUser.role!=3\" type=\"button\" value=\"Target\" id=\"tabs3\" (click)=\"getSummary(3)\" class=\"tabsbtn\">\n                  <input *ngIf=\"currentUser.role!=4  && currentUser.role!=3\" type=\"button\" value=\"Buyer\" id=\"tabs4\" (click)=\"getSummary(4)\" class=\"tabsbtn\">\n                  <input *ngIf=\"currentUser.role!=4\" type=\"button\" value=\"Dialed #\" id=\"tabs5\" (click)=\"getSummary(5)\" class=\"tabsbtn\">\n                  <!-- <input *ngIf=\"currentUser.role!=4  && currentUser.role!=3\" type=\"button\" value=\"IVR Input All\" id=\"tabs7\" (click)=\"getSummary(7)\" class=\"tabsbtn\">\n                  <input *ngIf=\"currentUser.role!=4  && currentUser.role!=3\" type=\"button\" value=\"IVR Input\" id=\"tabs8\" (click)=\"getSummary(8)\" class=\"tabsbtn\">   -->\n                  <angular2-multiselect *ngIf=\"currentUser.role!=4  && currentUser.role!=3\"  [data]=\"alltags\" id=\"tabs9\" style=\"width: auto;\" class=\"tabsbtn\" [(ngModel)]=\"tagselectedvalue\" (ngModelChange)=\"gettags()\" [settings]=\n                  \"{\n                    enableSearchFilter: true,\n                    classes: 'filtertags',\n                    showCheckbox:false,\n                    singleSelection: true, text:'Tags',groupBy:'category'}\" [ngModelOptions]=\"{standalone: true}\"></angular2-multiselect>\n\n                </div>\n                 <div class=\"input-group float-right\" style=\"display: contents;\" >\n                  <button (click)=\"exportcalldata()\" class=\"tabsbtn \"><i class=\"fas fa-file-export\"></i> Export\n                  </button>\n                  </div>\n                </div>\n              </div>\n              <!-- <div class=\"row\">\n                <div class=\"col-12\">\n                  <div class=\"card\">\n\n                    <div class=\"card-body\"> -->\n                      <div class=\"table-responsive\">\n\n\n                        <!-- <table  id=\"datatable1\" datatable [dtOptions]=\"dtOptions\" [dtTrigger]=\"dtTrigger\" class=\"table table-striped dataTable no-footer row-border hover\"> -->\n                      <!-- <table class=\"table table-striped dataTable no-footer row-border hover\" datatable [dtOptions]=\"dtOptions\" [dtTrigger]=\"dtTrigger\"> -->\n\n                      <!-- <table #dataTable1 id=\"datatable\" class=\"table table-striped dataTable no-footer row-border hover\"> -->\n                        <table #dataTable1  class=\"table table-striped dataTable no-footer row-border hover\" datatable [dtOptions]=\"dtOptions\" [dtTrigger]=\"dtTrigger\">\n                          <!-- <table #dataTable1 [dtOptions]=\"dtOptions\" [dtTrigger]=\"dtTrigger\" class=\"row-border hover\"> -->\n                            <!-- <table id='table' #dataTable1 [dtOptions]=\"dtOptions\" class=\"table table-striped table-bordered\" cellspacing=\"0\" width=\"100%\"> -->\n\n                          <thead>\n                            <tr>\n                              <th style=\"width:fit-content\">\n                                <span *ngIf='filtertype==1'>Campaign</span>\n                                <span *ngIf='filtertype==2'>Target</span>\n                                <span *ngIf='filtertype==3'>Buyer</span>\n                                <span *ngIf='filtertype==4'>Publisher</span>\n                                <span *ngIf='filtertype==5'>Dialed #</span>\n                                <span *ngIf='filtertype==6'>Number Pool</span>\n                                <span *ngIf='filtertype==7'>IVR Input</span>\n                                <span *ngIf='filtertype==8'>Key</span>\n                                <span *ngIf='filtertype==9 && tagselectedvalue?.length>0'>{{tagselectedvalue[0].category}} : {{tagselectedvalue[0].name}}</span>\n                              </th>\n                              <th>Incoming</th>\n                              <th>Unique Calls</th>\n                              <th *ngIf=\"currentUser.role!=4\">IVR Input</th>\n\n                              <th *ngIf=\"currentUser.role!=3\">Reached to Buyer</th>\n                              <th>Connected</th>\n                              <th>Qualified</th>\n                              <th>Converted</th>\n                              <th>Completed</th>\n                              <th>No Answer</th>\n                              <th>No Connect</th>\n                              <th>Duplicate</th>\n                              <th>Blocked</th>\n                              <th *ngIf=\"currentUser.role!=4\">Payout</th>\n                              <th *ngIf=\"currentUser.role!=3\">Revenue</th>\n                              <th *ngIf=\"currentUser.role!=4 && currentUser.role!=3\">Profit</th>\n                              <th>CR%</th>\n                              <th>RPC</th>\n                              <th>ACL</th>\n                              <th title=\"Average Call Length\">TCL</th>\n                            </tr>\n                          </thead>\n                          <tbody *ngIf=\"callsdata?.length != 0\">\n                            <!-- #55646b -->\n                            <!-- #fff -->\n                              <tr *ngFor=\"let data of callsdata;let i=index\" [style.background-color]=\"i == totaldata-1 ? '' : ''\" [style.color]=\"i == totaldata-1 ? '' : ''\">\n                                  <td style=\"width: 50%;\"><span style=\"cursor: pointer;overflow: hidden;\n\n                                    max-width: 100px;\" (click)=\"filterbyvalue(data.uuid,data.filter)\">{{ data.filter=='n'? 'none': data.filter}}</span></td>\n                                  <td>{{ data.incoming}}</td>\n                                  <td>{{ data.uniquecalls}}</td>\n                                  <!-- <td>\n                                    <span *ngIf=\"data.ivr_inputs==0\">{{ filtertype!=8 ? data.ivr_inputs: '-' }}</span>\n                                    <span  *ngIf=\"data.ivr_inputs>0\" style=\"cursor: pointer;\" (click)=\"filterbyvalue(data.uuid,data.filter,6)\">{{ filtertype!=8 ? data.ivr_inputs : '-'}}</span>\n                                  </td> -->\n\n                                  <td *ngIf=\"currentUser.role!=4\"><span style=\"cursor: pointer;\" (click)=\"filterbyvalue(data.uuid,data.filter,6)\">{{ filtertype!=8 ? data.ivr_inputs : '-'}}</span></td>\n\n                                  <!-- <td>{{ filtertype!=8 ? data.ivr_inputs: '-'}}</td> -->\n                                  <!-- <td>{{ filtertype!=8 ? data.reachedtobuyer : '-'}}</td> -->\n                                  <td *ngIf=\"currentUser.role!=3\"><span style=\"cursor: pointer;\" (click)=\"filterbyvalue(data.uuid,data.filter,7)\">{{ filtertype!=8 ? data.reachedtobuyer : '-'}}</span></td>\n\n                                  <td><span style=\"cursor: pointer;\" (click)=\"filterbyvalue(data.uuid,data.filter,2)\">{{ filtertype!=8 ? data.connected : '-'}}</span></td>\n                                  <td>\n                                    <span *ngIf=\"data.qualified==0\">{{ filtertype!=8 ? data.qualified: '-' }}</span>\n                                    <span  *ngIf=\"data.qualified>0\" style=\"cursor: pointer;\" (click)=\"filterbyvalue(data.uuid,data.filter,3)\">{{ filtertype!=8 ? data.qualified : '-'}}</span>\n                                  </td>\n                                  <td>\n                                    <span *ngIf=\"data.converted==0\">{{ filtertype!=8 ? data.converted: '-' }}</span>\n                                    <span  *ngIf=\"data.converted>0\" style=\"cursor: pointer;\" (click)=\"filterbyvalue(data.uuid,data.filter,3)\">{{ filtertype!=8 ? data.converted : '-'}}</span>\n                                  </td>\n\n                                  <td><span style=\"cursor: pointer;\" (click)=\"filterbyvalue(data.uuid,data.filter,2)\">{{ filtertype!=8 ? data.completed : '-'}}</span></td>\n\n                                  <td>\n                                    <span *ngIf=\"data.no_answer==0\">{{ filtertype!=8 ? data.no_answer: '-' }}</span>\n                                    <span  *ngIf=\"data.no_answer>0\" style=\"cursor: pointer;\" (click)=\"filterbyvalue(data.uuid,data.filter,4)\">{{ filtertype!=8 ? data.no_answer : '-'}}</span>\n                                  </td>\n\n                                  <!-- <td>\n                                    <span *ngIf=\"data.no_connect==0\">{{ filtertype!=8 ? data.no_connect: '-' }}</span>\n                                    <span  *ngIf=\"data.no_connect>0\" style=\"cursor: pointer;\" (click)=\"filterbyvalue(data.uuid,data.filter,5)\">{{ filtertype!=8 ? data.no_connect : '-'}}</span>\n                                  </td> -->\n\n                                  <td><span style=\"cursor: pointer;\" (click)=\"filterbyvalue(data.uuid,data.filter,5)\">{{ filtertype!=8 ? data.no_connect : '-'}}</span></td>\n\n                                  <!-- <td>{{ filtertype!=8 ? data.no_answer : '-'}}</td> -->\n                                  <!-- <td>{{ filtertype!=8 ? data.no_connect : '-'}}</td> -->\n                                  <td>\n                                    <span *ngIf=\"data.duplicate==0\">{{ filtertype!=8 ? data.duplicate: '-' }}</span>\n                                    <span *ngIf=\"data.duplicate>0\" style=\"cursor: pointer;\" (click)=\"filterbyvalue(data.uuid,data.filter,1)\">{{ filtertype!=8 ? data.duplicate: '-' }}</span>\n                                  </td>\n                                  <td>{{ data.blocked }}</td>\n                                  <td *ngIf=\"currentUser.role!=4\">$ {{ filtertype!=8 ? data.payout: 0 }}</td>\n                                  <td *ngIf=\"currentUser.role!=3\">$ {{ filtertype!=8 ? data.revenue: 0 }}</td>\n                                  <td *ngIf=\"currentUser.role!=4 && currentUser.role!=3\">$ {{ filtertype!=8 ? data.profit: 0 }}</td>\n                                  <td>{{ filtertype!=8 ? data.cr_percent: '-' }}</td>\n                                  <td>$ {{ filtertype!=8 ? data.rpc: 0 }}</td>\n                                  <td title=\"Average Call Length\">{{ filtertype!=8 ? data.acl: '-' }}</td>\n                                  <td>{{ filtertype!=8 ? data.tcl: '-' }}</td>\n                              </tr>\n                          </tbody>\n                          <tfoot *ngIf=\"totalcount?.length != 0\" style=\"background: #3858E7;color: white;\">\n                            <tr>\n                               <td style=\"width: 100px!important;\">{{totalcount.filter}}</td>\n                               <td>{{ totalcount.incoming}}</td>\n                               <td>{{ totalcount.uniquecalls}}</td>\n                               <td *ngIf=\"currentUser.role!=4\">{{ filtertype!=8 ? totalcount.ivr_inputs :'-'}}</td>\n                               <td *ngIf=\"currentUser.role!=3\">{{ filtertype!=8 ? totalcount.reachedtobuyer: '-'}}</td>\n                               <td>{{ filtertype!=8 ? totalcount.connected: '-'}}</td>\n                               <td>{{ filtertype!=8 ? totalcount.qualified: '-'}}</td>\n                               <td>{{ filtertype!=8 ? totalcount.converted: '-'}}</td>\n                               <td>{{ filtertype!=8 ? totalcount.completed: '-'}}</td>\n                               <td>{{ filtertype!=8 ? totalcount.no_answer: '-' }}</td>\n                               <td>{{ filtertype!=8 ? totalcount.no_connect : '-'}}</td>\n                               <td>{{ filtertype!=8 ? totalcount.duplicate: '-' }}</td>\n                               <td>{{ filtertype!=8 ? totalcount.blocked: '-' }}</td>\n                               <td *ngIf=\"currentUser.role!=4\">$ {{ filtertype!=8 ? totalcount.payout: '0' }}</td>\n                               <td *ngIf=\"currentUser.role!=3\">$ {{ filtertype!=8 ? totalcount.revenue: '0' }}</td>\n                               <td *ngIf=\"currentUser.role!=4 && currentUser.role!=3\">$ {{ filtertype!=8 ? totalcount.profit: '0' }}</td>\n                               <td>{{ filtertype!=8 ? totalcount.cr_percent: '-' }}</td>\n                               <td>$ {{ filtertype!=8 ? totalcount.rpc : '0'}}</td>\n                               <td title=\"Average Call Length\">{{ filtertype!=8 ? totalcount.acl: '-' }}</td>\n                               <td>{{ filtertype!=8 ? totalcount.tcl: '-' }}</td>\n\n                            </tr>\n                          </tfoot>\n\n                          <tbody *ngIf=\"callsdata?.length == 0\">\n                            <tr>\n                              <td >No data!</td>\n\n                              <td *ngIf=\"currentUser.role!=4\" style=\"display: none\"></td>\n                              <td *ngIf=\"currentUser.role!=4\" style=\"display: none\"></td>\n                              <td *ngIf=\"currentUser.role!=4\" style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>\n                              <td style=\"display: none\"></td>\n                            </tr>\n                          <tbody>\n                        </table>\n                      </div>\n                    <!-- </div>\n                  </div>\n                </div>\n              </div> -->\n          </div>\n\n          <!-- list -->\n          <!-- <div class=\"row\">\n            <div class=\"col-12\">\n              <div class=\"card\"> -->\n\n\n                <!-- <div class=\"row\" style=\"margin-top: 20px;\">\n\n                    <div class=\"col-7\">\n                        <div class=\"card-header\">\n                        <h4>Call Details</h4></div>\n                    </div>\n                    <div class=\"col-4 text-right mt-2\">\n                       <div class=\"form-group\">\n                        <button data-toggle=\"modal\" data-target=\"#addLabels\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-2\"><i class=\"fas fa-file-export\"></i> Export\n                        </button>\n                         (click)=\"exportdata()\"\n                          </div>\n                    </div>\n                </div>  -->\n                <!-- <div style=\"border-top: 1px solid #2f3031;margin-top: 17px;\"></div> -->\n                <h6 class=\"pb-2 pt-2\">Call Details</h6>\n                <div class=\"row mt-2 mb-3\">\n\n                  <div class=\"col-md-12 col-sm-12\" style=\"display: inherit;\">\n                    <div class=\"input-group\">\n\n                      <!-- <input type=\"button\" value=\"Call List\" id=\"calltabs1\" (click)=\"getcallDetails(1)\" class=\"tabsbtn activetab\">\n                      <input type=\"button\" value=\"Live Calls\" id=\"calltabs2\" (click)=\"getcallDetails(2)\" class=\"tabsbtn\">   -->\n\n                  </div>\n                   <div class=\"input-group float-right\" style=\"display: contents;\" >\n                    <!-- data-toggle=\"modal\" data-target=\"#addLabels\" -->\n                    <button (click)=\"exportdata()\" class=\"tabsbtn mr-2\"><i class=\"fas fa-file-export\"></i> Export\n                    </button>\n                    <button *ngIf=\"currentUser.role!=3 && currentUser.role!=4\" (click)=\"blockselectedno()\" title=\"Block Number\" class=\"tabsbtn mr-2\" style=\"width: 47px;\">\n                      <!-- data-toggle=\"modal\" data-target=\"#blockselectedno\" -->\n                      <i style=\"cursor: pointer;\"  class=\"fa fa-ban font-12\" ></i>\n                    </button>\n\n                    <button *ngIf=\"currentUser.role!=3 && currentUser.role!=4\" (click)=\"adjustcallselectedno()\" title=\"Block Number\" class=\"tabsbtn mr-2\" style=\"width: 40px;\">\n                      <!-- data-toggle=\"modal\" data-target=\"#blockselectedno\" -->\n                      <!-- <i style=\"cursor: pointer;\"  class=\"fa fa-usd font-14 mr-2\" ></i> -->\n                      <i class=\"fa fa-usd font-14\" style=\"cursor: pointer;\">$</i>\n                    </button>\n\n                    <button type=\"button\" class=\"mr-1 tabsbtn1 btn-primary\" (click)=\"scrolltox()\"> << </button>\n                    <button type=\"button\" class=\"ml-1 tabsbtn1 btn-primary\" (click)=\"scrolltoy()\"> >> </button>\n                      </div>\n                  </div>\n                </div>\n\n                <div>\n\n                  <div *ngIf=\"!islive\" id=\"wrapper1\">\n                    <div id=\"content1\" style=\"position: relative\">\n                    <!-- <ngx-ui-loader [loaderId]=\"'loader-01'\"></ngx-ui-loader> -->\n                    <ng-template #foregroundSpinner2>\n                      <div class=\"sk-chase\">\n                        <div class=\"sk-chase-dot customLoaderId\"></div>\n                      </div>\n                    </ng-template>\n                    <ngx-ui-loader\n                      [loaderId]=\"loader.loaderId2\"\n                      [fgsTemplate]=\"foregroundSpinner2\"\n                    ></ngx-ui-loader>\n                    <!-- ngxclass -->\n                    <!-- [loadingIndicator]=\"loadingIndicator\" -->\n                  <ngx-datatable #myTable\n                  [ngClass]=\"\"\n                  [offset]=\"1000\"\n                  class=\"striped expandable bordered material\"\n                  [rows]=\"calls\"\n                  [columnMode]=\"ColumnMode.force\"\n                  [headerHeight]=\"headerHeight\"\n                  [footerHeight]=\"40\"\n                  [scrollbarV]=\"true\"\n                  (scroll)=\"onScroll($event)\"\n                  [scrollbarH]=\"true\"\n                  [rowHeight]=\"rowHeight\"\n                  [selectionType]=\"SelectionType.multiClick\"\n                  [selected]=\"selectedrow\"\n                  (select)=\"onSelect($event)\"\n                  [messages]=\"{emptyMessage: 'No Record Found'}\"\n                  style=\"height: 600px;\"\n                  >\n                  <!--  -->\n                  <!-- (activate)=\"onActivate($event)\" -->\n                      <!-- Row Detail Template -->\n                  <ngx-datatable-row-detail\n                    [rowHeight]=\"auto\"\n                    #myDetailRow>\n                    <ng-template\n                      let-row=\"row\"\n                      let-expanded=\"expanded\"\n                      ngx-datatable-row-detail-template>\n                      <!-- <div style=\"padding-left:35px;display: flex;\"> -->\n                      <div class=\"appendData\" style=\"height: auto;width: 100%;\">\n                      </div>\n                    </ng-template>\n                   </ngx-datatable-row-detail>\n\n\n                    <!-- Column Templates -->\n                    <!-- <ngx-datatable-column\n                      [width]=\"50\"\n                      [resizeable]=\"false\"\n                      [sortable]=\"false\"\n                      [draggable]=\"false\"\n                      [canAutoResize]=\"false\"\n                      [frozenLeft]=\"true\"\n                      name=\">\"\n                    >\n                      <ng-template let-row=\"row\" let-expanded=\"expanded\" ngx-datatable-cell-template let-rowIndex=\"rowIndex\">\n                        <i class=\"whitestatusarrow\" ></i>\n                        <i class=\"yellowstatusarrow\" ></i>\n                        <i class=\"redstatusarrow\" ></i>\n                        <a\n                        *ngIf=\"!expanded\"\n                        href=\"javascript:void(0)\"\n                        (click)=\"toggleExpandRow(rowIndex,row)\">\n                         <i class=\"fa fa-angle-right\" ></i>\n                        </a>\n                        <a\n                          *ngIf=\"expanded\"\n                        href=\"javascript:void(0)\"\n                        (click)=\"toggleCollaspeRow(row)\">\n                          <i class=\"fa fa-angle-down\"> </i>\n                      </a>\n                      </ng-template>\n                    </ngx-datatable-column> -->\n\n\n                  <ngx-datatable-column  name=\"Date Time\" [width]=\"150\" [frozenLeft]=\"true\" [sortable]=\"true\" prop=\"time_of_call\">\n                      <ng-template  let-expanded=\"expanded\" ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                          <i *ngIf=\"row.billsec==0\" title=\"Call Not Connected\" class=\"redstatusarrow\" ></i>\n                          <i *ngIf=\"row.billsec>0\" title=\"Completed - without Conversion\" class=\"yellowstatusarrow\" ></i>\n                          <i *ngIf=\"row.revenue>0\" title=\"Converted\" class=\"whitestatusarrow\" ></i>\n                          <i *ngIf=\"row.is_live==1\" title=\"Live\" class=\"greenstatusarrow\" ></i>\n                          <a\n                          *ngIf=\"!expanded && row.is_live!=1 && currentUser.role!=4 && currentUser.role!=3\"\n                          href=\"javascript:void(0)\"\n                          (click)=\"toggleExpandRow(rowIndex,row)\">\n                           <i class=\"fa fa-angle-right\" ></i>\n                          </a>\n                          <a\n                            *ngIf=\"expanded && row.is_live!=1 && currentUser.role!=4 && currentUser.role!=3\"\n                          href=\"javascript:void(0)\"\n                          (click)=\"toggleCollaspeRow(row)\">\n                            <i class=\"fa fa-angle-down\"> </i>\n                        </a>\n                          <span class=\"ml-2\" [title]=\"row.uuid\">{{row.date_of_call}} {{row.time_of_call}}</span>\n                      </ng-template>\n                  </ngx-datatable-column>\n                  <!-- <ngx-datatable-column name=\"Campaign\">\n                      <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                          <span>{{row.campaign}}</span>\n                      </ng-template>\n                  </ngx-datatable-column>                                                                      -->\n                  <ngx-datatable-column name=\"Campaign\" [frozenLeft]=\"true\" *ngIf=\"currentUser.role!=4\">\n                    <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                      <ng-template #htmlContent >\n                        <div  (click)=\"filtercalldata(1,row.campaign_uuid,row.campaign)\"><i style=\"font-size: 10px;cursor: pointer;\" class=\"fa fa-filter mr-2\"></i></div>\n                        <div (click)=\"copyName(row.campaign)\"><i style=\"font-size: 10px;cursor: pointer;\" class=\"fa fa-copy\"></i></div>\n                        <a class=\"text-white ml-2\" target=\"_blank\" routerLink=\"/edit-campaign/{{row.campaign_uuid}}\"><i style=\"font-size: 10px;cursor: pointer;\" class=\"fa fa-edit\"></i></a>\n                      </ng-template>\n                        <div style=\"cursor: pointer;\" triggers=\"click\" [ngbTooltip]=\"htmlContent\" [autoClose]=\"true\" placement=\"top\">{{row.campaign}}</div>\n                    </ng-template>\n                </ngx-datatable-column>\n\n                  <!-- <ngx-datatable-column name=\"Number Called\">\n                      <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                          <span>{{row.did}}</span>\n                      </ng-template>\n                  </ngx-datatable-column>\n                   -->\n                  <ngx-datatable-column name=\"Number Called\" [width]=\"130\" [sortable]=\"true\" prop=\"did\">\n                    <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                        <ng-template #htmlContent >\n                          <div  (click)=\"filtercalldata(6,row.uuid,row.did)\"><i style=\"font-size: 10px;cursor: pointer;\" class=\"fa fa-filter mr-2\"></i></div>\n                          <div (click)=\"copyName(row.did)\"><i style=\"font-size: 10px;cursor: pointer;\" class=\"fa fa-copy\"></i></div>\n                        </ng-template>\n                          <div style=\"cursor: pointer;\" triggers=\"click\" [ngbTooltip]=\"htmlContent\" [autoClose]=\"true\" placement=\"top\">\n                            <!-- {{row.did}} -->\n                            ({{row.did | slice:0:3}}) {{row.did | slice:3:6}}-{{row.did | slice:6:10}}\n                          </div>\n                      </ng-template>\n                  </ngx-datatable-column>\n\n                  <ngx-datatable-column name=\"Caller ID\" [width]=\"100\" [sortable]=\"true\" prop=\"incoming_number\">\n                      <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                        <ng-template #htmlContent >\n                          <div  (click)=\"filtercalldata(5,row.uuid,row.incoming_number)\"><i style=\"font-size: 10px;cursor: pointer;\" class=\"fa fa-filter mr-2\"></i></div>\n                          <div (click)=\"copyName(row.incoming_number)\"><i style=\"font-size: 10px;cursor: pointer;\" class=\"fa fa-copy\"></i></div>\n                        </ng-template>\n                          <div style=\"cursor: pointer;\" triggers=\"click\" [ngbTooltip]=\"htmlContent\" [autoClose]=\"true\" placement=\"top\">{{row.incoming_number}}\n                          </div>\n                      </ng-template>\n                  </ngx-datatable-column>\n\n                  <ngx-datatable-column name=\"Duplicate\" [width]=\"80\" [sortable]=\"true\" prop=\"duplicate\" *ngIf=\"currentUser.role!=4\">\n                    <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                        <span>   <div *ngIf=\"row.duplicate==1\">Yes</div>\n                          <div *ngIf=\"row.duplicate==0\">No</div></span>\n                    </ng-template>\n                </ngx-datatable-column>\n\n                  <!-- <ngx-datatable-column name=\"Publisher\">\n                      <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                          <span>{{row.publisher}}</span>\n                      </ng-template>\n                  </ngx-datatable-column>                                                                      -->\n                <ngx-datatable-column name=\"Publisher\" [width]=\"100\" [sortable]=\"true\" prop=\"publisher\" *ngIf=\"currentUser.role!=4 && currentUser.role!=3\">\n                  <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                      <ng-template #htmlContent >\n                        <div  (click)=\"filtercalldata(4,row.publisher_uuid,row.publisher)\"><i style=\"font-size: 10px;cursor: pointer;\" class=\"fa fa-filter mr-2\"></i></div>\n                        <div (click)=\"copyName(row.publisher)\"><i style=\"font-size: 10px;cursor: pointer;\" class=\"fa fa-copy\"></i></div>\n                      </ng-template>\n                        <div style=\"cursor: pointer;\" triggers=\"click\" [ngbTooltip]=\"htmlContent\" [autoClose]=\"true\" placement=\"top\">{{row.publisher}}</div>\n                    </ng-template>\n                </ngx-datatable-column>\n\n                  <!-- <ngx-datatable-column name=\"Target\">\n                      <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                          <span>{{row.target}}</span>\n                      </ng-template>\n                  </ngx-datatable-column>                                                                      -->\n                  <ngx-datatable-column name=\"Target\" [width]=\"120\" [sortable]=\"true\" prop=\"target\" *ngIf=\"currentUser.role!=3\">\n                    <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                        <ng-template #htmlContent >\n                          <div  (click)=\"filtercalldata(2,row.target_uuid,row.target)\"><i style=\"font-size: 10px;cursor: pointer;\" class=\"fa fa-filter mr-2\"></i></div>\n                          <div (click)=\"copyName(row.target)\"><i style=\"font-size: 10px;cursor: pointer;\" class=\"fa fa-copy\"></i></div>\n                          <a class=\"text-white ml-2\" target=\"_blank\" routerLink=\"/edit-numbers/{{row.target_uuid}}\"><i style=\"font-size: 10px;cursor: pointer;\" class=\"fa fa-edit\"></i></a>\n                        </ng-template>\n                          <div style=\"cursor: pointer;\" triggers=\"click\" [ngbTooltip]=\"htmlContent\" [autoClose]=\"true\" placement=\"top\">{{row.target}}\n                            <br>\n                            <div >\n                              <span class=\"badge badge-primary\" style=\"padding: 6px 5px 2px 5px;margin-top: 2px;\" *ngIf=\"row.ivr_hack=='YES'\"> IVR HACK</span>\n                              <!-- <span class=\"badge badge-primary\" style=\"padding: 2px 6px 2px 5px;\"\n                              *ngIf=\"row.is_ringtree==1\">\n                               Ringtree</span> -->\n                            </div>\n                          </div>\n                      </ng-template>\n                  </ngx-datatable-column>\n\n                  <ngx-datatable-column name=\"Routed To\" [width]=\"120\" [sortable]=\"true\" prop=\"routed_to\" *ngIf=\"currentUser.role!=4 && currentUser.role!=3\">\n                      <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                          <span>{{row.routed_to}}</span>\n                      </ng-template>\n                  </ngx-datatable-column>\n                  <!--   -->\n                  <ngx-datatable-column name=\"Hangup\" [width]=\"80\"  [sortable]=\"true\" prop=\"hangup_by\" *ngIf=\"currentUser.role!=4 && currentUser.role!=3\">\n                      <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                          <span><div *ngIf=\"row.hangup_by=='System'\">\n                            <i title=\"System\" class=\"fa fa-server\"></i>\n                          </div>\n                          <div *ngIf=\"row.hangup_by=='User'\">\n                            <i title=\"Caller\" class=\"fa fa-user\"></i>\n                          </div>\n                          <div *ngIf=\"row.hangup_by==''\">-</div></span>\n                      </ng-template>\n                  </ngx-datatable-column>\n\n                  <ngx-datatable-column name=\"IVR Inputs\" [width]=\"80\" [sortable]=\"true\" prop=\"ivr_inputs\" *ngIf=\"currentUser.role!=4 && currentUser.role!=3\">\n                      <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                          <span>{{ row.ivr_inputs}}</span>\n                      </ng-template>\n                  </ngx-datatable-column>\n\n                  <ngx-datatable-column name=\"ACT Duration\" [width]=\"120\" [sortable]=\"true\" prop=\"call_duration\">\n                      <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                          <span>{{ 1000 * row.call_duration | date:'H:mm:ss':'UTC'}}</span>\n                      </ng-template>\n                  </ngx-datatable-column>\n                  <ngx-datatable-column name=\"IVR Duration\" [width]=\"120\" [sortable]=\"true\" prop=\"ivr_duration\" *ngIf=\"currentUser.role!=4 || currentUser.role!=3\">\n                      <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                          <span>{{ 1000 * row.ivr_duration | date:'H:mm:ss':'UTC'}}</span>\n                      </ng-template>\n                  </ngx-datatable-column>\n                  <ngx-datatable-column name=\"Billable Duration\" [width]=\"120\" [sortable]=\"true\" prop=\"billable_duration\">\n                      <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                          <span>{{ 1000 * row.billable_duration | date:'H:mm:ss':'UTC'}}</span>\n                      </ng-template>\n                  </ngx-datatable-column>\n                  <ngx-datatable-column name=\"Revenue\" [width]=\"120\" [sortable]=\"true\" prop=\"revenue\" *ngIf=\"currentUser.role!=4 && currentUser.role!=3\">\n                      <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                          <span>{{row.revenue}}</span>\n                      </ng-template>\n                  </ngx-datatable-column>\n                  <ngx-datatable-column name=\"Revenue\" [width]=\"120\" [sortable]=\"true\" prop=\"revenue\" *ngIf=\"currentUser.role==4\">\n                      <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                          <span>{{row.revenue}}</span>\n                      </ng-template>\n                  </ngx-datatable-column>\n                  <ngx-datatable-column name=\"Payout\" [width]=\"120\" [sortable]=\"true\" prop=\"payout\" *ngIf=\"currentUser.role==3\">\n                      <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                          <span>{{row.payout}}</span>\n                      </ng-template>\n                  </ngx-datatable-column>\n                  <ngx-datatable-column name=\"Payout\" [width]=\"120\" [sortable]=\"true\" prop=\"payout\" *ngIf=\"currentUser.role!=3 && currentUser.role!=4\">\n                      <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                          <span>{{row.payout}}</span>\n                      </ng-template>\n                  </ngx-datatable-column>\n                  <ngx-datatable-column name=\"Recording\" [frozenRight]=\"true\" [width]=\"60\" *ngIf=\"currentUser.role!=4 && currentUser.role!=3\">\n                      <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                          <span>\n                            <div *ngIf=\"row.recording!=null\" style=\"cursor: pointer;\">\n                              <i class=\"fa fa-play-circle\" (click) = \"play(row.recording, row.incoming_number)\"></i>\n                              <!-- <i class=\"fa fa-pause\"></i> -->\n                              <!-- <audio style=\"width: 130px;height: 30px;\" controls muted loop>\n                                <source src=\"https://repuatationmanagement.s3.us-west-2.amazonaws.com/{{row.recording}}\" type=\"audio/mp3\">\n                              </audio>  -->\n                            </div>\n                          </span>\n                      </ng-template>\n                  </ngx-datatable-column>\n                  <ngx-datatable-column name=\"Actions\" [frozenRight]=\"true\" [width]=\"70\" >\n                      <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                          <span>\n                            <i *ngIf=\"currentUser.role==3 || currentUser.role==4\" style=\"cursor: pointer;\">-</i>\n\n                            <i *ngIf=\"currentUser.role!=3 && currentUser.role!=4\" style=\"cursor: pointer;\" (click)=\"blockno(row.campaign,row.campaign_uuid,row.incoming_number)\" class=\"fa fa-ban font-12 mr-2\" data-toggle=\"modal\" data-target=\"#blockno\"></i>\n                            <!-- <i style=\"cursor: pointer;\" class=\"material-icons font-13 mr-2\" data-toggle=\"modal\" data-target=\"#addLabels\">edit</i> -->\n                            <i *ngIf=\"currentUser.role!=3 && currentUser.role!=4\" style=\"cursor: pointer;\" (click)=\"adjustcall(row.uuid,row.freeswitch_call_uuid,row.payoutdata)\"  class=\"fa fa-usd font-14 mr-2\" data-toggle=\"modal\" data-target=\"#adjustcall\">$</i>\n                          </span>\n                      </ng-template>\n                  </ngx-datatable-column>\n\n              </ngx-datatable>\n               <!-- <ngx-ui-loader></ngx-ui-loader> -->\n\n\n              </div>\n              </div>\n              <!-- {{livecalls}} -->\n              <!-- Display Live data -->\n              <!-- <div *ngIf=\"islive\">\n                <ngx-datatable #Table\n                class=\"striped calllive\"\n                [rows]=\"livecalls\"\n                [scrollbarH]=\"true\"\n                [headerHeight]=\"headerHeight\"\n                [footerHeight]=\"50\"\n                [rowHeight]=\"50\"\n                [messages]=\"{emptyMessage: 'No Record Found'}\"\n                >\n\n                <ngx-datatable-column name=\"Created\">\n                    <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                        <span>{{row.created}}</span>\n                    </ng-template>\n                </ngx-datatable-column>\n                <ngx-datatable-column name=\"Caller ID\">\n                    <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                        <span>{{row.cid_name}}</span>\n                    </ng-template>\n                </ngx-datatable-column>\n                <ngx-datatable-column name=\"Called Number\">\n                    <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                        <span>{{row.cid_num}}</span>\n                    </ng-template>\n                </ngx-datatable-column>\n                <ngx-datatable-column name=\"IP Address\">\n                    <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                        <span>{{row.ip_addr}}</span>\n                    </ng-template>\n                </ngx-datatable-column>\n                <ngx-datatable-column name=\"Destination\">\n                    <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                        <span>{{row.dest}}</span>\n                    </ng-template>\n                </ngx-datatable-column>\n                <ngx-datatable-column name=\"AppData\">\n                    <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                        <span>{{row.application_data}}</span>\n                    </ng-template>\n                </ngx-datatable-column>\n                <ngx-datatable-column name=\"Read codec\">\n                    <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                        <span>{{row.read_codec}}</span>\n                    </ng-template>\n                </ngx-datatable-column>\n                <ngx-datatable-column name=\"write codec\">\n                    <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                        <span>{{row.write_codec}}</span>\n                    </ng-template>\n                </ngx-datatable-column>\n                <ngx-datatable-column name=\"State\">\n                    <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                        <span>{{row.callstate}}</span>\n                    </ng-template>\n                </ngx-datatable-column>\n                <ngx-datatable-column name=\"Duration\">\n                    <ng-template ngx-datatable-cell-template let-rowIndex=\"rowIndex\" let-value=\"value\" let-row=\"row\">\n                        <span>{{row.created_epoch}}</span>\n                    </ng-template>\n                </ngx-datatable-column>\n            </ngx-datatable>\n\n\n              </div> -->\n\n\n                  <!-- <div class=\"table-responsive\">\n                  <table #dataTable id=\"example\" class=\"table table-striped dataTable no-footer row-border hover\">\n                      <thead>\n                        <tr>\n                          <th></th>\n                          <th>Date<br>Time</th>\n                          <th>Campaign</th>\n                          <th>Number<br>Called</th>\n                          <th>Caller<br>ID</th>\n                          <th>Publisher</th>\n                          <th>Target</th>\n                          <th>Routed<br>To</th>\n                          <th>Labels</th>\n                          <th>Hangup</th>\n                          <th>ACT<br>Duration\t</th>\n                          <th>IVR<br>Duration\t</th>\n                          <th>Billable<br>Duration\t</th>\n                          <th>Duplicate</th>\n                          <th>Revenue</th>\n                          <th>Payout</th>\n                          <th>Recording</th>\n                        </tr>\n                      </thead>\n                      <tbody *ngIf=\"labels?.length != 0\">\n                          <tr *ngFor=\"let data of labels;let i = index;\" class=\"detailrow_{{i}}\">\n                              <td (click)='details(i,data)' class=\"details-control\"></td>\n                              <td>{{ data.date_of_call }} {{ data.time_of_call }}</td>\n                              <td>{{ data.campaign}}</td>\n                              <td>{{ data.did}}</td>\n                              <td>{{ data.incoming_number}}</td>\n                              <td>{{ data.publisher}}</td>\n                              <td>{{ data.target}}</td>\n                              <td>{{ data.routed_to}}</td>\n                              <td><span *ngFor=\"let assosciated_label of data.assosciated_labels?.split(',')\">\n                                  <span class=\"badge badge-primary p-1 ml-1\">{{assosciated_label }}</span><br>\n                                </span>\n                              </td>\n                              <td>\n                                <div *ngIf=\"data.hangup_by=='System'\">\n                                  <i title=\"System\" class=\"fa fa-server\"></i>\n                                </div>\n                                <div *ngIf=\"data.hangup_by=='User'\">\n                                  <i title=\"Caller\" class=\"fa fa-user\"></i>\n                                </div>\n                                <div *ngIf=\"data.hangup_by==''\">-</div>\n                              </td>\n\n                              <td>{{ 1000 * data.call_duration | date:'H:mm:ss':'UTC'}}</td>\n                              <td>{{ 1000 * data.ivr_duration | date:'H:mm:ss':'UTC'}}</td>\n                              <td>{{ 1000 * data.billable_duration | date:'H:mm:ss':'UTC'}}</td>\n                              <td *ngIf=\"data.duplicate==1\">Yes</td>\n                              <td *ngIf=\"data.duplicate==0\">No</td>\n\n                              <td>{{ data.revenue }}</td>\n\n                              <td>{{ data.payout }}</td>\n                              <td>\n                              <div *ngIf=\"data.recording==null\">\n                                <button class=\"badge badge-primary btn-sm\"><i class=\"fa fa-times\"></i></button>\n                              </div>\n                              <div *ngIf=\"data.recording!=null\">\n                                <audio style=\"width: 142px;\" controls>\n                                  <source src=\"https://d2actkasrcrrs8.cloudfront.net/{{data.recording}}\" type=\"audio/mp3\">\n                                </audio>\n                              </div>\n                              </td>\n                          </tr>\n                      </tbody>\n                      <tbody *ngIf=\"labels?.length == 0\">\n                        <tr>\n                          <td colspan=\"16\" class=\"no-data-available\">No data Available!</td>\n                        </tr>\n                      <tbody>\n                    </table>\n\n\n\n                  </div> -->\n                <!-- </div>\n              </div>\n            </div> -->\n          </div>\n        </div>\n      </div>\n    </section>\n\n\n\n    <section class=\"section\">\n      <div class=\"section-body\">\n\n      </div>\n    </section>\n\n  </div>\n\n\n";

/***/ }),

/***/ 66425:
/*!***************************************************************!*\
  !*** ./src/app/modules/rules/rules.component.html?ngResource ***!
  \***************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n\n      <div class=\"main-content\">\n\n        <section class=\"section\">\n          <div class=\"section-body\">\n            <div class=\"row\">\n              <div class=\"col-12\">\n                <div class=\"card\">\n                    <div class=\"row\" style=\"margin-top: 20px;\n                    \">\n                        <div class=\"col-9\">\n                            <div class=\"card-header\">\n                            <h4>Rule Sets</h4></div>\n                        </div>\n                        <div class=\"col-3 text-right mt-2\">\n                           <div class=\"form-group\"  style=\"margin-right: 28px;padding: 3px;font-size: 14px;\">\n                               <button routerLink=\"/add-rule\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2\"><i class=\"fa fa-plus\"></i> Add Rule\n                                </button>\n                              </div>\n                        </div>\n\n                    </div>\n\n                  <div class=\"card-body\">\n                    <div class=\"table-responsive\">\n                    <table #dataTable class=\"table table-striped dataTable no-footer row-border hover\">\n                        <thead>\n                          <tr>\n                            <th>Name</th>\n                            <th>Created Date</th>\n                            <th>Action</th>\n                          </tr>\n                        </thead>\n                        <tbody *ngIf=\"rules?.length != 0\">\n                            <tr *ngFor=\"let rule of rules\">\n                                <td>{{ rule.name }}</td>\n                                <td>{{ rule.created_at }}</td>\n                                <td><a routerLink=\"/edit-rule/{{ rule.uuid }}\" class=\"btn btn-primary btn-sm actionedit\"><i class=\"far fa-edit\"></i></a>&nbsp;<button (click)=\"Delete((rule.uuid))\" class=\"btn btn-danger btn-sm actiondelete\"><i class=\"fas fa-trash\"></i></button></td>\n                            </tr>\n                        </tbody>\n                        <tbody *ngIf=\"rules?.length == 0\">\n                          <tr>\n                            <td colspan=\"8\" class=\"no-data-available\">No data Available!</td>\n                          </tr>\n                        <tbody>\n                      </table>\n                    </div>\n                  </div>\n                </div>\n              </div>\n            </div>\n          </div>\n        </section>\n\n      </div>\n";

/***/ }),

/***/ 99993:
/*!***************************************************************************!*\
  !*** ./src/app/modules/rules/rulesadd/rulesadd.component.html?ngResource ***!
  \***************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "<div class=\"main-content\">\n       <section class=\"section\">\n         <div class=\"section-body\">\n           <div class=\"row\">\n             <div class=\"col-12 col-md-12 col-lg-12\">\n               <form [formGroup]=\"addForm\" (ngSubmit)=\"onSubmit()\">\n               <div class=\"card\" >\n                 <div class=\"card-header\">\n                   <h4>Add Rule</h4>\n                 </div>\n                 <div class=\"card-body\">                    \n                   <div class=\"form-group\">\n                     <label>Name</label>\n                     <input type=\"text\" formControlName=\"name\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': submitted && f.name.errors }\">\n                     <div *ngIf=\"submitted && f.name.errors\" class=\"invalid-feedback\">\n                         <div *ngIf=\"f.name.errors.required\">Name is required</div>\n                     </div> \n                   </div>\n\n                   <table class=\"table table-striped dataTable no-footer\" *ngIf=\"addForm['controls'].itemRows!=null\" formGroupName=\"itemRows\">\n                        <tbody *ngFor=\"let itemrow of addForm['controls'].itemRows['controls']; let i=index\" [formGroupName]=\"i\">      \n                            <tr style=\"background: #fff;\">\n                                <td>\n                                    <div class=\"rule-text-block\">If</div>\n                                    <div class=\"rule-input\">\n                                        <select formControlName=\"ifval\" class=\"form-control\" [value]=\"'NUMBER'\">        \n                                            <option value=\"NUMBER\">Number</option>\n                                            <option value=\"AREA_CODE\">Area Code</option>\n                                            <option value=\"WILDCARD\">Wildcard</option>\n                                        </select>\n                                    </div>\n                                </td>\n                                <td>\n                                    <div class=\"rule-text-block\">is</div> \n                                    <div class=\"rule-input\">\n                                        <input formControlName=\"isval\" id=\"number\" (keypress)=_keyPress($event) type=\"text\" class=\"form-control number\" maxlength=\"14\">\n                                    </div>\n                                </td>\n                                <td>\n                                    <div class=\"rule-text-block\">then</div> \n                                    <div class=\"rule-input\">\n                                        <select formControlName=\"thenval\" class=\"form-control\" [value]=\"'FORWARD_TO'\">\n                                            <option value=\"FORWARD_TO\">Forward The Call To</option>\n                                            <option value=\"REJECT_THE_CALL\">Reject The Call</option>\n                                            <option value=\"PLAY_AUDIO\">Play An Audio File</option>\n                                            <option value=\"FORWARD_TO_SECONDARY\">Forward To Number Secondary</option>\n                                            <option value=\"FORWARD_TO_IVR_MENU\">Forward To IVR Menu</option>\n                                        </select>\n                                    </div>\n                                </td>\n                                <td>\n                                        <input formControlName=\"thentxt\" type=\"text\" class=\"form-control\">\n                                </td>\n                                <td>\n                                    <div class=\"rule-text-block\">and</div> \n                                    <div class=\"rule-input\">\n                                        <select [attr.disabled]=\"controlEnabled\" formControlName=\"andval\" class=\"form-control ember-view\" [value]=\"'STOP'\">\n                                              <option value=\"STOP\">Stop Processing</option>\n                                                <!-- <option value=\"TRY_NEXT_RULE\">Try Next Rule</option>\n                                                <option value=\"FORWARD_TO_NUMBER_DEFAULT\">Forward To Number Default</option>\n                                                <option value=\"FORWARD_TO_NUMBER_SECONDARY\">Forward To Number Secondary</option> -->\n                                        </select>\n                                    </div>\n                                </td>\n                                <td>\n                                    <button type=\"button\" (click)=\"deleteRow(i)\" class=\"btn btn-danger btn-md trashbtn\" style=\"color: #fff;\"><i class=\"fa fa-trash\"></i></button>\n                                </td>\n                            </tr>\n                            <tr style=\"background: #fff;\">\n                                    <td colspan=\"6\" class=\"text-center\">\n                                        otherwise\n                                    </td>\n                                </tr>\n                        </tbody>\n                        <tbody>\n                                <tr style=\"background: #fff;\">\n                                        <td colspan=\"4\"></td>\n                                        <td colspan=\"2\" class=\"text-center\" style=\"padding-left: 130px!important;\">\n                                            <button type=\"button\" (click)=\"addRow()\" class=\"btn btn-primary\"><i class=\"fa fa-plus\"></i> Add Row</button>\n                                            <!-- *ngIf=\"addForm.get('rows')\" -->\n                                        </td>\n                                        \n                                </tr>\n                                <tr style=\"background: #fff;\">\n                                    <td colspan=\"6\" class=\"text-center\">\n                                        <strong>otherwise</strong><br>\n                                        <strong>Redirect Call To It's Forwarding Number</strong></td>\n                                </tr>\n                        </tbody>\n                    </table>\n\n                 </div>\n                 <div class=\"card-footer text-right\">\n                       <button  class=\"btn btn-primary mr-1\" type=\"submit\">Create Rule</button>\n                       <button style=\"margin-right: 4px;\" routerLink=\"/rules\" class=\"btn btn-primary\">Back To Rule Sets</button>\n                       <button class=\"btn btn-secondary\" type=\"reset\">Reset</button>\n                     </div>\n               </div>\n             </form>\n\n   </div>\n";

/***/ }),

/***/ 77216:
/*!*****************************************************************************!*\
  !*** ./src/app/modules/rules/rulesedit/rulesedit.component.html?ngResource ***!
  \*****************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "<div class=\"main-content\">\n        <section class=\"section\">\n          <div class=\"section-body\">\n            <div class=\"row\">\n              <div class=\"col-12 col-md-12 col-lg-12\">\n                <form [formGroup]=\"editForm\" (ngSubmit)=\"onSubmit()\">\n                <div class=\"card\" >\n                  <div class=\"card-header\">\n                    <h4>Edit Rule</h4>\n                  </div>\n                  <div class=\"card-body\">                    \n                    <div class=\"form-group\">\n                      <label>Name</label>\n                      <input type=\"text\" formControlName=\"name\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': submitted && f.name.errors }\">\n                      <div *ngIf=\"submitted && f.name.errors\" class=\"invalid-feedback\">\n                          <div *ngIf=\"f.name.errors.required\">Name is required</div>\n                      </div> \n                    </div>\n \n                    <table class=\"table table-striped  dataTable no-footer\" *ngIf=\"editForm['controls'].itemRows!=null\" formGroupName=\"itemRows\">\n                         <tbody *ngFor=\"let itemrow of editForm['controls'].itemRows['controls']; let i=index\" [formGroupName]=\"i\">      \n                             <tr style=\"background: #fff;\">\n                                 <td>\n                                     <div class=\"rule-text-block\"><strong>If</strong></div>\n                                     <div class=\"rule-input\">\n                                         <select formControlName=\"ifval\" class=\"form-control\">        \n                                             <option value=\"NUMBER\">Number</option>\n                                             <option value=\"AREA_CODE\">Area Code</option>\n                                             <option value=\"WILDCARD\">Wildcard</option>\n                                         </select>\n                                     </div>\n                                 </td>\n                                 <td>\n                                     <div class=\"rule-text-block\"><strong>Is</strong></div> \n                                     <div class=\"rule-input\">\n                                         <input formControlName=\"isval\" type=\"text\" id=\"number\" (keypress)=_keyPress($event) type=\"text\" class=\"form-control number\" maxlength=\"14\">\n                                     </div>\n                                 </td>\n                                 <td>\n                                     <div class=\"rule-text-block\"><strong>Then</strong></div> \n                                     <div class=\"rule-input\">\n                                         <select formControlName=\"thenval\" class=\"form-control\">\n                                             <option value=\"FORWARD_TO\">Forward The Call To</option>\n                                             <option value=\"REJECT_THE_CALL\">Reject The Call</option>\n                                             <option value=\"PLAY_AUDIO\">Play An Audio File</option>\n                                             <option value=\"FORWARD_TO_SECONDARY\">Forward To Number Secondary</option>\n                                             <option value=\"FORWARD_TO_IVR_MENU\">Forward To IVR Menu</option>\n                                         </select>\n                                     </div>\n                                 </td>\n                                 <td>\n                                         <input formControlName=\"thentxt\" type=\"text\" class=\"form-control\">\n                                 </td>\n                                 <td>\n                                     <div class=\"rule-text-block\"><strong>And</strong></div> \n                                     <div class=\"rule-input\">\n                                         <select [attr.disabled]=\"controlEnabled\" formControlName=\"andval\" class=\"form-control ember-view\" [value]=\"'STOP'\">\n                                               <option value=\"STOP\">Stop Processing</option>\n                                                 <!-- <option value=\"TRY_NEXT_RULE\">Try Next Rule</option>\n                                                 <option value=\"FORWARD_TO_NUMBER_DEFAULT\">Forward To Number Default</option>\n                                                 <option value=\"FORWARD_TO_NUMBER_SECONDARY\">Forward To Number Secondary</option> -->\n                                         </select>\n                                     </div>\n                                 </td>\n                                 <td>\n                                     <button type=\"button\" (click)=\"deleteRow(i)\" class=\"btn btn-danger btn-md trashbtn\" style=\"color: #fff;\"><i class=\"fa fa-trash\"></i></button>\n                                 </td>\n                             </tr>\n                             <tr style=\"background: #fff;\">\n                                    <td colspan=\"6\" class=\"text-center\">\n                                            <strong>Otherwise</strong>\n                                    </td>\n                                </tr>\n                            </tbody>\n                             <tbody>\n                             <tr style=\"background: #fff;\">\n                                     <td colspan=\"4\"></td>\n                                     <td colspan=\"2\" class=\"text-center\" style=\"padding-left: 130px!important;\">\n                                         <button type=\"button\" (click)=\"addRow()\" class=\"btn btn-primary\"><i class=\"fa fa-plus\"></i> Add Row</button>\n                                         <!-- *ngIf=\"editForm.get('rows')\" -->\n                                     </td>\n                                     \n                             </tr>\n                             <tr style=\"background: #fff;\">\n                                 <td colspan=\"6\" class=\"text-center\">\n                                     <strong>Otherwise</strong><br>\n                                     <strong>Redirect Call To It's Forwarding Number</strong></td>\n                             </tr>\n                         </tbody>\n                     </table>\n \n                  </div>\n                  <div class=\"card-footer text-right\">\n                        <button  class=\"btn btn-primary mr-1\" type=\"submit\">Update Rule Sets</button>\n                        <button style=\"margin-right: 4px;\" routerLink=\"/rules\" class=\"btn btn-primary\">Back To Rule Sets</button>\n                        <button class=\"btn btn-secondary\" type=\"reset\">Reset</button>\n                      </div>\n                </div>\n              </form>\n \n    </div>\n ";

/***/ }),

/***/ 42400:
/*!****************************************************************************************************!*\
  !*** ./src/app/modules/settings/alert-configuration/alert-configuration.component.html?ngResource ***!
  \****************************************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n  \n  <div class=\"main-content\">  \n    <section class=\"section\">\n      <div class=\"section-body\">\n        <div class=\"row\">\n          <div class=\"col-12\">\n            <div class=\"card\">\n                <div class=\"row\">\n                    <div class=\"col-3\">\n                        <div class=\"card-header\">\n                        <h4>Alert Configuration</h4></div>\n                    </div>                   \n                </div>            \n                \n              <div class=\"card-body\">\n                <form id=\"addLabel\" [formGroup]=\"addForm\" (ngSubmit)=\"onSubmit()\">\n                    <div class=\"row\">\n                      <div class=\"col-md-12\">\n                    <div class=\"form-group\">\n                        <label  class=\"d-block\">Name of Alert :</label>\n                        <input formControlName=\"nameofalert\" type=\"text\" class=\"form-control\">\n                    </div>   \n                    <div class=\"form-group\">\n                        <label  class=\"d-block\">Select a Label :</label>\n                        <angular2-multiselect *ngIf=\"isdontuselabel==false\" [data]=\"alllabels\" formControlName=\"labelname\" [settings]=\"dropdownSettings\" ></angular2-multiselect>\n                        <!-- <select class=\"form-control\" name=\"labelname\" formControlName=\"labelname\" id=\"\">\n                            <option value=\"\">Select a Label</option>\n                            <option value=\"{{item.id}}\" *ngFor=\"let item of alllabels\">{{item.itemName}}</option>\n                        </select>                                 -->\n                        <div class=\"form-check form-check-inline mt-3\">\n                            <input type=\"checkbox\" (click)=\"dontuselabel($event)\" class=\"form-check\" name=\"\" id=\"\">\n                            <label class=\"form-check-label\" for=\"inlineRadio1\"> Dont use a Label(recommended)</label>\n                          </div>\n                    </div>   \n                    \n                    <div class=\"form-group\">\n                        <label  class=\"d-block\">Call Length Threshold - Recommended value :</label>\n                        <input formControlName=\"calllength\" type=\"text\" class=\"form-control\">                            \n                    </div>   \n\n                    <div class=\"form-group\">\n                        <label  class=\"d-block\">One Time Alert :</label>\n                          <div class=\"form-check form-check-inline\">\n                            <input type=\"radio\" name=\"onetimealert\" formControlName=\"onetimealert\" value=\"\" id=\"\">\n                            <label class=\"form-check-label\" for=\"inlineRadio1\">Yes (Alert will expire once completed)</label>\n                          </div>\n                          \n                          <div class=\"form-check form-check-inline\">\n                            <input type=\"radio\" name=\"onetimealert\"  formControlName=\"onetimealert\"  value=\"\" id=\"\">\n                            <label class=\"form-check-label\" for=\"inlineRadio1\">No  (Alert will be an ongoing alert)</label>\n                          </div>\n                    </div>\n                 \n                    <div class=\"form-group\">\n                        <label  class=\"d-block\">Who should the system alert?</label>\n                        <div class=\"form-check form-check-inline\">\n                            <input type=\"checkbox\" formControlName=\"systemalert\"  class=\"form-check\" name=\"\" id=\"\">\n                            <label class=\"form-check-label\" for=\"inlineRadio1\"> Check All</label>\n                          </div>         \n                    </div>   \n                   \n                    <div class=\"form-group\">\n                        <div class=\"form-check form-check-inline\">\n                            <input type=\"checkbox\" class=\"form-check\" name=\"\" id=\"\">\n                            <label class=\"form-check-label\" for=\"inlineRadio1\"> Brian Smith</label>\n                        </div>         \n                        <div class=\"form-check form-check-inline\">\n                            <input type=\"checkbox\" class=\"form-check\" name=\"\" id=\"\">\n                            <label class=\"form-check-label\" for=\"inlineRadio1\"> Tina Dixon</label>\n                        </div>         \n                        <div class=\"form-check form-check-inline\">\n                            <input type=\"checkbox\" class=\"form-check\" name=\"\" id=\"\">\n                            <label class=\"form-check-label\" for=\"inlineRadio1\"> Bhavik Patel</label>\n                        </div>         \n                    </div>   \n                    </div>       \n                 </div>\n                    <div class=\"modal-footer\" style=\"padding: 0;\">\n                       <button type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Save</button>                       \n                      </div>\n                  </form>\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n    </section>\n    \n  </div>\n";

/***/ }),

/***/ 54610:
/*!****************************************************************************************!*\
  !*** ./src/app/modules/settings/basic-setting/basic-setting.component.html?ngResource ***!
  \****************************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n  \n  <div class=\"main-content\">  \n    <section class=\"section\">\n      <div class=\"section-body\">\n        <div class=\"row\">\n          <div class=\"col-12\">\n            <div class=\"card\">\n                <div class=\"row\">\n                    <div class=\"col-5\">\n                        <div class=\"card-header\">\n                        <h4>Settings</h4></div>\n                    </div>                   \n                </div>            \n                \n              <div class=\"card-body\">\n                <form id=\"addLabel\" [formGroup]=\"addForm\" (ngSubmit)=\"onSubmit()\">\n                    <div class=\"row\">\n                      <div class=\"col-md-12\">\n\n                      <div class=\"form-group \">\n                        <label  class=\"d-block\">Select Email Id: </label>\n                        <div class=\"row\">\n                          <div class=\"col-md-6\">\n                          <!-- <select name=\"\" id=\"\" class=\"form-control\">\n                            <option value=\"\">Select Email ID</option>\n                          </select> -->\n                          \n                          <angular2-multiselect [data]=\"allBuyers\" [(ngModel)]=\"selectedItems\"  formControlName=\"email\" [settings]=\n                          \"{enableSearchFilter: true,showCheckbox:false,singleSelection: true, text:'Select Email Id'}\"></angular2-multiselect>\n\n                          </div>\n                          <div class=\"col-md-2\">\n                            <button type=\"button\" style=\"width:50%\" (click)=\"isaddemailfun(!isaddemail)\" class=\"btn pb-2 pt-2 btn-sm btn-primary\">Add New Email Id</button>\n                          </div>\n                      </div>   \n                      </div>   \n                      \n                      <div class=\"form-group\" *ngIf=\"isaddemail==1\">\n                          <div class=\"row\">\n                            <div class=\"col-md-3\">\n                              <label  class=\"d-block\">Enter Email Id: </label>\n                              <input [(ngModel)]=\"addemailval\" [ngModelOptions]=\"{standalone: true}\" type=\"text\" class=\"form-control\">                                 \n                            </div>\n                            <div class=\"col-md-6 mt-4\">\n                              <button type=\"button\" style=\"width:10%\" (click)=\"addnewemail()\" class=\"btn pb-2 pt-2 btn-sm btn-success\">Submit</button>\n                            </div>\n                          </div>                          \n                          \n                      </div>   \n\n                    <div class=\"form-group\">\n                        <label  class=\"d-block\">Forwarding Directory Google Sheet Link: </label>\n                        <input formControlName=\"googlesheetlink\" type=\"text\" class=\"form-control\">                                 \n                    </div>   \n                    <!-- <div *ngIf=\"ispubreg==true\"> -->\n                    <!-- <div class=\"form-group\">\n                        <label  class=\"d-block\">Introduction :</label>\n                        <label class=\"custom-switch mt-2 pl-0\">\n                            <textarea formControlName=\"intro\" name=\"\" id=\"\" cols=\"190\" rows=\"10\" class=\"form-control\"></textarea>                            \n                        </label>                                    \n                    </div>    -->\n                    \n                    <div class=\"form-group\">\n                        <label  class=\"d-block\">Duplicate Rule: </label>\n                        <label class=\"custom-switch mt-2 pl-0\">\n                            <input type=\"checkbox\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\" (change)=\"xyzrules_enable($event)\"  [checked]=\"xyzrules==true\">\n                            <span class=\"custom-switch-indicator\"></span>                     \n                        </label>           \n                    </div>   \n\n                    <!-- <div class=\"form-group\">\n                        <label  class=\"d-block\">Terms and Conditions :</label>\n                        <label class=\"custom-switch mt-2 pl-0\">\n                            <input type=\"checkbox\" [checked]=\"terms_condstatus==true\" formControlName=\"terms_cond\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\" (change)=\"tc_enable($event)\">\n                            <span class=\"custom-switch-indicator\"></span>                     \n                        </label>                                    \n                    </div>\n                 \n                    <div class=\"form-group\">\n                        <label  class=\"d-block\">Terms and Conditions URL :</label>\n                        <input formControlName=\"tc_url\"  type=\"text\" class=\"form-control\">           \n                    </div>   \n                   \n                    <div class=\"form-group\">\n                        <label  class=\"d-block\">URL :</label>\n                        <a href=\"{{BaseUrl}}publisher-registration/{{Companyuuid}}\" target=\"_blank\">{{BaseUrl}}publisher-registration/{{Companyuuid}}</a>                        \n                    </div>   -->  \n                    <!-- </div>     -->    \n                    </div>     \n                 </div>\n                    <div class=\"modal-footer\" style=\"padding: 0;\">\n                       <button  type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Save</button>                       \n                      </div>\n                  </form>\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n    </section>\n    \n  </div>\n";

/***/ }),

/***/ 86446:
/*!******************************************************************************************!*\
  !*** ./src/app/modules/settings/manage-company/manage-company.component.html?ngResource ***!
  \******************************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n\n  <div class=\"main-content\">\n    <section class=\"section\">\n      <div class=\"section-body\">\n        <div class=\"row\">\n          <div class=\"col-12\">\n            <div class=\"card\">\n                <div class=\"row\">\n                    <div class=\"col-3\">\n                        <div class=\"card-header\">\n                        <h4> Manage Companies</h4></div>\n                    </div>\n                    <div class=\"col-9 text-right mt-2\">\n                        <div class=\"form-group\"  style=\"margin-right: 28px;padding: 3px;font-size: 14px;\">\n                          <button type=\"button\" data-toggle=\"modal\" data-target=\"#addLabels\" class=\"btn btn-primary daterange-btn icon-left btn-sm btn-icon mr-2 p-2\"><i class=\"fa fa-plus\"></i> Create Company\n                          </button>\n                          </div>\n                    </div>\n\n                </div>\n\n              <div class=\"card-body\">\n                <div class=\"table-responsive\">\n                <table #dataTable class=\"table table-striped dataTable no-footer row-border hover\" style=\"width: 100%;\">\n                    <thead>\n                      <tr>\n                        <th>Name</th>\n                        <th>Phone</th>\n                        <th>City</th>\n                        <th>State</th>\n                        <th>Country</th>\n                        <th>Postal Code</th>\n                        <th>Created Date</th>\n                        <th>Action</th>\n                      </tr>\n                    </thead>\n                    <tbody *ngIf=\"numbers?.length != 0\">\n                        <tr *ngFor=\"let data of numbers\">\n                            <td><a (click)=\"editdata(data.uuid,data.name,data.phone,data.city,data.state,data.country,data.postal_code)\" href=\"#\" data-toggle=\"modal\" data-target=\"#editLabels\" class=\"text-white actionedit\">{{ data.name }}</a></td>\n                            <td>{{ data.phone }}</td>\n                            <td>{{ data.city }}</td>\n                            <td>{{ data.state }}</td>\n                            <td>{{ data.country }}</td>\n                            <td>{{ data.postal_code }}</td>\n                            <td>{{ data.created_at }}</td>\n                            <td class=\"d-flex\" style=\"cursor:pointer;\">\n                                <a (click)=\"editdata(data.uuid,data.name,data.phone,data.city,data.state,data.country,data.postal_code)\" href=\"#\" data-toggle=\"modal\" data-target=\"#editLabels\" class=\"actionedit\"><i class=\"far fa-edit\"></i></a>&nbsp;&nbsp;&nbsp;\n                                <div (click)=\"Delete((data.id))\" class=\"actiondelete\"><i class=\"fas fa-trash\"></i></div>\n                            </td>\n                        </tr>\n                    </tbody>\n                    <tbody *ngIf=\"numbers?.length == 0\">\n                      <tr>\n                        <td colspan=\"8\" class=\"no-data-available\">No data Available!</td>\n                      </tr>\n                    <tbody>\n                  </table>\n                </div>\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n    </section>\n\n  </div>\n\n\n  <!-- Add Label Modal -->\n<div class=\"modal fade\" id=\"addLabels\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\naria-hidden=\"true\">\n<div class=\"modal-dialog model-lg\" role=\"document\">\n  <div class=\"modal-content\">\n    <div class=\"modal-header\">\n      <h5 class=\"modal-title\" id=\"formModal\">Create Company</h5>\n      <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n        <span aria-hidden=\"true\">&times;</span>\n      </button>\n    </div>\n    <div class=\"modal-body\">\n      <form id=\"addLabel\" [formGroup]=\"addForm\" (ngSubmit)=\"onSubmit()\">\n        <div class=\"row\">\n          <div class=\"col-md-12\">\n            <div class=\"form-group\">\n                <label>Company Name</label>\n                <input formControlName=\"company_name\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && addcontrol.company_name.errors }\">\n                <div *ngIf=\"Submitted && addcontrol.company_name.errors\" class=\"invalid-feedback\">\n                    <div *ngIf=\"addcontrol.company_name.errors.required\">Company Name is required</div>\n                </div>\n             </div>\n\n             <div class=\"form-group\">\n                <label>Phone Number</label>\n                <input formControlName=\"phone\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && addcontrol.phone.errors }\">\n                <div *ngIf=\"Submitted && addcontrol.phone.errors\" class=\"invalid-feedback\">\n                    <div *ngIf=\"addcontrol.phone.errors.required\">Phone Number is required</div>\n                </div>\n             </div>\n\n             <div class=\"row\">\n               <div class=\"col-4\">\n                <div class=\"form-group\">\n                  <label>City</label>\n                  <input formControlName=\"city\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && addcontrol.city.errors }\">\n                  <div *ngIf=\"Submitted && addcontrol.city.errors\" class=\"invalid-feedback\">\n                      <div *ngIf=\"addcontrol.city.errors.required\">City is required</div>\n                  </div>\n               </div>\n               </div>\n               <div class=\"col-4\">\n                <div class=\"form-group\">\n                  <label>State</label>\n                  <input formControlName=\"state\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && addcontrol.state.errors }\">\n                  <div *ngIf=\"Submitted && addcontrol.state.errors\" class=\"invalid-feedback\">\n                      <div *ngIf=\"addcontrol.state.errors.required\">State is required</div>\n                  </div>\n               </div>\n               </div>\n               <div class=\"col-4\">\n                <div class=\"form-group\">\n                  <label>Country</label>\n                  <input formControlName=\"country\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && addcontrol.country.errors }\">\n                  <div *ngIf=\"Submitted && addcontrol.country.errors\" class=\"invalid-feedback\">\n                      <div *ngIf=\"addcontrol.country.errors.required\">Country is required</div>\n                  </div>\n               </div>\n               </div>\n             </div>\n\n             <div class=\"form-group\">\n                <label>Postal Code</label>\n                <input formControlName=\"postal_code\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && addcontrol.postal_code.errors }\">\n                <div *ngIf=\"Submitted && addcontrol.postal_code.errors\" class=\"invalid-feedback\">\n                    <div *ngIf=\"addcontrol.postal_code.errors.required\">Postal Code is required</div>\n                </div>\n            </div>\n         </div>\n     </div>\n        <div class=\"modal-footer\" style=\"padding: 0;\">\n         <!-- !addLabelForm.valid || -->\n           <button (click)=\"closeModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Create Company</button>\n           <button  type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\">Reset</button>\n          </div>\n      </form>\n    </div>\n  </div>\n</div>\n</div>\n\n<!-- Edit Label Modal -->\n<div class=\"modal fade\" id=\"editLabels\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\naria-hidden=\"true\">\n<div class=\"modal-dialog model-lg\" role=\"document\">\n  <div class=\"modal-content\">\n    <div class=\"modal-header\">\n      <h5 class=\"modal-title\" id=\"formModal\">Update Company Details</h5>\n      <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n        <span aria-hidden=\"true\">&times;</span>\n      </button>\n    </div>\n    <div class=\"modal-body\">\n      <form id=\"addLabel\" [formGroup]=\"editForm\" (ngSubmit)=\"onEditSubmit()\">\n        <div class=\"row\">\n          <div class=\"col-md-12\">\n            <div class=\"form-group\">\n                <label>Company Name</label>\n                <input formControlName=\"company_name\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && editcontrol.company_name.errors }\">\n                <div *ngIf=\"Submitted && editcontrol.company_name.errors\" class=\"invalid-feedback\">\n                    <div *ngIf=\"editcontrol.company_name.errors.required\">Company Name is required</div>\n                </div>\n             </div>\n\n             <div class=\"form-group\">\n                <label>Phone Number</label>\n                <input formControlName=\"phone\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && editcontrol.phone.errors }\">\n                <div *ngIf=\"Submitted && editcontrol.phone.errors\" class=\"invalid-feedback\">\n                    <div *ngIf=\"editcontrol.phone.errors.required\">Phone Number is required</div>\n                </div>\n             </div>\n\n             <div class=\"row\">\n               <div class=\"col-4\">\n                <div class=\"form-group\">\n                  <label>City</label>\n                  <input formControlName=\"city\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && editcontrol.city.errors }\">\n                  <div *ngIf=\"Submitted && editcontrol.city.errors\" class=\"invalid-feedback\">\n                      <div *ngIf=\"editcontrol.city.errors.required\">City is required</div>\n                  </div>\n               </div>\n               </div>\n               <div class=\"col-4\">\n                <div class=\"form-group\">\n                  <label>State</label>\n                  <input formControlName=\"state\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && editcontrol.state.errors }\">\n                  <div *ngIf=\"Submitted && editcontrol.state.errors\" class=\"invalid-feedback\">\n                      <div *ngIf=\"editcontrol.state.errors.required\">State is required</div>\n                  </div>\n               </div>\n               </div>\n               <div class=\"col-4\">\n                <div class=\"form-group\">\n                  <label>Country</label>\n                  <input formControlName=\"country\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && editcontrol.country.errors }\">\n                  <div *ngIf=\"Submitted && editcontrol.country.errors\" class=\"invalid-feedback\">\n                      <div *ngIf=\"editcontrol.country.errors.required\">Country is required</div>\n                  </div>\n               </div>\n               </div>\n             </div>\n\n             <div class=\"form-group\">\n                <label>Postal Code</label>\n                <input formControlName=\"postal_code\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && editcontrol.postal_code.errors }\">\n                <div *ngIf=\"Submitted && editcontrol.postal_code.errors\" class=\"invalid-feedback\">\n                    <div *ngIf=\"editcontrol.postal_code.errors.required\">Postal Code is required</div>\n                </div>\n            </div>\n         </div>\n     </div>\n        <div class=\"modal-footer\" style=\"padding: 0;\">\n         <!-- !addLabelForm.valid || -->\n           <button (click)=\"closeEditModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Update Company</button>\n           <button class=\"btn btn-primary\" data-dismiss=\"modal\" aria-label=\"Close\">Close</button>\n          </div>\n      </form>\n    </div>\n  </div>\n</div>\n</div>\n";

/***/ }),

/***/ 70265:
/*!**************************************************************************************!*\
  !*** ./src/app/modules/settings/manage-users/manage-users.component.html?ngResource ***!
  \**************************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n\n  <div class=\"main-content\">\n    <section class=\"section\">\n      <div class=\"section-body\">\n        <div class=\"row\">\n          <div class=\"col-12\">\n            <div class=\"card\">\n                <div class=\"row\">\n                    <div class=\"col-3\">\n                        <div class=\"card-header\">\n                        <h4> Manage Users</h4></div>\n                    </div>\n                    <div class=\"col-9 text-right mt-2\">\n                        <div class=\"form-group\"  style=\"margin-right: 28px;padding: 3px;font-size: 14px;\">\n                          <button type=\"button\" data-toggle=\"modal\" data-target=\"#addLabels\" class=\"btn btn-primary daterange-btn icon-left btn-sm btn-icon mr-2 p-2\"><i class=\"fa fa-plus\"></i> Create User\n                          </button>\n                          </div>\n                    </div>\n\n                </div>\n\n              <div class=\"card-body\">\n                <div class=\"table-responsive\">\n                <table #dataTable class=\"table table-striped dataTable no-footer row-border hover\" style=\"width: 100%;\">\n                    <thead>\n                      <tr>\n                        <th>First Name</th>\n                        <th>Last Name</th>\n                        <th>Email</th>\n                        <th>Role</th>\n                        <th>Invitation</th>\n                        <th>Created At</th>\n                        <th>Action</th>\n                      </tr>\n                    </thead>\n                    <tbody *ngIf=\"numbers?.length != 0\">\n                        <tr *ngFor=\"let number of numbers\">\n                            <td>{{ number.first_name }}</td>\n                            <td>{{ number.last_name }}</td>\n                            <td>{{ number.email }}</td>\n                            <td *ngIf=\"number.role==0\"><div class=\"badge badge-success\">Admin</div></td>\n                            <td *ngIf=\"number.role==1\"><div class=\"badge badge-warning\">Reporting User</div></td>\n                            <td *ngIf=\"number.role==2\"><div class=\"badge badge-warning\">Master Admin</div></td>\n                            <td *ngIf=\"number.invitation==0\"><div class=\"badge badge-danger\">Pending</div></td>\n                            <td *ngIf=\"number.invitation==1\"><div class=\"badge badge-success\">Accepted</div></td>\n                            <td>{{ number.created_at }}</td>\n                            <td class=\"d-flex\" style=\"cursor:pointer;\">\n                                <!-- <a (click)=\"editdata()\" href=\"#\" data-toggle=\"modal\" data-target=\"#editLabels\" class=\"btn btn-primary btn-sm actionedit\"><i class=\"far fa-edit\"></i></a>&nbsp; -->\n                                <div (click)=\"Delete((number.id))\" class=\"actiondelete\"><i class=\"fas fa-trash\"></i></div></td>\n                        </tr>\n                    </tbody>\n                    <tbody *ngIf=\"numbers?.length == 0\">\n                      <tr>\n                        <td colspan=\"8\" class=\"no-data-available\">No data Available!</td>\n                      </tr>\n                    <tbody>\n                  </table>\n                </div>\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n    </section>\n\n  </div>\n\n\n  <!-- Add Label Modal -->\n<div class=\"modal fade\" id=\"addLabels\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\naria-hidden=\"true\">\n<div class=\"modal-dialog model-lg\" role=\"document\">\n  <div class=\"modal-content\">\n    <div class=\"modal-header\">\n      <h5 class=\"modal-title\" id=\"formModal\">Create User</h5>\n      <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n        <span aria-hidden=\"true\">&times;</span>\n      </button>\n    </div>\n    <div class=\"modal-body\">\n      <form id=\"addLabel\" [formGroup]=\"addForm\" (ngSubmit)=\"onSubmit()\">\n        <div class=\"row\">\n          <div class=\"col-md-12\">\n            <div class=\"form-group\">\n                <label>Firstname</label>\n                <input formControlName=\"first_name\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && buyercontrol.first_name.errors }\">\n                <div *ngIf=\"Submitted && buyercontrol.first_name.errors\" class=\"invalid-feedback\">\n                    <div *ngIf=\"buyercontrol.first_name.errors.required\">Firstname is required</div>\n                </div>\n             </div>\n\n             <div class=\"form-group\">\n                <label>Lastname</label>\n                <input formControlName=\"last_name\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && buyercontrol.last_name.errors }\">\n                <div *ngIf=\"Submitted && buyercontrol.last_name.errors\" class=\"invalid-feedback\">\n                    <div *ngIf=\"buyercontrol.last_name.errors.required\">Lastname is required</div>\n                </div>\n             </div>\n\n             <div class=\"form-group\">\n                <label>Email Id</label>\n                <input formControlName=\"email\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && buyercontrol.email.errors }\">\n                <div *ngIf=\"Submitted && buyercontrol.email.errors\" class=\"invalid-feedback\">\n                    <div *ngIf=\"buyercontrol.email.errors.required\">Email Id is required</div>\n                </div>\n             </div>\n\n             <div class=\"form-group\">\n                <label>Role</label>\n                <select formControlName=\"role\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': Submitted && buyercontrol.role.errors }\" [value]=\"''\">\n                    <option value=\"\">Select Role</option>\n                    <option value=\"0\">Admin</option>\n                    <option value=\"1\">Reporting User</option>\n                </select>\n                <div *ngIf=\"Submitted && buyercontrol.role.errors\" class=\"invalid-feedback\">\n                    <div *ngIf=\"buyercontrol.role.errors.required\">Role is required</div>\n                </div>\n             </div>\n\n         </div>\n     </div>\n        <div class=\"modal-footer\" style=\"padding: 0;\">\n         <!-- !addLabelForm.valid || -->\n           <button (click)=\"closeModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Create User</button>\n           <button  type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\">Reset</button>\n          </div>\n      </form>\n    </div>\n  </div>\n</div>\n</div>\n\n<!-- Edit Label Modal -->\n<div class=\"modal fade\" id=\"editLabels\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\naria-hidden=\"true\">\n<div class=\"modal-dialog model-lg\" role=\"document\">\n  <div class=\"modal-content\">\n    <div class=\"modal-header\">\n      <h5 class=\"modal-title\" id=\"formModal\">Update Buyer</h5>\n      <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n        <span aria-hidden=\"true\">&times;</span>\n      </button>\n    </div>\n    <div class=\"modal-body\">\n      <form id=\"editLabel\" [formGroup]=\"editForm\" (ngSubmit)=\"onEditSubmit()\">\n        <div class=\"row\">\n          <div class=\"col-md-12\">\n        <div class=\"form-group\">\n            <label>Company</label>\n            <input type=\"hidden\" name=\"uuid\" formControlName=\"uuid\">\n            <input formControlName=\"company\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': editSubmitted && editbuyercontrol.company.errors }\">\n            <div *ngIf=\"editSubmitted && editbuyercontrol.company.errors\" class=\"invalid-feedback\">\n                <div *ngIf=\"editbuyercontrol.company.errors.required\">Company is required</div>\n            </div>\n         </div>\n\n          <div class=\"form-group\">\n            <label  class=\"d-block\">Sub Id  :</label>\n            <input formControlName=\"sub_id\" type=\"text\" class=\"form-control\">\n          </div>\n\n          <div class=\"form-group\">\n            <label  class=\"d-block\">Allow Buyer To Pause Targets :</label>\n            <label class=\"custom-switch mt-2 pl-0\">\n              <input type=\"checkbox\" formControlName=\"allow_buyer_to_pause_target\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n              <span class=\"custom-switch-indicator\"></span>\n            </label>\n          </div>\n\n          <div class=\"form-group\">\n            <label  class=\"d-block\">Allow Buyer To Set Target Concurrency :</label>\n            <label class=\"custom-switch mt-2 pl-0\">\n              <input type=\"checkbox\" formControlName=\"allow_buyer_to_set_target_concurrency\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n              <span class=\"custom-switch-indicator\"></span>\n            </label>\n          </div>\n\n          <div class=\"form-group\">\n            <label  class=\"d-block\">Allow Buyer To Dispute Call Conversions :</label>\n            <label class=\"custom-switch mt-2 pl-0\">\n              <input type=\"checkbox\" formControlName=\"allow_buyer_to_dispute_call_conversions\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n              <span class=\"custom-switch-indicator\"></span>\n            </label>\n          </div>\n\n          <div class=\"form-group\">\n            <label  class=\"d-block\">Limit Revenue : </label>\n            <label class=\"custom-switch mt-2 pl-0\">\n              <input type=\"checkbox\" formControlName=\"limit_revenue\" name=\"custom-switch-checkbox\" class=\"custom-switch-input\">\n              <span class=\"custom-switch-indicator\"></span>\n            </label>\n          </div>\n\n         </div>\n     </div>\n        <div class=\"modal-footer\" style=\"padding: 0;\">\n         <!-- !addLabelForm.valid || -->\n           <button (click)=\"closeEditModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Update Buyer</button>\n           <button  type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\">Reset</button>\n          </div>\n      </form>\n    </div>\n  </div>\n</div>\n</div>\n";

/***/ }),

/***/ 97653:
/*!*******************************************************************************************************!*\
  !*** ./src/app/modules/settings/predictive-routing/add-routing/add-routing.component.html?ngResource ***!
  \*******************************************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "<div class=\"main-content\">\n    <div class=\"section\">\n      <div class=\"section-body\">\n        <div class=\"row\">\n          <div class=\"col-12 col-md-12 col-lg-12\">\n            <form method=\"post\" [formGroup]=\"addForm\" (ngSubmit)=\"onSubmit()\">\n            <div class=\"card\">\n              <div class=\"card-header\">\n                <h4>Create Configuration</h4>\n              </div>\n              <div class=\"card-body\">   \n\n                <div class=\"form-group\">\n                    <label>Name</label>\n                    <div class=\"input-group\">\n                      <input formControlName=\"name\" id=\"name\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': submitted && f.name.errors }\"> \n                      <div *ngIf=\"submitted && f.name.errors\" class=\"invalid-feedback\">\n                          <div *ngIf=\"f.name.errors.required\">Name is required</div>          \n                      </div>                      \n                      </div>  \n                  </div>\n\n                <b>Tracking Settings</b>\n                <p style=\"border: 1px solid gray;\" class=\"mt-2 mb-3\">\n                <div class=\"row\">\n                    <div class=\"col-md-6\">\n                        <div class=\"form-group\">\n                            <label>Count Attempts </label>\n                            <div class=\"input-group\">\n                            <select  formControlName=\"count_attempts\" class=\"form-control\" (change)=\"IVR_Options($event)\">\n                                <option value=\"0\">On Dial</option>\n                                <option value=\"1\">On Connect</option>                                \n                              </select>\n                          </div>  \n                        </div>                  \n         \n                    </div>\n                    <div class=\"col-md-6\">\n                        <div class=\"form-group\">\n                            <label>Track Conversions by </label>\n                            <select  formControlName=\"track_conversions_by\" class=\"form-control\" (change)=\"IVR_Options($event)\">\n                                <option value=\"0\">Buyer</option>\n                                <option value=\"1\">Target</option>\n                                <option value=\"2\">Campaign and Buyer</option>\n                                <option value=\"3\">Campaign and Target</option>\n                                <option value=\"4\">Publisher, Campaign and Buyer</option>\n                                <option value=\"5\">Publisher, Campaign and Target</option>                                \n                              </select>\n                            \n                          </div>                    \n         \n                    </div>\n                </div>   \n                \n                \n                <b>Call Filter Settings</b>\n                <p style=\"border: 1px solid gray;\" class=\"mt-2 mb-3\">\n               \n                <div class=\"row\">\n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                    <label for=\"\">Minimum Number of Calls </label>\n                    <div class=\"input-group\">\n                        <input formControlName=\"minimum_numberofCalls\" id=\"minimum_numberofCalls\" type=\"number\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': submitted && f.minimum_numberofCalls.errors }\" min=\"0\"> \n                        <div *ngIf=\"submitted && f.minimum_numberofCalls.errors\" class=\"invalid-feedback\">\n                            <div *ngIf=\"f.minimum_numberofCalls.errors.required\">Minimum Number of Calls is required</div>                            \n                        </div>                      \n                    </div> \n                    </div>\n                </div> \n               \n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                    <label for=\"\">Desired Number of Calls </label>\n                    <div class=\"input-group\">\n                        <input formControlName=\"desired_numberofCalls\" id=\"desired_numberofCalls\" type=\"number\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': submitted && f.desired_numberofCalls.errors }\" min=\"0\"> \n                        <div *ngIf=\"submitted && f.desired_numberofCalls.errors\" class=\"invalid-feedback\">\n                            <div *ngIf=\"f.desired_numberofCalls.errors.required\">Desired Number of Calls is required</div>                            \n                        </div>                      \n                    </div> \n                    </div>\n                </div> \n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                    <label for=\"\">Minimum Number of Hours </label>\n                    <div class=\"input-group\">\n                        <input formControlName=\"minimum_numberofHours\" id=\"minimum_numberofHours\" type=\"number\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': submitted && f.minimum_numberofHours.errors }\" min=\"0\"> \n                        <div *ngIf=\"submitted && f.minimum_numberofHours.errors\" class=\"invalid-feedback\">\n                            <div *ngIf=\"f.minimum_numberofHours.errors.required\">Minimum Number of Hours is required</div>                            \n                        </div>                      \n                    </div> \n                    </div>\n                </div> \n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                    <label for=\"\">Desired Number of Hours </label>\n                    <div class=\"input-group\">\n                        <input formControlName=\"desired_numberofHours\" id=\"desired_numberofHours\" type=\"number\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': submitted && f.desired_numberofHours.errors }\" min=\"0\"> \n                        <div *ngIf=\"submitted && f.desired_numberofHours.errors\" class=\"invalid-feedback\">\n                            <div *ngIf=\"f.desired_numberofHours.errors.required\">Desired Number of Hours required</div>                            \n                        </div>                      \n                    </div> \n                    </div>\n                </div> \n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                    <label for=\"\">Skip Latest Hours </label>\n                    <div class=\"input-group\">\n                        <input formControlName=\"skip_latest_hours\" id=\"skip_latest_hours\" type=\"number\" class=\"form-control\"  min=\"0\"> \n                        <!-- <div *ngIf=\"submitted && f.noofretries.errors\" class=\"invalid-feedback\">\n                            <div *ngIf=\"f.noofretries.errors.required\">Number Of Retries is required</div>                            \n                        </div>                       -->\n                    </div> \n                    </div>\n                </div> \n                </div> \n\n                <b>Priority Settings</b>\n                <p style=\"border: 1px solid gray;\" class=\"mt-2 mb-3\">\n               \n                <div class=\"row\">\n                    <div class=\"col-md-6\">\n                        <div class=\"form-group\">\n                        <label for=\"\">New Targets </label>\n                        <div class=\"input-group\">\n                            <input formControlName=\"new_targets\" id=\"new_targets\" type=\"number\" class=\"form-control\" min=\"0\"> \n                            <!-- [ngClass]=\"{ 'is-invalid': submitted && f.noofretries.errors }\" -->\n                            <!-- <div *ngIf=\"submitted && f.noofretries.errors\" class=\"invalid-feedback\">\n                                <div *ngIf=\"f.noofretries.errors.required\">Number Of Retries is required</div>                            \n                            </div>                       -->\n                        </div> \n                        </div>\n                    </div> \n                    <div class=\"col-md-6\">\n                        <div class=\"form-group\">\n                        <label for=\"\">Underperforming Targets</label>\n                        <div class=\"input-group\">\n                            <input formControlName=\"underperforming_targets\" id=\"underperforming_targets\" type=\"number\" class=\"form-control\" min=\"0\"> \n                            <!-- [ngClass]=\"{ 'is-invalid': submitted && f.noofretries.errors }\" -->\n                            <!-- <div *ngIf=\"submitted && f.noofretries.errors\" class=\"invalid-feedback\">\n                                <div *ngIf=\"f.noofretries.errors.required\">Number Of Retries is required</div>                            \n                            </div>                       -->\n                        </div> \n                        </div>\n                    </div> \n                </div> \n\n              </div>\n              <div class=\"card-footer text-right\">\n                    <button  class=\"btn btn-primary mr-1 btn-sm  p-2\" type=\"submit\">Create Configuration</button>\n                    <button style=\"margin-right: 4px;\" routerLink=\"/predictive-routing\" class=\"btn btn-primary btn-sm  p-2\">Back To Predictive Routing</button>\n                  </div>\n            </div>\n          </form>\n\n</div>\n";

/***/ }),

/***/ 61192:
/*!*********************************************************************************************************!*\
  !*** ./src/app/modules/settings/predictive-routing/edit-routing/edit-routing.component.html?ngResource ***!
  \*********************************************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "<div class=\"main-content\">\n    <div class=\"section\">\n      <div class=\"section-body\">\n        <div class=\"row\">\n          <div class=\"col-12 col-md-12 col-lg-12\">\n            <form method=\"post\" [formGroup]=\"addForm\" (ngSubmit)=\"onSubmit()\">\n            <div class=\"card\">\n              <div class=\"card-header\">\n                <h4>Edit Configuration</h4>\n              </div>\n              <div class=\"card-body\">   \n\n                <div class=\"form-group\">\n                    <label>Name</label>\n                    <div class=\"input-group\">\n                      <input formControlName=\"name\" id=\"name\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': submitted && f.name.errors }\"> \n                      <div *ngIf=\"submitted && f.name.errors\" class=\"invalid-feedback\">\n                          <div *ngIf=\"f.name.errors.required\">Name is required</div>          \n                      </div>                      \n                      </div>  \n                  </div>\n\n                <b>Tracking Settings</b>\n                <p style=\"border: 1px solid gray;\" class=\"mt-2 mb-3\">\n                <div class=\"row\">\n                    <div class=\"col-md-6\">\n                        <div class=\"form-group\">\n                            <label>Count Attempts </label>\n                            <div class=\"input-group\">\n                            <select  formControlName=\"count_attempts\" class=\"form-control\" (change)=\"IVR_Options($event)\">\n                                <option value=\"0\">On Dial</option>\n                                <option value=\"1\">On Connect</option>                                \n                              </select>\n                          </div>  \n                        </div>                  \n         \n                    </div>\n                    <div class=\"col-md-6\">\n                        <div class=\"form-group\">\n                            <label>Track Conversions by </label>\n                            <select  formControlName=\"track_conversions_by\" class=\"form-control\" (change)=\"IVR_Options($event)\">\n                                <option value=\"0\">Buyer</option>\n                                <option value=\"1\">Target</option>\n                                <option value=\"2\">Campaign and Buyer</option>\n                                <option value=\"3\">Campaign and Target</option>\n                                <option value=\"4\">Publisher, Campaign and Buyer</option>\n                                <option value=\"5\">Publisher, Campaign and Target</option>                                \n                              </select>\n                            \n                          </div>                    \n         \n                    </div>\n                </div>   \n                \n                \n                <b>Call Filter Settings</b>\n                <p style=\"border: 1px solid gray;\" class=\"mt-2 mb-3\">\n               \n                <div class=\"row\">\n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                    <label for=\"\">Minimum Number of Calls </label>\n                    <div class=\"input-group\">\n                        <input formControlName=\"minimum_numberofCalls\" id=\"minimum_numberofCalls\" type=\"number\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': submitted && f.minimum_numberofCalls.errors }\" min=\"0\"> \n                        <div *ngIf=\"submitted && f.minimum_numberofCalls.errors\" class=\"invalid-feedback\">\n                            <div *ngIf=\"f.minimum_numberofCalls.errors.required\">Minimum Number of Calls is required</div>                            \n                        </div>                      \n                    </div> \n                    </div>\n                </div> \n               \n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                    <label for=\"\">Desired Number of Calls </label>\n                    <div class=\"input-group\">\n                        <input formControlName=\"desired_numberofCalls\" id=\"desired_numberofCalls\" type=\"number\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': submitted && f.desired_numberofCalls.errors }\" min=\"0\"> \n                        <div *ngIf=\"submitted && f.desired_numberofCalls.errors\" class=\"invalid-feedback\">\n                            <div *ngIf=\"f.desired_numberofCalls.errors.required\">Desired Number of Calls is required</div>                            \n                        </div>                      \n                    </div> \n                    </div>\n                </div> \n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                    <label for=\"\">Minimum Number of Hours </label>\n                    <div class=\"input-group\">\n                        <input formControlName=\"minimum_numberofHours\" id=\"minimum_numberofHours\" type=\"number\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': submitted && f.minimum_numberofHours.errors }\" min=\"0\"> \n                        <div *ngIf=\"submitted && f.minimum_numberofHours.errors\" class=\"invalid-feedback\">\n                            <div *ngIf=\"f.minimum_numberofHours.errors.required\">Minimum Number of Hours is required</div>                            \n                        </div>                      \n                    </div> \n                    </div>\n                </div> \n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                    <label for=\"\">Desired Number of Hours </label>\n                    <div class=\"input-group\">\n                        <input formControlName=\"desired_numberofHours\" id=\"desired_numberofHours\" type=\"number\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': submitted && f.desired_numberofHours.errors }\" min=\"0\"> \n                        <div *ngIf=\"submitted && f.desired_numberofHours.errors\" class=\"invalid-feedback\">\n                            <div *ngIf=\"f.desired_numberofHours.errors.required\">Desired Number of Hours required</div>                            \n                        </div>                      \n                    </div> \n                    </div>\n                </div> \n                <div class=\"col-md-6\">\n                    <div class=\"form-group\">\n                    <label for=\"\">Skip Latest Hours </label>\n                    <div class=\"input-group\">\n                        <input formControlName=\"skip_latest_hours\" id=\"skip_latest_hours\" type=\"number\" class=\"form-control\"  min=\"0\"> \n                        <!-- <div *ngIf=\"submitted && f.noofretries.errors\" class=\"invalid-feedback\">\n                            <div *ngIf=\"f.noofretries.errors.required\">Number Of Retries is required</div>                            \n                        </div>                       -->\n                    </div> \n                    </div>\n                </div> \n                </div> \n\n                <b>Priority Settings</b>\n                <p style=\"border: 1px solid gray;\" class=\"mt-2 mb-3\">\n               \n                <div class=\"row\">\n                    <div class=\"col-md-6\">\n                        <div class=\"form-group\">\n                        <label for=\"\">New Targets </label>\n                        <div class=\"input-group\">\n                            <input formControlName=\"new_targets\" id=\"new_targets\" type=\"number\" class=\"form-control\" min=\"0\"> \n                            <!-- [ngClass]=\"{ 'is-invalid': submitted && f.noofretries.errors }\" -->\n                            <!-- <div *ngIf=\"submitted && f.noofretries.errors\" class=\"invalid-feedback\">\n                                <div *ngIf=\"f.noofretries.errors.required\">Number Of Retries is required</div>                            \n                            </div>                       -->\n                        </div> \n                        </div>\n                    </div> \n                    <div class=\"col-md-6\">\n                        <div class=\"form-group\">\n                        <label for=\"\">Underperforming Targets</label>\n                        <div class=\"input-group\">\n                            <input formControlName=\"underperforming_targets\" id=\"underperforming_targets\" type=\"number\" class=\"form-control\" min=\"0\"> \n                            <!-- [ngClass]=\"{ 'is-invalid': submitted && f.noofretries.errors }\" -->\n                            <!-- <div *ngIf=\"submitted && f.noofretries.errors\" class=\"invalid-feedback\">\n                                <div *ngIf=\"f.noofretries.errors.required\">Number Of Retries is required</div>                            \n                            </div>                       -->\n                        </div> \n                        </div>\n                    </div> \n                </div> \n\n              </div>\n              <div class=\"card-footer text-right\">\n                    <button  class=\"btn btn-primary mr-1 btn-sm  p-2\" type=\"submit\">Create Configuration</button>\n                    <button style=\"margin-right: 4px;\" routerLink=\"/predictive-routing\" class=\"btn btn-primary btn-sm  p-2\">Back To Predictive Routing</button>\n                  </div>\n            </div>\n          </form>\n\n</div>\n";

/***/ }),

/***/ 59514:
/*!**************************************************************************************************!*\
  !*** ./src/app/modules/settings/predictive-routing/predictive-routing.component.html?ngResource ***!
  \**************************************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n      \n      <div class=\"main-content\">\n        \n        <section class=\"section\">\n          <div class=\"section-body\">\n            <div class=\"row\">\n              <div class=\"col-12\">\n                <div class=\"card\">\n                    <div class=\"row\">\n                        <div class=\"col-8\">\n                            <div class=\"card-header\">\n                                <i class=\"material-icons\">settings</i> <h4 class=\"ml-2\">Predictive Routing</h4></div>\n                        </div>\n                        <div class=\"col-4 text-right mt-2\">\n                            <div class=\"form-group\"  style=\"margin-right: 28px;padding: 3px;font-size: 14px;\">\n                               <button routerLink=\"/predictive-routing-add\" class=\"btn btn-primary daterange-btn icon-left btn-sm btn-icon p-2 mr-2\"><i class=\"fa fa-plus\"></i> Create Configuration\n                                </button>\n                                <!-- <button [disabled]=\"ischecked === '1'\" (click)=\"onDeleteSubmit()\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-2\"><i class=\"fas fa-file-export\"        ></i> Delete Selected\n                                </button>    -->\n                              </div>                       \n                        </div>                  \n                    </div>            \n                    \n                  <div class=\"card-body\">\n                    <div class=\"table-responsive\">\n                    <table #dataTable class=\"table table-striped dataTable no-footer row-border hover\">\n                        <thead>\n                          <tr>\n                            <!-- <th style=\"padding: 10px;\">\n                              <div class=\"custom-control custom-checkbox\" *ngIf=\"IVRMenus?.length != 0\">\n                              <input type=\"checkbox\" class=\"custom-control-input\" id=\"customCheck1\" (change)=\"checkalldelete($event)\" (click)=\"deleteselected($event)\">\n                              <label class=\"custom-control-label\" for=\"customCheck1\"></label>\n                              </div>\n                          </th> -->\n                            <th>Name</th>\n                            <th>Created Date</th>\n                            <th>Action</th>\n                          </tr>\n                        </thead>\n                        <tbody *ngIf=\"IVRMenus?.length != 0\">\n                            <tr *ngFor=\"let IVRMenu of IVRMenus\">\n                                <td><a routerLink=\"/predictive-routing-edit/{{ IVRMenu.uuid }}\" class=\"text-white actionedit\">{{ IVRMenu.name }}</a></td>\n                                <td>{{ IVRMenu.created_at }}</td>\n                                <td style=\"cursor:pointer;\">\n                                  <!-- <i style=\"font-size: 12px;\" placement=\"bottom\" ngbTooltip=\"Duplicate Data\" (click)=\"Clone(IVRMenu.uuid)\" class=\"far fa-clone\"></i>&nbsp;&nbsp; -->\n                                  <a style=\"font-size: 12px;\" placement=\"bottom\" ngbTooltip=\"Edit Data\" routerLink=\"/predictive-routing-edit/{{ IVRMenu.uuid }}\" class=\"actionedit\"><i class=\"far fa-edit\"></i></a>&nbsp;&nbsp;\n                                  <i style=\"font-size: 12px;\" placement=\"bottom\" ngbTooltip=\"Delete Data\" (click)=\"Delete((IVRMenu.uuid))\" class=\"fas fa-trash\"></i>\n                                </td>\n                            </tr>\n                        </tbody>\n                        <tbody *ngIf=\"IVRMenus?.length == 0\">\n                          <tr>\n                            <td colspan=\"8\" class=\"no-data-available\">No data Available!</td>\n                          </tr>\n                        <tbody>\n                      </table>\n                    </div>\n                  </div>\n                </div>\n              </div>\n            </div>\n          </div>\n        </section>\n        \n      </div>";

/***/ }),

/***/ 7693:
/*!***********************************************************************!*\
  !*** ./src/app/modules/shortlist/shortlist.component.html?ngResource ***!
  \***********************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n      <div class=\"main-content\">  \n        <section class=\"section\">\n          <div class=\"section-body\">\n            <div class=\"row\">\n              <div class=\"col-12\">\n                <div class=\"card\">\n                  <div class=\"row\" style=\"margin-top: 20px;\n                  \">\n                      <div class=\"col-9\">\n                          <div class=\"card-header\">\n                          <h4>All ShortList Numbers</h4></div>\n                      </div>\n                  </div> \n                  <form  (ngSubmit)=\"loadcalls()\">\n                  <div class=\"row\" style=\"margin-top: 10px;margin-left: 11px;\" > \n                  <div class=\"col-3\">\n                    <input type=\"text\" [(ngModel)]=\"numbers\" [ngModelOptions]=\"{standalone: true}\" class=\"form-control\" placeholder=\"Search Call Records\" >\n                  </div>                  \n                  <div class=\"col-8\">\n                    <input type=\"text\"\n                    ngxDaterangepickerMd\n                    [(ngModel)]=\"selected\" [ngModelOptions]=\"{standalone: true}\"\n                    [showCustomRangeLabel]=\"true\"\n                    [alwaysShowCalendars]=\"alwaysShowCalendars\"\n                    [ranges]=\"ranges\"                \n                    [showCancel]=\"true\"\n                    [linkedCalendars]=\"true\"                    \n                    [locale]=\"{applyLabel: 'Done'}\"\n                    [keepCalendarOpeningWithRange]=\"keepCalendarOpeningWithRange\"\n                    [showRangeLabelOnInput]=\"showRangeLabelOnInput\"\n                    class=\"form-control\"\n                    placeholder=\"Select please...\"/>\n                  </div>\n                  \n                  <div class=\"col-1\" style=\"margin-left: -22px;\">\n                    <button type=\"submit\" class=\"btn btn-success btn-lg\"><i class=\"fas fa-search\"></i></button>\n                  </div>\n                </div>\n                </form>         \n    \n              <div class=\"card-body\">\n                <div class=\"table-responsive\">\n                <table #dataTable class=\"table table-striped dataTable no-footer row-border hover\">\n                    <thead>\n                      <tr>\n                        <th>Number</th>\n                        <th>Forwarded To\t</th>\n                        <th>Created Date</th>                                                                     \n                      </tr>\n                    </thead>\n                    <tbody *ngIf=\"alldata?.length != 0\">\n                        <tr *ngFor=\"let data of alldata\">\n                            <td>{{ data.number }}</td>\n                            <td>{{ data.forward_to }}</td>\n                            <td>{{ data.created_at }}</td>                            \n                        </tr>\n                    </tbody>\n                    <tbody *ngIf=\"alldata?.length == 0\">\n                      <tr>\n                        <td colspan=\"8\" class=\"no-data-available\">No data Available!</td>\n                      </tr>\n                    <tbody>\n                  </table>\n                </div>\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n    </section>\n</div>  ";

/***/ }),

/***/ 275:
/*!***********************************************************!*\
  !*** ./src/app/modules/sms/sms.component.html?ngResource ***!
  \***********************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n      <div class=\"main-content\">  \n        <section class=\"section\">\n          <div class=\"section-body\">\n            <div class=\"row\">\n              <div class=\"col-12\">\n                <div class=\"card\">\n                  <div class=\"row\" style=\"margin-top: 20px;\n                  \">\n                      <div class=\"col-9\">\n                          <div class=\"card-header\">\n                          <h4>SMS Logs</h4></div>\n                      </div>\n                      <div class=\"col-3 text-right mt-2\">\n                         <div class=\"form-group\"  style=\"margin-right: 28px;padding: 3px;font-size: 14px;\">\n                          <button (click)=\"exportdata()\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-2\"><i class=\"fas fa-file-export\"></i> Export\n                          </button>                     \n                            </div>                       \n                      </div>\n                \n                  </div> \n                  <form  (ngSubmit)=\"loadcalls()\">\n                  <div class=\"row\" style=\"margin-top: 10px;margin-left: 11px;\" > \n                  <div class=\"col-3\">\n                    <input type=\"text\" [(ngModel)]=\"sms\" [ngModelOptions]=\"{standalone: true}\" class=\"form-control\" placeholder=\"Search SMS\" >                   \n                  </div>                  \n                  <div class=\"col-8\">\n                    <input type=\"text\"\n                    ngxDaterangepickerMd\n                    [(ngModel)]=\"selected\" [ngModelOptions]=\"{standalone: true}\"\n                    [showCustomRangeLabel]=\"true\"\n                    [alwaysShowCalendars]=\"alwaysShowCalendars\"\n                    [ranges]=\"ranges\"                \n                    [showCancel]=\"true\"\n                    [linkedCalendars]=\"true\"\n                    [locale]=\"{applyLabel: 'Done'}\"                \n                    [keepCalendarOpeningWithRange]=\"keepCalendarOpeningWithRange\"\n                    [showRangeLabelOnInput]=\"showRangeLabelOnInput\"\n                    class=\"form-control\"\n                    placeholder=\"Select please...\"/>\n                  </div>\n                  \n                  <div class=\"col-1\" style=\"margin-left: -22px;\">\n                    <button type=\"submit\" class=\"btn btn-success btn-lg\"><i class=\"fas fa-search\"></i></button>\n                  </div>\n                </div>\n                </form>         \n    \n                  <div class=\"card-body\">\n                    <div class=\"table-responsive\">\n                    <table #dataTable class=\"table table-striped dataTable no-footer row-border hover\">\n                        <thead>\n                          <tr>\n                            <th>From</th>\n                            <th>To</th>\n                            <th>Time</th>\n                            <th>Message</th>\n                            <th>Source Network</th>\n                            <th>Date Received</th>\n                          </tr>\n                        </thead>\n                        <tbody *ngIf=\"smses?.length != 0\">\n                            <tr *ngFor=\"let data of smses\">\n                                <td>{{ data.sms_from }}</td>\n                                <td>{{ data.sms_to }}</td>\n                                <td>{{ data.time }}</td>\n                                <td>{{ data.message }}</td>\n                                <td>{{ data.source_network }}</td>\n                                <td>{{ data.date_received }}</td>                                \n                            </tr>\n                        </tbody>\n                        <tbody *ngIf=\"smses?.length == 0\">\n                          <tr>\n                            <td colspan=\"8\" class=\"no-data-available\">No data Available!</td>\n                          </tr>\n                        <tbody>\n                      </table>\n                    </div>\n                  </div>\n                </div>\n              </div>\n            </div>\n          </div>\n        </section>\n        \n      </div>  ";

/***/ }),

/***/ 13562:
/*!***************************************************************!*\
  !*** ./src/app/modules/tasks/tasks.component.html?ngResource ***!
  \***************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "<div class=\"main-content\">\n    <section class=\"section\">\n      <div class=\"section-body\">\n        <div class=\"row\">\n          <div class=\"col-12 col-md-12 col-lg-12\">\n            <h6 class=\"text-white\">Tasks</h6>\n            <div style=\"border-top: 1px solid #2f3031\"></div>\n                        \n                        <!-- <div class=\"row\">\n                          <div class=\"col-12 col-md-12 col-lg-12\"> -->\n                            <div class=\"input-group\" style=\"background: #111319;\">\n                              <button id=\"tabs1\" style=\"width: 33.33%;height: 41px;\" (click)=\"getParticipationType(0)\" class=\"camactivetab camtabsbtn\"><i class=\"fa fa-calendar-plus m-r-5 f-s-14\"></i>Open <span class=\"badge badge-danger ml-2 p-2\" *ngIf=\"opendata?.length>0\">{{opendata.length}}</span></button>\n                              <button id=\"tabs2\" style=\"width: 33.33%;height: 41px;\" (click)=\"getParticipationType(1)\" class=\"camtabsbtn\"><i class=\"fa fa-hourglass m-r-5 f-s-14\"></i>Pending <span class=\"badge badge-danger ml-2 p-2\" *ngIf=\"pendingdata?.length>0\">{{pendingdata?.length}}</span></button>\n                              <button style=\"width: 33.33%;height: 41px;\" id=\"tabs3\" (click)=\"getParticipationType(2)\" class=\"camtabsbtn\"><i class=\"fa fa-check-square m-r-5 f-s-14\"></i>Completed <span class=\"badge badge-success ml-2 p-2\" *ngIf=\"completed?.length>0\">{{completed?.length}}</span></button>                                \n                            </div>   \n                          <!-- </div>\n                        </div>   -->\n                        \n                        <div class=\"row\" [style.display]=\"pfiltertype == 0?'block':'none'\" >\n                        <div class=\"col-12 col-md-12 col-lg-12\">                        \n                            <div style=\"position: relative\">\n                              <!-- <ngx-ui-loader [loaderId]=\"'loader-03'\"></ngx-ui-loader> -->\n                              <ng-template #foregroundSpinner>\n                                <div class=\"sk-chase\">\n                                  <div class=\"sk-chase-dot customLoaderId\"></div>\n                                </div>\n                              </ng-template>                \n                              <ngx-ui-loader\n                                [loaderId]=\"loader.loaderId\"\n                                [fgsTemplate]=\"foregroundSpinner\"\n                              ></ngx-ui-loader>\n                              <div class=\"table-responsive\">\n                                <table class=\"table table-striped dataTable no-footer row-border hover dt\" >\n              \n                                  <thead>\n                                    <tr>\n                                      <th>Description</th>\n                                      <th>From</th>\n                                      <th>Status</th>\n                                      <th>Created</th>           \n                                    </tr>\n                                  </thead>\n                                  <tbody *ngIf=\"opendata?.length != 0\">\n                                        <tr *ngFor=\"let data of opendata;let i = index;\" style=\"cursor:pointer\" class=\"detailrow_{{i}}\">\n                                            <td data-toggle=\"modal\" (click)='details(i,data)'>{{data.description}} <br>\n                                            {{data.subdescription}}\n                                            </td>\n                                            <td data-toggle=\"modal\" (click)='details(i,data)'>{{data.from}}</td>\n                                            <td data-toggle=\"modal\" (click)='details(i,data)'><span class=\"badge badge-primary\">Open</span></td>\n                                            <td>{{data.created_at}}</td>\n                                        </tr>\n                                    </tbody>\n                                    <tbody *ngIf=\"opendata?.length == 0\">\n                                        <tr>\n                                        <td colspan=\"4\" class=\"no-data-available\">No data Available!</td>\n                                        </tr>\n                                    <tbody>\n                                </table>\n                              </div>\n                            </div>\n                          \n                          </div>              \n                        </div>              \n                      \n                        <div class=\"row\" [style.display]=\"pfiltertype == 1?'block':'none'\">\n                        <div class=\"col-12 col-md-12 col-lg-12\">\n                                \n\n                            <div style=\"position: relative\" class=\"adjustspan\">\n                                <span>You don't have any pending tasks.</span>\n                            <!--     <ngx-ui-loader [loaderId]=\"'loader-04'\"></ngx-ui-loader>\n                              <div class=\"table-responsive\">\n                                <table class=\"table table-striped dataTable no-footer row-border hover\" id=\"dt\"  datatable [dtOptions]=\"dtOptionsPending\" [dtTrigger]=\"dtTrigger\">\n              \n                                    <thead>\n                                      <tr>\n                                        <th>Description</th>\n                                        <th>From</th>\n                                        <th>Status</th>\n                                        <th>Created</th>           \n                                      </tr>\n                                    </thead>\n                                    <tbody *ngIf=\"pendingdata?.length != 0\">\n                                          <tr *ngFor=\"let data of pendingdata;let i = index;\" style=\"cursor:pointer\" class=\"detailrow_{{i}}\">\n                                              <td data-toggle=\"modal\" (click)='details(i,data)'>{{data.description}} <br>\n                                              {{data.subdescription}}\n                                              </td>\n                                              <td data-toggle=\"modal\" (click)='details(i,data)'>{{data.from}}</td>\n                                              <td data-toggle=\"modal\" (click)='details(i,data)'><span class=\"badge badge-primary\">Open</span></td>\n                                              <td>{{data.created_at}}</td>\n                                          </tr>\n                                      </tbody>\n                                      <tbody *ngIf=\"pendingdata?.length == 0\">\n                                          <tr>\n                                          <td colspan=\"4\" class=\"no-data-available\">No data Available!</td>\n                                          </tr>\n                                      <tbody>\n                                  </table>\n                              </div>-->\n                            </div>\n                           \n                          </div>              \n                        </div> \n                      \n                        <div class=\"row\" [style.display]=\"pfiltertype == 2?'block':'none'\">\n                            <div class=\"col-12 col-md-12 col-lg-12\" >                        \n                            <div style=\"position: relative\">\n                            <!-- <ngx-ui-loader [loaderId]=\"'loader-05'\"></ngx-ui-loader> -->\n                            <ng-template #foregroundSpinner>\n                              <div class=\"sk-chase\">\n                                <div class=\"sk-chase-dot customLoaderId\"></div>\n                              </div>\n                            </ng-template>                \n                            <ngx-ui-loader\n                              [loaderId]=\"loader.loaderId1\"\n                              [fgsTemplate]=\"foregroundSpinner\"\n                            ></ngx-ui-loader>\n                              <div class=\"table-responsive\" style=\"background: #0e0f14;padding: 7px;\">\n                                <table class=\"table table-striped dataTable no-footer row-border hover dt\">              \n                                    <thead>\n                                      <tr>\n                                        <th>Description</th>\n                                        <th>From</th>\n                                        <th>Status</th>\n                                        <th>Created</th>           \n                                      </tr>\n                                    </thead>\n                                    <tbody *ngIf=\"completed?.length != 0\">\n                                          <tr *ngFor=\"let data of completed;let i = index;\" style=\"cursor:pointer\" class=\"detailrow_{{i}}\">\n                                              <td data-toggle=\"modal\" (click)='details(i,data)'>{{data.description}} <br>\n                                              {{data.subdescription}}\n                                              </td>\n                                              <td data-toggle=\"modal\" (click)='details(i,data)'>{{data.from}}</td>\n                                              <td data-toggle=\"modal\" (click)='details(i,data)'>\n                                                <span class=\"badge badge-primary\" *ngIf=\"data.status==0\">Open</span>\n                                                <span class=\"badge badge-success\" *ngIf=\"data.status==1\">Approved</span>\n                                                <span class=\"badge badge-danger\" *ngIf=\"data.status==2\">Rejected</span>\n                                              </td>\n                                              <td>{{data.created_at}}</td>\n                                          </tr>\n                                      </tbody>\n                                      <tbody *ngIf=\"completed?.length == 0\">\n                                          <tr>\n                                          <td colspan=\"4\" class=\"no-data-available\">No data Available!</td>\n                                          </tr>\n                                      <tbody>\n                                  </table>\n                              </div>\n                            </div>\n                          \n                          </div>              \n                        </div> \n                        <!-- <br/>\n                        <div *ngIf=\"diffdays!=0\" [ngClass]=\"{'text-danger': diffdays<5, 'text-success': diffdays>5}\" class=\"text-right font-15\">{{offerdetails ? offerdetails.exp_date:null}} ({{diffdays}} Days Left)</div>\n                        <div *ngIf=\"diffdays==0\" [ngClass]=\"{'text-danger': diffdays<5, 'text-success': diffdays>5}\" class=\"text-right font-15\">{{offerdetails ? offerdetails.exp_date:null}} (Plan Expired)</div> -->\n                    </div>\n                </div>\n            </div>  \n            <div class=\"row\" [style.display]=\"filtertype == 1?'block':'none'\">\n              <div class=\"col-12 col-md-12 col-lg-12\">\n               </div>  \n            </div>         \n    </section>  \n</div>  ";

/***/ }),

/***/ 29389:
/*!***************************************************************************************************!*\
  !*** ./src/app/modules/verification-management/verification-management.component.html?ngResource ***!
  \***************************************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n    \n    <!-- Add Mail Modal -->\n    <div class=\"modal  fade\" id=\"addLabels\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n     aria-hidden=\"true\">\n     <div class=\"modal-dialog\" role=\"document\">\n       <div class=\"modal-content\">\n         <div class=\"modal-header\">\n           <h5 class=\"modal-title\" id=\"formModal\">Add New Verification Notification Email            </h5>\n           <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n             <span aria-hidden=\"true\">&times;</span>\n           </button>\n         </div>\n         <div class=\"modal-body\">\n           <form id=\"addEmail\" [formGroup]=\"addEmailForm\" (ngSubmit)=\"onEmailSubmit();\">\n               <div class=\"form-group\">\n                 <label  class=\"d-block\">Email:</label>\n                 <input formControlName=\"email\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': EmailSubmitted && Emailcontrol.email.errors }\">          \n                 <div *ngIf=\"EmailSubmitted && Emailcontrol.email.errors\" class=\"invalid-feedback\">\n                    <div *ngIf=\"Emailcontrol.email.errors.required\">Email is required</div>\n                    <div *ngIf=\"Emailcontrol.email.errors.email\">Email must be a valid email address</div>\n                </div>         \n               </div>\n               \n             <div class=\"modal-footer\" style=\"padding: 0;\">\n                <button (click)=\"closeModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Add Email</button>\n                <button  type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\">Reset</button>\n               </div>\n           </form>\n         </div>\n       </div>\n     </div>\n     </div>  \n\n    <!-- Edit Mail Modal -->\n    <div class=\"modal  fade\" id=\"editmail\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n     aria-hidden=\"true\">\n     <div class=\"modal-dialog\" role=\"document\">\n       <div class=\"modal-content\">\n         <div class=\"modal-header\">\n           <h5 class=\"modal-title\" id=\"formModal\">Update Verification Notification Email            </h5>\n           <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n             <span aria-hidden=\"true\">&times;</span>\n           </button>\n         </div>\n         <div class=\"modal-body\">\n           <form id=\"editEmail\" [formGroup]=\"editEmailForm\" (ngSubmit)=\"oneditEmailSubmit();\">\n               <div class=\"form-group\">\n                 <label  class=\"d-block\">Email:</label>\n                 <input formControlName=\"uuid\" type=\"hidden\">\n                 <input formControlName=\"email\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': editEmailSubmitted && editEmailcontrol.email.errors }\">          \n                 <div *ngIf=\"editEmailSubmitted && editEmailcontrol.email.errors\" class=\"invalid-feedback\">\n                    <div *ngIf=\"editEmailcontrol.email.errors.required\">Email is required</div>\n                    <div *ngIf=\"editEmailcontrol.email.errors.email\">Email must be a valid email address</div>\n                </div>         \n               </div>\n               \n             <div class=\"modal-footer\" style=\"padding: 0;\">\n                <button (click)=\"closeModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Update Email</button>\n                <button class=\"close\" data-dismiss=\"modal\" class=\"btn btn-secondary m-t-15 waves-effect\">Close</button>\n               </div>\n           </form>\n         </div>\n       </div>\n     </div>\n     </div>   \n\n    <!-- Add Wildcard Modal -->\n    <div class=\"modal  fade\" id=\"addWildcard\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n    aria-hidden=\"true\">\n    <div class=\"modal-dialog\" role=\"document\">\n      <div class=\"modal-content\">\n        <div class=\"modal-header\">\n          <h5 class=\"modal-title\" id=\"formModal\">Add New Verification Wildcard</h5>\n          <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n            <span aria-hidden=\"true\">&times;</span>\n          </button>\n        </div>\n        <div class=\"modal-body\">\n          <form id=\"addWildcarddata\" [formGroup]=\"addWildcardForm\" (ngSubmit)=\"onwildcardSubmit()\">\n              <div class=\"form-group\">\n                    <label  class=\"d-block\">Wildcard:</label>\n                    <input formControlName=\"name\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': WildcardSubmitted && wildcardcontrol.name.errors }\">          \n                    <div *ngIf=\"WildcardSubmitted && wildcardcontrol.notes.errors\" class=\"invalid-feedback\">\n                       <div *ngIf=\"wildcardcontrol.notes.errors.required\">Wildcard is required</div>\n                   </div>         \n                </div>\n\n                <div class=\"form-group\">\n                        <label  class=\"d-block\">Notes:</label>\n                        <textarea formControlName=\"notes\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': WildcardSubmitted && wildcardcontrol.notes.errors }\"></textarea>                   \n                        <div *ngIf=\"WildcardSubmitted && wildcardcontrol.notes.errors\" class=\"invalid-feedback\">\n                           <div *ngIf=\"wildcardcontrol.notes.errors.required\">Notes is required</div>\n                       </div>         \n                </div>\n              \n            <div class=\"modal-footer\" style=\"padding: 0;\">\n               <button (click)=\"closeModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Create Wildcard</button>\n               <button  type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\">Reset</button>\n              </div>\n          </form>\n        </div>\n      </div>\n    </div>\n    </div>  \n\n    <!-- Edit Wildcard -->\n\n    <div class=\"modal  fade\" id=\"editwildcard\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n    aria-hidden=\"true\">\n    <div class=\"modal-dialog\" role=\"document\">\n      <div class=\"modal-content\">\n        <div class=\"modal-header\">\n          <h5 class=\"modal-title\" id=\"formModal\">Update Verification Wildcard</h5>\n          <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n            <span aria-hidden=\"true\">&times;</span>\n          </button>\n        </div>\n        <div class=\"modal-body\">\n          <form id=\"editWildcarddata\" [formGroup]=\"editWildcardForm\" (ngSubmit)=\"onupdatewildcardSubmit()\">\n              \n              <div class=\"form-group\">\n                    <label  class=\"d-block\">Wildcard:</label>\n                    <input type=\"hidden\" name=\"uuid\" formControlName=\"uuid\">\n                    <input formControlName=\"name\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': editwildcardcontrol && editwildcardcontrol.name.errors }\">          \n                    <div *ngIf=\"editwildcardcontrol && editwildcardcontrol.notes.errors\" class=\"invalid-feedback\">\n                       <div *ngIf=\"editwildcardcontrol.notes.errors.required\">Wildcard is required</div>\n                   </div>         \n              </div>\n\n              <div class=\"form-group\">\n                        <label  class=\"d-block\">Notes:</label>\n                        <textarea formControlName=\"notes\" class=\"form-control\"  [ngClass]=\"{ 'is-invalid': editwildcardcontrol && editwildcardcontrol.notes.errors }\"></textarea>                   \n                        <div *ngIf=\"editwildcardcontrol && editwildcardcontrol.notes.errors\" class=\"invalid-feedback\">\n                           <div *ngIf=\"editwildcardcontrol.notes.errors.required\">Notes is required</div>\n                       </div>         \n              </div>\n              \n            <div class=\"modal-footer\" style=\"padding: 0;\">\n               <button (click)=\"closeModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Update Wildcard</button>\n               <button class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\" class=\"btn btn-secondary m-t-15 waves-effect\">Close</button>\n              </div>\n          </form>\n        </div>\n      </div>\n    </div>\n    </div>  \n    <!-- End -->\n\n<div class=\"main-content\">\n    <section class=\"section\">\n      <div class=\"section-body\">\n        <div class=\"row\">\n          <div class=\"col-12 col-md-12 col-lg-12\">\n            <form [formGroup]=\"addForm\" (ngSubmit)=\"onSubmit()\">\n            <div class=\"card\" >\n              <div class=\"card-header\">\n                <h4>Verification Rules</h4>\n              </div>\n              <div class=\"card-body\">                    \n                <table class=\"table table-striped dataTable no-footer\" *ngIf=\"addForm.controls.itemRows!=null\" formGroupName=\"itemRows\">\n                     <tbody *ngFor=\"let itemrow of addForm.get('itemRows')?.controls; let i=index\" [formGroupName]=\"i\">      \n                         <tr style=\"background: #fff;\">\n                             <td>\n                                 <div class=\"rule-text-block\">If</div>\n                                 <div class=\"rule-input\">\n                                     <select formControlName=\"ifval\" class=\"form-control\" [value]=\"'RULE_SET'\">        \n                                      <option value=\"RULE_SET\">Rule Set</option>\n                                     </select>\n                                 </div>\n                             </td>\n                             <td>\n                                 <div class=\"rule-text-block\">is</div> \n                                 <div class=\"rule-input\">\n                                    <!-- value=\"{{ rulesdata[0].uuid }}\" -->\n                                    <select formControlName=\"isval\" class=\"form-control\" >\n                                      <option value=\"\">Select Rule Sets</option>\n                                      <option *ngFor=\"let rules of rulesdata\" value=\"{{ rules.uuid }}\">{{ rules.name }}</option>                                   \n                                    </select>\n                                 </div>\n                             </td>\n                             <td>\n                                 <div class=\"rule-text-block\">then</div> \n                                 <div class=\"rule-input\">\n                                    <!-- [value]=\"'FORWARD_TO'\" -->\n                                    <!-- (input)='data=$event.target.value' -->\n                                    <!-- (change)=\"thenval($event,i)\"  -->\n                                     <select [(ngModel)]=\"data[i]\" class=\"form-control\" formControlName=\"thenval\">\n                                      <option value=\"FORWARD_TO\">Forward The Call To</option>\n                                      <option value=\"FORWARD_TO_IVR_MENU\">Forward To IVR Menu</option>\n                                     </select>\n                                 </div>\n                             </td>\n                             <td>\n                                <!-- {{ data[i]}} -->\n                                <!-- || result[i].then_condition_action == 'FORWARD_TO' -->\n                                <!-- || result[i].then_condition_action == 'FORWARD_TO_IVR_MENU' -->\n\n                                     <input *ngIf=\"data[i] == 'FORWARD_TO' \" formControlName=\"thentxt\" id=\"thentxt_{{i}}\" type=\"text\" class=\"form-control\">\n                                     <select *ngIf=\"data[i] == 'FORWARD_TO_IVR_MENU'\" formControlName=\"thenselect\" id=\"thenselect_{{i}}\" class=\"form-control\" >\n                                       <option value=\"\">Select IVR</option>\n                                      <option *ngFor=\"let ivrname of ivrnamedata\" value=\"{{ ivrname.uuid }}\">{{ ivrname.name }}</option> \n                                    </select>\n                                    <!-- </div> -->\n                             </td>\n                             <td>\n                                 <div class=\"rule-text-block\">and</div> \n                                 <div class=\"rule-input\">\n                                     <select [attr.disabled]=\"controlEnabled\" formControlName=\"andval\" class=\"form-control ember-view\" [value]=\"'STOP'\">\n                                           <option value=\"STOP\">Stop Processing</option>\n                                     </select>\n                                 </div>\n                             </td>\n                             <td>\n                                 <button type=\"button\" (click)=\"deleteRow(i)\" class=\"btn btn-danger btn-md trashbtn\" style=\"color: #fff;\"><i class=\"fa fa-trash\"></i></button>\n                             </td>\n                         </tr>\n                         <tr style=\"background: #fff;\">\n                                 <td colspan=\"6\" class=\"text-center\">\n                                     otherwise\n                                 </td>\n                             </tr>\n                     </tbody>\n                     <tbody>\n                             <tr class=\"text-center\" style=\"background: #fff;\">\n                                     <td colspan=\"6\" class=\"text-center\">\n                                         <div *ngIf=\"addForm.get('itemRows')?.length==0\">\n                                           <small><b>No Rules Added Yet</b></small>\n                                         </div> \n                                         <button type=\"button\" (click)=\"addRow(addForm.get('itemRows')?.length)\" class=\"btn btn-primary\"><i class=\"fa fa-plus\"></i> Add a Rule</button>  \n                                     </td>\n                                     \n                             </tr>\n                             <tr style=\"background: #fff;\">   \n                                <td colspan=\"4\" class=\"text-left\">\n                                    <strong>otherwise</strong><br>\n                                    <strong>Redirect Call To It's Forwarding Number</strong></td>                        \n                                <td colspan=\"2\">\n                                        <div class=\"card-footer text-right\" style=\"padding: 0;\">\n                                            <button class=\"btn btn-primary\" type=\"submit\"><i class=\"fa fa-save\"></i> Save Rules</button>  \n                                        </div>\n                                     </td>\n                             </tr>\n                     </tbody>\n                 </table>\n\n              </div>\n             \n            </div>\n            <hr>\n          </form>\n\n\n    <!-- *ngIf=\"thenvalue == 'FORWARD_TO' && rowcount == i\"  -->\n                                <!-- *ngIf=\"thenvalue == 'FORWARD_TO_IVR_MENU'  && rowcount == i\" -->\n                                <!-- value=\"{{ ivrnamedata[0].uuid }}\" -->\n          <div class=\"row\">\n            <div class=\"col-lg-6 col-md-12 col-12 col-sm-12\">\n                    <div class=\"row\">\n                        <div class=\"col-md-7\"></div>\n                        <div class=\"col-md-5\">\n                            <button type=\"button\" data-toggle=\"modal\" data-target=\"#addLabels\" class=\"btn btn-primary\"><i class=\"fa fa-plus\"></i>  Add Notification Email</button><br><br>\n                        </div>\n                    </div>\n                <div class=\"card\">\n                    <div class=\"card-header\">\n                      <h4>Verification Notification Emails</h4>\n                     </div>\n                    <div class=\"card-body\">\n                            \n                      <div class=\"table-responsive\">\n                        <table class=\"table dataTable table-striped\">\n                          <tbody><tr>\n                            <th>Email</th>\n                            <th>Action</th>\n                          </tr>\n                          <tr *ngFor=\"let email of emaildata\">\n                            <td>{{email.email}}</td>\n                            <td>\n                              <button (click)=\"editEmail(email.uuid,email.email)\" data-toggle=\"modal\" data-target=\"#editmail\" class=\"btn btn-primary btn-sm actionedit\"><i class=\"far fa-edit\"></i></button>\n                              \n                            </td>\n                          </tr> \n                          <tr *ngIf=\"emaildata?.length == 0\" class=\"text-center\">\n                            <td colspan=\"2\">No Data Available</td>\n                          </tr>                         \n                          </tbody>\n                        </table>\n                      </div>\n                    </div>\n                  </div>\n            </div>\n            <div class=\"col-lg-6 col-md-12 col-12 col-sm-12\">\n                    <div class=\"row\">\n                            <div class=\"col-md-7\"></div>\n                            <div class=\"col-md-5\">\n                                    <button type=\"button\" data-toggle=\"modal\" data-target=\"#addWildcard\" class=\"btn btn-primary\"><i class=\"fa fa-plus\"></i>   Add Verification Wildcard</button><br><br>\n                            </div>\n                        </div>\n              <div class=\"card\">\n                <div class=\"card-header\">\n                  <h4>Verification Wildcards</h4>\n                </div>\n                <div class=\"card-body\">\n                  <div class=\"table-responsive\">\n                    <table class=\"table dataTable table-striped\">\n                      <tbody><tr>\n                        <th>Wildcard</th>\n                        <th>Notes</th>\n                        <th>Action</th>                       \n                      </tr>\n                      <tr *ngFor=\"let data of wildcarddata\">\n                        <td>{{data.number}}</td>\n                        <td>{{data.notes}}</td>\n                        <td>\n                          <button (click)=\"editWildcard(data.uuid,data.number,data.notes)\" data-toggle=\"modal\" data-target=\"#editwildcard\" class=\"btn btn-primary btn-sm actionedit\"><i class=\"far fa-edit\"></i></button>\n                        </td>\n                      </tr>  \n                      <tr *ngIf=\"wildcarddata?.length == 0\" class=\"text-center\">\n                        <td colspan=\"3\">No Data Available</td>\n                      </tr>  \n                      \n                    </tbody></table>\n                  </div>\n                </div>\n              </div>\n            </div>\n          </div>\n         \n\n</div>\n";

/***/ }),

/***/ 35200:
/*!***********************************************************************!*\
  !*** ./src/app/modules/voicemail/voicemail.component.html?ngResource ***!
  \***********************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n\n  <div class=\"main-content\">\n    <section class=\"section\">\n      <div class=\"section-body\">\n        <div class=\"row\">\n          <div class=\"col-12\">\n            <div class=\"card\">\n                <div class=\"row\" style=\"margin-top: 20px;\n                \">\n                    <div class=\"col-3\">\n                        <div class=\"card-header\">\n                        <!-- <h4>Number Data</h4></div> -->\n                        <h4>Voicemail</h4></div>\n                    </div>\n                    <div class=\"col-9 text-right mt-2\">\n                        <div class=\"form-group\"  style=\"margin-right: 28px;padding: 3px;font-size: 14px;\">\n                          <!-- <button routerLink=\"/add-target\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-1\"><i class=\"fa fa-plus\"></i> New Target\n                          </button> -->\n                          <!-- <button routerLink=\"/numbers/batch-edit\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-1\"><i class=\"fa fa-tasks\"></i> Batch Edit</button>\n                          <button routerLink=\"/numbers-import\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-1\"><i class=\"fa fa-plus\"></i> Import </button> -->\n                           <!-- <button (click)=\"exportdata()\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-1\"><i class=\"fas fa-file-export\"></i> Export -->\n                          <!-- </button> -->\n                          <!-- <button [disabled]=\"ischecked === '1'\" (click)=\"onDeleteSubmit()\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-2\"><i class=\"fas fa-file-export\"></i> Delete Selected\n                          </button>                          -->\n\n                          </div>\n                    </div>\n\n                </div>\n\n              <div class=\"card-body\">\n                <div class=\"table-responsive\">\n                <table #dataTable class=\"table table-striped dataTable no-footer row-border hover\" style=\"width: 100%;\">\n                    <thead>\n                      <tr>\n                        <!-- <th></th> -->\n                        <!-- <th style=\"padding: 10px;width: 1px;\">\n                            <div class=\"custom-control custom-checkbox\" *ngIf=\"numbers?.length != 0\">\n                            <input type=\"checkbox\" class=\"custom-control-input\" id=\"customCheck1\" (change)=\"checkalldelete($event)\" (click)=\"deleteselected($event)\">\n                            <label class=\"custom-control-label\" for=\"customCheck1\"></label>\n                            </div>\n                        </th>                       -->\n                        <th>Time</th>\n                        <th>Callerid Number</th>\n                        <th>Campaign</th>\n                        <th>Recordings</th>\n                        <!-- <th>CID Number</th>\n                        <th>File Path</th>  -->\n                        <!-- <th>Created Date</th>\n                        <th>Active</th> -->\n                        <!-- <th>Action</th> -->\n                        <!-- <th>Action</th> -->\n                      </tr>\n                    </thead>\n                    <tbody *ngIf=\"numbers?.length != 0\">\n                        <tr *ngFor=\"let number of numbers;let i = index;\" class=\"detailrow_{{i}}\">\n                            <!-- <td (click)='details(i,number)' class=\"details-control\"></td> -->\n                            <!-- <td>\n                                <div class=\"custom-control custom-checkbox\">\n                                <input type=\"checkbox\" (click)=\"deleteselected($event)\" class=\"custom-control-input\" id=\"customCheck_{{number.uuid}}\"  [checked]=\"number.selected\" [value]=\"number.id\" >\n                                <label class=\"custom-control-label\" for=\"customCheck_{{number.uuid}}\"></label>\n                                </div>\n                            </td>                           -->\n                            <td>{{ number.created_epoch }}</td>\n                            <td>{{ number.cid_number }}</td>\n                            <td>{{ number.campaign }}</td>\n                            <td>\n                                <span>\n                                    <div *ngIf=\"number.file_path!=null\" style=\"cursor: pointer;\">\n                                      <i style=\"font-size: 21px;\" class=\"fa fa-play-circle\" (click) = \"play(number.file_path, number.cid_number)\"></i>\n                                      <!-- <i class=\"fa fa-pause\"></i> -->\n                                      <!-- <audio style=\"width: 130px;height: 30px;\" controls muted loop>\n                                        <source src=\"https://repuatationmanagement.s3.us-west-2.amazonaws.com/{{row.recording}}\" type=\"audio/mp3\">\n                                      </audio>  -->\n                                    </div>\n                                  </span>\n                            </td>\n\n                            <!-- <td>\n                              <a routerLink=\"/edit-numbers/{{ number.uuid }}\" class=\"btn btn-primary btn-sm actionedit\"><i class=\"far fa-edit\"></i></a>&nbsp;\n                              <button (click)=\"Delete((number.uuid))\" class=\"btn btn-danger btn-sm actiondelete\"><i class=\"fas fa-trash\"></i></button></td> -->\n                        </tr>\n                    </tbody>\n                    <tbody *ngIf=\"numbers?.length == 0\">\n                      <tr>\n                        <td colspan=\"9\" class=\"no-data-available\">No data Available!</td>\n                      </tr>\n                    <tbody>\n                  </table>\n                </div>\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n    </section>\n\n  </div>\n";

/***/ }),

/***/ 569:
/*!***********************************************************************!*\
  !*** ./src/app/modules/whitelist/whitelist.component.html?ngResource ***!
  \***********************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n\n<!-- Add Number Modal -->\n<div class=\"modal  fade\" id=\"addNumber\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n aria-hidden=\"true\">\n <div class=\"modal-dialog\" role=\"document\">\n   <div class=\"modal-content\">\n     <div class=\"modal-header\">\n       <h5 class=\"modal-title\" id=\"formModal\">Add Number</h5>\n       <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n         <span aria-hidden=\"true\">&times;</span>\n       </button>\n     </div>\n     <div class=\"modal-body\">\n       <form id=\"addNumber\" [formGroup]=\"addNumberForm\" (ngSubmit)=\"onNumberSubmit()\">\n         <div class=\"form-group\">\n             <label>Number</label>\n             <input formControlName=\"number\" id=\"number\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': numberSubmitted && numbercontrol.number.errors }\" (keypress)=_keyPress($event) placeholder=\"(000) 000 - 0000\" maxlength=\"16\">\n             <div *ngIf=\"numberSubmitted && numbercontrol.number.errors\" class=\"invalid-feedback\">\n                 <div *ngIf=\"numbercontrol.number.errors.required\">Number is required</div>\n             </div>\n          </div>\n\n          <div class=\"modal-footer\" style=\"padding: 0;\">\n            <button (click)=\"closeModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Create Number</button>\n            <button  type=\"reset\" class=\"btn btn-secondary m-t-15 waves-effect\">Reset</button>\n           </div>\n       </form>\n     </div>\n   </div>\n </div>\n </div>\n\n<!-- Edit Number Modal -->\n<div class=\"modal  fade\" id=\"editNumber\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"formModal\"\n aria-hidden=\"true\">\n <div class=\"modal-dialog\" role=\"document\">\n   <div class=\"modal-content\">\n     <div class=\"modal-header\">\n       <h5 class=\"modal-title\" id=\"formModal\">Save Number</h5>\n       <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">\n         <span aria-hidden=\"true\">&times;</span>\n       </button>\n     </div>\n     <div class=\"modal-body\">\n       <form [formGroup]=\"editNumberForm\" (ngSubmit)=\"onNumberEditSubmit()\">\n         <div class=\"form-group\">\n             <label>Number</label>\n             <input type=\"hidden\" name=\"uuid\" formControlName=\"uuid\">\n             <input formControlName=\"number\" id=\"editnumber\" type=\"text\" class=\"form-control\" [ngClass]=\"{ 'is-invalid': numbereditSubmitted && numbereditcontrol.number.errors }\" (keypress)=_keyPress($event) placeholder=\"(000) 000 - 0000\" maxlength=\"16\">\n             <div *ngIf=\"numbereditSubmitted && numbereditcontrol.number.errors\" class=\"invalid-feedback\">\n                 <div *ngIf=\"numbereditcontrol.number.errors.required\">Number is required</div>\n             </div>\n           </div>\n\n         <div class=\"modal-footer\" style=\"padding: 0;\">\n            <button (click)=\"closeModal()\" type=\"submit\" class=\"btn btn-primary m-t-15 waves-effect\">Save Number</button>\n            <button type=\"button\" class=\"btn btn-secondary m-t-15 waves-effect\" data-dismiss=\"modal\" aria-label=\"Close\">\n              Close\n            </button>\n           </div>\n       </form>\n     </div>\n   </div>\n </div>\n </div>\n\n  <div class=\"main-content\">\n\n    <section class=\"section\">\n      <div class=\"section-body\">\n        <div class=\"row\">\n          <div class=\"col-12\">\n            <div class=\"card\">\n                <div class=\"row\" style=\"margin-top: 20px;\n                \">\n                    <div class=\"col-8\">\n                        <div class=\"card-header\">\n                        <h4>Whitelist Numbers</h4></div>\n                    </div>\n                    <div class=\"col-4 text-right mt-2\">\n                        <div class=\"form-group\"  style=\"margin-right: 28px;padding: 3px;font-size: 14px;\">\n                           <button data-toggle=\"modal\" data-target=\"#addNumber\" class=\"btn btn-primary daterange-btn icon-left btn-sm btn-icon p-2 mr-2\"><i class=\"fa fa-plus\"></i> Add Number\n                            </button>\n                            <button [disabled]=\"ischecked === '1'\" (click)=\"onDeleteSubmit()\" class=\"btn btn-primary daterange-btn icon-left btn-icon btn-sm p-2 mr-2\"><i class=\"fa fa-trash\"></i> Delete Selected\n                            </button>\n                          </div>\n                    </div>\n\n                </div>\n\n              <div class=\"card-body\">\n                <div class=\"table-responsive\">\n                <table #dataTable class=\"table table-striped dataTable no-footer row-border hover\">\n                    <thead>\n                      <tr>\n                        <th style=\"padding: 10px;\">\n                          <div class=\"custom-control custom-checkbox\" *ngIf=\"numbers?.length != 0\">\n                          <input type=\"checkbox\" class=\"custom-control-input\" id=\"customCheck1\" (change)=\"checkalldelete($event)\" (click)=\"deleteselected($event)\">\n                          <label class=\"custom-control-label\" for=\"customCheck1\"></label>\n                          </div>\n                        </th>\n                        <th>Number</th>\n                        <th>Created Date</th>\n                        <th>Action</th>\n                      </tr>\n                    </thead>\n                    <tbody *ngIf=\"numbers?.length != 0\">\n                        <tr *ngFor=\"let number of numbers;let i=index\">\n                            <td>\n                                <div class=\"custom-control custom-checkbox\">\n                                <input type=\"checkbox\" (click)=\"deleteselected($event)\" class=\"custom-control-input\" id=\"customCheck_{{number.uuid}}\"  [checked]=\"number.selected\" [value]=\"number.id\" >\n                                <label class=\"custom-control-label\" for=\"customCheck_{{number.uuid}}\"></label>\n                                </div>\n                            </td>\n                            <td>{{ number.number }}</td>\n                            <td>{{ number.created_at }}</td>\n                            <td><button (click)=\"editNumber(number.uuid,number.number)\" data-toggle=\"modal\" data-target=\"#editNumber\" class=\"btn btn-primary btn-sm actionedit\"><i class=\"far fa-edit\"></i></button>&nbsp;<button (click)=\"Delete((number.uuid))\" class=\"btn btn-danger btn-sm actiondelete\"><i class=\"fas fa-trash\"></i></button></td>\n                        </tr>\n                    </tbody>\n                    <tbody *ngIf=\"numbers?.length == 0\">\n                      <tr>\n                        <td colspan=\"8\" class=\"no-data-available\">No data Available!</td>\n                      </tr>\n                    <tbody>\n                  </table>\n                </div>\n              </div>\n            </div>\n          </div>\n        </div>\n      </div>\n    </section>\n\n  </div>\n";

/***/ }),

/***/ 71170:
/*!*********************************************************************************************!*\
  !*** ./src/app/page-not-found-component/page-not-found-component.component.html?ngResource ***!
  \*********************************************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "\n\n<div class=\"\">\n    <section class=\"section\">\n         <div class=\"section-body\">\n           <div class=\"row\">\n             <div class=\"col-12 col-md-12 col-lg-12\">\n                <div id=\"app\">\n                    <section class=\"section\">\n                      <div class=\"container mt-5\">\n                        <div class=\"page-error\">\n                          <div class=\"page-inner\">\n                            <h1>404</h1>\n                            <div class=\"page-description\">\n                              The page you were looking for could not be found.\n                            </div>\n                            <!-- <div class=\"page-search\"> -->\n                              <!-- <form>\n                                <div class=\"form-group floating-addon floating-addon-not-append\"> -->\n                                  <!-- <div class=\"input-group\">\n                                    <div class=\"input-group-prepend\">\n                                      <div class=\"input-group-text\">\n                                        <i class=\"fas fa-search\"></i>\n                                      </div>\n                                    </div>\n                                    <input type=\"text\" class=\"form-control\" placeholder=\"Search\">\n                                    <div class=\"input-group-append\">\n                                      <button class=\"btn btn-primary btn-lg\">\n                                        Search\n                                      </button>\n                                    </div>\n                                  </div> -->\n                                <!-- </div>\n                              </form> -->\n                              <div class=\"mt-5\">\n                                <h6><a [routerLink]=\"['/']\" routerLinkActive=\"router-link-active\" >Back to Home</a></h6>\n                              </div>\n                            </div>\n                          <!-- </div> -->\n                        </div>\n                      </div>\n                    </section>\n                  </div>        \n            </div>\n            </div>\n        </div>\n    </section>        \n</div>\n\n";

/***/ }),

/***/ 25689:
/*!*********************************************************************!*\
  !*** ./src/app/pagenotfound/pagenotfound.component.html?ngResource ***!
  \*********************************************************************/
/***/ ((module) => {

"use strict";
module.exports = "<p>pagenotfound works!</p>\n";

/***/ }),

/***/ 28945:
/*!***********************************************************!*\
  !*** ./src/app/sidebar/sidebar.component.html?ngResource ***!
  \***********************************************************/
/***/ ((module) => {

"use strict";
module.exports = "<div class=\"main-sidebar sidebar-style-2\" tabindex=\"1\" style=\"overflow: hidden; outline: none;\">\n    <aside id=\"sidebar-wrapper\">\n      <div class=\"sidebar-brand\">\n        <a> <img alt=\"image\" src=\"assets/img/logo.png\" class=\"header-logo\">\n        </a>\n      </div>\n      <div class=\"sidebar-user\">\n        <div class=\"sidebar-user-picture\">\n          <img alt=\"image\" src=\"assets/img/userbig.png\">\n        </div>\n        <div class=\"sidebar-user-details\">\n          <div class=\"user-name\">{{firstName}} {{lastName}}</div>\n          <div class=\"user-name\">{{companyName}}</div>\n          <!-- <div class=\"user-role\">Administrator</div> -->\n        </div>\n      </div>\n      <ul class=\"sidebar-menu\">\n        <li class=\"menu-header\">Menu\n        </li>\n        <li class=\"dropdown\" *ngIf=\"role==3 || role==4\">\n          <a routerLink=\"/reports\" class=\"nav-link\"><i class=\"material-icons\">show_chart</i> <span>Reports</span></a>\n        </li>\n        <li class=\"dropdown\" *ngIf=\"role==3\">\n          <a routerLink=\"/numbers\" class=\"nav-link\"><i class=\"material-icons\">phone</i> <span>Numbers</span></a>\n        </li>\n\n        <li class=\"dropdown\" *ngIf=\"role==4\">\n          <a routerLink=\"/target\" class=\"nav-link\"><i class=\"material-icons\">gps_fixed</i> <span>Target</span></a>\n        </li>\n\n        <div class=\"menu\" *ngFor=\"let menus of menu\">\n          <div *ngIf=\"(menus.url != 'target') && (menus.url != 'blocklist') && (menus.url != 'numbers') && (menus.url != 'settings') && (menus.url != 'reports')  && (menus.url != 'ivr-menu')\" >\n            <li class=\"dropdown active\" *ngIf=\"'/'+menus.url == this.router.url;\">\n              <a routerLink=\"/{{menus.url}}\" class=\"nav-link \"><i class=\"material-icons\">{{menus.icon}}</i> <span>{{menus.title}}</span></a>\n            </li>\n\n            <li class=\"dropdown\" *ngIf=\"'/'+menus.url != this.router.url;\">\n            <a routerLink=\"/{{menus.url}}\" class=\"nav-link\"><i class=\"material-icons\">{{menus.icon}}</i> <span>{{menus.title}}</span></a>\n\n            </li>\n            </div>\n\n            <li class=\"dropdown\" dropdown *ngIf=\"menus.url == 'target' && role!=4\" (click)=\"showSubmenu(0)\">\n              <a dropdownToggle class=\"nav-link has-dropdown\"><i class=\"material-icons\">{{menus.icon}}</i><span> {{menus.title}}</span></a>\n             <ul class=\"dropdown-menu target-item\" [ngClass]=\"{'show': this.router.url=='/target' || this.router.url=='/buyer'}\">\n                <li ><a class=\"dropdown-item\" [ngClass]=\"{'active': this.router.url=='/target'}\"\n                  routerLink=\"/{{menus.url}}\">Manage Target</a></li>\n\n                <li *ngIf=\"google_sheet_link\"><a target=\"_blank\" class=\"dropdown-item\"\n                  href=\"{{google_sheet_link}}\">Forwarding Number Directory</a></li>\n\n                  <!-- <li><a class=\"dropdown-item\" [ngClass]=\"{'active': this.router.url=='/add-weekdays'}\"\n                  routerLink=\"/add-weekdays\">Add Week Days</a></li> -->\n\n                <li *ngIf=\"role!=4\"><a class=\"dropdown-item\" routerLink=\"/buyer\" [ngClass]=\"{'active': this.router.url=='/buyer'}\">Buyers </a></li>\n              </ul>\n            </li>\n            <!-- {{this.router.url}} -->\n            <!-- {{routerurl}} -->\n\n\n           <li class=\"dropdown\" dropdown *ngIf=\"menus.url == 'reports' && role!=3 && role!=4\" (click)=\"showSubmenu(1)\">\n              <a dropdownToggle class=\"nav-link has-dropdown\"><i class=\"material-icons\">{{menus.icon}}</i><span>  {{menus.title}}</span></a>\n              <ul class=\"dropdown-menu report-item\" [ngClass]=\"{'show': this.router.url.startsWith('/reports') || this.router.url=='/comparison-reports' || this.router.url=='/{{routerurl}}'}\">\n                <li><a class=\"dropdown-item\" [ngClass]=\"{'active': this.router.url=='/reports'}\"\n                  routerLink=\"/{{menus.url}}\">Reports</a></li>\n                <li *ngIf=\"role!=3 && role!=4\"><a class=\"dropdown-item\" [ngClass]=\"{'active': this.router.url=='/voicemail'}\"\n                  routerLink=\"/voicemail\">Voicemail</a></li>\n                <li *ngIf=\"role!=3 && role!=4\"><a class=\"dropdown-item\" [ngClass]=\"{'active': this.router.url=='/comparison-reports'}\"\n                  routerLink=\"/comparison-reports\">Comparison Reports</a></li>\n\n                <li *ngIf=\"role!=3 && role!=4\">\n                  <!-- [ngClass]=\"{'active': this.router.url=='reports/{{item1.uuid}}'}\" -->\n                  <span  *ngFor=\"let item1 of allsavedreports\">\n                    <a class=\"dropdown-item\"\n                    routerLink=\"/reports/{{item1.uuid}}/\">{{item1.reportlabelname}}</a>\n                  </span>\n                </li>\n\n                 <!-- <li *ngIf=\"role!=3\" class=\"active\"  [ngClass]=\"{'active': this.router.url.startsWith('/reports/')}\"> -->\n                  <!-- <span  *ngFor=\"let item1 of allsavedreports\"> -->\n                    <!-- <a class=\"dropdown-item \" routerLink=\"/reports/{{item1.uuid}}/\" [ngClass]=\"{'active': this.router.url=='/routerurl'}\">{{item1.reportlabelname}}</a>\n                  </span> -->\n                <!-- </li>                         -->\n                </ul>\n            </li>\n\n            <li class=\"dropdown\" dropdown *ngIf=\"menus.url == 'blocklist'\" (click)=\"showSubmenu(2)\">\n              <a dropdownToggle class=\"nav-link has-dropdown\"><i class=\"material-icons\">{{menus.icon}}</i><span> {{menus.title}}</span></a>\n             <ul class=\"dropdown-menu blocklist-item\" [ngClass]=\"{'show': this.router.url=='/whitelist' || this.router.url=='/blacklist' || this.router.url=='/shortlist' || this.router.url=='/longlist'}\">\n                <li><a class=\"dropdown-item\" [ngClass]=\"{'active': this.router.url=='/whitelist'}\"\n                  routerLink=\"/whitelist\">Whitelist</a></li>\n                <li><a class=\"dropdown-item\" routerLink=\"/blacklist\" [ngClass]=\"{'active': this.router.url=='/blacklist'}\">Blacklist </a></li>\n                <li><a class=\"dropdown-item\" routerLink=\"/shortlist\" [ngClass]=\"{'active': this.router.url=='/shortlist'}\">Shortlist </a></li>\n                <li><a class=\"dropdown-item\" routerLink=\"/longlist\" [ngClass]=\"{'active': this.router.url=='/longlist'}\">Longlist </a></li>\n              </ul>\n            </li>\n\n            <li class=\"dropdown\" dropdown *ngIf=\"menus.url == 'numbers' && role!=3\" (click)=\"showSubmenu(3)\">\n              <a dropdownToggle class=\"nav-link has-dropdown\"><i class=\"material-icons\">{{menus.icon}}</i><span> {{menus.title}}</span></a>\n             <ul class=\"dropdown-menu numbers-item\" [ngClass]=\"{'show': this.router.url=='/numbers' || this.router.url=='/blocked-numbers' || this.router.url=='/number-pools'}\">\n                <li><a class=\"dropdown-item\" [ngClass]=\"{'active': this.router.url=='/numbers'}\"\n                  routerLink=\"/numbers\">Numbers</a></li>\n                <li *ngIf=\"role!=3\"><a class=\"dropdown-item\" [ngClass]=\"{'active': this.router.url=='/blocked-numbers'}\"\n                  routerLink=\"/blocked-numbers\">Manage Blocked Numbers</a></li>\n                <!-- <li *ngIf=\"role!=3\"><a class=\"dropdown-item\" [ngClass]=\"{'active': this.router.url=='/number-pools'}\"\n                  routerLink=\"/number-pools\">Manage Pools</a></li>                                                 -->\n              </ul>\n            </li>\n\n            <li class=\"dropdown\" dropdown *ngIf=\"menus.url == 'settings'\" (click)=\"showSubmenu(4)\">\n              <a dropdownToggle class=\"nav-link has-dropdown\"><i class=\"material-icons\">{{menus.icon}}</i><span> {{menus.title}}</span></a>\n             <ul class=\"dropdown-menu settings-item\" [ngClass]=\"{'show': this.router.url=='/manage-company' || this.router.url=='/manage-users' || this.router.url=='/publishers-registration-settings' || this.router.url=='/basic-setting' || this.router.url=='/alert-configuration' || this.router.url=='/change-log'}\">\n                <li *ngIf=\"role==2\"><a class=\"dropdown-item\" [ngClass]=\"{'active': this.router.url=='/manage-company'}\"\n                  routerLink=\"/manage-company\">Manage Company</a></li>\n                <li><a class=\"dropdown-item\" [ngClass]=\"{'active': this.router.url=='/manage-users'}\"\n                  routerLink=\"/manage-users\">Manage Users</a></li>\n                <li><a class=\"dropdown-item\" [ngClass]=\"{'active': this.router.url=='/predictive-routing'}\"\n                  routerLink=\"/predictive-routing\">Predictive Routing</a></li>\n                <li><a class=\"dropdown-item\" [ngClass]=\"{'active': this.router.url=='/publishers-registration-settings'}\"\n                  routerLink=\"/publishers-registration-settings\">Publisher Registration</a></li>\n                <li><a class=\"dropdown-item\" [ngClass]=\"{'active': this.router.url=='/basic-setting'}\"\n                  routerLink=\"/basic-setting\">Basic Setting</a></li>\n                <li><a class=\"dropdown-item\" [ngClass]=\"{'active': this.router.url=='/alert-configuration'}\"\n                  routerLink=\"/alert-configuration\">Alert Configuration</a></li>\n                <li><a class=\"dropdown-item\" [ngClass]=\"{'active': this.router.url=='/change-log'}\"\n                  routerLink=\"/change-log\">Change Log</a></li>\n              </ul>\n            </li>\n\n            <li class=\"dropdown\" dropdown *ngIf=\"menus.url == 'ivr-menu'\" (click)=\"showSubmenu(5)\">\n              <a dropdownToggle class=\"nav-link has-dropdown\"><i class=\"material-icons\">{{menus.icon}}</i><span> {{menus.title}}</span></a>\n             <ul class=\"dropdown-menu ivr-item\" [ngClass]=\"{'show': this.router.url=='/ivr-menu' || this.router.url=='/number-pools' || this.router.url=='/ivr-routing-plans'}\">\n                <li><a class=\"dropdown-item\" [ngClass]=\"{'active': this.router.url=='/ivr-menu'}\"\n                  routerLink=\"/ivr-menu\">IVR Options</a></li>\n                <li><a class=\"dropdown-item\" [ngClass]=\"{'active': this.router.url=='/ivr-routing-plans'}\"\n                  routerLink=\"/ivr-routing-plans\">Routing Plans</a></li>\n              </ul>\n            </li>\n\n      </div>\n\n\n\n      </ul>\n    </aside>\n  </div>\n";

/***/ }),

/***/ 28022:
/*!********************!*\
  !*** fs (ignored) ***!
  \********************/
/***/ (() => {

/* (ignored) */

/***/ })

},
/******/ __webpack_require__ => { // webpackRuntimeModules
/******/ var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId))
/******/ __webpack_require__.O(0, ["vendor"], () => (__webpack_exec__(14431)));
/******/ var __webpack_exports__ = __webpack_require__.O();
/******/ }
]);
//# sourceMappingURL=main.js.map