[ZBX-13680] Cloning an action attempts to reuse opcommand ID Created: 2018 Mar 31  Updated: 2024 Apr 10  Resolved: 2018 May 13

Status: Closed
Project: ZABBIX BUGS AND ISSUES
Component/s: API (A), Frontend (F)
Affects Version/s: 3.0.15, 3.4.8, 4.0.0alpha5
Fix Version/s: 3.0.17rc1, 3.4.10rc1, 4.0.0alpha7, 4.0 (plan)

Type: Problem report Priority: Trivial
Reporter: Alexey Pustovalov Assignee: Andrejs Griščenko
Resolution: Fixed Votes: 0
Labels: action, remotecommands
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Attachments: PNG File Screen Shot 2018-03-31 at 13.35.53.png     PNG File Selection_424.png    
Issue Links:
Duplicate
Team: Team B
Team: Team B
Sprint: Sprint 31, Sprint 32, Sprint 33
Story Points: 0.5

 Description   
  1. have an action with a remote command operation
  2. open it's properties, switch to the "Operations" tab, click 'edit' for the operation
  3. click the "Clone" button at the bottom
  4. click "Update" in the "Operation details" block
  5. switch to the "Action" tab, modify the name
  6. click the "Add" button at the bottom

Observe an error like this :

    Error in query [INSERT INTO opcommand (type,execute_on,command,operationid) VALUES ('0','1','test command','11')] [Duplicate entry '11' for key 'PRIMARY']
    SQL statement execution has failed "INSERT INTO opcommand (type,execute_on,command,operationid) VALUES ('0','1','test command','11')". [actionconf.php:231 ? CFrontendApiWrapper->create() ? CApiWrapper->__call() ? CFrontendApiWrapper->callMethod() ? CApiWrapper->callMethod() ? CFrontendApiWrapper->callClientMethod() ? CLocalApiClient->callMethod() ? call_user_func_array() ? CAction->create() ? CAction->addOperations() ? DB::insert() ? DB::exception() in include/classes/db/DB.php:468]


 Comments   
Comment by Andrejs Griščenko [ 2018 Apr 06 ]

(1) [F] No translation strings changes.

sasha CLOSED

Comment by Andrejs Griščenko [ 2018 Apr 06 ]

Fixed in development branches:

  • for 3.0 - svn://svn.zabbix.com/branches/dev/ZBX-13680
  • for 3.4 - svn://svn.zabbix.com/branches/dev/ZBX-13680_3.4
Comment by Andrejs Griščenko [ 2018 Apr 18 ]

Fixed in:

  • 3.0.17rc1 r79847
  • 3.4.10rc1 r80693
  • 4.0.0alpha7(trunk) r80694
Generated at Fri Apr 19 11:48:47 EEST 2024 using Jira 9.12.4#9120004-sha1:625303b708afdb767e17cb2838290c41888e9ff0.