예제 #1
0
        public object Get(FB_Projects request)
        {
            ApiUser         hdUser         = request.ApiUser;
            Instance_Config instanceConfig = new Models.Instance_Config(hdUser);

            int clientID = 0;

            if (!int.TryParse(request.client, out clientID))
            {
                throw new HttpError(HttpStatusCode.NotFound, "incorrect client id");
            }
            int staffID = 0;

            if (!int.TryParse(request.staff, out staffID))
            {
                throw new HttpError(HttpStatusCode.NotFound, "incorrect staff id");
            }

            return(FBProjects.GetFBProjects(instanceConfig, request.page, request.limit, clientID, staffID));
        }
예제 #2
0
        public object Get(FB_Projects request)
        {
            ApiUser hdUser = request.ApiUser;
            Instance_Config instanceConfig = new Models.Instance_Config(hdUser);

            int clientID = 0;
            if (!int.TryParse(request.client, out clientID))
            {
                throw new HttpError(HttpStatusCode.NotFound, "incorrect client id");
            }
            int staffID = 0;
            if (!int.TryParse(request.staff, out staffID))
            {
                throw new HttpError(HttpStatusCode.NotFound, "incorrect staff id");
            }

            return FBProjects.GetFBProjects(instanceConfig, request.page, request.limit, clientID, staffID);
        }