Rename table for a better understanding
This commit is contained in:
parent
145f70a341
commit
8fa8bc7d34
@ -97,7 +97,7 @@ ALTER TABLE llx_product_lot_extrafields ADD INDEX idx_product_lot_extrafields (f
|
|||||||
|
|
||||||
ALTER TABLE llx_website_page MODIFY content MEDIUMTEXT;
|
ALTER TABLE llx_website_page MODIFY content MEDIUMTEXT;
|
||||||
|
|
||||||
create table llx_product_stock_entrepot
|
create table llx_product_warehouse_properties
|
||||||
(
|
(
|
||||||
rowid integer AUTO_INCREMENT PRIMARY KEY,
|
rowid integer AUTO_INCREMENT PRIMARY KEY,
|
||||||
tms timestamp,
|
tms timestamp,
|
||||||
|
|||||||
@ -18,7 +18,7 @@
|
|||||||
--
|
--
|
||||||
-- ============================================================================
|
-- ============================================================================
|
||||||
|
|
||||||
create table llx_product_stock_entrepot
|
create table llx_product_warehouse_properties
|
||||||
(
|
(
|
||||||
rowid integer AUTO_INCREMENT PRIMARY KEY,
|
rowid integer AUTO_INCREMENT PRIMARY KEY,
|
||||||
tms timestamp,
|
tms timestamp,
|
||||||
|
|||||||
@ -926,7 +926,7 @@ class Product extends CommonObject
|
|||||||
// Delete all child tables
|
// Delete all child tables
|
||||||
if (! $error)
|
if (! $error)
|
||||||
{
|
{
|
||||||
$elements = array('product_fournisseur_price','product_price','product_lang','categorie_product','product_stock','product_customer_price','product_lot','product_stock_entrepot');
|
$elements = array('product_fournisseur_price','product_price','product_lang','categorie_product','product_stock','product_customer_price','product_lot','product_warehouse_properties');
|
||||||
foreach($elements as $table)
|
foreach($elements as $table)
|
||||||
{
|
{
|
||||||
if (! $error)
|
if (! $error)
|
||||||
|
|||||||
@ -221,7 +221,7 @@ class Entrepot extends CommonObject
|
|||||||
{
|
{
|
||||||
$this->db->begin();
|
$this->db->begin();
|
||||||
|
|
||||||
$elements = array('stock_mouvement','product_stock','product_stock_entrepot');
|
$elements = array('stock_mouvement','product_stock','product_warehouse_properties');
|
||||||
foreach($elements as $table)
|
foreach($elements as $table)
|
||||||
{
|
{
|
||||||
if (! $error)
|
if (! $error)
|
||||||
|
|||||||
@ -47,7 +47,7 @@ class ProductStockEntrepot extends CommonObject
|
|||||||
/**
|
/**
|
||||||
* @var string Name of table without prefix where object is stored
|
* @var string Name of table without prefix where object is stored
|
||||||
*/
|
*/
|
||||||
public $table_element = 'product_stock_entrepot';
|
public $table_element = 'product_warehouse_properties';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*/
|
*/
|
||||||
|
|||||||
@ -270,7 +270,7 @@ $sql.= ' FROM ' . MAIN_DB_PREFIX . 'product as p';
|
|||||||
$sql.= ' LEFT JOIN ' . MAIN_DB_PREFIX . 'product_stock as s';
|
$sql.= ' LEFT JOIN ' . MAIN_DB_PREFIX . 'product_stock as s';
|
||||||
$sql.= ' ON p.rowid = s.fk_product';
|
$sql.= ' ON p.rowid = s.fk_product';
|
||||||
if(!empty($conf->global->STOCK_ALLOW_ADD_LIMIT_STOCK_BY_WAREHOUSE) && $fk_entrepot > 0) {
|
if(!empty($conf->global->STOCK_ALLOW_ADD_LIMIT_STOCK_BY_WAREHOUSE) && $fk_entrepot > 0) {
|
||||||
$sql.= ' LEFT JOIN '.MAIN_DB_PREFIX.'product_stock_entrepot pse ON (p.rowid = pse.fk_product AND pse.fk_entrepot = '.$fk_entrepot.')';
|
$sql.= ' LEFT JOIN '.MAIN_DB_PREFIX.'product_warehouse_properties pse ON (p.rowid = pse.fk_product AND pse.fk_entrepot = '.$fk_entrepot.')';
|
||||||
}
|
}
|
||||||
$sql.= ' WHERE p.entity IN (' . getEntity("product", 1) . ')';
|
$sql.= ' WHERE p.entity IN (' . getEntity("product", 1) . ')';
|
||||||
if ($sall) {
|
if ($sall) {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user