using System; using System.Collections; using System.Configuration; using System.Data; using System.Linq; using System.Web; using System.Web.Security; using System.Web.UI; using System.Web.UI.HtmlControls; using System.Web.UI.WebControls; using System.Web.UI.WebControls.WebParts; using System.Xml.Linq; using System.Text; using System.Data.SqlClient; using System.Collections.Generic; using System.Xml; using DSWeb.Models; using DSWeb.EntityDA; namespace DSWeb.FeeCodes { public partial class CLOSINGDATEAdapter : System.Web.UI.Page { private string hdBSNO = ""; private string strPortName = ""; protected void Page_Load(object sender, EventArgs e) { if (Request.QueryString["hdBSNO"] != null) { hdBSNO = Request.QueryString["hdBSNO"].ToString(); } if (hdBSNO != "") { TopSeaeEntity TopSeaeEntity = new TopSeaeEntity(); SeaExportInfoDA SeaExportInfoDA = new SeaExportInfoDA(); TopSeaeEntity = SeaExportInfoDA.GetID(hdBSNO.ToString().Trim()); if (TopSeaeEntity.BSNO != null) { //截港日期==截港日期 if (TopSeaeEntity.CLOSINGDATE.ToString().Trim().IndexOf("0001")>-1 || TopSeaeEntity.CLOSINGDATE.ToString().Trim().Equals("")) { strPortName = ""; } else { strPortName = DateTime.Parse(TopSeaeEntity.CLOSINGDATE.ToString().Trim()).ToString("yyyy-MM-dd hh:mm").Trim(); } Response.Write(strPortName); return; } } } } }