Merge remote-tracking branch 'upstream/develop' into Squiz.ControlStructures.ControlSignature.SpaceAfterKeyword
This commit is contained in:
commit
416e6dd90d
@ -177,12 +177,6 @@ class ActionComm extends CommonObject
|
|||||||
*/
|
*/
|
||||||
public $fulldayevent = 0;
|
public $fulldayevent = 0;
|
||||||
|
|
||||||
/**
|
|
||||||
* @var int Milestone
|
|
||||||
* @deprecated Milestone is already event with end date = start date
|
|
||||||
*/
|
|
||||||
public $punctual = 1;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var integer Percentage
|
* @var integer Percentage
|
||||||
*/
|
*/
|
||||||
@ -384,7 +378,6 @@ class ActionComm extends CommonObject
|
|||||||
if (empty($this->percentage)) $this->percentage = 0;
|
if (empty($this->percentage)) $this->percentage = 0;
|
||||||
if (empty($this->priority) || !is_numeric($this->priority)) $this->priority = 0;
|
if (empty($this->priority) || !is_numeric($this->priority)) $this->priority = 0;
|
||||||
if (empty($this->fulldayevent)) $this->fulldayevent = 0;
|
if (empty($this->fulldayevent)) $this->fulldayevent = 0;
|
||||||
if (empty($this->punctual)) $this->punctual = 0;
|
|
||||||
if (empty($this->transparency)) $this->transparency = 0;
|
if (empty($this->transparency)) $this->transparency = 0;
|
||||||
if ($this->percentage > 100) $this->percentage = 100;
|
if ($this->percentage > 100) $this->percentage = 100;
|
||||||
//if ($this->percentage == 100 && ! $this->dateend) $this->dateend = $this->date;
|
//if ($this->percentage == 100 && ! $this->dateend) $this->dateend = $this->date;
|
||||||
@ -462,7 +455,7 @@ class ActionComm extends CommonObject
|
|||||||
$sql .= "fk_user_author,";
|
$sql .= "fk_user_author,";
|
||||||
$sql .= "fk_user_action,";
|
$sql .= "fk_user_action,";
|
||||||
$sql .= "fk_user_done,";
|
$sql .= "fk_user_done,";
|
||||||
$sql .= "label,percent,priority,fulldayevent,location,punctual,";
|
$sql .= "label,percent,priority,fulldayevent,location,";
|
||||||
$sql .= "transparency,";
|
$sql .= "transparency,";
|
||||||
$sql .= "fk_element,";
|
$sql .= "fk_element,";
|
||||||
$sql .= "elementtype,";
|
$sql .= "elementtype,";
|
||||||
@ -492,7 +485,7 @@ class ActionComm extends CommonObject
|
|||||||
$sql .= (isset($user->id) && $user->id > 0 ? $user->id : "null").", ";
|
$sql .= (isset($user->id) && $user->id > 0 ? $user->id : "null").", ";
|
||||||
$sql .= ($userownerid > 0 ? $userownerid : "null").", ";
|
$sql .= ($userownerid > 0 ? $userownerid : "null").", ";
|
||||||
$sql .= ($userdoneid > 0 ? $userdoneid : "null").", ";
|
$sql .= ($userdoneid > 0 ? $userdoneid : "null").", ";
|
||||||
$sql .= "'".$this->db->escape($this->label)."','".$this->db->escape($this->percentage)."','".$this->db->escape($this->priority)."','".$this->db->escape($this->fulldayevent)."','".$this->db->escape($this->location)."','".$this->db->escape($this->punctual)."', ";
|
$sql .= "'".$this->db->escape($this->label)."','".$this->db->escape($this->percentage)."','".$this->db->escape($this->priority)."','".$this->db->escape($this->fulldayevent)."','".$this->db->escape($this->location)."', ";
|
||||||
$sql .= "'".$this->db->escape($this->transparency)."', ";
|
$sql .= "'".$this->db->escape($this->transparency)."', ";
|
||||||
$sql .= (!empty($this->fk_element) ? $this->fk_element : "null").", ";
|
$sql .= (!empty($this->fk_element) ? $this->fk_element : "null").", ";
|
||||||
$sql .= (!empty($this->elementtype) ? "'".$this->db->escape($this->elementtype)."'" : "null").", ";
|
$sql .= (!empty($this->elementtype) ? "'".$this->db->escape($this->elementtype)."'" : "null").", ";
|
||||||
@ -693,7 +686,7 @@ class ActionComm extends CommonObject
|
|||||||
$sql .= " a.fk_user_action, a.fk_user_done,";
|
$sql .= " a.fk_user_action, a.fk_user_done,";
|
||||||
$sql .= " a.fk_contact, a.percent as percentage,";
|
$sql .= " a.fk_contact, a.percent as percentage,";
|
||||||
$sql .= " a.fk_element as elementid, a.elementtype,";
|
$sql .= " a.fk_element as elementid, a.elementtype,";
|
||||||
$sql .= " a.priority, a.fulldayevent, a.location, a.punctual, a.transparency,";
|
$sql .= " a.priority, a.fulldayevent, a.location, a.transparency,";
|
||||||
$sql .= " c.id as type_id, c.code as type_code, c.libelle as type_label, c.color as type_color, c.picto as type_picto,";
|
$sql .= " c.id as type_id, c.code as type_code, c.libelle as type_label, c.color as type_color, c.picto as type_picto,";
|
||||||
$sql .= " s.nom as socname,";
|
$sql .= " s.nom as socname,";
|
||||||
$sql .= " u.firstname, u.lastname as lastname";
|
$sql .= " u.firstname, u.lastname as lastname";
|
||||||
@ -758,7 +751,6 @@ class ActionComm extends CommonObject
|
|||||||
$this->fulldayevent = $obj->fulldayevent;
|
$this->fulldayevent = $obj->fulldayevent;
|
||||||
$this->location = $obj->location;
|
$this->location = $obj->location;
|
||||||
$this->transparency = $obj->transparency;
|
$this->transparency = $obj->transparency;
|
||||||
$this->punctual = $obj->punctual; // deprecated
|
|
||||||
|
|
||||||
$this->socid = $obj->fk_soc; // To have fetch_thirdparty method working
|
$this->socid = $obj->fk_soc; // To have fetch_thirdparty method working
|
||||||
$this->contactid = $obj->fk_contact; // To have fetch_contact method working
|
$this->contactid = $obj->fk_contact; // To have fetch_contact method working
|
||||||
@ -1612,7 +1604,7 @@ class ActionComm extends CommonObject
|
|||||||
$sql .= " a.fk_user_action,";
|
$sql .= " a.fk_user_action,";
|
||||||
$sql .= " a.fk_contact, a.percent as percentage,";
|
$sql .= " a.fk_contact, a.percent as percentage,";
|
||||||
$sql .= " a.fk_element, a.elementtype,";
|
$sql .= " a.fk_element, a.elementtype,";
|
||||||
$sql .= " a.priority, a.fulldayevent, a.location, a.punctual, a.transparency,";
|
$sql .= " a.priority, a.fulldayevent, a.location, a.transparency,";
|
||||||
$sql .= " u.firstname, u.lastname, u.email,";
|
$sql .= " u.firstname, u.lastname, u.email,";
|
||||||
$sql .= " s.nom as socname,";
|
$sql .= " s.nom as socname,";
|
||||||
$sql .= " c.id as type_id, c.code as type_code, c.libelle as type_label";
|
$sql .= " c.id as type_id, c.code as type_code, c.libelle as type_label";
|
||||||
@ -1719,7 +1711,6 @@ class ActionComm extends CommonObject
|
|||||||
$event['fulldayevent'] = $obj->fulldayevent;
|
$event['fulldayevent'] = $obj->fulldayevent;
|
||||||
$event['location'] = $obj->location;
|
$event['location'] = $obj->location;
|
||||||
$event['transparency'] = (($obj->transparency > 0) ? 'OPAQUE' : 'TRANSPARENT'); // OPAQUE (busy) or TRANSPARENT (not busy)
|
$event['transparency'] = (($obj->transparency > 0) ? 'OPAQUE' : 'TRANSPARENT'); // OPAQUE (busy) or TRANSPARENT (not busy)
|
||||||
$event['punctual'] = $obj->punctual;
|
|
||||||
$event['category'] = $obj->type_label;
|
$event['category'] = $obj->type_label;
|
||||||
$event['email'] = $obj->email;
|
$event['email'] = $obj->email;
|
||||||
// Define $urlwithroot
|
// Define $urlwithroot
|
||||||
@ -1929,11 +1920,7 @@ class ActionComm extends CommonObject
|
|||||||
$this->datem = $now;
|
$this->datem = $now;
|
||||||
$this->datep = $now;
|
$this->datep = $now;
|
||||||
$this->datef = $now;
|
$this->datef = $now;
|
||||||
$this->author = $user;
|
|
||||||
$this->usermod = $user;
|
|
||||||
$this->usertodo = $user;
|
|
||||||
$this->fulldayevent = 0;
|
$this->fulldayevent = 0;
|
||||||
$this->punctual = 0;
|
|
||||||
$this->percentage = 0;
|
$this->percentage = 0;
|
||||||
$this->location = 'Location';
|
$this->location = 'Location';
|
||||||
$this->transparency = 1; // 1 means opaque
|
$this->transparency = 1; // 1 means opaque
|
||||||
|
|||||||
@ -1,4 +1,6 @@
|
|||||||
<?php
|
<?php
|
||||||
|
use Splash\Tests\WsObjects\O00ObjectBaseTest;
|
||||||
|
|
||||||
/* Copyright (C) 2003-2007 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
/* Copyright (C) 2003-2007 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
||||||
* Copyright (C) 2003 Xavier Dutoit <doli@sydesy.com>
|
* Copyright (C) 2003 Xavier Dutoit <doli@sydesy.com>
|
||||||
* Copyright (C) 2004-2016 Laurent Destailleur <eldy@users.sourceforge.net>
|
* Copyright (C) 2004-2016 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||||
@ -37,7 +39,7 @@ class Conf
|
|||||||
public $file;
|
public $file;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var DoliDB Database handler.
|
* @var Object Associative array with some properties ->type, ->db, ...
|
||||||
*/
|
*/
|
||||||
public $db;
|
public $db;
|
||||||
|
|
||||||
|
|||||||
@ -2226,7 +2226,7 @@ function print_projecttasks_array($db, $form, $socid, $projectsListId, $mytasks
|
|||||||
print '<tr class="oddeven">';
|
print '<tr class="oddeven">';
|
||||||
|
|
||||||
print '<td>';
|
print '<td>';
|
||||||
print $projectstatic->getNomUrl(1, '', 0, '', '-', 0 , -1, 'nowraponall');
|
print $projectstatic->getNomUrl(1, '', 0, '', '-', 0, -1, 'nowraponall');
|
||||||
if (!in_array('projectlabel', $hiddenfields)) print '<br><span class="opacitymedium">'.dol_trunc($objp->title, 24).'</span>';
|
if (!in_array('projectlabel', $hiddenfields)) print '<br><span class="opacitymedium">'.dol_trunc($objp->title, 24).'</span>';
|
||||||
print '</td>';
|
print '</td>';
|
||||||
print '<td class="nowraponall tdoverflowmax100">';
|
print '<td class="nowraponall tdoverflowmax100">';
|
||||||
|
|||||||
@ -255,7 +255,6 @@ class CommActionRapport
|
|||||||
$eventstatic->id = $obj->id;
|
$eventstatic->id = $obj->id;
|
||||||
$eventstatic->percentage = $obj->percent;
|
$eventstatic->percentage = $obj->percent;
|
||||||
$eventstatic->fulldayevent = $obj->fulldayevent;
|
$eventstatic->fulldayevent = $obj->fulldayevent;
|
||||||
$eventstatic->punctual = $obj->punctual;
|
|
||||||
|
|
||||||
$y = max($y, $pdf->GetY(), $y0, $y1, $y2, $y3);
|
$y = max($y, $pdf->GetY(), $y0, $y1, $y2, $y3);
|
||||||
|
|
||||||
|
|||||||
@ -898,7 +898,6 @@ class InterfaceActionsAuto extends DolibarrTriggers
|
|||||||
$actioncomm->datep = $now;
|
$actioncomm->datep = $now;
|
||||||
$actioncomm->datef = $now;
|
$actioncomm->datef = $now;
|
||||||
$actioncomm->durationp = 0;
|
$actioncomm->durationp = 0;
|
||||||
$actioncomm->punctual = 1;
|
|
||||||
$actioncomm->percentage = -1; // Not applicable
|
$actioncomm->percentage = -1; // Not applicable
|
||||||
$actioncomm->socid = $societeforaction->id;
|
$actioncomm->socid = $societeforaction->id;
|
||||||
$actioncomm->contactid = $contactforaction->id;
|
$actioncomm->contactid = $contactforaction->id;
|
||||||
|
|||||||
@ -80,7 +80,7 @@ llxHeader('', $title);
|
|||||||
$resultboxes = FormOther::getBoxesArea($user, "0"); // Load $resultboxes (selectboxlist + boxactivated + boxlista + boxlistb)
|
$resultboxes = FormOther::getBoxesArea($user, "0"); // Load $resultboxes (selectboxlist + boxactivated + boxlista + boxlistb)
|
||||||
|
|
||||||
|
|
||||||
print load_fiche_titre($langs->trans("HomeArea"), $resultboxes['selectboxlist'], 'home', 0, '', 'titleforhome');
|
print load_fiche_titre(' ', $resultboxes['selectboxlist'], '', 0, '', 'titleforhome');
|
||||||
|
|
||||||
if (!empty($conf->global->MAIN_MOTD))
|
if (!empty($conf->global->MAIN_MOTD))
|
||||||
{
|
{
|
||||||
|
|||||||
@ -74,6 +74,8 @@ delete from llx_const where name = 'PROJECT_HIDE_TASKS' and entity = 0;
|
|||||||
-- VMYSQL4.1 DROP INDEX ix_fk_product_stock on llx_product_batch;
|
-- VMYSQL4.1 DROP INDEX ix_fk_product_stock on llx_product_batch;
|
||||||
-- VPGSQL8.2 DROP INDEX ix_fk_product_stock
|
-- VPGSQL8.2 DROP INDEX ix_fk_product_stock
|
||||||
|
|
||||||
|
ALTER TABLE llx_actioncomm DROP COLUMN punctual;
|
||||||
|
|
||||||
DELETE FROM llx_menu where module='supplier_proposal';
|
DELETE FROM llx_menu where module='supplier_proposal';
|
||||||
|
|
||||||
UPDATE llx_website SET lang = 'en' WHERE lang like 'en_%';
|
UPDATE llx_website SET lang = 'en' WHERE lang like 'en_%';
|
||||||
|
|||||||
@ -48,7 +48,6 @@ create table llx_actioncomm
|
|||||||
priority smallint, -- priority (ical standard)
|
priority smallint, -- priority (ical standard)
|
||||||
visibility varchar(12) DEFAULT 'default', -- visibility (ical standard) - 'default', 'public', 'private', 'confidential'
|
visibility varchar(12) DEFAULT 'default', -- visibility (ical standard) - 'default', 'public', 'private', 'confidential'
|
||||||
fulldayevent smallint NOT NULL default 0, -- full day (ical standard)
|
fulldayevent smallint NOT NULL default 0, -- full day (ical standard)
|
||||||
punctual smallint NOT NULL default 1, -- deprecated. milestone is event with date start (datep) = date end (datep2)
|
|
||||||
percent smallint NOT NULL default 0,
|
percent smallint NOT NULL default 0,
|
||||||
location varchar(128),
|
location varchar(128),
|
||||||
durationp real, -- planed duration
|
durationp real, -- planed duration
|
||||||
|
|||||||
@ -58,8 +58,8 @@ AccountancyAreaDescActionOnceBis=Next steps should be done to save you time in f
|
|||||||
AccountancyAreaDescActionFreq=The following actions are usually executed every month, week or day for very large companies...
|
AccountancyAreaDescActionFreq=The following actions are usually executed every month, week or day for very large companies...
|
||||||
|
|
||||||
AccountancyAreaDescJournalSetup=STEP %s: Create or check content of your journal list from menu %s
|
AccountancyAreaDescJournalSetup=STEP %s: Create or check content of your journal list from menu %s
|
||||||
AccountancyAreaDescChartModel=STEP %s: Create a model of chart of account from menu %s
|
AccountancyAreaDescChartModel=STEP %s: Check that a model of chart of account exists or create one from menu %s
|
||||||
AccountancyAreaDescChart=STEP %s: Create or check content of your chart of account from menu %s
|
AccountancyAreaDescChart=STEP %s: Select and|or complete your chart of account from menu %s
|
||||||
|
|
||||||
AccountancyAreaDescVat=STEP %s: Define accounting accounts for each VAT Rates. For this, use the menu entry %s.
|
AccountancyAreaDescVat=STEP %s: Define accounting accounts for each VAT Rates. For this, use the menu entry %s.
|
||||||
AccountancyAreaDescDefault=STEP %s: Define default accounting accounts. For this, use the menu entry %s.
|
AccountancyAreaDescDefault=STEP %s: Define default accounting accounts. For this, use the menu entry %s.
|
||||||
|
|||||||
@ -112,8 +112,10 @@ BOM_CLOSEInDolibarr=BOM disabled
|
|||||||
BOM_REOPENInDolibarr=BOM reopen
|
BOM_REOPENInDolibarr=BOM reopen
|
||||||
BOM_DELETEInDolibarr=BOM deleted
|
BOM_DELETEInDolibarr=BOM deleted
|
||||||
MRP_MO_VALIDATEInDolibarr=MO validated
|
MRP_MO_VALIDATEInDolibarr=MO validated
|
||||||
|
MRP_MO_UNVALIDATEInDolibarr=MO set to draft status
|
||||||
MRP_MO_PRODUCEDInDolibarr=MO produced
|
MRP_MO_PRODUCEDInDolibarr=MO produced
|
||||||
MRP_MO_DELETEInDolibarr=MO deleted
|
MRP_MO_DELETEInDolibarr=MO deleted
|
||||||
|
MRP_MO_CANCELInDolibarr=MO canceled
|
||||||
##### End agenda events #####
|
##### End agenda events #####
|
||||||
AgendaModelModule=Document templates for event
|
AgendaModelModule=Document templates for event
|
||||||
DateActionStart=Start date
|
DateActionStart=Start date
|
||||||
|
|||||||
@ -929,7 +929,7 @@ class Mo extends CommonObject
|
|||||||
return -1;
|
return -1;
|
||||||
}*/
|
}*/
|
||||||
|
|
||||||
return $this->setStatusCommon($user, self::STATUS_DRAFT, $notrigger, 'MO_UNVALIDATE');
|
return $this->setStatusCommon($user, self::STATUS_DRAFT, $notrigger, 'MRP_MO_UNVALIDATE');
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -954,7 +954,7 @@ class Mo extends CommonObject
|
|||||||
return -1;
|
return -1;
|
||||||
}*/
|
}*/
|
||||||
|
|
||||||
return $this->setStatusCommon($user, self::STATUS_CANCELED, $notrigger, 'MO_CLOSE');
|
return $this->setStatusCommon($user, self::STATUS_CANCELED, $notrigger, 'MRP_MO_CANCEL');
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -967,7 +967,7 @@ class Mo extends CommonObject
|
|||||||
public function reopen($user, $notrigger = 0)
|
public function reopen($user, $notrigger = 0)
|
||||||
{
|
{
|
||||||
// Protection
|
// Protection
|
||||||
if ($this->status != self::STATUS_CANCELED)
|
if ($this->status != self::STATUS_PRODUCED && $this->status != self::STATUS_CANCELED)
|
||||||
{
|
{
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
@ -979,7 +979,7 @@ class Mo extends CommonObject
|
|||||||
return -1;
|
return -1;
|
||||||
}*/
|
}*/
|
||||||
|
|
||||||
return $this->setStatusCommon($user, self::STATUS_VALIDATED, $notrigger, 'MO_REOPEN');
|
return $this->setStatusCommon($user, self::STATUS_VALIDATED, $notrigger, 'MRP_MO_REOPEN');
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@ -169,6 +169,35 @@ if (empty($reshook))
|
|||||||
{
|
{
|
||||||
$object->setProject(GETPOST('projectid', 'int'));
|
$object->setProject(GETPOST('projectid', 'int'));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Action close produced
|
||||||
|
if ($action == 'confirm_produced' && $confirm == 'yes' && $permissiontoadd)
|
||||||
|
{
|
||||||
|
$result = $object->setStatut($object::STATUS_PRODUCED, 0, '', 'MRP_MO_PRODUCED');
|
||||||
|
if ($result >= 0)
|
||||||
|
{
|
||||||
|
// Define output language
|
||||||
|
if (empty($conf->global->MAIN_DISABLE_PDF_AUTOUPDATE))
|
||||||
|
{
|
||||||
|
$outputlangs = $langs;
|
||||||
|
$newlang = '';
|
||||||
|
if ($conf->global->MAIN_MULTILANGS && empty($newlang) && GETPOST('lang_id', 'aZ09')) $newlang = GETPOST('lang_id', 'aZ09');
|
||||||
|
if ($conf->global->MAIN_MULTILANGS && empty($newlang)) $newlang = $object->thirdparty->default_lang;
|
||||||
|
if (!empty($newlang)) {
|
||||||
|
$outputlangs = new Translate("", $conf);
|
||||||
|
$outputlangs->setDefaultLang($newlang);
|
||||||
|
}
|
||||||
|
$model = $object->modelpdf;
|
||||||
|
$ret = $object->fetch($id); // Reload to get new records
|
||||||
|
|
||||||
|
$object->generateDocument($model, $outputlangs, 0, 0, 0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
setEventMessages($object->error, $object->errors, 'errors');
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -630,10 +659,13 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
|
|||||||
{
|
{
|
||||||
if ($object->status == $object::STATUS_VALIDATED || $object->status == $object::STATUS_INPROGRESS)
|
if ($object->status == $object::STATUS_VALIDATED || $object->status == $object::STATUS_INPROGRESS)
|
||||||
{
|
{
|
||||||
|
// TODO If production is already > 1, show only close, else show cancel
|
||||||
|
print '<a class="butAction" href="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'&action=confirm_produced&confirm=yes">'.$langs->trans("Close").'</a>'."\n";
|
||||||
|
|
||||||
print '<a class="butActionDelete" href="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'&action=confirm_close&confirm=yes">'.$langs->trans("Cancel").'</a>'."\n";
|
print '<a class="butActionDelete" href="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'&action=confirm_close&confirm=yes">'.$langs->trans("Cancel").'</a>'."\n";
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($object->status == $object::STATUS_CANCELED)
|
if ($object->status == $object::STATUS_PRODUCED || $object->status == $object::STATUS_CANCELED)
|
||||||
{
|
{
|
||||||
print '<a class="butAction" href="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'&action=confirm_reopen&confirm=yes">'.$langs->trans("Re-Open").'</a>'."\n";
|
print '<a class="butAction" href="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'&action=confirm_reopen&confirm=yes">'.$langs->trans("Re-Open").'</a>'."\n";
|
||||||
}
|
}
|
||||||
|
|||||||
@ -383,6 +383,35 @@ if (empty($reshook))
|
|||||||
exit;
|
exit;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Action close produced
|
||||||
|
if ($action == 'confirm_produced' && $confirm == 'yes' && $permissiontoadd)
|
||||||
|
{
|
||||||
|
$result = $object->setStatut($object::STATUS_PRODUCED, 0, '', 'MRP_MO_PRODUCED');
|
||||||
|
if ($result >= 0)
|
||||||
|
{
|
||||||
|
// Define output language
|
||||||
|
if (empty($conf->global->MAIN_DISABLE_PDF_AUTOUPDATE))
|
||||||
|
{
|
||||||
|
$outputlangs = $langs;
|
||||||
|
$newlang = '';
|
||||||
|
if ($conf->global->MAIN_MULTILANGS && empty($newlang) && GETPOST('lang_id', 'aZ09')) $newlang = GETPOST('lang_id', 'aZ09');
|
||||||
|
if ($conf->global->MAIN_MULTILANGS && empty($newlang)) $newlang = $object->thirdparty->default_lang;
|
||||||
|
if (!empty($newlang)) {
|
||||||
|
$outputlangs = new Translate("", $conf);
|
||||||
|
$outputlangs->setDefaultLang($newlang);
|
||||||
|
}
|
||||||
|
$model = $object->modelpdf;
|
||||||
|
$ret = $object->fetch($id); // Reload to get new records
|
||||||
|
|
||||||
|
$object->generateDocument($model, $outputlangs, 0, 0, 0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
setEventMessages($object->error, $object->errors, 'errors');
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -599,6 +628,9 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
|
|||||||
{
|
{
|
||||||
if ($object->status == $object::STATUS_VALIDATED || $object->status == $object::STATUS_INPROGRESS)
|
if ($object->status == $object::STATUS_VALIDATED || $object->status == $object::STATUS_INPROGRESS)
|
||||||
{
|
{
|
||||||
|
// TODO If production is already > 1, show only close, else show cancel
|
||||||
|
print '<a class="butAction" href="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'&action=confirm_produced&confirm=yes">'.$langs->trans("Close").'</a>'."\n";
|
||||||
|
|
||||||
print '<a class="butActionDelete" href="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'&action=confirm_close&confirm=yes">'.$langs->trans("Cancel").'</a>'."\n";
|
print '<a class="butActionDelete" href="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'&action=confirm_close&confirm=yes">'.$langs->trans("Cancel").'</a>'."\n";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -1049,12 +1049,15 @@ class Project extends CommonObject
|
|||||||
if (isset($this->public)) {
|
if (isset($this->public)) {
|
||||||
$label .= '<br><b>'.$langs->trans("Visibility").":</b> ".($this->public ? $langs->trans("SharedProject") : $langs->trans("PrivateProject"));
|
$label .= '<br><b>'.$langs->trans("Visibility").":</b> ".($this->public ? $langs->trans("SharedProject") : $langs->trans("PrivateProject"));
|
||||||
}
|
}
|
||||||
if (!empty($this->thirdparty_name))
|
if (!empty($this->thirdparty_name)) {
|
||||||
$label .= ($label ? '<br>' : '').'<b>'.$langs->trans('ThirdParty').': </b>'.$this->thirdparty_name; // The space must be after the : to not being explode when showing the title in img_picto
|
$label .= ($label ? '<br>' : '').'<b>'.$langs->trans('ThirdParty').': </b>'.$this->thirdparty_name; // The space must be after the : to not being explode when showing the title in img_picto
|
||||||
if (!empty($this->dateo))
|
}
|
||||||
|
if (!empty($this->dateo)) {
|
||||||
$label .= ($label ? '<br>' : '').'<b>'.$langs->trans('DateStart').': </b>'.dol_print_date($this->dateo, 'day'); // The space must be after the : to not being explode when showing the title in img_picto
|
$label .= ($label ? '<br>' : '').'<b>'.$langs->trans('DateStart').': </b>'.dol_print_date($this->dateo, 'day'); // The space must be after the : to not being explode when showing the title in img_picto
|
||||||
if (!empty($this->datee))
|
}
|
||||||
|
if (!empty($this->datee)) {
|
||||||
$label .= ($label ? '<br>' : '').'<b>'.$langs->trans('DateEnd').': </b>'.dol_print_date($this->datee, 'day'); // The space must be after the : to not being explode when showing the title in img_picto
|
$label .= ($label ? '<br>' : '').'<b>'.$langs->trans('DateEnd').': </b>'.dol_print_date($this->datee, 'day'); // The space must be after the : to not being explode when showing the title in img_picto
|
||||||
|
}
|
||||||
if ($moreinpopup) $label .= '<br>'.$moreinpopup;
|
if ($moreinpopup) $label .= '<br>'.$moreinpopup;
|
||||||
if (isset($this->status)) {
|
if (isset($this->status)) {
|
||||||
$label .= '<br><b>'.$langs->trans("Status").":</b> ".$this->getLibStatut(5);
|
$label .= '<br><b>'.$langs->trans("Status").":</b> ".$this->getLibStatut(5);
|
||||||
@ -1225,9 +1228,9 @@ class Project extends CommonObject
|
|||||||
}
|
}
|
||||||
|
|
||||||
return ($userAccess ? $userAccess : -1);
|
return ($userAccess ? $userAccess : -1);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Return array of projects a user has permission on, is affected to, or all projects
|
* Return array of projects a user has permission on, is affected to, or all projects
|
||||||
*
|
*
|
||||||
* @param User $user User object
|
* @param User $user User object
|
||||||
@ -1237,8 +1240,8 @@ class Project extends CommonObject
|
|||||||
* @param string $filter additionnal filter on project (statut, ref, ...)
|
* @param string $filter additionnal filter on project (statut, ref, ...)
|
||||||
* @return array or string Array of projects id, or string with projects id separated with "," if list is 1
|
* @return array or string Array of projects id, or string with projects id separated with "," if list is 1
|
||||||
*/
|
*/
|
||||||
public function getProjectsAuthorizedForUser($user, $mode = 0, $list = 0, $socid = 0, $filter = '')
|
public function getProjectsAuthorizedForUser($user, $mode = 0, $list = 0, $socid = 0, $filter = '')
|
||||||
{
|
{
|
||||||
$projects = array();
|
$projects = array();
|
||||||
$temp = array();
|
$temp = array();
|
||||||
|
|
||||||
@ -1328,9 +1331,9 @@ public function getProjectsAuthorizedForUser($user, $mode = 0, $list = 0, $socid
|
|||||||
}
|
}
|
||||||
|
|
||||||
return $projects;
|
return $projects;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Load an object from its id and create a new one in database
|
* Load an object from its id and create a new one in database
|
||||||
*
|
*
|
||||||
* @param User $user User making the clone
|
* @param User $user User making the clone
|
||||||
@ -1345,8 +1348,8 @@ public function getProjectsAuthorizedForUser($user, $mode = 0, $list = 0, $socid
|
|||||||
* @param int $newthirdpartyid New thirdparty id
|
* @param int $newthirdpartyid New thirdparty id
|
||||||
* @return int New id of clone
|
* @return int New id of clone
|
||||||
*/
|
*/
|
||||||
public function createFromClone(User $user, $fromid, $clone_contact = false, $clone_task = true, $clone_project_file = false, $clone_task_file = false, $clone_note = true, $move_date = true, $notrigger = 0, $newthirdpartyid = 0)
|
public function createFromClone(User $user, $fromid, $clone_contact = false, $clone_task = true, $clone_project_file = false, $clone_task_file = false, $clone_note = true, $move_date = true, $notrigger = 0, $newthirdpartyid = 0)
|
||||||
{
|
{
|
||||||
global $langs, $conf;
|
global $langs, $conf;
|
||||||
|
|
||||||
$error = 0;
|
$error = 0;
|
||||||
@ -1589,17 +1592,17 @@ public function createFromClone(User $user, $fromid, $clone_contact = false, $cl
|
|||||||
dol_syslog(get_class($this)."::createFromClone nbError: ".$error." error : ".$this->error, LOG_ERR);
|
dol_syslog(get_class($this)."::createFromClone nbError: ".$error." error : ".$this->error, LOG_ERR);
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Shift project task date from current date to delta
|
* Shift project task date from current date to delta
|
||||||
*
|
*
|
||||||
* @param integer $old_project_dt_start Old project start date
|
* @param integer $old_project_dt_start Old project start date
|
||||||
* @return int 1 if OK or < 0 if KO
|
* @return int 1 if OK or < 0 if KO
|
||||||
*/
|
*/
|
||||||
public function shiftTaskDate($old_project_dt_start)
|
public function shiftTaskDate($old_project_dt_start)
|
||||||
{
|
{
|
||||||
global $user, $langs, $conf;
|
global $user, $langs, $conf;
|
||||||
|
|
||||||
$error=0;
|
$error=0;
|
||||||
@ -1657,19 +1660,19 @@ public function shiftTaskDate($old_project_dt_start)
|
|||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
return $result;
|
return $result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
|
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
|
||||||
/**
|
/**
|
||||||
* Associate element to a project
|
* Associate element to a project
|
||||||
*
|
*
|
||||||
* @param string $tableName Table of the element to update
|
* @param string $tableName Table of the element to update
|
||||||
* @param int $elementSelectId Key-rowid of the line of the element to update
|
* @param int $elementSelectId Key-rowid of the line of the element to update
|
||||||
* @return int 1 if OK or < 0 if KO
|
* @return int 1 if OK or < 0 if KO
|
||||||
*/
|
*/
|
||||||
public function update_element($tableName, $elementSelectId)
|
public function update_element($tableName, $elementSelectId)
|
||||||
{
|
{
|
||||||
// phpcs:enable
|
// phpcs:enable
|
||||||
$sql = "UPDATE ".MAIN_DB_PREFIX.$tableName;
|
$sql = "UPDATE ".MAIN_DB_PREFIX.$tableName;
|
||||||
|
|
||||||
@ -1692,10 +1695,10 @@ public function update_element($tableName, $elementSelectId)
|
|||||||
} else {
|
} else {
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
|
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
|
||||||
/**
|
/**
|
||||||
* Associate element to a project
|
* Associate element to a project
|
||||||
*
|
*
|
||||||
* @param string $tableName Table of the element to update
|
* @param string $tableName Table of the element to update
|
||||||
@ -1704,8 +1707,8 @@ public function update_element($tableName, $elementSelectId)
|
|||||||
*
|
*
|
||||||
* @return int 1 if OK or < 0 if KO
|
* @return int 1 if OK or < 0 if KO
|
||||||
*/
|
*/
|
||||||
public function remove_element($tableName, $elementSelectId, $projectfield = 'fk_projet')
|
public function remove_element($tableName, $elementSelectId, $projectfield = 'fk_projet')
|
||||||
{
|
{
|
||||||
// phpcs:enable
|
// phpcs:enable
|
||||||
$sql = "UPDATE ".MAIN_DB_PREFIX.$tableName;
|
$sql = "UPDATE ".MAIN_DB_PREFIX.$tableName;
|
||||||
|
|
||||||
@ -1727,9 +1730,9 @@ public function remove_element($tableName, $elementSelectId, $projectfield = 'fk
|
|||||||
} else {
|
} else {
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Create an intervention document on disk using template defined into PROJECT_ADDON_PDF
|
* Create an intervention document on disk using template defined into PROJECT_ADDON_PDF
|
||||||
*
|
*
|
||||||
* @param string $modele Force template to use ('' by default)
|
* @param string $modele Force template to use ('' by default)
|
||||||
@ -1739,8 +1742,8 @@ public function remove_element($tableName, $elementSelectId, $projectfield = 'fk
|
|||||||
* @param int $hideref Hide ref
|
* @param int $hideref Hide ref
|
||||||
* @return int 0 if KO, 1 if OK
|
* @return int 0 if KO, 1 if OK
|
||||||
*/
|
*/
|
||||||
public function generateDocument($modele, $outputlangs, $hidedetails = 0, $hidedesc = 0, $hideref = 0)
|
public function generateDocument($modele, $outputlangs, $hidedetails = 0, $hidedesc = 0, $hideref = 0)
|
||||||
{
|
{
|
||||||
global $conf,$langs;
|
global $conf,$langs;
|
||||||
|
|
||||||
$langs->load("projects");
|
$langs->load("projects");
|
||||||
@ -1758,10 +1761,10 @@ public function generateDocument($modele, $outputlangs, $hidedetails = 0, $hided
|
|||||||
$modelpath = "core/modules/project/doc/";
|
$modelpath = "core/modules/project/doc/";
|
||||||
|
|
||||||
return $this->commonGenerateDocument($modelpath, $modele, $outputlangs, $hidedetails, $hidedesc, $hideref);
|
return $this->commonGenerateDocument($modelpath, $modele, $outputlangs, $hidedetails, $hidedesc, $hideref);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Load time spent into this->weekWorkLoad and this->weekWorkLoadPerTask for all day of a week of project.
|
* Load time spent into this->weekWorkLoad and this->weekWorkLoadPerTask for all day of a week of project.
|
||||||
* Note: array weekWorkLoad and weekWorkLoadPerTask are reset and filled at each call.
|
* Note: array weekWorkLoad and weekWorkLoadPerTask are reset and filled at each call.
|
||||||
*
|
*
|
||||||
@ -1770,8 +1773,8 @@ public function generateDocument($modele, $outputlangs, $hidedetails = 0, $hided
|
|||||||
* @param int $userid Time spent by a particular user
|
* @param int $userid Time spent by a particular user
|
||||||
* @return int <0 if OK, >0 if KO
|
* @return int <0 if OK, >0 if KO
|
||||||
*/
|
*/
|
||||||
public function loadTimeSpent($datestart, $taskid = 0, $userid = 0)
|
public function loadTimeSpent($datestart, $taskid = 0, $userid = 0)
|
||||||
{
|
{
|
||||||
$error=0;
|
$error=0;
|
||||||
|
|
||||||
$this->weekWorkLoad=array();
|
$this->weekWorkLoad=array();
|
||||||
@ -1823,9 +1826,9 @@ public function loadTimeSpent($datestart, $taskid = 0, $userid = 0)
|
|||||||
dol_syslog(get_class($this)."::fetch ".$this->error, LOG_ERR);
|
dol_syslog(get_class($this)."::fetch ".$this->error, LOG_ERR);
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Load time spent into this->weekWorkLoad and this->weekWorkLoadPerTask for all day of a week of project.
|
* Load time spent into this->weekWorkLoad and this->weekWorkLoadPerTask for all day of a week of project.
|
||||||
* Note: array weekWorkLoad and weekWorkLoadPerTask are reset and filled at each call.
|
* Note: array weekWorkLoad and weekWorkLoadPerTask are reset and filled at each call.
|
||||||
*
|
*
|
||||||
@ -1834,8 +1837,8 @@ public function loadTimeSpent($datestart, $taskid = 0, $userid = 0)
|
|||||||
* @param int $userid Time spent by a particular user
|
* @param int $userid Time spent by a particular user
|
||||||
* @return int <0 if OK, >0 if KO
|
* @return int <0 if OK, >0 if KO
|
||||||
*/
|
*/
|
||||||
public function loadTimeSpentMonth($datestart, $taskid = 0, $userid = 0)
|
public function loadTimeSpentMonth($datestart, $taskid = 0, $userid = 0)
|
||||||
{
|
{
|
||||||
$error = 0;
|
$error = 0;
|
||||||
|
|
||||||
$this->monthWorkLoad = array();
|
$this->monthWorkLoad = array();
|
||||||
@ -1890,18 +1893,18 @@ public function loadTimeSpentMonth($datestart, $taskid = 0, $userid = 0)
|
|||||||
dol_syslog(get_class($this)."::fetch ".$this->error, LOG_ERR);
|
dol_syslog(get_class($this)."::fetch ".$this->error, LOG_ERR);
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
|
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
|
||||||
/**
|
/**
|
||||||
* Load indicators for dashboard (this->nbtodo and this->nbtodolate)
|
* Load indicators for dashboard (this->nbtodo and this->nbtodolate)
|
||||||
*
|
*
|
||||||
* @param User $user Objet user
|
* @param User $user Objet user
|
||||||
* @return WorkboardResponse|int <0 if KO, WorkboardResponse if OK
|
* @return WorkboardResponse|int <0 if KO, WorkboardResponse if OK
|
||||||
*/
|
*/
|
||||||
public function load_board($user)
|
public function load_board($user)
|
||||||
{
|
{
|
||||||
// phpcs:enable
|
// phpcs:enable
|
||||||
global $conf, $langs;
|
global $conf, $langs;
|
||||||
|
|
||||||
@ -1960,10 +1963,10 @@ public function load_board($user)
|
|||||||
$this->error = $this->db->error();
|
$this->error = $this->db->error();
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Function used to replace a thirdparty id with another one.
|
* Function used to replace a thirdparty id with another one.
|
||||||
*
|
*
|
||||||
* @param DoliDB $db Database handler
|
* @param DoliDB $db Database handler
|
||||||
@ -1971,24 +1974,24 @@ public function load_board($user)
|
|||||||
* @param int $dest_id New thirdparty id
|
* @param int $dest_id New thirdparty id
|
||||||
* @return bool
|
* @return bool
|
||||||
*/
|
*/
|
||||||
public static function replaceThirdparty(DoliDB $db, $origin_id, $dest_id)
|
public static function replaceThirdparty(DoliDB $db, $origin_id, $dest_id)
|
||||||
{
|
{
|
||||||
$tables = array(
|
$tables = array(
|
||||||
'projet'
|
'projet'
|
||||||
);
|
);
|
||||||
|
|
||||||
return CommonObject::commonReplaceThirdparty($db, $origin_id, $dest_id, $tables);
|
return CommonObject::commonReplaceThirdparty($db, $origin_id, $dest_id, $tables);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
|
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
|
||||||
/**
|
/**
|
||||||
* Charge indicateurs this->nb pour le tableau de bord
|
* Charge indicateurs this->nb pour le tableau de bord
|
||||||
*
|
*
|
||||||
* @return int <0 if KO, >0 if OK
|
* @return int <0 if KO, >0 if OK
|
||||||
*/
|
*/
|
||||||
public function load_state_board()
|
public function load_state_board()
|
||||||
{
|
{
|
||||||
// phpcs:enable
|
// phpcs:enable
|
||||||
global $user;
|
global $user;
|
||||||
|
|
||||||
@ -2020,16 +2023,16 @@ public function load_state_board()
|
|||||||
$this->error = $this->db->error();
|
$this->error = $this->db->error();
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Is the project delayed?
|
* Is the project delayed?
|
||||||
*
|
*
|
||||||
* @return bool
|
* @return bool
|
||||||
*/
|
*/
|
||||||
public function hasDelay()
|
public function hasDelay()
|
||||||
{
|
{
|
||||||
global $conf;
|
global $conf;
|
||||||
|
|
||||||
if (!($this->statut == self::STATUS_VALIDATED)) return false;
|
if (!($this->statut == self::STATUS_VALIDATED)) return false;
|
||||||
@ -2038,17 +2041,17 @@ public function hasDelay()
|
|||||||
$now = dol_now();
|
$now = dol_now();
|
||||||
|
|
||||||
return ($this->datee ? $this->datee : $this->date_end) < ($now - $conf->projet->warning_delay);
|
return ($this->datee ? $this->datee : $this->date_end) < ($now - $conf->projet->warning_delay);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Charge les informations d'ordre info dans l'objet commande
|
* Charge les informations d'ordre info dans l'objet commande
|
||||||
*
|
*
|
||||||
* @param int $id Id of order
|
* @param int $id Id of order
|
||||||
* @return void
|
* @return void
|
||||||
*/
|
*/
|
||||||
public function info($id)
|
public function info($id)
|
||||||
{
|
{
|
||||||
$sql = 'SELECT c.rowid, datec as datec, tms as datem,';
|
$sql = 'SELECT c.rowid, datec as datec, tms as datem,';
|
||||||
$sql .= ' date_close as datecloture,';
|
$sql .= ' date_close as datecloture,';
|
||||||
$sql .= ' fk_user_creat as fk_user_author, fk_user_close as fk_use_cloture';
|
$sql .= ' fk_user_creat as fk_user_author, fk_user_close as fk_use_cloture';
|
||||||
@ -2086,9 +2089,9 @@ public function info($id)
|
|||||||
{
|
{
|
||||||
dol_print_error($this->db);
|
dol_print_error($this->db);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Sets object to supplied categories.
|
* Sets object to supplied categories.
|
||||||
*
|
*
|
||||||
* Deletes object from existing categories not supplied.
|
* Deletes object from existing categories not supplied.
|
||||||
@ -2098,8 +2101,8 @@ public function info($id)
|
|||||||
* @param int[]|int $categories Category or categories IDs
|
* @param int[]|int $categories Category or categories IDs
|
||||||
* @return void
|
* @return void
|
||||||
*/
|
*/
|
||||||
public function setCategories($categories)
|
public function setCategories($categories)
|
||||||
{
|
{
|
||||||
$type_categ = Categorie::TYPE_PROJECT;
|
$type_categ = Categorie::TYPE_PROJECT;
|
||||||
|
|
||||||
// Handle single category
|
// Handle single category
|
||||||
@ -2144,20 +2147,20 @@ public function setCategories($categories)
|
|||||||
}
|
}
|
||||||
|
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Create an array of tasks of current project
|
* Create an array of tasks of current project
|
||||||
*
|
*
|
||||||
* @param User $user Object user we want project allowed to
|
* @param User $user Object user we want project allowed to
|
||||||
* @return int >0 if OK, <0 if KO
|
* @return int >0 if OK, <0 if KO
|
||||||
*/
|
*/
|
||||||
public function getLinesArray($user)
|
public function getLinesArray($user)
|
||||||
{
|
{
|
||||||
require_once DOL_DOCUMENT_ROOT.'/projet/class/task.class.php';
|
require_once DOL_DOCUMENT_ROOT.'/projet/class/task.class.php';
|
||||||
$taskstatic = new Task($this->db);
|
$taskstatic = new Task($this->db);
|
||||||
|
|
||||||
$this->lines = $taskstatic->getTasksArray(0, $user, $this->id, 0, 0);
|
$this->lines = $taskstatic->getTasksArray(0, $user, $this->id, 0, 0);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user