A beginner level smart contract assignment for a simple group to-do list.
Each ToDo will have:
- Assignee
only asignee can change the status of the task to done - Assigner
only the contract deployer (group leader) can assign task
assigner may reassign the task if it HAS NOT been completed by the current assignee - Task
the name of the task - Status
to indicate complete/incompleted, initially the status should be incompleted
Only addresses that are part of the group (the group leader/assigner and those who are assigned a task can view the ToDo List.
Challenge:
- Add deadline date to the ToDo property (Clue: Unix Timestamp)
- Assignee cannot change status to complete if the date has passed the deadline
- Assigner can refresh the ToDo list to check if there are unfinished tasks that has passed the deadline, if there is, the status should change to failed. (Clue: loop)
- Add task with assigner address - Success
- Add task with non assignes address - Failed
- Complete task with assignee address - Success
- Complete task with non-assignee address - Failed
- View task with member address - Success
- View task with non-member address - Failed
- Reassign incomplete task by assigner - Success
- Reassign completed task by assigner - Failed
- Reassign task by non-assigner - Failed
Challenge
- Refresh task by assigner (opt) - Success
- Refresh task by non-assigner (opt) - Failed
- Complete task with assignee address before deadline (opt) - Success
- Complete task with assignee address after deadline (opt) - Failed