// Stock Available : Improve BackOffice interface + Update all SQL requests relative to StockAvailable + code refactoring on Product Class
git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@10843 b9a71923-0436-4b27-9f14-aed3839534dd
This commit is contained in:
@@ -139,7 +139,8 @@ class AdminGroupShopControllerCore extends AdminController
|
||||
'label' => $this->l('Disabled')
|
||||
)
|
||||
),
|
||||
'desc' => $this->l('Share available quantities to sale between shops of this group')
|
||||
'desc' => $this->l('Share available quantities to sale between shops of this group'),
|
||||
'h' => $this->l('When changing this option, all product available quantities for the current groupof shop will be reseted to 0.')
|
||||
),
|
||||
array(
|
||||
'type' => 'radio',
|
||||
@@ -252,12 +253,18 @@ class AdminGroupShopControllerCore extends AdminController
|
||||
{
|
||||
if (Tools::getValue('useImportData') && ($import_data = Tools::getValue('importData')) && is_array($import_data))
|
||||
$new_group_shop->copyGroupShopData(Tools::getValue('importFromShop'), $import_data);
|
||||
|
||||
//Reset available quantitites
|
||||
StockAvailable::resetProductFromStockAvailableByGroupShop($new_group_shop);
|
||||
}
|
||||
|
||||
public function afterUpdate($new_group_shop)
|
||||
{
|
||||
if (Tools::getValue('useImportData') && ($import_data = Tools::getValue('importData')) && is_array($import_data))
|
||||
$new_group_shop->copyGroupShopData(Tools::getValue('importFromShop'), $import_data);
|
||||
|
||||
//Reset available quantitites
|
||||
StockAvailable::resetProductFromStockAvailableByGroupShop($new_group_shop);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user