From 8722d2bb39c6c0697647e77a879d14b28d3ef0f5 Mon Sep 17 00:00:00 2001
From: zmk <496160012@qq.com>
Date: 星期五, 17 五月 2024 19:16:36 +0800
Subject: [PATCH] Merge branch 'master' of ssh://117.78.1.188:29418/dkyChenJiang

---
 javaweb-plus/javaweb-cms/src/main/resources/templates/geo/projectData/projectData.html |   64 ++++++++++++++-----------------
 1 files changed, 29 insertions(+), 35 deletions(-)

diff --git a/javaweb-plus/javaweb-cms/src/main/resources/templates/geo/projectData/projectData.html b/javaweb-plus/javaweb-cms/src/main/resources/templates/geo/projectData/projectData.html
index bb97ca8..50579ed 100644
--- a/javaweb-plus/javaweb-cms/src/main/resources/templates/geo/projectData/projectData.html
+++ b/javaweb-plus/javaweb-cms/src/main/resources/templates/geo/projectData/projectData.html
@@ -15,20 +15,6 @@
                                 <input type="text" name="name"/>
                             </li>
                             <li>
-                                <p>璧勬枡绫诲瀷锛�</p>
-                                <select name="dataType" th:with="type=${@dict.getType('project_data_type')}">
-                                    <option value="">鎵�鏈�</option>
-                                    <option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
-                                </select>
-                            </li>
-                            <li>
-                                <p>鏂囦欢绫诲瀷锛�</p>
-                                <select name="fileType" th:with="type=${@dict.getType('project_data_file_type')}">
-                                    <option value="">鎵�鏈�</option>
-                                    <option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
-                                </select>
-                            </li>
-                            <li>
                                 <p>鏍囩锛�</p>
                                 <input type="text" name="labels"/>
                             </li>
@@ -38,6 +24,7 @@
                             </li>
                         </ul>
                     </div>
+
                 </form>
             </div>
 
@@ -51,9 +38,12 @@
                 <a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="geo:projectData:remove">
                     <i class="fa fa-remove"></i> 鍒犻櫎
                 </a>
-                <a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="geo:projectData:export">
-                    <i class="fa fa-download"></i> 瀵煎嚭
-                 </a>
+<!--                <a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="geo:projectData:export">-->
+<!--                    <i class="fa fa-download"></i> 瀵煎嚭-->
+<!--                 </a>-->
+                <a class="btn btn-danger" data-toggle="modal" onclick="uploadZIP();">
+                    <i class="fa fa-upload"></i>涓婁紶闄勪欢
+                </a>
             </div>
             <div class="col-sm-12 select-table table-striped">
                 <table id="bootstrap-table"></table>
@@ -69,11 +59,12 @@
         var projectId=[[${projectId}]];
         var type=[[${type}]];
         var prefix = ctx + "geo/projectData";
+        console.log("type",type);
 
         $(function() {
             var options = {
-                url: prefix + "/list?projectId="+projectId + "&dataType=" + type,
-                createUrl: prefix + "/add",
+                url: prefix + "/list?projectId=" + projectId + "&dataType=" + type,
+                createUrl: prefix + "/add?projectId=" + projectId + "&dataType=" + type,
                 updateUrl: prefix + "/edit/{id}",
                 removeUrl: prefix + "/remove",
                 exportUrl: prefix + "/export",
@@ -87,22 +78,8 @@
                     visible: false
                 },
                 {
-                    field : 'name', 
+                    field : 'name',
                     title : '璧勬枡鍚嶇О'
-                },
-                {
-                    field : 'dataType', 
-                    title : '璧勬枡绫诲瀷',
-                    formatter: function(value, row, index) {
-                       return $.table.selectDictLabel(dataTypeDatas, value);
-                    }
-                },
-                {
-                    field : 'fileType', 
-                    title : '鏂囦欢绫诲瀷',
-                    formatter: function(value, row, index) {
-                       return $.table.selectDictLabel(fileTypeDatas, value);
-                    }
                 },
                 {
                     field : 'labels', 
@@ -118,13 +95,30 @@
                     formatter: function(value, row, index) {
                         var actions = [];
                         actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.id + '\')"><i class="fa fa-edit"></i>缂栬緫</a> ');
-                        actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="javascript:void(0)" onclick="$.operate.remove(\'' + row.id + '\')"><i class="fa fa-remove"></i>鍒犻櫎</a>');
+                        actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="javascript:void(0)" onclick="$.operate.remove(\'' + row.id + '\')"><i class="fa fa-remove"></i>鍒犻櫎</a> ');
+                        actions.push('<a class="btn btn-info btn-xs ' + '" href="javascript:void(0)" onclick="viewImg(\'' + row.dataUrl + '\' , \'' + row.id + '\')"><i class="glyphicon glyphicon-menu-hamburger"></i>鏌ョ湅闄勪欢</a>');
                         return actions.join('');
                     }
                 }]
             };
             $.table.init(options);
         });
+
+        // 涓婁紶闄勪欢
+        function uploadZIP(){
+            $.modal.open('涓婁紶闄勪欢', prefix + "/importImg");
+        }
+
+
+        // 鏌ョ湅鍥剧墖璇︽儏
+        function viewImg(path, id) {
+            if(path === null || path === '' || path === 'null'){
+                $.modal.alertSuccess("鏂囦欢鏃犳硶鎵撳紑锛�");
+                return;
+            }
+            var url = prefix + "/viewImage?id=" + id;
+            $.modal.open("鏌ョ湅鍥剧墖", url, 800, 600);
+        }
     </script>
 </body>
 </html>
\ No newline at end of file

--
Gitblit v1.9.1