Skip to content
Snippets Groups Projects
Commit 6df1c3a2 authored by Hamza HRAMCHI's avatar Hamza HRAMCHI
Browse files

FEAT #16982 TIME 0:33 add user phone

parent 74bfe955
No related branches found
No related tags found
No related merge requests found
......@@ -53,6 +53,11 @@
<ion-input type="email" name="email" [maxlength]="128" [(ngModel)]="user.email" required
pattern="(^[a-zA-Z0-9_.+-]+@[a-zA-Z0-9-]+\.[a-zA-Z0-9-.]+$)"></ion-input>
</ion-item>
<ion-item>
<ion-label color="secondary" position="floating">{{'lang.phoneAlt' | translate}} *</ion-label>
<ion-input type="text" name="phone" [(ngModel)]="user.phone" required
pattern="^(?:0|\(?\+33\)?\s?|0033\s?)[1-79](?:[\.\-\s]?\d\d){4}$"></ion-input>
</ion-item>
<ion-item>
<ion-label>{{'lang.restUser' | translate}}</ion-label>
<ion-toggle slot="start" color="primary" [disabled]="!creationMode" name="isRest" [(ngModel)]="user.isRest"
......
......@@ -18,6 +18,7 @@ export interface User {
lastname: string;
login: string;
email: string;
phone: string;
picture: string;
isRest: boolean;
signatureModes: string[];
......@@ -40,6 +41,7 @@ export class UserComponent implements OnInit {
lastname: '',
login: '',
email: '',
phone: '',
picture: '',
isRest: false,
signatureModes: ['stamp'],
......@@ -99,6 +101,7 @@ export class UserComponent implements OnInit {
lastname: '',
login: '',
email: '',
phone: '',
picture: '',
signatureModes: ['stamp'],
isRest: false,
......
......@@ -51,6 +51,12 @@
<ion-label color="secondary" position="floating">{{'lang.lastname' | translate}}</ion-label>
<ion-input name="lastname" [maxlength]="128" [(ngModel)]="profileInfo.lastname" [readonly]="authService.authMode !== 'default'" required></ion-input>
</ion-item>
<ion-item>
<ion-label color="secondary" position="floating">{{'lang.phoneAlt' | translate}}</ion-label>
<ion-input name="phone" [(ngModel)]="profileInfo.phone" [readonly]="authService.authMode !== 'default'"
pattern="^(?:0|\(?\+33\)?\s?|0033\s?)[1-79](?:[\.\-\s]?\d\d){4}$" required>
</ion-input>
</ion-item>
<div *ngIf="authService.authMode === 'default'">
<ion-list-header lines="none">
<ion-label color="primary">{{'lang.changePassword' | translate}}</ion-label>
......
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