Commit Graph

204 Commits

Author SHA1 Message Date
Tim Donohue
9e77f543e0 Merge pull request #10774 from the-library-code/9212_bundle_policy_inheritance
Inherit custom, non-admin policies when creating new bundles
2025-08-01 11:38:36 -05:00
Kim Shepherd
924678a092 [TLC-1117] Inherit custom, non-admin policies when creating new bundles
Also shifted some resource policy methods from ItemService to
AuthorizeService as they seemed better suited there.
2025-05-26 16:35:15 +02:00
Mark H. Wood
852549b1f1 Replace duplicated literals with manifest constants. 2025-04-01 13:38:47 -04:00
Tim Donohue
611e98afe8 Replace java.util.Date and java.util.Calendar with java.time.* equivalents. 2025-03-05 16:37:03 -06:00
Tim Donohue
e254007583 Merge pull request #9718 from 4Science/task/main/CST-14901
Handles versioning for ORCID publications.
2025-01-22 14:50:06 -06:00
Jens Vannerum
352f4c2152 118774: status of doi should be set to TO_BE_DELETED when related item is removed permanently 2024-10-14 17:03:15 +02:00
Christian Clauss
dbf33f2113 Fix typos discovered by codespell 2024-08-06 16:37:21 +02:00
Sascha Szott
fa0fb14a18 fix invalid usage of == operator 2024-08-02 14:12:53 +02:00
Vincenzo Mecca
74d0494738 [CST-14901][DSC-1357][#8662] Handles versioning for ORCID publications.
feat:
  - ORCID publications waiting to be published are removed whenever a new version is created
  - ORCID publications already published will be updated with the ref to the last item version
  - ORCID consumer will process only latest item versions, ignoring all the other ones
2024-07-22 12:34:30 +02:00
damian
01be5eee41 Level up counting items methods - both now use the same flags from Item model (discoverable, archived, withdrawn) 2024-05-24 16:10:21 +02:00
Tim Donohue
d63b815028 Merge pull request #9229 from tuub/DS-3439
[DS-3439] Copy collection template item specified metadata during …
2024-04-29 16:42:02 -05:00
Tim Donohue
66402b2d62 Fix PatchMetadataIT failures by ensuring MetadataValue place is updated for virtual fields as well. Also minor code cleanup in PatchMetadataIT. 2024-03-27 14:38:35 -05:00
Tim Donohue
fafb16ad6b Fix Hibernate 6 syntax of several queries. Must use Hibernate name and not SQL database column name. 2024-03-25 12:28:21 -05:00
jeffmorin
1a3c0726dc Content reports ported from DSpace 6.x (#8598)
* content Reports

* Fixed CheckStyle errors

* Fixed CheckStyle errors

* Fixed CheckStyle errors

* First batch of fixes: mainly Javadoc, and a bit of code re-engineering

* Fixed CheckStyle errors

* Fixed CheckStyle errors in dspace-server-webapp

* Applied requested changes for DSpace code conventions compliance

* Added GET endpoint to Filtered Items report

* Updated to latest version from main branch

* Fixed missing imports

* Fixed CheckStyle errors

* Fixed H2 database initialization

* Fixed unit tests and an integration test

* Fixed CheckStyle errors

* Fixed CheckStyle errors

* Fixed ItemServiceIT test

* Test without collection criterion

* Fixed max result count in integration test

* Disable findByMetadataQuery test to diagnose errors in other tests

* Disabled ContentReportRestRepositoryIT test to validate existing tests

* Re-enable test in dspace-api

* Re-enabled ContentReportRestRepositoryIT tests to diagnose failures

* Fixed item matching in the second test

* Fixed JSON path error

* Use projections to trigger embedding the owning collection in ItemRest only for the Filtered Items report

* Fixed usage of allowEmbedding() through non-null arguments

* Exclude owning collection from ItemRest when null/empty

* Trying an alternate way to discriminate report-based Item conversions

* Fixed embedded owning collection management

* Replaced ItemConverter with correct version

* Fixed Filtered Collections test in ContentReportRestRepositoryIT

* Fixed test

* Transferred owning collection to a separate class FilteredItemRest

* Rollback to DSpace repo version

* Fixed matcher for Filtered Collections summary

* Fixed matcher for Filtered Collections summary (take 2)

* Add printing mock request results to diagnose remaining problems

* Try logging output through System.err

* Cancelled attempt to print JSON results (does nothing)

* Attempt to fix ContentReportRestRepositoryIT tests

* Removed predefined UUIDs and handles

* Fixed import formatting

* Fixed expected results in ContentReportRestRepositoryIT

* Switched to a custom matcher for the Filtered Item report test

* Fixed import format

* Fixed JSON collection matching in Filtered Items test

* Fixed Filtered Items matcher

* Fixed expected result

* Fixed the test for now...

* Fixed test again

* Disabled non-working test

* Fixed a few typos

* Moved Filtered Collections report business logic to dspace-api

* Fixed outdated controller

* Fixed import and lost @Ignore annotation

* Retrieved a lost test correction

* Fixed Filtered Collections test

* Reverted to the last working version (except for 2nd test, which remains
disabled)

* Moved Filtered Items report business logic to dspace-api

* Fixed import style

* Added switch to enable/disable Content Reports

* Fixed an out-of-date class

* Removed unused imports

* Fixed activation configuration for Content Reports

* Added missing @Test annotation

* A forgotten Hibernate dialect configuration. I also removed obsolete
Oracle settings configuration.

* Switched to GET requests for Content Reports

* Switched to GET requests for Content Reports

* Fixed styling in imports

* Fixed imports

* Cleaned deprecated code

* Simplified regex since trim() method is invoked on each token thereafter

* Added Javadoc in the interface.

* Relocated Content Reports configuration into a new file

* Added "unauthorized" tests and cleaned up code repetitions

* Fixed parameter according to Javadoc

* Fixed Filtered Items test

* Use of @ConditionalOnProperty annotation

* Rolled back to manual parameter managing

* Second try on @ConditionalOnProperty, with proper test configuration

* Rolled back (again) to manual service activation checking (needed for
proper behaviour depending on activation and authorization)

* Eliminated inheritance between FilteredItemRest and ItemRest

* Re-established the type property in FilteredItemRest (and in
FilterCollectionRest for uniformity).

---------

Co-authored-by: Jean-François Morin <jean-francois.morin@bibl.ulaval.ca>
2024-02-28 11:48:16 -06:00
Tim Donohue
944305a8ca Remove dspace-rest, all configs and a few deprecated methods only used by this module. 2024-01-19 11:15:18 -06:00
nwoodward
848df25984 catch exceptions stemming from invalid id's 2024-01-18 11:44:57 -06:00
frabacche
ff5f3fa74f CST-5249 rename OpenAIRE to Openaire, other minor issues 2023-12-12 16:15:25 +01:00
haoueclf
7ead4ae7f0 [DS-3439] Copy collection template item specified metadata during Sword v2 METS deposit ingestion. 2023-12-11 19:17:05 +01:00
frabacche
c440a9f6b3 Merge branch 'main' of https://github.com/4Science/DSpace into CST-5249 2023-10-27 12:29:46 +02:00
Koen Pauwels
88749f6c61 103818 Extend ItemServiceTest#testMoveItemToCollectionWithMoreRestrictiveReadPolicy 2023-08-08 11:49:08 +02:00
Koen Pauwels
d4eb327ce5 103818 Add boolean parameters to ItemServiceImpl methodds to decide whether to override read policies 2023-08-07 16:52:42 +02:00
Koen Pauwels
e4ff24a2d9 103818 Add boolean parameter to ItemServiceImpl#inheritCollectionDefaultPolicies to decide whether to override item read policies 2023-08-07 16:15:42 +02:00
Koen Pauwels
54280e8fe2 103818 ItemServiceImpl#inheritCollectionDefaultPolicies now clears item READ policies if new parent collection has a default READ policy 2023-08-07 16:15:24 +02:00
Francesco Bacchelli
57f9071497 Merge branch 'main' of https://github.com/DSpace/DSpace into CST-11298 2023-08-01 13:10:52 +02:00
Tim Donohue
240bfbfdc9 Fix to adjusting bundle and bitstream policies (item install, embargo lift)
Apply DEFAULT_ITEM_READ to bundles, not DEFAULT_BITSTREAM_READ so that
files can be listed if the item / default item is readable
2023-06-16 11:00:03 -05:00
eskander
6848ab20bd Merge remote-tracking branch 'origin/main' into duracom-136_CST-9634
# Conflicts:
#	dspace/config/spring/api/discovery.xml
2023-06-06 17:30:53 +03:00
Giuseppe Digilio
ec3cc2dcf1 Merge branch 'main' into duracom-136_CST-9634 2023-05-25 15:49:41 +02:00
Kim Shepherd
2ef268380f Unlink DOI from item on deletion even if no provider is configured 2023-05-21 15:43:26 +12:00
Mohamed Saber Eskander
4e64afbe3b bulk access controll 2023-05-11 12:04:20 +03:00
Vincenzo Mecca
b1c1edc7f0 [DURACOM-125][#8736] Preserved order of modified MetadataValues
feat:
  - Introduced new Class with static methods usable to order
`MetadataValue` lists;
  - Introduced ITs also for `PatchMetadata` replace operations;
  - Introduced new method `DspaceObject#getMetadataFieldId`.
ref:
  - Replaced old sort method inside `ItemServiceImpl` with the new one
2023-03-24 17:34:02 +01:00
jensvannerum
9bf9ba0775 Merge branch 'main' into w2p-99200_request-copy-bugfix 2023-02-14 14:24:30 +01:00
Raf Ponsaerts
a8a886b242 removed the log info 2023-02-14 11:22:13 +01:00
Jens Vannerum
c2845e95aa 99200: Delete items after copies have been requested fix 2023-02-09 11:19:47 +01:00
corrado lombardi
0edaba6f3a [CST-7756] after merge checkstyle fix 2023-02-02 17:54:09 +01:00
corrado lombardi
83649f6036 Merge branch 'main' into CST-7756-SubscriptionFeature
# Conflicts:
#	dspace-api/src/main/java/org/dspace/content/ItemServiceImpl.java
2023-02-02 17:52:50 +01:00
Koen Pauwels
9534b7893e 97183 Tests for findItemsWithEdit and countItemsWithEdit methods of ItemServiceImpl 2023-01-17 16:14:42 +01:00
Koen Pauwels
7ee46e0cba 97183 Processing PR review feedback 2023-01-02 09:58:31 +01:00
Koen Pauwels
6cbb1630e3 97183 ItemService: added methods to search the index for items for which the current user has editing rights 2022-12-02 16:09:26 +01:00
Mykhaylo
bdb4bd53dc [DSC-183] New endpoint, IT tests changed 2022-12-01 18:43:42 +01:00
Luca Giamminonni
d5f8fea24b [CST-5249] Improved QAEventProcessed test 2022-07-08 17:53:56 +02:00
Luca Giamminonni
680e96fda3 [CST-5587] Moved org.dspace.app.orcid and org.dspace.app.profile into org.dspace.orcid and org.dspace.profile 2022-06-20 16:02:01 +02:00
Luca Giamminonni
18573ff054 [CST-5587] Various improvements 2022-06-20 15:00:14 +02:00
Luca Giamminonni
9f4cee5dbc [CST-5587] Fixed compilation errors 2022-06-17 13:34:49 +02:00
Luca Giamminonni
c9ce57334b Merge remote-tracking branch '4science-bitbucket/main' into CST-5587 2022-06-17 13:28:31 +02:00
Bruno Roemers
3404c074d3 Merge branch 'main' into feature-relationship-versioning-contribution 2022-06-17 10:13:21 +02:00
Bruno Roemers
c1e99b1b7a Merge branch 'main' into feature-relationship-versioning-contribution 2022-06-10 13:25:00 +02:00
Ben Bosman
cdac9db9d7 Merge remote-tracking branch 'origin/feature-relationship-versioning_discover-7.2' into feature-relationship-versioning-contribution 2022-06-02 14:29:04 +02:00
Bruno Roemers
b0482bcdd8 91354: WIP: basic fix for reindexing older versions of items 2022-05-31 14:10:51 +02:00
Ben Bosman
e91593abdb Merge remote-tracking branch 'origin/feature-relationship-versioning_discover-7.2' into feature-relationship-versioning-contribution 2022-05-25 17:53:09 +02:00
Bruno Roemers
6257b386b3 91680: Fix NPE 2022-05-25 16:57:30 +02:00