[ZBX-5665] Unusable code in TriggerPrototype methods Created: 2012 Oct 07  Updated: 2017 May 30  Resolved: 2012 Oct 16

Status: Closed
Project: ZABBIX BUGS AND ISSUES
Component/s: API (A)
Affects Version/s: 2.0.3
Fix Version/s: 2.0.4rc1, 2.1.0

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


 Description   

Some code should be removed from the TriggerPrototype module:

delete method:

  • DB:delete('events', ....
    the trigger prototypes do not generate events
  • DB::delete('sysmaps_elements', ...
    the trigger prototype doesn't join the screen
  • actions disabling code and deleting action conditions

get method:

  • withUnacknowledgedEvents option
  • withAcknowledgedEvents option
  • lastChangeSince option
  • lastChangeTill option
  • only_true option

Something else?



 Comments   
Comment by Alexander Vladishev [ 2012 Oct 08 ]

Same problems with GraphPrototype:

delete method:

  • DB::delete('screens_items', ...
  • DB::delete('profiles', ...
Comment by Alexey Fukalov [ 2012 Oct 11 ]

svn://svn.zabbix.com/branches/dev/ZBX-5665

Comment by Alexey Fukalov [ 2012 Oct 11 ]

Also fixed bug when delete trigger prototype and created triggers are not deleted.

Comment by Toms (Inactive) [ 2012 Oct 15 ]

(1) in CGraphPrototype delete() method comment missing type for $graphids

Vedmak RESOLVED r30856.

tomtom CLOSED

Comment by Toms (Inactive) [ 2012 Oct 15 ]

(2) in CGraphPrototype checkInput()method comment - it is OK to give 'true' as return type if function always returns true.
Samples: http://manual.phpdoc.org/HTMLSmartyConverter/HandS/phpDocumentor/tutorial_tags.return.pkg.html

Vedmak I think it's incorrect example there. Description says there should be type of variable not value.

tomtom CLOSED

Comment by Toms (Inactive) [ 2012 Oct 15 ]

(3) Message 'Cannot delete trigger prototype.' in CTriggerPrototype should be something like 'Cannot delete trigger prototype child triggers.'.

Vedmak RESOLVED r30856.

tomtom CLOSED

Comment by Toms (Inactive) [ 2012 Oct 15 ]

(4) Comment for CItemPrototype delete() method is wrong

Vedmak RESOLVED r30856.

tomtom CLOSED

Comment by Toms (Inactive) [ 2012 Oct 16 ]

Review my changes, if OK merge

Comment by Alexey Fukalov [ 2012 Oct 16 ]

Fixed in 2.0.4rc1 r30859, pre-2.1.0 r30860.

Comment by Pavels Jelisejevs (Inactive) [ 2012 Oct 16 ]

(5) Please add this to the API changelog:

"Also fixed bug when delete trigger prototype and created triggers are not deleted."

Vedmak CLOSED

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