View Issue Details

This bug affects 1 person(s).
 4
IDProjectCategoryView StatusLast Update
19924Bug reportsSurvey editingpublic2025-01-27 14:10
Reporter2BITS_PL Assigned Totibor.pacalat  
PrioritynoneSeverityminor 
Status closedResolutionfixed 
Product Version6.6.x 
Summary19924: Multiplication of #pjaxClickInhibitor DOM element when switching response view mode in LimeSurvey
Description

There is an issue in LimeSurvey when toggling between response view modes (Expanded/Compact). Each toggle causes the #pjaxClickInhibitor DOM element to multiply. With every subsequent toggle, these elements stack on top of each other, significantly increasing script execution time. This issue can also be reproduced on the official demo instance: demo.limesurvey.org.

Steps To Reproduce

Steps to Reproduce:

  1. Go to demo.limesurvey.org.
  2. Log in as an administrator and open any survey with responses.
  3. Navigate to the responses list for the selected survey.
  4. Switch the response view mode from "Expanded" to "Compact" or vice versa.
  5. Repeat the toggle several times.
  6. Observe in the DOM inspector that the #pjaxClickInhibitor element multiplies with each toggle.

Expected Behavior:
When switching response view modes, the #pjaxClickInhibitor element should be properly managed, and its count in the DOM should remain constant (one element).

Attachments:

  1. diff file containing changes to resolve the issue.
  2. Information about the required regeneration of the adminsidepanel.js file using Gulp.

Additional Information:
The diff file includes fixes that need to be applied to the repository. After applying these changes, you must run Gulp in the assets/packages/adminsidepanel directory to regenerate the adminsidepanel.js file.

TagsNo tags attached.
Attached Files
fixed_multiplication_pjaxClickInhibitor.diff (826 bytes)   
 assets/packages/adminsidepanel/src/adminsidepanelmain.js | 1 +
 1 file changed, 1 insertion(+)

diff --git a/assets/packages/adminsidepanel/src/adminsidepanelmain.js b/assets/packages/adminsidepanel/src/adminsidepanelmain.js
index 9327b109..8628267b 100644
--- a/assets/packages/adminsidepanel/src/adminsidepanelmain.js
+++ b/assets/packages/adminsidepanel/src/adminsidepanelmain.js
@@ -98,6 +98,7 @@ const Lsadminsidepanel = (userid, surveyid) => {
         $(document)
             .off("pjax:send.panelloading")
             .on("pjax:send.panelloading", () => {
+                $("#pjaxClickInhibitor").remove();
                 $('<div id="pjaxClickInhibitor"></div>').appendTo("body");
                 $(
                     ".ui-dialog.ui-corner-all.ui-widget.ui-widget-content.ui-front.ui-draggable.ui-resizable"
Bug heat4
Complete LimeSurvey version number (& build)6.9.0
I will donate to the project if issue is resolvedNo
Browser
Database type & versionSQL Server 2022
Server OS (if known)
Webserver software & version (if known)
PHP Versionv8.1.29 NTS x64

Users monitoring this issue

There are no users monitoring this issue.

Activities

gabrieljenik

gabrieljenik

2025-01-17 20:57

manager   ~81842

What was multiplying was the handle of the click on the Display Mode selector
https://github.com/LimeSurvey/LimeSurvey/pull/4138/files

LimeBot

LimeBot

2025-01-27 14:10

administrator   ~81910

Fixed in Release 6.10.2+250127

Issue History

Date Modified Username Field Change
2025-01-08 10:41 2BITS_PL New Issue
2025-01-08 10:41 2BITS_PL File Added: fixed_multiplication_pjaxClickInhibitor.diff
2025-01-08 14:41 tibor.pacalat Assigned To => gabrieljenik
2025-01-08 14:41 tibor.pacalat Status new => assigned
2025-01-17 20:57 gabrieljenik Assigned To gabrieljenik => DenisChenu
2025-01-17 20:57 gabrieljenik Status assigned => ready for code review
2025-01-17 20:57 gabrieljenik Note Added: 81842
2025-01-17 20:57 gabrieljenik Bug heat 0 => 2
2025-01-20 07:38 DenisChenu Assigned To DenisChenu => tibor.pacalat
2025-01-20 07:38 DenisChenu Status ready for code review => ready for testing
2025-01-20 17:26 tibor.pacalat Status ready for testing => resolved
2025-01-20 17:26 tibor.pacalat Resolution open => fixed
2025-01-27 14:10 LimeBot Note Added: 81910
2025-01-27 14:10 LimeBot Status resolved => closed
2025-01-27 14:10 LimeBot Bug heat 2 => 4