Description of Task state transitions. git-svn-id: http://soc.googlecode.com/svn/wiki@3230 5fae56a1-394a-0410-ba46-5107137fd53f
diff --git a/GHOPImplementationDesign.wiki b/GHOPImplementationDesign.wiki index 251cd7e..1d4b39a 100644 --- a/GHOPImplementationDesign.wiki +++ b/GHOPImplementationDesign.wiki
@@ -143,7 +143,7 @@ ** Unpublished: This task is not published yet, ** Open: This task has not yet been claimed, ** Reopened: This task has been claimed but never finished and has been reopened, - ** Claimrequested: This task has been requested to be claimed by a student, + ** ClaimRequested: This task has been requested to be claimed by a student, ** Claimed: This task has been claimed and someone is working on it, ** ActionNeeded: Work on this task must be submitted for review within 24 hours, ** Closed: Work on this task has been successfully completed. @@ -244,6 +244,24 @@ = Task States = +== Description of how state transitions == +_Describes how the *state* property in the Task model works._ + +Note all the state transitions are hidden state transitions. The state property won't appear in the user interface. + * When a mentor creates a task, the state is initialized to *Unapproved*. If the task is created by an Org Admin it is automatically initialized to *Unpublished* state. The was`_`reopened property will be set to *False* by default. + * The Mentor/Org Admin can bulk choose tasks for publishing.(will be given list of tasks in Unpublished state with check boxes. Can check the tasks and click on Publish button). The tasks state changes to *Open*. + * A student requests to claim a task the system checks if the student has already completed one task successfully. If yes, it checks if he has completed his student registration procedure. If not it forces him to sign up and returns back to this page. If he has already signed up the state changes to *ClaimRequested*. + * Org Admin/Mentor can either accept the request in which case the task state is set to *Claimed* or reject the request in which case state is changed to back to *Open* since the was`_`reopened property is *False*. If was`_`reopened is *True* the state changes back to *Reopened*. + * If a student withdraws the claim request before it was assigned to him the state changes to either *Open* or *Reopened* depending on the value of was`_`reopened. + * If the student withdraws from the task after it was assigned to him the state is changed to *Reopened* irrespective of the value of was`_`reopened and was`_`reopened is set to *True* + * The student can submit his work and check the _Request to review the work_ option in which case the task state changes to *NeedsReview*. + * Now the Mentor is given a Drop Down with options to + # Fail the student, in which case the state changes to *Reopened* + # Pass the student, in which case the state changes to *AwaitingRegistration* if this is first task the student has completed successfully. Otherwise state changes to *Closed*. + # Work is not sufficient/satisfactory, in which case a text box appears to allow Mentor to set the extended deadline in hours and upon that changes the state to *NeedsWork*. + * If the deadline is passed and the student doesn't submit any work the state automatically changes to *Reopened*. + * If the task deadline is close by and student doesn't submit his work yet, if the Mentor finds the need to extend his deadline, he can click the button *ActionNeeded* and the state changes to *ActionNeeded*, in which case the deadline is extended by 24 hours. + == Visualizing the states of a Task == http://img230.imageshack.us/img230/1641/taskstatemachine.png http://img15.imageshack.us/img15/5099/taskclaimstatemachine.png