<?xml version="1.0"?>
<cps-workflow workflow_id="waeup_base_wf"
              title="CPS Workflow Definition"
              state_variable="review_state"
              meta_type="CPS Workflow">
 <permission>View</permission>
 <state state_id="checked" title="Checked">
  <exit-transition transition_id="create_content"/>
  <exit-transition transition_id="cut_copy_paste"/>
  <exit-transition transition_id="retract"/>
  <permission-map name="View" acquired="True">
   <permission-role>SectionOfficer</permission-role>
  </permission-map>
 </state>
 <state state_id="unchecked" title="Unchecked">
  <exit-transition transition_id="approve"/>
  <exit-transition transition_id="create_content"/>
  <exit-transition transition_id="cut_copy_paste"/>
  <permission-map name="View" acquired="True">
   <permission-role>SectionOfficer</permission-role>
  </permission-map>
 </state>
 <transition transition_id="approve" title="Approve"
             new_state="checked" trigger="USER"
             before_script="" after_script="">
  <action url="%(content_url)s/content_status_modify?workflow_action=approve"
          category="workflow">Approve</action>
  <guard>
   <guard-role>Manager</guard-role>
   <guard-role>SectionManager</guard-role>
   <guard-role>SectionOfficer</guard-role>
  </guard>
 </transition>
 <transition transition_id="create" title="Initial creation"
             new_state="unchecked" trigger="USER"
             before_script="" after_script="">

  <guard>
   <guard-role>Manager</guard-role>
   <guard-role>SectionManager</guard-role>
   <guard-role>SectionOfficer</guard-role>
  </guard>
  <transition-behavior behavior_id="initial-create"/>
 </transition>
 <transition transition_id="create_content"
             title="Create content" new_state=""
             trigger="USER" before_script="" after_script="">

  <guard>
   <guard-role>Manager</guard-role>
   <guard-role>SectionManager</guard-role>
   <guard-role>SectionOfficer</guard-role>
  </guard>
  <transition-behavior behavior_id="allow-sub-create"/>
  <transition-behavior behavior_id="allow-sub-publishing"/>
 </transition>
 <transition transition_id="cut_copy_paste"
             title="Cut/Copy/Paste" new_state=""
             trigger="USER" before_script="" after_script="">

  <guard>
   <guard-role>Manager</guard-role>
   <guard-role>SectionManager</guard-role>
   <guard-role>SectionOfficer</guard-role>
  </guard>
  <transition-behavior behavior_id="allow-sub-move"/>
  <transition-behavior behavior_id="allow-sub-delete"/>
  <transition-behavior behavior_id="allow-sub-copy"/>
 </transition>
 <transition transition_id="retract" title="Retract"
             new_state="unchecked" trigger="USER"
             before_script="" after_script="">
  <action url="%(content_url)s/content_status_modify?workflow_action=retract"
          category="workflow">Retract</action>
  <guard>
   <guard-role>Manager</guard-role>
  </guard>
 </transition>
</cps-workflow>