<!DOCTYPE html>
|
<html>
|
|
<head>
|
<meta charset="utf-8">
|
<title>标签打印</title>
|
<meta name="renderer" content="webkit">
|
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
|
<meta name="viewport"
|
content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
|
<link rel="stylesheet" href="../../layuiadmin/layui/css/layui.css" media="all">
|
<link rel="stylesheet" href="../../layuiadmin/style/admin.css" media="all">
|
<style media="print">
|
@page {
|
size: auto;
|
margin: 0 0 0 20px;
|
}
|
|
.layui-input {
|
padding-left: 0px;
|
}
|
|
.layui-form-item {
|
margin-bottom: 2px;
|
}
|
</style>
|
<style>
|
.layui-form-item .layui-input-inline {
|
display: block;
|
float: none;
|
left: -3px;
|
width: auto;
|
margin: 0 0 10px 90px;
|
}
|
|
.hideCls {
|
display: none;
|
}
|
|
.showCls {
|
display: block;
|
}
|
|
.font-size12 {
|
font-size: 14px;
|
}
|
|
.font-size10 {
|
font-size: 10px;
|
}
|
</style>
|
</head>
|
|
<body>
|
<div style="width:100%;">
|
<div class="layui-form" style="padding: 30px 15px 0px; " id="button">
|
<div class="layui-form-item" style="margin-bottom:0px;">
|
<label class="layui-form-label" style="width: 60px;">箱码1</label>
|
<div class="layui-input-inline">
|
<input type="text" id="BoxCode" name="BoxCode" placeholder="箱码1" autocomplete="off"
|
class="layui-input">
|
</div>
|
</div>
|
<div class="layui-form-item" style="margin-bottom:0px;">
|
<label class="layui-form-label" style="width: 60px;">箱码2</label>
|
<div class="layui-input-inline">
|
<input type="text" id="BoxCode2" name="BoxCode2" placeholder="箱码2" autocomplete="off"
|
class="layui-input">
|
</div>
|
</div>
|
<div class="layui-form-item" style="margin-bottom:0px; text-align: center;">
|
|
<button id="btnMerge" class="layui-btn layui-btn-edit" lay-event="Add"><i
|
class="layui-icon"></i>合并</button>
|
</div>
|
</div>
|
</div>
|
<script src="../../layuiadmin/layui/layui.js"></script>
|
<script src="../../js/public.js"></script>
|
<script src="../../js/jquery-3.5.1.min.js"></script>
|
<script src="../../js/jquery.cookie.js"></script>
|
<script>
|
var boxcode = "";
|
layui.config({
|
base: '../../layuiadmin/' //静态资源所在路径
|
}).extend({
|
index: 'lib/index' //主入口模块
|
}).use(['index', 'form', 'layer', 'laydate'], function () {
|
|
var $ = layui.$,
|
form = layui.form,
|
layer = layui.layer;
|
var laydate = layui.laydate;
|
var indes = layer.index;
|
|
var xun = 0;
|
|
$('#btnMerge').on('click', function () {
|
if ($("#BoxCode").val() ==''|| $("#BoxCode").val() == undefined) {
|
layer.msg("请输入箱码1!", {
|
icon: 2,
|
time: 2000 //2秒关闭(如果不配置,默认是3秒)
|
});
|
return -1;
|
}
|
if ($("#BoxCode2").val()=='' || $("#BoxCode2").val() == undefined) {
|
layer.msg("请输入箱码2!", {
|
icon: 2,
|
time: 2000 //2秒关闭(如果不配置,默认是3秒)
|
});
|
return -1;
|
}
|
var param = {
|
BoxNo: $("#BoxCode").val(),
|
BoxNo2:$("#BoxCode2").val(),
|
};
|
synData(IP + "/BllAsn/MergeLableBox", param, 'post', function (res) {
|
if (res.code == 0) { //成功
|
layer.msg(res.msg, {
|
icon: 1,
|
time: 2000 //2秒关闭(如果不配置,默认是3秒)
|
}, function () {
|
parent.location.reload();
|
parent.layer.close(layer.index);
|
});
|
|
} else { //不成功
|
layer.msg(res.msg, {
|
icon: 2,
|
time: 2500 //2秒关闭(如果不配置,默认是3秒)
|
}, function () { });
|
}
|
});
|
});
|
|
// 获取传递参数
|
function getQueryString(name) {
|
var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i");
|
var r = window.location.search.substr(1).match(reg);
|
if (r != null) return unescape(r[2]);
|
return null;
|
}
|
})
|
|
</script>
|
|
</body>
|
|
</html>
|