-
Notifications
You must be signed in to change notification settings - Fork 1.5k
[NEW] Create Team #3082
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[NEW] Create Team #3082
Changes from 9 commits
2f5f247
c8a88c9
585a9ae
8b82bd4
c8b8680
a245af6
16fd575
1ff7711
69214be
27ced96
7e6a277
0a80ee5
300dacc
da6eb44
6c8406d
4bda9ba
ebd1f9c
b2e7067
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -728,7 +728,24 @@ const RocketChat = { | |
| prid, pmid, t_name, reply, users, encrypted | ||
| }); | ||
| }, | ||
|
|
||
| createTeam({ | ||
| name, users, type, readOnly, broadcast, encrypted | ||
| }) { | ||
| const params = { | ||
| name, | ||
| users, | ||
| type: type ? 1 : 0, | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 1 and 0 don't mean true and false. |
||
| room: { | ||
| readOnly, | ||
| extraData: { | ||
| broadcast, | ||
| encrypted | ||
| } | ||
| } | ||
| }; | ||
| // RC 3.13.0 | ||
| return this.post('teams.create', params); | ||
| }, | ||
| joinRoom(roomId, joinCode, type) { | ||
| // TODO: join code | ||
| // RC 0.48.0 | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -50,7 +50,7 @@ class SelectedUsersView extends React.Component { | |
| constructor(props) { | ||
| super(props); | ||
| this.init(); | ||
|
|
||
| this.flatlist = React.createRef(); | ||
| const maxUsers = props.route.params?.maxUsers; | ||
| this.state = { | ||
| maxUsers, | ||
|
|
@@ -190,9 +190,13 @@ class SelectedUsersView extends React.Component { | |
| if (users.length === 0) { | ||
| return null; | ||
| } | ||
| const ITEM_WIDTH = 250; | ||
| return ( | ||
| <FlatList | ||
| data={users} | ||
| ref={ref => this.flatlist = ref} | ||
| onContentSizeChange={() => this.flatlist.scrollToEnd()} | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Maybe we could do it on |
||
| getItemLayout={(_, index) => ({ length: ITEM_WIDTH, offset: ITEM_WIDTH * index, index })} | ||
| keyExtractor={item => item._id} | ||
| style={[sharedStyles.separatorTop, { borderColor: themes[theme].separatorColor }]} | ||
| contentContainerStyle={{ marginVertical: 5 }} | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.