[TikiWiki-commits] [Git][tikiwiki/tiki][master] [FIX] Objectlib: Refresh tracker item title on update

"Bruno Kambere \(@kambereBr\) via TikiWiki-cvs" <[email protected]>
Newsgroups gmane.comp.cms.tiki.cvs
Message-ID <6a160cdcf3f5f_381932a09225a@gitlab-sidekiq-low-urgency-cpu-bound-v2-6f449fff7f-r2xw8.mail>

Bruno Kambere pushed to branch master at Tiki Wiki CMS Groupware / Tiki


Commits:
70bdb046 by Josaphat Imani at 2026-05-26T23:54:36+03:00
[FIX] Objectlib: Refresh tracker item title on update
---
* [FIX] Objectlib: Refresh tracker item title on update

See merge request tikiwiki/tiki!10173

- - - - -


2 changed files:

- lib/setup/events.php
- lib/trackers/trackerlib.php


Changes:

=====================================
lib/setup/events.php
=====================================
@@ -104,6 +104,7 @@ function tiki_setup_events()
 
         $events->bind('tiki.trackeritem.create', $defer('trk', 'setup_wiki_fields'));
         $events->bind('tiki.trackeritem.update', $defer('trk', 'update_wiki_fields'));
+        $events->bind('tiki.trackeritem.update', $defer('trk', 'updateTikiObject'));
         $events->bind('tiki.trackeritem.delete', $defer('trk', 'delete_wiki_fields'));
 
         if ($prefs['userTracker'] == 'y') {


=====================================
lib/trackers/trackerlib.php
=====================================
@@ -6390,6 +6390,24 @@ class TrackerLib extends TikiLib
         }
     }
 
+    public function updateTikiObject($args)
+    {
+        $itemId = $args['object'];
+        $item = $this->get_tracker_item($itemId);
+        if (! $item) {
+            return;
+        }
+
+        $objectlib = TikiLib::lib('object');
+        if (! $objectlib->get_object_id('trackeritem', $itemId)) {
+            return;
+        }
+
+        $name = $this->get_isMain_value(null, $itemId);
+        $href = "tiki-view_tracker_item.php?itemId=$itemId&trackerId=" . $item['trackerId'];
+        $objectlib->add_object('trackeritem', $itemId, false, '', $name, $href);
+    }
+
     public function update_create_missing_pages($args)
     {
         global $user;



View it on GitLab: https://gitlab.com/tikiwiki/tiki/-/commit/70bdb04664d3b03ba25806fb30c4bf8ff0f541d6

-- 
View it on GitLab: https://gitlab.com/tikiwiki/tiki/-/commit/70bdb04664d3b03ba25806fb30c4bf8ff0f541d6
You're receiving this email because of your account on gitlab.com. Manage all notifications: https://gitlab.com/-/profile/notifications | Help: https://gitlab.com/help

_______________________________________________
TikiWiki-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/tikiwiki-cvs
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.