From 6822df350e06df44c08fc5bca15b7317878cd8c7 Mon Sep 17 00:00:00 2001 From: erdanergou Date: Tue, 20 Jun 2023 13:32:48 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E5=BA=93=E5=AD=98=E6=90=9C?= =?UTF-8?q?=E7=B4=A2=E6=8C=89=E5=BA=93=E4=BD=8D=E6=90=9C=E7=B4=A2=EF=BC=8C?= =?UTF-8?q?=E4=B8=94=E4=BF=AE=E5=A4=8D=E5=BA=93=E5=86=85=E7=A7=BB=E5=8A=A8?= =?UTF-8?q?=E6=97=B6=E7=9A=84bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../pages/depository/table-stock.html | 20 ++++++++++--------- .../pages/depository/table-stock.html | 20 ++++++++++--------- 2 files changed, 22 insertions(+), 18 deletions(-) diff --git a/src/main/resources/templates/pages/depository/table-stock.html b/src/main/resources/templates/pages/depository/table-stock.html index cb156918..c489f917 100644 --- a/src/main/resources/templates/pages/depository/table-stock.html +++ b/src/main/resources/templates/pages/depository/table-stock.html @@ -145,6 +145,7 @@ // 用于保证导入时点击只导入一次 let flagForImport = true; + let reqForPublic = {}; layui.use(['form', 'table', 'upload'], function () { var $ = layui.jquery, @@ -360,6 +361,7 @@ if (data.materialTypeId !== '') { req.materialTypeId = data.materialTypeId; } + reqForPublic = req; //执行搜索重载 table.reload('currentTableId', { url: '/material/findInventory', @@ -405,7 +407,8 @@ url: '/material/findInventory', page: { curr: 1 - } + }, + where:reqForPublic }, 'data'); }); } else { @@ -418,7 +421,8 @@ url: '/material/findInventory', page: { curr: 1 - } + }, + where:reqForPublic }, 'data'); }) } @@ -547,7 +551,7 @@ page: { curr: 1 } - , where: {} + , where:reqForPublic }, 'data'); } }); @@ -683,7 +687,8 @@ url: '/material/findInventory', page: { curr: 1 - } + }, + where:reqForPublic }, 'data'); }) }, @@ -758,7 +763,8 @@ url: '/material/findInventory', page: { curr: 1 - } + }, + where:reqForPublic }, 'data'); } }); @@ -767,10 +773,6 @@ }); return false; } - - $('body').on('click', '[data-refresh]', function () { - location.reload(); - }) }); diff --git a/target/classes/templates/pages/depository/table-stock.html b/target/classes/templates/pages/depository/table-stock.html index cb156918..c489f917 100644 --- a/target/classes/templates/pages/depository/table-stock.html +++ b/target/classes/templates/pages/depository/table-stock.html @@ -145,6 +145,7 @@ // 用于保证导入时点击只导入一次 let flagForImport = true; + let reqForPublic = {}; layui.use(['form', 'table', 'upload'], function () { var $ = layui.jquery, @@ -360,6 +361,7 @@ if (data.materialTypeId !== '') { req.materialTypeId = data.materialTypeId; } + reqForPublic = req; //执行搜索重载 table.reload('currentTableId', { url: '/material/findInventory', @@ -405,7 +407,8 @@ url: '/material/findInventory', page: { curr: 1 - } + }, + where:reqForPublic }, 'data'); }); } else { @@ -418,7 +421,8 @@ url: '/material/findInventory', page: { curr: 1 - } + }, + where:reqForPublic }, 'data'); }) } @@ -547,7 +551,7 @@ page: { curr: 1 } - , where: {} + , where:reqForPublic }, 'data'); } }); @@ -683,7 +687,8 @@ url: '/material/findInventory', page: { curr: 1 - } + }, + where:reqForPublic }, 'data'); }) }, @@ -758,7 +763,8 @@ url: '/material/findInventory', page: { curr: 1 - } + }, + where:reqForPublic }, 'data'); } }); @@ -767,10 +773,6 @@ }); return false; } - - $('body').on('click', '[data-refresh]', function () { - location.reload(); - }) });