Skip to content

Commit

Permalink
Merge pull request #609 from LINCnil/fix-for-non-updated_tags_after_p…
Browse files Browse the repository at this point in the history
…ia_new_role

fix: refactor and add pia global update
  • Loading branch information
kevin-atnos authored Nov 10, 2021
2 parents d5e32ab + b981902 commit 73809d5
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -396,7 +396,7 @@ export class PiaCardComponent implements OnInit, OnChanges {
this.pia[field] = this.piaForm.controls[field].value.map(x => x.id);

await this.piaService.update(this.pia).then((resp: Pia) => {
this.pia.user_pias = resp.user_pias;
this.pia = resp;
});
}

Expand Down
8 changes: 6 additions & 2 deletions src/app/modules/entries/list/pia-line/pia-line.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -274,7 +274,9 @@ export class PiaLineComponent implements OnInit, OnChanges {
break;
}
this.pia[field] = [userBehavior.value.id];
this.piaService.update(this.pia);
this.piaService.update(this.pia).then((resp: Pia) => {
this.pia = resp;
});
}
}
});
Expand Down Expand Up @@ -302,7 +304,9 @@ export class PiaLineComponent implements OnInit, OnChanges {
this.pia['guests'] = this.pia['guests'].map(x =>
typeof x === 'object' ? x.id : x
);
this.piaService.update(this.pia);
this.piaService.update(this.pia).then((resp: Pia) => {
this.pia = resp;
});
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@
</p>
</div>
<div class="validForm">
<button (click)="onCanceled()">
<button type="reset" (click)="onCanceled()">
{{ "authentication.cancel" | translate }}
</button>
<button
Expand Down

0 comments on commit 73809d5

Please sign in to comment.