Changes

Jump to: navigation, search

Timesheet Variables

3,081 bytes added, 16:11, 25 July 2014
Examples
* Billable: '''~billable~'''
* Notes: '''~itemdescription~'''
* Timecode: '''~timecode~'''
* Is Billable: '''~isagainstjob~''' - ''will return 1 when timecode used is marked as'' billable'', 0 when timecode is not''
==ExampleExamples==The following is a example are examples that would could be used on the [[Web Page View Field|Web Page View]] a {{WPV}} to create a table listing all the timesheet items for the invoice, as well as the Subtotal, Total GST, PST and Invoice Total:
<prestyle="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;"><tablecellspacing=0 cellpadding=2 border=1> <tr> <tdth>Product CodeStaff</tdth> <tdth>Item DescriptionDetails</tdth> <tdth>QuantityDate</tdth> <tdth>Unit CostEffort</tdth> <tdth>Total CostStatus</tdth> <tdth>GSTBillable</tdth> <tdth>PSTBilled</tdth></tr>
<form name=frmsubact>[#(?object=itemstimesheet;orderby=actiondate)
<tr> <tdnowrap>$Product Code$~username~</td> <td>~descriptionitemdescription~</td> <td> ~qtyactiondate~ </td> <td> ~amounttotalhours~ </td> <td> ~fullamountstatus~ </td> <td> ~taxbillable~ </td> <td> ~tax2if(tsinvoiceid>0,'Yes','No') as billed~ </td></tr>
#]
</form>
<tr/table> <td/pre> <b>Subpre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-Totalwrap:</bbreak-word;"> </tdtable cellspacing=0 cellpadding=2 border=0> <tdtr>@amount@</tdth>Billable Hours</tr><trth> <tdth>Not Billable Hours<b/th>Total GST:</bth>Billed Hours</tdth> <tdth>@tax@Unbilled Hours</tdth></tr>  <tr!--Billable Hours:--> <tdtr><bth>Total PST:[#(?object=timesheet;criteria=isagainstjob=1;groupfunction=sum)~totalhours~#]</bth> </td!--Not Billable Hours:--> <tdth>@tax2@[#(?object=timesheet;criteria=isagainstjob=0;groupfunction=sum)~totalhours~#]</tdth></tr><tr!--Billed Hours:--> <tdth><b[#(?object=timesheet;criteria=tsinvoiceid>Total:0 and isagainstjob=1;groupfunction=sum)~totalhours~#]</bth> </td!--Unbilled Hours:--> <tdth>@invtotal@[#(?object=timesheet;criteria=tsinvoiceid=0 and isagainstjob=1;groupfunction=sum)~totalhours~#]</tdth
</tr>
</table></pre>
The code between the '''[#(?object=timesheet)''' and closing '''#]''' will be repeated for each timesheet item to be included.
The code between the '''[#(?object=items)''' and closing '''#]''' will be repeated for each line item to be included on the invoice. Other examples include:
===Last Timesheet Entry Date===
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">[#(?object=timesheet;groupfunction=max)~actiondate~#]
</pre>
===Non-Invoiced Hours===
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;"><!--@sscalculation((REPLACE("[#(?object=timesheet;criteria=tsinvoiceid=0 and isagainstjob=1;groupfunction=sum)~totalhours~#]",",",""))*1)-->
</pre>
===Invoiced===
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;"><!--@sscalculation((REPLACE("[#(?object=timesheet;criteria=tsinvoiceid>0 and isagainstjob=1;groupfunction=sum)~totalhours~#]",",",""))*1)-->
</pre>
===Non-billable hours===
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;"><!--@sscalculation((REPLACE("[#(?object=timesheet;criteria=isagainstjob=0;groupfunction=sum)~totalhours~#]",",",""))*1)-->
</pre>
===Billable Hours===
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;"><!--@sscalculation((REPLACE("[#(?object=timesheet;criteria=isagainstjob=1;groupfunction=sum)~totalhours~#]",",",""))*1)-->
</pre>
===Actual Hours (total hours)===
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;"><!--@sscalculation(REPLACE("[#(?object=timesheet;groupfunction=sum)~totalhours~#]",",","")*1)-->
</pre>
===Timecodes===
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">[#(?object=timesheet;)~timecode~<BR>#]
</pre>
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Implementation Note: Saving timesheet records does not trigger the template formulas of Level 1 objects to which they are associated. To have fields summing timesheet items on the Level 1 record, use Read Only - System Variable fields.</pre>
==See Also==
* [[Invoice UTA|Invoice Configuration Page]]
* [[Invoice Module Variables]]
* [[Web Page View Field Variables]]
[[Category:Universal Tracking Application]][[Category:Variables]]
8,849
edits

Navigation menu