Exemplo n.º 1
0
        public object Delete(WorkflowCommentJunction request)
        {
            switch (request.Junction.ToLower().TrimAndPruneSpaces())
            {
            case "workflowcomment":
                return(RemoveJunction <WorkflowComment, DocEntityWorkflowComment, DocEntityWorkflowComment, WorkflowComment, WorkflowCommentSearch>((int)request.Id, DocConstantModelName.WORKFLOWCOMMENT, "Children", request));

            default:
                throw new HttpError(HttpStatusCode.NotFound, $"Route for workflowcomment/{request.Id}/{request.Junction} was not found");
            }
        }
Exemplo n.º 2
0
        public object Get(WorkflowCommentJunction request)
        {
            switch (request.Junction.ToLower().TrimAndPruneSpaces())
            {
            case "workflowcomment":
                return(GetJunctionSearchResult <WorkflowComment, DocEntityWorkflowComment, DocEntityWorkflowComment, WorkflowComment, WorkflowCommentSearch>((int)request.Id, DocConstantModelName.WORKFLOWCOMMENT, "Children", request, (ss) => HostContext.ResolveService <WorkflowCommentService>(Request)?.Get(ss)));

            default:
                throw new HttpError(HttpStatusCode.NotFound, $"Route for workflowcomment/{request.Id}/{request.Junction} was not found");
            }
        }