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 +01:00
Joas Schilling
aa5f037af7
chore: apply changes from Nextcloud coding standards 1.1.1
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
Signed-off-by: Benjamin Gaussorgues <benjamin.gaussorgues@nextcloud.com>
2023-11-23 10:36:13 +01:00
Joas Schilling
4d2217073a
fix(comments): Use provided offset in best effort when loading comments
...
When we didn't find the "$lastKnownComment" the whole condition was ignored.
Now we still use the ID as an offset.
This is required as a fall-back for expired messages in Talk
and deleted comments in other apps.
Signed-off-by: Joas Schilling <coding@schilljs.com>
2023-09-18 20:09:32 +02:00
Côme Chilliet
7aa97dcc23
Throw if creation date is read before inserting into database
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-06-20 12:14:57 +02:00
Carl Schwan
9725d00329
Cleanup comments code
...
- Fix various psalm issues
- Add as much typing as possible while preserving stable API
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
2023-06-20 10:55:20 +02:00
Faraz Samapoor
e7cc7653b8
Refactors "strpos" calls in lib/private to improve code readability.
...
Signed-off-by: Faraz Samapoor <fsamapoor@gmail.com>
2023-05-15 15:17:19 +03:30
Vitor Mattos
7ab50ab010
Update expire_date column of table comments
...
Signed-off-by: Vitor Mattos <vitor@php.rio>
2023-04-26 11:29:56 -03: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 -03: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 +01:00
Joas Schilling
3f4fed3550
Fix forwarding the object id when searching comments
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2022-11-16 12:08:34 +01:00
Vitor Mattos
7a0648757a
Delete comments that expired now
...
Signed-off-by: Vitor Mattos <vitor@php.rio>
2022-07-25 11:30:20 -03:00
blizzz
c98e44507d
Merge pull request #32865 from nextcloud/bugfix/remove-unecessary-row
...
Remove unecessary row and make compatible with db schema
2022-07-08 23:11:10 +02: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 +02: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 -03:00
Vitor Mattos
b9def2f073
Set as optional argument
...
Signed-off-by: Vitor Mattos <vitor@php.rio>
2022-06-13 16:12:35 -03:00
Vitor Mattos
45cdb36d5c
Remove unecessary row and make compatible with db schema
...
Signed-off-by: Vitor Mattos <vitor@php.rio>
2022-06-13 13:35:34 -03:00
Joas Schilling
5b82ad0b30
Create query parameters on correct objects to make debugging easier
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2022-05-23 13:02:36 +02:00
Joas Schilling
4e0595fb0f
Fix JSON error when comment has no reactions
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2022-05-09 09:53:49 +02:00
Joas Schilling
0d87335751
Merge pull request #31703 from nextcloud/techdebt/noid/emojihelper-interface
...
Emojihelper interface
2022-04-29 18:31:29 +02:00
Joas Schilling
7c85f8dea4
Make the order of reactions reliable
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2022-04-28 16:13:41 +02:00
Vitor Mattos
a75a22f3ac
Increase check if support reactions
...
Signed-off-by: Vitor Mattos <vitor@php.rio>
2022-04-28 07:09:44 -03: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 -03: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 +01:00
Joas Schilling
d05dca0c1c
Simplify comment search in special cases
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2022-03-18 09:22:16 +01: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 -03: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 +01:00
Joas Schilling
1ceba64863
Allow to get comments with a given set of verbs
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2022-01-21 13:42:04 +01: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 -03:00
Joas Schilling
c9f2f00777
Fix CS
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2022-01-21 08:39:40 -03:00
Joas Schilling
ecb98f772e
Throw if trying to save reaction without support
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2022-01-21 08:39:40 -03:00
Joas Schilling
e0b89cd576
Only check mb_strlen()
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2022-01-21 08:39:40 -03:00
Joas Schilling
d850dc0220
Remove order from groupConcat as it is not working everywhere
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2022-01-21 08:39:39 -03: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 -03:00
Vitor Mattos
f071b4dfbb
Fix groupConcat and ordering on Oracle
...
Signed-off-by: Vitor Mattos <vitor@php.rio>
2022-01-21 08:39:39 -03: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 -03: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 -03:00
Vitor Mattos
898e87fe1a
Rename vars and move logic to method
...
Signed-off-by: Vitor Mattos <vitor@php.rio>
2022-01-21 08:37:07 -03:00
Vitor Mattos
a7c0868a4c
Prevent violate constraint
...
Signed-off-by: Vitor Mattos <vitor@php.rio>
2022-01-21 08:37:06 -03:00
Vitor Mattos
1dda03e1b5
Rename vars
...
Signed-off-by: Vitor Mattos <vitor@php.rio>
2022-01-21 08:37:05 -03:00
Vitor Mattos
9efbc9c1d5
Add comments reactions
...
Signed-off-by: Vitor Mattos <vitor@php.rio>
2022-01-21 08:37:04 -03:00
Joas Schilling
2166cfde9e
Allow to count comments with multiple verbs
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-11-26 12:29:44 +01:00
Joas Schilling
6536ff2cec
Prepare for group mentions
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-10-08 13:23:18 +02:00
Mátyás Jani
1018eb4411
Fix SQL type error
...
Fixing the following SQL error encountered with PostgreSQL:
SQLSTATE[42883]: Undefined function: 7 ERROR:
No operator matches the given name and argument types. You might need to add explicit type casts.
This prevented the Nextcloud apps/files page to show the files and directories. See #27881
2021-08-17 15:10:38 +02:00
John Molakvoæ (skjnldsv)
215aef3cbd
Update php licenses
...
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
2021-06-04 22:02:41 +02:00
Joas Schilling
6578a93463
Merge pull request #27053 from nextcloud/bugfix/noid/dont-throw-when-comments-is-disabled
...
Don't throw when comments is disabled
2021-06-02 15:40:51 +02:00
Joas Schilling
c0c5340f4e
Fix populating the array and closing the cursors
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-06-01 09:15:34 +02:00
Simounet
a50eba16ad
Fix Oracle query limit compliance in Comments
...
Signed-off-by: Simounet <contact@simounet.net>
2021-05-28 08:48:01 +02:00
Joas Schilling
5ae5729664
Don't throw when comments is disabled
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-05-21 12:04:23 +02:00
Joas Schilling
98032425b4
Fix linter
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-02-06 13:07:06 +01:00
Joas Schilling
ef7ed47f14
Make Psalm happy
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-02-06 13:07:06 +01:00