Rocket.Chat.ReactNative/app/lib/methods
Reinaldo Neto da6af286c6
[IMPROVE] Check permission to create a room (#3233)
* [IMPROVE] Check permission to create new message, channels, teams

* Show or not the button to create at RoomListView

* Check permission for each button inside NewMessageView

* Check permission to create private or public channel

* Minor tweak

* Refactor to create a function tuserHasRolePermission

* Refactor to use only one function at rocketchat to check the user permission

* Minor tweaks

* Reactive create channel

* reactive new message view, and handleHasPermission out of constructor

* handleHasPermission to didMount in roomListView

* remove console.log

* Call the function in componentDidMount

* Changed === to dequal, to check array

Co-authored-by: Gerzon Z <gerzonc@icloud.com>
Co-authored-by: Gerzon Z <gerzonzcanario@gmail.com>
Co-authored-by: AlexAlexandre <alexalexandrejr@gmail.com>
Co-authored-by: Diego Mello <diegolmello@gmail.com>
2021-10-05 10:59:40 -03:00
..
helpers Chore: Start Typescript migration (#3279) 2021-09-13 17:41:05 -03:00
subscriptions Chore: Start Typescript migration (#3279) 2021-09-13 17:41:05 -03:00
actions.js Chore: Start Typescript migration (#3279) 2021-09-13 17:41:05 -03:00
callJitsi.js Chore: Start Typescript migration (#3279) 2021-09-13 17:41:05 -03:00
canOpenRoom.js Chore: Start Typescript migration (#3279) 2021-09-13 17:41:05 -03:00
enterpriseModules.js Chore: Start Typescript migration (#3279) 2021-09-13 17:41:05 -03:00
getCustomEmojis.js Chore: Start Typescript migration (#3279) 2021-09-13 17:41:05 -03:00
getPermissions.js [IMPROVE] Check permission to create a room (#3233) 2021-10-05 10:59:40 -03:00
getRoles.js Chore: Start Typescript migration (#3279) 2021-09-13 17:41:05 -03:00
getRoomInfo.js Chore: Start Typescript migration (#3279) 2021-09-13 17:41:05 -03:00
getRooms.js Chore: Start Typescript migration (#3279) 2021-09-13 17:41:05 -03:00
getSettings.js Chore: Start Typescript migration (#3279) 2021-09-13 17:41:05 -03:00
getSingleMessage.js Chore: Start Typescript migration (#3279) 2021-09-13 17:41:05 -03:00
getSlashCommands.js Chore: Start Typescript migration (#3279) 2021-09-13 17:41:05 -03:00
getThreadName.js Chore: Start Typescript migration (#3279) 2021-09-13 17:41:05 -03:00
getUsersPresence.js Chore: Start Typescript migration (#3279) 2021-09-13 17:41:05 -03:00
loadMessagesForRoom.js Chore: Start Typescript migration (#3279) 2021-09-13 17:41:05 -03:00
loadMissedMessages.js Chore: Start Typescript migration (#3279) 2021-09-13 17:41:05 -03:00
loadNextMessages.js Chore: Start Typescript migration (#3279) 2021-09-13 17:41:05 -03:00
loadSurroundingMessages.js Chore: Start Typescript migration (#3279) 2021-09-13 17:41:05 -03:00
loadThreadMessages.js Chore: Start Typescript migration (#3279) 2021-09-13 17:41:05 -03:00
logout.js Chore: Start Typescript migration (#3279) 2021-09-13 17:41:05 -03:00
readMessages.js Chore: Start Typescript migration (#3279) 2021-09-13 17:41:05 -03:00
sendFileMessage.js Chore: Start Typescript migration (#3279) 2021-09-13 17:41:05 -03:00
sendMessage.js Chore: Start Typescript migration (#3279) 2021-09-13 17:41:05 -03:00
updateMessages.js Chore: Start Typescript migration (#3279) 2021-09-13 17:41:05 -03:00