public ActionResult GetGridJson(Pagination pagination, string itemId, string keyword)
        {
            var data = new
            {
                rows    = StreetApp.GetList(itemId, pagination, keyword),
                total   = pagination.total,
                page    = pagination.page,
                records = pagination.records
            };

            return(Content(data.ToJson()));
        }
Esempio n. 2
0
        public object GetProfileStreet()
        {
            ProfileStreetApp streetApp = new ProfileStreetApp();
            var data = streetApp.GetList();
            Dictionary <string, object> dictionary = new Dictionary <string, object>();

            foreach (ProfileStreetEntity item in data)
            {
                var fieldItem = new
                {
                    encode   = item.F_Id,
                    fullname = item.StreetName
                };
                dictionary.Add(item.F_Id, fieldItem);
            }
            return(dictionary);
        }