You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

50 lines
2.2 KiB

2 months ago
  1. framework:
  2. workflows:
  3. task_lifecycle:
  4. type: state_machine
  5. audit_trail:
  6. enabled: true
  7. marking_store:
  8. type: 'method'
  9. property: 'status'
  10. supports:
  11. - App\Entity\Task
  12. initial_marking: !php/const App\Entity\Task::STATUS_TODO
  13. places:
  14. !php/const App\Entity\Task::STATUS_TODO:
  15. metadata:
  16. title: 'À faire'
  17. color: danger
  18. !php/const App\Entity\Task::STATUS_DOING:
  19. metadata:
  20. title: 'En cours'
  21. color: warning
  22. !php/const App\Entity\Task::STATUS_DONE:
  23. metadata:
  24. title: 'Terminé'
  25. color: success
  26. transitions:
  27. !php/const App\Entity\Task::TRANSITION_START:
  28. from: !php/const App\Entity\Task::STATUS_TODO
  29. to: !php/const App\Entity\Task::STATUS_DOING
  30. metadata:
  31. title: 'Commencer la tâche'
  32. route: 'app_task_start'
  33. !php/const App\Entity\Task::TRANSITION_FINISH:
  34. from: !php/const App\Entity\Task::STATUS_DOING
  35. to: !php/const App\Entity\Task::STATUS_DONE
  36. metadata:
  37. title: 'Terminer la tâche'
  38. route: 'app_task_finish'
  39. !php/const App\Entity\Task::TRANSITION_CANCEL:
  40. from: !php/const App\Entity\Task::STATUS_DOING
  41. to: !php/const App\Entity\Task::STATUS_TODO
  42. metadata:
  43. title: 'Abandonner la tâche'
  44. route: 'app_task_cancel'
  45. !php/const App\Entity\Task::TRANSITION_RESET:
  46. from: !php/const App\Entity\Task::STATUS_DONE
  47. to: !php/const App\Entity\Task::STATUS_TODO
  48. metadata:
  49. title: 'Recommencer la tâche'
  50. route: 'app_task_reset'