/// <summary> /// Setting init when load page /// </summary> /// <param name="ID"></param> private void Initialize(int ID, int SubID) { // Init value var transportCompany = TransportCompanyController.GetAllReceivePlaceByID(ID, SubID); if (transportCompany != null) { this.hdfID.Value = transportCompany.ID.ToString(); this.hdfSubID.Value = transportCompany.SubID.ToString(); this.txtCompanyName.Text = transportCompany.CompanyName; this.txtCompanyPhone.Text = transportCompany.CompanyPhone; this.txtCompanyAddress.Text = transportCompany.CompanyAddress; this.txtShipTo.Text = transportCompany.ShipTo; this.txtAddress.Text = transportCompany.Address; this.rdbPrepay.SelectedValue = transportCompany.Prepay? "true" : "false"; this.rdbCOD.SelectedValue = transportCompany.COD ? "true" : "false"; this.pNote.Text = transportCompany.Note; } else { Response.Redirect("/danh-sach-nha-xe"); } // Setting display this.txtShipTo.Focus(); }