Skip to content
Snippets Groups Projects
Commit df17de9d authored by Laurent Destailleur's avatar Laurent Destailleur Committed by GitHub
Browse files

Merge pull request #6543 from laudeco/feature/expenseNoteFusionPdf

add 'fusion pdf' in mass action of expense report
parents 6f323174 a05ebb6c
No related branches found
No related tags found
No related merge requests found
...@@ -1807,6 +1807,14 @@ function dol_check_secure_access_document($modulepart,$original_file,$entity,$fu ...@@ -1807,6 +1807,14 @@ function dol_check_secure_access_document($modulepart,$original_file,$entity,$fu
} }
$original_file=$conf->facture->dir_output.'/temp/massgeneration/'.$user->id.'/'.$original_file; $original_file=$conf->facture->dir_output.'/temp/massgeneration/'.$user->id.'/'.$original_file;
} }
else if ($modulepart == 'massfilesarea_expensereport')
{
if ($fuser->rights->facture->lire || preg_match('/^specimen/i',$original_file))
{
$accessallowed=1;
}
$original_file=$conf->expensereport->dir_output.'/temp/massgeneration/'.$user->id.'/'.$original_file;
}
// Wrapping for interventions // Wrapping for interventions
else if (($modulepart == 'fichinter' || $modulepart == 'ficheinter') && !empty($conf->ficheinter->dir_output)) else if (($modulepart == 'fichinter' || $modulepart == 'ficheinter') && !empty($conf->ficheinter->dir_output))
......
...@@ -303,7 +303,7 @@ if ($resql) ...@@ -303,7 +303,7 @@ if ($resql)
// List of mass actions available // List of mass actions available
$arrayofmassactions = array( $arrayofmassactions = array(
//'presend'=>$langs->trans("SendByMail"), //'presend'=>$langs->trans("SendByMail"),
//'builddoc'=>$langs->trans("PDFMerge"), 'builddoc'=>$langs->trans("PDFMerge"),
); );
if ($user->rights->expensereport->supprimer) $arrayofmassactions['delete']=$langs->trans("Delete"); if ($user->rights->expensereport->supprimer) $arrayofmassactions['delete']=$langs->trans("Delete");
if ($massaction == 'presend') $arrayofmassactions=array(); if ($massaction == 'presend') $arrayofmassactions=array();
...@@ -716,7 +716,7 @@ if ($resql) ...@@ -716,7 +716,7 @@ if ($resql)
print '</form>'."\n"; print '</form>'."\n";
/*
if ($massaction == 'builddoc' || $action == 'remove_file' || $show_files) if ($massaction == 'builddoc' || $action == 'remove_file' || $show_files)
{ {
// Show list of available documents // Show list of available documents
...@@ -727,13 +727,12 @@ if ($resql) ...@@ -727,13 +727,12 @@ if ($resql)
$genallowed=$user->rights->expensereport->lire; $genallowed=$user->rights->expensereport->lire;
$delallowed=$user->rights->expensereport->lire; $delallowed=$user->rights->expensereport->lire;
print $formfile->showdocuments('massfilesarea_orders','',$filedir,$urlsource,0,$delallowed,'',1,1,0,48,1,$param,$title,''); print $formfile->showdocuments('massfilesarea_expensereport','',$filedir,$urlsource,0,$delallowed,'',1,1,0,48,1,$param,$title,'');
} }
else else
{ {
print '<br><a name="show_files"></a><a href="'.$_SERVER["PHP_SELF"].'?show_files=1'.$param.'#show_files">'.$langs->trans("ShowTempMassFilesArea").'</a>'; print '<br><a name="show_files"></a><a href="'.$_SERVER["PHP_SELF"].'?show_files=1'.$param.'#show_files">'.$langs->trans("ShowTempMassFilesArea").'</a>';
} }
*/
} }
else else
{ {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment