From 4d6c8efe44e81ff704d0e6c4dda7c2cc84535a6f Mon Sep 17 00:00:00 2001 From: syuilo Date: Sat, 8 Feb 2020 15:17:35 +0900 Subject: [PATCH] wip --- locales/ja-JP.yml | 1 + src/client/pages/my-groups/group.vue | 20 ++++++++++++++++++++ 2 files changed, 21 insertions(+) diff --git a/locales/ja-JP.yml b/locales/ja-JP.yml index 7f2c2a2d95..17bd5356ac 100644 --- a/locales/ja-JP.yml +++ b/locales/ja-JP.yml @@ -368,6 +368,7 @@ invite: "招待" invites: "招待" groupName: "グループ名" members: "メンバー" +transfer: "譲渡" _2fa: alreadyRegistered: "既に設定は完了しています。" diff --git a/src/client/pages/my-groups/group.vue b/src/client/pages/my-groups/group.vue index 67f5f9754f..c8170a2a57 100644 --- a/src/client/pages/my-groups/group.vue +++ b/src/client/pages/my-groups/group.vue @@ -7,6 +7,7 @@
{{ $t('rename') }} + {{ $t('transfer') }} {{ $t('delete') }}
@@ -135,6 +136,25 @@ export default Vue.extend({ this.group.name = name; }, + transfer() { + this.$root.new(MkUserSelect, {}).$once('selected', user => { + this.$root.api('users/groups/transfer', { + groupId: this.group.id, + userId: user.id + }).then(() => { + this.$root.dialog({ + type: 'success', + iconOnly: true, autoClose: true + }); + }).catch(e => { + this.$root.dialog({ + type: 'error', + text: e + }); + }); + }); + }, + async deleteGroup() { const { canceled } = await this.$root.dialog({ type: 'warning',