diff --git a/ChangeLog b/ChangeLog
index 0839fd77e95..62d791a670a 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -126,6 +126,115 @@ FIX: When saving an action it didn't save the label based on the type of event i
FIX: when STOCK_CALCULATE_ON_SHIPMENT_NEW: is set, deleting a "closed" shipment now increases stock as expected
FIX: wrong path sociales/index.php doesnt exist anymore
+
+***** ChangeLog for 10.0.1 compared to 10.0.0 *****
+FIX: #10930
+FIX: #10984
+FIX: reposition on "Build backup" button
+FIX: #11400
+FIX: #11412
+FIX: #11460
+FIX: #11463
+FIX: #11466
+FIX: #11492
+FIX: #11498
+FIX: #11505
+FIX: #11506
+FIX: #11507
+FIX: #11509
+FIX: #11537
+FIX: #11543
+FIX: #11553
+FIX: #11576
+FIX: #11584
+FIX: #11590
+FIX: accounting mode must be taken from global conf, because there's no way to choose a mode with interface
+FIX: Add message from public interface
+FIX: add missing hook calls
+FIX: Add warning when setup is strange
+FIX: ajax call for line positioning when CSRFCHECK_WITH_TOKEN is on
+FIX: API return 404 sometimes even if API exists
+FIX: Attachment was lost when we validate an expense report
+FIX: avoid conflict with "$classname" in card.php
+FIX: Bad sql request
+FIX: better compatibility with multicompany transverse mode
+FIX: Better PHP compatibility
+FIX: Block to link with tickets
+FIX: Can't submit a ticket from public interface
+FIX: categories import: prevent mismatch between category type and object type
+FIX: Closing ticket from public interface
+FIX: Column 'paid' missing in expense report
+FIX: compatibility mysql 8. rank is reserved
+FIX: Computed field were not calculated into lists.
+FIX: Content of email for subscription
+FIX: correct error in files with multiple spaces
+FIX: CVE-2019-11199
+FIX: delete of links between objects
+FIX: div not balanced
+FIX: do not return formatted prices in json string
+FIX: duplicate on the check (TODO field $onetrtd not used ?)
+FIX: element name in update_price
+FIX: empty product_use_units in product configuration
+FIX: expedition card: infinite loop for printObjectLine hook if return > 0
+FIX: extrafield loading bug due to assumption that an object is a third party while it may be a contact if MAIN_USE_COMPANY_NAME_OF_CONTACT is set.
+FIX: Fatal error on dol_htmloutput_mesg with corrupted array
+FIX: Fatal situation if payment removed on expense report. Action
+FIX: FEC Format - Missing date_creation in general ledger when you add a new transaction
+FIX: FEC Format - Save translation of the journal label in database & nowrap on amount
+FIX: floating point precision errors in the triggers of the workflow module
+FIX: for #11232
+FIX: format of field with type timestamp
+FIX: fournrprice log for insert
+FIX: help text
+FIX: import filter error
+FIX: __INFOS__ tag not exists
+FIX: issue #9300: install error with PostgreSQL when using custom table prefix
+FIX: Language key
+FIX: Limit of uploaded files (max_post_size was not used)
+FIX: list of balance of leaves
+FIX: minor spelling issues
+FIX: missing "dropdown-icon" replacement
+FIX: Missing field "Conciliated" into bank transaction export
+FIX: missing filter by current contact
+FIX: missing token
+FIX: Missing where on entity
+FIX: move sql request in INNER JOIN
+FIX: name was able to be in field but went back to new line
+FIX: Nowrap on amount
+FIX: Online payment
+FIX: on shipment delete confirm dialog, a new checkbox allows the user to choose if they want their stock re-incremented after the deletion.
+FIX: option EXPORT_LABEL_FOR_SELECT to restore compatibility in export
+FIX: Option THIRDPARTY_SUGGEST_ALSO_ADDRESS_CREATION
+FIX: outdated phpdoc
+FIX: Permission for BOM menu
+FIX: permission to delete a draft purchase order
+FIX: phpcs
+FIX: Position was lost when we edit the line of template invoice
+FIX: product_use_units was set to 0 each time a conf in block other was set
+FIX: propal createFrom hook: undefined parameter attached
+FIX: Responsive of public interface of ticket
+FIX: search by phone pro
+FIX: Setup of TakePos was not possible after a clean install
+FIX: Show list of events on tickets
+FIX: socpeople assigned list in action com list
+FIX: SQL problem on donation & nowrap on amount
+FIX: stock increase on shipment deletion if STOCK_CALCULATE_ON_SHIPMENT_NEW: is set
+FIX: stripe webhook ID constant set
+FIX: summary of time spent in preview tab of projects
+FIX: the feature to bill time spent was not enabled.
+FIX: The new feature to attach document on lines was not correclty
+FIX: The proposed new supplier code does not work
+FIX: this function can not be private
+FIX: tk9877 - PDF rouget requires product.lib.php (otherwise measuring_units_string() is not defined)
+FIX: Update the file index table when we validate/rename a ref.
+FIX: use rounding to compare the amounts
+FIX: We must save code instead of value in database for template invoice modelpdf
+FIX: we need to be able to add freeline with qty between 0 & 1 in supplierorder line
+FIX: We should remove property comments only for project and task api.
+FIX: When saving an action it didn't save the label based on the type of event if the label is empty and the type is customized
+FIX: when STOCK_CALCULATE_ON_SHIPMENT_NEW: is set, deleting a "closed" shipment now increases stock as expected
+FIX: wrong path sociales/index.php doesnt exist anymore
+
***** ChangeLog for 10.0.0 compared to 9.0.0 *****
For Users:
NEW: Module "Ticket" is available as a stable module.
diff --git a/htdocs/core/boxes/box_task.php b/htdocs/core/boxes/box_task.php
index d07792dc991..3a0b2c67af9 100644
--- a/htdocs/core/boxes/box_task.php
+++ b/htdocs/core/boxes/box_task.php
@@ -31,10 +31,10 @@ require_once DOL_DOCUMENT_ROOT."/core/lib/date.lib.php";
*/
class box_task extends ModeleBoxes
{
- public $boxcode="projet";
+ public $boxcode="projettask";
public $boximg="object_projecttask";
public $boxlabel;
- //public $depends = array("projet");
+ public $depends = array("projet");
/**
* @var DoliDB Database handler.
@@ -42,7 +42,7 @@ class box_task extends ModeleBoxes
public $db;
public $param;
- public $enabled = 0; // Disabled because bugged.
+ public $enabled = 1; // enable because fixed ;-).
public $info_box_head = array();
public $info_box_contents = array();
@@ -78,54 +78,110 @@ class box_task extends ModeleBoxes
global $conf, $user, $langs, $db;
$this->max=$max;
-
- $totalMnt = 0;
- $totalnb = 0;
- $totalDuree=0;
- $totalplannedtot=0;
- $totaldurationtot=0;
-
include_once DOL_DOCUMENT_ROOT."/projet/class/task.class.php";
+ include_once DOL_DOCUMENT_ROOT.'/projet/class/project.class.php';
+ require_once DOL_DOCUMENT_ROOT."/core/lib/project.lib.php";
+ $projectstatic = new Project($this->db);
$taskstatic=new Task($db);
+ $form= new Form($db);
+ $cookie_name='boxfilter_task';
+ $boxcontent='';
+
+ $textHead = $langs->trans("CurentlyOpenedTasks");
+
+ $filterValue='all';
+ if(in_array(GETPOST($cookie_name), array('all','im_project_contact','im_task_contact'))){
+ $filterValue = GETPOST($cookie_name);
+ }
+ elseif(!empty($_COOKIE[$cookie_name])){
+ $filterValue = $_COOKIE[$cookie_name];
+ }
- $textHead = $langs->trans("Tasks")." ".date("Y");
- $this->info_box_head = array('text' => $textHead, 'limit'=> dol_strlen($textHead));
+ if($filterValue == 'im_task_contact'){
+ $textHead.= ' : '.$langs->trans("WhichIamLinkedTo");
+ }
+ elseif($filterValue == 'im_project_contact'){
+ $textHead.= ' : '.$langs->trans("WhichIamLinkedToProject");
+ }
+
+
+ $this->info_box_head = array(
+ 'text' => $textHead,
+ 'limit'=> dol_strlen($textHead),
+ 'sublink'=>'',
+ 'subtext'=>$langs->trans("Filter"),
+ 'subpicto'=>'filter.png',
+ 'subclass'=>'linkobject boxfilter',
+ 'target'=>'none' // Set '' to get target="_blank"
+ );
// list the summary of the orders
if ($user->rights->projet->lire) {
- // FIXME fk_statut on a task is not be used. We use the percent. This means this box is useless.
- $sql = "SELECT pt.fk_statut, count(DISTINCT pt.rowid) as nb, sum(ptt.task_duration) as durationtot, sum(pt.planned_workload) as plannedtot";
- $sql.= " FROM ".MAIN_DB_PREFIX."projet_task as pt, ".MAIN_DB_PREFIX."projet_task_time as ptt";
- $sql.= " WHERE pt.datec BETWEEN '".$this->db->idate(dol_get_first_day(date("Y"), 1))."' AND '".$this->db->idate(dol_get_last_day(date("Y"), 12))."'";
- $sql.= " AND pt.rowid = ptt.fk_task";
- $sql.= " GROUP BY pt.fk_statut ";
- $sql.= " ORDER BY pt.fk_statut DESC";
+ $boxcontent.= '