Commit Graph

18285 Commits

Author SHA1 Message Date
Scott Bishel
82b8d4dc07
MM-55966 - Update ArrayFromJSON to use LimitedReader (#25510)
* update ArrayFromJSON to use LimitedReader

* update for bad merge

* fix lint errors

* update test code

* update unit tests

* update unit tests

* fix unit tests

* use consts, other cleanup

* add non sorting duplicate check

* set config to default value, then config setting if available

* fix lint errors

* fixes and debugs

* fix log test

* remove setting from Client, add unlimited Parser to client

* a couple more fixes

* another fix

* rename some variables

* remove superflous call

* check for valid MaximumPayloadSize

* update language file

* fix for e2e-tests

* update util function to return error

* lint fix

* update config property name to include unit

* fix for unit test

* add new config to telemetry

* call function to create LimitedReader

* Deprecate old function, use new function name

* return new AppError on failed parse

* return new AppError on failed parse

* return new AppError on failed parse

* add constant for i18n valid constants

* Update server/public/model/utils_test.go

Co-authored-by: Miguel de la Cruz <mgdelacroix@gmail.com>

* Apply suggestions from code review

Co-authored-by: Miguel de la Cruz <mgdelacroix@gmail.com>

* update error variable, remove unnecessary check

* Update function names

* fix errors from merge

* update unit test to create unique ids

---------

Co-authored-by: Mattermost Build <build@mattermost.com>
Co-authored-by: Miguel de la Cruz <mgdelacroix@gmail.com>
2024-01-09 10:04:16 -07:00
Syed Ali Abbas Zaidi
4f0598d592
[MM-56296] Convert ./components/sidebar/sidebar_channel/sidebar_group_channel/sidebar_group_channel.tsx from Class Component to Function Component (#25768)
* [MM-56296] Convert `./components/sidebar/sidebar_channel/sidebar_group_channel/sidebar_group_channel.tsx` from Class Component to Function Component

* refactor: remove unnecessary callback
2024-01-09 15:24:43 +01:00
Thomas Brq
eca13a947b
Convert class to function component (#25769)
Co-authored-by: Mattermost Build <build@mattermost.com>
2024-01-09 15:24:12 +01:00
Jesús Espino
e959d9e4ea
Simplifying the channel_header component (#25795)
* Simplifying the channel_header component

* Addressing PR Review Comments

* Addressing PR Review Comments

* Addressing linter errors

* Fixing CI

* Fixing CI

* Addressing PR Review Comments
2024-01-09 13:05:50 +01:00
Doug Lauder
93351ff8a4
Fix error message when sharing already shared channel; also make idempotent (#25854)
* fix appError/error assignment bug

* make ShareChannel plugin API idempotent

---------

Co-authored-by: Mattermost Build <build@mattermost.com>
2024-01-09 12:42:11 +01:00
Doug Lauder
241e8edc2e
Ping new shared channels remotes immediately (#25850)
* option for auto inviting plugin to all shared channels.

* auto-invite remotes to shared channels when flag set

* fix unit test

* immediately ping new remotes; fix unique siteurl bug

* make i18n-extract

* fix translations

* fix merge conflicts

* make modules-tidy

* revert accidental go.mod change

* revert accidental go.sum changes

---------

Co-authored-by: Mattermost Build <build@mattermost.com>
2024-01-09 12:35:05 +01:00
Mario Vitale
43c3003e9d
CLD-6867 E2E Tests - Decouple cycle creation from test running (#25367)
* Separate test cycle generation from test running

---------

Co-authored-by: Mattermost Build <build@mattermost.com>
2024-01-09 11:40:33 +01:00
Doug Lauder
000aa0d891
Plugin API for Shared Channels: support auto invite (#25834)
* option for auto inviting plugin to all shared channels.

* auto-invite remotes to shared channels when flag set

* fix unit test

---------

Co-authored-by: Mattermost Build <build@mattermost.com>
2024-01-08 18:12:18 +01:00
Jesse Hallam
b05093d508
Source available metrics (#24879)
* Expose metrics under a source available license

* do not assume Cluster()

* allow metrics if licensed or dev

* temporary vet override

* simplify BULID_TAGS handling

* auto clean old imports.go

* fix license listener

* e2e test metrics & license semantics

* update from enterprise

* switch back to mattermost-govet/v2@new now

* update metrics from upstream

* Update license_spec.js

Co-authored-by: Saturnino Abril <saturnino.abril@gmail.com>

* Update license_spec.js

Co-authored-by: Saturnino Abril <saturnino.abril@gmail.com>

* Update e2e-tests/cypress/tests/integration/channels/enterprise/metrics/license_spec.js

Co-authored-by: Saturnino Abril <saturnino.abril@gmail.com>

* Update e2e-tests/cypress/tests/integration/channels/enterprise/metrics/license_spec.js

* split up specs

* require/delete license earlier in e2e test

* expanded expect to debug failures

* more logging

* Revert "more logging"

This reverts commit 0bc513fd92.

* e2e: try deleting license first

* update from enterprise

* toggleMetricsOn to work around license delete

* eslint

* ensure admin before deleting license

* update from enterprise

* updates from enterprise

* fix cypress logging

* temp: log at DEBUG for Cypress tests

---------

Co-authored-by: Saturnino Abril <saturnino.abril@gmail.com>
Co-authored-by: Mattermost Build <build@mattermost.com>
2024-01-08 10:47:24 -04:00
Miguel de la Cruz
6184c36e0b
Fix make permission error (#25860) 2024-01-08 14:45:48 +01:00
Miguel de la Cruz
e1a27cf57f
Adds a team check to get groups by team (#25462)
* Adds a team check to get groups by team

* Update to take into account groups_by_channel and new permissions

* Update API docs
2024-01-08 13:28:51 +01:00
Syed Ali Abbas Zaidi
a1bdbe9875
[MM-56004] Convert ./components/post_view/new_message_separator/new_message_separator.tsx from Class Component to Function Component (#25647)
* [MM-56004] Convert `./components/post_view/new_message_separator/new_message_separator.tsx` from Class Component to Function Component

* refactor: update snapshot

---------

Co-authored-by: Mattermost Build <build@mattermost.com>
2024-01-08 11:13:56 +01:00
Nick Misasi
e52940cd08
Lock wrangler behind enterprise (#25703)
* Lock wrangler behind enterprise

* Run tests with SetupEnterprise so Thread Moving is unlocked. Tweak NewTestLicense to include a SkuShortName for 'enterprise'

* Don't set SkuShortName in NewTestLicense just in case. Fix up some old debug code in tests

* Remove checks on enterprise/e20 and just enforce that the workspace has any license

* Update admin_definition.tsx accordingly

---------

Co-authored-by: Mattermost Build <build@mattermost.com>
2024-01-05 13:20:37 -05:00
Devin Binnie
ac854498a4
[MM-56266] Check for public channels when getting channel member counts to avoid 403 errors (#25831)
* [MM-56266] Check for public channels when getting channel member counts to avoid 403 errors

* Fix test
2024-01-05 12:28:22 -05:00
Syed Ali Abbas Zaidi
d9c2a8825b
[MM-56290] Convert ./components/channel_header_dropdown/menu_items/toggle_favorite_channel/toggle_favorite_channel.tsx from Class Component to Function Component (#25762)
* [MM-56290] Convert `./components/channel_header_dropdown/menu_items/toggle_favorite_channel/toggle_favorite_channel.tsx` from Class Component to Function Component

* fix: update snapshots and check-types issue
2024-01-05 11:57:19 -05:00
Claudio Costa
077221a940
Revert "MM-55295: Improve DB performance of some APIs (#25318)" (#25852)
This reverts commit ec88ab4ee9.
2024-01-05 10:05:37 -06:00
M-ZubairAhmed
4b88bfd5fb
[MM-53149] White Screen when replying to a thread (#25818) 2024-01-05 06:47:23 +00:00
unified-ci-app[bot]
34e1692286
Update latest minor version to 9.5.0 (#25847)
Automatic Merge
2024-01-04 21:54:56 +02:00
Agniva De Sarker
ca94577cd5
MM-56260: connIndex: safely remove conns while iterating (#25785)
PR https://github.com/mattermost/mattermost/pull/22560
introduced a regression in the case where we had
multiple connections for a single user.

Because if connIndex.Remove was called during the iteration
from connIndex.ForUser, then the slice would be modified
during iteration and if a connection got removed,
then a good connection would move from the last index
to the current index. But since we would be actively
iterating, the last index would be read as nil and we would
never be able to reach the good connection.

We fix this by returning a copy of the original slice
if there are more than one elements in the slice.

https://mattermost.atlassian.net/browse/MM-56260
```release-note
Fix a bug where if there were multiple websocket
connections from a single user, then in case one connection
got removed during a broadcast, there was a possibility
that the other good connection might not get the event.
```
2024-01-04 13:36:22 -06:00
Harrison Healey
59549653a7
MM-56147 Add GetPreferenceForUser plugin API (#25704)
* MM-56147 Add GetPreferenceForUser plugin API

* Change return type to non-pointer for preference consistency

* Fix merge
2024-01-04 13:50:19 -05:00
Ben Schumacher
edc305716f
[MM-56284] Remove non-generic StoreResult (#25750) 2024-01-04 12:30:21 +01:00
Harrison Healey
502cd6ef7d
MM-56082 Add PreferencesHaveChanged plugin hook (#25659)
* Add interface for PreferencesHaveChanged hook

* Add context to preference-related methods of App

* Implement PreferencesHaveChanged

* Re-add missing "fmt" import

* Update minimum server version for the new hook

* Remove pointers to be consistent with other preference APIs
2024-01-03 12:25:53 -05:00
M-ZubairAhmed
18f0d8d88f
[MM-55407] Remove deprecated LocalizedIcon component (#25828) 2024-01-03 05:25:26 +00:00
Harshil Sharma
9016e30044
Fixed user reporting pagination (#25780)
* Fixed pagination and sorting for Postgres

* Updated tests
2024-01-02 10:41:00 -05:00
unified-ci-app[bot]
39b2ecf2dd
chore: Update NOTICE.txt file with updated dependencies (#25827)
Automatic Merge
2024-01-02 16:54:57 +02:00
M-ZubairAhmed
47bf846731
[MM-56387] Replace missed usage of LocalizedIcon in 'search_results_header.tsx' with i/span tags (#25826) 2024-01-02 10:36:33 +00:00
Sudhanva-Nadiger
64232a106e
[MM-47083] Migrate "components/pdf_preview.jsx" and tests to Typescript (#25211) 2024-01-02 10:33:42 +00:00
Kapil Dutta
b4ee90afca
[MM-55101] Replace usage of LocalizedIcon in 'multiselect.tsx' with i/span tags (#25665) 2024-01-01 12:12:03 +00:00
Sudhanva-Nadiger
ef0c5e2125
[MM-47086] Migrate "components/size_aware_image.jsx" and tests to Typescript (#25230) 2023-12-30 12:52:27 +00:00
Angel Mendez
fb1038548e
[MM-47961] Migrate /support/assertions.js e2e tests file to TypeScript (#25731) 2023-12-29 07:47:39 +00:00
M-ZubairAhmed
1af0782991
[MM-55307] Make AdminConsole/TeamFilterDropdown use AsyncSelect instead of LegacyInfiniteScroll (#25294) 2023-12-28 10:09:35 +00:00
Felipe Martin
81a1d725a0
[WIP] [MM-55031] OAuth Outgoing Connection App integration (#25379)
* OAuthOutgoingConnection model

* added store

* make generated

* add missing license headers

* fix receiver name

* i18n

* i18n sorting

* update migrations from master

* make migrations-extract

* update retrylayer tests

* replaced sql query with id pagination

* fixed flaky tests

* missing columns

* missing columns on save/update

* typo

* improved tests

* remove enum from mysql colum

* add password credentials to store

* license changes

* OAuthOutgoingConnectionInterface

* Oauth -> OAuth

* make generated

* merge migrations

* renamed migrations

* model change suggestions

* refactor test functionsn

* migration typo

* refactor store table names

* updated sanitize test

* cleanup merge

* refactor symbol

* list endpoint

* oauthoutgoingconnection -> outgoingoauthconnection

* signature change

* i18n update

* granttype typo

* naming

* api list

* uppercase typo

* i18n

* missing license header

* fixed path in comments

* updated openapi definitions

* sanitize connections

* make generated

* test license and no feature flag

* removed t.fatal

* updated testhelper calls

* yaml schema fixes

* switched interface name

* suggested translation

* missing i18n translation

* address comments

* updated i18n
2023-12-26 10:46:20 +01:00
Zubair Imtiaz
287cbad2d5
[MM-55974] Theme is not used in notification selector box in user notification settings (#25689) 2023-12-26 09:24:33 +00:00
Asaad Mahmood
8f0d2b05ea
MM-56352 - Making modals consistent overall (#25622)
* Modal UI Improvements

* Updating modal header

* Updating modals

* Updating invite as a guest

* Updating modals

* Modal fixes

* Updating modal footer DMs

* Updating footer buttons next prev

* Updating tests

* Updating tests

* Updating modal css

* Updating modal

* Updating UI

* Updating modal snap

* Updating modal issues

* Updating modal

* Updating modal scss

* Updating modal changes

* Updating sys console modal

* Updating modal css

* Updating modal issue

* Removing css file

* Updating test

* Updating modal

* Updating test spec
2023-12-26 12:36:22 +05:00
Syed Ali Abbas Zaidi
02e27f78b2
[MM-56291] Convert ./components/widgets/icons/checkbox_checked_icon.tsx from Class Component to Function Component (#25763)
* [MM-56291] Convert `./components/widgets/icons/checkbox_checked_icon.tsx` from Class Component to Function Component

* refactor: update snapshots
2023-12-26 09:04:36 +05:30
Syed Ali Abbas Zaidi
55e222a9e2
[MM-56019] Move the deactivate account section to the last, and change the button to danger (#25697)
* [MM-56019] 🎨 Move the deactivate account section to the last, and change the button to danger

* refactor: remove unnecessary divider
2023-12-26 09:04:03 +05:30
Angel Mendez
3a6264ad19
[MM-47306] Migrate /enterprise/integrations e2e tests to TypeScript (#25720) 2023-12-25 09:45:00 +00:00
Harshil Sharma
bc1a53472a
Added air-gapped contact sales modal (#25807) 2023-12-25 09:42:17 +00:00
Syed Ali Abbas Zaidi
77161715fc
[MM-56042] Show full timestamp with seconds in tooltip of post date (#25699) 2023-12-25 07:35:39 +00:00
Harshil Sharma
d23c16b9aa
Removed user bands (#25806) 2023-12-25 07:11:28 +00:00
Harshil Sharma
6520e570e0
Updated tier wording (#25808) 2023-12-25 07:09:20 +00:00
Doug Lauder
2d1135ca46
Shared channels plugin APIs for MS Teams plugin (#25805)
New plugin APIs and hooks for accessing Shared Channels service via plugin. 

- RegisterPluginForSharedChannels(opts model.RegisterPluginOpts) (remoteID string, err error)
- UnregisterPluginForSharedChannels(pluginID string) error
- ShareChannel(sc *model.SharedChannel) (*model.SharedChannel, error)
- UpdateSharedChannel(sc *model.SharedChannel) (*model.SharedChannel, error)
- UnshareChannel(channelID string) (unshared bool, err error)
- UpdateSharedChannelCursor(channelID, remoteID string, cusror model.GetPostsSinceForSyncCursor) error
- SyncSharedChannel(channelID string) error
- InviteRemoteToChannel(channelID string, remoteID string, userID string) error
- UninviteRemoteFromChannel(channelID string, remoteID string) error

Hooks
- OnSharedChannelsSyncMsg(msg *model.SyncMsg, rc *model.RemoteCluster) (model.SyncResponse, error)
- OnSharedChannelsPing(rc *model.RemoteCluster) bool
2023-12-22 17:00:27 -05:00
Ibrahim Serdar Acikgoz
0f3553c8ab
shared/filestore/localstore.go: remove unnecessary warning (#25801) 2023-12-22 19:26:57 +01:00
Agniva De Sarker
0496483a9e
MM-56359: Skip TestUploadLicenseFile (#25800) 2023-12-22 13:21:33 +01:00
Syed Ali Abbas Zaidi
11ae867ce3
[MM-56294] Convert ./components/admin_console/group_settings/group_details/group_profile.tsx from Class Component to Function Component (#25766)
* [MM-56294] Convert `./components/admin_console/group_settings/group_details/group_profile.tsx` from Class Component to Function Component

* refactor: update snapshots
2023-12-22 10:35:17 +01:00
Daniel Espino García
ec4fdba04e
Fix auto delete post when dismissed by a plugin (#25791) 2023-12-22 10:34:32 +01:00
Miguel de la Cruz
0e60f3d542
Improves validation in getRolesByName endpoint (#25215)
* Improves validation in getRolesByName endpoint

* Updates the max constant and fixes linter

* Adds a mechanism to split roles in chunks in the webapp client

---------

Co-authored-by: Mattermost Build <build@mattermost.com>
2023-12-22 10:29:51 +01:00
dkkb
be24f108e1
Refactor server runJobs function. (#23854) 2023-12-22 09:51:40 +01:00
Harshil Sharma
a59f5ccded
Added API to return user count bands and user count (#25796) 2023-12-21 13:00:19 +00:00
Syed Ali Abbas Zaidi
cac50f593b
[MM-56298] Convert ./components/file_attachment/file_thumbnail/file_thumbnail.tsx from Class Component to Function Component (#25761)
* [MM-56298] Convert `./components/file_attachment/file_thumbnail/file_thumbnail.tsx` from Class Component to Function Component

* refactor: implement code review changes
2023-12-21 15:43:08 +05:30