mirror of
https://github.com/anyproto/anytype-ts.git
synced 2025-06-09 09:35:02 +09:00
JS-3902: revoke confirm
This commit is contained in:
parent
f73a9ac8a6
commit
bed2b8873e
2 changed files with 13 additions and 1 deletions
|
@ -274,6 +274,9 @@ const PopupSettingsSpaceShare = observer(class PopupSettingsSpaceShare extends R
|
|||
};
|
||||
|
||||
onStopSharing () {
|
||||
const { space } = commonStore;
|
||||
const { onPage } = this.props;
|
||||
|
||||
popupStore.open('confirm', {
|
||||
data: {
|
||||
title: translate('popupConfirmStopSharingSpaceTitle'),
|
||||
|
@ -281,7 +284,8 @@ const PopupSettingsSpaceShare = observer(class PopupSettingsSpaceShare extends R
|
|||
textConfirm: translate('popupConfirmStopSharingSpaceConfirm'),
|
||||
colorConfirm: 'red',
|
||||
onConfirm: () => {
|
||||
// stop sharing logic goes here
|
||||
C.SpaceInviteRevoke(space);
|
||||
onPage('spaceIndex');
|
||||
},
|
||||
},
|
||||
});
|
||||
|
|
|
@ -1883,6 +1883,14 @@ export const SpaceInviteView = (cid: string, key: string, callBack?: (message: a
|
|||
dispatcher.request(SpaceInviteView.name, request, callBack);
|
||||
};
|
||||
|
||||
export const SpaceInviteRevoke = (spaceId: string, callBack?: (message: any) => void) => {
|
||||
const request = new Rpc.Space.InviteRevoke.Request();
|
||||
|
||||
request.setSpaceid(spaceId);
|
||||
|
||||
dispatcher.request(SpaceInviteRevoke.name, request, callBack);
|
||||
};
|
||||
|
||||
export const SpaceJoin = (networkId: string, spaceId: string, cid: string, key: string, callBack?: (message: any) => void) => {
|
||||
const request = new Rpc.Space.Join.Request();
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue