Fix save of doc template for recuring invoices.
This commit is contained in:
parent
8090a8abb6
commit
b66ad24d85
@ -1424,7 +1424,7 @@ else
|
||||
$list = array();
|
||||
$models = ModelePDFFactures::liste_modeles($db);
|
||||
foreach ($models as $k => $model) {
|
||||
$list[] = $k . ':' . $model;
|
||||
$list[] = str_replace(':', '|', $k) . ':' . $model;
|
||||
}
|
||||
$select = 'select;'.implode(',', $list);
|
||||
print $form->editfieldval($langs->trans("Model"), 'modelpdf', $object->modelpdf, $object, $user->rights->facture->creer, $select);
|
||||
|
||||
@ -152,7 +152,7 @@ class Form
|
||||
* @param string $value Value to show/edit
|
||||
* @param object $object Object
|
||||
* @param boolean $perm Permission to allow button to edit parameter
|
||||
* @param string $typeofdata Type of data ('string' by default, 'email', 'amount:99', 'numeric:99', 'text' or 'textarea:rows:cols%', 'datepicker' ('day' do not work, don't know why), 'dayhour' or 'datepickerhour', 'ckeditor:dolibarr_zzz:width:height:savemethod:toolbarstartexpanded:rows:cols', 'select:xxx'...)
|
||||
* @param string $typeofdata Type of data ('string' by default, 'email', 'amount:99', 'numeric:99', 'text' or 'textarea:rows:cols%', 'datepicker' ('day' do not work, don't know why), 'dayhour' or 'datepickerhour', 'ckeditor:dolibarr_zzz:width:height:savemethod:toolbarstartexpanded:rows:cols', 'select;xkey:xval,ykey:yval,...')
|
||||
* @param string $editvalue When in edit mode, use this value as $value instead of value (for example, you can provide here a formated price instead of value). Use '' to use same than $value
|
||||
* @param object $extObject External object
|
||||
* @param mixed $custommsg String or Array of custom messages : eg array('success' => 'MyMessage', 'error' => 'MyMessage')
|
||||
@ -172,7 +172,7 @@ class Form
|
||||
if (empty($typeofdata)) return 'ErrorBadParameter';
|
||||
|
||||
// When option to edit inline is activated
|
||||
if (! empty($conf->global->MAIN_USE_JQUERY_JEDITABLE) && ! preg_match('/^select;|datehourpicker/',$typeofdata)) // TODO add jquery timepicker
|
||||
if (! empty($conf->global->MAIN_USE_JQUERY_JEDITABLE) && ! preg_match('/^select;|datehourpicker/',$typeofdata)) // TODO add jquery timepicker and support select
|
||||
{
|
||||
$ret.=$this->editInPlace($object, $value, $htmlname, $perm, $typeofdata, $editvalue, $extObject, $custommsg);
|
||||
}
|
||||
@ -229,7 +229,8 @@ class Form
|
||||
foreach($arraydata as $val)
|
||||
{
|
||||
$tmp=explode(':',$val);
|
||||
$arraylist[$tmp[0]]=$tmp[1];
|
||||
$tmpkey=str_replace('|', ':', $tmp[0]);
|
||||
$arraylist[$tmpkey]=$tmp[1];
|
||||
}
|
||||
$ret.=$this->selectarray($htmlname,$arraylist,$value);
|
||||
}
|
||||
@ -298,7 +299,7 @@ class Form
|
||||
* @param string $value Value to show/edit
|
||||
* @param string $htmlname DIV ID (field name)
|
||||
* @param int $condition Condition to edit
|
||||
* @param string $inputType Type of input ('string', 'numeric', 'datepicker' ('day' do not work, don't know why), 'textarea:rows:cols', 'ckeditor:dolibarr_zzz:width:height:?:1:rows:cols', 'select:xxx')
|
||||
* @param string $inputType Type of input ('string', 'numeric', 'datepicker' ('day' do not work, don't know why), 'textarea:rows:cols', 'ckeditor:dolibarr_zzz:width:height:?:1:rows:cols', 'select:loadmethod:savemethod:buttononly')
|
||||
* @param string $editvalue When in edit mode, use this value as $value instead of value
|
||||
* @param object $extObject External object
|
||||
* @param mixed $custommsg String or Array of custom messages : eg array('success' => 'MyMessage', 'error' => 'MyMessage')
|
||||
|
||||
Loading…
Reference in New Issue
Block a user