public modCompatibleItemWindow(CatalogBike bc_) { InitializeComponent(); // initialise the windows bc = bc_; //display the kit data tb_BikeName.Text = bc.getName(); tb_title.Text = "Edit compatible kits with " + bc.getName() + "bike"; set_dg_selCompatibleKit_content(); }
public modItemWindow(CatalogBike kt_) { InitializeComponent(); //initialize the windows kt = kt_; //diplay the item data tb_newItemName.Text = kt.getName(); sl_pricemul.Value = kt.getPriceMul(); lb_pricemul.Content = "Price " + (sl_pricemul.Value / 100).ToString("P"); }
public static string updateCatalogBike(CatalogBike kt) { return("UPDATE `bv_catalog` SET `name` = '" + kt.getName() + "' , `PriceMul` = '" + kt.getPriceMul().ToString() + "' WHERE `id` = " + kt.getId().ToString()); }
public static string addCatalogBike(CatalogBike cb) { return("INSERT INTO `bv_catalog` (`id`,`name`,`PriceMul`,`picture`) VALUES (" + cb.getId().ToString() + ",'" + cb.getName() + "'," + cb.getPriceMul().ToString() + ", 'Bike0.jpg')"); }