private void dajCenuIzJsona(CeneSastojaka cs) { jaja = cs.jaja.Min(); majonez = cs.majonez.Min(); origano = cs.origano.Min(); tuna = cs.tuna.Min(); sunka = cs.sunka.Min(); sir = cs.sir.Min(); }
private void dajJson() { string line; using (StreamReader sr = new StreamReader(@"C:\Users\uros4\OneDrive\Desktop\PizzaApp\RadnickiDeo\sastojci\NapraviSamSastojci.json")) { line = sr.ReadToEnd(); } var sastojci = JsonConvert.DeserializeObject <CeneSastojaka>(line); cs = sastojci; }