jwyu hai 1 ano
pai
achega
fb51a61ef6

+ 1 - 1
src/views/smartReport/components/ChartComp.vue

@@ -1,7 +1,7 @@
 <template>
     <div 
         class="report-comp-item chart-comp"
-        style="width:100%;height:100%;overflow: hidden;display:flex;flex-direction: column;margin-bottom:10px"
+        style="width:100%;height:100%;overflow: hidden;display:flex;flex-direction: column;"
     >
         <iframe :src="compData.content" style="flex:1;width:100%;height:100%;border-width:0px;"></iframe>
     </div>

+ 2 - 2
src/views/smartReport/components/ImgComp.vue

@@ -1,9 +1,9 @@
 <template>
     <div 
         class="report-comp-item img-comp" 
-        style="width:100%;height:100%;overflow-y: auto;margin-bottom:10px"
+        style="width:100%;height:100%;overflow-y: auto;"
     >
-        <img style="width:100%" :src="compData.content" alt="">
+        <img style="width:100%;display:block" :src="compData.content" alt="">
     </div>
 </template>
 

+ 1 - 1
src/views/smartReport/components/SheetComp.vue

@@ -1,7 +1,7 @@
 <template>
     <div 
         class="report-comp-item sheet-comp"
-        style="width:100%;overflow: hidden;margin-bottom:10px"
+        style="width:100%;overflow: hidden;"
     >
         <iframe :class="id" :src="compData.content" width="100%" style="border-width:0px;"></iframe>
     </div>

+ 1 - 1
src/views/smartReport/components/TextComp.vue

@@ -1,7 +1,7 @@
 <template>
     <div 
         class="report-comp-item text-comp" 
-        style="width:100%;height: 100%;overflow-y: auto;margin-bottom:10px"
+        style="width:100%;height: 100%;overflow-y: auto;"
     >
         <div class="rich-text-box" v-html="compData.content"></div>
     </div>

+ 18 - 6
src/views/smartReport/editReport.vue

@@ -65,7 +65,11 @@
                         :move="handleParentMove"
                     >
                         <div 
-                            :class="['report-drag-item-wrap',activeId===item.id?'blue-bg':'']" 
+                            :class="[
+                                'report-drag-item-wrap',
+                                activeId===item.id?'blue-bg':'',
+                                item.child&&!item.child.length?'report-drag-item-out':''
+                            ]"
                             v-for="item,index in conList" 
                             :key="item.id"
                             :comp-type="item.compType"
@@ -358,6 +362,9 @@ export default {
                 // targetBox.style.minHeight=`${h<50?50:h}px`
                 targetBox.style.height=`${h}px`
 
+                // 去除minhight
+                targetBox.style.minHeight=`10px`
+
                 // 计算宽度
                 const w=mouseEl.clientX-startX+targetBoxWidth
                 const resW= (w/parentBoxWidth)*100//计算出的百分比结果值
@@ -1124,11 +1131,10 @@ div{
         border-radius: 4px;
         border: 1px solid var(--gary-gy-5-line, #C8CDD9);
         background: #FFF;
-        padding: 20px 20px 20px 64px;
+        padding: 20px 20px 20px 44px;
         height: calc(100vh - 180px);
         position: relative;
         overflow-y: auto;
-        
     }
 }
 
@@ -1144,11 +1150,11 @@ div{
         min-height: 100%;
         .report-drag-item-wrap{
             width: 100%;
-            padding: 20px;
+            padding: 3px;
             min-height: 80px;
             border: 1px dashed #0052D9;
             position: relative;
-            margin-bottom: 10px;
+            margin-bottom: 3px;
             &:hover{
                 border-style: solid;
                 .opt-btn-box{
@@ -1193,8 +1199,14 @@ div{
                 cursor: nw-resize;
             }
         }
+        .report-drag-item-out{
+            display: flex;
+            padding-left: 20px;
+        }
         .report-drag-item-wrap_child-wrap{
-            min-height: 30px;
+            // min-height: 30px;
+            flex-shrink: 0;
+            min-width: 20px;
         }
         .report-drag-item-wrap_child_content{
             min-height: 80px;