index.vue 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. <template>
  2. <div>
  3. <page-header
  4. :title="$t('storage.text_37')"
  5. :tabs="cloudEnvOptions"
  6. :current-tab.sync="cloudEnv"
  7. isShowResStatusTab
  8. :status-opts="statusOpts"
  9. :status-click-handle="statusClickHandle" />
  10. <page-body>
  11. <list
  12. :id="listId"
  13. :cloud-env="cloudEnv"
  14. :cloudEnvOptions="cloudEnvOptions"
  15. :filterParams="filterParams"
  16. statusResKey="blockstorage"
  17. @resStatisticsChange="resStatisticsChange" />
  18. </page-body>
  19. </div>
  20. </template>
  21. <script>
  22. import ResStatisticsV2Mixin from '@/mixins/resStatisticsV2Mixin'
  23. import List from './components/List'
  24. export default {
  25. name: 'BlockAtorage',
  26. components: {
  27. List,
  28. },
  29. mixins: [ResStatisticsV2Mixin],
  30. data () {
  31. return {
  32. listId: 'BlockStorageList',
  33. cloudEnv: 'host',
  34. statusModule: 'blockstorage',
  35. statusNormalList: ['online', 'offline', 'unmount'],
  36. statusHiddenList: ['error'],
  37. }
  38. },
  39. computed: {
  40. cloudEnvOptions () {
  41. return [
  42. { key: 'host', label: this.$t('compute.text_111') },
  43. { key: 'baremetal', label: this.$t('compute.text_112') },
  44. ]
  45. },
  46. },
  47. }
  48. </script>