Просмотр исходного кода

说明、计算规则动态高度

zhongzewei 6 лет назад
Родитель
Сommit
60ffe4716f

+ 3 - 2
web/maintain/ration_repository/dinge.html

@@ -115,7 +115,8 @@
                                 <!--  <div class="m-2"><a href="javacript:void(0);" data-toggle="modal" data-target="#editTsm" title="编辑">编辑说明</a></div>-->
                                   <div class="main-content m-2">
                                       <h5>说明</h5>
-                                      <textarea id="explanationShow" class="form-control" rows="35" style="background: white;"></textarea>
+                                      <!--<textarea id="explanationShow" class="form-control" rows="35" style="background: white;"></textarea>-->
+                                      <textarea id="explanationShow" class="form-control" style="background: white;"></textarea>
                                   </div>
                               </div>
                           </div>
@@ -125,7 +126,7 @@
                          <!--         <div class="m-2"><a href="javacript:void(0);" data-toggle="modal" data-target="#editTjs" title="编辑">编辑计算规则</a></div>-->
                                   <div class="main-content m-2">
                                       <h5>计算规则</h5>
-                                      <textarea id="ruleTextShow" class="form-control"   rows="35" style="background: white;"></textarea>
+                                      <textarea id="ruleTextShow" class="form-control" style="background: white;"></textarea>
                                   </div>
                               </div>
                           </div>

+ 4 - 0
web/maintain/ration_repository/js/global.js

@@ -21,6 +21,10 @@ function autoFlashHeight(){
     $('#partialBody').find('tr').find('td:eq(0)').width(partialWidth * 0.06);
     $('#partialBody').find('tr').find('td:eq(1)').width(partialWidth * 0.3);
     $('#partialBody').find('tr').find('td:eq(2)').width(partialWidth * 0.64);
+    //说明
+    $('#explanationShow').height($(window).height()-headerHeight-toolsBar-100);
+    //计算规则
+    $('#ruleTextShow').height($(window).height()-headerHeight-toolsBar-100);
 };
 $(window).resize(autoFlashHeight);
 /*全局自适应高度结束*/