Skip to content

Commit

Permalink
Evarisk#10 [Setup] fix: clean code on the view file
Browse files Browse the repository at this point in the history
  • Loading branch information
evarisk-charles committed Aug 14, 2024
1 parent 9ee0d91 commit 7390fef
Show file tree
Hide file tree
Showing 12 changed files with 1,493 additions and 1,874 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@

- Support & Assistance : [Forum dolibarr.fr](https://dolibarr.fr) / Par mail à [email protected]
- Demo : [Demo DigiKanban](https://demodoli.digirisk.com) - ID: demo - Password: demo
- Documentation : [Wiki DigiKanban](https://wiki.dolibarr.org/index.php/Module_DigiKanban)
- Documentation : [Wiki DigiKanban](https://wiki.dolibarr.org/view/kanban_view.php/Module_DigiKanban)
- Projet GitHub : [Projet DigiKanban](https://github.com/Evarisk/digikanban/projects?query=is%3Aopen)
- Saturne Framework : [Télécharger Saturne](https://dolistore.com/fr/modules/1906-Saturne.html)
- D'autres modules développés par Evarisk disponibles sur [DoliStore.com](https://dolistore.com)
Expand Down
1 change: 1 addition & 0 deletions admin/setup.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@
// Libraries
require_once __DIR__ . '/../class/digikanban.class.php';
require_once __DIR__ . '/../lib/digikanban.lib.php';
require_once __DIR__ . '/../lib/digikanban_functions.lib.php';

// Global variables definitions
global $conf, $db, $langs, $moduleName, $user;
Expand Down
18 changes: 10 additions & 8 deletions check.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@
require_once DOL_DOCUMENT_ROOT.'/core/class/html.formother.class.php';
require_once DOL_DOCUMENT_ROOT.'/core/class/extrafields.class.php';

require_once __DIR__ . '/lib/digikanban_functions.lib.php';

dol_include_once('/digikanban/class/digikanban_checklist.class.php');
dol_include_once('/digikanban/class/digikanban.class.php');
dol_include_once('/digikanban/class/digikanban_tags.class.php');
Expand Down Expand Up @@ -871,13 +873,13 @@
$updatetask = false;
$option_taskurgent = !empty($task->array_options['options_digikanban_taskurgent']) ? $task->array_options['options_digikanban_taskurgent'] : '';
$keytag = !empty($task->array_options['options_digikanban_colomn']) ? $task->array_options['options_digikanban_colomn'] : '';
checkIfNeedToBeTransfered($task, $updatetask, $tobetransferedto, $option_taskurgent);
check_if_need_to_be_transfered($task, $updatetask, $tobetransferedto, $option_taskurgent);

$key = $keytag>0 ? $keytag : 1;


// if(!$obj->dateo || !$obj->datee){
// $html = getTaskelement($obj, $task, $kanban->status_date, 'enattent');
// $html = get_task_element($obj, $task, $kanban->status_date, 'enattent');
// $data['enattent'][]=$html;
// }

Expand All @@ -888,7 +890,7 @@
// $updatetask = 1;
// }

// $html = getTaskelement($obj, $task, $kanban->status_date, 'urgents');
// $html = get_task_element($obj, $task, $kanban->status_date, 'urgents');
// $data['urgents'][] = $html;

// }
Expand All @@ -897,7 +899,7 @@
// $dd = dol_getdate($db->jdate($obj->dateo));
// $dt = dol_mktime(0, 0, 0, $dd['mon'], 1, $dd['year']);

// $html = getTaskelement($obj, $task, $kanban->status_date);
// $html = get_task_element($obj, $task, $kanban->status_date);

// $data['month'.$dt][]=$html;
// }
Expand All @@ -909,7 +911,7 @@
// }

// if($task->array_options['options_digikanban_colomn']>0 || $object->showtaskinfirstcolomn>0){
$html = getTaskelement($obj, $task, $kanban->status_date, 'urgents');
$html = get_task_element($obj, $task, $kanban->status_date, 'urgents');
$data['colomn'.$key][]=$html;
// }

Expand Down Expand Up @@ -1056,7 +1058,7 @@

// $tobetransferedto = 0;
// $updatetask = false;
// checkIfNeedToBeTransfered($task, $updatetask, $tobetransferedto, $option_taskurgent = 0);
// check_if_need_to_be_transfered($task, $updatetask, $tobetransferedto, $option_taskurgent = 0);

// if ($tobetransferedto == 1) {
// $result['error'] = 1;
Expand Down Expand Up @@ -1115,7 +1117,7 @@
}


$titletask = kanbanGetTitleOfCurrentTask($task);
$titletask = kanban_get_title_of_current_task($task);

$result['titletask'] = $titletask;
// $html = "true";
Expand Down Expand Up @@ -1158,7 +1160,7 @@
$html .= '</div>';
$html .= $checklist->selectCheck($id_tache);
}elseif($id_modal){
$html .= selectCheckModal($id_modal);
$html .= select_check_modal($id_modal);
}

$html .= '<div class="kanban_btn_set">';
Expand Down
3 changes: 2 additions & 1 deletion columns/card.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
require_once DOL_DOCUMENT_ROOT.'/core/class/html.form.class.php';

dol_include_once('/digikanban/lib/digikanban.lib.php');
dol_include_once('/digikanban/lib/digikanban_functions.lib.php');
dol_include_once('/digikanban/class/digikanban.class.php');
dol_include_once('/digikanban/class/digikanban_columns.class.php');

Expand Down Expand Up @@ -148,7 +149,7 @@
llxHeader(array(), $modname,'','','','',$morejs,0,0);

$linkback ="";
digikanbanPrepareAdminHead('columns', $linkback, 'title_setup');
digikanban_admin_prepare_head('columns', $linkback, 'title_setup');

$htmlright = "";

Expand Down
3 changes: 2 additions & 1 deletion columns/list.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
dol_include_once('/digikanban/class/digikanban.class.php');
dol_include_once('/digikanban/class/digikanban_columns.class.php');
dol_include_once('/digikanban/lib/digikanban.lib.php');
dol_include_once('/digikanban/lib/digikanban_functions.lib.php');

if (empty($conf->digikanban->enabled) || !$user->rights->digikanban->lire) accessforbidden();

Expand Down Expand Up @@ -231,7 +232,7 @@
llxHeader('', $title, $help_url = '', $target = '', $disablejs = 0, $disablehead = 0, $arrayofjs);

$linkback ="";
digikanbanPrepareAdminHead('columns', $linkback, 'title_setup');
digikanban_admin_prepare_head('columns', $linkback, 'title_setup');


$sql = "SELECT";
Expand Down
2 changes: 1 addition & 1 deletion core/modules/modDigiKanban.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -259,7 +259,7 @@ function __construct($db)
'titre' => 'digikanban',
'prefix' => '<span class="paddingrightonly fa fa-th-list"></span>',
'leftmenu' => 'digikanban',
'url' => '/digikanban/index.php',
'url' => '/digikanban/view/kanban_view.php',
'langs' => 'digikanban@digikanban',
'position' => 1000 + $r,
'enabled' => 1,
Expand Down
Loading

0 comments on commit 7390fef

Please sign in to comment.