Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop
This commit is contained in:
commit
7cb3b8dfec
@ -57,7 +57,7 @@ llxHeader('', $langs->trans($page_name));
|
|||||||
// Subheader
|
// Subheader
|
||||||
$linkback = '<a href="' . DOL_URL_ROOT . '/admin/modules.php">'
|
$linkback = '<a href="' . DOL_URL_ROOT . '/admin/modules.php">'
|
||||||
. $langs->trans("BackToModuleList") . '</a>';
|
. $langs->trans("BackToModuleList") . '</a>';
|
||||||
print_fiche_titre($langs->trans($page_name), $linkback);
|
print load_fiche_titre($langs->trans($page_name), $linkback);
|
||||||
|
|
||||||
// Configuration header
|
// Configuration header
|
||||||
|
|
||||||
|
|||||||
@ -38,103 +38,35 @@ $action = GETPOST('action','alpha');
|
|||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Actions
|
* Action
|
||||||
*/
|
*/
|
||||||
|
if (preg_match('/set_([a-z0-9_\-]+)/i',$action,$reg))
|
||||||
if($action)
|
|
||||||
{
|
{
|
||||||
$db->begin();
|
$code=$reg[1];
|
||||||
|
if (dolibarr_set_const($db, $code, 1, 'chaine', 0, '', $conf->entity) > 0)
|
||||||
if ($action == 'STOCK_SUPPORTS_SERVICES')
|
|
||||||
{
|
{
|
||||||
$res = dolibarr_set_const($db, "STOCK_SUPPORTS_SERVICES", GETPOST('STOCK_SUPPORTS_SERVICES','alpha'),'chaine',0,'',$conf->entity);
|
header("Location: ".$_SERVER["PHP_SELF"]);
|
||||||
}
|
exit;
|
||||||
if ($action == 'STOCK_USERSTOCK_AUTOCREATE')
|
|
||||||
{
|
|
||||||
$res = dolibarr_set_const($db, "STOCK_USERSTOCK_AUTOCREATE", GETPOST('STOCK_USERSTOCK_AUTOCREATE','alpha'),'chaine',0,'',$conf->entity);
|
|
||||||
}
|
|
||||||
if ($action == 'STOCK_ALLOW_ADD_LIMIT_STOCK_BY_WAREHOUSE') {
|
|
||||||
$res = dolibarr_set_const($db, "STOCK_ALLOW_ADD_LIMIT_STOCK_BY_WAREHOUSE", GETPOST('STOCK_ALLOW_ADD_LIMIT_STOCK_BY_WAREHOUSE','alpha'),'chaine',0,'',$conf->entity);
|
|
||||||
}
|
|
||||||
if ($action == 'STOCK_ALLOW_NEGATIVE_TRANSFER')
|
|
||||||
{
|
|
||||||
$res = dolibarr_set_const($db, "STOCK_ALLOW_NEGATIVE_TRANSFER", GETPOST('STOCK_ALLOW_NEGATIVE_TRANSFER','alpha'),'chaine',0,'',$conf->entity);
|
|
||||||
}
|
|
||||||
// Mode of stock decrease
|
|
||||||
if ($action == 'STOCK_CALCULATE_ON_BILL'
|
|
||||||
|| $action == 'STOCK_CALCULATE_ON_VALIDATE_ORDER'
|
|
||||||
|| $action == 'STOCK_CALCULATE_ON_SHIPMENT'
|
|
||||||
|| $action == 'STOCK_CALCULATE_ON_SHIPMENT_CLOSE')
|
|
||||||
{
|
|
||||||
$res=dolibarr_set_const($db, "STOCK_CALCULATE_ON_BILL", '','chaine',0,'',$conf->entity);
|
|
||||||
$res=dolibarr_set_const($db, "STOCK_CALCULATE_ON_VALIDATE_ORDER", '','chaine',0,'',$conf->entity);
|
|
||||||
$res=dolibarr_set_const($db, "STOCK_CALCULATE_ON_SHIPMENT", '','chaine',0,'',$conf->entity);
|
|
||||||
$res=dolibarr_set_const($db, "STOCK_CALCULATE_ON_SHIPMENT_CLOSE", '','chaine',0,'',$conf->entity);
|
|
||||||
if ($action == 'STOCK_CALCULATE_ON_BILL') $res=dolibarr_set_const($db, "STOCK_CALCULATE_ON_BILL", GETPOST('STOCK_CALCULATE_ON_BILL','alpha'),'chaine',0,'',$conf->entity);
|
|
||||||
if ($action == 'STOCK_CALCULATE_ON_VALIDATE_ORDER') $res=dolibarr_set_const($db, "STOCK_CALCULATE_ON_VALIDATE_ORDER", GETPOST('STOCK_CALCULATE_ON_VALIDATE_ORDER','alpha'),'chaine',0,'',$conf->entity);
|
|
||||||
if ($action == 'STOCK_CALCULATE_ON_SHIPMENT') $res=dolibarr_set_const($db, "STOCK_CALCULATE_ON_SHIPMENT", GETPOST('STOCK_CALCULATE_ON_SHIPMENT','alpha'),'chaine',0,'',$conf->entity);
|
|
||||||
if ($action == 'STOCK_CALCULATE_ON_SHIPMENT_CLOSE') $res=dolibarr_set_const($db, "STOCK_CALCULATE_ON_SHIPMENT_CLOSE", GETPOST('STOCK_CALCULATE_ON_SHIPMENT_CLOSE','alpha'),'chaine',0,'',$conf->entity);
|
|
||||||
}
|
|
||||||
// Mode of stock increase
|
|
||||||
if ($action == 'STOCK_CALCULATE_ON_SUPPLIER_BILL'
|
|
||||||
|| $action == 'STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER'
|
|
||||||
|| $action == 'STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER'
|
|
||||||
|| $action == 'STOCK_CALCULATE_ON_RECEPTION'
|
|
||||||
|| $action == 'STOCK_CALCULATE_ON_RECEPTION_CLOSE')
|
|
||||||
{
|
|
||||||
//Use variable cause empty(GETPOST()) do not work with php version < 5.4
|
|
||||||
$valdispatch=GETPOST('STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER','alpha');
|
|
||||||
|
|
||||||
$res=dolibarr_set_const($db, "STOCK_CALCULATE_ON_SUPPLIER_BILL", '','chaine',0,'',$conf->entity);
|
|
||||||
$res=dolibarr_set_const($db, "STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER", '','chaine',0,'',$conf->entity);
|
|
||||||
$res=dolibarr_set_const($db, "STOCK_CALCULATE_ON_RECEPTION", '','chaine',0,'',$conf->entity);
|
|
||||||
$res=dolibarr_set_const($db, "STOCK_CALCULATE_ON_RECEPTION_CLOSE", '','chaine',0,'',$conf->entity);
|
|
||||||
$res=dolibarr_set_const($db, "STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER", '','chaine',0,'',$conf->entity);
|
|
||||||
if ($action == 'STOCK_CALCULATE_ON_SUPPLIER_BILL') $res=dolibarr_set_const($db, "STOCK_CALCULATE_ON_SUPPLIER_BILL", GETPOST('STOCK_CALCULATE_ON_SUPPLIER_BILL','alpha'),'chaine',0,'',$conf->entity);
|
|
||||||
if ($action == 'STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER') $res=dolibarr_set_const($db, "STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER", GETPOST('STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER','alpha'),'chaine',0,'',$conf->entity);
|
|
||||||
if ($action == 'STOCK_CALCULATE_ON_RECEPTION') $res=dolibarr_set_const($db, "STOCK_CALCULATE_ON_RECEPTION", GETPOST('STOCK_CALCULATE_ON_RECEPTION','alpha'),'chaine',0,'',$conf->entity);
|
|
||||||
if ($action == 'STOCK_CALCULATE_ON_RECEPTION_CLOSE') $res=dolibarr_set_const($db, "STOCK_CALCULATE_ON_RECEPTION_CLOSE", GETPOST('STOCK_CALCULATE_ON_RECEPTION_CLOSE','alpha'),'chaine',0,'',$conf->entity);
|
|
||||||
if ($action == 'STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER') $res=dolibarr_set_const($db, "STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER", $valdispatch,'chaine',0,'',$conf->entity);
|
|
||||||
if (empty($valdispatch)) {
|
|
||||||
$res=dolibarr_set_const($db, "SUPPLIER_ORDER_USE_DISPATCH_STATUS", '','chaine',0,'',$conf->entity);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if($action == 'SUPPLIER_ORDER_USE_DISPATCH_STATUS') {
|
|
||||||
$res = dolibarr_set_const($db, "SUPPLIER_ORDER_USE_DISPATCH_STATUS", GETPOST('SUPPLIER_ORDER_USE_DISPATCH_STATUS','alpha'),'chaine',0,'',$conf->entity);
|
|
||||||
}
|
|
||||||
|
|
||||||
if($action == 'STOCK_USE_VIRTUAL_STOCK') {
|
|
||||||
$res = dolibarr_set_const($db, "STOCK_USE_VIRTUAL_STOCK", GETPOST('STOCK_USE_VIRTUAL_STOCK','alpha'),'chaine',0,'',$conf->entity);
|
|
||||||
}
|
|
||||||
|
|
||||||
if($action == 'STOCK_MUST_BE_ENOUGH_FOR_INVOICE') {
|
|
||||||
$res = dolibarr_set_const($db, "STOCK_MUST_BE_ENOUGH_FOR_INVOICE", GETPOST('STOCK_MUST_BE_ENOUGH_FOR_INVOICE','alpha'),'chaine',0,'',$conf->entity);
|
|
||||||
}
|
|
||||||
if($action == 'STOCK_MUST_BE_ENOUGH_FOR_ORDER') {
|
|
||||||
$res = dolibarr_set_const($db, "STOCK_MUST_BE_ENOUGH_FOR_ORDER", GETPOST('STOCK_MUST_BE_ENOUGH_FOR_ORDER','alpha'),'chaine',0,'',$conf->entity);
|
|
||||||
}
|
|
||||||
if($action == 'STOCK_MUST_BE_ENOUGH_FOR_SHIPMENT') {
|
|
||||||
$res = dolibarr_set_const($db, "STOCK_MUST_BE_ENOUGH_FOR_SHIPMENT", GETPOST('STOCK_MUST_BE_ENOUGH_FOR_SHIPMENT','alpha'),'chaine',0,'',$conf->entity);
|
|
||||||
}
|
|
||||||
if($action == 'INDEPENDANT_SUBPRODUCT_STOCK') {
|
|
||||||
$res = dolibarr_set_const($db, "INDEPENDANT_SUBPRODUCT_STOCK", GETPOST('INDEPENDANT_SUBPRODUCT_STOCK','alpha'),'chaine',0,'',$conf->entity);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (! $res > 0) $error++;
|
|
||||||
|
|
||||||
if (! $error)
|
|
||||||
{
|
|
||||||
$db->commit();
|
|
||||||
setEventMessages($langs->trans("SetupSaved"), null, 'mesgs');
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
$db->rollback();
|
dol_print_error($db);
|
||||||
setEventMessages($langs->trans("Error"), null, 'errors');
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (preg_match('/del_([a-z0-9_\-]+)/i',$action,$reg))
|
||||||
|
{
|
||||||
|
$code=$reg[1];
|
||||||
|
if (dolibarr_del_const($db, $code, $conf->entity) > 0)
|
||||||
|
{
|
||||||
|
header("Location: ".$_SERVER["PHP_SELF"]);
|
||||||
|
exit;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
dol_print_error($db);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* View
|
* View
|
||||||
@ -166,22 +98,22 @@ print '<br>';
|
|||||||
print '<table class="noborder" width="100%">';
|
print '<table class="noborder" width="100%">';
|
||||||
print '<tr class="liste_titre">';
|
print '<tr class="liste_titre">';
|
||||||
print "<td>".$langs->trans("RuleForStockManagementDecrease")."</td>\n";
|
print "<td>".$langs->trans("RuleForStockManagementDecrease")."</td>\n";
|
||||||
print " <td align=\"right\"> </td>\n";
|
print '<td align="center">'.$langs->trans("Status").'</td>'."\n";
|
||||||
print '</tr>'."\n";
|
print '</tr>'."\n";
|
||||||
|
|
||||||
$found=0;
|
$found=0;
|
||||||
|
|
||||||
print '<tr class="oddeven">';
|
print '<tr class="oddeven">';
|
||||||
print '<td>'.$langs->trans("DeStockOnBill").'</td>';
|
print '<td>'.$langs->trans("DeStockOnBill").'</td>';
|
||||||
print '<td align="right">';
|
print '<td align="center">';
|
||||||
if (! empty($conf->facture->enabled))
|
if (! empty($conf->facture->enabled))
|
||||||
{
|
{
|
||||||
print "<form method=\"post\" action=\"stock.php\">";
|
if ($conf->use_javascript_ajax) {
|
||||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
print ajax_constantonoff('STOCK_CALCULATE_ON_BILL');
|
||||||
print "<input type=\"hidden\" name=\"action\" value=\"STOCK_CALCULATE_ON_BILL\">";
|
} else {
|
||||||
print $form->selectyesno("STOCK_CALCULATE_ON_BILL",$conf->global->STOCK_CALCULATE_ON_BILL,1,$disabled);
|
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
|
||||||
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'"'.$disabled.'>';
|
print $form->selectarray("STOCK_CALCULATE_ON_BILL", $arrval, $conf->global->STOCK_CALCULATE_ON_BILL);
|
||||||
print "</form>\n";
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@ -193,15 +125,15 @@ $found++;
|
|||||||
|
|
||||||
print '<tr class="oddeven">';
|
print '<tr class="oddeven">';
|
||||||
print '<td>'.$langs->trans("DeStockOnValidateOrder").'</td>';
|
print '<td>'.$langs->trans("DeStockOnValidateOrder").'</td>';
|
||||||
print '<td align="right">';
|
print '<td align="center">';
|
||||||
if (! empty($conf->commande->enabled))
|
if (! empty($conf->commande->enabled))
|
||||||
{
|
{
|
||||||
print "<form method=\"post\" action=\"stock.php\">";
|
if ($conf->use_javascript_ajax) {
|
||||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
print ajax_constantonoff('STOCK_CALCULATE_ON_VALIDATE_ORDER');
|
||||||
print "<input type=\"hidden\" name=\"action\" value=\"STOCK_CALCULATE_ON_VALIDATE_ORDER\">";
|
} else {
|
||||||
print $form->selectyesno("STOCK_CALCULATE_ON_VALIDATE_ORDER",$conf->global->STOCK_CALCULATE_ON_VALIDATE_ORDER,1,$disabled);
|
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
|
||||||
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'"'.$disabled.'>';
|
print $form->selectarray("STOCK_CALCULATE_ON_VALIDATE_ORDER", $arrval, $conf->global->STOCK_CALCULATE_ON_VALIDATE_ORDER);
|
||||||
print "</form>\n";
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@ -215,15 +147,15 @@ $found++;
|
|||||||
|
|
||||||
print '<tr class="oddeven">';
|
print '<tr class="oddeven">';
|
||||||
print '<td>'.$langs->trans("DeStockOnShipment").'</td>';
|
print '<td>'.$langs->trans("DeStockOnShipment").'</td>';
|
||||||
print '<td align="right">';
|
print '<td align="center">';
|
||||||
if (! empty($conf->expedition->enabled))
|
if (! empty($conf->expedition->enabled))
|
||||||
{
|
{
|
||||||
print "<form method=\"post\" action=\"stock.php\">";
|
if ($conf->use_javascript_ajax) {
|
||||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
print ajax_constantonoff('STOCK_CALCULATE_ON_SHIPMENT');
|
||||||
print "<input type=\"hidden\" name=\"action\" value=\"STOCK_CALCULATE_ON_SHIPMENT\">";
|
} else {
|
||||||
print $form->selectyesno("STOCK_CALCULATE_ON_SHIPMENT",$conf->global->STOCK_CALCULATE_ON_SHIPMENT,1,$disabled);
|
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
|
||||||
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'"'.$disabled.'>';
|
print $form->selectarray("STOCK_CALCULATE_ON_SHIPMENT", $arrval, $conf->global->STOCK_CALCULATE_ON_SHIPMENT);
|
||||||
print "</form>\n";
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@ -235,15 +167,15 @@ $found++;
|
|||||||
|
|
||||||
print '<tr class="oddeven">';
|
print '<tr class="oddeven">';
|
||||||
print '<td>'.$langs->trans("DeStockOnShipmentOnClosing").'</td>';
|
print '<td>'.$langs->trans("DeStockOnShipmentOnClosing").'</td>';
|
||||||
print '<td align="right">';
|
print '<td align="center">';
|
||||||
if (! empty($conf->expedition->enabled))
|
if (! empty($conf->expedition->enabled))
|
||||||
{
|
{
|
||||||
print "<form method=\"post\" action=\"stock.php\">";
|
if ($conf->use_javascript_ajax) {
|
||||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
print ajax_constantonoff('STOCK_CALCULATE_ON_SHIPMENT_CLOSE');
|
||||||
print "<input type=\"hidden\" name=\"action\" value=\"STOCK_CALCULATE_ON_SHIPMENT_CLOSE\">";
|
} else {
|
||||||
print $form->selectyesno("STOCK_CALCULATE_ON_SHIPMENT_CLOSE",$conf->global->STOCK_CALCULATE_ON_SHIPMENT_CLOSE,1,$disabled);
|
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
|
||||||
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'"'.$disabled.'>';
|
print $form->selectarray("STOCK_CALCULATE_ON_SHIPMENT_CLOSE", $arrval, $conf->global->STOCK_CALCULATE_ON_SHIPMENT_CLOSE);
|
||||||
print "</form>\n";
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@ -268,22 +200,22 @@ print '<br>';
|
|||||||
print '<table class="noborder" width="100%">';
|
print '<table class="noborder" width="100%">';
|
||||||
print '<tr class="liste_titre">';
|
print '<tr class="liste_titre">';
|
||||||
print "<td>".$langs->trans("RuleForStockManagementIncrease")."</td>\n";
|
print "<td>".$langs->trans("RuleForStockManagementIncrease")."</td>\n";
|
||||||
print " <td align=\"right\"> </td>\n";
|
print '<td align="center">'.$langs->trans("Status").'</td>'."\n";
|
||||||
print '</tr>'."\n";
|
print '</tr>'."\n";
|
||||||
|
|
||||||
$found=0;
|
$found=0;
|
||||||
|
|
||||||
print '<tr class="oddeven">';
|
print '<tr class="oddeven">';
|
||||||
print '<td>'.$langs->trans("ReStockOnBill").'</td>';
|
print '<td>'.$langs->trans("ReStockOnBill").'</td>';
|
||||||
print '<td align="right">';
|
print '<td align="center">';
|
||||||
if (! empty($conf->fournisseur->enabled))
|
if (! empty($conf->fournisseur->enabled))
|
||||||
{
|
{
|
||||||
print "<form method=\"post\" action=\"stock.php\">";
|
if ($conf->use_javascript_ajax) {
|
||||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
print ajax_constantonoff('STOCK_CALCULATE_ON_SUPPLIER_BILL');
|
||||||
print "<input type=\"hidden\" name=\"action\" value=\"STOCK_CALCULATE_ON_SUPPLIER_BILL\">";
|
} else {
|
||||||
print $form->selectyesno("STOCK_CALCULATE_ON_SUPPLIER_BILL",$conf->global->STOCK_CALCULATE_ON_SUPPLIER_BILL,1,$disabled);
|
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
|
||||||
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'"'.$disabled.'>';
|
print $form->selectarray("STOCK_CALCULATE_ON_SUPPLIER_BILL", $arrval, $conf->global->STOCK_CALCULATE_ON_SUPPLIER_BILL);
|
||||||
print "</form>\n";
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@ -296,15 +228,15 @@ $found++;
|
|||||||
|
|
||||||
print '<tr class="oddeven">';
|
print '<tr class="oddeven">';
|
||||||
print '<td>'.$langs->trans("ReStockOnValidateOrder").'</td>';
|
print '<td>'.$langs->trans("ReStockOnValidateOrder").'</td>';
|
||||||
print '<td align="right">';
|
print '<td align="center">';
|
||||||
if (! empty($conf->fournisseur->enabled))
|
if (! empty($conf->fournisseur->enabled))
|
||||||
{
|
{
|
||||||
print "<form method=\"post\" action=\"stock.php\">";
|
if ($conf->use_javascript_ajax) {
|
||||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
print ajax_constantonoff('STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER');
|
||||||
print "<input type=\"hidden\" name=\"action\" value=\"STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER\">";
|
} else {
|
||||||
print $form->selectyesno("STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER",$conf->global->STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER,1,$disabled);
|
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
|
||||||
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'"'.$disabled.'>';
|
print $form->selectarray("STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER", $arrval, $conf->global->STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER);
|
||||||
print "</form>\n";
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@ -317,14 +249,14 @@ if (!empty($conf->reception->enabled))
|
|||||||
{
|
{
|
||||||
print '<tr class="oddeven">';
|
print '<tr class="oddeven">';
|
||||||
print '<td width="60%">'.$langs->trans("StockOnReception").'</td>';
|
print '<td width="60%">'.$langs->trans("StockOnReception").'</td>';
|
||||||
print '<td width="160" align="right">';
|
print '<td align="center">';
|
||||||
|
|
||||||
print "<form method=\"post\" action=\"stock.php\">";
|
if ($conf->use_javascript_ajax) {
|
||||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
print ajax_constantonoff('STOCK_CALCULATE_ON_RECEPTION');
|
||||||
print "<input type=\"hidden\" name=\"action\" value=\"STOCK_CALCULATE_ON_RECEPTION\">";
|
} else {
|
||||||
print $form->selectyesno("STOCK_CALCULATE_ON_RECEPTION", $conf->global->STOCK_CALCULATE_ON_RECEPTION, 1, $disabled);
|
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
|
||||||
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'"'.$disabled.'>';
|
print $form->selectarray("STOCK_CALCULATE_ON_RECEPTION", $arrval, $conf->global->STOCK_CALCULATE_ON_RECEPTION);
|
||||||
print "</form>\n";
|
}
|
||||||
|
|
||||||
print "</td>\n</tr>\n";
|
print "</td>\n</tr>\n";
|
||||||
$found++;
|
$found++;
|
||||||
@ -332,15 +264,14 @@ if (!empty($conf->reception->enabled))
|
|||||||
|
|
||||||
print '<tr class="oddeven">';
|
print '<tr class="oddeven">';
|
||||||
print '<td width="60%">'.$langs->trans("StockOnReceptionOnClosing").'</td>';
|
print '<td width="60%">'.$langs->trans("StockOnReceptionOnClosing").'</td>';
|
||||||
print '<td width="160" align="right">';
|
print '<td align="center">';
|
||||||
|
|
||||||
print "<form method=\"post\" action=\"stock.php\">";
|
|
||||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
|
||||||
print "<input type=\"hidden\" name=\"action\" value=\"STOCK_CALCULATE_ON_RECEPTION_CLOSE\">";
|
|
||||||
print $form->selectyesno("STOCK_CALCULATE_ON_RECEPTION_CLOSE", $conf->global->STOCK_CALCULATE_ON_RECEPTION_CLOSE, 1, $disabled);
|
|
||||||
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'"'.$disabled.'>';
|
|
||||||
print "</form>\n";
|
|
||||||
|
|
||||||
|
if ($conf->use_javascript_ajax) {
|
||||||
|
print ajax_constantonoff('STOCK_CALCULATE_ON_RECEPTION_CLOSE');
|
||||||
|
} else {
|
||||||
|
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
|
||||||
|
print $form->selectarray("STOCK_CALCULATE_ON_RECEPTION_CLOSE", $arrval, $conf->global->STOCK_CALCULATE_ON_RECEPTION_CLOSE);
|
||||||
|
}
|
||||||
print "</td>\n</tr>\n";
|
print "</td>\n</tr>\n";
|
||||||
$found++;
|
$found++;
|
||||||
}
|
}
|
||||||
@ -348,15 +279,15 @@ else
|
|||||||
{
|
{
|
||||||
print '<tr class="oddeven">';
|
print '<tr class="oddeven">';
|
||||||
print '<td>'.$langs->trans("ReStockOnDispatchOrder").'</td>';
|
print '<td>'.$langs->trans("ReStockOnDispatchOrder").'</td>';
|
||||||
print '<td align="right">';
|
print '<td align="center">';
|
||||||
if (! empty($conf->fournisseur->enabled))
|
if (! empty($conf->fournisseur->enabled))
|
||||||
{
|
{
|
||||||
print "<form method=\"post\" action=\"stock.php\">";
|
if ($conf->use_javascript_ajax) {
|
||||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
print ajax_constantonoff('STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER');
|
||||||
print "<input type=\"hidden\" name=\"action\" value=\"STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER\">";
|
} else {
|
||||||
print $form->selectyesno("STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER",$conf->global->STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER,1,$disabled);
|
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
|
||||||
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'"'.$disabled.'>';
|
print $form->selectarray("STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER", $arrval, $conf->global->STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER);
|
||||||
print "</form>\n";
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@ -380,19 +311,19 @@ print '<br>';
|
|||||||
print '<table class="noborder" width="100%">';
|
print '<table class="noborder" width="100%">';
|
||||||
print '<tr class="liste_titre">';
|
print '<tr class="liste_titre">';
|
||||||
print "<td>".$langs->trans("RuleForStockAvailability")."</td>\n";
|
print "<td>".$langs->trans("RuleForStockAvailability")."</td>\n";
|
||||||
print " <td align=\"right\"> </td>\n";
|
print '<td align="center">'.$langs->trans("Status").'</td>'."\n";
|
||||||
print '</tr>'."\n";
|
print '</tr>'."\n";
|
||||||
|
|
||||||
|
|
||||||
print '<tr class="oddeven">';
|
print '<tr class="oddeven">';
|
||||||
print '<td>'.$langs->trans("WarehouseAllowNegativeTransfer").'</td>';
|
print '<td>'.$langs->trans("WarehouseAllowNegativeTransfer").'</td>';
|
||||||
print '<td align="right">';
|
print '<td align="center">';
|
||||||
print "<form method=\"post\" action=\"stock.php\">";
|
if ($conf->use_javascript_ajax) {
|
||||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
print ajax_constantonoff('STOCK_ALLOW_NEGATIVE_TRANSFER');
|
||||||
print "<input type=\"hidden\" name=\"action\" value=\"STOCK_ALLOW_NEGATIVE_TRANSFER\">";
|
} else {
|
||||||
print $form->selectyesno("STOCK_ALLOW_NEGATIVE_TRANSFER",$conf->global->STOCK_ALLOW_NEGATIVE_TRANSFER,1);
|
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
|
||||||
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'">';
|
print $form->selectarray("STOCK_ALLOW_NEGATIVE_TRANSFER", $arrval, $conf->global->STOCK_ALLOW_NEGATIVE_TRANSFER);
|
||||||
print '</form>';
|
}
|
||||||
print "</td>\n";
|
print "</td>\n";
|
||||||
print "</tr>\n";
|
print "</tr>\n";
|
||||||
|
|
||||||
@ -401,13 +332,13 @@ if($conf->invoice->enabled)
|
|||||||
{
|
{
|
||||||
print '<tr class="oddeven">';
|
print '<tr class="oddeven">';
|
||||||
print '<td>'.$langs->trans("StockMustBeEnoughForInvoice").'</td>';
|
print '<td>'.$langs->trans("StockMustBeEnoughForInvoice").'</td>';
|
||||||
print '<td align="right">';
|
print '<td align="center">';
|
||||||
print "<form method=\"post\" action=\"stock.php\">";
|
if ($conf->use_javascript_ajax) {
|
||||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
print ajax_constantonoff('STOCK_MUST_BE_ENOUGH_FOR_INVOICE');
|
||||||
print "<input type=\"hidden\" name=\"action\" value=\"STOCK_MUST_BE_ENOUGH_FOR_INVOICE\">";
|
} else {
|
||||||
print $form->selectyesno("STOCK_MUST_BE_ENOUGH_FOR_INVOICE",$conf->global->STOCK_MUST_BE_ENOUGH_FOR_INVOICE,1);
|
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
|
||||||
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'">';
|
print $form->selectarray("STOCK_MUST_BE_ENOUGH_FOR_INVOICE", $arrval, $conf->global->STOCK_MUST_BE_ENOUGH_FOR_INVOICE);
|
||||||
print '</form>';
|
}
|
||||||
print "</td>\n";
|
print "</td>\n";
|
||||||
print "</tr>\n";
|
print "</tr>\n";
|
||||||
}
|
}
|
||||||
@ -416,13 +347,13 @@ if($conf->order->enabled)
|
|||||||
{
|
{
|
||||||
print '<tr class="oddeven">';
|
print '<tr class="oddeven">';
|
||||||
print '<td>'.$langs->trans("StockMustBeEnoughForOrder").'</td>';
|
print '<td>'.$langs->trans("StockMustBeEnoughForOrder").'</td>';
|
||||||
print '<td align="right">';
|
print '<td align="center">';
|
||||||
print "<form method=\"post\" action=\"stock.php\">";
|
if ($conf->use_javascript_ajax) {
|
||||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
print ajax_constantonoff('STOCK_MUST_BE_ENOUGH_FOR_ORDER');
|
||||||
print "<input type=\"hidden\" name=\"action\" value=\"STOCK_MUST_BE_ENOUGH_FOR_ORDER\">";
|
} else {
|
||||||
print $form->selectyesno("STOCK_MUST_BE_ENOUGH_FOR_ORDER",$conf->global->STOCK_MUST_BE_ENOUGH_FOR_ORDER,1);
|
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
|
||||||
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'">';
|
print $form->selectarray("STOCK_MUST_BE_ENOUGH_FOR_ORDER", $arrval, $conf->global->STOCK_MUST_BE_ENOUGH_FOR_ORDER);
|
||||||
print '</form>';
|
}
|
||||||
print "</td>\n";
|
print "</td>\n";
|
||||||
print "</tr>\n";
|
print "</tr>\n";
|
||||||
}
|
}
|
||||||
@ -431,13 +362,13 @@ if($conf->expedition->enabled)
|
|||||||
{
|
{
|
||||||
print '<tr class="oddeven">';
|
print '<tr class="oddeven">';
|
||||||
print '<td>'.$langs->trans("StockMustBeEnoughForShipment").'</td>';
|
print '<td>'.$langs->trans("StockMustBeEnoughForShipment").'</td>';
|
||||||
print '<td align="right">';
|
print '<td align="center">';
|
||||||
print "<form method=\"post\" action=\"stock.php\">";
|
if ($conf->use_javascript_ajax) {
|
||||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
print ajax_constantonoff('STOCK_MUST_BE_ENOUGH_FOR_SHIPMENT');
|
||||||
print "<input type=\"hidden\" name=\"action\" value=\"STOCK_MUST_BE_ENOUGH_FOR_SHIPMENT\">";
|
} else {
|
||||||
print $form->selectyesno("STOCK_MUST_BE_ENOUGH_FOR_SHIPMENT",$conf->global->STOCK_MUST_BE_ENOUGH_FOR_SHIPMENT,1);
|
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
|
||||||
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'">';
|
print $form->selectarray("STOCK_MUST_BE_ENOUGH_FOR_SHIPMENT", $arrval, $conf->global->STOCK_MUST_BE_ENOUGH_FOR_SHIPMENT);
|
||||||
print '</form>';
|
}
|
||||||
print "</td>\n";
|
print "</td>\n";
|
||||||
print "</tr>\n";
|
print "</tr>\n";
|
||||||
}
|
}
|
||||||
@ -455,18 +386,18 @@ if ($virtualdiffersfromphysical)
|
|||||||
print '<table class="noborder" width="100%">';
|
print '<table class="noborder" width="100%">';
|
||||||
print '<tr class="liste_titre">';
|
print '<tr class="liste_titre">';
|
||||||
print "<td>".$langs->trans("RuleForStockReplenishment")." ".img_help('help',$langs->trans("VirtualDiffersFromPhysical"))."</td>\n";
|
print "<td>".$langs->trans("RuleForStockReplenishment")." ".img_help('help',$langs->trans("VirtualDiffersFromPhysical"))."</td>\n";
|
||||||
print " <td align=\"right\"> </td>\n";
|
print '<td align="center">'.$langs->trans("Status").'</td>'."\n";
|
||||||
print '</tr>'."\n";
|
print '</tr>'."\n";
|
||||||
|
|
||||||
print '<tr class="oddeven">';
|
print '<tr class="oddeven">';
|
||||||
print '<td>'.$langs->trans("UseVirtualStockByDefault").'</td>';
|
print '<td>'.$langs->trans("UseVirtualStockByDefault").'</td>';
|
||||||
print '<td align="right">';
|
print '<td align="center">';
|
||||||
print "<form method=\"post\" action=\"stock.php\">";
|
if ($conf->use_javascript_ajax) {
|
||||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
print ajax_constantonoff('STOCK_USE_VIRTUAL_STOCK');
|
||||||
print "<input type=\"hidden\" name=\"action\" value=\"STOCK_USE_VIRTUAL_STOCK\">";
|
} else {
|
||||||
print $form->selectyesno("STOCK_USE_VIRTUAL_STOCK",$conf->global->STOCK_USE_VIRTUAL_STOCK,1);
|
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
|
||||||
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'">';
|
print $form->selectarray("STOCK_USE_VIRTUAL_STOCK", $arrval, $conf->global->STOCK_USE_VIRTUAL_STOCK);
|
||||||
print '</form>';
|
}
|
||||||
print "</td>\n";
|
print "</td>\n";
|
||||||
print "</tr>\n";
|
print "</tr>\n";
|
||||||
print '</table>';
|
print '</table>';
|
||||||
@ -478,18 +409,18 @@ print '<table class="noborder" width="100%">';
|
|||||||
|
|
||||||
print '<tr class="liste_titre">';
|
print '<tr class="liste_titre">';
|
||||||
print "<td>".$langs->trans("Other")."</td>\n";
|
print "<td>".$langs->trans("Other")."</td>\n";
|
||||||
print " <td align=\"right\"> </td>\n";
|
print '<td align="center">'.$langs->trans("Status").'</td>'."\n";
|
||||||
print '</tr>'."\n";
|
print '</tr>'."\n";
|
||||||
|
|
||||||
print '<tr class="oddeven">';
|
print '<tr class="oddeven">';
|
||||||
print '<td>'.$langs->trans("UserWarehouseAutoCreate").'</td>';
|
print '<td>'.$langs->trans("UserWarehouseAutoCreate").'</td>';
|
||||||
print '<td align="right">';
|
print '<td align="center">';
|
||||||
print "<form method=\"post\" action=\"stock.php\">";
|
if ($conf->use_javascript_ajax) {
|
||||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
print ajax_constantonoff('STOCK_USERSTOCK_AUTOCREATE');
|
||||||
print "<input type=\"hidden\" name=\"action\" value=\"STOCK_USERSTOCK_AUTOCREATE\">";
|
} else {
|
||||||
print $form->selectyesno("STOCK_USERSTOCK_AUTOCREATE",$conf->global->STOCK_USERSTOCK_AUTOCREATE,1);
|
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
|
||||||
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'">';
|
print $form->selectarray("STOCK_USERSTOCK_AUTOCREATE", $arrval, $conf->global->STOCK_USERSTOCK_AUTOCREATE);
|
||||||
print '</form>';
|
}
|
||||||
print "</td>\n";
|
print "</td>\n";
|
||||||
print "</tr>\n";
|
print "</tr>\n";
|
||||||
|
|
||||||
@ -497,25 +428,25 @@ print '<tr class="oddeven">';
|
|||||||
print '<td>';
|
print '<td>';
|
||||||
print $form->textwithpicto($langs->trans("StockSupportServices"), $langs->trans("StockSupportServicesDesc"));
|
print $form->textwithpicto($langs->trans("StockSupportServices"), $langs->trans("StockSupportServicesDesc"));
|
||||||
print '</td>';
|
print '</td>';
|
||||||
print '<td align="right">';
|
print '<td align="center">';
|
||||||
print "<form method=\"post\" action=\"stock.php\">";
|
if ($conf->use_javascript_ajax) {
|
||||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
print ajax_constantonoff('STOCK_SUPPORTS_SERVICES');
|
||||||
print "<input type=\"hidden\" name=\"action\" value=\"STOCK_SUPPORTS_SERVICES\">";
|
} else {
|
||||||
print $form->selectyesno("STOCK_SUPPORTS_SERVICES",$conf->global->STOCK_SUPPORTS_SERVICES,1);
|
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
|
||||||
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'">';
|
print $form->selectarray("STOCK_SUPPORTS_SERVICES", $arrval, $conf->global->STOCK_SUPPORTS_SERVICES);
|
||||||
print '</form>';
|
}
|
||||||
print "</td>\n";
|
print "</td>\n";
|
||||||
print "</tr>\n";
|
print "</tr>\n";
|
||||||
|
|
||||||
print '<tr class="oddeven">';
|
print '<tr class="oddeven">';
|
||||||
print '<td>'.$langs->trans("AllowAddLimitStockByWarehouse").'</td>';
|
print '<td>'.$langs->trans("AllowAddLimitStockByWarehouse").'</td>';
|
||||||
print '<td align="right">';
|
print '<td align="center">';
|
||||||
print "<form method=\"post\" action=\"stock.php\">";
|
if ($conf->use_javascript_ajax) {
|
||||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
print ajax_constantonoff('STOCK_ALLOW_ADD_LIMIT_STOCK_BY_WAREHOUSE');
|
||||||
print "<input type=\"hidden\" name=\"action\" value=\"STOCK_ALLOW_ADD_LIMIT_STOCK_BY_WAREHOUSE\">";
|
} else {
|
||||||
print $form->selectyesno("STOCK_ALLOW_ADD_LIMIT_STOCK_BY_WAREHOUSE",$conf->global->STOCK_ALLOW_ADD_LIMIT_STOCK_BY_WAREHOUSE,1);
|
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
|
||||||
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'">';
|
print $form->selectarray("STOCK_ALLOW_ADD_LIMIT_STOCK_BY_WAREHOUSE", $arrval, $conf->global->STOCK_ALLOW_ADD_LIMIT_STOCK_BY_WAREHOUSE);
|
||||||
print '</form>';
|
}
|
||||||
print "</td>\n";
|
print "</td>\n";
|
||||||
print "</tr>\n";
|
print "</tr>\n";
|
||||||
|
|
||||||
@ -524,12 +455,12 @@ if (! empty($conf->fournisseur->enabled) && !empty($conf->global->STOCK_CALCULAT
|
|||||||
print '<tr class="oddeven">';
|
print '<tr class="oddeven">';
|
||||||
print '<td>'.$langs->trans("UseDispatchStatus").'</td>';
|
print '<td>'.$langs->trans("UseDispatchStatus").'</td>';
|
||||||
print '<td align="right">';
|
print '<td align="right">';
|
||||||
print "<form method=\"post\" action=\"stock.php\">";
|
if ($conf->use_javascript_ajax) {
|
||||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
print ajax_constantonoff('SUPPLIER_ORDER_USE_DISPATCH_STATUS');
|
||||||
print "<input type=\"hidden\" name=\"action\" value=\"SUPPLIER_ORDER_USE_DISPATCH_STATUS\">";
|
} else {
|
||||||
print $form->selectyesno("SUPPLIER_ORDER_USE_DISPATCH_STATUS",$conf->global->SUPPLIER_ORDER_USE_DISPATCH_STATUS,1);
|
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
|
||||||
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'">';
|
print $form->selectarray("SUPPLIER_ORDER_USE_DISPATCH_STATUS", $arrval, $conf->global->SUPPLIER_ORDER_USE_DISPATCH_STATUS);
|
||||||
print "</form>\n";
|
}
|
||||||
print "</td>\n</tr>\n";
|
print "</td>\n</tr>\n";
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -541,46 +472,43 @@ if ($conf->global->MAIN_FEATURES_LEVEL >= 2)
|
|||||||
print '<table class="noborder" width="100%">';
|
print '<table class="noborder" width="100%">';
|
||||||
print '<tr class="liste_titre">';
|
print '<tr class="liste_titre">';
|
||||||
print '<td>'.$langs->trans("Inventory").'</td>'."\n";
|
print '<td>'.$langs->trans("Inventory").'</td>'."\n";
|
||||||
print '<td align="center" width="20"> </td>';
|
print '<td align="center">'.$langs->trans("Status").'</td>'."\n";
|
||||||
print '<td align="center"> </td>'."\n";
|
print '</tr>'."\n";
|
||||||
|
|
||||||
// Example with a yes / no select
|
// Example with a yes / no select
|
||||||
print '<tr class="oddeven">';
|
print '<tr class="oddeven">';
|
||||||
print '<td>'.$langs->trans("INVENTORY_DISABLE_VIRTUAL").'</td>';
|
print '<td>'.$langs->trans("INVENTORY_DISABLE_VIRTUAL").'</td>';
|
||||||
print '<td align="center" width="20"> </td>';
|
print '<td align="center">';
|
||||||
print '<td align="right" width="300">';
|
if ($conf->use_javascript_ajax) {
|
||||||
print '<form method="POST" action="'.$_SERVER['PHP_SELF'].'">';
|
print ajax_constantonoff('INVENTORY_DISABLE_VIRTUAL');
|
||||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
} else {
|
||||||
print '<input type="hidden" name="action" value="set_INVENTORY_DISABLE_VIRTUAL">';
|
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
|
||||||
print $form->selectyesno("INVENTORY_DISABLE_VIRTUAL",$conf->global->INVENTORY_DISABLE_VIRTUAL,1);
|
print $form->selectarray("INVENTORY_DISABLE_VIRTUAL", $arrval, $conf->global->INVENTORY_DISABLE_VIRTUAL);
|
||||||
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'">';
|
}
|
||||||
print '</form>';
|
|
||||||
print '</td></tr>';
|
print '</td></tr>';
|
||||||
|
|
||||||
// Example with a yes / no select
|
// Example with a yes / no select
|
||||||
print '<tr class="oddeven">';
|
print '<tr class="oddeven">';
|
||||||
print '<td>'.$langs->trans("INVENTORY_USE_MIN_PA_IF_NO_LAST_PA").'</td>';
|
print '<td>'.$langs->trans("INVENTORY_USE_MIN_PA_IF_NO_LAST_PA").'</td>';
|
||||||
print '<td align="center" width="20"> </td>';
|
print '<td align="center">';
|
||||||
print '<td align="right" width="300">';
|
if ($conf->use_javascript_ajax) {
|
||||||
print '<form method="POST" action="'.$_SERVER['PHP_SELF'].'">';
|
print ajax_constantonoff('INVENTORY_USE_MIN_PA_IF_NO_LAST_PA');
|
||||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
} else {
|
||||||
print '<input type="hidden" name="action" value="set_INVENTORY_USE_MIN_PA_IF_NO_LAST_PA">';
|
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
|
||||||
print $form->selectyesno("INVENTORY_USE_MIN_PA_IF_NO_LAST_PA",$conf->global->INVENTORY_USE_MIN_PA_IF_NO_LAST_PA,1);
|
print $form->selectarray("INVENTORY_USE_MIN_PA_IF_NO_LAST_PA", $arrval, $conf->global->INVENTORY_USE_MIN_PA_IF_NO_LAST_PA);
|
||||||
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'">';
|
}
|
||||||
print '</form>';
|
|
||||||
print '</td></tr>';
|
print '</td></tr>';
|
||||||
|
|
||||||
// Example with a yes / no select
|
// Example with a yes / no select
|
||||||
print '<tr class="oddeven">';
|
print '<tr class="oddeven">';
|
||||||
print '<td>'.$langs->trans("INVENTORY_USE_INVENTORY_DATE_FROM_DATEMVT").'</td>';
|
print '<td>'.$langs->trans("INVENTORY_USE_INVENTORY_DATE_FROM_DATEMVT").'</td>';
|
||||||
print '<td align="center" width="20"> </td>';
|
print '<td align="center">';
|
||||||
print '<td align="right" width="300">';
|
if ($conf->use_javascript_ajax) {
|
||||||
print '<form method="POST" action="'.$_SERVER['PHP_SELF'].'">';
|
print ajax_constantonoff('INVENTORY_USE_INVENTORY_DATE_FROM_DATEMVT');
|
||||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
} else {
|
||||||
print '<input type="hidden" name="action" value="set_INVENTORY_USE_INVENTORY_DATE_FROM_DATEMVT">';
|
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
|
||||||
print $form->selectyesno("INVENTORY_USE_INVENTORY_DATE_FROM_DATEMVT",$conf->global->INVENTORY_USE_INVENTORY_DATE_FROM_DATEMVT,1);
|
print $form->selectarray("INVENTORY_USE_INVENTORY_DATE_FROM_DATEMVT", $arrval, $conf->global->INVENTORY_USE_INVENTORY_DATE_FROM_DATEMVT);
|
||||||
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'">';
|
}
|
||||||
print '</form>';
|
|
||||||
print '</td></tr>';
|
print '</td></tr>';
|
||||||
|
|
||||||
print '</table>';
|
print '</table>';
|
||||||
|
|||||||
@ -253,7 +253,7 @@ dol_fiche_end();
|
|||||||
* Projects Numbering model
|
* Projects Numbering model
|
||||||
*/
|
*/
|
||||||
|
|
||||||
print_titre($langs->trans("TicketNumberingModules"));
|
print load_fiche_titre($langs->trans("TicketNumberingModules"));
|
||||||
|
|
||||||
print '<table class="noborder" width="100%">';
|
print '<table class="noborder" width="100%">';
|
||||||
print '<tr class="liste_titre">';
|
print '<tr class="liste_titre">';
|
||||||
@ -353,7 +353,7 @@ if (!$conf->use_javascript_ajax) {
|
|||||||
print '<input type="hidden" name="token" value="' . $_SESSION['newtoken'] . '">';
|
print '<input type="hidden" name="token" value="' . $_SESSION['newtoken'] . '">';
|
||||||
print '<input type="hidden" name="action" value="setvarother">';
|
print '<input type="hidden" name="action" value="setvarother">';
|
||||||
}
|
}
|
||||||
print_titre($langs->trans("TicketParamPublicInterface"));
|
print load_fiche_titre($langs->trans("TicketParamPublicInterface"));
|
||||||
|
|
||||||
print '<table class="noborder" width="100%">';
|
print '<table class="noborder" width="100%">';
|
||||||
|
|
||||||
@ -422,7 +422,7 @@ print '</tr>';
|
|||||||
|
|
||||||
print '</table><br>';
|
print '</table><br>';
|
||||||
|
|
||||||
print_titre($langs->trans("TicketParams"));
|
print load_fiche_titre($langs->trans("TicketParams"));
|
||||||
print '<table class="noborder" width="100%">';
|
print '<table class="noborder" width="100%">';
|
||||||
|
|
||||||
// Activate email notifications
|
// Activate email notifications
|
||||||
@ -515,7 +515,7 @@ if (!$conf->use_javascript_ajax) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Admin var of module
|
// Admin var of module
|
||||||
print_titre($langs->trans("TicketParamMail"));
|
print load_fiche_titre($langs->trans("TicketParamMail"));
|
||||||
|
|
||||||
print '<table class="noborder" width="100%">';
|
print '<table class="noborder" width="100%">';
|
||||||
|
|
||||||
|
|||||||
@ -92,7 +92,7 @@ if ($action != 'create' && $action != 'edit') {
|
|||||||
|
|
||||||
if ($action == 'create') {
|
if ($action == 'create') {
|
||||||
print "<br>";
|
print "<br>";
|
||||||
print_titre($langs->trans('NewAttribute'));
|
print load_fiche_titre($langs->trans('NewAttribute'));
|
||||||
|
|
||||||
include DOL_DOCUMENT_ROOT . '/core/tpl/admin_extrafields_add.tpl.php';
|
include DOL_DOCUMENT_ROOT . '/core/tpl/admin_extrafields_add.tpl.php';
|
||||||
}
|
}
|
||||||
@ -104,7 +104,7 @@ if ($action == 'create') {
|
|||||||
/* ************************************************************************** */
|
/* ************************************************************************** */
|
||||||
if ($action == 'edit' && !empty($attrname)) {
|
if ($action == 'edit' && !empty($attrname)) {
|
||||||
print "<br>";
|
print "<br>";
|
||||||
print_titre($langs->trans("FieldEdition", $attrname));
|
print load_fiche_titre($langs->trans("FieldEdition", $attrname));
|
||||||
|
|
||||||
include DOL_DOCUMENT_ROOT . '/core/tpl/admin_extrafields_edit.tpl.php';
|
include DOL_DOCUMENT_ROOT . '/core/tpl/admin_extrafields_edit.tpl.php';
|
||||||
}
|
}
|
||||||
|
|||||||
@ -463,7 +463,7 @@ if (! empty($conf->salaries->enabled) && ! empty($user->rights->salaries->read))
|
|||||||
|
|
||||||
print "<br>";
|
print "<br>";
|
||||||
|
|
||||||
print_fiche_titre( $langs->trans("SalariesPayments").($year?' ('.$langs->trans("Year").' '.$year.')':''), '', '');
|
print load_fiche_titre( $langs->trans("SalariesPayments").($year?' ('.$langs->trans("Year").' '.$year.')':''), '', '');
|
||||||
|
|
||||||
$sql = "SELECT s.rowid, s.amount, s.label, s.datep as datep, s.datev as datev, s.datesp, s.dateep, s.salary, s.fk_bank, u.salary as current_salary,";
|
$sql = "SELECT s.rowid, s.amount, s.label, s.datep as datep, s.datev as datev, s.datesp, s.dateep, s.salary, s.fk_bank, u.salary as current_salary,";
|
||||||
$sql.= " pct.code as payment_code,";
|
$sql.= " pct.code as payment_code,";
|
||||||
|
|||||||
@ -405,7 +405,7 @@ if (! empty($conf->salaries->enabled) && ! empty($user->rights->salaries->read))
|
|||||||
|
|
||||||
print "<br>";
|
print "<br>";
|
||||||
|
|
||||||
print_fiche_titre($langs->trans("SalariesPayments").($year?' ('.$langs->trans("Year").' '.$year.')':''), '', '');
|
print load_fiche_titre($langs->trans("SalariesPayments").($year?' ('.$langs->trans("Year").' '.$year.')':''), '', '');
|
||||||
|
|
||||||
$sql = "SELECT s.rowid, s.amount, s.label, s.datep as datep, s.datev as datev, s.datesp, s.dateep, s.salary, u.salary as current_salary";
|
$sql = "SELECT s.rowid, s.amount, s.label, s.datep as datep, s.datev as datev, s.datesp, s.dateep, s.salary, u.salary as current_salary";
|
||||||
$sql.= " FROM ".MAIN_DB_PREFIX."payment_salary as s, ".MAIN_DB_PREFIX."user as u";
|
$sql.= " FROM ".MAIN_DB_PREFIX."payment_salary as s, ".MAIN_DB_PREFIX."user as u";
|
||||||
|
|||||||
@ -682,7 +682,7 @@ else
|
|||||||
// Jabber
|
// Jabber
|
||||||
if (! empty($conf->global->SOCIALNETWORKS_JABBER))
|
if (! empty($conf->global->SOCIALNETWORKS_JABBER))
|
||||||
{
|
{
|
||||||
print '<tr><td><label for="skype">'.fieldLabel('Jabber','jabberid').'</label></td>';
|
print '<tr><td><label for="skype">'.$form->editfieldkey('Jabber','jabberid', '', $object, 0).'</label></td>';
|
||||||
print '<td colspan="3"><input type="text" name="jabberid" id="jabberid" class="minwidth100" maxlength="80" value="'.dol_escape_htmltag(GETPOSTISSET("jabberid")?GETPOST("jabberid",'alpha'):$object->jabberid).'"></td></tr>';
|
print '<td colspan="3"><input type="text" name="jabberid" id="jabberid" class="minwidth100" maxlength="80" value="'.dol_escape_htmltag(GETPOSTISSET("jabberid")?GETPOST("jabberid",'alpha'):$object->jabberid).'"></td></tr>';
|
||||||
}
|
}
|
||||||
// Skype
|
// Skype
|
||||||
@ -968,7 +968,7 @@ else
|
|||||||
// Jabber ID
|
// Jabber ID
|
||||||
if (! empty($conf->global->SOCIALNETWORKS_JABBER))
|
if (! empty($conf->global->SOCIALNETWORKS_JABBER))
|
||||||
{
|
{
|
||||||
print '<tr><td><label for="jabberid">'.fieldLabel('Jabber','jabberid').'</label></td>';
|
print '<tr><td><label for="jabberid">'.$form->editfieldkey('Jabber','jabberid', '', $object, 0).'</label></td>';
|
||||||
print '<td><input type="text" name="jabberid" id="jabberid" class="minwidth100" maxlength="80" value="'.dol_escape_htmltag(GETPOSTISSET("jabberid")?GETPOST("jabberid",'alpha'):$object->jabberid).'"></td></tr>';
|
print '<td><input type="text" name="jabberid" id="jabberid" class="minwidth100" maxlength="80" value="'.dol_escape_htmltag(GETPOSTISSET("jabberid")?GETPOST("jabberid",'alpha'):$object->jabberid).'"></td></tr>';
|
||||||
}
|
}
|
||||||
// Skype
|
// Skype
|
||||||
|
|||||||
@ -39,48 +39,6 @@
|
|||||||
include_once DOL_DOCUMENT_ROOT .'/core/lib/json.lib.php';
|
include_once DOL_DOCUMENT_ROOT .'/core/lib/json.lib.php';
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Function to return value of a static property when class
|
|
||||||
* name is dynamically defined (not hard coded).
|
|
||||||
* This is because $myclass::$myvar works from PHP 5.3.0+ only
|
|
||||||
*
|
|
||||||
* @param string $class Class name
|
|
||||||
* @param string $member Name of property
|
|
||||||
* @return mixed Return value of static property
|
|
||||||
* @deprecated Dolibarr now requires 5.3.0+, use $class::$property syntax
|
|
||||||
* @see https://php.net/manual/language.oop5.static.php
|
|
||||||
*/
|
|
||||||
function getStaticMember($class, $member)
|
|
||||||
{
|
|
||||||
dol_syslog(__FUNCTION__ . " is deprecated", LOG_WARNING);
|
|
||||||
|
|
||||||
// This part is deprecated. Uncomment if for php 5.2.*, and comment next isset class::member
|
|
||||||
/*if (version_compare(phpversion(), '5.3.0', '<'))
|
|
||||||
{
|
|
||||||
if (is_object($class)) $class = get_class($class);
|
|
||||||
$classObj = new ReflectionClass($class);
|
|
||||||
$result = null;
|
|
||||||
|
|
||||||
$found=0;
|
|
||||||
foreach($classObj->getStaticProperties() as $prop => $value)
|
|
||||||
{
|
|
||||||
if ($prop == $member)
|
|
||||||
{
|
|
||||||
$result = $value;
|
|
||||||
$found++;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if ($found) return $result;
|
|
||||||
}*/
|
|
||||||
|
|
||||||
if (isset($class::$member)) return $class::$member;
|
|
||||||
dol_print_error('','Try to get a static member "'.$member.'" in class "'.$class.'" that does not exists or is not static.');
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Return a DoliDB instance (database handler).
|
* Return a DoliDB instance (database handler).
|
||||||
*
|
*
|
||||||
|
|||||||
@ -47,7 +47,7 @@ print '<script type="text/javascript" language="javascript">
|
|||||||
</script>';
|
</script>';
|
||||||
|
|
||||||
|
|
||||||
print_fiche_titre($langs->trans("AdvTgtTitle"));
|
print load_fiche_titre($langs->trans("AdvTgtTitle"));
|
||||||
|
|
||||||
print '<div class="tabBar">' . "\n";
|
print '<div class="tabBar">' . "\n";
|
||||||
print '<form name="find_customer" id="find_customer" action="' . $_SERVER['PHP_SELF'] . '?id=' . $id . '" method="POST">' . "\n";
|
print '<form name="find_customer" id="find_customer" action="' . $_SERVER['PHP_SELF'] . '?id=' . $id . '" method="POST">' . "\n";
|
||||||
@ -520,7 +520,7 @@ print '<script type="text/javascript" language="javascript">
|
|||||||
|
|
||||||
print '<form action="' . $_SERVER['PHP_SELF'] . '?action=clear&id=' . $object->id . '" method="POST">';
|
print '<form action="' . $_SERVER['PHP_SELF'] . '?action=clear&id=' . $object->id . '" method="POST">';
|
||||||
print '<input type="hidden" name="token" value="' . $_SESSION['newtoken'] . '">';
|
print '<input type="hidden" name="token" value="' . $_SESSION['newtoken'] . '">';
|
||||||
print_titre($langs->trans("ToClearAllRecipientsClickHere"));
|
print load_fiche_titre($langs->trans("ToClearAllRecipientsClickHere"));
|
||||||
print '<table class="noborder" width="100%">';
|
print '<table class="noborder" width="100%">';
|
||||||
print '<tr class="liste_titre">';
|
print '<tr class="liste_titre">';
|
||||||
print '<td class="liste_titre" align="right"><input type="submit" class="button" value="' . $langs->trans("TargetsReset") . '"></td>';
|
print '<td class="liste_titre" align="right"><input type="submit" class="button" value="' . $langs->trans("TargetsReset") . '"></td>';
|
||||||
|
|||||||
@ -54,7 +54,7 @@ $listhalfday=array('morning'=>$langs->trans("Morning"),"afternoon"=>$langs->tran
|
|||||||
|
|
||||||
llxHeader('', $langs->trans('CPTitreMenu'));
|
llxHeader('', $langs->trans('CPTitreMenu'));
|
||||||
|
|
||||||
print_fiche_titre($langs->trans('MenuReportMonth'));
|
print load_fiche_titre($langs->trans('MenuReportMonth'));
|
||||||
|
|
||||||
$html = new Form($db);
|
$html = new Form($db);
|
||||||
$formother = new FormOther($db);
|
$formother = new FormOther($db);
|
||||||
|
|||||||
@ -44,3 +44,5 @@ OrderPrinters=Order printers
|
|||||||
SearchProduct=Search product
|
SearchProduct=Search product
|
||||||
Receipt=Receipt
|
Receipt=Receipt
|
||||||
AmountAtEndOfPeriod=Amount at end of period (day, month or year)
|
AmountAtEndOfPeriod=Amount at end of period (day, month or year)
|
||||||
|
Header=Header
|
||||||
|
Footer=Footer
|
||||||
|
|||||||
@ -43,3 +43,5 @@ TakeposConnectorNecesary='Conector TakePOS' requerido
|
|||||||
OrderPrinters=Impresoras de pedidos
|
OrderPrinters=Impresoras de pedidos
|
||||||
SearchProduct=Buscar producto
|
SearchProduct=Buscar producto
|
||||||
Receipt=Comprobante
|
Receipt=Comprobante
|
||||||
|
Header=Cabecera
|
||||||
|
Footer=Pie de página
|
||||||
|
|||||||
@ -43,3 +43,5 @@ TakeposConnectorNecesary='Connecteur TakePOS' requis
|
|||||||
OrderPrinters=Commande imprimantes
|
OrderPrinters=Commande imprimantes
|
||||||
SearchProduct=Rechercher un produit
|
SearchProduct=Rechercher un produit
|
||||||
Receipt=Le reçu
|
Receipt=Le reçu
|
||||||
|
Header=Entête
|
||||||
|
Footer=Bas de page
|
||||||
|
|||||||
@ -143,7 +143,7 @@ $title = $langs->trans("Margins");
|
|||||||
|
|
||||||
llxHeader('', $title);
|
llxHeader('', $title);
|
||||||
|
|
||||||
// print_fiche_titre($text);
|
// print load_fiche_titre($text);
|
||||||
|
|
||||||
$param='';
|
$param='';
|
||||||
if (! empty($contextpage) && $contextpage != $_SERVER["PHP_SELF"]) $param.='&contextpage='.$contextpage;
|
if (! empty($contextpage) && $contextpage != $_SERVER["PHP_SELF"]) $param.='&contextpage='.$contextpage;
|
||||||
|
|||||||
@ -949,7 +949,7 @@ if (! $variants) {
|
|||||||
|
|
||||||
if (!empty($conf->global->STOCK_ALLOW_ADD_LIMIT_STOCK_BY_WAREHOUSE)) {
|
if (!empty($conf->global->STOCK_ALLOW_ADD_LIMIT_STOCK_BY_WAREHOUSE)) {
|
||||||
print '<br><br>';
|
print '<br><br>';
|
||||||
print_titre($langs->trans('AddNewProductStockWarehouse'));
|
print load_fiche_titre($langs->trans('AddNewProductStockWarehouse'));
|
||||||
|
|
||||||
if (!empty($user->rights->produit->creer)) {
|
if (!empty($user->rights->produit->creer)) {
|
||||||
print '<form action="' . $_SERVER["PHP_SELF"] . '" method="POST">';
|
print '<form action="' . $_SERVER["PHP_SELF"] . '" method="POST">';
|
||||||
|
|||||||
@ -25,6 +25,7 @@
|
|||||||
require '../../main.inc.php'; // Load $user and permissions
|
require '../../main.inc.php'; // Load $user and permissions
|
||||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/admin.lib.php';
|
require_once DOL_DOCUMENT_ROOT.'/core/lib/admin.lib.php';
|
||||||
require_once DOL_DOCUMENT_ROOT.'/product/class/html.formproduct.class.php';
|
require_once DOL_DOCUMENT_ROOT.'/product/class/html.formproduct.class.php';
|
||||||
|
require_once DOL_DOCUMENT_ROOT.'/core/lib/pdf.lib.php';
|
||||||
|
|
||||||
// If socid provided by ajax company selector
|
// If socid provided by ajax company selector
|
||||||
if (! empty($_REQUEST['CASHDESK_ID_THIRDPARTY_id']))
|
if (! empty($_REQUEST['CASHDESK_ID_THIRDPARTY_id']))
|
||||||
@ -59,6 +60,8 @@ if (GETPOST('action','alpha') == 'set')
|
|||||||
$res = dolibarr_set_const($db,"TAKEPOS_BAR_RESTAURANT", GETPOST('TAKEPOS_BAR_RESTAURANT','alpha'),'chaine',0,'',$conf->entity);
|
$res = dolibarr_set_const($db,"TAKEPOS_BAR_RESTAURANT", GETPOST('TAKEPOS_BAR_RESTAURANT','alpha'),'chaine',0,'',$conf->entity);
|
||||||
$res = dolibarr_set_const($db,"TAKEPOS_PRINT_SERVER", GETPOST('TAKEPOS_PRINT_SERVER','alpha'),'chaine',0,'',$conf->entity);
|
$res = dolibarr_set_const($db,"TAKEPOS_PRINT_SERVER", GETPOST('TAKEPOS_PRINT_SERVER','alpha'),'chaine',0,'',$conf->entity);
|
||||||
$res = dolibarr_set_const($db,"TAKEPOS_ORDER_PRINTERS", GETPOST('TAKEPOS_ORDER_PRINTERS','alpha'),'chaine',0,'',$conf->entity);
|
$res = dolibarr_set_const($db,"TAKEPOS_ORDER_PRINTERS", GETPOST('TAKEPOS_ORDER_PRINTERS','alpha'),'chaine',0,'',$conf->entity);
|
||||||
|
$res = dolibarr_set_const($db,"TAKEPOS_HEADER", GETPOST('TAKEPOS_HEADER','alpha'),'chaine',0,'',$conf->entity);
|
||||||
|
$res = dolibarr_set_const($db,"TAKEPOS_FOOTER", GETPOST('TAKEPOS_FOOTER','alpha'),'chaine',0,'',$conf->entity);
|
||||||
|
|
||||||
dol_syslog("admin/cashdesk: level ".GETPOST('level','alpha'));
|
dol_syslog("admin/cashdesk: level ".GETPOST('level','alpha'));
|
||||||
|
|
||||||
@ -140,6 +143,44 @@ if ($conf->global->TAKEPOS_BAR_RESTAURANT && $conf->global->TAKEPOSCONNECTOR){
|
|||||||
print '</td></tr>';
|
print '</td></tr>';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$substitutionarray=pdf_getSubstitutionArray($langs, null, null, 2);
|
||||||
|
$substitutionarray['__(AnyTranslationKey)__']=$langs->trans("Translation");
|
||||||
|
$htmltext = '<i>'.$langs->trans("AvailableVariables").':<br>';
|
||||||
|
foreach($substitutionarray as $key => $val) $htmltext.=$key.'<br>';
|
||||||
|
$htmltext.='</i>';
|
||||||
|
|
||||||
|
print '<tr class="oddeven"><td>';
|
||||||
|
print $form->textwithpicto($langs->trans("FreeLegalTextOnInvoices")." - ".$langs->trans("Header"), $htmltext, 1, 'help', '', 0, 2, 'freetexttooltip').'<br>';
|
||||||
|
print '</td><td>';
|
||||||
|
$variablename='TAKEPOS_HEADER';
|
||||||
|
if (empty($conf->global->PDF_ALLOW_HTML_FOR_FREE_TEXT))
|
||||||
|
{
|
||||||
|
print '<textarea name="'.$variablename.'" class="flat" cols="120">'.$conf->global->$variablename.'</textarea>';
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
include_once DOL_DOCUMENT_ROOT.'/core/class/doleditor.class.php';
|
||||||
|
$doleditor=new DolEditor($variablename, $conf->global->$variablename,'',80,'dolibarr_notes');
|
||||||
|
print $doleditor->Create();
|
||||||
|
}
|
||||||
|
print "</td></tr>\n";
|
||||||
|
|
||||||
|
print '<tr class="oddeven"><td>';
|
||||||
|
print $form->textwithpicto($langs->trans("FreeLegalTextOnInvoices")." - ".$langs->trans("Footer"), $htmltext, 1, 'help', '', 0, 2, 'freetexttooltip').'<br>';
|
||||||
|
print '</td><td>';
|
||||||
|
$variablename='TAKEPOS_FOOTER';
|
||||||
|
if (empty($conf->global->PDF_ALLOW_HTML_FOR_FREE_TEXT))
|
||||||
|
{
|
||||||
|
print '<textarea name="'.$variablename.'" class="flat" cols="120">'.$conf->global->$variablename.'</textarea>';
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
include_once DOL_DOCUMENT_ROOT.'/core/class/doleditor.class.php';
|
||||||
|
$doleditor=new DolEditor($variablename, $conf->global->$variablename,'',80,'dolibarr_notes');
|
||||||
|
print $doleditor->Create();
|
||||||
|
}
|
||||||
|
print "</td></tr>\n";
|
||||||
|
|
||||||
print '</table>';
|
print '</table>';
|
||||||
|
|
||||||
print '<br>';
|
print '<br>';
|
||||||
|
|||||||
@ -51,9 +51,14 @@ $object->fetch($facid);
|
|||||||
</center>
|
</center>
|
||||||
<br>
|
<br>
|
||||||
<p align="left">
|
<p align="left">
|
||||||
<?php print dol_nl2br(dol_format_address($mysoc)).'<br>'.$langs->trans("Phone").': '.$mysoc->phone;
|
<?php
|
||||||
|
$substitutionarray=getCommonSubstitutionArray($langs);
|
||||||
|
if (! empty($conf->global->TAKEPOS_HEADER))
|
||||||
|
{
|
||||||
|
$newfreetext=make_substitutions($conf->global->TAKEPOS_HEADER,$substitutionarray);
|
||||||
|
echo $newfreetext;
|
||||||
|
}
|
||||||
?>
|
?>
|
||||||
|
|
||||||
</p>
|
</p>
|
||||||
<p align="right">
|
<p align="right">
|
||||||
<?php
|
<?php
|
||||||
@ -107,9 +112,12 @@ print $object->ref;
|
|||||||
<br>
|
<br>
|
||||||
<br>
|
<br>
|
||||||
<?php
|
<?php
|
||||||
echo $langs->trans("Cashier: ");
|
$substitutionarray=getCommonSubstitutionArray($langs);
|
||||||
echo $user->firstname.'<br>'.$mysoc->url.'<br>';
|
if (! empty($conf->global->TAKEPOS_FOOTER))
|
||||||
echo '<center>'.$langs->trans("Thanks for your coming !").'</center>';
|
{
|
||||||
|
$newfreetext=make_substitutions($conf->global->TAKEPOS_FOOTER,$substitutionarray);
|
||||||
|
echo $newfreetext;
|
||||||
|
}
|
||||||
?>
|
?>
|
||||||
|
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
|
|||||||
@ -1212,7 +1212,7 @@ class ActionsTicket
|
|||||||
$this->viewTicketOriginalMessage($user, $action);
|
$this->viewTicketOriginalMessage($user, $action);
|
||||||
|
|
||||||
if (is_array($this->dao->cache_msgs_ticket) && count($this->dao->cache_msgs_ticket) > 0) {
|
if (is_array($this->dao->cache_msgs_ticket) && count($this->dao->cache_msgs_ticket) > 0) {
|
||||||
print_titre($langs->trans('TicketMailExchanges'));
|
print load_fiche_titre($langs->trans('TicketMailExchanges'));
|
||||||
|
|
||||||
print '<table class="border" style="width:100%;">';
|
print '<table class="border" style="width:100%;">';
|
||||||
|
|
||||||
|
|||||||
@ -32,7 +32,7 @@ $langs = $GLOBALS['langs'];
|
|||||||
$langs->load('ticket');
|
$langs->load('ticket');
|
||||||
$linkedObjectBlock = $GLOBALS['linkedObjectBlock'];
|
$linkedObjectBlock = $GLOBALS['linkedObjectBlock'];
|
||||||
echo '<br>';
|
echo '<br>';
|
||||||
print_titre($langs->trans('RelatedTickets'));
|
print load_fiche_titre($langs->trans('RelatedTickets'));
|
||||||
?>
|
?>
|
||||||
<table class="noborder" width="100%">
|
<table class="noborder" width="100%">
|
||||||
<tr class="liste_titre">
|
<tr class="liste_titre">
|
||||||
|
|||||||
@ -408,7 +408,7 @@ if (! empty($id) || ! empty($ref))
|
|||||||
} else {
|
} else {
|
||||||
$title = $langs->trans('EditProductCombination');
|
$title = $langs->trans('EditProductCombination');
|
||||||
}
|
}
|
||||||
print_fiche_titre($title);
|
print load_fiche_titre($title);
|
||||||
|
|
||||||
if ($action == 'add') {
|
if ($action == 'add') {
|
||||||
$prodattr_all = $prodattr->fetchAll();
|
$prodattr_all = $prodattr->fetchAll();
|
||||||
|
|||||||
@ -2333,6 +2333,7 @@ if ($action == 'createsite')
|
|||||||
|
|
||||||
if (GETPOST('WEBSITE_REF')) $siteref=GETPOST('WEBSITE_REF','alpha');
|
if (GETPOST('WEBSITE_REF')) $siteref=GETPOST('WEBSITE_REF','alpha');
|
||||||
if (GETPOST('WEBSITE_DESCRIPTION')) $sitedesc=GETPOST('WEBSITE_DESCRIPTION','alpha');
|
if (GETPOST('WEBSITE_DESCRIPTION')) $sitedesc=GETPOST('WEBSITE_DESCRIPTION','alpha');
|
||||||
|
if (GETPOST('WEBSITE_VIRTUALHOST')) $sitevhost=GETPOST('WEBSITE_VIRTUALHOST','alpha');
|
||||||
|
|
||||||
print '<tr><td class="titlefieldcreate fieldrequired">';
|
print '<tr><td class="titlefieldcreate fieldrequired">';
|
||||||
print $langs->trans('Ref');
|
print $langs->trans('Ref');
|
||||||
@ -2354,7 +2355,7 @@ if ($action == 'createsite')
|
|||||||
|
|
||||||
print $form->textwithpicto($langs->trans('Virtualhost'), $htmltext, 1, 'help', '', 0, 2, 'tooltipvirtual');
|
print $form->textwithpicto($langs->trans('Virtualhost'), $htmltext, 1, 'help', '', 0, 2, 'tooltipvirtual');
|
||||||
print '</td><td>';
|
print '</td><td>';
|
||||||
print '<input type="text" class="flat minwidth300" name="WEBSITE_DESCRIPTION" value="'.dol_escape_htmltag($sitedesc).'">';
|
print '<input type="text" class="flat minwidth300" name="WEBSITE_VIRTUALHOST" value="'.dol_escape_htmltag($sitevhost).'">';
|
||||||
print '</td></tr>';
|
print '</td></tr>';
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user