Граф коммитов

1585 Коммитов

Автор SHA1 Сообщение Дата
Agniva De Sarker
c72e9131f4 MM-46577: Remove empty translation strings (#20876)
We replace the empty translation key with <untranslated>
which is ignored by the translation check tool.

https://mattermost.atlassian.net/browse/MM-46577

```release-note
NONE
```
2022-08-25 19:59:16 +05:30
Nick Misasi
e8a45a8cf7 [MM-43399] Cloud Delinquency Email Sequence (#20814)
* Add DelinquentSince to Subscription fields

* Stashing, migrating

* Adding file

* Adding many email templates

* Fix templates pipeline

* Fix translations

* Fix mocks

* Many changes

* Adjust mocks

* Update i18n/en.json

Co-authored-by: Maria A Nunez <maria.nunez@mattermost.com>

* PR fixes

* Update string

* Update i18n/en.json

Co-authored-by: Maria A Nunez <maria.nunez@mattermost.com>

* Update URL's for buttons to open the delinquency modal

* Update emails from mjml

Co-authored-by: Mattermod <mattermod@users.noreply.github.com>
Co-authored-by: Maria A Nunez <maria.nunez@mattermost.com>
2022-08-25 09:39:35 -04:00
Shivashis Padhi
6adbcc5d05 MM-45899: Insights: least active channels (#20796)
* Add api endpoints, app layers for top inactive channels with dummy store calls

* Add store functions for top inactive channels

* Add model, store, app tests.

* Add client function and api tests

* Add participants information to TopInactiveChannel

* Translation fix

* Style fix while writing response

* Return channelmember IDs instead of profiles, query in batch avoiding inside the loop

* Make the following changes

 - move DeleteAt to subqueries, to avoid select, group by
 - Remove TeamId from response
 - Count bots and webhook posts

* SQL query lint fix, store test fix to include bot messages

* make app-layers

* Fix empty participant lists being sent as [""]

* Track channel joins, to distinguish 0 activity channels vs new channels

Co-authored-by: Mattermod <mattermod@users.noreply.github.com>
2022-08-24 23:14:56 +05:30
Ibrahim Serdar Acikgoz
efbcb0a35a move logger under platform (#20831)
* move logger under platform
2022-08-24 10:10:56 +03:00
Julien Tant
3138543d10 [MM-46468] Change /help and add /marketplace (#20850) 2022-08-23 08:37:06 -07:00
Mattermod
e87a2bbe19 Merge branch 'master' into MM-45118_my_top_dms 2022-08-18 20:42:32 +03:00
Agniva De Sarker
9de6ce5275 MM-46450: Skip flaky TestSearchUsers (#20845)
https://mattermost.atlassian.net/browse/MM-46450

```release-note
NONE
```
2022-08-18 19:53:37 +05:30
Tim Scheuermann
e665542c91 Put wrapped errors into the detailed field on serialization (#20846) 2022-08-18 14:22:12 +02:00
Agniva De Sarker
d9d75b1a7d MM-45198: Migrate app/import and api4/import (#20799)
We migrate them to use logger context.

https://mattermost.atlassian.net/browse/MM-45198

```release-note
NONE
```
2022-08-17 19:58:52 +05:30
Amy Blais
6aa57e6242 Revert "MM-45272: Fix getPostThread permissions (#20565)" (#20811)
Automatic Merge
2022-08-12 18:43:49 +03:00
Shivashis Padhi
582812f1fc Merge branch 'master' of github.com:mattermost/mattermost-server into top-dms-clean 2022-08-12 17:00:55 +05:30
Martin Kraft
55b3961b98 MM-45120: Track team join times. Add API to retrieve new team members since a given time. (#20708)
* MM-45120: Starts tracking team join time. Adds API to retrieve team members who joined after a given time.

* MM-45120: Updates json casing to match model.User.
2022-08-11 10:38:52 -04:00
Shivashis Padhi
e5c1b17d77 Lint fixes 2022-08-11 12:19:25 +05:30
Shivashis Padhi
4ec3eade3b Merge branch 'master' of github.com:mattermost/mattermost-server into top-dms-clean 2022-08-10 21:00:57 +05:30
Tim Scheuermann
1738bd6e92 [MM-45991] Check and return JSON errors (#20735) 2022-08-10 10:56:58 +02:00
Tim Scheuermann
b4570afa90 Replace deprecated ioutil with io and os (#20776)
* Replace ioutil with io and os

* Replace ioutil in utils/file.go

* Minor fix to tests and excluded files

Co-authored-by: Tim Scheuermann <tim.scheuermann@mattermost.com>
Co-authored-by: Mattermod <mattermod@users.noreply.github.com>
2022-08-09 14:25:46 +03:00
Agniva De Sarker
97b3ffd7ea MM-43202: Change some 501 response codes to fix SLO violations (#20767)
There were lots of cases where we were using the code 501
in an incorrect manner, and since 5xx codes are considered
as SLO violations, these were flagged by our monitoring incorrectly.

These were the guidelines to change the codes:
1. Any case of missing license or config not correctly enabled
is set as Forbidden. The logic is that the user is correctly
authenticated with a session, but does not have enough privileges
to have the higher license, or hasn't changed the config correctly.
2. Any case of incorrectly formed request is obviously a 400.

https://mattermost.atlassian.net/browse/MM-43202

```release-note
NONE
```
2022-08-08 20:02:49 +05:30
Agniva De Sarker
b826421716 MM-45534: Fix flaky TestCreateGroupChannel (#20781)
The returned elements weren't in a specific order.
Therefore, we need to perform an order insensitive match.

https://mattermost.atlassian.net/browse/MM-45534

```release-note
NONE
```
2022-08-08 14:14:18 +05:30
Mattermod
4fc8ef0125 Merge branch 'master' into MM-45118_my_top_dms 2022-08-05 09:56:52 +03:00
Pablo Andrés Vélez Vidal
e7156476fa MM-45542 - do not fail if site url is not set when requesting trial (#20713)
* MM-45542 - do not fail if site url is not set when requesting trial

* remove unnecessary text

Co-authored-by: Pablo Velez Vidal <pablo.velez@mattermost.com>
Co-authored-by: Mattermod <mattermod@users.noreply.github.com>
2022-08-03 23:54:43 +02:00
Ibrahim Serdar Acikgoz
ac79a887a2 Move metrics under platform service (continued) (#20732)
* move metrics into platform

Co-authored-by: Agniva De Sarker <agnivade@yahoo.co.in>
2022-08-02 10:59:29 +03:00
Vishal
276594608c Remove the read_channel permission to unfollow a thread (#20662) 2022-08-02 12:12:41 +05:30
Shivashis Padhi
d5f5d18fa9 Lint fix 2022-08-01 14:38:32 +05:30
Agniva De Sarker
55f64195b1 MM-45195: Use api4/bot and app/bot to use logger context (#20729)
https://mattermost.atlassian.net/browse/MM-45195

```release-note
NONE
```
2022-08-01 13:48:45 +05:30
Mattermod
8a532c0b8c Merge branch 'master' into MM-45118_my_top_dms 2022-07-29 10:46:32 +03:00
Agniva De Sarker
887bc0173e MM-45715: Fix incorrect permissions (Round 2) (#20731)
We missed a case to return if there are no
items in the slice. Otherwise it falls through
and returns false incorrectly.

Rectified the tests to trigger the case.

https://mattermost.atlassian.net/browse/MM-45715

```release-note
NONE
```
2022-07-29 09:58:44 +05:30
Tim Scheuermann
832736da37 [MM-45990] log JSON parsing errors in API4 (#20724) 2022-07-28 17:05:03 +02:00
Ashish Bhate
04cd6d35e9 MM-45272: Fix getPostThread permissions (#20565)
Summary
Fix permissions for the the getPostThread API Method.
User can view thread if user is member of the channel
User can view threads in public channels (in the user's team) that they're not a member of, only if compliance export is disabled.

Ticket Link
https://mattermost.atlassian.net/browse/MM-45272
2022-07-28 20:25:20 +05:30
Pablo Andrés Vélez Vidal
0ee05ce054 MM-45713 - change 500 error to json object (#20682)
* MM-45713 - change 500 error to json object

* validate possible encoding errors and follow standards

* replace normal debugging string with true string

* use bool type instead of string

Co-authored-by: Pablo Velez Vidal <pablo.velez@mattermost.com>
Co-authored-by: Mattermod <mattermod@users.noreply.github.com>
2022-07-28 15:07:54 +02:00
Shivashis Padhi
f007d94155 Ignore self DMs 2022-07-28 12:46:18 +05:30
Agniva De Sarker
0e75cecc4f Fix bad merge due to https://github.com/mattermost/mattermost-server/pull/20674 (#20728)
```release-note
NONE
```
2022-07-28 10:34:02 +05:30
Agniva De Sarker
d4b710b3ab MM-45194: Switch app/user and api4/user to logger context (#20674)
```release-note
NONE
```

Co-authored-by: Mattermod <mattermod@users.noreply.github.com>
2022-07-28 10:04:21 +05:30
Agniva De Sarker
90c6350410 Revert "move metrics server into platform service (#20683)" (#20726)
This reverts commit b18a42313b.

Co-authored-by: Mattermod <mattermod@users.noreply.github.com>
2022-07-27 21:30:25 +02:00
Tim Scheuermann
f199be6aa5 [MM-45715] Check for correct permission when requesting teams (#20715) 2022-07-27 19:17:02 +02:00
Shivashis Padhi
e94532c862 SecondParticipant now has extended user object 2022-07-27 18:41:18 +05:30
Shivashis Padhi
849aea452c Merge branch 'master' of github.com:mattermost/mattermost-server into top-dms-clean 2022-07-27 17:03:34 +05:30
Tim Scheuermann
eba08cbb11 Replace ioutil.Discard with io.Discard (#20707) 2022-07-27 11:40:33 +02:00
Julien Tant
1044fba449 [MM-45817] Set cloud cookies whenever user gets logged in (#20692) 2022-07-26 07:47:09 -07:00
Agniva De Sarker
20cb042362 Hackathon: Post Reminders (#20555)
This PR adds the post reminder backend work.

We add a new API endpoint via which a user can set a reminder for a post. An ephemeral message will be sent down the line to let the user know about the action. And then after the time is over, the system admin bot will send a DM message to the user about the reminder post.
2022-07-26 16:12:56 +05:30
Nathaniel Allred
77881fc357 Mm 43609 (#20657)
* return first inaccessible post time instead of has inaccessible posts
2022-07-25 16:01:59 -05:00
Ibrahim Serdar Acikgoz
b18a42313b move metrics server into platform service (#20683)
move metrics into platform
2022-07-25 16:54:06 +03:00
Shivashis Padhi
365def37cb Lint fixes 2022-07-25 14:36:23 +05:30
Shivashis Padhi
e2e9e2cd14 Add check for deleted users' DMs 2022-07-25 14:24:46 +05:30
Shivashis Padhi
5f56d43d80 Make the following changes
- Use db userId instead of referring to session
 - Filter out bot DM channels, and add relevant test
2022-07-25 14:07:08 +05:30
Claudio Costa
9255671222 [MM-45862] Set size and extension to fileinfo (#20681)
* Set size and extension to fileinfo

* Remove unnecessary check
2022-07-22 09:14:01 +02:00
Riccardo Santoni
3d7859396d [MM-42194] Get file information from a deleted post (#20279)
* Introduced inlcude_deleted query parameter to allow admins to retrieve contents of post regardless of deletion status

* Introduced new client route and tests for getting file info of deleted posts

* Fixed tests due to caching of posts

* gofmt

* Small formatting updates

* Invalidating file infos cache on delete of post if post includes files

* Including deleted in migration flow

* Moved invalidating of cache

Co-authored-by: Mattermod <mattermod@users.noreply.github.com>
2022-07-21 11:11:08 -04:00
Shivashis Padhi
ec463c45fc go vet fixes 2022-07-21 19:11:09 +05:30
Shivashis Padhi
0936c891ff Add client, integration tests for top DMs 2022-07-21 18:42:15 +05:30
Shivashis Padhi
0ab2189941 Add top DMs route and handlers 2022-07-21 18:39:03 +05:30
Shivashis Padhi
56cf4b4ee7 Clean license, and guest user check for top threads 2022-07-21 17:52:41 +05:30