[ZBX-7407] URL eventsource parameter has effect on existing action Created: 2013 Nov 20  Updated: 2017 May 30  Resolved: 2013 Nov 25

Status: Closed
Project: ZABBIX BUGS AND ISSUES
Component/s: API (A), Frontend (F)
Affects Version/s: 2.2.0
Fix Version/s: 2.2.2rc1, 2.3.0

Type: Incident report Priority: Major
Reporter: Alexander Vladishev Assignee: Unassigned
Resolution: Fixed Votes: 0
Labels: urls
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Duplicate
is duplicated by ZBX-7685 action edit form not reset properly Closed

 Description   

User can change action's eventsource by using URL parameter.

For example:
(1) open any trigger action
(2) add into an URL &eventsource=1 and press Enter
(3) save action



 Comments   
Comment by Ivo Kurzemnieks [ 2013 Nov 22 ]

RESOLVED in svn://svn.zabbix.com/branches/dev/ZBX-7407

Comment by Ivo Kurzemnieks [ 2013 Nov 22 ]

(1) hidden field "form_refresh" repeats twice in form

iivs RESOLVED in r40459

jelisejev CLOSED.

Comment by Pavels Jelisejevs (Inactive) [ 2013 Dec 12 ]

(2) I would suggest just ignoring the eventsource parameter for update forms. Otherwise, it makes the validation code more complicated. We do it for most of the parameters.

iivs RESOLVED in r40924

jelisejev CLOSED.

Comment by Pavels Jelisejevs (Inactive) [ 2013 Dec 12 ]

(3) A problem with cloning actions:

1. Open a trigger action configuration form, press clone.
2. Try to save the action, you'll see the "action already exists" error.
3. Change the name of the action and save it again. You'll see the "Field "eventsource" must be missing." error.

iivs RESOLVED in r40924

jelisejev CLOSED.

Comment by Pavels Jelisejevs (Inactive) [ 2013 Dec 12 ]

(4) In actionconf.php:

  • please revert the formatting to the validation code.
  • don't modify the $_REQUEST variable.
  • the "eventsource" parameter is passed to the view file twice in the $data array: under the "eventsource" key and in the "action" array.

iivs RESOLVED in r40924

jelisejev A minor formatting correction in r40939.

iivs REVIEWED.
Thanks!
CLOSED.

Comment by Pavels Jelisejevs (Inactive) [ 2013 Dec 13 ]

TESTED.

Please review (4) before merging.

Comment by Ivo Kurzemnieks [ 2013 Dec 13 ]

Fixed in pre-2.2.2rc1 r40942 and pre-2.3.0 (trunk) r40943

Comment by Pavels Jelisejevs (Inactive) [ 2013 Dec 16 ]

(5) I've updated the API docs, please review:

sasha CLOSED

Generated at Fri Apr 19 06:00:04 EEST 2024 using Jira 9.12.4#9120004-sha1:625303b708afdb767e17cb2838290c41888e9ff0.