Skip to content
Snippets Groups Projects
Commit 38cfc19d authored by Florian Azizian's avatar Florian Azizian
Browse files

FIX #15719 TIME 0:40 reset input file after upload + accept only pdf file

parent b9d7d688
No related branches found
No related tags found
No related merge requests found
......@@ -47,7 +47,7 @@
</ion-buttons>
</ion-item>
</ion-list>
<input type="file" #docToUpload name="files[]" (change)="uploadTrigger($event)" style="display:none;" multiple>
<input type="file" #docToUpload name="files[]" (change)="uploadTrigger($event)" style="display:none;" multiple accept="application/pdf">
<div class="dnd-area" appUploadFileDragDrop (onFileDropped)="dndUploadFile($event)">
<ion-button fill="outline" color="medium" size="large" (click)="docToUpload.click()">
{{'lang.chooseDocuments' | translate}}
......
import { DatePipe } from '@angular/common';
import { HttpClient } from '@angular/common/http';
import { Component, OnInit, TemplateRef, ViewChild, ViewContainerRef } from '@angular/core';
import { Component, ElementRef, OnInit, TemplateRef, ViewChild, ViewContainerRef } from '@angular/core';
import { Router } from '@angular/router';
import { AlertController, LoadingController, MenuController, ModalController } from '@ionic/angular';
import { TranslateService } from '@ngx-translate/core';
......@@ -26,6 +26,7 @@ export class IndexationComponent implements OnInit {
@ViewChild('appVisaWorkflow', { static: false }) appVisaWorkflow: VisaWorkflowComponent;
@ViewChild('rightContent', { static: true }) rightContent: TemplateRef<any>;
@ViewChild('docToUpload') fileImport: ElementRef;
constructor(
public http: HttpClient,
......@@ -306,6 +307,7 @@ export class IndexationComponent implements OnInit {
}
};
}
this.fileImport.nativeElement.value = "";
} else {
this.loading = false;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment