Пример #1
0
        public ActionResult Index()
        {
            DM_VAITROBusiness = Get <DM_VAITROBusiness>();
            var searchmodel = new DM_VAITRO_SEARCHBO();

            SessionManager.SetValue("dmvaitroSearchModel", null);
            var data = DM_VAITROBusiness.GetDaTaByPage(null);

            return(View(data));
        }
Пример #2
0
        public JsonResult searchData(FormCollection form)
        {
            DM_VAITROBusiness = Get <DM_VAITROBusiness>();
            var searchModel = SessionManager.GetValue("dmvaitroSearchModel") as DM_VAITRO_SEARCHBO;

            if (searchModel == null)
            {
                searchModel          = new DM_VAITRO_SEARCHBO();
                searchModel.pageSize = 20;
            }

            searchModel.QR_MA     = form["QR_MA"];
            searchModel.QR_VAITRO = form["QR_VAITRO"];
            SessionManager.SetValue("dmvaitroSearchModel", searchModel);

            var data = DM_VAITROBusiness.GetDaTaByPage(searchModel, 1, searchModel.pageSize);

            return(Json(data));
        }
Пример #3
0
        public JsonResult getData(int indexPage, string sortQuery, int pageSize)
        {
            DM_VAITROBusiness = Get <DM_VAITROBusiness>();
            var searchModel = SessionManager.GetValue("dmvaitroSearchModel") as DM_VAITRO_SEARCHBO;

            if (!string.IsNullOrEmpty(sortQuery))
            {
                if (searchModel == null)
                {
                    searchModel = new DM_VAITRO_SEARCHBO();
                }
                searchModel.sortQuery = sortQuery;
                if (pageSize > 0)
                {
                    searchModel.pageSize = pageSize;
                }
                SessionManager.SetValue("dmvaitroSearchModel", searchModel);
            }
            var data = DM_VAITROBusiness.GetDaTaByPage(searchModel, indexPage, pageSize);

            return(Json(data));
        }