Exemplo n.º 1
0
 public Vehicle()
 {
     Specification  = new VehicleSpecification();
     Seller         = new VehicleSeller();
     ComplianceDate = new SimpleDate();
     BuildDate      = new SimpleDate();
     Warranty       = new VehicleWarranty();
     Identification = new List <TypeValue>();
     Registration   = new VehicleRegistration();
 }
Exemplo n.º 2
0
        public VehicleSpecification GetWebdata()
        {
            Model           modal            = new Model();
            decodersettings decoder_settings = new decodersettings();

            commondatapacks common_data_packs = new commondatapacks();

            styledatapacks style_data_packs = new styledatapacks();

            queryrequest query_requests = new queryrequest();

            requestsample Request_Sample = new requestsample();

            Request_Sample.vin  = vinApprisal_txb.Value.ToString();
            Request_Sample.year = "";

            query_requests.Request_Sample = Request_Sample;

            common_data_packs.basic_data   = "on";
            common_data_packs.single_stock = "on";

            style_data_packs.basic_data    = "on";
            style_data_packs.engines       = "on";
            style_data_packs.transmissions = "on";
            style_data_packs.single_stock  = "on";

            decoder_settings.common_data_packs = common_data_packs;
            decoder_settings.style_data_packs  = style_data_packs;
            decoder_settings.display           = "full";
            decoder_settings.version           = "7.0.1";
            decoder_settings.styles            = "on";
            decoder_settings.common_data       = "on";

            modal.decoder_settings = decoder_settings;
            modal.query_requests   = query_requests;


            string jsondata = JsonConvert.SerializeObject(modal);
            //CallLink();
            VehicleSpecification spec = new VehicleSpecification();

            spec.VIN = vinApprisal_txb.Value.ToString();
            WebServiceRepository wr = new WebServiceRepository();

            spec = wr.CallLink(jsondata);
            return(spec);
        }
Exemplo n.º 3
0
        protected void VehiclApprislForm_nextbtn_Click(object sender, ImageClickEventArgs e)
        {
            VehicleSpecification spec1 = GetWebdata();

            if (spec1.isValid)
            {
                Session["vin_data"] = spec1;
                Response.Redirect("Caroffers.aspx");
            }
            else
            {
                Response.Write(spec1.ErrorMessage);
            }

            // string vin = vinApprisal_txb.Value.ToString();
            // Session["vin"] = vin;
            // Response.Redirect("caroffers.aspx");
        }
Exemplo n.º 4
0
        protected void imgbtn_Click(object sender, ImageClickEventArgs e)
        {
            VehicleSpecification spec1 = GetWebdata();

            if (spec1.isValid)
            {
                Session["vin_data"] = spec1;
                Response.Redirect("Caroffers.aspx");
            }
            else
            {
                // Response.Write(spec1.ErrorMessage);
                Page.RegisterStartupScript("popalert", "<script type='text/javascript'> alert('" + spec1.ErrorMessage + "');</script>");
            }
            //string vin = vintxt.Value;
            // Session["vin_Number"] = vin;
            // Response.Redirect("Caroffers.aspx");
            // Server.Transfer("Caroffers.aspx");
        }