Added initial backstage components and InstalledIntegrations page
Этот коммит содержится в:
@@ -1121,3 +1121,49 @@ export function getRecentAndNewUsersAnalytics(teamId) {
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
export function listIncomingHooks() {
|
||||
if (isCallInProgress('listIncomingHooks')) {
|
||||
return;
|
||||
}
|
||||
|
||||
callTracker.listIncomingHooks = utils.getTimestamp();
|
||||
|
||||
client.listIncomingHooks(
|
||||
(data) => {
|
||||
callTracker.listIncomingHooks = 0;
|
||||
|
||||
AppDispatcher.handleServerAction({
|
||||
type: ActionTypes.RECEIVED_INCOMING_WEBHOOKS,
|
||||
incomingWebhooks: data
|
||||
});
|
||||
},
|
||||
(err) => {
|
||||
callTracker.listIncomingHooks = 0;
|
||||
dispatchError(err, 'getIncomingHooks');
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
export function listOutgoingHooks() {
|
||||
if (isCallInProgress('listOutgoingHooks')) {
|
||||
return;
|
||||
}
|
||||
|
||||
callTracker.listOutgoingHooks = utils.getTimestamp();
|
||||
|
||||
client.listOutgoingHooks(
|
||||
(data) => {
|
||||
callTracker.listOutgoingHooks = 0;
|
||||
|
||||
AppDispatcher.handleServerAction({
|
||||
type: ActionTypes.RECEIVED_OUTGOING_WEBHOOKS,
|
||||
outgoingWebhooks: data
|
||||
});
|
||||
},
|
||||
(err) => {
|
||||
callTracker.listOutgoingHooks = 0;
|
||||
dispatchError(err, 'getOutgoingHooks');
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
@@ -68,6 +68,8 @@ export default {
|
||||
RECEIVED_PREFERENCE: null,
|
||||
RECEIVED_PREFERENCES: null,
|
||||
RECEIVED_FILE_INFO: null,
|
||||
RECEIVED_INCOMING_WEBHOOKS: null,
|
||||
RECEIVED_OUTGOING_WEBHOOKS: null,
|
||||
|
||||
RECEIVED_MSG: null,
|
||||
|
||||
|
||||
@@ -1398,3 +1398,13 @@ export function localizeMessage(id, defaultMessage) {
|
||||
|
||||
return id;
|
||||
}
|
||||
|
||||
export function freezeArray(arr) {
|
||||
for (const obj of arr) {
|
||||
Object.freeze(obj);
|
||||
}
|
||||
|
||||
Object.freeze(arr);
|
||||
|
||||
return arr;
|
||||
}
|
||||
|
||||
Ссылка в новой задаче
Block a user