nathan...@users.adullact.net
unread,Apr 8, 2026, 11:53:36 AMApr 8Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to openmairi...@googlegroups.com
Author: nathanaelhoun
Date: 2026-04-08 17:53:33 +0200 (Wed, 08 Apr 2026)
New Revision: 22876
Modified:
branches/10920_EVO_opti_listing_task/data/pgsql/v6.20.0.dev0.sql
branches/10920_EVO_opti_listing_task/sql/pgsql/task.inc.php
Log:
feat: optimisation du listing des taches
Modified: branches/10920_EVO_opti_listing_task/data/pgsql/v6.20.0.dev0.sql
===================================================================
--- branches/10920_EVO_opti_listing_task/data/pgsql/v6.20.0.dev0.sql 2026-04-08 15:39:18 UTC (rev 22875)
+++ branches/10920_EVO_opti_listing_task/data/pgsql/v6.20.0.dev0.sql 2026-04-08 15:53:33 UTC (rev 22876)
@@ -13,3 +13,14 @@
--
-- END / [#10886] Matrice DIT / taches sortantes autorisees
--
+
+
+--
+-- BEGIN / [#10920] Optimiser le listing des tâches
+--
+
+CREATE INDEX IF NOT EXISTS task_category_type_idx ON openads.task (category, type);
+
+--
+-- END / [#10920] Optimiser le listing des tâches
+--
Modified: branches/10920_EVO_opti_listing_task/sql/pgsql/task.inc.php
===================================================================
--- branches/10920_EVO_opti_listing_task/sql/pgsql/task.inc.php 2026-04-08 15:39:18 UTC (rev 22875)
+++ branches/10920_EVO_opti_listing_task/sql/pgsql/task.inc.php 2026-04-08 15:53:33 UTC (rev 22876)
@@ -187,14 +187,21 @@
'libelle' => __("type"),
'type' => 'select',
'subtype' => 'sqlselect',
- 'sql' => 'SELECT
- DISTINCT(type),
- '.$template_case_traduction_type.'
- FROM
- '.DB_PREFIXE.'task
- WHERE
- task.category = \''. $category .'\'
- ORDER BY type ASC',
+ 'sql' => sprintf(<<<'SQL'
+ SELECT
+ type,
+ %2$s
+ FROM
+ %1$stask
+ WHERE
+ task.category = '%3$s'
+ GROUP BY type
+ ORDER BY type ASC
+ SQL,
+ DB_PREFIXE,
+ $template_case_traduction_type,
+ $category,
+ ),
),
'state' => array(
@@ -297,6 +304,6 @@
'task.comment as "'.__("commentaire").'"',
);
-$selection = " WHERE LOWER(task.category) = '".PLATAU."'";
+$selection = " WHERE task.category = '".PLATAU."'";
$tri="ORDER BY task.task ASC NULLS LAST";