Projekt

Obecné

Profil

« Předchozí | Další » 

Revize b613cbc0

Přidáno uživatelem Ondřej Váně před téměř 5 roky(ů)

Úprava progress baru

- úprava progress baru na stránce upload
- dokud nejsou stránky zaindexované, tak progress bar zůstane na 95%
- pokud se úspětně zaindexují, naběhne 100% a vypíše se zpráva

Zobrazit rozdíly:

fe/fulltextsearch/src/app/components/pages/upload/upload.component.ts
36 36

  
37 37
    this.queryService.uploadFile(this.selectedFiles).subscribe( event => {
38 38
      if (event.type === HttpEventType.UploadProgress) {
39
        this.progress = Math.round(event.loaded / event.total * 100);
39
        this.progress = Math.round(event.loaded / event.total * 100) - 5;
40 40
      } else if (event.type === HttpEventType.Response ) {
41 41
        this.resultMessage = 'Successfully uploaded ' + this.selectedFiles.length + ' files';
42
        this.progress = 100;
42 43
        this.selectedFiles = null;
43 44
        this.LOGGER.info('Files successfully uploaded');
44 45
      }

Také k dispozici: Unified diff