Fix: function must return a string
This commit is contained in:
parent
89ebb3c0ef
commit
8f3e9b1832
@ -103,7 +103,6 @@ print "</tr>\n";
|
|||||||
$var=!$var;
|
$var=!$var;
|
||||||
print '<tr '.$bc[$var].'><td width=\"50%\">'.$langs->trans("CashDeskThirdPartyForSell").'</td>';
|
print '<tr '.$bc[$var].'><td width=\"50%\">'.$langs->trans("CashDeskThirdPartyForSell").'</td>';
|
||||||
print '<td colspan="2">';
|
print '<td colspan="2">';
|
||||||
//print $form->select_company($conf->global->CASHDESK_ID_THIRDPARTY,'socid','s.client in (1,3)',1,1);
|
|
||||||
print $form->select_thirdparty($conf->global->CASHDESK_ID_THIRDPARTY,'socid','s.client in (1,3)',0,array(),1);
|
print $form->select_thirdparty($conf->global->CASHDESK_ID_THIRDPARTY,'socid','s.client in (1,3)',0,array(),1);
|
||||||
print '</td></tr>';
|
print '</td></tr>';
|
||||||
if (! empty($conf->banque->enabled))
|
if (! empty($conf->banque->enabled))
|
||||||
|
|||||||
@ -667,7 +667,7 @@ class Form
|
|||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Return list of company for customer in Ajax if Ajax activated or go to select_thirparty_list
|
* Return HTML code to select a company.
|
||||||
*
|
*
|
||||||
* @param int $selected Preselected products
|
* @param int $selected Preselected products
|
||||||
* @param string $htmlname Name of HTML seletc field (must be unique in page)
|
* @param string $htmlname Name of HTML seletc field (must be unique in page)
|
||||||
@ -675,12 +675,14 @@ class Form
|
|||||||
* @param int $limit Limit on number of returned lines
|
* @param int $limit Limit on number of returned lines
|
||||||
* @param array $ajaxoptions Options for ajax_autocompleter
|
* @param array $ajaxoptions Options for ajax_autocompleter
|
||||||
* @param int $forcecombo Force to use combo box
|
* @param int $forcecombo Force to use combo box
|
||||||
* @return void
|
* @return string Return select box for thirdparty.
|
||||||
*/
|
*/
|
||||||
function select_thirdparty($selected='', $htmlname='productid', $filter='', $limit=20, $ajaxoptions=array(), $forcecombo=0)
|
function select_thirdparty($selected='', $htmlname='productid', $filter='', $limit=20, $ajaxoptions=array(), $forcecombo=0)
|
||||||
{
|
{
|
||||||
global $langs,$conf;
|
global $langs,$conf;
|
||||||
|
|
||||||
|
$out='';
|
||||||
|
|
||||||
/* TODO Use ajax autocompletion (not finished)
|
/* TODO Use ajax autocompletion (not finished)
|
||||||
if (! empty($conf->use_javascript_ajax) && ! empty($conf->global->COMPANY_USE_SEARCH_TO_SELECT) && ! $forcecombo)
|
if (! empty($conf->use_javascript_ajax) && ! empty($conf->global->COMPANY_USE_SEARCH_TO_SELECT) && ! $forcecombo)
|
||||||
{
|
{
|
||||||
@ -711,8 +713,10 @@ class Form
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{*/
|
{*/
|
||||||
print $this->select_thirdparty_list($selected,$htmlname,$filter,1,0,$forcecombo,array(),'',0,$limit);
|
$out.=$this->select_thirdparty_list($selected,$htmlname,$filter,1,0,$forcecombo,array(),'',0,$limit);
|
||||||
//}
|
//}
|
||||||
|
|
||||||
|
return $out;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user