-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(history): create a new history page
- Loading branch information
Showing
48 changed files
with
449 additions
and
343 deletions.
There are no files selected for viewing
Binary file not shown.
2 changes: 2 additions & 0 deletions
2
...es/usager-notes/components/profil-historique-notes/profil-historique-notes.component.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 5 additions & 5 deletions
10
...uments/profil-structure-docs.component.ts → ...uments/profil-structure-docs.component.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 2 additions & 2 deletions
4
...tat-civil/display-etat-civil.component.ts → ...tat-civil/display-etat-civil.component.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 3 additions & 3 deletions
6
...general-historique-courriers.component.ts → ...general-historique-courriers.component.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
59 changes: 59 additions & 0 deletions
59
...nents/_historiques/profil-historique-decisions/profil-historique-decisions.component.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
<h3>Historique des décisions</h3> | ||
<div class="alert alert-info" *ngIf="usager.historique.length === 0"> | ||
<p>Aucun historique de décision n'est enregistré</p> | ||
</div> | ||
<div class="table-responsive" *ngIf="usager.historique.length > 0"> | ||
<table class="table table-hover"> | ||
<caption class="visually-hidden"> | ||
Historique des décisions | ||
</caption> | ||
<thead> | ||
<tr> | ||
<th scope="col">Date</th> | ||
<th scope="col">Type de décision</th> | ||
<th scope="col">Responsable</th> | ||
<th scope="col" class="text-end d-print-none">Actions</th> | ||
</tr> | ||
</thead> | ||
<tbody> | ||
<tr | ||
*ngFor=" | ||
let histo of usager.historique | orderByDate : 'desc'; | ||
let i = index | ||
" | ||
[attr.aria-rowindex]="i + 1" | ||
> | ||
<td> | ||
{{ histo.dateDecision | date : "dd MMMM yyyy à HH:mm" }} | ||
</td> | ||
<td> | ||
{{ USAGER_DECISION_STATUT_LABELS_PROFIL[histo.statut] }} | ||
<span *ngIf="histo.statut === 'REFUS' || histo.statut === 'RADIE'"> | ||
le {{ histo.dateDebut | date : "dd MMMM yyyy" }} | ||
</span> | ||
|
||
<span *ngIf="histo.statut === 'VALIDE'"> | ||
du | ||
<strong> | ||
{{ histo.dateDebut | date : "dd MMMM yyyy" }} | ||
</strong> | ||
au | ||
<strong>{{ histo.dateFin | date : "dd MMMM yyyy" }}</strong> | ||
</span> | ||
<div *ngIf="histo.statut === 'RADIE'"> | ||
{{ histo.motifString }} | ||
</div> | ||
</td> | ||
<td>{{ histo.userName }}</td> | ||
<td class="text-end d-print-none"> | ||
<app-delete-usager-menu | ||
*ngIf="i === 0" | ||
[usager]="usager" | ||
context="HISTORY" | ||
[me]="me" | ||
></app-delete-usager-menu> | ||
</td> | ||
</tr> | ||
</tbody> | ||
</table> | ||
</div> |
22 changes: 22 additions & 0 deletions
22
...ts/_historiques/profil-historique-decisions/profil-historique-decisions.component.spec.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
import { ComponentFixture, TestBed } from "@angular/core/testing"; | ||
|
||
import { ProfilHistoriqueDecisionsComponent } from "./profil-historique-decisions.component"; | ||
|
||
describe("ProfilHistoriqueDecisionsComponent", () => { | ||
let component: ProfilHistoriqueDecisionsComponent; | ||
let fixture: ComponentFixture<ProfilHistoriqueDecisionsComponent>; | ||
|
||
beforeEach(async () => { | ||
await TestBed.configureTestingModule({ | ||
declarations: [ProfilHistoriqueDecisionsComponent], | ||
}).compileComponents(); | ||
|
||
fixture = TestBed.createComponent(ProfilHistoriqueDecisionsComponent); | ||
component = fixture.componentInstance; | ||
fixture.detectChanges(); | ||
}); | ||
|
||
it("should create", () => { | ||
expect(component).toBeTruthy(); | ||
}); | ||
}); |
15 changes: 15 additions & 0 deletions
15
...ponents/_historiques/profil-historique-decisions/profil-historique-decisions.component.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
import { Component, Input } from "@angular/core"; | ||
import { UsagerFormModel } from "../../../../usager-shared/interfaces"; | ||
import { USAGER_DECISION_STATUT_LABELS_PROFIL } from "@domifa/common"; | ||
import { UserStructure } from "../../../../../../_common/model"; | ||
|
||
@Component({ | ||
selector: "app-profil-historique-decisions", | ||
templateUrl: "./profil-historique-decisions.component.html", | ||
}) | ||
export class ProfilHistoriqueDecisionsComponent { | ||
public readonly USAGER_DECISION_STATUT_LABELS_PROFIL = | ||
USAGER_DECISION_STATUT_LABELS_PROFIL; | ||
@Input() public me!: UserStructure; | ||
@Input() public usager!: UsagerFormModel; | ||
} |
Oops, something went wrong.