Fixing style errors.

This commit is contained in:
stickler-ci 2023-04-19 16:22:47 +00:00
parent fde16f42c9
commit a5c4ec5dcf
3 changed files with 6 additions and 6 deletions

View File

@ -171,10 +171,10 @@ if (empty($reshook)) {
$efficiency = price2num(GETPOST('efficiency', 'alpha'));
$fk_unit = GETPOST('fk_unit', 'alphanohtml');
if(!empty($idprod)){
if (!empty($idprod)) {
$product = new Product($db);
$res = $product->fetch($idprod);
if($res > 0 && $product->type == Product::TYPE_SERVICE) $fk_default_workstation = $product->fk_default_workstation;
if ($res > 0 && $product->type == Product::TYPE_SERVICE) $fk_default_workstation = $product->fk_default_workstation;
}
if ($qty == '') {

View File

@ -741,7 +741,7 @@ class Mo extends CommonObject
$moline->position = $line->position;
$moline->qty_frozen = $line->qty_frozen;
$moline->disable_stock_change = $line->disable_stock_change;
if(!empty($line->fk_default_workstation)) $moline->fk_default_workstation = $line->fk_default_workstation;
if (!empty($line->fk_default_workstation)) $moline->fk_default_workstation = $line->fk_default_workstation;
$resultline = $moline->create($user, false); // Never use triggers here
if ($resultline <= 0) {
@ -1721,7 +1721,7 @@ class MoLine extends CommonObjectLine
'fk_user_creat' =>array('type'=>'integer', 'label'=>'UserCreation', 'enabled'=>1, 'visible'=>-1, 'notnull'=>1, 'position'=>170),
'fk_user_modif' =>array('type'=>'integer', 'label'=>'UserModification', 'enabled'=>1, 'visible'=>-1, 'position'=>175),
'import_key' =>array('type'=>'varchar(14)', 'label'=>'ImportId', 'enabled'=>1, 'visible'=>-1, 'position'=>180),
'fk_default_workstation' =>array('type'=>'integer', 'label'=>'DefaultWorkstation', 'enabled'=>1, 'visible'=>1, 'notnull'=>0, 'position'=>185)
'fk_default_workstation' =>array('type'=>'integer', 'label'=>'DefaultWorkstation', 'enabled'=>1, 'visible'=>1, 'notnull'=>0, 'position'=>185)
);
public $rowid;

View File

@ -169,10 +169,10 @@ if (empty($reshook)) {
$moline->origin_type = 'free'; // free consume line
$moline->position = 0;
if(!empty($moline->fk_product)){
if (!empty($moline->fk_product)) {
$product = new Product($db);
$product->fetch($moline->fk_product);
if($product->type == Product::TYPE_SERVICE) $moline->fk_default_workstation = $product->fk_default_workstation;
if ($product->type == Product::TYPE_SERVICE) $moline->fk_default_workstation = $product->fk_default_workstation;
}
$resultline = $moline->create($user, false); // Never use triggers here