22if (!defined(
'ALLOWED'))
23 die(
'Appel direct ne sont pas permis');
40$aRow=
$cn->get_array(
"select a.f_id,ap_id,ag_id,f.ad_value,f.ad_id,fd.fd_id,jfa.jnt_order
42join fiche f1 on (a.f_id=f1.f_id)
43join fiche_detail f on (a.f_id=f.f_id)
44join fiche_def fd on (fd.fd_id=f1.fd_id)
45join jnt_fic_attr jfa on (fd.fd_id=jfa.fd_id and jfa.ad_id=f.ad_id)
47order by f1.fd_id, a.f_id,jnt_order",[
$ag_id]);
60join action_person_option apo on (a.ap_id=apo.action_person_id)
61join contact_option_ref cor on (cor.cor_id=apo.contact_option_ref_id)
73 $aColHeader =
$cn->get_array(
"select jnt_order,
77 join jnt_fic_attr jfa using (fd_id)
78 join attr_def ad using (ad_id)
81 order by jnt_order",[
$aRow[
$i][
'fd_id']]);
84 for ( $j = 0;$j <
$nb_col;$j++) {
85 $aCol[]=$aColHeader[$j][
'ad_text'];
89 $aOptionCat=
$cn->get_array(
"select
92 public.jnt_document_option_contact jdoc
93 join contact_option_ref cor on
94 (jdoc.contact_option_ref_id = cor_id )
99 for ( $j = 0;$j <
$nb_col;$j++) {
100 $aCol[]=$aOptionCat[$j][
'cor_label'];
102 $csv->write_header($aCol);
111join action_person_option apo on (a.ap_id=apo.action_person_id)
112join contact_option_ref cor on (cor.cor_id=apo.contact_option_ref_id)
global $g_user
if no group available , then stop