예제 #1
0
        public ActionResult GetUserStores([DataSourceRequest] DataSourceRequest request, int?userId)
        {
            var list = new WebStoreGridDTO[0];

            if (userId == null)
            {
                return(Json(list.ToDataSourceResult(request), JsonRequestBehavior.AllowGet));
            }

            list = _webStoreServices.GetOwnerStores((int)userId).OrderBy(x => x.AddOn).ThenBy(x => x.Name).ToArray();

            return(Json(list.ToDataSourceResult(request), JsonRequestBehavior.AllowGet));
        }
예제 #2
0
        public ActionResult GetUserStores([DataSourceRequest] DataSourceRequest request, int id)
        {
            var list = _webStoreServices.GetOwnerStores(id).OrderBy(x => x.AddOn).ThenBy(x => x.Name).ToArray();

            return(Json(list.ToDataSourceResult(request), JsonRequestBehavior.AllowGet));
        }
예제 #3
0
 private BaseListDTO[] GetAuthorSotresLOV()
 {
     return(_webStoreServices.GetOwnerStores(CurrentUserId).Select(x => new BaseListDTO {
         id = x.StoreId, name = x.Name
     }).Union(_webStoreServices.GetUserAffiliateStoresLOV(CurrentUserId)).ToArray());
 }