diff --git a/htdocs/core/lib/expensereport.lib.php b/htdocs/core/lib/expensereport.lib.php index bc5641b2593..cc60f9feb13 100644 --- a/htdocs/core/lib/expensereport.lib.php +++ b/htdocs/core/lib/expensereport.lib.php @@ -56,6 +56,18 @@ function expensereport_prepare_head($object) $head[$h][2] = 'documents'; $h++; + if (empty($conf->global->MAIN_DISABLE_NOTES_TAB)) + { + $nbNote = 0; + if(!empty($object->note_private)) $nbNote++; + if(!empty($object->note_public)) $nbNote++; + $head[$h][0] = DOL_URL_ROOT.'/expensereport/note.php?id='.$object->id; + $head[$h][1] = $langs->trans('Notes'); + if ($nbNote > 0) $head[$h][1].= ' '.$nbNote.''; + $head[$h][2] = 'note'; + $h++; + } + $head[$h][0] = DOL_URL_ROOT . '/expensereport/info.php?id=' . $object->id; $head[$h][1] = $langs->trans("Info"); $head[$h][2] = 'info'; diff --git a/htdocs/core/lib/functions.lib.php b/htdocs/core/lib/functions.lib.php index 1e0e4239763..01c23ce70f6 100644 --- a/htdocs/core/lib/functions.lib.php +++ b/htdocs/core/lib/functions.lib.php @@ -2585,7 +2585,7 @@ function img_warning($titlealt = 'default', $morealt = '') if ($titlealt == 'default') $titlealt = $langs->trans('Warning'); - return img_picto($titlealt, 'warning.png', 'class="pictowarning"'.($morealt ? ($morealt == '1' ? ' style="float: right"' : ' '.$morealt): '')); + return img_picto($titlealt, 'warning.png', 'class="pictowarning valignmiddle"'.($morealt ? ($morealt == '1' ? ' style="float: right"' : ' '.$morealt): '')); } /** diff --git a/htdocs/expensereport/document.php b/htdocs/expensereport/document.php index 9ff90982c3e..0ada24ed89e 100644 --- a/htdocs/expensereport/document.php +++ b/htdocs/expensereport/document.php @@ -93,7 +93,15 @@ if ($object->id) dol_fiche_head($head, 'documents', $langs->trans("ExpenseReport"), 0, 'trip'); - + $linkback = ''.$langs->trans("BackToList").''; + + $morehtmlref='
| '.$langs->trans("Ref").' | '; - print $form->showrefnav($object, 'ref', $linkback, 1, 'ref', 'ref', ''); - print ' | ||
| ".$langs->trans("Company")." | ".$object->client->getNomUrl(1)." | ||
| '.$langs->trans("NbOfAttachedFiles").' | '.count($filearray).' | ||
| '.$langs->trans("NbOfAttachedFiles").' | '.count($filearray).' | ||
| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.$totalsize.' '.$langs->trans("bytes").' | ||
| ';
+ $linkback = ''.$langs->trans("BackToList").'';
+
+ $morehtmlref=' ';
+ $morehtmlref.=' ';
+
+
+ dol_banner_tab($object, 'ref', $linkback, 1, 'ref', 'ref', $morehtmlref);
+
+ print '';
+ print '';
+
+ print ' ';
+
+ dol_fiche_end();
}
llxFooter();
diff --git a/htdocs/expensereport/note.php b/htdocs/expensereport/note.php
new file mode 100644
index 00000000000..71ba4eb32dd
--- /dev/null
+++ b/htdocs/expensereport/note.php
@@ -0,0 +1,119 @@
+
+ * Copyright (C) 2004-2007 Laurent Destailleur '; + + print '
';
+ $morehtmlref.=' ';
+
+
+ dol_banner_tab($object, 'ref', $linkback, 1, 'ref', 'ref', $morehtmlref);
+
+
+ /*
+ print '
'; + */ + + print ' ';
+ print '';
+
+ $cssclass="titlefield";
+ include DOL_DOCUMENT_ROOT.'/core/tpl/notes.tpl.php';
+
+ print ' ';
+
+ dol_fiche_end();
+
+}
+
+
+llxFooter();
+$db->close();
| |||||