index.vue 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. <template>
  2. <div>
  3. <page-header
  4. :title="$t('compute.text_100')"
  5. :tabs="cloudEnvOptions"
  6. :current-tab.sync="cloudEnv"
  7. isShowResStatusTab
  8. :status-opts="statusOpts"
  9. :status-click-handle="statusClickHandle" />
  10. <page-body>
  11. <disk-list
  12. :id="listId"
  13. :getParams="getParams"
  14. :cloud-env="cloudEnv"
  15. :cloudEnvOptions="cloudEnvOptions"
  16. :filterParams="filterParams"
  17. statusResKey="disk"
  18. @resStatisticsChange="resStatisticsChange" />
  19. </page-body>
  20. </div>
  21. </template>
  22. <script>
  23. import { getCloudEnvOptions } from '@/utils/common/hypervisor'
  24. import ResStatisticsV2Mixin from '@/mixins/resStatisticsV2Mixin'
  25. import DiskList from './components/List'
  26. export default {
  27. name: 'DiskIndex',
  28. components: {
  29. DiskList,
  30. },
  31. mixins: [ResStatisticsV2Mixin],
  32. data () {
  33. return {
  34. listId: 'DiskList',
  35. getParams: {
  36. details: true,
  37. 'filter.0': 'disk_type.notin(volume)',
  38. },
  39. cloudEnvOptions: getCloudEnvOptions('compute_engine_brands'),
  40. cloudEnv: '',
  41. statusModule: 'disk',
  42. statusNormalList: ['ready'],
  43. }
  44. },
  45. }
  46. </script>