[ZBX-8874] Incorrect focus field in LLD rule settings causes adding flexible interval in most browsers Created: 2014 Oct 08  Updated: 2017 May 30  Resolved: 2015 Jan 06

Status: Closed
Project: ZABBIX BUGS AND ISSUES
Component/s: Frontend (F)
Affects Version/s: 2.4.1
Fix Version/s: 2.4.4rc1, 2.5.0

Type: Incident report Priority: Blocker
Reporter: Alexey Pustovalov Assignee: Unassigned
Resolution: Fixed Votes: 0
Labels: itemconfigform, regression
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Duplicate

 Description   

To reproduce the problem. Open existing LLD rule or create new LLD rule, put mouse cursor to item "Name" field and press Enter key.
You will see how new flexible interval will be added with default/example options.



 Comments   
Comment by Alexander Vladishev [ 2014 Oct 09 ]

Cannot reproduce with Firefox and Chrome (2.2.6 and pre-2.2.7 r49694).

Please add more information how to reproduce the issue.

Comment by Pavels Jelisejevs (Inactive) [ 2014 Oct 09 ]

Tried IE11, works fine as well.

Comment by Pavels Jelisejevs (Inactive) [ 2014 Oct 10 ]

The bug is reproducible in the LLD rule form.

Comment by Krists Krigers (Inactive) [ 2014 Oct 16 ]

Fixed and committed in r49943, svn://svn.zabbix.com/branches/dev/ZBX-8874 (copy of branches/2.4).

Comment by Ivo Kurzemnieks [ 2014 Oct 16 ]

(1) String changes?

kristsk No string changes. RESOLVED.

iivs CLOSED.

Comment by Ivo Kurzemnieks [ 2014 Oct 16 ]

(2) Macros tab in Host and Template forms no longer work. Start typing beginning with {... and form submits

kristsk RESOLVED in r49961.

iivs CLOSED.

Comment by Ivo Kurzemnieks [ 2014 Oct 16 ]

(3) Host and Template forms: placing cursor in different fields, gives different results. Placing it in name field, will try to submit form and if no name is entered, it fails with error. It is OK. Placing it in interface field and not providing name, does submit form, but does not give error. If there is no subform, main form should be submitted.

kristsk Fixed the way how keypress handler is attached to inputs and selects. RESOLVED in r49963.

iivs

  • In LLD rule form, when cursor is in flexible interval, submits subform (Add), but In item/item prototype forms, when cursor is in flexible interval, submits main form.
  • In item form (and other simlilar places), when focus is in application select (it's a multiple select), form does not submit (FF only issue). Other selects work fine.
  • Pop-up submits form in its' own window and does not close. Other pop-ups like trigger expression and media, work fine.
    REOPENED.

kristsk Discussed witrh jelisejev and decided to leave FF and popup behavior as they are now. Fixed flexible intervals in LLD form. RESOLVED in r50047.

iivs Please, revert jquery.js file and as we discussed, for now we will not use subforms. So having cursor in flexible interval, we need to submit main form.
REOPENED.

kristsk RESOLVED in r50060.

iivs Almost good. Just few more things:

  • in Latest Data the "main" button (Filter) is determined by order. Maybe it's better to add that 'main' class for it too;
  • init.js: 156 we can use $ instead of jQuery and there is an extra space after { bracket.
  • main.js the new code piece no longer processes subforms, and it's safe to remove the code;
  • maybe we can document on how the main class is created and how it's used. "How it works" section ok? I found at least 3 ways: with makeFormFooter() using first parameter, addClass('main') and useJQueryStyle('main').

REOPENED.

kristsk See some documentation in https://documentation.zabbix.lan/internal/devel_howitworks/default_submit_button_in_forms.
RESOLVED in r50083.

sasha jquery.js was not fully restored

$ md5sum ../../2.4/frontends/php/js/jquery/jquery.js
df6173bad69801a82b84701789ab16c5  ../../2.4/frontends/php/js/jquery/jquery.js
$ md5sum frontends/php/js/jquery/jquery.js
628072e7212db1e8cdacb22b21752cda  frontends/php/js/jquery/jquery.js

iivs Thanks for documenting this. I restored jquery.js using diff. Some extra comment was added at the top of the file. See r50279. Also, as discussed, I made minor corrections to enterSubmit function. Please, review r50286

kristsk CLOSED.

Comment by Ivo Kurzemnieks [ 2014 Oct 29 ]

TESTED,
but close (3) before merging.

Comment by Krists Krigers (Inactive) [ 2014 Oct 31 ]

(4) Added plugin initialization parameter validation in r50323. Please check.

iivs I made minor corrections to your code in r50379

kristsk Looks good. CLOSED.

Comment by Krists Krigers (Inactive) [ 2014 Nov 05 ]

Fixed and merged to

  • 2.4.3rc1 in r50449,
  • 2.5.0 (trunk) in r50450.
Comment by Alexander Vladishev [ 2014 Nov 06 ]

(5) Submit occurs when pressing Enter key on focused button (for example [Clone], [Cancel], [Reset] ...).

REOPENED

iivs Branch to this solution deleted. See (8).
CLOSED.

Comment by Krists Krigers (Inactive) [ 2014 Nov 07 ]

Fixed in r50499, new branch svn://svn.zabbix.com/branches/dev/ZBX-8874 (copy of branches/2.4). RESOLVED.

Comment by Alexei Vladishev [ 2014 Nov 07 ]

(6) Configuration->Actions, new condition "Trigger name= like ". Press Enter key in the trigger name input, the form will be submitted. It should create a new condition before as it worked before.

kristsk RESOLVED in r50701.

iivs Branch to this solution deleted. See (8).
CLOSED.

Comment by Alexander Vladishev [ 2014 Nov 10 ]

(7) Broken Autofill browser functionality. I cannot select data with Enter from Autofill data.

kristsk RESOLVED in r50701.

iivs Branch to this solution deleted. See (8).
CLOSED.

Comment by Alexander Vladishev [ 2014 Nov 17 ]

Undoing changes in r50646 (branches/2.4) and r50647 (trunk).

Comment by Krists Krigers (Inactive) [ 2014 Nov 20 ]

Fixed in r50701, branch svn://svn.zabbix.com/branches/dev/ZBX-8874.

Comment by Ivo Kurzemnieks [ 2015 Jan 06 ]

(8) Provided different solution to fix the original problem in svn://svn.zabbix.com/branches/dev/ZBX-8874 r51396

sasha Thanks! CLOSED

Comment by Ivo Kurzemnieks [ 2015 Jan 06 ]

Fixed in pre-2.4.4rc1 r51402 and pre-2.5.0 (trunk) r51403

Generated at Sat Apr 27 06:18:10 EEST 2024 using Jira 9.12.4#9120004-sha1:625303b708afdb767e17cb2838290c41888e9ff0.