feature_sale_crm
bzr revid: rmu@tinyerp.com-20130122054119-b00o7fwd9ja1d1va
This commit is contained in:
parent
d931634596
commit
2de1bf67d4
|
@ -484,6 +484,16 @@ class account_analytic_account(osv.osv):
|
||||||
res['value']['to_invoice'] = template.to_invoice.id
|
res['value']['to_invoice'] = template.to_invoice.id
|
||||||
res['value']['pricelist_id'] = template.pricelist_id.id
|
res['value']['pricelist_id'] = template.pricelist_id.id
|
||||||
return res
|
return res
|
||||||
|
|
||||||
|
def on_change_timesheets(self, cr, ids, uid, invoice_on_timesheets):
|
||||||
|
if invoice_on_timesheets == True:
|
||||||
|
return { 'value':{
|
||||||
|
'use_timesheets': True,
|
||||||
|
'to_invoice':1,
|
||||||
|
}}
|
||||||
|
else:
|
||||||
|
return { 'value':{'use_timesheets': False}}
|
||||||
|
|
||||||
account_analytic_account()
|
account_analytic_account()
|
||||||
|
|
||||||
class account_analytic_account_summary_user(osv.osv):
|
class account_analytic_account_summary_user(osv.osv):
|
||||||
|
|
|
@ -79,7 +79,7 @@
|
||||||
<td class="oe_timesheet_grey">
|
<td class="oe_timesheet_grey">
|
||||||
<label for="invoice_on_timesheets"/>
|
<label for="invoice_on_timesheets"/>
|
||||||
</td><td class="oe_timesheet_grey">
|
</td><td class="oe_timesheet_grey">
|
||||||
<field name="invoice_on_timesheets"/>
|
<field name="invoice_on_timesheets" on_change="on_change_timesheets(invoice_on_timesheets)"/>
|
||||||
</td><td>
|
</td><td>
|
||||||
<field class="oe_inline" name="hours_qtt_est" attrs="{'invisible': [('invoice_on_timesheets','=',False)]}"/>
|
<field class="oe_inline" name="hours_qtt_est" attrs="{'invisible': [('invoice_on_timesheets','=',False)]}"/>
|
||||||
</td><td>
|
</td><td>
|
||||||
|
@ -121,7 +121,7 @@
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
<group name='invoice_on_timesheets' attrs="{'invisible': [('invoice_on_timesheets','=',False)]}">
|
<group name='invoice_on_timesheets' attrs="{'invisible': [('invoice_on_timesheets','=',False)]}">
|
||||||
<p class="oe_grey oe_edit_only" colspan="2">
|
<p class="oe_grey oe_edit_only" colspan="2">
|
||||||
When invoicing on timesheet, OpenERP uses the
|
When invoicing on timesheet, OpenERP uses the
|
||||||
pricelist of the contract which uses the price
|
pricelist of the contract which uses the price
|
||||||
|
|
|
@ -18,10 +18,10 @@
|
||||||
</xpath>
|
</xpath>
|
||||||
<xpath expr="/form/sheet" position='before'>
|
<xpath expr="/form/sheet" position='before'>
|
||||||
<header>
|
<header>
|
||||||
<button name="set_pending" string="Pending" type="object" states="open" />
|
<button name="set_pending" string="To Renew" type="object" states="open" />
|
||||||
<button name="set_close" string="Contract Finished" type="object" states="open,pending" />
|
<button name="set_close" string="Contract Finished" type="object" states="open,pending" />
|
||||||
<button name="set_open" string="Re-open project" type="object" states="pending,close" />
|
<button name="set_open" string="Set In Progress" type="object" states="pending,close" />
|
||||||
<button name="set_open" string="Re-open project" type="object" states="cancelled,draft"/>
|
<button name="set_open" string="Set In Progress" type="object" states="cancelled,draft"/>
|
||||||
<button name="set_cancel" string="Cancel Contract" type="object" states="open,pending"/>
|
<button name="set_cancel" string="Cancel Contract" type="object" states="open,pending"/>
|
||||||
<field name="state" readonly="1" widget="statusbar"
|
<field name="state" readonly="1" widget="statusbar"
|
||||||
statusbar_visible="open,pending,close" statusbar_colors='{"pending":"red", "template":"blue"}'/>
|
statusbar_visible="open,pending,close" statusbar_colors='{"pending":"red", "template":"blue"}'/>
|
||||||
|
|
Loading…
Reference in New Issue