diff --git a/src/main/resources/templates/pages/depository/table-stock.html b/src/main/resources/templates/pages/depository/table-stock.html
index 51431a26..0bf66584 100644
--- a/src/main/resources/templates/pages/depository/table-stock.html
+++ b/src/main/resources/templates/pages/depository/table-stock.html
@@ -86,8 +86,8 @@
@@ -151,8 +151,8 @@
var $ = layui.jquery,
form = layui.form,
upload = layui.upload,
+ util = layui.util,
table = layui.table;
- var util = layui.util;
let display = $("#display").val();
@@ -454,37 +454,7 @@
table.on('tool(currentTableFilter)', function (obj) {
let data = obj.data;
- /*if (obj.event === 'applicationIn') {
- // 入库申请
- var index = layer.open({
- title: '入库申请',
- type: 2,
- shade: 0.2,
- maxmin: true,
- shadeClose: true,
- area: ['100%', '100%'],
- content: '/application_in_back?mid=' + data.id + "&depositoryId=" + data.depositoryId
- });
- $(window).on("resize", function () {
- layer.full(index);
- });
- return false;
- } else */if (obj.event === 'applicationOut') {
- // 出库申请
- var index = layer.open({
- title: '出库申请',
- type: 2,
- shade: 0.2,
- maxmin: true,
- shadeClose: true,
- area: ['100%', '100%'],
- content: '/application_out_back?code=' + data.code + "&depositoryId=" + data.depositoryId
- });
- $(window).on("resize", function () {
- layer.full(index);
- });
- return false;
- } else if (obj.event === 'changeUnit') {
+ if (obj.event === 'changeUnit') {
let showQuantity = data.showQuantity;
let btn = $("#btn_" + data.id);
let clickNum = Number(btn.attr("click_num"));
@@ -524,16 +494,34 @@
// 事件
util.on('lay-on', {
- 'applicationIn': function(){
+ 'applicationIn': function(obj){
+ let mid = $(obj).attr('mid');
+ let depositoryId = $(obj).attr('depository');
+ layer.open({
+ type: 2,
+ offset: 'r',
+ anim: 'slideLeft', // 从右往左
+ area: ['40%', '100%'],
+ shade: 0.1,
+ title:"入库申请",
+ shadeClose: true,
+ id: 'ID-demo-layer-direction-r',
+ content: '/application_in_back?mid=' +mid + "&depositoryId=" + depositoryId
+ });
+ },
+ 'applicationOut': function(obj){
+ let code = $(obj).attr('code');
+ let depositoryId = $(obj).attr('depository');
layer.open({
- type: 1,
+ type: 2,
offset: 'r',
anim: 'slideLeft', // 从右往左
- area: ['320px', '100%'],
+ area: ['40%', '100%'],
shade: 0.1,
+ title:"出库申请",
shadeClose: true,
id: 'ID-demo-layer-direction-r',
- content: '任意 HTML 内容
'
+ content: '/application_out_back?code=' + code+ "&depositoryId=" + depositoryId
});
},
diff --git a/target/classes/static/js/lay-module/layuimini/miniMenu.js b/target/classes/static/js/lay-module/layuimini/miniMenu.js
index 14b62d83..12348a1c 100644
--- a/target/classes/static/js/lay-module/layuimini/miniMenu.js
+++ b/target/classes/static/js/lay-module/layuimini/miniMenu.js
@@ -55,21 +55,25 @@ layui.define(["element", "laytpl", "jquery"], function (exports) {
*/
compileMenu: function (menu, isSub) {
// var menuHtml = '';
- var menuHtml = '';
+ var menuHtml = '';
if (isSub) {
menuHtml = ''
}
return laytpl(menuHtml).render(menu);
},
compileMenuContainer: function (menu, isSub) {
- var wrapperHtml = '';
+ var wrapperHtml;
+
if (isSub) {
- wrapperHtml = '{{d.children}}
';
+ wrapperHtml = '{{-d.children}}
';
+ } else {
+ wrapperHtml = '';
}
if (!menu.children) {
return "";
}
- return laytpl(wrapperHtml).render(menu);
+ let render = laytpl(wrapperHtml).render(menu);
+ return render;
},
each: function (list, callback) {
@@ -108,7 +112,6 @@ layui.define(["element", "laytpl", "jquery"], function (exports) {
});
return leftMenuHtml;
}).join("");
-
leftMenusHtml = me.compileMenuContainer({
id: options.parentMenuId,
className: options.leftMenuCheckDefault,
@@ -120,7 +123,7 @@ layui.define(["element", "laytpl", "jquery"], function (exports) {
* 判断是否为手机
* @returns {boolean}
*/
- checkMobile:function () {
+ checkMobile: function () {
var ua = navigator.userAgent.toLocaleLowerCase();
var pf = navigator.platform.toLocaleLowerCase();
var isAndroid = (/android/i).test(ua) || ((/iPhone|iPod|iPad/i).test(ua) && (/linux/i).test(pf))
@@ -150,12 +153,12 @@ layui.define(["element", "laytpl", "jquery"], function (exports) {
headerMenuCheckDefault = 'layui-this';
if (menuChildOpen) childOpenClass = ' layui-nav-itemed';
- if(miniMenu.checkMobile()){
- headerMenuHtml = this.each(menuList, function (index, val) { //顶部菜单渲染
+ if (miniMenu.checkMobile()) {
+ headerMenuHtml = this.each(menuList, function (index, val) { //顶部菜单渲染
leftMenuCheckDefault = 'layui-hide';
var menu = 'multi_module_' + index;
let title = val.title;
- if(title === '仓库管理'){
+ if (title === '仓库管理') {
leftMenuCheckDefault = 'layui-this';
}
var id = menu + "HeaderId";
@@ -183,8 +186,9 @@ layui.define(["element", "laytpl", "jquery"], function (exports) {
headerMenuCheckDefault = "";
return topMenuItemHtml;
}).join("");
- }else{
- headerMenuHtml = this.each(menuList, function (index, val) { //顶部菜单渲染
+ }
+ else {
+ headerMenuHtml = this.each(menuList, function (index, val) { //顶部菜单渲染
var menu = 'multi_module_' + index;
var id = menu + "HeaderId";
var topMenuItemHtml = "";
diff --git a/target/classes/templates/pages/depository/table-stock.html b/target/classes/templates/pages/depository/table-stock.html
index 51431a26..0bf66584 100644
--- a/target/classes/templates/pages/depository/table-stock.html
+++ b/target/classes/templates/pages/depository/table-stock.html
@@ -86,8 +86,8 @@
@@ -151,8 +151,8 @@
var $ = layui.jquery,
form = layui.form,
upload = layui.upload,
+ util = layui.util,
table = layui.table;
- var util = layui.util;
let display = $("#display").val();
@@ -454,37 +454,7 @@
table.on('tool(currentTableFilter)', function (obj) {
let data = obj.data;
- /*if (obj.event === 'applicationIn') {
- // 入库申请
- var index = layer.open({
- title: '入库申请',
- type: 2,
- shade: 0.2,
- maxmin: true,
- shadeClose: true,
- area: ['100%', '100%'],
- content: '/application_in_back?mid=' + data.id + "&depositoryId=" + data.depositoryId
- });
- $(window).on("resize", function () {
- layer.full(index);
- });
- return false;
- } else */if (obj.event === 'applicationOut') {
- // 出库申请
- var index = layer.open({
- title: '出库申请',
- type: 2,
- shade: 0.2,
- maxmin: true,
- shadeClose: true,
- area: ['100%', '100%'],
- content: '/application_out_back?code=' + data.code + "&depositoryId=" + data.depositoryId
- });
- $(window).on("resize", function () {
- layer.full(index);
- });
- return false;
- } else if (obj.event === 'changeUnit') {
+ if (obj.event === 'changeUnit') {
let showQuantity = data.showQuantity;
let btn = $("#btn_" + data.id);
let clickNum = Number(btn.attr("click_num"));
@@ -524,16 +494,34 @@
// 事件
util.on('lay-on', {
- 'applicationIn': function(){
+ 'applicationIn': function(obj){
+ let mid = $(obj).attr('mid');
+ let depositoryId = $(obj).attr('depository');
+ layer.open({
+ type: 2,
+ offset: 'r',
+ anim: 'slideLeft', // 从右往左
+ area: ['40%', '100%'],
+ shade: 0.1,
+ title:"入库申请",
+ shadeClose: true,
+ id: 'ID-demo-layer-direction-r',
+ content: '/application_in_back?mid=' +mid + "&depositoryId=" + depositoryId
+ });
+ },
+ 'applicationOut': function(obj){
+ let code = $(obj).attr('code');
+ let depositoryId = $(obj).attr('depository');
layer.open({
- type: 1,
+ type: 2,
offset: 'r',
anim: 'slideLeft', // 从右往左
- area: ['320px', '100%'],
+ area: ['40%', '100%'],
shade: 0.1,
+ title:"出库申请",
shadeClose: true,
id: 'ID-demo-layer-direction-r',
- content: '任意 HTML 内容
'
+ content: '/application_out_back?code=' + code+ "&depositoryId=" + depositoryId
});
},
diff --git a/target/classes/templates/pages/user/register.html b/target/classes/templates/pages/user/register.html
index 16eeb4b7..1fb1219d 100644
--- a/target/classes/templates/pages/user/register.html
+++ b/target/classes/templates/pages/user/register.html
@@ -7,7 +7,7 @@
-
+