Micro presentation of my new project – MigWork
A client submits a project – something they need done. They have already made a payment so their account has a positive balance.
A manager breaks it into a TO-DO list: each step called a task. If it’s a common project, the manager will pull up a template and copy each template_task into that project’s tasks.
The manager shows the tasks and estimated cost to the client for approval. The client’s balance needs to be enough to cover the project before we begin.
A worker, a person paid for their time, is alerted when there are unassigned tasks to do. They claim the task if they want, then have to start or finish the task soon, or else the task is unassigned and put back into the pool so that other workers can be alerted.
As the worker marks a task as finished, the total number of time spent on that task is multiplied by the worker’s rate to create a charge, which is subtracted from the client’s balance, and a worker_charge. These are separate because sometimes the client will be charged a flate rate for a task, and not billed by the second, but the worker still needs to get paid for their time.
When Migwork pays the worker, we log a worker_payment, and the corresponding worker_charges are updated with its worker_payment.id, to mark those worker_charges as paid.