Пример #1
0
        public void ModifyChains(ActionCallSet actions, BehaviorGraph graph)
        {
            // Attach the creation handlers
            actions.ForOutput(x => x.Closes(typeof(CreationRequest <>))).Each(addCreatorCall);

            // Attach the creation permissions
            actions.StartingWith("Create").Each(addCreationPermission);
            actions.StartingWith("New").Each(addCreationPermission);

            // Mark the New method as the 'new' url for that entity type
            modifyNewAction(actions);

            // Flesh out the behavior chains for "New" chains
            actions.StartingWith("New").Each(addNewEntityPipeline);

            // add the Find and EditProperty endpoints
            addEndpointsFor(_entityType, graph);

            // Attach more behaviors and security for the Edit endpoints
            modifyEditAction(actions.ByName("Edit"));
        }
Пример #2
0
        public void ModifyChains(ActionCallSet actions, BehaviorGraph graph)
        {
            // Attach the creation handlers
            actions.ForOutput(x => x.Closes(typeof(CreationRequest<>))).Each(addCreatorCall);

            // Attach the creation permissions
            actions.StartingWith("Create").Each(addCreationPermission);
            actions.StartingWith("New").Each(addCreationPermission);

            // Mark the New method as the 'new' url for that entity type
            modifyNewAction(actions);

            // Flesh out the behavior chains for "New" chains
            actions.StartingWith("New").Each(addNewEntityPipeline);

            // add the Find and EditProperty endpoints
            addEndpointsFor(_entityType, graph);

            // Attach more behaviors and security for the Edit endpoints
            modifyEditAction(actions.ByName("Edit"));
        }