- saving progress;

This commit is contained in:
Vitalii Kiiko
2024-12-16 15:13:41 +01:00
parent 9789f5a07a
commit ea2b46ddfe
5 changed files with 102 additions and 64 deletions

View File

@@ -88,7 +88,7 @@ const DomandaEditPreInstructor = () => {
const doNewSoccorso = () => {
if (connectedSoccorsoId !== 0) {
doSaveDraft(`/domande/${id}/soccorso/${connectedSoccorsoId}`)
navigate(`/domande/${id}/soccorso/${connectedSoccorsoId}`);
} else {
doSaveDraft(`/domande/${id}/aggiungi-soccorso/`)
}
@@ -605,16 +605,34 @@ const DomandaEditPreInstructor = () => {
</div>
</div>
{/*<div className="appPageSection">
<div className="appPageSection">
<h2>{__('Documenti di soccorso', 'gepafin')}</h2>
<ListOfFiles
files={data.files}
updateFn={updateEvaluationValue}
shouldDisableFieldFn={shouldDisableField}
name="files"
ndg={data.ndg}
applicationId={id}/>
</div>*/}
{data.amendmentDetails
.filter(o => o.amendmentDocuments && !isEmpty(o.amendmentDocuments)
|| o.formFieldDocuments && !isEmpty(o.formFieldDocuments))
.map(o => {
const aDocs = pathOr([],['amendmentDocuments'], o)
.map(o => ({
id: o.fieldId,
label: o.nameValue,
fileDetail: o.fileValue,
valid: o.valid
}));
const fDocs = pathOr([],['formFieldDocuments'], o);
return {
id: o.id,
files: [...aDocs, ...fDocs]
}
})
.map(o => <ListOfFiles
files={o.files}
updateFn={updateEvaluationValue}
shouldDisableFieldFn={shouldDisableField}
name="files"
ndg={data.ndg}
applicationId={id}/>)}
</div>
<div className="appPageSection">
<h2>{__('Punteggi di valutazione', 'gepafin')}</h2>