当前位置: 首页>>代码示例>>TypeScript>>正文


TypeScript NgbActiveModal.close方法代码示例

本文整理汇总了TypeScript中@ng-bootstrap/ng-bootstrap.NgbActiveModal.close方法的典型用法代码示例。如果您正苦于以下问题:TypeScript NgbActiveModal.close方法的具体用法?TypeScript NgbActiveModal.close怎么用?TypeScript NgbActiveModal.close使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在@ng-bootstrap/ng-bootstrap.NgbActiveModal的用法示例。


在下文中一共展示了NgbActiveModal.close方法的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的TypeScript代码示例。

示例1: generateCreateTableStatement

    private generateCreateTableStatement(csvData) {
        let rows = csvData.split('\n');
        let fieldList = rows[0].replace(/"/g,'');
        let fields = fieldList.split(',');

        let sql = '-- DROP TABLE IF EXISTS workspace.' + this.tableName + ';\n\n';
        sql += 'CREATE TABLE workspace.' + this.tableName + '(\n';

        for (let i = 0; i < fields.length; i++) {
            sql += '\t' + fields[i] + ' CHARACTER VARYING(255),\n';
        }
        sql += '\tCONSTRAINT pk_'+this.tableName+'_'+fields[0]+' PRIMARY KEY ('+fields[0]+')\n';
        sql += ');\n\n';

        sql += 'INSERT INTO workspace.' + this.tableName + '\n';
        sql += '(' + fieldList + ')\n';
        sql += 'VALUES';

        for (let i = 1; i < rows.length; i++) {
            if (i > 1)
                sql += ',';
            sql += '\n(' + rows[i].replace(/"/g,"'") + ')';
        }
        sql += ';';

        this.activeModal.close(sql);
    }
开发者ID:endeavourhealth,项目名称:DataChecker,代码行数:27,代码来源:uploadCsv.dialog.ts

示例2: sendPrice

  // send price to parent component
 sendPrice(){
   if(this.price != null){ // check if the user entered price
     this.boughtInputModalService.neededPriceChange.emit(this.price);
     this.activeModal.close(); //close modal
   }
   else if(this.price== null ){
     this.errorMessage = "Item Price missing";
   }    
 }
开发者ID:mostafa17dev,项目名称:supermarketList,代码行数:10,代码来源:bought-input-modal.component.ts

示例3: GuardarCambios

 /// *** Event handlers *************************************************
 /**
  * Guarda los cambios para el pago mensual
  * 
  * @memberOf EditarPagoComponent
  */
 GuardarCambios():void {
     this.activeModal.close();
     const modalRef = this.modalService.open(framework.ProgresoModal);
     modalRef.componentInstance.Mensaje = "Guardando pago";
     this.planillaService.ActualizarPago(this.PagoMensual)
      .subscribe(result => { modalRef.close() }, 
                 error => { 
                      modalRef.close();
                     console.log(error); 
                 });  
 }
开发者ID:andresAste,项目名称:AndresSites,代码行数:17,代码来源:editarPago.component.ts

示例4: execute

 execute(form: NgForm) : void {
     let variables: EnvironmentVariable[] = [];
     this.workflow.referenced_variables.forEach(variable => {
         if (form.value[variable.id] && form.value[variable.id] != '') {
             let newV = new EnvironmentVariable();
             newV.id = variable.id;
             newV.value = form.value[variable.id];
             variables.push(newV);
         }
     })
     this.activeModal.close(variables);
 }
开发者ID:iadgov,项目名称:WALKOFF,代码行数:12,代码来源:execution.variable.modal.component.ts

示例5: creerVehicule

 creerVehicule() {
   const newVehicule = new VehiculeSociete(
     this.immatriculation.value,
     this.marque.value,
     this.modele.value,
     this.categorie.value,
     this.nbPlaces.value,
     this.photo.value
   );
   console.log('publish : ', newVehicule);
   this.ds.publishVehicule(newVehicule).subscribe(veh => {
     console.log('response to publish : ', veh);
   });
   this.activeModal.close();
 }
开发者ID:thienban,项目名称:gestion-du-transport,代码行数:15,代码来源:creer-vehicule.component.ts

示例6: onSubmit

 private onSubmit() {
     if (this.form.valid) {
         const item = this.item
             ? new NameListItem(
                 this.firstName,
                 this.lastName,
                 this.email,
                 this.item.id,
                 this.item.readUri,
                 this.item.updateUri,
                 this.item.deleteUri)
             : new NameListItem(
                 this.firstName,
                 this.lastName,
                 this.email);
         this.activeModal.close(item);
     }
 }
开发者ID:taylorjg,项目名称:Angular2Dialog,代码行数:18,代码来源:nameListItemModalContent.component.ts

示例7:

 .subscribe(data => {
   this.saving = false;
    console.log('Snippet assigned to idea: ' + data.idea_snippet_id);
    this.activeModal.close('Snippet saved.');
 },
开发者ID:Coppia,项目名称:web,代码行数:5,代码来源:snippet-modal.component.ts

示例8: okModal

 okModal() {
   this.activeModal.close('Y');
 }
开发者ID:rahulsingh0394,项目名称:csquare_ui,代码行数:3,代码来源:common-modal.component.ts

示例9:

 (image) => this.modalInstance.close(image),
开发者ID:Ke1R0,项目名称:koroljuk-portfolio-dev,代码行数:1,代码来源:gallery-image-edit.component.ts

示例10: onSubmit

 async onSubmit () {
   const formModel = this.form.value
   await this.projectsService
     .createProject(formModel.name)
   this.activeModal.close()
 }
开发者ID:ChristosGeorgiou,项目名称:balance,代码行数:6,代码来源:create-project.component.ts


注:本文中的@ng-bootstrap/ng-bootstrap.NgbActiveModal.close方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。