Skip to content

[Feature Request] Bulk deletion of completed tasks. #69

Closed

Description

@slevit

Steps to reproduce

  1. Click "Load remaining completed tasks." button.

Expected behaviour

Button or some other control/logic to allow bulk deletion of completed tasks.

Actual behaviour

No button or some other control/logic to allow bulk deletion of completed tasks.

Server configuration

Operating system:
Debian Jesse
Web server:
Lighttpd/1.4.35
Database:
MySql
PHP version:
5.5
Nextcloud version: (see Nextcloud admin page)
11.0.2
Tasks version: (see Nextcloud apps page)
0.9.5
Updated from an older Nextcloud or fresh install:
Fresh
Signing status:
No errors have been found.

Login as admin user into your Nextcloud and access 
http://example.com/index.php/settings/integrity/failed 
paste the results here.

List of activated apps:
Enabled:

  • activity: 2.4.1
  • calendar: 1.5.2
  • comments: 1.1.0
  • contacts: 1.5.3
  • dav: 1.1.1
  • federatedfilesharing: 1.1.1
  • federation: 1.1.1
  • files: 1.6.1
  • files_pdfviewer: 1.0.1
  • files_sharing: 1.1.1
  • files_texteditor: 2.2
  • files_trashbin: 1.1.0
  • files_versions: 1.4.0
  • files_videoplayer: 1.0.0
  • firstrunwizard: 2.0
  • gallery: 16.0.0
  • logreader: 2.0.0
  • lookup_server_connector: 1.0.0
  • nextcloud_announcements: 1.0
  • notifications: 1.0.1
  • password_policy: 1.1.0
  • provisioning_api: 1.1.0
  • rainloop: 4.28.1
  • serverinfo: 1.1.1
  • sharebymail: 1.0.1
  • survey_client: 0.1.5
  • systemtags: 1.1.3
  • tasks: 0.9.5
  • theming: 1.1.1
  • twofactor_backupcodes: 1.0.0
  • updatenotification: 1.1.1
  • workflowengine: 1.1.1
    Disabled:
  • admin_audit
  • encryption
  • external
  • files_accesscontrol
  • files_automatedtagging
  • files_external
  • files_retention
  • templateeditor
  • user_external
  • user_ldap
  • user_saml
If you have access to your command line run e.g.:
sudo -u www-data php occ app:list
from within your Nextcloud installation folder

Activity

  1. ThomasLeister commented on May 22, 2017

    @ThomasLeister

    Would like to have this feature, too!

  2. nachoparker commented on Jul 25, 2017

    @nachoparker
    Member

    please, implement this. Specially given how SLOW the UI gets ATM when you have many tasks

  3. melohr commented on Jun 6, 2018

    @melohr

    I second! I use DAVdroid to sync with a nextcloud server (server and tasks app up to date). Several days ago, I wondered about high battery load (~1.5A) and drain (~2-4%) when syncing. OS monitor showef full load on one CPU core for the OpenTasks Android app. A quick check revealed about 2k items (>95% completed) being synced several times a day.
    Sure, one could argue it's not the server's tasks app error. But in contrast to calendar items (which by the way are handled correctly on the client side), task items not necessarily contain date information and sync cannot be selected specifically during sync to my understanding.
    A "drop completed tasks" button would be perfect for my needs!

  4. changed the title [-]Bulk deletion of completed tasks.[/-] [+][Feature Request] Bulk deletion of completed tasks.[/+] on Jun 19, 2018
  5. JustABoringUser commented on Aug 29, 2018

    @JustABoringUser

    Would this command maybe help to be ran against the database?

    DELETE FROM oc_calendarobjects WHERE calendardata LIKE '%STATUS:COMPLETED%' AND componenttype= 'VTODO'

  6. slevit commented on Aug 29, 2018

    @slevit
    Author

    It would, and, it did. But, the onus shouldn't be on the user (most aren't technically savvy enough) or the DB administrator. Adding a command button to the frontend and your query to the backend shouldn't be too difficult for the developers.

  7. JustABoringUser commented on Aug 29, 2018

    @JustABoringUser

    @slevit I totally agree, just wanted to know if it helps or maybe damages something else. I encountered low performance on android as well, so I will give it a try.

  8. slevit commented on Aug 29, 2018

    @slevit
    Author

    Actually, it's more complicated than that. You'll find the status of a task in the oc_calendarobjects_props table, then you'll have to take the objectid and find a match in the oc_calendarobjects table to determine if it's a VTODO. Only then can you delete the oc_calendarobjects row and all corresponding oc_calendarobjects_props rows. Foreign key constraints would be a big help, but that's a whole other kettle of fish. Backup your DB first and good luck.

  9. raimund-schluessler commented on Aug 29, 2018

    @raimund-schluessler
    Member

    I would strongly advise against messing with your database. The CalDAV tables are only meant to be altered by Nextcloud Server itself via the SabreDAV interface. Running queries against the database is like fiddling on your engine instead of using the gas pedal to accelerate your car. It might work, but the potential to mess things up completly is huge.

    That being said, we will definitely not implement it by putting an sql query somewhere. This app is a CalDAV client, so we have to use the CalDAV interface. We can query the server for all completed tasks (which is done in the "Completed" collection) and then just delete all of them.

  10. JustABoringUser commented on Aug 30, 2018

    @JustABoringUser

    Ok, thanks for your feedback. I definitely won't make any manual changes to the database but, just for your information, the overview for completed tasks in Nextcloud itself (not in the Android app) does not show any tasks for me.

  11. raimund-schluessler commented on Aug 30, 2018

    @raimund-schluessler
    Member

    just for your information, the overview for completed tasks in Nextcloud itself (not in the Android app) does not show any tasks for me.

    Completed tasks are not loaded by default to not slow down the app even more. You can load them for every calendar separately when you select a calendar and click on "Load remaining completed tasks".

    But I guess we could improve the "Completed" view and show a button to load all completed tasks there as well (and one to delete all of them) 😃

  12. JustABoringUser commented on Aug 30, 2018

    @JustABoringUser

    Completed tasks are not loaded by default to not slow down the app even more. You can load them for every calendar separately when you select a calendar and click on "Load remaining completed tasks".

    Unfortunately I do not see the button "Load remaining completed tasks". The list ist completely empty.
    image

  13. raimund-schluessler commented on Aug 30, 2018

    @raimund-schluessler
    Member

    Yes, I didn't make it clear very well. You have to select a calendar (e.g. "Dennis" in your case) and click the button there.

    If no completed tasks are present for a certain calendar, then the calendar will not be shown at all in the completed view, neither will be the button to load the completed tasks. This should be changed.

  14. slevit commented on Aug 30, 2018

    @slevit
    Author
  15. raimund-schluessler commented on Aug 31, 2018

    @raimund-schluessler
    Member

    I currently rewrite the app in Vue.js, because the currently used Angular is outdated and very difficult to maintain. I will implement this feature in the rewritten app. In the meantime you can just delete multiple completed tasks using Thunderbird + Lightning.

  16. nachoparker commented on Sep 1, 2018

    @nachoparker
    Member

    good to know that you are working in the new version! looking forward to it. The current one is almost perfect for me, if it wasn't so slow.

    cheers!

  17. added this to the 1.0.0 milestone on Oct 23, 2018
  18. raimund-schluessler commented on May 20, 2019

    @raimund-schluessler
    Member

    Please have a look at #414

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions