index.vue 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. <template>
  2. <div class="layout-padding">
  3. <div class="engagement-time">
  4. <el-row :gutter="12" style="padding: 0 12px 12px; row-gap: 12px;">
  5. <el-col :xs="24" :sm="24" :md="24" :lg="24" :xl="24">
  6. <SelectForm :type="type" :form="form" :title="'使用频率'" />
  7. </el-col>
  8. </el-row>
  9. <el-row :gutter="12" style="padding: 0 12px 12px; row-gap: 12px;">
  10. <el-col :xs="24" :sm="24" :md="24" :lg="24" :xl="24">
  11. <OneDay :type="type" :form="form" />
  12. </el-col>
  13. </el-row>
  14. <el-row :gutter="12" style="padding: 0 12px 12px; row-gap: 12px;">
  15. <el-col :xs="24" :sm="24" :md="24" :lg="24" :xl="24">
  16. <Week :type="type" :form="form" />
  17. </el-col>
  18. </el-row>
  19. <el-row :gutter="12" style="padding: 0 12px 12px; row-gap: 12px;">
  20. <el-col :xs="24" :sm="24" :md="24" :lg="24" :xl="24">
  21. <Month :type="type" :form="form" />
  22. </el-col>
  23. </el-row>
  24. </div>
  25. </div>
  26. </template>
  27. <script lang="ts" name="engagementTime" setup>
  28. import { reactive } from 'vue'
  29. import OneDay from './OneDay.vue';
  30. import Week from './Week.vue';
  31. import Month from './Month.vue';
  32. import SelectForm from '../components/SelectForm.vue';
  33. const type = ref('date');
  34. const form = reactive({
  35. dateArray: [new Date().getTime() - 1000 * 60 * 60 * 24 * 7, new Date().getTime()],
  36. date: new Date().getTime(),
  37. selectedDates: [] as string[], // 存储多个选中的日期
  38. timeCompare: 'time1',
  39. channel: 'all',
  40. version: 'all'
  41. })
  42. </script>
  43. <style scoped lang="scss">
  44. @import '/@/views/count/styles/common.scss';
  45. svg {
  46. vertical-align: middle;
  47. margin: 0 0 0 12px;
  48. }
  49. .engagement-time {
  50. }
  51. </style>