mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2025-02-20 13:46:52 +01:00
Debug v14. Fix regression.
This commit is contained in:
parent
ba6e675273
commit
5e0f2f9781
|
|
@ -64,6 +64,10 @@ ALTER TABLE llx_export_model MODIFY COLUMN type varchar(64);
|
|||
|
||||
-- For v14
|
||||
|
||||
ALTER TABLE llx_product_lot ADD COLUMN eol_date datetime NULL;
|
||||
ALTER TABLE llx_product_lot ADD COLUMN manufacturing_date datetime NULL;
|
||||
ALTER TABLE llx_product_lot ADD COLUMN scrapping_date datetime NULL;
|
||||
|
||||
create table llx_accounting_groups_account
|
||||
(
|
||||
rowid integer AUTO_INCREMENT PRIMARY KEY,
|
||||
|
|
|
|||
|
|
@ -24,6 +24,9 @@ CREATE TABLE llx_product_lot (
|
|||
batch varchar(128) DEFAULT NULL, -- Lot or serial number
|
||||
eatby date DEFAULT NULL, -- Eatby date
|
||||
sellby date DEFAULT NULL, -- Sellby date
|
||||
eol_date datetime NULL,
|
||||
manufacturing_date datetime NULL,
|
||||
scrapping_date datetime NULL,
|
||||
datec datetime,
|
||||
tms timestamp DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
fk_user_creat integer,
|
||||
|
|
|
|||
|
|
@ -91,11 +91,11 @@ class Productlot extends CommonObject
|
|||
'batch' => array('type'=>'varchar(30)', 'label'=>'Batch', 'enabled'=>1, 'visible'=>1, 'notnull'=>0, 'showoncombobox'=>1, 'index'=>1, 'position'=>10, 'comment'=>'Batch', 'searchall'=>1),
|
||||
'entity' => array('type'=>'integer', 'label'=>'Entity', 'enabled'=>1, 'visible'=>0, 'default'=>1, 'notnull'=>1, 'index'=>1, 'position'=>20),
|
||||
'sellby' => array('type'=>'date', 'label'=>'SellByDate', 'enabled'=>'empty($conf->global->PRODUCT_DISABLE_SELLBY)?1:0', 'visible'=>5, 'position'=>60),
|
||||
'eol_date' => array('type'=>'date', 'label'=>'EndOfLife', 'enabled'=>'empty($conf->global->PRODUCT_DISABLE_TRACEABILITY)?1:0', 'visible'=>5, 'position'=>70),
|
||||
'manufacturing_date' => array('type'=>'date', 'label'=>'ManufacturingDate', 'enabled'=>'empty($conf->global->PRODUCT_DISABLE_TRACEABILITY)?1:0', 'visible'=>5, 'position'=>80),
|
||||
'scrapping_date' => array('type'=>'date', 'label'=>'DestructionDate', 'enabled'=>'empty($conf->global->PRODUCT_DISABLE_TRACEABILITY)?1:0', 'visible'=>5, 'position'=>90),
|
||||
'commissionning_date' => array('type'=>'date', 'label'=>'FirstUseDate', 'enabled'=>'empty($conf->global->PRODUCT_DISABLE_TRACEABILITY)?1:0', 'visible'=>5, 'position'=>100),
|
||||
'qc_frequency' => array('type'=>'varchar(6)', 'label'=>'QCFrequency', 'enabled'=>'empty($conf->global->PRODUCT_DISABLE_TRACEABILITY)?1:0', 'visible'=>5, 'position'=>110),
|
||||
'eol_date' => array('type'=>'date', 'label'=>'EndOfLife', 'enabled'=>'empty($conf->global->PRODUCT_ENABLE_TRACEABILITY)?0:1', 'visible'=>5, 'position'=>70),
|
||||
'manufacturing_date' => array('type'=>'date', 'label'=>'ManufacturingDate', 'enabled'=>'empty($conf->global->PRODUCT_ENABLE_TRACEABILITY)?0:1', 'visible'=>5, 'position'=>80),
|
||||
'scrapping_date' => array('type'=>'date', 'label'=>'DestructionDate', 'enabled'=>'empty($conf->global->PRODUCT_ENABLE_TRACEABILITY)?0:1', 'visible'=>5, 'position'=>90),
|
||||
//'commissionning_date' => array('type'=>'date', 'label'=>'FirstUseDate', 'enabled'=>'empty($conf->global->PRODUCT_ENABLE_TRACEABILITY)?0:1', 'visible'=>5, 'position'=>100),
|
||||
//'qc_frequency' => array('type'=>'varchar(6)', 'label'=>'QCFrequency', 'enabled'=>'empty($conf->global->PRODUCT_ENABLE_QUALITYCONTROL)?1:0', 'visible'=>5, 'position'=>110),
|
||||
'eatby' => array('type'=>'date', 'label'=>'EatByDate', 'enabled'=>'empty($conf->global->PRODUCT_DISABLE_EATBY)?1:0', 'visible'=>5, 'position'=>62),
|
||||
'datec' => array('type'=>'datetime', 'label'=>'DateCreation', 'enabled'=>1, 'visible'=>1, 'notnull'=>1, 'position'=>500),
|
||||
'tms' => array('type'=>'timestamp', 'label'=>'DateModification', 'enabled'=>1, 'visible'=>-2, 'notnull'=>1, 'position'=>501),
|
||||
|
|
@ -120,8 +120,8 @@ class Productlot extends CommonObject
|
|||
public $eol_date = '';
|
||||
public $manufacturing_date = '';
|
||||
public $scrapping_date = '';
|
||||
public $commissionning_date = '';
|
||||
public $qc_frequency = '';
|
||||
//public $commissionning_date = '';
|
||||
//public $qc_frequency = '';
|
||||
public $datec = '';
|
||||
public $tms = '';
|
||||
|
||||
|
|
@ -184,8 +184,6 @@ class Productlot extends CommonObject
|
|||
$this->import_key = trim($this->import_key);
|
||||
}
|
||||
|
||||
|
||||
|
||||
// Check parameters
|
||||
// Put here code to add control on parameters values
|
||||
|
||||
|
|
@ -199,8 +197,8 @@ class Productlot extends CommonObject
|
|||
$sql .= 'eol_date,';
|
||||
$sql .= 'manufacturing_date,';
|
||||
$sql .= 'scrapping_date,';
|
||||
$sql .= 'commissionning_date,';
|
||||
$sql .= 'qc_frequency,';
|
||||
//$sql .= 'commissionning_date,';
|
||||
//$sql .= 'qc_frequency,';
|
||||
$sql .= 'datec,';
|
||||
$sql .= 'fk_user_creat,';
|
||||
$sql .= 'fk_user_modif,';
|
||||
|
|
@ -214,9 +212,8 @@ class Productlot extends CommonObject
|
|||
$sql .= ' '.(!isset($this->eol_date) || dol_strlen($this->eol_date) == 0 ? 'NULL' : "'".$this->db->idate($this->eol_date)."'").',';
|
||||
$sql .= ' '.(!isset($this->manufacturing_date) || dol_strlen($this->manufacturing_date) == 0 ? 'NULL' : "'".$this->db->idate($this->manufacturing_date)."'").',';
|
||||
$sql .= ' '.(!isset($this->scrapping_date) || dol_strlen($this->scrapping_date) == 0 ? 'NULL' : "'".$this->db->idate($this->scrapping_date)."'").',';
|
||||
$sql .= ' '.(!isset($this->commissionning_date) || dol_strlen($this->commissionning_date) == 0 ? 'NULL' : "'".$this->db->idate($this->commissionning_date)."'").',';
|
||||
$sql .= ' '.(!isset($this->qc_frequency) ? 'NULL' : $this->qc_frequency).',';
|
||||
|
||||
//$sql .= ' '.(!isset($this->commissionning_date) || dol_strlen($this->commissionning_date) == 0 ? 'NULL' : "'".$this->db->idate($this->commissionning_date)."'").',';
|
||||
//$sql .= ' '.(!isset($this->qc_frequency) ? 'NULL' : $this->qc_frequency).',';
|
||||
$sql .= ' '."'".$this->db->idate(dol_now())."'".',';
|
||||
$sql .= ' '.(!isset($this->fk_user_creat) ? 'NULL' : $this->fk_user_creat).',';
|
||||
$sql .= ' '.(!isset($this->fk_user_modif) ? 'NULL' : $this->fk_user_modif).',';
|
||||
|
|
@ -292,8 +289,8 @@ class Productlot extends CommonObject
|
|||
$sql .= " t.eol_date,";
|
||||
$sql .= " t.manufacturing_date,";
|
||||
$sql .= " t.scrapping_date,";
|
||||
$sql .= " t.commissionning_date,";
|
||||
$sql .= " t.qc_frequency,";
|
||||
//$sql .= " t.commissionning_date,";
|
||||
//$sql .= " t.qc_frequency,";
|
||||
$sql .= " t.datec,";
|
||||
$sql .= " t.tms,";
|
||||
$sql .= " t.fk_user_creat,";
|
||||
|
|
@ -322,11 +319,10 @@ class Productlot extends CommonObject
|
|||
$this->eatby = $this->db->jdate($obj->eatby);
|
||||
$this->sellby = $this->db->jdate($obj->sellby);
|
||||
$this->eol_date = $this->db->jdate($obj->eol_date);
|
||||
|
||||
$this->manufacturing_date = $this->db->jdate($obj->manufacturing_date);
|
||||
$this->scrapping_date = $this->db->jdate($obj->scrapping_date);
|
||||
$this->commissionning_date = $this->db->jdate($obj->commissionning_date);
|
||||
$this->qc_frequency = $obj->qc_frequency;
|
||||
//$this->commissionning_date = $this->db->jdate($obj->commissionning_date);
|
||||
//$this->qc_frequency = $obj->qc_frequency;
|
||||
|
||||
$this->datec = $this->db->jdate($obj->datec);
|
||||
$this->tms = $this->db->jdate($obj->tms);
|
||||
|
|
@ -407,8 +403,8 @@ class Productlot extends CommonObject
|
|||
$sql .= ' eol_date = '.(!isset($this->eol_date) || dol_strlen($this->eol_date) != 0 ? "'".$this->db->idate($this->eol_date)."'" : 'null').',';
|
||||
$sql .= ' manufacturing_date = '.(!isset($this->manufacturing_date) || dol_strlen($this->manufacturing_date) != 0 ? "'".$this->db->idate($this->manufacturing_date)."'" : 'null').',';
|
||||
$sql .= ' scrapping_date = '.(!isset($this->destruction_date) || dol_strlen($this->destruction_date) != 0 ? "'".$this->db->idate($this->destruction_date)."'" : 'null').',';
|
||||
$sql .= ' commissionning_date = '.(!isset($this->first_use_date) || dol_strlen($this->first_use_date) != 0 ? "'".$this->db->idate($this->first_use_date)."'" : 'null').',';
|
||||
$sql .= ' qc_frequency = '.(!isset($this->qc_frequency) || dol_strlen($this->qc_frequency) != 0 ? "'".$this->db->escape($this->qc_frequency)."'" : 'null').',';
|
||||
//$sql .= ' commissionning_date = '.(!isset($this->first_use_date) || dol_strlen($this->first_use_date) != 0 ? "'".$this->db->idate($this->first_use_date)."'" : 'null').',';
|
||||
//$sql .= ' qc_frequency = '.(!isset($this->qc_frequency) || dol_strlen($this->qc_frequency) != 0 ? "'".$this->db->escape($this->qc_frequency)."'" : 'null').',';
|
||||
$sql .= ' datec = '.(!isset($this->datec) || dol_strlen($this->datec) != 0 ? "'".$this->db->idate($this->datec)."'" : 'null').',';
|
||||
$sql .= ' tms = '.(dol_strlen($this->tms) != 0 ? "'".$this->db->idate($this->tms)."'" : "'".$this->db->idate(dol_now())."'").',';
|
||||
$sql .= ' fk_user_creat = '.(isset($this->fk_user_creat) ? $this->fk_user_creat : "null").',';
|
||||
|
|
|
|||
|
|
@ -3836,7 +3836,7 @@ tr.liste_titre_sel th, th.liste_titre_sel, tr.liste_titre_sel td, td.liste_titre
|
|||
font-family: <?php print $fontlist ?>;
|
||||
font-weight: normal;
|
||||
border-bottom: 1px solid #FDFFFF;
|
||||
text-decoration: underline;
|
||||
/* text-decoration: underline; */
|
||||
}
|
||||
input.liste_titre {
|
||||
background: transparent;
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user