Skip to content

Commit

Permalink
[VAS] Story 11586: up up
Browse files Browse the repository at this point in the history
  • Loading branch information
laedanrex committed Sep 4, 2023
1 parent 1d48e32 commit 13d6c74
Show file tree
Hide file tree
Showing 14 changed files with 658 additions and 333 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@

import com.fasterxml.jackson.annotation.JsonInclude;
import fr.gouv.vitam.common.model.administration.ActivationStatus;
import fr.gouv.vitam.common.model.administration.SignaturePolicy;
import fr.gouv.vitamui.commons.api.domain.IdDto;
import lombok.Getter;
import lombok.Setter;
Expand Down Expand Up @@ -96,4 +97,6 @@ public class IngestContractDto extends IdDto implements Serializable {
private String managementContractId;

private boolean computeInheritedRulesAtIngest;

private SignaturePolicy signaturePolicy;
}
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@

public class IngestContractConverter {

private static final VitamUILogger LOGGER = VitamUILoggerFactory.getInstance(IngestContractConverter.class);
private static final VitamUILogger LOGGER = VitamUILoggerFactory.getInstance(IngestContractConverter.class);

public IngestContractModel convertDtoToVitam(final IngestContractDto dto) {
final IngestContractModel ingestContract = VitamUIUtils.copyProperties(dto, new IngestContractModel());
Expand All @@ -65,6 +65,7 @@ public IngestContractModel convertDtoToVitam(final IngestContractDto dto) {
ingestContract.setActivationdate(dto.getActivationdate());
ingestContract.setDeactivationdate(dto.getDeactivationdate());
ingestContract.setComputeInheritedRulesAtIngest(dto.isComputeInheritedRulesAtIngest());
ingestContract.setSignaturePolicy(dto.getSignaturePolicy());

return ingestContract;
}
Expand All @@ -85,6 +86,7 @@ public IngestContractDto convertVitamToDto(final IngestContractModel ingestContr
dto.setLastupdate(ingestContract.getLastupdate());
dto.setActivationdate(ingestContract.getActivationdate());
dto.setDeactivationdate(ingestContract.getDeactivationdate());
dto.setSignaturePolicy(ingestContract.getSignaturePolicy());

return dto;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,4 +52,18 @@ export interface IngestContract extends Id {
archiveProfiles: Array<string>;
managementContractId: string;
computeInheritedRulesAtIngest: boolean;
signaturePolicy: SignaturePolicy;
}

export interface SignaturePolicy {
signedDocument: SignedDocumentPolicyEnum;
needSignature: boolean;
needTimestamp: boolean;
needAdditionalProof: boolean;
}

export enum SignedDocumentPolicyEnum {
ALLOWED = 'ALLOWED',
ONLY = 'ONLY',
FORBIDDEN = 'FORBIDDEN',
}
38 changes: 38 additions & 0 deletions ui/ui-frontend-common/src/assets/shared-i18n/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -4407,5 +4407,43 @@
"SYMBOL": "kg"
}
}
},
"INGEST_CONTRACT": {
"SIGNED_DOCUMENT_TYPE": {
"ALLOWED": "Allowed",
"ONLY": "Mandatory",
"FORBIDDEN": "Forbidden"
},
"ELEMENT_TO_CHECK": {
"SIGNED_DOCUMENT": "Signed document",
"SIGNATURE": "Signature",
"TIMESTAMP": "Timestamp",
"ADDITIONAL_EVIDENCES": "Additional evidences"
},
"MODAL_CREATE": {
"TITLE": "Creation of an ingest contract",
"INFORMATIONS": {
"TITLE": "Informations"
},
"FILES_FORMAT": {
"TITLE": "Format des fichiers"
},
"OBJECTS": {
"TITLE": "Objets"
},
"INHERITANCE": {
"TITLE": "Héritage"
},
"ATTACHMENT_POSITION": {
"TITLE": "Position de rattachement"
},
"ATTACHMENT_CONTROLS": {
"TITLE": "Contrôle des rattachements"
},
"SIGNING_POLICY": {
"TITLE": "Ingest of signed documents",
"ELEMENTS_TO_CHECK": "Systematic verification of the presence of the following elements:"
}
}
}
}
39 changes: 38 additions & 1 deletion ui/ui-frontend-common/src/assets/shared-i18n/fr.json
Original file line number Diff line number Diff line change
Expand Up @@ -3960,7 +3960,6 @@
"VERIFY_TIMESTAMP.VERIFY_TOKEN_TIMESTAMP": "Vérification de l'horodatage",
"VERIFY_TIMESTAMP.WARNING": "Avertissement lors de la vérification de l'horodatage",
"VERIFY_TIMESTAMP": "Vérification de l'horodatage",

"ARCHIVE_TRANSFER_LABEL": "Transfert des unités archivistiques et des groupes d'objets",
"CHECK_DATAOBJECTPACKAGE.TOO_MANY_VERSION_BY_USAGE.KO": "Le transfert de plusieurs versions d'un même usage dans un même versement est interdit",
"CHECK_UNIT_SCHEMA.RULE_DATE_FORMAT.KO": "Échec du calcul des dates d'échéance : la date ne peut être gérée",
Expand Down Expand Up @@ -5320,5 +5319,43 @@
"SYMBOL": "kg"
}
}
},
"INGEST_CONTRACT": {
"SIGNED_DOCUMENT_TYPE": {
"ALLOWED": "Autorisé",
"ONLY": "Obligatoire",
"FORBIDDEN": "Interdit"
},
"ELEMENT_TO_CHECK": {
"SIGNED_DOCUMENT": "Document signé",
"SIGNATURE": "Signature",
"TIMESTAMP": "Horodatage",
"ADDITIONAL_EVIDENCES": "Preuves complémentaires"
},
"MODAL_CREATE": {
"TITLE": "Création d'un contrat d'entrée",
"INFORMATIONS": {
"TITLE": "Informations"
},
"FILES_FORMAT": {
"TITLE": "Format des fichiers"
},
"OBJECTS": {
"TITLE": "Objets"
},
"INHERITANCE": {
"TITLE": "Héritage"
},
"ATTACHMENT_POSITION": {
"TITLE": "Position de rattachement"
},
"ATTACHMENT_CONTROLS": {
"TITLE": "Contrôle des rattachements"
},
"SIGNING_POLICY": {
"TITLE": "Versement de documents signés",
"ELEMENTS_TO_CHECK": "Vérification systématique de la présence des éléments suivants:"
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
&.disabled {
border-color: var(--vitamui-grey);
}


.mat-button-toggle-disabled {
background-color: var(--vitamui-grey-300);
Expand All @@ -38,10 +38,9 @@
}

.mat-button-toggle-label-content {

font-size: 14px;
line-height: 36px!important;
padding: 0 14px!important;
line-height: 22px !important;
padding: 6px 30px !important;
}
.mat-button-toggle-button {
padding: 1px 0 0 0;
Expand Down Expand Up @@ -92,4 +91,4 @@
}
}
}
}
}
2 changes: 1 addition & 1 deletion ui/ui-frontend-common/src/sass/material/_modal.scss
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ $footer-height: 100px !default;
@extend %mat-dialog-container;

.header {
padding: 30px 60px 30px 60px;
padding: 30px 60px 20px 60px;
}

.content {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,6 @@
<input
type="checkbox"
id="TRANSFER_FINAL_ACTION"
type="checkbox"
(click)="checkBoxChange('FINAL_ACTION_TYPE_TRANSFER', $event)"
[checked]="storageAdditionalCriteria.get('FINAL_ACTION_TYPE_TRANSFER')"
/>
Expand All @@ -252,7 +251,6 @@
<input
type="checkbox"
id="RESTRICT_ACCESS_FINAL_ACTION"
type="checkbox"
(click)="checkBoxChange('FINAL_ACTION_TYPE_RESTRICT_ACCESS', $event)"
[checked]="storageAdditionalCriteria.get('FINAL_ACTION_TYPE_RESTRICT_ACCESS')"
/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,6 @@
<input
type="checkbox"
id="TRANSFER_FINAL_ACTION"
type="checkbox"
(click)="checkBoxChange('FINAL_ACTION_TYPE_TRANSFER', $event)"
[checked]="storageAdditionalCriteria.get('FINAL_ACTION_TYPE_TRANSFER')"
/>
Expand All @@ -230,7 +229,6 @@
<input
type="checkbox"
id="RESTRICT_ACCESS_FINAL_ACTION"
type="checkbox"
(click)="checkBoxChange('FINAL_ACTION_TYPE_RESTRICT_ACCESS', $event)"
[checked]="storageAdditionalCriteria.get('FINAL_ACTION_TYPE_RESTRICT_ACCESS')"
/>
Expand Down
Loading

0 comments on commit 13d6c74

Please sign in to comment.