Commit Graph

88 Commits (fac380fb886d6f1b9cf645870f999230c05155d5)

Author SHA1 Message Date
Ferdinand Thiessen d6d6747a73 refactor: apply rector rules for PHPUnit 10
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
2025-10-27 21:56:04 +07:00
Joas Schilling 102c778228
fix(comments): Fix missing return type on new method
Signed-off-by: Joas Schilling <coding@schilljs.com>
2025-08-28 08:58:52 +07:00
Carl Schwan fa5548a1f3 perf(comments): Add a way to get comments for multiple objects at the same time
Signed-off-by: Carl Schwan <carl.schwan@nextclound.com>
2025-08-21 11:18:57 +07:00
Joas Schilling 088d6843b7
fix(comments): Adjust interface with implementation
Signed-off-by: Joas Schilling <coding@schilljs.com>
2025-07-10 22:03:21 +07:00
Robin Appelman aa15f9d16d
chore: run rector
Signed-off-by: Robin Appelman <robin@icewind.nl>
2025-07-01 22:45:52 +07:00
Ferdinand Thiessen 5981b7eb51
chore: apply new CSFixer rules
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>

# Conflicts:
#	apps/settings/lib/SetupChecks/PhpOpcacheSetup.php
2025-07-01 16:26:50 +07:00
Robin Appelman 29e39c0a2e
chore: run rector on tests
Signed-off-by: Robin Appelman <robin@icewind.nl>
2025-06-12 18:31:58 +07:00
Joas Schilling 0d79156bb2
test: Speed up comments test
Signed-off-by: Joas Schilling <coding@schilljs.com>
2025-05-21 07:53:23 +07:00
Joas Schilling 3e7db013c1
test: Fix non-static data providers
Signed-off-by: Joas Schilling <coding@schilljs.com>
2025-05-15 08:25:01 +07:00
Joas Schilling 7304756e03
test: Sort the reactions before comparing
Signed-off-by: Joas Schilling <coding@schilljs.com>
2025-05-14 11:42:52 +07:00
Joas Schilling d46d2d1acf
test: Fix coding standards
Signed-off-by: Joas Schilling <coding@schilljs.com>
2025-05-05 10:09:22 +07:00
Joas Schilling 10424f248b
test(comments): Make Comments test result output properly readable
Signed-off-by: Joas Schilling <coding@schilljs.com>
2025-05-05 09:38:02 +07:00
Joas Schilling e2cd436205
test: Improve comments manager test output in case of failure
Signed-off-by: Joas Schilling <coding@schilljs.com>
2025-04-09 13:49:16 +07:00
Ferdinand Thiessen 2ef74b9860
Merge pull request #47329 from nextcloud/feat/add-datetime-qbmapper-support
feat(AppFramework): Add full support for date / time / datetime columns
2024-10-18 19:05:08 +07:00
Joas Schilling 882f91605b
fix(comments): Add test for email mention
Signed-off-by: Joas Schilling <coding@schilljs.com>
2024-10-18 07:39:41 +07:00
Ferdinand Thiessen db94e10af0
fix: Prevent breaking change in IQueryBuilder
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
2024-10-17 18:31:44 +07:00
Ferdinand Thiessen ee02e3246d
feat(AppFramework): Add full support for date / time / datetime columns
This adds support for all Doctrine supported types, for the column types only the immutable variants needed to be added.
But especially those types are the important ones, as our **Entity** class works by detecting changes through setters.
Meaning if it is mutable, changes like `$entity->date->modfiy()` can not be detected, so the immutable types make more sense here.

Similar the parameter types needed to be added.

`Enity` and `QBMapper` needed to be adjusted so they support (auto map) those types, required when insert or update an entity.

Also added more tests, especially to make sure the mapper really serializes the values correctly.

Co-authored-by: Ferdinand Thiessen <opensource@fthiessen.de>
Co-authored-by: Côme Chilliet <91878298+come-nc@users.noreply.github.com>
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
2024-10-17 18:31:42 +07:00
provokateurin 9836e9b164
chore(deps): Update nextcloud/coding-standard to v1.3.1
Signed-off-by: provokateurin <kate@provokateurin.de>
2024-09-19 14:21:20 +07:00
Christoph Wurst 49dd79eabb
refactor: Add void return type to PHPUnit test methods
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2024-09-15 22:32:31 +07:00
Anna Larch 6c36c54dc6 feat(db): switch from settype to casts
Signed-off-by: Anna Larch <anna@nextcloud.com>
2024-09-15 19:26:58 +07:00
Daniel Kesselberg af6de04e9e
style: update codestyle for coding-standard 1.2.3
Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
2024-08-25 19:34:58 +07:00
Julius Härtl 9713dd3fa9
chore: Move comments event handler to use proper event dispatcher
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2024-06-26 18:13:07 +07:00
Andy Scherzinger 1f7e2ba599
chore: Add SPDX header
Signed-off-by: Andy Scherzinger <info@andy-scherzinger.de>
2024-05-13 17:41:36 +07:00
Côme Chilliet ec5133b739 fix: Apply new coding standard to all files
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2024-04-02 14:16:21 +07:00
Andrew Summers 6910832170 Refactor `OC\Server::getCommentsManager`
Signed-off-by: Andrew Summers <18727110+summersab@users.noreply.github.com>
2024-03-15 13:14:06 +07:00
Robin Appelman eb5832b8fa refactor: depricate getNumberOfUnreadCommentsForFolder and redo it's implementation based on getNumberOfUnreadCommentsForObjects
Signed-off-by: Robin Appelman <robin@icewind.nl>
2024-03-07 19:19:07 +07:00
Joas Schilling e5b0c06b24
feat(comments): Allow mentions of federated users, groups and teams in the future
Signed-off-by: Joas Schilling <coding@schilljs.com>
2024-02-27 17:11:23 +07:00
Joas Schilling 6056928dc6
feat(comments): Add a meta data column for comments
Signed-off-by: Joas Schilling <coding@schilljs.com>
2023-12-14 14:32:00 +07:00
Vitor Mattos 5ed6722dd2 Cover expire_date with unit tests
Signed-off-by: Vitor Mattos <vitor@php.rio>
2023-04-26 13:21:08 +07:00
Vitor Mattos e9295f739e Split the comments ids by chunks
Split the comments ids by chunks to prevent error with Oracle database
that can't do a query with more than 1000 parameters.

https://github.com/nextcloud/spreed/issues/8287

Signed-off-by: Vitor Mattos <vitor@php.rio>
2023-03-01 13:08:17 +07:00
Côme Chilliet f5c361cf44
composer run cs:fix
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-01-20 11:45:08 +07:00
Vitor Mattos 7a0648757a
Delete comments that expired now
Signed-off-by: Vitor Mattos <vitor@php.rio>
2022-07-25 11:30:20 +07:00
Joas Schilling d722a0c12a
Adjust fake manager
Signed-off-by: Joas Schilling <coding@schilljs.com>
2022-07-01 16:38:58 +07:00
Joas Schilling 198224bf7a
Allow to expire comments of multiple objects with one call
Signed-off-by: Joas Schilling <coding@schilljs.com>
2022-07-01 15:59:29 +07:00
Vitor Mattos 3be1217c04
Follow the most common pattern used in project
```
git grep strval|wc -l
32
git grep "(string)"|wc -l
481
```

Signed-off-by: Vitor Mattos <vitor@php.rio>
2022-06-20 11:46:13 +07:00
Vitor Mattos c59b0c2ff7
Add comments expire date
https://github.com/nextcloud/spreed/pull/7327

Signed-off-by: Vitor Mattos <vitor@php.rio>
2022-06-15 11:58:29 +07:00
Joas Schilling 902476fa20
Extract the EmojiService from user status and add an OCP interface
Signed-off-by: Joas Schilling <coding@schilljs.com>
2022-04-28 07:09:44 +07:00
Joas Schilling 367be7c55f
Allow reactions also with other combined emojis
Honerful copying the EmojiService from UserStatus for now
I think this should be put into a decent place and then reused,
but I couldn't find somethin short term before beta1

Signed-off-by: Joas Schilling <coding@schilljs.com>
2022-03-24 15:13:09 +07:00
Vitor Mattos 8ec7c5c8ae
Update ICommentsManager with reaction methods
Fix psalm errors
Reorder methods and remove return null
Use best pattern on docblock

Goals: update https://github.com/ChristophWurst/nextcloud_composer/ with reaction methods.
The script
https://github.com/ChristophWurst/nextcloud_composer/blob/master/build.sh
only get lib/public classes

Signed-off-by: Vitor Mattos <vitor@php.rio>
2022-02-03 12:52:18 +07:00
Joas Schilling e8c66d0f89
Merge pull request #30794 from nextcloud/techdebt/noid/allow-to-get-comments-with-verb
Allow to get comments with a given set of verbs
2022-01-28 16:41:42 +07:00
Joas Schilling 429380337f
Fix fake manager
Signed-off-by: Joas Schilling <coding@schilljs.com>
2022-01-21 14:02:34 +07:00
Vitor Mattos 7bb01b6ccc
Refactor and fixes on tests
Signed-off-by: Vitor Mattos <vitor@php.rio>
2022-01-21 08:40:29 +07:00
Vitor Mattos b9f74584a1
Fix check after change from string to mb_string
Signed-off-by: Vitor Mattos <vitor@php.rio>
2022-01-21 08:39:41 +07:00
Joas Schilling 189f9f96ce
Limit the summary and sort it afterwards
Signed-off-by: Joas Schilling <coding@schilljs.com>
2022-01-21 08:39:39 +07:00
Vitor Mattos f7cd995612
Order the reaction summary, improvements on validations
Signed-off-by: Vitor Mattos <vitor@php.rio>
2022-01-21 08:39:39 +07:00
Vitor Mattos 1ce894a50c
Disable reactions if database don't support utf8mb4
Fix column size

Signed-off-by: Vitor Mattos <vitor@php.rio>
2022-01-21 08:39:37 +07:00
Vitor Mattos 52affa9ddd
Skip if dont support 4 bytes UTF8
Signed-off-by: Vitor Mattos <vitor@php.rio>
2022-01-21 08:37:07 +07:00
Vitor Mattos 425b5cf081
Add unit tests
Signed-off-by: Vitor Mattos <vitor@php.rio>
2022-01-21 08:37:06 +07:00
Joas Schilling 03abaaaee5
Fix unit tests
Signed-off-by: Joas Schilling <coding@schilljs.com>
2022-01-05 11:53:33 +07:00
Joas Schilling 3487aeeb1f
Add integration tests for group
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-10-12 14:05:38 +07:00