Merge branch 'thierry' of ssh://git.marbelium.com:10023/Viiciouss/XJC into anis

thierry
Viiciouss 7 years ago
commit 7de085f948

@ -18,7 +18,7 @@
<i class="fa fa-calendar-times-o prefix grey-text"></i>
<input type="date" id="orangeForm-Date" [(ngModel)]="opComm.dateFin" placeholder="Date fin" required min="minDateTimeTest" max="maxDateTimeTest" name="dateFin" #dateFin="ngModel">
<div *ngIf="(validationDateFin()) && (dateFin.dirty || dateFin.touched)" class="alert alert-danger">
La date de fin doit être comprise entre <strong><i>{{todayDateTimeTest | date:'dd/MM/yyyy'}} et 01/01/2117</i></strong>.
La date de fin doit être comprise entre <strong><i>{{opComm.dateDebut | date:'dd/MM/yyyy'}} et 01/01/2117</i></strong>.
</div>
</div>

@ -110,7 +110,7 @@
</div>
<div class="row">
<div class="col-md-12" id="footer-3">
<div *ngIf="carteEnvoieOK" class="alert alert-danger">
<div *ngIf="carteEnvoieOK" class="alert alert-success">
Une carte vient d'être envoyée au nouveau Parrain {{cartePar.parrainCarte.firstname}} {{cartePar.parrainCarte.familyname}}
</div>
<div *ngIf="echecRegisterPar" class="alert alert-danger">

@ -230,31 +230,31 @@ export class EnvoyerCarteComponent implements OnInit, OnDestroy {
this.carteEnvoieOK = false;
})
.then(function(userCreate) {
// I don't know if the next statement is necessary
const imagePath = 'profilImage/' + userCreate.uid + '/userPic.jpg';
const dbRef = firebase.database().ref();
const userRef = dbRef.child('Parrain').child(userCreate.uid);
userCreate.updateProfile({
displayName: parrainTemp.status,
photoURL: imagePath,
emailVerified: true
});
try {
parrainTemp.uid = userCreate.uid;
parrainTemp.emailVerified = userCreate.emailVerified;
userRef.set(parrainTemp);
if(userCreate){
// I don't know if the next statement is necessary
const imagePath = 'profilImage/' + userCreate.uid + '/userPic.jpg';
const dbRef = firebase.database().ref();
const userRef = dbRef.child('Parrain').child(userCreate.uid);
userCreate.updateProfile({
displayName: parrainTemp.status,
photoURL: imagePath,
emailVerified: true
});
try {
parrainTemp.uid = userCreate.uid;
parrainTemp.emailVerified = userCreate.emailVerified;
userRef.set(parrainTemp);
this.secondaryApp.auth().sendPasswordResetEmail(userCreate.email);
userCreate.sendEmailVerification();
this.secondaryApp.auth().signOut();
} catch (e) {
// No content response..
console.log(e);
// this.goToOpComm();
// this.router.navigate(['/']);
} catch (e) {
// No content response..
console.log(e);
// this.goToOpComm();
// this.router.navigate(['/']);
}
}
// fin
});
@ -276,6 +276,9 @@ export class EnvoyerCarteComponent implements OnInit, OnDestroy {
this.carteEnvoieEncours = true;
this.carteEnvoieOK = true;
setTimeout(() => {
this.secondaryApp.auth().sendPasswordResetEmail(elementParTemp.email);
this.secondaryApp.auth().currentUser.sendEmailVerification();
this.secondaryApp.auth().signOut();
this.carteEnvoieEncours = false;
this.goToOpComm();
this.toastrService.success('Envoie de la carte à ' + elementParTemp.familyname
@ -287,6 +290,7 @@ export class EnvoyerCarteComponent implements OnInit, OnDestroy {
});
});
} else {
this.carteEnvoieOK = false;
this.echecRegisterPar = true;
}
});
@ -437,8 +441,9 @@ export class EnvoyerCarteComponent implements OnInit, OnDestroy {
//////
ngOnDestroy() {
this.secondaryApp.delete();
this.validC = '';
if (this.subscription){
if (this.subscription) {
this.subscription.unsubscribe();
}

@ -149,16 +149,15 @@
<label for="orangeForm-File">Choose a file</label>
</div>-->
<div class="flex-column flex-center">
<button class="btn btn-deep-orange" style="margin-top: 2%;" (click)="modifyPasswordSection()">Modifier Email/Mot de passe</button>
</div>
<div class="md-form">
<i class="fa fa-file-picture-o prefix grey-text"></i>
<input type="file" id="orangeForm-File" name="file" style="padding-top: 1%;" accept=".jpg, .jpeg, .png">
</div>
<!--
<div class="flex-column flex-center">
<input type="file" name="file-1[]" id="orangeForm-File" class="inputfile inputfile-1" data-multiple-caption="{count} files selected" multiple />
<label class="waves-effect" for="orangeForm-File"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="17" viewBox="0 0 20 17"><path d="M10 0l-5.2 4.9h3.3v5.1h3.8v-5.1h3.3l-5.2-4.9zm9.3 11.5l-3.2-2.1h-2l3.4 2.6h-3.5c-.1 0-.2.1-.2.1l-.8 2.3h-6l-.8-2.2c-.1-.1-.1-.2-.2-.2h-3.6l3.4-2.6h-2l-3.2 2.1c-.4.3-.7 1-.6 1.5l.6 3.1c.1.5.7.9 1.2.9h16.3c.6 0 1.1-.4 1.3-.9l.6-3.1c.1-.5-.2-1.2-.7-1.5z"/></svg> <span>Choisir image</span></label>
<button class="btn btn-deep-orange" style="margin-top: 2%;" (click)="modifyPasswordSection()">Modifier Email/Mot de passe</button>
</div>-->
<div class="card" style="margin-bottom: 5%" *ngIf="modifiermdp">
<div class="md-form">
<i class="fa fa-lock prefix grey-text"></i>

Loading…
Cancel
Save