28if (empty($object) || !is_object($object)) {
29 print
"Error, template page can't be called as URL";
33if (!is_object($form)) {
34 $form =
new Form($db);
39<!-- BEGIN PHP TEMPLATE accountancy_code_view.tpl.php -->
42if (!is_array($parameters)) {
43 $parameters = array();
45$parameters[
'assetaccountancycodes'] = &$assetaccountancycodes;
46$reshook = $hookmanager->executeHooks(
'formAssetAccountancyCodes', $parameters, $object, $action);
47print $hookmanager->resPrint;
53 if (isModEnabled(
'accounting')) require_once DOL_DOCUMENT_ROOT .
'/accountancy/class/accountingaccount.class.php';
55 foreach ($assetaccountancycodes->accountancy_codes_fields as $mode_key => $mode_info) {
59 print
'<div class="fichecenter">';
60 print
'<div class="underbanner clearboth"></div>';
61 print
'<table class="border centpercent tableforfield">';
62 foreach ($mode_info[
'fields'] as $field_key => $field_info) {
63 print
'<tr><td class="titlefieldcreate">' . $langs->trans($field_info[
'label']) .
'</td><td colspan="3">';
64 if (!empty($assetaccountancycodes->accountancy_codes[$mode_key][$field_key])) {
65 $accountancy_code = $assetaccountancycodes->accountancy_codes[$mode_key][$field_key];
66 if (isModEnabled(
'accounting')) {
68 $accountingaccount->fetch(
'', $accountancy_code, 1);
70 print $accountingaccount->getNomUrl(0, 1, 1,
'', 1);
72 print $accountancy_code;
82<!-- END PHP TEMPLATE accountancy_code_view.tpl.php -->
Class to manage accounting accounts.
load_fiche_titre($titre, $morehtmlright='', $picto='generic', $pictoisfullpath=0, $id='', $morecssontable='', $morehtmlcenter='')
Load a title with picto.
setEventMessages($mesg, $mesgs, $style='mesgs', $messagekey='', $noduplicate=0)
Set event messages in dol_events session object.