Version 6.x.x Source

Table Name: tabTime Log

Log of Activities performed by users against Tasks that can be used for tracking time, billing.

Fields

Sr Fieldname Type Label Options
1 activity_type Link Activity Type Activity Type
2 naming_series Select Series
TL-
3 project Link Project Project
4 task Link Task Task
5 status Select Status
Draft
Submitted
Batched for Billing
Billed
Cancelled
6 column_break_2 Column Break
7 from_time Datetime From Time
8 hours Float Hours
9 to_time Datetime To Time
10 billable Check Billable
11 section_break_7 Section Break
12 note Text Editor Note
13 section_break_12 Section Break
14 user Link User User
15 employee Link Employee Employee
16 column_break_3 Column Break
17 for_manufacturing Check For Manufacturing
18 section_break_11 Section Break
19 production_order Link Production Order Production Order
20 operation Link Operation Operation
21 operation_id Data Operation ID
22 column_break_14 Column Break
23 workstation Link Workstation Workstation
24 completed_qty Float Completed Qty

Operation completed for how many finished goods?

25 section_break_24 Section Break
26 costing_rate Currency Costing Rate based on Activity Type (per hour)
27 costing_amount Currency Costing Amount
28 column_break_25 Column Break
29 billing_rate Currency Billing Rate based on Activity Type (per hour)
30 additional_cost Currency Additional Cost
31 billing_amount Currency Billing Amount

Will be updated only if Time Log is 'Billable'

32 section_break_29 Section Break
33 time_log_batch Link Time Log Batch

Will be updated when batched.

Time Log Batch
34 sales_invoice Link Sales Invoice

Will be updated when billed.

Sales Invoice
35 amended_from Link Amended From Time Log
36 title Data Title

Controller

erpnext.projects.doctype.time_log.time_log

Class NegativeHoursError

Inherits from frappe.exceptions.ValidationError


Class NotSubmittedError

Inherits from frappe.exceptions.ValidationError


Class OverProductionLoggedError

Inherits from frappe.exceptions.ValidationError


Class OverlapError

Inherits from frappe.exceptions.ValidationError


Class TimeLog

Inherits from frappe.model.document.Document

before_cancel (self)

No docs


before_update_after_submit (self)

No docs


calculate_total_hours (self)

No docs


check_workstation_timings (self)

Checks if Time Log is between operating hours of the Workstation.


get_operation_start_end_time (self)

Returns Min From and Max To Dates of Time Logs against a specific Operation.


get_overlap_for (self, fieldname)

No docs


get_time_log_summary (self)

Returns 'Actual Operating Time'.


move_to_next_day (self)

Move start and end time one day forward


move_to_next_non_overlapping_slot (self)

If in overlap, set start as the end point of the overlapping time log


move_to_next_working_slot (self)

Move to next working slot from workstation


on_cancel (self)

No docs


on_submit (self)

No docs


set_project_if_missing (self)

Set project if task is set


set_status (self)

No docs


set_title (self)

Set default title for the Time Log


update_cost (self)

No docs


update_production_order (self)

Updates start_date, end_date, status for operation in Production Order.


update_task_and_project (self)

Update costing rate in Task or Project if either is set


validate (self)

No docs


validate_manufacturing (self)

No docs


validate_overlap (self)

Checks if 'Time Log' entries overlap for a user, workstation.


validate_overlap_for (self, fieldname)

No docs


validate_production_order (self)

Throws 'NotSubmittedError' if production order is not submitted.


validate_time_log_for (self)

No docs


validate_timings (self)

No docs



Public API
/api/method/erpnext.projects.doctype.time_log.time_log.get_activity_cost

erpnext.projects.doctype.time_log.time_log.get_activity_cost (employee=None, activity_type=None)

No docs


Public API
/api/method/erpnext.projects.doctype.time_log.time_log.get_events

erpnext.projects.doctype.time_log.time_log.get_events (start, end, filters=None)

Returns events for Gantt / Calendar view rendering.

Parameters:


Linked In: