<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<object-views xmlns="http://axelor.com/xml/ns/object-views"
              xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
              xsi:schemaLocation="http://axelor.com/xml/ns/object-views http://axelor.com/xml/ns/object-views/object-views_5.2.xsd">
              
    <grid model="com.axelor.team.db.TeamTask" title="Tasks" name="business-project-team-task-grid" orderBy="-taskDate">
    	<field name="project"/>
    	<field name="name"/>
    	<field name="taskDate"/>
    	<field name="status"/>
    	<field name="progressSelect" widget="SelectProgress"/>
    	<field name="exTaxTotal"/>
    	<field name="toInvoice"/>
    	<field name="invoiced"/>
    	<button name="updateToInvoiceBtn" title="Update to invoice" readonlyIf="invoiced" icon="fa-check-circle" onClick="action-team-task-method-update-to-invoice"/>
    </grid>

	<action-method name="action-team-task-method-update-to-invoice">
		<call class="com.axelor.apps.businessproject.web.TeamTaskController" method="updateToInvoice"/>
	</action-method>
	
	<action-method name="action-team-task-method-update-discount">
		<call class="com.axelor.apps.businessproject.web.TeamTaskController" method="updateDiscount"/>
	</action-method>
	
	<action-method name="action-team-task-method-compute">
		<call class="com.axelor.apps.businessproject.web.TeamTaskController" method="compute"/>
	</action-method>
	
	<action-attrs name="action-team-task-attrs-scale-and-precision">
		<attribute name="scale" for="priceDiscounted" expr="eval: __config__.app.getNbDecimalDigitForUnitPrice()"/>
		<attribute name="scale" for="discountAmount" expr="eval: __config__.app.getNbDecimalDigitForUnitPrice()"/>
	</action-attrs>
	
</object-views>
