Commit Graph

287 Commits

Author SHA1 Message Date
eikek
27fd7a5867 Make sure the empty-trash task is started for all collectives 2021-08-14 20:40:04 +02:00
eikek
50706c3d6d Add a task implementation to delete items 2021-08-14 19:33:18 +02:00
eikek
4901276c66 Change "empty trash" settings for a collective and submit the job 2021-08-14 19:33:15 +02:00
eikek
f999662905 Add routes to restore deleted items 2021-08-14 16:48:03 +02:00
eikek
a7b74bd5ae Allow to search in soft-deleted items
A new query/request parameter can be used to apply a search to only
soft-deleted items.

The query expression `Trashed` has been introduced which selects only
items with state `Deleted`. This is another option an analog to
`ValidItemStates` (both cannot be used together as they would select
no items). This new query node is not added to the parser, because
users may not use it in their own queries - it must be part of the
"fixed" query so the application can control in which subset to search
(it would otherwise be possible to select any items).
2021-08-14 14:53:05 +02:00
eikek
cb777e30c0 Delete items by introducing a deleted state
When deleting items via the http api, they are not deleted anymore but
a new status "Deleted" is set. The collective insights contains now a
count separately for deleted items.
2021-08-14 14:18:03 +02:00
eikek
48d13a35fc Fix search summary to restrict on valid items 2021-08-14 14:09:07 +02:00
eikek
1256a6e8cf Allo wildcards when searching by attachment ids 2021-07-31 01:23:37 +02:00
eikek
15b15666bf Allow to use the created timestamp in item queries
Refs: 925
2021-07-27 17:33:13 +02:00
eikek
d95a78f495 Allow to set folder by id or name 2021-07-17 15:10:19 +02:00
eikek
8e5c88fd32 Add copyright header to source files 2021-07-04 10:57:53 +02:00
eikek
ce6f53cc29 Fix next-job query to do round-robin through job groups 2021-06-27 00:04:56 +02:00
eikek
988367a281 Extend query builder to compare results from subselects 2021-06-26 21:12:02 +02:00
eikek
bd791b4593 Upgrade code base to CE3 2021-06-22 22:53:34 +02:00
eikek
3ee0846e19 Remove fts_migration table
It is now stored it SOLR instead.
2021-06-07 17:53:47 +02:00
eikek
c2170d2daf Fix tag category search being case insensitive 2021-06-03 21:44:55 +02:00
Eike Kettner
25788a0b23 Add routes for storing/retrieving client settings 2021-05-27 21:34:05 +02:00
Eike Kettner
a1a93e5ca6 Fixes searching items with fulltext
When using fulltext only search, then only the index must be searched.
This wasn't working anymore, because the routes added a query to
always select valid items (those not being processed). But this lead
to the downstream code to always consult the database, too. Since the
routes are using a "simple-search" interface, this is now adding the
valid-state condition if applicable. There are still more low-level
interfaces that can be used when searching should be done differently.

Closes: #823
2021-05-23 14:14:25 +02:00
Stefan Scheidewig
6149a2ab89 Restored unused imports to make it compile again 2021-04-15 18:34:54 +02:00
Stefan Scheidewig
fa34312020 Implemented endpoint to delete multiple attachments 2021-04-15 18:05:01 +02:00
Eike Kettner
994e3df597 Fix query for getting tag categoy summary 2021-04-12 13:40:22 +02:00
Eike Kettner
3e0914ece7 Correctly count tag categories
If multiple tags of the same category are applied to the same item,
just summing tag counts will produce the wrong results as now items
are counted multiple times.
2021-04-11 14:34:44 +02:00
Eike Kettner
4041018c47 Reduce not expressions
Fixes queries containing macros inside a "not".
2021-04-11 12:57:42 +02:00
Eike Kettner
e1bbc2edf5 Apply autoformat 2021-04-10 16:31:58 +02:00
Scala Steward
144ea852bf Update fs2-core, fs2-io to 2.5.4 2021-03-31 21:10:42 +02:00
Eike Kettner
c36073b852 Allow to give human readable summary to user tasks 2021-03-27 22:13:13 +01:00
Eike Kettner
cc38b850a6 Remove deprecated search routes and some refactoring 2021-03-27 22:13:13 +01:00
Eike Kettner
177488817d Fix h2 migration
Using java source code obviously requires `javac` during migration.
2021-03-13 16:38:48 +01:00
Eike Kettner
2e443bc9b9 Fix mariadb migration 2021-03-13 15:52:38 +01:00
Eike Kettner
0229a867af Add a use colum to metadata entities 2021-03-10 23:55:18 +01:00
Eike Kettner
6a63694a3e Convert unit tests to munit 2021-03-10 19:48:56 +01:00
Eike Kettner
77a87782b7 Refactoring parser
- put all used strings in one place to have it easier to track
- don't use `$` for shortcuts, it's a detail not interesting to a
  user; now names must not clash (which is a good idea anyways)
- Added two more shortcuts `conc` and `corr`
2021-03-08 22:51:14 +01:00
Eike Kettner
e681ffa96f Extend query builder allowing more conditions
Before only a column or a dbfunction could be used in a condition. It
is now allowed for all `SelectExpr`.
2021-03-08 22:51:08 +01:00
Eike Kettner
30c901ddf1 Add more ways to query for attachments
- find items with a specified attachment count
- find items by attachment id
2021-03-08 09:49:38 +01:00
Eike Kettner
2b2f913e85 Add checksum query expr 2021-03-08 01:53:21 +01:00
Eike Kettner
1c834cbb77 Correctly compare numeric field values 2021-03-03 22:54:55 +01:00
Eike Kettner
71985244f1 Use a better representation for macros 2021-03-03 00:44:49 +01:00
Eike Kettner
a48504debb Specificly search for field id vs name 2021-03-02 21:09:31 +01:00
Eike Kettner
168f5a1a98 Fix like search for custom fields 2021-03-01 20:56:23 +01:00
Eike Kettner
f8307f77c6 Search by field id or name 2021-03-01 20:56:23 +01:00
Eike Kettner
698ff58aa3 Provide a more convenient interface to search 2021-03-01 11:50:07 +01:00
Eike Kettner
d737da768e Move to munit in query module 2021-03-01 00:51:01 +01:00
Eike Kettner
9013d9264e Add more convenient date parsers and some basic macros 2021-03-01 00:51:01 +01:00
Eike Kettner
af73b59ec2 Parser improvements
- default expressions into a and node
- fix parsing string lists that end in whitespace
- fix package names of internal classes
2021-03-01 00:51:01 +01:00
Eike Kettner
a80d73d5d2 Optimize imports 2021-03-01 00:51:01 +01:00
Eike Kettner
e9ed998e3a Basic poc to search via custom query 2021-03-01 00:51:01 +01:00
Eike Kettner
186014a1c6 Refactor search to separate between a base query and user query
The `findBase` is adding only strictly required conditions. Everything
else comes from the user.
2021-03-01 00:51:01 +01:00
Eike Kettner
c3cdec416c Sketching some basic tests 2021-03-01 00:50:52 +01:00
Eike Kettner
be5c7ffb88 First draft of ast and parser 2021-03-01 00:46:57 +01:00
Eike Kettner
e6d9ce2c37 Remove obsolete type capabilities
These are now detected by the new scala compiler and lead to compile
errors.
2021-03-01 00:16:30 +01:00