Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop
This commit is contained in:
commit
9ec23c7073
@ -1286,7 +1286,7 @@ if (is_object($objcanvas) && $objcanvas->displayCanvasExists($action)) {
|
||||
print '</td></tr>';
|
||||
|
||||
// EMail
|
||||
print '<tr><td>'.($conf->global->ADHERENT_MAIL_REQUIRED ? '<span class="fieldrequired">' : '').$langs->trans("EMail").($conf->global->ADHERENT_MAIL_REQUIRED ? '</span>' : '').'</td>';
|
||||
print '<tr><td>'.(getDolGlobalString("ADHERENT_MAIL_REQUIRED") ? '<span class="fieldrequired">' : '').$langs->trans("EMail").(getDolGlobalString("ADHERENT_MAIL_REQUIRED") ? '</span>' : '').'</td>';
|
||||
print '<td>'.img_picto('', 'object_email', 'class="pictofixedwidth"').'<input type="text" name="member_email" class="minwidth300" maxlength="255" value="'.(GETPOSTISSET("member_email") ? GETPOST("member_email", '', 2) : $object->email).'"></td></tr>';
|
||||
|
||||
// Website
|
||||
|
||||
@ -519,7 +519,9 @@ class Proposals extends DolibarrApi
|
||||
isset($request_data->date_end) ? $request_data->date_end : $propalline->date_end,
|
||||
isset($request_data->array_options) ? $request_data->array_options : $propalline->array_options,
|
||||
isset($request_data->fk_unit) ? $request_data->fk_unit : $propalline->fk_unit,
|
||||
isset($request_data->multicurrency_subprice) ? $request_data->multicurrency_subprice : $propalline->subprice
|
||||
isset($request_data->multicurrency_subprice) ? $request_data->multicurrency_subprice : $propalline->subprice,
|
||||
0,
|
||||
isset($request_data->rang) ? $request_data->rang : $propalline->rang
|
||||
);
|
||||
|
||||
if ($updateRes > 0) {
|
||||
|
||||
@ -806,9 +806,10 @@ class Propal extends CommonObject
|
||||
* @param string $fk_unit Code of the unit to use. Null to use the default one
|
||||
* @param double $pu_ht_devise Unit price in currency
|
||||
* @param int $notrigger disable line update trigger
|
||||
* @param integer $rang line rank
|
||||
* @return int 0 if OK, <0 if KO
|
||||
*/
|
||||
public function updateline($rowid, $pu, $qty, $remise_percent, $txtva, $txlocaltax1 = 0.0, $txlocaltax2 = 0.0, $desc = '', $price_base_type = 'HT', $info_bits = 0, $special_code = 0, $fk_parent_line = 0, $skip_update_total = 0, $fk_fournprice = 0, $pa_ht = 0, $label = '', $type = 0, $date_start = '', $date_end = '', $array_options = 0, $fk_unit = null, $pu_ht_devise = 0, $notrigger = 0)
|
||||
public function updateline($rowid, $pu, $qty, $remise_percent, $txtva, $txlocaltax1 = 0.0, $txlocaltax2 = 0.0, $desc = '', $price_base_type = 'HT', $info_bits = 0, $special_code = 0, $fk_parent_line = 0, $skip_update_total = 0, $fk_fournprice = 0, $pa_ht = 0, $label = '', $type = 0, $date_start = '', $date_end = '', $array_options = 0, $fk_unit = null, $pu_ht_devise = 0, $notrigger = 0, $rang = 0)
|
||||
{
|
||||
global $mysoc, $langs;
|
||||
|
||||
@ -894,6 +895,7 @@ class Propal extends CommonObject
|
||||
$line->oldline = $staticline;
|
||||
$this->line = $line;
|
||||
$this->line->context = $this->context;
|
||||
$this->line->rang = $rang;
|
||||
|
||||
// Reorder if fk_parent_line change
|
||||
if (!empty($fk_parent_line) && !empty($staticline->fk_parent_line) && $fk_parent_line != $staticline->fk_parent_line) {
|
||||
|
||||
@ -439,7 +439,8 @@ class Orders extends DolibarrApi
|
||||
$request_data->fk_unit,
|
||||
$request_data->multicurrency_subprice,
|
||||
0,
|
||||
$request_data->ref_ext
|
||||
$request_data->ref_ext,
|
||||
$request_data->rang
|
||||
);
|
||||
|
||||
if ($updateRes > 0) {
|
||||
|
||||
@ -3087,9 +3087,10 @@ class Commande extends CommonOrder
|
||||
* @param double $pu_ht_devise Amount in currency
|
||||
* @param int $notrigger disable line update trigger
|
||||
* @param string $ref_ext external reference
|
||||
* @param integer $rang line rank
|
||||
* @return int < 0 if KO, > 0 if OK
|
||||
*/
|
||||
public function updateline($rowid, $desc, $pu, $qty, $remise_percent, $txtva, $txlocaltax1 = 0.0, $txlocaltax2 = 0.0, $price_base_type = 'HT', $info_bits = 0, $date_start = '', $date_end = '', $type = 0, $fk_parent_line = 0, $skip_update_total = 0, $fk_fournprice = null, $pa_ht = 0, $label = '', $special_code = 0, $array_options = 0, $fk_unit = null, $pu_ht_devise = 0, $notrigger = 0, $ref_ext = '')
|
||||
public function updateline($rowid, $desc, $pu, $qty, $remise_percent, $txtva, $txlocaltax1 = 0.0, $txlocaltax2 = 0.0, $price_base_type = 'HT', $info_bits = 0, $date_start = '', $date_end = '', $type = 0, $fk_parent_line = 0, $skip_update_total = 0, $fk_fournprice = null, $pa_ht = 0, $label = '', $special_code = 0, $array_options = 0, $fk_unit = null, $pu_ht_devise = 0, $notrigger = 0, $ref_ext = '', $rang = 0)
|
||||
{
|
||||
global $conf, $mysoc, $langs, $user;
|
||||
|
||||
@ -3214,6 +3215,7 @@ class Commande extends CommonOrder
|
||||
$line->oldline = $staticline;
|
||||
$this->line = $line;
|
||||
$this->line->context = $this->context;
|
||||
$this->line->rang = $rang;
|
||||
|
||||
// Reorder if fk_parent_line change
|
||||
if (!empty($fk_parent_line) && !empty($staticline->fk_parent_line) && $fk_parent_line != $staticline->fk_parent_line) {
|
||||
|
||||
@ -451,7 +451,8 @@ class Invoices extends DolibarrApi
|
||||
$request_data->fk_unit,
|
||||
$request_data->multicurrency_subprice,
|
||||
0,
|
||||
$request_data->ref_ext
|
||||
$request_data->ref_ext,
|
||||
$request_data->rang
|
||||
);
|
||||
|
||||
if ($updateRes > 0) {
|
||||
|
||||
@ -3840,9 +3840,10 @@ class Facture extends CommonInvoice
|
||||
* @param double $pu_ht_devise Unit price in currency
|
||||
* @param int $notrigger disable line update trigger
|
||||
* @param string $ref_ext External reference of the line
|
||||
* @param integer $rang rank of line
|
||||
* @return int < 0 if KO, > 0 if OK
|
||||
*/
|
||||
public function updateline($rowid, $desc, $pu, $qty, $remise_percent, $date_start, $date_end, $txtva, $txlocaltax1 = 0, $txlocaltax2 = 0, $price_base_type = 'HT', $info_bits = 0, $type = self::TYPE_STANDARD, $fk_parent_line = 0, $skip_update_total = 0, $fk_fournprice = null, $pa_ht = 0, $label = '', $special_code = 0, $array_options = 0, $situation_percent = 100, $fk_unit = null, $pu_ht_devise = 0, $notrigger = 0, $ref_ext = '')
|
||||
public function updateline($rowid, $desc, $pu, $qty, $remise_percent, $date_start, $date_end, $txtva, $txlocaltax1 = 0, $txlocaltax2 = 0, $price_base_type = 'HT', $info_bits = 0, $type = self::TYPE_STANDARD, $fk_parent_line = 0, $skip_update_total = 0, $fk_fournprice = null, $pa_ht = 0, $label = '', $special_code = 0, $array_options = 0, $situation_percent = 100, $fk_unit = null, $pu_ht_devise = 0, $notrigger = 0, $ref_ext = '', $rang = 0)
|
||||
{
|
||||
global $conf, $user;
|
||||
// Deprecation warning
|
||||
@ -3970,6 +3971,7 @@ class Facture extends CommonInvoice
|
||||
$line->oldline = $staticline;
|
||||
$this->line = $line;
|
||||
$this->line->context = $this->context;
|
||||
$this->line->rang = $rang;
|
||||
|
||||
// Reorder if fk_parent_line change
|
||||
if (!empty($fk_parent_line) && !empty($staticline->fk_parent_line) && $fk_parent_line != $staticline->fk_parent_line) {
|
||||
|
||||
@ -856,7 +856,7 @@ if (is_object($objcanvas) && $objcanvas->displayCanvasExists($action)) {
|
||||
if (!empty($value['icon'])) {
|
||||
print '<span class="fa '.$value['icon'].'"></span>';
|
||||
}
|
||||
print '<input type="text" name="'.$key.'" id="'.$key.'" class="minwidth100" maxlength="80" value="'.dol_escape_htmltag(GETPOSTISSET($key) ?GETPOST($key, 'alphanohtml') : $object->socialnetworks[$key]).'">';
|
||||
print '<input type="text" name="'.$key.'" id="'.$key.'" class="minwidth100" maxlength="80" value="'.dol_escape_htmltag(GETPOSTISSET($key) ?GETPOST($key, 'alphanohtml') : (!empty($object->socialnetworks[$key]) ? $object->socialnetworks[$key] : "")).'">';
|
||||
print '</td>';
|
||||
print '</tr>';
|
||||
} elseif (!empty($object->socialnetworks[$key])) {
|
||||
|
||||
@ -7734,7 +7734,7 @@ class Form
|
||||
$val = preg_replace('/t\./', '', $val);
|
||||
$label .= (($label && $obj->$val) ? ($oldvalueforshowoncombobox != $objecttmp->fields[$val]['showoncombobox'] ? ' - ' : ' ') : '');
|
||||
$label .= $obj->$val;
|
||||
$oldvalueforshowoncombobox = $objecttmp->fields[$val]['showoncombobox'];
|
||||
$oldvalueforshowoncombobox = !empty($objecttmp->fields[$val]['showoncombobox']) ? $objecttmp->fields[$val]['showoncombobox'] : 0;
|
||||
}
|
||||
if (empty($outputmode)) {
|
||||
if ($preselectedvalue > 0 && $preselectedvalue == $obj->rowid) {
|
||||
|
||||
@ -133,7 +133,7 @@ class FormSetup
|
||||
*/
|
||||
public function generateOutput($editMode = false)
|
||||
{
|
||||
global $hookmanager, $action;
|
||||
global $hookmanager, $action, $langs;
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/html.form.class.php';
|
||||
|
||||
$parameters = array(
|
||||
@ -177,6 +177,8 @@ class FormSetup
|
||||
$out .= '<div class="form-setup-button-container center">'; // Todo : remove .center by adding style to form-setup-button-container css class in all themes
|
||||
$out.= $this->htmlOutputMoreButton;
|
||||
$out .= '<input class="button button-save" type="submit" value="' . $this->langs->trans("Save") . '">'; // Todo fix dolibarr style for <button and use <button instead of input
|
||||
$out .= ' ';
|
||||
$out .= '<a class="button button-cancel" type="submit" href="' . $this->formAttributes['action'] . '">'.$langs->trans('Cancel').'</a>';
|
||||
$out .= '</div>';
|
||||
}
|
||||
|
||||
@ -283,8 +285,13 @@ class FormSetup
|
||||
|
||||
$out = '';
|
||||
if ($item->enabled==1) {
|
||||
$trClass = 'oddeven';
|
||||
if ($item->getType() == 'title') {
|
||||
$trClass = 'liste_titre';
|
||||
}
|
||||
|
||||
$this->setupNotEmpty++;
|
||||
$out.= '<tr class="oddeven">';
|
||||
$out.= '<tr class="'.$trClass.'">';
|
||||
|
||||
$out.= '<td class="col-setup-title">';
|
||||
$out.= '<span id="helplink'.$item->confKey.'" class="spanforparamtooltip">';
|
||||
@ -579,6 +586,15 @@ class FormSetupItem
|
||||
/** @var int $rank */
|
||||
public $rank = 0;
|
||||
|
||||
/** @var array set this var for options on select and multiselect items */
|
||||
public $fieldOptions = array();
|
||||
|
||||
/** @var callable $saveCallBack */
|
||||
public $saveCallBack;
|
||||
|
||||
/** @var callable $setValueFromPostCallBack */
|
||||
public $setValueFromPostCallBack;
|
||||
|
||||
/**
|
||||
* @var string $errors
|
||||
*/
|
||||
@ -636,6 +652,10 @@ class FormSetupItem
|
||||
*/
|
||||
public function saveConfValue()
|
||||
{
|
||||
if (!empty($this->saveCallBack) && is_callable($this->saveCallBack)) {
|
||||
return call_user_func($this->saveCallBack);
|
||||
}
|
||||
|
||||
// Modify constant only if key was posted (avoid resetting key to the null value)
|
||||
if ($this->type != 'title') {
|
||||
$result = dolibarr_set_const($this->db, $this->confKey, $this->fieldValue, 'chaine', 0, '', $this->entity);
|
||||
@ -647,6 +667,25 @@ class FormSetupItem
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Set an override function for saving data
|
||||
* @param callable $callBack a callable function
|
||||
* @return void
|
||||
*/
|
||||
public function setSaveCallBack(callable $callBack)
|
||||
{
|
||||
$this->saveCallBack = $callBack;
|
||||
}
|
||||
|
||||
/**
|
||||
* Set an override function for get data from post
|
||||
* @param callable $callBack a callable function
|
||||
* @return void
|
||||
*/
|
||||
public function setValueFromPostCallBack(callable $callBack)
|
||||
{
|
||||
$this->setValueFromPostCallBack = $callBack;
|
||||
}
|
||||
|
||||
/**
|
||||
* Save const value based on htdocs/core/actions_setmoduleoptions.inc.php
|
||||
@ -654,6 +693,10 @@ class FormSetupItem
|
||||
*/
|
||||
public function setValueFromPost()
|
||||
{
|
||||
if (!empty($this->setValueFromPostCallBack) && is_callable($this->setValueFromPostCallBack)) {
|
||||
return call_user_func($this->setValueFromPostCallBack);
|
||||
}
|
||||
|
||||
// Modify constant only if key was posted (avoid resetting key to the null value)
|
||||
if ($this->type != 'title') {
|
||||
if (preg_match('/category:/', $this->type)) {
|
||||
@ -662,6 +705,13 @@ class FormSetupItem
|
||||
} else {
|
||||
$val_const = GETPOST($this->confKey, 'int');
|
||||
}
|
||||
} elseif ($this->type == 'multiselect') {
|
||||
$val = GETPOST($this->confKey, 'array');
|
||||
if ($val && is_array($val)) {
|
||||
$val_const = implode(',', $val);
|
||||
}
|
||||
} elseif ($this->type == 'html') {
|
||||
$val_const = GETPOST($this->confKey, 'restricthtml');
|
||||
} else {
|
||||
$val_const = GETPOST($this->confKey, 'alpha');
|
||||
}
|
||||
@ -719,6 +769,10 @@ class FormSetupItem
|
||||
|
||||
if ($this->type == 'title') {
|
||||
$out.= $this->generateOutputField(); // title have no input
|
||||
} elseif ($this->type == 'multiselect') {
|
||||
$out.= $this->generateInputFieldMultiSelect();
|
||||
} elseif ($this->type == 'select') {
|
||||
$out.= $this->generateInputFieldSelect();
|
||||
} elseif ($this->type == 'textarea') {
|
||||
$out.= $this->generateInputFieldTextarea();
|
||||
} elseif ($this->type== 'html') {
|
||||
@ -851,6 +905,29 @@ class FormSetupItem
|
||||
return $out;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @return string
|
||||
*/
|
||||
public function generateInputFieldMultiSelect()
|
||||
{
|
||||
$TSelected = array();
|
||||
if ($this->fieldValue) {
|
||||
$TSelected = explode(',', $this->fieldValue);
|
||||
}
|
||||
|
||||
return $this->form->multiselectarray($this->confKey, $this->fieldOptions, $TSelected, 0, 0, '', 0, 0, 'style="min-width:100px"');
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @return string
|
||||
*/
|
||||
public function generateInputFieldSelect()
|
||||
{
|
||||
return $this->form->selectarray($this->confKey, $this->fieldOptions, $this->fieldValue);
|
||||
}
|
||||
|
||||
/**
|
||||
* get the type : used for old module builder setup conf style conversion and tests
|
||||
* because this two class will quickly evolve it's important to not set or get directly $this->type (will be protected) so this method exist
|
||||
@ -916,6 +993,10 @@ class FormSetupItem
|
||||
// nothing to do
|
||||
} elseif ($this->type == 'textarea') {
|
||||
$out.= dol_nl2br($this->fieldValue);
|
||||
} elseif ($this->type == 'multiselect') {
|
||||
$out.= $this->generateOutputFieldMultiSelect();
|
||||
} elseif ($this->type == 'select') {
|
||||
$out.= $this->generateOutputFieldSelect();
|
||||
} elseif ($this->type== 'html') {
|
||||
$out.= $this->fieldValue;
|
||||
} elseif ($this->type == 'yesno') {
|
||||
@ -969,6 +1050,41 @@ class FormSetupItem
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @return string
|
||||
*/
|
||||
public function generateOutputFieldMultiSelect()
|
||||
{
|
||||
$outPut = '';
|
||||
$TSelected = array();
|
||||
if (!empty($this->fieldValue)) {
|
||||
$TSelected = explode(',', $this->fieldValue);
|
||||
}
|
||||
|
||||
if (!empty($TSelected)) {
|
||||
foreach ($TSelected as $selected) {
|
||||
if (!empty($this->fieldOptions[$selected])) {
|
||||
$outPut.= dolGetBadge('', $this->fieldOptions[$selected], 'info').' ';
|
||||
}
|
||||
}
|
||||
}
|
||||
return $outPut;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @return string
|
||||
*/
|
||||
public function generateOutputFieldSelect()
|
||||
{
|
||||
$outPut = '';
|
||||
if (!empty($this->fieldOptions[$this->fieldValue])) {
|
||||
$outPut = $this->fieldOptions[$this->fieldValue];
|
||||
}
|
||||
|
||||
return $outPut;
|
||||
}
|
||||
|
||||
/*
|
||||
* METHODS FOR SETTING DISPLAY TYPE
|
||||
*/
|
||||
@ -1076,4 +1192,37 @@ class FormSetupItem
|
||||
$this->type = 'title';
|
||||
return $this;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Set type of input as a simple title
|
||||
* no data to store
|
||||
* @param array $fieldOptions A table of field options
|
||||
* @return self
|
||||
*/
|
||||
public function setAsMultiSelect($fieldOptions)
|
||||
{
|
||||
if (is_array($fieldOptions)) {
|
||||
$this->fieldOptions = $fieldOptions;
|
||||
}
|
||||
|
||||
$this->type = 'multiselect';
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Set type of input as a simple title
|
||||
* no data to store
|
||||
* @param array $fieldOptions A table of field options
|
||||
* @return self
|
||||
*/
|
||||
public function setAsSelect($fieldOptions)
|
||||
{
|
||||
if (is_array($fieldOptions)) {
|
||||
$this->fieldOptions = $fieldOptions;
|
||||
}
|
||||
|
||||
$this->type = 'select';
|
||||
return $this;
|
||||
}
|
||||
}
|
||||
|
||||
@ -134,10 +134,10 @@ class modTicket extends DolibarrModules
|
||||
$this->dictionaries = array(
|
||||
'langs' => 'ticket',
|
||||
'tabname' => array(
|
||||
MAIN_DB_PREFIX."c_ticket_type",
|
||||
MAIN_DB_PREFIX."c_ticket_severity",
|
||||
MAIN_DB_PREFIX."c_ticket_category",
|
||||
MAIN_DB_PREFIX."c_ticket_resolution"
|
||||
"c_ticket_type",
|
||||
"c_ticket_severity",
|
||||
"c_ticket_category",
|
||||
"c_ticket_resolution"
|
||||
),
|
||||
'tablib' => array(
|
||||
"TicketDictType",
|
||||
|
||||
@ -647,7 +647,8 @@ class SupplierInvoices extends DolibarrApi
|
||||
$request_data->array_options,
|
||||
$request_data->fk_unit,
|
||||
$request_data->multicurrency_subprice,
|
||||
$request_data->ref_supplier
|
||||
$request_data->ref_supplier,
|
||||
$request_data->rang
|
||||
);
|
||||
|
||||
if ($updateRes > 0) {
|
||||
|
||||
@ -2277,9 +2277,10 @@ class FactureFournisseur extends CommonInvoice
|
||||
* @param string $fk_unit Code of the unit to use. Null to use the default one
|
||||
* @param double $pu_devise Amount in currency
|
||||
* @param string $ref_supplier Supplier ref
|
||||
* @param integer $rang line rank
|
||||
* @return int <0 if KO, >0 if OK
|
||||
*/
|
||||
public function updateline($id, $desc, $pu, $vatrate, $txlocaltax1 = 0, $txlocaltax2 = 0, $qty = 1, $idproduct = 0, $price_base_type = 'HT', $info_bits = 0, $type = 0, $remise_percent = 0, $notrigger = false, $date_start = '', $date_end = '', $array_options = 0, $fk_unit = null, $pu_devise = 0, $ref_supplier = '')
|
||||
public function updateline($id, $desc, $pu, $vatrate, $txlocaltax1 = 0, $txlocaltax2 = 0, $qty = 1, $idproduct = 0, $price_base_type = 'HT', $info_bits = 0, $type = 0, $remise_percent = 0, $notrigger = false, $date_start = '', $date_end = '', $array_options = 0, $fk_unit = null, $pu_devise = 0, $ref_supplier = '', $rang = 0)
|
||||
{
|
||||
global $mysoc, $langs;
|
||||
|
||||
@ -2401,6 +2402,7 @@ class FactureFournisseur extends CommonInvoice
|
||||
$line->product_type = $product_type;
|
||||
$line->info_bits = $info_bits;
|
||||
$line->fk_unit = $fk_unit;
|
||||
$line->rang = $rang;
|
||||
|
||||
if (is_array($array_options) && count($array_options) > 0) {
|
||||
// We replace values in this->line->array_options only for entries defined into $array_options
|
||||
@ -3686,6 +3688,10 @@ class SupplierInvoiceLine extends CommonObjectLine
|
||||
$sql .= ", info_bits = ".((int) $this->info_bits);
|
||||
$sql .= ", fk_unit = ".($fk_unit > 0 ? (int) $fk_unit : 'null');
|
||||
|
||||
if (!empty($this->rang)) {
|
||||
$sql .= ", rang=".((int) $this->rang);
|
||||
}
|
||||
|
||||
// Multicurrency
|
||||
$sql .= " , multicurrency_subprice=".price2num($this->multicurrency_subprice)."";
|
||||
$sql .= " , multicurrency_total_ht=".price2num($this->multicurrency_total_ht)."";
|
||||
|
||||
@ -512,3 +512,25 @@ INSERT INTO llx_c_regions (fk_pays, code_region, cheflieu, tncc, nom) values ( 2
|
||||
INSERT INTO llx_c_regions (fk_pays, code_region, cheflieu, tncc, nom) values ( 232, 23208, '', 0, 'Nor-Oriental');
|
||||
INSERT INTO llx_c_regions (fk_pays, code_region, cheflieu, tncc, nom) values ( 232, 23209, '', 0, 'Zuliana');
|
||||
|
||||
|
||||
|
||||
-- Burundi Regions (id country=61) -- https://fr.wikipedia.org/wiki/Provinces_du_Burundi
|
||||
INSERT INTO llx_c_regions (fk_pays, code_region, cheflieu, tncc, nom) VALUES ( 61, 6101, '', 0, "Bubanza");
|
||||
INSERT INTO llx_c_regions (fk_pays, code_region, cheflieu, tncc, nom) VALUES ( 61, 6102, '', 0, "Bujumbura Mairie");
|
||||
INSERT INTO llx_c_regions (fk_pays, code_region, cheflieu, tncc, nom) VALUES ( 61, 6103, '', 0, "Bujumbura Rural");
|
||||
INSERT INTO llx_c_regions (fk_pays, code_region, cheflieu, tncc, nom) VALUES ( 61, 6104, '', 0, "Bururi");
|
||||
INSERT INTO llx_c_regions (fk_pays, code_region, cheflieu, tncc, nom) VALUES ( 61, 6105, '', 0, "Cankuzo");
|
||||
INSERT INTO llx_c_regions (fk_pays, code_region, cheflieu, tncc, nom) VALUES ( 61, 6106, '', 0, "Cibitoke");
|
||||
INSERT INTO llx_c_regions (fk_pays, code_region, cheflieu, tncc, nom) VALUES ( 61, 6107, '', 0, "Gitega");
|
||||
INSERT INTO llx_c_regions (fk_pays, code_region, cheflieu, tncc, nom) VALUES ( 61, 6108, '', 0, "Karuzi");
|
||||
INSERT INTO llx_c_regions (fk_pays, code_region, cheflieu, tncc, nom) VALUES ( 61, 6109, '', 0, "Kayanza");
|
||||
INSERT INTO llx_c_regions (fk_pays, code_region, cheflieu, tncc, nom) VALUES ( 61, 6110, '', 0, "Kirundo");
|
||||
INSERT INTO llx_c_regions (fk_pays, code_region, cheflieu, tncc, nom) VALUES ( 61, 6111, '', 0, "Makamba");
|
||||
INSERT INTO llx_c_regions (fk_pays, code_region, cheflieu, tncc, nom) VALUES ( 61, 6112, '', 0, "Muramvya");
|
||||
INSERT INTO llx_c_regions (fk_pays, code_region, cheflieu, tncc, nom) VALUES ( 61, 6113, '', 0, "Muyinga");
|
||||
INSERT INTO llx_c_regions (fk_pays, code_region, cheflieu, tncc, nom) VALUES ( 61, 6114, '', 0, "Mwaro");
|
||||
INSERT INTO llx_c_regions (fk_pays, code_region, cheflieu, tncc, nom) VALUES ( 61, 6115, '', 0, "Ngozi");
|
||||
INSERT INTO llx_c_regions (fk_pays, code_region, cheflieu, tncc, nom) VALUES ( 61, 6116, '', 0, "Rumonge");
|
||||
INSERT INTO llx_c_regions (fk_pays, code_region, cheflieu, tncc, nom) VALUES ( 61, 6117, '', 0, "Rutana");
|
||||
INSERT INTO llx_c_regions (fk_pays, code_region, cheflieu, tncc, nom) VALUES ( 61, 6118, '', 0, "Ruyigi");
|
||||
|
||||
|
||||
@ -1759,6 +1759,127 @@ INSERT INTO llx_c_departements ( code_departement, fk_region, cheflieu, tncc, nc
|
||||
INSERT INTO llx_c_departements ( code_departement, fk_region, cheflieu, tncc, ncc, nom, active) VALUES ('VE-S', 23209, '', 0, 'VE-S', 'Táchira', 1);
|
||||
|
||||
|
||||
-- Burundi Communes (id country=61) -- https://fr.wikipedia.org/wiki/Communes_du_Burundi
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6101, 'BI0001', '', 0, '', 'Bubanza');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6101, 'BI0002', '', 0, '', 'Gihanga');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6101, 'BI0003', '', 0, '', 'Musigati');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6101, 'BI0004', '', 0, '', 'Mpanda');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6101, 'BI0005', '', 0, '', 'Rugazi');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6102, 'BI0006', '', 0, '', 'Muha');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6102, 'BI0007', '', 0, '', 'Mukaza');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6102, 'BI0008', '', 0, '', 'Ntahangwa');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6103, 'BI0009', '', 0, '', 'Isale');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6103, 'BI0010', '', 0, '', 'Kabezi');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6103, 'BI0011', '', 0, '', 'Kanyosha');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6103, 'BI0012', '', 0, '', 'Mubimbi');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6103, 'BI0013', '', 0, '', 'Mugongomanga');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6103, 'BI0014', '', 0, '', 'Mukike');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6103, 'BI0015', '', 0, '', 'Mutambu');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6103, 'BI0016', '', 0, '', 'Mutimbuzi');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6103, 'BI0017', '', 0, '', 'Nyabiraba');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6104, 'BI0018', '', 0, '', 'Bururi');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6104, 'BI0019', '', 0, '', 'Matana');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6104, 'BI0020', '', 0, '', 'Mugamba');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6104, 'BI0021', '', 0, '', 'Rutovu');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6104, 'BI0022', '', 0, '', 'Songa');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6104, 'BI0023', '', 0, '', 'Vyanda');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6105, 'BI0024', '', 0, '', 'Cankuzo');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6105, 'BI0025', '', 0, '', 'Cendajuru');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6105, 'BI0026', '', 0, '', 'Gisagara');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6105, 'BI0027', '', 0, '', 'Kigamba');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6105, 'BI0028', '', 0, '', 'Mishiha');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6106, 'BI0029', '', 0, '', 'Buganda');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6106, 'BI0030', '', 0, '', 'Bukinanyana');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6106, 'BI0031', '', 0, '', 'Mabayi');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6106, 'BI0032', '', 0, '', 'Mugina');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6106, 'BI0033', '', 0, '', 'Murwi');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6106, 'BI0034', '', 0, '', 'Rugombo');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6107, 'BI0035', '', 0, '', 'Bugendana');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6107, 'BI0036', '', 0, '', 'Bukirasazi');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6107, 'BI0037', '', 0, '', 'Buraza');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6107, 'BI0038', '', 0, '', 'Giheta');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6107, 'BI0039', '', 0, '', 'Gishubi');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6107, 'BI0040', '', 0, '', 'Gitega');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6107, 'BI0041', '', 0, '', 'Itaba');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6107, 'BI0042', '', 0, '', 'Makebuko');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6107, 'BI0043', '', 0, '', 'Mutaho');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6107, 'BI0044', '', 0, '', 'Nyanrusange');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6107, 'BI0045', '', 0, '', 'Ryansoro');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6108, 'BI0046', '', 0, '', 'Bugenyuzi');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6108, 'BI0047', '', 0, '', 'Buhiga');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6108, 'BI0048', '', 0, '', 'Gihogazi');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6108, 'BI0049', '', 0, '', 'Gitaramuka');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6108, 'BI0050', '', 0, '', 'Mutumba');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6108, 'BI0051', '', 0, '', 'Nyabikere');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6108, 'BI0052', '', 0, '', 'Shombo');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6109, 'BI0053', '', 0, '', 'Butaganzwa');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6109, 'BI0054', '', 0, '', 'Gahombo');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6109, 'BI0055', '', 0, '', 'Gatara');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6109, 'BI0056', '', 0, '', 'Kabarore');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6109, 'BI0057', '', 0, '', 'Kayanza');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6109, 'BI0058', '', 0, '', 'Matongo');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6109, 'BI0059', '', 0, '', 'Muhanga');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6109, 'BI0060', '', 0, '', 'Muruta');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6109, 'BI0061', '', 0, '', 'Rango');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6110, 'BI0062', '', 0, '', 'Bugabira');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6110, 'BI0063', '', 0, '', 'Busoni');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6110, 'BI0064', '', 0, '', 'Bwambarangwe');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6110, 'BI0065', '', 0, '', 'Gitobe');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6110, 'BI0066', '', 0, '', 'Kirundo');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6110, 'BI0067', '', 0, '', 'Ntega');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6110, 'BI0068', '', 0, '', 'Vumbi');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6111, 'BI0069', '', 0, '', 'Kayogoro');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6111, 'BI0070', '', 0, '', 'Kibago');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6111, 'BI0071', '', 0, '', 'Mabanda');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6111, 'BI0072', '', 0, '', 'Makamba');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6111, 'BI0073', '', 0, '', 'Nyanza-Lac');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6111, 'BI0074', '', 0, '', 'Vugizo');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6112, 'BI0075', '', 0, '', 'Bukeye');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6112, 'BI0076', '', 0, '', 'Kiganda');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6112, 'BI0077', '', 0, '', 'Mbuye');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6112, 'BI0078', '', 0, '', 'Muramvya');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6112, 'BI0079', '', 0, '', 'Rutegama');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6113, 'BI0080', '', 0, '', 'Buhinyuza');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6113, 'BI0081', '', 0, '', 'Butihinda');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6113, 'BI0082', '', 0, '', 'Gashoho');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6113, 'BI0083', '', 0, '', 'Gasorwe');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6113, 'BI0084', '', 0, '', 'Giteranyi');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6113, 'BI0085', '', 0, '', 'Muyinga');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6113, 'BI0086', '', 0, '', 'Mwakiro');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6114, 'BI0087', '', 0, '', 'Bisoro');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6114, 'BI0088', '', 0, '', 'Gisozi');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6114, 'BI0089', '', 0, '', 'Kayokwe');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6114, 'BI0090', '', 0, '', 'Ndava');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6114, 'BI0091', '', 0, '', 'Nyabihanga');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6114, 'BI0092', '', 0, '', 'Rusaka');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6115, 'BI0093', '', 0, '', 'Busiga');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6115, 'BI0094', '', 0, '', 'Gashikanwa');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6115, 'BI0095', '', 0, '', 'Kiremba');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6115, 'BI0096', '', 0, '', 'Marangara');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6115, 'BI0097', '', 0, '', 'Mwumba');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6115, 'BI0098', '', 0, '', 'Ngozi');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6115, 'BI0099', '', 0, '', 'Nyamurenza');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6115, 'BI0100', '', 0, '', 'Ruhororo');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6115, 'BI0101', '', 0, '', 'Tangara');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6116, 'BI0102', '', 0, '', 'Bugarama');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6116, 'BI0103', '', 0, '', 'Burambi');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6116, 'BI0104', '', 0, '', 'Buyengero');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6116, 'BI0105', '', 0, '', 'Muhuta');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6116, 'BI0106', '', 0, '', 'Rumonge');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6117, 'BI0107', '', 0, '', 'Bukemba');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6117, 'BI0108', '', 0, '', 'Giharo');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6117, 'BI0109', '', 0, '', 'Gitanga');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6117, 'BI0110', '', 0, '', 'Mpinga-Kayove');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6117, 'BI0111', '', 0, '', 'Musongati');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6117, 'BI0112', '', 0, '', 'Rutana');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6118, 'BI0113', '', 0, '', 'Butaganzwa');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6118, 'BI0114', '', 0, '', 'Butezi');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6118, 'BI0115', '', 0, '', 'Bweru');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6118, 'BI0116', '', 0, '', 'Gisuru');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6118, 'BI0117', '', 0, '', 'Kinyinya');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6118, 'BI0118', '', 0, '', 'Nyabitsinda');
|
||||
INSERT INTO llx_c_departements (fk_region, code_departement, cheflieu, tncc, ncc, nom) VALUES (6118, 'BI0119', '', 0, '', 'Ruyigi');
|
||||
|
||||
-- Provinces United Arab Emirates (id country=227)
|
||||
INSERT INTO llx_c_departements (code_departement, fk_region, cheflieu, tncc, ncc, nom) VALUES ('AE-1', 22701, '', 0, '', 'Abu Dhabi');
|
||||
INSERT INTO llx_c_departements (code_departement, fk_region, cheflieu, tncc, ncc, nom) VALUES ('AE-2', 22701, '', 0, '', 'Dubai');
|
||||
@ -1767,4 +1888,3 @@ INSERT INTO llx_c_departements (code_departement, fk_region, cheflieu, tncc, ncc
|
||||
INSERT INTO llx_c_departements (code_departement, fk_region, cheflieu, tncc, ncc, nom) VALUES ('AE-5', 22701, '', 0, '', 'Ras al-Khaimah');
|
||||
INSERT INTO llx_c_departements (code_departement, fk_region, cheflieu, tncc, ncc, nom) VALUES ('AE-6', 22701, '', 0, '', 'Sharjah');
|
||||
INSERT INTO llx_c_departements (code_departement, fk_region, cheflieu, tncc, ncc, nom) VALUES ('AE-7', 22701, '', 0, '', 'Umm al-Quwain');
|
||||
|
||||
|
||||
@ -7,6 +7,7 @@
|
||||
-- Copyright (C) 2007 Patrick Raguin <patrick.raguin@gmail.com>
|
||||
-- Copyright (C) 2011 Juanjo Menent <jmenent@2byte.es>
|
||||
-- Copyright (C) 2020 Udo Tamm <dev@dolibit.de>
|
||||
-- Copyright (C) 2022 Éric Seigne <eric.seigne@cap-rel.fr>
|
||||
-- Copyright (C) 2021 Lenin Rivas <lenin@leninrivas.com>
|
||||
--
|
||||
-- This program is free software; you can redistribute it and/or modify
|
||||
@ -57,6 +58,7 @@ INSERT INTO llx_c_currencies ( code_iso, unicode, active, label ) VALUES ( 'BWP'
|
||||
INSERT INTO llx_c_currencies ( code_iso, unicode, active, label ) VALUES ( 'BGN', '[1083,1074]', 1, 'Bulgaria Lev');
|
||||
INSERT INTO llx_c_currencies ( code_iso, unicode, active, label ) VALUES ( 'BRL', '[82,36]', 1, 'Brazil Real');
|
||||
INSERT INTO llx_c_currencies ( code_iso, unicode, active, label ) VALUES ( 'BND', '[36]', 1, 'Brunei Darussalam Dollar');
|
||||
INSERT INTO llx_c_currencies ( code_iso, unicode, active, label ) VALUES ( 'BIF', NULL, 1, 'Burundi Franc');
|
||||
INSERT INTO llx_c_currencies ( code_iso, unicode, active, label ) VALUES ( 'KHR', '[6107]', 1, 'Cambodia Riel');
|
||||
INSERT INTO llx_c_currencies ( code_iso, unicode, active, label ) VALUES ( 'CAD', '[36]', 1, 'Canada Dollar');
|
||||
INSERT INTO llx_c_currencies ( code_iso, unicode, active, label ) VALUES ( 'CVE', '[4217]', 1, 'Cap Verde Escudo');
|
||||
|
||||
@ -384,6 +384,13 @@ INSERT INTO llx_c_forme_juridique (fk_pays, code, libelle) VALUES (20, '2010', '
|
||||
INSERT INTO llx_c_forme_juridique (fk_pays, code, libelle) VALUES (20, '2011', 'Ideell förening');
|
||||
INSERT INTO llx_c_forme_juridique (fk_pays, code, libelle) VALUES (20, '2012', 'Stiftelse');
|
||||
|
||||
-- Burundi (id contry=61)
|
||||
insert into llx_c_forme_juridique (fk_pays, code, libelle) values (61,'6100','Indépendant - Personne physique');
|
||||
insert into llx_c_forme_juridique (fk_pays, code, libelle) values (61,'6101','Société Unipersonnelle');
|
||||
insert into llx_c_forme_juridique (fk_pays, code, libelle) values (61,'6102','Société de personne à responsabilité limité (SPRL)');
|
||||
insert into llx_c_forme_juridique (fk_pays, code, libelle) values (61,'6103','Société anonyme (SA)');
|
||||
insert into llx_c_forme_juridique (fk_pays, code, libelle) values (61,'6104','Société coopérative');
|
||||
|
||||
-- Croatia (id country=76)
|
||||
INSERT INTO llx_c_forme_juridique (fk_pays, code, libelle) VALUES (76, '7601', 'Društvo s ograničenom odgovornošću (d.o.o.)');
|
||||
INSERT INTO llx_c_forme_juridique (fk_pays, code, libelle) VALUES (76, '7602', 'Jednostavno društvo s ograničenom odgovornošću (j.d.o.o.)');
|
||||
|
||||
@ -139,6 +139,12 @@ ProfId3BE=-
|
||||
ProfId4BE=-
|
||||
ProfId5BE=Numéro EORI
|
||||
ProfId6BE=-
|
||||
ProfId1BI=Id. prof. 1 (TIN)
|
||||
ProfId2BI=Id. prof. 2 (PAN)
|
||||
ProfId3BI=Id. prof. 3 (SRVC TAX)
|
||||
ProfId4BI=Id. prof. 4 (FISCAL CENTER)
|
||||
ProfId5BI=Id. prof. 5
|
||||
ProfId6BI=-
|
||||
ProfId1BR=-
|
||||
ProfId2BR=IE (Inscricao Estadual)
|
||||
ProfId3BR=IM (Inscricao Municipal)
|
||||
|
||||
@ -50,6 +50,7 @@ $contextpage = GETPOST('contextpage', 'aZ') ?GETPOST('contextpage', 'aZ') : 'moc
|
||||
$backtopage = GETPOST('backtopage', 'alpha');
|
||||
$lineid = GETPOST('lineid', 'int');
|
||||
$fk_movement = GETPOST('fk_movement', 'int');
|
||||
$fk_default_warehouse = GETPOST('fk_default_warehouse', 'int');
|
||||
|
||||
$collapse = GETPOST('collapse', 'aZ09comma');
|
||||
|
||||
@ -734,6 +735,16 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
|
||||
print '<td>';
|
||||
if ($collapse || in_array($action, array('consumeorproduce', 'consumeandproduceall'))) {
|
||||
print $langs->trans("Warehouse");
|
||||
|
||||
// Select warehouse to force it everywhere
|
||||
if (in_array($action, array('consumeorproduce', 'consumeandproduceall'))) {
|
||||
$listwarehouses = $tmpwarehouse->list_array(1);
|
||||
if (count($listwarehouses) > 1) {
|
||||
print '<br><span class="opacitymedium">' . $langs->trans("ForceTo") . '</span> ' . $form->selectarray('fk_default_warehouse', $listwarehouses, $fk_default_warehouse, 1, 0, 0, '', 0, 0, 0, '', 'minwidth100 maxwidth300', 1);
|
||||
} elseif (count($listwarehouses) == 1) {
|
||||
print '<br><span class="opacitymedium">' . $langs->trans("ForceTo") . '</span> ' . $form->selectarray('fk_default_warehouse', $listwarehouses, $fk_default_warehouse, 0, 0, 0, '', 0, 0, 0, '', 'minwidth100 maxwidth300', 1);
|
||||
}
|
||||
}
|
||||
}
|
||||
print '</td>';
|
||||
if ($conf->stock->enabled) {
|
||||
@ -1057,6 +1068,16 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
|
||||
print '</table>';
|
||||
print '</div>';
|
||||
|
||||
// default warehouse processing
|
||||
print '<script type="text/javascript">
|
||||
$(document).ready(function () {
|
||||
$("select[name=fk_default_warehouse]").change(function() {
|
||||
var fk_default_warehouse = $("option:selected", this).val();
|
||||
$("select[name^=idwarehouse-]").val(fk_default_warehouse).change();
|
||||
});
|
||||
});
|
||||
</script>';
|
||||
|
||||
|
||||
// Lines to produce
|
||||
|
||||
|
||||
@ -192,7 +192,7 @@ if ($id > 0 || $ref) {
|
||||
if (get_class($objproduct) == 'Product') {
|
||||
$out .= '&prodid='.$objproduct->id.'&origin=product&originid='.$id;
|
||||
}
|
||||
$out .= (!empty($objcon->id) ? '&contactid='.$objcon->id : '').'&backtopage=1&percentage=-1';
|
||||
$out .= (!empty($objcon->id) ? '&contactid='.$objcon->id : '').'&backtopage='.$_SERVER["PHP_SELF"].'?id='.$object->id.'&percentage=-1';
|
||||
//$out.=$langs->trans("AddAnAction").' ';
|
||||
//$out.=img_picto($langs->trans("AddAnAction"),'filenew');
|
||||
//$out.="</a>";
|
||||
|
||||
@ -1650,9 +1650,9 @@ if (is_object($objcanvas) && $objcanvas->displayCanvasExists($action)) {
|
||||
print '<tr><td class="titlefieldcreate">'.$langs->trans("ProductAccountancySellCode").'</td>';
|
||||
print '<td>';
|
||||
if ($type == 0) {
|
||||
$accountancy_code_sell = (GETPOSTISSET('accountancy_code_sell') ? GETPOST('accountancy_code_sell', 'alpha') : $conf->global->ACCOUNTING_PRODUCT_SOLD_ACCOUNT);
|
||||
$accountancy_code_sell = (GETPOSTISSET('accountancy_code_sell') ? GETPOST('accountancy_code_sell', 'alpha') : getDolGlobalString("ACCOUNTING_PRODUCT_SOLD_ACCOUNT"));
|
||||
} else {
|
||||
$accountancy_code_sell = (GETPOSTISSET('accountancy_code_sell') ? GETPOST('accountancy_code_sell', 'alpha') : $conf->global->ACCOUNTING_SERVICE_SOLD_ACCOUNT);
|
||||
$accountancy_code_sell = (GETPOSTISSET('accountancy_code_sell') ? GETPOST('accountancy_code_sell', 'alpha') : getDolGlobalString("ACCOUNTING_SERVICE_SOLD_ACCOUNT"));
|
||||
}
|
||||
print $formaccounting->select_account($accountancy_code_sell, 'accountancy_code_sell', 1, null, 1, 1, 'minwidth150 maxwidth300', 1);
|
||||
print '</td></tr>';
|
||||
@ -1662,9 +1662,9 @@ if (is_object($objcanvas) && $objcanvas->displayCanvasExists($action)) {
|
||||
print '<tr><td class="titlefieldcreate">'.$langs->trans("ProductAccountancySellIntraCode").'</td>';
|
||||
print '<td>';
|
||||
if ($type == 0) {
|
||||
$accountancy_code_sell_intra = (GETPOSTISSET('accountancy_code_sell_intra') ? GETPOST('accountancy_code_sell_intra', 'alpha') : $conf->global->ACCOUNTING_PRODUCT_SOLD_INTRA_ACCOUNT);
|
||||
$accountancy_code_sell_intra = (GETPOSTISSET('accountancy_code_sell_intra') ? GETPOST('accountancy_code_sell_intra', 'alpha') : getDolGlobalString("ACCOUNTING_PRODUCT_SOLD_INTRA_ACCOUNT"));
|
||||
} else {
|
||||
$accountancy_code_sell_intra = (GETPOSTISSET('accountancy_code_sell_intra') ? GETPOST('accountancy_code_sell_intra', 'alpha') : $conf->global->ACCOUNTING_SERVICE_SOLD_INTRA_ACCOUNT);
|
||||
$accountancy_code_sell_intra = (GETPOSTISSET('accountancy_code_sell_intra') ? GETPOST('accountancy_code_sell_intra', 'alpha') : getDolGlobalString("ACCOUNTING_SERVICE_SOLD_INTRA_ACCOUNT"));
|
||||
}
|
||||
print $formaccounting->select_account($accountancy_code_sell_intra, 'accountancy_code_sell_intra', 1, null, 1, 1, 'minwidth150 maxwidth300', 1);
|
||||
print '</td></tr>';
|
||||
@ -1674,9 +1674,9 @@ if (is_object($objcanvas) && $objcanvas->displayCanvasExists($action)) {
|
||||
print '<tr><td class="titlefieldcreate">'.$langs->trans("ProductAccountancySellExportCode").'</td>';
|
||||
print '<td>';
|
||||
if ($type == 0) {
|
||||
$accountancy_code_sell_export = (GETPOST('accountancy_code_sell_export') ? GETPOST('accountancy_code_sell_export', 'alpha') : $conf->global->ACCOUNTING_PRODUCT_SOLD_EXPORT_ACCOUNT);
|
||||
$accountancy_code_sell_export = (GETPOST('accountancy_code_sell_export') ? GETPOST('accountancy_code_sell_export', 'alpha') : getDolGlobalString("ACCOUNTING_PRODUCT_SOLD_EXPORT_ACCOUNT"));
|
||||
} else {
|
||||
$accountancy_code_sell_export = (GETPOST('accountancy_code_sell_export') ? GETPOST('accountancy_code_sell_export', 'alpha') : $conf->global->ACCOUNTING_SERVICE_SOLD_EXPORT_ACCOUNT);
|
||||
$accountancy_code_sell_export = (GETPOST('accountancy_code_sell_export') ? GETPOST('accountancy_code_sell_export', 'alpha') : getDolGlobalString("ACCOUNTING_SERVICE_SOLD_EXPORT_ACCOUNT"));
|
||||
}
|
||||
print $formaccounting->select_account($accountancy_code_sell_export, 'accountancy_code_sell_export', 1, null, 1, 1, 'minwidth150 maxwidth300', 1);
|
||||
print '</td></tr>';
|
||||
@ -1685,9 +1685,9 @@ if (is_object($objcanvas) && $objcanvas->displayCanvasExists($action)) {
|
||||
print '<tr><td>'.$langs->trans("ProductAccountancyBuyCode").'</td>';
|
||||
print '<td>';
|
||||
if ($type == 0) {
|
||||
$accountancy_code_buy = (GETPOST('accountancy_code_buy', 'alpha') ? (GETPOST('accountancy_code_buy', 'alpha')) : $conf->global->ACCOUNTING_PRODUCT_BUY_ACCOUNT);
|
||||
$accountancy_code_buy = (GETPOST('accountancy_code_buy', 'alpha') ? (GETPOST('accountancy_code_buy', 'alpha')) : getDolGlobalString("ACCOUNTING_PRODUCT_BUY_ACCOUNT"));
|
||||
} else {
|
||||
$accountancy_code_buy = (GETPOST('accountancy_code_buy', 'alpha') ? (GETPOST('accountancy_code_buy', 'alpha')) : $conf->global->ACCOUNTING_SERVICE_BUY_ACCOUNT);
|
||||
$accountancy_code_buy = (GETPOST('accountancy_code_buy', 'alpha') ? (GETPOST('accountancy_code_buy', 'alpha')) : getDolGlobalString("ACCOUNTING_SERVICE_BUY_ACCOUNT"));
|
||||
}
|
||||
print $formaccounting->select_account($accountancy_code_buy, 'accountancy_code_buy', 1, null, 1, 1, 'minwidth150 maxwidth300', 1);
|
||||
print '</td></tr>';
|
||||
@ -1697,9 +1697,9 @@ if (is_object($objcanvas) && $objcanvas->displayCanvasExists($action)) {
|
||||
print '<tr><td class="titlefieldcreate">'.$langs->trans("ProductAccountancyBuyIntraCode").'</td>';
|
||||
print '<td>';
|
||||
if ($type == 0) {
|
||||
$accountancy_code_buy_intra = (GETPOSTISSET('accountancy_code_buy_intra') ? GETPOST('accountancy_code_buy_intra', 'alpha') : $conf->global->ACCOUNTING_PRODUCT_BUY_INTRA_ACCOUNT);
|
||||
$accountancy_code_buy_intra = (GETPOSTISSET('accountancy_code_buy_intra') ? GETPOST('accountancy_code_buy_intra', 'alpha') : getDolGlobalString("ACCOUNTING_PRODUCT_BUY_INTRA_ACCOUNT"));
|
||||
} else {
|
||||
$accountancy_code_buy_intra = (GETPOSTISSET('accountancy_code_buy_intra') ? GETPOST('accountancy_code_buy_intra', 'alpha') : $conf->global->ACCOUNTING_SERVICE_BUY_INTRA_ACCOUNT);
|
||||
$accountancy_code_buy_intra = (GETPOSTISSET('accountancy_code_buy_intra') ? GETPOST('accountancy_code_buy_intra', 'alpha') : getDolGlobalString("ACCOUNTING_SERVICE_BUY_INTRA_ACCOUNT"));
|
||||
}
|
||||
print $formaccounting->select_account($accountancy_code_buy_intra, 'accountancy_code_buy_intra', 1, null, 1, 1, 'minwidth150 maxwidth300', 1);
|
||||
print '</td></tr>';
|
||||
@ -1709,9 +1709,9 @@ if (is_object($objcanvas) && $objcanvas->displayCanvasExists($action)) {
|
||||
print '<tr><td class="titlefieldcreate">'.$langs->trans("ProductAccountancyBuyExportCode").'</td>';
|
||||
print '<td>';
|
||||
if ($type == 0) {
|
||||
$accountancy_code_buy_export = (GETPOST('accountancy_code_buy_export') ? GETPOST('accountancy_code_buy_export', 'alpha') : $conf->global->ACCOUNTING_PRODUCT_BUY_EXPORT_ACCOUNT);
|
||||
$accountancy_code_buy_export = (GETPOST('accountancy_code_buy_export') ? GETPOST('accountancy_code_buy_export', 'alpha') : getDolGlobalString("ACCOUNTING_PRODUCT_BUY_EXPORT_ACCOUNT"));
|
||||
} else {
|
||||
$accountancy_code_buy_export = (GETPOST('accountancy_code_buy_export') ? GETPOST('accountancy_code_buy_export', 'alpha') : $conf->global->ACCOUNTING_SERVICE_BUY_EXPORT_ACCOUNT);
|
||||
$accountancy_code_buy_export = (GETPOST('accountancy_code_buy_export') ? GETPOST('accountancy_code_buy_export', 'alpha') : getDolGlobalString("ACCOUNTING_SERVICE_BUY_EXPORT_ACCOUNT"));
|
||||
}
|
||||
print $formaccounting->select_account($accountancy_code_buy_export, 'accountancy_code_buy_export', 1, null, 1, 1, 'minwidth150 maxwidth300', 1);
|
||||
print '</td></tr>';
|
||||
|
||||
@ -74,6 +74,9 @@ if ($object->id > 0) {
|
||||
} else {
|
||||
restrictedArea($user, 'produit|service', $fieldvalue, 'product&product', '', '', $fieldtype);
|
||||
}
|
||||
$usercanread = (($object->type == Product::TYPE_PRODUCT && $user->rights->produit->lire) || ($object->type == Product::TYPE_SERVICE && $user->rights->service->lire));
|
||||
$usercancreate = (($object->type == Product::TYPE_PRODUCT && $user->rights->produit->creer) || ($object->type == Product::TYPE_SERVICE && $user->rights->service->creer));
|
||||
$usercandelete = (($object->type == Product::TYPE_PRODUCT && $user->rights->produit->supprimer) || ($object->type == Product::TYPE_SERVICE && $user->rights->service->supprimer));
|
||||
|
||||
|
||||
/*
|
||||
|
||||
@ -764,7 +764,7 @@ END;
|
||||
|
||||
// Reputation
|
||||
print '<tr><td>'.$langs->trans("ReferenceReputation").'</td><td>';
|
||||
echo $form->selectarray('supplier_reputation', $object->reputations, $supplier_reputation ? $supplier_reputation : $object->supplier_reputation);
|
||||
echo $form->selectarray('supplier_reputation', $object->reputations, !empty($supplier_reputation) ? $supplier_reputation : $object->supplier_reputation);
|
||||
print '</td></tr>';
|
||||
|
||||
// Barcode
|
||||
@ -775,7 +775,7 @@ END;
|
||||
print '<tr>';
|
||||
print '<td>'.$langs->trans('BarcodeType').'</td>';
|
||||
print '<td>';
|
||||
print $formbarcode->selectBarcodeType(($rowid ? $object->supplier_fk_barcode_type : $conf->global->PRODUIT_DEFAULT_BARCODE_TYPE), 'fk_barcode_type', 1);
|
||||
print $formbarcode->selectBarcodeType(($rowid ? $object->supplier_fk_barcode_type : getDolGlobalint("PRODUIT_DEFAULT_BARCODE_TYPE")), 'fk_barcode_type', 1);
|
||||
print '</td>';
|
||||
print '</tr>';
|
||||
|
||||
@ -787,7 +787,7 @@ END;
|
||||
}
|
||||
|
||||
// Option to define a transport cost on supplier price
|
||||
if ($conf->global->PRODUCT_CHARGES) {
|
||||
if (!empty($conf->global->PRODUCT_CHARGES)) {
|
||||
if (!empty($conf->margin->enabled)) {
|
||||
print '<tr>';
|
||||
print '<td>'.$langs->trans("Charges").'</td>';
|
||||
@ -815,7 +815,7 @@ END;
|
||||
|
||||
// Extrafields
|
||||
$extrafields->fetch_name_optionals_label("product_fournisseur_price");
|
||||
$extralabels = $extrafields->attributes["product_fournisseur_price"]['label'];
|
||||
$extralabels = !empty($extrafields->attributes["product_fournisseur_price"]['label']) ? $extrafields->attributes["product_fournisseur_price"]['label'] : '';
|
||||
$extrafield_values = $extrafields->getOptionalsFromPost("product_fournisseur_price");
|
||||
if (!empty($extralabels)) {
|
||||
if (empty($rowid)) {
|
||||
@ -868,7 +868,7 @@ END;
|
||||
}
|
||||
|
||||
if (is_object($hookmanager)) {
|
||||
$parameters = array('id_fourn'=>$id_fourn, 'prod_id'=>$object->id);
|
||||
$parameters = array('id_fourn'=>!empty($id_fourn) ? $id_fourn : 0, 'prod_id'=>$object->id);
|
||||
$reshook = $hookmanager->executeHooks('formObjectOptions', $parameters, $object, $action);
|
||||
print $hookmanager->resPrint;
|
||||
}
|
||||
|
||||
@ -143,6 +143,9 @@ if ($type !== '') {
|
||||
}
|
||||
$sql .= " GROUP BY p.rowid, p.label, p.ref, p.fk_product_type";
|
||||
|
||||
$num = 0;
|
||||
$totalnboflines = 0;
|
||||
|
||||
if (!empty($mode) && $mode != '-1') {
|
||||
$result = $db->query($sql);
|
||||
if ($result) {
|
||||
|
||||
@ -1753,7 +1753,7 @@ if ((empty($conf->global->PRODUIT_CUSTOMER_PRICES) || $action == 'showlog_defaul
|
||||
if (empty($positiverates)) {
|
||||
$positiverates = '0';
|
||||
}
|
||||
echo vatrate($positiverates.($objp->default_vat_code ? ' ('.$objp->default_vat_code.')' : ''), '%', $objp->tva_npr);
|
||||
echo vatrate($positiverates.($objp->default_vat_code ? ' ('.$objp->default_vat_code.')' : ''), '%', !empty($objp->tva_npr) ? $objp->tva_npr : 0);
|
||||
/*
|
||||
if ($objp->default_vat_code)
|
||||
{
|
||||
|
||||
@ -46,6 +46,7 @@ $mode = (GETPOST('mode', 'alpha') ? GETPOST('mode', 'alpha') : 'byunit');
|
||||
$search_year = GETPOST('search_year', 'int');
|
||||
$search_categ = GETPOST('search_categ', 'int');
|
||||
$notab = GETPOST('notab', 'int');
|
||||
$type = GETPOST('type', 'alpha');
|
||||
|
||||
$error = 0;
|
||||
$mesg = '';
|
||||
|
||||
@ -986,6 +986,7 @@ if (!$variants) {
|
||||
$num = 0;
|
||||
$total = 0;
|
||||
$totalvalue = $totalvaluesell = 0;
|
||||
$totalwithpmp = 0;
|
||||
|
||||
$resql = $db->query($sql);
|
||||
if ($resql) {
|
||||
|
||||
@ -909,7 +909,7 @@ if (empty($reshook)) {
|
||||
|
||||
// Actions to build doc
|
||||
$id = $socid;
|
||||
$upload_dir = $conf->societe->multidir_output[$object->entity];
|
||||
$upload_dir = !empty($conf->societe->multidir_output[$object->entity])?$conf->societe->multidir_output[$object->entity]:$conf->societe->dir_output;
|
||||
$permissiontoadd = $user->rights->societe->creer;
|
||||
include DOL_DOCUMENT_ROOT.'/core/actions_builddoc.inc.php';
|
||||
}
|
||||
|
||||
@ -52,6 +52,9 @@ $toselect = GETPOST('toselect', 'array');
|
||||
$cancel = GETPOST('cancel', 'alpha');
|
||||
$delete_product = GETPOST('delete_product', 'alpha');
|
||||
$subaction = GETPOST('subaction', 'aZ09');
|
||||
$backtopage = GETPOST('backtopage', 'alpha');
|
||||
$sortfield = GETPOST('sortfield', 'aZ09comma');
|
||||
$sortorder = GETPOST('sortorder', 'aZ09comma');
|
||||
|
||||
// Security check
|
||||
$fieldvalue = (!empty($id) ? $id : $ref);
|
||||
@ -66,7 +69,7 @@ if ($id > 0 || $ref) {
|
||||
$object->fetch($id, $ref);
|
||||
}
|
||||
|
||||
$selectedvariant = $_SESSION['addvariant_'.$object->id];
|
||||
$selectedvariant = !empty($_SESSION['addvariant_'.$object->id]) ? $_SESSION['addvariant_'.$object->id] : 0;
|
||||
|
||||
// Security check
|
||||
if (empty($conf->variants->enabled)) {
|
||||
@ -86,6 +89,9 @@ if ($object->id > 0) {
|
||||
} else {
|
||||
restrictedArea($user, 'produit|service', $fieldvalue, 'product&product', '', '', $fieldtype);
|
||||
}
|
||||
$usercanread = (($object->type == Product::TYPE_PRODUCT && $user->rights->produit->lire) || ($object->type == Product::TYPE_SERVICE && $user->rights->service->lire));
|
||||
$usercancreate = (($object->type == Product::TYPE_PRODUCT && $user->rights->produit->creer) || ($object->type == Product::TYPE_SERVICE && $user->rights->service->creer));
|
||||
$usercandelete = (($object->type == Product::TYPE_PRODUCT && $user->rights->produit->supprimer) || ($object->type == Product::TYPE_SERVICE && $user->rights->service->supprimer));
|
||||
|
||||
|
||||
/*
|
||||
|
||||
Loading…
Reference in New Issue
Block a user