[REF][hr_timesheet_invoice] Add if exists domain and pep8 in modify lines.
bzr revid: moylop260@vauxoo.com-20130908212817-sxx8n2iaqoqpwpgj
This commit is contained in:
parent
e37f1e0f26
commit
9f33f77f3e
|
@ -79,11 +79,17 @@
|
|||
I click on "Create Invoice" button of "Invoice analytic Line" wizard to create invoice.
|
||||
-
|
||||
!python {model: hr.timesheet.invoice.create}: |
|
||||
created=self.do_create(cr, uid, [ref("hr_timesheet_invoice_create_0")], {"active_ids": [ref("hr_timesheet_invoice.account_analytic_line_developyamlforhrmodule0")]})
|
||||
created=self.do_create(cr, uid, [ref("hr_timesheet_invoice_create_0")], {
|
||||
"active_ids": [ref("hr_timesheet_invoice.account_analytic_line_developyamlforhrmodule0")]
|
||||
})
|
||||
invoice_pool = self.pool.get('account.invoice')
|
||||
invoice_domain = created.get('domain')
|
||||
invoice_ids = invoice_pool.search(cr, uid, invoice_domain)
|
||||
invoice_pool.write(cr, uid, invoice_ids, {'origin': 'test-hrtsic0_id_'+str( ref("hr_timesheet_invoice_create_0")) + '_aaldyfhrm0_id_'+str( ref("hr_timesheet_invoice.account_analytic_line_developyamlforhrmodule0") ) })
|
||||
invoice_domain = created.get('domain', False)
|
||||
if invoice_domain:
|
||||
invoice_ids = invoice_pool.search(cr, uid, invoice_domain)
|
||||
invoice_pool.write(cr, uid, invoice_ids, {'origin': 'test-hrtsic0_id_'+str( ref("hr_timesheet_invoice_create_0")) \
|
||||
+ '_aaldyfhrm0_id_'+str( ref("hr_timesheet_invoice.account_analytic_line_developyamlforhrmodule0") ) })
|
||||
else:
|
||||
pass#Assert missed invoice in next section
|
||||
|
||||
-
|
||||
I check that Invoice is created for this timesheet.
|
||||
|
|
|
@ -78,12 +78,17 @@
|
|||
I click on "Create Invoice" button of "Invoice analytic Line" wizard to create invoice.
|
||||
-
|
||||
!python {model: hr.timesheet.invoice.create}: |
|
||||
created=self.do_create(cr, uid, [ref("hr_timesheet_invoice_create_0")], {"active_ids": [ref("hr_timesheet_invoice.account_analytic_line_developyamlforhrmodule1")]})
|
||||
created=self.do_create(cr, uid, [ref("hr_timesheet_invoice_create_0")], {
|
||||
"active_ids": [ref("hr_timesheet_invoice.account_analytic_line_developyamlforhrmodule1")]
|
||||
})
|
||||
invoice_pool = self.pool.get('account.invoice')
|
||||
invoice_domain = created.get('domain')
|
||||
invoice_ids = invoice_pool.search(cr, uid, invoice_domain)
|
||||
invoice_pool.write(cr, uid, invoice_ids, {'origin': 'test-hrtsic0_id_'+str( ref("hr_timesheet_invoice_create_0")) + '_aaldyfhrm1_id_'+str( ref("hr_timesheet_invoice.account_analytic_line_developyamlforhrmodule1") ) })
|
||||
|
||||
invoice_domain = created.get('domain', False)
|
||||
if invoice_domain:
|
||||
invoice_ids = invoice_pool.search(cr, uid, invoice_domain)
|
||||
invoice_pool.write(cr, uid, invoice_ids, {'origin': 'test-hrtsic0_id_'+str( ref("hr_timesheet_invoice_create_0"))\
|
||||
+ '_aaldyfhrm1_id_'+str( ref("hr_timesheet_invoice.account_analytic_line_developyamlforhrmodule1") ) })
|
||||
else:
|
||||
pass#Assert missed invoice in next section
|
||||
-
|
||||
I check that Invoice is created for this timesheet.
|
||||
-
|
||||
|
|
Loading…
Reference in New Issue