diff options
| author | taehoon <th.dev91@gmail.com> | 2019-02-13 21:08:14 -0500 |
|---|---|---|
| committer | taehoon <th.dev91@gmail.com> | 2019-02-20 13:30:30 -0500 |
| commit | 8c8a6edc7800bac854ef23f29aa87f5b932cb415 (patch) | |
| tree | 175fdbdb07551998ab3e79b2b8bb06bf042351cd /src/components/user_settings | |
| parent | 159e84532ebdae038e1263efe8832015597a5e20 (diff) | |
Remove pagination support from block-list
Diffstat (limited to 'src/components/user_settings')
| -rw-r--r-- | src/components/user_settings/user_settings.js | 10 | ||||
| -rw-r--r-- | src/components/user_settings/user_settings.vue | 2 |
2 files changed, 7 insertions, 5 deletions
diff --git a/src/components/user_settings/user_settings.js b/src/components/user_settings/user_settings.js index 621dcd4b..8eade382 100644 --- a/src/components/user_settings/user_settings.js +++ b/src/components/user_settings/user_settings.js @@ -7,13 +7,15 @@ import StyleSwitcher from '../style_switcher/style_switcher.vue' import fileSizeFormatService from '../../services/file_size_format/file_size_format.js' import BlockCard from '../block_card/block_card.vue' import withLoadMore from '../../hocs/with_load_more/with_load_more' +import withSubscription from '../../hocs/with_subscription/with_subscription' import withList from '../../hocs/with_list/with_list' -const BlockList = withList(BlockCard, entry => ({ userId: entry.id })) -const BlockListWithLoadMore = withLoadMore( +const BlockList = withList(BlockCard, userId => ({ userId })) +const BlockListWithSubscription = withSubscription( BlockList, (props, $store) => $store.dispatch('fetchBlocks'), - (props, $store) => get($store.state.users.currentUser, 'blocks', []) + (props, $store) => get($store.state.users.currentUser, 'blockIds', []), + 'entries' ) const UserSettings = { @@ -53,7 +55,7 @@ const UserSettings = { StyleSwitcher, TabSwitcher, ImageCropper, - 'block-list': BlockListWithLoadMore + 'block-list': BlockListWithSubscription }, computed: { user () { diff --git a/src/components/user_settings/user_settings.vue b/src/components/user_settings/user_settings.vue index be9f27e7..5cf21815 100644 --- a/src/components/user_settings/user_settings.vue +++ b/src/components/user_settings/user_settings.vue @@ -164,7 +164,7 @@ </div> <div :label="$t('settings.blocks_tab')"> - <block-list /> + <block-list id="123" /> </div> </tab-switcher> </div> |
