| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241 |
- <%@ page contentType="text/html;charset=GBK"%>
- <%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
- <HEAD>
- <TITLE>收货信息</TITLE>
- <link href="${pageContext.request.contextPath }/liger/lib/ligerUI/skins/${sessionScope.css}/css/ligerui-all.css" rel="stylesheet" type="text/css" />
- <script src="${pageContext.request.contextPath }/liger/lib/jquery/jquery-1.3.2.min.js" type="text/javascript"></script>
- <script src="${pageContext.request.contextPath }/liger/lib/ligerUI/js/core/base.js" type="text/javascript"></script>
- <script src="${pageContext.request.contextPath }/liger/lib/ligerUI/js/plugins/ligerDateEditor.js" type="text/javascript"></script>
- <script src="${pageContext.request.contextPath }/liger/lib/ligerUI/js/plugins/ligerGrid.js" type="text/javascript"></script>
- <link href="${pageContext.request.contextPath}/main.css" rel="stylesheet" type="text/css" />
- <script src="${pageContext.request.contextPath}/liger/lib/ligerUI/js/ligerui.all.js" type="text/javascript"></script>
- <script type="text/javascript" src="/shares/js/constant.js"></script>
- <script type="text/javascript" src="/shares/js/common.js"></script>
- <script type="text/javascript">
- var grid = null;
- $(document).ready(function() {
- $("#search_date_start").ligerDateEditor({
- labelWidth : 128,
- labelAlign : 'right',
- showTime : false
- });
- $("#search_date_end").ligerDateEditor({
- labelWidth : 128,
- labelAlign : 'right',
- showTime : false
- });
- searchByKword();
- });
- function loadReceiveList(params) {
- var columns = [
- {
- display : '车牌号',
- name : 'car_number',
- width : 120
- },
- {
- display : '物流单号',
- name : 'logist_num',
- width : 120,
- render : function(row) {
- var html = '<a href=\"#\" onclick=\"viewLogistEntry('
- + row.logistice_id
- + ')\"><font style="color:#0000FF">'
- + row.logist_num + '</font></a> ';
- return html;
- }
- }, {
- display : '调拨单号',
- name : 'tran_num',
- width : 120
- }, {
- display : '司机姓名',
- name : 'driver_name',
- width : 120
- }, {
- display : '收货时间',
- name : 'receive_date',
- width : 150
- }, {
- display : '操作人',
- name : 'create_user_name',
- width : 120
- }, {
- display : '操作时间',
- name : 'create_date',
- width : 150
- } ];
- if ("${requestScope.lookup }" == "") {
- columns.push({
- display : '操作',
- isAllowHide : false,
- width : 200,
- render : function(row) {
- var html = '<a href=\"#\" onclick=\"viewReceiveEntry('
- + row.universalid + ')\">查看</a> ';
- if ("${requestScope.loginId }" != null
- && "${requestScope.loginId }" != '') {
- /*html += '<a href=\"#\" onclick=\"editReceiveEntry('
- + row.universalid + ',' + row.logistice_id
- + ')\">编辑</a> ';*/
- html += '<a href=\"#\" onclick=\"delReceiveEntry('
- + row.universalid + ',' + row.logistice_id
- + ')\">删除</a> ';
- }
- return html;
- }
- });
- }
- grid = $("#receiveGrid")
- .ligerGrid(
- {
- columns : columns,
- pageSize : 20,
- url : 'erpEndProdReceiveAction.do?task=receiveList&lookup=${lookup}&loginId=${loginId}'
- + params + '&time=' + new Date().getTime(),
- pageParmName : 'p', //页索引参数名,(提交给服务器)
- pagesizeParmName : 'pSize', //页记录数参数名,(提交给服务器)
- width : '99.9%',
- height : '99%'
- });
- $("#pageloading").hide();
- }
- function viewLogistEntry(universalid) {
- addTab('viewLogist' + getCurrentTabId(), '查看物流指令',
- '${pageContext.request.contextPath }/erpLogistAction.do?task=view&universalid='
- + universalid + '&tabid=' + getCurrentTabId(), true,
- true);
- }
- function viewReceiveEntry(id) {
- window.parent
- .f_addTab(
- new Date().getTime(),
- '查看收货信息',
- '${pageContext.request.contextPath }/erpEndProdReceiveAction.do?task=viewReceiveEntry&id='
- + id + '&tabid=' + getCurrentTabId());
- }
- function editReceiveEntry(id, logist_id) {
- window.parent
- .f_addTab(
- new Date().getTime(),
- '编辑收货信息',
- '${pageContext.request.contextPath }/erpEndProdReceiveAction.do?task=toEditReceiveEntry&id='
- + id
- + '&logist_id='
- + logist_id
- + '&tabid='
- + getCurrentTabId());
- }
- function delReceiveEntry(id, logistice_id) {
- if (window.confirm("确定要删除吗?")) {
- /*var param = {
- 'id' : id,
- 'logistice_id' : logistice_id
- };
- sendAjaxParam(param,
- "erpEndProdReceiveAction.do?task=delReceiveEntry", 'json',
- delProcess);*/
-
- $.ajax({
- type:"POST", //请求方式
- url:"erpLogistAction.do?task=deleteLogistTacheRec&universalid="+id+"&logist_universalid="+logistice_id+"&type=3&time="+new Date().getTime(), //请求路径
- cache: false,
- dataType: 'json', //返回值类型
- success:function(json){
- if(json == '0'){
- addInfo("删除成功!");
- }else if(json == '-1'){
- addError("删除失败!");
- }else if(json == '1'){
- addError("该物流指令已在装货中,无法删除!");
- }else if(json == '2'){
- addError("该物流指令不在装货环节,无法删除!");
- }else if(json == '3'){
- addError("该物流指令不在出门环节,无法删除!");
- }else if(json == '4'){
- addError("该物流指令不在收货环节,无法删除!");
- }else if(json == '5'){
- addError("该物流指令还未完成,无法删除!");
- }
- searchByKword();
- }
- });
- }
- }
- function delProcess(data) {
- if (data.error != null) {
- $.ligerDialog.error(data.error);
- }
- if (data.success != null) {
- $.ligerDialog.success(data.success);
- }
- searchByKword();
- }
- function searchByKword() {
- if (grid != null) {
- grid.set("newPage", "1");
- }
- var params = "";
- var search_car_num = $("#search_car_num").val();
- params = params + "&search_car_num="
- + encodeURI(encodeURI(search_car_num));
- var search_logist_num = $("#search_logist_num").val();
- params = params + "&search_logist_num="
- + encodeURI(encodeURI(search_logist_num));
- var search_date_start = $("#search_date_start").val();
- params = params + "&search_date_start="
- + encodeURI(encodeURI(search_date_start));
- var search_date_end = $("#search_date_end").val();
- params = params + "&search_date_end="
- + encodeURI(encodeURI(search_date_end));
- loadReceiveList(params);
- }
- </script>
- </HEAD>
- <BODY>
- <%@ include file="/include/button.jsp"%>
- <%@ include file="/include/message.jsp"%>
- <div class="container">
- <c:if test="${requestScope.loginId != null && requestScope.loginId != '' }">
- <div id="title" class="form-button">
- <input style="width: 80px;" type="button" class="l-button" value="收货登记"
- onclick="window.parent.f_addTab(new Date().getTime(), '收货登记', '${pageContext.request.contextPath }/erpEndProdReceiveAction.do?task=toCreate&tabid=' + getCurrentTabId());" />
- </div>
- <div class="default_search" style="margin: 0; height: 30px;"></div>
- </c:if>
- <div class="default_search" style="margin: 0;">
- <ul class="list_search">
- <li class="title">车牌号:</li>
- <li class="text"><input type="text" name="search_car_num" id="search_car_num" value="" /></li>
- </ul>
- <ul class="list_search">
- <li class="title">物流单号:</li>
- <li class="text"><input type="text" name="search_logist_num" id="search_logist_num" value="" /></li>
- </ul>
- <!-- </div> -->
- <!-- <div class="default_search" style="margin: 0;"> -->
- <ul class="list_search">
- <li class="title">收货时间:</li>
- <li class="text"><input type="text" name="search_date_start" id="search_date_start" style="width: 130px;" />
- 至</li>
- <li class="text"><input type="text" name="search_date_end" id="search_date_end" style="width: 130px;" /></li>
-
- </ul>
-
- <ul>
- <li class="search-button"><input type="button" class='l-button' name="search" onclick="searchByKword()" value="查询" /></li>
- </ul>
- </div>
- <div style="overflow: hidden; clear: both;">
- <div id="receiveGrid" style="margin: 0; padding: 0"></div>
- </div>
- </div>
- </BODY>
- </HTML>
|