@ng-bootstrap/ng-bootstrap#NgbModal TypeScript Examples

The following examples show how to use @ng-bootstrap/ng-bootstrap#NgbModal. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: vieworders.component.ts    From spurtcommerce with BSD 3-Clause "New" or "Revised" License 6 votes vote down vote up
constructor(
    private modalService: NgbModal,
    private modalService2: NgbModal,
    private route: ActivatedRoute,
    public orderSandbox: OrdersSandbox,
    public layoutSandbox: LayoutSandbox,
    public orderStatusSandbox: OrderstatusSandbox,
    public datePipe: DatePipe,
    private configService: ConfigService,
    private pipe: CurrencySymbolPipe,

  ) {
    pdfMake.vfs = pdfFonts.pdfMake.vfs;
  }
Example #2
Source File: info.component.ts    From dev-manager-desktop with Apache License 2.0 6 votes vote down vote up
constructor(
    private modalService: NgbModal,
    private deviceManager: DeviceManagerService,
    private appManager: AppManagerService,
    private appsRepo: AppsRepoService,
    private devMode: DevModeService
  ) {
    deviceManager.selected$.subscribe((selected) => {
      this.device = selected;
      this.loadInfo();
    });
  }
Example #3
Source File: home.component.ts    From dev-manager-desktop with Apache License 2.0 6 votes vote down vote up
constructor(
    public deviceManager: DeviceManagerService,
    private modalService: NgbModal,
    private router: Router,
    private translate: TranslateService,
  ) {
    deviceManager.devices$.subscribe((devices) => {
      this.selectedDevice = devices.find((device) => device.default);
    });
  }
Example #4
Source File: files.component.ts    From dev-manager-desktop with Apache License 2.0 6 votes vote down vote up
constructor(
    private modalService: NgbModal,
    private deviceManager: DeviceManagerService,
  ) {
    deviceManager.selected$.subscribe((selected) => {
      this.device = selected;
      this.cd('/media/developer', true);
    });
    this.filesSubject = new BehaviorSubject([]);
    this.files$ = this.filesSubject.asObservable();
  }
Example #5
Source File: apps.component.ts    From dev-manager-desktop with Apache License 2.0 6 votes vote down vote up
constructor(
    private modalService: NgbModal,
    private translate: TranslateService,
    private deviceManager: DeviceManagerService,
    private appManager: AppManagerService,
    private appsRepo: AppsRepoService,
  ) {
    deviceManager.selected$.subscribe((device) => {
      this.device = device;
      if (device) {
        this.loadPackages();
      } else {
        this.packages$ = null;
        this.packagesError = null;
        if (this.subscription) {
          this.subscription.unsubscribe();
        }
      }
    });
  }
Example #6
Source File: app.component.ts    From dev-manager-desktop with Apache License 2.0 6 votes vote down vote up
constructor(
    translate: TranslateService,
    private update: UpdateService,
    private modalService: NgbModal,
  ) {
    translate.setDefaultLang('en');
    update.getRecentRelease().then(info => {
      let curVer = new SemVer(packageInfo.version, true);
      const until = update.ignoreUntil;
      if (until && curVer.compare(until) < 0) {
        curVer = new SemVer(until, true);
      }
      const remoteVer = new SemVer(info.tag_name, true);
      if (remoteVer.compare(curVer) > 0) {
        return this.notifyUpdate(info, remoteVer);
      }
    });
  }
Example #7
Source File: add-device.component.ts    From dev-manager-desktop with Apache License 2.0 6 votes vote down vote up
constructor(
    public modal: NgbActiveModal,
    private modalService: NgbModal,
    private translate: TranslateService,
    private deviceManager: DeviceManagerService,
    fb: FormBuilder,
  ) {
    this.formGroup = fb.group({
      name: ['tv'],
      address: [''],
      port: ['9922'],
      description: [],
      // Unix username Regex: https://unix.stackexchange.com/a/435120/277731
      sshUsername: ['prisoner', Validators.pattern(/^[a-z_]([a-z0-9_-]{0,31}|[a-z0-9_-]{0,30}\$)$/)],
      sshAuth: ['devKey'],
      sshPassword: [],
      sshPrivkey: [],
      sshPrivkeyPassphrase: [''],
    });
  }
Example #8
Source File: remove-wallet.component.ts    From StraxUI with MIT License 6 votes vote down vote up
constructor(
    private walletService: WalletService,
    private globalService: GlobalService,
    private modalService: NgbModal,
    private router: Router,
    private stakingService: StakingService,
    private coldStakingService: ColdStakingService,
    private authenticationService: AuthenticationService
  ) { }
Example #9
Source File: editprofile.component.ts    From spurtcommerce with BSD 3-Clause "New" or "Revised" License 6 votes vote down vote up
constructor(
    public fb: FormBuilder,
    private modalService: NgbModal,
    private modalService2: NgbModal,
    private router: Router,
    private editProfilesandbox: EditprofileSandbox,
    public editProfileService: EditprofileService,
    public configService: ConfigService
  ) {}
Example #10
Source File: add.component.ts    From spurtcommerce with BSD 3-Clause "New" or "Revised" License 6 votes vote down vote up
constructor(
    private modalService: NgbModal,
    private route: ActivatedRoute,
    private modalService2: NgbModal,
    private router: Router,
    public fb: FormBuilder,
    public appSandbox: CustomerSandbox,
    private service: CustomersApiClientService,
  ) {}
Example #11
Source File: add.component.ts    From spurtcommerce with BSD 3-Clause "New" or "Revised" License 6 votes vote down vote up
constructor(
    private modalService: NgbModal,
    public appSandbox: PagesSandbox,
    public service: PagesApiclientService,
    public fb: FormBuilder,
    private route: ActivatedRoute,
    private modalService2: NgbModal,
    private router: Router
  ) {}
Example #12
Source File: add.component.ts    From spurtcommerce with BSD 3-Clause "New" or "Revised" License 6 votes vote down vote up
constructor(
    private modalService: NgbModal,
    private modalService2: NgbModal,
    private router: Router,
    private fb: FormBuilder,
    private route: ActivatedRoute,
    private changeDetectRef: ChangeDetectorRef,
    private configService: ConfigService,
    public sandbox: BannerSandbox,
    private service: BannerService
  ) {}
Example #13
Source File: list.component.ts    From spurtcommerce with BSD 3-Clause "New" or "Revised" License 6 votes vote down vote up
constructor(
    public productSandbox: ProductSandbox,
    public commonSandbox: LayoutSandbox,
    private router: Router,
    private toastr: ToastrManager,
    public modalService: NgbModal,
    public layoutSandbox: LayoutsSandbox,
    public configService: ConfigService
  ) {}
Example #14
Source File: add.component.ts    From spurtcommerce with BSD 3-Clause "New" or "Revised" License 6 votes vote down vote up
constructor(
    public fb: FormBuilder,
    public productSandbox: ProductSandbox,
    public categoriessandbox: CategoriesSandbox,
    public brandsandbox: BrandSandbox,
    private popup: NgbModal,
    private route: ActivatedRoute,
    private changeDetectRef: ChangeDetectorRef,
    public stockStatusSandbox: StockSandbox,
    public configService: ConfigService,
    private datePipe: DatePipe
  ) {
    this.mycontent = `<p>My html content</p>`;
    // this.initDropDownList();
    this.route.params.subscribe(data => {
      if (data) {
        this.editId = data['id'];
      }
    });
  }
Example #15
Source File: add.component.ts    From spurtcommerce with BSD 3-Clause "New" or "Revised" License 6 votes vote down vote up
constructor(
    private modalService: NgbModal,
    public fb: FormBuilder,
    private configService: ConfigService,
    public sandbox: CategoriesSandbox,
    private categoryservice: CategoriesService
  ) {
    this.valids = false;
  }
Example #16
Source File: add.component.ts    From spurtcommerce with BSD 3-Clause "New" or "Revised" License 6 votes vote down vote up
constructor(
    private modalService: NgbModal,
    private modalService2: NgbModal,
    private fb: FormBuilder,
    private sandBox: BrandSandbox,
    private brandApi: BrandApiClient,
    private router: Router,
    private configService: ConfigService,
    private changeDetectRef: ChangeDetectorRef
  ) {}
Example #17
Source File: proposed-certificate-details.component.ts    From distributed-compliance-ledger with Apache License 2.0 5 votes vote down vote up
constructor(public pkiService: PkiService,
              private route: ActivatedRoute,
              private modalService: NgbModal) {
  }
Example #18
Source File: approved-certificates-list.component.ts    From distributed-compliance-ledger with Apache License 2.0 5 votes vote down vote up
constructor(public pkiService: PkiService,
              private modalService: NgbModal) {
  }
Example #19
Source File: proposed-certificates-list.component.ts    From distributed-compliance-ledger with Apache License 2.0 5 votes vote down vote up
constructor(public pkiService: PkiService,
              private router: Router,
              private modalService: NgbModal) {
  }
Example #20
Source File: approved-certificate-details.component.ts    From distributed-compliance-ledger with Apache License 2.0 5 votes vote down vote up
constructor(public pkiService: PkiService,
              private route: ActivatedRoute,
              private modalService: NgbModal) {
  }
Example #21
Source File: testing-result-list.component.ts    From distributed-compliance-ledger with Apache License 2.0 5 votes vote down vote up
constructor(
    public testingResultService: ModelTestingResultsService,
    private route: ActivatedRoute,
    private modalService: NgbModal
  ) {}
Example #22
Source File: ngx-photo-editor.component.ts    From ngx-photo-editor with MIT License 5 votes vote down vote up
constructor(private modalService: NgbModal) {
  }
Example #23
Source File: model-info-list.component.ts    From distributed-compliance-ledger with Apache License 2.0 5 votes vote down vote up
constructor(public modelInfoService: ModelInfoService,
              private router: Router,
              private modalService: NgbModal) {
  }
Example #24
Source File: progress-dialog.component.ts    From dev-manager-desktop with Apache License 2.0 5 votes vote down vote up
static open(service: NgbModal): NgbModalRef {
    const ref = service.open(ProgressDialogComponent, {
      centered: true,
      backdrop: 'static',
      keyboard: false
    });
    return ref;
  }
Example #25
Source File: message-dialog.component.ts    From dev-manager-desktop with Apache License 2.0 5 votes vote down vote up
static open(service: NgbModal, config: MessageDialogConfig): NgbModalRef {
    return service.open(MessageDialogComponent, {
      centered: true,
      injector: Injector.create({
        providers: [{ provide: 'config', useValue: config }]
      })
    });
  }
Example #26
Source File: wallet.component.ts    From StraxUI with MIT License 5 votes vote down vote up
constructor(
    private modalService: NgbModal) {
  }
Example #27
Source File: transaction-details.component.ts    From StraxUI with MIT License 5 votes vote down vote up
constructor(
    private snackbarService: SnackbarService,
    private nodeService: NodeService,
    private globalService: GlobalService,
    private modalService: NgbModal) {
  }
Example #28
Source File: address-book.component.ts    From StraxUI with MIT License 5 votes vote down vote up
constructor(
    private router: Router,
    private addressBookService: AddressBookService,
    private modalService: NgbModal) {
  }
Example #29
Source File: modal.service.ts    From StraxUI with MIT License 5 votes vote down vote up
constructor(private modalService: NgbModal) {}