Closed tonobo closed 3 years ago
Hello @tonobo, I'll validate this on a vanilla system and get back to you.
@rkaldung I can confirm this behaviour. I can provide a simple patch in a few minutes...
@reneeb Thanks, I can confirm this too
Or to be more clear: It depends on the order of the requested TicketIDs. In the case described above, everything is ok as the ticket with more articles is requested first. But all tickets requested after the ticket with less articles will show the lower bounds:
So ticket 1: 12 articles ticket 2: 7 articles
Request 1: ArticleLimit: 100, TicketIDs: [1,2] --> everything is ok Request 2: ArticleLimit: 100, TicketIDs: [2, 1] --> Ticket 1 shows only 7 articles
Nice. :+1:
@tonobo @reneeb
Thank you very much. The fix from @reneeb will be part of release 6.0.33.
Fixed in rel-6_0_33.
Expected behavior
The ArticleLimit should be applied per Ticket
Actual behavior
When passing multiple TicketIDs via SOAP in TicketGet request in addtion with an ArticleLimit, then the article limit seems to be overwritten in TicketGet loop.
I guess that's the reason for it: https://github.com/znuny/Znuny/blob/rel-6_0/Kernel/GenericInterface/Operation/Ticket/TicketGet.pm#L429
Sample Request:
How to reprocude
Insert 2 ticket with different amount of articles. Assume ticket
1
has 12 articles and2
has only 7.Query:
TicketGet[1, 2]
=> articles:{1 => 7, 2 => 7}
Query:TicketGet[1]
=> articles:{1 => 12}
Query:TicketGet[2]
=> articles:{1 => 7}
Environment