Creation de la table par fichier
This commit is contained in:
parent
02cb364d8d
commit
b6d23a2953
@ -67,18 +67,22 @@ if ($_POST["action"] == 'multiprix')
|
|||||||
// on crée la table societe_prices
|
// on crée la table societe_prices
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
$table = MAIN_DB_PREFIX."societe_prices";
|
/*
|
||||||
$fields['rowid'] = array('type'=>'int','value'=>'11','null'=>'not null','extra'=> 'auto_increment');
|
* La table est desormais cree par un fichier SQL comme les autres tables
|
||||||
$fields['fk_soc'] = array('type'=>'int','value'=>'11','null'=>'not null','default'=> '0');
|
*
|
||||||
$fields['tms'] = array('type'=>'timestamp','value'=>'14','null'=>'not null');
|
* $table = MAIN_DB_PREFIX."societe_prices";
|
||||||
$fields['datec'] = array('type'=>'datetime','default'=> 'null');
|
* $fields['rowid'] = array('type'=>'int','value'=>'11','null'=>'not null','extra'=> 'auto_increment');
|
||||||
$fields['fk_user_author'] = array('type'=>'int','value'=>'11','default'=> 'null');
|
* $fields['fk_soc'] = array('type'=>'int','value'=>'11','null'=>'not null','default'=> '0');
|
||||||
$fields['price_level'] = array('type'=>'tinyint','value'=>'4','default'=> '1');
|
* $fields['tms'] = array('type'=>'timestamp','value'=>'14','null'=>'not null');
|
||||||
if ($db->DDLCreateTable($table,$fields,"rowid","InnoDB") < 0)
|
* $fields['datec'] = array('type'=>'datetime','default'=> 'null');
|
||||||
{
|
* $fields['fk_user_author'] = array('type'=>'int','value'=>'11','default'=> 'null');
|
||||||
dolibarr_print_error($db);
|
* $fields['price_level'] = array('type'=>'tinyint','value'=>'4','default'=> '1');
|
||||||
exit;
|
* if ($db->DDLCreateTable($table,$fields,"rowid","InnoDB") < 0)
|
||||||
}
|
* {
|
||||||
|
* dolibarr_print_error($db);
|
||||||
|
* exit;
|
||||||
|
* }
|
||||||
|
*/
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
dolibarr_set_const($db, "PRODUIT_MULTIPRICES", $_POST["activate_multiprix"]);
|
dolibarr_set_const($db, "PRODUIT_MULTIPRICES", $_POST["activate_multiprix"]);
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user