Ming hace 4 años
padre
commit
02237e4a14
Se han modificado 3 ficheros con 25 adiciones y 25 borrados
  1. 2 2
      js/monthReport.js
  2. 21 21
      js/record-inner.js
  3. 2 2
      monthReport.html

+ 2 - 2
js/monthReport.js

@@ -17,7 +17,7 @@ layui.use('layer', function() {
             $('.clsBtn,.cancel').click(function() {
                 layer.close(layerCreateIndex);
                 //关闭弹框
-                window.open("./index.html");
+                window.open(`${BASEURL}view/mainframe.jsp`);
             })
         }
     })
@@ -878,7 +878,7 @@ $('#nextStep').click(function() {
 
                     //关闭弹框
                     $('.clsBtn,.cancel').click(function() {
-                        window.open("./index.html");
+                        window.open(`${BASEURL}view/mainframe.jsp`);
                     })
                 }
             })

+ 21 - 21
js/record-inner.js

@@ -3,7 +3,7 @@ var aa = '';
 
 
 // 详情弹框
-$(document).on('click', 'a.view-detail', function () {
+$(document).on('click', 'a.view-detail', function() {
 
     let dataId = $(this).data('id'); // 单位ID
     alert(dataId)
@@ -19,10 +19,10 @@ $(document).on('click', 'a.view-detail', function () {
             '700px', '500px'
         ],
         content: $(".queryPointDetailList"),
-        success: function () {
-            getPointDetailAjax({"id": dataId})
-            // 获取部门列表 ajax请求
-            $('.clsBtn,.cancel').click(function () {
+        success: function() {
+            getPointDetailAjax({ "id": dataId })
+                // 获取部门列表 ajax请求
+            $('.clsBtn,.cancel').click(function() {
                 layer.close(layerDepartmentIndex);
             })
         }
@@ -30,7 +30,7 @@ $(document).on('click', 'a.view-detail', function () {
 
 
     // 按钮搜索
-    $('#buttonSearch2').on('click', function () {
+    $('#buttonSearch2').on('click', function() {
         page = 1;
         getPointDetailAjax(getSearchParamObj2());
     })
@@ -66,11 +66,11 @@ function getPointDetailAjax(queryParam = {}, page = 1) {
     queryParam.page = page;
     queryParam.limit = 1; // 每页显示条数
     queryParam.start = (queryParam.page - 1) * queryParam.limit;
-    ajaxRequest(RECORD_AND_POINT, "POST", queryParam, function (result) {
+    ajaxRequest(RECORD_AND_POINT, "POST", queryParam, function(result) {
         let data = result.RESULT;
         let items = '';
         if (result.totalCount > 0) {
-            data.forEach(function (item, key) {
+            data.forEach(function(item, key) {
                 items += "<tr>" + "<td class='status'></td>" + "<td>" + item.spot_name + "</td>" + "<td>" + item.spot_address + "</td>" + "<td>" + item.wcqk + "</td>" + "<td>" + item.wcqk + "</td>" + "<td>" + item.wcqk + "</td>" + "<td ><a class='view-detail' data-id=" + item.phone + ">查看</a></td>" + "<td ><a class='view-detail' data-id=" + item.phone + ">查看</a></td>" + "</tr>"
             })
             $('#dataList2').html(items);
@@ -90,7 +90,7 @@ function getPointDetailAjax(queryParam = {}, page = 1) {
         $('#pageTo2').html(pageTo);
 
         // 无数据时
-        if (! result.totalCount) {
+        if (!result.totalCount) {
             $('.pager2.has-data').hide()
             $('.pager2.no-data').show()
         } else {
@@ -107,33 +107,33 @@ function getPointDetailAjax(queryParam = {}, page = 1) {
         } else {
             $('#firstPageButton2,#prevPageButton2').removeClass('disabled');
         }
-    }, function (errorMsg) {
+    }, function(errorMsg) {
         alert("请求数据失败!");
     }, 3)
-}
+};
 
 
 // 分页操作
-$('#firstPageButton2').on('click', function () {
+$('#firstPageButton2').on('click', function() {
     page = 1;
     getPointDetailAjax({}, 1)
-    // getListDataAjax(getSearchParamObj(), 1);
-})
+        // getListDataAjax(getSearchParamObj(), 1);
+});
 
-$('#lastPageButton2').on('click', function () {
+$('#lastPageButton2').on('click', function() {
     page = totalPages;
     // getListDataAjax({}, page);
     getPointDetailAjax({}, page)
-})
+});
 
-$('#prevPageButton2').on('click', function () {
+$('#prevPageButton2').on('click', function() {
     page -= 1;
     // getListDataAjax(getSearchParamObj(), page);
     getPointDetailAjax({}, page)
-})
+});
 
-$('#nextPageButton2').on('click', function () {
+$('#nextPageButton2').on('click', function() {
     page += 1;
     // getListDataAjax(getSearchParamObj(), page);
-    getPointDetailAjax({}, page)
-})
+    getPointDetailAjax(getSearchParamObj2(), page)
+})

+ 2 - 2
monthReport.html

@@ -44,9 +44,9 @@
                 </div>
                 <div class="btnArea">
                     <div class="btnGroup">
-                        <a id="nextStep" class="sgBtn ok"><img src="../../images/accept.png" alt=""> &nbsp;&nbsp;下一步
+                        <a id="nextStep" class="sgBtn ok"><img src="images/accept.png" alt=""> &nbsp;&nbsp;下一步
                         </a>
-                        <a class="sgBtn cancel"><img src="../../images/cancel.png" alt="">关闭</a>
+                        <a class="sgBtn cancel"><img src="images/cancel.png" alt="">关闭</a>
                     </div>
                 </div>
             </form>