Fix block to generate donation document missing
This commit is contained in:
parent
a815326a28
commit
c478ab952f
@ -692,7 +692,8 @@ class FormFile
|
|||||||
$out.= '<!-- html.formfile::showdocuments -->'."\n";
|
$out.= '<!-- html.formfile::showdocuments -->'."\n";
|
||||||
|
|
||||||
// Show title of array if not already shown
|
// Show title of array if not already shown
|
||||||
if ((! empty($file_list) || ! empty($link_list) || preg_match('/^massfilesarea/', $modulepart)) && ! $headershown)
|
if ((! empty($file_list) || ! empty($link_list) || preg_match('/^massfilesarea/', $modulepart))
|
||||||
|
&& ! $headershown)
|
||||||
{
|
{
|
||||||
$headershown=1;
|
$headershown=1;
|
||||||
$out.= '<div class="titre">'.$titletoshow.'</div>'."\n";
|
$out.= '<div class="titre">'.$titletoshow.'</div>'."\n";
|
||||||
|
|||||||
@ -209,7 +209,7 @@ print load_fiche_titre($langs->trans("DonationsSetup"),$linkback,'title_setup');
|
|||||||
|
|
||||||
$head = donation_admin_prepare_head();
|
$head = donation_admin_prepare_head();
|
||||||
|
|
||||||
dol_fiche_head($head, 'general', $langs->trans("Donations"), 0, 'payment');
|
dol_fiche_head($head, 'general', $langs->trans("Donations"), -1, 'payment');
|
||||||
|
|
||||||
|
|
||||||
// Document templates
|
// Document templates
|
||||||
|
|||||||
@ -67,7 +67,7 @@ print load_fiche_titre($langs->trans("DonationsSetup"),$linkback,'title_setup');
|
|||||||
|
|
||||||
$head = donation_admin_prepare_head();
|
$head = donation_admin_prepare_head();
|
||||||
|
|
||||||
dol_fiche_head($head, 'attributes', $langs->trans("Donations"), 0, 'payment');
|
dol_fiche_head($head, 'attributes', $langs->trans("Donations"), -1, 'payment');
|
||||||
|
|
||||||
require DOL_DOCUMENT_ROOT.'/core/tpl/admin_extrafields_view.tpl.php';
|
require DOL_DOCUMENT_ROOT.'/core/tpl/admin_extrafields_view.tpl.php';
|
||||||
|
|
||||||
|
|||||||
@ -764,7 +764,7 @@ if (! empty($id) && $action != 'edit')
|
|||||||
$filename = dol_sanitizeFileName($object->id);
|
$filename = dol_sanitizeFileName($object->id);
|
||||||
$filedir = $conf->don->dir_output . "/" . dol_sanitizeFileName($object->id);
|
$filedir = $conf->don->dir_output . "/" . dol_sanitizeFileName($object->id);
|
||||||
$urlsource = $_SERVER['PHP_SELF'].'?rowid='.$object->id;
|
$urlsource = $_SERVER['PHP_SELF'].'?rowid='.$object->id;
|
||||||
$genallowed = ($object->statut == 2 && ($object->paid == 0 || $user->admin) && $user->rights->don->lire);
|
$genallowed = (($object->paid == 0 || $user->admin) && $user->rights->don->lire);
|
||||||
$delallowed = $user->rights->don->creer;
|
$delallowed = $user->rights->don->creer;
|
||||||
|
|
||||||
print $formfile->showdocuments('donation',$filename,$filedir,$urlsource,$genallowed,$delallowed,$object->modelpdf);
|
print $formfile->showdocuments('donation',$filename,$filedir,$urlsource,$genallowed,$delallowed,$object->modelpdf);
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user