Merge remote-tracking branch 'origin/3.7' into develop
Conflicts: htdocs/compta/prelevement/class/bonprelevement.class.php htdocs/fourn/commande/card.php htdocs/langs/en_US/admin.lang htdocs/projet/index.php
This commit is contained in:
commit
2795d27cc9
@ -139,6 +139,8 @@ print " <td align=\"right\" width=\"160\"> </td>\n";
|
|||||||
print '</tr>'."\n";
|
print '</tr>'."\n";
|
||||||
$var=true;
|
$var=true;
|
||||||
|
|
||||||
|
$found=0;
|
||||||
|
|
||||||
if (! empty($conf->facture->enabled))
|
if (! empty($conf->facture->enabled))
|
||||||
{
|
{
|
||||||
$var=!$var;
|
$var=!$var;
|
||||||
@ -151,6 +153,7 @@ if (! empty($conf->facture->enabled))
|
|||||||
print $form->selectyesno("STOCK_CALCULATE_ON_BILL",$conf->global->STOCK_CALCULATE_ON_BILL,1,$disabled);
|
print $form->selectyesno("STOCK_CALCULATE_ON_BILL",$conf->global->STOCK_CALCULATE_ON_BILL,1,$disabled);
|
||||||
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'"'.$disabled.'>';
|
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'"'.$disabled.'>';
|
||||||
print "</form>\n</td>\n</tr>\n";
|
print "</form>\n</td>\n</tr>\n";
|
||||||
|
$found++;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (! empty($conf->commande->enabled))
|
if (! empty($conf->commande->enabled))
|
||||||
@ -165,6 +168,7 @@ if (! empty($conf->commande->enabled))
|
|||||||
print $form->selectyesno("STOCK_CALCULATE_ON_VALIDATE_ORDER",$conf->global->STOCK_CALCULATE_ON_VALIDATE_ORDER,1,$disabled);
|
print $form->selectyesno("STOCK_CALCULATE_ON_VALIDATE_ORDER",$conf->global->STOCK_CALCULATE_ON_VALIDATE_ORDER,1,$disabled);
|
||||||
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'"'.$disabled.'>';
|
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'"'.$disabled.'>';
|
||||||
print "</form>\n</td>\n</tr>\n";
|
print "</form>\n</td>\n</tr>\n";
|
||||||
|
$found++;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (! empty($conf->expedition->enabled))
|
if (! empty($conf->expedition->enabled))
|
||||||
@ -179,7 +183,17 @@ if (! empty($conf->expedition->enabled))
|
|||||||
print $form->selectyesno("STOCK_CALCULATE_ON_SHIPMENT",$conf->global->STOCK_CALCULATE_ON_SHIPMENT,1,$disabled);
|
print $form->selectyesno("STOCK_CALCULATE_ON_SHIPMENT",$conf->global->STOCK_CALCULATE_ON_SHIPMENT,1,$disabled);
|
||||||
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'"'.$disabled.'>';
|
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'"'.$disabled.'>';
|
||||||
print "</form>\n</td>\n</tr>\n";
|
print "</form>\n</td>\n</tr>\n";
|
||||||
|
$found++;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (! $found)
|
||||||
|
{
|
||||||
|
$var=!$var;
|
||||||
|
print "<tr ".$bc[$var].">";
|
||||||
|
print '<td colspan="2">'.$langs->trans("NoModueToManageStockDecrease").'</td>';
|
||||||
|
print "</tr>\n";
|
||||||
|
}
|
||||||
|
|
||||||
print '</table>';
|
print '</table>';
|
||||||
|
|
||||||
print '<br>';
|
print '<br>';
|
||||||
@ -192,6 +206,8 @@ print " <td align=\"right\" width=\"160\"> </td>\n";
|
|||||||
print '</tr>'."\n";
|
print '</tr>'."\n";
|
||||||
$var=true;
|
$var=true;
|
||||||
|
|
||||||
|
$found=0;
|
||||||
|
|
||||||
if (! empty($conf->fournisseur->enabled))
|
if (! empty($conf->fournisseur->enabled))
|
||||||
{
|
{
|
||||||
$var=!$var;
|
$var=!$var;
|
||||||
@ -204,6 +220,7 @@ if (! empty($conf->fournisseur->enabled))
|
|||||||
print $form->selectyesno("STOCK_CALCULATE_ON_SUPPLIER_BILL",$conf->global->STOCK_CALCULATE_ON_SUPPLIER_BILL,1,$disabled);
|
print $form->selectyesno("STOCK_CALCULATE_ON_SUPPLIER_BILL",$conf->global->STOCK_CALCULATE_ON_SUPPLIER_BILL,1,$disabled);
|
||||||
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'"'.$disabled.'>';
|
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'"'.$disabled.'>';
|
||||||
print "</form>\n</td>\n</tr>\n";
|
print "</form>\n</td>\n</tr>\n";
|
||||||
|
$found++;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (! empty($conf->fournisseur->enabled))
|
if (! empty($conf->fournisseur->enabled))
|
||||||
@ -218,6 +235,7 @@ if (! empty($conf->fournisseur->enabled))
|
|||||||
print $form->selectyesno("STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER",$conf->global->STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER,1,$disabled);
|
print $form->selectyesno("STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER",$conf->global->STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER,1,$disabled);
|
||||||
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'"'.$disabled.'>';
|
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'"'.$disabled.'>';
|
||||||
print "</form>\n</td>\n</tr>\n";
|
print "</form>\n</td>\n</tr>\n";
|
||||||
|
$found++;
|
||||||
}
|
}
|
||||||
if (! empty($conf->fournisseur->enabled))
|
if (! empty($conf->fournisseur->enabled))
|
||||||
{
|
{
|
||||||
@ -231,65 +249,76 @@ if (! empty($conf->fournisseur->enabled))
|
|||||||
print $form->selectyesno("STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER",$conf->global->STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER,1,$disabled);
|
print $form->selectyesno("STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER",$conf->global->STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER,1,$disabled);
|
||||||
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'"'.$disabled.'>';
|
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'"'.$disabled.'>';
|
||||||
print "</form>\n</td>\n</tr>\n";
|
print "</form>\n</td>\n</tr>\n";
|
||||||
|
$found++;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (! $found)
|
||||||
|
{
|
||||||
|
$var=!$var;
|
||||||
|
print "<tr ".$bc[$var].">";
|
||||||
|
print '<td colspan="2">'.$langs->trans("NoModueToManageStockIncrease").'</td>';
|
||||||
|
print "</tr>\n";
|
||||||
}
|
}
|
||||||
|
|
||||||
print '</table>';
|
print '</table>';
|
||||||
|
|
||||||
// Optio to force stock to be enough before adding a line into document
|
// Optio to force stock to be enough before adding a line into document
|
||||||
print '<br>';
|
if ($conf->invoice->enabled || $conf->order->enabled || $conf->expedition->enabled)
|
||||||
print '<table class="noborder" width="100%">';
|
{
|
||||||
print '<tr class="liste_titre">';
|
print '<br>';
|
||||||
print " <td>".$langs->trans("RuleForStockAvailability")."</td>\n";
|
print '<table class="noborder" width="100%">';
|
||||||
print " <td align=\"right\" width=\"160\"> </td>\n";
|
print '<tr class="liste_titre">';
|
||||||
print '</tr>'."\n";
|
print " <td>".$langs->trans("RuleForStockAvailability")."</td>\n";
|
||||||
|
print " <td align=\"right\" width=\"160\"> </td>\n";
|
||||||
|
print '</tr>'."\n";
|
||||||
|
|
||||||
if($conf->invoice->enabled) {
|
if($conf->invoice->enabled) {
|
||||||
$var = !$var;
|
$var = !$var;
|
||||||
print "<tr ".$bc[$var].">";
|
print "<tr ".$bc[$var].">";
|
||||||
print '<td width="60%">'.$langs->trans("StockMustBeEnoughForInvoice").'</td>';
|
print '<td width="60%">'.$langs->trans("StockMustBeEnoughForInvoice").'</td>';
|
||||||
print '<td width="160" align="right">';
|
print '<td width="160" align="right">';
|
||||||
print "<form method=\"post\" action=\"stock.php\">";
|
print "<form method=\"post\" action=\"stock.php\">";
|
||||||
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=\"STOCK_MUST_BE_ENOUGH_FOR_INVOICE\">";
|
print "<input type=\"hidden\" name=\"action\" value=\"STOCK_MUST_BE_ENOUGH_FOR_INVOICE\">";
|
||||||
print $form->selectyesno("STOCK_MUST_BE_ENOUGH_FOR_INVOICE",$conf->global->STOCK_MUST_BE_ENOUGH_FOR_INVOICE,1);
|
print $form->selectyesno("STOCK_MUST_BE_ENOUGH_FOR_INVOICE",$conf->global->STOCK_MUST_BE_ENOUGH_FOR_INVOICE,1);
|
||||||
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'">';
|
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'">';
|
||||||
print '</form>';
|
print '</form>';
|
||||||
print "</td>\n";
|
print "</td>\n";
|
||||||
print "</tr>\n";
|
print "</tr>\n";
|
||||||
|
}
|
||||||
|
|
||||||
|
if($conf->order->enabled) {
|
||||||
|
$var = !$var;
|
||||||
|
print "<tr ".$bc[$var].">";
|
||||||
|
print '<td width="60%">'.$langs->trans("StockMustBeEnoughForOrder").'</td>';
|
||||||
|
print '<td width="160" align="right">';
|
||||||
|
print "<form method=\"post\" action=\"stock.php\">";
|
||||||
|
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
||||||
|
print "<input type=\"hidden\" name=\"action\" value=\"STOCK_MUST_BE_ENOUGH_FOR_ORDER\">";
|
||||||
|
print $form->selectyesno("STOCK_MUST_BE_ENOUGH_FOR_ORDER",$conf->global->STOCK_MUST_BE_ENOUGH_FOR_ORDER,1);
|
||||||
|
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'">';
|
||||||
|
print '</form>';
|
||||||
|
print "</td>\n";
|
||||||
|
print "</tr>\n";
|
||||||
|
}
|
||||||
|
|
||||||
|
if($conf->expedition->enabled) {
|
||||||
|
$var = !$var;
|
||||||
|
print "<tr ".$bc[$var].">";
|
||||||
|
print '<td width="60%">'.$langs->trans("StockMustBeEnoughForShipment").'</td>';
|
||||||
|
print '<td width="160" align="right">';
|
||||||
|
print "<form method=\"post\" action=\"stock.php\">";
|
||||||
|
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
||||||
|
print "<input type=\"hidden\" name=\"action\" value=\"STOCK_MUST_BE_ENOUGH_FOR_SHIPMENT\">";
|
||||||
|
print $form->selectyesno("STOCK_MUST_BE_ENOUGH_FOR_SHIPMENT",$conf->global->STOCK_MUST_BE_ENOUGH_FOR_SHIPMENT,1);
|
||||||
|
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'">';
|
||||||
|
print '</form>';
|
||||||
|
print "</td>\n";
|
||||||
|
print "</tr>\n";
|
||||||
|
}
|
||||||
|
print '</table>';
|
||||||
}
|
}
|
||||||
|
|
||||||
if($conf->order->enabled) {
|
|
||||||
$var = !$var;
|
|
||||||
print "<tr ".$bc[$var].">";
|
|
||||||
print '<td width="60%">'.$langs->trans("StockMustBeEnoughForOrder").'</td>';
|
|
||||||
print '<td width="160" align="right">';
|
|
||||||
print "<form method=\"post\" action=\"stock.php\">";
|
|
||||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
|
||||||
print "<input type=\"hidden\" name=\"action\" value=\"STOCK_MUST_BE_ENOUGH_FOR_ORDER\">";
|
|
||||||
print $form->selectyesno("STOCK_MUST_BE_ENOUGH_FOR_ORDER",$conf->global->STOCK_MUST_BE_ENOUGH_FOR_ORDER,1);
|
|
||||||
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'">';
|
|
||||||
print '</form>';
|
|
||||||
print "</td>\n";
|
|
||||||
print "</tr>\n";
|
|
||||||
}
|
|
||||||
|
|
||||||
if($conf->expedition->enabled) {
|
|
||||||
$var = !$var;
|
|
||||||
print "<tr ".$bc[$var].">";
|
|
||||||
print '<td width="60%">'.$langs->trans("StockMustBeEnoughForShipment").'</td>';
|
|
||||||
print '<td width="160" align="right">';
|
|
||||||
print "<form method=\"post\" action=\"stock.php\">";
|
|
||||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
|
||||||
print "<input type=\"hidden\" name=\"action\" value=\"STOCK_MUST_BE_ENOUGH_FOR_SHIPMENT\">";
|
|
||||||
print $form->selectyesno("STOCK_MUST_BE_ENOUGH_FOR_SHIPMENT",$conf->global->STOCK_MUST_BE_ENOUGH_FOR_SHIPMENT,1);
|
|
||||||
print '<input type="submit" class="button" value="'.$langs->trans("Modify").'">';
|
|
||||||
print '</form>';
|
|
||||||
print "</td>\n";
|
|
||||||
print "</tr>\n";
|
|
||||||
}
|
|
||||||
print '</table>';
|
|
||||||
|
|
||||||
|
|
||||||
$virtualdiffersfromphysical=0;
|
$virtualdiffersfromphysical=0;
|
||||||
if (! empty($conf->global->STOCK_CALCULATE_ON_SHIPMENT)
|
if (! empty($conf->global->STOCK_CALCULATE_ON_SHIPMENT)
|
||||||
|| ! empty($conf->global->STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER)
|
|| ! empty($conf->global->STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER)
|
||||||
|
|||||||
@ -1259,7 +1259,7 @@ class BonPrelevement extends CommonObject
|
|||||||
$sql = "SELECT f.facnumber as fac FROM ".MAIN_DB_PREFIX."prelevement_lignes as pl, ".MAIN_DB_PREFIX."facture as f, ".MAIN_DB_PREFIX."prelevement_facture as pf, ".MAIN_DB_PREFIX."societe as soc, ".MAIN_DB_PREFIX."c_country as p, ".MAIN_DB_PREFIX."societe_rib as rib WHERE pl.fk_prelevement_bons = ".$this->id." AND pl.rowid = pf.fk_prelevement_lignes AND pf.fk_facture = f.rowid AND soc.fk_pays = p.rowid AND soc.rowid = f.fk_soc AND rib.fk_soc = f.fk_soc AND rib.default_rib = 1";
|
$sql = "SELECT f.facnumber as fac FROM ".MAIN_DB_PREFIX."prelevement_lignes as pl, ".MAIN_DB_PREFIX."facture as f, ".MAIN_DB_PREFIX."prelevement_facture as pf, ".MAIN_DB_PREFIX."societe as soc, ".MAIN_DB_PREFIX."c_country as p, ".MAIN_DB_PREFIX."societe_rib as rib WHERE pl.fk_prelevement_bons = ".$this->id." AND pl.rowid = pf.fk_prelevement_lignes AND pf.fk_facture = f.rowid AND soc.fk_pays = p.rowid AND soc.rowid = f.fk_soc AND rib.fk_soc = f.fk_soc AND rib.default_rib = 1";
|
||||||
$resql=$this->db->query($sql);
|
$resql=$this->db->query($sql);
|
||||||
if ($resql)
|
if ($resql)
|
||||||
{
|
{
|
||||||
$num = $this->db->num_rows($resql);
|
$num = $this->db->num_rows($resql);
|
||||||
while ($j < $num)
|
while ($j < $num)
|
||||||
{
|
{
|
||||||
|
|||||||
@ -1095,6 +1095,9 @@ ALTER TABLE llx_projet_task_time ADD INDEX idx_projet_task_time_task (fk_task);
|
|||||||
ALTER TABLE llx_projet_task_time ADD INDEX idx_projet_task_time_date (task_date);
|
ALTER TABLE llx_projet_task_time ADD INDEX idx_projet_task_time_date (task_date);
|
||||||
ALTER TABLE llx_projet_task_time ADD INDEX idx_projet_task_time_datehour (task_datehour);
|
ALTER TABLE llx_projet_task_time ADD INDEX idx_projet_task_time_datehour (task_datehour);
|
||||||
|
|
||||||
|
ALTER TABLE llx_projet_task CHANGE COLUMN duration_effective real DEFAULT 0 NULL;
|
||||||
|
ALTER TABLE llx_projet_task CHANGE COLUMN planned_workload real DEFAULT 0 NULL;
|
||||||
|
|
||||||
|
|
||||||
-- add extrafield on ficheinter lines
|
-- add extrafield on ficheinter lines
|
||||||
CREATE TABLE llx_fichinterdet_extrafields
|
CREATE TABLE llx_fichinterdet_extrafields
|
||||||
|
|||||||
@ -31,10 +31,10 @@ create table llx_projet_task
|
|||||||
datev datetime, -- date validation
|
datev datetime, -- date validation
|
||||||
label varchar(255) NOT NULL,
|
label varchar(255) NOT NULL,
|
||||||
description text,
|
description text,
|
||||||
duration_effective real DEFAULT 0 NOT NULL,
|
duration_effective real DEFAULT 0,
|
||||||
planned_workload real DEFAULT 0 NOT NULL,
|
planned_workload real DEFAULT 0,
|
||||||
progress integer DEFAULT 0, -- percentage increase
|
progress integer DEFAULT 0, -- percentage increase
|
||||||
priority integer DEFAULT 0, -- priority
|
priority integer DEFAULT 0, -- priority
|
||||||
fk_user_creat integer, -- user who created the task
|
fk_user_creat integer, -- user who created the task
|
||||||
fk_user_valid integer, -- user who validated the task
|
fk_user_valid integer, -- user who validated the task
|
||||||
fk_statut smallint DEFAULT 0 NOT NULL,
|
fk_statut smallint DEFAULT 0 NOT NULL,
|
||||||
|
|||||||
@ -1590,3 +1590,5 @@ TypePaymentDesc=0:Customer payment type, 1:Supplier payment type, 2:Both custome
|
|||||||
IncludePath=Include path (defined into variable %s)
|
IncludePath=Include path (defined into variable %s)
|
||||||
ExpenseReportsSetup=Setup of module Expense Reports
|
ExpenseReportsSetup=Setup of module Expense Reports
|
||||||
TemplatePDFExpenseReports=Document templates to generate expense report document
|
TemplatePDFExpenseReports=Document templates to generate expense report document
|
||||||
|
NoModueToManageStockDecrease=No module able to manage automatic stock decrease has been activated. Stock decrease will be done on manual input only.
|
||||||
|
NoModueToManageStockIncrease=No module able to manage automatic stock increase has been activated. Stock increase will be done on manual input only.
|
||||||
|
|||||||
@ -25,6 +25,7 @@
|
|||||||
|
|
||||||
require '../main.inc.php';
|
require '../main.inc.php';
|
||||||
require_once DOL_DOCUMENT_ROOT.'/projet/class/project.class.php';
|
require_once DOL_DOCUMENT_ROOT.'/projet/class/project.class.php';
|
||||||
|
require_once DOL_DOCUMENT_ROOT.'/projet/class/task.class.php';
|
||||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/project.lib.php';
|
require_once DOL_DOCUMENT_ROOT.'/core/lib/project.lib.php';
|
||||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/date.lib.php';
|
require_once DOL_DOCUMENT_ROOT.'/core/lib/date.lib.php';
|
||||||
|
|
||||||
@ -50,6 +51,7 @@ $sortorder = GETPOST("sortorder",'alpha');
|
|||||||
$socstatic=new Societe($db);
|
$socstatic=new Societe($db);
|
||||||
$projectstatic=new Project($db);
|
$projectstatic=new Project($db);
|
||||||
$userstatic=new User($db);
|
$userstatic=new User($db);
|
||||||
|
$tasktmp=new Task($db);
|
||||||
|
|
||||||
$projectsListId = $projectstatic->getProjectsAuthorizedForUser($user,($mine?$mine:(empty($user->rights->projet->all->lire)?0:2)),1);
|
$projectsListId = $projectstatic->getProjectsAuthorizedForUser($user,($mine?$mine:(empty($user->rights->projet->all->lire)?0:2)),1);
|
||||||
//var_dump($projectsListId);
|
//var_dump($projectsListId);
|
||||||
@ -227,7 +229,9 @@ if (empty($conf->global->PROJECT_HIDE_TASKS))
|
|||||||
print '<td>';
|
print '<td>';
|
||||||
if (! empty($obj->taskid))
|
if (! empty($obj->taskid))
|
||||||
{
|
{
|
||||||
print '<a href="'.DOL_URL_ROOT.'/projet/tasks/task.php?id='.$obj->taskid.'&withproject=1">'.$obj->label.'</a>';
|
$tasktmp->id = $obj->taskid;
|
||||||
|
$tasktmp->ref = $obj->label;
|
||||||
|
print $tasktmp->getNomUrl(1,'withproject');
|
||||||
}
|
}
|
||||||
else print $langs->trans("NoTasks");
|
else print $langs->trans("NoTasks");
|
||||||
print '</td>';
|
print '</td>';
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user