Clean code
This commit is contained in:
parent
a4d9e3b9d3
commit
d7c59edd11
@ -1399,8 +1399,8 @@ if ($resql)
|
|||||||
{
|
{
|
||||||
print '<td class="tdoverflowmax150">';
|
print '<td class="tdoverflowmax150">';
|
||||||
|
|
||||||
$companylinked = 0;
|
$companylinked_id = 0;
|
||||||
$userlinked = 0;
|
$userlinked_id = 0;
|
||||||
|
|
||||||
//payment line type to define user display
|
//payment line type to define user display
|
||||||
foreach($links as $key=>$value){
|
foreach($links as $key=>$value){
|
||||||
@ -1408,20 +1408,20 @@ if ($resql)
|
|||||||
if($links[$key]['type'] == 'payment_salary') $type_link = 'payment_salary';
|
if($links[$key]['type'] == 'payment_salary') $type_link = 'payment_salary';
|
||||||
|
|
||||||
if($links[$key]['type'] == 'company') {
|
if($links[$key]['type'] == 'company') {
|
||||||
$companylinked = $links[$key]['url_id'];
|
$companylinked_id = $links[$key]['url_id'];
|
||||||
}
|
}
|
||||||
if($links[$key]['type'] == 'user') {
|
if($links[$key]['type'] == 'user') {
|
||||||
$userlinked = $links[$key]['url_id'];
|
$userlinked_id = $links[$key]['url_id'];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if($companylinked) {
|
if($companylinked_id) {
|
||||||
$companystatic->fetch($companylinked);
|
$companystatic->fetch($companylinked_id);
|
||||||
print $companystatic->getNomUrl(1);
|
print $companystatic->getNomUrl(1);
|
||||||
} elseif($userlinked &&
|
} elseif($userlinked_id &&
|
||||||
(($type_link == 'payment_salary' && !empty($user->rights->salaries->read))
|
(($type_link == 'payment_salary' && !empty($user->rights->salaries->read))
|
||||||
|| ($type_link == 'payment_sc' && !empty($user->rights->tax->charges->lire)))){
|
|| ($type_link == 'payment_sc' && !empty($user->rights->tax->charges->lire)))){
|
||||||
$userstatic->fetch($userlinked);
|
$userstatic->fetch($userlinked_id);
|
||||||
print $userstatic->getNomUrl(1);
|
print $userstatic->getNomUrl(1);
|
||||||
} else {
|
} else {
|
||||||
print ' ';
|
print ' ';
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user