Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MOBILE - Generación de QR #191

Merged
merged 16 commits into from
Oct 18, 2023
Merged
Show file tree
Hide file tree
Changes from 5 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29,466 changes: 25,613 additions & 3,853 deletions package-lock.json

Large diffs are not rendered by default.

18 changes: 10 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,7 @@
"@ionic/storage-angular": "^3.0.6",
"@types/google-maps": "^3.2.2",
"agm-core": "^1.0.0-beta.5",
"angularx-qrcode": "^10.0.12",
"config-cordova": "^0.8.4",
"cordova-browser": "6.0.0",
"cordova.plugins.diagnostic": "^6.0.3",
Expand All @@ -106,6 +107,7 @@
"rxjs": "^6.6.3",
"rxjs-compat": "^6.6.3",
"shiro-trie": "^0.4.9",
"signature_pad": "^4.0.7",
"svg-inline-loader": "^0.8.2",
"tslib": "^2.0.0",
"zone.js": "~0.10.3"
Expand All @@ -123,13 +125,13 @@
"@types/node": "^12.11.1",
"codelyzer": "^6.0.0",
"com-badrit-base64": "^0.2.0",
"cordova-android": "^10.1.1",
"cordova-android": "^9.1.0",
"cordova-common": "^4.0.2",
"cordova-ios": "^6.2.0",
"cordova-plugin-advanced-http": "^3.2.2",
"cordova-plugin-androidx": "^3.0.0",
"cordova-plugin-androidx-adapter": "^1.1.3",
"cordova-plugin-camera": "^6.0.0",
"cordova-plugin-camera": "^5.0.2",
"cordova-plugin-device": "^2.0.2",
"cordova-plugin-email-composer": "^0.9.2",
"cordova-plugin-file": "^6.0.2",
Expand Down Expand Up @@ -198,19 +200,19 @@
"ANDROIDBLACKLISTSECURESOCKETPROTOCOLS": "SSLv3,TLSv1"
},
"cordova-sqlite-storage": {},
"cordova-plugin-camera": {
"ANDROIDX_CORE_VERSION": "1.6.+"
},
"cordova-plugin-email-composer": {
"ANDROID_SUPPORT_V4_VERSION": "27.+"
},
"mx.ferreyra.callnumber": {},
"call-number": {}
"call-number": {},
"cordova-plugin-camera": {
"ANDROID_SUPPORT_V4_VERSION": "27.+"
}
},
"platforms": [
"browser",
"android",
"ios"
"ios",
"android"
]
}
}
3 changes: 2 additions & 1 deletion src/app/app.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ import { SQLite } from '@ionic-native/sqlite/ngx';
import { ConnectivityService } from './providers/connectivity.service';
import { PhotoViewer } from '@ionic-native/photo-viewer/ngx';
import { AdsModule } from './ads/ads.module';
import { ProfesionalProvider } from 'src/providers/profesional';

import { LOCALE_ID } from '@angular/core';
import localeSpanish from '@angular/common/locales/es';
Expand All @@ -47,7 +48,6 @@ import { HttpModule } from '@angular/http';
import { DescargaArchivosProvider } from 'src/providers/descarga-archivos';
import { FirebaseMessaging } from '@ionic-native/firebase-messaging/ngx';
import { HTTP } from '@ionic-native/http/ngx';

registerLocaleData(localeSpanish, 'es');
moment.locale('es');

Expand Down Expand Up @@ -100,6 +100,7 @@ moment.locale('es');
SQLite,
PhotoViewer,
DescargaArchivosProvider,
ProfesionalProvider,
FirebaseMessaging,
HTTP,
StorageService,
Expand Down
7 changes: 7 additions & 0 deletions src/app/home/home-page.ts
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,14 @@ export class HomePage {
this.router.navigate(['profesional/formulario-terapeutico']);
}

misMatriculas() {
this.router.navigate(['profesional/mis-matriculas']);
}


get background() {
return ((this.isLogin() && this.familiar) ? 'familiar' : 'dark');
}


}
38 changes: 23 additions & 15 deletions src/app/home/home.page.html
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ <h4 class="welcome-subtitle " [ngClass]="{'wheat' : familiar, 'primary': !famili
<li class="fab-secundario">
<div class="item-content horizontal ic-0">
<a class="item-icon outline circular" [class.disabled]="!isLogin()"
(click)="misTurnos()">
(click)="misTurnos()">
<ion-icon name="andes-turno"></ion-icon>
</a>
<div class="fab-title" (click)="misTurnos()">Mis<br>turnos</div>
Expand All @@ -54,7 +54,7 @@ <h4 class="welcome-subtitle " [ngClass]="{'wheat' : familiar, 'primary': !famili
<li class="fab-secundario">
<div class="item-content horizontal ic-2">
<a class="item-icon outline circular" [class.disabled]="!isLogin()"
(click)="laboratorio()">
(click)="laboratorio()">
<ion-icon name="andes-laboratorio"></ion-icon>
</a>
<div class="fab-title" (click)="laboratorio()">Mis<br>laboratorios </div>
Expand All @@ -64,7 +64,7 @@ <h4 class="welcome-subtitle " [ngClass]="{'wheat' : familiar, 'primary': !famili
<li class="fab-secundario" *ngIf="!familiar">
<div class="item-content vertical ic-3">
<a class="item-icon outline circular" [class.disabled]="!isLogin()"
(click)="misFamiliares()">
(click)="misFamiliares()">
<ion-icon name="andes-violencia-familiar"></ion-icon>
</a>
<div class="fab-title" (click)="misFamiliares()">Mis<br>familiares
Expand All @@ -76,7 +76,7 @@ <h4 class="welcome-subtitle " [ngClass]="{'wheat' : familiar, 'primary': !famili
<li class="fab-secundario" *ngIf="familiar">
<div class="item-content vertical ic-3">
<a class="item-icon outline circular" [class.disabled]="!isLogin()"
(click)="salirDeFamiliar()">
(click)="salirDeFamiliar()">
<ion-icon name="andes-violencia-familiar"></ion-icon>
</a>
<div class="fab-title" (click)="salirDeFamiliar()">Salir de<br>familiar
Expand All @@ -87,7 +87,7 @@ <h4 class="welcome-subtitle " [ngClass]="{'wheat' : familiar, 'primary': !famili
<li class="fab-secundario">
<div class="item-content horizontal-left ic-3">
<a class="item-icon outline circular" [class.disabled]="!isLogin()"
(click)="historiaDeSalud()">
(click)="historiaDeSalud()">
<ion-icon name="andes-huds"></ion-icon>
</a>
<div class="fab-title" (click)="historiaDeSalud()">Mi historia<br>de salud</div>
Expand All @@ -103,10 +103,19 @@ <h4 class="welcome-subtitle " [ngClass]="{'wheat' : familiar, 'primary': !famili
<img src="assets/svg/andes-profesional-in.svg" alt="">
</button>
<ul class="circle-container">

<li class="fab-secundario">
<div class="item-content horizontal ic-0">
<a class="item-icon outline circular" [class.disabled]="!isLogin()"
(click)="misMatriculas()">
<ion-icon class="icono-usuarios" name="andes-usuarios"></ion-icon>
</a>
<div class="fab-title" (click)="misMatriculas()">Mis<br>matrículas
</div>
</div>
</li>
<li class="fab-secundario"
[ngStyle]="{visibility: authService.check('rup:?') ? 'visible' : 'hidden' }">
<div class="item-content horizontal ic-2">
<div class="item-content horizontal ic-1">
<a class="item-icon outline circular" [class.disabled]="!isLogin()" (click)="rup()">
<ion-icon name="andes-vacuna"></ion-icon>
</a>
Expand All @@ -115,37 +124,36 @@ <h4 class="welcome-subtitle " [ngClass]="{'wheat' : familiar, 'primary': !famili
</li>

<li class="fab-secundario">
<div class="item-content horizontal ic-3">
<div class="item-content horizontal ic-2">
<a class="item-icon outline circular" [class.disabled]="!isLogin()"
(click)="misAgendas()">
(click)="misAgendas()">
<ion-icon name="andes-turno"></ion-icon>
</a>
<div class="fab-title" (click)="misAgendas()">Mis<br>agendas</div>
</div>
</li>
<li class="fab-secundario"
[ngStyle]="{visibility: authService.check('mpi:?') ? 'visible' : 'hidden' }">
<div class="item-content horizontal ic-4">
<div class="item-content vertical ic-3">
<a class="item-icon outline circular" [class.disabled]="!isLogin()" (click)="mpi()">
<ion-icon name="andes-mpi"></ion-icon>
</a>
<div class="fab-title" (click)="mpi()">MPI </div>
</div>
</li>
<li class="fab-secundario">
<div class="item-content vertical ic-6">
<div class="item-content horizontal-left ic-4">
<a class="item-icon outline circular" [class.disabled]="!isLogin()"
(click)="formularioTerapeutico()">
(click)="formularioTerapeutico()">
<ion-icon name="medkit-outline"></ion-icon>
</a>
<div class="fab-title" (click)="formularioTerapeutico()">Formulario terapéutico
<div class="fab-title" (click)="formularioTerapeutico()">Formulario <br>terapéutico
</div>
</div>
</li>
<li class="fab-secundario"></li>
<li class="fab-secundario"></li>
<li class="fab-secundario"></li>
<li class="fab-secundario"></li>
</ul>
</section>
</ion-col>
Expand Down Expand Up @@ -208,4 +216,4 @@ <h4 class="welcome-subtitle " [ngClass]="{'wheat' : familiar, 'primary': !famili
</ion-fab-button>
</ion-fab-list>
</ion-fab>
</ion-content>
</ion-content>
5 changes: 5 additions & 0 deletions src/app/home/home.page.scss
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,8 @@
text-decoration: none;
}

.icono-usuarios {
.icon-inner {
font-size: 3.5rem !important;
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
<ion-header class="dark">
<ion-toolbar>
<ion-back-button slot="start" defaultHref="home" text=""></ion-back-button>
<ion-title><small>COMPROBANTE DE PAGO </small></ion-title>
<ion-buttons slot="end">
<ion-menu-button></ion-menu-button>
</ion-buttons>
</ion-toolbar>
</ion-header>

<ion-content *ngIf="authProvider.user" class="dark" padding>
<div class="no-item" *ngIf="inProgress">
<ads-icon icon="ball-triangle"></ads-icon>
</div>
<div>
<div *ngIf="!inProgress" class="content-title">
<button class="outline circular">
<ion-icon class="content-icon" name="cloud-upload-outline"></ion-icon>
</button>
Adjuntar comprobante de pago
</div>

<div *ngIf="files.length" class="img-wrapper">
<div *ngIf="files[0].loading">
<ads-icon icon="ball-triangle"></ads-icon>
</div>
<div *ngIf="!files[0].loading">
<div class="close-icon" (click)="remove()">
<ion-icon name="close"></ion-icon>
</div>
<div *ngIf="files[0].ext !== 'pdf'">
<img [src]="files[0].file" class="img-fluid" width="80" height="104" alt="">
</div>
<div *ngIf="files[0].ext === 'pdf'">
<img src="assets/img/pdf.png" width="80" height="104" class="img-fluid" alt="">
</div>
</div>
</div>

<ion-grid *ngIf="!inProgress">
<ion-row>
<ion-col col-6 for="fileupload">
<ion-button color="primary" expand="block" (click)="upload.click()" [disabled]="files.length === 1">
<ion-icon name="search"></ion-icon>Examinar
</ion-button>
<input id="fileupload" type="file" (change)="changeListener($event)" style="display:none;" #upload>
</ion-col>
<ion-col col-6>
<ion-button name="adjuntar" shape="round" color="success" size="medium" expand="block"
[disabled]="files.length === 0" (click)="confirmarComprobante()">
<ion-label>Adjuntar archivo</ion-label>
</ion-button>
</ion-col>
</ion-row>
</ion-grid>
</div>

</ion-content>
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
.content-title {
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
margin-top: 1rem;
margin-bottom: 1rem;
}

.cuerpo {
flex-grow: 2;
}

.img-wrapper {
margin: 0 0.5rem;
}
Loading