Show extrafield separator on invoice
This commit is contained in:
parent
ba0963ea7d
commit
f1a05528ad
@ -2101,6 +2101,13 @@ if ($action == 'create')
|
|||||||
foreach($extrafields->attribute_label as $key=>$label)
|
foreach($extrafields->attribute_label as $key=>$label)
|
||||||
{
|
{
|
||||||
$value=(isset($_POST["options_".$key])?$_POST["options_".$key]:$object->array_options["options_".$key]);
|
$value=(isset($_POST["options_".$key])?$_POST["options_".$key]:$object->array_options["options_".$key]);
|
||||||
|
// Show separator only
|
||||||
|
if ($extrafields->attribute_type[$key] == 'separate')
|
||||||
|
{
|
||||||
|
print $extrafields->showSeparator($key);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
print '<tr><td';
|
print '<tr><td';
|
||||||
if (! empty($extrafields->attribute_required[$key])) print ' class="fieldrequired"';
|
if (! empty($extrafields->attribute_required[$key])) print ' class="fieldrequired"';
|
||||||
print '>'.$label.'</td><td colspan="3">';
|
print '>'.$label.'</td><td colspan="3">';
|
||||||
@ -2108,6 +2115,7 @@ if ($action == 'create')
|
|||||||
print '</td></tr>'."\n";
|
print '</td></tr>'."\n";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Modele PDF
|
// Modele PDF
|
||||||
print '<tr><td>'.$langs->trans('Model').'</td>';
|
print '<tr><td>'.$langs->trans('Model').'</td>';
|
||||||
@ -3090,6 +3098,12 @@ else if ($id > 0 || ! empty($ref))
|
|||||||
foreach($extrafields->attribute_label as $key=>$label)
|
foreach($extrafields->attribute_label as $key=>$label)
|
||||||
{
|
{
|
||||||
$value=(isset($_POST["options_".$key])?$_POST["options_".$key]:$object->array_options["options_".$key]);
|
$value=(isset($_POST["options_".$key])?$_POST["options_".$key]:$object->array_options["options_".$key]);
|
||||||
|
if ($extrafields->attribute_type[$key] == 'separate')
|
||||||
|
{
|
||||||
|
print $extrafields->showSeparator($key);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
print '<tr><td';
|
print '<tr><td';
|
||||||
if (! empty($extrafields->attribute_required[$key])) print ' class="fieldrequired"';
|
if (! empty($extrafields->attribute_required[$key])) print ' class="fieldrequired"';
|
||||||
print '>'.$label.'</td><td colspan="5">';
|
print '>'.$label.'</td><td colspan="5">';
|
||||||
@ -3101,9 +3115,9 @@ else if ($id > 0 || ! empty($ref))
|
|||||||
{
|
{
|
||||||
print $extrafields->showOutputField($key,$value);
|
print $extrafields->showOutputField($key,$value);
|
||||||
}
|
}
|
||||||
|
|
||||||
print '</td></tr>'."\n";
|
print '</td></tr>'."\n";
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if(count($extrafields->attribute_label) > 0) {
|
if(count($extrafields->attribute_label) > 0) {
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user