private void LoadRecord() { Common Common = new Common(); Int64 iID = Convert.ToInt64(Common.Decrypt(Request.QueryString["retid"], Session.SessionID)); POReturns clsPOReturns = new POReturns(); POReturnDetails clsDetails = clsPOReturns.Details(iID); clsPOReturns.CommitAndDispose(); lblDebitMemoID.Text = clsDetails.DebitMemoID.ToString(); lblReturnNo.Text = clsDetails.MemoNo; lblReturnDate.Text = clsDetails.MemoDate.ToString("yyyy-MM-dd HH:mm:ss"); lblRequiredReturnDate.Text = clsDetails.RequiredPostingDate.ToString("yyyy-MM-dd"); lblSupplierID.Text = clsDetails.SupplierID.ToString(); lblSupplierCode.Text = clsDetails.SupplierCode.ToString(); string stParam = "?task=" + Common.Encrypt("details", Session.SessionID) + "&id=" + Common.Encrypt(clsDetails.SupplierID.ToString(), Session.SessionID); lblSupplierCode.NavigateUrl = Constants.ROOT_DIRECTORY + "/PurchasesAndPayables/_Vendor/Default.aspx" + stParam; lblSupplierContact.Text = clsDetails.SupplierContact; lblSupplierTelephoneNo.Text = clsDetails.SupplierTelephoneNo; lblTerms.Text = clsDetails.SupplierTerms.ToString("##0"); switch (clsDetails.SupplierModeOfTerms) { case 0: lblModeOfterms.Text = "Days"; break; case 1: lblModeOfterms.Text = "Months"; break; case 2: lblModeOfterms.Text = "Years"; break; } lblSupplierAddress.Text = clsDetails.SupplierAddress; lblBranchID.Text = clsDetails.BranchID.ToString(); lblBranchCode.Text = clsDetails.BranchCode; lblBranchAddress.Text = clsDetails.BranchAddress; lblReturnRemarks.Text = clsDetails.Remarks; UpdateFooter(clsDetails); }
private void LoadRecord() { Common Common = new Common(); Int64 iID = Convert.ToInt64(Common.Decrypt(Request.QueryString["retid"], Session.SessionID)); POReturns clsPOReturns = new POReturns(); POReturnDetails clsDetails = clsPOReturns.Details(iID); clsPOReturns.CommitAndDispose(); lblDebitMemoID.Text = clsDetails.DebitMemoID.ToString(); lnkReturnNo.Text = clsDetails.MemoNo; lnkReturnNo.NavigateUrl = "Default.aspx?task=" + Common.Encrypt("details", Session.SessionID) + "&retid=" + Common.Encrypt(clsDetails.DebitMemoID.ToString(), Session.SessionID); lblReturnDate.Text = clsDetails.MemoDate.ToString("yyyy-MM-dd HH:mm:ss"); txtRequiredReturnDate.Text = clsDetails.RequiredPostingDate.ToString("yyyy-MM-dd"); cboSupplier.SelectedIndex = cboSupplier.Items.IndexOf(cboSupplier.Items.FindByValue(clsDetails.SupplierID.ToString())); txtSupplierContact.Text = clsDetails.SupplierContact; txtSupplierTelephoneNo.Text = clsDetails.SupplierTelephoneNo; lblTerms.Text = clsDetails.SupplierTerms.ToString("##0"); switch (clsDetails.SupplierModeOfTerms) { case 0: lblModeOfterms.Text = "Days"; break; case 1: lblModeOfterms.Text = "Months"; break; case 2: lblModeOfterms.Text = "Years"; break; } txtSupplierAddress.Text = clsDetails.SupplierAddress; cboBranch.SelectedIndex = cboBranch.Items.IndexOf(cboBranch.Items.FindByValue(clsDetails.BranchID.ToString())); txtBranchAddress.Text = clsDetails.BranchAddress; txtRemarks.Text = clsDetails.Remarks; }