index.vue 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. <template>
  2. <div class="reportManager">
  3. <customHeader>报表管理中心</customHeader>
  4. <div class="content">
  5. <NormalTable
  6. v-if="refesh"
  7. :columns="columns"
  8. :searchFormSchema="searchFormSchema"
  9. :deleteById="deleteById"
  10. :downLoad="downLoad"
  11. :list="reportList"
  12. designScope="device-tabel"
  13. title="报表管理"
  14. :showTab="true"
  15. @saveAdd="saveAdd"
  16. />
  17. </div>
  18. </div>
  19. </template>
  20. <script setup lang="ts">
  21. import { ref, nextTick } from 'vue';
  22. import customHeader from '/@/components/vent/customHeader.vue';
  23. import NormalTable from './comment/NormalTable.vue';
  24. import { columns, searchFormSchema } from './reportManager.data';
  25. import { reportList, save, deleteById, downLoad } from './reportManager.api';
  26. let refesh = ref(true);
  27. async function saveAdd(params) {
  28. let res = await save({ ...params });
  29. console.log(res, '新增成功-------');
  30. refesh.value = false;
  31. nextTick(() => {
  32. refesh.value = true;
  33. });
  34. }
  35. </script>
  36. <style lang="less" scoped>
  37. .reportManager {
  38. width: calc(100% - 20px);
  39. height: calc(100% - 90px);
  40. position: relative;
  41. margin: 80px 10px 10px 10px;
  42. .content {
  43. width: 100%;
  44. height: calc(100% - 30px);
  45. position: relative;
  46. }
  47. }
  48. </style>