Beispiel #1
0
        public ActionResult KullanicilarJson(int page, int rows, string sort, string order)
        {
            var kullanicilar = kullaniciServis.Kullanicilar(page, rows);

            var result = new
            {
                total = kullanicilar.KayitSayisi,
                rows  = kullanicilar.KaynakListe.Select(x => new
                {
                    Id           = x.Id,
                    KullaniciAdi = x.KullaniciAdi,
                    Eposta       = x.Eposta,
                    Resim        = x.KucukProfilResim,
                    Roller       = String.Join(",", rolServis.KullaniciRolleri(x.Eposta))
                })
                        .AsQueryable()
                        .OrderBy(sort + " " + order)
            };

            return(Json(result, JsonRequestBehavior.AllowGet));
        }
Beispiel #2
0
 public override string[] GetRolesForUser(string username)
 {
     return(rolServis.KullaniciRolleri(username));
 }