Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop

This commit is contained in:
Laurent Destailleur 2016-05-07 17:12:43 +02:00
commit 5bee176ff8
6 changed files with 18 additions and 9 deletions

View File

@ -456,8 +456,8 @@ class FormAdvTargetEmailing extends Form
* selectAdvtargetemailingTemplate
*
* @param string $htmlname control name
* @param number $selected defaut selected
* @param number $showempty empty lines
* @param integer $selected defaut selected
* @param integer $showempty empty lines
*
* @return string HTML combo
*/

View File

@ -273,7 +273,7 @@ if (! empty($conf->contrat->enabled) && $user->rights->contrat->lire)
}
else
{
print '<tr colspan="3" '.$bc[$var].'><td>'.$langs->trans("NoContracts").'</td></tr>';
print '<tr '.$bc[$var].'><td colspan="3">'.$langs->trans("NoContracts").'</td></tr>';
}
print "</table><br>";
$db->free($resql);

View File

@ -5250,7 +5250,7 @@ class Form
*
* @param CommonObject $object Object we want to show links to
* @param array $restrictlinksto Restrict links to some elements, for exemple array('order') or array('supplier_order')
* @return int <0 if KO, >0 if OK
* @return string <0 if KO, >0 if OK
*/
function showLinkToObjectBlock($object, $restrictlinksto=array())
{
@ -5468,7 +5468,7 @@ class Form
* @param int $option 0 return yes/no, 1 return 1/0
* @param bool $disabled true or false
* @param int $useempty 1=Add empty line
* @return mixed See option
* @return string See option
*/
function selectyesno($htmlname,$value='',$option=0,$disabled=false,$useempty='')
{
@ -5810,7 +5810,7 @@ class Form
* @param string $include Array list of groups id to include
* @param int $enableonly Array list of groups id to be enabled. All other must be disabled
* @param int $force_entity 0 or Id of environment to force
* @return void
* @return string
* @see select_dolusers
*/
function select_dolgroups($selected='', $htmlname='groupid', $show_empty=0, $exclude='', $disabled=0, $include='', $enableonly='', $force_entity=0)

View File

@ -325,3 +325,6 @@ ProductVolume=Volume for 1 product
WeightUnits=Weight unit
VolumeUnits=Volume unit
SizeUnits=Size unit
DeleteProductBuyPrice=Delete buying price
ConfirmDeleteProductBuyPrice=Are you sure you want to delete this buying price?

View File

@ -115,7 +115,7 @@ if (empty($reshook))
}
}
if ($action == 'remove_pf')
if ($action == 'confirm_remove_pf')
{
if ($rowid) // id of product supplier price to remove
{
@ -285,6 +285,12 @@ if ($id > 0 || $ref)
if ($result)
{
if ($action == 'ask_remove_pf') {
$form = new Form($db);
$formconfirm = $form->formconfirm($_SERVER["PHP_SELF"] . '?id=' . $id . '&rowid=' . $rowid, $langs->trans('DeleteProductBuyPrice'), $langs->trans('ConfirmDeleteProductBuyPrice'), 'confirm_remove_pf', '', 0, 1);
echo $formconfirm;
}
if ($action <> 'edit' && $action <> 're-edit')
{
$head=product_prepare_head($object);
@ -680,7 +686,7 @@ if ($id > 0 || $ref)
if ($user->rights->produit->creer || $user->rights->service->creer)
{
print '<a href="'.$_SERVER['PHP_SELF'].'?id='.$object->id.'&amp;socid='.$productfourn->fourn_id.'&amp;action=add_price&amp;rowid='.$productfourn->product_fourn_price_id.'">'.img_edit()."</a>";
print '<a href="'.$_SERVER['PHP_SELF'].'?id='.$object->id.'&amp;socid='.$productfourn->fourn_id.'&amp;action=remove_pf&amp;rowid='.$productfourn->product_fourn_price_id.'">'.img_picto($langs->trans("Remove"),'disable.png').'</a>';
print '<a href="'.$_SERVER['PHP_SELF'].'?id='.$object->id.'&amp;socid='.$productfourn->fourn_id.'&amp;action=ask_remove_pf&amp;rowid='.$productfourn->product_fourn_price_id.'">'.img_picto($langs->trans("Remove"),'disable.png').'</a>';
}
print '</td>';

View File

@ -370,7 +370,7 @@ class ThirdpartyApi extends DolibarrApi
* Delete thirdparty
*
* @param int $id Thirparty ID
* @return type
* @return integer
*
* @url DELETE thirdparty/{id}
* @url DELETE customer/{id}