You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

375 lines
17 KiB
Plaintext

<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="SeanInTradeList.aspx.cs" Inherits="DSWeb.SeanInfo.SeanInTradeList" %>
<%@ Register Assembly="AspNetPager" Namespace="Wuqi.Webdiyer" TagPrefix="webdiyer" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title></title>
<link href="../theme/buttons.css" rel="stylesheet" type="text/css" />
<link rel="STYLESHEET" type="text/css" href="../theme/button/default/Fee.css"/>
<script src="../js/jquery/js/jquery.js" type="text/javascript"></script>
<script src="../js/m97date/WdatePicker.js" type="text/javascript"></script>
<script type="text/javascript">
//双击打开表示编辑信息
function InfoControl(idd) {
window.open('SeanEdit.aspx?handle=edit&id=' + idd, '', 'height=700, width=1200, top=10,left=10, toolbar=no, menubar=no, scrollbars=no, resizable=yes,location=no, status=no');
}
//添加新项
function addnnewinfo() {
window.open('SeanEdit.aspx?handle=add', '', 'height=700, width=1200, top=10,left=10, toolbar=no, menubar=no, scrollbars=no, resizable=yes,location=no, status=no')
}
//删除选择项目
function deleinfo() {
var checkvalue = "";
$("[name=checkdele]:checkbox:checked").each(function () {
if ($.trim($(this).val()).length > 0) {
checkvalue += "," + $.trim($(this).val());
}
});
if (checkvalue.length<40) {
alert("您还没有选择删除项!");
return false;
}
else {
if (confirm("确认删除?")) {
$("#<%=hid_saveallinfo.ClientID %>").val(checkvalue.substr(1));
return true;
}
else {
return false;
}
}
}
//复制添加新项
function CopeyAddNew() {
var checkvalue = "";
$("[name=checkdele]:checkbox:checked").each(function () {
if ($.trim($(this).val()).length > 0) {
checkvalue += "," + $.trim($(this).val());
}
});
if (checkvalue.length>60 ) {
alert("您只能选择一个进行复制添加委托!");
return false;
}
if (checkvalue.length < 40) {
alert("请选择一个项复制委托!");
}
else {
window.open('SeanEdit.aspx?handle=addfull&id=' + checkvalue.substr(1), '', 'height=700, width=1200, top=10,left=100, toolbar=no, menubar=no, scrollbars=no, resizable=yes,location=no, status=no')
return true;
}
}
//checkbox的全选与取消
function checkall(event) {
var intboxname = document.getElementsByName("checkdele");
if (event.checked) {
$.each(intboxname, function (i, n) {
n.checked = true;
})
}
else {
$.each(intboxname, function (i, n) {
n.checked = false;
})
}
}
//选择每一行 的checkbox变色
function changecolor(even) {
var idd = even.value;
if (even.checked) {
$("#" + idd).removeClass();
$("#"+idd).addClass("chekBox");
}
else {
$("#" + idd).removeClass("chekBox");
}
}
$(document).ready(function () {
$(".stripe tr").mouseover(function () {
$(this).addClass("over");
}).mouseout(function () {
$(this).removeClass("over");
})
$(".stripe tr:even").addClass("alt");
});
function getNewPage() {
//window.location.reload();
window.location.href = window.location.href;
}
//打印清单
function PintSeanAndCtn() {
var checkvalue = "";
var bsnos = "";
$("[name=checkdele]:checkbox:checked").each(function () {
if ($.trim($(this).val()).length > 0) {
checkvalue += "," + $.trim($(this).val());
}
});
if (checkvalue.length == 0) {
if (confirm("您是否要全部打印?")) {
printInfo("","printALL");
}
}
else {
if (confirm("您是否打印选择项?")) {
bsnos = checkvalue.substr(1);
printInfo(bsnos,"printPart");
return true;
}
else {
return false;
}
}
}
function printInfo(strGid,handle) {
var printUrl = "";
var companyID = "";
var typeName = "PrintSeanAndCtnList";
var dbSourceID = "";
var userID = "";
$.ajax({
type: "post",
url: "SeanAjax.aspx",
data: "type=PrintSeanAndCtnLists&handle=" + handle + "&BSNOS=" + strGid,
dataType: "json",
beforeSend: function (XMLHttpRequest) { },
success: function (msg) {
var results = msg.result;
companyID = results[0].compid;
dbSourceID = results[0].sourceid;
userID = results[0].userid;
printUrl = "print://?comp=" + companyID + "&type=" + typeName + "&dbid=" + dbSourceID + "&uid=" + userID;
window.location.href = window.location.href;
location.href = printUrl;
},
error: function () { alert("error2"); }
});
}
function setExcel() {
if (window.confirm("是否导出Excel")) {
return true;
}
else {
return false;
}
}
</script>
<style type="text/css">
.stripe .chekBox td
{
background-color:#FFA07A;
}
.stripe .tr_header td
{
background:#99BBFF;
}
tr.alt td {
background:#F5F5F5 ; /*这行将给所有的 tr 加上背景色*/
}
tr.over td {
background:#99BBFF; /*这个将是鼠标高亮行的背景色*/
}
tr.addcolor td
{
background:#ecf6fc;
}
.divsearchtop
{
width:100%;
height:20px;
background:url("../images/content-header.gif");
cursor:default;
vertical-align:middle;
}
.divtopmenu
{
width:100%;
height:30px;
background:url("../images/content-header.gif");
cursor:default;
vertical-align:bottom;
}
.drop
{
width:115px;
font-size:11px;
}
img
{
cursor:pointer;
}
.txt
{
width:110px;
}
.table_control .table_Tr td:hover
{
background-color:#33CCFF;
border-left:1px solid #A0522D;
border-right:1px solid #A0522D;
}
</style>
</head>
<body style=" background-color:#ECF2FF; height:100%;">
<form id="form1" runat="server">
<div>
<table border="0" cellpadding="0" cellspacing="0">
<tr>
<td>
<table border="0" width="100%">
<tr>
<td>
<div id="div_top_search" class="divsearchtop" >
<span style=" font-size:large; font-family:宋体; font-weight:bold; text-align:left;">
查询区域
</span>
</div>
</td>
</tr>
<tr>
<td>
<table border="0" style=" width:auto;font-size:12px;">
<tr>
<td colspan="5">运单号/委托单位/箱号/发货人/收货人/揽货人/装货地址/送货地址/封号/船公司/船名/航次/品名/装货港/卸货港:</td>
<td><asp:TextBox ID="txt_allsearch" runat="server" CssClass="txt" ></asp:TextBox></td>
<td></td>
</tr>
<tr style=" height:30px; ">
<td>启港时期:</td><td><input type="text" id="txt_endTime" class="txt" runat="server" onclick="WdatePicker();" /></td>
<td>入港时期:</td><td><input type="text" id="txt_enaTime" class="txt" runat="server" onclick="WdatePicker();" /></td>
<td>会计期间:</td><td><asp:TextBox runat="server" ID="txt_accdate" CssClass="txt" ToolTip="例:2011-04" onclick="WdatePicker({ dateFmt: 'yyyy-MM', isShowToday: false, isShowClear: false })"></asp:TextBox></td>
<td></td>
<td ><div class="buttons" style=" vertical-align:bottom;"><a href="javascript:void(0);" class="regular">
<asp:ImageButton runat="server" ID="img_search"
ImageUrl="~/images/icons/btnSearch.gif" onclick="img_search_Click" /></a></div></td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td>
<div id="div_top_menu" class="divtopmenu">
<div class="btn-blank"></div>
<div class="xbtn-img"><div class="btnimg"><img src="../images/icons/new.gif" width="16px" height="16px" title="添加委托" onclick="return addnnewinfo()" class="cssfont"/></div></div>
<div class="xbtn-img"><div class="btnimg"><img src="../images/cmd-copy.gif" width="16px" height="16px" title="复制添加委托" onclick="return CopeyAddNew();" class="cssfont"/></div></div>
<div class="xbtn-img"><div class="btnimg"><asp:ImageButton runat="server" ID="img_DeleteInfo" ToolTip="多项删除"
ImageUrl="../images/icons/delete.gif" OnClientClick="return deleinfo();"
onclick="img_DeleteInfo_Click" style="width: 16px; cursor:pointer;" /></div></div>
<div class="xbtn-img"><div class="btnimg"><img src="../images/icons/refresh.gif" width="16px" title="刷新列表" onclick="getNewPage()" class="cssfont"/></div></div>
<div class="xbtn-img"><div class="btnimg"><asp:ImageButton ID="img_btnexcel"
runat="server" ImageUrl="../images/icons/excel.gif" Width="16" Height="16"
ToolTip="导出EXCEL" CssClass="cssfont" OnClientClick="return setExcel()" onclick="img_btnexcel_Click" /></div></div>
<div class="xbtn-img"><div class="btnimg"><img id="img_print" alt="加载失败" title="打印" width="16px" height="16" src="../images/icons/print.gif" onclick="return PintSeanAndCtn();" /></div></div>
</div>
</td>
</tr>
<tr>
<td>
<div style="height:400px; width:2000px;overflow-x:scroll;margin-top:5px;word-break: keep-all;white-space:nowrap;text-align:center;">
<asp:Repeater runat="server" ID="repeaterMess">
<HeaderTemplate>
<table class="stripe" cellpadding="1" cellspacing="1">
<thead class="tr_header" style="font-size:15px; font-weight:bold; height:40px;">
<tr>
<td><input type="checkbox" id="checall" onclick="checkall(this)" /></td>
<td>运单号</td>
<td>委托单位</td>
<td>发货人</td>
<td>收货人</td>
<td>船名</td>
<td>航次</td>
<td>船公司</td>
<td>开船日期</td>
<td>到港日期</td>
<td>装货港</td>
<td>卸货港</td>
<td>品名</td>
<td>毛重</td>
<td>毛重单位</td>
<td>尺码</td>
<td>尺码单位</td>
<td>委托方式</td>
<td>业务状态</td>
<td>费用状态</td>
<td>会计期间</td>
<td>操作员</td>
<td>揽货人</td>
<td>录入人</td>
<td>录入时间</td>
<td>修改人</td>
<td>修改时间</td>
<td>装货地址</td>
<td>送货地址</td>
</tr>
</thead>
</HeaderTemplate>
<ItemTemplate>
<tr id='<%#Eval("BSNO") %>' style=" cursor:pointer; font-size:small; height:20px;" ondblclick="InfoControl(this.id);">
<td><input type="checkbox" id="check_content" onclick="changecolor(this);" name="checkdele" value='<%#Eval("BSNO") %>' /></td>
<td><%#Eval("MBLNO")%></td>
<td><%#Eval("CUSTOMERNAME")%></td>
<td><%#Eval("SHIPPER")%></td>
<td><%#Eval("CONSIGNEE")%></td>
<td><%#Eval("VESSEL")%></td>
<td><%#Eval("VOYNO")%></td>
<td><%#Eval("CARRIER")%></td>
<td><%#ShowDateTime(Eval("ETD"))%></td>
<td><%#ShowDateTime(Eval("ETA"))%></td>
<td><%#Eval("PORTLOAD")%></td>
<td><%#Eval("PORTDISCHARGE")%></td>
<td><%#Eval("GOODSNAME")%></td>
<td><%#Eval("GROSSWEIGHT")%></td>
<td><%#Eval("GROSSWEIGHTUNIT")%></td>
<td><%#Eval("MEASUREMENT")%></td>
<td><%#Eval("MEASUREMENTUNIT")%></td>
<td><%#Eval("ORDERTYPE")%></td>
<td><%#changeShow(Eval("BSSTATUS"))%></td>
<td><%#changeShow(Eval("FEESTATUS"))%></td>
<td><%#Eval("ACCDATE")%></td>
<td><%#Eval("OP")%></td>
<td><%#Eval("SALE")%></td>
<td><%#Eval("INPUTBY")%></td>
<td><%#Eval("INPUTTIME")%></td>
<td><%#Eval("UPDATEPPER") %></td>
<td><%#Eval("UPDATETIME")%></td>
<td><%#Eval("LOADADDRESS")%></td>
<td><%#Eval("DELIVERADDRESS")%></td>
</tr>
</ItemTemplate>
<FooterTemplate>
</table>
</FooterTemplate>
</asp:Repeater>
<input type="hidden" id="hid_saveallinfo" runat="server" />
<input type="hidden" id="hid_singlevalue" runat="server" />
</div>
<br />
<div>
<webdiyer:aspnetpager id="AspNetPager1" runat="server" horizontalalign="left" onpagechanged="AspNetPager1_PageChanged"
showcustominfosection="Left" width="100%" meta:resourceKey="AspNetPager1" style="font-size:14px" PageIndexBoxStyle="width:18px;border-top:1px solid #A3B2CC;border-left:1px solid #A3B2CC;border-right:1px solid #A3B2CC;border-bottom:1px solid #A3B2CC;height:17px;"
CustomInfoHTML=" 当前页<font color='red'><b>%CurrentPageIndex%</b></font>共%PageCount%页,记录%StartRecordIndex%-%EndRecordIndex%"
ShowNavigationToolTip="True" CustomInfoStylae="font-size:14px;padding-top:6px;width:300px;" TextAfterPageIndexBox=" " SubmitButtonText=" 转" SubmitButtonStyle="width:41px;height:21px;border: none;cursor:hand;background-image: url(/images/go.gif)" CustomInfoTextAlign="left" ShowPageIndexBox="Always" AlwaysShow="True"
FirstPageText="【首页】" LastPageText="【尾页】" NextPageText="【下页】" PageSize="15" PrevPageText="【前页】">
</webdiyer:aspnetpager>
</div>
</td>
</tr>
</table>
</div>
</form>
</body>
</html>