Ejemplo n.º 1
0
        public void getCompanyDetail()
        {
            try
            {
                string company_id = Request.QueryString["company_id"];
                if ((!string.IsNullOrEmpty(company_id.Trim())) && (!company_id.Trim().Equals("0")))
                {
                    var data = CompanyRepos.getCompany(int.Parse(company_id));
                    txt_comeFrom.Value     = data.comeFrom;
                    txt_company_name.Value = data.company_name;
                    txt_email.Value        = data.email;
                    txt_password.Value     = data.password;
                    txt_phoneNumber.Value  = data.phoneNumber;

                    img_ceoID_link.HRef = "./upload/" + data.ceoID_path;
                    img_ceoID_path.Src  = "./upload/" + data.ceoID_path;
                    img_companyCertificate_link.HRef = "./upload/" + data.companyCertificate_path;
                    img_companyCertificate_path.Src  = "./upload/" + data.companyCertificate_path;
                    img_permissions_link.HRef        = "./upload/" + data.permissions_path;
                    img_permissions_path.Src         = "./upload/" + data.permissions_path;


                    if (data.isConfirmed == true)
                    {
                        companyConfirm.Checked    = true;
                        companyNotConfirm.Checked = false;
                    }
                    else if (data.isConfirmed == false)
                    {
                        companyConfirm.Checked    = false;
                        companyNotConfirm.Checked = true;
                    }
                }
                else
                {
                    Response.Redirect("Companies.aspx");
                }
            }
            catch (Exception)
            {
                Response.Redirect("Companies.aspx");
            }
        }