DetailModal.vue 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101
  1. <template>
  2. <BasicModal @register="register" title="风机详情" width="100%" v-bind="$attrs" @ok="onSubmit" @cancel="onSubmit" :defaultFullscreen="true">
  3. <div class="detail-box">
  4. <div class="left-box">流程图</div>
  5. <div class="right-box">
  6. <div class="right-title">二部胶带机移变移动变电站控制详情</div>
  7. <div class="detail-container">
  8. <div class="detail-control">
  9. <div>高压分闸</div>
  10. <div>高压合闸</div>
  11. <div>高压复位</div>
  12. <div>低压复位</div>
  13. </div>
  14. <div class="detail-box">
  15. <a-tabs class="tabs-box" v-model:activeKey="activeKey" @change="tabChange">
  16. <a-tab-pane key="1" tab="运行状态">
  17. </a-tab-pane>
  18. <a-tab-pane key="2" tab="保护使能">
  19. </a-tab-pane>
  20. </a-tabs>
  21. </div>
  22. </div>
  23. </div>
  24. </div>
  25. </BasicModal>
  26. </template>
  27. <script lang="ts" setup>
  28. import { onMounted, ref, defineEmits, onUnmounted, watch } from 'vue';
  29. import { BasicModal, useModalInner } from '/@/components/Modal';
  30. const emit = defineEmits(['close', 'register'])
  31. const props = defineProps({
  32. })
  33. const activeKey = ref('1')
  34. // 注册 modal
  35. const [register, { closeModal }] = useModalInner();
  36. const tabChange = (key) => {
  37. activeKey.value = key
  38. }
  39. async function onSubmit() {
  40. emit('close')
  41. closeModal();
  42. }
  43. onMounted(async () => {
  44. });
  45. onUnmounted(() => {
  46. });
  47. </script>
  48. <style scoped lang="less">
  49. @import '/@/design/vent/color.less';
  50. @import '/@/design/vent/modal.less';
  51. .detail-box{
  52. width: 100%;
  53. height: 100%;
  54. padding: 10px;
  55. display: flex;
  56. justify-content: space-between;
  57. .left-box{
  58. width: 600px;
  59. height: 100%;
  60. border-right: 1px solid #ffffff22;
  61. display: flex;
  62. justify-content: center;
  63. align-items: center;
  64. font-size: 30px;
  65. }
  66. .right-box{
  67. flex: 1;
  68. height: 100%;
  69. .right-title{
  70. line-height: 60px;
  71. }
  72. .detail-container{
  73. height: 100%;
  74. display: flex;
  75. justify-content: space-between;
  76. .detail-control{
  77. width: 300px;
  78. display: flex;
  79. flex-direction: column;
  80. background: #ffffff11;
  81. }
  82. .detail-box{
  83. }
  84. }
  85. }
  86. }
  87. </style>