Tasks
Tasks
Tasks are tenant-scoped work items that can be created directly from a Task widget card or from the tasks index.
Add tasks from TaskButtons
- Click
+to open the task dialog and fill task attributes. - Click
▶to start a task immediately with default titlenew task.
Task stats in TaskStats
- Shows open task count.
- Shows total time spent this month as hours and minutes.
Tasks list
- Open the tasks page using the widget title link.
- Use search to filter tasks by title.
- Drag and drop tasks to reorder or nest under another task.
- The list lazy-loads additional tasks as you scroll.
Task entries
- Open Task entries to log time passes.
- Each entry belongs to a task and includes
started_at, optionalstopped_at, andminutes_spent.
Billable autofill on client select
- In task create/edit, when a Client is selected, billable defaults are fetched automatically.
- The server resolves
product_idviaProductResolverand pricing viaPricingEngine. - Returned defaults are applied to billable fields (
product,price list,unit,unit price).
Example response from GET /:tenant_slug/tasks/billable_defaults?client_id=...&task_id=...:
{
"product_id": 12,
"price_list_id": 5,
"pricelist_id": 5,
"unit": "hour",
"unit_price": "250.0",
"currency": "DKK"
}
From Tasks to Invoices
Create a billable task. The task is created with a client/contact, billable flag, billing unit, and usually a product/price context. The end-to-end flow is exercised in invoices_flow_test.rb.
Add time entries to the task. Work is recorded as task entries with start/stop timestamps. Those entries become the raw source for billing later. The tested flow is also in invoices_flow_test.rb.
Compile task work into billable items. The app runs the billable-items compiler, which turns eligible task work into tenant billable items. The controller entrypoint is billable_items_controller.rb.
Review billable items. Compiled billable items are the staging layer between task work and invoicing. They can be listed before invoice generation. The listing entrypoint is billable_items_controller.rb.
Generate invoices from selected billable items. Invoice generation is requested from selected billable item ids plus a grouping mode. That creates an invoice operation and queues background processing. The controller entrypoint is invoices_controller.rb.
Background job builds the invoice records. The queued invoice operation runs the invoice generator and creates the invoice plus invoice items. That work is handled in invoice_operation_job.rb.
Open and review the generated invoice. Once generation completes, the invoice appears in the invoices index and can be opened on its show page for review and editing. The tested browse flow is in invoices_flow_test.rb, and the main controller is invoices_controller.rb.
Update invoice details if needed. Draft invoices can be updated for status, due date, payment term, and payment method before final downstream actions. That update flow is in invoices_controller.rb.
Sync the invoice to Dinero. A manual sync can be triggered from the invoice list item. Sync is only queued when the invoice has line items. The route/controller flow is in invoices_controller.rb, and the row UI is in list_item.rb.
Watch sync status on the invoice row or show page. The invoice row/show badge reflects the latest integration sync log, including async completion updates. The lookup is in sync_status_lookup.rb, and the async rerender path is in sync_resource_job.rb.
Download/export the invoice. A single invoice can be downloaded directly, and collections can be exported through a queued invoice operation. Those flows are in invoices_controller.rb and invoice_operation_job.rb.