index.vue 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. <template>
  2. <div>
  3. <page-header
  4. :title="$t('dictionary.dbinstance')"
  5. isShowResStatusTab
  6. :status-opts="statusOpts"
  7. :status-click-handle="statusClickHandle" />
  8. <page-body>
  9. <rds-list
  10. :id="listId"
  11. :cloud-env="cloudEnv"
  12. :cloudEnvOptions="cloudEnvOptions"
  13. :filterParams="filterParams"
  14. statusResKey="rds"
  15. @refresh="refreshHandle"
  16. @resStatisticsChange="resStatisticsChange" />
  17. </page-body>
  18. </div>
  19. </template>
  20. <script>
  21. import { getCloudEnvOptions } from '@/utils/common/hypervisor'
  22. import ResStatisticsV2Mixin from '@/mixins/resStatisticsV2Mixin'
  23. import rdsList from './components/List'
  24. export default {
  25. name: 'RDSIndex',
  26. components: {
  27. rdsList,
  28. },
  29. mixins: [ResStatisticsV2Mixin],
  30. data () {
  31. return {
  32. listId: 'RDSList',
  33. cloudEnvOptions: getCloudEnvOptions('rds_engine_brands'),
  34. cloudEnv: '',
  35. statusNormalList: ['running'],
  36. }
  37. },
  38. methods: {
  39. createServer () {
  40. this.$router.push('/rds/create')
  41. },
  42. },
  43. }
  44. </script>