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
Vitor Mattos
7a0648757a
Delete comments that expired now
...
Signed-off-by: Vitor Mattos <vitor@php.rio>
2022-07-25 11:30:20 -03:00
Joas Schilling
d722a0c12a
Adjust fake manager
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2022-07-01 16:38:58 +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
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 -03: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
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
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
429380337f
Fix fake manager
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2022-01-21 14:02:34 +01:00
Vitor Mattos
7bb01b6ccc
Refactor and fixes on tests
...
Signed-off-by: Vitor Mattos <vitor@php.rio>
2022-01-21 08:40:29 -03: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
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
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
52affa9ddd
Skip if dont support 4 bytes UTF8
...
Signed-off-by: Vitor Mattos <vitor@php.rio>
2022-01-21 08:37:07 -03:00
Vitor Mattos
425b5cf081
Add unit tests
...
Signed-off-by: Vitor Mattos <vitor@php.rio>
2022-01-21 08:37:06 -03:00
Joas Schilling
03abaaaee5
Fix unit tests
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2022-01-05 11:53:33 +01:00
Joas Schilling
3487aeeb1f
Add integration tests for group
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-10-12 14:05:38 +02:00
Joas Schilling
86109f77e0
Fix unit tests
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-02-06 13:07:06 +01:00
Joas Schilling
ede7510854
Add a function to get the unread count for multiple objects in one go
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2020-11-04 11:01:21 +01:00
Joas Schilling
1f1244fdcc
Fix PHP CS
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2020-10-22 11:00:54 +02:00
Joas Schilling
8600e51df5
Fix manager creation and testing
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2020-10-22 10:54:03 +02:00
John Molakvoæ (skjnldsv)
3e1916080a
Add ICommentsManager::load method
...
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
2020-10-20 14:39:28 +02:00
Morris Jobke
234b510652
Change PHPDoc type hint from PHPUnit_Framework_MockObject_MockObject to \PHPUnit\Framework\MockObject\MockObject
...
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2020-08-12 13:55:19 +02:00
Christoph Wurst
caff1023ea
Format control structures, classes, methods and function
...
To continue this formatting madness, here's a tiny patch that adds
unified formatting for control structures like if and loops as well as
classes, their methods and anonymous functions. This basically forces
the constructs to start on the same line. This is not exactly what PSR2
wants, but I think we can have a few exceptions with "our" style. The
starting of braces on the same line is pracrically standard for our
code.
This also removes and empty lines from method/function bodies at the
beginning and end.
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-04-10 14:19:56 +02:00
Christoph Wurst
14c996d982
Use elseif instead of else if
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-04-10 10:35:09 +02:00
Christoph Wurst
afbd9c4e6e
Unify function spacing to PSR2 recommendation
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-04-09 13:54:22 +02:00
Christoph Wurst
41b5e5923a
Use exactly one empty line after the namespace declaration
...
For PSR2
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-04-09 11:48:10 +02:00
Christoph Wurst
2ee65f177e
Use the shorter phpunit syntax for mocked return values
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-03-25 22:21:27 +01:00
Roeland Jago Douma
3a7cf40aaa
Mode to modern phpunit
...
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2019-11-27 15:27:18 +01:00
Roeland Jago Douma
c007ca624f
Make phpunit8 compatible
...
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2019-11-27 13:34:41 +01:00
Joas Schilling
092d34d9df
Add a unit test for guests as well
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2019-07-11 10:24:27 +02:00
Joas Schilling
10ba0bed8a
Match mentions when the username is wrapped in quotes
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2018-11-07 12:33:44 +01:00
Joas Schilling
66945f9574
Allow to filter the unread count by verb
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2018-07-30 09:41:51 +02:00
Joas Schilling
ac2314e3d0
Add pagination support
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2018-07-25 18:53:45 +02:00
Joas Schilling
8c7969e730
Allow to search by comments
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2018-07-25 18:53:44 +02:00
Mario Danic
d959ca8eb0
Add another test
...
Signed-off-by: Mario Danic <mario@lovelyhq.com>
2018-06-08 17:21:46 +02:00
Mario Danic
5acdd45b77
Add a new regex test
...
Signed-off-by: Mario Danic <mario@lovelyhq.com>
2018-06-08 17:15:41 +02:00
Joas Schilling
cccdfaa6e9
Fix FakeManager
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2018-04-19 17:12:07 +02:00
Joas Schilling
f50abde7ac
Add proper comment offset support
...
The offset is based on the last known comment instead of limit-offset,
so new comments don't mess up requests which get the history of an object-
Signed-off-by: Joas Schilling <coding@schilljs.com>
2018-04-18 14:23:15 +02:00
Arthur Schiwon
3784fa2074
comments should compile mentions also if done by author
...
it is used by clients for formatting reasons, there is no reason not format
the author if her handle is included in the comment body.
It is unrelated to sending out notifications.
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2018-01-17 13:48:43 +01:00
Arthur Schiwon
d5f1cef642
fix comment sorter
...
background: we have a flat hierarchy of comments, not a tree. therefore we
can also remove again the unnecessary additions.
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2017-10-30 15:59:43 +01:00
Arthur Schiwon
fd6daf8d19
AutoCompletion backend
...
* introduce a Controller for requests
* introduce result sorting mechanism
* extend Comments to retrieve commentors (actors) in a tree
* add commenters sorter
* add share recipients sorter
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2017-10-22 14:13:32 +02:00
Joas Schilling
20f8d1094a
Can not insert auto increment on oracle
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2017-08-02 09:48:16 +02:00
Robin Appelman
2a4d9f71af
update FakeManager
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2017-03-30 12:48:34 +02:00
Robin Appelman
212d9fd277
Add test for getting unread comment count by folder
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2017-03-30 12:48:27 +02:00
Morris Jobke
cde7f535bd
Merge pull request #1738 from nextcloud/comments-provide-displaynames-with-mentions
...
comment mentions: show displayname not uid
2016-10-26 14:02:49 +02:00