arreglos mensajes de alerta en categorias
This commit is contained in:
		
							parent
							
								
									cfe03c45de
								
							
						
					
					
						commit
						17445e28b4
					
				| 
						 | 
					@ -1,9 +1,5 @@
 | 
				
			||||||
<form class="ds-form" *ngIf="categoria" name="deleteForm" (ngSubmit)="confirmDelete(categoria!)">
 | 
					<form class="ds-form" *ngIf="categoria" name="deleteForm" (ngSubmit)="confirmDelete(categoria!)">
 | 
				
			||||||
  <div class="modal-header">
 | 
					  <div class="modal-header"></div>
 | 
				
			||||||
    <h4 class="modal-title" data-cy="categoriaDeleteDialogHeading" jhiTranslate="entity.delete.title">Confirm delete operation</h4>
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    <button type="button" class="ds-btn close" data-dismiss="modal" aria-hidden="true" (click)="cancel()">×</button>
 | 
					 | 
				
			||||||
  </div>
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
  <div class="modal-body">
 | 
					  <div class="modal-body">
 | 
				
			||||||
    <jhi-alert-error></jhi-alert-error>
 | 
					    <jhi-alert-error></jhi-alert-error>
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -15,9 +15,11 @@
 | 
				
			||||||
    </div>
 | 
					    </div>
 | 
				
			||||||
  </h2>
 | 
					  </h2>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  <jhi-alert-error></jhi-alert-error>
 | 
					  <!--  <div class="alert alert-success" *ngIf="success" jhiTranslate="dataSurveyApp.categoria.delete.error">
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  <jhi-alert></jhi-alert>
 | 
					  </div>-->
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  <div class="alert alert-success" *ngIf="success" jhiTranslate="dataSurveyApp.categoria.delete.success"></div>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  <div class="alert alert-warning" id="no-result" *ngIf="categorias?.length === 0">
 | 
					  <div class="alert alert-warning" id="no-result" *ngIf="categorias?.length === 0">
 | 
				
			||||||
    <span jhiTranslate="dataSurveyApp.categoria.home.notFound">No categorias found</span>
 | 
					    <span jhiTranslate="dataSurveyApp.categoria.home.notFound">No categorias found</span>
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -14,6 +14,7 @@ export class CategoriaComponent implements OnInit {
 | 
				
			||||||
  categorias?: ICategoria[];
 | 
					  categorias?: ICategoria[];
 | 
				
			||||||
  isLoading = false;
 | 
					  isLoading = false;
 | 
				
			||||||
  public searchString: string;
 | 
					  public searchString: string;
 | 
				
			||||||
 | 
					  success = false;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  constructor(protected categoriaService: CategoriaService, protected modalService: NgbModal) {
 | 
					  constructor(protected categoriaService: CategoriaService, protected modalService: NgbModal) {
 | 
				
			||||||
    this.searchString = '';
 | 
					    this.searchString = '';
 | 
				
			||||||
| 
						 | 
					@ -48,6 +49,7 @@ export class CategoriaComponent implements OnInit {
 | 
				
			||||||
    // unsubscribe not needed because closed completes on modal close
 | 
					    // unsubscribe not needed because closed completes on modal close
 | 
				
			||||||
    modalRef.closed.subscribe(reason => {
 | 
					    modalRef.closed.subscribe(reason => {
 | 
				
			||||||
      if (reason === 'deleted') {
 | 
					      if (reason === 'deleted') {
 | 
				
			||||||
 | 
					        this.success = true;
 | 
				
			||||||
        this.loadAll();
 | 
					        this.loadAll();
 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
    });
 | 
					    });
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -12,7 +12,9 @@
 | 
				
			||||||
      "updated": "Los datos de la categoría {{ nombre }} han sido actualizados",
 | 
					      "updated": "Los datos de la categoría {{ nombre }} han sido actualizados",
 | 
				
			||||||
      "deleted": "La categoría  {{ nombre }} ha sido deshabilitada",
 | 
					      "deleted": "La categoría  {{ nombre }} ha sido deshabilitada",
 | 
				
			||||||
      "delete": {
 | 
					      "delete": {
 | 
				
			||||||
        "question": "¿Seguro que quiere cambiar el estado de \"{{ nombre }}\"?"
 | 
					        "question": "¿Seguro que quiere cambiar el estado de \"{{ nombre }}\"?",
 | 
				
			||||||
 | 
					        "success": "Su categoría ha sido modificada de manera exitosa ",
 | 
				
			||||||
 | 
					        "error": "Ocurrió un error al cambiar el estado de su categoría, por favor intentar de nuevo"
 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
      "detail": {
 | 
					      "detail": {
 | 
				
			||||||
        "title": "Categoría"
 | 
					        "title": "Categoría"
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in New Issue