diff options
author | desperateCoder <echotodevnull@gmail.com> | 2020-10-04 11:46:35 +0300 |
---|---|---|
committer | desperateCoder <echotodevnull@gmail.com> | 2020-10-04 11:46:35 +0300 |
commit | 9df2a2897b571a9d5c31fcc7d1a1218f7214aa7e (patch) | |
tree | c3dc4a428163320e73ce3006e70095fd241fc5a3 /app/src/main/java/it/niedermann/nextcloud/deck/persistence | |
parent | 16a0a85c60d72cb30721acd3576153000c60997e (diff) |
#663 implemented filtered archiving
Diffstat (limited to 'app/src/main/java/it/niedermann/nextcloud/deck/persistence')
-rw-r--r-- | app/src/main/java/it/niedermann/nextcloud/deck/persistence/sync/adapters/db/DataBaseAdapter.java | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/app/src/main/java/it/niedermann/nextcloud/deck/persistence/sync/adapters/db/DataBaseAdapter.java b/app/src/main/java/it/niedermann/nextcloud/deck/persistence/sync/adapters/db/DataBaseAdapter.java index 17ab2a419..f08cbe2a1 100644 --- a/app/src/main/java/it/niedermann/nextcloud/deck/persistence/sync/adapters/db/DataBaseAdapter.java +++ b/app/src/main/java/it/niedermann/nextcloud/deck/persistence/sync/adapters/db/DataBaseAdapter.java @@ -268,6 +268,9 @@ public class DataBaseAdapter { throw new IllegalArgumentException("Xou need to add your new EDueType value\"" + filter.getDueType() + "\" here!"); } } + if (filter.getArchiveStatus() != FilterInformation.EArchiveStatus.ALL) { + query.append(" and c.archived = "+(filter.getArchiveStatus() == FilterInformation.EArchiveStatus.ARCHIVED ? 1 : 0)); + } query.append(" and status<>3 order by `order`, createdAt asc;"); return new SimpleSQLiteQuery(query.toString(), args.toArray()); } |