fix : odt project and task extrafields management
This commit is contained in:
parent
c7f54439ff
commit
ceb85cfa45
@ -130,12 +130,9 @@ class doc_generic_project_odt extends ModelePDFProjects
|
|||||||
$array_key.'_statut'=>$object->getLibStatut()
|
$array_key.'_statut'=>$object->getLibStatut()
|
||||||
);
|
);
|
||||||
|
|
||||||
// Retrieve extrafields
|
|
||||||
$extrafieldkey=$object->element;
|
|
||||||
|
|
||||||
require_once DOL_DOCUMENT_ROOT.'/core/class/extrafields.class.php';
|
require_once DOL_DOCUMENT_ROOT.'/core/class/extrafields.class.php';
|
||||||
$extrafields = new ExtraFields($this->db);
|
$extrafields = new ExtraFields($this->db);
|
||||||
$extralabels = $extrafields->fetch_name_optionals_label($extrafieldkey,true);
|
$extralabels = $extrafields->fetch_name_optionals_label($object->table_element,true);
|
||||||
$object->fetch_optionals($object->id,$extralabels);
|
$object->fetch_optionals($object->id,$extralabels);
|
||||||
|
|
||||||
$resarray = $this->fill_substitutionarray_with_extrafields($object,$resarray,$extrafields,$array_key,$outputlangs);
|
$resarray = $this->fill_substitutionarray_with_extrafields($object,$resarray,$extrafields,$array_key,$outputlangs);
|
||||||
@ -154,7 +151,7 @@ class doc_generic_project_odt extends ModelePDFProjects
|
|||||||
{
|
{
|
||||||
global $conf;
|
global $conf;
|
||||||
|
|
||||||
return array(
|
$resarray = array(
|
||||||
'task_ref'=>$task->ref,
|
'task_ref'=>$task->ref,
|
||||||
'task_fk_project'=>$task->fk_project,
|
'task_fk_project'=>$task->fk_project,
|
||||||
'task_projectref'=>$task->projectref,
|
'task_projectref'=>$task->projectref,
|
||||||
@ -170,6 +167,16 @@ class doc_generic_project_odt extends ModelePDFProjects
|
|||||||
'task_note_private'=>$task->note_private,
|
'task_note_private'=>$task->note_private,
|
||||||
'task_note_public'=>$task->note_public
|
'task_note_public'=>$task->note_public
|
||||||
);
|
);
|
||||||
|
|
||||||
|
require_once DOL_DOCUMENT_ROOT.'/core/class/extrafields.class.php';
|
||||||
|
$extrafields = new ExtraFields($this->db);
|
||||||
|
$extralabels = $extrafields->fetch_name_optionals_label($task->table_element,true);
|
||||||
|
$task->fetch_optionals($task->id,$extralabels);
|
||||||
|
|
||||||
|
$resarray = $this->fill_substitutionarray_with_extrafields($task,$resarray,$extrafields,'task',$outputlangs);
|
||||||
|
|
||||||
|
return $resarray;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user