Beispiel #1
0
        public int FirmaYildiziGuncelle(int firmaid, out int siparissayisi)
        {
            MyContext      db = new MyContext();
            List <Siparis> Firmaninsiparisleri = new SiparisRepo().GetAll().Where(x => x.FirmaID == firmaid).ToList();
            int            yildiz = Firmaninsiparisleri.Sum(x => x.Yildiz.Value);

            siparissayisi = Firmaninsiparisleri.Count(x => x.Yildiz > 0);
            return(yildiz);
        }
Beispiel #2
0
        public Siparis SiparisiGetir(int siparisid)
        {
            Siparis siparis = new SiparisRepo().GetAll().FirstOrDefault(x => x.ID == siparisid);

            return(siparis);
        }