Commit Graph
15681 Commits
Author SHA1 Message Date
MattermodandGitHub 91db5cc9da Update Licences at Notice.txt to reflect dependency changes. (#21751) 2022-11-29 13:30:18 +03:00
emmyniandGitHub fb072c02ec [MM-48088]: Ability to migrate from Monthly to Cloud Pro Annual (#21673) 2022-11-28 16:54:15 -05:00
emmyniandGitHub 2c71ba0f82 [MM-48097]: Delinquency Email Spacing/Wording Changes (#21740) 2022-11-28 14:46:48 -05:00
Martin KraftandGitHub e6424668ed MM-47936: Removes CustomGroups feature flag. (#21739)
* MM-47936: Removes CustomGroups feature flag.

* MM-47936: Updates godoc.
2022-11-28 13:49:51 -05:00
Tim ScheuermannandGitHub 44d6e14c29 [MM-48391] Store the server info in the export version line (#21709) 2022-11-28 17:35:47 +01:00
Pantelis VratsalisandGitHub 870e049230 Merge pull request #21750 from m1lt0n/translations_fix_nov_28
Translations fix nov 28
2022-11-28 18:21:52 +02:00
Martin KraftandGitHub c9190f58eb MM-41294: Allow team scheme APIs to be accessed with a professional l… (#21660)
* MM-41294: Allow team scheme APIs to be accessed with a professional license.

* MM-41294: Adds tests.
2022-11-28 11:19:58 -05:00
Martin KraftandGitHub a9078d8a29 MM-48181: Invalidate cache to reflect permissions changes from a team scheme. (#21735)
* MM-48181: Bust the allChannelMembersForUserCache when assigning a team scheme.

* MM-48181: Tests cache fix.
2022-11-28 11:18:17 -05:00
Martin KraftandGitHub 7586732b1c gofmt fixes. (#21742) 2022-11-28 11:16:47 -05:00
b09027495b [MM-47982] [MM-47983] Honor the ShowEmailAddress setting (#21707)
* Honor the ShowEmailAddress setting for the `/api/v4/teams/[teamid]/regenerate_invite_id` and `/api/v4/users/me/teams` API paths. Fixes MM-47982 and MM-47983

* Fix linter error in test code

* MM-48186: Add a new API endpoint to add a user to their default GroupChannels and GroupTeams. (#21591)

* MM-48186: Add a new API endpoint to add a user to their default GroupChannels and GroupTeams.

* MM-48186: Removed unrelated lint fixes.

* MM-48186: Removed variable from previous iteration.

* MM-48186: Adds translation.

* MM-48186: Not upgrading golang.org/x/text in this pr.

* MM-48186: Validate user ID and auth service.

* MM-48186: Use user id from struct.

* MM-48186: Added basic client test.

* MM-48186: Adds empty translation.

* MM-48186: Added translations.

Co-authored-by: Mattermod <[email protected]>

* [MM-47384] Make OpenID Connect free for all (#21556)

* wip: make OpenID Connect free-for-all

* Deprecation note: GoogleOAuth, Office365OAuth

* Improve deprecation comments

Co-authored-by: Martin Kraft <[email protected]>

* Lint fix

* Add model/oauthproviders, move google, openid, office365 from enterprise

* Vet fixes

* Remove redundant log

Co-authored-by: Martin Kraft <[email protected]>
Co-authored-by: Mattermod <[email protected]>

Co-authored-by: Martin Kraft <[email protected]>
Co-authored-by: Mattermod <[email protected]>
Co-authored-by: Shivashis Padhi <[email protected]>
2022-11-28 11:12:41 -05:00
Pantelis Vratsalis ca97fb9de3 Fix translations conflicts 2022-11-28 17:42:44 +02:00
Miguel de la CruzandGitHub 1511352c05 Update haserver docker-compose to include boards as a product (#21738) 2022-11-28 12:34:51 +03:00
f0ceece785 MM-48070 - Remove the unused CallsMobile feature flag (#21721)
Co-authored-by: Mattermod <[email protected]>
2022-11-25 14:45:25 -05:00
2461c16581 Adds support for clustered websocket messages for products (#21737)
* Adds support for clustered websocket messages for products

* Update app/cluster_handlers.go

Co-authored-by: Ibrahim Serdar Acikgoz <[email protected]>

Co-authored-by: Ibrahim Serdar Acikgoz <[email protected]>
2022-11-25 18:02:30 +01:00
Alejandro García MontoroandGitHub 6669566731 Skip flaky test GetUptoNSizeFileTime (#21731) 2022-11-25 12:33:51 +01:00
Ibrahim Serdar AcikgozandGitHub c9c3d5c357 Revert "app/pluginservice: move plugin out from the Channels product (#21697)" (#21725)
This reverts commit a610f78567.
2022-11-24 19:22:36 +05:30
Martin KraftandGitHub 430ae3fef4 New isrole replacement (#21688)
* Adds new function to use in place of isRole that includes team and channel schemes.

* Adds tests. Fixes code.

* Adds warning to isRole.

* Fixes phrasing.

* Added more docs.

* Moved from strings to constants.

* Added some spacing and improved some comments.

* Renames some functions.

* Rename isNotRole to isNotExactRole. Add a new isNotRole function.

* Switch to only checking prefix.

* Ignores unused function warning.

* Lint fix.

* Switch from unused to deadcode.

* Adds test for isNotRole.
2022-11-24 07:41:09 -05:00
Miguel de la CruzandGitHub e3f748d65c Prepackage Boards v7.5.2 (#21713) 2022-11-24 13:01:29 +01:00
Daniel SchallaandGitHub ac91327342 [CLD-4570] Disable CodeQL Auto Build (#21716)
* Disable CodeQL Auto Build

* Update codeql-analysis.yml

* Separate Linux Build Targets
2022-11-24 16:16:39 +05:30
Ibrahim Serdar AcikgozandGitHub a610f78567 app/pluginservice: move plugin out from the Channels product (#21697) 2022-11-24 11:13:29 +03:00
5db468d906 MM-45317: global drafts endpoints and ws events (#20614)
* MM-23881: global drafts endpoints and ws events

Adds endpoints:
- create/update drafts
- delete draft
- get drafts

Adds WS events:
- draft_updated
- draft_created
- draft_deleted

* Ordering and WS event name fixes

* Adds PostID to the drafts table

In the future the drafts will include edited posts, this commit adds the
post id in the combined pkey of the table.

* Fixes route for deleting a thread draft

* Fixes failed checks

* Fixes migrations

* Fixes migration

* Extract translation strings

* Removes PostID since we won't sync editing posts

* Fixes tests

* Fixes i18n

* Update migrations for global drafts

* update branch with latest master changes

* Add feature flag for global drafts

* Set global drafts feature flag default to true

* Added support for files in drafts

* Fix failing i18n check

* Added support for deleting files in drafts

* Revert "Added support for deleting files in drafts"

This reverts commit 45dfd04a760359de2e8814d652c9ef46daf994f6.

* Triggering new test server

* Add config setting 'AllowSyncedDrafts' for syncing drafts with server

* Triggering new test server

* Triggering new test server

* Add guard for config setting and add initial tests

* Fix i18n and lint errors

* Triggering new test server

* Add tests for drafts

* fix lint issues

* Add tests for model/draft

* Triggering new test server

* Triggering new test server

* Trigger new test server

* Address PR comments

* Change left join to regular join in GetDraftsForUser

* Fix broken test

Maybe consider adding an inclDeleted field if we want to get deleted drafts in the future

* fix translations

* Add store tests for drafts

* fix test naming

* remove comment

* update migrations

* set feature flag default to false

* update migrations

Co-authored-by: Mylon Suren <[email protected]>
Co-authored-by: Mattermod <[email protected]>
2022-11-23 22:21:40 -05:00
d07f114dfb MM-47750: Adds PostAcknowledgements table and apis (#21689)
* MM-46410: adds urgency on mention counts

We have introduced priority for posts in
https://github.com/mattermost/mattermost-webapp/pull/10951.
We do need to color the mention badges in the webapp with a prominent
color when a mention is posted in an urgent message.
A thread has urgent mentions if the root post is marked as urgent, and
the replies contain mentions to the user viewing the thread.

This PR adds two columns, urgentmentioncount, and isurgent, in
channelmembers, and threads tables respectively.
Furthermore when asking for team/thread mention counts, we also return
urgent mention counts for the user.

* Fixes method in tests

* empty commit

* Fixes method call

* Fixes single thread response is_urgent

* Fixes errors

* Fixes mysql migration and adds graphql schema

* Fixes tests

* Refactors IsUrgent and Adds PostsPriority table

Changes:
- removes is_urgent from the threads table
- adds a new table to hold posts priorities
- refactors priority out of the props and into the new table

* Fixes

* Adds translation strings

* Fixes migrations and tests

* Fixes tests

* empty

* Adds Priority to Copy

* empty

* Fixes priority not saved when boards is enabled

We are nilifying Metadata when post.ForPlugin(), which didn't save Priority
for a post when Boards was enabled.
This commit copies metadata again to the post, so metadata are
reinstated.

* Fixes tests

* Adding store tests and fixes syntax error

* Uses threads.ThreadTeamId

* Fixes error

* Adds UrgentMentionCount in graphql api test

* Fetches post priority in batches

* Addresses review comments

* Restore only priority on create post

* Fixes tests

* Nits

* Some refactoring

* Fixes get thread options when post priority enabled

* Adds missing translation

* Use the constant instead of "urgent" string

* Renames urgent constant

* MM-47750: Adds PostAcknowledgements table and apis

- Adds post acknowledgement api/app/store methods to be able to save and
delete post acknowledgements by users.
- Adds wesbsocket events for acknowledgement created/deleted
- Returns post acknowledgements in the post's metadata

* Empty

* Fixes incorrect urgent count when marking a post as unread

* Adds license

* Fixes ACK api, and adds tests

* Fixes vet

* Fixes tests

* Addresses review comments

* Remove unnecessary lines

* Adds config option and changes return of delete ack

* Empty

* Empty

* Enable config by default

* Fixes intl

* Fixes test after setting config default true

* Changes endpoints to PostForUser

* Avoids replica lag

* Fixes error in merge

* Fixes RetryLayer tests due to merge

* Empty

* Empty

* Empty

Co-authored-by: Mattermod <[email protected]>
2022-11-23 19:41:23 -05:00
5418023f35 MM-46410: adds urgency on mention counts (#20999)
* MM-46410: adds urgency on mention counts

We have introduced priority for posts in
https://github.com/mattermost/mattermost-webapp/pull/10951.
We do need to color the mention badges in the webapp with a prominent
color when a mention is posted in an urgent message.
A thread has urgent mentions if the root post is marked as urgent, and
the replies contain mentions to the user viewing the thread.

This PR adds a column, urgentmentioncount, in channelmembers.
Furthermore when asking for team/thread mention counts, we also return
urgent mention counts for the user.

Adds a new table to hold posts priorities
Refactors priority out of the props and into the new table

We are nilifying Metadata when post.ForPlugin(), which didn't save Priority
for a post when Boards was enabled.
This commit copies metadata again to the post, so metadata are
reinstated.

Co-authored-by: Mattermod <[email protected]>
Co-authored-by: Vishal Choudhary <[email protected]>
2022-11-23 21:08:21 +02:00
Nick MisasiandGitHub 21fe49b385 [MM-48560] LastAccessiblePostTime not removed on upgrade to Professional (#21708)
* Delete system value for LastAccessibleFileTime and LastAccessiblePostTime if the limits are 0 and a value is set

* Update tests
2022-11-23 14:06:29 -05:00
Tom De MoorandHosted Weblate 52f2e0bda6 Deleted translation using Weblate (Croatian) 2022-11-23 17:42:52 +01:00
31480c231a [MM-48542] Removing integration limits (#21282)
* Removing integration limits

* Remove freemium limit test

* Remove test assertion regarding cloud limits

* Remove GetIntegrationsUsage

* Removing integrations usage notifications

* This shouldn't be removed

* Removing client call and websocket event

* Remove old translations

Co-authored-by: Mattermod <[email protected]>
2022-11-23 10:42:23 +01:00
KonstantinandHosted Weblate 6f7f85c6bf Translated using Weblate (Russian)
Currently translated at 100.0% (2390 of 2390 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/ru/
2022-11-23 10:02:03 +01:00
Angel Mendez CanoandHosted Weblate df4dc84e7f Translated using Weblate (Spanish)
Currently translated at 100.0% (2390 of 2390 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/es/
2022-11-23 10:02:03 +01:00
Hosted Weblate 9f437c0ab4 Update translation files
Updated by "Cleanup translation files" hook in Weblate.

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/

Update translation files

Updated by "Cleanup translation files" hook in Weblate.

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/
2022-11-23 10:02:02 +01:00
master7andHosted Weblate 337f9f01e6 Translated using Weblate (Polish)
Currently translated at 100.0% (2390 of 2390 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/pl/

Translated using Weblate (Polish)

Currently translated at 100.0% (2391 of 2391 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/pl/
2022-11-23 10:02:01 +01:00
jpruschandHosted Weblate fcc72e44d4 Translated using Weblate (German)
Currently translated at 100.0% (2391 of 2391 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/de/

Translated using Weblate (German)

Currently translated at 100.0% (2391 of 2391 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/de/
2022-11-23 10:02:01 +01:00
MArtin JohnsonandHosted Weblate 9b1dfa46de Translated using Weblate (Swedish)
Currently translated at 100.0% (2389 of 2389 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/sv/
2022-11-23 10:02:00 +01:00
aidenandHosted Weblate 77a3290bd7 Translated using Weblate (Korean)
Currently translated at 82.9% (1982 of 2389 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/ko/
2022-11-23 10:02:00 +01:00
WeblateandHosted Weblate 59a16bb857 Added translation using Weblate (Croatian) 2022-11-23 10:02:00 +01:00
kaakaaandHosted Weblate a32cda0dc3 Translated using Weblate (Japanese)
Currently translated at 100.0% (2389 of 2389 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/ja/
2022-11-23 10:01:59 +01:00
Tom De MoorandHosted Weblate 3638143b0f Translated using Weblate (Dutch)
Currently translated at 100.0% (2391 of 2391 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/nl/

Deleted translation using Weblate (Croatian)

Translated using Weblate (Dutch)

Currently translated at 100.0% (2389 of 2389 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/nl/
2022-11-23 10:01:59 +01:00
Matthew WilliamsandHosted Weblate 880008a77d Translated using Weblate (English (Australia))
Currently translated at 100.0% (2390 of 2390 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/en_AU/

Translated using Weblate (English (Australia))

Currently translated at 100.0% (2389 of 2389 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/en_AU/
2022-11-23 10:01:58 +01:00
Claudio CostaandGitHub b1fd6064af [MM-48523] Expose resumable uploads API to plugins (#21700)
* Expose resumable uploads API to plugins

* Update translations
2022-11-22 15:26:22 -06:00
eda963bffd Call Cloud HandleLicenseChange when license is changed in Cloud (#21583)
* Call Cloud HandleLicenseChange when license is changed in a cloud context

* Remove UpdateSubscriptionFromHook as its no longer necessary

* Update mocks

* Remove another reference

* Remove translation

Co-authored-by: Mattermod <[email protected]>
2022-11-22 13:22:45 -05:00
2610940ce6 [MM-5046] Fix emails search for Postgres DB (#21590)
* Support emails search in Postgres

* Add @ exception for postgres

* update comment

Co-authored-by: Mattermod <[email protected]>
2022-11-22 12:02:33 -05:00
01aaf37efc [MM-46692] Channel group member count (#21270)
* tools updates

* Revert "tools updates"

This reverts commit 676a705c33.

* adding channel member count to groups request

* fixing models

* adding a new test

* removing unused var

Co-authored-by: Benjamin Cooke <[email protected]>
Co-authored-by: Benjamin Cooke <[email protected]>
Co-authored-by: Benjamin Cooke <[email protected]>
Co-authored-by: Benjamin Cooke <[email protected]>
Co-authored-by: Mattermod <[email protected]>
2022-11-22 11:31:04 -05:00
Amy BlaisandGitHub b396c43756 Update minimum supported MacOS and Edge versions (#21520)
Automatic Merge
2022-11-22 16:09:11 +02:00
650a113217 [MM-42335] Fix in RenderMobileError (#21536)
* tools updates

* Revert "tools updates"

This reverts commit 676a705c33.

* fix

Co-authored-by: Benjamin Cooke <[email protected]>
Co-authored-by: Benjamin Cooke <[email protected]>
Co-authored-by: Benjamin Cooke <[email protected]>
Co-authored-by: Benjamin Cooke <[email protected]>
2022-11-22 08:43:26 -05:00
68b19e23dc [MM-47384] Make OpenID Connect free for all (#21556)
* wip: make OpenID Connect free-for-all

* Deprecation note: GoogleOAuth, Office365OAuth

* Improve deprecation comments

Co-authored-by: Martin Kraft <[email protected]>

* Lint fix

* Add model/oauthproviders, move google, openid, office365 from enterprise

* Vet fixes

* Remove redundant log

Co-authored-by: Martin Kraft <[email protected]>
Co-authored-by: Mattermod <[email protected]>
2022-11-22 11:09:04 +05:30
de29627df8 MM-48186: Add a new API endpoint to add a user to their default GroupChannels and GroupTeams. (#21591)
* MM-48186: Add a new API endpoint to add a user to their default GroupChannels and GroupTeams.

* MM-48186: Removed unrelated lint fixes.

* MM-48186: Removed variable from previous iteration.

* MM-48186: Adds translation.

* MM-48186: Not upgrading golang.org/x/text in this pr.

* MM-48186: Validate user ID and auth service.

* MM-48186: Use user id from struct.

* MM-48186: Added basic client test.

* MM-48186: Adds empty translation.

* MM-48186: Added translations.

Co-authored-by: Mattermod <[email protected]>
2022-11-21 13:36:41 -05:00
3f1c573a11 [MM-47145] My Insights license change (#21443)
* tools updates

* Revert "tools updates"

This reverts commit 676a705c33.

* remove license checks for my insights endpoints

* removing new config

* remove license checks from insights test

* adding some license tests for team endpoints

* fixing tests

Co-authored-by: Benjamin Cooke <[email protected]>
Co-authored-by: Benjamin Cooke <[email protected]>
Co-authored-by: Benjamin Cooke <[email protected]>
Co-authored-by: Benjamin Cooke <[email protected]>
Co-authored-by: Mattermod <[email protected]>
2022-11-18 11:29:06 -05:00
mattermod 9badbd9b1a Update latest version to 7.5.1 2022-11-18 15:50:15 +00:00
mattermod 0d62977263 Update latest version to 7.5.0 2022-11-18 15:35:54 +00:00
Ibrahim Serdar AcikgozandGitHub bf9f4f7ae9 migrations: bump morph dependency and reflect changes (#21670) 2022-11-17 19:36:08 +03:00
Agniva De SarkerandGitHub d98b9dd07b MM-47465: Fix flaky TestDeleteChannel (#21686)
Creating the post in a separate goroutine would create a race condition
because that method also calls GetChannel. This can cause a bug
if the cache was wiped before the the other goroutine would get
a chance to update the cache. And if that happens, then
it would populate the cache with the old value.

Pseudo-code

```
func deleteChannel() {
    go func() {
        getFromCache()
    }()
    updateDB()
    wipeCache() // a
}

func getFromCache() {
    err := checkCache()
    if err == ErrNotFound {
        getFromDB() // x
        updateCache() // y
    }
}

func Test() {
    deleteChannel()
    getFromCache()
}
```

If the sequence of events happen like
- x
- a
- y

Then the getFromCache() call later will get the wrong
value from cache.

The fix is to make the call synchronous.

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

Special thanks to @noxer for finding the root cause.

```release-note
NONE
```
2022-11-17 20:44:18 +05:30