dever 6 years ago
parent
commit
677cd038fd

+ 14 - 5
assets/layadmin/html/project/database/list.html

@@ -17,6 +17,13 @@
 .layui-table-cell {
     height: auto;
 }
+
+.table th,.table td {
+  min-width: 100px;
+}
+#table_2,#table_1 {
+  overflow: auto;
+}
 </style>
 <span id="dever-name" style="display:none;"></span>
 <div class="topbar">
@@ -60,13 +67,13 @@
         </div>
         <div id="table_1" style="display:none;"></div>
         <div id="table_2"> 
-          <table class="table layui-table" id="table" lay-filter="table" style="display:none;">
-          <thead>
+          <table class="table layui-table layui-table-body" id="table">
+          <thead id="list-thead">
               <tr>
                   <th>Company</th>
               </tr>
           </thead>
-          <tbody>
+          <tbody id="list-tbody">
               <tr>
                   <th></th>
               </tr>      
@@ -89,11 +96,11 @@
 </div>
 
   <script class="include" system="" path="inc/" file="script">include()</script>
-  <script id="list-thead">
+  <script ids="list-thead">
     config.table = {};
     config.table.cols = [];
   </script>
-  <script id="list-tbody">
+  <script ids="list-tbody">
     config.table.data = [];
   </script>
   <script>
@@ -107,6 +114,7 @@
     var form = layui.form; 
     var formSelects = layui.formSelects;
 
+    /*
     table.render({
       elem: '#table'
       ,page: false
@@ -114,6 +122,7 @@
       ,cols: config.table.cols
       ,data: config.table.data
     });
+    */
 
     init();
   });

+ 8 - 0
template/layadmin/project/database/list.php

@@ -30,10 +30,18 @@ $view
 ->fetch('#desc',	'manage/database.info#listDesc', 'none')
  
 # 数据列表的标题 
+/*
 ->loop('#list-thead', 'manage/database.list_thead_layui')      
 
 # 数据列表 
 ->loop('#list-tbody','manage/database.list_tbody_layui')  
+*/
+
+# 数据列表的标题 
+->loop('#list-thead tr', 'manage/database.list_thead')      
+
+# 数据列表 
+->loop('#list-tbody','manage/database.list_tbody')  
 
 
 # 数据列表