diff options
Diffstat (limited to 'src/components/user_settings')
| -rw-r--r-- | src/components/user_settings/user_settings.js | 8 | ||||
| -rw-r--r-- | src/components/user_settings/user_settings.vue | 5 |
2 files changed, 13 insertions, 0 deletions
diff --git a/src/components/user_settings/user_settings.js b/src/components/user_settings/user_settings.js index fa252e59..c4214744 100644 --- a/src/components/user_settings/user_settings.js +++ b/src/components/user_settings/user_settings.js @@ -242,6 +242,14 @@ const UserSettings = { } }) }, + importBlocks (file) { + return this.$store.state.api.backendInteractor.importBlocks(file) + .then((status) => { + if (!status) { + throw new Error('failed') + } + }) + }, /* This function takes an Array of Users * and outputs a file with all the addresses for the user to download */ diff --git a/src/components/user_settings/user_settings.vue b/src/components/user_settings/user_settings.vue index fc40bdc0..520a3d8a 100644 --- a/src/components/user_settings/user_settings.vue +++ b/src/components/user_settings/user_settings.vue @@ -180,6 +180,11 @@ <div class="setting-item" v-else> <h2>{{$t('settings.follow_export_processing')}}</h2> </div> + <div class="setting-item"> + <h2>{{$t('settings.block_import')}}</h2> + <p>{{$t('settings.import_blocks_from_a_csv_file')}}</p> + <Importer :submitHandler="importFollows" :successMessage="$t('settings.blocks_imported')" :errorMessage="$t('settings.block_import_error')" /> + </div> </div> <div :label="$t('settings.blocks_tab')"> |
