[PLT-6707] /header [text] slash command: Edit the channel header (#6566)
* add /header slash command * update websocket * updater per review
Этот коммит содержится в:
коммит произвёл
Joram Wilander
родитель
520cedea16
Коммит
976030ea25
@@ -212,6 +212,14 @@ export function showDeletePostModal(post, commentCount = 0) {
|
||||
});
|
||||
}
|
||||
|
||||
export function showChannelHeaderUpdateModal(channel) {
|
||||
AppDispatcher.handleViewAction({
|
||||
type: ActionTypes.TOGGLE_CHANNEL_HEADER_UPDATE_MODAL,
|
||||
value: true,
|
||||
channel
|
||||
});
|
||||
}
|
||||
|
||||
export function showGetPostLinkModal(post) {
|
||||
AppDispatcher.handleViewAction({
|
||||
type: ActionTypes.TOGGLE_GET_POST_LINK_MODAL,
|
||||
|
||||
@@ -229,6 +229,11 @@ function handleEvent(msg) {
|
||||
}
|
||||
}
|
||||
|
||||
function handleChannelUpdatedEvent(msg) {
|
||||
const channel = JSON.parse(msg.data.channel);
|
||||
dispatch({type: ChannelTypes.RECEIVED_CHANNEL, data: channel});
|
||||
}
|
||||
|
||||
function handleNewPostEvent(msg) {
|
||||
const post = JSON.parse(msg.data.post);
|
||||
handleNewPost(post, msg);
|
||||
@@ -341,11 +346,6 @@ function handleUserRemovedEvent(msg) {
|
||||
}
|
||||
}
|
||||
|
||||
function handleChannelUpdatedEvent(msg) {
|
||||
const channel = JSON.parse(msg.data.channel);
|
||||
dispatch({type: ChannelTypes.RECEIVED_CHANNEL, data: channel});
|
||||
}
|
||||
|
||||
function handleUserUpdatedEvent(msg) {
|
||||
const user = msg.data.user;
|
||||
if (UserStore.getCurrentId() !== user.id) {
|
||||
|
||||
Ссылка в новой задаче
Block a user