Added delete buttons to InstalledIntegrations

Этот коммит содержится в:
Harrison Healey
2016-03-28 16:17:17 -04:00
родитель 3634b5bab5
Коммит bb13476326
6 изменённых файлов: 215 добавлений и 66 удалений

Просмотреть файл

@@ -1213,3 +1213,33 @@ export function addOutgoingHook(hook, success, error) {
}
);
}
export function deleteIncomingHook(id) {
client.deleteIncomingHook(
{id},
() => {
AppDispatcher.handleServerAction({
type: ActionTypes.REMOVED_INCOMING_WEBHOOK,
id
});
},
(err) => {
dispatchError(err, 'deleteIncomingHook');
}
);
}
export function deleteOutgoingHook(id) {
client.deleteOutgoingHook(
{id},
() => {
AppDispatcher.handleServerAction({
type: ActionTypes.REMOVED_OUTGOING_WEBHOOK,
id
});
},
(err) => {
dispatchError(err, 'deleteOutgoingHook');
}
);
}