@@ -1657,7 +1657,7 @@ |
||
| 1657 | 1657 | 70 => array('lang' => 'interventions', 'enabled' => isModEnabled("intervention"), 'perm' => $user->hasRight('fichinter', 'creer'), 'label' => 'AddIntervention', 'url' => '/fichinter/card.php?action=create&projectid=' . $object->id . '&socid=' . $object->socid), |
| 1658 | 1658 | 80 => array('lang' => 'contracts', 'enabled' => isModEnabled("contract"), 'perm' => $user->hasRight('contrat', 'creer'), 'label' => 'AddContract', 'url' => '/contrat/card.php?action=create&projectid=' . $object->id . '&socid=' . $object->socid), |
| 1659 | 1659 | 90 => array('lang' => 'trips', 'enabled' => isModEnabled("expensereport"), 'perm' => $user->hasRight('expensereport', 'creer'), 'label' => 'AddTrip', 'url' => '/expensereport/card.php?action=create&projectid=' . $object->id . '&socid=' . $object->socid), |
| 1660 | - 100 => array('lang' => 'donations', 'enabled' => isModEnabled("don"), 'perm' => $user->hasRight('don', 'creer'), 'label' => 'AddDonation', 'url' => '/don/card.php?action=create&projectid=' . $object->id . '&socid=' . $object->socid), |
|
| 1660 | + 100 => array('lang' => 'donations', 'enabled' => isModEnabled("don"), 'perm' => $user->hasRight('don', 'creer'), 'label' => 'AddDonation', 'url' => '/don/card.php?action=create&projectid=' . $object->id . '&socid=' . $object->socid), |
|
| 1661 | 1661 | ); |
| 1662 | 1662 | |
| 1663 | 1663 | $params = array('backtopage' => $_SERVER["PHP_SELF"] . '?id=' . $object->id); |
@@ -111,7 +111,7 @@ discard block |
||
| 111 | 111 | |
| 112 | 112 | $permissiontoadd = $user->hasRight('projet', 'creer'); |
| 113 | 113 | $permissiontodelete = $user->hasRight('projet', 'supprimer'); |
| 114 | -$permissiondellink = $user->hasRight('projet', 'creer'); // Used by the include of actions_dellink.inc.php |
|
| 114 | +$permissiondellink = $user->hasRight('projet', 'creer'); // Used by the include of actions_dellink.inc.php |
|
| 115 | 115 | |
| 116 | 116 | |
| 117 | 117 | /* |
@@ -162,7 +162,7 @@ discard block |
||
| 162 | 162 | $action = ''; |
| 163 | 163 | } |
| 164 | 164 | |
| 165 | - include DOL_DOCUMENT_ROOT . '/core/actions_dellink.inc.php'; // Must be include, not include_once |
|
| 165 | + include DOL_DOCUMENT_ROOT . '/core/actions_dellink.inc.php'; // Must be include, not include_once |
|
| 166 | 166 | |
| 167 | 167 | // Action setdraft object |
| 168 | 168 | if ($action == 'confirm_setdraft' && $confirm == 'yes' && $permissiontoadd) { |
@@ -52,7 +52,7 @@ discard block |
||
| 52 | 52 | $confirm = GETPOST('confirm', 'alpha'); |
| 53 | 53 | $cancel = GETPOST('cancel', 'aZ09'); |
| 54 | 54 | $contextpage = GETPOST('contextpage', 'aZ') ? GETPOST('contextpage', 'aZ') : 'projecttasklist'; |
| 55 | -$backtopage = GETPOST('backtopage', 'alpha'); // if not set, a default page will be used |
|
| 55 | +$backtopage = GETPOST('backtopage', 'alpha'); // if not set, a default page will be used |
|
| 56 | 56 | //$backtopageforcancel = GETPOST('backtopageforcancel', 'alpha'); // if not set, $backtopage will be used |
| 57 | 57 | //$backtopagejsfields = GETPOST('backtopagejsfields', 'alpha'); |
| 58 | 58 | $optioncss = GETPOST('optioncss', 'aZ'); |
@@ -94,20 +94,20 @@ discard block |
||
| 94 | 94 | $search_date_start_startmonth = GETPOSTINT('search_date_start_startmonth'); |
| 95 | 95 | $search_date_start_startyear = GETPOSTINT('search_date_start_startyear'); |
| 96 | 96 | $search_date_start_startday = GETPOSTINT('search_date_start_startday'); |
| 97 | -$search_date_start_start = dol_mktime(0, 0, 0, $search_date_start_startmonth, $search_date_start_startday, $search_date_start_startyear); // Use tzserver |
|
| 97 | +$search_date_start_start = dol_mktime(0, 0, 0, $search_date_start_startmonth, $search_date_start_startday, $search_date_start_startyear); // Use tzserver |
|
| 98 | 98 | $search_date_start_endmonth = GETPOSTINT('search_date_start_endmonth'); |
| 99 | 99 | $search_date_start_endyear = GETPOSTINT('search_date_start_endyear'); |
| 100 | 100 | $search_date_start_endday = GETPOSTINT('search_date_start_endday'); |
| 101 | -$search_date_start_end = dol_mktime(23, 59, 59, $search_date_start_endmonth, $search_date_start_endday, $search_date_start_endyear); // Use tzserver |
|
| 101 | +$search_date_start_end = dol_mktime(23, 59, 59, $search_date_start_endmonth, $search_date_start_endday, $search_date_start_endyear); // Use tzserver |
|
| 102 | 102 | |
| 103 | 103 | $search_date_end_startmonth = GETPOSTINT('search_date_end_startmonth'); |
| 104 | 104 | $search_date_end_startyear = GETPOSTINT('search_date_end_startyear'); |
| 105 | 105 | $search_date_end_startday = GETPOSTINT('search_date_end_startday'); |
| 106 | -$search_date_end_start = dol_mktime(0, 0, 0, $search_date_end_startmonth, $search_date_end_startday, $search_date_end_startyear); // Use tzserver |
|
| 106 | +$search_date_end_start = dol_mktime(0, 0, 0, $search_date_end_startmonth, $search_date_end_startday, $search_date_end_startyear); // Use tzserver |
|
| 107 | 107 | $search_date_end_endmonth = GETPOSTINT('search_date_end_endmonth'); |
| 108 | 108 | $search_date_end_endyear = GETPOSTINT('search_date_end_endyear'); |
| 109 | 109 | $search_date_end_endday = GETPOSTINT('search_date_end_endday'); |
| 110 | -$search_date_end_end = dol_mktime(23, 59, 59, $search_date_end_endmonth, $search_date_end_endday, $search_date_end_endyear); // Use tzserver |
|
| 110 | +$search_date_end_end = dol_mktime(23, 59, 59, $search_date_end_endmonth, $search_date_end_endday, $search_date_end_endyear); // Use tzserver |
|
| 111 | 111 | |
| 112 | 112 | //if (! $user->rights->projet->all->lire) $mine=1; // Special for projects |
| 113 | 113 | |
@@ -185,7 +185,7 @@ discard block |
||
| 185 | 185 | include DOL_DOCUMENT_ROOT . '/core/tpl/extrafields_list_array_fields.tpl.php'; |
| 186 | 186 | |
| 187 | 187 | $arrayfields = dol_sort_array($arrayfields, 'position'); |
| 188 | -'@phan-var-force array<string,array{label:string,checked?:int<0,1>,position?:int,help?:string}> $arrayfields'; // dol_sort_array looses type for Phan |
|
| 188 | +'@phan-var-force array<string,array{label:string,checked?:int<0,1>,position?:int,help?:string}> $arrayfields'; // dol_sort_array looses type for Phan |
|
| 189 | 189 | |
| 190 | 190 | $varpage = empty($contextpage) ? $_SERVER["PHP_SELF"] : $contextpage; |
| 191 | 191 | |
@@ -187,7 +187,7 @@ |
||
| 187 | 187 | } else { |
| 188 | 188 | $error++; |
| 189 | 189 | } |
| 190 | - } elseif (! ($contactid > 0)) { |
|
| 190 | + } elseif (!($contactid > 0)) { |
|
| 191 | 191 | $error++; |
| 192 | 192 | $langs->load("errors"); |
| 193 | 193 | setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("Contact")), null, 'errors'); |
@@ -766,7 +766,7 @@ |
||
| 766 | 766 | if (empty($totalforeachday[$tmpday])) { |
| 767 | 767 | $totalforeachday[$tmpday] = empty($projectstatic->weekWorkLoad[$tmpday]) ? 0 : $projectstatic->weekWorkLoad[$tmpday]; |
| 768 | 768 | } else { |
| 769 | - $totalforeachday[$tmpday] += empty($projectstatic->weekWorkLoad[$tmpday]) ? 0 : $projectstatic->weekWorkLoad[$tmpday]; |
|
| 769 | + $totalforeachday[$tmpday] += empty($projectstatic->weekWorkLoad[$tmpday]) ? 0 : $projectstatic->weekWorkLoad[$tmpday]; |
|
| 770 | 770 | } |
| 771 | 771 | } |
| 772 | 772 | } |
@@ -147,38 +147,38 @@ discard block |
||
| 147 | 147 | $search_date_start_startmonth = GETPOSTINT('search_date_start_startmonth'); |
| 148 | 148 | $search_date_start_startyear = GETPOSTINT('search_date_start_startyear'); |
| 149 | 149 | $search_date_start_startday = GETPOSTINT('search_date_start_startday'); |
| 150 | -$search_date_start_start = dol_mktime(0, 0, 0, $search_date_start_startmonth, $search_date_start_startday, $search_date_start_startyear); // Use tzserver |
|
| 150 | +$search_date_start_start = dol_mktime(0, 0, 0, $search_date_start_startmonth, $search_date_start_startday, $search_date_start_startyear); // Use tzserver |
|
| 151 | 151 | $search_date_start_endmonth = GETPOSTINT('search_date_start_endmonth'); |
| 152 | 152 | $search_date_start_endyear = GETPOSTINT('search_date_start_endyear'); |
| 153 | 153 | $search_date_start_endday = GETPOSTINT('search_date_start_endday'); |
| 154 | -$search_date_start_end = dol_mktime(23, 59, 59, $search_date_start_endmonth, $search_date_start_endday, $search_date_start_endyear); // Use tzserver |
|
| 154 | +$search_date_start_end = dol_mktime(23, 59, 59, $search_date_start_endmonth, $search_date_start_endday, $search_date_start_endyear); // Use tzserver |
|
| 155 | 155 | |
| 156 | 156 | $search_date_end_startmonth = GETPOSTINT('search_date_end_startmonth'); |
| 157 | 157 | $search_date_end_startyear = GETPOSTINT('search_date_end_startyear'); |
| 158 | 158 | $search_date_end_startday = GETPOSTINT('search_date_end_startday'); |
| 159 | -$search_date_end_start = dol_mktime(0, 0, 0, $search_date_end_startmonth, $search_date_end_startday, $search_date_end_startyear); // Use tzserver |
|
| 159 | +$search_date_end_start = dol_mktime(0, 0, 0, $search_date_end_startmonth, $search_date_end_startday, $search_date_end_startyear); // Use tzserver |
|
| 160 | 160 | $search_date_end_endmonth = GETPOSTINT('search_date_end_endmonth'); |
| 161 | 161 | $search_date_end_endyear = GETPOSTINT('search_date_end_endyear'); |
| 162 | 162 | $search_date_end_endday = GETPOSTINT('search_date_end_endday'); |
| 163 | -$search_date_end_end = dol_mktime(23, 59, 59, $search_date_end_endmonth, $search_date_end_endday, $search_date_end_endyear); // Use tzserver |
|
| 163 | +$search_date_end_end = dol_mktime(23, 59, 59, $search_date_end_endmonth, $search_date_end_endday, $search_date_end_endyear); // Use tzserver |
|
| 164 | 164 | |
| 165 | 165 | $search_date_creation_startmonth = GETPOSTINT('search_date_creation_startmonth'); |
| 166 | 166 | $search_date_creation_startyear = GETPOSTINT('search_date_creation_startyear'); |
| 167 | 167 | $search_date_creation_startday = GETPOSTINT('search_date_creation_startday'); |
| 168 | -$search_date_creation_start = dol_mktime(0, 0, 0, $search_date_creation_startmonth, $search_date_creation_startday, $search_date_creation_startyear); // Use tzserver |
|
| 168 | +$search_date_creation_start = dol_mktime(0, 0, 0, $search_date_creation_startmonth, $search_date_creation_startday, $search_date_creation_startyear); // Use tzserver |
|
| 169 | 169 | $search_date_creation_endmonth = GETPOSTINT('search_date_creation_endmonth'); |
| 170 | 170 | $search_date_creation_endyear = GETPOSTINT('search_date_creation_endyear'); |
| 171 | 171 | $search_date_creation_endday = GETPOSTINT('search_date_creation_endday'); |
| 172 | -$search_date_creation_end = dol_mktime(23, 59, 59, $search_date_creation_endmonth, $search_date_creation_endday, $search_date_creation_endyear); // Use tzserver |
|
| 172 | +$search_date_creation_end = dol_mktime(23, 59, 59, $search_date_creation_endmonth, $search_date_creation_endday, $search_date_creation_endyear); // Use tzserver |
|
| 173 | 173 | |
| 174 | 174 | $search_date_modif_startmonth = GETPOSTINT('search_date_modif_startmonth'); |
| 175 | 175 | $search_date_modif_startyear = GETPOSTINT('search_date_modif_startyear'); |
| 176 | 176 | $search_date_modif_startday = GETPOSTINT('search_date_modif_startday'); |
| 177 | -$search_date_modif_start = dol_mktime(0, 0, 0, $search_date_modif_startmonth, $search_date_modif_startday, $search_date_modif_startyear); // Use tzserver |
|
| 177 | +$search_date_modif_start = dol_mktime(0, 0, 0, $search_date_modif_startmonth, $search_date_modif_startday, $search_date_modif_startyear); // Use tzserver |
|
| 178 | 178 | $search_date_modif_endmonth = GETPOSTINT('search_date_modif_endmonth'); |
| 179 | 179 | $search_date_modif_endyear = GETPOSTINT('search_date_modif_endyear'); |
| 180 | 180 | $search_date_modif_endday = GETPOSTINT('search_date_modif_endday'); |
| 181 | -$search_date_modif_end = dol_mktime(23, 59, 59, $search_date_modif_endmonth, $search_date_modif_endday, $search_date_modif_endyear); // Use tzserver |
|
| 181 | +$search_date_modif_end = dol_mktime(23, 59, 59, $search_date_modif_endmonth, $search_date_modif_endday, $search_date_modif_endyear); // Use tzserver |
|
| 182 | 182 | |
| 183 | 183 | $search_category_array = array(); |
| 184 | 184 | |
@@ -264,14 +264,14 @@ discard block |
||
| 264 | 264 | |
| 265 | 265 | $object->fields = dol_sort_array($object->fields, 'position'); |
| 266 | 266 | $arrayfields = dol_sort_array($arrayfields, 'position'); |
| 267 | -'@phan-var-force array<string,array{label:string,checked?:int<0,1>,position?:int,help?:string}> $arrayfields'; // dol_sort_array looses type for Phan |
|
| 267 | +'@phan-var-force array<string,array{label:string,checked?:int<0,1>,position?:int,help?:string}> $arrayfields'; // dol_sort_array looses type for Phan |
|
| 268 | 268 | |
| 269 | 269 | // Add a groupby field. Set $groupby and $groupbyvalues. |
| 270 | 270 | // TODO Move this into a inc file |
| 271 | 271 | $groupbyvalues = array(); |
| 272 | 272 | if ($mode == 'kanban') { |
| 273 | 273 | $groupbyold = null; |
| 274 | - $groupby = GETPOST('groupby', 'aZ09'); // Example: $groupby = 'p.fk_opp_status' or $groupby = 'p.fk_statut' |
|
| 274 | + $groupby = GETPOST('groupby', 'aZ09'); // Example: $groupby = 'p.fk_opp_status' or $groupby = 'p.fk_statut' |
|
| 275 | 275 | $groupbyfield = preg_replace('/[a-z]\./', '', $groupby); |
| 276 | 276 | if (!empty($object->fields[$groupbyfield]['alias'])) { |
| 277 | 277 | $groupbyfield = $object->fields[$groupbyfield]['alias']; |
@@ -1192,7 +1192,7 @@ discard block |
||
| 1192 | 1192 | } |
| 1193 | 1193 | |
| 1194 | 1194 | $varpage = empty($contextpage) ? $_SERVER["PHP_SELF"] : $contextpage; |
| 1195 | -$htmlofselectarray = $form->multiSelectArrayWithCheckbox('selectedfields', $arrayfields, $varpage, getDolGlobalString('MAIN_CHECKBOX_LEFT_COLUMN')); // This also change content of $arrayfields with user setup |
|
| 1195 | +$htmlofselectarray = $form->multiSelectArrayWithCheckbox('selectedfields', $arrayfields, $varpage, getDolGlobalString('MAIN_CHECKBOX_LEFT_COLUMN')); // This also change content of $arrayfields with user setup |
|
| 1196 | 1196 | $selectedfields = ($mode != 'kanban' ? $htmlofselectarray : ''); |
| 1197 | 1197 | $selectedfields .= (count($arrayofmassactions) ? $form->showCheckAddButtons('checkforselect', 1) : ''); |
| 1198 | 1198 | |
@@ -1653,7 +1653,7 @@ discard block |
||
| 1653 | 1653 | |
| 1654 | 1654 | if (!empty($groupby)) { |
| 1655 | 1655 | if (is_null($groupbyold)) { |
| 1656 | - print '<div class="box-flex-container-columns kanban">'; // Start div for all kanban columns |
|
| 1656 | + print '<div class="box-flex-container-columns kanban">'; // Start div for all kanban columns |
|
| 1657 | 1657 | } |
| 1658 | 1658 | // Start kanban column |
| 1659 | 1659 | if (is_null($obj->$groupbyfield)) { |
@@ -1669,7 +1669,7 @@ discard block |
||
| 1669 | 1669 | // |
| 1670 | 1670 | //var_dump($groupbyvalues); |
| 1671 | 1671 | //var_dump($obj->$groupbyfield); |
| 1672 | - print '<div class="box-flex-container-column kanban column" data-html="column_' . preg_replace('/[^a-z0-9]/', '', $groupbyvalue) . '">'; // Start new column |
|
| 1672 | + print '<div class="box-flex-container-column kanban column" data-html="column_' . preg_replace('/[^a-z0-9]/', '', $groupbyvalue) . '">'; // Start new column |
|
| 1673 | 1673 | } |
| 1674 | 1674 | $groupbyold = $groupbyvalue; |
| 1675 | 1675 | } elseif ($i == 0) { |
@@ -352,10 +352,10 @@ discard block |
||
| 352 | 352 | } |
| 353 | 353 | |
| 354 | 354 | if ($action == 'confirm_deleteline' && $confirm == "yes" && ($user->hasRight('projet', 'time') || $user->hasRight('projet', 'all', 'creer'))) { |
| 355 | - $object->fetchTimeSpent(GETPOSTINT('lineid')); // load properties like $object->timespent_xxx |
|
| 355 | + $object->fetchTimeSpent(GETPOSTINT('lineid')); // load properties like $object->timespent_xxx |
|
| 356 | 356 | |
| 357 | 357 | if (in_array($object->timespent_fk_user, $childids) || $user->hasRight('projet', 'all', 'creer')) { |
| 358 | - $result = $object->delTimeSpent($user); // delete line with $object->timespent_id |
|
| 358 | + $result = $object->delTimeSpent($user); // delete line with $object->timespent_id |
|
| 359 | 359 | |
| 360 | 360 | if ($result < 0) { |
| 361 | 361 | $langs->load("errors"); |
@@ -480,7 +480,7 @@ discard block |
||
| 480 | 480 | $arrayoftasks = array(); |
| 481 | 481 | foreach ($toselect as $key => $value) { |
| 482 | 482 | // Get userid, timepent |
| 483 | - $object->fetchTimeSpent($value); // $value is ID of 1 line in timespent table |
|
| 483 | + $object->fetchTimeSpent($value); // $value is ID of 1 line in timespent table |
|
| 484 | 484 | $arrayoftasks[$object->timespent_fk_user][(int) $object->timespent_fk_product]['timespent'] += $object->timespent_duration; |
| 485 | 485 | $arrayoftasks[$object->timespent_fk_user][(int) $object->timespent_fk_product]['totalvaluetodivideby3600'] += ($object->timespent_duration * $object->timespent_thm); |
| 486 | 486 | } |
@@ -672,7 +672,7 @@ discard block |
||
| 672 | 672 | $arrayoftasks = array(); |
| 673 | 673 | foreach ($toselect as $key => $value) { |
| 674 | 674 | // Get userid, timepent |
| 675 | - $object->fetchTimeSpent($value); // Call method to get list of timespent for a timespent line id (We use the utiliy method found into Task object) |
|
| 675 | + $object->fetchTimeSpent($value); // Call method to get list of timespent for a timespent line id (We use the utiliy method found into Task object) |
|
| 676 | 676 | // $object->id is now the task id |
| 677 | 677 | $arrayoftasks[$object->id][(int) $object->timespent_fk_product]['timespent'] += $object->timespent_duration; |
| 678 | 678 | $arrayoftasks[$object->id][(int) $object->timespent_fk_product]['totalvaluetodivideby3600'] += ($object->timespent_duration * $object->timespent_thm); |
@@ -1133,7 +1133,7 @@ discard block |
||
| 1133 | 1133 | } |
| 1134 | 1134 | |
| 1135 | 1135 | $param = ($withproject ? '&withproject=1' : ''); |
| 1136 | - $param .= ($param ? '&' : '') . 'id=' . $object->id; // ID of task |
|
| 1136 | + $param .= ($param ? '&' : '') . 'id=' . $object->id; // ID of task |
|
| 1137 | 1137 | $linkback = $withproject ? '<a href="' . constant('BASE_URL') . '/projet/tasks.php?id=' . $projectstatic->id . '">' . $langs->trans("BackToList") . '</a>' : ''; |
| 1138 | 1138 | |
| 1139 | 1139 | if (!GETPOST('withproject') || empty($projectstatic->id)) { |
@@ -1268,10 +1268,10 @@ discard block |
||
| 1268 | 1268 | // Definition of fields for list |
| 1269 | 1269 | $arrayfields = array(); |
| 1270 | 1270 | $arrayfields['t.element_date'] = array('label' => $langs->trans("Date"), 'checked' => 1); |
| 1271 | - $arrayfields['p.fk_soc'] = array('label' => $langs->trans("ThirdParty"), 'type' => 'integer:Societe:/societe/class/societe.class.php:1','checked' => 1); |
|
| 1271 | + $arrayfields['p.fk_soc'] = array('label' => $langs->trans("ThirdParty"), 'type' => 'integer:Societe:/societe/class/societe.class.php:1', 'checked' => 1); |
|
| 1272 | 1272 | $arrayfields['s.name_alias'] = array('label' => $langs->trans("AliasNameShort"), 'type' => 'integer:Societe:/societe/class/societe.class.php:1'); |
| 1273 | 1273 | if ((empty($id) && empty($ref)) || !empty($projectidforalltimes)) { // Not a dedicated task |
| 1274 | - if (! empty($allprojectforuser)) { |
|
| 1274 | + if (!empty($allprojectforuser)) { |
|
| 1275 | 1275 | $arrayfields['p.project_ref'] = ['label' => $langs->trans('RefProject'), 'checked' => 1]; |
| 1276 | 1276 | $arrayfields['p.project_label'] = ['label' => $langs->trans('ProjectLabel'), 'checked' => 1]; |
| 1277 | 1277 | } |
@@ -1290,7 +1290,7 @@ discard block |
||
| 1290 | 1290 | include DOL_DOCUMENT_ROOT . '/core/tpl/extrafields_list_array_fields.tpl.php'; |
| 1291 | 1291 | |
| 1292 | 1292 | $arrayfields = dol_sort_array($arrayfields, 'position'); |
| 1293 | - '@phan-var-force array<string,array{label:string,checked?:int<0,1>,position?:int,help?:string}> $arrayfields'; // dol_sort_array looses type for Phan |
|
| 1293 | + '@phan-var-force array<string,array{label:string,checked?:int<0,1>,position?:int,help?:string}> $arrayfields'; // dol_sort_array looses type for Phan |
|
| 1294 | 1294 | |
| 1295 | 1295 | $param = ''; |
| 1296 | 1296 | if (!empty($contextpage) && $contextpage != $_SERVER["PHP_SELF"]) { |
@@ -144,7 +144,7 @@ discard block |
||
| 144 | 144 | |
| 145 | 145 | if ($action == 'confirm_merge' && $confirm == 'yes' && $user->hasRight('projet', 'creer')) { |
| 146 | 146 | $task_origin_id = GETPOSTINT('task_origin'); |
| 147 | - $task_origin = new Task($db); // The Task that we will delete |
|
| 147 | + $task_origin = new Task($db); // The Task that we will delete |
|
| 148 | 148 | |
| 149 | 149 | if ($task_origin_id <= 0) { |
| 150 | 150 | $langs->load('errors'); |
@@ -260,7 +260,7 @@ discard block |
||
| 260 | 260 | |
| 261 | 261 | $title = $object->ref; |
| 262 | 262 | if (!empty($withproject)) { |
| 263 | - $title .= ' | ' . $langs->trans("Project") . (!empty($projectstatic->ref) ? ': ' . $projectstatic->ref : '') ; |
|
| 263 | + $title .= ' | ' . $langs->trans("Project") . (!empty($projectstatic->ref) ? ': ' . $projectstatic->ref : ''); |
|
| 264 | 264 | } |
| 265 | 265 | $help_url = ''; |
| 266 | 266 | |
@@ -149,7 +149,7 @@ |
||
| 149 | 149 | |
| 150 | 150 | $title = $object->ref . ' - ' . $langs->trans("Contacts"); |
| 151 | 151 | if (!empty($withproject)) { |
| 152 | - $title .= ' | ' . $langs->trans("Project") . (!empty($projectstatic->ref) ? ': ' . $projectstatic->ref : '') ; |
|
| 152 | + $title .= ' | ' . $langs->trans("Project") . (!empty($projectstatic->ref) ? ': ' . $projectstatic->ref : ''); |
|
| 153 | 153 | } |
| 154 | 154 | $help_url = ''; |
| 155 | 155 | |
@@ -96,7 +96,7 @@ discard block |
||
| 96 | 96 | $search_date_endday = GETPOSTINT('search_date_endday'); |
| 97 | 97 | $search_date_endmonth = GETPOSTINT('search_date_endmonth'); |
| 98 | 98 | $search_date_endyear = GETPOSTINT('search_date_endyear'); |
| 99 | -$search_date_start = dol_mktime(0, 0, 0, $search_date_startmonth, $search_date_startday, $search_date_startyear); // Use tzserver |
|
| 99 | +$search_date_start = dol_mktime(0, 0, 0, $search_date_startmonth, $search_date_startday, $search_date_startyear); // Use tzserver |
|
| 100 | 100 | $search_date_end = dol_mktime(23, 59, 59, $search_date_endmonth, $search_date_endday, $search_date_endyear); |
| 101 | 101 | $search_datelimit_startday = GETPOSTINT('search_datelimit_startday'); |
| 102 | 102 | $search_datelimit_startmonth = GETPOSTINT('search_datelimit_startmonth'); |
@@ -186,7 +186,7 @@ discard block |
||
| 186 | 186 | |
| 187 | 187 | $object->fields = dol_sort_array($object->fields, 'position'); |
| 188 | 188 | $arrayfields = dol_sort_array($arrayfields, 'position'); |
| 189 | -'@phan-var-force array<string,array{label:string,checked?:int<0,1>,position?:int,help?:string}> $arrayfields'; // dol_sort_array looses type for Phan |
|
| 189 | +'@phan-var-force array<string,array{label:string,checked?:int<0,1>,position?:int,help?:string}> $arrayfields'; // dol_sort_array looses type for Phan |
|
| 190 | 190 | |
| 191 | 191 | $permissiontoread = $user->hasRight('projet', 'lire'); |
| 192 | 192 | $permissiontocreate = $user->hasRight('projet', 'creer'); |
@@ -589,7 +589,7 @@ discard block |
||
| 589 | 589 | // Direct jump if only one record found |
| 590 | 590 | if ($num == 1 && getDolGlobalString('MAIN_SEARCH_DIRECT_OPEN_IF_ONLY_ONE') && $search_all) { |
| 591 | 591 | $obj = $db->fetch_object($resql); |
| 592 | - $id = $obj->id; // in select, task id has been aliases into 'id' |
|
| 592 | + $id = $obj->id; // in select, task id has been aliases into 'id' |
|
| 593 | 593 | header("Location: " . constant('BASE_URL') . '/projet/tasks/task.php?id=' . $id . '&withproject=1'); |
| 594 | 594 | exit; |
| 595 | 595 | } |
@@ -598,7 +598,7 @@ discard block |
||
| 598 | 598 | // Output page |
| 599 | 599 | // -------------------------------------------------------------------- |
| 600 | 600 | |
| 601 | -llxHeader('', $title, $help_url, '', 0, 0, $morejs, $morecss, '', 'bodyforlist'); // Can use also classforhorizontalscrolloftabs instead of bodyforlist for no horizontal scroll |
|
| 601 | +llxHeader('', $title, $help_url, '', 0, 0, $morejs, $morecss, '', 'bodyforlist'); // Can use also classforhorizontalscrolloftabs instead of bodyforlist for no horizontal scroll |
|
| 602 | 602 | |
| 603 | 603 | $arrayofselected = is_array($toselect) ? $toselect : array(); |
| 604 | 604 | |
@@ -837,7 +837,7 @@ discard block |
||
| 837 | 837 | } |
| 838 | 838 | |
| 839 | 839 | $varpage = empty($contextpage) ? $_SERVER["PHP_SELF"] : $contextpage; |
| 840 | -$htmlofselectarray = $form->multiSelectArrayWithCheckbox('selectedfields', $arrayfields, $varpage, getDolGlobalString('MAIN_CHECKBOX_LEFT_COLUMN')); // This also change content of $arrayfields with user setup |
|
| 840 | +$htmlofselectarray = $form->multiSelectArrayWithCheckbox('selectedfields', $arrayfields, $varpage, getDolGlobalString('MAIN_CHECKBOX_LEFT_COLUMN')); // This also change content of $arrayfields with user setup |
|
| 841 | 841 | $selectedfields = ($mode != 'kanban' ? $htmlofselectarray : ''); |
| 842 | 842 | $selectedfields .= (count($arrayofmassactions) ? $form->showCheckAddButtons('checkforselect', 1) : ''); |
| 843 | 843 | |