123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152 |
- {Template header}
- <body>
- <div class="warp">
- <div class="fixed">
- <ul class="searchtop" style="text-align: center;padding: 10px 0 20px 0;border-bottom: 1px solid #ccc;">
- <li><input value="" name="hq" id="outsku" placeholder="点此处输入或扫码" type="text" style="width: 500px;text-align: center;"></li></ul>
- <ul class="search">
- <li>
- 店铺:<select name="shop" class="select">
- <option value="">请选择</option>
- {loop usershop() as $val}
- <option value="{$val['id']}">{$val['shopname']}</option>
- {/loop}</select>
- </li>
- <li>
- 快递:<select name="express" class="select">
- <option value="">请选择</option>
- {loop express(100) as $val}
- <option value="{$val['id']}">{$val['servicename']}</option>
- {/loop}</select>
- </li>
- <li>订单号:<input value="" name="orderinfo" type="text" ></li>
- <li>编号:<input value="" name="number" type="text" ></li>
- <li>运单号:<input value="" name="waybill" type="text" ></li>
- <li>客户名:<input value="" name="name" type="text" ></li>
- <li><input id="timetk" value="{date('Y-m-d',time()-30*24*3600)} 0:00" name="timetkk" type="text" onclick="laydate({istime: true,format:'YYYY-MM-DD hh:mm'})">
- 至 <input id="timetj" value="{date('Y-m-d',time()+24*3600)} 0:00" name="timetjj" type="text" onclick="laydate({istime: true,format:'YYYY-MM-DD hh:mm'})"></li>
- <input value="{$url}" name="cz" type="hidden">
- <li><span>确 定</span></li>
- <!-- <li><a href="javascript:void(0);" class="whlabelczdc">导出统计</a></li> -->
- </ul>
- <table class="datatitle data" border="0" style="border-collapse:collapse;">
- <tr>
- <td><label onClick="swapCheck()"><input name="checkbox" type="checkbox" class="regular-checkbox"></label></td>
- <td>店铺</td>
- <td>名称</td>
- <td>编号</td>
- <td>订单号</td>
- <td>快递</td>
- <td>运单号</td>
- <td>扫描时间</td>
- </tr>
- </table>
- </div>
- <table class="datatext data" border="0" style="border-collapse:collapse;">
- </table>
- <div class="bomf"></div>
- </div>
- <audio id="music_d">
- <source src="/data/print/d.mp3" type="audio/mpeg">
- </audio>
- <audio id="music_c">
- <source src="/data/print/c.mp3" type="audio/mpeg">
- </audio>
- <script>
- $(document).ready(function() {
- $("#outsku").focus();
- });
- var dataurl = "/fullorderout";
- var editurl = "/fullorderout/edit/";
- var editdj = 3;
- var editt = "退单管理 - 修改";
- var customon = 1;
- function custom(){
- $(".data tr").each(function() {
- });}
- $(".whlabelczdc").click(function() {
- var f = "";
- $(".select").each(function() {
- f = f + $(this).attr("name") + "=" + $(this).children("option:selected").val() + "&";
- });
- $("input:text").each(function() {
- f = f + $(this).attr("name") + "=" + $(this).val() + "&";
- });
- $("input:hidden").each(function() {
- f = f + $(this).attr("name") + "=" + $(this).val() + "&";
- });
- layx.load('loadId','数据准备中,请稍后',{shadable:0.6});
- $.ajax({
- url: "/whlabel/whlabelczdc",
- data: "excel="+$(this).data("id")+"&"+f,
- type: "get",
- success: function(exl) {
- layx.destroy('loadId');
- if(exl)
- {
- var ff = new Blob([data], {type: 'application/octet-stream'});
- console.log(ff);
- var data = exl;
- var blob = new Blob([data], {type: 'application/octet-stream'});
- var url = URL.createObjectURL(blob);
- var exportLink = document.createElement('a');
- exportLink.setAttribute("download",fileName);
- exportLink.href = url;
- document.body.appendChild(exportLink);
- exportLink.click();
- }
- else
- {
- $(".ts p").html("下载失败,请稍后再试");
- $(".ts").fadeIn();
- setTimeout('$(".ts").fadeOut()', 1100);
- }
- }
- });
- /**
- window.location.href = "/whlabel/whlabelczdc?excel="+$(this).data("id")+"&"+f;
- **/
- })
- $(document).keyup(function(event){
- if(event.keyCode ==13 && $("input[name=hq]").val()!=""){
- $("#orderinfo").blur();
- $(".express p:eq(0)").html("<i class='fa fa-2x fa-cog fa-spin'></i> 处理中,请稍后...");
- $(".express p:eq(1)").html("");
- $(".express").show();
- $.ajax({
- url: dataurl,
- data: "hq="+$("input[name=hq]").val(),
- type: "POST",
- dataType: "json",
- success: function(a) {
- $(".express").hide();
- if (a && a.success) {
- $("#music_d")[0].play();
- $("#outsku").val("");
- $("#orderinfo").val("");
- //$(".search span").click();
- //$("#orderinfo").focus();
- window.location.reload()
- } else {
- $("#music_c")[0].play();
- $(".express p:eq(0)").html(a.msg);
- $(".express p:eq(1)").html("<font class='wcsj'>确 定</font>");
- $(".express").show();
- $("#orderinfo").focus();
- }
- }
- });
- }
- });
- /* 清空并聚焦出库input */
- $(".express").on('click',".wcsj",function() {
- $("#outsku").val("");
- $("#outsku").focus();
- $(".express").hide();
- });
- $(".crk font").click(function() {
- window.location.href = $(this).data("cz");
- });
- ;</script>
- <script type="text/javascript" src="{$theme}js/laydate.js"></script>
- {Template footer}
|