New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.
Already on GitHub? Sign in to your account
Delete tickets via admin interface as job #214
Comments
Hi @MDXDave - since Zammad is revision-proof this is not an option. |
I understand your objection, but at least admins should have the possibility to delete tickets. |
As an admin you can use the |
I know that this is possible with rails, but it would be easier to delete tickets within Zammad. 馃憤 |
At least scheduler should be able to do it. |
I think @thorsteneckel decision is right. You should be able to audit old tickets after years so deletion shouldn't be an option at least in the UI. For testing zammad (even a production setup) you should be fine using the rails console which is not hard as well! |
I use this function in OTRS to delete spam tickets after 30 days in our spam queue. Sure, one could do this from the command line but its not so comfortable like to do it from the scheduler. |
I see your point! We will implement it in the near future. Maybe something like https://github.com/rubysherpas/paranoia is useful in this context. |
It's not only about hiding the tickets,it's also about removing the unnecessary stuff from the DB. Currently our spam to ham mail ratio is pretty high, but we detect most of the messages with spamassassin. Nevertheless, email filtering happens after downloading the mails from the POP3, so the tickets have already been created the database and the disk space allocated (speaking of OTRS) |
Is there any documentation of how to get in and use the rails console? I'm currently testing a lot around, and I'd like to get rid of all the tickets "Test1", "Test2", "Test3" etc ;-) |
shell> rails c If you use the Zammad RPM, you need to do: |
Thanks, works like a charm! |
in case you're looking for a way to delete all tickets but some you can use this method: tickets_to_keep = [1, 2, 3] # enter the ids of all tickets you want to keep
(Ticket.all.pluck(:id) - tickets_to_keep).each { |id| Ticket.find(id).destroy } this will delete all tickets except Ticket with id |
Still no news about it? 馃槓 |
commit fb089fd8a0ee2cfeb6882e993bbfe637847ddea5 Author: Rolf Schmidt <rolf.schmidt@znuny.com> Date: Wed May 3 17:12:24 2017 +0200 Moved touch_reference_by_params to own function. commit 13971570cba1bf0f437ff810792755c3bfbd8f1c Author: Rolf Schmidt <rolf.schmidt@znuny.com> Date: Wed May 3 16:20:15 2017 +0200 Added code to perform ticket deletions in frontend of zammad. commit 88a079b6a5558cbfe5f4b76bfdc74cde98d79e6a Author: Rolf Schmidt <rolf.schmidt@znuny.com> Date: Wed May 3 14:03:29 2017 +0200 Fixed test. commit c6e44a2027834f2f70b17f821232cbf8501a3f5c Author: Rolf Schmidt <rolf.schmidt@znuny.com> Date: Wed May 3 13:57:31 2017 +0200 Fixed pod. commit f0ed06be7d6759cbfeabaac5e2653b84f9646967 Author: Rolf Schmidt <rolf.schmidt@znuny.com> Date: Wed May 3 13:55:34 2017 +0200 Improved ticket object to kill all associations on destroy (#214). commit 56d39992045f5bf8fb91721f3fe7497d5d49f880 Merge: cbbbc00 7647849 Author: Rolf Schmidt <rolf.schmidt@znuny.com> Date: Wed May 3 09:38:03 2017 +0200 Merge branch 'develop' into private-bugfix-214-rs-develop commit cbbbc0039e9ecdaab185e7bc2fdee046e636eb3a Author: Rolf Schmidt <rolf.schmidt@znuny.com> Date: Tue May 2 16:53:21 2017 +0200 Reworked file structure of concerns. - can (new methods) - checks (events, pre/post function checks) - has (model related functions and events)
Hi, I tried to use the "delete" action and therefore created a macro to use it. Sadly, it's doing nothing with the ticket, only causing lots of activity in the logs (see below). I'm using the current develop Debian package 1.6.1-1502058507.b2ece283.jessie Messages from the log file are like attached when I select the delete macro for one ticket (Id 2394 in this case):
|
@rolfschmidt Is your delete action already available in the latest official Zammad2? I can't find it.
|
Hey guys, @strangechoice : yes this was a mistake. The delete action will be only supported in the scheduler. We removed the action from the macros. @passboltUser : Please take a look at the scheduler. Best regards, |
@rolfschmidt Thanks. Unfortunately I can't get it running, don't see the |
Hello @passboltUser ,
Best regards, Hallo @passboltUser ,
Gru脽 |
@rolfschmidt Danke, habs gefunden. So werden alle bestimmten Tickets gel枚scht? Kann man auch einzelne l枚schen? Wir haben geschlossene Tickets die wir mit einem Added eng: Thanks, found it. But this way all tickets are doing to be deleted? It it possible to delete individual ones? We have closed tickets which we tagged 'Tutorial' to lookup later how a problem was once solved (these tickes can be displayed nicely in a self-created view). |
Hi @passboltUser , I'm sorry guys, i added the english translation for my last post. We should write english here on the issue tracker. |
Ok, thanks, I'll try. (also added english translation) |
Thanks, it works 馃憤 I added a second condition where I filtered by tickets which contain the tag "Spam" (so one has to add the tag "Spam" to such tickets). |
First, i am happy to be able to delete tickets that creates loops - like tickets out techs sent to wrong email address of the client and the NDR keeps returning as we try to close the ticket since there is a close notification... The problem we face is having a batch of 30 different numbered tickets that has loops or other issues that we want to delete and the schedule way is a way to learn what is patience... one manually entered ticket number for every 5 minutes... My 2c is that there should be an admin-only, password protected form to delete tickets directly at the web interface. |
I think i have found a nice solution with the great genius tools Zammad has to offer but it is not working for some reason :) Now all i have to do is find the tickets i want to delete and enter this text string at the new field i have created. The problem is it does not work (not deleting tickets) :) Another option to accomplish deletion of many tickets without the need to wait for the schedule timer is to have a "run now" button for the scheduler :) |
Hi @DjMagicFingers , Best regards, |
This is already part of Zammad and has been adressed with: 7d2409b |
Please make it possible to delete tickets and not just close them. 馃樃
The text was updated successfully, but these errors were encountered: