Add more info to help debug
This commit is contained in:
parent
fde9a6667f
commit
fa5d96d562
@ -108,6 +108,11 @@ class AccountingAccount extends CommonObject
|
|||||||
*/
|
*/
|
||||||
public $account_category;
|
public $account_category;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @var int Label category account
|
||||||
|
*/
|
||||||
|
public $account_category_label;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var int Status
|
* @var int Status
|
||||||
*/
|
*/
|
||||||
@ -193,7 +198,8 @@ class AccountingAccount extends CommonObject
|
|||||||
$sql .= " AND a.fk_pcg_version = '".$this->db->escape($limittoachartaccount)."'";
|
$sql .= " AND a.fk_pcg_version = '".$this->db->escape($limittoachartaccount)."'";
|
||||||
}
|
}
|
||||||
|
|
||||||
dol_syslog(get_class($this)."::fetch", LOG_DEBUG);
|
dol_syslog(get_class($this)."::fetch id=".$id." account_number=".$account_number, LOG_DEBUG);
|
||||||
|
|
||||||
$result = $this->db->query($sql);
|
$result = $this->db->query($sql);
|
||||||
if ($result) {
|
if ($result) {
|
||||||
$obj = $this->db->fetch_object($result);
|
$obj = $this->db->fetch_object($result);
|
||||||
|
|||||||
@ -1834,6 +1834,7 @@ if ($id) {
|
|||||||
$class = '';
|
$class = '';
|
||||||
$showfield = 1;
|
$showfield = 1;
|
||||||
$valuetoshow = empty($obj->{$value}) ? '' : $obj->{$value};
|
$valuetoshow = empty($obj->{$value}) ? '' : $obj->{$value};
|
||||||
|
$titletoshow = '';
|
||||||
|
|
||||||
if ($value == 'entity') {
|
if ($value == 'entity') {
|
||||||
$withentity = $valuetoshow;
|
$withentity = $valuetoshow;
|
||||||
@ -1965,6 +1966,11 @@ if ($id) {
|
|||||||
} elseif (in_array($value, array('recuperableonly'))) {
|
} elseif (in_array($value, array('recuperableonly'))) {
|
||||||
$class = "center";
|
$class = "center";
|
||||||
} elseif ($value == 'accountancy_code' || $value == 'accountancy_code_sell' || $value == 'accountancy_code_buy') {
|
} elseif ($value == 'accountancy_code' || $value == 'accountancy_code_sell' || $value == 'accountancy_code_buy') {
|
||||||
|
if (!empty($conf->accounting->enabled)) {
|
||||||
|
$tmpaccountingaccount = new AccountingAccount($db);
|
||||||
|
$tmpaccountingaccount->fetch(0, $valuetoshow, 1);
|
||||||
|
$titletoshow = $langs->transnoentitiesnoconv("Pcgtype").': '.$tmpaccountingaccount->pcg_type;
|
||||||
|
}
|
||||||
$valuetoshow = length_accountg($valuetoshow);
|
$valuetoshow = length_accountg($valuetoshow);
|
||||||
} elseif ($value == 'fk_tva') {
|
} elseif ($value == 'fk_tva') {
|
||||||
foreach ($form->cache_vatrates as $key => $Tab) {
|
foreach ($form->cache_vatrates as $key => $Tab) {
|
||||||
@ -2012,7 +2018,7 @@ if ($id) {
|
|||||||
}
|
}
|
||||||
// Show value for field
|
// Show value for field
|
||||||
if ($showfield) {
|
if ($showfield) {
|
||||||
print '<!-- '. $value .' --><td class="'.$class.'">'.$valuetoshow.'</td>';
|
print '<!-- '. $value .' --><td class="'.$class.'"'.($titletoshow ? ' title="'.dol_escape_htmltag($titletoshow).'"' : '').'>'.$valuetoshow.'</td>';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user