revert merge

bzr revid: nel@tinyerp.com-20100409082251-xf1r7upp83566a30
This commit is contained in:
nel@tinyerp.com 2010-04-09 10:22:51 +02:00
parent 0525336d28
commit 1b2c83c8fb
92 changed files with 1126 additions and 2213 deletions

View File

@ -80,15 +80,13 @@ module named account_voucherss
'report/account_analytic_report_view.xml',
],
'demo_xml': [
#'demo/price_accuracy00.yml',
'account_demo.xml',
'project/project_demo.xml',
'project/analytic_account_demo.xml',
'demo/account_minimal.xml',
'account_unit_test.xml',
],
'test': [
'test/price_accuracy00.yml',
],
'installable': True,
'active': False,
'certificate': '0080331923549',

View File

@ -44,6 +44,7 @@
Then I should see an account entry linked to this invoice.
-
!assert {model: account.invoice, id: invoice1}:
test:
- bool(move_id)
-
# This is not working, find a way to do that in YAML, *qty is not
@ -52,12 +53,14 @@
equal to *qty x *price x (1 + *tax)
-
!assert {model: account.invoice, id: invoice1}:
- abs(sum(x.credit for x in move_id.line_id) - 163.97) < 0.000001
test:
- abs(sum(x.credit for x in move_id.line_id) - 163.97) < 0.000001
-
And this account entry must have a credit equals to the debit
-
!assert {model: account.invoice, id: invoice1}:
- abs(sum(x.credit - x.debit for x in move_id.line_id)) < 0.000001
test:
- abs(sum(x.credit - x.debit for x in move_id.line_id)) < 0.000001
-
Then, I change the precision of numbers to 3 digits.
-
@ -77,7 +80,8 @@
Then this account entry must have a credit equals to the debit
-
!assert {model: account.invoice, id: invoice2}:
- abs(sum(x.credit - x.debit for x in move_id.line_id)) < 0.000001
test:
- abs(sum(x.credit - x.debit for x in move_id.line_id)) < 0.000001
-
And this account entry must have a credit equals to 163.968€ which is
equal to *qty x *price x (1 + *tax)

View File

@ -7,13 +7,13 @@ msgstr ""
"Project-Id-Version: OpenERP Server 5.0.0\n"
"Report-Msgid-Bugs-To: support@openerp.com\n"
"POT-Creation-Date: 2009-08-28 16:01+0000\n"
"PO-Revision-Date: 2010-04-08 18:06+0000\n"
"PO-Revision-Date: 2010-04-01 22:39+0000\n"
"Last-Translator: mitev.dmitry <Unknown>\n"
"Language-Team: \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Launchpad-Export-Date: 2010-04-09 03:56+0000\n"
"X-Launchpad-Export-Date: 2010-04-03 03:54+0000\n"
"X-Generator: Launchpad (build Unknown)\n"
#. module: account
@ -115,7 +115,7 @@ msgstr "Rodič"
#. module: account
#: selection:account.move,type:0
msgid "Journal Voucher"
msgstr "Rada"
msgstr ""
#. module: account
#: field:account.invoice,residual:0
@ -134,7 +134,7 @@ msgstr "Základní kódová značka"
#: model:ir.actions.wizard,name:account.wizard_unreconcile_select
#: model:ir.ui.menu,name:account.menu_unreconcile_select
msgid "Unreconcile entries"
msgstr "Nepotvrzené záznamy"
msgstr ""
#. module: account
#: constraint:account.period:0
@ -159,7 +159,7 @@ msgstr "Debetní Centralizace"
#. module: account
#: model:ir.actions.wizard,name:account.wizard_invoice_state_confirm
msgid "Confirm draft invoices"
msgstr "Potvrdit návrh faktury"
msgstr ""
#. module: account
#: help:account.payment.term.line,days2:0
@ -182,7 +182,7 @@ msgstr "Grafy účtu"
#. module: account
#: model:ir.actions.wizard,name:account.wizard_move_line_select
msgid "Move line select"
msgstr "Přesun řádku vyberte"
msgstr ""
#. module: account
#: rml:account.journal.period.print:0
@ -310,7 +310,7 @@ msgstr "Původ"
#. module: account
#: rml:account.analytic.account.journal:0
msgid "Move Name"
msgstr "Název Pohybu"
msgstr ""
#. module: account
#: xsl:account.transfer:0
@ -325,7 +325,7 @@ msgstr "Vypočítat předpaltné(Subscription Compute)"
#. module: account
#: rml:account.central.journal:0
msgid "Account Num."
msgstr "Číslo účtu"
msgstr ""
#. module: account
#: rml:account.analytic.account.analytic.check:0
@ -337,12 +337,12 @@ msgstr ""
#: field:account.invoice,amount_tax:0
#: field:account.move.line,account_tax_id:0
msgid "Tax"
msgstr "Daň"
msgstr ""
#. module: account
#: rml:account.general.journal:0
msgid "Debit Trans."
msgstr "Debetní transakce"
msgstr ""
#. module: account
#: field:account.analytic.line,account_id:0
@ -356,24 +356,24 @@ msgstr "Analytický účet"
#: field:account.tax,child_depend:0
#: field:account.tax.template,child_depend:0
msgid "Tax on Children"
msgstr "Daň z dětí"
msgstr ""
#. module: account
#: rml:account.central.journal:0
#: rml:account.general.journal:0
#: field:account.journal,name:0
msgid "Journal Name"
msgstr "Název časopisu"
msgstr ""
#. module: account
#: view:account.payment.term:0
msgid "Description on invoices"
msgstr "Popis na fakturách"
msgstr ""
#. module: account
#: constraint:account.analytic.account:0
msgid "Error! You can not create recursive analytic accounts."
msgstr "Chyba! Nemůžete vytvářet rekurzivní analytické účty."
msgstr ""
#. module: account
#: field:account.bank.statement.reconcile,total_entry:0
@ -389,13 +389,13 @@ msgstr "Zdroj účtu"
#. module: account
#: field:account.journal,update_posted:0
msgid "Allow Cancelling Entries"
msgstr "Povolit Zrušení Příspěvky"
msgstr ""
#. module: account
#: model:process.transition,name:account.process_transition_paymentorderbank0
#: model:process.transition,name:account.process_transition_paymentorderreconcilation0
msgid "Payment Reconcilation"
msgstr "Platba usmíření"
msgstr ""
#. module: account
#: model:account.journal,name:account.expenses_journal
@ -425,7 +425,7 @@ msgstr "(Účet / Partner) Název"
#. module: account
#: selection:account.move,type:0
msgid "Contra"
msgstr "Kontraindikace"
msgstr ""
#. module: account
#: field:account.analytic.account,state:0
@ -447,7 +447,7 @@ msgstr ""
#: view:account.tax:0
#: view:account.tax.template:0
msgid "Special Computation"
msgstr "Speciální výpočetní"
msgstr ""
#. module: account
#: model:process.transition,note:account.process_transition_confirmstatementfromdraft0
@ -506,7 +506,7 @@ msgstr ""
#. module: account
#: view:account.invoice:0
msgid "Supplier invoice"
msgstr "Dodavatele uvedený na faktuře"
msgstr ""
#. module: account
#: model:process.transition,name:account.process_transition_reconcilepaid0
@ -533,7 +533,7 @@ msgstr ""
#. module: account
#: field:account.account.type,close_method:0
msgid "Deferral Method"
msgstr "Metoda zpoždění"
msgstr ""
#. module: account
#: field:account.tax.template,include_base_amount:0
@ -560,7 +560,7 @@ msgstr ""
#: selection:account.tax,applicable_type:0
#: selection:account.tax.template,applicable_type:0
msgid "True"
msgstr "Pravda"
msgstr ""
#. module: account
#: help:account.payment.term.line,days:0
@ -577,7 +577,7 @@ msgstr ""
#. module: account
#: rml:account.central.journal:0
msgid "Printing Date"
msgstr "Datum vydání"
msgstr ""
#. module: account
#: rml:account.general.ledger:0
@ -593,7 +593,7 @@ msgstr ""
#. module: account
#: view:account.journal:0
msgid "Entry Controls"
msgstr "Vstupní kontrolou"
msgstr ""
#. module: account
#: help:account.model.line,sequence:0
@ -616,13 +616,13 @@ msgstr ""
#. module: account
#: field:account.analytic.account,contact_id:0
msgid "Contact"
msgstr "Kontakt"
msgstr ""
#. module: account
#: selection:account.model.line,date:0
#: selection:account.model.line,date_maturity:0
msgid "Partner Payment Term"
msgstr "Partner splatnosti"
msgstr ""
#. module: account
#: view:account.move.reconcile:0
@ -637,13 +637,13 @@ msgstr "Otevřeno pro bankovní vyrovnání(Open for bank reconciliation)"
#. module: account
#: field:account.invoice.line,discount:0
msgid "Discount (%)"
msgstr "Sleva (%)"
msgstr ""
#. module: account
#: wizard_field:account.move.line.reconcile,init_full,writeoff:0
#: wizard_field:account.move.line.reconcile,init_partial,writeoff:0
msgid "Write-Off amount"
msgstr "Odpis části"
msgstr ""
#. module: account
#: help:account.fiscalyear,company_id:0
@ -653,7 +653,7 @@ msgstr ""
#. module: account
#: model:ir.ui.menu,name:account.menu_analytic_accounting
msgid "Analytic Accounting"
msgstr "Analytické účetnictví"
msgstr ""
#. module: account
#: rml:account.overdue:0
@ -666,22 +666,22 @@ msgstr ""
#: model:ir.actions.act_window,name:account.action_account_analytic_line_form
#: model:ir.ui.menu,name:account.next_id_41
msgid "Analytic Entries"
msgstr "Analytická Příspěvky"
msgstr ""
#. module: account
#: selection:account.subscription,period_type:0
msgid "month"
msgstr "měsíc"
msgstr ""
#. module: account
#: field:account.analytic.account,partner_id:0
msgid "Associated Partner"
msgstr "Přidruženého partnera"
msgstr ""
#. module: account
#: field:account.invoice,comment:0
msgid "Additional Information"
msgstr "Další informace"
msgstr ""
#. module: account
#: selection:account.invoice,type:0
@ -719,18 +719,18 @@ msgstr ""
#. module: account
#: model:process.transition,name:account.process_transition_supplieranalyticcost0
msgid "Analytic Invoice"
msgstr "Analytická faktury"
msgstr ""
#. module: account
#: field:account.journal.column,field:0
msgid "Field Name"
msgstr "Název pole"
msgstr ""
#. module: account
#: field:account.tax.code,sign:0
#: field:account.tax.code.template,sign:0
msgid "Sign for parent"
msgstr "Přihlaste se na mateřské"
msgstr ""
#. module: account
#: field:account.fiscalyear,end_journal_period_id:0
@ -741,7 +741,7 @@ msgstr ""
#: view:product.product:0
#: view:product.template:0
msgid "Purchase Properties"
msgstr "Nákup Nemovitosti"
msgstr ""
#. module: account
#: model:process.node,note:account.process_node_paymententries0
@ -751,12 +751,12 @@ msgstr ""
#. module: account
#: wizard_button:account.invoice.pay,init,reconcile:0
msgid "Partial Payment"
msgstr "Částečná platba"
msgstr ""
#. module: account
#: wizard_view:account_use_models,create:0
msgid "Move Lines Created."
msgstr "Přesun vytvořených linek."
msgstr ""
#. module: account
#: field:account.fiscalyear,state:0
@ -766,18 +766,18 @@ msgstr "Přesun vytvořených linek."
#: field:account.period,state:0
#: field:account.subscription,state:0
msgid "Status"
msgstr "Stav"
msgstr ""
#. module: account
#: rml:account.analytic.account.cost_ledger:0
#: rml:account.analytic.account.quantity_cost_ledger:0
msgid "Period to"
msgstr "Období do"
msgstr ""
#. module: account
#: field:account.account.type,partner_account:0
msgid "Partner account"
msgstr "Partner účet"
msgstr ""
#. module: account
#: wizard_view:account.subscription.generate,init:0
@ -803,7 +803,7 @@ msgstr ""
#. module: account
#: field:account.invoice,move_lines:0
msgid "Move Lines"
msgstr "Přesun Linky"
msgstr ""
#. module: account
#: model:ir.model,name:account.model_account_config_wizard
@ -831,26 +831,26 @@ msgstr ""
#. module: account
#: model:ir.ui.menu,name:account.next_id_30
msgid "Bank Reconciliation"
msgstr "Bankovní usmíření"
msgstr ""
#. module: account
#: model:ir.model,name:account.model_account_account_template
msgid "Templates for Accounts"
msgstr "Šablony pro účty"
msgstr ""
#. module: account
#: model:ir.actions.act_window,name:account.action_account_analytic_account_form
#: model:ir.model,name:account.model_account_analytic_account
#: model:ir.ui.menu,name:account.account_analytic_def_account
msgid "Analytic Accounts"
msgstr "Analytické účty"
msgstr ""
#. module: account
#: wizard_view:account.print.journal.report,init:0
#: model:ir.actions.wizard,name:account.wizard_print_journal
#: model:ir.ui.menu,name:account.menu_print_journal
msgid "Print Journal"
msgstr "Tisk věstníku"
msgstr ""
#. module: account
#: model:ir.model,name:account.model_account_bank_accounts_wizard
@ -861,39 +861,39 @@ msgstr ""
#: field:account.move.line,date_created:0
#: field:account.move.reconcile,create_date:0
msgid "Creation date"
msgstr "Datum vytvoření"
msgstr ""
#. module: account
#: wizard_button:account.invoice.refund,init,cancel_invoice:0
msgid "Cancel Invoice"
msgstr "Zrušit účet"
msgstr ""
#. module: account
#: field:account.journal.column,required:0
msgid "Required"
msgstr "Požadované"
msgstr ""
#. module: account
#: field:product.category,property_account_expense_categ:0
#: field:product.template,property_account_expense:0
msgid "Expense Account"
msgstr "Cestovní účet"
msgstr ""
#. module: account
#: wizard_field:account.move.line.reconcile,addendum,journal_id:0
msgid "Write-Off Journal"
msgstr "Odpis věstníku"
msgstr ""
#. module: account
#: field:account.model.line,amount_currency:0
#: field:account.move.line,amount_currency:0
msgid "Amount Currency"
msgstr "Částka měny"
msgstr ""
#. module: account
#: field:account.chart.template,property_account_expense_categ:0
msgid "Expense Category Account"
msgstr "Kategorie výdajů účtu"
msgstr ""
#. module: account
#: wizard_field:account.fiscalyear.close,init,fy2_id:0
@ -910,7 +910,7 @@ msgstr ""
#. module: account
#: wizard_field:account.open_closed_fiscalyear,init,fyear_id:0
msgid "Fiscal Year to Open"
msgstr "Fiskální rok otevřena"
msgstr ""
#. module: account
#: view:account.config.wizard:0
@ -928,7 +928,7 @@ msgstr ""
#: field:account.model.line,quantity:0
#: field:account.move.line,quantity:0
msgid "Quantity"
msgstr "Množství"
msgstr ""
#. module: account
#: wizard_field:account.account.balance.report,checktype,date_to:0
@ -936,7 +936,7 @@ msgstr "Množství"
#: wizard_field:account.partner.balance.report,init,date2:0
#: wizard_field:account.third_party_ledger.report,init,date2:0
msgid "End date"
msgstr "Datum ukončení"
msgstr ""
#. module: account
#: field:account.invoice.tax,base_amount:0
@ -957,12 +957,12 @@ msgstr ""
#: model:ir.actions.act_window,name:account.action_bank_statement_tree
#: model:ir.ui.menu,name:account.menu_bank_statement_tree
msgid "Entries by Statements"
msgstr "Příspěvky výroky"
msgstr ""
#. module: account
#: model:process.transition,name:account.process_transition_analyticinvoice0
msgid "analytic Invoice"
msgstr "analytické faktury"
msgstr ""
#. module: account
#: wizard_field:account.automatic.reconcile,init,period_id:0
@ -981,22 +981,22 @@ msgstr "analytické faktury"
#: wizard_field:account.print.journal.report,init,period_id:0
#: field:account.subscription,period_nbr:0
msgid "Period"
msgstr "Perioda"
msgstr ""
#. module: account
#: rml:account.partner.balance:0
msgid "Grand total"
msgstr "Úhrn"
msgstr ""
#. module: account
#: model:ir.ui.menu,name:account.menu_finance_accounting
msgid "Financial Accounting"
msgstr "Finanční účetnictví"
msgstr ""
#. module: account
#: rml:account.invoice:0
msgid "Net Total:"
msgstr "Čistá celkem:"
msgstr ""
#. module: account
#: view:account.fiscal.position:0
@ -1010,7 +1010,7 @@ msgstr "Čistá celkem:"
#: model:ir.model,name:account.model_account_fiscal_position
#: field:res.partner,property_account_position:0
msgid "Fiscal Position"
msgstr "Fiskální pozice"
msgstr ""
#. module: account
#: field:account.analytic.line,product_uom_id:0
@ -1027,7 +1027,7 @@ msgstr ""
#: field:account.account,child_parent_ids:0
#: field:account.account.template,child_parent_ids:0
msgid "Children"
msgstr "Děti"
msgstr ""
#. module: account
#: model:ir.model,name:account.model_account_fiscal_position_tax
@ -1038,35 +1038,35 @@ msgstr ""
#: model:ir.actions.act_window,name:account.action_invoice_tree2_new
#: model:ir.ui.menu,name:account.menu_action_invoice_tree2_new
msgid "New Supplier Invoice"
msgstr "Nového dodavatele faktury"
msgstr ""
#. module: account
#: wizard_field:account.invoice.pay,init,amount:0
msgid "Amount paid"
msgstr "Zaplacené částky"
msgstr ""
#. module: account
#: selection:account.invoice,type:0
#: model:process.transition,name:account.process_transition_customerinvoice0
#: model:process.transition,name:account.process_transition_suppliercustomerinvoice0
msgid "Customer Invoice"
msgstr "Zákazník faktury"
msgstr ""
#. module: account
#: wizard_view:account.open_closed_fiscalyear,init:0
msgid "Choose Fiscal Year"
msgstr "Vyberte si fiskální rok"
msgstr ""
#. module: account
#: field:account.sequence.fiscalyear,sequence_main_id:0
msgid "Main Sequence"
msgstr "Hlavní posloupnosti"
msgstr ""
#. module: account
#: model:ir.actions.act_window,name:account.action_account_analytic_journal_tree
#: model:ir.ui.menu,name:account.account_analytic_journal_print
msgid "Print Analytic Journals"
msgstr "Tisk Analytické Časopisy"
msgstr ""
#. module: account
#: rml:account.tax.code.entries:0
@ -1083,7 +1083,7 @@ msgstr ""
#. module: account
#: field:account.bank.statement.reconcile,total_new:0
msgid "Total write-off"
msgstr "Celkem odpis"
msgstr ""
#. module: account
#: view:account.tax.template:0
@ -1095,14 +1095,14 @@ msgstr ""
#: model:ir.actions.act_window,name:account.action_tax_code_list
#: model:ir.ui.menu,name:account.menu_action_tax_code_list
msgid "Tax codes"
msgstr "Daňové kódy"
msgstr ""
#. module: account
#: field:account.fiscal.position.template,chart_template_id:0
#: field:account.tax.template,chart_template_id:0
#: field:wizard.multi.charts.accounts,chart_template_id:0
msgid "Chart Template"
msgstr "Graf šablony"
msgstr ""
#. module: account
#: field:account.chart.template,property_account_income_categ:0
@ -1113,24 +1113,24 @@ msgstr ""
#: model:ir.actions.act_window,name:account.analytic_account_form
#: model:ir.ui.menu,name:account.account_analytic_form
msgid "New Analytic Account"
msgstr "Nový analitickiý účet"
msgstr ""
#. module: account
#: model:ir.actions.act_window,name:account.action_account_fiscal_position_template_form
#: model:ir.ui.menu,name:account.menu_action_account_fiscal_position_form_template
msgid "Fiscal Position Templates"
msgstr "Fiskální pozice Šablony"
msgstr ""
#. module: account
#: rml:account.invoice:0
#: field:account.invoice.line,price_unit:0
msgid "Unit Price"
msgstr "Cena za kus"
msgstr ""
#. module: account
#: rml:account.analytic.account.journal:0
msgid "Period from :"
msgstr "Období od:"
msgstr ""
#. module: account
#: model:ir.model,name:account.model_wizard_multi_charts_accounts
@ -1140,7 +1140,7 @@ msgstr ""
#. module: account
#: model:account.journal,name:account.sales_journal
msgid "Journal de vente"
msgstr "Prodej věstníku"
msgstr ""
#. module: account
#: help:account.model.line,amount_currency:0
@ -1151,23 +1151,23 @@ msgstr ""
#: view:account.fiscal.position.template:0
#: field:account.fiscal.position.template,name:0
msgid "Fiscal Position Template"
msgstr "Fiskální pozice šablony"
msgstr ""
#. module: account
#: field:account.payment.term,line_ids:0
msgid "Terms"
msgstr "Podmínky"
msgstr ""
#. module: account
#: rml:account.vat.declaration:0
msgid "Tax Report"
msgstr "Daňové Report"
msgstr ""
#. module: account
#: wizard_button:account.analytic.account.chart,init,open:0
#: wizard_button:account.chart,init,open:0
msgid "Open Charts"
msgstr "Zobrazit Grafy"
msgstr ""
#. module: account
#: wizard_view:account.fiscalyear.close.state,init:0
@ -1177,7 +1177,7 @@ msgstr ""
#. module: account
#: selection:account.move,type:0
msgid "Bank Receipt"
msgstr "Bankovní Příjem"
msgstr ""
#. module: account
#: view:res.partner:0
@ -1187,17 +1187,17 @@ msgstr "Bankovní účet"
#. module: account
#: field:account.chart.template,tax_template_ids:0
msgid "Tax Template List"
msgstr "Daňové seznamu šablon"
msgstr ""
#. module: account
#: model:process.transition,name:account.process_transition_invoiceimport0
msgid "Invoice import"
msgstr "Faktura import"
msgstr ""
#. module: account
#: model:ir.actions.wizard,name:account.action_move_journal_line_form_select
msgid "Standard entry"
msgstr "Standardní vstupní"
msgstr ""
#. module: account
#: help:account.account,currency_mode:0
@ -1212,7 +1212,7 @@ msgstr ""
#. module: account
#: field:account.account,company_currency_id:0
msgid "Company Currency"
msgstr "Společnost měny"
msgstr ""
#. module: account
#: model:ir.model,name:account.model_account_fiscal_position_account_template
@ -1222,7 +1222,7 @@ msgstr ""
#. module: account
#: field:account.analytic.account,parent_id:0
msgid "Parent Analytic Account"
msgstr "Parent Analytická účtu"
msgstr ""
#. module: account
#: wizard_button:account.move.line.reconcile,init_partial,addendum:0
@ -1242,22 +1242,22 @@ msgstr ""
#. module: account
#: field:account.bank.statement,balance_end_real:0
msgid "Ending Balance"
msgstr "Konečný zůstatek"
msgstr ""
#. module: account
#: view:product.product:0
msgid "Purchase Taxes"
msgstr "Nákup Daně"
msgstr ""
#. module: account
#: field:account.payment.term.line,name:0
msgid "Line Name"
msgstr "Název řádku"
msgstr ""
#. module: account
#: selection:account.payment.term.line,value:0
msgid "Fixed Amount"
msgstr "Pevná částka"
msgstr ""
#. module: account
#: rml:account.analytic.account.analytic.check:0
@ -1285,24 +1285,24 @@ msgstr ""
#. module: account
#: view:account.config.wizard:0
msgid "Continue"
msgstr "Pokračovat"
msgstr ""
#. module: account
#: field:account.payment.term.line,value:0
msgid "Value"
msgstr "Hodnota"
msgstr ""
#. module: account
#: wizard_field:account.invoice.pay,addendum,writeoff_acc_id:0
#: wizard_field:account.move.line.reconcile,addendum,writeoff_acc_id:0
msgid "Write-Off account"
msgstr "Odpis účet"
msgstr ""
#. module: account
#: field:account.model.line,model_id:0
#: field:account.subscription,model_id:0
msgid "Model"
msgstr "Vzor"
msgstr ""
#. module: account
#: model:ir.actions.wizard,name:account.wizard_fiscalyear_close_state
@ -1313,12 +1313,12 @@ msgstr ""
#. module: account
#: field:account.journal,centralisation:0
msgid "Centralised counterpart"
msgstr "Centralizované protějšek"
msgstr ""
#. module: account
#: view:wizard.company.setup:0
msgid "Message"
msgstr "Zpráva"
msgstr ""
#. module: account
#: model:process.node,note:account.process_node_supplierpaymentorder0
@ -1332,7 +1332,7 @@ msgstr ""
#: selection:account.analytic.account,type:0
#: field:account.journal,view_id:0
msgid "View"
msgstr "Pohled"
msgstr ""
#. module: account
#: selection:account.account.balance.report,checktype,display_account:0
@ -1340,13 +1340,13 @@ msgstr "Pohled"
#: selection:account.tax,type_tax_use:0
#: selection:account.tax.template,type_tax_use:0
msgid "All"
msgstr "Vše"
msgstr ""
#. module: account
#: field:account.move.line,analytic_lines:0
#: model:ir.model,name:account.model_account_analytic_line
msgid "Analytic lines"
msgstr "Analytická linky"
msgstr ""
#. module: account
#: help:account.tax,type:0
@ -1370,28 +1370,28 @@ msgstr ""
#. module: account
#: model:process.node,name:account.process_node_electronicfile0
msgid "Electronic File"
msgstr "Elektronický soubor"
msgstr ""
#. module: account
#: view:res.partner:0
msgid "Customer Credit"
msgstr "Odběratelský úvěr"
msgstr ""
#. module: account
#: field:account.invoice,tax_line:0
msgid "Tax Lines"
msgstr "Daňové Linky"
msgstr ""
#. module: account
#: field:ir.sequence,fiscal_ids:0
msgid "Sequences"
msgstr "Posloupnosti"
msgstr ""
#. module: account
#: model:ir.actions.act_window,name:account.action_account_type_form
#: model:ir.ui.menu,name:account.menu_action_account_type_form
msgid "Account Types"
msgstr "Typy účtů"
msgstr ""
#. module: account
#: wizard_field:account.automatic.reconcile,init,journal_id:0
@ -1413,18 +1413,18 @@ msgstr "Typy účtů"
#: wizard_field:populate_statement_from_inv,init,journal_id:0
#: field:report.hr.timesheet.invoice.journal,journal_id:0
msgid "Journal"
msgstr "Časopis"
msgstr ""
#. module: account
#: field:account.account,child_id:0
#: field:account.analytic.account,child_ids:0
msgid "Child Accounts"
msgstr "Dětská konta"
msgstr ""
#. module: account
#: field:account.account,check_history:0
msgid "Display History"
msgstr "Zobrazení historie"
msgstr ""
#. module: account
#: wizard_field:account.third_party_ledger.report,init,date1:0
@ -1454,7 +1454,7 @@ msgstr ""
#: wizard_view:account.move.line.reconcile,init_full:0
#: wizard_view:account.move.line.reconcile,init_partial:0
msgid "Write-Off"
msgstr "Odpis"
msgstr ""
#. module: account
#: help:account.invoice,partner_bank:0
@ -1466,12 +1466,12 @@ msgstr ""
#. module: account
#: field:res.partner,debit:0
msgid "Total Payable"
msgstr "Celkem za poplatek"
msgstr ""
#. module: account
#: wizard_button:account.fiscalyear.close.state,init,close:0
msgid "Close states"
msgstr "Zavřít státy"
msgstr ""
#. module: account
#: model:ir.model,name:account.model_wizard_company_setup
@ -1486,22 +1486,22 @@ msgstr ""
#. module: account
#: field:account.journal,refund_journal:0
msgid "Refund Journal"
msgstr "Refundace věstníku"
msgstr ""
#. module: account
#: model:account.account.type,name:account.account_type_income
msgid "Income"
msgstr "Příjem"
msgstr ""
#. module: account
#: selection:account.bank.statement.line,type:0
msgid "Supplier"
msgstr "Dodavatel"
msgstr ""
#. module: account
#: rml:account.invoice:0
msgid "Tel. :"
msgstr "Telefonní číslo:"
msgstr ""
#. module: account
#: field:account.invoice.tax,tax_amount:0

View File

@ -49,39 +49,40 @@
<field name="arch" type="xml">
<search string="Invoices">
<group>
<filter icon="terp-account"
string="This Year"
domain="[('year','=',time.strftime('%%Y'))]"
help="Invoices of the year"/>
<filter icon="terp-account"
string="This Month"
domain="[('month','=',time.strftime('%%m'))]"
help="Invoices of this month"/>
<separator orientation="vertical"/>
<filter icon="terp-account"
string="Draft"
domain="[('state','=','draft')]"/>
<filter icon="terp-account"
string="Invoices"
domain="[('state','&lt;&gt;','draft'),('state','&lt;&gt;','cancel')]"/>
<filter icon="terp-account"
string="Paid"
domain="[('state','=','paid')]"/>
<separator orientation="vertical"/>
<field name="product_id"/>
<field name="user_id" widget="selection">
<filter icon="terp-account"
string="My Invoices"
domain="[('user_id','=',uid)]"/>
</field>
<field name="partner_id"/>
<field name="company_id" groups="base.group_multi_company" widget="selection"/>
</group>
<filter icon="terp-account"
string="This Year"
domain="[('year','=',time.strftime('%%Y'))]"
help="Invoices of the year"/>
<filter icon="terp-account"
string="This Month"
domain="[('month','=',time.strftime('%%m'))]"
help="Invoices of this month"/>
<separator orientation="vertical"/>
<filter icon="terp-account"
string="Draft"
domain="[('state','=','draft')]"/>
<filter icon="terp-account"
string="Invoices"
domain="[('state','&lt;&gt;','draft'),('state','&lt;&gt;','cancel')]"/>
<filter icon="terp-account"
string="Paid"
domain="[('state','=','paid')]"/>
<separator orientation="vertical"/>
<field name="product_id"/>
<field name="user_id" widget="selection">
<filter icon="terp-account"
string="My Invoices"
domain="[('user_id','=',uid)]"/>
</field>
<field name="partner_id"/>
<field name="company_id" groups="base.group_multi_company" widget="selection"/>
</group>
<newline/>
<group expand="1" string="Extended options..." >
<group expand="1" string="Extended options..." colspan="10" col="12">
<filter icon="terp-account"
string="Customer Invoices"
domain="[('type','=','out_invoice')]"/>
domain="[('type','=','out_invoice')]"
default="1"/>
<filter icon="terp-account"
string="Customer Refunds"
domain="[('type','=','out_refund')]"/>
@ -94,9 +95,9 @@
domain="[('type','=','in_refund')]"/>
</group>
<newline/>
<group expand="1" string="Group By..." >
<group expand="1" string="Group By..." colspan="10" col="12">
<filter string="Company" icon="terp-account" context="{'group_by':'company_id'}"/>
<filter string="Salesman" icon="terp-account" context="{'group_by':'user_id'}" />
<filter string="Salesman" icon="terp-account" context="{'group_by':'user_id'}" default="1"/>
<filter string="Payment Term" icon="terp-account" context="{'group_by':'payment_term'}"/>
<separator orientation="vertical"/>
<filter string="Currency" icon="terp-account" context="{'group_by':'currency_id'}"/>

View File

@ -0,0 +1,54 @@
# -*- coding: utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Management Solution
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as
# published by the Free Software Foundation, either version 3 of the
# License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
##############################################################################
#
# TODO: move this in a YAML test with !python tag
#
import xmlrpclib
DB = 'training3'
USERID = 1
USERPASS = 'admin'
sock = xmlrpclib.ServerProxy('http://%s:%s/xmlrpc/object' % ('localhost',8069))
ids = sock.execute(DB, USERID, USERPASS, 'account.account', 'search', [], {})
account_lists = sock.execute(DB, USERID, USERPASS, 'account.account', 'read', ids, ['parent_id','parent_left','parent_right'])
accounts = dict(map(lambda x: (x['id'],x), account_lists))
for a in account_lists:
if a['parent_id']:
assert a['parent_left'] > accounts[a['parent_id'][0]]['parent_left']
assert a['parent_right'] < accounts[a['parent_id'][0]]['parent_right']
assert a['parent_left'] < a['parent_right']
for a2 in account_lists:
assert not ((a2['parent_right']>a['parent_left']) and
(a2['parent_left']<a['parent_left']) and
(a2['parent_right']<a['parent_right']))
if a2['parent_id']==a['id']:
assert (a2['parent_left']>a['parent_left']) and (a2['parent_right']<a['parent_right'])
print 'Tests Ok'

View File

@ -1,12 +1,5 @@
- |
In order to test the Preorder Traversal Tree algorythm to organize tree
structure, we retrieve all accounts and test their parent_left and
parent_right values with the following assertions
. parent_left < parent_right
. parent_left < parent_left of all childs
. parent_right > parent_right of all childs
. if an account is a child it is included in parent_left-parent_right
. if an account is not a child it is not included in parent_left-parent_right
-
We retrieve all accounts and test they are in a tree data structure.
-
!python {model: account.account}: |
ids = self.search(cr, uid, [])

View File

@ -7,13 +7,13 @@ msgstr ""
"Project-Id-Version: OpenERP Server 5.0.4\n"
"Report-Msgid-Bugs-To: support@openerp.com\n"
"POT-Creation-Date: 2009-08-28 16:01+0000\n"
"PO-Revision-Date: 2010-04-07 22:24+0000\n"
"Last-Translator: mitev.dmitry <Unknown>\n"
"PO-Revision-Date: 2009-02-03 06:24+0000\n"
"Last-Translator: <>\n"
"Language-Team: \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Launchpad-Export-Date: 2010-04-08 07:18+0000\n"
"X-Launchpad-Export-Date: 2010-03-30 04:07+0000\n"
"X-Generator: Launchpad (build Unknown)\n"
#. module: account_payment
@ -46,7 +46,7 @@ msgstr ""
#: field:payment.line,info_owner:0
#: view:payment.order:0
msgid "Owner Account"
msgstr "Majitel účtu"
msgstr ""
#. module: account_payment
#: help:account.invoice,amount_to_pay:0
@ -65,17 +65,17 @@ msgstr ""
#. module: account_payment
#: field:payment.order,date_prefered:0
msgid "Preferred date"
msgstr "Preferované datum"
msgstr ""
#. module: account_payment
#: selection:payment.line,state:0
msgid "Free"
msgstr "Volný"
msgstr ""
#. module: account_payment
#: wizard_field:populate_payment,search,entries:0
msgid "Entries"
msgstr "Příspěvky"
msgstr ""
#. module: account_payment
#: wizard_field:populate_payment,init,duedate:0
@ -96,7 +96,7 @@ msgstr ""
#: rml:payment.order:0
#: view:payment.order:0
msgid "Amount"
msgstr "Částka"
msgstr ""
#. module: account_payment
#: rml:payment.order:0
@ -111,7 +111,7 @@ msgstr ""
#. module: account_payment
#: selection:payment.order,state:0
msgid "Cancelled"
msgstr "Zrušeno"
msgstr ""
#. module: account_payment
#: model:ir.actions.act_window,name:account_payment.action_payment_order_tree_new
@ -123,7 +123,7 @@ msgstr ""
#: rml:payment.order:0
#: field:payment.order,reference:0
msgid "Reference"
msgstr "Odkaz"
msgstr ""
#. module: account_payment
#: model:ir.actions.act_window,name:account_payment.action_payment_order_tree
@ -134,7 +134,7 @@ msgstr ""
#. module: account_payment
#: selection:payment.order,date_prefered:0
msgid "Directly"
msgstr "Přímo"
msgstr ""
#. module: account_payment
#: model:ir.actions.act_window,name:account_payment.action_payment_line_form
@ -157,7 +157,7 @@ msgstr ""
#. module: account_payment
#: selection:payment.order,state:0
msgid "Confirmed"
msgstr "Potvrzeno"
msgstr ""
#. module: account_payment
#: help:payment.line,ml_date_created:0
@ -177,12 +177,12 @@ msgstr ""
#. module: account_payment
#: selection:payment.line,state:0
msgid "Structured"
msgstr "Strukturované"
msgstr ""
#. module: account_payment
#: field:payment.order,state:0
msgid "State"
msgstr "Stav"
msgstr ""
#. module: account_payment
#: view:payment.line:0
@ -223,17 +223,17 @@ msgstr ""
#. module: account_payment
#: field:payment.order,date_done:0
msgid "Execution date"
msgstr "Datum představení"
msgstr ""
#. module: account_payment
#: selection:payment.order,date_prefered:0
msgid "Fixed date"
msgstr "Pevné datum"
msgstr ""
#. module: account_payment
#: field:payment.line,info_partner:0
msgid "Destination Account"
msgstr "Protiúčet"
msgstr ""
#. module: account_payment
#: view:payment.line:0
@ -251,12 +251,12 @@ msgstr ""
#: wizard_button:populate_payment,search,end:0
#: wizard_button:populate_statement,init,end:0
msgid "_Cancel"
msgstr "Zrušit"
msgstr ""
#. module: account_payment
#: field:payment.line,create_date:0
msgid "Created"
msgstr "Vytvořeno"
msgstr ""
#. module: account_payment
#: view:payment.line:0
@ -281,12 +281,12 @@ msgstr ""
#. module: account_payment
#: field:payment.line,communication:0
msgid "Communication"
msgstr "Komunikace"
msgstr ""
#. module: account_payment
#: selection:payment.order,date_prefered:0
msgid "Due date"
msgstr "Termín dokončení"
msgstr ""
#. module: account_payment
#: field:account.invoice,amount_to_pay:0
@ -307,7 +307,7 @@ msgstr ""
#: view:payment.type:0
#: help:payment.type,name:0
msgid "Payment Type"
msgstr "Typ platby"
msgstr ""
#. module: account_payment
#: help:payment.line,amount_currency:0

View File

@ -7,19 +7,19 @@ msgstr ""
"Project-Id-Version: OpenERP Server 5.0.4\n"
"Report-Msgid-Bugs-To: support@openerp.com\n"
"POT-Creation-Date: 2009-08-28 16:01+0000\n"
"PO-Revision-Date: 2010-04-07 08:27+0000\n"
"Last-Translator: iTuxer <Unknown>\n"
"PO-Revision-Date: 2009-02-03 12:33+0000\n"
"Last-Translator: Fabien (Open ERP) <fp@tinyerp.com>\n"
"Language-Team: \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Launchpad-Export-Date: 2010-04-08 07:18+0000\n"
"X-Launchpad-Export-Date: 2010-03-30 04:13+0000\n"
"X-Generator: Launchpad (build Unknown)\n"
#. module: audittrail
#: model:ir.module.module,shortdesc:audittrail.module_meta_information
msgid "Audit Trail"
msgstr "Audit Trail"
msgstr ""
#. module: audittrail
#: constraint:ir.model:0
@ -32,22 +32,22 @@ msgstr ""
#. module: audittrail
#: field:audittrail.log.line,log_id:0
msgid "Log"
msgstr "Log"
msgstr ""
#. module: audittrail
#: selection:audittrail.rule,state:0
msgid "Subscribed"
msgstr "Iscritto"
msgstr ""
#. module: audittrail
#: view:audittrail.log:0
msgid "Old Value : "
msgstr "Valore precendente : "
msgstr ""
#. module: audittrail
#: selection:audittrail.log,method:0
msgid "Create"
msgstr "Crea"
msgstr ""
#. module: audittrail
#: wizard_view:audittrail.view.log,init:0
@ -67,7 +67,7 @@ msgstr ""
#. module: audittrail
#: field:audittrail.log.line,old_value:0
msgid "Old Value"
msgstr "Valore precedente"
msgstr ""
#. module: audittrail
#: constraint:ir.actions.act_window:0

View File

@ -14,7 +14,7 @@ msgstr ""
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Launchpad-Export-Date: 2010-04-08 07:18+0000\n"
"X-Launchpad-Export-Date: 2010-04-07 03:46+0000\n"
"X-Generator: Launchpad (build Unknown)\n"
#. module: base_contact

View File

@ -1,283 +0,0 @@
# Persian translation for openobject-addons
# Copyright (c) 2010 Rosetta Contributors and Canonical Ltd 2010
# This file is distributed under the same license as the openobject-addons package.
# FIRST AUTHOR <EMAIL@ADDRESS>, 2010.
#
msgid ""
msgstr ""
"Project-Id-Version: openobject-addons\n"
"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
"POT-Creation-Date: 2009-08-28 16:01+0000\n"
"PO-Revision-Date: 2010-04-08 14:27+0000\n"
"Last-Translator: Sadegh Ismael Nattaj <nat@sethack.com>\n"
"Language-Team: Persian <fa@li.org>\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Launchpad-Export-Date: 2010-04-09 03:56+0000\n"
"X-Generator: Launchpad (build Unknown)\n"
#. module: base_setup
#: wizard_field:base_setup.base_setup,company,city:0
#: wizard_field:base_setup.base_setup,init,city:0
#: wizard_field:base_setup.base_setup,update,city:0
msgid "City"
msgstr "شهر"
#. module: base_setup
#: wizard_view:base_setup.base_setup,finish:0
msgid ""
"You can start configuring the system or connect directly to the database "
"using the default setup."
msgstr ""
"شما می‌توانید با بکارگیری از سوارسازی پیش‌فرض آغاز به پیکربندی سامانه کنید و "
"یا یک‌راست به دادگان متصل شوید."
#. module: base_setup
#: wizard_field:base_setup.base_setup,company,zip:0
#: wizard_field:base_setup.base_setup,init,zip:0
#: wizard_field:base_setup.base_setup,update,zip:0
msgid "Zip code"
msgstr "کد پستی"
#. module: base_setup
#: wizard_view:base_setup.base_setup,init:0
msgid "Select a Profile"
msgstr "یک پروفایل را برگزینید"
#. module: base_setup
#: wizard_view:base_setup.base_setup,company:0
msgid "Report header"
msgstr "سرنویس گزارش"
#. module: base_setup
#: wizard_button:base_setup.base_setup,finish,config:0
msgid "Start Configuration"
msgstr "آغاز پیکربندی"
#. module: base_setup
#: wizard_view:base_setup.base_setup,init:0
msgid ""
"You'll be able to install more modules later through the Administration menu."
msgstr ""
"شما می‌توانید از طریق منوی راهبری پیمانه‌های بیشتری را در آینده برپاسازی "
"نمایید."
#. module: base_setup
#: wizard_view:base_setup.base_setup,init:0
msgid ""
"A profile sets a pre-selection of modules for specific needs. These profiles "
"have been setup to help you discover the different aspects of OpenERP. This "
"is just an overview, we have 300+ available modules."
msgstr ""
"یک پروفایل دارای پیمانه‌های از پیش گزینش شده برای نیازهای خاص است. این "
"پروفایل‌ها برای این سوار می‌شوند تا به شما برای شناخت بیشتر جنبه‌های متفاوت "
"اپن ای‌آر‌پی کمک نماید. این تنها یک پیش‌نمایش است، ما بیش از ۳۰۰ پیمانه "
"آماده داریم."
#. module: base_setup
#: wizard_button:base_setup.base_setup,company,update:0
#: wizard_button:base_setup.base_setup,init,company:0
msgid "Next"
msgstr "پس"
#. module: base_setup
#: wizard_field:base_setup.base_setup,company,email:0
#: wizard_field:base_setup.base_setup,init,email:0
#: wizard_field:base_setup.base_setup,update,email:0
msgid "E-mail"
msgstr "ایمیل"
#. module: base_setup
#: wizard_field:base_setup.base_setup,company,state_id:0
#: wizard_field:base_setup.base_setup,init,state_id:0
#: wizard_field:base_setup.base_setup,update,state_id:0
msgid "State"
msgstr "استان"
#. module: base_setup
#: wizard_view:base_setup.base_setup,finish:0
msgid "Your new database is now fully installed."
msgstr "دادگان نو شما بطور کامل برپاسازی گردید."
#. module: base_setup
#: wizard_field:base_setup.base_setup,company,profile:0
#: wizard_field:base_setup.base_setup,init,profile:0
#: wizard_field:base_setup.base_setup,update,profile:0
msgid "Profile"
msgstr "پروفایل"
#. module: base_setup
#: wizard_field:base_setup.base_setup,company,rml_footer1:0
#: wizard_field:base_setup.base_setup,init,rml_footer1:0
#: wizard_field:base_setup.base_setup,update,rml_footer1:0
msgid "Report Footer 1"
msgstr "پانویس گزارش ۱"
#. module: base_setup
#: wizard_field:base_setup.base_setup,company,rml_footer2:0
#: wizard_field:base_setup.base_setup,init,rml_footer2:0
#: wizard_field:base_setup.base_setup,update,rml_footer2:0
msgid "Report Footer 2"
msgstr "پانویس گزارش ۲"
#. module: base_setup
#: wizard_view:base_setup.base_setup,company:0
msgid "General Information"
msgstr "آگهگان عمومی"
#. module: base_setup
#: wizard_field:base_setup.base_setup,company,street2:0
#: wizard_field:base_setup.base_setup,init,street2:0
#: wizard_field:base_setup.base_setup,update,street2:0
msgid "Street2"
msgstr "خیابان۲"
#. module: base_setup
#: wizard_view:base_setup.base_setup,company:0
msgid "Report Information"
msgstr "آگهگان گزارش"
#. module: base_setup
#: wizard_field:base_setup.base_setup,company,phone:0
#: wizard_field:base_setup.base_setup,init,phone:0
#: wizard_field:base_setup.base_setup,update,phone:0
msgid "Phone"
msgstr "تلفن"
#. module: base_setup
#: wizard_view:base_setup.base_setup,company:0
msgid "Define Main Company"
msgstr "تعریف شرکت اصلی"
#. module: base_setup
#: wizard_field:base_setup.base_setup,company,name:0
#: wizard_field:base_setup.base_setup,init,name:0
#: wizard_field:base_setup.base_setup,update,name:0
msgid "Company Name"
msgstr "نام شرکت"
#. module: base_setup
#: help:base_setup.base_setup,company,rml_footer2:0
#: help:base_setup.base_setup,init,rml_footer2:0
#: help:base_setup.base_setup,update,rml_footer2:0
msgid ""
"This sentence will appear at the bottom of your reports.\n"
"We suggest you to put bank information here:\n"
"IBAN: BE74 1262 0121 6907 - SWIFT: CPDF BE71 - VAT: BE0477.472.701"
msgstr ""
"این جمله در پایین گزارش‌های شما ظاهر خواهد شد.\n"
"پیشنهاد می‌کنیم آگهگان بانکی را اینجا وارد نمایید:\n"
"IBAN: BE74 1262 0121 6907 - SWIFT: CPDF BE71 - VAT: BE0477.472.701"
#. module: base_setup
#: wizard_field:base_setup.base_setup,company,country_id:0
#: wizard_field:base_setup.base_setup,init,country_id:0
#: wizard_field:base_setup.base_setup,update,country_id:0
msgid "Country"
msgstr "کشور"
#. module: base_setup
#: wizard_view:base_setup.base_setup,company:0
#: wizard_view:base_setup.base_setup,finish:0
#: wizard_view:base_setup.base_setup,init:0
#: wizard_view:base_setup.base_setup,update:0
#: model:ir.actions.wizard,name:base_setup.action_wizard_setup
#: model:ir.actions.wizard,name:base_setup.wizard_base_setup
msgid "Setup"
msgstr "سوارکردن"
#. module: base_setup
#: help:base_setup.base_setup,company,rml_footer1:0
#: help:base_setup.base_setup,init,rml_footer1:0
#: help:base_setup.base_setup,update,rml_footer1:0
msgid ""
"This sentence will appear at the bottom of your reports.\n"
"We suggest you to write legal sentences here:\n"
"Web: http://openerp.com - Fax: +32.81.73.35.01 - Fortis Bank: 126-2013269-07"
msgstr ""
"این جمله در پایین گزارش‌های شما ظاهر خواهد شد.\n"
"پیشنهاد می‌کنیم تا از عبارات قانونی در اینجا بکار ببرید:\n"
"Web: http://openerp.com - Fax: +32.81.73.35.01 - Fortis Bank: 126-2013269-07"
#. module: base_setup
#: wizard_view:base_setup.base_setup,update:0
msgid "Summary"
msgstr "چکیده"
#. module: base_setup
#: wizard_button:base_setup.base_setup,update,finish:0
msgid "Install"
msgstr "برپایی"
#. module: base_setup
#: wizard_view:base_setup.base_setup,finish:0
msgid "Installation Done"
msgstr "برپایی انجام شد"
#. module: base_setup
#: help:base_setup.base_setup,company,rml_header1:0
#: help:base_setup.base_setup,init,rml_header1:0
#: help:base_setup.base_setup,update,rml_header1:0
msgid ""
"This sentence will appear at the top right corner of your reports.\n"
"We suggest you to put a slogan here:\n"
"\"Open Source Business Solutions\"."
msgstr ""
"این جمله در گوشه بالا سمت راست گزارش‌های شما ظاهر خواهد شد.\n"
"پیشنهاد می‌کنیم شعار خود را اینجا قرار دهید:\n"
"\"راهکارهای بازمتن برای تجارت\"."
#. module: base_setup
#: wizard_field:base_setup.base_setup,company,rml_header1:0
#: wizard_field:base_setup.base_setup,init,rml_header1:0
#: wizard_field:base_setup.base_setup,update,rml_header1:0
msgid "Report Header"
msgstr "سرنویس گزارش"
#. module: base_setup
#: wizard_view:base_setup.base_setup,company:0
msgid "Your Logo - Use a size of about 450x150 pixels."
msgstr "نشان شما - اندازه تصویری ۱۵۰×۴۵۰ پیکسل را بکار برید."
#. module: base_setup
#: wizard_field:base_setup.base_setup,company,currency:0
#: wizard_field:base_setup.base_setup,init,currency:0
#: wizard_field:base_setup.base_setup,update,currency:0
msgid "Currency"
msgstr "ارز"
#. module: base_setup
#: wizard_field:base_setup.base_setup,company,street:0
#: wizard_field:base_setup.base_setup,init,street:0
#: wizard_field:base_setup.base_setup,update,street:0
msgid "Street"
msgstr "خیابان"
#. module: base_setup
#: wizard_button:base_setup.base_setup,finish,menu:0
msgid "Use Directly"
msgstr "بکارگیری آنی"
#. module: base_setup
#: wizard_button:base_setup.base_setup,init,menu:0
msgid "Cancel"
msgstr "لغو"
#. module: base_setup
#: wizard_field:base_setup.base_setup,company,logo:0
#: wizard_field:base_setup.base_setup,init,logo:0
#: wizard_field:base_setup.base_setup,update,logo:0
msgid "Logo"
msgstr "نشان"
#. module: base_setup
#: model:ir.module.module,shortdesc:base_setup.module_meta_information
msgid "Base Setup"
msgstr "سوارکردن پایه"
#. module: base_setup
#: wizard_button:base_setup.base_setup,company,init:0
#: wizard_button:base_setup.base_setup,update,company:0
msgid "Previous"
msgstr "پیش"

View File

@ -13,7 +13,6 @@
<field name="view_type">form</field>
<field name="view_mode">tree,calendar,form,graph</field>
<field name="view_id" ref="crm_case_claims_tree_view"/>
<field name="context">{"search_default_section_id":section_id,"search_default_current":1,"search_default_my_claims":1}</field>
<field name="search_view_id" ref="crm.view_crm_case_claims_filter"/>
</record>

View File

@ -161,7 +161,7 @@
<separator string="Action Information" colspan="4"/>
<field name="name" colspan="4"/>
<field name="date"/>
<field name="user_id"/>
<field name="user_id"/>
</form>
</field>
</page>
@ -183,7 +183,7 @@
<newline/>
<field name="description" colspan="4" nolabel="1"/>
<button colspan="4"
string="Reply to Email"
string="Reply to Last Email"
name="%(action_crm_send_mail)d"
context="{'mail':'reply', 'model': 'crm.claim'}"
icon="gtk-undo" type="action" />
@ -245,9 +245,9 @@
<field name="type">search</field>
<field name="arch" type="xml">
<search string="Search Claims">
<filter icon="gtk-new" string="Current" name="current"
<filter icon="gtk-new" string="Current"
domain="[('state','in',('draft', 'open'))]"
separator="1" help="Current Claims"
separator="1" help="Current Claims" default="1"
/>
<filter icon="gtk-execute"
string="In Progress"
@ -263,14 +263,16 @@
<field name="name" select='1'/>
<field name="partner_id" select="1"/>
<field name="user_id" select="1" widget="selection">
<filter icon="terp-partner" name="my_claims"
domain="[('user_id','=',uid)]" help="My Claims"/>
<filter icon="terp-partner"
domain="[('user_id','=',uid)]" help="My Claims"
default="1" />
<filter icon="terp-partner"
domain="[('user_id','=', False)]"
help="Unassigned Claims" />
</field>
<field name="section_id" select="1"
widget="selection">
widget="selection"
default="context.get('section_id', False)">
<filter icon="terp-crm"
domain="[('section_id','=',context.get('section_id',False))]"
help="My section" />

View File

@ -12,7 +12,6 @@
<field name="res_model">crm.fundraising</field>
<field name="view_mode">tree,form,graph</field>
<field name="view_id" ref="crm.crm_case_tree_view_fund"/>
<field name="context">{"search_default_my_funds":1,"search_default_section_id":section_id}</field>
<field name="search_view_id" ref="crm.view_crm_case_fund_filter"/>
</record>

View File

@ -169,7 +169,7 @@
<separator string="Action Information" colspan="4"/>
<field name="name" colspan="4"/>
<field name="date"/>
<field name="user_id"/>
<field name="user_id"/>
</form>
</field>
</page>
@ -181,8 +181,8 @@
<form string="Communication history">
<group col="7" colspan="4">
<field name="date"/>
<field name="email_to"/>
<field name="email_from"/>
<field name="email_to"/>
<field name="email_from"/>
<button
string="Add a CC"
name="%(crm.action_view_crm_email_add_cc_wizard)d"
@ -191,7 +191,7 @@
<newline/>
<field name="description" colspan="4" nolabel="1"/>
<button colspan="4"
string="Reply to Email"
string="Reply to Last Email"
name="%(action_crm_send_mail)d"
context="{'mail':'reply', 'model': 'crm.fundraising'}"
icon="gtk-undo" type="action" />
@ -252,7 +252,7 @@
<search string="Search Funds">
<group col='6' colspan='4'>
<filter icon="terp-partner" string="My Funds"
name="my_funds" domain="[('user_id','=',uid)]"
default="1" domain="[('user_id','=',uid)]"
separator="1"
help="Funds Related to Current User"
/>
@ -277,7 +277,9 @@
domain="[('user_id','=', False)]"
help="Unassigned" />
</field>
<field name="section_id" select="1" widget="selection" string="Section">
<field name="section_id" select="1"
widget="selection"
default="context.get('section_id', False)">
<filter icon="terp-crm"
domain="[('section_id','=',context.get('section_id',False))]"
help="My section" />

View File

@ -11,7 +11,6 @@
<field name="res_model">crm.helpdesk</field>
<field name="view_mode">tree,calendar,form</field>
<field name="view_id" ref="crm_case_tree_view_helpdesk"/>
<field name="context">{"search_default_my_hd_request":1,"search_default_section_id":section_id}</field>
<field name="search_view_id" ref="crm.view_crm_case_helpdesk_filter"/>
</record>

View File

@ -126,7 +126,7 @@
<newline/>
<field name="description" colspan="4" nolabel="1"/>
<button colspan="4"
string="Reply to Email"
string="Reply to Last Email"
name="%(action_crm_send_mail)d"
context="{'mail':'reply', 'model': 'crm.helpdesk'}"
icon="gtk-undo" type="action" />
@ -223,10 +223,13 @@
<field name="name" select='1' string="Query"/>
<field name="partner_id" />
<field name="user_id" select="1" widget="selection">
<filter icon="terp-partner" name="my_hd_request"
domain="[('user_id','=',uid)]" help="My Helpdesk Requests"/>
<filter icon="terp-partner"
domain="[('user_id','=',uid)]"
help="My Helpdesk Requests" default="1" />
</field>
<field name="section_id" select="1" widget="selection" string="Section">
<field name="section_id"
default="context.get('section_id', False)" select="1"
widget="selection" string="Section">
<filter icon="terp-crm"
domain="[('section_id','=',context.get('section_id',False))]"
help="My section" />

View File

@ -7,8 +7,6 @@
<field name="res_model">crm.lead</field>
<field name="view_mode">tree,form</field>
<field name="view_id" ref="crm_case_tree_view_leads"/>
<field name="context">{"search_default_current":1,"search_default_my_lead":1,"search_default_section_id":section_id}</field>
<field name="context">{"search_default_current":1,"search_default_my_lead":1,"search_default_section_id":section_id}</field>
<field name="search_view_id" ref="crm.view_crm_case_leads_filter"/>
</record>
<record model="ir.actions.act_window.view" id="action_crm_tag_tree_view_leads_all">

View File

@ -166,7 +166,7 @@
<newline/>
<field name="description" colspan="4" nolabel="1"/>
<button colspan="4"
string="Reply to Email"
string="Reply to Last Email"
name="%(action_crm_send_mail)d"
context="{'mail':'reply', 'model': 'crm.lead'}"
icon="gtk-undo" type="action" />
@ -262,8 +262,9 @@
<field name="type">search</field>
<field name="arch" type="xml">
<search string="Search Leads">
<filter icon="terp-project" name="current"
<filter icon="terp-project"
string="Current"
default="1"
domain="[('state','in',('draft','open'))]"/>
<filter icon="terp-project"
string="Open"
@ -288,13 +289,13 @@
<field name="user_id" widget="selection">
<filter icon="terp-partner"
domain="[('user_id','=',uid)]"
help="My Leads" name="my_lead"
help="My Leads" default="1"
/>
<filter icon="terp-partner"
domain="[('user_id','=', False)]"
help="Unassigned Leads" />
</field>
<field name="section_id" widget="selection"
<field name="section_id" default="context.get('section_id', False)" widget="selection"
context="{'invisible_section': False}">
<filter icon="terp-crm"
context="{'invisible_section': False}"

View File

@ -36,14 +36,14 @@
<field name="view_id" ref="crm_case_form_view_meet"/>
<field name="act_window_id" ref="crm_case_categ_meet_create_partner"/>
</record>
<record model="ir.actions.act_window.view" id="action_crm_tag_gantt_meet_partner">
<record model="ir.actions.act_window.view" id="action_crm_tag_gantt_meet_partner">
<field name="sequence" eval="3"/>
<field name="view_mode">gantt</field>
<field name="view_id" ref="crm_case_gantt_view_meet"/>
<field name="act_window_id" ref="crm_case_categ_meet_create_partner"/>
</record>
<act_window
<act_window
id="crm_case_categ_meet_case"
name="Schedule a Meeting"
res_model="crm.meeting"
@ -74,7 +74,7 @@
<field name="view_id" ref="crm_case_form_view_meet"/>
<field name="act_window_id" ref="crm_case_categ_meet_case"/>
</record>
<record model="ir.actions.act_window.view" id="action_crm_tag_gantt_meet_case">
<record model="ir.actions.act_window.view" id="action_crm_tag_gantt_meet_case">
<field name="sequence" eval="3"/>
<field name="view_mode">gantt</field>
<field name="view_id" ref="crm_case_gantt_view_meet"/>
@ -85,7 +85,6 @@
<field name="res_model">crm.meeting</field>
<field name="view_mode">calendar,tree,form,gantt</field>
<field name="view_id" ref="crm_case_calendar_view_meet"/>
<field name="context">{"search_default_current":1,"search_default_section_id":section_id}</field>
<field name="search_view_id" ref="view_crm_case_meetings_filter"/>
</record>
<record model="ir.actions.act_window.view" id="action_crm_tag_calendar_meet">
@ -116,27 +115,26 @@
<!-- ALL MEETINGS -->
<menuitem name="Meetings" id="menu_meeting_sale"
parent="base.menu_base_partner" sequence="3" />
parent="base.menu_base_partner" sequence="3" />
<menuitem name="Meetings" id="menu_crm_case_categ_meet"
action="crm_case_categ_meet" parent="menu_meeting_sale"
sequence="1" />
action="crm_case_categ_meet" parent="menu_meeting_sale"
sequence="1" />
<record id="action_view_attendee_form" model="ir.actions.act_window">
<field name="name">Meeting Invitations</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">calendar.attendee</field>
<field name="view_type">form</field>
<field name="view_mode">tree,form</field>
<field name="view_id" ref="base_calendar.base_calendar_attendee_tree_view" />
<field name="name">Meeting Invitations</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">calendar.attendee</field>
<field name="view_type">form</field>
<field name="view_mode">tree,form</field>
<field name="view_id" ref="base_calendar.base_calendar_attendee_tree_view" />
<field name="domain">[('ref','like','crm.meeting,')]</field>
<field name="context">{'default_sent_by_uid': uid}</field>
</record>
<field name="context">{'default_sent_by_uid': uid}</field>
</record>
<menuitem id="menu_attendee_invitations"
name="Meeting Invitations" parent="crm.menu_meeting_sale"
groups="base.group_extended"
sequence="10" action="action_view_attendee_form" />
name="Meeting Invitations" parent="crm.menu_meeting_sale"
sequence="10" action="action_view_attendee_form" />
<record model="ir.actions.act_window" id="crm_case_category_act_meetall3">
@ -146,7 +144,7 @@
<field name="view_mode">tree,calendar,form,gantt</field>
<field name="view_id" ref="crm_case_calendar_view_meet"/>
<field name="domain"
eval="[('state','in',('pending','draft','open')),('date','>=',time.strftime('%Y-%m-%d'))]" />
eval="[('state','in',('pending','draft','open')),('date','>=',time.strftime('%Y-%m-%d'))]" />
</record>
<record model="ir.actions.act_window.view" id="action_crm_tag_calendar_view_meetall3">
@ -170,7 +168,7 @@
<field name="act_window_id" ref="crm_case_category_act_meetall3"/>
</record>
<record model="ir.actions.act_window.view" id="action_crm_tag_gantt_view_meetall3">
<record model="ir.actions.act_window.view" id="action_crm_tag_gantt_view_meetall3">
<field name="sequence" eval="2"/>
<field name="view_mode">gantt</field>
<field name="view_id" ref="crm_case_gantt_view_meet"/>

View File

@ -259,13 +259,17 @@
<filter icon="terp-crm" string="My Meetings"
domain="[('user_id','=',uid)]"
help="My Meetings" />
<filter icon="terp-crm" name="current" string="Current"
domain="[('state','in',('draft', 'open'))]"
help="Current Meetings"/>
<filter icon="terp-crm" string="Current"
domain="[('state','in',('draft', 'open'))]"
default="1" help="Current Meetings" />
<filter icon="terp-crm" string="Confirmed"
domain="[('state','=','done')]"
help="Confirmed Meetings" />
<separator orientation="vertical"/>
<field name="name" select="1" string="Subject"/>
<field name="partner_id" select="1" />
<field name="section_id"
default="context.get('section_id', False)"
select="1" widget="selection">
<filter icon="terp-crm"
domain="[('section_id','=',context.get('section_id',False))]"

View File

@ -88,7 +88,7 @@ class crm_opportunity(osv.osv):
resource_id = False
if opportunity.user_id:
resource_ids = res_obj.search(cr, uid, [('user_id','=',opportunity.user_id.id)])
resource_id = len(resource_ids) and resource_ids[0] or False
resource_id = len(resource_ids) or resource_ids[0]
duration = float(ans.days)
if opportunity.section_id.resource_calendar_id:

View File

@ -27,7 +27,6 @@
<field name="res_model">crm.opportunity</field>
<field name="view_mode">tree,form,graph</field>
<field name="view_id" ref="crm_case_tree_view_oppor"/>
<field name="context">{"search_default_my_oprtnit":1,"search_default_new_oprtnit":1,"search_default_section_id":section_id}</field>
<field name="search_view_id" ref="crm.view_crm_case_opportunities_filter"/>
</record>
<record model="ir.actions.act_window.view" id="action_crm_tag_tree_view_oppor11">

View File

@ -82,19 +82,21 @@
</group>
<notebook colspan="4">
<page string="Opportunity">
<group col="4" colspan="2">
<group col="3" colspan="2">
<separator colspan="4" string="Contacts"/>
<field name="partner_id" select="1"
on_change="onchange_partner_id(partner_id, email_from)" />
on_change="onchange_partner_id(partner_id, email_from)"
colspan="2" />
<field name="partner_address_id"
string="Contact"
on_change="onchange_partner_address_id(partner_address_id, email_from)"/>
on_change="onchange_partner_address_id(partner_address_id, email_from)"
colspan="1" />
<field name="email_from" string="Email" />
<field name="phone"/>
</group>
<group col="2" colspan="2">
<separator colspan="2" string="Categorization"/>
<field name="type_id" select="1" string="Campaign" groups="base.group_extended"/>
<field name="type_id" select="1" string="Campaign"/>
<field name="section_id" colspan="1" widget="selection"/>
<field name="priority" string="Priority"/>
<field name="categ_id" select="1"
@ -102,7 +104,7 @@
domain="[('object_id.model', '=', 'crm.opportunity')]" />
</group>
<separator colspan="4" string="Notes"/>
<separator colspan="4" string="Details"/>
<field name="description" nolabel="1" colspan="4"/>
<separator colspan="4"/>
@ -213,9 +215,9 @@
<button name="stage_next" string="Next"
states="open,pending" type="object"
icon="gtk-go-forward" />
<field name="planned_revenue" sum="Expected Revenue"/>
<field name="planned_revenue" sum="Total of Planned Revenue"/>
<field name="probability" widget="progressbar" avg="Avg. of Probability"/>
<field name="date_deadline" string="Expected Closing"/>
<field name="date_deadline" string="Excepted Closing"/>
<field name="section_id"/>
<field name="user_id"/>
<field name="priority"/>
@ -261,6 +263,7 @@
<search string="Search Opportunities">
<filter icon="terp-project"
string="Current"
default="1"
domain="[('state','in',('draft','open'))]"/>
<filter icon="terp-project"
string="Open"
@ -281,15 +284,16 @@
<field name="name" string="Opportunity"/>
<field name="partner_id"/>
<field name="user_id" widget="selection">
<filter icon="terp-partner" name="my_oprtnit"
<filter icon="terp-partner"
domain="[('user_id','=',uid)]"
help="My Opportunities" />
help="My Opportunities" default="1"
/>
<filter icon="terp-partner"
domain="[('user_id','=', False)]"
help="Unassigned Opportunities" />
</field>
<field name="section_id"
select="1"
default="context.get('section_id', False)" select="1"
widget="selection">
<filter icon="terp-crm"
domain="[('section_id','=',context.get('section_id',False))]"

View File

@ -20,7 +20,6 @@
<field name="view_type">form</field>
<field name="view_mode">tree,calendar</field>
<field name="view_id" ref="crm_case_phone_tree_view"/>
<field name="context">{"set_editable":True,"default_state":'open',"search_default_my_calls":1,"search_default_state":1,"search_default_section_id":section_id}</field>
<field name="search_view_id" ref="crm.view_crm_case_phonecalls_filter"/>
</record>
@ -55,7 +54,7 @@
<field name="view_mode">tree,calendar</field>
<field name="view_id" ref="crm_case_phone_tree_view"/>
<field name="domain" eval="'[(\'categ_id\',\'=\','+str(ref('categ_phone1'))+')]'"/>
<field name="context">{"default_state":'open',"search_default_my_calls":1,"search_default_state":1,"search_default_section_id":section_id}</field>
<field name="context">{'set_editable':True,'default_state':'open'}</field>
<field name="search_view_id" ref="crm.view_crm_case_phonecalls_filter"/>
</record>

View File

@ -176,15 +176,16 @@
<field name="name" string="Call Summary"/>
<field name="partner_id"/>
<field name="user_id" widget="selection">
<filter icon="terp-partner" name="my_calls"
domain="[('user_id','=',uid)]"
help="My Phonecalls"/>
<filter icon="terp-partner"
domain="[('user_id','=',uid)]" help="My Phonecalls"
default="1" />
<filter icon="terp-partner"
domain="[('user_id','=',False)]"
help="Unassigned Phonecalls" />
</field>
<field name="section_id"
select="1" widget="selection" string="Section">
default="context.get('section_id', False)" select="1"
widget="selection" string="Section">
<filter icon="terp-crm"
domain="[('section_id','=',context.get('section_id',False))]"
help="My section" />

View File

@ -78,6 +78,7 @@
help="Cases by Section and Type for this month" />
<separator orientation="vertical"/>
<field name="section_id"
default="context.get('section_id', False)"
select="1" widget="selection" />
<field name="category2_id" select="1"/>
<field name="nbr" select="1"/>

View File

@ -364,7 +364,7 @@
<separator colspan="4" string="Action Information"/>
<field colspan="4" name="name"/>
<field name="date" select="2"/>
<field name="user_id" select="2"/>
<field name="user_id" select="2"/>
</form>
</field>
</page>
@ -377,7 +377,7 @@
<group col="7" colspan="4">
<field name="date"/>
<field name="email_to"/>
<field name="email_from"/>
<field name="email_from"/>
<button
string="Add a CC"
name="%(crm.action_view_crm_email_add_cc_wizard)d"
@ -386,7 +386,7 @@
<newline/>
<field name="description" colspan="4" nolabel="1"/>
<button colspan="4"
string="Reply to Email"
string="Reply to Last Email"
name="%(action_crm_send_mail)d"
context="{'mail':'reply', 'model': 'crm.case'}"
icon="gtk-undo" type="action" />
@ -418,7 +418,7 @@
<group col='6' colspan='4'>
<filter icon="terp-partner" string="My Cases"
domain="[('user_id','=',uid)]" separator="1"
help="Cases Related to Current User" />
default="1" help="Cases Related to Current User" />
<field name="state" select="1">
<filter icon="gtk-new"
domain="[('state','in',('draft', 'open'))]"
@ -435,7 +435,8 @@
widget="selection" />
</group>
<field name="section_id"
select="1" widget="selection" string="Section"/>
default="context.get('section_id', False)" select="1"
widget="selection"/>
</search>
</field>
</record>
@ -510,6 +511,7 @@
<field name="date" select="1"/>
<field name="user_id" select="1" widget="selection"/>
<field name="section_id"
default="context.get('section_id', False)"
select="1" widget="selection"/>
</group>
</search>

View File

@ -14,7 +14,7 @@ msgstr ""
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Launchpad-Export-Date: 2010-04-08 07:18+0000\n"
"X-Launchpad-Export-Date: 2010-04-07 03:46+0000\n"
"X-Generator: Launchpad (build Unknown)\n"
#. module: crm

View File

@ -83,7 +83,6 @@
<field name="view_type">form</field>
<field name="view_mode">tree,graph</field>
<field name="view_id" ref="view_report_crm_claim_tree"/>
<field name="context">{"search_default_section_id":section_id,"search_default_this_year":1,"search_default_this_month":1,"search_default_by_user":1}</field>
<field name="search_view_id" ref="view_report_crm_claim_filter"/>
</record>

View File

@ -80,7 +80,6 @@
<field name="view_type">form</field>
<field name="view_mode">tree,graph</field>
<field name="view_id" ref="view_report_crm_fundraising_tree"/>
<field name="context">{"search_default_section_id":section_id,"search_default_this_year":1,"search_default_this_month":1,"search_default_by_user":1}</field>
<field name="search_view_id" ref="view_report_crm_fundraising_filter"/>
</record>

View File

@ -68,11 +68,11 @@
<group col="16" colspan="9">
<filter string="This Year" icon="terp-hr"
domain="[('name','=',time.localtime()[0])]"
name="this_year" />
default="1" />
<filter string="This Month" icon="terp-hr"
domain="[('month','=',time.strftime('%%m'))]"
name="this_month" />
default="1" />
<separator orientation="vertical" />
<filter string="Current" icon="terp-hr"
@ -89,6 +89,7 @@
<separator orientation="vertical" />
<field name="section_id"
default="context.get('section_id', False)"
widget="selection"
context="{'invisible_section': False}">
@ -137,7 +138,8 @@
<group expand="1" string="Group By..." colspan="4" col="8">
<filter string="User" icon="terp-sale"
domain="[]" context="{'group_by':'user_id'}" />
domain="[]" context="{'group_by':'user_id'}"
default="1" />
<filter string="Company" icon="terp-sale"
domain="[]"
@ -175,7 +177,6 @@
<field name="view_type">form</field>
<field name="view_mode">tree,graph</field>
<field name="view_id" ref="view_report_crm_helpdesk_tree"/>
<field name="context">{"search_default_section_id":section_id,"search_default_this_year":1,"search_default_this_month":1,"search_default_by_user":1}</field>
<field name="search_view_id" ref="view_report_crm_helpdesk_filter"/>
</record>

View File

@ -79,7 +79,6 @@
<field name="res_model">crm.lead.report</field>
<field name="view_type">form</field>
<field name="view_mode">tree,graph</field>
<field name="context">{"search_default_section_id":section_id,"search_default_this_year":1,"search_default_this_month":1,"search_default_by_user":1}</field>
<field name="search_view_id" ref="view_report_crm_lead_filter"/>
</record>

View File

@ -88,7 +88,6 @@
<field name="res_model">crm.opportunity.report</field>
<field name="view_type">form</field>
<field name="view_mode">tree,graph</field>
<field name="context">{"search_default_section_id":section_id,"search_default_this_year":1,"search_default_this_month":1,"search_default_by_user":1}</field>
<field name="search_view_id" ref="view_report_crm_opportunity_filter"/>
</record>
<record model="ir.actions.act_window.view" id="action_report_crm_opportunity_tree">

View File

@ -77,7 +77,6 @@
<field name="view_type">form</field>
<field name="view_mode">tree,graph</field>
<field name="view_id" ref="view_report_crm_phonecall_tree"/>
<field name="context">{"search_default_section_id":section_id,"search_default_this_year":1,"search_default_this_month":1,"search_default_by_user":1}</field>
<field name="search_view_id" ref="view_report_crm_phonecall_filter"/>
</record>

View File

@ -65,11 +65,11 @@
<group col="16" colspan="8">
<filter string="This Year" icon="terp-hr"
domain="[('name','=',time.localtime()[0])]"
name="this_year" />
default="1" />
<filter string="This Month" icon="terp-hr"
domain="[('month','=',time.strftime('%%m'))]"
name="this_month" />
default="1" />
<separator orientation="vertical" />
<filter string="Current" icon="terp-hr"
@ -83,6 +83,7 @@
<separator orientation="vertical" />
<field name="section_id"
default="context.get('section_id', False)"
widget="selection"
context="{'invisible_section': False}">
@ -107,7 +108,7 @@
<group expand="1" string="Group By..." colspan="4" col="8">
<filter string="User" icon="terp-sale"
domain="[]" context="{'group_by':'user_id'}"
name="by_user" />
default="1" />
<filter string="Company" icon="terp-sale"
domain="[]"
@ -145,7 +146,6 @@
<field name="res_model">crm.case.report</field>
<field name="view_type">form</field>
<field name="view_mode">tree,graph</field>
<field name="context">{"search_default_section_id":section_id,"search_default_this_year":1,"search_default_this_month":1}</field>
<field name="search_view_id" ref="view_crm_case_filter"/>
</record>

View File

@ -146,7 +146,7 @@ class crm_send_new_email(osv.osv_memory):
if 'email_cc' in fields:
res.update({'email_cc': case.email_cc or ''})
if 'text' in fields:
res.update({'text': '\n\n'+(case.user_id.signature or '')})
res.update({'text': '\n\n'+(case.user_id.signature or '') + '\n\n' + (case.description or '')})
if 'state' in fields:
res.update({'state': 'pending'})
return res

View File

@ -15,7 +15,6 @@
<field name="subject" colspan="4"/>
<group colspan="4" string="Extended Options" expand="1">
<field name="email_from" />
<newline/>
<field name="doc1" filename="doc1_fname"/>
<field name="doc1_fname"/>
<field name="doc2" filename="doc2_fname" />

View File

@ -332,7 +332,7 @@
<field name="requirements" colspan="4" nolabel="1"/>
</page>
<page string="Employee">
<field name="employee_ids" colspan='4' nolabel="1" widget="many2many"/>
<field name="employee_ids" colspan='4' nolabel="1" mode="tree,form"/>
</page>
</notebook>
<field name="state"/>

View File

@ -300,51 +300,6 @@ class hr_evaluation_interview(osv.osv):
self.write(cr, uid, ids, { 'state' : 'cancel'}, context=context)
return True
def action_print_survey(self, cr, uid, ids, context=None):
"""
If response is available then print this response otherwise print survey form(print template of the survey).
@param self: The object pointer
@param cr: the current row, from the database cursor,
@param uid: the current users ID for security checks,
@param ids: List of Survey IDs
@param context: A standard dictionary for contextual values
@return : Dictionary value for print survey form.
"""
if not context:
context = {}
record = self.browse(cr, uid, ids, context)
record = record and record[0]
datas = {}
page_setting = {'orientation': 'vertical', 'without_pagebreak': 0, 'paper_size': 'letter', 'page_number': 1, 'survey_title': 1}
report = {}
if record:
datas['ids'] = [record.survey_id.id]
response_id = record.response.id
if response_id:
context.update({'survey_id': datas['ids'], 'response_id' : [response_id], 'response_no':0})
datas['form'] = page_setting
datas['model'] = 'survey.print.answer'
report = {
'type': 'ir.actions.report.xml',
'report_name': 'survey.browse.response',
'datas': datas,
'nodestroy': True,
'context' : context
}
else:
datas['form'] = page_setting
datas['model'] = 'survey.print'
report = {
'type': 'ir.actions.report.xml',
'report_name': 'survey.form',
'datas': datas,
'nodestroy':True,
'context' : context
}
return report
hr_evaluation_interview()
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:1

View File

@ -209,7 +209,7 @@
<field name="type">search</field>
<field name="arch" type="xml">
<search string="Search Evaluation">
<group>
<group col='10' colspan='4'>
<filter icon="terp-hr" string="Draft" domain="[('state','=','draft')]"/>
<filter icon="terp-crm" string="In progress" domain="[('state','=','wait')]"/>
<filter icon="terp-mrp" string="Final Step" domain="[('state','=','progress')]"/>
@ -226,9 +226,9 @@
<separator orientation="vertical"/>
<field name="employee_id" widget="selection" select="1"/>
<field name="plan_id" widget="selection" select="1"/>
</group>
<newline/>
<group expand='1' string='Group by...'>
</group>
<newline/>
<group col='8' colspan='15' expand='1' string='Group by...'>
<filter string='Employee' icon="terp-stock" domain="[]" context="{'group_by' : 'employee_id'}" />
<filter string='Plan' icon="terp-stock" domain="[]" context="{'group_by' : 'plan_id'}" />
<filter string='State' icon="terp-stock" domain="[]" context="{'group_by' : 'state'}" />
@ -261,8 +261,8 @@
<group colspan="1">
<button name="%(survey.action_view_survey_question_message)d" string="Interview Question" type="action" states="waiting_answer,done,cancel"
icon="gtk-execute" context="{'survey_id': survey_id, 'response_id': [response], 'response_no':0, 'active' : response,'request' : True, 'object' : 'hr.evaluation.interview', 'cur_id' : active_id}" attrs="{'readonly':[('survey_id','=',False)]}"/>
<button name="action_print_survey" string="Print Interview" type="object" states="waiting_answer,done,cancel"
icon="gtk-print" attrs="{'readonly':[('survey_id','=',False)]}" />
<button name="%(survey.survey_browse_response)d" string="Print Interview" type="action" states="done"
icon="gtk-print" context="{'survey_id': survey_id, 'response_id' : [response], 'response_no':0,}" attrs="{'readonly':[('response','=',False)]}" />
</group>
</group>
<group col="4" colspan="4">
@ -297,8 +297,8 @@
<field name="response" readonly="1" invisible="True"/>
<button name="%(survey.action_view_survey_question_message)d" string="Interview Question" type="action" states="waiting_answer,done,cancel"
icon="gtk-execute" context="{'survey_id': survey_id, 'response_id': [response], 'response_no':0, 'active' : response, 'request' : True, 'object' : 'hr.evaluation.interview', 'cur_id' : active_id}" attrs="{'readonly':[('survey_id','=',False)]}"/>
<button name="action_print_survey" string="Print Interview" type="object" states="waiting_answer,done,cancel"
icon="gtk-print" attrs="{'readonly':[('survey_id','=',False)]}"/>
<button name="%(survey.survey_browse_response)d" string="Print Interview" type="action" states="done"
icon="gtk-print" context="{'survey_id': survey_id, 'response_id' : [response], 'response_no':0}" attrs="{'readonly':[('response','=',False)]}" />
<field name="state"/>
</tree>
</field>

View File

@ -67,6 +67,7 @@
<field name="arch" type="xml">
<form string="Expenses Sheet">
<group colspan="4" col="6">
<field name="employee_id" select="1"/>
<field name="name" select="1"/>
<field name="employee_id" select="1"/>
<field name="ref" select="2"/>
@ -127,7 +128,7 @@
<field name="type">search</field>
<field name="arch" type="xml">
<search string="Expense">
<group>
<group col="20" colspan="4">
<filter
icon="terp-hr"
domain="[('state','=','draft')]"
@ -148,10 +149,11 @@
<field name="date" select='1'/>
<field name="user_id" select="1" widget="selection">
<filter
icon="gtk-execute" name="my_expns"
icon="gtk-execute"
help="My Expenses"
default="1"
domain="[('user_id','=',uid)]"/>
<filter icon="terp-hr"
<filter icon="terp-hr"
domain="[('department_id','=',context.get('department_id',False))]"
string="Expenses of My Department"/>
</field>
@ -172,7 +174,6 @@
<field name="name">Expenses</field>
<field name="res_model">hr.expense.expense</field>
<field name="view_type">form</field>
<field name="context">{"search_default_my_expns":1}</field>
<field name="search_view_id" ref="view_hr_expense_filter"/>
</record>

View File

@ -43,7 +43,7 @@
<field name="type">search</field>
<field name="arch" type="xml">
<search string="Expenses">
<group>
<group>
<filter icon="terp-hr"
string="This Year"
domain="[('year','=',time.strftime('%%Y'))]"
@ -56,7 +56,7 @@
<filter icon="terp-hr"
string="Draft"
domain="[('state','=','draft')]"/>
<filter icon="terp-hr"
<filter icon="terp-hr"
string="Expenses"
default="1"
domain="[('state','&lt;&gt;','draft'),('state','&lt;&gt;','cancelled')]"/>
@ -68,11 +68,11 @@
domain="[('user_id','=',uid)]"/>
</field>
<field name="company_id" groups="base.group_multi_company" widget="selection"/>
</group>
</group>
<newline/>
<group expand="1" string="Group By...">
<group expand="1" string="Group By..." colspan="10" col="12">
<filter string="Company" icon="terp-hr" context="{'group_by':'company_id'}"/>
<filter string="User" name="by_user" icon="terp-hr" context="{'group_by':'user_id'}"/>
<filter string="User" icon="terp-hr" context="{'group_by':'user_id'}" default="1"/>
<filter string="Employee" icon="terp-hr" context="{'group_by':'employee_id'}"/>
<filter string="Department" icon="terp-hr" context="{'group_by':'department_id'}"/>
<separator orientation="vertical"/>
@ -91,7 +91,6 @@
<field name="res_model">hr.expense.report</field>
<field name="view_type">form</field>
<field name="view_mode">tree,graph</field>
<field name="context">{"search_default_expenses":1,"search_default_by_user":1}</field>
<field name="search_view_id" ref="view_hr_expense_report_search"/>
</record>

View File

@ -1,85 +1,14 @@
<?xml version="1.0"?>
<openerp>
<data>
<report id="report_holidays_summary"
string="Summary Of Leaves"
model="hr.holidays"
name="holidays.summary"
xsl="hr_holidays/report/holidays_summary.xsl"
auto="False"
menu="False"/>
<data>
<report id="report_holidays_summary"
string="Summary Of Leaves"
model="hr.holidays"
name="holidays.summary"
xsl="hr_holidays/report/holidays_summary.xsl"
auto="False"
menu="False"/>
<!-- available holidays report -->
<record id="view_report_hr_holiday_tree" model="ir.ui.view">
<field name="name">hr.holidays.report.tree</field>
<field name="model">hr.holidays.report</field>
<field name="type">tree</field>
<field name="arch" type="xml">
<tree string="Available Holidays">
<field name="employee_id"/>
<field name="holiday_status_id"/>
<field name="remaining_leave"/>
</tree>
</field>
</record>
<record id="view_report_hr_holiday_form" model="ir.ui.view">
<field name="name">hr.holidays.report.form</field>
<field name="model">hr.holidays.report</field>
<field name="type">form</field>
<field name="arch" type="xml">
<tree string="Available Holidays">
<field name="employee_id" select="1"/>
<field name="holiday_status_id" select="1"/>
<field name="remaining_leave"/>
</tree>
</field>
</record>
<record id="view_report_hr_holiday_graph" model="ir.ui.view">
<field name="name">hr.holiday.report.graph</field>
<field name="model">hr.holidays.report</field>
<field name="type">graph</field>
<field name="arch" type="xml">
<graph orientation="horizontal" string="Available Holidays" type="bar">
<field name="holiday_status_id"/>
<field name="remaining_leave" operator="+"/>
<field group="True" name="employee_id"/>
</graph>
</field>
</record>
<record id="action_report_hr_holiday" model="ir.actions.act_window">
<field name="name">Available Holidays</field>
<field name="res_model">hr.holidays.report</field>
<field name="view_type">form</field>
<field name="view_mode">tree,graph</field>
<field name="view_id" ref="view_report_hr_holiday_tree"/>
</record>
<record model="ir.actions.act_window.view" id="action_report_hr_holiday_tree">
<field name="sequence" eval="1"/>
<field name="view_mode">tree</field>
<field name="view_id" ref="view_report_hr_holiday_tree"/>
<field name="act_window_id" ref="action_report_hr_holiday"/>
</record>
<record model="ir.actions.act_window.view" id="action_report_hr_holiday_graph">
<field name="sequence" eval="2"/>
<field name="view_mode">graph</field>
<field name="view_id" ref="view_report_hr_holiday_graph"/>
<field name="act_window_id" ref="action_report_hr_holiday"/>
</record>
<menuitem name="Available Holidays" id="menu_report_hr_holiday_tree" action="action_report_hr_holiday" parent="menu_hr_reporting_holidays"/>
</data>
</data>
</openerp>

View File

@ -10,9 +10,10 @@
<group col='8' colspan='4'>
<filter icon="terp-hr" domain="[('state','=','draft')]" string="To Confirm"/>
<filter icon="terp-hr" domain="[('state','=','confirm')]" string="To Validate"/>
<filter icon="terp-hr" domain="[('state','=','validate')]" string="Validated"/>
<filter icon="terp-hr" domain="[('state','=','validate')]" string="Validated"
default="context.get('report', False)"/>
<separator orientation="vertical"/>
<filter icon="terp-hr" help="My Leaves" domain="[('user_id','=',uid)]" string="My Leaves"/>
<filter icon="terp-hr" help="My Leaves" domain="[('user_id','=',uid)]" string="My Leaves" default="1"/>
<separator orientation="vertical"/>
<field name="user_id" widget="selection" />
<field name="department_id" widget="selection">
@ -26,10 +27,11 @@
<group expand="1" string="Group By..." colspan="11" col="11">
<filter string="Department" icon="terp-sale" domain="[]" context="{'group_by':'department_id'}"/>
<filter string="Manager" icon="terp-sale" domain="[]" context="{'group_by':'manager_id'}"/>
<filter string="User" icon="terp-sale" domain="[]" context="{'group_by':'employee_id'}"/>
<filter string="User" icon="terp-sale" domain="[]" context="{'group_by':'user_id'}"/>
<separator orientation="vertical"/>
<filter string="State" icon="terp-sale" domain="[]" context="{'group_by':'state'}"/>
<filter string="Type" icon="terp-sale" domain="[]" context="{'group_by':'holiday_status_id'}"/>
<filter string="Type" icon="terp-sale" domain="[]" context="{'group_by':'holiday_status_id'}"
default="context.get('report', False)"/>
</group>
</search>
</field>

View File

@ -18,24 +18,38 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
##############################################################################
from osv import fields,osv
import tools
class available_holidays_report(osv.osv):
_name = "available.holidays.report"
_auto = False
_columns = {
'date': fields.datetime('Date', readonly=True),
'year': fields.char('Year', size=4, readonly=True),
'month':fields.selection([('01','January'), ('02','February'), ('03','March'), ('04','April'),
('05','May'), ('06','June'), ('07','July'), ('08','August'), ('09','September'),
('10','October'), ('11','November'), ('12','December')], 'Month',readonly=True),
'employee_id': fields.many2one ('hr.employee', 'Employee', readonly=True),
'holiday_status_id': fields.many2one('hr.holidays.status', 'Leave Type', readonly=True),
'max_leave': fields.float('Allocated Leaves', readonly=True),
'taken_leaves': fields.float('Taken Leaves', readonly=True),
'remaining_leave': fields.float('Remaining Leaves',readonly=True),
'user_id':fields.many2one('res.users', 'User', readonly=True),
}
def init(self, cr):
tools.drop_view_if_exists(cr, 'available_holidays_report')
cr.execute("""
create or replace view available_holidays_report as (
select
min(h.id) as id,
date_trunc('day',h.create_date) as date,
to_char(s.create_date, 'YYYY') as year,
to_char(s.create_date, 'MM') as month,
h.employee_id as employee_id,
h.user_id as user_id,
h.state as state,
h.holiday_status_id as holiday_status_id,
sum(number_of_days) as remaining_leave,
(select sum(number_of_days_temp) from hr_holidays
where type='remove'
@ -48,9 +62,15 @@ class available_holidays_report(osv.osv):
and holiday_status_id=h.holiday_status_id
and state='validate') as max_leave
from hr_holidays h
left join hr_holidays_status s on (s.id = h.holiday_status_id)
where h.state='validate'
and h.employee_id is not null
and s.active <> 'f'
group by h.holiday_status_id, h.employee_id,
date_trunc('day',h.create_date),to_char(s.create_date, 'YYYY'),
to_char(s.create_date, 'MM'),h.user_id,h.state
)""")
available_holidays_report()
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:

View File

@ -9,7 +9,6 @@
<tree string="Leaves Statistics">
<field name="date"/>
<field name="employee_id"/>
<field name="user_id" invisible="1"/>
<field name="date_from"/>
<field name="date_to"/>
<field name="number_of_days_temp"/>
@ -47,6 +46,7 @@
domain="[('month','=',time.strftime('%%m'))]"
help="Leaves of this month"/>
<separator orientation="vertical"/>
<filter icon="terp-hr"
string="Draft"
domain="[('state','=','draft')]"/>
<filter icon="terp-hr"
@ -54,8 +54,12 @@
domain="[('state','=','validate')]"/>
<filter icon="terp-hr"
string="Start Leaves"
domain="[('date_from','=',time.strftime('%%Y/%%m/%%d'))]"/>
<filter icon="terp-hr"
string="End Leaves"
domain="[('date_to','=',time.strftime('%%Y/%%m/%%d'))]"/>
<separator orientation="vertical"/>
<field name="employee_id"/>
<field name="user_id" widget="selection">
<filter icon="terp-sale"

View File

@ -20,7 +20,6 @@
##############################################################################
from osv import fields,osv,orm
from tools.translate import _
AVAILABLE_STATES = [
('draft','New'),
@ -55,145 +54,13 @@ class hr_applicant(osv.osv):
'partner_name': fields.char("Applicant's Name", size=64),
'partner_phone': fields.char('Phone', size=32),
'partner_mobile': fields.char('Mobile', size=32),
'stage_id': fields.many2one ('crm.case.stage', 'Stage', domain="[('object_id.model', '=', 'hr.applicant')]"),
'type_id': fields.many2one('crm.case.resource.type', 'Degree', domain="[('object_id.model', '=', 'hr.applicant')]"),
'stage_id': fields.many2one ('crm.case.stage', 'Stage', domain="[('section_id','=',section_id),('object_id.model', '=', 'hr.applicant')]"),
'type_id': fields.many2one('crm.case.resource.type', 'Degree', domain="[('section_id','=',section_id),('object_id.model', '=', 'hr.applicant')]"),
'department_id':fields.many2one('hr.department','Department'),
'state': fields.selection(AVAILABLE_STATES, 'State', size=16, readonly=True),
'survey' : fields.related('job_id', 'survey_id', type='many2one', relation='survey', string='Survey'),
'response' : fields.integer("Response"),
}
def stage_previous(self, cr, uid, ids, context=None):
"""This function computes previous stage for case from its current stage
using available stage for that case type
@param self: The object pointer
@param cr: the current row, from the database cursor,
@param uid: the current users ID for security checks,
@param ids: List of case IDs
@param context: A standard dictionary for contextual values"""
if not context:
context = {}
for case in self.browse(cr, uid, ids, context):
section = (case.section_id.id or False)
st = case.stage_id.id or False
stage_ids = self.pool.get('crm.case.stage').search(cr, uid, [])
if st and stage_ids.index(st):
self.write(cr, uid, [case.id], {'stage_id': stage_ids[stage_ids.index(st)-1]})
return True
def stage_next(self, cr, uid, ids, context=None):
"""This function computes next stage for case from its current stage
using available stage for that case type
@param self: The object pointer
@param cr: the current row, from the database cursor,
@param uid: the current users ID for security checks,
@param ids: List of case IDs
@param context: A standard dictionary for contextual values"""
if not context:
context = {}
for case in self.browse(cr, uid, ids, context):
section = (case.section_id.id or False)
st = case.stage_id.id or False
stage_ids = self.pool.get('crm.case.stage').search(cr, uid, [])
if st and len(stage_ids) != stage_ids.index(st)+1:
self.write(cr, uid, [case.id], {'stage_id': stage_ids[stage_ids.index(st)+1]})
return True
def action_makeMeeting(self, cr, uid, ids, context=None):
"""
This opens Meeting's calendar view to schedule meeting on current Opportunity
@param self: The object pointer
@param cr: the current row, from the database cursor,
@param uid: the current users ID for security checks,
@param ids: List of Opportunity to Meeting IDs
@param context: A standard dictionary for contextual values
@return : Dictionary value for created Meeting view
"""
value = {}
for opp in self.browse(cr, uid, ids):
data_obj = self.pool.get('ir.model.data')
# Get meeting views
result = data_obj._get_id(cr, uid, 'crm', 'view_crm_case_meetings_filter')
res = data_obj.read(cr, uid, result, ['res_id'])
id1 = data_obj._get_id(cr, uid, 'crm', 'crm_case_calendar_view_meet')
id2 = data_obj._get_id(cr, uid, 'crm', 'crm_case_form_view_meet')
id3 = data_obj._get_id(cr, uid, 'crm', 'crm_case_tree_view_meet')
if id1:
id1 = data_obj.browse(cr, uid, id1, context=context).res_id
if id2:
id2 = data_obj.browse(cr, uid, id2, context=context).res_id
if id3:
id3 = data_obj.browse(cr, uid, id3, context=context).res_id
context = {
'default_opportunity_id': opp.id,
'default_partner_id': opp.partner_id and opp.partner_id.id or False,
'default_section_id': opp.section_id and opp.section_id.id or False,
'default_email_from': opp.email_from,
'default_state': 'open',
'default_name': opp.name
}
value = {
'name': _('Meetings'),
'domain': "[('user_id','=',%s)]" % (uid),
'context': context,
'view_type': 'form',
'view_mode': 'calendar,form,tree',
'res_model': 'crm.meeting',
'view_id': False,
'views': [(id1, 'calendar'), (id2, 'form'), (id3, 'tree')],
'type': 'ir.actions.act_window',
'search_view_id': res['res_id'],
'nodestroy': True
}
return value
def action_print_survey(self, cr, uid, ids, context=None):
"""
If response is available then print this response otherwise print survey form(print template of the survey).
@param self: The object pointer
@param cr: the current row, from the database cursor,
@param uid: the current users ID for security checks,
@param ids: List of Survey IDs
@param context: A standard dictionary for contextual values
@return : Dictionary value for print survey form.
"""
if not context:
context = {}
datas = {}
record = self.browse(cr, uid, ids, context)
record = record and record[0]
page_setting = {'orientation': 'vertical', 'without_pagebreak': 0, 'paper_size': 'letter', 'page_number': 1, 'survey_title': 1}
report = {}
if record:
datas['ids'] = [record.survey.id]
response_id = record.response
if response_id:
context.update({'survey_id': datas['ids'], 'response_id' : [response_id], 'response_no':0,})
datas['form'] = page_setting
datas['model'] = 'survey.print.answer'
report = {
'type': 'ir.actions.report.xml',
'report_name': 'survey.browse.response',
'datas': datas,
'nodestroy': True,
'context' : context
}
else:
datas['form'] = page_setting
datas['model'] = 'survey.print'
report = {
'type': 'ir.actions.report.xml',
'report_name': 'survey.form',
'datas': datas,
'nodestroy':True,
'context' : context
}
return report
hr_applicant()
class hr_job(osv.osv):

View File

@ -9,7 +9,6 @@
<field name="res_model">hr.applicant</field>
<field name="view_mode">tree,form,graph</field>
<field name="view_id" ref="crm_case_tree_view_job"/>
<field name="context">{"search_default_current":1,"search_default_my_recrui":1}</field>
<field name="search_view_id" ref="view_crm_case_jobs_filter"/>
</record>

View File

@ -43,8 +43,8 @@
<field name="partner_phone"/>
<field name="job_id"/>
<field name="stage_id"/>
<button name="stage_previous" string="Previous" states="draft,open,cancel,done,pending" type="object" icon="gtk-go-back"/>
<button name="stage_next" string="Next" states="draft,open,cancel,done,pending" type="object" icon="gtk-go-forward"/>
<button name="stage_previous" string="Previous" states="open,pending" type="object" icon="gtk-go-back"/>
<button name="stage_next" string="Next" states="open,pending" type="object" icon="gtk-go-forward"/>
<field name="survey" invisible="1"/>
<field name="response" invisible="1"/>
<field name="priority"/>
@ -71,24 +71,22 @@
<group colspan="4" col="8">
<field name="name" string="Subject"/>
<label string="Stage: " align="1.0"/>
<group colspan="1" col="3">
<group colspan="1" col="2">
<field name="stage_id" nolabel="1"/>
<button name="stage_previous" string="" type="object" icon="gtk-go-back"/>
<button icon="gtk-go-forward" string="" name="stage_next" type="object"/>
</group>
<field name="user_id"/>
<button string="Schedule a Phone Call"
name="%(wizard_hr_job_reschedule_phone_call)d" icon="gtk-redo" type="action"/>
<button name="%(survey.action_view_survey_question_message)d" string="Interview Question" type="action"
icon="gtk-execute" context="{'survey_id': survey, 'response_id': [response], 'response_no':0 ,'active' : response, 'object' : 'hr.applicant', 'cur_id' :active_id}" attrs="{'readonly':[('survey','=',False)]}"/>
icon="gtk-execute" context="{'survey_id': survey, 'response_id': [response], 'response_no':0 ,'active' : response, 'object' : 'hr.applicant', 'cur_id' :active_id}" attrs="{'readonly':[('survey','=',False)]}"/>
<newline/>
<field name="partner_name"/>
<field name="job_id"/>
<field name="department_id" widget="selection"/>
<button name="action_makeMeeting" type="object"
string="Schedule Meeting" icon="terp-hr" />
<button name="action_print_survey" string="Print Interview" type="object"
icon="gtk-print" attrs="{'readonly':[('survey','=',False)]}"/>
<button name="%(wizard_hr_job_meeting_set)d" string="Schedule Meeting" icon="terp-hr" type="action"/>
<button name="%(survey.survey_browse_response)d" string="Print Interview" type="action"
icon="gtk-print" context="{'survey_id': survey, 'response_id' : [response], 'response_no':0,}" attrs="{'readonly':[('response','=',False)]}" />
</group>
<notebook colspan="4">
<page string="Job Info">
@ -160,10 +158,10 @@
<newline/>
<field name="description" colspan="4" nolabel="1"/>
<button colspan="4"
string="Reply to Last Email"
name="%(crm.action_crm_send_mail)d"
context="{'mail':'reply', 'model': 'hr.applicant'}"
icon="gtk-undo" type="action" />
string="Reply to Last Email"
name="%(crm.action_crm_send_mail)d"
context="{'mail':'reply', 'model': 'hr.applicant'}"
icon="gtk-undo" type="action" />
</form>
<tree string="Communication history">
<field name="description"/>
@ -172,9 +170,9 @@
</tree>
</field>
<button colspan="4" string="Send New Email"
name="%(crm.action_crm_send_mail)d"
context="{'mail':'new', 'model': 'hr.applicant'}"
icon="gtk-go-forward" type="action" />
name="%(crm.action_crm_send_mail)d"
context="{'mail':'new', 'model': 'hr.applicant'}"
icon="gtk-go-forward" type="action" />
</page>
</notebook>
</form>
@ -201,10 +199,10 @@
<field name="type">search</field>
<field name="arch" type="xml">
<search string="Search Jobs">
<group>
<filter icon="gtk-new" string="Current" name="current"
<filter icon="gtk-new" string="Current"
domain="[('state','in',('draft','open'))]"
help="All new and in progress jobs"
default="1"
/>
<filter icon="gtk-new" string="New"
domain="[('state','=','draft')]"
@ -222,9 +220,8 @@
<field name="partner_name"/>
<field name="email_from"/>
<field name="job_id" widget="selection"/>
<newline/>
<field name="user_id" widget="selection">
<filter domain="[('user_id','=',uid)]" name="my_recrui" help="My Recruitements" icon="gtk-execute"/>
<filter domain="[('user_id','=',uid)]" help="My Recruitements" icon="gtk-execute" default="1"/>
<filter domain="[('user_id','=',False)]" help="Unassigned Recruitements" icon="gtk-execute" separator="1"/>
</field>
<field name="department_id" widget="selection" string="Department" context="{'invisible_department': False}">
@ -232,9 +229,8 @@
domain="[('department_id','=',context.get('department_id',False))]"
help="My Department"/>
</field>
</group>
<newline/>
<group expand="1" string="Group By..." >
<group expand="1" string="Group By..." colspan="11" col="20">
<filter string="Department" icon="terp-project" domain="[]" context="{'group_by':'department_id'}"/>
<filter string="Responsible" icon="terp-project" domain="[]" context="{'group_by':'user_id'}"/>
<separator orientation="vertical"/>

View File

@ -9,6 +9,14 @@
multi="True"
string="Schedule Phone Call" />
<wizard
id="wizard_hr_job_meeting_set"
keyword="client_action_multi"
model="hr.applicant"
name="hr.applicant.meeting_set"
multi="True"
string="Schedule Meeting"/>
<wizard
id="wizard_hr_job_partner_create"
keyword="client_action_multi"

View File

@ -57,6 +57,7 @@
<field name="user_id" widget="selection">
<filter icon="terp-sale"
string="My Recruitments"
default="1"
domain="[('user_id','=',uid)]"/>
</field>
</group>
@ -81,7 +82,7 @@
<newline/>
<group expand="1" string="Group By..." colspan="10" col="12">
<filter string="User" name="by_user" icon="terp-hr" domain="[]" context="{'group_by':'user_id'}" />
<filter string="User" icon="terp-hr" domain="[]" context="{'group_by':'user_id'}" default="1" />
<filter string="Company" icon="terp-hr" domain="[]" context="{'group_by':'company_id'}"/>
<filter string="Stage" icon="terp-hr" domain="[]" context="{'group_by':'stage_id'}"/>
<separator orientation="vertical"/>
@ -102,7 +103,6 @@
<field name="res_model">hr.recruitment.report</field>
<field name="view_type">form</field>
<field name="view_mode">tree,graph</field>
<field name="context">{"search_default_user_id":1,"search_default_by_user":1}</field>
<field name="search_view_id" ref="view_hr_recruitment_report_search"/>
</record>
<menuitem id="hr.menu_hr_reporting" name="Reporting" parent="hr.menu_hr_root"/>

View File

@ -132,6 +132,61 @@ class job2phonecall(wizard.interface):
job2phonecall('hr.applicant.reschedule_phone_call')
class job2meeting(wizard.interface):
def _makeMeeting(self, cr, uid, data, context):
pool = pooler.get_pool(cr.dbname)
job_case_obj = pool.get('hr.applicant')
meeting_case_obj = pool.get('hr.meeting')
for job in job_case_obj.browse(cr, uid, data['ids']):
new_meeting_id = meeting_case_obj.create(cr, uid, {
'name': job.name,
'date': job.date,
'duration': job.duration,
})
new_meeting = meeting_case_obj.browse(cr, uid, new_meeting_id)
vals = {}
job_case_obj.write(cr, uid, [job.id], vals)
job_case_obj.case_cancel(cr, uid, [job.id])
meeting_case_obj.case_open(cr, uid, [new_meeting_id])
data_obj = pool.get('ir.model.data')
result = data_obj._get_id(cr, uid, 'hr', 'view_hr_case_meetings_filter')
id = data_obj.read(cr, uid, result, ['res_id'])
id1 = data_obj._get_id(cr, uid, 'hr', 'hr_case_calendar_view_meet')
id2 = data_obj._get_id(cr, uid, 'hr', 'hr_case_form_view_meet')
id3 = data_obj._get_id(cr, uid, 'hr', 'hr_case_tree_view_meet')
if id1:
id1 = data_obj.browse(cr, uid, id1, context=context).res_id
if id2:
id2 = data_obj.browse(cr, uid, id2, context=context).res_id
if id3:
id3 = data_obj.browse(cr, uid, id3, context=context).res_id
return {
'name': _('Meetings'),
'view_type': 'form',
'view_mode': 'calendar,form,tree',
'res_model': 'hr.meeting',
'view_id': False,
'views': [(id1,'calendar'),(id2,'form'),(id3,'tree'),(False,'graph')],
'type': 'ir.actions.act_window',
'search_view_id': id['res_id']
}
states = {
'init': {
'actions': [],
'result': {'type': 'action', 'action': _makeMeeting, 'state': 'order'}
},
'order': {
'actions': [],
'result': {'type': 'state', 'state': 'end'}
}
}
job2meeting('hr.applicant.meeting_set')
class partner_create(wizard.interface):
case_form = """<?xml version="1.0"?>

View File

@ -13,7 +13,7 @@ msgstr ""
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Launchpad-Export-Date: 2010-04-08 07:18+0000\n"
"X-Launchpad-Export-Date: 2010-04-07 03:46+0000\n"
"X-Generator: Launchpad (build Unknown)\n"
#. module: hr_timesheet

View File

@ -181,7 +181,7 @@
<field name="arch" type="xml">
<search string="Search Timesheet">
<group col="10" colspan="4">
<filter icon="terp-partner" domain="[('user_id','=',uid)]" help="My" />
<filter icon="terp-partner" domain="[('user_id','=',uid)]" help="My" default="1"/>
<separator orientation="vertical"/>
<filter icon="terp-crm" string="In Progress" domain="[('state','in',('draft', 'new'))]" help="Unvalidated Timesheets"/>
<filter icon="terp-crm" string="To Validate" domain="[('state','=','confirmed')]" help="Confirmed Timesheets"/>

View File

@ -618,7 +618,8 @@
<filter icon="terp-mrp" string="Draft"
domain="[('state','=','draft')]"
help="Non confirmed manufacturing orders"/>
<filter icon="terp-mrp" string="Current" name="current"
<filter icon="terp-mrp" string="Current"
default="1"
domain="[('state','in',('confirmed','ready'))]"
help="Manufacturing Orders which are waiting for raw materials"/>
<filter icon="terp-mrp" string="Ready"
@ -656,7 +657,6 @@
<field name="view_type">form</field>
<field name="view_mode">tree,form,calendar,graph,gantt</field>
<field name="view_id" eval="False"/>
<field name="context">{"search_default_current":1}</field>
<field name="search_view_id" ref="view_mrp_production_filter"/>
</record>
<menuitem action="mrp_production_action" id="menu_mrp_production_action" parent="menu_mrp_manufacturing" sequence="1"/>
@ -808,7 +808,7 @@
<page string="Procurement Details">
<separator colspan="4" string="Product &amp; Location"/>
<field name="product_id" select="1" on_change="onchange_product_id(product_id)"/>
<field name="location_id" select="2" domain="[('usage','=','internal')]"/>
<field name="location_id" select="2"/>
<field name="product_qty"/>
<field name="product_uom"/>
@ -852,7 +852,7 @@
<field name="arch" type="xml">
<search string="Search Procurement">
<group col='10' colspan='4'>
<filter icon="terp-mrp" string="Current" domain="[('state','in',('draft','confirmed'))]" name="current" help="Procurement Orders in draft or open state."/>
<filter icon="terp-mrp" string="Current" domain="[('state','in',('draft','confirmed'))]" default="1" help="Procurement Orders in draft or open state."/>
<filter icon="terp-mrp" string="Exceptions" domain="[('state','=','exception')]" help="Procurement Orders with exceptions"/>
<filter icon="terp-mrp" string="Late"
domain="['&amp;', ('date_planned::date','&lt;', current_date), ('state', 'in', ('draft', 'confirmed'))]"
@ -878,7 +878,6 @@
<field name="res_model">mrp.procurement</field>
<field name="view_type">form</field>
<field name="view_id" eval="False"/>
<field name="context">{"search_default_current":1}</field>
<field name="search_view_id" ref="view_mrp_procurement_filter"/>
</record>
<menuitem action="mrp_procurement_action" id="menu_mrp_procurement_action" parent="mrp.menu_mrp_manufacturing"
@ -896,7 +895,7 @@
</record>
<menuitem action="mrp_procurement_action3" id="menu_procurement_requisitions" parent="purchase.menu_procurement_management"
sequence="5" />
name="Requisitions" sequence="5" />
<record id="mrp_procurement_action5" model="ir.actions.act_window">
<field name="name">Procurement Exceptions</field>

View File

@ -163,7 +163,8 @@
<record id="act_produce" model="workflow.activity">
<field name="wkf_id" ref="wkf"/>
<field name="name">produce</field>
<field name="kind">function</field>
<field name="kind">subflow</field>
<field name="subflow_id" search="[('osv','=','mrp.production')]"/>
<field name="action">action_produce_assign_product()</field>
</record>
<record id="act_produce_check" model="workflow.activity">
@ -179,7 +180,8 @@
<record id="act_buy" model="workflow.activity">
<field name="wkf_id" ref="wkf"/>
<field name="name">buy</field>
<field name="kind">function</field>
<field name="kind">subflow</field>
<field name="subflow_id" search="[('osv','=','purchase.order')]"/>
<field name="action">action_po_assign()</field>
</record>
<record id="act_make_done" model="workflow.activity">
@ -306,16 +308,26 @@
<field name="trigger_model" eval="False"/>
<field name="trigger_expr_id" eval="False"/>
</record>
<record id="trans_produce_cancel" model="workflow.transition">
<field name="act_from" ref="act_produce"/>
<field name="act_to" ref="act_cancel"/>
<field name="signal">subflow.cancel</field>
</record>
<record id="trans_produce_service_cancel" model="workflow.transition">
<field name="act_from" ref="act_produce_service"/>
<field name="act_to" ref="act_cancel"/>
<field name="signal">subflow.cancel</field>
</record>
<record id="trans_buy_cancel" model="workflow.transition">
<field name="act_from" ref="act_buy"/>
<field name="act_to" ref="act_cancel"/>
<field name="signal">subflow.cancel</field>
</record>
<record id="trans_produce_make_done" model="workflow.transition">
<field name="act_from" ref="act_produce"/>
<field name="act_to" ref="act_make_done"/>
<field name="signal" eval="False"/>
<field name="signal">subflow.done</field>
</record>
<record id="trans_produce_service_make_done" model="workflow.transition">
@ -325,14 +337,12 @@
<record id="trans_buy_make_done" model="workflow.transition">
<field name="act_from" ref="act_buy"/>
<field name="act_to" ref="act_make_done"/>
<field name="signal" eval="False"/>
<field name="signal">subflow.delivery_done</field>
</record>
<record id="trans_make_done_done" model="workflow.transition">
<field name="act_from" ref="act_make_done"/>
<field name="act_to" ref="act_done"/>
<field name="condition">action_check_finnished() or (not move_id)</field>
<field name="trigger_model">stock.move</field>
<field name="trigger_expr_id">[move_id.id]</field>
<field name="condition">action_check_finnished()</field>
</record>
<record id="trans_make_done_confirm" model="workflow.transition">
<field name="act_from" ref="act_make_done"/>

View File

@ -48,8 +48,8 @@
<field name="arch" type="xml">
<search string="Search">
<group col="16" colspan="6">
<filter string="This Year" name="this_year" icon="terp-hr" domain="[('name','=',time.localtime()[0])]" default = "1"/>
<filter string="This Month" name="this_month" icon="terp-hr" domain="[('month','=',time.strftime('%%m'))]"/>
<filter string="This Year" icon="terp-mrp" domain="[('name','=',time.localtime()[0])]" default="1" />
<filter string="This Month" icon="terp-mrp" domain="[('month','=',time.strftime('%%m'))]" default="1"/>
<separator orientation="vertical"/>
<filter string="Current" icon="terp-mrp" domain="[('state','in',('open','draft'))]"/>
<separator orientation="vertical"/>
@ -99,7 +99,6 @@
<field name="res_model">mrp.production.order</field>
<field name="view_type">form</field>
<field name="view_mode">tree,graph</field>
<field name="context">{"search_default_this_year":1,"search_default_this_month":1}</field>
<field name="view_id" ref="view_report_mrp_production_order_tree"/>
<field name="search_view_id" ref="view_report_mrp_production_order_filter"/>
</record>

View File

@ -1,56 +0,0 @@
# Chinese (Simplified) translation for openobject-addons
# Copyright (c) 2010 Rosetta Contributors and Canonical Ltd 2010
# This file is distributed under the same license as the openobject-addons package.
# FIRST AUTHOR <EMAIL@ADDRESS>, 2010.
#
msgid ""
msgstr ""
"Project-Id-Version: openobject-addons\n"
"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
"POT-Creation-Date: 2009-11-26 05:29+0000\n"
"PO-Revision-Date: 2010-04-08 02:07+0000\n"
"Last-Translator: Silence <Unknown>\n"
"Language-Team: Chinese (Simplified) <zh_CN@li.org>\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Launchpad-Export-Date: 2010-04-09 03:56+0000\n"
"X-Generator: Launchpad (build Unknown)\n"
#. module: olap_extract
#: model:ir.module.module,shortdesc:olap_extract.module_meta_information
msgid "olap_extract"
msgstr ""
#. module: olap_extract
#: wizard_button:olap.extract.schema,init,ok:0
msgid "OK"
msgstr "确定"
#. module: olap_extract
#: model:ir.actions.wizard,name:olap_extract.bi_olap_extract_schema
msgid "Olap Extract"
msgstr "Olap提取"
#. module: olap_extract
#: model:ir.module.module,description:olap_extract.module_meta_information
msgid ""
"\n"
" Extracts the schema structure.\n"
" "
msgstr ""
#. module: olap_extract
#: wizard_field:olap.extract.schema,init,module_name:0
msgid "Module Name"
msgstr "模块名称"
#. module: olap_extract
#: wizard_button:olap.extract.schema,init,end:0
msgid "Cancel"
msgstr "取消"
#. module: olap_extract
#: wizard_view:olap.extract.schema,init:0
msgid "New Module Name"
msgstr "新的模块名"

View File

@ -9,7 +9,7 @@
<field name="arch" type="xml">
<page string="Sales &amp; Purchases" position="inside">
<newline/>
<group col="2" colspan="2" name="sale_list" groups="base.group_extended">
<group col="2" colspan="2" name="sale_list">
<separator string="Sales Properties" colspan="2"/>
<field name="property_product_pricelist"/>
</group>

View File

@ -2,10 +2,7 @@
<openerp>
<data>
<menuitem id="menu_product_pricelist_main"
name="Pricelists" parent="prod_config_main"
groups="base.group_extended"
sequence="50"/>
<menuitem groups="base.group_extended" id="menu_product_pricelist_main" name="Pricelists" parent="prod_config_main" sequence="50"/>
<record id="product_pricelist_version_form_view" model="ir.ui.view">
<field name="name">product.pricelist.version.form</field>

View File

@ -49,7 +49,7 @@
<button name="set_cancel" string="Cancel" type="object" states="open,pending" icon="gtk-cancel"/>
<button name="set_done" string="Done" type="object" states="open,pending" icon="gtk-jump-to"/>
<button name="reset_project" string="Reset as Project" type="object" states="template" icon="gtk-convert"/>
<button
<button
string="New Project Based on Template"
name="duplicate_template" type="object"
states="template" icon="gtk-new"/>
@ -110,11 +110,11 @@
<field name="arch" type="xml">
<search string="Search Project">
<group col='15' colspan='4'>
<filter icon="terp-project" string="Current" domain="[('state', 'in',('open','draft'))]" help="Open and Draft Projects" name="open"/>
<filter icon="terp-project" string="Current" domain="[('state', 'in',('open','draft'))]" help="Open and Draft Projects" default="1"/>
<filter icon="terp-project" string="Pending" domain="[('state', '=', 'pending')]" help="Pending Projects"/>
<separator orientation="vertical"/>
<filter icon="terp-project" string="Manager" domain="[('user_id', '=', uid)]" help="Projects in which I am a manager."/>
<filter icon="terp-project" string="Member" domain="['|',('user_id', '=', uid),('members', '=', uid)]" help="Projects in which I am a member." name="member"/>
<filter icon="terp-project" string="Member" domain="['|',('user_id', '=', uid),('members', '=', uid)]" help="Projects in which I am a member." default="1"/>
<separator orientation="vertical"/>
<filter icon="terp-project" string="Templates" domain="[('state','=','template')]" help="Template Projects"/>
<separator orientation="vertical"/>
@ -152,7 +152,6 @@
<field name="view_type">form</field>
<field name="domain">[]</field>
<field name="view_id" ref="view_project"/>
<field name="context">{"search_default_open":1,"search_default_member":1}</field>
<field name="search_view_id" ref="view_project_project_filter"/>
</record>
<menuitem action="open_view_project_all" id="menu_open_view_project_all" parent="menu_project_management" sequence="1"/>
@ -403,18 +402,18 @@
<field name="arch" type="xml">
<search string="Task Edition">
<group col="20" colspan="4">
<filter string="Current" domain="[('state','in',('open','draft'))]" help="Draft, Open and Pending Tasks" icon="terp-project" name="current"/>
<filter string="Current" domain="[('state','in',('open','draft'))]" help="Draft, Open and Pending Tasks" icon="terp-project" default="1"/>
<filter string="In Progress" domain="[('state','=','open')]" help="Open Tasks" icon="terp-project"/>
<filter string="Pending" domain="[('state','=','pending')]" context="{'show_delegated':False}" help="Pending Tasks" icon="terp-project"/>
<separator orientation="vertical"/>
<filter string="Deadlines" domain="[('date_deadline','&lt;&gt;',False)]" help="Show only tasks having a deadline" icon="terp-project"/>
<separator orientation="vertical"/>
<field name="name" select="1"/>
<field name="project_id" select="1" widget="selection">
<field name="project_id" select="1" widget="selection" default="context.get('project_id', False)">
<filter domain="[('project_id.user_id','=',uid)]" help="My Projects" icon="terp-project"/>
</field>
<field name="user_id" select="1" widget="selection">
<filter domain="[('user_id','=',uid)]" help="My Tasks" icon="gtk-execute" name="my_task"/>
<filter domain="[('user_id','=',uid)]" help="My Tasks" icon="gtk-execute" default="1"/>
<filter domain="[('user_id','=',False)]" help="Unassigned Tasks" icon="gtk-execute" separator="1"/>
</field>
</group>
@ -440,7 +439,6 @@
<field name="view_mode">tree,form,calendar,gantt,graph</field>
<field eval="False" name="filter"/>
<field name="view_id" ref="view_task_tree2"/>
<field name="context">{"search_default_current":1,"search_default_my_task":1}</field>
<field name="search_view_id" ref="view_task_search_form"/>
</record>
<menuitem action="action_view_task" id="menu_action_view_task" parent="project.menu_project_management" sequence="2"/>
@ -535,25 +533,25 @@
<!-- User Form-->
<record id="view_project_users_form_simple" model="ir.ui.view">
<field name="name">res.users.project.form1</field>
<field name="model">res.users</field>
<field name="type">form</field>
<field name="inherit_id" ref="base.view_users_form"/>
<field eval="18" name="priority"/>
<field name="arch" type="xml">
<field name="password" position="after">
<field name="context_project_id" completion="1" widget="selection"/>
</field>
</field>
<field name="name">res.users.project.form1</field>
<field name="model">res.users</field>
<field name="type">form</field>
<field name="inherit_id" ref="base.view_users_form"/>
<field eval="18" name="priority"/>
<field name="arch" type="xml">
<field name="password" position="after">
<field name="context_project_id" completion="1" widget="selection"/>
</field>
</field>
</record>
<record model="ir.ui.view" id="view_users_form_project_modif_inherited1">
<field name="name">view.users.form.project.modif.inherited1</field>
<field name="model">res.users</field>
<field name="inherit_id" ref="base.view_users_form_simple_modif" />
<field name="type">form</field>
<field eval="18" name="priority"/>
<field name="arch" type="xml">
<field name="name">view.users.form.project.modif.inherited1</field>
<field name="model">res.users</field>
<field name="inherit_id" ref="base.view_users_form_simple_modif" />
<field name="type">form</field>
<field eval="18" name="priority"/>
<field name="arch" type="xml">
<page string="Current Activity" position="inside">
<field name="context_project_id" completion="1" widget="selection" context="{'user_prefence':True}"/>
</page>
@ -603,12 +601,12 @@
<filter domain="[('date','&gt;=',time.strftime('%%Y-%%m-01'))]" icon="terp-project" string="This Month" />
<filter domain="[('date', '=', time.strftime('%%Y-%%m-%%d'))]" icon="terp-project" string="Today" />
<separator orientation="vertical"/>
<field name="subject"/>
<field name="project_id" select="1" widget="selection"/>
<field name="user_id" select="1" widget="selection">
<filter domain="[('user_id','=',uid)]" help="My Message" icon="gtk-execute" name="my_msg"/>
</field>
<separator orientation="vertical"/>
<field name="subject"/>
<field name="project_id" select="1" widget="selection"/>
<field name="user_id" select="1" widget="selection">
<filter domain="[('user_id','=',uid)]" help="My Message" icon="gtk-execute" default="1"/>
</field>
</group>
<newline/>
<group expand="1" string="Group By..." colspan="4" col="20">
@ -626,7 +624,6 @@
<field name="view_type">form</field>
<field name="view_mode">tree,form</field>
<field name="view_id" ref="view_project_message_tree"/>
<field name="context">{"search_default_my_msg":1}</field>
<field name="search_view_id" ref="view_project_message_search"/>
</record>

View File

@ -29,35 +29,23 @@ class report_project_task_user(osv.osv):
_columns = {
'name': fields.char('Year',size=64,required=False, readonly=True),
'user_id':fields.many2one('res.users', 'User', readonly=True),
'date_start': fields.datetime('Starting Date',readonly=True),
'date_end': fields.datetime('Ending Date',readonly=True),
'date_deadline': fields.date('Deadline',readonly=True),
'date_start': fields.datetime('Starting Date'),
'date_end': fields.datetime('Ending Date'),
'date_deadline': fields.date('Deadline'),
'project_id':fields.many2one('project.project', 'Project', readonly=True),
'hours_planned': fields.float('Planned Hours', readonly=True),
'hours_effective': fields.float('Effective Hours', readonly=True),
'hours_delay': fields.float('Avg. Plan.-Eff.', readonly=True),
'closing_days': fields.char('Avg Closing Delay', size=64, readonly=True),
'nbr': fields.integer('#Number of tasks', readonly=True),
'priority' : fields.selection([('4','Very Low'),
('3','Low'),
('2','Medium'),
('1','Urgent'),
('0','Very urgent')],
'Importance',readonly=True),
'month':fields.selection([('01','January'), ('02','February'), ('03','March'), ('04','April'), ('05','May'), ('06','June'),
('07','July'), ('08','August'), ('09','September'), ('10','October'), ('11','November'), ('12','December')],'Month',readonly=True),
'state': fields.selection([
('draft', 'Draft'),
'state': fields.selection([('draft', 'Draft'),
('open', 'In Progress'),
('pending', 'Pending'),
('cancelled', 'Cancelled'),
('done', 'Done')],
'State', readonly=True),
'company_id': fields.many2one('res.company', 'Company',readonly=True),
'partner_id': fields.many2one('res.partner', 'Partner',readonly=True),
'type': fields.many2one('project.task.type', 'Stage',readonly=True),
}
_order = 'name desc, project_id'
@ -72,14 +60,10 @@ class report_project_task_user(osv.osv):
count(distinct t.id) as nbr,
date_trunc('day',t.date_start) as date_start,
date_trunc('day',t.date_end) as date_end,
to_date(to_char(t.date_deadline, 'dd-MM-YYYY'),'dd-MM-YYYY') as date_deadline,
date_trunc('day',t.date_deadline) as date_deadline,
t.user_id,
t.project_id,
t.state,
t.priority,
t.company_id,
t.partner_id,
t.type,
sum(planned_hours) as hours_planned,
to_char(avg(date_end::abstime-t.create_date::timestamp), 'DD"d" HH24:MI:SS') as closing_days,
sum(w.hours) as hours_effective,
@ -89,15 +73,8 @@ class report_project_task_user(osv.osv):
group by
to_char(date_start, 'YYYY'),
to_char(date_start, 'MM'),
t.priority,
t.user_id,
t.state,
t.date_end,
to_date(to_char(t.date_deadline, 'dd-MM-YYYY'),'dd-MM-YYYY'),
t.date_start,
t.company_id,
t.partner_id,
t.type,
t.user_id,t.state,t.date_end,
t.date_deadline,t.date_start,
t.project_id
)
""")

View File

@ -9,23 +9,19 @@
<field name="type">tree</field>
<field name="arch" type="xml">
<tree string="Tasks">
<field name="project_id"/>
<field name="user_id"/>
<field name="date_deadline"/>
<field name="nbr" sum='#Number of tasks'/>
<field name="hours_planned" sum='Planned Hours'/>
<field name="hours_effective" sum='Effective Hours'/>
<field name="hours_delay" sum='Avg. Plan.-Eff.'/>
<field name="closing_days" sum='Avg Closing Delay'/>
<field name="state"/>
<field name="date_start" invisible="1"/>
<field name="date_end" invisible="1"/>
<field name="company_id" invisible="1"/>
<field name="partner_id" invisible="1"/>
<field name="type" invisible="1"/>
<field name="name" invisible="1"/>
<field name="month" invisible="1"/>
<field name="user_id"/>
<field name="project_id"/>
<field name="nbr"/>
<field name="date_start" invisible="1"/>
<field name="date_end" invisible="1"/>
<field name="date_deadline" invisible="1"/>
<field name="hours_planned"/>
<field name="hours_effective"/>
<field name="hours_delay"/>
<field name="closing_days"/>
<field name="state"/>
</tree>
</field>
</record>
@ -36,44 +32,23 @@
<field name="type">search</field>
<field name="arch" type="xml">
<search string="Tasks">
<group>
<filter icon="terp-project" string="This Year" domain="[('name','=',time.strftime('%%Y'))]" help="Tasks performed in this year"/>
<filter icon="terp-project" string="This Month" domain="[('month','=',time.strftime('%%m'))]" help="Tasks performed in this month"/>
<separator orientation="vertical"/>
<filter string="Deadline" icon="terp-project" domain="[('date_deadline','=',time.strftime('%%Y/%%m/%%d'))]"/>
<separator orientation="vertical"/>
<field name="project_id"/>
<field name="user_id" widget="selection">
<filter icon="terp-project" string="My Task" domain="[('user_id','=',uid)]" name="my_task"/>
</field>
</group>
<filter icon="terp-project" string="This Year" domain="[('name','=',time.strftime('%%Y'))]" help="Tasks performed in this year"/>
<filter icon="terp-project" string="This Month" domain="[('month','=',time.strftime('%%m'))]" help="Tasks performed in this month"/>
<separator orientation="vertical"/>
<filter string="In Progress" icon="terp-project" domain="[('state','=','open')]"/>
<filter string="Pending" icon="terp-project" domain="[('state','=','pending')]"/>
<filter string="Closed" icon="terp-project" domain="[('state','=','done')]"/>
<separator orientation="vertical"/>
<field name="project_id"/>
<field name="user_id" widget="selection">
<filter icon="terp-project" string="My Task" domain="[('user_id','=',uid)]" default="1"/>
</field>
<newline/>
<group expand="1" string="Extended options..." colspan="10" col="12">
<filter string="Draft" icon="terp-project" domain="[('state','=','draft')]"/>
<filter string="In Progress" icon="terp-project" domain="[('state','=','open')]"/>
<filter string="Pending" icon="terp-project" domain="[('state','=','pending')]"/>
<filter string="Done" icon="terp-project" domain="[('state','=','done')]"/>
<filter string="Cancelled" icon="terp-project" domain="[('state','=','cancelled')]"/>
<separator orientation="vertical"/>
<field name="date_start"/>
<newline/>
<filter icon="terp-project" string="Very Low" domain="[('priority','=','4')]"/>
<filter icon="terp-project" string="Low" domain="[('priority','=','3')]"/>
<filter icon="terp-project" string="Medium" domain="[('priority','=','2')]"/>
<filter icon="terp-project" string="Urgent" domain="[('priority','=','1')]"/>
<filter icon="terp-project" string="Very Urgent" domain="[('priority','=','0')]"/>
<separator orientation="vertical"/>
<field name="date_end"/>
</group>
<newline/>
<group expand="1" string="Group By...">
<group expand="1" string="Group By..." colspan="10" col="11">
<filter string="User" icon="terp-project" context="{'group_by':'user_id'}" />
<filter string="Project" icon="terp-project" context="{'group_by':'project_id'}" default = "1"/>
<filter string="Partner" icon="terp-project" context="{'group_by':'partner_id'}" />
<separator orientation="vertical"/>
<filter string="State" icon="terp-project" context="{'group_by':'state'}"/>
<filter string="Company" icon="terp-project" context="{'group_by':'company_id'}" />
<filter string="Stage" icon="terp-project" context="{'group_by':'type'}" />
<separator orientation="vertical"/>
<filter string="Month" icon="terp-project" context="{'group_by':'month'}"/>
<filter string="Year" icon="terp-project" context="{'group_by':'name'}"/>
@ -87,7 +62,6 @@
<field name="res_model">report.project.task.user</field>
<field name="view_type">form</field>
<field name="view_mode">tree</field>
<field name="context">{"search_default_my_task":1}</field>
<field name="search_view_id" ref="view_task_project_user_search"/>
</record>
<menuitem action="action_project_task_user_tree" id="menu_project_task_user_tree" parent="base.menu_project_report"/>

View File

@ -1,7 +1,7 @@
<?xml version="1.0"?>
<openerp>
<data noupdate="1">
<data noupdate="1">
######################## ISSUE TRACKING (menu) ###########################
<!--
@ -14,7 +14,6 @@
<field name="view_mode">tree,calendar</field>
<field name="view_id" ref="project_issue_tree_view"/>
<field name="domain" eval="[('categ_id','=',ref('bug_categ'))]"/>
<field name="context">{"search_default_my_bugs":1,"search_default_current_bugs":1,"search_default_project_id":project_id}</field>
<field name="search_view_id" ref="view_project_issue_filter"/>
</record>
<record model="ir.actions.act_window.view" id="action_crm_tag_tree_view0">

View File

@ -190,7 +190,7 @@
<field name="type">search</field>
<field name="arch" type="xml">
<search string="Issue Tracker Search">
<group>
<group col="3" colspan="1">
<filter icon="gtk-home" string=" Today "
separator="1"
domain="[('date','=',time.strftime('%%Y-%%m-%%d'))]"
@ -204,16 +204,16 @@
</group>
<separator orientation="vertical"/>
<group>
<group col="5" colspan="2">
<field name="name" select='1' string="Subject"/>
<field name="user_id" select="1" widget="selection">
<filter icon="terp-partner" domain="[('user_id','=',uid)]" help="My Bugs" name="my_bugs"/>
<filter icon="terp-partner" domain="[('user_id','=',uid)]" help="My Bugs" default="1"/>
</field>
<field name="state" select="1">
<filter icon="gtk-new" domain="[('state','in',('open','draft'))]" help="Current Bugs" name="current_bugs"/>
<filter icon="gtk-new" domain="[('state','in',('open','draft'))]" help="Current Bugs" default="1"/>
<filter icon="gtk-yes" domain="[('state','=','open')]" help="Open Bugs"/>
</field>
<field name="project_id" select="1" widget="selection" string="Project">
<field name="project_id" select="1" widget="selection" string="Project" default="context.get('project_id', False)">
<filter icon="terp-crm"
domain="[('project_id','=',context.get('project_id',False))]"
help="My Project"
@ -277,7 +277,7 @@
<field name="type">search</field>
<field name="arch" type="xml">
<search string="Feature Tracker Search">
<group>
<group col="3" colspan="1">
<filter icon="gtk-home" string=" Today "
separator="1"
domain="[('date','=',time.strftime('%%Y-%%m-%%d'))]"
@ -290,16 +290,16 @@
/>
</group>
<separator orientation="vertical"/>
<group>
<group col="5" colspan="2">
<field name="name" select='1' string="Feature description"/>
<field name="user_id" select="1" widget="selection">
<filter icon="terp-partner" domain="[('user_id','=',uid)]" help="My Features" name="my_feature"/>
<filter icon="terp-partner" domain="[('user_id','=',uid)]" help="My Features" default="1"/>
</field>
<field name="state" select="1">
<filter icon="gtk-new" domain="[('state','in',('open','draft'))]" help="Current Features" name="current_feature"/>
<filter icon="gtk-new" domain="[('state','in',('open','draft'))]" help="Current Features" default="1"/>
<filter icon="gtk-yes" domain="[('state','=','open')]" help="Open Features"/>
</field>
<field name="project_id" select="1" widget="selection" string="Project">
<field name="project_id" select="1" widget="selection" string="Project" default="context.get('project_id', False)">
<filter icon="terp-crm"
domain="[('project_id','=',context.get('project_id',False))]"
help="My Project"

View File

@ -196,7 +196,7 @@
<field name="arch" type="xml">
<search string="Project Phases">
<group colspan="4" col="20">
<filter string="Current" domain="[('state','in',('open','draft'))]" help="Draft, Open and Pending Phases" icon="terp-project" name="current"/>
<filter string="Current" domain="[('state','in',('open','draft'))]" help="Draft, Open and Pending Phases" icon="terp-project" default="1"/>
<filter string="In Progress" domain="[('state','=','open')]" help="Open Phases" icon="terp-project"/>
<filter string="Pending" domain="[('state','=','pending')]" help="Pending Phases" icon="terp-project"/>
<separator orientation="vertical"/>
@ -205,7 +205,7 @@
<filter domain="[('project_id.user_id','=',uid)]" help="My Projects" icon="terp-project"/>
</field>
<field name="responsible_id" widget="selection">
<filter domain="[('responsible_id','=',uid)]" help="My Phase" icon="gtk-execute" name="my_phase"/>
<filter domain="[('responsible_id','=',uid)]" help="My Phase" icon="gtk-execute" default="1"/>
</field>
<field name="date_start"/>
</group>
@ -225,7 +225,6 @@
<field name="res_model">project.phase</field>
<field name="view_type">form</field>
<field name="view_mode">tree,form,calendar,gantt</field>
<field name="context">{"search_default_current":1,"search_default_my_phase":1}</field>
<field name="search_view_id" ref="view_project_phase_search"/>
</record>

View File

@ -71,7 +71,7 @@
<field name="type">search</field>
<field name="arch" type="xml">
<search string="Tasks by User">
<group>
<group col="10" colspan="4">
<filter icon="terp-project" string="This Year" domain="[('year','=',time.strftime('%%Y'))]" help="Tasks performed in this year"/>
<filter icon="terp-project" string="This Month" domain="[('month','=',time.strftime('%%m'))]" help="Tasks performed in this month"/>
<separator orientation="vertical"/>
@ -81,7 +81,7 @@
<separator orientation="vertical"/>
<field name="project_id" select="1"/>
<field name="user_id" select="1" widget="selection">
<filter icon="terp-project" name="my_task" string="My Task" domain="[('user_id','=',uid)]" default="1"/>
<filter icon="terp-project" string="My Task" domain="[('user_id','=',uid)]" default="1"/>
</field>
<newline/>
<group expand="1" string="Extended options..." colspan="10" col="12">
@ -102,7 +102,7 @@
domain="[('priority','=','4')]"/>
</group>
<newline/>
<group expand="1" string="Group By..." >
<group expand="1" string="Group By..." colspan="10" col="11">
<filter string="User" icon="terp-project" context="{'group_by':'user_id'}" />
<filter string="Project" icon="terp-project" context="{'group_by':'project_id'}" />
<filter string="Company" icon="terp-project" context="{'group_by':'company_id'}" />
@ -124,7 +124,6 @@
<field name="view_type">form</field>
<field name="view_mode">tree,graph</field>
<field name="domain">[]</field>
<field name="context">{"search_default_my_task":1}</field>
<field name="search_view_id" ref="view_report_task_search"/>
</record>
<menuitem id="base.menu_project_report" name="Reporting" parent="base.menu_main_pm" sequence="50"/>
@ -163,7 +162,7 @@
</group>
<newline/>
<group expand="1" string="Group By..." colspan="4" col="3">
<filter string="User" name="by_user" icon="terp-project" context="{'group_by':'user_id'}" />
<filter string="User" icon="terp-project" context="{'group_by':'user_id'}" default="1" />
<filter string="Year" icon="terp-project" context="{'group_by':'year'}" />
<filter string="Month" icon="terp-project" context="{'group_by':'month'}" />
</group>
@ -175,7 +174,6 @@
<field name="res_model">report.timesheet.task.user</field>
<field name="view_type">form</field>
<field name="view_mode">tree</field>
<field name="context">{"search_default_by_user":1}</field>
<field name="search_view_id" ref="view_report_timesheet_task_user_search"/>
</record>
<menuitem id="menu_timesheet_task_user" parent="hr.menu_hr_reporting" action="action_report_timesheet_task_user"/>

View File

@ -8,7 +8,7 @@
<field name="inherit_id" ref="base.view_partner_form"/>
<field name="priority">36</field>
<field name="arch" type="xml">
<group name="sale_list" position="after" groups="base.group_extended">
<group name="sale_list" position="after">
<group colspan="2" col="2">
<separator string="Purchases Properties" colspan="2"/>
<field name="property_product_pricelist_purchase"/>

View File

@ -47,11 +47,13 @@
<search string="Purchase Orders">
<group>
<filter icon="terp-purchase"
string="This Year" name="this_year"
string="This Year"
domain="[('name','=',time.strftime('%%Y'))]"
default="1"
help="Purchase orders of the year"/>
<filter icon="terp-purchase"
string="This Month" name="this_month"
string="This Month"
default="1"
domain="[('month','=',time.strftime('%%m'))]"
help="Purchase orders of this month"/>
<separator orientation="vertical"/>
@ -59,7 +61,8 @@
string="Quotations"
domain="[('state','=','draft')]"/>
<filter icon="terp-purchase"
string="Purchase" name="purchase"
string="Purchase"
default="1"
domain="[('state','&lt;&gt;','draft'),('state','&lt;&gt;','cancel')]"/>
<separator orientation="vertical"/>
<field name="user_id" widget="selection">
@ -86,6 +89,8 @@
<filter icon="terp-purchase" string="Cancel" domain="[('state','=','cancel')]"/>
</group>
<newline/>
<separator string="Group by" />
<group expand="1" string="Group By..." colspan="10" col="12">
<filter string="Company" icon="terp-purchase" context="{'group_by':'company_id'}"/>
<filter string="Warehouse" icon="terp-purchase" context="{'group_by':'warehouse_id'}"/>
<filter string="Location" icon="terp-purchase" context="{'group_by':'location_id'}"/>
@ -108,7 +113,6 @@
<field name="res_model">purchase.report</field>
<field name="view_type">form</field>
<field name="view_mode">tree,graph</field>
<field name="context">{"search_default_this_year":1,"search_default_this_month":1,"search_default_purchase":1,"search_default_by_user":1}</field>
<field name="search_view_id" ref="view_purchase_order_search"/>
<field name="context">{'search_default_user_id':True}</field>
</record>

View File

@ -28,7 +28,7 @@
When a purchase order is created, you now have the opportunity to save the related tender.
This new object will regroup and will allow you to easily keep track and order all your purchase orders.
""",
"depends" : ["purchase","mrp"],
"depends" : ["purchase"],
"init_xml" : [],
"demo_xml" : [],
"update_xml" : ["purchase_tender_view.xml","security/ir.model.access.csv","purchase_tender_sequence.xml"],

View File

@ -1,7 +1,7 @@
# -*- encoding: utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Management Solution
# OpenERP, Open Source Management Solution
# Copyright (C) 2004-2008 Tiny SPRL (<http://tiny.be>). All Rights Reserved
# $Id$
#
@ -33,10 +33,8 @@ class purchase_tender(osv.osv):
'date_start': fields.datetime('Date Start'),
'date_end': fields.datetime('Date End'),
'user_id': fields.many2one('res.users', 'Responsible'),
'exclusive': fields.boolean('Exclusive', help="If the tender is exclusive, it will cancel all purchase orders when you confirm one of them"),
'description': fields.text('Description'),
'purchase_ids' : fields.one2many('purchase.order','tender_id','Purchase Orders'),
'line_ids' : fields.one2many('purchase.tender.line','tender_id','Products to Purchase'),
'state': fields.selection([('draft','Draft'),('open','Open'),('close','Close')], 'State', required=True)
}
_defaults = {
@ -46,18 +44,6 @@ class purchase_tender(osv.osv):
}
purchase_tender()
class purchase_tender_line(osv.osv):
_name = "purchase.tender.line"
_description="Purchase Tender Line"
_rec_name = 'product_id'
_columns = {
'product_id': fields.many2one('product.product', 'Product'),
'product_uom_id': fields.many2one('product.uom', 'Product UoM'),
'product_qty': fields.float('Date End', digits=(16,2)),
'tender_id' : fields.many2one('purchase.tender','Purchase Tender', ondelete='cascade')
}
purchase_tender_line()
class purchase_order(osv.osv):
_inherit = "purchase.order"
_description = "purchase order"
@ -67,7 +53,7 @@ class purchase_order(osv.osv):
def wkf_confirm_order(self, cr, uid, ids, context={}):
res = super(purchase_order, self).wkf_confirm_order(cr, uid, ids, context)
for po in self.browse(cr, uid, ids, context):
if po.tender_id and po.tender_id.exclusive:
if po.tender_id:
for order in po.tender_id.purchase_ids:
if order.id<>po.id:
wf_service = netsvc.LocalService("workflow")
@ -75,34 +61,3 @@ class purchase_order(osv.osv):
self.pool.get('purchase.tender').write(cr, uid, [po.tender_id.id], {'state':'close'})
return res
purchase_order()
class product_product(osv.osv):
_inherit = 'product.product'
_columns = {
'purchase_tender': fields.boolean('Purchase Tender', help="Check this box so that requisitions generates purchase tenders instead of directly requests for quotations.")
}
_defaults = {
'purchase_tender': lambda *args: False
}
product_product()
class mrp_procurement(osv.osv):
_inherit = 'mrp.procurement'
def make_po(self, cr, uid, ids, context={}):
res = super(mrp_procurement, self).make_po(cr, uid, ids, context)
for proc_id,po_id in res.items():
procurement = self.browse(cr, uid, proc_id)
if procurement.product_id.purchase_tender:
self.pool.get('purchase.tender').create(cr, uid, {
'name': procurement.name,
'lines_ids': [(0,0,{
'product_id': procurement.product_id.id,
'product_uom_id': procurement.product_uom.id,
'product_qty': procurement.product_qty
})],
'purchase_ids': [(6,0,[po_id])]
})
mrp_procurement()

View File

@ -21,84 +21,82 @@
<field name="inherit_id" ref="purchase.purchase_order_form"/>
<field name="arch" type="xml">
<field name="partner_ref" position="after">
<field name="tender_id"/>
<field name="tender_id" select="2"/>
</field>
</field>
</record>
<record model="ir.ui.view" id="view_purchase_tender_form">
<field name="name">purchase.tender.form</field>
<field name="type">form</field>
<field name="model">purchase.tender</field>
<field name="arch" type="xml">
<form string="Purchase Tender">
<field name="name" select="1"/>
<field name="user_id" select="1"/>
<field name="date_start"/>
<field name="date_end"/>
<notebook colspan="4">
<page string="Products">
<field name="line_ids" colspan="4" nolabel="1">
<tree string="Products" editable="bottom">
<field name="product_id"/>
<field name="product_uom_id"/>
<field name="product_qty"/>
</tree>
<form string="Products" editable="bottom">
<field name="product_id"/>
<field name="product_uom_id"/>
<field name="product_qty"/>
</form>
</field>
</page>
<page string="Notes">
<field name="description" colspan="4" nolabel="1"/>
</page>
<page string="Quotations">
<field name="purchase_ids" nolabel="1" colspan="4"/>
</page>
</notebook>
<field name="state" select="1"/>
</form>
</field>
</record>
<record model="ir.ui.view" id="view_purchase_tender_tree">
<field name="name">purchase.tender.tree</field>
<field name="type">tree</field>
<field name="model">purchase.tender</field>
<field name="arch" type="xml">
<tree string="Purchase Tender">
<field name="name"/>
<field name="user_id"/>
<field name="date_start"/>
<field name="date_end"/>
<field name="state"/>
</tree>
</field>
</record>
<record model="ir.actions.act_window" id="action_purchase_tender">
<field name="name">Purchase Tenders</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">purchase.tender</field>
<field name="view_type">form</field>
</record>
<menuitem id="menu_purchase_Tender_pro_mgt" parent="purchase.menu_procurement_management" action="action_purchase_tender"/>
<record model="ir.ui.view" id="product_normal_form_view_inherit">
<field name="name">product.form.inherit</field>
<field name="type">form</field>
<field name="model">product.product</field>
<field name="inherit_id" ref="product.product_normal_form_view"/>
<field name="arch" type="xml">
<field name="supply_method" position="after">
<group colspan="2" col="2" attrs="{'invisible': [('supply_method','&lt;&gt;','buy')]}">
<field name="purchase_tender"/>
</group>
<record model="ir.ui.view" id="view_purchase_tender_form">
<field name="name">purchase.tender.form</field>
<field name="type">form</field>
<field name="model">purchase.tender</field>
<field name="arch" type="xml">
<form string="Purchase Tender">
<field name="name" select="1"/>
<field name="user_id" select="1"/>
<field name="date_start" select="2"/>
<field name="date_end" select="2"/>
<notebook colspan="4">
<page string="Description">
<field name="description" colspan="4" nolabel="1" select="2"/>
</page>
<page string="Quotations">
<field name="purchase_ids" nolabel="1" colspan="4"/>
</page>
</notebook>
<field name="state" select="1"/>
</form>
</field>
</field>
</record>
</record>
<record model="ir.ui.view" id="view_purchase_tender_tree">
<field name="name">purchase.tender.tree</field>
<field name="type">tree</field>
<field name="model">purchase.tender</field>
<field name="arch" type="xml">
<tree string="Purchase Tender">
<field name="name"/>
<field name="user_id"/>
<field name="date_start"/>
<field name="date_end"/>
<field name="state"/>
</tree>
</field>
</record>
<record model="ir.actions.act_window" id="action_purchase_tender">
<field name="name">Purchase Tenders</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">purchase.tender</field>
<field name="view_type">form</field>
</record>
<!-- <menuitem name="Purchase Tenders" id="menu_purchase_tender" parent="base.menu_purchase_root"/>-->
<!-- <menuitem id="menu_purchase_Tender1" parent="menu_purchase_tender" action="action_purchase_tender"/>-->
<menuitem id="menu_purchase_Tender_pro_mgt" parent="purchase.menu_procurement_management" action="action_purchase_tender"/>
<record model="ir.actions.act_window" id="action_purchase_tender_draft">
<field name="name">Draft Purchase Tenders</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">purchase.tender</field>
<field name="domain">[('state','=','draft')]</field>
<field name="view_type">form</field>
</record>
<!-- <menuitem id="menu_purchase_Tender1_draft" parent="menu_purchase_Tender1" action="action_purchase_tender_draft"/>-->
<record model="ir.actions.act_window" id="action_purchase_tender_open">
<field name="name">Open Purchase Tenders</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">purchase.tender</field>
<field name="domain">[('state','=','open')]</field>
<field name="view_type">form</field>
</record>
<!-- <menuitem id="menu_purchase_Tender1_open" parent="menu_purchase_Tender1" action="action_purchase_tender_open"/>-->
<record model="ir.actions.act_window" id="action_purchase_tender_new">
<field name="name">New Purchase Tenders</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">purchase.tender</field>
<field name="view_type">form</field>
<field name="view_mode">form,tree</field>
</record>
<!-- <menuitem id="menu_purchase_Tender1_new" parent="menu_purchase_tender" action="action_purchase_tender_new"/>-->
</data>
</openerp>

View File

@ -14,7 +14,7 @@ msgstr ""
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Launchpad-Export-Date: 2010-04-08 07:18+0000\n"
"X-Launchpad-Export-Date: 2010-04-07 03:46+0000\n"
"X-Generator: Launchpad (build Unknown)\n"
#. module: report_purchase

View File

@ -10,10 +10,10 @@
<field name="type">search</field>
<field name="arch" type="xml">
<search string="Search Resource">
<group>
<group col='15' colspan='4'>
<field name="name"/>
<field name="user_id" string="User" widget="selection">
<filter domain="[('user_id','=',uid)]" help="My Resouces" icon="gtk-execute" name="my_resources"/>
<filter domain="[('user_id','=',uid)]" help="My Resouces" icon="gtk-execute" default="1"/>
</field>
<field name="resource_type"/>
<field name="company_id" widget="selection"/>
@ -98,7 +98,6 @@
<field name="view_type">form</field>
<field name="view_mode">tree,form</field>
<field name="view_id" eval="False"/>
<field name="context">{"search_default_my_resources":1}</field>
<field name="search_view_id" ref="view_resource_calendar_search"/>
</record>

View File

@ -47,11 +47,13 @@
<search string="Sale Orders">
<group>
<filter icon="terp-sale"
string="This Year" name="this_year"
string="This Year"
domain="[('year','=',time.strftime('%%Y'))]"
default="1"
help="Sales orders of the year"/>
<filter icon="terp-sale"
string="This Month" name="this_month"
string="This Month"
default="1"
domain="[('month','=',time.strftime('%%m'))]"
help="Sales orders of this month"/>
<separator orientation="vertical"/>
@ -59,7 +61,8 @@
string="Quotations"
domain="[('state','=','draft')]"/>
<filter icon="terp-sale"
string="Sales" name="sales"
string="Sales"
default="1"
domain="[('state','&lt;&gt;','draft'),('state','&lt;&gt;','cancel')]"/>
<separator orientation="vertical"/>
<field name="user_id" widget="selection">
@ -70,7 +73,7 @@
<field name="partner_id"/>
<field name="product_id"/>
<field name="company_id" groups="base.group_multi_company" widget="selection"/>
</group>
</group>
<newline/>
<group expand="1" string="Extended options..." colspan="10" col="12">
<filter icon="terp-sale" string="Waiting Schedule" domain="[('state','=','waiting_date')]"/>
@ -83,10 +86,10 @@
</group>
<newline/>
<newline/>
<group expand="1" string="Group By..." >
<group expand="1" string="Group By..." colspan="10" col="12">
<filter string="Company" icon="terp-sale" context="{'group_by':'company_id'}"/>
<filter string="Shop" icon="terp-sale" context="{'group_by':'shop_id'}"/>
<filter string="Salesman" name="by_user" icon="terp-sale" context="{'group_by':'user_id'}" />
<filter string="Salesman" icon="terp-sale" context="{'group_by':'user_id'}" default="1"/>
<separator orientation="vertical"/>
<filter string="Product" icon="terp-sale" context="{'group_by':'product_id'}"/>
<filter string="Partner" icon="terp-sale" context="{'group_by':'partner_id'}"/>
@ -106,7 +109,6 @@
<field name="res_model">sale.report</field>
<field name="view_type">form</field>
<field name="view_mode">tree,graph</field>
<field name="context">{"search_default_this_year":1,"search_default_this_month":1,"search_default_sales":1,"search_default_by_user":1}</field>
<field name="search_view_id" ref="view_order_product_search"/>
</record>

View File

@ -18,7 +18,7 @@
<field name="warehouse_id" required="1" select="1" widget="selection"/>
<separator colspan="4" string="Accounting"/>
<field name="payment_default_id"/>
<field domain="[('type','=','sale')]" name="pricelist_id" select="1" groups="base.group_extended"/>
<field domain="[('type','=','sale')]" name="pricelist_id" select="1"/>
<field name="project_id" select="1"/>
</form>
</field>
@ -31,7 +31,7 @@
<tree string="Sale Shop">
<field name="name"/>
<field name="warehouse_id"/>
<field name="pricelist_id" groups="base.group_extended"/>
<field name="pricelist_id"/>
<field name="project_id"/>
</tree>
</field>
@ -110,9 +110,8 @@
<field domain="[('partner_id','=',partner_id)]" name="partner_order_id"/>
<field domain="[('partner_id','=',partner_id)]" name="partner_invoice_id"/>
<field domain="[('partner_id','=',partner_id)]" name="partner_shipping_id"/>
<field domain="[('type','=','sale')]" name="pricelist_id" groups="base.group_extended"/>
<field name="project_id" select="2"
context="{'partner_id':partner_id, 'contact_id':partner_order_id, 'pricelist_id':pricelist_id, 'default_name':name}"/>
<field domain="[('type','=','sale')]" name="pricelist_id"/>
<field name="project_id" select="2" context="{'partner_id':partner_id, 'contact_id':partner_order_id, 'pricelist_id':pricelist_id, 'default_name':name}"/>
<newline/>
<field colspan="4" mode="tree,form,graph" name="order_line" nolabel="1" widget="one2many_list">
<form string="Sale Order Lines">
@ -260,7 +259,7 @@
<field name="name" select="1"/>
<field name="partner_id" select="1"/>
<field name="user_id" select="1" widget="selection">
<filter icon="terp-partner" name="my_sale" domain="[('user_id','=',uid)]" help="My Sale Orders" />
<filter icon="terp-partner" domain="[('user_id','=',uid)]" help="My Sale Orders" default="1"/>
</field>
<field name="date_order" select="1" string="Order date" />
<newline/>
@ -280,7 +279,6 @@
<field name="res_model">sale.order</field>
<field name="view_type">form</field>
<field name="view_mode">tree,form,calendar,graph</field>
<field name="context">{"search_default_my_sale":1}</field>
<field name="search_view_id" ref="view_sales_order_filter"/>
</record>
<menuitem action="action_order_form" id="menu_sale_order" parent="base.menu_sales" sequence="3"/>
@ -429,7 +427,7 @@
</field>
<newline/>
<group expand="context.get('report',False)" string="Group By..." colspan="9" col="8">
<filter string="Product" icon="terp-sale" domain="[]" context="{'group_by':'product_id'}"/>
<filter string="Product" icon="terp-sale" default="1" domain="[]" context="{'group_by':'product_id'}"/>
<filter string="Order" icon="terp-sale" domain="[]" context="{'group_by':'order_id'}"/>
<filter string="State" icon="terp-sale" domain="[]" context="{'group_by':'state'}"/>
</group>
@ -443,21 +441,19 @@
<field name="type">search</field>
<field name="arch" type="xml">
<search string="Search Uninvoiced Lines">
<group>
<filter icon="terp-purchase" string="Shipped"
domain="[('state','=','done')]"
separator="1" />
<filter icon="terp-purchase" string="Uninvoiced" name="uninvoiced"
domain="[('invoiced','&lt;&gt;', 1),('state','&lt;&gt;','draft'),('state','&lt;&gt;','cancel')]"
<filter icon="terp-purchase" string="Uninvoiced"
domain="[('invoiced','&lt;&gt;', 1),('state','&lt;&gt;','draft'),('state','&lt;&gt;','cancel')]" default="1"
separator="1" />
<separator orientation="vertical"/>
<field name="order_id" select="1"/>
<field name="order_partner_id" select="1"/>
<field name="product_id" select="1"/>
<field name="state" select="1"/>
</group>
<newline />
<group expand="1" string="Group By...">
<group expand="1" string="Group By..." colspan="9" col="8">
<filter string="Product" icon="terp-sale" domain="[]" context="{'group_by':'product_id'}"/>
<filter string="Order" icon="terp-sale" domain="[]" context="{'group_by':'order_id'}"/>
<filter string="State" icon="terp-sale" domain="[]" context="{'group_by':'state'}"/>
@ -472,7 +468,6 @@
<field name="res_model">sale.order.line</field>
<field name="view_type">form</field>
<field name="view_mode">tree,form,graph</field>
<field name="context">{"search_default_uninvoiced":1}</field>
<field name="search_view_id" ref="view_sales_order_uninvoiced_line_filter" />
<field name="filter" eval="True"/>
</record>

View File

@ -14,7 +14,7 @@ msgstr ""
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Launchpad-Export-Date: 2010-04-08 07:18+0000\n"
"X-Launchpad-Export-Date: 2010-04-07 03:46+0000\n"
"X-Generator: Launchpad (build Unknown)\n"
#. module: scrum

View File

@ -100,7 +100,7 @@
<field name="arch" type="xml">
<search string="Product Backlogs">
<group col="10" colspan="4">
<filter name="current"
<filter default="1"
icon="terp-project"
string="Current"
domain="['|','&amp;',('sprint_id.date_start','&lt;=',time.strftime('%%Y-%%m-%%d')), ('sprint_id.date_stop','&gt;=',time.strftime('%%Y-%%m-%%d')), ('state','in',['draft','open'])]"
@ -112,10 +112,10 @@
<field name="name"/>
<field name="project_id"
widget="selection"
/>
default="context.get('project_id', False)"/>
<field name="sprint_id"/>
<field name="user_id" widget="selection">
<filter name="my_features"
<filter default="1"
icon="terp-project"
string="My Features"
domain="[('user_id','=',uid)]"
@ -138,7 +138,6 @@
<field name="name">Product Backlogs</field>
<field name="res_model">scrum.product.backlog</field>
<field name="view_type">form</field>
<field name="context">{"search_default_current":1,"search_default_my_features":1,"search_default_project_id":project_id}</field>
<field name="search_view_id" ref="view_scrum_product_backlog_search"/>
</record>
<menuitem
@ -230,14 +229,15 @@
<field name="arch" type="xml">
<search string="Sprints">
<group col="10" colspan="4">
<filter name="current" icon="terp-project" string="Current" domain="[('state','in',('draft','open'))]" help="Draft and open Sprints"/>
<filter default="1" icon="terp-project" string="Current" domain="[('state','in',('draft','open'))]" help="Draft and open Sprints"/>
<filter icon="terp-project" string="Draft" domain="[('state','=','draft')]" help="Draft Sprints"/>
<filter icon="terp-project" string="Open" domain="[('state','=','open')]" help="Open Sprints"/>
<separator orientation="vertical"/>
<field name="name"/>
<field name="project_id" widget="selection"/>
<field name="scrum_master_id" widget="selection">
<filter icon="gtk-execute" name="my_sprints" domain="[('scrum_master_id','=',uid)]"
<filter icon="gtk-execute" domain="[('scrum_master_id','=',uid)]"
default="1"
help="My Sprints"/>
</field>
<field name="date_start"/>
@ -261,7 +261,6 @@
<field name="view_type">form</field>
<field name="view_mode">tree,form</field>
<field name="view_id" ref="view_scrum_sprint_tree"/>
<field name="context">{"search_default_current":1,"search_default_my_sprints":1}</field>
<field name="search_view_id" ref="view_scrum_sprint_search"/>
</record>
<menuitem
@ -324,7 +323,7 @@
<separator orientation="vertical"/>
<field name="name"/>
<field name="sprint_id">
<filter icon="terp-project" name="current" string="Current" domain="[('sprint_id.state','in',('draft','open'))]" help="Current Sprints"/>
<filter icon="terp-project" string="Current" domain="[('sprint_id.state','in',('draft','open'))]" help="Current Sprints" default="1"/>
</field>
<field name="date"/>
</group>
@ -342,7 +341,6 @@
<field name="res_model">scrum.meeting</field>
<field name="view_type">form</field>
<field name="view_mode">tree,form</field>
<field name="context">{"search_default_current":1}</field>
<field name="search_view_id" ref="view_scrum_meeting_search"/>
</record>
<menuitem sequence="30"
@ -426,7 +424,7 @@
<field name="inherit_id" ref="project.view_task_tree2"/>
<field name="arch" type="xml">
<field name="user_id" position="after">
<field name="sprint_id"/>
<field name="sprint_id" invisible="context.get('sprint_invisible',True)"/>
<field name="product_backlog_id" invisible="1"/>
</field>
</field>

View File

@ -56,6 +56,7 @@ Thanks to the double entry management, the inventory controlling is powerful and
"wizard/stock_traceability_view.xml",
"wizard/stock_picking_make_view.xml",
"wizard/stock_return_picking_view.xml",
"wizard/stock_split_move_view.xml",
"stock_workflow.xml",
"stock_incoterms.xml",
"stock_wizard.xml",

View File

@ -56,9 +56,9 @@
<field name="type">search</field>
<field name="arch" type="xml">
<search string="Search">
<group>
<filter string="This Year" name="this_year" icon="terp-hr" domain="[('name','=',time.localtime()[0])]" />
<filter string="This Month" name="this_month" icon="terp-hr" domain="[('month','=',time.strftime('%%m'))]" />
<group col="16" colspan="6">
<filter string="This Year" icon="terp-hr" domain="[('name','=',time.localtime()[0])]" default="1" />
<filter string="This Month" icon="terp-hr" domain="[('month','=',time.strftime('%%m'))]" default="1"/>
<separator orientation="vertical"/>
<filter string="Current" icon="terp-hr" domain="[('state','in',('open','draft'))]"/>
<filter string="Order Date" icon="terp-stock" domain="[('order_date',=,time.strftime('%%Y-%%m-%%d'))]" />
@ -68,7 +68,7 @@
<field name="origin" />
</group>
<newline/>
<group expand="1" string="Extended options...">
<group expand="1" string="Extended options..." colspan="4" col="5">
<filter icon="terp-sale"
string="Sending Goods"
domain="[('type','=','out')]"/>
@ -83,7 +83,7 @@
domain="[('type','=','delivery')]"/>
</group>
<newline/>
<group expand="1" string="Group By...">
<group expand="1" string="Group By..." colspan="4" col="5">
<filter string="Partner" icon="terp-stock" domain="[]" context="{'group_by':'address_id'}"/>
<filter string="State" icon="terp-stock" domain="[]" context="{'group_by':'state'}"/>
<separator orientation="vertical"/>
@ -99,7 +99,6 @@
<field name="view_type">form</field>
<field name="view_mode">tree,graph</field>
<field name="view_id" ref="view_report_report_stock_picking_tree"/>
<field name="context">{"search_default_this_year":1,"search_default_this_month":1}</field>
<field name="search_view_id" ref="view_report_report_stock_picking_filter"/>
</record>

View File

@ -9,10 +9,10 @@
<field name="arch" type="xml">
<search string="Search Location">
<group col="10" colspan="4">
<filter icon="terp-stock" name="in_location" string="Internal Locations" domain="[('location_id.usage', '=', 'internal')]" help="Internal Locations" />
<filter icon="terp-stock" string="Internal Locations" domain="[('location_id.usage', '=', 'internal')]" help="Internal Locations" default="1" />
<filter icon="terp-stock" string="Customer Locations" domain="[('location_id.usage', '=', 'customer')]" help="Customer Locations" />
<filter icon="terp-stock" string="Supplier Locations" domain="[('location_id.usage', '=', 'supplier')]" help="Supplier Locations" />
<separator orientation="vertical"/>
<field name="location_id" select="1" />
<field name="product_id" select="1" />
@ -61,7 +61,7 @@
<field name="res_model">stock.report.prodlots</field>
<field name="view_type">form</field>
<field name="view_mode">tree,form</field>
<field name="context">{'full':'1',"search_default_in_location":1}</field>
<field name="context">{'full':'1'}</field>
<field name="search_view_id" ref="view_stock_report_prodlots_filter" />
</record>

View File

@ -36,6 +36,8 @@
"access_stock_invoice_onshipping","stock.invoice.onshipping","model_stock_invoice_onshipping","stock.group_stock_user",1,0,0,0
"access_stock_location_product","stock.location.product","model_stock_location_product","stock.group_stock_user",1,0,0,0
"access_report_stock_picking","report.stock.picking","model_report_stock_picking","stock.group_stock_user",1,0,0,0
"access_stock_delivery","stock.delivery","model_stock_delivery","stock.group_stock_user",1,0,0,0
"access_stock_traceability_upstream","stock.traceability.upstream","model_stock_traceability_upstream","stock.group_stock_user",1,0,0,0
"access_stock_traceability_downstream","stock.traceability.downstream","model_stock_traceability_downstream","stock.group_stock_user",1,0,0,0
"access_stock_traceability_lot_upstream","stock.traceability.lot.upstream","model_stock_traceability_lot_upstream","stock.group_stock_user",1,0,0,0
@ -44,4 +46,4 @@
"access_stock_partial_move","stock.partial.move","model_stock_partial_move","stock.group_stock_user",1,0,0,0
"access_stock_picking_make","stock.picking.make","model_stock_picking_make","stock.group_stock_user",1,0,0,0
"access_stock_inventory_merge","stock.inventory.merge","model_stock_inventory_merge","stock.group_stock_user",1,0,0,0
"access_stock_change_standard_price","stock.change.standard.price","model_stock_change_standard_price","stock.group_stock_user",1,0,0,0
"access_stock_change_standard_price","stock.change.standard.price","model_stock_change_standard_price","stock.group_stock_user",1,0,0,0
Can't render this file because it contains an unexpected character in line 45 and column 53.

View File

@ -492,6 +492,7 @@ class stock_picking(osv.osv):
'max_date': fields.function(get_min_max_date, fnct_inv=_set_maximum_date, multi="min_max_date",
method=True, store=True, type='datetime', string='Max. Expected Date', select=2),
'move_lines': fields.one2many('stock.move', 'picking_id', 'Entry lines', states={'done': [('readonly', True)], 'cancel': [('readonly', True)]}),
'delivery_line':fields.one2many('stock.delivery', 'picking_id', 'Delivery lines', readonly=True),
'auto_picking': fields.boolean('Auto-Picking'),
'address_id': fields.many2one('res.partner.address', 'Partner', help="Address of partner"),
'invoice_state': fields.selection([
@ -876,6 +877,7 @@ class stock_picking(osv.osv):
"""
res = {}
move_obj = self.pool.get('stock.move')
delivery_obj = self.pool.get('stock.delivery')
product_obj = self.pool.get('product.product')
currency_obj = self.pool.get('res.currency')
users_obj = self.pool.get('res.users')
@ -1001,6 +1003,14 @@ class stock_picking(osv.osv):
delivered_pack_id = pick.id
delivered_pack = self.browse(cr, uid, delivered_pack_id, context=context)
delivery_id = delivery_obj.create(cr, uid, {
'name': delivered_pack.name,
'partner_id': partner_id,
'address_id': address_id,
'date': delivery_date,
'picking_id' : pick.id,
'move_delivered' : [(6,0, map(lambda x:x.id, delivered_pack.move_lines))]
}, context=context)
res[pick.id] = {'delivered_picking': delivered_pack.id or False}
return res
@ -1102,6 +1112,26 @@ class stock_production_lot_revision(osv.osv):
stock_production_lot_revision()
class stock_delivery(osv.osv):
""" Tracability of partialdeliveries """
_name = "stock.delivery"
_description = "Delivery"
_columns = {
'name': fields.char('Name', size=60, required=True),
'date': fields.datetime('Date', required=True),
'partner_id': fields.many2one('res.partner', 'Partner', required=True),
'address_id': fields.many2one('res.partner.address', 'Address', required=True),
'move_delivered':fields.one2many('stock.move', 'delivered_id', 'Move Delivered'),
'picking_id': fields.many2one('stock.picking', 'Picking list'),
}
stock_delivery()
# ----------------------------------------------------
# Move
# ----------------------------------------------------
#
# Fields:
# location_dest_id is only used for predicting futur stocks
@ -1181,6 +1211,7 @@ class stock_move(osv.osv):
'backorder_id': fields.related('picking_id','backorder_id',type='many2one', relation="stock.picking", string="Back Orders"),
'origin': fields.related('picking_id','origin',type='char', size=64, relation="stock.picking", string="Origin"),
'move_stock_return_history': fields.many2many('stock.move', 'stock_move_return_history', 'move_id', 'return_move_id', 'Move Return History',readonly=True),
'delivered_id': fields.many2one('stock.delivery', 'Product delivered'),
'scraped': fields.boolean('Scraped'),
}
_constraints = [
@ -1772,6 +1803,7 @@ class stock_move(osv.osv):
"""
res = {}
picking_obj = self.pool.get('stock.picking')
delivery_obj = self.pool.get('stock.delivery')
product_obj = self.pool.get('product.product')
currency_obj = self.pool.get('res.currency')
users_obj = self.pool.get('res.users')
@ -1877,6 +1909,18 @@ class stock_move(osv.osv):
done_move_ids = []
for move in complete:
done_move_ids.append(move.id)
if move.picking_id.id not in ref:
delivery_id = delivery_obj.create(cr, uid, {
'partner_id': partner_id,
'address_id': address_id,
'date': delivery_date,
'name' : move.picking_id.name,
'picking_id': move.picking_id.id
}, context=context)
ref[move.picking_id.id] = delivery_id
delivery_obj.write(cr, uid, ref[move.picking_id.id], {
'move_delivered' : [(4,move.id)]
})
return done_move_ids
stock_move()

View File

@ -20,7 +20,7 @@
<field name="prod_lot_id"/>
<button name="%(stock.action_view_stock_inventory_line_split)d"
string="Split inventory lines"
type="action" icon="gtk-justify-fill"/>
type="action" icon="gtk-justify-fill"/>
<field name="location_id"/>
</tree>
</field>
@ -35,7 +35,7 @@
<field name="product_qty"/>
<field name="product_uom"/>
<field name="prod_lot_id"/>
<field colspan="4" domain="[('usage','=','internal')]" name="location_id" select="1"/>
<field colspan="4" domain="[('usage','=','internal')]" name="location_id" select="1"/>
<button name="%(stock.action_view_stock_inventory_line_split)d"
string="Split inventory lines"
type="action" icon="gtk-justify-fill"/>
@ -264,7 +264,7 @@
<field name="arch" type="xml">
<search string="Product Lots Filter">
<group col="10" colspan="4">
<filter icon="terp-stock" name="available" string="Available" domain="[('stock_available', '&gt;', 0)]" help="Available Product Lots" />
<filter icon="terp-stock" string="Available" domain="[('stock_available', '&gt;', 0)]" help="Available Product Lots" default="1" />
<separator orientation="vertical"/>
<field name="prefix" select="1"/>
<field name="name" select="1"/>
@ -287,7 +287,7 @@
<field name="view_type">form</field>
<field name="view_id" ref="view_production_lot_tree"/>
<field name="search_view_id" ref="search_product_lot_filter" />
<field name="context">{'full':'1',"search_default_available":1}</field>
<field name="context">{'full':'1'}</field>
</record>
<menuitem action="action_production_lot_form" id="menu_action_production_lot_form" parent="menu_traceability"/>
@ -426,7 +426,7 @@
</form>
</field>
</record>
<record id="view_location_tree2" model="ir.ui.view">
<field name="name">stock.location.tree</field>
<field name="model">stock.location</field>
@ -585,17 +585,17 @@
<field name="min_date" select="1"/>
<field name="type"/>
<field name="company_id" select="1" groups="base.group_multi_company" widget="selection"/>
<button name="%(act_stock_make_picking_wizard)d"
states="confirmed,assigned"
string="Make Picking"
type="action"
<button name="%(act_stock_make_picking_wizard)d"
states="confirmed,assigned"
string="Make Picking"
type="action"
icon="gtk-go-forward"
help="Make Picking" colspan="2"/>
<button name="%(act_stock_return_picking)d"
states="done"
string="Return Picking"
<button name="%(act_stock_return_picking)d"
states="done"
string="Return Picking"
type="action"
icon="gtk-go-back"
icon="gtk-go-back"
help="Return Picking" colspan="2"/>
</group>
<notebook colspan="4">
@ -619,9 +619,9 @@
states="draft,waiting,confirmed,assigned" />
<button name="%(stock.move_scrap)d"
string="Scrap Products" type="action"
icon="gtk-convert" context="{'scrap': True}"
states="draft,waiting,confirmed,assigned" />
string="Scrap Products" type="action"
icon="gtk-convert" context="{'scrap': True}"
states="draft,waiting,confirmed,assigned" />
</tree>
<form string="Stock Moves">
<notebook colspan="4">
@ -662,6 +662,10 @@
</notebook>
</form>
</field>
<group col="7" colspan="4">
<label colspan="6"/>
<button name="%(act_split_moves)d" string="Split Entry Lines in two" type="action" icon="gtk-justify-fill"/>
</group>
<group col="10" colspan="4">
<field name="state" readonly="1"/>
<button name="draft_force_assign" states="draft" string="Confirm (Do Not Process Now)" type="object" icon="gtk-apply"/>
@ -683,7 +687,7 @@
<newline/>
<field name="move_type"/>
</page>
</notebook>
</notebook>
</form>
</field>
</record>
@ -695,7 +699,7 @@
<field name="arch" type="xml">
<search string="Search Stock Picking">
<group col="10" colspan="4">
<filter icon="terp-stock" name="available" string="Available" domain="[('state','=','assigned')]" help="Available Pickings"/>
<filter icon="terp-stock" string="Available" domain="[('state','=','assigned')]" help="Available Pickings" default="1" />
<filter icon="terp-stock" string="Confirmed" domain="[('state','=','confirmed')]" help="Confirmed Pickings"/>
<separator orientation="vertical"/>
<filter icon="terp-stock" string="Back Order" domain="[('backorder_id', '!=', False)]" help="Has Back Order" />
@ -704,8 +708,8 @@
<field name="location_dest_id" select="1"/>
<field name="name" select="1"/>
<field name="address_id" select="1"/>
</group>
<newline/>
</group>
<newline/>
<group expand="1" string="Group By..." colspan="4" col="8">
<filter string="Partner" icon="terp-stock" domain="[]" context="{'group_by':'address_id'}"/>
<filter string="State" icon="terp-stock" domain="[]" context="{'group_by':'state'}"/>
@ -746,18 +750,19 @@
<field name="backorder_id" select="2" readonly="1"/>
<field name="date" />
<field name="min_date" select="1"/>
<field name="type"/>
<field name="company_id" select="1" groups="base.group_multi_company" widget="selection"/>
<button name="%(act_stock_make_picking_wizard)d"
states="assigned"
string="Make Picking"
type="action"
icon="gtk-go-forward"
<button name="%(act_stock_make_picking_wizard)d"
states="assigned"
string="Make Picking"
type="action"
icon="gtk-go-forward"
help="Make Picking" colspan="2"/>
<button name="%(act_stock_return_picking)d"
states="done"
string="Return Picking"
type="action"
icon="gtk-go-back"
<button name="%(act_stock_return_picking)d"
states="done"
string="Return Picking"
type="action"
icon="gtk-go-back"
help="Return Picking" colspan="2"/>
</group>
<notebook colspan="4">
@ -780,9 +785,9 @@
type="action" icon="gtk-justify-fill"
states="draft,waiting,confirmed,assigned" />
<button name="%(stock.move_scrap)d"
string="Scrap Products" type="action"
icon="gtk-convert" context="{'scrap': True}"
states="draft,waiting,confirmed,assigned" />
string="Scrap Products" type="action"
icon="gtk-convert" context="{'scrap': True}"
states="draft,waiting,confirmed,assigned" />
</tree>
<form string="Stock Moves">
<notebook colspan="4">
@ -818,6 +823,10 @@
</notebook>
</form>
</field>
<group col="7" colspan="4">
<label colspan="6"/>
<button name="%(act_split_moves)d" string="Split in Two" type="action" states="assigned,confirmed,draft,auto" icon="gtk-justify-fill"/>
</group>
<group col="10" colspan="4">
<field name="state" readonly="1"/>
<button name="draft_force_assign" states="draft" string="Process Later" type="object" icon="gtk-ok"/>
@ -839,7 +848,7 @@
<field name="date_done" select="2"/>
<field name="move_type"/>
</page>
</notebook>
</notebook>
</form>
</field>
</record>
@ -851,7 +860,7 @@
<field name="arch" type="xml">
<search string="Search Stock Delivery">
<group col="10" colspan="4">
<filter icon="terp-stock" name="available" string="Available" domain="[('state','=','assigned')]" help="Assigned Orders" />
<filter icon="terp-stock" string="Available" domain="[('state','=','assigned')]" help="Assigned Orders" default="1"/>
<filter icon="terp-stock" string="Confirmed" domain="[('state','=','confirmed')]" help="Confirmed Orders"/>
<separator orientation="vertical"/>
<filter icon="terp-stock" string="Back Order" domain="[('backorder_id','!=',False)]" help="Back Order"/>
@ -859,8 +868,8 @@
<field name="name" select="1"/>
<field name="address_id" select="1"/>
<field name="origin" select="1"/>
</group>
<newline/>
</group>
<newline/>
<group expand="1" string="Group By..." colspan="4" col="10">
<filter string="Partner" icon="terp-stock" domain="[]" context="{'group_by':'address_id'}"/>
<filter string="State" icon="terp-stock" domain="[]" context="{'group_by':'state'}"/>
@ -877,7 +886,7 @@
<field name="view_type">form</field>
<field name="view_mode">tree,form,calendar</field>
<field name="domain">[('type','=','delivery')]</field>
<field name="context">{'contact_display': 'partner',"search_default_available":1}</field>
<field name="context">{'contact_display': 'partner'}</field>
<field name="search_view_id" ref="view_stock_delivery_filter"/>
</record>
<record id="action_picking_tree_delivery_view1" model="ir.actions.act_window.view">
@ -930,23 +939,24 @@
<form string="Picking list">
<group col="6" colspan="4">
<field name="address_id" select="2"/>
<field name="type"/>
<field name="min_date" select="2"/>
<field name="name" select="1" readonly="1"/>
<field name="invoice_state"/>
<field name="backorder_id" select="2" readonly="1"/>
<field name="origin" select="2" readonly="1"/>
<field name="company_id" select="1" groups="base.group_multi_company" widget="selection"/>
<button name="%(act_stock_make_picking_wizard)d"
states="assigned"
string="Make Picking"
type="action"
icon="gtk-go-forward"
<button name="%(act_stock_make_picking_wizard)d"
states="assigned"
string="Make Picking"
type="action"
icon="gtk-go-forward"
help="Make Picking" colspan="2"/>
<button name="%(act_stock_return_picking)d"
states="done"
string="Return Picking"
type="action"
icon="gtk-go-back"
<button name="%(act_stock_return_picking)d"
states="done"
string="Return Picking"
type="action"
icon="gtk-go-back"
help="Return Picking" colspan="2"/>
</group>
<notebook colspan="4">
@ -1010,6 +1020,10 @@
</notebook>
</form>
</field>
<group col="7" colspan="4">
<label colspan="6"/>
<button name="%(act_split_moves)d" string="Split in Two" type="action" icon="gtk-justify-fill"/>
</group>
<group col="10" colspan="4">
<field name="state" readonly="1"/>
<button name="draft_force_assign" states="draft" string="Process Later" type="object" icon="gtk-ok"/>
@ -1020,6 +1034,9 @@
<button name="button_cancel" states="assigned,confirmed,draft" string="Cancel" icon="gtk-cancel"/>
</group>
</page>
<page string="Delivery Info">
<field colspan="4" name="delivery_line" nolabel="1"/>
</page>
<page string="Notes">
<field colspan="4" name="note" nolabel="1"/>
</page>
@ -1049,8 +1066,8 @@
<field name="name" select="1"/>
<field name="address_id" select="1"/>
<field name="company_id" select="1" widget="selection"/>
</group>
<newline/>
</group>
<newline/>
<group expand="1" string="Group By..." colspan="4" col="8">
<filter string="Partner" icon="terp-stock" domain="[]" context="{'group_by':'address_id'}"/>
<filter string="State" icon="terp-stock" domain="[]" context="{'group_by':'state'}"/>
@ -1122,18 +1139,19 @@
<field name="date"/>
<field name="min_date" select="2" readonly="1"/>
<field name="invoice_state" select="2" string="Invoice Control"/>
<field name="type"/>
<field name="company_id" select="1" groups="base.group_multi_company" widget="selection"/>
<button name="%(act_stock_make_picking_wizard)d"
states="confirmed,assigned"
string="Make Picking"
type="action"
icon="gtk-go-forward"
<button name="%(act_stock_make_picking_wizard)d"
states="confirmed,assigned"
string="Make Picking"
type="action"
icon="gtk-go-forward"
help="Make Picking" colspan="2"/>
<button name="%(act_stock_return_picking)d"
states="done"
string="Return Picking"
type="action"
icon="gtk-go-back"
<button name="%(act_stock_return_picking)d"
states="done"
string="Return Picking"
type="action"
icon="gtk-go-back"
help="Return Picking" colspan="2"/>
</group>
<notebook colspan="4">
@ -1152,9 +1170,9 @@
type="action" icon="gtk-justify-fill"
states="draft,waiting,confirmed,assigned" />
<button name="%(stock.move_scrap)d"
string="Scrap Products" type="action"
icon="gtk-convert" context="{'scrap': True}"
states="draft,waiting,confirmed,assigned" />
string="Scrap Products" type="action"
icon="gtk-convert" context="{'scrap': True}"
states="draft,waiting,confirmed,assigned" />
</tree>
<form string="Stock Moves">
<notebook colspan="4">
@ -1209,6 +1227,9 @@
<button name="button_cancel" states="assigned,confirmed,draft" string="Cancel" icon="gtk-cancel"/>
</group>
</page>
<page string="Delivery Info">
<field colspan="4" name="delivery_line" nolabel="1"/>
</page>
<page string="Notes">
<field colspan="4" name="note" nolabel="1"/>
</page>
@ -1224,15 +1245,15 @@
<field name="arch" type="xml">
<search string="Input Picking List">
<group col="8" colspan="4">
<filter icon="terp-stock" name="available" string="Available" domain="[('state','=','assigned')]" help="Assigned Incoming Orders" />
<filter icon="terp-stock" string="Available" domain="[('state','=','assigned')]" help="Assigned Incoming Orders" default="1" />
<separator orientation="vertical"/>
<filter icon="terp-stock" string="Back Order" domain="[('backorder_id', '!=', False)]" help="Has Back Order" />
<separator orientation="vertical"/>
<field name="name" select="1"/>
<field name="address_id" select="1"/>
<field name="company_id" select="1" widget="selection" groups="base.group_multi_company" />
</group>
<newline/>
</group>
<newline/>
<group expand="1" string="Group By..." colspan="4" col="8">
<filter string="Partner" icon="terp-stock" domain="[]" context="{'group_by':'address_id'}"/>
<filter string="Date" icon="terp-stock" domain="[]" context="{'group_by':'date'}"/>
@ -1244,13 +1265,13 @@
<record id="action_picking_tree4" model="ir.actions.act_window">
<field name="name">Incoming Shipments</field>
<field name="name">Incoming shipments</field>
<field name="res_model">stock.picking</field>
<field name="type">ir.actions.act_window</field>
<field name="view_type">form</field>
<field name="view_mode">tree,form,calendar</field>
<field name="domain">[('type','=','in')]</field>
<field name="context">{'contact_display': 'partner',"search_default_available":1}</field>
<field name="context">{'contact_display': 'partner'}</field>
<field name="search_view_id" ref="view_picking_in_search"/>
</record>
<record id="action_invoice_tree5_view1" model="ir.actions.act_window.view">
@ -1280,13 +1301,13 @@
<search string="Internal Picking List">
<group col="8" colspan="4">
<filter icon="terp-stock" string="Available" domain="[('state','=','assigned')]" help="Assigned Internal Moves"/>
<filter icon="terp-stock" name="confirmed" string="Confirmed" domain="[('state','=','confirmed')]" help="Confirmed Internal Moves" />
<filter icon="terp-stock" string="Confirmed" domain="[('state','=','confirmed')]" help="Confirmed Internal Moves" default="1" />
<separator orientation="vertical"/>
<field name="name" select="1"/>
<field name="origin" select="1"/>
<field name="company_id" select="1" widget="selection"/>
</group>
<newline/>
</group>
<newline/>
<group expand="1" string="Group By..." colspan="4" col="8">
<filter string="Partner" icon="terp-stock" domain="[]" context="{'group_by':'address_id'}"/>
<filter string="Date" icon="terp-stock" domain="[]" context="{'group_by':'date'}"/>
@ -1303,7 +1324,7 @@
<field name="view_type">form</field>
<field name="view_mode">tree,form,calendar</field>
<field name="domain">[('type','=','internal')]</field>
<field name="context">{'contact_display': 'partner',"search_default_confirmed":1}</field>
<field name="context">{'contact_display': 'partner'}</field>
<field name="search_view_id" ref="view_picking_internal_search"/>
</record>
<menuitem action="action_picking_tree6" id="menu_action_picking_tree6" parent="menu_stock_warehouse_mgmt" sequence="2"/>
@ -1343,6 +1364,7 @@
<group colspan="2" col="2">
<separator colspan="2" string="Move Information"/>
<field name="name" select="2"/>
<field name="delivered_id"/>
<field name="product_id" select="1" on_change="onchange_product_id(product_id,location_id,location_dest_id)"/>
<field name="product_qty" select="2" on_change="onchange_quantity(product_id, product_qty, product_uom, product_uos)"/>
<field name="product_uom" select="2"/>
@ -1405,8 +1427,8 @@
<field name="location_id" select="1"/>
<field name="location_dest_id" select="1"/>
<field name="product_id" select="1"/>
</group>
<newline/>
</group>
<newline/>
<group expand="1" string="Group By..." colspan="4" col="8">
<filter string="Product" icon="terp-stock" domain="[]" context="{'group_by':'product_id'}"/>
<filter string="Date" icon="terp-stock" domain="[]" context="{'group_by':'date'}"/>
@ -1427,6 +1449,24 @@
</record>
<menuitem action="action_move_form2" id="menu_action_move_form2" parent="menu_traceability" sequence="1"/>
<record id="action_picking_all" model="ir.actions.act_window">
<field name="name">Picking lists</field>
<field name="res_model">stock.picking</field>
<field name="type">ir.actions.act_window</field>
<field name="view_type">form</field>
<field name="view_mode">tree,form,calendar</field>
<field name="search_view_id" ref="view_stock_picking_filter"/>
<field name="domain">[('type','=','out')]</field>
<field name="context">{'contact_display': 'partner'}</field>
</record>
<record id="action_picking_out_tree_view" model="ir.actions.act_window.view">
<field eval="1" name="sequence"/>
<field name="view_mode">tree</field>
<field name="view_id" ref="view_picking_out_tree"/>
<field name="act_window_id" ref="action_picking_all"/>
</record>
<menuitem action="action_picking_all" id="menu_action_picking_all" parent="menu_stock_warehouse_mgmt" sequence="3"/>
====================================
Reception Picking (By Stock Move)
====================================
@ -1464,6 +1504,7 @@
<notebook colspan="4">
<page string="General Information">
<separator colspan="4" string="Move Information"/>
<field name="delivered_id"/>
<field name="location_id" select="1"/>
<field name="location_dest_id" select="1"/>
<field colspan="4" name="product_id" select="1" on_change="onchange_product_id(product_id,location_id,location_dest_id)"/>
@ -1513,15 +1554,15 @@
<field name="arch" type="xml">
<search string="Stock Moves">
<group col="8" colspan="4">
<filter icon="terp-stock" name="receive" string="To Receive" domain="[('state','in',('confirmed','assigned'))]" help="Stock to be received"/>
<filter icon="terp-stock" string="To Receive" domain="[('state','in',('confirmed','assigned'))]" default="1" help="Stock to be received"/>
<filter icon="terp-stock" string="Back Orders" domain="[('backorder_id','!=',False)]" help="Back Orders"/>
<filter icon="terp-stock" string="Planned Today" domain="[('date_planned::date','=',time.strftime('%%Y-%%m-%%d'))]" help="Orders planned for today"/>
<separator orientation="vertical"/>
<field name="origin" string="Latest Requisition" select="1"/>
<field name="partner_id" string="Supplier" select="1"/>
<field name="product_id"/>
</group>
<newline/>
</group>
<newline/>
<group expand="1" string="Group By..." colspan="4" col="8">
<filter string="Product" icon="terp-stock" domain="[]" context="{'group_by':'product_id'}"/>
<filter string="State" icon="terp-stock" domain="[]" context="{'group_by':'state'}"/>
@ -1539,7 +1580,6 @@
<field name="view_mode">tree,form</field>
<field name="domain">[('picking_id','!=',False),('picking_id.type','=','in')]</field>
<field name="view_id" ref="view_move_tree_reception_picking"/>
<field name="context">{"search_default_receive":1}</field>
<field name="search_view_id" ref="view_move_search_reception_picking"/>
</record>
@ -1713,6 +1753,56 @@
<field name="view_mode">graph,tree</field>
<field name="view_id" ref="view_move_delivery_products_planned_graph"/>
</record>
<!-- Product Delivered -->
<record id="view_stock_delivery_form" model="ir.ui.view">
<field name="name">stock.delivery.from</field>
<field name="model">stock.delivery</field>
<field name="type">form</field>
<field name="arch" type="xml">
<form string="Product">
<field name="name"/>
<field name="date"/>
<field name="partner_id"/>
<field name="address_id"/>
<field name="picking_id"/>
<separator string="Product Delivered Information" colspan="4" />
<field name="move_delivered" colspan="4" nolabel="1" widget="one2many" mode="tree,form">
<tree string="Stock Moves" editable="top">
<field name="picking_id" string="Reference"/>
<field name="origin" string="Latest Requisition"/>
<field name="partner_id" string="Supplier"/>
<field name="product_id"/>
<field name="product_qty" />
<field name="product_uom" string="UOM"/>
<field name="prodlot_id" string="Lot"/>
</tree>
</field>
</form>
</field>
</record>
<record id="view_stock_delivery_tree" model="ir.ui.view">
<field name="name">stock.delivery.tree</field>
<field name="model">stock.delivery</field>
<field name="type">tree</field>
<field name="arch" type="xml">
<tree string="Delivered Product">
<field name="name"/>
<field name="date"/>
<field name="partner_id"/>
<field name="address_id"/>
</tree>
</field>
</record>
<record id="action_stock_delivery" model="ir.actions.act_window">
<field name="name">Delivered Products</field>
<field name="res_model">stock.delivery</field>
<field name="type">ir.actions.act_window</field>
<field name="view_type">form</field>
<field name="view_mode">form,tree</field>
<field name="view_id" ref="view_stock_delivery_tree"/>
</record>
<menuitem action="action_stock_delivery" id="menu_action_picking_all" parent="menu_traceability" sequence="4"/>
</data>
</openerp>

View File

@ -26,6 +26,7 @@ import stock_partial_move
import stock_picking_make
import wizard_replacement
import stock_return_picking
import stock_split_move
import wizard_ups
import stock_inventory_merge
import stock_inventory_set_stock_zero

View File

@ -27,19 +27,22 @@ import pooler
import time
class stock_partial_move(osv.osv_memory):
_name = "stock.partial.move"
_description = "Partial Move"
_name = "stock.partial.move"
_description = "Partial Move"
_columns = {
'date': fields.datetime('Date', required=True),
}
'date': fields.datetime('Date', required=True),
'partner_id': fields.many2one('res.partner',string="Partner", required=True),
'address_id': fields.many2one('res.partner.address', 'Delivery Address', help="Address where goods are to be delivered", required=True),
}
def view_init(self, cr, uid, fields_list, context=None):
res = super(stock_partial_move, self).view_init(cr, uid, fields_list, context=context)
move_obj = self.pool.get('stock.move')
move_obj = self.pool.get('stock.move')
if not context:
context={}
moveids = []
for m in move_obj.browse(cr, uid, context.get('active_ids', [])):
for m in move_obj.browse(cr, uid, context.get('active_ids', [])):
if m.state in ('done', 'cancel'):
continue
if 'move%s_product_id'%(m.id) not in self._columns:
@ -54,53 +57,55 @@ class stock_partial_move(osv.osv_memory):
self._columns['move%s_product_price'%(m.id)] = fields.float("Price")
if 'move%s_product_currency'%(m.id) not in self._columns:
self._columns['move%s_product_currency'%(m.id)] = fields.many2one('res.currency',string="Currency")
return res
return res
def fields_view_get(self, cr, uid, view_id=None, view_type='form', context=None, toolbar=False,submenu=False):
result = super(stock_partial_move, self).fields_view_get(cr, uid, view_id, view_type, context, toolbar,submenu)
result = super(stock_partial_move, self).fields_view_get(cr, uid, view_id, view_type, context, toolbar,submenu)
move_obj = self.pool.get('stock.move')
move_ids = context.get('active_ids', False)
move_ids = context.get('active_ids', False)
move_ids = move_obj.search(cr, uid, [('id','in',move_ids)])
_moves_arch_lst = """<form string="Deliver Products">
<separator colspan="4" string="Information"/>
<separator colspan="4" string="Delivery Information"/>
<field name="date" colspan="4" />
<field name="partner_id"/>
<field name="address_id"/>
<newline/>
<separator colspan="4" string="Move Detail"/>
"""
_moves_fields = result['fields']
if move_ids and view_type in ['form']:
for m in move_obj.browse(cr, uid, move_ids, context):
if move_ids and view_type in ['form']:
for m in move_obj.browse(cr, uid, move_ids, context):
if m.state in ('done', 'cancel'):
continue
_moves_fields.update({
'move%s_product_id'%(m.id) : {
'string': _('Product'),
'type' : 'many2one',
'relation': 'product.product',
'required' : True,
'readonly' : True,
'type' : 'many2one',
'relation': 'product.product',
'required' : True,
'readonly' : True,
},
'move%s_product_qty'%(m.id) : {
'string': _('Quantity'),
'type' : 'float',
'required': True,
'required': True,
},
'move%s_product_uom'%(m.id) : {
'string': _('Product UOM'),
'type' : 'many2one',
'relation': 'product.uom',
'required' : True,
'readonly' : True,
'type' : 'many2one',
'relation': 'product.uom',
'required' : True,
'readonly' : True,
}
})
})
_moves_arch_lst += """
<group colspan="4" col="10">
<field name="move%s_product_id" nolabel="1"/>
<field name="move%s_product_qty" string="Qty" />
<field name="move%s_product_uom" nolabel="1" />
"""%(m.id, m.id, m.id)
if (m.picking_id.type == 'in') and (m.product_id.cost_method == 'average'):
if (m.picking_id.type == 'in') and (m.product_id.cost_method == 'average'):
_moves_fields.update({
'move%s_product_price'%(m.id) : {
'string': _('Price'),
@ -108,9 +113,9 @@ class stock_partial_move(osv.osv_memory):
},
'move%s_product_currency'%(m.id): {
'string': _('Currency'),
'type' : 'float',
'type' : 'many2one',
'relation': 'res.currency',
'type' : 'float',
'type' : 'many2one',
'relation': 'res.currency',
}
})
_moves_arch_lst += """
@ -131,31 +136,31 @@ class stock_partial_move(osv.osv_memory):
</group>
</form>"""
result['arch'] = _moves_arch_lst
result['fields'] = _moves_fields
result['fields'] = _moves_fields
return result
def default_get(self, cr, uid, fields, context=None):
"""
"""
To get default values for the object.
@param self: The object pointer.
@param cr: A database cursor
@param uid: ID of the user currently logged in
@param fields: List of fields for which we want default values
@param context: A standard dictionary
@return: A dictionary which of fields with values.
"""
@param fields: List of fields for which we want default values
@param context: A standard dictionary
@return: A dictionary which of fields with values.
"""
res = super(stock_partial_move, self).default_get(cr, uid, fields, context=context)
move_obj = self.pool.get('stock.move')
move_obj = self.pool.get('stock.move')
if not context:
context={}
moveids = []
if 'date' in fields:
res.update({'date': time.strftime('%Y-%m-%d %H:%M:%S')})
for m in move_obj.browse(cr, uid, context.get('active_ids', [])):
for m in move_obj.browse(cr, uid, context.get('active_ids', [])):
if m.state in ('done', 'cancel'):
continue
if 'move%s_product_id'%(m.id) in fields:
@ -173,21 +178,23 @@ class stock_partial_move(osv.osv_memory):
currency = False
if hasattr(m.picking_id, 'purchase_id') and m.picking_id.purchase_id:
currency = m.picking_id.purchase_id.pricelist_id.currency_id.id
if 'move%s_product_price'%(m.id) in fields:
res['move%s_product_price'%(m.id)] = price
if 'move%s_product_currency'%(m.id) in fields:
res['move%s_product_currency'%(m.id)] = currency
return res
return res
def do_partial(self, cr, uid, ids, context):
move_obj = self.pool.get('stock.move')
def do_partial(self, cr, uid, ids, context):
move_obj = self.pool.get('stock.move')
move_ids = context.get('active_ids', False)
partial = self.browse(cr, uid, ids[0], context)
partial_datas = {
'delivery_date' : partial.date
'partner_id' : partial.partner_id and partial.partner_id.id or False,
'address_id' : partial.address_id and partial.address_id.id or False,
'delivery_date' : partial.date
}
for m in move_obj.browse(cr, uid, move_ids):
for m in move_obj.browse(cr, uid, move_ids):
if m.state in ('done', 'cancel'):
continue
partial_datas['move%s'%(m.id)] = {
@ -196,14 +203,15 @@ class stock_partial_move(osv.osv_memory):
'product_uom' : getattr(partial, 'move%s_product_uom'%(m.id)).id
}
if (m.picking_id.type == 'in') and (m.product_id.cost_method == 'average'):
partial_datas['move%s'%(m.id)].update({
if (m.picking_id.type == 'in') and (m.product_id.cost_method == 'average'):
partial_datas['move%s'%(m.id)].update({
'product_price' : getattr(partial, 'move%s_product_price'%(m.id)),
'product_currency': getattr(partial, 'move%s_product_currency'%(m.id)).id
})
})
res = move_obj.do_partial(cr, uid, move_ids, partial_datas, context=context)
return {}
stock_partial_move()
stock_partial_move()
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:

View File

@ -0,0 +1,125 @@
# -*- coding: utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Management Solution
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as
# published by the Free Software Foundation, either version 3 of the
# License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
##############################################################################
from osv import osv, fields
class stock_split_move_line(osv.osv_memory):
_name = 'stock.move.line.split'
_description = "Split Moves"
def default_get(self, cr, uid, fields, context):
"""
To get default values for the object.
@param self: The object pointer.
@param cr: A database cursor
@param uid: ID of the user currently logged in
@param fields: List of fields for which we want default values
@param context: A standard dictionary
@return: A dictionary which of fields with values.
"""
res = super(stock_split_move_line, self).default_get(cr, uid, fields, context=context)
record_id = context and context.get('active_id', False) or False
pick_obj = self.pool.get('stock.picking')
pick = pick_obj.browse(cr, uid, record_id)
for m in [line for line in pick.move_lines]:
res['move%s'%(m.id)] = m.product_qty
return res
def view_init(self, cr, uid, fields_list, context=None):
"""
Creates view dynamically and adding fields at runtime.
@param self: The object pointer.
@param cr: A database cursor
@param uid: ID of the user currently logged in
@param context: A standard dictionary
@return: New arch of view with new columns.
"""
res = super(stock_split_move_line, self).view_init(cr, uid, fields_list, context=context)
record_id = context and context.get('active_id', False) or False
if record_id:
pick_obj = self.pool.get('stock.picking')
try:
pick = pick_obj.browse(cr, uid, record_id)
for m in [line for line in pick.move_lines]:
if 'move%s' % m.id not in self._columns:
self._columns['move%s' % m.id] = fields.float(string=m.product_id.name)
except:
return res
return res
def fields_view_get(self, cr, uid, view_id=None, view_type='form',
context=None, toolbar=False, submenu=False):
"""
Changes the view dynamically
@param self: The object pointer.
@param cr: A database cursor
@param uid: ID of the user currently logged in
@param context: A standard dictionary
@return: New arch of view.
"""
res = super(stock_split_move_line, self).fields_view_get(cr, uid, view_id=view_id, view_type=view_type, context=context, toolbar=toolbar,submenu=False)
record_id = context and context.get('active_id', False) or False
assert record_id,'Active ID not found'
pick_obj = self.pool.get('stock.picking')
pick = pick_obj.browse(cr, uid, record_id)
arch_lst = ['<?xml version="1.0"?>', '<form string="Split lines">', '<label string="Indicate here the quantity of the new line. A quantity of zero will not split the line." colspan="4"/>']
for m in [line for line in pick.move_lines]:
quantity = m.product_qty
arch_lst.append('<field name="move%s" />\n<newline />' % (m.id,))
res['fields']['move%s' % m.id] = {'string' : m.product_id.name, 'type' : 'float', 'required' : True}
arch_lst.append('<group col="2" colspan="4">')
arch_lst.append('<button icon="gtk-cancel" special="cancel" string="Cancel" />')
arch_lst.append('<button name="split_lines" string="Split" colspan="1" type="object" icon="gtk-apply" />')
arch_lst.append('</group>')
arch_lst.append('</form>')
res['arch'] = '\n'.join(arch_lst)
return res
def split_lines(self, cr, uid, ids, context):
"""
Splits moves in quantity given in the wizard.
@param self: The object pointer.
@param cr: A database cursor
@param uid: ID of the user currently logged in
@param ids: List of ids selected
@param context: A standard dictionary
@return: A dictionary which of fields with values.
"""
move_obj = self.pool.get('stock.move')
record_id = context and context.get('active_id', False) or False
pick_obj = self.pool.get('stock.picking')
pick = pick_obj.browse(cr, uid, record_id)
data = self.read(cr, uid, ids[0])
move_ids = [m.id for m in [line for line in pick.move_lines]]
for move in move_obj.browse(cr, uid, move_ids):
quantity = data['move%s' % move.id]
if 0 < quantity < move.product_qty:
new_qty = move.product_qty - quantity
new_uos_qty = new_qty / move.product_qty * move.product_uos_qty
new_obj = move_obj.copy(cr, uid, move.id, {'product_qty' : new_qty, 'product_uos_qty': new_uos_qty, 'state':move.state})
uos_qty = quantity / move.product_qty * move.product_uos_qty
move_obj.write(cr, uid, [move.id], {'product_qty' : quantity, 'product_uos_qty': uos_qty})
return {}
stock_split_move_line()
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:

View File

@ -1,6 +1,17 @@
<?xml version="1.0" encoding="utf-8"?>
<openerp>
<data>
</data>
</openerp>
<!-- Split Moves -->
<record id="act_split_moves" model="ir.actions.act_window">
<field name="name">Split Moves</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">stock.move.line.split</field>
<field name="view_type">form</field>
<field name="view_mode">form</field>
<field name="target">new</field>
</record>
</data>
</openerp>

View File

@ -1,695 +0,0 @@
# Chinese (Simplified) translation for openobject-addons
# Copyright (c) 2010 Rosetta Contributors and Canonical Ltd 2010
# This file is distributed under the same license as the openobject-addons package.
# FIRST AUTHOR <EMAIL@ADDRESS>, 2010.
#
msgid ""
msgstr ""
"Project-Id-Version: openobject-addons\n"
"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
"POT-Creation-Date: 2009-11-26 06:01+0000\n"
"PO-Revision-Date: 2010-04-08 01:37+0000\n"
"Last-Translator: Silence <Unknown>\n"
"Language-Team: Chinese (Simplified) <zh_CN@li.org>\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Launchpad-Export-Date: 2010-04-09 03:56+0000\n"
"X-Generator: Launchpad (build Unknown)\n"
#. module: survey
#: model:ir.ui.menu,name:survey.menu_survey_form
msgid "Surveys"
msgstr "调查"
#. module: survey
#: model:ir.actions.report.xml,name:survey.survey
msgid "Survey Analysis Report"
msgstr "调查分析报告"
#. module: survey
#: model:ir.actions.act_window,name:survey.act_survey_page_question
#: model:ir.ui.menu,name:survey.menu_survey_question_form1
msgid "Survey Questions"
msgstr "调查问题"
#. module: survey
#: view:survey:0
#: view:survey.response:0
msgid "Set to draft"
msgstr "设为草稿"
#. module: survey
#: constraint:ir.actions.act_window:0
msgid "Invalid model name in the action definition."
msgstr "在动作定义使用了无效的模型名称。"
#. module: survey
#: field:survey.history,date:0
msgid "Date started"
msgstr "开始日期"
#. module: survey
#: field:survey,history:0
msgid "History Lines"
msgstr "日志明细"
#. module: survey
#: wizard_field:wizard.send.invitation,init,mail:0
msgid "Body"
msgstr "内容"
#. module: survey
#: model:ir.actions.act_window,name:survey.action_view_survey_name
#: model:ir.ui.menu,name:survey.menu_run_survey_form
msgid "Give Survey Response"
msgstr "调查回答"
#. module: survey
#: model:ir.actions.act_window,name:survey.act_survey_question
msgid "All Questions"
msgstr "所有问题"
#. module: survey
#: field:survey,date_open:0
msgid "Survey Open Date"
msgstr "调查开展日期"
#. module: survey
#: model:ir.model,name:survey.model_survey_name_wiz
msgid "survey.name.wiz"
msgstr ""
#. module: survey
#: view:survey:0
msgid "Users Details"
msgstr "用户详细信息"
#. module: survey
#: model:ir.actions.act_window,name:survey.action_view_survey_question_message
#: model:ir.model,name:survey.model_survey_question
#: view:survey:0
#: view:survey.page:0
#: view:survey.question:0
msgid "Survey Question"
msgstr "调查问题"
#. module: survey
#: help:survey,response_user:0
msgid "Set to one if you require only one response per user"
msgstr "如果你只需要每个用户回答设为1"
#. module: survey
#: field:survey.page,title:0
msgid "Page Title"
msgstr "页面标题"
#. module: survey
#: model:ir.model,name:survey.model_survey_history
msgid "Survey History"
msgstr "调查历史"
#. module: survey
#: field:survey.response,comment:0
#: field:survey.response.answer,comment:0
msgid "Notes"
msgstr "备注"
#. module: survey
#: field:survey.question,tot_resp:0
msgid "Total Response"
msgstr "回答合计"
#. module: survey
#: view:survey.question.wiz:0
msgid "Your Messages"
msgstr "你的消息"
#. module: survey
#: selection:survey,state:0
msgid "Cancelled"
msgstr "已取消"
#. module: survey
#: field:survey.question,allow_comment:0
msgid "Allow Comment Field"
msgstr "允许注释字段"
#. module: survey
#: code:addons/survey/survey.py:0
#, python-format
msgid "Warning !"
msgstr "警告!"
#. module: survey
#: wizard_view:wizard.send.invitation,init:0
#: wizard_field:wizard.send.invitation,init,send_mail_existing:0
msgid "Send reminder for existing user"
msgstr "为现有用户发送提醒"
#. module: survey
#: model:ir.actions.act_window,name:survey.action_new_survey_question_form
#: model:ir.ui.menu,name:survey.menu_new_survey_question_form1
msgid "New Survey Question"
msgstr "新的调查问题"
#. module: survey
#: view:survey.response:0
msgid "Skip"
msgstr "跳过"
#. module: survey
#: wizard_field:wizard.send.invitation,init,partner_ids:0
msgid "Partner"
msgstr "伙伴"
#. module: survey
#: wizard_field:wizard.send.invitation,init,mail_subject:0
#: wizard_field:wizard.send.invitation,init,mail_subject_existing:0
msgid "Subject"
msgstr "主题"
#. module: survey
#: field:survey,max_response_limit:0
msgid "Maximum Response Limit"
msgstr ""
#. module: survey
#: wizard_field:wizard.send.invitation,init,mail_from:0
msgid "From"
msgstr "发件人"
#. module: survey
#: field:survey.response,response_type:0
msgid "Response Type"
msgstr ""
#. module: survey
#: field:survey.name.wiz,transfer:0
msgid "Page Transfer"
msgstr ""
#. module: survey
#: field:survey.answer,question_id:0
#: field:survey.page,question_ids:0
#: field:survey.question,question:0
#: field:survey.response,question_id:0
msgid "Question"
msgstr ""
#. module: survey
#: wizard_button:wizard.send.invitation,init,send:0
msgid "Send"
msgstr ""
#. module: survey
#: field:survey.answer,response:0
msgid "#Response"
msgstr ""
#. module: survey
#: field:survey.response,response_answer_ids:0
msgid "Response Answer"
msgstr ""
#. module: survey
#: rml:survey_analysis_report:0
msgid "Response Summary"
msgstr ""
#. module: survey
#: wizard_view:wizard.send.invitation,init:0
#: wizard_field:wizard.send.invitation,init,send_mail:0
msgid "Send mail for new user"
msgstr ""
#. module: survey
#: code:addons/survey/survey.py:0
#, python-format
msgid "Error !"
msgstr ""
#. module: survey
#: rml:survey_analysis_report:0
msgid "Skipped Question"
msgstr ""
#. module: survey
#: wizard_button:wizard.send.invitation,send,end:0
msgid "_Ok"
msgstr ""
#. module: survey
#: selection:survey.response,response_type:0
msgid "Link"
msgstr ""
#. module: survey
#: model:ir.ui.menu,name:survey.menu_survey_config
msgid "Configuration"
msgstr ""
#. module: survey
#: model:ir.model,name:survey.model_survey_question_wiz
msgid "survey.question.wiz"
msgstr ""
#. module: survey
#: constraint:ir.ui.view:0
msgid "Invalid XML for View Architecture!"
msgstr ""
#. module: survey
#: model:ir.model,name:survey.model_survey_response_answer
#: view:survey.response.answer:0
msgid "Survey Response Answer"
msgstr ""
#. module: survey
#: rml:survey_analysis_report:0
msgid "Page :-"
msgstr ""
#. module: survey
#: field:survey,response_user:0
msgid "Maximum Response per User"
msgstr ""
#. module: survey
#: rml:survey_analysis_report:0
msgid "Total Started Survey :-"
msgstr ""
#. module: survey
#: view:survey.response:0
msgid "Comment"
msgstr ""
#. module: survey
#: field:survey.response,date_modify:0
msgid "Modify Date"
msgstr ""
#. module: survey
#: rml:survey_analysis_report:0
msgid "Answered Question"
msgstr ""
#. module: survey
#: code:addons/survey/survey.py:0
#, python-format
msgid "You can not give response for this survey more than %s times"
msgstr ""
#. module: survey
#: selection:survey.response,response_type:0
msgid "Manually"
msgstr ""
#. module: survey
#: model:ir.actions.act_window,name:survey.action_survey_form1
msgid "All Surveys"
msgstr ""
#. module: survey
#: view:survey:0
#: field:survey,users:0
msgid "Users"
msgstr ""
#. module: survey
#: wizard_view:wizard.send.invitation,init:0
msgid "Message"
msgstr ""
#. module: survey
#: field:survey.name.wiz,page_no:0
msgid "Page Number"
msgstr ""
#. module: survey
#: wizard_field:wizard.send.invitation,send,note:0
msgid "Log"
msgstr ""
#. module: survey
#: model:ir.actions.act_window,name:survey.action_survey_question_form
msgid "All Survey Questions"
msgstr ""
#. module: survey
#: field:survey,date_close:0
msgid "Survey Close Date"
msgstr ""
#. module: survey
#: view:survey.name.wiz:0
msgid "Start"
msgstr ""
#. module: survey
#: selection:survey,state:0
#: selection:survey.response,state:0
msgid "Draft"
msgstr ""
#. module: survey
#: selection:survey,state:0
msgid "Closed"
msgstr ""
#. module: survey
#: view:survey:0
#: field:survey.answer,answer:0
#: view:survey.page:0
#: view:survey.question:0
#: field:survey.question,answer_choice_ids:0
#: field:survey.response.answer,answer_id:0
msgid "Answer"
msgstr ""
#. module: survey
#: model:ir.actions.act_window,name:survey.action_survey_page_form
msgid "All Survey Pages"
msgstr ""
#. module: survey
#: field:survey.name.wiz,store_ans:0
msgid "Store Answer"
msgstr ""
#. module: survey
#: field:survey,state:0
#: field:survey.response,state:0
msgid "Status"
msgstr ""
#. module: survey
#: model:ir.module.module,shortdesc:survey.module_meta_information
msgid "Survey Module"
msgstr ""
#. module: survey
#: model:ir.module.module,description:survey.module_meta_information
msgid ""
"\n"
" This module is used for surveing. It depends on the answers or reviews "
"of some questions by different users.\n"
" A survey may have multiple pages. Each page may contain multiple "
"questions and each question may have multiple answers.\n"
" Different users may give different answers of question and according to "
"that survey is done. \n"
" Partners are also sent mails with user name and password for the "
"invitation of the survey\n"
" "
msgstr ""
#. module: survey
#: view:survey:0
#: view:survey.name.wiz:0
msgid "Survey Details"
msgstr ""
#. module: survey
#: field:survey.question,is_require_answer:0
msgid "Required Answer"
msgstr ""
#. module: survey
#: field:survey.history,user_id:0
#: field:survey.response,response_id:0
msgid "User"
msgstr ""
#. module: survey
#: field:res.users,survey_id:0
msgid "Groups"
msgstr ""
#. module: survey
#: view:survey:0
#: view:survey.page:0
#: view:survey.question:0
#: field:survey.question,response_ids:0
#: view:survey.response:0
#: field:survey.response.answer,response_id:0
msgid "Response"
msgstr ""
#. module: survey
#: model:ir.actions.act_window,name:survey.action_new_survey_form1
#: model:ir.ui.menu,name:survey.menu_new_survey_form
msgid "New Survey"
msgstr ""
#. module: survey
#: model:ir.ui.menu,name:survey.main_menu_survey
msgid "Survey Management"
msgstr ""
#. module: survey
#: selection:survey.response,state:0
msgid "Skiped"
msgstr ""
#. module: survey
#: model:ir.model,name:survey.model_survey_answer
#: view:survey.answer:0
msgid "Survey Answer"
msgstr ""
#. module: survey
#: code:addons/survey/wizard/wizard_survey.py:0
#, python-format
msgid "Attention!"
msgstr ""
#. module: survey
#: model:ir.model,name:survey.model_survey
#: view:res.users:0
#: view:survey:0
#: field:survey.history,survey_id:0
#: view:survey.name.wiz:0
#: field:survey.name.wiz,survey_id:0
#: field:survey.page,survey_id:0
#: field:survey.question,survey:0
msgid "Survey"
msgstr ""
#. module: survey
#: rml:survey_analysis_report:0
msgid "Total Completed Survey :-"
msgstr ""
#. module: survey
#: view:survey:0
msgid "History"
msgstr ""
#. module: survey
#: view:survey:0
#: view:survey.answer:0
#: view:survey.page:0
#: view:survey.question:0
msgid "Seq"
msgstr ""
#. module: survey
#: field:survey,tot_comp_survey:0
msgid "Total Completed Survey"
msgstr ""
#. module: survey
#: rml:survey_analysis_report:0
msgid "Response Percentage"
msgstr ""
#. module: survey
#: field:survey.question.wiz,name:0
msgid "Number"
msgstr ""
#. module: survey
#: rml:survey_analysis_report:0
msgid "Survey Title :-"
msgstr ""
#. module: survey
#: view:survey.response:0
msgid "Done"
msgstr ""
#. module: survey
#: code:addons/survey/survey.py:0
#, python-format
msgid "'\" + que_rec[0]['question'] + \"' This question requires an answer."
msgstr ""
#. module: survey
#: view:survey:0
#: view:survey.name.wiz:0
#: wizard_button:wizard.send.invitation,init,end:0
msgid "Cancel"
msgstr ""
#. module: survey
#: view:survey:0
msgid "Close"
msgstr ""
#. module: survey
#: view:survey:0
#: selection:survey,state:0
msgid "Open"
msgstr ""
#. module: survey
#: field:survey,tot_start_survey:0
msgid "Total Started Survey"
msgstr ""
#. module: survey
#: constraint:ir.model:0
msgid ""
"The Object name must start with x_ and not contain any special character !"
msgstr ""
#. module: survey
#: model:ir.model,name:survey.model_survey_response
#: view:survey.response:0
msgid "Survey Response"
msgstr ""
#. module: survey
#: field:survey.answer,average:0
msgid "#Avg"
msgstr ""
#. module: survey
#: field:survey,responsible_id:0
msgid "Responsible"
msgstr ""
#. module: survey
#: selection:survey.response,state:0
msgid "Answered"
msgstr ""
#. module: survey
#: view:survey:0
msgid "Other"
msgstr ""
#. module: survey
#: model:ir.actions.wizard,name:survey.wizard_send_invitation
#: wizard_view:wizard.send.invitation,init:0
msgid "Send Invitation"
msgstr ""
#. module: survey
#: field:survey,title:0
msgid "Survey Title"
msgstr ""
#. module: survey
#: rml:survey_analysis_report:0
msgid "%"
msgstr ""
#. module: survey
#: view:survey:0
#: field:survey,note:0
#: field:survey.name.wiz,note:0
#: view:survey.page:0
#: field:survey.page,note:0
#: view:survey.response:0
msgid "Description"
msgstr ""
#. module: survey
#: view:survey.name.wiz:0
msgid "Select Survey"
msgstr ""
#. module: survey
#: model:ir.actions.act_window,name:survey.action_new_survey_page_form
#: model:ir.ui.menu,name:survey.menu_new_survey_page_form1
msgid "New Survey Page"
msgstr ""
#. module: survey
#: view:survey:0
#: view:survey.page:0
#: field:survey.question,page_id:0
msgid "Survey Page"
msgstr ""
#. module: survey
#: model:ir.actions.act_window,name:survey.act_survey_answer
msgid "Survey Answers"
msgstr ""
#. module: survey
#: view:survey.page:0
msgid "#Questions"
msgstr ""
#. module: survey
#: rml:survey_analysis_report:0
msgid "Que:"
msgstr ""
#. module: survey
#: field:survey,page_ids:0
msgid "Page"
msgstr ""
#. module: survey
#: wizard_view:wizard.send.invitation,send:0
msgid "User creation"
msgstr ""
#. module: survey
#: field:survey.answer,sequence:0
#: field:survey.page,sequence:0
#: field:survey.question,sequence:0
msgid "Sequence"
msgstr ""
#. module: survey
#: wizard_view:wizard.send.invitation,send:0
msgid "Results :"
msgstr ""
#. module: survey
#: code:addons/survey/wizard/wizard_survey.py:0
#, python-format
msgid "%sSurvey is not in open state"
msgstr ""
#. module: survey
#: wizard_view:wizard.send.invitation,init:0
msgid "Select Partner"
msgstr ""
#. module: survey
#: field:survey.response,date_create:0
msgid "Create Date"
msgstr ""
#. module: survey
#: model:ir.actions.act_window,name:survey.act_survey_pages
#: model:ir.model,name:survey.model_survey_page
#: model:ir.ui.menu,name:survey.menu_survey_page_form1
msgid "Survey Pages"
msgstr ""
#. module: survey
#: rml:survey_analysis_report:0
msgid "Response Count"
msgstr ""
#. module: survey
#: field:survey.name.wiz,page:0
msgid "Page Position"
msgstr ""

View File

@ -95,46 +95,6 @@ class survey(osv.osv):
def copy(self, cr, uid, id, default=None,context={}):
raise osv.except_osv(_('Warning !'),_('You cannot duplicate the resource!'))
def action_print_survey(self, cr, uid, ids, context=None):
"""
If response is available then print this response otherwise print survey form(print template of the survey).
@param self: The object pointer
@param cr: the current row, from the database cursor,
@param uid: the current users ID for security checks,
@param ids: List of Survey IDs
@param context: A standard dictionary for contextual values
@return : Dictionary value for print survey form.
"""
if not context:
context = {}
datas = {}
response_id = self.pool.get('survey.response').search(cr, uid, [('survey_id','=', ids)], context=context)
page_setting = {'orientation': 'vertical', 'without_pagebreak': 0, 'paper_size': 'letter', 'page_number': 1, 'survey_title': 1}
report = {}
datas['ids'] = ids
if response_id:
context.update({'survey_id': datas['ids']})
datas['form'] = page_setting
datas['model'] = 'survey.print.answer'
report = {
'type': 'ir.actions.report.xml',
'report_name': 'survey.browse.response',
'datas': datas,
'nodestroy': True,
'context' : context
}
else:
datas['form'] = page_setting
datas['model'] = 'survey.print'
report = {
'type': 'ir.actions.report.xml',
'report_name': 'survey.form',
'datas': datas,
'nodestroy':True,
'context' : context
}
return report
survey()
class survey_history(osv.osv):

View File

@ -243,8 +243,8 @@
string="Answer Survey" type="action" icon="gtk-execute" context="{'survey_id': active_id}" attrs="{'invisible':[('state','!=','open')]}"/>
<button name="%(action_view_survey_question_message)d" states="open,draft,close,cancel"
string="Edit Survey" type="action" icon="gtk-edit" context="{'active':True,'edit' : True,'survey_id': active_id}"/>
<button name="action_print_survey" states="open,draft,close,cancel"
string="Print Answer" type="object" icon="gtk-print"/>
<button name="%(survey_browse_response)d" states="open,draft,close,cancel"
string="Print Answer" type="action" icon="gtk-print"/>
</tree>
</field>
</record>
@ -261,7 +261,7 @@
<separator orientation="vertical"/>
<field name="title" select="1"/>
<field name="type" select="1" widget="selection"/>
<field name="responsible_id" select="1" widget="selection" >
<field name="responsible_id" select="1" widget="selection" default="1">
<filter string="MY" icon="terp-partner" domain="[('responsible_id','=',uid)]"/>
</field>
</group>
@ -1071,7 +1071,7 @@
<separator orientation="vertical"/>
<field name="survey_id" widget="selection" select="1"/>
<field name="email" select="1"/>
<field name="user_id" select="1" widget="selection" >
<field name="user_id" select="1" widget="selection" default="1">
<filter string="MY" icon="terp-partner" domain="[('user_id','=',uid)]"/>
</field>
</group>

View File

@ -1,85 +0,0 @@
# Chinese (Simplified) translation for openobject-addons
# Copyright (c) 2010 Rosetta Contributors and Canonical Ltd 2010
# This file is distributed under the same license as the openobject-addons package.
# FIRST AUTHOR <EMAIL@ADDRESS>, 2010.
#
msgid ""
msgstr ""
"Project-Id-Version: openobject-addons\n"
"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
"POT-Creation-Date: 2009-11-26 06:05+0000\n"
"PO-Revision-Date: 2010-04-08 00:41+0000\n"
"Last-Translator: Silence <Unknown>\n"
"Language-Team: Chinese (Simplified) <zh_CN@li.org>\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Launchpad-Export-Date: 2010-04-08 07:18+0000\n"
"X-Generator: Launchpad (build Unknown)\n"
#. module: thunderbird
#: field:tinythunderbird.partner,copy_to:0
msgid "Copy To"
msgstr "复制到"
#. module: thunderbird
#: constraint:ir.model:0
msgid ""
"The Object name must start with x_ and not contain any special character !"
msgstr "对象名必须是以x_开头并且不能含有特殊字符"
#. module: thunderbird
#: field:tinythunderbird.partner,description:0
msgid "Description"
msgstr "描述"
#. module: thunderbird
#: field:tinythunderbird.partner,reference:0
msgid "Reference"
msgstr "参考"
#. module: thunderbird
#: model:ir.model,name:thunderbird.model_tinythunderbird_partner
msgid "Thunderbid mails"
msgstr ""
#. module: thunderbird
#: field:tinythunderbird.partner,attachments:0
msgid "Attached Files"
msgstr "添加附件"
#. module: thunderbird
#: field:tinythunderbird.partner,res_user_id:0
msgid "User"
msgstr "用户"
#. module: thunderbird
#: field:tinythunderbird.partner,receiver:0
msgid "Receiver"
msgstr "收件人"
#. module: thunderbird
#: field:tinythunderbird.partner,date:0
msgid "Date"
msgstr "日期"
#. module: thunderbird
#: field:tinythunderbird.partner,title:0
msgid "Subject"
msgstr "主题"
#. module: thunderbird
#: code:addons/thunderbird/partner/partner.py:0
#, python-format
msgid "Archive"
msgstr "存档"
#. module: thunderbird
#: model:ir.module.module,shortdesc:thunderbird.module_meta_information
msgid "Thunderbird Interface"
msgstr "Thunderbird接口"
#. module: thunderbird
#: field:tinythunderbird.partner,sender:0
msgid "Sender"
msgstr "发件人"