Fix: missing parameters

This commit is contained in:
Regis Houssin 2012-07-08 12:24:13 +02:00
parent 3ca844b3df
commit 680fd32d23
2 changed files with 14 additions and 12 deletions

View File

@ -1640,6 +1640,8 @@ abstract class CommonObject
$justsource=false; $justsource=false;
$justtarget=false; $justtarget=false;
$withtargettype=false;
$withsourcetype=false;
if (! empty($sourceid) && ! empty($sourcetype) && empty($targetid)) if (! empty($sourceid) && ! empty($sourcetype) && empty($targetid))
{ {
@ -1649,7 +1651,7 @@ abstract class CommonObject
if (! empty($targetid) && ! empty($targettype) && empty($sourceid)) if (! empty($targetid) && ! empty($targettype) && empty($sourceid))
{ {
$justtarget=true; $justtarget=true;
if (! empty($sourcetype)) $withsourcetype; if (! empty($sourcetype)) $withsourcetype=true;
} }
$sourceid = (! empty($sourceid) ? $sourceid : $this->id); $sourceid = (! empty($sourceid) ? $sourceid : $this->id);

View File

@ -450,17 +450,17 @@ class FormOther
} }
} }
/** /**
* Output a HTML code to select a color * Output a HTML code to select a color
* *
* @param string $set_color Pre-selected color * @param string $set_color Pre-selected color
* @param string $prefix Name of HTML field * @param string $prefix Name of HTML field
* @param string $form_name Name of form * @param string $form_name Name of form
* @param int $showcolorbox 1=Show color code and color box, 0=Show only color code * @param int $showcolorbox 1=Show color code and color box, 0=Show only color code
* @param array $arrayofcolors Array of colors. Example: array('29527A','5229A3','A32929','7A367A','B1365F','0D7813') * @param array $arrayofcolors Array of colors. Example: array('29527A','5229A3','A32929','7A367A','B1365F','0D7813')
* @return void * @return void
*/ */
function select_color($set_color='', $prefix='f_color', $form_name='objForm', $showcolorbox=1, $arrayofcolors='') function select_color($set_color='', $prefix='f_color', $form_name='objForm', $showcolorbox=1, $arrayofcolors='')
{ {
print $this->selectColor($set_color, $prefix, $form_name, $showcolorbox, $arrayofcolors); print $this->selectColor($set_color, $prefix, $form_name, $showcolorbox, $arrayofcolors);
} }