commit
5effcd222f
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
/* Copyright (C) 2016 Marcos García <marcosgdf@gmail.com>
|
||||
/* Copyright (C) 2016 Marcos García <marcosgdf@gmail.com>
|
||||
* Copyright (C) 2018 Frédéric France <frederic.france@netlogic.fr>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
@ -62,9 +62,9 @@ print '<tr class="oddeven"><td>'.$langs->trans('HideProductCombinations').'</td>
|
||||
print $form->selectyesno("PRODUIT_ATTRIBUTES_HIDECHILD",$conf->global->PRODUIT_ATTRIBUTES_HIDECHILD,1).'</td></tr>';
|
||||
print '<tr class="oddeven"><td>'.$langs->trans('CombinationsSeparator').'</td>';
|
||||
if(isset($conf->global->PRODUIT_ATTRIBUTES_SEPARATOR)) {
|
||||
$separator = $conf->global->PRODUIT_ATTRIBUTES_SEPARATOR;
|
||||
$separator = $conf->global->PRODUIT_ATTRIBUTES_SEPARATOR;
|
||||
} else {
|
||||
$separator = "_";
|
||||
$separator = "_";
|
||||
}
|
||||
print '<td align="right"><input size="3" type="text" class="flat" name="PRODUIT_ATTRIBUTES_SEPARATOR" value="'.$separator.'"></td></tr>';
|
||||
print '</table>';
|
||||
@ -74,4 +74,3 @@ print '</form>';
|
||||
// End of page
|
||||
llxFooter();
|
||||
$db->close();
|
||||
|
||||
|
||||
@ -1,5 +1,6 @@
|
||||
<?php
|
||||
/* Copyright (C) 2016 Marcos García <marcosgdf@gmail.com>
|
||||
/* Copyright (C) 2016 Marcos García <marcosgdf@gmail.com>
|
||||
* Copyright (C) 2018 Frédéric France <frederic.france@netlogic.fr>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
@ -50,7 +51,7 @@ if ($_POST) {
|
||||
$object->label = $label;
|
||||
|
||||
if ($object->update($user) < 1) {
|
||||
setEventMessages($langs->trans('CoreErrorMessage'), null, 'errors');
|
||||
setEventMessages($langs->trans('CoreErrorMessage'), $object->errors, 'errors');
|
||||
} else {
|
||||
setEventMessages($langs->trans('RecordSaved'), null, 'mesgs');
|
||||
header('Location: '.dol_buildpath('/variants/card.php?id='.$id, 2));
|
||||
@ -79,7 +80,7 @@ if ($_POST) {
|
||||
if ($objectval->update($user) > 0) {
|
||||
setEventMessages($langs->trans('RecordSaved'), null, 'mesgs');
|
||||
} else {
|
||||
setEventMessage($langs->trans('CoreErrorMessage'), null, 'errors');
|
||||
setEventMessage($langs->trans('CoreErrorMessage'), $objectval->errors, 'errors');
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -99,7 +100,7 @@ if ($confirm == 'yes') {
|
||||
|
||||
if ($res < 1 || ($object->delete() < 1)) {
|
||||
$db->rollback();
|
||||
setEventMessages($langs->trans('CoreErrorMessage'), null, 'errors');
|
||||
setEventMessages($langs->trans('CoreErrorMessage'), $object->errors, 'errors');
|
||||
header('Location: '.dol_buildpath('/variants/card.php?id='.$object->id, 2));
|
||||
} else {
|
||||
$db->commit();
|
||||
@ -113,7 +114,7 @@ if ($confirm == 'yes') {
|
||||
if ($objectval->fetch($valueid) > 0) {
|
||||
|
||||
if ($objectval->delete() < 1) {
|
||||
setEventMessages($langs->trans('CoreErrorMessage'), null, 'errors');
|
||||
setEventMessages($langs->trans('CoreErrorMessage'), $objectval->errors, 'errors');
|
||||
} else {
|
||||
setEventMessages($langs->trans('RecordSaved'), null, 'mesgs');
|
||||
}
|
||||
|
||||
@ -1,6 +1,7 @@
|
||||
<?php
|
||||
/* Copyright (C) 2016 Marcos García <marcosgdf@gmail.com>
|
||||
* Copyright (C) 2017 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
/* Copyright (C) 2016 Marcos García <marcosgdf@gmail.com>
|
||||
* Copyright (C) 2017 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2018 Frédéric France <frederic.france@netlogic.fr>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
||||
@ -1,5 +1,6 @@
|
||||
<?php
|
||||
/* Copyright (C) 2016 Marcos García <marcosgdf@gmail.com>
|
||||
/* Copyright (C) 2016 Marcos García <marcosgdf@gmail.com>
|
||||
* Copyright (C) 2018 Frédéric France <frederic.france@netlogic.fr>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
@ -49,7 +50,7 @@ if ($_POST) {
|
||||
}
|
||||
exit;
|
||||
} else {
|
||||
setEventMessage($langs->trans('ErrorRecordAlreadyExists'), 'errors');
|
||||
setEventMessages($langs->trans('ErrorRecordAlreadyExists'), $prodattr->errors, 'errors');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -1,5 +1,6 @@
|
||||
<?php
|
||||
/* Copyright (C) 2016 Marcos García <marcosgdf@gmail.com>
|
||||
* Copyright (C) 2018 Frédéric France <frederic.france@netlogic.fr>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
@ -70,7 +71,7 @@ if ($action == 'add')
|
||||
header('Location: '.DOL_URL_ROOT.'/variants/card.php?id='.$object->id);
|
||||
exit();
|
||||
} else {
|
||||
setEventMessages($langs->trans('ErrorCreatingProductAttributeValue'), null, 'errors');
|
||||
setEventMessages($langs->trans('ErrorCreatingProductAttributeValue'), $objectval->errors, 'errors');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
/* Copyright (C) 2016 Marcos García <marcosgdf@gmail.com>
|
||||
/* Copyright (C) 2016 Marcos García <marcosgdf@gmail.com>
|
||||
* Copyright (C) 2018 Frédéric France <frederic.france@netlogic.fr>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
||||
Loading…
Reference in New Issue
Block a user