[MERGE]
authoruco (Open ERP) <uco@tinyerp.com>
Thu, 19 Aug 2010 13:16:56 +0000 (18:46 +0530)
committeruco (Open ERP) <uco@tinyerp.com>
Thu, 19 Aug 2010 13:16:56 +0000 (18:46 +0530)
bzr revid: uco@tinyerp.com-20100819131656-05g7tso6gfelxs2h

233 files changed:
addons/account/__openerp__.py
addons/account/account.py
addons/account/account_analytic_line.py
addons/account/account_assert_test.xml
addons/account/account_bank_statement.py
addons/account/account_cash_statement.py
addons/account/account_invoice_view.xml
addons/account/account_invoice_workflow.xml
addons/account/account_menuitem.xml
addons/account/account_move_line.py
addons/account/account_report.xml
addons/account/account_view.xml
addons/account/account_wizard.xml
addons/account/board_account_demo.xml
addons/account/company_view.xml
addons/account/configurable_account_chart.xml
addons/account/demo/account_minimal.xml
addons/account/installer.py
addons/account/invoice.py
addons/account/partner_view.xml
addons/account/process/customer_invoice_process.xml
addons/account/project/project_report.xml
addons/account/project/project_view.xml
addons/account/project/wizard/account_analytic_balance_report.py
addons/account/project/wizard/account_analytic_chart.py
addons/account/project/wizard/account_analytic_check.py
addons/account/project/wizard/account_analytic_cost_ledger_for_journal_report.py
addons/account/project/wizard/account_analytic_cost_ledger_report.py
addons/account/project/wizard/account_analytic_inverted_balance_report.py
addons/account/project/wizard/account_analytic_journal_report.py
addons/account/project/wizard/project_account_analytic_line.py
addons/account/project/wizard/project_account_analytic_line_view.xml
addons/account/report/account_aged_partner_balance.py
addons/account/report/account_balance.py
addons/account/report/account_balance_landscape.py
addons/account/report/account_balance_sheet.py
addons/account/report/account_report.py
addons/account/report/account_report_view.xml
addons/account/report/compare_account_balance.py
addons/account/report/rml_parse.py
addons/account/report/tax_report.py
addons/account/wizard/__init__.py
addons/account/wizard/account_automatic_reconcile.py
addons/account/wizard/account_chart.py
addons/account/wizard/account_compare_account_balance_report.py
addons/account/wizard/account_fiscalyear_close.py
addons/account/wizard/account_fiscalyear_close_state.py
addons/account/wizard/account_invoice_state_view.xml
addons/account/wizard/account_move_bank_reconcile.py
addons/account/wizard/account_move_journal.py
addons/account/wizard/account_move_line_reconcile_select.py
addons/account/wizard/account_move_line_reconcile_select_view.xml
addons/account/wizard/account_move_line_select_view.xml
addons/account/wizard/account_move_line_unreconcile_select.py
addons/account/wizard/account_move_line_unreconcile_select_view.xml
addons/account/wizard/account_open_closed_fiscalyear.py
addons/account/wizard/account_open_closed_fiscalyear_view.xml
addons/account/wizard/account_pay_invoice.py
addons/account/wizard/account_pay_invoice_view.xml
addons/account/wizard/account_period_close.py
addons/account/wizard/account_reconcile.py
addons/account/wizard/account_reconcile_partner_process.py
addons/account/wizard/account_reconcile_partner_process_view.xml
addons/account/wizard/account_reconcile_view.xml
addons/account/wizard/account_report_account_balance.py
addons/account/wizard/account_report_account_balance_view.xml
addons/account/wizard/account_report_aged_partner_balance.py
addons/account/wizard/account_report_balance_sheet.py
addons/account/wizard/account_report_balance_sheet_view.xml
addons/account/wizard/account_report_central_journal.py
addons/account/wizard/account_report_central_journal_view.xml
addons/account/wizard/account_report_common_account.py
addons/account/wizard/account_report_common_journal.py
addons/account/wizard/account_report_common_partner.py
addons/account/wizard/account_report_common_view.xml
addons/account/wizard/account_report_general_journal_view.xml
addons/account/wizard/account_report_partner_ledger.py
addons/account/wizard/account_report_print_journal.py
addons/account/wizard/account_report_profit_loss.py
addons/account/wizard/account_statement_from_invoice.py
addons/account/wizard/account_statement_from_invoice_view.xml
addons/account/wizard/account_subscription_generate.py
addons/account/wizard/account_use_model.py
addons/account/wizard/account_use_model_view.xml
addons/account/wizard/account_validate_account_move.py
addons/account_analytic_analysis/account_analytic_analysis.py
addons/account_budget/__openerp__.py
addons/account_budget/account_budget_wizard.xml
addons/account_budget/crossovered_budget_report.xml
addons/account_budget/crossovered_budget_view.xml
addons/account_budget/crossovered_budget_workflow.xml
addons/account_budget/report/analytic_account_budget_report.py
addons/account_budget/report/crossovered_budget_report.py
addons/account_cancel/account_cancel_view.xml
addons/account_followup/account_followup_view.xml
addons/account_followup/report/account_followup_report.py
addons/account_followup/wizard/account_followup_print.py
addons/account_followup/wizard/account_followup_print_view.xml
addons/account_invoice_layout/account_invoice_layout.py
addons/account_payment/account_move_line.py
addons/account_payment/wizard/account_payment_pay.py
addons/account_report/account.py
addons/account_report/account_view.xml
addons/account_report/account_wizard.xml
addons/account_report/report/accounting_report.py
addons/account_report/report/print_indicator.py
addons/account_reporting/account.py
addons/account_reporting/account_report.xml
addons/account_reporting/report/account_report_bs.py
addons/account_tax_include/account_tax_include.py
addons/account_voucher/report/report_voucher.py
addons/account_voucher/report/rml_parse.py
addons/account_voucher/voucher_view.xml
addons/account_voucher/voucher_wizard.xml
addons/account_voucher_payment/wizard/account_voucher_unreconcile_view.xml
addons/analytic_journal_billing_rate/analytic_journal_billing_rate_view.xml
addons/analytic_user_function/analytic_user_function.py
addons/auction/__openerp__.py
addons/auction/auction.py
addons/auction/auction_demo.xml
addons/auction/auction_report.xml
addons/auction/auction_wizard.xml
addons/auction/board_auction_demo.xml
addons/auction/board_auction_view.xml
addons/auction/report/__init__.py
addons/auction/report/ach_bordereau_photo.xml
addons/auction/report/buyer_form_report.py
addons/auction/report/catalog2.py
addons/auction/report/deposit.xml
addons/auction/report/huissier.py
addons/auction/report/report_auction.py
addons/auction/report/report_auction_view.xml
addons/auction/report/seller_form_report.py
addons/auction/report/total.py
addons/auction/wizard/auction_aie_send.py
addons/auction/wizard/auction_lots_auction_move.py
addons/auction/wizard/auction_lots_invoice.py
addons/auction/wizard/auction_pay_sel.py
addons/audittrail/audittrail.py
addons/audittrail/wizard/audittrail_view_log.py
addons/base_calendar/base_calendar.py
addons/base_contact/process/base_contact_process.xml
addons/base_module_doc_rst/base_module_doc_rst.py
addons/base_module_doc_rst/report/report_proximity_graph.py
addons/base_module_doc_rst/wizard/wizard_tech_guide_rst.py
addons/base_module_quality/base_module_quality.py
addons/base_module_quality/pylint_test/pylint_test.py
addons/base_module_quality/structure_test/structure_test.py
addons/base_report_creator/base_report_creator.py
addons/base_report_creator/wizard/wiz_set_filter_fields.py
addons/base_report_designer/wizard/tiny_sxw2rml/tiny_sxw2rml.py
addons/base_setup/__openerp__.py
addons/base_setup/base_setup_demo.xml
addons/base_setup/base_setup_todo.xml
addons/base_setup/todo.py
addons/base_vat/base_vat.py
addons/caldav/caldav_node.py
addons/caldav/calendar.py
addons/crm/board_crm_demo.xml
addons/crm/crm_view.xml
addons/crm/report/crm_phonecall_report_view.xml
addons/crm/report/report_businessopp.py
addons/crm/wizard/crm_merge_opportunities_view.xml
addons/crm/wizard/crm_partner_to_opportunity.py
addons/crm_claim/report/crm_claim_report_view.xml
addons/crm_fundraising/report/crm_fundraising_report_view.xml
addons/crm_profiling/crm_profiling_demo.xml
addons/crm_profiling/crm_profiling_wizard.xml
addons/delivery/__init__.py
addons/document/document_directory.py
addons/document_ftp/__openerp__.py
addons/document_ftp/ftpserver/abstracted_fs.py
addons/document_ftp/ftpserver/ftpserver.py
addons/document_ftp/wizard/ftp_browse.py
addons/document_ics/document_ics.py
addons/document_webdav/dav_fs.py
addons/document_webdav/webdav.py
addons/document_webdav/webdav_server.py
addons/email_template/email_template_mailbox_view.xml
addons/email_template/wizard/email_template_send_wizard_view.xml
addons/event/board_association_view.xml
addons/event/event_view.xml
addons/event/report/report_event_registration_view.xml
addons/event/wizard/event_make_invoice.py
addons/fetchmail/fetchmail.py
addons/google_map/google_map.py
addons/hr/hr_department.py
addons/hr/hr_view.xml
addons/hr_attendance/report/attendance_errors.py
addons/hr_attendance/wizard/hr_attendance_byweek_view.xml
addons/hr_evaluation/hr_evaluation_demo.xml
addons/hr_evaluation/hr_evaluation_view.xml
addons/hr_expense/__openerp__.py
addons/hr_expense/hr_expense.py
addons/hr_expense/hr_expense_workflow.xml
addons/hr_holidays/__openerp__.py
addons/hr_holidays/hr_holidays.py
addons/hr_holidays/hr_holidays_view.xml
addons/hr_holidays/hr_holidays_workflow.xml
addons/hr_holidays/report/holidays_summary_report.py
addons/hr_payroll/hr_payroll.py
addons/hr_payroll/hr_payroll_view.xml
addons/hr_payroll/report/rml_parse.py
addons/hr_payroll/wizard/hr_payroll_create_analytic.xml
addons/hr_payroll_account/hr_payroll_account.py
addons/hr_recruitment/__openerp__.py
addons/hr_recruitment/hr_recruitment.py
addons/hr_recruitment/hr_recruitment_view.xml
addons/hr_recruitment/wizard/hr_recruitment_phonecall.py
addons/hr_recruitment/wizard/hr_recruitment_phonecall_view.xml
addons/hr_timesheet/hr_timesheet_report.xml
addons/hr_timesheet/hr_timesheet_view.xml
addons/hr_timesheet/hr_timesheet_wizard.xml
addons/hr_timesheet/process/hr_timesheet_process.xml
addons/hr_timesheet/wizard/hr_timesheet_print_employee_view.xml
addons/hr_timesheet_invoice/hr_timesheet_invoice_report.xml
addons/hr_timesheet_invoice/hr_timesheet_invoice_wizard.xml
addons/hr_timesheet_invoice/report/hr_timesheet_invoice_report_view.xml
addons/hr_timesheet_invoice/report/report_analytic_view.xml
addons/hr_timesheet_invoice/wizard/hr_timesheet_invoice_analytic_cost_ledger_view.xml
addons/hr_timesheet_invoice/wizard/hr_timesheet_invoice_create.py
addons/hr_timesheet_sheet/board_hr_timesheet_view.xml
addons/hr_timesheet_sheet/hr_timesheet_sheet_demo.xml
addons/hr_timesheet_sheet/hr_timesheet_sheet_view.xml
addons/idea/security/idea_security.xml
addons/l10n_be/account_pcmn_belgium.xml
addons/l10n_be/wizard/l10_be_partner_vat_listing.py
addons/l10n_ch/partner.py
addons/l10n_ch/wizard/create_dta.py
addons/l10n_ch_chart_c2c_pcg/account.xml
addons/l10n_chart_uk_minimal/l10n_uk_chart.xml
addons/mrp/mrp.py
addons/stock/stock.py

index f061234..3923add 100644 (file)
@@ -45,7 +45,6 @@ module named account_voucher.
     'init_xml': [],
     "depends" : ["product", "analytic", "process","board"],
     'update_xml': [
-        #'test/test_parent_structure.yml',
         'security/account_security.xml',
         'security/ir.model.access.csv',
         'account_menuitem.xml',
@@ -80,7 +79,6 @@ module named account_voucher.
         'wizard/account_invoice_state_view.xml',
         'wizard/account_report_partner_balance_view.xml',
         'wizard/account_report_account_balance_view.xml',
-#        'wizard/account_move_line_select_view.xml',
         'wizard/account_report_aged_partner_balance_view.xml',
         'wizard/account_compare_account_balance_report_view.xml',
         'wizard/account_report_partner_ledger_view.xml',
@@ -120,7 +118,6 @@ module named account_voucher.
         "wizard/account_report_balance_sheet_view.xml"
     ],
     'demo_xml': [
-        #'demo/price_accuracy00.yml',
         'account_demo.xml',
         'project/project_demo.xml',
         'project/analytic_account_demo.xml',
@@ -135,7 +132,6 @@ module named account_voucher.
         'test/chart_of_account.yml',
         'test/account_period_close.yml',
         'test/account_fiscalyear_close_state.yml',
-        #'test/account_invoice_state.yml',
         'test/account_use_model.yml',
         'test/account_validate_account_move.yml',
         'test/account_fiscalyear_close.yml',
index 40695d9..a82c395 100644 (file)
@@ -686,14 +686,6 @@ class account_journal(osv.osv):
                 'sequence_id':seq_id
             })
 
-#        if journal.type in journal_type and not journal.invoice_sequence_id:
-#            res_ids = date_pool.search(cr, uid, [('model','=','ir.sequence'), ('name','=',journal_seq.get(journal.type, 'sale'))])
-#            inv_seq_id = date_pool.browse(cr, uid, res_ids[0]).res_id
-#            inv_seq_id
-#            res.update({
-#                'invoice_sequence_id':inv_seq_id
-#            })
-
         result = self.write(cr, uid, [journal.id], res)
 
         return result
@@ -701,16 +693,6 @@ class account_journal(osv.osv):
     def create(self, cr, uid, vals, context={}):
         journal_id = super(account_journal, self).create(cr, uid, vals, context)
         self.create_sequence(cr, uid, [journal_id], context)
-
-#       journal_name = self.browse(cr, uid, [journal_id])[0].code
-#       periods = self.pool.get('account.period')
-#       ids = periods.search(cr, uid, [('date_stop','>=',time.strftime('%Y-%m-%d'))])
-#       for period in periods.browse(cr, uid, ids):
-#           self.pool.get('account.journal.period').create(cr, uid, {
-#               'name': (journal_name or '')+':'+(period.code or ''),
-#               'journal_id': journal_id,
-#               'period_id': period.id
-#           })
         return journal_id
 
     def name_search(self, cr, user, name, args=None, operator='ilike', context=None, limit=100):
@@ -724,7 +706,6 @@ class account_journal(osv.osv):
         if name:
             ids = self.search(cr, user, [('code', 'ilike', name)]+ args, limit=limit, context=context)
         if not ids:
-#            ids = self.search(cr, user, [('name', operator, name)]+ args, limit=limit, context=context)
             ids = self.search(cr, user, [('name', 'ilike', name)]+ args, limit=limit, context=context)#fix it ilike should be replace with operator
 
         return self.name_get(cr, user, ids, context=context)
@@ -1412,8 +1393,6 @@ class account_move(osv.osv):
                 self.pool.get('account.move.line').write(cr, uid, line_ids, {
                     'journal_id': move.journal_id.id,
                     'period_id': move.period_id.id,
-                    #'tax_code_id': False,
-                    #'tax_amount': False,
                     'state': 'draft'
                 }, context, check=False)
         # Create analytic lines for the valid moves
@@ -1896,8 +1875,6 @@ class account_tax(osv.osv):
                 amount = localdict['result']
             elif tax.type=='balance':
                 amount = cur_price_unit - reduce(lambda x,y: y.get('amount',0.0)+x, res, 0.0)
-#                data['balance'] = cur_price_unit
-
 
             if tax.include_base_amount:
                 cur_price_unit -= amount
@@ -2250,12 +2227,8 @@ class account_add_tmpl_wizard(osv.osv_memory):
         data= self.read(cr, uid, ids)
         company_id = acc_obj.read(cr, uid, [data[0]['cparent_id']], ['company_id'])[0]['company_id'][0]
         account_template = tmpl_obj.browse(cr, uid, context['tmpl_ids'])
-        #tax_ids = []
-        #for tax in account_template.tax_ids:
-        #    tax_ids.append(tax_template_ref[tax.id])
         vals={
             'name': account_template.name,
-            #'sign': account_template.sign,
             'currency_id': account_template.currency_id and account_template.currency_id.id or False,
             'code': account_template.code,
             'type': account_template.type,
@@ -2264,7 +2237,6 @@ class account_add_tmpl_wizard(osv.osv_memory):
             'shortcut': account_template.shortcut,
             'note': account_template.note,
             'parent_id': data[0]['cparent_id'],
-            # 'tax_ids': [(6,0,tax_ids)], todo!!
             'company_id': company_id,
             }
         new_account = acc_obj.create(cr, uid, vals)
@@ -2581,7 +2553,6 @@ class wizard_multi_charts_accounts(osv.osv_memory):
                 code_acc=str(code_acc) + (str('0'*(dig-code_main)))
             vals={
                 'name': (obj_acc_root.id == account_template.id) and obj_multi.company_id.name or account_template.name,
-                #'sign': account_template.sign,
                 'currency_id': account_template.currency_id and account_template.currency_id.id or False,
                 'code': code_acc,
                 'type': account_template.type,
index 1792525..36fc350 100644 (file)
@@ -42,7 +42,7 @@ class account_analytic_line(osv.osv):
     _defaults = {
         'date': lambda *a: time.strftime('%Y-%m-%d'),
         'company_id': lambda self,cr,uid,c: self.pool.get('res.company')._company_default_get(cr, uid, 'account.analytic.line', context=c),
-                }
+    }
     _order = 'date'
 
     def search(self, cr, uid, args, offset=0, limit=None, order=None, context=None, count=False):
@@ -65,7 +65,6 @@ class account_analytic_line(osv.osv):
                 return False
         return True
     _constraints = [
-#        (_check_company, 'You can not create analytic line that is not in the same company than the account line', ['account_id'])
     ]
 
     # Compute the cost based on the price type define into company
index 585c6bd..ba5f984 100644 (file)
@@ -4,25 +4,5 @@
         <assert model="account.move" search="[]" string="For all Ledger Postings, the state is valid implies that the sum of credits equals the sum of debits">
             <test expr="not len(line_id) or line_id[0].state != 'valid' or (sum([l.debit - l.credit for l in line_id]) &lt;= 0.00001)"/>
         </assert>
-
-
-   <!--     <assert model="account.account" search="[]" string="For all accounts, the balance is equal to the sum of the balance of its childs">
-        <assert model="account.account" search="[]" string="For all accounts, the balance is equal to the sum of the balance of its childs">
-            <test expr="not len(child_id) or (balance - sum([c.balance for c in child_id]) &lt;= 0.00001)"/>
-        </assert>
-
-        <assert model="account.move.line" search="[('account_id.type', '=', 'view')]" string="Accounts of view type do not contain any move line">
-            <test expr="False"/>
-        </assert>
-
-        <assert model="account.invoice" search="[('state', 'in', ['paid', 'open'])]" string="The total amount of all paid or open invoices is correctly computed">
-            <test expr="sum([l.price_subtotal for l in invoice_line]) - amount_untaxed &lt;= 0.00001"/>
-        </assert>
-
-        <assert model="account.move.reconcile" search="[]" string="For each reconciliation, the sum of credits equals the sum of debits">
-            <test expr="sum([l.debit - l.credit for l in line_id]) &lt;= 0.00001"/>
-        </assert>
-
--->
     </data>
 </openerp>
index 95b487e..8ae6b24 100644 (file)
@@ -367,8 +367,6 @@ class account_bank_statement(osv.osv):
                             account_move_line_obj.reconcile(cr, uid, torec, 'statement', writeoff_acc_id=writeoff_acc_id, writeoff_period_id=st.period_id.id, writeoff_journal_id=st.journal_id.id, context=context)
                     else:
                         account_move_line_obj.reconcile_partial(cr, uid, torec, 'statement', context)
-                    #except:
-                    #    raise osv.except_osv(_('Error !'), _('Unable to reconcile entry "%s": %.2f') % (move.name, move.amount))
 
                 if st.journal_id.entry_posted:
                     account_move_obj.write(cr, uid, [move_id], {'state': 'posted'})
index f08f9de..8bf75a8 100644 (file)
@@ -118,19 +118,6 @@ class account_cash_statement(osv.osv):
             res2[statement.id]=encoding_total
         return res2
 
-#    def _default_journal_id(self, cr, uid, context={}):
-
-#        """ To get default journal for the object"
-#        @param name: Names of fields.
-#        @return: journal
-#        """
-#        company_id = self.pool.get('res.users').browse(cr, uid, uid).company_id.id
-#        journal = self.pool.get('account.journal').search(cr, uid, [('type', '=', 'cash'), ('company_id', '=', company_id)])
-#        if journal:
-#            return journal[0]
-#        else:
-#            return False
-
     def _end_balance(self, cursor, user, ids, name, attr, context=None):
         res_currency_obj = self.pool.get('res.currency')
         res_users_obj = self.pool.get('res.users')
@@ -374,10 +361,6 @@ class account_cash_statement(osv.osv):
             if not self._equal_balance(cr, uid, ids, st, context):
                 raise osv.except_osv(_('Error !'), _('CashBox Balance is not matching with Calculated Balance !'))
 
-#            if not (abs((st.balance_end or 0.0) - st.balance_end_real) < 0.0001):
-#                raise osv.except_osv(_('Error !'),
-#                        _('The statement balance is incorrect !\n') +
-#                        _('The expected balance (%.2f) is different than the computed one. (%.2f)') % (st.balance_end_real, st.balance_end))
             if (not st.journal_id.default_credit_account_id) \
                     or (not st.journal_id.default_debit_account_id):
                 raise osv.except_osv(_('Configuration Error !'),
index 55e9230..dee0eac 100644 (file)
             <field name="view_id" ref="invoice_form"/>
             <field name="act_window_id" ref="action_invoice_tree"/>
         </record>
-<!--        <menuitem name="Invoices" id="menu_finance_invoice" parent="account.menu_finance" sequence="2"/>-->
 
         <record id="action_invoice_tree1" model="ir.actions.act_window">
             <field name="name">Customer Invoices</field>
index ba8d1ba..c3749eb 100644 (file)
             <field name="flow_start">True</field>
             <field name="name">draft</field>
         </record>
-        
-        <!--        <record model="workflow.activity" id="act_confirm">
-            <field name="wkf_id" ref="wkf"/>
-            <field name="name">confirm</field>
-        </record> -->
-        
-<!--        <record id="act_proforma" model="workflow.activity">-->
-<!--            <field name="wkf_id" ref="wkf"/>-->
-<!--            <field name="name">proforma</field>-->
-<!--            <field name="action">action_move_create()-->
-<!--write({'state':'proforma'})</field>-->
-<!--            <field name="kind">function</field>-->
-<!--        </record>-->
 
         <record id="act_proforma2" model="workflow.activity">
             <field name="wkf_id" ref="wkf"/>
@@ -65,35 +52,11 @@ write({'state':'cancel'})</field>
             <field name="kind">function</field>
         </record>
 
-        <!--
-        <record model="workflow.transition" id="t1">
-            <field name="act_from" ref="act_draft"/>
-            <field name="act_to" ref="act_confirm"/>
-        </record>
-        -->
-
-<!--        <record id="t3" model="workflow.transition">-->
-<!--            <field name="act_from" ref="act_draft"/>-->
-<!--            <field name="act_to" ref="act_proforma"/>-->
-<!--            <field name="signal">invoice_proforma</field>-->
-<!--        </record>-->
         <record id="t4" model="workflow.transition">
             <field name="act_from" ref="act_draft"/>
             <field name="act_to" ref="act_open"/>
             <field name="signal">invoice_open</field>
         </record>
-<!--        <record id="t5" model="workflow.transition">-->
-<!--            <field name="act_from" ref="act_proforma"/>-->
-<!--            <field name="act_to" ref="act_open"/>-->
-<!--            <field name="signal">invoice_open</field>-->
-<!--        </record>-->
-<!--        <record id="t7" model="workflow.transition">-->
-<!--            <field name="act_from" ref="act_proforma"/>-->
-<!--            <field name="act_to" ref="act_paid"/>-->
-<!--            <field name="trigger_model">account.move.line</field>-->
-<!--            <field name="trigger_expr_id">move_line_id_payment_get()</field>-->
-<!--            <field name="condition">test_paid()</field>-->
-<!--        </record>-->
         <record id="t8" model="workflow.transition">
             <field name="act_from" ref="act_open"/>
             <field name="act_to" ref="act_paid"/>
@@ -106,11 +69,6 @@ write({'state':'cancel'})</field>
             <field name="act_to" ref="act_cancel"/>
             <field name="signal">invoice_cancel</field>
         </record>
-<!--        <record id="t11" model="workflow.transition">-->
-<!--            <field name="act_from" ref="act_proforma"/>-->
-<!--            <field name="act_to" ref="act_cancel"/>-->
-<!--            <field name="signal">invoice_cancel</field>-->
-<!--        </record>-->
         <record id="t12" model="workflow.transition">
             <field name="act_from" ref="act_open"/>
             <field name="act_to" ref="act_cancel"/>
@@ -126,7 +84,7 @@ write({'state':'cancel'})</field>
             <field name="act_to" ref="act_cancel"/>
             <field name="signal">invoice_cancel</field>
         </record>
-        
+
         <record id="open_test_to_paid" model="workflow.transition">
             <field name="act_from" ref="act_open_test"/>
             <field name="act_to" ref="act_paid"/>
@@ -134,7 +92,7 @@ write({'state':'cancel'})</field>
             <field name="trigger_expr_id">move_line_id_payment_get()</field>
             <field name="condition">test_paid()</field>
         </record>
-        
+
         <record id="draft_to_pro2" model="workflow.transition">
             <field name="act_from" ref="account.act_draft"/>
             <field name="act_to" ref="act_proforma2"/>
index 74c8234..3cb2131 100644 (file)
@@ -6,13 +6,10 @@
         <menuitem id="menu_finance_receivables" name="Receivables" parent="menu_finance" sequence="1" groups="group_account_user,group_account_manager,base.group_system"/>
         <menuitem id="menu_finance_payables" name="Payables" parent="menu_finance" sequence="2" groups="group_account_user,group_account_manager,base.group_system"/>
         <menuitem id="menu_finance_bank_and_cash" name="Bank and Cash" parent="menu_finance" sequence="3"/>
-<!--        <menuitem id="menu_accounting" name="Accounting" parent="menu_finance" sequence="5"/>-->
         <menuitem id="menu_finance_periodical_processing" name="Periodical Processing" parent="menu_finance" sequence="8" groups="group_account_user,group_account_manager,base.group_system,group_account_invoice"/>
         <menuitem id="periodical_processing_journal_entries_validation" name="Draft Entries" parent="menu_finance_periodical_processing" groups="group_account_user,group_account_manager,base.group_system"/>
         <menuitem id="periodical_processing_reconciliation" name="Reconciliation" parent="menu_finance_periodical_processing"/>
-<!--            <menuitem id="periodical_processing_recurrent_entries" name="Recurrent Entries" parent="menu_finance_periodical_processing"/>-->
         <menuitem id="periodical_processing_invoicing" name="Invoicing" parent="menu_finance_periodical_processing"/>
-<!--            <menuitem id="periodical_processing_end_of_period" name="End of Period" parent="menu_finance_periodical_processing"/>-->
         <menuitem id="menu_finance_charts" name="Charts" parent="menu_finance" sequence="5" groups="base.group_system"/>
         <menuitem id="menu_finance_reporting" name="Reporting" parent="account.menu_finance" sequence="12" groups="base.group_system,group_account_manager,group_account_user"/>
         <menuitem id="menu_finance_reporting_budgets" name="Budgets" parent="menu_finance_reporting"/>
         <menuitem id="menu_low_level" name="Low Level" parent="menu_finance_accounting" groups="base.group_extended"/>
         <menuitem id="menu_configuration_misc" name="Miscellaneous" parent="menu_finance_configuration"/>
         <menuitem id="base.menu_action_currency_form" parent="menu_configuration_misc" sequence="20"/>
-<!--        <menuitem id="menu_finance_configuration1" name="Configuration" parent="menu_finance" sequence="80"/>-->
-<!--        <menuitem id="base.menu_action_currency_form" parent="menu_finance_configuration" sequence="20"/>-->
-<!--        <menuitem id="menu_finance_accounting1" name="Financial Accounting" parent="menu_finance_configuration" sequence="80"/>-->
-<!--        <menuitem id="menu_analytic_accounting1" name="Analytic Accounting" parent="menu_finance_configuration" sequence="80"/>-->
-
-<!--        <menuitem id="menu_finance_reporting11" name="Reporting" parent="account.menu_finance"  sequence="80"/>-->
         <menuitem id="menu_finance_generic_reporting" name="Generic Reporting" parent="menu_finance_reporting" sequence="100" groups="base.group_system,group_account_manager"/>
-<!--        <menuitem id="menu_finance_legal_statement1" name="Legal Statements" parent="account.menu_finance_reporting" sequence="200"/>-->
-
         <menuitem id="menu_finance_entries" name="Accounting" parent="menu_finance" sequence="4"
         groups="group_account_user,group_account_manager,base.group_system"/>
         <menuitem id="account.menu_finance_recurrent_entries" name="Recurring Entries" parent="menu_finance_periodical_processing" sequence="15"
             groups="base.group_extended"/>
 
-<!--        <menuitem id="menu_finance_periodical_processing11" name="Periodical Processing" parent="account.menu_finance"-->
-<!--            sequence="3"-->
-<!--            groups="group_account_user"/>-->
         <menuitem id="menu_account_end_year_treatments" name="End of Period" parent="menu_finance_periodical_processing" groups="group_account_user,group_account_manager,base.group_system"/>
 
         <menuitem id="menu_finance_statistic_report_statement" name="Statistic Reports" parent="menu_finance_reporting" sequence="300" groups="account.group_account_manager"/>
index 94dd4e8..4e6c2cb 100644 (file)
@@ -572,7 +572,7 @@ class account_move_line(osv.osv):
             if journal:
                 jt = self.pool.get('account.journal').browse(cr, uid, journal).type
                 #FIXME: Bank and cash journal are such a journal we can not assume a account based on this 2 journals
-                # Bank and cash journal can have a payment or receipt transection, and in both type partner account
+                # Bank and cash journal can have a payment or receipt transaction, and in both type partner account
                 # will not be same id payment then payable, and if receipt then receivable
                 #if jt in ('sale', 'purchase_refund', 'bank', 'cash'):
                 if jt in ('sale', 'purchase_refund'):
@@ -1155,11 +1155,6 @@ class account_move_line(osv.osv):
                         'journal_id': journal.analytic_journal_id.id,
                         'ref': vals.get('ref', False),
                     })]
-            #else:
-            #    raise osv.except_osv(_('No analytic journal !'), _('Please set an analytic journal on this financial journal !'))
-
-        #if not 'currency_id' in vals:
-        #    vals['currency_id'] = account.company_id.currency_id.id
 
         result = super(osv.osv, self).create(cr, uid, vals, context)
         # CREATE Taxes
@@ -1228,11 +1223,6 @@ class account_move_line(osv.osv):
                     self.create(cr, uid, data, context)
             del vals['account_tax_id']
 
-        # No needed, related to the job
-        #if not is_new_move and 'date' in vals:
-        #    if context and ('__last_update' in context):
-        #        del context['__last_update']
-        #    self.pool.get('account.move').write(cr, uid, [move_id], {'date':vals['date']}, context=context)
         if check and ((not context.get('no_store_function')) or journal.entry_posted):
             tmp = self.pool.get('account.move').validate(cr, uid, [vals['move_id']], context)
             if journal.entry_posted and tmp:
index 8e26ee8..be0569f 100644 (file)
             name="Taxes"
             parent="account.menu_finance_generic_reporting" sequence="3"/>
 
-<!--        <wizard
-            id="wizard_vat_declaration"
-            menu="False"
-            model="account.tax.code"
-            name="account.vat.declaration"
-            string="Print Taxes Report"/> -->
-
-<!--        <menuitem
-            icon="STOCK_PRINT"
-            action="wizard_vat_declaration"
-            id="menu_wizard_vat_declaration"
-            parent="menu_tax_report"
-            type="wizard"/> -->
-
         <report id="account_account_balance_compare"
             string="Account balance"
             model="account.account"
             auto="False"
             menu="False"/>
 
-        <!--
-
-        <report id="analytic_journal"
-            string="Analytic journal"
-            model="account.analytic.account"
-            name="account.analytic.journal"
-            xml="account/report/analytic_journal.rml"
-            auto="False" />
-
-
-        -->
     </data>
 </openerp>
index 1dc871a..c1954e2 100644 (file)
                             <group col="2" colspan="2">
                                 <separator string="Reconcile" colspan="2"/>
                                 <field name="reconcile"/>
-<!--                                <field name="active"/>-->
                             </group>
                             <separator string="Default Taxes" colspan="4"/>
                             <field colspan="4" name="tax_ids" nolabel="1" domain="[('parent_id','=',False)]"/>
             <field name="view_id" ref="view_account_tree"/>
             <field name="domain">[('parent_id','=',False)]</field>
         </record>
-<!--        <menuitem action="action_account_tree" id="menu_action_account_tree" parent="account.account_account_menu"/>-->
 
         <!--
         Journal
             <field name="filter" eval="True"/>
         </record>
 
-<!--        <record id="action_bank_statement_tree2" model="ir.actions.act_window">-->
-<!--            <field name="name">New Statement</field>-->
-<!--            <field name="res_model">account.bank.statement</field>-->
-<!--            <field name="view_type">form</field>-->
-<!--            <field name="view_mode">form,tree</field>-->
-<!--        </record>-->
-
         <record id="view_bank_statement_reconcile" model="ir.ui.view">
             <field name="name">account.bank.statement.reconcile.form</field>
             <field name="model">account.bank.statement.reconcile</field>
             id="menu_action_tax_code_tree"
             parent="menu_finance_charts"
             sequence="12"/>
-<!--       <wizard id="action_move_journal_line_form" menu="False" model="account.move.line" name="account.move.journal" string="Entries by Line"/-->
 
         <!--
     Entries lines
                <field eval="[(6,0,[ref('account.group_accounting_accountant')])]" name="groups_id"/>
            </record>
 
-<!--        <record id="action_move_to_review" model="ir.actions.act_window">-->
-<!--            <field name="name">Journal Entries</field>-->
-<!--            <field name="type">ir.actions.act_window</field>-->
-<!--            <field name="res_model">account.move</field>-->
-<!--            <field name="view_type">form</field>-->
-<!--            <field name="view_id" ref="view_move_tree"/>-->
-<!--            <field name="search_view_id" ref="view_account_move_filter"/>-->
-<!--            <field name="domain">[('to_check','=',True), ('state','=','draft')]</field>-->
-<!--        </record>-->
-<!--        <menuitem-->
-<!--            action="action_move_to_review"-->
-<!--            id="menu_action_move_to_review"-->
-<!--            parent="periodical_processing_journal_entries_validation"-->
-<!--        />-->
-
-<!--        <menuitem id="next_id_29" name="Search Entries" parent="account.menu_finance_entries" sequence="40"/>-->
-<!--        <menuitem action="action_move_line_form" id="menu_action_move_line_form" parent="next_id_29"/>-->
-
-        <!-- <record id="action_move_line_form_encode_by_move" model="ir.actions.act_window">
-            <field name="name">Journal Entries</field>
-            <field name="res_model">account.move</field>
-            <field name="view_type">form</field>
-            <field name="view_mode">tree,form</field>
-            <field name="view_id" ref="view_move_tree"/>
-            <field name="search_view_id" ref="view_account_move_filter"/>
-        </record>
-
-        <menuitem action="action_move_line_form_encode_by_move" id="menu_encode_entries_by_move" parent="menu_finance_entries"/>-->
-
-<!--        <record id="action_account_moves_sale" model="ir.actions.act_window">-->
-<!--            <field name="name">Journal Items</field>-->
-<!--            <field name="res_model">account.move.line</field>-->
-<!--            <field name="view_type">form</field>-->
-<!--            <field name="view_mode">tree,form,graph</field>-->
-<!--            <field name="view_id" ref="view_move_line_tree"/>-->
-<!--            <field name="search_view_id" ref="view_account_move_line_filter"/>-->
-<!--            <field name="domain">[('journal_id.type', 'in', ['sale', 'purchase_refund'])]</field>-->
-<!--        </record>-->
-
-<!--        <menuitem action="action_account_moves_sale" id="menu_eaction_account_moves_sale" parent="menu_finance_receivables"/>-->
-
-<!--        <record id="action_account_moves_purchase" model="ir.actions.act_window">-->
-<!--            <field name="name">Journal Items</field>-->
-<!--            <field name="res_model">account.move.line</field>-->
-<!--            <field name="view_type">form</field>-->
-<!--            <field name="view_mode">tree,form,graph</field>-->
-<!--            <field name="view_id" ref="view_move_line_tree"/>-->
-<!--            <field name="search_view_id" ref="view_account_move_line_filter"/>-->
-<!--            <field name="domain">[('journal_id.type', 'in', ['purchase', 'sale_refund'])]</field>-->
-<!--        </record>-->
-
-<!--        <menuitem action="action_account_moves_purchase" id="menu_eaction_account_moves_purchase" parent="menu_finance_payables"/>-->
-
         <record id="action_move_line_search" model="ir.actions.act_window">
             <field name="name">Entry Lines</field>
             <field name="type">ir.actions.act_window</field>
             <field name="view_mode">form</field>
             <field name="act_window_id" ref="action_move_line_search"/>
         </record>
-<!--        <record id="action_move_line_search_view4" model="ir.actions.act_window">-->
-<!--            <field name="name">Cheque Register</field>-->
-<!--            <field name="type">ir.actions.act_window</field>-->
-<!--            <field name="res_model">account.move.line</field>-->
-<!--            <field name="view_type">form</field>-->
-<!--            <field name="view_mode">tree,form</field>-->
-<!--            <field name="view_id" ref="view_move_line_tree"/>-->
-<!--            <field name="search_view_id" ref="view_account_move_line_filter"/>-->
-<!--            <field name="domain">[('journal_id.type', '=', 'bank')]</field>-->
-<!--        </record>-->
-<!--        -->
-<!--        <menuitem action="action_move_line_search_view4" id="journal_bank_move_lines" parent="menu_finance_bank_and_cash"/>-->
-
-<!--        <menuitem action="action_move_line_search" id="menu_action_move_line_search" parent="account.next_id_29"/>-->
 
         <menuitem id="menu_finance_charts" name="Charts" parent="account.menu_finance" sequence="4"/>
-    <!--    <wizard id="wizard_account_chart" menu="False" model="account.account" name="account.chart" string="Chart of Accounts"/>
-        <menuitem icon="STOCK_INDENT" action="wizard_account_chart" id="menu_action_account_tree2" parent="account.menu_finance_charts" type="wizard"/>
- -->
-
 
         <record id="view_bank_statement_reconcile_form" model="ir.ui.view">
             <field name="name">account.bank.statement.reconcile.form</field>
             <field name="view_mode">form,tree</field>
             <field name="view_id" ref="view_bank_statement_reconcile_form"/>
         </record>
-        <!-- <menuitem
-            id="next_id_30"
-            name="Bank Reconciliation"
-            parent="menu_finance_periodical_processing"
-            groups="group_account_user"/> -->
-
-<!--        <menuitem action="action_bank_statement_reconciliation_form" id="menu_action_account_bank_reconcile_tree" parent="next_id_30"/>-->
-  <!--        <wizard id="action_account_bank_reconcile_tree" menu="False" model="account.move.line" name="account.move.bank.reconcile" string="Bank reconciliation"/> -->
-    <!--     <menuitem action="action_account_bank_reconcile_tree" id="menu_action_account_bank_reconcile_check_tree" parent="account.next_id_30" type="wizard"/>   -->
-
-<!--  bank reconciliation  -->
-<!--        <menuitem action="action_account_bank_reconcile_tree"-->
-<!--            id="menu_action_account_bank_reconcile_check_tree"-->
-<!--            parent="periodical_processing_reconciliation" groups="group_account_user" />-->
 
         <act_window
             context="{'search_default_next_partner':1,'view_mode':True}"
             <field name="view_type">tree</field>
             <field name="help">You can look up individual account entries by searching for useful information. To search for account entries, open a journal, then select a record line.</field>
         </record>
-<!--        <menuitem action="action_account_journal_period_tree" id="menu_action_account_journal_period_tree" parent="account.menu_finance_generic_reporting" sequence="2"/>-->
-
 
         <!--
-    # Account Models
--->
+        # Account Models
+        -->
 
         <record id="view_model_line_tree" model="ir.ui.view">
             <field name="name">account.model.line.tree</field>
                 </form>
             </field>
         </record>
-<!--        <record id="view_account_move_line_filter" model="ir.ui.view">-->
-<!--            <field name="name">Payment Terms</field>-->
-<!--            <field name="model">account.payment.term</field>-->
-<!--            <field name="type">search</field>-->
-<!--            <field name="arch" type="xml">-->
-<!--                <search string="Search Payment Terms">-->
-<!--                    <group col='10' colspan='4'>-->
-<!--                        <filter icon="terp-document-new" string="Draft" domain="[('state','=','draft')]" help="Draft Entry Lines"/>-->
-<!--                        <filter icon="terp-camera_test" string="Posted" domain="[('state','=','valid')]" help="Posted Entry Lines"/>-->
-<!--                        <separator orientation="vertical"/>-->
-<!--                        <field name="date" select='1'/>-->
-<!--                        <field name="account_id" select='1'/>-->
-<!--                        <field name="partner_id" select='1'>-->
-<!--                            <filter help="Next Partner Entries to reconcile" name="next_partner" string="Next Partner to reconcile" context="{'next_partner_only': 1}" icon="terp-partner" domain="[('account_id.reconcile','=',True),('reconcile_id','=',False)]"/>-->
-<!--                        </field>-->
-<!--                        <field name="balance" string="Debit/Credit" select='1'/>-->
-<!--                    </group>-->
-<!--                </search>-->
-<!--            </field>-->
-<!--        </record>-->
+
         <record id="action_payment_term_form" model="ir.actions.act_window">
             <field name="name">Payment Terms</field>
             <field name="res_model">account.payment.term</field>
         <menuitem action="action_payment_term_form" id="menu_action_payment_term_form" parent="menu_configuration_misc"/>
 
         <!--
-    # Account Subscriptions
--->
+        # Account Subscriptions
+        -->
 
         <record id="view_subscription_line_form" model="ir.ui.view">
             <field name="name">account.subscription.line.form</field>
                         <separator colspan="4" string="Starts on"/>
                         <field name="date_start" select="1"/>
                         <field name="period_total"/>
-
                     </group>
 
                     <group col="2" colspan="2">
             <field name="domain">[('account_id','child_of', [active_id]),('state','&lt;&gt;','draft')]</field>
             <field name="context">{'account_id':active_id}</field>
         </record>
-<!--        <wizard id="wizard_move_line_select" menu="False" model="account.move.line" name="account.move.line.select" string="Move line select"/>-->
-<!--        <record id="ir_open_account_account" model="ir.values">-->
-<!--            <field eval="'tree_but_open'" name="key2"/>-->
-<!--            <field eval="'account.account'" name="model"/>-->
-<!--            <field name="name">Account Entries</field>-->
-<!--            <field eval="'ir.actions.wizard,%d'%wizard_move_line_select" name="value"/>-->
-<!--            <field eval="True" name="object"/>-->
-<!--        </record>-->
-
 
         <record id="view_move_line_tax_tree" model="ir.ui.view">
             <field name="name">account.move.line.tax.tree</field>
index d7a879c..639dc2d 100644 (file)
@@ -1,100 +1,7 @@
 <?xml version="1.0" encoding="utf-8"?>
 <openerp>
     <data>
-<!--        <wizard-->
-<!--            string="Account balance-Compare Years"-->
-<!--            model="account.account"-->
-<!--            name="account.balance.account.balance.report"-->
-<!--            keyword="client_print_multi"-->
-<!--            id="wizard_account_balance_compare_report"/>-->
-
-<!--  for test only -->
-
-
-
-        <!--  wizard id="wizard_invoice_pay" model="account.invoice" name="account.invoice.pay" string="Pay invoice" groups="base.group_user"/-->
-
-        <!-- close year, period, journal -->
-<!--        <wizard id="wizard_fiscalyear_close" menu="False" model="account.fiscalyear" name="account.fiscalyear.close" string="Generate Fiscal Year Opening Entries"/>-->
-<!---->
-<!--        <menuitem-->
-<!--            action="wizard_fiscalyear_close"-->
-<!--            id="menu_wizard_fy_close"-->
-<!--            parent="menu_account_end_year_treatments"-->
-<!--            type="wizard"-->
-<!--            sequence="1"/>-->
-
-  <!--     <wizard id="wizard_fiscalyear_close_state" menu="False" model="account.fiscalyear" name="account.fiscalyear.close.state" string="Close a Fiscal Year"/>
-        <menuitem action="wizard_fiscalyear_close_state" id="menu_wizard_fy_close_state" parent="menu_account_end_year_treatments" type="wizard"/>
- -->
-
-        <!-- automatic reconcile -->
-<!--        <menuitem id="next_id_20" name="Reconciliation" parent="menu_finance_periodical_processing"/>-->
-    <!--    <wizard id="wizard_automatic_reconcile" menu="False" model="account.account" name="account.automatic.reconcile" string="Automatic reconciliation"/>
-        <menuitem action="wizard_automatic_reconcile" id="menu_automatic_reconcile" parent="next_id_20" type="wizard"/>-->
-
-        <!-- Import entry in statement -->
-
-<!--        <wizard-->
-<!--            string="Import invoices"-->
-<!--            model="account.bank.statement"-->
-<!--            name="populate_statement_from_inv"-->
-<!--            menu="False"-->
-<!--            id="wizard_populate_statement_from_inv"/>-->
-
-        <!-- manual reconcile -->
-<!--        <wizard id="wizard_reconcile" model="account.move.line" name="account.move.line.reconcile" string="Reconcile Entries"/>-->
-
-<!--        <wizard id="wizard_reconcile_unreconcile" model="account.move.reconcile" name="account.reconcile.unreconcile" string="Unreconcile Entries"/>-->
-
-
- <!--       <wizard id="wizard_reconcile_select" menu="False" model="account.move.line" name="account.move.line.reconcile.select" string="Reconcile entries"/> -->
-       <!-- <menuitem action="wizard_reconcile_select" id="menu_reconcile_select" parent="account.next_id_20" type="wizard"/> -->
-
-        <!-- unreconcile -->
-<!--        <wizard id="wizard_unreconcile" model="account.move.line" name="account.move.line.unreconcile" string="Unreconcile Entries"/>-->
-
-
-        <!-- <wizard id="wizard_unreconcile_select" menu="False" model="account.move.line" name="account.move.line.unreconcile.select" string="Unreconcile entries"/> -->
-        <!-- <menuitem action="wizard_unreconcile_select" id="menu_unreconcile_select" parent="account.next_id_20" type="wizard"/> -->
-
-        <!-- subscriptions -->
-        <!--
-        <wizard id="wizard_generate_subscription" menu="False" model="account.subscription" name="account.subscription.generate" string="Create subscription entries"/>
-        <menuitem action="wizard_generate_subscription" id="menu_generate_subscription" parent="account.menu_finance_periodical_processing" type="wizard"/>
-         -->
-        <!-- Aged partner balance -->
-<!--        <wizard id="wizard_aged_trial_balance" menu="False" model="res.partner" name="account.aged.trial.balance" string="Aged Partner Balance"/>
-
-        <menuitem icon="STOCK_PRINT" action="wizard_aged_trial_balance" id="menu_aged_trial_balance" parent="next_id_22" type="wizard"/>-->
-
-        <!-- report-related wizards -->
-<!--        <wizard id="wizard_partner_balance_report" menu="False" model="res.partner" name="account.partner.balance.report" string="Partner Balance"/>
-        <menuitem icon="STOCK_PRINT" action="wizard_partner_balance_report" id="menu_partner_balance" parent="account.next_id_22" type="wizard"/> -->
         <menuitem id="next_id_22" name="Partner Accounts" parent="menu_finance_generic_reporting" sequence="1"/>
 
-
-
-<!--        <wizard id="wizard_invoice_state_confirm" keyword="client_action_multi" model="account.invoice" multi="True" name="account.invoice.state.confirm" string="Confirm draft invoices" groups="base.group_user"/>-->
-<!--        <wizard id="wizard_invoice_state_cancel" keyword="client_action_multi" model="account.invoice" multi="True" name="account.invoice.state.cancel" string="Cancel selected invoices" groups="base.group_user"/>-->
-<!---->
-
-        <!-- account.move validate -->
-<!--        <wizard id="wizard_validate_account_moves" menu="False" model="account.move" name="account.move.validate" string="Validate Ledger Postings"/>
-        <menuitem action="wizard_validate_account_moves" id="menu_validate_account_moves" parent="account.menu_finance_periodical_processing" type="wizard"/>
-
-        <wizard id="wizard_validate_account_moves_line" menu="True" model="account.move.line" name="account.move_line.validate" string="Validate Ledger Postings"/>-->
-
-        <!-- Use Models -->
-<!--        <wizard string="Create Entries From Models" model="account.model" name="account_use_models" menu="False" id="wizard_account_use_model"/>-->
-<!--        <menuitem action="wizard_account_use_model" type="wizard" parent="account.menu_finance_recurrent_entries" id="menu_account_use_model"/>-->
-
-<!--        <wizard string="Create Entries From Models" model="account.move.line" name="account_use_models" menu="True" id="wizard_line_account_use_model"/>-->
-
-        <!-- account.invoice -->
-<!--    <wizard string="Open State" model="account.invoice" name="account.wizard_paid_open" menu="False" id="wizard_paid_open" groups="base.group_user"/> -->
-
-
-<!--        <wizard id="wizard_invoice_currency_change" model="account.invoice" name="account.invoice.currency_change" string="Change Currency" groups="base.group_user"/>-->
     </data>
 </openerp>
index cfcebdb..93bfed6 100644 (file)
@@ -2,16 +2,9 @@
 <openerp>
     <data noupdate="1">
         <!--
-                       Administrator shortcut
-                       Demo user startup menu
+               Administrator shortcut
+               Demo user startup menu
                -->
-        <!-- <record id="sc_account_dash" model="ir.ui.view_sc">
-            <field name="name">Accounting dashboard</field>
-            <field name="user_id" ref="base.user_root"/>
-            <field name="resource">ir.ui.menu</field>
-            <field name="sequence">0</field>
-            <field name="res_id" ref="menu_board_account"/>
-        </record> -->
         <record id="base.user_root" model="res.users">
             <field name="action_id" ref="open_board_account"/>
         </record>
index a3a1ec0..692c796 100644 (file)
@@ -7,12 +7,12 @@
             <field name="model">res.company</field>
             <field name="type">form</field>
             <field name="arch" type="xml">
-             <notebook>
-                <page string="Overdue Payments" position="inside">
-                    <separator string="Overdue Payments Message" colspan="4"/>
-                    <field name="overdue_msg" nolabel="1" colspan ="4"/>
-                </page>
-             </notebook>
+                <notebook>
+                    <page string="Overdue Payments" position="inside">
+                        <separator string="Overdue Payments Message" colspan="4"/>
+                        <field name="overdue_msg" nolabel="1" colspan ="4"/>
+                    </page>
+                </notebook>
             </field>
         </record>
         
index 8aab78f..de8c1ba 100644 (file)
                                    <field name="user_type" ref="conf_account_type_asset"/>
                                </record>
                                
-                               <!-- <record id="account.property_account_receivable" model="ir.property">
-                                   <field eval="'account.account,'+str(a_recv)" name="value"/>
-                               </record> -->
-                       
                                <record id="conf_ova" model="account.account.template">
                                    <field name="code">1103</field>
                                    <field name="name">Output VAT</field>
                                    <field name="user_type" ref="conf_account_type_bnk"/>
                                </record>
                        
-               <!--        <record id="conf_cash" model="account.account.template">-->
-               <!--            <field name="code">1105</field>-->
-               <!--            <field name="name">Cash</field>-->
-               <!--            <field ref="conf_cas" name="parent_id"/>-->
-               <!--            <field name="type">view</field>-->
-               <!--            <field name="user_type" ref="conf_account_type_cash"/>-->
-               <!--        </record>-->
-                       
                        <record id="conf_cli" model="account.account.template">
                            <field name="code">111</field>
                            <field name="name">Current Liabilities</field>
                                    <field name="user_type" ref="conf_account_type_liability"/>
                                </record>
                        
-                               <!-- <record id="account.property_account_payable" model="ir.property">
-                                   <field eval="'account.account,'+str(a_pay)" name="value"/>
-                               </record>-->
-                       
                                <record id="conf_iva" model="account.account.template">
                                    <field name="code">1112</field>
                                    <field name="name">Input VAT</field>
                            <field name="user_type" ref="conf_account_type_income"/>
                        </record>
        
-               <!-- <record id="account.property_account_income_categ" model="ir.property">
-                   <field eval="'account.account,'+str(a_sale)" name="value"/>
-               </record> -->
-       
                <record id="conf_cos" model="account.account.template">
                    <field name="code">21</field>
                    <field name="name">Cost of Sales</field>
                     <field name="user_type" ref="conf_account_type_expense"/>
                 </record>
 
-        <!-- <record id="account.property_account_expense_categ" model="ir.property">
-            <field eval="'account.account,'+str(a_expense)" name="value"/>
-        </record> -->
-
         <!-- Taxes -->
-          <!-- TAX Code Definitions -->
+        <!-- TAX Code Definitions -->
 
         <!-- Invoiced TAX -->
 
index 5f614e4..bedfed3 100644 (file)
         Product income and expense accounts, default parameters
         -->
 
-<!--        <record id="property_account_expense_prd" model="ir.property">-->
-<!--            <field name="name">property_account_expense</field>-->
-<!--            <field name="fields_id" search="[('model','=','product.template'),('name','=','property_account_expense')]"/>-->
-<!--            <field eval="'account.account,'+str(ref('account.a_expense'))" name="value"/>-->
-<!--            <field name="company_id" ref="base.main_company"/>-->
-<!--        </record>-->
-<!--        <record id="property_account_income_prd" model="ir.property">-->
-<!--            <field name="name">property_account_income</field>-->
-<!--            <field name="fields_id" search="[('model','=','product.template'),('name','=','property_account_income')]"/>-->
-<!--            <field eval="'account.account,'+str(ref('account.a_sale'))" name="value"/>-->
-<!--            <field name="company_id" ref="base.main_company"/>-->
-<!--        </record>-->
         <record id="property_account_expense_categ" model="ir.property">
             <field name="name">property_account_expense_categ</field>
             <field name="fields_id" search="[('model','=','product.category'),('name','=','property_account_expense_categ')]"/>
index 4843f54..6671241 100644 (file)
@@ -71,7 +71,6 @@ class account_installer(osv.osv_memory):
         'period':lambda *a:'month',
         'sale_tax':lambda *a:0.0,
         'purchase_tax':lambda *a:0.0,
-        #'charts':'configurable',
         'bank_accounts_id':_get_default_accounts
     }
 
index cff1ce6..c2fbe5f 100644 (file)
@@ -319,7 +319,6 @@ class account_invoice(osv.osv):
     }
     _defaults = {
         'type': _get_type,
-        #'date_invoice': lambda *a: time.strftime('%Y-%m-%d'),
         'state': 'draft',
         'journal_id': _get_journal,
         'currency_id': _get_currency,
@@ -372,9 +371,6 @@ class account_invoice(osv.osv):
         osv.osv.unlink(self, cr, uid, unlink_ids, context=context)
         return True
 
-#   def get_invoice_address(self, cr, uid, ids):
-#       res = self.pool.get('res.partner').address_get(cr, uid, [part], ['invoice'])
-#       return [{}]
     def onchange_partner_id(self, cr, uid, ids, type, partner_id,\
             date_invoice=False, payment_term=False, partner_bank_id=False, company_id=False):
         invoice_addr_id = False
@@ -636,7 +632,6 @@ class account_invoice(osv.osv):
                 ait_obj.create(cr, uid, taxe)
          # Update the stored value (fields.function), so we write to trigger recompute
         self.pool.get('account.invoice').write(cr, uid, ids, {'invoice_line':[]}, context=context)
-#        self.pool.get('account.invoice').write(cr, uid, ids, {}, context=context)
         return True
 
     def button_compute(self, cr, uid, ids, context=None, set_total=False):
@@ -879,7 +874,7 @@ class account_invoice(osv.osv):
 
             line = self.group_lines(cr, uid, iml, line, inv)
 
-            journal_id = inv.journal_id.id #self._get_journal(cr, uid, {'type': inv['type']})
+            journal_id = inv.journal_id.id 
             journal = self.pool.get('account.journal').browse(cr, uid, journal_id)
             if journal.centralisation:
                 raise osv.except_osv(_('UserError'),
@@ -1321,9 +1316,6 @@ class account_invoice_line(osv.osv):
                 else:
                     app_acc_in = in_acc_cate
                     app_acc_exp = ex_acc_cate
-#            else:
-#                app_acc_in = self.pool.get('account.account').browse(cr,uid,in_pro_id)[0]
-#                app_acc_exp = self.pool.get('account.account').browse(cr,uid,exp_pro_id)[0]
             if app_acc_in.company_id.id != company_id and app_acc_exp.company_id.id != company_id:
                 in_res_id = account_obj.search(cr, uid, [('name','=',app_acc_in.name),('company_id','=',company_id)])
                 exp_res_id = account_obj.search(cr, uid, [('name','=',app_acc_exp.name),('company_id','=',company_id)])
index 609b8f0..f3a8cca 100644 (file)
@@ -63,7 +63,7 @@
 
         <!--
         Partners Extension
-    -->
+       -->
 
         <record id="view_partner_property_form" model="ir.ui.view">
             <field name="name">res.partner.property.form.inherit</field>
index 172de7b..1f04c8e 100644 (file)
@@ -1,21 +1,21 @@
 <?xml version="1.0" ?>
 <openerp>
     <data>
-        
-        <!--    
-            Process    
+
+        <!--
+            Process
         -->
-        
+
         <record id="process_process_invoiceprocess0" model="process.process">
             <field eval="1" name="active"/>
              <field name="model_id" ref="account.model_account_invoice"/>
             <field eval="&quot;&quot;&quot;Customer Invoice&quot;&quot;&quot;" name="name"/>
         </record>
-        
-        <!--    
+
+        <!--
             Process Node
         -->
-        
+
         <record id="process_node_analytic0" model="process.node">
             <field name="menu_id" ref="account.account_analytic_def_account"/>
             <field name="model_id" ref="analytic.model_account_analytic_account"/>
@@ -26,7 +26,7 @@
             <field eval="&quot;&quot;&quot;object.state in ('draft', 'open', 'pending', 'close')&quot;&quot;&quot;" name="model_states"/>
             <field eval="1" name="flow_start"/>
         </record>
-        
+
         <record id="process_node_draftinvoices0" model="process.node">
             <field name="menu_id" ref="account.menu_action_invoice_tree1"/>
             <field name="model_id" ref="account.model_account_invoice"/>
@@ -37,7 +37,7 @@
             <field eval="&quot;&quot;&quot;object.state=='draft'&quot;&quot;&quot;" name="model_states"/>
             <field eval="0" name="flow_start"/>
         </record>
-    
+
         <record id="process_node_invoiceinvoice0" model="process.node">
             <field name="menu_id" ref="account.menu_finance_receivables"/>
             <field name="model_id" ref="account.model_account_invoice"/>
@@ -48,7 +48,7 @@
             <field eval="&quot;&quot;&quot;object.state=='draft'&quot;&quot;&quot;" name="model_states"/>
             <field eval="0" name="flow_start"/>
         </record>
-    
+
         <record id="process_node_accountingentries0" model="process.node">
             <field name="menu_id" ref="account.menu_action_move_journal_line_form"/>
             <field name="model_id" ref="account.model_account_move"/>
@@ -58,7 +58,7 @@
             <field name="process_id" ref="process_process_invoiceprocess0"/>
             <field eval="0" name="flow_start"/>
         </record>
-    
+
         <record id="process_node_bankstatement0" model="process.node">
             <field name="menu_id" ref="account.menu_bank_statement_tree"/>
             <field name="model_id" ref="account.model_account_bank_statement"/>
@@ -70,7 +70,7 @@
             <field eval="&quot;&quot;&quot;object.state=='draft'&quot;&quot;&quot;" name="model_states"/>
             <field eval="1" name="flow_start"/>
                </record>
-    
+
         <record id="process_node_paymententries0" model="process.node">
             <field name="menu_id" ref="account.menu_action_move_journal_line_form"/>
             <field name="model_id" ref="account.model_account_move_line"/>
@@ -81,7 +81,7 @@
             <field eval="&quot;&quot;&quot;object.state in ('draft', 'valid')&quot;&quot;&quot;" name="model_states"/>
             <field eval="0" name="flow_start"/>
         </record>
-    
+
         <record id="process_node_reconciliation0" model="process.node">
             <field name="menu_id" ref="account.menu_eaction_account_moves_all"/>
             <field name="model_id" ref="account.model_account_move_reconcile"/>
@@ -92,7 +92,7 @@
             <field eval="&quot;&quot;&quot;object.state=='valid'&quot;&quot;&quot;" name="model_states"/>
             <field eval="0" name="flow_start"/>
         </record>
-    
+
         <record id="process_node_paidinvoice0" model="process.node">
             <field name="menu_id" ref="account.menu_action_invoice_tree1"/>
             <field name="model_id" ref="account.model_account_invoice"/>
             <field eval="&quot;&quot;&quot;object.state=='paid'&quot;&quot;&quot;" name="model_states"/>
             <field eval="0" name="flow_start"/>
         </record>
-        
+
         <record id="process_node_accountingstatemententries0" model="process.node">
             <field name="menu_id" ref="account.menu_eaction_account_moves_all"/>
             <field name="model_id" ref="account.model_account_move_line"/>
             <field eval="&quot;&quot;&quot;object.state in ('draft', 'valid')&quot;&quot;&quot;" name="model_states"/>
             <field eval="0" name="flow_start"/>
         </record>
-        
 
-        <!--    
+
+        <!--
             Process Transition
         -->
-        
+
         <record id="res_roles_invoice0" model="res.roles">
             <field eval="&quot;&quot;&quot;Invoice&quot;&quot;&quot;" name="name"/>
         </record>
-        
-<!--        <record id="account.t5" model="workflow.transition">-->
-<!--            <field name="role_id" ref="res_roles_invoice0"/>-->
-<!--        </record>-->
-        
+
         <record id="process_transition_confirmstatementfromdraft0" model="process.transition">
             <field eval="[(6,0,[])]" name="role_ids"/>
             <field eval="[(6,0,[])]" name="transition_ids"/>
             <field model="process.node" name="target_node_id" ref="process_node_accountingstatemententries0"/>
             <field model="process.node" name="source_node_id" ref="account.process_node_draftstatement0"/>
         </record>
-    
+
         <record id="process_transition_analyticinvoice0" model="process.transition">
             <field eval="[(6,0,[])]" name="role_ids"/>
             <field eval="[(6,0,[])]" name="transition_ids"/>
             <field model="process.node" name="target_node_id" ref="process_node_draftinvoices0"/>
             <field model="process.node" name="source_node_id" ref="process_node_analytic0"/>
         </record>
-        
+
         <record id="process_transition_customerinvoice0" model="process.transition">
             <field eval="[(6,0,[])]" name="role_ids"/>
             <field eval="[(6,0,[])]" name="transition_ids"/>
             <field model="process.node" name="source_node_id" ref="process_node_draftinvoices0"/>
             <field eval="[(6,0,[ref('account.pro2_to_open')])]" name="transition_ids"/>
         </record>
-    
+
         <record id="process_transition_validentries0" model="process.transition">
             <field eval="[(6,0,[])]" name="role_ids"/>
             <field eval="[(6,0,[])]" name="transition_ids"/>
             <field model="process.node" name="target_node_id" ref="process_node_accountingentries0"/>
             <field model="process.node" name="source_node_id" ref="process_node_invoiceinvoice0"/>
         </record>
-    
+
         <record id="process_transition_entriesreconcile0" model="process.transition">
             <field eval="[(6,0,[])]" name="role_ids"/>
             <field eval="[(6,0,[])]" name="transition_ids"/>
             <field model="process.node" name="target_node_id" ref="process_node_reconciliation0"/>
             <field model="process.node" name="source_node_id" ref="process_node_accountingentries0"/>
         </record>
-    
+
         <record id="process_transition_statemententries0" model="process.transition">
             <field eval="[(6,0,[])]" name="role_ids"/>
             <field eval="[(6,0,[])]" name="transition_ids"/>
             <field model="process.node" name="target_node_id" ref="process_node_paymententries0"/>
             <field model="process.node" name="source_node_id" ref="process_node_bankstatement0"/>
         </record>
-    
+
         <record id="process_transition_paymentreconcile0" model="process.transition">
             <field eval="[(6,0,[])]" name="role_ids"/>
             <field eval="[(6,0,[])]" name="transition_ids"/>
             <field model="process.node" name="target_node_id" ref="process_node_reconciliation0"/>
             <field model="process.node" name="source_node_id" ref="process_node_paymententries0"/>
         </record>
-    
+
         <record id="process_transition_reconcilepaid0" model="process.transition">
             <field eval="[(6,0,[])]" name="role_ids"/>
             <field eval="[(6,0,[])]" name="transition_ids"/>
             <field model="process.node" name="target_node_id" ref="process_node_paidinvoice0"/>
             <field model="process.node" name="source_node_id" ref="process_node_reconciliation0"/>
         </record>
-        
-        <!--    
+
+        <!--
             Process Action
         -->
-        
+
         <record id="process_transition_action_createentries0" model="process.transition.action">
             <field eval="&quot;&quot;&quot;action_move_create&quot;&quot;&quot;" name="action"/>
             <field eval="&quot;&quot;&quot;object&quot;&quot;&quot;" name="state"/>
             <field eval="&quot;&quot;&quot;Create entry&quot;&quot;&quot;" name="name"/>
             <field name="transition_id" ref="process_transition_customerinvoice0"/>
         </record>
-    
+
     </data>
 </openerp>
index ae6aede..0bc8077 100644 (file)
@@ -3,32 +3,15 @@
     <data>
         <report auto="False" id="analytic_journal_print" menu="False" model="account.analytic.journal" name="account.analytic.account.journal" rml="account/project/report/analytic_journal.rml" string="Analytic Journal"/>
 
-<!--        <wizard id="account_analytic_account_journal_report" keyword="client_print_multi" model="account.analytic.journal" name="account.analytic.account.journal.report" string="Analytic Journal"/>-->
-
-
         <report auto="False" id="account_analytic_account_balance" menu="False" model="account.analytic.account" name="account.analytic.account.balance" rml="account/project/report/analytic_balance.rml" string="Analytic Balance"/>
 
-        <!--<wizard id="account_analytic_account_balance_report" keyword="client_print_multi" model="account.analytic.account" name="account.analytic.account.balance.report" string="Analytic Balance"/> -->
-
-
         <report auto="False" id="account_analytic_account_inverted_balance" menu="False" model="account.analytic.account" name="account.analytic.account.inverted.balance" rml="account/project/report/inverted_analytic_balance.rml" string="Inverted Analytic Balance"/>
 
-<!--        <wizard id="account_analytic_account_inverted_balance_report" keyword="client_print_multi" model="account.analytic.account" name="account.analytic.account.inverted.balance.report" string="Inverted Analytic Balance"/>-->
-
-
         <report auto="False" id="account_analytic_account_cost_ledger" menu="False" model="account.analytic.account" name="account.analytic.account.cost_ledger" rml="account/project/report/cost_ledger.rml" string="Cost Ledger"/>
 
-<!--        <wizard id="account_analytic_account_cost_ledger_report" keyword="client_print_multi" model="account.analytic.account" name="account.analytic.account.cost_ledger.report" string="Cost Ledger"/>-->
-
-
         <report auto="False" id="account_analytic_account_quantity_cost_ledger" menu="False" model="account.analytic.account" name="account.analytic.account.quantity_cost_ledger" rml="account/project/report/quantity_cost_ledger.rml" string="Cost Ledger (Only quantities)"/>
 
-<!--        <wizard id="account_analytic_account_quantity_cost_ledger_report" keyword="client_print_multi" model="account.analytic.account" name="account.analytic.account.quantity_cost_ledger.report" string="Cost Ledger (Only quantities)"/>-->
-
-
         <report auto="False" id="account_analytic_account_analytic_check" menu="False" model="account.account" name="account.analytic.account.analytic.check" rml="account/project/report/analytic_check.rml" string="Analytic Check"/>
 
-<!--        <wizard id="account_analytic_account_analytic_check_report" keyword="client_print_multi" model="account.account" name="account.analytic.account.analytic.check.report" string="Analytic Check"/>-->
-
     </data>
 </openerp>
index 6b973d1..fb7e411 100644 (file)
                     <field name="balance"/>
                     <field name="company_currency_id"/>
                     <field name="date" invisible="1"/>
-<!--                    <field name="parent_id" invisible="1"/>-->
-<!--                    <field name="type" invisible="1"/>-->
-<!--                    <field name="partner_id" invisible="1"/>-->
-<!--                    <field name="user_id" invisible="1"/>-->
                 </tree>
             </field>
         </record>
             <field name="context">{"search_default_user_id":uid}</field>
             <field name="search_view_id" ref="account.view_account_analytic_account_search"/>
         </record>
-        <!--<menuitem id="menu_analytic_account" name="Analytic Accounts" parent="account.menu_analytic_accounting"/>-->
         <menuitem action="action_account_analytic_account_form" id="account_analytic_def_account" parent="menu_analytic_accounting" groups="base.group_extended"/>
 
         <record id="act_account_renew_view" model="ir.actions.act_window">
             <field name="view_id" ref="view_account_analytic_account_tree"/>
             <field name="help">Analytic Charts of Accounts allows you to access to reports by analytic accounts (or cost accounts) . From this menu you can access to analytic balance, a report that relates the analytic accounts to the general accounts. It is useful for analyzing the profitability of projects, giving you the profitability of a project for the different operations that you used to carry out the project.</field>
         </record>
-<!--        <menuitem-->
-<!--            action="action_account_analytic_account_tree2"-->
-<!--            id="account_analytic_def_chart"-->
-<!--            parent="account_analytic_def_account"/>-->
-<!--        <menuitem action="action_account_analytic_account_tree2" id="account_analytic_chart" parent="account.menu_finance_charts"/>-->
-
-<!--        <wizard id="wizard_analytic_account_chart" menu="False" model="account.analytic.account" name="account.analytic.account.chart" string="Analytic Chart of Accounts"/>
-        <menuitem icon="STOCK_INDENT" action="wizard_analytic_account_chart" id="menu_action_analytic_account_tree2" parent="account.menu_finance_charts" type="wizard"/>-->
 
         <menuitem id="next_id_40" name="Analytic" parent="account.menu_finance_generic_reporting" sequence="4" groups="base.group_extended"/>
-<!--        <menuitem action="action_account_analytic_account_tree2" id="account_analytic_chart_balance" parent="next_id_40"/>-->
 
         <record id="view_account_analytic_line_form" model="ir.ui.view">
             <field name="name">account.analytic.line.form</field>
             <field name="context">{"search_default_user_id":uid}</field>
             <field name="view_id" ref="view_account_analytic_line_tree"/>
         </record>
-<!--       <wizard id="action_account_analytic_line" menu="False" model="account.analytic.line" name="account.analytic.line" string="Entries by Line"/>-->
-<!--        <menuitem id="next_id_41" name="Analytic Entries" parent="account.menu_finance_entries"/>-->
-          <!-- Entries by Line -->
 
-<!--         <menuitem  icon="STOCK_JUSTIFY_FILL"-->
-<!--          action="action_project_account_analytic_line_form"-->
-<!--          id="account_entries_analytic_entries"-->
-<!--          parent="next_id_41"/>-->
+        <!-- Entries by Line -->
 
         <record id="action_account_tree1" model="ir.actions.act_window">
             <field name="name">Analytic Entries</field>
             <field name="view_mode">tree,form</field>
         </record>
         <menuitem action="action_account_analytic_journal_open_form" id="account_analytic_journal_entries" parent="menu_finance_entries" groups="base.group_extended"/>
-        <!-- <record id="action_account_analytic_journal_open_form" model="ir.actions.act_window">
-            <field name="name">Check Register</field>
-            <field name="res_model">account.analytic.line</field>
-            <field name="view_type">form</field>
-            <field name="view_mode">tree,form</field>
-            <field name="domain">[('journal_id','=',active_id)]</field>
-        </record> -->
-<!--        <menuitem action="action_account_analytic_journal_open_form" id="account_analytic_journal_entries" parent="menu_finance_bank_and_cash"/>-->
-         <!-- <record id="action_account_analytic_journal_open_form" model="ir.actions.act_window">
-            <field name="name">Check Registers</field>
-            <field name="res_model">account.analytic.line</field>
-            <field name="view_type">form</field>
-            <field name="view_mode">tree,form</field>
-            <field name="domain">[('journal_id','=',active_id)]</field>
-        </record> -->
-<!--        <menuitem action="action_account_analytic_journal_open_form" id="account_analytic_journal_entries" parent="menu_finance_bank_and_cash"/>-->
-
-<!--        <record id="ir_open_account_journal_analytic" model="ir.values">-->
-<!--            <field eval="'tree_but_open'" name="key2"/>-->
-<!--            <field eval="'account.analytic.journal'" name="model"/>-->
-<!--            <field name="name">Open Analytic Journal</field>-->
-<!--            <field eval="'ir.actions.act_window,%d'%action_account_analytic_journal_open_form" name="value"/>-->
-<!--            <field eval="True" name="object"/>-->
-<!--        </record>-->
 
         #
         # Reporting
         </record>
         <menuitem action="action_account_analytic_journal_tree" id="account_analytic_journal_print" parent="account.next_id_40" groups="base.group_extended"/>
 
-
-<!--        <record id="action_account_analytic_journal_tree2" model="ir.actions.act_window">-->
-<!--            <field name="name">Analytic Entries by Journal</field>-->
-<!--            <field name="res_model">account.analytic.journal</field>-->
-<!--            <field name="view_type">tree</field>-->
-<!--            <field name="view_id" ref="view_account_analytic_journal_tree"/>-->
-<!--        </record>-->
-<!--        <menuitem action="action_account_analytic_journal_tree2" id="account_analytic_journal_entries" parent="account.next_id_41"/>-->
-
         #
         # Statistics
         #
             <field name="view_mode">tree,graph</field>
             <field name="search_view_id" ref="report_hr_timesheet_invoice_journal_search"/>
         </record>
-<!--        <menuitem action="report_account_analytic_journal_tree" id="report_account_analytic_journal_print" parent="account.next_id_40"/>-->
 
         <act_window domain="[('account_id', '=', active_id)]" id="act_acc_analytic_acc_5_report_hr_timesheet_invoice_journal" name="All Analytic Entries" res_model="account.analytic.line" src_model="account.analytic.account" view_mode="tree,form" view_type="form"/>
 
index b751808..2a0a8bb 100644 (file)
@@ -30,12 +30,12 @@ class account_analytic_balance(osv.osv_memory):
         'date1': fields.date('Start of period', required=True),
         'date2': fields.date('End of period', required=True),
         'empty_acc': fields.boolean('Empty Accounts ? ', help='Check if you want to display Accounts with 0 balance too.'),
-        }
+    }
 
     _defaults = {
         'date1':time.strftime('%Y-01-01'),
         'date2':time.strftime('%Y-%m-%d')
-        }
+    }
 
     def check_report(self, cr, uid, ids, context=None):
         datas = {}
index dc55d6c..8915581 100644 (file)
@@ -27,7 +27,7 @@ class account_analytic_chart(osv.osv_memory):
     _columns = {
         'from_date': fields.date('From'),
         'to_date': fields.date('To'),
-        }
+    }
 
     def analytic_account_chart_open_window(self, cr, uid, ids, context=None):
         mod_obj = self.pool.get('ir.model.data')
index 48c89df..5332796 100644 (file)
@@ -29,12 +29,12 @@ class account_analytic_check(osv.osv_memory):
     _columns = {
         'date1': fields.date('Start of period', required=True),
         'date2': fields.date('End of period', required=True),
-        }
+    }
 
     _defaults = {
         'date1':time.strftime('%Y-01-01'),
         'date2':time.strftime('%Y-%m-%d')
-        }
+    }
 
     def check_report(self, cr, uid, ids, context=None):
         datas = {}
index 6074fee..ad1ea42 100644 (file)
@@ -30,12 +30,12 @@ class account_analytic_cost_ledger_journal_report(osv.osv_memory):
         'date1': fields.date('Start of period', required=True),
         'date2': fields.date('End of period', required=True),
         'journal': fields.many2many('account.analytic.journal', 'ledger_journal_rel', 'ledger_id', 'Journal_id', 'Journals'),
-        }
+    }
 
     _defaults = {
         'date1':time.strftime('%Y-01-01'),
         'date2':time.strftime('%Y-%m-%d')
-        }
+    }
 
     def check_report(self, cr, uid, ids, context=None):
         datas = {}
index 96b480b..d228499 100644 (file)
@@ -29,12 +29,12 @@ class account_analytic_cost_ledger(osv.osv_memory):
     _columns = {
         'date1': fields.date('Start of period', required=True),
         'date2': fields.date('End of period', required=True),
-        }
+    }
 
     _defaults = {
         'date1':time.strftime('%Y-01-01'),
         'date2':time.strftime('%Y-%m-%d')
-        }
+    }
 
     def check_report(self, cr, uid, ids, context=None):
         datas = {}
index 52f7da9..0fac1ba 100644 (file)
@@ -29,12 +29,12 @@ class account_analytic_inverted_balance(osv.osv_memory):
     _columns = {
         'date1': fields.date('Start of period', required=True),
         'date2': fields.date('End of period', required=True),
-        }
+    }
 
     _defaults = {
         'date1':time.strftime('%Y-01-01'),
         'date2':time.strftime('%Y-%m-%d')
-        }
+    }
 
     def check_report(self, cr, uid, ids, context=None):
         datas = {}
index aef6a85..06bec94 100644 (file)
@@ -29,12 +29,12 @@ class account_analytic_Journal_report(osv.osv_memory):
     _columns = {
         'date1': fields.date('Start of period', required=True),
         'date2': fields.date('End of period', required=True),
-        }
+    }
 
     _defaults = {
         'date1':time.strftime('%Y-01-01'),
         'date2':time.strftime('%Y-%m-%d')
-        }
+    }
 
     def check_report(self, cr, uid, ids, context=None):
         datas = {}
index dbe3df3..5437abe 100644 (file)
@@ -27,7 +27,7 @@ class project_account_analytic_line(osv.osv_memory):
      _columns = {
          'from_date': fields.date('From'),
          'to_date': fields.date('To'),
-                }
+     }
 
      def action_open_window(self, cr, uid, ids, context={}):
           mod_obj =self.pool.get('ir.model.data')
index d564ffb..926c783 100644 (file)
@@ -28,8 +28,8 @@
             <field name="res_model">project.account.analytic.line</field>
             <field name="view_type">form</field>
             <field name="view_mode">tree,form</field>
-           <field name="view_id" ref="view_project_account_analytic_line_form"/>
-           <field name="target">new</field>
+            <field name="view_id" ref="view_project_account_analytic_line_form"/>
+            <field name="target">new</field>
         </record>
 
     </data>
index a70d79c..8e07f3a 100644 (file)
@@ -181,10 +181,6 @@ class aged_trial_report(rml_parse.rml_parse, common_report_header):
                        ## Add for total
                        self.total_account[(i+1)] = self.total_account[(i+1)] + (total and total[0] or 0.0)
                        values['name'] = partner['name']
-                       #t = 0.0
-                       #for i in range(5)+['direction']:
-                       #       t+= float(values.get(str(i), 0.0) or 0.0)
-                       #values['total'] = t
 
                        if values['total']:
                                res.append(values)
@@ -217,7 +213,7 @@ class aged_trial_report(rml_parse.rml_parse, common_report_header):
                    return 'Payable Accounts'
                elif data['form']['result_selection'] == 'customer_supplier':
                    return 'Receivable and Payable Accounts'
-               return ''       
+               return ''
 
 report_sxw.report_sxw('report.account.aged_trial_balance', 'res.partner',
                'addons/account/report/account_aged_partner_balance.rml',parser=aged_trial_report, header=False)
index 076369f..79e2334 100644 (file)
@@ -86,10 +86,6 @@ class account_balance(report_sxw.rml_parse, common_report_header):
         elif form['filter'] == 'filter_date':
             ctx['date_from'] = form['date_from']
             ctx['date_to'] =  form['date_to']
-#        accounts = obj_account.browse(self.cr, self.uid, ids, ctx)
-#        def cmp_code(x, y):
-#            return cmp(x.code, y.code)
-#        accounts.sort(cmp_code)
 
         child_ids = obj_account._get_children_and_consol(self.cr, self.uid, ids, ctx)
         if child_ids:
@@ -108,28 +104,11 @@ class account_balance(report_sxw.rml_parse, common_report_header):
                     'debit': account['debit'],
                     'credit': account['credit'],
                     'balance': account['balance'],
-                   # 'leef': not bool(account['child_id']),
                     'parent_id':account['parent_id'],
                     'bal_type':'',
                 }
             self.sum_debit += account['debit']
             self.sum_credit += account['credit']
-#            if account.child_id:
-#                def _check_rec(account):
-#                    if not account.child_id:
-#                        return bool(account.credit or account.debit)
-#                    for c in account.child_id:
-#                        if not _check_rec(c) or _check_rec(c):
-#                            return True
-#                    return False
-#                if not _check_rec(account) :
-#                    continue
-#            if account['parent_id']:
-#                acc = obj_account.read(self.cr, self.uid, [ account['parent_id'][0] ] ,['name'], ctx)
-#                for r in result_acc:
-#                    if r['id'] == account['parent_id'][0]:
-#                        res['level'] = r['level'] + 1
-#                        break
             if form['display_account'] == 'bal_movement':
                 if res['credit'] > 0 or res['debit'] > 0 or res['balance'] > 0 :
                     result_acc.append(res)
@@ -138,16 +117,6 @@ class account_balance(report_sxw.rml_parse, common_report_header):
                     result_acc.append(res)
             else:
                 result_acc.append(res)
-#            if account.child_id:
-#                acc_id = [acc.id for acc in account.child_id]
-#                lst_string = ''
-#                lst_string = '\'' + '\',\''.join(map(str,acc_id)) + '\''
-#                self.cr.execute("select code,id from account_account where id IN (%s)"%(lst_string))
-#                a_id = self.cr.fetchall()
-#                a_id.sort()
-#                ids2 = [x[1] for x in a_id]
-#
-#                result_acc += self.lines(form, ids2, done, level+1)
         return result_acc
 
 report_sxw.report_sxw('report.account.account.balance', 'account.account', 'addons/account/report/account_balance.rml', parser=account_balance, header="internal")
index 02d69ba..e8b8502 100644 (file)
@@ -24,8 +24,6 @@ import locale
 from report import report_sxw
 import rml_parse
 
-#from addons.account.wizard import wizard_account_balance_report
-
 parents = {
     'tr':1,
     'li':1,
@@ -59,267 +57,6 @@ class account_balance_landscape(rml_parse.rml_parse):
             })
         self.context = context
 
-#    def repeatIn(self, lst, name, nodes_parent=False,td=False,width=[],value=[],type=[]):
-#        self._node.data = ''
-#        node = self._find_parent(self._node, nodes_parent or parents)
-#        ns = node.nextSibling
-##start
-#        if value==['Cash','%']:
-#            if show==1:
-#                if perc==1:
-#                    if pattern=='none':
-#                        value=['','Cash','%']
-#                        type=['lable','lable','lable']
-#                        width=[130,65,65]
-#                    else:
-#                        value=[' ','','Cash','%']
-#                        type=['string','lable','lable','lable']
-#                        width=[65,130,65,65]
-#                else:
-#                    if pattern=='none':
-#                        value=['']
-#                        type=['lable']
-#                        width=[195]
-#                    else:
-#                        value=[' ','']
-#                        type=['string','lable']
-#                        width=[65,195]
-#            else:
-#                if perc==1:
-#                    if pattern=='none':
-#                        value=['Cash','%']
-#                        type=['lable','lable']
-#                        width=[65,65]
-#                    else:
-#                        value=[' ','Cash','%']
-#                        type=['string','lable','lable']
-#                        width=[65,65,65]
-#                else:
-#                    if pattern=='none':
-#                        value=['']
-#                        type=['lable']
-#                        width=[65]
-#                    else:
-#                        value=[' ','']
-#                        type=['string','lable']
-#                        width=[65,65]
-#
-#
-#        if value==['year']:
-#            if show==1:
-#                if perc==1:
-#                    if pattern=='none':
-#                        width=[260]
-#                    else:
-#                        value=[' ','year']
-#                        type=['string','string']
-#                        width=[65,260]
-#                else:
-#                    if pattern=='none':
-#                        width=[195]
-#                    else:
-#                        value=[' ','year']
-#                        type=['string','string']
-#                        width=[65,195]
-#            else:
-#                if perc==1:
-#                    if pattern=='none':
-#                        width=[130]
-#                    else:
-#                        value=[' ','year']
-#                        type=['string','string']
-#                        width=[65,130]
-#
-#                else:
-#                    if pattern=='none':
-#                        width=[65]
-#                    else:
-#                        value=[' ','year']
-#                        type=['string','string']
-#                        width=[65,65]
-#
-#        if value==['Debit','Credit','Balance']:
-#            if show==1:
-#                if perc==1:
-#                    if pattern=='none':
-#                        width=[65,65,130]
-#                    else:
-#                        value=[' ','Debit','Credit','Balance']
-#                        type=['string','lable','lable','lable']
-#                        width=[65,65,65,130]
-#                else:
-#                    if pattern=='none':
-#                        width=[65,65,65]
-#                    else:
-#                        value=[' ','Debit','Credit','Balance']
-#                        type=['string','lable','lable','lable']
-#                        width=[65,65,65,65]
-#
-#            else:
-#                if perc==1:
-#                    if pattern=='none':
-#                        value=['Balance']
-#                        type=['lable']
-#                        width=[130]
-#                    else:
-#                        value=[' ','Balance']
-#                        type=['string','lable']
-#                        width=[65,130]
-#                else:
-#                    if pattern=='none':
-#                        value=['Balance']
-#                        type=['lable']
-#                        width=[65]
-#                    else:
-#                        value=[' ','Balance']
-#                        type=['string','lable']
-#                        width=[65,65]
-#
-#        if value==['debit','credit','balance']:
-#            if show==1:
-#                if perc==1:
-#                    if pattern=='none':
-#                        value=['debit','credit','balance','balance_perc']
-#                        type=['string','string','string','string']
-#                        width=[65,65,65,65]
-#                    else:
-#                        value=[pattern,'debit','credit','balance','balance_perc']
-#                        type=['string','string','string','string','string']
-#                        width=[65,65,65,65,65]
-#                else:
-#                    if pattern=='none':
-#                        value=['debit','credit','balance']
-#                        type=['string','string','string']
-#                        width=[65,65,65]
-#                    else:
-#                        value=[pattern,'debit','credit','balance']
-#                        type=['string','string','string','string']
-#                        width=[65,65,65,65]
-#
-#            else:
-#                if perc==1:
-#                    if pattern=='none':
-#                        value=['balance','balance_perc']
-#                        type=['string','string']
-#                        width=[65,65]
-#                    else:
-#                        value=[pattern,'balance','balance_perc']
-#                        type=['string','string','string']
-#                        width=[65,65,65]
-#                else:
-#                    if pattern=='none':
-#                        value=['balance']
-#                        type=['string']
-#                        width=[65]
-#                    else:
-#                        value=[pattern,'balance']
-#                        type=['string','string']
-#                        width=[65,65]
-#
-#        if value==['sum_debit','sum_credit','']:
-#            if show==1:
-#                if perc==1:
-#                    if pattern=='none':
-#                        width=[65,65,130]
-#                    else:
-#                        value=[' ','sum_debit','sum_credit','']
-#                        type=['string','string','string','lable']
-#                        width=[65,65,65,130]
-#                else:
-#                    if pattern=='none':
-#                        width=[65,65,65]
-#                    else:
-#                        value=[' ','sum_debit','sum_credit','']
-#                        type=['string','string','string','lable']
-#                        width=[65,65,65,65]
-#            else:
-#                if perc==1:
-#                    if pattern=='none':
-#                        value=['']
-#                        type=['lable']
-#                        width=[130]
-#                    else:
-#                        value=[' ','']
-#                        type=['string','lable']
-#                        width=[65,130]
-#                else:
-#                    if pattern=='none':
-#                        value=['']
-#                        type=['lable']
-#                        width=[65]
-#                    else:
-#                        value=[' ','']
-#                        type=['string','lable']
-#                        width=[65,65]
-#
-#        if not lst:
-#            lst.append(1)
-#        for ns in node.childNodes :
-#            if ns and ns.nodeName!='#text' and ns.tagName=='blockTable' and td :
-#                width_str = ns._attrs['colWidths'].nodeValue
-#                ns.removeAttribute('colWidths')
-#                total_td = td * len(value)
-#
-#                if not width:
-#                    for v in value:
-#                        width.append(30)
-#                check1=0
-#                for t in range(td):
-#                    for v in range(len(value)):
-#                        if type[v] in ('String','STRING','string'):
-#                            if (value[v]==" " or value[0]==pattern):
-#                                if check1==0:
-#                                    check1=1
-#                                    width_str +=',0.0'
-#                                else:
-#                                    width_str +=',%d'%width[v]
-#                            else:
-#                                width_str +=',%d'%width[v]
-#                        else:
-#                            width_str +=',%d'%width[v]
-#                ns.setAttribute('colWidths',width_str)
-#
-#                child_list =  ns.childNodes
-#
-#                check=0
-#                for child in child_list:
-#                    if child.nodeName=='tr':
-#                        lc = child.childNodes[1]
-#                        for t in range(td):
-#                            i=0
-#                            for v in value:
-#
-#                                newnode = lc.cloneNode(1)
-#                                temp2="%s['status']==1 and ( setTag('para','para',{'fontName':'Helvetica-bold'})) ]]"%(name)
-##
-#                                if type[i] in ('String','STRING','string'):
-#                                    if (v==" " or v==pattern) and i==0 and check==0:
-#                                        check=1
-#                                        if newnode.childNodes[1].lastChild:
-#                                            newnode.childNodes[1].lastChild.data=""
-#                                    else:
-#                                        if v==" ":
-#                                            if newnode.childNodes[1].lastChild:
-#                                                newnode.childNodes[1].lastChild.data=""
-#                                        else:
-#                                            t1= "[[ %s['%s%d'] ]]"%(name,v,t)
-#                                            if v=="year" or v=="sum_debit" or v=="sum_credit":
-#                                                if newnode.childNodes[1].lastChild:
-#                                                    newnode.childNodes[1].lastChild.data = t1
-#                                            else:
-#                                                if newnode.childNodes[1].lastChild:
-#                                                    newnode.childNodes[1].lastChild.data = t1+"[["+temp2
-##                                   newnode.childNodes[1].lastChild.data=[[ a['status']==1 and ( setTag('para','para',{'fontName':'Times-bold'})) ]]
-#                                elif type[i] in ('Lable','LABLE','lable'):
-#                                    if newnode.childNodes[1].lastChild:
-#                                        newnode.childNodes[1].lastChild.data= v
-#
-#                                child.appendChild(newnode)
-#
-#                                newnode=False
-#                                i+=1
-#        return super(account_balance_landscape,self).repeatIn(lst, name, nodes_parent=False)
-#end
     def linesForYear(self,form):
         temp=0
         years={}
@@ -363,7 +100,6 @@ class account_balance_landscape(rml_parse.rml_parse):
 
 
         total_for_perc=[]
-#       if perc==1:
         self.done_total=1
         self.total_for_perc=self.linesForTotal(form, ids={}, doneAccount={}, level=1)
         self.done_total=0
@@ -372,8 +108,6 @@ class account_balance_landscape(rml_parse.rml_parse):
             locale.setlocale(locale.LC_ALL, '')
             self.result_total["sum_credit" + str(t1)]=locale.format("%.2f", self.result_total["sum_credit" + str(t1)], grouping=True)
             self.result_total["sum_debit" + str(t1)]=locale.format("%.2f", self.result_total["sum_debit" + str(t1)], grouping=True)
-#           self.flag=1
-#           self.result_total = {}
 
         for temp in range(0,len(form['fiscalyear'])):
             fy=self.pool.get('account.fiscalyear').name_get(self.cr, self.uid, form['fiscalyear'][temp])
index ab5a284..e76c845 100644 (file)
@@ -91,7 +91,6 @@ class report_balancesheet_horizontal(rml_parse.rml_parse, common_report_header):
         ]
 
         ctx = self.context.copy()
-#        ctx['state'] = form['context'].get('state','filter_no')
         ctx['fiscalyear'] = data['form'].get('fiscalyear_id', False)
 
         if data['form']['filter'] == 'filter_period' :
index 5a62c1e..362d0ad 100644 (file)
@@ -122,7 +122,6 @@ class report_aged_receivable(osv.osv):
         """ This view will be used in dashboard
         The reason writing this code here is, we need to check date range from today to first date of fiscal year.
         """
-#        ranges = _get_ranges(cr) # Gets the ranges for the x axis of the graph (name column values)
         pool_obj_fy = pooler.get_pool(cr.dbname).get('account.fiscalyear')
         today = time.strftime('%Y-%m-%d')
         fy_id = pool_obj_fy.find(cr, uid, exception=False)
index 96b49f0..a0cee80 100644 (file)
@@ -47,7 +47,6 @@
             <field name="view_type">form</field>
             <field name="view_mode">tree,graph</field>
         </record>
-       <!--  <menuitem action="action_account_receivable_graph" id="menu_account_receivable_graph" parent="account.menu_finance_reporting"/> -->
 
         <!-- Report for Aged Receivable -->
 
                    <field name="view_id" ref="board_view_created_invoice"/>
            </record>
 
-<!--       <menuitem id="menu_report_this_month" name="This Month" parent="account.menu_finance_reporting"/>-->
-           <!-- <menuitem id="menu_report_all_months" name="Sales by Account" parent="account.menu_finance_reporting"/> -->
-           <!-- Report of the sales by product and account -->
            <record id="view_report_account_sales_tree" model="ir.ui.view">
             <field name="name">report.account.sales.tree</field>
             <field name="model">report.account.sales</field>
             <field name="view_mode">graph,tree</field>
             <field name="search_view_id" ref="view_report_account_sales_search"/>
         </record>
-        <!-- <menuitem action="action_report_account_sales_tree_all" id="menu_report_account_sales_all" parent="menu_report_all_months"/> -->
 
-        <!-- Report of the sales by product and account type -->
            <record id="view_report_account_type_sales_tree" model="ir.ui.view">
             <field name="name">report.account_type.sales.tree</field>
             <field name="model">report.account_type.sales</field>
             <field name="view_mode">graph,tree</field>
             <field name="search_view_id" ref="view_report_account_type_sales_search"/>
         </record>
-        <!-- <menuitem action="action_report_account_type_sales_tree_all" id="menu_report_account_type_sales_all" parent="menu_report_all_months"/> -->
 
     </data>
 </openerp>
index 13fb90f..b29b2ea 100644 (file)
@@ -58,268 +58,6 @@ class account_balance(report_sxw.rml_parse):
             })
         self.context = context
 
-#    def repeatIn(self, lst, name, nodes_parent=False,td=False,width=[],value=[],type=[]):
-#        self._node.data = ''
-#        node = self._find_parent(self._node, nodes_parent or parents)
-#        ns = node.nextSibling
-##start
-#        if value==['Cash','%']:
-#            if show==1:
-#                if perc==1:
-#                    if pattern=='none':
-#                        value=['','Cash','%']
-#                        type=['lable','lable','lable']
-#                        width=[130,65,65]
-#                    else:
-#                        value=[' ','','Cash','%']
-#                        type=['string','lable','lable','lable']
-#                        width=[65,130,65,65]
-#                else:
-#                    if pattern=='none':
-#                        value=['']
-#                        type=['lable']
-#                        width=[195]
-#                    else:
-#                        value=[' ','']
-#                        type=['string','lable']
-#                        width=[65,195]
-#            else:
-#                if perc==1:
-#                    if pattern=='none':
-#                        value=['Cash','%']
-#                        type=['lable','lable']
-#                        width=[65,65]
-#                    else:
-#                        value=[' ','Cash','%']
-#                        type=['string','lable','lable']
-#                        width=[65,65,65]
-#                else:
-#                    if pattern=='none':
-#                        value=['']
-#                        type=['lable']
-#                        width=[65]
-#                    else:
-#                        value=[' ','']
-#                        type=['string','lable']
-#                        width=[65,65]
-#
-#
-#        if value==['year']:
-#            if show==1:
-#                if perc==1:
-#                    if pattern=='none':
-#                        width=[260]
-#                    else:
-#                        value=[' ','year']
-#                        type=['string','string']
-#                        width=[65,260]
-#                else:
-#                    if pattern=='none':
-#                        width=[195]
-#                    else:
-#                        value=[' ','year']
-#                        type=['string','string']
-#                        width=[65,195]
-#            else:
-#                if perc==1:
-#                    if pattern=='none':
-#                        width=[130]
-#                    else:
-#                        value=[' ','year']
-#                        type=['string','string']
-#                        width=[65,130]
-#
-#                else:
-#                    if pattern=='none':
-#                        width=[65]
-#                    else:
-#                        value=[' ','year']
-#                        type=['string','string']
-#                        width=[65,65]
-#
-#        if value==['Debit','Credit','Balance']:
-#            if show==1:
-#                if perc==1:
-#                    if pattern=='none':
-#                        width=[65,65,130]
-#                    else:
-#                        value=[' ','Debit','Credit','Balance']
-#                        type=['string','lable','lable','lable']
-#                        width=[65,65,65,130]
-#                else:
-#                    if pattern=='none':
-#                        width=[65,65,65]
-#                    else:
-#                        value=[' ','Debit','Credit','Balance']
-#                        type=['string','lable','lable','lable']
-#                        width=[65,65,65,65]
-#
-#            else:
-#                if perc==1:
-#                    if pattern=='none':
-#                        value=['Balance']
-#                        type=['lable']
-#                        width=[130]
-#                    else:
-#                        value=[' ','Balance']
-#                        type=['string','lable']
-#                        width=[65,130]
-#                else:
-#                    if pattern=='none':
-#                        value=['Balance']
-#                        type=['lable']
-#                        width=[65]
-#                    else:
-#                        value=[' ','Balance']
-#                        type=['string','lable']
-#                        width=[65,65]
-#
-#        if value==['debit','credit','balance']:
-#            if show==1:
-#                if perc==1:
-#                    if pattern=='none':
-#                        value=['debit','credit','balance','balance_perc']
-#                        type=['string','string','string','string']
-#                        width=[65,65,65,65]
-#                    else:
-#                        value=[pattern,'debit','credit','balance','balance_perc']
-#                        type=['string','string','string','string','string']
-#                        width=[65,65,65,65,65]
-#                else:
-#                    if pattern=='none':
-#                        value=['debit','credit','balance']
-#                        type=['string','string','string']
-#                        width=[65,65,65]
-#                    else:
-#                        value=[pattern,'debit','credit','balance']
-#                        type=['string','string','string','string']
-#                        width=[65,65,65,65]
-#
-#            else:
-#                if perc==1:
-#                    if pattern=='none':
-#                        value=['balance','balance_perc']
-#                        type=['string','string']
-#                        width=[65,65]
-#                    else:
-#                        value=[pattern,'balance','balance_perc']
-#                        type=['string','string','string']
-#                        width=[65,65,65]
-#                else:
-#                    if pattern=='none':
-#                        value=['balance']
-#                        type=['string']
-#                        width=[65]
-#                    else:
-#                        value=[pattern,'balance']
-#                        type=['string','string']
-#                        width=[65,65]
-#
-#        if value==['sum_debit','sum_credit','']:
-#            if show==1:
-#                if perc==1:
-#                    if pattern=='none':
-#                        width=[65,65,130]
-#                    else:
-#                        value=[' ','sum_debit','sum_credit','']
-#                        type=['string','string','string','lable']
-#                        width=[65,65,65,130]
-#                else:
-#                    if pattern=='none':
-#                        width=[65,65,65]
-#                    else:
-#                        value=[' ','sum_debit','sum_credit','']
-#                        type=['string','string','string','lable']
-#                        width=[65,65,65,65]
-#            else:
-#                if perc==1:
-#                    if pattern=='none':
-#                        value=['']
-#                        type=['lable']
-#                        width=[130]
-#                    else:
-#                        value=[' ','']
-#                        type=['string','lable']
-#                        width=[65,130]
-#                else:
-#                    if pattern=='none':
-#                        value=['']
-#                        type=['lable']
-#                        width=[65]
-#                    else:
-#                        value=[' ','']
-#                        type=['string','lable']
-#                        width=[65,65]
-#
-#        if not lst:
-#            lst.append(1)
-#        for ns in node.childNodes :
-#            if ns and ns.nodeName!='#text' and ns.tagName=='blockTable' and td :
-#                width_str = ns._attrs['colWidths'].nodeValue
-#                ns.removeAttribute('colWidths')
-#                total_td = td * len(value)
-#
-#                if not width:
-#                    for v in value:
-#                        width.append(30)
-#                check1=0
-#                for t in range(td):
-#                    for v in range(len(value)):
-#                        if type[v] in ('String','STRING','string'):
-#                            if (value[v]==" " or value[0]==pattern):
-#                                if check1==0:
-#                                    check1=1
-#                                    width_str +=',0.0'
-#                                else:
-#                                    width_str +=',%d'%width[v]
-#                            else:
-#                                width_str +=',%d'%width[v]
-#                        else:
-#                            width_str +=',%d'%width[v]
-#                ns.setAttribute('colWidths',width_str)
-#
-#                child_list =  ns.childNodes
-#
-#                check=0
-#                for child in child_list:
-#                    if child.nodeName=='tr':
-#                        lc = child.childNodes[1]
-#                        for t in range(td):
-#                            i=0
-#                            for v in value:
-#
-#                                newnode = lc.cloneNode(1)
-#                                temp2="%s['status']==1 and ( setTag('para','para',{'fontName':'Helvetica-bold'})) ]]"%(name)
-##
-#                                if type[i] in ('String','STRING','string'):
-#                                    if (v==" " or v==pattern) and i==0 and check==0:
-#                                        check=1
-#                                        if newnode.childNodes[1].lastChild:
-#                                            newnode.childNodes[1].lastChild.data=""
-#                                    else:
-#                                        if v==" ":
-#                                            if newnode.childNodes[1].lastChild:
-#                                                newnode.childNodes[1].lastChild.data=""
-#                                        else:
-#                                            t1= "[[ %s['%s%d'] ]]"%(name,v,t)
-#                                            if v=="year" or v=="sum_debit" or v=="sum_credit":
-#                                                if newnode.childNodes[1].lastChild:
-#                                                    newnode.childNodes[1].lastChild.data = t1
-#                                            else:
-#                                                if newnode.childNodes[1].lastChild:
-#                                                    newnode.childNodes[1].lastChild.data = t1+"[["+temp2
-##                                   newnode.childNodes[1].lastChild.data=[[ a['status']==1 and ( setTag('para','para',{'fontName':'Times-bold'})) ]]
-#                                elif type[i] in ('Lable','LABLE','lable'):
-#                                    if newnode.childNodes[1].lastChild:
-#                                        newnode.childNodes[1].lastChild.data= v
-#
-#                                child.appendChild(newnode)
-#
-#                                newnode=False
-#                                i+=1
-#        return super(account_balance,self).repeatIn(lst, name, nodes_parent=False)
-#end
-
     def linesForYear(self, form):
         temp=0
         years={}
@@ -363,7 +101,6 @@ class account_balance(report_sxw.rml_parse):
 
 
         total_for_perc=[]
-#       if perc==1:
         self.done_total=1
         self.total_for_perc=self.linesForTotal(form, ids={}, doneAccount={}, level=1)
         self.done_total=0
@@ -372,8 +109,6 @@ class account_balance(report_sxw.rml_parse):
             locale.setlocale(locale.LC_ALL, '')
             self.result_total["sum_credit" + str(t1)]=locale.format("%.2f", self.result_total["sum_credit" + str(t1)], grouping=True)
             self.result_total["sum_debit" + str(t1)]=locale.format("%.2f", self.result_total["sum_debit" + str(t1)], grouping=True)
-#           self.flag=1
-#           self.result_total = {}
 
         for temp in range(0,len(form['fiscalyear'])):
             fy=self.pool.get('account.fiscalyear').name_get(self.cr, self.uid, form['fiscalyear'][temp])
index 1b38b93..9178c0f 100644 (file)
@@ -106,7 +106,6 @@ class rml_parse(report_sxw.rml_parse):
             return Stringer
         return Stringer
     def explode_this(self,chaine,length):
-        #chaine = self.repair_string(chaine)
         chaine = rstrip(chaine)
         ast = list(chaine)
         i = length
@@ -120,7 +119,6 @@ class rml_parse(report_sxw.rml_parse):
         UnicodeAst = []
         _previouslyfound = False
         i = 0
-        #print str(ast)
         while i < len(ast):
             elem = ast[i]
             try:
@@ -160,25 +158,5 @@ class rml_parse(report_sxw.rml_parse):
         rml_head =  rml_head.replace('<pageGraphics>','''<pageGraphics> <image x="10" y="26cm" height="770.0" width="1120.0" >[[company.logo]] </image> ''')
         return True
 
-    # def _add_header(self, node):
-    #   rml_head = tools.file_open('specific_param/report/header/corporate_rml_header_ch.rml').read()
-    #   head_dom = xml.dom.minidom.parseString(rml_head)
-    #   #for frame in head_dom.getElementsByTagName('frame'):
-    #   #   frame.parentNode.removeChild(frame)
-    #   node2 = head_dom.documentElement
-    #   for tag in node2.childNodes:
-    #       if tag.nodeType==tag.ELEMENT_NODE:
-    #           found = self._find_node(node, tag.localName)
-    #   #       rml_frames = found.getElementsByTagName('frame')
-    #           if found:
-    #               if tag.hasAttribute('position') and (tag.getAttribute('position')=='inside'):
-    #                   found.appendChild(tag)
-    #               else:
-    #                   found.parentNode.replaceChild(tag, found)
-    #   #       for frame in rml_frames:
-    #   #           tag.appendChild(frame)
-    #   return True
-
-
 
 # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
index 2075b1f..5e5f68a 100644 (file)
@@ -78,7 +78,6 @@ class tax_report(rml_parse.rml_parse):
                                top_result.append(res_general[ind_general])
                                ind_general+=1
                        i+=1
-               #array_result = self.sort_result(top_result)
                return top_result
                #return array_result
 
@@ -133,8 +132,6 @@ class tax_report(rml_parse.rml_parse):
                                                company_id, periods_ids,))
                res = self.cr.dictfetchall()
 
-                                               #AND line.period_id IN ('+ period_sql_list +') \
-
                i = 0
                while i<len(res):
                        res[i]['account'] = obj_account.browse(self.cr, self.uid, res[i]['account_id'], context=context)
index b88619e..dea907a 100644 (file)
@@ -50,7 +50,6 @@ import account_invoice_state
 import account_chart
 #TODO: remove this file no moe used
 # also remove related view fiel
-#import account_move_line_select
 
 import account_validate_account_move
 import account_use_model
index 900e1c4..436d320 100644 (file)
@@ -151,8 +151,6 @@ class account_automatic_reconcile(osv.osv_memory):
                 query = "SELECT partner_id FROM account_move_line WHERE account_id=%s AND reconcile_id IS NULL \
                 AND state <> 'draft' GROUP BY partner_id \
                 HAVING ABS(SUM(debit-credit)) <> %s AND count(*)>0"%(account_id, 0.0)
-#                query="SELECT partner_id FROM account_move_line WHERE account_id=%s AND reconcile_id IS NULL \
-#                AND state <> 'draft' GROUP BY partner_id AND debit = credi"%(account_id)
             else:
                 query = "SELECT partner_id FROM account_move_line WHERE account_id=%s AND reconcile_id IS NULL \
                 AND state <> 'draft' GROUP BY partner_id \
index c9cc5ff..bace3d0 100644 (file)
@@ -64,7 +64,7 @@ class account_chart(osv.osv_memory):
     _defaults = {
         'fiscalyear': _get_fiscalyear,
         'target_move': 'all'
-                }
+    }
 account_chart()
 
 # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
index 5378cd2..05e441c 100644 (file)
@@ -46,13 +46,13 @@ class account_compare_account_balance_report(osv.osv_memory):
         'periods': fields.many2many('account.period', 'period_account_balance_rel',
                                     'report_id', 'period_id', 'Periods',
                                     help='Keep empty for all open fiscal year'),
-        }
+    }
 
     _defaults={
         'compare_pattern': 'none',
         'account_choice': 'moves',
         'period_manner': 'actual',
-        }
+    }
 
     def check(self, cr, uid, ids, context=None):
         data={}
index 65645f5..a8018e0 100644 (file)
@@ -39,10 +39,10 @@ class account_fiscalyear_close(osv.osv_memory):
                                  'Opening Entries Period', required=True),
        'report_name': fields.char('Name of new entries',size=64, required=True),
        'sure': fields.boolean('Check this box'),
-              }
+    }
     _defaults = {
         'report_name':'End of Fiscal Year Entry',
-        }
+    }
 
     def data_save(self, cr, uid, ids, context=None):
         """
index 4d0479f..fd58e8c 100644 (file)
@@ -33,7 +33,7 @@ class account_fiscalyear_close_state(osv.osv_memory):
        'fy_id': fields.many2one('account.fiscalyear', \
                                  'Fiscal Year to close', required=True),
        'sure': fields.boolean('Check this box', required=False)
-              }
+    }
 
     def data_save(self, cr, uid, ids, context=None):
         """
index 7130e7d..6f6dca2 100644 (file)
@@ -12,7 +12,7 @@
                         <button icon="gtk-cancel" special="cancel" string="Close"/>
                         <button icon="terp-camera_test" string="Confirm Invoices" name="invoice_confirm" type="object" default_focus="1"/>
                    </group>
-               </form>
+            </form>
             </field>
         </record>
 
             <field name="res_model">account.invoice.confirm</field>
             <field name="view_type">form</field>
             <field name="view_mode">form</field>
-           <field name="view_id" ref="account_invoice_confirm_view"/>
-           <field name="target">new</field>
+            <field name="view_id" ref="account_invoice_confirm_view"/>
+            <field name="target">new</field>
         </record>
 
-<!--        <record model="ir.values" id="action_account_invoice_confirm_values">-->
-<!--            <field name="model_id" ref="account.model_account_invoice" />-->
-<!--            <field name="object" eval="1" />-->
-<!--            <field name="name">Confirm Draft Invoices</field>-->
-<!--            <field name="key2">client_action_multi</field>-->
-<!--            <field name="value" eval="'ir.actions.act_window,' +str(ref('action_account_invoice_confirm'))" />-->
-<!--            <field name="key">action</field>-->
-<!--            <field name="model">account.invoice</field>-->
-<!--        </record>-->
-
         <record id="account_invoice_cancel_view" model="ir.ui.view">
             <field name="name">account.invoice.cancel.form</field>
             <field name="model">account.invoice.cancel</field>
@@ -46,7 +36,7 @@
                         <button icon="terp-dialog-close" special="cancel" string="Close"/>
                         <button icon="gtk-cancel" string="Cancel Invoices" name="invoice_cancel" type="object" default_focus="1"/>
                    </group>
-               </form>
+            </form>
             </field>
         </record>
 
             <field name="res_model">account.invoice.cancel</field>
             <field name="view_type">form</field>
             <field name="view_mode">form</field>
-           <field name="view_id" ref="account_invoice_cancel_view"/>
-           <field name="target">new</field>
+            <field name="view_id" ref="account_invoice_cancel_view"/>
+            <field name="target">new</field>
         </record>
 
-<!--        <record model="ir.values" id="action_account_invoice_cancel_values">-->
-<!--            <field name="model_id" ref="account.model_account_invoice" />-->
-<!--            <field name="object" eval="1" />-->
-<!--            <field name="name">Cancel Selected Invoices</field>-->
-<!--            <field name="key2">client_action_multi</field>-->
-<!--            <field name="value" eval="'ir.actions.act_window,' +str(ref('action_account_invoice_cancel'))" />-->
-<!--            <field name="key">action</field>-->
-<!--            <field name="model">account.invoice</field>-->
-<!--        </record>-->
-
     </data>
 </openerp>
index b103f0c..fd1d560 100644 (file)
@@ -31,7 +31,7 @@ class account_move_bank_reconcile(osv.osv_memory):
     _description = "Move bank reconcile"
     _columns = {
        'journal_id': fields.many2one('account.journal', 'Journal', required=True),
-              }
+    }
 
     def action_open_window(self, cr, uid, ids, context={}):
         """
index 1d0dce8..7f89e70 100644 (file)
@@ -156,7 +156,6 @@ class account_move_journal(osv.osv_memory):
         res_id = data_pool.browse(cr, uid, result, context=context).res_id
         
         return {
-#            'domain': str([('journal_id', '=', journal_id), ('period_id', '=', period_id)]),
             'name': name,
             'view_type': 'form',
             'view_mode': 'tree,graph,form',
index d089db0..8538270 100644 (file)
@@ -27,7 +27,7 @@ class account_move_line_reconcile_select(osv.osv_memory):
     _columns = {
        'account_id': fields.many2one('account.account', 'Account', \
                             domain = [('reconcile', '=', 1)], required=True),
-              }
+    }
 
     def action_open_window(self, cr, uid, ids, context={}):
         """
@@ -47,7 +47,7 @@ class account_move_line_reconcile_select(osv.osv_memory):
             'view_id': False,
             'res_model': 'account.move.line',
             'type': 'ir.actions.act_window'
-            }
+        }
 
 account_move_line_reconcile_select()
 
index c4c06dc..93e8c9a 100644 (file)
@@ -29,8 +29,5 @@
            <field name="target">new</field>
         </record>
 
-        <!-- <menuitem action="action_account_reconcile_select"
-            id="menu_reconcile_select" parent="periodical_processing_reconciliation" /> -->
-
     </data>
 </openerp>
index 645b5a0..ae6c9e5 100644 (file)
             <field name="res_model">account.move.line.select</field>
             <field name="view_type">form</field>
             <field name="view_mode">form</field>
-           <field name="view_id" ref="account_move_line_select_button_view"/>
-           <field name="target">new</field>
+            <field name="view_id" ref="account_move_line_select_button_view"/>
+            <field name="target">new</field>
         </record>
 
-<!--        <record id="ir_account_move_line_select" model="ir.values">-->
-<!--            <field name="key2">tree_but_open</field>-->
-<!--            <field name="model">account.account</field>-->
-<!--            <field name="name">Open Account</field>-->
-<!--            <field eval="'ir.actions.act_window,%d'%action_account_move_line_select_button" name="value"/>-->
-<!--            <field eval="True" name="object"/>-->
-<!--        </record>-->
-
     </data>
 </openerp>
index 35d4420..c445828 100644 (file)
@@ -28,7 +28,7 @@ class account_move_line_unreconcile_select(osv.osv_memory):
     _description = "Unreconciliation"
     _columns ={
        'account_id': fields.many2one('account.account','Account',required=True),
-               }
+    }
     def action_open_window(self, cr, uid, ids, context={}):
         data = self.read(cr, uid, ids, context=context)[0]
         return {
@@ -39,7 +39,7 @@ class account_move_line_unreconcile_select(osv.osv_memory):
                 'view_id': False,
                 'res_model': 'account.move.line',
                 'type': 'ir.actions.act_window'
-            }
+        }
 
 account_move_line_unreconcile_select()
 
index 33e96b9..146d288 100644 (file)
@@ -29,8 +29,5 @@
             <field name="target">new</field>
         </record>
 
-      <!--  <menuitem action="action_account_unreconcile_select"
-            id="menu_unreconcile_select" parent="periodical_processing_reconciliation" /> -->
-
     </data>
 </openerp>
index 381c4c4..229a0d5 100644 (file)
@@ -27,7 +27,7 @@ class account_open_closed_fiscalyear(osv.osv_memory):
     _columns = {
        'fyear_id': fields.many2one('account.fiscalyear', \
                                  'Fiscal Year to Open', required=True, help='Select Fiscal Year which you want to remove entries for its End of year entries journal'),
-              }
+    }
 
     def remove_entries(self, cr, uid, ids, context={}):
         data = self.read(cr, uid, ids, [])[0]
index d4c3509..625be2d 100644 (file)
@@ -29,9 +29,5 @@
             <field name="target">new</field>
         </record>
 
-<!--        <menuitem action="action_account_open_closed_fiscalyear"-->
-<!--            id="menu_wizard_open_closed_fy"  sequence="2"-->
-<!--            parent="account.menu_account_end_year_treatments" />-->
-
     </data>
 </openerp>
index 078929f..109d9f1 100644 (file)
@@ -36,7 +36,7 @@ class account_invoice_pay_writeoff(osv.osv_memory):
         'writeoff_journal_id': fields.many2one('account.journal', 'Write-Off journal', required=True),
         'comment': fields.char('Comment', size=64, required=True),
         'analytic_id': fields.many2one('account.analytic.account','Analytic Account', domain=[('parent_id', '!=', False)])
-        }
+    }
     _defaults = {
         'comment': 'Write-Off',
     }
index 78254a9..a157624 100644 (file)
@@ -16,7 +16,7 @@
                         <field name="period_id" widget="selection"/>
                     </group>
                     <group colspan="4" col="6">
-                           <label string ="" colspan="2"/>
+                        <label string ="" colspan="2"/>
                         <button icon="gtk-cancel" special="cancel" string="Cancel"/>
                         <button icon="gtk-execute" string="Partial Payment" name="pay_and_reconcile" type="object"/>
                         <button icon="gtk-execute" string="Full Payment" name="wo_check" type="object"/>
@@ -60,6 +60,5 @@
             </field>
         </record>
 
-
     </data>
 </openerp>
index 56a4f2c..5342f4b 100644 (file)
@@ -30,7 +30,7 @@ class account_period_close(osv.osv_memory):
     _description = "period close"
     _columns = {
         'sure': fields.boolean('Check this box'),
-              }
+    }
 
     def data_save(self, cr, uid, ids, context=None):
         """
index 27b7399..bb272eb 100644 (file)
@@ -30,7 +30,7 @@ class account_move_line_reconcile_prompt(osv.osv_memory):
     _name = 'account.move.line.reconcile.prompt'
     _description = 'Account move line reconcile'
     _columns = {
-        }
+    }
 
     def ask_reconcilation(self, cr, uid, ids, context):
         return self.pool.get('account.move.line.reconcile').partial_check(cr, uid, ids, context)
@@ -48,7 +48,7 @@ class account_move_line_reconcile(osv.osv_memory):
         'credit': fields.float('Credit amount', readonly=True),
         'debit': fields.float('Debit amount', readonly=True),
         'writeoff': fields.float('Write-Off amount', readonly=True),
-        }
+    }
 
     def default_get(self, cr, uid, fields, context=None):
         res = super(account_move_line_reconcile, self).default_get(cr, uid, fields, context=context)
@@ -149,11 +149,11 @@ class account_move_line_reconcile_writeoff(osv.osv_memory):
         'date_p': fields.date('Date'),
         'comment': fields.char('Comment', size= 64, required=True),
         'analytic_id': fields.many2one('account.analytic.account', 'Analytic Account', domain=[('parent_id', '!=', False)]),
-        }
+    }
     _defaults = {
         'date_p': time.strftime('%Y-%m-%d'),
         'comment': 'Write-off',
-        }
+    }
 
     def trans_rec_addendum(self, cr, uid, ids, context=None):
         mod_obj = self.pool.get('ir.model.data')
index 6a1e354..d1b84e0 100644 (file)
@@ -71,15 +71,6 @@ class account_partner_reconcile_process(osv.osv_memory):
         self.pool.get('res.partner').write(cr, uid, partner_id, {'last_reconciliation_date': time.strftime('%Y-%m-%d')}, context)
         #TODO: we have to find a way to update the context of the current tab (we could open a new tab with the context but it's not really handy)
         #TODO: remove that comments when the client side dev is done
-        #context.update({'partner_id': self.browse(cr, uid, ids, context)[0].next_partner_id})
-        #return {'context': context,
-        #        'target': 'opener',
-        #        'name': 'reconciliation process',
-        #        'view_type': 'form',
-        #        'view_mode': 'tree,form',
-        #        'res_model': 'account.move.line',
-        #        'type': 'ir.actions.act_window'
-        #}
         return {}
 
     _columns = {
index 05a50e6..297269d 100644 (file)
             <field name="model">account.move.line</field>
         </record>
 
-<!--      <menuitem
-                       icon="STOCK_EXECUTE"
-                       name="Partner reconciliation"
-                       action="action_account_partner_reconcile"
-                       id="menu_partner_reconcile"
-                       parent="account.next_id_20"/>
--->
        </data>
 </openerp>
index 6732034..06dccb5 100644 (file)
@@ -2,42 +2,6 @@
 <openerp>
     <data>
 
-<!--        <record id="view_account_move_line_reconcile_prompt" model="ir.ui.view">-->
-<!--            <field name="name">account.move.line.reconcile.prompt.form</field>-->
-<!--            <field name="model">account.move.line.reconcile.prompt</field>-->
-<!--            <field name="type">form</field>-->
-<!--            <field name="arch" type="xml">-->
-<!--                <form string="Reconciliation">-->
-<!--                    <separator string="Are you sure you want to reconcile entries?" colspan="4"/>-->
-<!--                    <group colspan="4" col="6">-->
-<!--                           <label string ="" colspan="2"/>-->
-<!---->
-<!--                        <button icon="gtk-cancel" special="cancel" string="Cancel"/>-->
-<!--                        <button icon="gtk-ok" string="Ok" name="ask_reconcilation" type="object" default_focus="1"/>-->
-<!--                   </group>-->
-<!--               </form>-->
-<!--            </field>-->
-<!--        </record>-->
-
-<!--        <record id="action_view_account_move_line_reconcile_prompt" model="ir.actions.act_window">-->
-<!--            <field name="name">Reconcile Entries</field>-->
-<!--            <field name="res_model">account.move.line.reconcile.prompt</field>-->
-<!--            <field name="view_type">form</field>-->
-<!--            <field name="view_mode">tree,form</field>-->
-<!--               <field name="view_id" ref="view_account_move_line_reconcile_prompt"/>-->
-<!--               <field name="target">new</field>-->
-<!--        </record>-->
-
-<!--        <record model="ir.values" id="action_account_move_line_reconcile_prompt_values">-->
-<!--            <field name="model_id" ref="account.model_account_move_line" />-->
-<!--            <field name="object" eval="1" />-->
-<!--            <field name="name">Reconcile Entries</field>-->
-<!--            <field name="key2">client_action_multi</field>-->
-<!--            <field name="value" eval="'ir.actions.act_window,' +str(ref('action_view_account_move_line_reconcile_prompt'))" />-->
-<!--            <field name="key">action</field>-->
-<!--            <field name="model">account.move.line</field>-->
-<!--        </record>-->
-
         <record id="view_account_move_line_reconcile_full" model="ir.ui.view">
             <field name="name">account.move.line.reconcile.full.form</field>
             <field name="model">account.move.line.reconcile</field>
             <field name="key">action</field>
             <field name="model">account.move.line</field>
         </record>
-<!--        <record id="view_account_move_line_reconcile_full" model="ir.ui.view">-->
-<!--            <field name="name">account.move.line.reconcile.full.form</field>-->
-<!--            <field name="model">account.move.line.reconcile</field>-->
-<!--            <field name="type">form</field>-->
-<!--            <field name="arch" type="xml">-->
-<!--                <form string="Reconciliation">-->
-<!--                    <separator string="Reconciliation transactions" colspan="4"/>-->
-<!--                    <field name="trans_nbr"/>-->
-<!--                    <newline/>-->
-<!--                    <field name="credit"/>-->
-<!--                    <field name="debit"/>-->
-<!--                    <separator string="Write-Off" colspan="4"/>-->
-<!--                    <field name="writeoff"/>-->
-<!--                    <group colspan="4" col="6">-->
-<!--                           <label string ="" colspan="2"/>-->
-<!--                        <button icon="gtk-cancel" special="cancel" string="Cancel"/>-->
-<!--                        <button icon="terp-stock_effects-object-colorize" string="Reconcile" name="trans_rec_reconcile_full" type="object" default_focus="1"/>-->
-<!--                   </group>-->
-<!--               </form>-->
-<!--            </field>-->
-<!--        </record>-->
-<!---->
-<!--        <record id="view_account_move_line_reconcile_partial" model="ir.ui.view">-->
-<!--            <field name="name">account.move.line.reconcile.partial.form</field>-->
-<!--            <field name="model">account.move.line.reconcile</field>-->
-<!--            <field name="type">form</field>-->
-<!--            <field name="arch" type="xml">-->
-<!--                <form string="Reconciliation">-->
-<!--                    <separator string="Reconciliation transactions" colspan="4"/>-->
-<!--                    <field name="trans_nbr"/>-->
-<!--                    <newline/>-->
-<!--                    <field name="credit"/>-->
-<!--                    <field name="debit"/>-->
-<!--                    <separator string="Write-Off" colspan="4"/>-->
-<!--                    <field name="writeoff"/>-->
-<!--                    <group colspan="4" col="6">-->
-<!--                           <label string ="" colspan="2"/>-->
-<!--                        <button icon="gtk-cancel" special="cancel" string="Cancel"/>-->
-<!--                        <button icon="gtk-ok" string="Reconcile With Write-Off" name="trans_rec_addendum_writeoff" type="object" default_focus="1"/>-->
-<!--                        <button icon="gtk-ok" string="Partial Reconcile" name="trans_rec_reconcile_partial_reconcile" type="object"/>-->
-<!--                   </group>-->
-<!--               </form>-->
-<!--            </field>-->
-<!--        </record>-->
 
         <record id="account_move_line_reconcile_writeoff" model="ir.ui.view">
             <field name="name">account.move.line.reconcile.writeoff.form</field>
index 6c97449..398fba0 100644 (file)
@@ -30,7 +30,7 @@ class account_balance_report(osv.osv_memory):
 
     _defaults = {
         'journal_ids': [],
-                }
+    }
 
     def fields_view_get(self, cr, uid, view_id=None, view_type='form', context=None, toolbar=False, submenu=False):
         mod_obj = self.pool.get('ir.model.data')
index e107b7a..36af271 100644 (file)
@@ -3,28 +3,28 @@
 <openerp>
     <data>
 
-         <record id="account_report_balance_view" model="ir.ui.view">
-                <field name="name">Account Balance</field>
-                <field name="model">account.balance.report</field>
-                <field name="type">form</field>
-                <field name="inherit_id" ref="account_common_report_view" />
-                <field name="arch" type="xml">
-                   <field name="fiscalyear_id" position="after">
-                       <field name="display_account"/>
-                       <newline/>
-                   </field>
-                </field>
+        <record id="account_report_balance_view" model="ir.ui.view">
+               <field name="name">Account Balance</field>
+               <field name="model">account.balance.report</field>
+               <field name="type">form</field>
+               <field name="inherit_id" ref="account_common_report_view" />
+               <field name="arch" type="xml">
+                   <field name="fiscalyear_id" position="after">
+                       <field name="display_account"/>
+                       <newline/>
+                   </field>
+               </field>
         </record>
 
         <record id="action_account_balance_menu" model="ir.actions.act_window">
-                <field name="name">Account Balance</field>
-                <field name="type">ir.actions.act_window</field>
-                <field name="res_model">account.balance.report</field>
-                <field name="view_type">form</field>
-                <field name="view_mode">form</field>
-                <field name="view_id" ref="account_report_balance_view"/>
-                <field name="target">new</field>
-            </record>
+            <field name="name">Account Balance</field>
+            <field name="type">ir.actions.act_window</field>
+            <field name="res_model">account.balance.report</field>
+            <field name="view_type">form</field>
+            <field name="view_mode">form</field>
+            <field name="view_id" ref="account_report_balance_view"/>
+            <field name="target">new</field>
+        </record>
 
         <menuitem
                 icon="STOCK_PRINT"
index b972aeb..29867f0 100644 (file)
@@ -37,12 +37,12 @@ class account_aged_trial_balance(osv.osv_memory):
         'direction_selection': fields.selection([('past','Past'),
                                                  ('future','Future')],
                                                  'Analysis Direction', required=True),
-                }
+    }
     _defaults = {
         'period_length': 30,
         'date_from' : time.strftime('%Y-%m-%d'),
         'direction_selection': 'past',
-                }
+    }
 
     def fields_view_get(self, cr, uid, view_id=None, view_type='form', context=None, toolbar=False, submenu=False):
         mod_obj = self.pool.get('ir.model.data')
index 91840b5..ebe3b4c 100644 (file)
@@ -36,12 +36,12 @@ class account_bs_report(osv.osv_memory):
         'display_type': fields.boolean("Landscape Mode"),
         'reserve_account_id': fields.many2one('account.account', 'Reserve & Surplus Account',required = True,
                                       help='This Account is used for trasfering Profit/Loss(If It is Profit : Amount will be added, Loss : Amount will be duducted.), Which is calculated from Profilt & Loss Report', domain = [('type','=','payable')]),
-        }
+    }
 
     _defaults={
         'display_type': True,
         'journal_ids': [],
-        }
+    }
 
     def fields_view_get(self, cr, uid, view_id=None, view_type='form', context=None, toolbar=False, submenu=False):
         mod_obj = self.pool.get('ir.model.data')
@@ -68,13 +68,13 @@ class account_bs_report(osv.osv_memory):
                 'type': 'ir.actions.report.xml',
                 'report_name': 'account.balancesheet.horizontal',
                 'datas': data,
-                    }
+            }
         else:
             return {
                 'type': 'ir.actions.report.xml',
                 'report_name': 'account.balancesheet',
                 'datas': data,
-                    }
+            }
 
 account_bs_report()
 
index 3a4bfab..1f337ca 100644 (file)
@@ -9,8 +9,6 @@
             <field name="inherit_id" ref="account.account_common_report_view" />
             <field name="arch" type="xml">
                <field name="fiscalyear_id" position="after">
-<!--                <field name="reserve_account_id"/>-->
-<!--                <newline/>-->
                     <field name="display_account"/>
                     <field name="display_type"/>
                     <newline/>
index c424f39..e762e6d 100644 (file)
@@ -31,7 +31,7 @@ class account_central_journal(osv.osv_memory):
                 'type': 'ir.actions.report.xml',
                 'report_name': 'account.central.journal',
                 'datas': data,
-                }
+        }
 
 account_central_journal()
 
index 91c550d..3e24510 100644 (file)
@@ -11,7 +11,6 @@
                 <field name="fiscalyear_id" position="after">
                     <field name="amount_currency"/>
                     <newline/>
-                    <!-- we don't change the view but have to define a view for this specific object otherelse openerp will try to build a fedault one without using the one from the parent object -->
                 </field>
             </field>
         </record>
index 2ec4a4c..4f84d8f 100644 (file)
@@ -30,10 +30,10 @@ class account_common_account_report(osv.osv_memory):
                                             ('bal_solde','With balance is not equal to 0'),
                                             ],'Display accounts', required=True),
 
-                }
+    }
     _defaults = {
         'display_account': 'bal_all',
-                }
+    }
 
     def pre_print_report(self, cr, uid, ids, data, query_line, context=None):
         if context is None:
index edc7776..44ee844 100644 (file)
@@ -27,7 +27,7 @@ class account_common_journal_report(osv.osv_memory):
     _inherit = "account.common.report"
     _columns = {
         'amount_currency': fields.boolean("With Currency", help="Print Report with the currency column if the currency is different then the company currency"),
-                }
+    }
 
     def _build_context(self, cr, uid, ids, data, context=None):
         if context is None:
index 60be556..fe71ccb 100644 (file)
@@ -30,10 +30,10 @@ class account_common_partner_report(osv.osv_memory):
                                               ('supplier','Payable Accounts'),
                                               ('customer_supplier' ,'Receivable and Payable Accounts')],
                                               "Partner's", required=True),
-                }
+    }
     _defaults = {
         'result_selection': 'customer',
-                }
+    }
 
     def pre_print_report(self, cr, uid, ids, data, query_line, context=None):
         if context is None:
index 0c6a24c..aa140c7 100644 (file)
@@ -43,7 +43,6 @@
 
         <record id="action_account_common_menu" model="ir.actions.act_window">
             <field name="name">Common Report</field>
-<!--            <field name="type">ir.actions.act_window</field>-->
             <field name="res_model">account.common.report</field>
             <field name="view_type">form</field>
             <field name="view_mode">form</field>
index b36f9ee..5bc3392 100644 (file)
@@ -9,9 +9,8 @@
             <field name="inherit_id" ref="account_common_report_view" />
             <field name="arch" type="xml">
                 <field name="fiscalyear_id" position="after">
-                <field name="amount_currency"/>
-                <newline/>
-                <!-- we don't change the view but have to define a view for this specific object otherelse openerp will try to build a fedault one without using the one from the parent object -->
+                       <field name="amount_currency"/>
+                       <newline/>
                 </field>
             </field>
         </record>
index b1a7560..9283d62 100644 (file)
@@ -35,12 +35,12 @@ class account_partner_ledger(osv.osv_memory):
         'reconcil': fields.boolean('Include Reconciled Entries', help='Consider reconciled entries'),
         'page_split': fields.boolean('One Partner Per Page', help='Display Ledger Report with One partner per page'),
         'amount_currency': fields.boolean("With Currency", help="It adds the currency column if the currency is different then the company currency"),
-                }
+    }
     _defaults = {
        'reconcil': True,
        'initial_balance': True,
        'page_split': False,
-               }
+    }
 
     def _print_report(self, cr, uid, ids, data, query_line, context=None):
         if context is None:
@@ -52,12 +52,12 @@ class account_partner_ledger(osv.osv_memory):
                 'type': 'ir.actions.report.xml',
                 'report_name': 'account.third_party_ledger',
                 'datas': data,
-                    }
+            }
         return {
                 'type': 'ir.actions.report.xml',
                 'report_name': 'account.third_party_ledger_other',
                 'datas': data,
-                }
+        }
 
 account_partner_ledger()
 
index ff6832d..e9c5b0f 100644 (file)
@@ -30,10 +30,10 @@ class account_print_journal(osv.osv_memory):
         'sort_selection': fields.selection([('date', 'Date'),
                                             ('ref', 'Reference Number'),],
                                             'Entries Sorted By', required=True),
-                }
+    }
     _defaults = {
         'sort_selection': 'date',
-                }
+    }
 
     def _print_report(self, cr, uid, ids, data, query_line, context=None):
         if context is None:
index 0ffd525..fd73571 100644 (file)
@@ -32,12 +32,12 @@ class account_pl_report(osv.osv_memory):
     _description = "Account Profit And Loss Report"
     _columns = {
         'display_type': fields.boolean("Landscape Mode"),
-                }
+    }
 
     _defaults = {
         'display_type': True,
         'journal_ids': [],
-                }
+    }
 
     def fields_view_get(self, cr, uid, view_id=None, view_type='form', context=None, toolbar=False, submenu=False):
         mod_obj = self.pool.get('ir.model.data')
@@ -60,13 +60,13 @@ class account_pl_report(osv.osv_memory):
                 'type': 'ir.actions.report.xml',
                 'report_name': 'pl.account.horizontal',
                 'datas': data,
-                    }
+            }
         else:
             return {
                 'type': 'ir.actions.report.xml',
                 'report_name': 'pl.account',
                 'datas': data,
-                    }
+            }
 
 account_pl_report()
 
index a409bb7..ab17a7f 100644 (file)
@@ -31,10 +31,10 @@ class account_statement_from_invoice_lines(osv.osv_memory):
     _description = "Entries by Statement from Invoices"
     _columns = {
         'line_ids': fields.many2many('account.move.line', 'account_move_line_relation', 'move_id', 'line_id', 'Invoices'),
-                }
+    }
 
     def populate_statement(self, cr, uid, ids, context=None):
-        
+
         statement_id = context.get('statement_id', False)
         if not statement_id:
             return {}
@@ -42,7 +42,7 @@ class account_statement_from_invoice_lines(osv.osv_memory):
         line_ids = data['line_ids']
         if not line_ids:
             return {}
-        
+
         line_obj = self.pool.get('account.move.line')
         statement_obj = self.pool.get('account.bank.statement')
         statement_line_obj = self.pool.get('account.bank.statement.line')
@@ -50,29 +50,26 @@ class account_statement_from_invoice_lines(osv.osv_memory):
         statement_reconcile_obj = self.pool.get('account.bank.statement.reconcile')
         line_date = time.strftime('%Y-%m-%d')
         statement = statement_obj.browse(cr, uid, statement_id, context=context)
-        
+
         # for each selected move lines
         for line in line_obj.browse(cr, uid, line_ids, context=context):
             ctx = context.copy()
             #  take the date for computation of currency => use payment date
-            # if line.date_maturity:
-            #     ctx['date'] = line.date_maturity
-            # else:
             ctx['date'] = line_date
             amount = 0.0
-            
+
             if line.debit > 0:
                 amount = line.debit
             elif line.credit > 0:
                 amount = -line.credit
-                
+
             if line.amount_currency:
                 amount = currency_obj.compute(cursor, user, line.currency_id.id,
                     statement.currency.id, line.amount_currency, context=ctx)
             elif (line.invoice and line.invoice.currency_id.id <> statement.currency.id):
                 amount = currency_obj.compute(cursor, user, line.invoice.currency_id.id,
                     statement.currency.id, amount, context=ctx)
-            
+
             reconcile_id = statement_reconcile_obj.create(cr, uid, {
                 'line_ids': [(6, 0, [line.id])]
                 }, context=context)
@@ -150,7 +147,6 @@ class account_statement_from_invoice(osv.osv_memory):
             args.append(('id','not in',repeated_move_line_ids))
 
         line_ids = line_obj.search(cr, uid, args,
-            #order='date DESC, id DESC', #doesn't work
             context=context)
         model_data_ids = mod_obj.search(cr,uid,[('model','=','ir.ui.view'),('name','=','view_account_statement_from_invoice_lines')], context=context)
         resource_id = mod_obj.read(cr, uid, model_data_ids, fields=['res_id'], context=context)[0]['res_id']
index 2d8d748..1980514 100644 (file)
@@ -26,8 +26,8 @@
             <field name="res_model">account.statement.from.invoice</field>
             <field name="view_type">form</field>
             <field name="view_mode">tree,form</field>
-               <field name="view_id" ref="view_account_statement_from_invoice"/>
-               <field name="target">new</field>
+            <field name="view_id" ref="view_account_statement_from_invoice"/>
+            <field name="target">new</field>
         </record>
 
         <record id="view_account_statement_from_invoice_lines" model="ir.ui.view">
@@ -41,7 +41,7 @@
                         <field height="300" width="700" name="line_ids" colspan="4" nolabel="1" domain="[('account_id.type','in',['receivable','payable']), ('reconcile_id','=',False), ('reconcile_partial_id','=',False)]"/>
                     </group>
                     <group colspan="4" col="6">
-                           <label string ="" colspan="2"/>
+                        <label string ="" colspan="2"/>
                         <button icon="gtk-cancel" special="cancel" string="Cancel"/>
                         <button icon="gtk-execute" string="Ok" name="populate_statement" type="object"/>
                    </group>
@@ -54,9 +54,9 @@
             <field name="res_model">account.statement.from.invoice.lines</field>
             <field name="view_type">form</field>
             <field name="view_mode">tree,form</field>
-               <field name="view_id" ref="view_account_statement_from_invoice_lines"/>
-               <field name="target">new</field>
-               <field name="context">{'statement_id': active_id}</field>
+            <field name="view_id" ref="view_account_statement_from_invoice_lines"/>
+            <field name="target">new</field>
+            <field name="context">{'statement_id': active_id}</field>
         </record>
     </data>
 </openerp>
index dccc4bb..fbc051b 100644 (file)
@@ -29,10 +29,10 @@ class account_subscription_generate(osv.osv_memory):
     _description = "Subscription Compute"
     _columns = {
        'date': fields.date('Date', required=True),
-              }
+    }
     _defaults = {
         'date': lambda *a: time.strftime('%Y-%m-%d'),
-                }
+    }
     def action_generate(self, cr, uid, ids, context={}):
         mod_obj = self.pool.get('ir.model.data')
         act_obj = self.pool.get('ir.actions.act_window')
index 04647dc..facb675 100644 (file)
@@ -30,7 +30,7 @@ class account_use_model(osv.osv_memory):
     _description = 'Use model'
     _columns = {
         'model': fields.many2many('account.model', 'account_use_model_relation', 'account_id', 'model_id', 'Account Model'),
-        }
+    }
 
     def create_entries(self, cr, uid, ids, context=None):
         account_model_obj = self.pool.get('account.model')
@@ -92,7 +92,7 @@ class account_use_model(osv.osv_memory):
             'views': [(resource_id,'form')],
             'type': 'ir.actions.act_window',
             'target': 'new',
-            }
+        }
 
     def open_moves(self, cr, uid, ids, context=None):
         mod_obj = self.pool.get('ir.model.data')
index 54efb58..fd3b13f 100644 (file)
@@ -42,9 +42,6 @@
             <field name="model">account.move.line</field>
         </record>
 
-<!--        <menuitem action="action_view_account_use_model"-->
-<!--                    parent="account.menu_finance_recurrent_entries" id="menu_account_use_model"/>-->
-
         <record id="view_account_use_model_open_entry" model="ir.ui.view">
             <field name="name">account.use.model.open.entry.form</field>
             <field name="model">account.use.model</field>
index e3d9e49..0fac738 100644 (file)
@@ -27,7 +27,7 @@ class validate_account_move(osv.osv_memory):
     _columns = {
        'journal_id': fields.many2one('account.journal', 'Journal', required=True),
        'period_id': fields.many2one('account.period', 'Period', required=True, domain=[('state','<>','done')]),
-              }
+    }
 
     def validate_move(self, cr, uid, ids, context=None):
         obj_move = self.pool.get('account.move')
index 1ee0e1c..bf577eb 100644 (file)
@@ -560,7 +560,6 @@ class account_analytic_account_summary_month(osv.osv):
     _description = "Hours summary by month"
     _auto = False
     _rec_name = 'month'
-#    _order = 'month'
 
     def _unit_amount(self, cr, uid, ids, name, arg, context=None):
         res = {}
index 5b32009..6c822b7 100644 (file)
@@ -63,7 +63,6 @@ Three reports are available:
     ],
     'demo_xml': ['crossovered_budget_demo.xml'],
     'test':[
-#            'test/account_budget_spread.yml',
             'test/account_budget.yml',
             ],
     'installable': True,
index e153200..ebfe70e 100644 (file)
@@ -1,9 +1,6 @@
 <?xml version="1.0"?>
 <openerp>
        <data>
-<!--           <wizard id="wizard_budget_spread" menu="False" model="account.budget.post" name="account.budget.spread" string="Spread amount"/>-->
-
-<!--           <wizard id="wizard_budget_report" keyword="client_print_multi" model="account.budget.post" name="account.budget.report" string="Budget"/>-->
 
        </data>
 </openerp>
index 7a968cc..a6735cd 100644 (file)
                                auto="False"
                                menu="False" />
 
-<!--           <wizard-->
-<!--                   string="Print Budgets"-->
-<!--                   model="crossovered.budget"-->
-<!--                   name="wizard.crossovered.budget"-->
-<!--                   id="wizard_crossovered_budget_menu"-->
-<!--                   keyword="client_print_multi" />-->
-
-<!--           <wizard-->
-<!--                   string="Print Summary of Budgets"-->
-<!--                   model="crossovered.budget"-->
-<!--                   name="wizard.crossovered.budget.summary"-->
-<!--                   id="wizard_crossovered_budget_menu_1"-->
-<!--                   keyword="client_print_multi" />-->
-
-       <!-- Reports on account.analytic.account -->
-<!--           <wizard-->
-<!--                   id="account_analytic_account_budget_report"-->
-<!--                   string="Print Budgets"-->
-<!--                   model="account.analytic.account"-->
-<!--                   name="wizard.analytic.account.budget.report"-->
-<!--                   keyword="client_print_multi"/>-->
-<!---->
-<!--           <report id="account_analytic_account_budget"-->
-<!--                   string="Print Budgets"-->
-<!--                   model="account.analytic.account"-->
-<!--                   name="account.analytic.account.budget"-->
-<!--                   rml="account_budget/report/analytic_account_budget_report.rml"-->
-<!--                   auto="False"-->
-<!--                   menu="False"/>-->
-
        <!-- moved from account module -->
                <report auto="False"
                        id="account_budget"
index 30ae450..99ad26d 100644 (file)
@@ -79,7 +79,6 @@
                             <field name="crossovered_budget_line" widget="one2many_list" colspan="4" nolabel="1" mode="graph,tree">
                                 <graph type="bar" string="Lines">
                                     <field name="analytic_account_id" groups="base.group_extended"/>
-                                    <!--<field name="general_budget_id" operator="+" />-->
                                     <field name="planned_amount" operator="+"/>
                                     <field group="True" name="general_budget_id"/>
                                 </graph>
                                 <button string="Approve" name="validate" states="confirm" type="workflow" icon="gtk-ok"/>
                                 <button string="Done" name="done" states="validate" type="workflow"   icon="gtk-jump-to" />
                                 <button string="Cancel" name="cancel" states="confirm,validate" type="workflow" icon="gtk-cancel"/>
-                                <!--<button string="Set to Draft" name="action_set_to_draft" states="cancel" type="object"/>-->
                             </group>
 
                 </form>
                                 </form>
                                 <graph type="bar" string="Lines">
                                     <field name="general_budget_id" />
-                                    <!--<field name="analytic_account_id" operator="+"/>-->
                                     <field name="planned_amount" operator="+"/>
                                     <field group="True" name="analytic_account_id"/>
                                 </graph>
                 </notebook>
             </field>
         </record>
-        <!-- moved from account module -->
-         <!--Budget -->
-        <!--<report
-             id="account_analytic_budget_print"
-            string="Print Budget"
-            model="account.analytic.budget.post"
-            name="account.analytic.budget.print"
-            rml="account/project/report/account_analytic_budget_report.rml"
-            auto="False"
-            menu="False"/>-->
 
     </data>
 </openerp>
index a14cfd2..0874d51 100644 (file)
                <field name="action">budget_validate()</field>
        </record>
 
-       <!--<record model="workflow.activity" id="act_set_to_draft">
-               <field name="wkf_id" ref="wkf_crossovered_budget" />
-               <field name="name">settodraft</field>
-               <field name="kind">function</field>
-               <field name="action">action_set_to_draft()</field>
-       </record>-->
-
        <record model="workflow.activity" id="act_cancel">
                <field name="wkf_id" ref="wkf_crossovered_budget" />
                <field name="name">cancel</field>
                <field name="role_id" ref="crossovered_budget_role"/>
        </record>
 
-       <!--<record model="workflow.transition" id="t7">
-               <field name="act_from" ref="act_cancel" />
-               <field name="act_to" ref="act_draft" />
-               <field name="signal">settodraft</field>
-               <field name="role_id" ref="crossovered_budget_role"/>
-       </record>-->
 </data>
 </openerp>
index 07e8bb2..300d833 100644 (file)
@@ -39,8 +39,6 @@ class analytic_account_budget_report(report_sxw.rml_parse):
 
         if not ids:
             ids = self.ids
-#        if not ids:
-#            return []
         if not done:
             done={}
 
@@ -68,7 +66,6 @@ class analytic_account_budget_report(report_sxw.rml_parse):
             d_from=form['date_from']
             d_to=form['date_to']
 
-#            bd_ids = ','.join([str(x) for x in budget_lines])
             self.cr.execute('select distinct(crossovered_budget_id) from crossovered_budget_lines where id =ANY(%s)',(b_line_ids,))
             budget_ids=self.cr.fetchall()
 
index 6622ce8..a5f26b1 100644 (file)
@@ -40,8 +40,6 @@ class budget_report(report_sxw.rml_parse):
 
         if not ids:
             ids = self.ids
-#       if not ids:
-#           return []
         if not done:
             done={}
 
@@ -71,7 +69,6 @@ class budget_report(report_sxw.rml_parse):
             if not budget_ids:
                 return []
 
-#            bd_ids = ','.join([str(x) for x in budget_lines])
             self.cr.execute('select distinct(analytic_account_id) from crossovered_budget_lines where id =ANY(%s)',(budget_ids,))
             an_ids=self.cr.fetchall()
 
index 33d72e8..9e8b532 100644 (file)
@@ -11,6 +11,6 @@
                     <field name="update_posted"/>
                 </field>
             </field>
-           </record>
+        </record>
     </data>
 </openerp>
index 4af8021..0f22362 100644 (file)
             </field>
         </record>
 
-<!--        <act_window context="{'search_default_reconcile_id':False}" domain="[('partner_id', '=', active_id),('reconcile_id','=',False),('account_id.reconcile', '=', True),('account_id.type', 'in', ['receivable', 'payable'])]" id="account.act_account_partner_account_move_unreconciled" name="Receivables &amp; Payables" res_model="account.move.line" view="account_move_line_partner_tree"/>-->
-
         <act_window
             domain="[('reconcile_id', '=', False),('account_id.type','=','receivable')]"
             id="act_account_partner_account_move_all"
index ab0d753..28c039e 100644 (file)
@@ -39,7 +39,7 @@ class account_followup_stat(osv.osv):
         'date_move_last':fields.date('Last move', readonly=True),
         'date_followup':fields.date('Latest followup', readonly=True),
         'followup_id': fields.many2one('account_followup.followup.line',
-            'Follow Ups', readonly=True, ondelete="cascade"),
+                                    'Follow Ups', readonly=True, ondelete="cascade"),
         'balance':fields.float('Balance', readonly=True),
         'debit':fields.float('Debit', readonly=True),
         'credit':fields.float('Credit', readonly=True),
index 99e1533..a37b13c 100644 (file)
@@ -98,22 +98,7 @@ class account_followup_print_all(osv.osv_memory):
          'partner_lang': True,
          'partner_ids': _get_partners,
          'summary': _get_summary,
-#         'email_body':'''
-#Date : %(date)s
-#
-#Dear %(partner_name)s,
-#
-#Please find in attachment a reminder of all your unpaid invoices, for a total amount due of:
-#
-#%(followup_amount).2f %(company_currency)s
-#
-#
-#Thanks,
-#--
-#%(user_signature)s
-#%(company_name)s
-#        '''
-                 }
+    }
 
     def _get_partners_followp(self, cr, uid, ids, context=None):
         data = {}
index a97e543..eb322b2 100644 (file)
@@ -65,7 +65,6 @@
                                 <field name="email_conf" colspan="4"/>
                                 <field name="partner_lang" colspan="4"/>
                                 <field name="email_subject" colspan="4"/>
-                                <!--<separator string="Email body" colspan="4" attrs="{'readonly':[('partner_lang','=',True)]}"/>-->
                                 <separator string="Email body" colspan="4" />
                                 <field name="email_body" colspan="4" nolabel="1"/>
                                 <separator string="Legend" colspan="4"/>
index e596dd0..adb80d7 100644 (file)
@@ -170,7 +170,6 @@ class account_invoice_line(osv.osv):
     _defaults = {
         'state': 'article',
         'sequence': 0,
-#       'account_id': _default_account
     }
 
 account_invoice_line()
@@ -190,13 +189,6 @@ class one2many_mod2(fields.one2many):
             res[r[self._fields_id]].append( r['id'] )
         return res
 
-#   def copy(self, cr, uid, id, default=None, context=None):
-#       if default is None:
-#           default = {}
-#       default['line_ids'] = False
-#       return super(account_invoice, self).copy(cr, uid, id, default, context)
-
-
 class account_invoice(osv.osv):
 
     def copy(self, cr, uid, id, default=None, context=None):
index ca58318..3f9b6c4 100644 (file)
@@ -97,7 +97,6 @@ class account_move_line(osv.osv):
                 line2bank[line.id] = line.invoice.partner_bank_id.id
             elif line.partner_id:
                 if not line.partner_id.bank_ids:
-                    #raise osv.except_osv(_('Error !'), _('Partner '+ line.partner_id.name+ ' has no bank account defined'))
                     line2bank[line.id] = False
                 else:
                     for bank in line.partner_id.bank_ids:
index 3b99a26..5be2574 100644 (file)
@@ -47,8 +47,6 @@ class account_payment_make_payment(osv.osv_memory):
         result = obj_model._get_id(cr, uid, module, wizard)
         id = obj_model.read(cr, uid, [result], ['res_id'])[0]['res_id']
         return obj_act.read(cr, uid, [id])[0]
-        #result['context'] = str({'fiscalyear': data['form']['fiscalyear']})
-
 
 account_payment_make_payment()
 
index 784d95d..5dffc0c 100644 (file)
@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 ##############################################################################
-#    
+#
 #    OpenERP, Open Source Management Solution
 #    Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
 #
@@ -15,7 +15,7 @@
 #    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/>.     
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #
 ##############################################################################
 
@@ -33,25 +33,6 @@ from mx.DateTime import RelativeDateTime, now, DateTime, localtime
 class account_report(osv.osv):
     _name = "account.report.report"
     _description = "Account Reporting"
-#    _color = [
-#            ('', ''),
-#            ('green','Green'),
-#            ('red','Red'),
-#            ('pink','Pink'),
-#            ('blue','Blue'),
-#            ('yellow','Yellow'),
-#            ('cyan','Cyan'),
-#            ('lightblue','Light Blue'),
-#            ('orange','Orange'),
-#            ]
-#    _style = [
-#            ('1','Header 1'),
-#            ('2','Header 2'),
-#            ('3','Header 3'),
-#            ('4','Header 4'),
-#            ('5','Normal'),
-#            ('6', 'Small'),
-#            ]
 
     def _amount_get(self, cr, uid, ids, field_name, arg, context={}):
         obj_fy=self.pool.get('account.fiscalyear')
@@ -118,10 +99,6 @@ class account_report(osv.osv):
                 'report': _calc_report,
                 'tax_code': _calc_tax_code,
             }
-#            if field_name=='status':
-#                fld_name = 'expression_status'
-#            else:
-#                fld_name = 'expression'
             try:
                 val = eval(getattr(rep,'expression'), objdict)
             except:
@@ -147,8 +124,6 @@ class account_report(osv.osv):
         if parent_id:
             acc=self.pool.get('account.report.report').browse(cr, uid, parent_id)
             v['type']=acc.type
-#            if int(acc.style) < 6:
-#                v['style'] = str(int(acc.style)+1)
         return {'value': v}
 
     _columns = {
@@ -182,12 +157,8 @@ class account_report(osv.osv):
             string='Status'),
          'disp_tree':fields.boolean('Display Tree', help='When the indicators are printed, if one indicator is set with this field to True, then it will display one more graphs with all its children in tree'),
          'disp_graph':fields.boolean('Display As Graph', help='If the field is set to True, information will be printed as a Graph, otherwise as an array.'),
-#        'style': fields.selection(_style, 'Style', required=True),
-#        'color_font' : fields.selection(_color, 'Font Color', help="Font Color for the report"),
-#        'color_back' : fields.selection(_color, 'Back Color')
     }
     _defaults = {
-#        'style': lambda *args: '5',
         'active': lambda *args: True,
         'type': lambda *args: 'indicator',
     }
@@ -207,7 +178,7 @@ class account_report(osv.osv):
         return self.name_get(cr, user, ids, context=context)
 
     _constraints = [
-    #TODO Put an expression to valid expression 
+    #TODO Put an expression to valid expression
     ]
 
 account_report()
index 4b25851..e61ae8b 100644 (file)
@@ -17,7 +17,6 @@
                             <field name="sequence"/>
                             <field name="type" select="1"/>
                             <newline/>
-                           <!-- <field name="style"/>
                             <field name="color_font"/>
                             <field name="color_back"/>-->
                             <field name="badness_limit"/>
@@ -25,7 +24,6 @@
                             <field colspan="4" name="expression"/>
                             <field name="disp_tree"/>
                             <field name="disp_graph"/>
-                           <!-- <field colspan="4" name="expression_status"/>-->
                             <separator colspan="4" string="Legend of operators"/>
                             <label align="1.0" string="Account Debit:"/>
                             <label align="0.0" string="debit(['ACCOUNT_CODE',],fiscalyear)"/>
@@ -50,8 +48,6 @@
                                 <label align="1.0" string="= Badness Indicator Limit:"/>
                                 <label align="0.0" string="Bad"/>
                                 <newline/>
-                                <!--<label align="1.0" string="0:"/>
-                                <label align="0.0" string="Normal"/>-->
                                 <label align="1.0" string="= Goodness Indicator Limit:"/>
                                 <label align="0.0" string="Good"/>
                                 <newline/>
index 1e07a8f..c731b89 100644 (file)
@@ -1,10 +1,5 @@
 <?xml version="1.0" encoding="utf-8"?>
 <openerp>
     <data>
-<!--        <wizard id="wizard_print_indicators" name="print.indicators" string="Print Indicators"/>-->
-<!--        <menuitem action="wizard_print_indicators" type="wizard" parent="account_report.menu_action_account_report_tree_view" id="menu_wizard_print_indicators"/>-->
-
-<!--        <wizard id="wizard_indicators_with_pdf" model="account.report.report" name="print.indicators.pdf" string="Indicators in PDF" keyword="client_action_multi" />-->
-        <!--<menuitem action="wizard_indicators_with_pdf" type="wizard" parent="account_report.menu_action_account_report_tree_view" id="menu_wizard_print_indicators_with_pdf"/>-->
     </data>
 </openerp>
\ No newline at end of file
index 1bb6e7b..f38f09d 100644 (file)
@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 ##############################################################################
-#    
+#
 #    OpenERP, Open Source Management Solution
 #    Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
 #
@@ -15,7 +15,7 @@
 #    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/>.     
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #
 ##############################################################################
 
@@ -42,8 +42,6 @@ class accounting_report(report_sxw.rml_parse):
             'amount':res[0]['amount'],
             'note':res[0]['note'],
             'level': level,
-#            'color_font':res[0]['color_font'],
-#            'color_back':res[0]['color_back'],
         }
 
         self.ret_list.append(ret_dict)
index 4245bf4..5559676 100644 (file)
@@ -23,15 +23,6 @@ import pooler
 import time
 from report import report_sxw
 
-#from report.interface import report_int
-#from reportlab.graphics.shapes import Drawing
-#from reportlab.graphics.charts.barcharts import VerticalBarChart
-#import reportlab.lib.colors as colors
-#from reportlab.graphics.widgetbase import Widget, TypedPropertyCollection
-#from reportlab.graphics.charts.textlabels import BarChartLabel
-#from reportlab.graphics import renderPM
-#from report.render import render
-#from report.interface import report_int
 from pychart import *
 import StringIO
 theme.use_color = 1
@@ -70,14 +61,6 @@ class accounting_report_indicator(report_sxw.rml_parse):
         ind_ids=self.pool.get('account.report.report').search(self.cr,self.uid,[])
         obj_inds=self.pool.get('account.report.report').browse(self.cr,self.uid,ind_ids)
 
-#        def find_child(obj):
-#            self.list.append(obj)
-#            if obj.child_ids:
-#                for child in obj.child_ids:
-#                    find_child(child)
-#            return True
-#
-#        find_child(obj_inds)
 
         for obj_ind in obj_inds:
             level = 0
@@ -245,39 +228,6 @@ class accounting_report_indicator(report_sxw.rml_parse):
         if intercall:
             return True
         self.count +=1
-#        drawing = Drawing(400, 300)
-#        data = [
-#                 tuple(data_val),
-#                 ]
-#        value_min=0.0
-#        vmin=min(data_val)
-#        vmax=max(data_val)
-#
-#        val_min=((vmin < 0.00 and vmin-2.00)  or 0.00)
-#        # calculating maximum
-#        val_max=(vmax/(pow(10,len(str(int(vmax)))-2))+1)*pow(10,len(str(int(vmax)))-2)
-#        bc = VerticalBarChart()
-#        bc.x = 50
-#        bc.y = 50
-#        bc.height = 245
-#        bc.width = 300
-#        bc.data = data
-#        value_step=(abs(val_max)-abs(val_min))/5
-#
-#        bc.strokeColor = colors.black
-#        bc.valueAxis.valueMin = val_min
-#        bc.valueAxis.valueMax = val_max
-#        bc.valueAxis.valueStep = value_step
-#
-#        bc.categoryAxis.labels.boxAnchor = 'ne'
-#        bc.categoryAxis.labels.dx = 8
-#
-#        bc.categoryAxis.labels.dy = -2
-#        bc.categoryAxis.labels.angle = 30
-#        bc.categoryAxis.categoryNames = data_period
-#        drawing.add(bc)
-#        drawing.save(formats=['png'],fnRoot=path+str(self.count),title="helo")
-#        renderPM.drawToFile(drawing1, 'example1.jpg','jpg')
         import os
         path=tools.config['addons_path']+"/account_report/tmp_images/image"
 
@@ -286,7 +236,6 @@ class accounting_report_indicator(report_sxw.rml_parse):
             os.mkdir(dirname)
 
         can = canvas.init('image'+str(self.count)+".png")
-#        can.clip(0,0,600,400)
 
         data=zip(self.header_name,self.header_val)
 
@@ -300,7 +249,6 @@ class accounting_report_indicator(report_sxw.rml_parse):
         can.close()
         os.system('cp '+'image'+str(self.count)+'.png ' +path+str(self.count)+'.png')
         os.system('rm '+'image'+str(self.count)+'.png')
-#        can.endclip()
         return path+str(self.count)+'.png'
 
 report_sxw.report_sxw('report.print.indicators', 'account.report.history',
index c8b3273..c1c68f0 100644 (file)
@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 ##############################################################################
-#    
+#
 #    OpenERP, Open Source Management Solution
 #    Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
 #
@@ -15,7 +15,7 @@
 #    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/>.     
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #
 ##############################################################################
 import time
@@ -88,7 +88,6 @@ class account_report_bs(osv.osv):
         'code': fields.char('Code', size=64, required=True),
         'account_id': fields.many2many('account.account', 'account_report_rel', 'report_id', 'account_id', 'Accounts'),
         'note': fields.text('Note'),
-#       'style': fields.selection(_style, 'Style'),
         'color_font' : fields.many2one('color.rml','Font Color'),
         'color_back' : fields.many2one('color.rml','Back Color'),
         'font_style' : fields.selection(_font, 'Font'),
index 7603aaf..ebfe70e 100644 (file)
@@ -1,18 +1,6 @@
 <?xml version="1.0"?>
 <openerp>
        <data>
-<!--           <report id="balancesheet_report"
-                       string="BalanceSheet Report"
-                       model="account.report.bs"
-                       name="account.report.bs"
-                       rml="addons/account_report_bs/report/account_report_bs.rml"
-                       auto="False"/>-->
-<!--           <wizard-->
-<!--                   string="Account balance"-->
-<!--                   model="account.report.bs"-->
-<!--                   name="account.account.balancesheet.report"-->
-<!--                   keyword="client_print_multi"-->
-<!--                   id="wizard_balance_report"/>-->
 
        </data>
 </openerp>
index 89ad84d..2262822 100644 (file)
@@ -24,7 +24,6 @@ import pooler
 import locale
 from report import report_sxw
 
-#from addons.account.wizard import wizard_account_balance_report
 
 parents = {
     'tr':1,
@@ -124,8 +123,6 @@ class account_report_bs(report_sxw.rml_parse):
                                 res1['level'] = r['level'] + 1
                                 break
                     result.append(res1)
-                    #res1 = self.check_child_id(account_id,level,ctx,report_type)
-                    #result += res1
             if report_obj.child_id:
                 ids2 = [(x.code,x.id) for x in report_obj.child_id]
                 ids2.sort()
@@ -133,33 +130,6 @@ class account_report_bs(report_sxw.rml_parse):
 
         return result
 
-#    def check_child_id(self,account_id,level,ctx,report_type):
-#        account = self.pool.get('account.account').browse(self.cr,self.uid,[account_id],ctx)[0]
-#        result = []
-#        res = {
-#            'code': account.code,
-#            'name': account.name,
-#            'level': level+1,
-#            'balance': account.balance,
-#            'color_font' : 'black',
-#            'color_back' :'white',
-#            'font_style' : 'Helvetica',
-#            }
-#        result.append(res)
-#        if report_type != 'with_account':
-#            acc_child_id  = self.pool.get('account.account').search(self.cr,self.uid,[('parent_id','=',[account_id]),('type','=','view')])
-#            for child_id in acc_child_id :
-#                result += self.check_child_id(child_id,level+1,ctx,report_type)
-#        return result
-#
-#
-#
-#    def _sum_credit(self):
-#       return self.sum_credit
-#
-#    def _sum_debit(self):
-#       return self.sum_debit
-
 report_sxw.report_sxw('report.account.report.bs', 'account.report.bs', 'addons/account_reporting/report/account_report_bs.rml', parser=account_report_bs)
 
 # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
index 20adc9b..afd1ef3 100644 (file)
@@ -161,8 +161,6 @@ class account_invoice_line(osv.osv):
         # note: will call product_id_change_unit_price_inv with context...
 
         # Temporary trap, for bad context that came from koo:
-        # if isinstance(context, str):
-        #       print "str context:", context
 
         ctx = (context and context.copy()) or {}
         ctx.update({'price_type': ctx.get('price_type', 'tax_excluded')})
index 1524f97..a3f3bb0 100644 (file)
@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 ##############################################################################
-#    
+#
 #    OpenERP, Open Source Management Solution
 #    Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
 #
@@ -15,7 +15,7 @@
 #    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/>.     
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #
 ##############################################################################
 
@@ -37,19 +37,19 @@ class report_voucher(report_sxw.rml_parse):
     def convert(self, amount, cur):
         amt_en = amount_to_text_en.amount_to_text(amount, 'en', cur);
         return amt_en
-    
+
     def debit(self, move_ids):
         debit = 0.0
-        for move in move_ids:#self.pool.get('account.move.line').browse(self.cr, self.uid, move_ids):
+        for move in move_ids:
             debit +=move.debit
         return debit
-    
+
     def credit(self, move_ids):
         credit = 0.0
-        for move in move_ids:#self.pool.get('account.move.line').browse(self.cr, self.uid, move_ids):
+        for move in move_ids:
             credit +=move.credit
         return credit
-    
+
     def _get_ref(self, voucher_id, move_ids):
         voucher_line = self.pool.get('account.voucher.line').search(self.cr, self.uid, [('partner_id','=',move_ids.partner_id.id), ('voucher_id','=',voucher_id)])
         if voucher_line:
index 721c87f..e23d8c5 100644 (file)
@@ -107,7 +107,6 @@ class rml_parse(report_sxw.rml_parse):
         return Stringer
 
     def explode_this(self,chaine,length):
-        #chaine = self.repair_string(chaine)
         chaine = rstrip(chaine)
         ast = list(chaine)
         i = length
index f8bc28f..eb093a0 100644 (file)
                     </notebook>
                     <group col="10" colspan="4">
                         <field name="state"/>
-<!--                        <button name="open_voucher" states="draft" string="Compute" type="object" icon="terp-stock_format-scientific"/>-->
                         <button name="proforma_voucher" string="Create" states="draft" icon="terp-document-new"/>
                         <button name="recheck_voucher" string="Approve" states="recheck" icon="terp-check"/>
-<!--                        <button name="audit_complete" string="Audit Pass" states="posted" icon="terp-check"/>-->
                         <button name="cancel_voucher" string="Cancel" states="draft,proforma,recheck"  icon="gtk-cancel"/>
                         <button name="action_cancel_draft" type="object" states="cancel" string="Set to Draft" icon="terp-stock_effects-object-colorize"/>
                     </group>
             </field>
          </record>
         
-        <!--  Receipt Vouchers -->
-<!--        <record model="ir.actions.act_window" id="action_receipt_vou_voucher_list">-->
-<!--            <field name="name">Sales Receipt</field>-->
-<!--            <field name="res_model">account.voucher</field>-->
-<!--            <field name="view_type">form</field>-->
-<!--            <field name="view_mode">tree,form,graph</field>-->
-<!--            <field name="view_id" eval="view_voucher_tree"/>-->
-<!--            <field name="domain">[('journal_id.type','=','sale')]</field>-->
-<!--            <field name="context">{'type':'sale'}</field>-->
-<!--            <field name="search_view_id" ref="view_voucher_filter_new"/>-->
-<!--        </record>-->
-<!--        <menuitem id="menu_action_receipt_vou_voucher_list"-->
-<!--        action="action_receipt_vou_voucher_list" parent="account.menu_finance_receivables" sequence="12"/>-->
-<!--        -->
-        <!--  Sale Receipt Vouchers -->
-<!--        <record model="ir.actions.act_window" id="action_receipt_vou_voucher_list_pay_now">-->
-<!--            <field name="name">Sales Receipt Payment</field>-->
-<!--            <field name="res_model">account.voucher</field>-->
-<!--            <field name="view_type">form</field>-->
-<!--            <field name="view_mode">tree,form,graph</field>-->
-<!--            <field name="view_id" eval="view_voucher_tree"/>-->
-<!--            <field name="domain">[('journal_id.type','=','sale')]</field>-->
-<!--            <field name="context">{'type':'sale', 'pay_new':True}</field>-->
-<!--            <field name="search_view_id" ref="view_voucher_filter_new"/>-->
-<!--        </record>-->
-<!--        <menuitem id="menu_action_receipt_vou_voucher_list_pay_now"-->
-<!--        action="action_receipt_vou_voucher_list_pay_now" parent="account.menu_finance_receivables" sequence="12"/>-->
-
-        <!--  Purchase Vouchers -->
-<!--        <record model="ir.actions.act_window" id="action_pay_vou_voucher_list">-->
-<!--            <field name="name">Vendor Bills</field>-->
-<!--            <field name="res_model">account.voucher</field>-->
-<!--            <field name="view_type">form</field>-->
-<!--            <field name="view_mode">tree,form,graph</field>-->
-<!--            <field name="view_id" eval="view_voucher_tree"/>-->
-<!--            <field name="domain">[('journal_id.type','=','purchase')]</field>-->
-<!--            <field name="context">{'type':'purchase'}</field>-->
-<!--            <field name="search_view_id" ref="view_voucher_filter_new"/>-->
-<!--        </record>-->
-<!--        <menuitem id="menu_action_pay_vou_voucher_list"-->
-<!--        action="action_pay_vou_voucher_list" parent="account.menu_finance_payables" sequence="12"/>-->
-
         <!-- Journal Vouchers -->
         <record model="ir.actions.act_window" id="action_voucher_list">
             <field name="name">Journal Vouchers</field>
         </record>
         <menuitem action="action_voucher_list" id="menu_encode_entries_by_voucher" parent="account.menu_finance_entries" sequence="6"/>
 
-<!--        <record id="action_cheque_register" model="ir.actions.act_window">-->
-<!--            <field name="name">Sales Payments</field>-->
-<!--            <field name="type">ir.actions.act_window</field>-->
-<!--            <field name="res_model">account.voucher</field>-->
-<!--            <field name="view_type">form</field>-->
-<!--            <field name="view_mode">tree,form</field>-->
-<!--            <field name="domain">[('journal_id.type', 'in', ['bank', 'cash']), ('type','=','receipt')]</field>-->
-<!--            <field name="context">{'type':'bank'}</field>-->
-<!--            <field name="view_id" ref="view_voucher_tree"/>-->
-<!--            <field name="search_view_id" ref="view_voucher_filter_new"/>-->
-<!--        </record>-->
-<!--        <menuitem action="action_cheque_register" -->
-<!--            id="menu_action_cheque_register" -->
-<!--            parent="account.menu_finance_receivables"/>-->
-        
-<!--        <record id="action_cheque_pay" model="ir.actions.act_window">-->
-<!--            <field name="name">Vendor Payment</field>-->
-<!--            <field name="type">ir.actions.act_window</field>-->
-<!--            <field name="res_model">account.voucher</field>-->
-<!--            <field name="view_type">form</field>-->
-<!--            <field name="view_mode">tree,form</field>-->
-<!--            <field name="domain">[('journal_id.type', 'in', ['bank', 'cash']), ('type','=','payment')]</field>-->
-<!--            <field name="context">{'type':'bank'}</field>-->
-<!--            <field name="view_id" ref="view_voucher_tree"/>-->
-<!--            <field name="search_view_id" ref="view_voucher_filter_new"/>-->
-<!--        </record>-->
-<!--        <menuitem action="action_cheque_pay" -->
-<!--            id="menu_action_cheque_pay" -->
-<!--            parent="account.menu_finance_payables"/>-->
-        
-<!--        <record id="action_cheque_pay_voucher" model="ir.actions.act_window">-->
-<!--            <field name="name">Cheques</field>-->
-<!--            <field name="type">ir.actions.act_window</field>-->
-<!--            <field name="res_model">account.voucher</field>-->
-<!--            <field name="view_type">form</field>-->
-<!--            <field name="view_mode">tree,form</field>-->
-<!--            <field name="domain">[('journal_id.type', 'in', ['bank']), ('type','=','payment')]</field>-->
-<!--            <field name="context">{'type':'bank'}</field>-->
-<!--            <field name="view_id" ref="view_voucher_tree"/>-->
-<!--            <field name="search_view_id" ref="view_voucher_filter_new"/>-->
-<!--        </record>-->
-<!--        <menuitem action="action_cheque_pay_voucher" -->
-<!--            id="menu_action_cheque_pay_voucher" -->
-<!--            parent="account.menu_finance_bank_and_cash"/>-->
-        
         <record model="ir.ui.view" id="view_account_journal_form_inherit">
             <field name="name">account.journal.form.inherit</field>
             <field name="model">account.journal</field>
             <field name="search_view_id" ref="view_voucher_filter_new"/>
         </record>
 
-<!--        <menuitem -->
-<!--            id="menu_action_review_voucher_list"-->
-<!--            action="action_review_voucher_list" -->
-<!--            parent="account.periodical_processing_journal_entries_validation" sequence="2"/>-->
-<!--        -->
-        </data>
+    </data>
 </openerp>
index b8851b5..86c8221 100644 (file)
@@ -1,18 +1,5 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <openerp>
     <data>
-<!--        <wizard-->
-<!--             id="wizard_account_voucher_open"-->
-<!--             model="account.voucher"-->
-<!--             name="account.voucher.open"-->
-<!--             menu="False"-->
-<!--             string="Open a Voucher Entry"/>-->
-<!--        <menuitem-->
-<!--             action="wizard_account_voucher_open"-->
-<!--             id="menu_wizard_account_voucher_open"-->
-<!--             name="Open Vouchers"-->
-<!--             sequence="0"-->
-<!--             type="wizard"-->
-<!--             parent="menu_action_voucher_list"/>-->
     </data>
 </openerp>
index 3f8dd9c..d88a294 100644 (file)
@@ -1,7 +1,7 @@
 <?xml version="1.0" encoding="utf-8"?>
 <openerp>
     <data>
-    
+
         <record id="view_account_voucher_unreconcile" model="ir.ui.view">
             <field name="name">Account voucher unreconcile</field>
             <field name="model">account.voucher.unreconcile</field>
             <field name="view_id" ref="view_account_voucher_unreconcile"/>
             <field name="target">new</field>
         </record>
-        
-<!--    <act_window name="Unreconcile entries"            -->
-<!--            res_model="account.voucher.unreconcile"-->
-<!--            src_model="account.voucher"-->
-<!--            view_mode="form"-->
-<!--            target="new"        -->
-<!--            key2="client_action_multi"    -->
-<!--            id="action_view_account_voucher_unreconcile"/>-->
-     
+
      </data>
 </openerp>
index 3288ca9..39be4c7 100644 (file)
@@ -35,7 +35,6 @@
             <field name="inherit_id" ref="hr_timesheet_invoice.account_analytic_account_form_form"/>
             <field name="arch" type="xml">
                 <xpath expr="//field[@name='to_invoice']" position="after">
-                    <!--<field name="to_invoice" string="Default Invoicing Percentage"/>-->
                     <field name="journal_rate_ids" colspan="4"/>
                 </xpath>
             </field>
index 2f5152f..0bb9afc 100644 (file)
@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 ##############################################################################
-#    
+#
 #    OpenERP, Open Source Management Solution
 #    Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
 #
@@ -15,7 +15,7 @@
 #    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/>.     
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #
 ##############################################################################
 
@@ -54,7 +54,7 @@ class hr_analytic_timesheet(osv.osv):
     # Look in account, if no value for the user => look in parent until there is no more parent to look
     # Take the first found... if nothing found => return False
     def _get_related_user_account_recursiv(self, cr, uid, user_id, account_id):
-        
+
         temp=self.pool.get('analytic_user_funct_grid').search(cr, uid, [('user_id', '=', user_id),('account_id', '=', account_id) ])
         account=self.pool.get('account.analytic.account').browse(cr, uid, account_id)
         if temp:
@@ -64,21 +64,19 @@ class hr_analytic_timesheet(osv.osv):
                 return self._get_related_user_account_recursiv(cr, uid, user_id, account.parent_id.id)
             else:
                 return False
-                
-                
+
+
     def on_change_account_id(self, cr, uid, ids, account_id, user_id=False, unit_amount=0):
-        #{'value': {'to_invoice': False, 'amount': (-162.0,), 'product_id': 7, 'general_account_id': (5,)}}
         res = {}
         if not (account_id):
             #avoid a useless call to super
-            return res 
+            return res
 
         if not (user_id):
             return super(hr_analytic_timesheet, self).on_change_account_id(cr, uid, ids, account_id)
 
         #get the browse record related to user_id and account_id
         temp = self._get_related_user_account_recursiv(cr, uid, user_id, account_id)
-        # temp = self.pool.get('analytic_user_funct_grid').search(cr, uid, [('user_id', '=', user_id),('account_id', '=', account_id) ])
         if not temp:
             #if there isn't any record for this user_id and account_id
             return super(hr_analytic_timesheet, self).on_change_account_id(cr, uid, ids, account_id)
@@ -100,9 +98,9 @@ class hr_analytic_timesheet(osv.osv):
                                 'for this product: "%s" (id:%d)') % \
                                 (r.product_id.name, r.product_id.id,))
             # Compute based on pricetype
-            amount_unit = self.on_change_unit_amount(cr, uid, ids, 
+            amount_unit = self.on_change_unit_amount(cr, uid, ids,
                 r.product_id.id, unit_amount, r.product_id.uom_id.id)['value']['amount']
-                
+
             amount = unit_amount *  amount_unit
             res ['value']['amount']= - round(amount, 2)
             res ['value']['general_account_id']= a
@@ -112,19 +110,18 @@ class hr_analytic_timesheet(osv.osv):
         res = {}
         if not (user_id):
             #avoid a useless call to super
-            return res 
+            return res
 
         #get the old values from super
         res = super(hr_analytic_timesheet, self).on_change_user_id(cr, uid, ids, user_id)
 
         if account_id:
             #get the browse record related to user_id and account_id
-            # temp = self.pool.get('analytic_user_funct_grid').search(cr, uid, [('user_id', '=', user_id),('account_id', '=', account_id) ])
             temp = self._get_related_user_account_recursiv(cr, uid, user_id, account_id)
             if temp:
                 #add the value from the new relation analytic_user_funct_grid
                 r = self.pool.get('analytic_user_funct_grid').browse(cr, uid, temp)[0]
-                res['value']['product_id'] = r.product_id.id    
+                res['value']['product_id'] = r.product_id.id
 
                 #the change of product has to impact the amount, uom and general_account_id
                 a = r.product_id.product_tmpl_id.property_account_expense.id
@@ -136,9 +133,9 @@ class hr_analytic_timesheet(osv.osv):
                                     'for this product: "%s" (id:%d)') % \
                                     (r.product_id.name, r.product_id.id,))
                 # Compute based on pricetype
-                amount_unit = self.on_change_unit_amount(cr, uid, ids, 
+                amount_unit = self.on_change_unit_amount(cr, uid, ids,
                     r.product_id.id, unit_amount, r.product_id.uom_id.id)['value']['amount']
-                        
+
                 amount = unit_amount * amount_unit
                 res ['value']['amount']= - round(amount, 2)
                 res ['value']['general_account_id']= a
index 75b5011..69fef07 100644 (file)
     'init_xml': ['auction_sequence.xml', 'auction_data.xml'],
     'update_xml': [
         'security/ir.model.access.csv',
-       # 'wizard/auction_lots_able_view.xml',
-      #  'wizard/auction_lots_enable_view.xml',
         'wizard/auction_lots_make_invoice_buyer_view.xml',
         'wizard/auction_lots_make_invoice_view.xml',
         'wizard/auction_taken_view.xml',
         'wizard/auction_lots_auction_move_view.xml',
         'wizard/auction_pay_buy_view.xml',
-        #'wizard/auction_payer_sel_view.xml',
         'wizard/auction_lots_sms_send_view.xml',
         'wizard/auction_catalog_flagey_view.xml',
         'wizard/auction_lots_buyer_map_view.xml',
         'report/report_auction_view.xml',
         'auction_wizard.xml',
         'board_auction_view.xml',
-       # 'board_auction_manager_view.xml',
 
     ],
     'demo_xml': ['auction_demo.xml','board_auction_demo.xml'],
     'test': ['test/auction.yml'],
-             
+
     'installable': True,
     'active': False,
     'certificate': '0039333102717',
index 0014eda..5ea2441 100644 (file)
@@ -35,10 +35,10 @@ import tools
 class auction_artists(osv.osv):
     _name = "auction.artists"
     _columns = {
-        'name': fields.char('Artist/Author Name', size=64, required=True), 
-        'pseudo': fields.char('Pseudo', size=64), 
-        'birth_death_dates':fields.char('Birth / Death dates', size=64), 
-        'biography': fields.text('Biography'), 
+        'name': fields.char('Artist/Author Name', size=64, required=True),
+        'pseudo': fields.char('Pseudo', size=64),
+        'birth_death_dates':fields.char('Birth / Death dates', size=64),
+        'biography': fields.text('Biography'),
     }
 auction_artists()
 
@@ -49,10 +49,10 @@ class auction_dates(osv.osv):
     """Auction Dates"""
     _name = "auction.dates"
     _description=__doc__
-    
+
     def _adjudication_get(self, cr, uid, ids, prop, unknow_none, unknow_dict):
         res={}
-        total = 0.0        
+        total = 0.0
         lots_obj = self.pool.get('auction.lots')
         for auction in self.browse(cr, uid, ids):
             lots_ids = lots_obj.search(cr, uid, [('auction_id', '=', auction.id)])
@@ -71,27 +71,27 @@ class auction_dates(osv.osv):
         return name
 
     _columns = {
-        'name': fields.char('Auction Name', size=64, required=True), 
-        'expo1': fields.date('First Exposition Day', required=True, help="Beginning Exposition Date For Auction"), 
-        'expo2': fields.date('Last Exposition Day', required=True, help="Last Exposition Date For Auction"), 
-        'auction1': fields.date('First Auction Day', required=True, help="Start Date Of Auction"), 
-        'auction2': fields.date('Last Auction Day', required=True, help="End Date Of Auction"), 
-        'journal_id': fields.many2one('account.journal', 'Buyer Journal', required=True, help="Account Journal For Buyer"), 
-        'journal_seller_id': fields.many2one('account.journal', 'Seller Journal', required=True, help="Account Journal For Seller"), 
-        'buyer_costs': fields.many2many('account.tax', 'auction_buyer_taxes_rel', 'auction_id', 'tax_id', 'Buyer Costs', help="Account Tax For Buyer"), 
-        'seller_costs': fields.many2many('account.tax', 'auction_seller_taxes_rel', 'auction_id', 'tax_id', 'Seller Costs', help="Account Tax For Seller"), 
-        'acc_income': fields.many2one('account.account', 'Income Account', required=True), 
-        'acc_expense': fields.many2one('account.account', 'Expense Account', required=True), 
-        'adj_total': fields.function(_adjudication_get, method=True, string='Total Adjudication', store=True), 
-        'state': fields.selection((('draft', 'Draft'), ('closed', 'Closed')), 'State', select=1, readonly=True, 
-                                  help='When auction starts the state is \'Draft\'.\n At the end of auction, the state becomes \'Closed\'.'), 
-        'account_analytic_id': fields.many2one('account.analytic.account', 'Analytic Account', required=True), 
+        'name': fields.char('Auction Name', size=64, required=True),
+        'expo1': fields.date('First Exposition Day', required=True, help="Beginning Exposition Date For Auction"),
+        'expo2': fields.date('Last Exposition Day', required=True, help="Last Exposition Date For Auction"),
+        'auction1': fields.date('First Auction Day', required=True, help="Start Date Of Auction"),
+        'auction2': fields.date('Last Auction Day', required=True, help="End Date Of Auction"),
+        'journal_id': fields.many2one('account.journal', 'Buyer Journal', required=True, help="Account Journal For Buyer"),
+        'journal_seller_id': fields.many2one('account.journal', 'Seller Journal', required=True, help="Account Journal For Seller"),
+        'buyer_costs': fields.many2many('account.tax', 'auction_buyer_taxes_rel', 'auction_id', 'tax_id', 'Buyer Costs', help="Account Tax For Buyer"),
+        'seller_costs': fields.many2many('account.tax', 'auction_seller_taxes_rel', 'auction_id', 'tax_id', 'Seller Costs', help="Account Tax For Seller"),
+        'acc_income': fields.many2one('account.account', 'Income Account', required=True),
+        'acc_expense': fields.many2one('account.account', 'Expense Account', required=True),
+        'adj_total': fields.function(_adjudication_get, method=True, string='Total Adjudication', store=True),
+        'state': fields.selection((('draft', 'Draft'), ('closed', 'Closed')), 'State', select=1, readonly=True,
+                                  help='When auction starts the state is \'Draft\'.\n At the end of auction, the state becomes \'Closed\'.'),
+        'account_analytic_id': fields.many2one('account.analytic.account', 'Analytic Account', required=True),
     }
-    
+
     _defaults = {
-        'state': lambda *a: 'draft', 
+        'state': lambda *a: 'draft',
     }
-    
+
     _order = "auction1 desc"
 
     def close(self, cr, uid, ids, context=None):
@@ -112,7 +112,7 @@ class auction_dates(osv.osv):
         new_seller_invoice = lots_obj.seller_trans_create(cr, uid, lots_ids2, {})
         self.write(cr, uid, ids, {'state': 'closed'}) #close the auction
         return True
-    
+
 auction_dates()
 
 #----------------------------------------------------------
@@ -120,27 +120,27 @@ auction_dates()
 #----------------------------------------------------------
 class auction_deposit(osv.osv):
     """Auction Deposit Border"""
-    
+
     _name = "auction.deposit"
     _description=__doc__
     _order = "id desc"
     _columns = {
-        'transfer' : fields.boolean('Transfer'), 
-        'name': fields.char('Depositer Inventory', size=64, required=True), 
-        'partner_id': fields.many2one('res.partner', 'Seller', required=True, change_default=True), 
-        'date_dep': fields.date('Deposit date', required=True), 
-        'method': fields.selection((('keep', 'Keep until sold'), ('decease', 'Decrease limit of 10%'), ('contact', 'Contact the Seller')), 'Withdrawned method', required=True), 
-        'tax_id': fields.many2one('account.tax', 'Expenses'), 
-        'create_uid': fields.many2one('res.users', 'Created by', readonly=True), 
-        'info': fields.char('Description', size=64), 
-        'lot_id': fields.one2many('auction.lots', 'bord_vnd_id', 'Objects'), 
-        'specific_cost_ids': fields.one2many('auction.deposit.cost', 'deposit_id', 'Specific Costs'), 
-        'total_neg': fields.boolean('Allow Negative Amount'), 
+        'transfer' : fields.boolean('Transfer'),
+        'name': fields.char('Depositer Inventory', size=64, required=True),
+        'partner_id': fields.many2one('res.partner', 'Seller', required=True, change_default=True),
+        'date_dep': fields.date('Deposit date', required=True),
+        'method': fields.selection((('keep', 'Keep until sold'), ('decease', 'Decrease limit of 10%'), ('contact', 'Contact the Seller')), 'Withdrawned method', required=True),
+        'tax_id': fields.many2one('account.tax', 'Expenses'),
+        'create_uid': fields.many2one('res.users', 'Created by', readonly=True),
+        'info': fields.char('Description', size=64),
+        'lot_id': fields.one2many('auction.lots', 'bord_vnd_id', 'Objects'),
+        'specific_cost_ids': fields.one2many('auction.deposit.cost', 'deposit_id', 'Specific Costs'),
+        'total_neg': fields.boolean('Allow Negative Amount'),
     }
     _defaults = {
-        'method': lambda *a: 'keep', 
-        'total_neg': lambda *a: False, 
-        'name': lambda obj, cr, uid, context: obj.pool.get('ir.sequence').get(cr, uid, 'auction.deposit'), 
+        'method': lambda *a: 'keep',
+        'total_neg': lambda *a: False,
+        'name': lambda obj, cr, uid, context: obj.pool.get('ir.sequence').get(cr, uid, 'auction.deposit'),
     }
 
 auction_deposit()
@@ -149,16 +149,16 @@ auction_deposit()
 # (Specific) Deposit Costs
 #----------------------------------------------------------
 class auction_deposit_cost(osv.osv):
-    
+
     """Auction Deposit Cost"""
-    
+
     _name = 'auction.deposit.cost'
     _description=__doc__
     _columns = {
-        'name': fields.char('Cost Name', required=True, size=64), 
-        'amount': fields.float('Amount'), 
-        'account': fields.many2one('account.account', 'Destination Account', required=True), 
-        'deposit_id': fields.many2one('auction.deposit', 'Deposit'), 
+        'name': fields.char('Cost Name', required=True, size=64),
+        'amount': fields.float('Amount'),
+        'account': fields.many2one('account.account', 'Destination Account', required=True),
+        'deposit_id': fields.many2one('auction.deposit', 'Deposit'),
     }
 auction_deposit_cost()
 
@@ -166,16 +166,16 @@ auction_deposit_cost()
 # Lots Categories
 #----------------------------------------------------------
 class aie_category(osv.osv):
-    
+
     _name="aie.category"
     _order = "name"
     _columns={
-       'name': fields.char('Name', size=64, required=True), 
-       'code':fields.char('Code', size=64), 
-       'parent_id': fields.many2one('aie.category', 'Parent aie Category', ondelete='cascade'), 
-       'child_ids': fields.one2many('aie.category', 'parent_id', help="Childs aie category")       
+       'name': fields.char('Name', size=64, required=True),
+       'code':fields.char('Code', size=64),
+       'parent_id': fields.many2one('aie.category', 'Parent aie Category', ondelete='cascade'),
+       'child_ids': fields.one2many('aie.category', 'parent_id', help="Childs aie category")
     }
-    
+
     def name_get(self, cr, uid, ids, context=None):
         if not context:
             context = {}
@@ -189,22 +189,22 @@ class aie_category(osv.osv):
                 name = record['parent_id'][1] + ' / ' + name
             res.append((record['id'], name))
         return res
-    
-aie_category()   
-    
+
+aie_category()
+
 class auction_lot_category(osv.osv):
     """Auction Lots Category"""
-    
+
     _name = 'auction.lot.category'
     _description=__doc__
     _columns = {
-        'name': fields.char('Category Name', required=True, size=64), 
-        'priority': fields.float('Priority'), 
-        'active' : fields.boolean('Active', help="If the active field is set to true, it will allow you to hide the auction lot category without removing it."), 
-        'aie_categ': fields.many2one('aie.category', 'Category', ondelete='cascade'), 
+        'name': fields.char('Category Name', required=True, size=64),
+        'priority': fields.float('Priority'),
+        'active' : fields.boolean('Active', help="If the active field is set to true, it will allow you to hide the auction lot category without removing it."),
+        'aie_categ': fields.many2one('aie.category', 'Category', ondelete='cascade'),
     }
     _defaults = {
-        'active' : lambda *a: 1, 
+        'active' : lambda *a: 1,
     }
 auction_lot_category()
 
@@ -217,11 +217,11 @@ def _type_get(self, cr, uid, context=None):
     obj = self.pool.get('auction.lot.category')
     ids = obj.search(cr, uid, [])
     res = obj.read(cr, uid, ids, ['name'], context)
-    res = [(r['name'], r['name']) for r in res]   
-    return res 
+    res = [(r['name'], r['name']) for r in res]
+    return res
 
 class auction_lots(osv.osv):
-    
+
     """Auction Object"""
     _name = "auction.lots"
     _order = "obj_num,lot_num,id"
@@ -231,7 +231,7 @@ class auction_lots(osv.osv):
         if not context:
             context={}
         return self.write(cr, uid, ids, {'state':'unsold'})
-    
+
     def button_taken_away(self, cr, uid, ids, context=None):
         if not context:
             context={}
@@ -256,7 +256,7 @@ class auction_lots(osv.osv):
         """
         if not context:
             context = {}
-        
+
         res = {}
         account_analytic_line_obj = self.pool.get('account.analytic.line')
         lots = self.browse(cr, uid, ids, context)
@@ -289,24 +289,24 @@ class auction_lots(osv.osv):
                 elif name == "gross_revenue":
                     if lot.auction_id:
                         result = lot.buyer_price - lot.seller_price
-                        
+
                 elif name == "net_revenue":
                     if lot.auction_id:
                         result = lot.buyer_price - lot.seller_price - lot.costs
-                        
+
                 elif name == "gross_margin":
                    if ((lot.obj_price==0) and (lot.state=='draft')):
                      amount = lot.lot_est1
-                   else: 
+                   else:
                      amount = lot.obj_price
                    if amount > 0:
                      result = (lot.gross_revenue * 100) / amount
                      result = round(result,2)
-                     
+
                 elif name == "net_margin":
                     if ((lot.obj_price==0) and (lot.state=='draft')):
                         amount = lot.lot_est1
-                    else: 
+                    else:
                         amount = lot.obj_price
                     if amount > 0:
                         result = (lot.net_revenue * 100) / amount
@@ -320,8 +320,8 @@ class auction_lots(osv.osv):
                         auct_id = lot.auction_id.id
                         lot_count = self.search(cr, uid, [('auction_id', '=', auct_id)], count=True)
                         line_ids = account_analytic_line_obj.search(cr, uid, [
-                                    ('account_id', '=', lot.auction_id.account_analytic_id.id), 
-                                    ('journal_id', '<>', lot.auction_id.journal_id.id), 
+                                    ('account_id', '=', lot.auction_id.account_analytic_id.id),
+                                    ('journal_id', '<>', lot.auction_id.journal_id.id),
                                     ('journal_id', '<>', lot.auction_id.journal_seller_id.id)])
                         indir_cost = lot.bord_vnd_id.specific_cost_ids
                         for r in lot.bord_vnd_id.specific_cost_ids:
@@ -330,20 +330,20 @@ class auction_lots(osv.osv):
                             if line.amount:
                                 som -= line.amount
                         result = som/lot_count
-                    
+
                 elif name=="paid_ach":
                     result = False
                     if lot.ach_inv_id and lot.ach_inv_id.state == 'paid':
                         result = True
-                                        
+
                 elif name=="paid_vnd":
                     result = False
                     if lot.sel_inv_id and lot.sel_inv_id.state == 'paid':
-                        result = True  
-    
+                        result = True
+
                 res[lot.id][name] = result
-                
-            
+
+
         return res
 
     def onchange_obj_ret(self, cr, uid, ids, obj_ret, context=None):
@@ -354,66 +354,66 @@ class auction_lots(osv.osv):
         return {}
 
     _columns = {
-        'bid_lines':fields.one2many('auction.bid_line', 'lot_id', 'Bids'), 
-        'auction_id': fields.many2one('auction.dates', 'Auction', select=1, help="Auction For Object"), 
-        'bord_vnd_id': fields.many2one('auction.deposit', 'Depositer Inventory', required=True, help="Provide Deposit Information: seller, Withdrawned Method, Object, Deposit Costs"), 
-        'name': fields.char('Title', size=64, required=True, help='Auction Object Name'), 
-        'name2': fields.char('Short Description (2)', size=64), 
-        'lot_type': fields.selection(_type_get, 'Object category', size=64), 
-        'author_right': fields.many2one('account.tax', 'Author rights', help="Account Tax For Author Commission"), 
-        'lot_est1': fields.float('Minimum Estimation', help="Minimum Estimate Price"), 
-        'lot_est2': fields.float('Maximum Estimation', help="Maximum Estimate Price"), 
-        'lot_num': fields.integer('List Number', required=True, select=1, help="List Number In Depositer Inventory"), 
-        'create_uid': fields.many2one('res.users', 'Created by', readonly=True), 
-        'history_ids':fields.one2many('auction.lot.history', 'lot_id', 'Auction history'), 
-        'lot_local':fields.char('Location', size=64, help="Auction Location"), 
-        'artist_id':fields.many2one('auction.artists', 'Artist/Author'), 
-        'artist2_id':fields.many2one('auction.artists', 'Artist/Author2'), 
-        'important':fields.boolean('To be Emphatized'), 
-        'product_id':fields.many2one('product.product', 'Product', required=True), 
-        'obj_desc': fields.text('Object Description'), 
-        'obj_num': fields.integer('Catalog Number'), 
-        'obj_ret': fields.float('Price retired', help="Object Ret"), 
-        'obj_comm': fields.boolean('Commission'), 
-        'obj_price': fields.float('Adjudication price', help="Object Price"), 
-        'ach_avance': fields.float('Buyer Advance'), 
-        'ach_login': fields.char('Buyer Username', size=64), 
+        'bid_lines':fields.one2many('auction.bid_line', 'lot_id', 'Bids'),
+        'auction_id': fields.many2one('auction.dates', 'Auction', select=1, help="Auction For Object"),
+        'bord_vnd_id': fields.many2one('auction.deposit', 'Depositer Inventory', required=True, help="Provide Deposit Information: seller, Withdrawned Method, Object, Deposit Costs"),
+        'name': fields.char('Title', size=64, required=True, help='Auction Object Name'),
+        'name2': fields.char('Short Description (2)', size=64),
+        'lot_type': fields.selection(_type_get, 'Object category', size=64),
+        'author_right': fields.many2one('account.tax', 'Author rights', help="Account Tax For Author Commission"),
+        'lot_est1': fields.float('Minimum Estimation', help="Minimum Estimate Price"),
+        'lot_est2': fields.float('Maximum Estimation', help="Maximum Estimate Price"),
+        'lot_num': fields.integer('List Number', required=True, select=1, help="List Number In Depositer Inventory"),
+        'create_uid': fields.many2one('res.users', 'Created by', readonly=True),
+        'history_ids':fields.one2many('auction.lot.history', 'lot_id', 'Auction history'),
+        'lot_local':fields.char('Location', size=64, help="Auction Location"),
+        'artist_id':fields.many2one('auction.artists', 'Artist/Author'),
+        'artist2_id':fields.many2one('auction.artists', 'Artist/Author2'),
+        'important':fields.boolean('To be Emphatized'),
+        'product_id':fields.many2one('product.product', 'Product', required=True),
+        'obj_desc': fields.text('Object Description'),
+        'obj_num': fields.integer('Catalog Number'),
+        'obj_ret': fields.float('Price retired', help="Object Ret"),
+        'obj_comm': fields.boolean('Commission'),
+        'obj_price': fields.float('Adjudication price', help="Object Price"),
+        'ach_avance': fields.float('Buyer Advance'),
+        'ach_login': fields.char('Buyer Username', size=64),
         'ach_uid': fields.many2one('res.partner', 'Buyer'),
-        'seller_id': fields.related('bord_vnd_id','partner_id', type='many2one', relation='res.partner', string='Seller', readonly=True), 
-        'ach_emp': fields.boolean('Taken Away', readonly=True, help="When state is Taken Away, This field is Marked as True"), 
-        'is_ok': fields.boolean('Buyer\'s payment', help="When Buyer Pay For Bank statement', This field is Marked"), 
-        'ach_inv_id': fields.many2one('account.invoice', 'Buyer Invoice', readonly=True, states={'draft':[('readonly', False)]}), 
-        'sel_inv_id': fields.many2one('account.invoice', 'Seller Invoice', readonly=True, states={'draft':[('readonly', False)]}), 
-        'vnd_lim': fields.float('Seller limit'), 
-        'vnd_lim_net': fields.boolean('Net limit ?', readonly=True), 
-        'image': fields.binary('Image', help="Object Image"), 
-        'paid_vnd':fields.function(_getprice, string='Seller Paid', method=True, type='boolean', store=True, multi="paid_vnd", help="When state of Seller Invoice is 'Paid', This field is selected as True."), 
-        'paid_ach':fields.function(_getprice, string='Buyer Invoice Reconciled', method=True, type='boolean', store=True, multi="paid_ach", help="When state of Buyer Invoice is 'Paid', This field is selected as True."), 
+        'seller_id': fields.related('bord_vnd_id','partner_id', type='many2one', relation='res.partner', string='Seller', readonly=True),
+        'ach_emp': fields.boolean('Taken Away', readonly=True, help="When state is Taken Away, This field is Marked as True"),
+        'is_ok': fields.boolean('Buyer\'s payment', help="When Buyer Pay For Bank statement', This field is Marked"),
+        'ach_inv_id': fields.many2one('account.invoice', 'Buyer Invoice', readonly=True, states={'draft':[('readonly', False)]}),
+        'sel_inv_id': fields.many2one('account.invoice', 'Seller Invoice', readonly=True, states={'draft':[('readonly', False)]}),
+        'vnd_lim': fields.float('Seller limit'),
+        'vnd_lim_net': fields.boolean('Net limit ?', readonly=True),
+        'image': fields.binary('Image', help="Object Image"),
+        'paid_vnd':fields.function(_getprice, string='Seller Paid', method=True, type='boolean', store=True, multi="paid_vnd", help="When state of Seller Invoice is 'Paid', This field is selected as True."),
+        'paid_ach':fields.function(_getprice, string='Buyer Invoice Reconciled', method=True, type='boolean', store=True, multi="paid_ach", help="When state of Buyer Invoice is 'Paid', This field is selected as True."),
         'state': fields.selection((
-            ('draft', 'Draft'), 
-            ('unsold', 'Unsold'), 
-            ('paid', 'Paid'), 
-            ('sold', 'Sold'), 
-            ('taken_away', 'Taken away')), 'State', required=True, readonly=True, 
+            ('draft', 'Draft'),
+            ('unsold', 'Unsold'),
+            ('paid', 'Paid'),
+            ('sold', 'Sold'),
+            ('taken_away', 'Taken away')), 'State', required=True, readonly=True,
             help=' * The \'Draft\' state is used when a object is encoding as a new object. \
                 \n* The \'Unsold\' state is used when object does not sold for long time, user can also set it as draft state after unsold. \
                 \n* The \'Paid\' state is used when user pay for the object \
-                \n* The \'Sold\' state is used when user buy the object.'), 
-        'buyer_price': fields.function(_getprice, method=True, string='Buyer price', store=True, multi="buyer_price", help="Buyer Price"), 
-        'seller_price': fields.function(_getprice, method=True, string='Seller price', store=True, multi="seller_price", help="Seller Price"), 
-        'gross_revenue':fields.function(_getprice, method=True, string='Gross revenue', store=True, multi="gross_revenue", help="Buyer Price - Seller Price"), 
-        'gross_margin':fields.function(_getprice, method=True, string='Gross Margin (%)', store=True, multi="gross_margin", help="(Gross Revenue*100.0)/ Object Price"), 
-        'costs':fields.function(_getprice, method=True, string='Indirect costs', store=True, multi="costs", help="Deposit cost"), 
-        'statement_id': fields.many2many('account.bank.statement.line', 'auction_statement_line_rel', 'auction_id', 'statement', 'Payment', help="Bank statement Line For Given Buyer"), 
-        'net_revenue':fields.function(_getprice, method=True, string='Net revenue', store=True, multi="net_revenue", help="Buyer Price - Seller Price - Indirect Cost"), 
-        'net_margin':fields.function(_getprice, method=True, string='Net Margin (%)', store=True, multi="net_margin", help="(Net Revenue * 100)/ Object Price"), 
+                \n* The \'Sold\' state is used when user buy the object.'),
+        'buyer_price': fields.function(_getprice, method=True, string='Buyer price', store=True, multi="buyer_price", help="Buyer Price"),
+        'seller_price': fields.function(_getprice, method=True, string='Seller price', store=True, multi="seller_price", help="Seller Price"),
+        'gross_revenue':fields.function(_getprice, method=True, string='Gross revenue', store=True, multi="gross_revenue", help="Buyer Price - Seller Price"),
+        'gross_margin':fields.function(_getprice, method=True, string='Gross Margin (%)', store=True, multi="gross_margin", help="(Gross Revenue*100.0)/ Object Price"),
+        'costs':fields.function(_getprice, method=True, string='Indirect costs', store=True, multi="costs", help="Deposit cost"),
+        'statement_id': fields.many2many('account.bank.statement.line', 'auction_statement_line_rel', 'auction_id', 'statement', 'Payment', help="Bank statement Line For Given Buyer"),
+        'net_revenue':fields.function(_getprice, method=True, string='Net revenue', store=True, multi="net_revenue", help="Buyer Price - Seller Price - Indirect Cost"),
+        'net_margin':fields.function(_getprice, method=True, string='Net Margin (%)', store=True, multi="net_margin", help="(Net Revenue * 100)/ Object Price"),
     }
     _defaults = {
-        'state':lambda *a: 'draft', 
-        'lot_num':lambda *a:1, 
-        'is_ok': lambda *a: False, 
+        'state':lambda *a: 'draft',
+        'lot_num':lambda *a:1,
+        'is_ok': lambda *a: False,
     }
-    
+
     def name_get(self, cr, user, ids, context=None):
         if not context:
             context={}
@@ -467,7 +467,7 @@ class auction_lots(osv.osv):
                 amount+=t['amount']
         amount_total['value']= amount
         amount_total['amount']= amount
-        
+
         return amount_total
 
 
@@ -481,7 +481,7 @@ class auction_lots(osv.osv):
                 tax_cost_ids.append(border_id.tax_id)
             elif lot.auction_id and lot.auction_id.seller_costs:
                 tax_cost_ids += lot.auction_id.seller_costs
-                
+
         tax_costs = self.pool.get('account.tax').compute_all(cr, uid, tax_cost_ids, lot.obj_price, 1)['taxes']
         # delete useless keys from the costs computed by the tax object... this is useless but cleaner...
         for cost in tax_costs:
@@ -497,13 +497,13 @@ class auction_lots(osv.osv):
             #FIXME:the string passes have lot 'should go through the system translations.
             obj_price_wh_costs = reduce(lambda x, y: x + y['amount'], tax_costs, lot.obj_price)
             if obj_price_wh_costs < lot.vnd_lim:
-                costs.append({  'type': 1, 
-                                'id': lot.obj_num, 
-                                'name': 'Remise lot '+ str(lot.obj_num), 
+                costs.append({  'type': 1,
+                                'id': lot.obj_num,
+                                'name': 'Remise lot '+ str(lot.obj_num),
                                 'amount': lot.vnd_lim - obj_price_wh_costs}
                             )
         return costs
-    
+
     def compute_seller_costs(self, cr, uid, ids, manual_only=False):
         lots = self.browse(cr, uid, ids)
         costs = []
@@ -543,9 +543,9 @@ class auction_lots(osv.osv):
 
     # sum remise limite net and ristourne
     def compute_seller_costs_summed(self, cr, uid, ids): #ach_pay_id
-        
+
         """This Fuction  sum Net remittance limit and refund"""
-        
+
         taxes = self.compute_seller_costs(cr, uid, ids)
         taxes_summed = {}
         for tax in taxes:
@@ -567,7 +567,7 @@ class auction_lots(osv.osv):
         return taxes_summed.values()
 
     def buyer_proforma(self, cr, uid, ids, context=None):
-        
+
         if not context:
             context={}
         invoices = {}
@@ -589,11 +589,10 @@ class auction_lots(osv.osv):
                 if not invoice_addr_id:
                     raise orm.except_orm(_('No Invoice Address'), _('The Buyer "%s" has no Invoice Address.') % (contact_addr_id,))
                 inv = {
-                    'name': 'Auction proforma:' +lot.name, 
-                    'journal_id': lot.auction_id.journal_id.id, 
-                    'partner_id': partner_ref, 
-                    'type': 'out_invoice', 
-                #   'state':'proforma',
+                    'name': 'Auction proforma:' +lot.name,
+                    'journal_id': lot.auction_id.journal_id.id,
+                    'partner_id': partner_ref,
+                    'type': 'out_invoice',
                 }
                 inv.update(inv_ref.onchange_partner_id(cr, uid, [], 'out_invoice', partner_ref)['value'])
                 inv['account_id'] = inv['account_id'] and inv['account_id'][0]
@@ -648,10 +647,10 @@ class auction_lots(osv.osv):
                 contact_addr_id = res['contact']
                 invoice_addr_id = res['invoice']
                 inv = {
-                    'name': 'Auction:' +lot.name, 
-                    'journal_id': lot.auction_id.journal_seller_id.id, 
-                    'partner_id': lot.bord_vnd_id.partner_id.id, 
-                    'type': 'in_invoice', 
+                    'name': 'Auction:' +lot.name,
+                    'journal_id': lot.auction_id.journal_seller_id.id,
+                    'partner_id': lot.bord_vnd_id.partner_id.id,
+                    'type': 'in_invoice',
                 }
                 inv.update(inv_ref.onchange_partner_id(cr, uid, [], 'in_invoice', lot.bord_vnd_id.partner_id.id)['value'])
                 inv_id = inv_ref.create(cr, uid, inv, context)
@@ -666,14 +665,14 @@ class auction_lots(osv.osv):
                 taxes += map(lambda x: x.id, lot.auction_id.seller_costs)
 
             inv_line= {
-                'invoice_id': inv_id, 
-                'quantity': 1, 
-                'product_id': lot.product_id.id, 
-                'name': '['+str(lot.obj_num)+'] '+lot.auction_id.name, 
-                'invoice_line_tax_id': [(6, 0, taxes)], 
-                'account_analytic_id': lot.auction_id.account_analytic_id.id, 
-                'account_id': lot.auction_id.acc_expense.id, 
-                'price_unit': lot.obj_price, 
+                'invoice_id': inv_id,
+                'quantity': 1,
+                'product_id': lot.product_id.id,
+                'name': '['+str(lot.obj_num)+'] '+lot.auction_id.name,
+                'invoice_line_tax_id': [(6, 0, taxes)],
+                'account_analytic_id': lot.auction_id.account_analytic_id.id,
+                'account_id': lot.auction_id.acc_expense.id,
+                'price_unit': lot.obj_price,
             }
             inv_line_obj.create(cr, uid, inv_line, context)
             inv_ref.button_compute(cr, uid, invoices.values())
@@ -715,11 +714,11 @@ class auction_lots(osv.osv):
                 price = lot.obj_price or 0.0
                 lot_name =lot.obj_num
                 inv = {
-                    'name':lot.auction_id.name or '', 
-                    'reference': lot.ach_login, 
-                    'journal_id': lot.auction_id.journal_id.id, 
-                    'partner_id': lot.ach_uid.id, 
-                    'type': 'out_invoice', 
+                    'name':lot.auction_id.name or '',
+                    'reference': lot.ach_login,
+                    'journal_id': lot.auction_id.journal_id.id,
+                    'partner_id': lot.ach_uid.id,
+                    'type': 'out_invoice',
                 }
                 if invoice_number:
                     inv['number'] = invoice_number
@@ -734,14 +733,14 @@ class auction_lots(osv.osv):
                 taxes.append(lot.author_right.id)
 
             inv_line= {
-                'invoice_id': inv_id, 
-                'quantity': 1, 
-                'product_id': lot.product_id.id, 
-                'name': '['+str(lot.obj_num)+'] '+ lot.name, 
-                'invoice_line_tax_id': [(6, 0, taxes)], 
-                'account_analytic_id': lot.auction_id.account_analytic_id.id, 
-                'account_id': lot.auction_id.acc_income.id, 
-                'price_unit': lot.obj_price, 
+                'invoice_id': inv_id,
+                'quantity': 1,
+                'product_id': lot.product_id.id,
+                'name': '['+str(lot.obj_num)+'] '+ lot.name,
+                'invoice_line_tax_id': [(6, 0, taxes)],
+                'account_analytic_id': lot.auction_id.account_analytic_id.id,
+                'account_id': lot.auction_id.acc_income.id,
+                'price_unit': lot.obj_price,
             }
             inv_line_obj.create(cr, uid, inv_line, context)
             inv_ref.button_compute(cr, uid, [inv_id])
@@ -756,21 +755,21 @@ auction_lots()
 #----------------------------------------------------------
 class auction_bid(osv.osv):
     """Bid Auctions"""
-    
+
     _name = "auction.bid"
     _description=__doc__
     _order = 'id desc'
     _columns = {
-        'partner_id': fields.many2one('res.partner', 'Buyer Name', required=True), 
-        'contact_tel':fields.char('Contact', size=64), 
-        'name': fields.char('Bid ID', size=64, required=True), 
-        'auction_id': fields.many2one('auction.dates', 'Auction Date', required=True), 
-        'bid_lines': fields.one2many('auction.bid_line', 'bid_id', 'Bid'), 
+        'partner_id': fields.many2one('res.partner', 'Buyer Name', required=True),
+        'contact_tel':fields.char('Contact', size=64),
+        'name': fields.char('Bid ID', size=64, required=True),
+        'auction_id': fields.many2one('auction.dates', 'Auction Date', required=True),
+        'bid_lines': fields.one2many('auction.bid_line', 'bid_id', 'Bid'),
     }
     _defaults = {
-        'name': lambda obj, cr, uid, context: obj.pool.get('ir.sequence').get(cr, uid, 'auction.bid'), 
+        'name': lambda obj, cr, uid, context: obj.pool.get('ir.sequence').get(cr, uid, 'auction.bid'),
     }
-    
+
     def onchange_contact(self, cr, uid, ids, partner_id):
         if not partner_id:
             return {'value': {'contact_tel':False}}
@@ -785,13 +784,13 @@ auction_bid()
 
 class auction_lot_history(osv.osv):
     """Lot History"""
-    
+
     _name = "auction.lot.history"
     _description=__doc__
     _columns = {
-        'name': fields.date('Date', size=64), 
-        'lot_id': fields.many2one('auction.lots', 'Object', required=True, ondelete='cascade'), 
-        'auction_id': fields.many2one('auction.dates', 'Auction date', required=True, ondelete='cascade'), 
+        'name': fields.date('Date', size=64),
+        'lot_id': fields.many2one('auction.lots', 'Object', required=True, ondelete='cascade'),
+        'auction_id': fields.many2one('auction.dates', 'Auction date', required=True, ondelete='cascade'),
         'price': fields.float('Withdrawn price', digits=(16, 2))
     }
     _defaults = {
@@ -804,11 +803,11 @@ class auction_bid_lines(osv.osv):
     _description="Bid"
 
     _columns = {
-        'name': fields.char('Bid date', size=64), 
-        'bid_id': fields.many2one('auction.bid', 'Bid ID', required=True, ondelete='cascade'), 
-        'lot_id': fields.many2one('auction.lots', 'Object', required=True, ondelete='cascade'), 
-        'call': fields.boolean('To be Called'), 
-        'price': fields.float('Maximum Price'), 
+        'name': fields.char('Bid date', size=64),
+        'bid_id': fields.many2one('auction.bid', 'Bid ID', required=True, ondelete='cascade'),
+        'lot_id': fields.many2one('auction.lots', 'Object', required=True, ondelete='cascade'),
+        'call': fields.boolean('To be Called'),
+        'price': fields.float('Maximum Price'),
         'auction': fields.char(string='Auction Name', size=64)
     }
     _defaults = {
index 45b157e..9b804e8 100644 (file)
        <record model="account.account" id="auction_income">
                <field name="name">Auction Adjudications</field>
                <field name="code">7x*</field>
-                <field name="user_type" ref="account.account_type_income"/> 
+                <field name="user_type" ref="account.account_type_income"/>
                <field name="type">receivable</field>
                <field name="currency_id" search="[('name','=','EUR')]"/>
                <field name="parent_id" eval="auction_income_view"/>
        </record>
-       
+
        <record model="account.account" id="auction_expense">
                <field name="name">Auction Adjudication Expenses</field>
                <field name="code">6x*</field>
            <field name="type">default</field>
            <field name="partner_id" ref="partner_record1"/>
        </record>
-       
+
        <record id="res_partner_unknown_address_3" model="res.partner.address">
            <field name="city">Louvain-la-Neuve</field>
            <field name="name">Thomas Passot</field>
        </record>
 
         <!-- demo data for the auction_artist object-->
-        
+
     <record model="auction.artists" id="auction_art_1">
         <field name="name">Philippe Lavilier</field>
         <field name="birth_death_dates">1345-1450</field>
     </record>
-    
+
     <record model="auction.artists" id="auction_art_2">
         <field name="name">POREAU OSWALD</field>
         <field name="birth_death_dates">1877-1955</field>
         <field name="base_code_id" ref="account_tax_code_id5"/>
         <field name="tax_code_id" ref="account_tax_code_id5"/>
     </record>
-    
+
     <record id="auction_tax1" model="account.tax">
         <field name="name">TVA</field>
         <field name="amount">0.12</field>
         <field name="base_code_id" ref="account_tax_code_id2"/>
         <field name="tax_code_id" ref="account_tax_code_id2"/>
     </record>
-    
+
     <record id="auction_tax3" model="account.tax">
         <field name="name">Buyer Costs</field>
         <field name="amount">0.21</field>
         <field name="base_code_id" ref="account_tax_code_id1"/>
         <field name="tax_code_id" ref="account_tax_code_id1"/>
     </record>
-    
+
     <record id="auction_tax4" model="account.tax">
          <field name="name">Seller Costs1</field>
          <field name="amount">-0.10</field>
          <field name="base_code_id" ref="account_tax_code_id1"/>
          <field name="tax_code_id" ref="account_tax_code_id1"/>
     </record>
-    
+
     <record id="auction_tax5" model="account.tax">
          <field name="name">Seller Costs</field>
          <field name="amount">-0.10</field>
        <field name="base_code_id" ref="account_tax_code_id2"/>
        <field name="tax_code_id" ref="account_tax_code_id2"/>
     </record>
-    
+
     <record id="monproduit" model="product.product">
         <field name="name">Oeuvres a 21%</field>
         <field name="categ_id" ref="product.product_category_pc"/>
         <field name="priority">1</field>
         <field name="aie_categ" ref="aie_category_paint_view"/>
     </record>
-    
+
     <record model="auction.lot.category" id="auction_cat_2">
         <field name="name">Furniture</field>
         <field name="priority">2</field>
         <field name="priority">2</field>
          <field name="aie_categ"  ref="aie_category_pcg_view"/>
     </record>
-    
+
     <record model="auction.lot.category" id="auction_cat_4">
         <field name="name">Sculpture</field>
         <field name="priority">10</field>
         <!--field name="product_id" ref="monproduit"/-->
         <field name="author_right" ref="auction_tax"/>
         <field name="product_id" model="product.product" search="[]"/>
-        <!--<field name="tva" model="account.tax" search="[]"/>-->
     </record>
 
     <record model="auction.lots" id="auction_deposit_2_lot_1">
         <field name="obj_num">4</field>
         <field name="obj_price">0.00</field>
         <field name="bord_vnd_id" ref="auction_deposit_2" />
-        <!--field name="product_id" ref="monproduit"/-->
         <field name="author_right" ref="auction_tax"/>
         <field name="product_id" model="product.product" search="[]"/>
-        <!--<field name="tva" model="account.tax" search="[]"/>-->
     </record>
 
     <record model="auction.lots" id="auction_deposit_2_lot_2">
         <field name="obj_num">4</field>
         <field name="obj_price">375</field>
         <field name="bord_vnd_id" ref="auction_deposit_2" />
-        <!--field name="product_id" ref="monproduit"/-->
         <field name="author_right" ref="auction_tax"/>
         <field name="product_id" model="product.product" search="[]"/>
-        <!--<field name="tva" model="account.tax" search="[]"/>-->
     </record>
 
     <record model="auction.lots" id="auction_deposit_3_lot_1">
         <field name="auction_id" ref="auction_date_1" />
         <field name="name">Plastic glass</field>
         <field name="lot_num">5</field>
-        <!--field name="lot_type">glass</field-->
         <field name="lot_est1">300</field>
         <field name="lot_est2">500</field>
         <field name="obj_desc">show pices</field>
         <field name="auction_id" ref="auction_date_1" />
         <field name="name">bresslet</field>
         <field name="lot_num">7</field>
-        <!--field name="lot_type">Jewellery</field-->
         <field name="lot_est1">150</field>
         <field name="lot_est2">400</field>
         <field name="obj_desc">show pices</field>
         <field name="auction_id" ref="auction_date_1" />
         <field name="name">gold chain</field>
         <field name="lot_num">11</field>
-        <!--field name="lot_type">Jawellery</field-->
         <field name="lot_est1">400</field>
         <field name="lot_est2">700</field>
         <field name="obj_desc">show pices</field>
         <field name="auction_id" ref="auction_date_1" />
         <field name="name">fiber glass</field>
         <field name="lot_num">8</field>
-        <!--field name="lot_type">glass</field-->
         <field name="lot_est1">300</field>
         <field name="lot_est2">500</field>
         <field name="obj_desc">show pices</field>
         <field name="auction_id" ref="auction_date_1" />
         <field name="name">lake photos</field>
         <field name="lot_num">9</field>
-        <!--field name="lot_type">painting</field-->
         <field name="lot_est1">100</field>
         <field name="lot_est2">200</field>
         <field name="obj_desc">show pices</field>
         <field name="auction_id" ref="auction_date_1" />
         <field name="name">mobile photos</field>
         <field name="lot_num">10</field>
-        <!--field name="lot_type">mobile</field-->
         <field name="lot_est1">4500</field>
         <field name="lot_est2">4700</field>
         <field name="obj_desc">show models</field>
         <field name="auction_id" ref="auction_date_1" />
         <field name="name">Antique photos</field>
         <field name="lot_num">11</field>
-        <!--field name="lot_type">common</field-->
         <field name="lot_est1">1600</field>
         <field name="lot_est2">2200</field>
         <field name="obj_desc">show map Items</field>
         <field name="auction_id" ref="auction_date_1" />
         <field name="name">Hardware  photos</field>
         <field name="lot_num">12</field>
-        <!--field name="lot_type">common</field-->
         <field name="lot_est1">2600</field>
         <field name="lot_est2">2800</field>
         <field name="obj_desc">show map Items</field>
         <field name="auction_id" ref="auction_date_1" />
         <field name="name">mobile accesories photos</field>
         <field name="lot_num">13</field>
-        <!--field name="lot_type">common</field-->
         <field name="lot_est1">1600</field>
         <field name="lot_est2">2200</field>
         <field name="obj_desc">show map Items</field>
         <field name="auction_id" ref="auction_date_2" />
         <field name="name">pikes-candles</field>
         <field name="lot_num">14</field>
-        <!--field name="lot_type">common</field-->
         <field name="lot_est1">30</field>
         <field name="lot_est2">50</field>
         <field name="obj_desc">show map Items</field>
         <field name="auction_id" ref="auction_date_1" />
         <field name="name">Coffee Service</field>
         <field name="lot_num">15</field>
-        <!--field name="lot_type">common</field-->
         <field name="lot_est1">10</field>
         <field name="lot_est2">20</field>
         <field name="obj_desc">show map Items</field>
 
     <record model="hr.employee" id="employee2">
        <field name="name">Demo</field>
-<!--            <field name="regime">45</field>-->
        <field name="user_id" search="[('login','=','admin')]" model="res.users"/>
-<!--            <field name="holiday_max">25</field>
          <field name="workgroups" ref="timesheet_group1" />-->
     </record>
 
         <field name="action">sign_in</field>
         <field name="employee_id" ref="hr.employee1" />
     </record>
-     
+
     <record model="hr.attendance" id="unknown1_emp2">
        <field name="name" eval="time.strftime('%Y-%m-25 9:21')"/>
        <field name="action">sign_out</field>
        <field name="employee_id" ref="hr.employee1" />
     </record>
-     
+
     <record model="hr.attendance" id="unknown1_emp3">
        <field name="name" eval="time.strftime('%Y-%m-25 09:25')"/>
        <field name="action">sign_in</field>
        <field name="employee_id" ref="hr.employee1" />
     </record>
-     
+
     <record model="hr.attendance" id="unknown1_emp4">
        <field name="name" eval="time.strftime('%Y-%m-25 11:54')"/>
        <field name="action">sign_out</field>
        <field name="employee_id" ref="hr.employee1" />
     </record>
-     
+
     <record model="hr.attendance" id="unknown1_emp5">
        <field name="name" eval="time.strftime('%Y-%m-25 11:59')"/>
        <field name="action">sign_in</field>
        <field name="employee_id" ref="hr.employee1" />
     </record>
-     
+
     <record model="hr.attendance" id="unknown1_emp6">
        <field name="name" eval="time.strftime('%Y-%m-25 13:31')"/>
        <field name="action">sign_out</field>
        <field name="employee_id" ref="hr.employee1"/>
     </record>
-     
+
     <record model="hr.attendance" id="unknown1_emp7">
        <field name="name" eval="time.strftime('%Y-%m-25 20:10')"/>
        <field name="action">sign_in</field>
        <field name="employee_id" ref="hr.employee1" />
     </record>
-     
+
     <record model="hr.attendance" id="unknown1_emp8">
        <field name="name" eval="time.strftime('%Y-%m-25 21:34')"/>
        <field name="action">sign_out</field>
        <field name="action">sign_in</field>
        <field name="employee_id" ref="employee2" />
     </record>
-     
+
     <record model="hr.attendance" id="unknown2_emp2">
        <field name="name" eval="time.strftime('%Y-%m-26 9:21')"/>
        <field name="action">sign_out</field>
        <field name="employee_id" ref="employee2" />
     </record>
-     
+
     <record model="hr.attendance" id="unknown2_emp3">
        <field name="name" eval="time.strftime('%Y-%m-26 10:21')"/>
        <field name="action">sign_in</field>
        <field name="employee_id" ref="employee2" />
     </record>
-     
+
     <record model="hr.attendance" id="unknown2_emp4">
        <field name="name" eval="time.strftime('%Y-%m-26 12:54')"/>
        <field name="action">sign_out</field>
        <field name="employee_id" ref="employee2" />
     </record>
-     
+
     <record model="hr.attendance" id="unknown2_emp5">
        <field name="name" eval="time.strftime('%Y-%m-26 13:32')"/>
        <field name="action">sign_in</field>
        <field name="employee_id" ref="employee2" />
     </record>
-     
+
     <record model="hr.attendance" id="unknown2_emp6">
        <field name="name" eval="time.strftime('%Y-%m-26 16:31')"/>
        <field name="action">sign_out</field>
        <field name="employee_id" ref="employee2"/>
     </record>
-     
+
     <record model="hr.attendance" id="unknown2_emp7">
        <field name="name" eval="time.strftime('%Y-%m-26 17:10')"/>
        <field name="action">sign_in</field>
        <field name="employee_id" ref="employee2" />
     </record>
-     
+
     <record model="hr.attendance" id="unknown2_emp8">
        <field name="name" eval="time.strftime('%Y-%m-26 22:34')"/>
        <field name="action">sign_out</field>
index 885c085..4df44c9 100644 (file)
@@ -1,7 +1,6 @@
 <?xml version="1.0"?>
 <openerp>
        <data>
-               <!--<delete model="ir.actions.report.xml" search="[('model','like','auction.')]"/>-->
 
     <report string="Bailiffs Listing"
                model="auction.lots"
                 id="art2"
                 multi="1"/>
 
-<!--           <report string="Artists Biography"
-
-                model="auction.lots"
-                name="auction.artists"
-                rml="auction/report/auction_artists.rml"
-                id="art_auction"
-                multi="1"/>
--->
     <report string="Bids phones"
                 model="auction.lots"
                 name="bids.lots"
                 auto="False"
                 multi="1"/>
 
-<!--   <report string="Catalog with pictures"
-               model="auction.lots"
-               name="catelogwithpictures"
-               rml="auction/report/catelogwithpictures.rml"
-               auto="False"
-               multi="1"
-               id="1"/>
--->
        <report string="Catalog"
                model="auction.lots"
                name="auction.catelog"
                auto="False"
                multi="1"/>
 
-       <!--<report string="Deposit Letter"
-               model="auction.lots"
-               name="deposit.seller"
-               rml="auction/report/deposit_seller.rml"
-               auto="False"
-               multi="1"/>-->
-
        <report string="Lots List"
                model="auction.lots"
                name="lots.list"
                auto="False"
                id="total_result1"
                multi="1"/>
-<!--             <report string="Buyer Form"
-                 model="auction.lots"
-                 name="buyer_form_report"
-                 rml="auction/report/buyer_form_report.rml"
-                 auto="False"
-                 multi="1"/>
--->
-<!--             <report string="Seller form"
-                 model="auction.lots"
-                 name="seller_form_report"
-                 rml="auction/report/seller_form_report.rml"
-                 auto="False"
-                 multi="1"/>-->
 
        <report string="Buyer Form"
                id="buyer_form_id"
                xml="auction/report/deposit.xml"
                xsl="auction/report/deposit.xsl"/>
 
-               <!--<report
-                       id="report_auction_catalog"
-                       string="Catalog flagey"
-                       model="auction.lots"
-                       name="auction.cat_flagy"
-                       xsl="'auction/report/catalog2.xsl"/>-->
-
        <report string="Seller Form"
                id="seller_lots_3"
                model="auction.lots"
            multi="1"/>
 
 
-<!--           <report string="Seller List"
-                model="auction.lots"
-                name="report.auction.seller.list"
-                xml="auction/report/seller_list.xml"
-                xsl="auction/report/seller_list.xsl"
-                menu="False"
-                id="v_seller_list"
-                 multi="1"/>
--->
        <report string="Bids per lot (phone)"
                 model="auction.lots"
                 name="bids.phones.details"
                multi="1"
                id="res_w_buyer"/>
 
-               <!--    <wizard
-                       id="auction_catalog_flagy"
-                       string="Auction Catalog Flagy"
-                       model="auction.lots"
-                       name="auction.catalog.flagey"
-                       keyword="client_print_multi"/>-->
-
                </data>
 </openerp>
 
index ab1b051..70caa14 100644 (file)
@@ -1,45 +1,6 @@
 <?xml version="1.0"?>
 <openerp>
        <data>
-<!--   Following wizard is remaining to implement in osv_memory-->
-               <!--  
-               <wizard string="Send to website"
-                       model="auction.lots"
-                       name="auction.lots.send.aie"
-                       id="wizard_send"/>
-
-               <wizard string="Send results to Auction-in-europe.com"
-               model="auction.lots"
-               name="auction.lots.send.aie.results"
-               multi="1"
-               id="wizard_results"/>
-
-               <wizard string="Map buyer username to Partners"
-               model="auction.lots"
-               name="auction.lots.buyer_map"
-               multi="1"
-               id="wizard_map_user"/>
-
-
-               <wizard string="Numerotation (per lot)"
-               model="auction.lots"
-               name="auction.lots.numerotate"
-               multi="1"
-               id="wizard_numerotate_lot"/>
-
-               <wizard string="Numerotation (automatic)"
-                model="auction.lots"
-                name="auction.lots.numerotate_cont"
-                multi="1"
-               id="wizard_numerotate_automatic"/>
-
-                       <wizard
-                       id="auction_catalog_flagy"
-                       string="Auction Catalog Flagey"
-                       model="auction.dates"
-                       name="auction.catalog.flagey"
-                       keyword="client_print_multi"/>
- -->
 
        </data>
 </openerp>
index f260f8b..1727d6a 100644 (file)
@@ -2,13 +2,6 @@
 
 <openerp>
     <data noupdate="1">
-<!--    <record model="ir.ui.view_sc" id="sc_auction_dash">-->
-<!--            <field name="name">Auction dashboard</field>-->
-<!--            <field name="user_id" ref="base.user_root"/>-->
-<!--            <field name="resource">ir.ui.menu</field>-->
-<!--            <field name="sequence">4</field>-->
-<!--            <field name="res_id" ref="menu_board_auction"/>-->
-<!--        </record>-->
 
     </data>
 </openerp>
index 8a183c2..8865550 100644 (file)
             <field name="view_type">form</field>
             <field name="view_mode">tree,form</field>
         </record>
-        
+
         <record model="ir.actions.act_window" id="action_report_latest_doposit_tree">
             <field name="res_model">auction.deposit</field>
             <field name="view_type">form</field>
             <field name="view_mode">tree,form</field>
-        </record>      
-        
+        </record>
+
         <record model="ir.ui.view" id="view_report_auction_estimation_adj_category_tree">
              <field name="name">report.auction.estimation.adj.category.tree</field>
             <field name="model">auction.lots</field>
             <field name="type">tree</field>
             <field name="arch" type="xml">
             <tree string="Min est/Adj/Max est">
-                <!--field name="date" select="1"/-->
                 <field name="create_uid" select="1"/>
                 <field name="lot_type" select="1"/>
                 <field name="lot_est1" select="1"/>
             </graph>
         </field>
     </record>
-    
+
     <record model="ir.actions.act_window" id="action_report_auction_lots_estimation_adj_category_tree">
         <field name="name">Min est/Adj/Max est</field>
         <field name="res_model">auction.lots</field>
         <field name="view_type">form</field>
         <field name="view_mode">graph,tree</field>
-    </record>  
+    </record>
 
         <record model="ir.ui.view" id="board_auction_form1">
             <field name="name">board.auction.form</field>
             <field name="usage">menu</field>
             <field name="view_id" ref="board_auction_form1"/>
         </record>
-        
+
         <menuitem name="Dashboard" id="menu_board_auction" parent="auction.auction_report_menu" sequence="0"/>
-        
+
         <menuitem
             name="Auction DashBoard"
             action="open_board_auction"
index feb96ce..10e3263 100644 (file)
@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 ##############################################################################
-#    
+#
 #    OpenERP, Open Source Management Solution
 #    Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
 #
 #    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/>.     
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #
 ##############################################################################
 
-#import flagey_huissier
 import total
 import auction_invoice
 import seller_address
@@ -38,8 +37,6 @@ import buyer_list
 
 import auction_catelog
 import auction_buyer_result
-#import auction_total_rml
-#import auction_report
 import auction_total_rml
 import deposit_seller
 import auction_artists
index 207107d..a0d3cec 100644 (file)
                        <mobile type="field" name="address.mobile"/>
                </client_info>
                <objects>
-<!--                   <cost type="call" name="compute_buyer_costs" args="">-->-->
                                <name value="name"/>
                                <amount value="amount"/>
-<!--                   </cost>-->
                        <object type="fields" name="obj_num,id">
                                <ref type="field" name="obj_num"/>
                                <title type="field" name="name"/>
index 5dfe5fe..2de9940 100644 (file)
@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 ##############################################################################
-#    
+#
 #    OpenERP, Open Source Management Solution
 #    Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
 #
@@ -15,7 +15,7 @@
 #    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/>.     
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #
 ##############################################################################
 
@@ -59,9 +59,6 @@ class buyer_form_report(report_sxw.rml_parse):
             else:
                 lots = partner.get('lots')
                 lots.append(object)
-#       buyer_ids=self.pool.get(auction.lots).read(cr,uid,lot)
-
-
         return ret_dict.values()
 
     def grand_buyer_total(self,o):
index 80df790..22b6ecb 100644 (file)
@@ -84,11 +84,6 @@ class auction_catalog(report_rml):
         auction_dates_pool = pooler.get_pool(cr.dbname).get('auction.dates')
         for auction in auction_dates_pool.browse(cr, uid, ids, context=context):
             auction_lot_ids = auction_lot_pool.search(cr, uid, [('auction_id', '=', auction.id)])
-            #for lot in auction_lot_pool.browse(cr, uid, auction_lot_ids, context=context):
-            #    ab=pooler.get_pool(cr.dbname).get('auction.lots').read(cr, uid, lot_ids, ['auction_id','name','lot_num','lot_est1','lot_est2'], context)
-            #auction_dates_ids = [x["auction_id"][0] for x in ab]
-
-            # name emelment
             key = 'name'
             categ = doc.createElement(key)
             categ.appendChild(doc.createTextNode(_to_decode(auction.name)))
index 94f7877..5c13806 100644 (file)
@@ -20,8 +20,6 @@
                                        <street2 type="field" name="street2"/>
                                        <postcode type="field" name="zip">2640</postcode>
                                        <city type="field" name="city">Mortsel</city>
-                                       <!--<state type="field" name="state"></state>-->
-                               <!--    <country type="field" name="country.name">Belgique</country>-->
                                </address>
                        </person>
                </deposit-to>
index ad8065b..2718e8b 100644 (file)
@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 ##############################################################################
-#    
+#
 #    OpenERP, Open Source Management Solution
 #    Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
 #
@@ -15,7 +15,7 @@
 #    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/>.     
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #
 ##############################################################################
 
@@ -42,10 +42,9 @@ class report_custom(report_rml):
         <name>%s</name>
         <date-au1>%s</date-au1>
     </auction>''' % (toxml(auction['name']), toxml(auction['auction1']))
-    
+
         i = 0
         for l in lots:
-#           l['id_cont'] = str(i)
             if l['obj_price']==0:
                 price_french = u'retiré'
             else:
@@ -59,7 +58,7 @@ class report_custom(report_rml):
         <obj_price>%s</obj_price>
     </object>''' % (i, l['obj_num'], ustr(toxml(l['name'])), ustr(price_french), ustr(l['obj_price'] or '/'))
         xml += '</report>'
-        
+
         return xml
 
 report_custom('report.flagey.huissier', 'auction.lots', '', 'addons/auction/report/huissier.xsl')
index 9ce346a..cf1c680 100644 (file)
@@ -34,11 +34,11 @@ def _type_get(self, cr, uid, context=None):
     obj = self.pool.get('auction.lot.category')
     ids = obj.search(cr, uid, [])
     res = obj.read(cr, uid, ids, ['name'], context)
-    res = [(r['name'], r['name']) for r in res]   
-    return res 
+    res = [(r['name'], r['name']) for r in res]
+    return res
 
 class report_auction(osv.osv):
-    
+
     """Auction Report"""
     _name = "report.auction"
     _description = "Auction's Summary"
@@ -49,22 +49,22 @@ class report_auction(osv.osv):
             ('05','May'), ('06','June'), ('07','July'), ('08','August'), ('09','September'),
             ('10','October'), ('11','November'), ('12','December')], 'Month',readonly=True),
         'day': fields.char('Day', size=128, readonly=True),
-        'buyer_login': fields.char('Buyer Login', size=64, readonly=True, select=1), 
-        'buyer':fields.many2one('res.partner', 'Buyer', readonly=True, select=2), 
+        'buyer_login': fields.char('Buyer Login', size=64, readonly=True, select=1),
+        'buyer':fields.many2one('res.partner', 'Buyer', readonly=True, select=2),
         'seller': fields.many2one('res.partner', 'Seller', readonly=True, select=1),
-        'object':fields.integer('No of objects', readonly=True, select=1), 
+        'object':fields.integer('No of objects', readonly=True, select=1),
         'total_price':fields.float('Total Price', digits=(16, 2), readonly=True, select=2),
-        'lot_type': fields.selection(_type_get, 'Object category', size=64), 
-        'avg_price':fields.float('Avg Price.', digits=(16, 2), readonly=True, select=2), 
+        'lot_type': fields.selection(_type_get, 'Object category', size=64),
+        'avg_price':fields.float('Avg Price.', digits=(16, 2), readonly=True, select=2),
         'date': fields.date('Create Date', select=1),
         'auction': fields.many2one('auction.dates', 'Auction date', readonly=True, select=1),
-        'gross_revenue':fields.float('Gross Revenue', readonly=True), 
-        'net_revenue':fields.float('Net Revenue', readonly=True), 
+        'gross_revenue':fields.float('Gross Revenue', readonly=True),
+        'net_revenue':fields.float('Net Revenue', readonly=True),
         'net_margin':fields.float('Net Margin', readonly=True),
         'avg_estimation':fields.float('Avg estimation', readonly=True),
         'user_id':fields.many2one('res.users', 'User', select=1),
         'state': fields.selection((('draft', 'Draft'), ('unsold', 'Unsold'), ('sold', 'Sold')), 'State', readonly=True, select=1),
-        
+
     }
 
     def init(self, cr):
@@ -125,7 +125,6 @@ class report_auction_object_date(osv.osv):
         'month': fields.date('Month', select=1),
         'user_id':fields.many2one('res.users', 'User',select=1),
     }
- #l.create_uid as user,
 
     def init(self, cr):
         cr.execute("""create or replace view report_auction_object_date as
@@ -213,6 +212,6 @@ class report_object_encoded(osv.osv):
             where al.obj_price>0
             group by to_char(al.create_date, 'YYYY-MM-DD'), al.state, al.create_uid)
              ''')
-        
+
 report_object_encoded()
 
index 686cb80..8153314 100644 (file)
@@ -1,7 +1,7 @@
 <?xml version="1.0"?>
 <openerp>
    <data>
-    
+
     <record model="ir.ui.view" id="view_report_auction_tree">
         <field name="name">Auction's Summary</field>
         <field name="model">report.auction</field>
@@ -29,7 +29,7 @@
             </tree>
         </field>
     </record>
-    
+
     <record id="view_report_auction_search" model="ir.ui.view">
         <field name="name">report.auction.search</field>
         <field name="model">report.auction</field>
@@ -55,7 +55,7 @@
                         domain="[('state','=','draft')]"/>
                     <filter icon="terp-dolar"
                         string="Sold"
-                        domain="[('state','=', 'sold')]"/>     
+                        domain="[('state','=', 'sold')]"/>
                     <separator orientation="vertical"/>
                     <field name="auction"/>
                     <field name="user_id" widget="selection">
@@ -89,7 +89,7 @@
             </search>
         </field>
     </record>
-    
+
     <record id="view_report_auction_graph" model="ir.ui.view">
          <field name="name">report.auction.graph</field>
          <field name="model">report.auction</field>
                 <field name="net_margin" operator="+"/>
              </graph>
          </field>
-    </record>    
-    
+    </record>
+
     <record model="ir.actions.act_window" id="action_report_auction">
         <field name="name">Auction Analysis</field>
         <field name="res_model">report.auction</field>
         <field name="view_type">form</field>
         <field name="view_mode">tree,graph</field>
-<!--        <field name="domain">[('date','ilike',time.strftime('%Y-%m'))]</field>-->
         <field name="search_view_id" ref="view_report_auction_search"/>
         <field name="context">{'search_default_month':1}</field>
     </record>
-    
-<!--    <menuitem name="Auction" id="auction_report_auction_menu" parent="auction.auction_report_menu"/>-->
+
     <menuitem name="Auction Analysis" action="action_report_auction" id="menu_report_auction" parent="auction.auction_report_menu"/>
 
 <!--end : creating buyer Reporting menu for the buyer by pmo-->
index 7e8af75..d033720 100644 (file)
@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 ##############################################################################
-#    
+#
 #    OpenERP, Open Source Management Solution
 #    Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
 #
@@ -15,7 +15,7 @@
 #    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/>.     
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #
 ##############################################################################
 
@@ -29,20 +29,12 @@ class seller_form_report(report_sxw.rml_parse):
     def __init__(self, cr, uid, name, context):
         super(seller_form_report, self).__init__(cr, uid, name, context=context)
         lot=self.pool.get('auction.lots').browse(cr, uid, uid)
-        #address=lot.bord_vnd_id.address_get(self.cr,self.uid,[partner.id])
-    #   partner=lot.bord_vnd_id.partner_id
-    #   address=partner.address and partner.address[0] or ""
-    #   street = address and address.street or ""
-
-
 
         self.localcontext.update({
             'time': time,
             'sum_taxes': self.sum_taxes,
             'sellerinfo' : self.seller_info,
             'grand_total' : self.grand_seller_total,
-    #       'street':street,
-    #       'address':address,
 })
 
 
@@ -69,7 +61,6 @@ class seller_form_report(report_sxw.rml_parse):
             else:
                 lots = partner.get('lots')
                 lots.append(object)
-#       buyer_ids=self.pool.get(auction.lots).read(cr,uid,lot)
         return ret_dict.values()
     def grand_seller_total(self,o):
         grand_total = 0
index fe6ce58..a5b937c 100644 (file)
@@ -38,14 +38,9 @@ class report_custom(report_rml):
     def create_xml(self, cr, uid, ids, datas, context={}):
         service = netsvc.LocalService("object_proxy")
 
-#       start_time = time.clock()
-
-#           lots = service.execute(cr.dbname,uid, 'auction.lots', 'read', ids, ['obj_price','ach_pay_id','ach_login','obj_comm','lot_est1','lot_est2','bord_vnd_id','ach_emp','auction_id'])
         lots = service.execute(cr.dbname, uid, 'auction.lots', 'read', ids, ['obj_price','ach_login','obj_comm','lot_est1','lot_est2','bord_vnd_id','ach_emp','auction_id'])
         auction = service.execute(cr.dbname, uid, 'auction.dates', 'read', [lots[0]['auction_id'][0]])[0]
 
-#       mid_time = time.clock()
-
         unsold = comm = emp = paid = unpaid = 0
         est1 = est2 = adj = 0
         paid_ids = []
@@ -83,24 +78,12 @@ class report_custom(report_rml):
             buyer[l['ach_login']]=1
             seller[l['bord_vnd_id']]=1
 
-#       mid_time2 = time.clock()
-
-#       costs = service.execute(cr.dbname,uid, 'auction.lots', 'compute_buyer_costs', paid_ids)
-#       for cost in costs:
-#           paid += cost['amount']
-#
-#       costs = service.execute(cr.dbname,uid, 'auction.lots', 'compute_buyer_costs', unpaid_ids)
-#       for cost in costs:
-#           unpaid += cost['amount']
-
-#       mid_time3 = time.clock()
 
         debit = adj
         costs = service.execute(cr.dbname, uid, 'auction.lots', 'compute_seller_costs', ids)
         for cost in costs:
             debit += cost['amount']
 
-#       mid_time4 = time.clock()
 
         xml = '''<?xml version="1.0" encoding="ISO-8859-1"?>
 <report>
@@ -130,8 +113,6 @@ class report_custom(report_rml):
     </seller>
 </report>''' % (time.strftime('%d/%m/%Y'), toxml(auction['name']), auction['auction1'], len(lots), est1, est2, unsold, adj, len(buyer), len(paid_ids), comm, emp, unpaid, paid, len(seller), debit)
 
-#       file('/tmp/terp.xml','wb+').write(xml)
-#       end_time = time.clock()
         return self.post_process_xml_data(cr, uid, xml, context)
 
 report_custom('report.auction.total', 'auction.lots', '', 'addons/auction/report/total.xsl')
index 8eb3922..f11c938 100644 (file)
@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 ##############################################################################
-#    
+#
 #    OpenERP, Open Source Management Solution
 #    Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
 #
@@ -15,7 +15,7 @@
 #    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/>.     
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #
 ##############################################################################
 
@@ -141,8 +141,6 @@ class auction_lots_send_aie(osv.osv_memory):
     def _photos_send(cr, uid, uname, passwd, did, ids):
         service = netsvc.LocalService("object_proxy")
         for (ref,id) in ids:
-            
-    #       ids_attach = service.execute(db_name,uid, 'ir.attachment', 'search', [('res_model','=','auction.lots'), ('res_id', '=',id)])
             datas = service.execute(cr.db_name, uid, 'auction.lots', 'read', [id], ['name','image'])
             if len(datas):
                 bin = base64.decodestring(datas[0]['image'])
index a9351d5..cb19f65 100644 (file)
@@ -32,7 +32,7 @@ class auction_lots_auction_move(osv.osv_memory):
     _name = "auction.lots.auction.move"
     _description = __doc__
     _columns= {
-        'auction_id':fields.many2one('auction.dates', 'Auction Date', required=True), 
+        'auction_id':fields.many2one('auction.dates', 'Auction Date', required=True),
     }
 
     def auction_move_set(self, cr, uid, ids, context=None):
@@ -53,24 +53,22 @@ class auction_lots_auction_move(osv.osv_memory):
         for current in self.browse(cr, uid, ids, context):
             if not (current.auction_id and len(context.get('active_ids', []))):
                 return {}
-            
-#           line_ids = auction_bid_line_obj.search(cr, uid, [('lot_id', 'in', context['active_ids'])])
-#           pooler.get_pool(cr.dbname).get('auction.bid_line').unlink(cr, uid, line_ids)
+
             for rec in rec_ids:
                 new_id = auction_lot_history_obj.create(cr, uid, {
-                    'auction_id': rec.auction_id.id, 
-                    'lot_id': rec.id, 
+                    'auction_id': rec.auction_id.id,
+                    'lot_id': rec.id,
                     'price': rec.obj_ret
                     })
                 up_auction = auction_lots_obj.write(cr, uid, [rec.id], {
-                    'auction_id': current.auction_id.id, 
-                    'obj_ret': None, 
-                    'obj_price': None, 
-                    'ach_login': None, 
-                    'ach_uid': None, 
-                    'ach_inv_id': None, 
-                    'sel_inv_id': None, 
-                    'obj_num': None, 
+                    'auction_id': current.auction_id.id,
+                    'obj_ret': None,
+                    'obj_price': None,
+                    'ach_login': None,
+                    'ach_uid': None,
+                    'ach_inv_id': None,
+                    'sel_inv_id': None,
+                    'obj_num': None,
                     'state': 'draft'})
             return {}
 
index 999db10..89d66f5 100644 (file)
@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 ##############################################################################
-#    
+#
 #    OpenERP, Open Source Management Solution
 #    Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
 #
@@ -15,7 +15,7 @@
 #    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/>.     
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #
 ##############################################################################
 
@@ -26,7 +26,7 @@ from tools.translate import _
 class auction_lots_invoice(osv.osv_memory):
     _name = 'auction.lots.invoice'
     _description = "Auction Lots Invoice"
-    
+
     _columns = {
         'amount': fields.float('Invoiced Amount', required=True, readonly=True),
         'amount_topay': fields.float('Amount to pay', required=True, readonly=True),
@@ -34,39 +34,33 @@ class auction_lots_invoice(osv.osv_memory):
         'objects': fields.integer('# of objects', required=True, readonly=True),
         'ach_uid': fields.many2one('res.partner','Buyer Name', required=True ),
         'number': fields.integer('Invoice Number'),
-#        'tax_applied':{'string':'Tax Applied', 'type':'float', 'readonly':True},
     }
 
     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. 
+         @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(auction_lots_invoice, self).default_get(cr, uid, fields, context=context)
         service = netsvc.LocalService("object_proxy")
         lots = service.execute(cr.dbname, uid, 'auction.lots', 'read', context.get('active_ids', []))
         auction = service.execute(cr.dbname, uid, 'auction.dates', 'read', [lots[0]['auction_id'][0]])[0]
-    
+
         price = 0.0
         price_topay = 0.0
         price_paid = 0.0
-        #tax=data['form']['tax_applied']
-#        uid = False
         for lot in lots:
             price_lot = lot['obj_price'] or 0.0
-            
+
             costs = service.execute(cr.dbname, uid, 'auction.lots', 'compute_buyer_costs', [lot['id']])
             price_lot += costs['amount']
-#            for cost in costs:
-#                price_lot += cost['amount']
-    
             price += price_lot
-    
+
             if lot['ach_uid']:
                 if uid and (lot['ach_uid'][0]<>uid):
                     raise osv.except_osv(_('UserError'), _('Two different buyers for the same invoice !\nPlease correct this problem before invoicing'))
@@ -81,7 +75,7 @@ class auction_lots_invoice(osv.osv_memory):
             else:
                 price_topay += price_lot
                 #*tax
-    
+
     #TODO: recuperer id next invoice (de la sequence)???
         invoice_number = False
         for lot in self.pool.get('auction.lots').browse(cr, uid, context.get('active_ids', [])):
@@ -106,19 +100,18 @@ class auction_lots_invoice(osv.osv_memory):
         @param uid: the current user’s ID for security checks.
         @param ids: List of Auction lots make invoice buyer’s IDs
         @return: dictionary of  account invoice form.
-        """ 
+        """
         service = netsvc.LocalService("object_proxy")
         datas = {'ids' : context.get('active_ids',[])}
         res = self.read(cr, uid, ids, ['number','ach_uid'])
-        res = res and res[0] or {}        
+        res = res and res[0] or {}
         datas['form'] = res
-#        service.execute(cr.dbname, uid, 'auction.lots', 'lots_invoice_and_cancel_old_invoice', datas['ids'], datas['form']['number'], datas['form']['ach_uid'], 'invoice_open')
         return {
             'type' : 'ir.actions.report.xml',
             'report_name':'auction.invoice',
-            'datas' : datas, 
+            'datas' : datas,
         }
-        
+
 auction_lots_invoice()
 
 # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
index 711cb8d..a6444f8 100644 (file)
@@ -25,23 +25,23 @@ import tools
 class auction_pay_sel(osv.osv_memory):
     _name = "auction.pay.sel"
     _description = "Pay Invoice"
-    
+
     _columns= {
-       'amount': fields.float('Amount paid', digits= (16, 2), required=True), 
-       'dest_account_id':fields.many2one('account.account', 'Payment to Account', required=True, domain= [('type', '=', 'cash')]), 
-       'journal_id':fields.many2one('account.journal', 'Journal', required=True), 
-       'period_id':fields.many2one('account.period', 'Period', required=True), 
+       'amount': fields.float('Amount paid', digits= (16, 2), required=True),
+       'dest_account_id':fields.many2one('account.account', 'Payment to Account', required=True, domain= [('type', '=', 'cash')]),
+       'journal_id':fields.many2one('account.journal', 'Journal', required=True),
+       'period_id':fields.many2one('account.period', 'Period', required=True),
     }
-    
+
     def pay_and_reconcile(self, cr, uid, ids, context):
         """
         Pay and Reconcile
         @param cr: the current row, from the database cursor.
         @param uid: the current user’s ID for security checks.
         @param ids: the ID or list of IDs
-        @param context: A standard dictionary 
-        @return: 
-        """          
+        @param context: A standard dictionary
+        @return:
+        """
         lot = self.pool.get('auction.lots').browse(cr, uid, context['active_id'], context)
         invoice_obj = self.pool.get('account.invoice')
         for datas in self.read(cr, uid, ids):
@@ -50,7 +50,6 @@ class auction_pay_sel(osv.osv_memory):
             journal_id = datas.get('journal_id', False)
             if lot.sel_inv_id:
                 p = invoice_obj.pay_and_reconcile(['lot.sel_inv_id.id'], datas['amount'], datas['dest_account_id'], journal_id, account_id, period_id, journal_id, context)
-        #   lots.sel_inv_id.pay_and_reconcile(cr,uid,data[id], form['amount'], form['dest_account_id'], journal_id, account_id, period_id, journal_id, context)
             return {}
-    
+
 auction_pay_sel()
index 3a56f15..e08fc0f 100644 (file)
@@ -146,7 +146,6 @@ class audittrail_log(osv.osv):
 
     _columns = {
         "name": fields.char("Resource Name",size=64),
-   #     "name": fields.function(_name_get_resname, type='char', string='Resource Name', method=True),
         "object_id": fields.many2one('ir.model', 'Object'),
         "user_id": fields.many2one('res.users', 'User'),
         "method": fields.char("Method", size=64),
index aa26c8c..f1329b5 100644 (file)
@@ -23,7 +23,7 @@ from osv import fields, osv
 import time
 
 class audittrail_view_log(osv.osv_memory):
-    
+
     _name = "audittrail.view.log"
     _description = "View Log"
     _columns = {
@@ -33,7 +33,7 @@ class audittrail_view_log(osv.osv_memory):
     _defaults = {
              'to': lambda *a: time.strftime("%Y-%m-%d %H:%M:%S"),
            }
-    
+
     def log_open_window(self, cr, uid, ids, context=None):
         """
         Open Log  form from given date range..
@@ -44,26 +44,23 @@ class audittrail_view_log(osv.osv_memory):
         """
         if not context:
             context = {}
-            
+
         mod_obj = self.pool.get('ir.model.data')
         act_obj = self.pool.get('ir.actions.act_window')
         result = mod_obj._get_id(cr, uid, 'audittrail', 'action_audittrail_log_tree')
         id = mod_obj.read(cr, uid, [result], ['res_id'])[0]['res_id']
         result = act_obj.read(cr, uid, [id])[0]
-        #log_obj = self.pool.get(result['res_model'])
-        #log_id = log_obj.search(cr, uid, [])
-        #log_model = log_obj.read(cr, uid, log_id, ['object_id'])  
 
-        #start Loop 
+        #start Loop
         for datas in self.read(cr, uid, ids):
             if not datas.get('from', None):
                 if  datas.get('to') <> time.strftime("%Y-%m-%d %H:%M:%S"):
-                    result['domain'] = str([('timestamp', '<', datas.get('to'))])                
+                    result['domain'] = str([('timestamp', '<', datas.get('to'))])
                 else:
                     pass
             else:
                 result['domain'] = str([('timestamp', '>', datas.get('from', None)), ('timestamp', '<', datas.get('to'))])
-        #End Loop        
+        #End Loop
         return result
 
 audittrail_view_log()
index 694b89f..d436f67 100644 (file)
@@ -1268,8 +1268,6 @@ true, it will allow you to hide the event alarm information without removing it.
                     break
                 event_date = datetime.strptime(data['date'], "%Y-%m-%d %H:%M:%S")
 #                To check: If the start date is replace by event date .. the event date will be changed by that of calendar code
-#                if start_date and start_date <= event_date:
-#                        start_date = event_date
                 start_date = event_date
                 if not data['rrule']:
                     if start_date and (event_date < start_date):
@@ -1822,7 +1820,6 @@ class res_users(osv.osv):
                     ('state', '=', 'accepted'), ('user_id', 'in', ids)
                     ])
 
-       # result = cr.dictfetchall()
         for attendee_data in attendee_obj.read(cr, uid, attendee_ids, ['user_id']):
             user_id = attendee_data['user_id']
             status = 'busy'
index f8d28ab..876905c 100644 (file)
@@ -37,7 +37,6 @@
                </record>
 
                <record id="process_node_function0" model="process.node">
-<!--                   <field name="menu_id" ref="base_contact.menu_action_res_partner_job"/>-->
                        <field name="model_id" ref="base_contact.model_res_partner_job"/>
                        <field eval="&quot;&quot;&quot;state&quot;&quot;&quot;" name="kind"/>
                        <field eval="&quot;&quot;&quot;Jobs at a same partner address.&quot;&quot;&quot;" name="note"/>
index fafa906..c7671a6 100755 (executable)
@@ -53,7 +53,6 @@ class module(osv.osv):
         res = {}
         for rel in relations:
             # if we have to display the string along with field name then uncomment the first line n comment the second line
-            # res.setdefault(rel[0], set()).add(rel[1]+'('+rel[4]+')')
             res.setdefault(rel[0], set()).add(rel[1])
             res.setdefault(rel[3], set())
         val = []
@@ -102,8 +101,6 @@ class module(osv.osv):
         object_ids = self._get_module_objects(cr, uid, module_name, context=context)
         if not object_ids:
             return {'module_file': False}
-#            raise orm.except_orm(_('Warning'),
-#                 _('No object available on this module or Module is not installed'))
         context.update({'level': 1})
         dots = self.get_graphical_representation(cr, uid, object_ids, context=context)
         # todo: use os.realpath
@@ -123,56 +120,6 @@ class module(osv.osv):
 
 module()
 
-#class report_graph_instance(object):
-#    def __init__(self, cr, uid, ids, data):
-#        print "data", data
-#        self.done = False
-#
-#        graph = pydot.Dot(fontsize=16, label="")
-#
-#        ps_string = graph.create_ps(prog='dot')
-#        if os.name == 'nt':
-#            prog = 'ps2pdf.bat'
-#        else:
-#            prog = 'ps2pdf'
-#
-#        args = (prog, '-', '-')
-#        try:
-#            input, output = tools.exec_command_pipe(*args)
-#        except:
-#            return
-#
-#        input.write(ps_string)
-#        input.close()
-#
-#        self.result = output.read()
-#        output.close()
-#        self.done = True
-#
-#    def is_done(self):
-#        return self.done
-#
-#    def get(self):
-#        if self.done:
-#            return self.result
-#        else:
-#            return False
-#
-#class report_graph(report.interface.report_int):
-#    def init__(self, name, table):
-#        super(report_graph, self).__init__(name)
-#
-#    def result(self):
-#        if self.obj.is_done():
-#            return (True, self.obj.get(), 'pdf')
-#        else:
-#            return (False, False, False)
-#
-#    def create(self, cr, uid, ids, data, context=None):
-#        self.obj = report_graph_instance(cr, uid, ids, data)
-#        return (self.obj.get(), 'pdf')
-#
-#report_graph('report.ir.model.graph')
 
 # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
 
index 10f5d28..6f3db7e 100644 (file)
@@ -37,9 +37,6 @@ class report_graph(report.interface.report_int):
             module_record = module_obj.browse(cr, uid, module_id, context=context)
             if module_record.name not in nodes:
                 # Add new field ir.module.module object in server side. field name = module_type/
-#                if module_record.module_type:
-#                    nodes.append((module_record.name, module_record.module_type))
-#                else:
                 nodes.append((module_record.name, "unknown"))
             if module_record.dependencies_id:
                 for depen in module_record.dependencies_id:
index 327367e..02561c6 100644 (file)
@@ -282,9 +282,6 @@ class RstDoc(object):
                        title,
                        '#' * len(title),
                        "",
-                       #".. index::",
-                       #"  single: %s object" % (obj_name),
-                       #".. ",
                       ]
 
                 for field in obj['fields']:
@@ -292,11 +289,6 @@ class RstDoc(object):
                            "",
                            write_field(field),
                            "",
-                           #".. index::",
-                           #"  single: %s field" % (field[0]),
-                           #".. ",
-                           #"",
-                           #"",
                           ]
                     slo.extend(slf)
                 sl.extend(slo)
@@ -499,11 +491,6 @@ class wizard_tech_guide_rst(wizard.interface):
             logger.notifyChannel("base_module_doc_rst", netsvc.LOG_ERROR, msg)
             return ""
 
-##     def _object_doc(self, cr, uid, obj):
-##         pool = pooler.get_pool(cr.dbname)
-##         modobj = pool.get(obj)
-##         return modobj.__doc__
-
     states = {
         'init': {
             'actions': [_generate],
index d6d67d4..c19bd37 100644 (file)
@@ -95,7 +95,6 @@ class abstract_quality_check(object):
                 x_file = getattr(x_module, item)
                 x_obj = getattr(x_file, item)
                 self.tests.append(x_obj)
-#        raise 'Not Implemented'
 
     def run_test(self, cr, uid, module_path=""):
         '''
@@ -211,7 +210,6 @@ class module_quality_check(osv.osv):
                          ..........]}
         So here the detail result is in html format and summary will be in text_wiki format.
         '''
-        #list_folders = os.listdir(config['addons_path']+'/base_module_quality/')
         pool = pooler.get_pool(cr.dbname)
         obj_module = pool.get('ir.module.module')
         if not module_state:
index 12400db..dfae53f 100644 (file)
@@ -64,21 +64,12 @@ class quality_test(base_module_quality.abstract_quality_check):
                     self.result += _("Error. Is pylint correctly installed? (http://pypi.python.org/pypi/pylint)")+"\n"
                     return None
                 count += 1
-#                leftchar = -1
-#                while res[leftchar:leftchar+1] != ' ' and leftchar-1 <= 0:
-#                    leftchar -= 1
-#                rightchar = -10
-#                while res[rightchar:rightchar+1] != '/' and rightchar+1 <= 0:
-#                    rightchar += 1
                 try:
-#                    score += float(res[leftchar+1:rightchar])
                     scr = res.split("Your code has been rated at")[1].split("</div>")[0].split("/")[0]
                     score += float(scr)
-                    #self.result += file + ": " + res[leftchar+1:rightchar] + "/10\n"
                     dict_py[file_py] = [file_py, scr]
                 except:
                     score += 0
-                    #self.result += file + ": "+_("Unable to parse the result. Check the details.")+"\n"
                     dict_py[file_py] = [file_py, _("Unable to parse the result. Check the details.")]
                 replace_string = ''
                 replace_string += res
index 10b80aa..2238d5f 100644 (file)
@@ -50,7 +50,6 @@ This test checks if the module satisfy tiny structure
         f_list = []
         module_dict = {}
         module_dict['module'] = []
-#        count = 0
         final_score = 0.0
 
         if not module_name.islower():
@@ -67,7 +66,6 @@ This test checks if the module satisfy tiny structure
                 elif file_struct == 'process' and os.path.isdir(path):
                     module_dict[file_struct] = []
                 elif file_struct != 'i18n' and os.path.isdir(path):
-#                    self.counter += 1
                     self.run_test(cr, uid, path)
                 module_dict['module'].append(file_struct)
                 f_list.append(file_struct)
index 3ba79ba..bb2379b 100644 (file)
@@ -34,7 +34,7 @@ class report_creator(osv.osv):
     # Should request only used fields
     #
     def export_data(self, cr, uid, ids, fields_to_export, context=None):
-        
+
         if context is None:
             context = {}
         data_l = self.read(cr, uid, ids, ['sql_query'], context)
@@ -52,7 +52,7 @@ class report_creator(osv.osv):
             final_datas += [datas]
             #End Loop
         return {'datas': final_datas}
-        
+
     def fields_get(self, cr, user, fields=None, context=None):
         """
         Get Fields.
@@ -63,7 +63,7 @@ class report_creator(osv.osv):
         """
         if context is None:
             context = {}
-            
+
         data = context and context.get('report_id', False) or False
         if (not context) or 'report_id' not in context:
             return super(report_creator, self).fields_get(cr, user, fields, context)
@@ -82,7 +82,7 @@ class report_creator(osv.osv):
                     i += 1
                 else:
                     fields['column_count'] = {'readonly': True, 'type': 'integer', 'string': 'Count', 'size': 64, 'name': 'column_count'}
-              
+
             return fields
 
     #
@@ -97,7 +97,7 @@ class report_creator(osv.osv):
         """
         if context is None:
             context = {}
-          
+
         data = context and context.get('report_id', False) or False
         if (not context) or 'report_id' not in context:
             return super(report_creator, self).fields_view_get(cr, user, view_id, view_type, context, toolbar=toolbar, submenu=submenu)
@@ -113,7 +113,7 @@ class report_creator(osv.osv):
                 i += 1
             else:
                 fields['column_count'] = {'readonly': True, 'type': 'integer', 'string': 'Count', 'size': 64, 'name': 'column_count'}
-            
+
         arch = '<?xml version="1.0"?>'
         if view_type == 'graph':
             orientation_eval = {'horz':'horizontal','vert' :'vertical'}
@@ -128,7 +128,7 @@ class report_creator(osv.osv):
                             i += 1
                         else:
                             arch += '<field name="%s" select="1"/>' % ('column_count',)
-                    
+
         elif view_type == 'calendar':
             required_types = ['date_start', 'date_delay', 'color']
             set_dict = {'view_type':view_type, 'string':report.name}
@@ -141,7 +141,7 @@ class report_creator(osv.osv):
                         i += 1
                     else:
                         field_cal = 'column_count'
-                    set_dict[f.calendar_mode] = field_cal   
+                    set_dict[f.calendar_mode] = field_cal
                     del required_types[required_types.index(f.calendar_mode)]
 
                 else:
@@ -149,8 +149,8 @@ class report_creator(osv.osv):
                         temp_list.append('''<field name = "%(name)s" select = "1"/>''' % {'name': 'field' + str(i)})
                         i += 1
                     else:
-                        temp_list.append('''<field name="%(name)s" select="1"/>''' % {'name':'column_count'})    
-                    
+                        temp_list.append('''<field name="%(name)s" select="1"/>''' % {'name':'column_count'})
+
             arch += '''<% (view_type)s string = "%(string)s" date_start = "%(date_start)s" ''' % set_dict
             if set_dict.get('date_delay', False):
                 arch += ''' date_delay = "%(date_delay)s"  ''' % set_dict
@@ -217,7 +217,7 @@ class report_creator(osv.osv):
                             continue
                         related_name = self.pool.get(field_dict.get('relation')).name_get(cr, user, [r[k]], context)[0]
                         r[k] = related_name
-            
+
             return res
 
     def search(self, cr, user, args, offset=0, limit=None, order=None, context=None, count=False):
@@ -226,12 +226,12 @@ class report_creator(osv.osv):
         @param cr: the current row, from the database cursor,
         @param user: the current user’s ID for security checks,
         @param args: list of tuples of form [(‘name_of_the_field’, â€˜operator’, value), ...].
-        @return: List of id 
+        @return: List of id
         """
         if context is None:
             context = {}
         context_id = context.get('report_id', False)
-        
+
         if (not context) or 'report_id' not in context:
             return super(report_creator, self).search(cr, user, args, offset, limit, order, context, count)
         if context_id:
@@ -243,7 +243,7 @@ class report_creator(osv.osv):
                     fields['field'+str(i)] = (f.field_id.model, f.field_id.name)
                     i += 1
                 else:
-                    fields['column_count'] = (False, 'Count')   
+                    fields['column_count'] = (False, 'Count')
             newargs = []
             newargs2 = []
             for a in args:
@@ -274,7 +274,7 @@ class report_creator(osv.osv):
         filter_list = []
         for model in models:
             model_dict[model.model] = self.pool.get(model.model)._table
-        
+
         model_list = model_dict.keys()
         reference_model_dict = {}
         for model in model_dict:
@@ -284,7 +284,7 @@ class report_creator(osv.osv):
             model_pool = self.pool.get(model)
             fields_get = model_pool.fields_get(cr, uid)
             model_columns = {}
-            
+
             def _get_inherit_fields(obj):
                 pool_model = self.pool.get(obj)
                 #Adding the columns of the model itself
@@ -293,11 +293,11 @@ class report_creator(osv.osv):
                 for record in pool_model._inherits.keys():
                     _get_inherit_fields(record)
 
-            _get_inherit_fields(model)         
-            
-            fields_filter = dict(filter(lambda x:x[1].get('relation', False) 
-                                        and x[1].get('relation') in rest_list 
-                                        and x[1].get('type') == 'many2one' 
+            _get_inherit_fields(model)
+
+            fields_filter = dict(filter(lambda x:x[1].get('relation', False)
+                                        and x[1].get('relation') in rest_list
+                                        and x[1].get('type') == 'many2one'
                                         and not (isinstance(model_columns[x[0]], fields.function) or isinstance(model_columns[x[0]], fields.related)), fields_get.items()))
             if fields_filter:
                 model in model_list and model_list.remove(model)
@@ -316,7 +316,7 @@ class report_creator(osv.osv):
                 if k in self.pool.get(model)._columns:
                     str_where = model_dict.get(model)+"."+ k + "=" + model_dict.get(v.get('relation'))+'.id'
                     where_list.append(str_where)
-                    
+
         if reference_model_dict:
             self.model_set_id = model_dict.get(reference_model_dict.keys()[reference_model_dict.values().index(min(reference_model_dict.values()))])
         if model_list and not len(model_dict.keys()) == 1:
@@ -348,20 +348,19 @@ class report_creator(osv.osv):
             if ret_str.endswith('or'):
                 ret_str = ret_str[0:len(ret_str)-2]
             ret_str = ret_str.strip()
-       
+
         return ret_str % {'uid': uid}
 
     def _id_get(self, cr, uid, id, context):
         """
         Get Model id
         """
-#       return 'min(sale_order_line.id)'
         return self.model_set_id and 'min('+self.model_set_id+'.id)'
 
     def _sql_query_get(self, cr, uid, ids, prop, unknow_none, context, where_plus=[], limit=None, offset=None):
         """
         Get sql query which return on sql_query field.
-        @return: Dictionary of sql query. 
+        @return: Dictionary of sql query.
         """
         result = {}
         for obj in self.browse(cr, uid, ids):
@@ -379,7 +378,7 @@ class report_creator(osv.osv):
                     groupby.append(t+'.'+f.field_id.name)
                 else:
                     fields.append('\t'+f.group_method+'('+t+'.'+f.field_id.name+')'+' as field'+str(i))
-                    
+
                 i += 1
             models = self._path_get(cr, uid, obj.model_ids, obj.filter_ids)
             check = self._id_get(cr, uid, ids[0], context)
@@ -458,7 +457,7 @@ class report_creator(osv.osv):
         rep = self.browse(cr, uid, ids, context=context)
         if not rep:
             return False
-        
+
         rep = rep[0]
         view_mode = rep.view_type1
         if rep.view_type2:
@@ -500,15 +499,15 @@ class report_creator(osv.osv):
 
     def _aggregation_error(self, cr, uid, ids):
         """
-        constraints function which specify that 
+        constraints function which specify that
                 aggregate function to the non calculated field..
         @param cr: the current row, from the database cursor,
         @param uid: the current user’s ID for security checks,
-        @param ids: List of Report creator's id.       
+        @param ids: List of Report creator's id.
         @return: True if model colume type is in integer or float.
                      or false model colume type is not in integer or float.
         """
-        
+
         aggregate_columns = ('integer', 'float')
         apply_functions = ('sum', 'min', 'max', 'avg', 'count')
         this_objs = self.browse(cr, uid, ids)
@@ -517,13 +516,12 @@ class report_creator(osv.osv):
                 # Allowing to use count(*)
                 if not fld.field_id.model and fld.group_method == 'count':
                     continue
-                model_column = self.pool.get(fld.field_id.model)._columns[fld.field_id.name]                
+                model_column = self.pool.get(fld.field_id.model)._columns[fld.field_id.name]
                 if model_column._type not in aggregate_columns and fld.group_method in apply_functions:
                     return False
         return True
 
     def _calander_view_error(self, cr, uid, ids):
-#       required_types = ['date_start','date_delay','color']
         required_types = []
         this_objs = self.browse(cr, uid, ids)
         for obj in this_objs:
index 064e542..dc7c977 100644 (file)
@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 ##############################################################################
-#    
+#
 #    OpenERP, Open Source Management Solution
 #    Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
 #
@@ -15,7 +15,7 @@
 #    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/>.     
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #
 ##############################################################################
 
@@ -62,11 +62,11 @@ def _set_field_domain(self,cr,uid,data,context):
     this_model = data.get('model')
     this_pooler = pooler.get_pool(cr.dbname).get(this_model)
     this_data = this_pooler.read(cr,uid,data.get('ids'),['model_ids'],context)[0]
-    select_field_fields['field_id']['domain'] = [('model_id','in',this_data.get('model_ids')),('ttype','<>','many2many'),('ttype','<>','one2many')] 
+    select_field_fields['field_id']['domain'] = [('model_id','in',this_data.get('model_ids')),('ttype','<>','many2many'),('ttype','<>','one2many')]
     return {'field_id':False}
 
 def set_field_operator(self,field_name,field_type,search_operator,search_value):
-        field_search = [field_name,search_operator,search_value]        
+        field_search = [field_name,search_operator,search_value]
         if search_operator == '=':
             if field_type=='many2one':
                 field_search[1]='in'
@@ -132,7 +132,7 @@ def _set_filter_value(self, cr, uid, data, context):
 
         if field_type in ['float','integer']:
             value_data =  value_data or 0
-        
+
         if field_type == 'many2many' and value_data and len(value_data):
             fields_list = set_field_operator(self,table_name+"."+field_data['name'],field_data['ttype'],form_data['operator'],value_data[0][2])
         else:
@@ -145,9 +145,6 @@ def _set_filter_value(self, cr, uid, data, context):
                            'condition' : form_data['condition']
                            }
             pooler.get_pool(cr.dbname).get('base_report_creator.report.filter').create(cr,uid,create_dict,context)
-        #end if field_type == 'many2many' and value_data and len(value_data):
-#       pooler.get_pool(cr.dbname).get('custom.report.filter').create(cr,uid,form_data)
-    #end if field_type:
     return {}
 
 def _set_form_value(self, cr, uid, data, context):
@@ -155,8 +152,6 @@ def _set_form_value(self, cr, uid, data, context):
     field_data = pooler.get_pool(cr.dbname).get('ir.model.fields').read(cr,uid,[field_id])[0]
     fields_dict = pooler.get_pool(cr.dbname).get(field_data.get('model')).fields_get(cr,uid,fields=[field_data.get('name')])
     value_field = set_value_fields.get('value')
-#   print "fields_dict :",fields_dict.get(field_data.get('name'))
-#   set_value_fields['value']= fields_dict.get(field_data.get('name'))
     for k,v in value_field.items():
         if k in ('size','relation','type'):
             del value_field[k]
@@ -170,15 +165,15 @@ def _set_form_value(self, cr, uid, data, context):
             selection_data = pooler.get_pool(cr.dbname).get(field_data['model']).fields_get(cr,uid,[field_data['name']])
             value_field['selection'] = selection_data.get(field_data['name']).get('selection')
     operator = (field_type=='many2one') and 'in' or '='
-    ret_dict={'field_id':field_id,'operator':operator, 'condition':'and','value':False}  
+    ret_dict={'field_id':field_id,'operator':operator, 'condition':'and','value':False}
     return ret_dict
 
 def _set_operator(self, cr, uid, data, context):
     field = pooler.get_pool(cr.dbname).get('ir.model.fields').browse(cr, uid, data['form']['field_id'])
     operator = set_value_fields['operator']['selection']
-    while operator: 
+    while operator:
         operator.pop(operator.__len__()-1)
-        
+
     if field.ttype == 'many2one':
         operator.append(('in','Equals'))
         operator.append(('in','Contains'))
@@ -210,7 +205,7 @@ class set_filter_fields(wizard.interface):
     states = {
         'init': {
             'actions': [_set_field_domain],
-            'result': {'type':'form', 'arch':select_field_form, 'fields':select_field_fields, 'state':[('end','Cancel'),('set_value_select_field','Continue')]}         
+            'result': {'type':'form', 'arch':select_field_form, 'fields':select_field_fields, 'state':[('end','Cancel'),('set_value_select_field','Continue')]}
         },
         'set_value_select_field':{
             'actions': [_set_form_value, _set_operator],
index 661ea44..1a29324 100644 (file)
@@ -290,8 +290,6 @@ class PyOpenOffice(object):
     def oo_replace(self,content):
         regex = [
             (r"<para[^>]*/>", ""),
-            #(r"<text:ordered-list.*?>(.*?)</text:ordered-list>", "$1"),
-            #(r"<text:unordered-list.*?>(.*?)</text:unordered-list>", "$1"),
             (r"<para(.*)>(.*?)<text:line-break[^>]*/>", "<para$1>$2</para><para$1>"),
         ]
         for key,val in regex:
index fbee18b..236a62c 100644 (file)
@@ -44,7 +44,6 @@
     'update_xml': ['security/ir.model.access.csv',
                    'base_setup_installer.xml',
                    'base_setup_todo.xml',
-#                   'gtk_contact_form.xml'
                    ],
     'demo_xml': ['base_setup_demo.xml'],
     'installable': True,
index ce0b4a7..39f923a 100644 (file)
@@ -1,10 +1,6 @@
 <?xml version="1.0" encoding="utf-8"?>
 <openerp>
     <data noupdate="1">
-        <!-- TODO:  Remove comment after fixing bug #527050-->
-<!--        <record id="base.user_demo" model="res.users">-->
-<!--            <field name="action_id" ref="action_base_setup"/>-->
-<!--        </record>-->
-        
+
     </data>
 </openerp>
index ceb915e..a4b4b2b 100644 (file)
@@ -37,7 +37,6 @@
                 </group>
                 <newline/>
                 <group colspan="2" groups="base.group_extended" >
-<!--                    <separator string="Report Information" colspan="4" />-->
                     <field name="rml_header1" colspan="5" invisible="1"/>
                     <field name="rml_footer1" colspan="5" invisible="1"/>
                     <field name="rml_footer2" colspan="5" invisible="1"/>
index 04a20a6..5f29325 100644 (file)
@@ -160,8 +160,6 @@ class res_currency(osv.osv):
             context = {}
 #        We can use the following line,if we want to restrict this name_get for company setup only
 #        But, its better to show currencies as name(Code).
-#        if not (context.get('active_model','') == 'ir.actions.todo'):
-#            return super(res_currency,self).name_get(cr, uid, ids, context=context)
         if not len(ids):
             return []
         if isinstance(ids, (int, long)):
index 5cba9ea..8480b05 100644 (file)
@@ -151,10 +151,6 @@ class res_partner(osv.osv):
         check = 11 - (sum % 11)
         if check == 11:
             check = 0
-#        if check == 10:
-#            return False
-#        if check != int(vat[9]):
-#            return False
         return True
 
     def check_vat_cy(self, vat):
@@ -413,8 +409,6 @@ class res_partner(osv.osv):
             check = 10 - (sum % 10)
             if check == 10:
                 check = 0
-#            if check != int(vat[8]):
-#                return False
             return True
         #Legal persons with non-profit aim
         elif vat[0] in ('N', 'P', 'Q', 'R', 'S', 'W'):
@@ -924,8 +918,6 @@ class res_partner(osv.osv):
         check = 11 - (sum % 11)
         if check == 10 or check == 11:
             check = 0
-#        if check != int(vat[8]):
-#            return False
         return True
 
     def check_vat_ro(self, vat):
@@ -992,9 +984,6 @@ class res_partner(osv.osv):
         if int(vat[9:11]) < 0:
             return False
 
-#        if int(vat[-2:]) != 1:
-#            return False
-
         sum = mult_add(2, int(vat[0])) + int(vat[1]) + \
                 mult_add(2, int(vat[2])) + int(vat[3]) + \
                 mult_add(2, int(vat[4])) + int(vat[5]) + \
index c6e21c4..63e683b 100644 (file)
@@ -143,11 +143,6 @@ class node_calendar(nodes.node_class):
     def get_domain(self, cr, filters):
         # TODO: doc.
         res = []
-        # dirobj = self.context._dirobj
-        #uid = self.context.uid
-        #ctx = self.context.context.copy()
-        #ctx.update(self.dctx)
-        # calendar_obj = dirobj.pool.get('basic.calendar')
         if not filters:
             return res
         if filters.localName == 'calendar-query':
@@ -217,9 +212,6 @@ class node_calendar(nodes.node_class):
 
         if not domain:
             domain = []
-        #for opr1, opt, opr2 in domain:
-        #    if opr1 == 'type' and opr2 != self.cal_type:
-        #        return []
 
         fil_obj = dirobj.pool.get('basic.calendar')
         ids = fil_obj.search(cr, uid, domain)
@@ -245,7 +237,7 @@ class node_calendar(nodes.node_class):
             # that have been imported. ICS may have had more elements,
             # but only one node can be returned here.
             assert isinstance(res[0], (int, long))
-            fnodes = fil_obj.get_calendar_objects(cr, uid, [self.calendar_id], self, 
+            fnodes = fil_obj.get_calendar_objects(cr, uid, [self.calendar_id], self,
                     domain=[('id','=',res[0])], context=ctx)
             return fnodes[0]
         return None
index f48e9f3..b830f77 100644 (file)
@@ -91,7 +91,7 @@ def mailto2str(arg):
         args = [arg,]
     else:
         args = arg
-    
+
     for ard in args:
         rstr = ard.get('name','')
         if ard.get('company',False):
@@ -108,12 +108,12 @@ def str2mailto(emailstr, multi=False):
     """
     # TODO: move to tools or sth.
     mege = re.compile(r'([^\(\<]+) *(\((.*?)\))? *(\< ?(.*?) ?\>)? ?(\((.*?)\))? *$')
-    
+
     mailz= [emailstr,]
     retz = []
     if multi:
         mailz = emailstr.split(',')
-    
+
     for mas in mailz:
         m = mege.match(mas.strip())
         if not m:
@@ -121,17 +121,17 @@ def str2mailto(emailstr, multi=False):
             # retz.append({ 'name': mas.strip() })
             # continue
             raise ValueError("Invalid email address %r" % mas)
-        rd = {  'name': m.group(1).strip(), 
+        rd = {  'name': m.group(1).strip(),
                 'email': m.group(5), }
         if m.group(2):
             rd['company'] = m.group(3).strip()
         elif m.group(6):
             rd['company'] = m.group(7).strip()
-        
+
         if rd['name'].startswith('"') and rd['name'].endswith('"'):
             rd['name'] = rd['name'][1:-1]
         retz.append(rd)
-        
+
     if multi:
         return retz
     else:
@@ -230,8 +230,6 @@ def map_data(cr, uid, obj, context=None):
 class CalDAV(object):
     __attribute__ = {}
 
-
-
     def ical_set(self, name, value, type):
         """ set calendar Attribute
          @param self: The object pointer,
@@ -294,12 +292,12 @@ class CalDAV(object):
         att_data = []
         exdates = []
         _server_tzinfo = pytz.timezone(tools.get_server_timezone())
-        
+
         for cal_data in child.getChildren():
             if cal_data.name.lower() == 'organizer':
                 dmail = { 'name': cal_data.params.get('CN', ['',])[0],
                             'email': cal_data.value.replace('MAILTO:',''),
-                            # TODO: company? 
+                            # TODO: company?
                             }
                 self.ical_set(cal_data.name.lower(), mailto2str(dmail), 'value')
                 continue
index 76caab9..9151d78 100644 (file)
@@ -6,13 +6,6 @@
                 Administrator shortcut
                 Demo user startup menu
                 -->
-<!--           <record model="ir.ui.view_sc" id="sc_crm_dash">
-                       <field name="name">CRM Dashboard</field>
-                       <field name="user_id" ref="base.user_demo"/>
-                       <field name="resource">ir.ui.menu</field>
-                       <field name="sequence">3</field>
-                       <field name="res_id" ref="menu_board_crm"/>
-               </record> -->
                <record model="res.users" id="base.user_root">
                        <field name="action_id" ref="open_board_crm"/>
                </record>
index 331dd79..cf3b89c 100644 (file)
@@ -2,8 +2,6 @@
 <openerp>
     <data>
 
-        <!--menuitem id="base.menu_crm_config_sales" name="Sales"
-            parent="base.menu_base_config" sequence="1"/-->
         <menuitem icon="terp-partner" id="base.menu_base_partner" name="Sales" sequence="0" groups="base.group_system,base.group_sale_manager,base.group_sale_salesman"/>
 
         <menuitem id="base.menu_crm_config_lead" name="Leads &amp; Opportunities"
         <menuitem id="base.menu_sale_config_sales" name="Sales"
             parent="base.menu_base_config" sequence="0" groups="base.group_system,base.group_extended"/>
 
-        <!--menuitem id="menu_crm_config_meeting" name="Meeting"
-            parent="base.menu_base_config" sequence="4"/-->
-
         <menuitem id="menu_crm_config_phonecall" name="Phone Call"
             parent="base.menu_base_config" sequence="5" groups="base.group_extended,base.group_system"/>
 
         <menuitem id="base.next_id_64" name="Reporting"
             parent="base.menu_base_partner" sequence="11" />
 
-        <!--menuitem action="crm_custom_create_menu_action"
-            id="crm_case_create_custom_menu"
-            parent="base.menu_crm_config_sales"
-            groups="base.group_extended"
-            name="Create Menu for Custom Cases" /-->
-
 
         <!-- Case Sections Form View -->
 
index 120bc9f..6940260 100644 (file)
             <field name="arch" type="xml">
                 <search string="Search">
                   <group col="16" colspan="8">
-                           <!--  <filter string="This Year" name="This Year" icon="terp-hr"
-                               domain="[('name','=',time.localtime()[0])]"/>-->
                            <filter string="This Year" icon="terp-go-year"
                                domain="[('create_date','&lt;=', time.strftime('%%Y-%%m-%%d')), ('create_date','&gt;',(datetime.date.today()-datetime.timedelta(days=365)).strftime('%%Y-%%m-%%d'))]"/>
 
-                           <!-- <filter string="This Month" name="This Year" icon="terp-hr"
-                               domain="[('month','=',time.strftime('%%m'))]" />-->
                        <filter string="This Month" icon="terp-go-month" name="This Month"
                            domain="[('create_date','&lt;=', time.strftime('%%Y-%%m-%%d')), ('create_date','&gt;',(datetime.date.today()-datetime.timedelta(days=30)).strftime('%%Y-%%m-%%d'))]"/>
 
index 5bce5fc..7cadb41 100644 (file)
@@ -34,7 +34,6 @@ from report.interface import report_int
 from pychart import *
 
 theme.use_color = 1
-#theme.scale = 2
 random.seed(0)
 
 class external_pdf(render):
index 5ee0eda..b6af1f2 100644 (file)
             <field name="target">new</field>
         </record>
 
-        <!--    This will also come in Leads Form as Lead and Opportunity are same object-->
-        <!-- <record id="merge_opportunity_act_value" model="ir.values">
-            <field name="model_id" ref="model_crm_lead" />
-            <field name="object" eval="1" />
-            <field name="name">Merge Opportunities</field>
-            <field name="key2">client_action_multi</field>
-            <field name="value" eval="'ir.actions.act_window,' + str(ref('merge_opportunity_act'))"/>
-            <field name="key">action</field>
-            <field name="model">crm.lead</field>
-        </record> -->
-
     </data>
 </openerp>
\ No newline at end of file
index f234f9c..0df19df 100644 (file)
@@ -47,7 +47,6 @@ class crm_partner2opportunity(osv.osv_memory):
         @return : default values of fields.
         """
         partner_obj = self.pool.get('res.partner')
-        #data = context and context.get('active_id', False) or False
         data = context and context.get('active_ids', []) or []
         res = super(crm_partner2opportunity, self).default_get(cr, uid, fields, context=context)
 
index 37fd3ec..3a1e8f4 100644 (file)
             <field name="arch" type="xml">
                 <search string="Search">
                   <group col="16" colspan="8">
-                               <!--  <filter string="This Year" name="This Year" icon="terp-hr"
-                                       domain="[('name','=',time.localtime()[0])]"/>-->
                                <filter string="This Year" icon="terp-go-year"
                                        domain="[('create_date','&lt;=', time.strftime('%%Y-%%m-%%d')), ('create_date','&gt;',(datetime.date.today()-datetime.timedelta(days=365)).strftime('%%Y-%%m-%%d'))]"/>
 
-                               <!-- <filter string="This Month" name="This Year" icon="terp-hr"
-                                       domain="[('month','=',time.strftime('%%m'))]" />-->
                        <filter string="This Month" icon="terp-go-month" name="This Month"
                           domain="[('create_date','&lt;=', time.strftime('%%Y-%%m-%%d')), ('create_date','&gt;',(datetime.date.today()-datetime.timedelta(days=30)).strftime('%%Y-%%m-%%d'))]"/>
 
index a0fd2e3..8e9f161 100644 (file)
             <field name="arch" type="xml">
                 <search string="Search">
                   <group col="16" colspan="8">
-                               <!--  <filter string="This Year" name="This Year" icon="terp-hr"
-                                       domain="[('name','=',time.localtime()[0])]"/>-->
                                <filter string="This Year" icon="terp-go-year"
                                        domain="[('create_date','&lt;=', time.strftime('%%Y-%%m-%%d')), ('create_date','&gt;',(datetime.date.today()-datetime.timedelta(days=365)).strftime('%%Y-%%m-%%d'))]"/>
 
-                               <!-- <filter string="This Month" name="This Year" icon="terp-hr"
-                                       domain="[('month','=',time.strftime('%%m'))]" />-->
                        <filter string="This Month" icon="terp-go-month" name="This Month"
                           domain="[('create_date','&lt;=', time.strftime('%%Y-%%m-%%d')), ('create_date','&gt;',(datetime.date.today()-datetime.timedelta(days=30)).strftime('%%Y-%%m-%%d'))]"/>
 
index 9295f00..1789e8b 100644 (file)
@@ -53,7 +53,7 @@
        <record model="crm_profiling.answer" id="nb_employees2">
                <field name="name">51 to 100</field>
                <field name="question_id" ref="nb_employees"/>
-       </record>       
+       </record>
        <record model="crm_profiling.answer" id="nb_employees3">
                <field name="name">more than 100</field>
                <field name="question_id" ref="nb_employees"/>
                <field name="answer_yes" eval="[(6,0,[partner_tiny1])]" />
                <field name="categ_id" ref="base.res_partner_category_2"/>
                <field name="profiling_active">True</field>
-       </record>               
+       </record>
        <record model="crm.segmentation" id="crm_segmentation1">
                <field name="name">Bronze partners</field>
                <field name="answer_yes" eval="[(6,0,[partner_quality1])]" />
                <field name="parent_id" ref="crm_segmentation0"/>
                <field name="categ_id" ref="base.res_partner_category_3"/>
                <field name="profiling_active">True</field>
-       </record>       
+       </record>
        <record model="crm.segmentation" id="crm_segmentation2">
-               <field name="name">Silver partners</field>      
+               <field name="name">Silver partners</field>
                <field name="answer_yes" eval="[(6,0,[partner_quality2])]" />
                <field name="parent_id" ref="crm_segmentation0"/>
                <field name="categ_id" ref="base.res_partner_category_4"/>
                <field name="categ_id" ref="base.res_partner_category_15"/>
                <field name="profiling_active">True</field>
        </record>
-<!--<record model="crm.segmentation" id="crm_segmentation7">
-               <field name="name">small HR partners</field>
-               <field name="parent_id" ref="crm_segmentation4"/>
-               <field name="answer_yes" eval="[(6,0,[nb_employees2])]" />
-               <field name="categ_id">3</field>
-       </record>
-       <record model="crm.segmentation" id="crm_segmentation8">
-               <field name="name">not big HR partners</field>
-               <field name="parent_id" ref="crm_segmentation4"/>
-               <field name="answer_no" eval="[(6,0,[nb_employees3])]" />
-               <field name="categ_id">3</field>
-       </record>
-       <record model="crm.segmentation" id="crm_segmentation9">
-               <field name="name">not bronze HR partners</field>
-               <field name="parent_id" ref="crm_segmentation4"/>
-               <field name="answer_no" eval="[(6,0,[partner_quality1])]" />
-               <field name="categ_id">3</field>
-       </record>
-       <record model="crm.segmentation" id="crm_segmentation10">
-               <field name="name">small telecom partners</field>
-               <field name="parent_id" ref="crm_segmentation5"/>
-               <field name="answer_yes" eval="[(6,0,[nb_employees2])]" />
-               <field name="categ_id">3</field>
-       </record>
-       <record model="crm.segmentation" id="crm_segmentation11">
-               <field name="name">not big telecom partners</field>
-               <field name="parent_id" ref="crm_segmentation5"/>
-               <field name="answer_no" eval="[(6,0,[nb_employees3])]" />
-               <field name="categ_id">3</field>
-       </record>
-       <record model="crm.segmentation" id="crm_segmentation12">
-               <field name="name">not bronze telecom partners</field>
-               <field name="parent_id" ref="crm_segmentation5"/>
-               <field name="answer_no" eval="[(6,0,[partner_quality1])]" />
-               <field name="categ_id">3</field>
-       </record>
-       <record model="crm.segmentation" id="crm_segmentation13">
-               <field name="name">small IT partners</field>
-               <field name="parent_id" ref="crm_segmentation6"/>
-               <field name="answer_yes" eval="[(6,0,[nb_employees2])]" />
-               <field name="categ_id">3</field>
-       </record>
-       <record model="crm.segmentation" id="crm_segmentation14">
-               <field name="name">not big IT partners</field>
-               <field name="parent_id" ref="crm_segmentation6"/>
-               <field name="answer_no" eval="[(6,0,[nb_employees3])]" />
-               <field name="categ_id">3</field>
-       </record>
-       <record model="crm.segmentation" id="crm_segmentation15">
-               <field name="name">not bronze IT partners</field>
-               <field name="parent_id" ref="crm_segmentation6"/>
-               <field name="answer_no" eval="[(6,0,[partner_quality1])]" />
-               <field name="categ_id">3</field>
-       </record>
 
-       <record model="crm.segmentation" id="crm_segmentation16">
-               <field name="name">not bronze partners</field>
-               <field name="answer_no" eval="[(6,0,[partner_quality1])]" />
-               <field name="categ_id">3</field>
-       </record>
--->
        <!--
        Partners
        -->
-               
+
        <record model="res.partner" id="base.res_partner_asus">
                <field name="answers_ids" eval="[(6,0,[ref('partner_quality1'), ref('nb_employees2'), ref('sector2'), ref('partner_tiny1')])]" />
                <field name="category_id" eval="[(6,0,[ref('base.res_partner_category_3'), ref('base.res_partner_category_16')])]"/>
        <record model="res.partner" id="base.res_partner_sednacom">
                <field name="answers_ids" eval="[(6,0,[ref('partner_quality2'), ref('nb_employees1'), ref('sector2'), ref('partner_tiny1')])]" />
                <field name="category_id" eval="[(6,0,[ref('base.res_partner_category_4'), ref('base.res_partner_category_16')])]"/>
-       </record>       
+       </record>
        <record model="res.partner" id="base.res_partner_thymbra">
                <field name="answers_ids" eval="[(6,0,[ref('partner_quality3'), ref('nb_employees3'), ref('sector3'), ref('partner_tiny1')])]" />
                <field name="category_id" eval="[(6,0,[ref('base.res_partner_category_5'), ref('base.res_partner_category_15')])]"/>
-       </record>       
+       </record>
        <record model="res.partner" id="base.res_partner_desertic_hispafuentes">
                <field name="answers_ids" eval="[(6,0,[ref('partner_quality2'), ref('nb_employees2'), ref('sector2'), ref('partner_tiny1')])]" />
                <field name="category_id" eval="[(6,0,[ref('base.res_partner_category_4'), ref('base.res_partner_category_16')])]"/>
-       </record>       
+       </record>
        <record model="res.partner" id="base.res_partner_tinyatwork">
                <field name="answers_ids" eval="[(6,0,[ref('partner_quality1'), ref('nb_employees1'), ref('sector1'), ref('partner_tiny1')])]" />
                <field name="category_id" eval="[(6,0,[ref('base.res_partner_category_3'), ref('base.res_partner_category_17')])]"/>
-       </record>       
+       </record>
        <record model="res.partner" id="base.res_partner_2">
                <field name="answers_ids" eval="[(6,0,[ref('partner_quality1'), ref('nb_employees2'), ref('sector3'), ref('partner_tiny1')])]" />
                <field name="category_id" eval="[(6,0,[ref('base.res_partner_category_3'), ref('base.res_partner_category_15')])]"/>
-       </record>       
+       </record>
        <record model="res.partner" id="base.res_partner_3">
                <field name="answers_ids" eval="[(6,0,[ref('partner_quality2'), ref('nb_employees1'), ref('sector3'), ref('partner_tiny1')])]" />
                <field name="category_id" eval="[(6,0,[ref('base.res_partner_category_4'), ref('base.res_partner_category_15')])]"/>
-       </record>       
+       </record>
        <record model="res.partner" id="base.res_partner_4">
                <field name="answers_ids" eval="[(6,0,[ref('partner_quality3'), ref('nb_employees1'), ref('sector2'), ref('partner_tiny1')])]" />
                <field name="category_id" eval="[(6,0,[ref('base.res_partner_category_1'), ref('base.res_partner_category_16')])]"/>
-       </record>       
+       </record>
        <record model="res.partner" id="base.res_partner_5">
                <field name="answers_ids" eval="[(6,0,[ref('partner_quality3'), ref('nb_employees2'), ref('sector1'), ref('partner_tiny1')])]" />
                <field name="category_id" eval="[(6,0,[ref('base.res_partner_category_1'), ref('base.res_partner_category_17')])]"/>
-       </record>       
+       </record>
        <record model="res.partner" id="base.res_partner_6">
                <field name="answers_ids" eval="[(6,0,[ref('partner_quality3'), ref('nb_employees3'), ref('sector2'), ref('partner_tiny1')])]" />
                <field name="category_id" eval="[(6,0,[ref('base.res_partner_category_1'), ref('base.res_partner_category_16')])]"/>
-       </record>       
+       </record>
        <record model="res.partner" id="base.res_partner_maxtor">
                <field name="answers_ids" eval="[(6,0,[ref('partner_quality3'), ref('nb_employees1'), ref('sector3'), ref('partner_tiny1')])]" />
                <field name="category_id" eval="[(6,0,[ref('base.res_partner_category_1'), ref('base.res_partner_category_15')])]"/>
-       </record>       
+       </record>
 
 </data>
 </openerp>
index 089e360..39d436a 100644 (file)
@@ -1,12 +1,5 @@
 <?xml version="1.0"?>
 <openerp>
        <data>
-
-<!--           <wizard
-                       string="Select partners"
-                       model="segmentation.profile"
-                       name="open_partner"
-                       id="wizard_open_partner"/>
--->
-               </data>
+       </data>
 </openerp>
index 1a504ed..cfe7327 100644 (file)
@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 ##############################################################################
-#    
+#
 #    OpenERP, Open Source Management Solution
 #    Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
 #
@@ -15,7 +15,7 @@
 #    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/>.     
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #
 ##############################################################################
 
@@ -26,7 +26,5 @@ import report
 import sale
 import stock
 
-#import report
-
 # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
 
index 18544b5..8fdbac0 100644 (file)
@@ -154,7 +154,6 @@ class document_directory(osv.osv):
     
     def __init__(self, *args, **kwargs):
         super(document_directory, self).__init__(*args, **kwargs)
-        #self._cache = {}
 
     def onchange_content_id(self, cr, uid, ids, ressource_type_id):
         return {}
index 9be245e..09c1ca6 100644 (file)
@@ -41,7 +41,6 @@
     'demo_xml': [],
     'test': [
         'test/document_ftp_test2.yml',
-        # 'test/document_ftp_test2.yml',
         'test/document_ftp_test4.yml',
     ],
     'installable': True,
index 952b75d..00f308f 100644 (file)
@@ -14,7 +14,6 @@ import netsvc
 
 from service import security
 from osv import osv
-#from document.nodes import node_res_dir, node_res_obj
 from document.nodes import get_node_context
 
 def _get_month_name(month):
@@ -74,7 +73,7 @@ class abstracted_fs(object):
                     cr.execute("SELECT 1 FROM pg_class WHERE relkind = 'r' AND relname = 'ir_module_module'")
                     if not cr.fetchone():
                         continue
-    
+
                     cr.execute("SELECT id FROM ir_module_module WHERE name = 'document_ftp' AND state IN ('installed', 'to upgrade') ")
                     res = cr.fetchone()
                     if res and len(res):
@@ -85,8 +84,6 @@ class abstracted_fs(object):
             finally:
                 if cr is not None:
                     cr.close()
-                #if db is not None:
-                #    pooler.close_db(db_name)        
         return self.db_name_list
 
     def ftpnorm(self, ftppath):
@@ -115,7 +112,7 @@ class abstracted_fs(object):
     def ftp2fs(self, path_orig, data):
         raise DeprecationWarning()
 
-    def fs2ftp(self, node):        
+    def fs2ftp(self, node):
         """ Return the string path of a node, in ftp form
         """
         res='/'
@@ -123,7 +120,7 @@ class abstracted_fs(object):
             paths = node.full_path()
             res = '/' + node.context.dbname + '/' +  \
                 _to_decode(os.path.join(*paths))
-            
+
         return res
 
     def validpath(self, path):
@@ -139,7 +136,7 @@ class abstracted_fs(object):
         """ Create a children file-node under node, open it
             @return open node_descriptor of the created node
         """
-        objname = _to_unicode(objname) 
+        objname = _to_unicode(objname)
         cr , node, rem = datacr
         try:
             child = node.child(cr, objname)
@@ -200,7 +197,6 @@ class abstracted_fs(object):
             if len(res):
                 pre = prefix.split('.')
                 prefix=pre[0] + '.v'+str(len(res))+'.'+pre[1]
-            #prefix = prefix + '.'
         return self.create(dir,suffix+prefix,text)
 
 
@@ -210,7 +206,7 @@ class abstracted_fs(object):
         if (not datacr) or datacr == (None, None, None):
             self.cwd = '/'
             self.cwd_node = None
-            return None        
+            return None
         if not datacr[1]:
             raise OSError(1, 'Operation not permitted')
         if datacr[1].type not in  ('collection','database'):
@@ -225,7 +221,7 @@ class abstracted_fs(object):
         cr, node, rem = datacr or (None, None, None)
         if not node:
             raise OSError(1, 'Operation not permited.')
-        
+
         try:
             basename =_to_unicode(basename)
             cdir = node.create_child_collection(cr, basename)
@@ -242,15 +238,15 @@ class abstracted_fs(object):
 
     def get_cr(self, pathname):
         raise DeprecationWarning()
-    
+
     def get_crdata(self, line, mode='file'):
         """ Get database cursor, node and remainder data, for commands
-        
+
         This is the helper function that will prepare the arguments for
         any of the subsequent commands.
         It returns a tuple in the form of:
         @code        ( cr, node, rem_path=None )
-        
+
         @param line An absolute or relative ftp path, as passed to the cmd.
         @param mode A word describing the mode of operation, so that this
                     function behaves properly in the different commands.
@@ -307,7 +303,6 @@ class abstracted_fs(object):
                 raise OSError(2, 'Authentification Required.')
             n = get_node_context(cr, uid, {})
             node = n.get_uri(cr, p_parts[1:])
-            # self._log.debug("get_crdata(abs): %r" % ( (cr, node, rem_path),))
             return (cr, node, rem_path)
         else:
             # we never reach here if cwd_node is not set
@@ -321,7 +316,6 @@ class abstracted_fs(object):
             if node is False and mode not in ('???'):
                 cr.close()
                 raise IOError(errno.ENOENT, 'Path does not exist')
-            # self._log.debug("get_crdata(rel): %r" % ( (cr, node, rem_path),))
             return (cr, node, rem_path)
 
     def get_node_cr_uid(self, node):
@@ -330,15 +324,15 @@ class abstracted_fs(object):
         assert node
         db = pooler.get_db(node.context.dbname)
         return db.cursor(), node.context.uid
-        
+
     def get_node_cr(self, node):
         """ Get the cursor for the database of a node
-        
-        The cursor is the only thing that a node will not store 
+
+        The cursor is the only thing that a node will not store
         persistenly, so we have to obtain a new one for each call.
         """
         return self.get_node_cr_uid(node)[0]
-        
+
     def listdir(self, datacr):
         """List the content of a directory."""
         class false_node(object):
@@ -349,7 +343,7 @@ class abstracted_fs(object):
             uuser = 'root'
             ugroup = 'root'
             type = 'database'
-            
+
             def __init__(self, db):
                 self.path = db
 
@@ -442,7 +436,7 @@ class abstracted_fs(object):
     def getmtime(self, datacr):
         """Return the last modified time as a number of seconds since
         the epoch."""
-        
+
         node = datacr[1]
         if node.write_date or node.create_date:
             dt = (node.write_date or node.create_date)[:19]
@@ -488,12 +482,11 @@ class abstracted_fs(object):
     def get_list_dir(self, datacr):
         """"Return an iterator object that yields a directory listing
         in a form suitable for LIST command.
-        """        
+        """
         if not datacr:
             return None
         elif self.isdir(datacr[1]):
             listing = self.listdir(datacr)
-            #listing.sort()
             return self.format_list(datacr[0], datacr[1], listing)
         # if path is a file or a symlink we return information about it
         elif self.isfile(datacr[1]):
@@ -561,11 +554,11 @@ class abstracted_fs(object):
                 mtime = mname+' '+time.strftime("%d %H:%M", st_mtime)
             except ValueError:
                 mname=_get_month_name(time.strftime("%m"))
-                mtime = mname+' '+time.strftime("%d %H:%M")            
+                mtime = mname+' '+time.strftime("%d %H:%M")
             fpath = node.path
             if isinstance(fpath, (list, tuple)):
                 fpath = fpath[-1]
-            # formatting is matched with proftpd ls output            
+            # formatting is matched with proftpd ls output
             path=_to_decode(fpath)
             yield "%s %3s %-8s %-8s %8s %s %s\r\n" %(perms, nlinks, uname, gname,
                                                      size, mtime, path)
@@ -608,7 +601,7 @@ class abstracted_fs(object):
             # type + perm
             if self.isdir(node):
                 if 'type' in facts:
-                    type = 'type=dir;'                    
+                    type = 'type=dir;'
                 if 'perm' in facts:
                     perm = 'perm=%s;' %permdir
             else:
index 0ca322f..710494b 100644 (file)
@@ -547,7 +547,6 @@ class ActiveDTP(asyncore.dispatcher):
         handler = self.cmd_channel.dtp_handler(self.socket, self.cmd_channel)
         self.cmd_channel.data_channel = handler
         self.cmd_channel.on_dtp_connection()
-        #self.close()  # <-- (done automatically)
 
     def handle_expt(self):
         self.cmd_channel.respond("425 Can't connect to specified address.")
@@ -1195,7 +1194,7 @@ class AbstractedFS:
             size = st.st_size  # file size
             uname = st.st_uid or "owner"
             gname = st.st_gid or "group"
-           
+
             # stat.st_mtime could fail (-1) if last mtime is too old
             # in which case we return the local time as last mtime
             try:
@@ -1412,7 +1411,7 @@ class FTPHandler(asynchat.async_chat):
         self._epsvall = False
         self.__in_dtp_queue = None
         self.__out_dtp_queue = None
-        
+
         self.__errno_responses = {
                 errno.EPERM: 553,
                 errno.EINVAL: 504,
@@ -1574,7 +1573,7 @@ class FTPHandler(asynchat.async_chat):
 
     def __check_path(self, cmd, line):
         """Check whether a path is valid."""
-        
+
         # Always true, we will only check later, once we have a cursor
         return True
 
@@ -1738,7 +1737,7 @@ class FTPHandler(asynchat.async_chat):
             self.__out_dtp_queue = (data, isproducer, file)
 
     def log(self, msg):
-        """Log a message, including additional identifying session data."""        
+        """Log a message, including additional identifying session data."""
         log("[%s]@%s:%s %s" %(self.username, self.remote_ip,
                               self.remote_port, msg))
 
@@ -1815,7 +1814,7 @@ class FTPHandler(asynchat.async_chat):
             why = (err.strerror) or 'Error in command'
             self.log('FAIL %s() %s errno=%s:  %s.' %(cmdname, uline, err.errno, why))
             self.respond('%s %s.' % (str(ret_code), why))
-        
+
             raise FTPExceptionSent(why)
         except Exception, err:
             cmdname = function.__name__
@@ -2058,7 +2057,7 @@ class FTPHandler(asynchat.async_chat):
         except FTPExceptionSent:
             self.fs.close_cr(datacr)
             return
-        
+
         try:
             self.log('OK LIST "%s". Transfer starting.' % line)
             producer = BufferedIteratorProducer(iterator)
@@ -2084,7 +2083,7 @@ class FTPHandler(asynchat.async_chat):
             else:
                 # if path is a file we just list its name
                 nodelist = [datacr[1],]
-            
+
             listing = []
             for nl in nodelist:
                 if isinstance(nl.path, (list, tuple)):
@@ -2094,7 +2093,7 @@ class FTPHandler(asynchat.async_chat):
         except FTPExceptionSent:
             self.fs.close_cr(datacr)
             return
-        
+
         self.fs.close_cr(datacr)
         data = ''
         if listing:
@@ -2145,7 +2144,7 @@ class FTPHandler(asynchat.async_chat):
         # if no argument, fall back on cwd as default
         if not line:
             line = ''
-        
+
         datacr = None
         try:
             datacr = self.get_crdata2(line, mode='list')
@@ -2532,12 +2531,6 @@ class FTPHandler(asynchat.async_chat):
         datacr = None
         try:
             datacr = self.get_crdata2(line, mode='file')
-            #if self.fs.isdir(datacr[1]):
-            #    why = "%s is not retrievable" %line
-            #    self.log('FAIL SIZE "%s". %s.' %(line, why))
-            #    self.respond("550 %s." %why)
-            #    self.fs.close_cr(datacr)
-            #    return
             size = self.try_as_current_user(self.fs.getsize,(datacr,), line=line)
         except FTPExceptionSent:
             self.fs.close_cr(datacr)
@@ -2552,7 +2545,7 @@ class FTPHandler(asynchat.async_chat):
         3307 style timestamp (YYYYMMDDHHMMSS) as defined in RFC-3659.
         """
         datacr = None
-            
+
         try:
             if line.find('/', 1) < 0:
                 # root or db, just return local
@@ -2561,9 +2554,7 @@ class FTPHandler(asynchat.async_chat):
                 datacr = self.get_crdata2(line)
                 if not datacr:
                     raise IOError(errno.ENOENT, "%s is not retrievable" %line)
-                #if not self.fs.isfile(datacr[1]):
-                #    raise IOError(errno.EPERM, "%s is not a regular file" % line)
-                
+
                 lmt = self.try_as_current_user(self.fs.getmtime, (datacr,), line=line)
             lmt = time.strftime("%Y%m%d%H%M%S", time.localtime(lmt))
             self.respond("213 %s" %lmt)
index 37aba51..42081c9 100644 (file)
@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 ##############################################################################
-#    
+#
 #    OpenERP, Open Source Management Solution
 #    Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
 #
@@ -15,7 +15,7 @@
 #    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/>.     
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #
 ##############################################################################
 
@@ -36,7 +36,6 @@ class document_ftp_browse(osv.osv_memory):
         if 'url' in fields:
             user_pool = self.pool.get('res.users')
             current_user = user_pool.browse(cr, uid, uid, context=context)
-            # dir_pool = self.pool.get('document.directory')
             data_pool = self.pool.get('ir.model.data')
             aid = data_pool._get_id(cr, uid, 'document_ftp', 'action_document_browse')
             aid = data_pool.browse(cr, uid, aid, context=context).res_id
@@ -45,7 +44,7 @@ class document_ftp_browse(osv.osv_memory):
             if url:
                 url = url[1]
             else:
-                url = '%s:%s' %(ftpserver.HOST, ftpserver.PORT) 
+                url = '%s:%s' %(ftpserver.HOST, ftpserver.PORT)
             res['url'] = 'ftp://%s@%s'%(current_user.login, url)
         return res
 
index fdcf9d9..9133a52 100644 (file)
@@ -166,7 +166,6 @@ class document_directory_content(osv.osv):
         ctx = (context or {})
         ctx.update(node.context.context.copy())
         ctx.update(node.dctx)
-        # print "ICS domain: ", type(content.ics_domain), content.ics_domain
         if content.ics_domain:
             for d in safe_eval(content.ics_domain,ctx):
                 # TODO: operator?
@@ -195,7 +194,6 @@ class document_directory_content(osv.osv):
                     elif ICS_TAGS[enl]=='date':
                         result[fields[enl]] = event.value.strftime('%Y-%m-%d %H:%M:%S')
 
-                    # print "Field ",enl,  result[fields[enl]]
                 elif fields[enl] and funcs[enl] == 'hours':
                     ntag = fexprs[enl] or 'dtstart'
                     ts_start = child.getChildValue(ntag, default=False)
@@ -238,9 +236,6 @@ class document_directory_content(osv.osv):
 
                 wexpr = [ ( 'id', '=', wematch.group(2) ) ]
 
-            # print "Looking at ", cmodel, " for ", wexpr
-            # print "domain=", idomain
-
             fobj = self.pool.get(content.object_id.model)
 
             if not wexpr:
@@ -354,7 +349,7 @@ class crm_meeting(osv.osv):
         if not default: default = {}
         if not context: context = {}
         default.update({'code': self.pool.get('ir.sequence').get(cr, uid, 'crm.meeting'), 'id': False})
-        return super(crm_meeting, self).copy(cr, uid, id, default, context)  
+        return super(crm_meeting, self).copy(cr, uid, id, default, context)
 
 crm_meeting()
 
index 798f277..f3c8201 100644 (file)
@@ -80,14 +80,14 @@ class openerp_dav_handler(dav_interface):
 
     M_NS={ "DAV:" : dav_interface.M_NS['DAV:'],}
 
-    def __init__(self,  parent, verbose=False):        
+    def __init__(self,  parent, verbose=False):
         self.db_name_list=[]
         self.parent = parent
         self.baseuri = parent.baseuri
         self.verbose = verbose
 
     def get_propnames(self, uri):
-        props = self.PROPS   
+        props = self.PROPS
         self.parent.log_message('get propnames: %s' % uri)
         cr, uid, pool, dbname, uri2 = self.get_cr(uri)
         if not dbname:
@@ -98,7 +98,7 @@ class openerp_dav_handler(dav_interface):
         if node:
             props = props.copy()
             props.update(node.get_dav_props(cr))
-        cr.close()     
+        cr.close()
         return props
 
     def _try_function(self, funct, args, opname='run function', cr=None,
@@ -140,20 +140,20 @@ class openerp_dav_handler(dav_interface):
     def _get_dav_supportedlock(self, uri):
         raise DAV_NotFound
 
-    def match_prop(self, uri, match, ns, propname):        
+    def match_prop(self, uri, match, ns, propname):
         if self.M_NS.has_key(ns):
             return match == dav_interface.get_prop(self, uri, ns, propname)
         cr, uid, pool, dbname, uri2 = self.get_cr(uri)
         if not dbname:
             if cr: cr.close()
             raise DAV_NotFound
-        node = self.uri2object(cr, uid, pool, uri2)        
+        node = self.uri2object(cr, uid, pool, uri2)
         if not node:
             cr.close()
             raise DAV_NotFound
-        res = node.match_dav_eprop(cr, match, ns, propname)        
-        cr.close()          
-        return res  
+        res = node.match_dav_eprop(cr, match, ns, propname)
+        cr.close()
+        return res
 
     def prep_http_options(self, uri, opts):
         """see HttpOptions._prep_OPTIONS """
@@ -192,7 +192,7 @@ class openerp_dav_handler(dav_interface):
             uri        -- uri of the object to get the property of
             ns        -- namespace of the property
             pname        -- name of the property
-         """            
+         """
         if self.M_NS.has_key(ns):
             return dav_interface.get_prop(self, uri, ns, propname)
         cr, uid, pool, dbname, uri2 = self.get_cr(uri)
@@ -204,8 +204,8 @@ class openerp_dav_handler(dav_interface):
             cr.close()
             raise DAV_NotFound
         res = node.get_dav_eprop(cr, ns, propname)
-        cr.close()        
-        return res    
+        cr.close()
+        return res
 
     def get_db(self, uri, rest_ret=False, allow_last=False):
         """Parse the uri and get the dbname and the rest.
@@ -272,17 +272,17 @@ class openerp_dav_handler(dav_interface):
         return self.db_name_list
 
     def get_childs(self, uri, filters=None):
-        """ return the child objects as self.baseuris for the given URI """        
+        """ return the child objects as self.baseuris for the given URI """
         self.parent.log_message('get childs: %s' % uri)
         cr, uid, pool, dbname, uri2 = self.get_cr(uri, allow_last=True)
-        
-        if not dbname:            
+
+        if not dbname:
             if cr: cr.close()
-            res = map(lambda x: self.urijoin(x), self.db_list())            
+            res = map(lambda x: self.urijoin(x), self.db_list())
             return res
         result = []
         node = self.uri2object(cr, uid, pool, uri2[:])
-        
+
         if not node:
             if cr: cr.close()
             raise DAV_NotFound2(uri2)
@@ -297,12 +297,12 @@ class openerp_dav_handler(dav_interface):
             if filters:
                 domain = node.get_domain(cr, filters)
             for d in node.children(cr, domain):
-                self.parent.log_message('child: %s' % d.path)                
+                self.parent.log_message('child: %s' % d.path)
                 if fp:
                     result.append( self.urijoin(dbname,fp,d.path) )
                 else:
                     result.append( self.urijoin(dbname,d.path) )
-        if cr: cr.close()        
+        if cr: cr.close()
         return result
 
     def uri2local(self, uri):
@@ -368,11 +368,11 @@ class openerp_dav_handler(dav_interface):
                 raise DAV_Error, 409
             return str(datas) # FIXME!
         finally:
-            if cr: cr.close()    
+            if cr: cr.close()
 
     @memoize(CACHE_SIZE)
     def _get_dav_resourcetype(self, uri):
-        """ return type of object """        
+        """ return type of object """
         self.parent.log_message('get RT: %s' % uri)
         cr, uid, pool, dbname, uri2 = self.get_cr(uri)
         try:
index 10a7f9d..3b6cf58 100644 (file)
@@ -57,10 +57,10 @@ def mk_prop_response(self, uri, good_props, bad_props, doc):
 
     def _prop_child(xnode, ns, prop, value):
         """Append a property xml node to xnode, with <prop>value</prop>
-           
+
            And a little smarter than that, it will consider namespace and
            also allow nested properties etc.
-           
+
            :param ns the namespace of the <prop/> node
            :param prop the name of the property
            :param value the value. Can be:
@@ -89,7 +89,7 @@ def mk_prop_response(self, uri, good_props, bad_props, doc):
             xnode.appendChild(pe)
 
     def _prop_elem_child(pnode, pns, v, pns_prefix):
-        
+
         if isinstance(v, list):
             for vit in v:
                 _prop_elem_child(pnode, pns, vit, pns_prefix)
@@ -102,8 +102,6 @@ def mk_prop_response(self, uri, good_props, bad_props, doc):
             elif v[1] in namespaces:
                 ns_prefix="ns"+str(namespaces.index(v[1]))+":"
             else:
-                # namespaces.append(v[1])
-                # nsnum += 1
                 ns_prefix="ns"+str(nsnum)+":"
                 need_ns = True
 
index 8a83e25..4459224 100644 (file)
@@ -44,7 +44,7 @@ def OpenDAVConfig(**kw):
     class OpenDAV:
         def __init__(self, **kw):
             self.__dict__.update(**kw)
-            
+
         def getboolean(self, word):
             return self.__dict__.get(word, False)
 
@@ -58,7 +58,7 @@ class DAVHandler(HttpOptions, FixSendError, DAVRequestHandler):
     verbose = False
     protocol_version = 'HTTP/1.1'
     _HTTP_OPTIONS= { 'DAV' : ['1',],
-                    'Allow' : [ 'GET', 'HEAD', 'COPY', 'MOVE', 'POST', 'PUT', 
+                    'Allow' : [ 'GET', 'HEAD', 'COPY', 'MOVE', 'POST', 'PUT',
                             'PROPFIND', 'PROPPATCH', 'OPTIONS', 'MKCOL',
                             'DELETE', 'TRACE', 'REPORT', ]
                     }
@@ -67,7 +67,7 @@ class DAVHandler(HttpOptions, FixSendError, DAVRequestHandler):
         return False
     def _log(self, message):
         netsvc.Logger().notifyChannel("webdav",netsvc.LOG_DEBUG,message)
-    
+
     def handle(self):
         self._init_buffer()
 
@@ -83,7 +83,7 @@ class DAVHandler(HttpOptions, FixSendError, DAVRequestHandler):
         self.davpath = '/'+config.get_misc('webdav','vdir','webdav')
         self.baseuri = "http://%s:%d/"% (self.server.server_name, self.server.server_port)
         self.IFACE_CLASS  = openerp_dav_handler(self, self.verbose)
-        
+
     def copymove(self, CLASS):
         """ Our uri scheme removes the /webdav/ component from there, so we
         need to mangle the header, too.
@@ -98,7 +98,7 @@ class DAVHandler(HttpOptions, FixSendError, DAVRequestHandler):
 
     def get_davpath(self):
         return self.davpath
-    
+
     def log_message(self, format, *args):
         netsvc.Logger().notifyChannel('webdav', netsvc.LOG_DEBUG_RPC, format % args)
 
@@ -111,7 +111,6 @@ class DAVHandler(HttpOptions, FixSendError, DAVRequestHandler):
         uri=urlparse.urljoin(self.get_baseuri(dc), self.path)
         uri=urllib.unquote(uri)
         try:
-            #location = dc.put(uri,body,ct)
             ret = dc.prep_http_options(uri, opts)
         except DAV_Error, (ec,dd):
             pass
@@ -119,7 +118,7 @@ class DAVHandler(HttpOptions, FixSendError, DAVRequestHandler):
             self.log_error("Error at options: %s", str(e))
             raise
         return ret
-            
+
     def send_response(self, code, message=None):
         # the BufferingHttpServer will send Connection: close , while
         # the BaseHTTPRequestHandler will only accept int code.
@@ -148,15 +147,15 @@ class DAVHandler(HttpOptions, FixSendError, DAVRequestHandler):
                     ctype=ctype, headers=headers)
 
     def do_PUT(self):
-        dc=self.IFACE_CLASS        
+        dc=self.IFACE_CLASS
         uri=urlparse.urljoin(self.get_baseuri(dc), self.path)
         uri=urllib.unquote(uri)
         # Handle If-Match
         if self.headers.has_key('If-Match'):
             test = False
             etag = None
-            
-            for match in self.headers['If-Match'].split(','):                
+
+            for match in self.headers['If-Match'].split(','):
                 if match.startswith('"') and match.endswith('"'):
                     match = match[1:-1]
                 if match == '*':
@@ -175,7 +174,7 @@ class DAVHandler(HttpOptions, FixSendError, DAVRequestHandler):
         # Handle If-None-Match
         if self.headers.has_key('If-None-Match'):
             test = True
-            etag = None            
+            etag = None
             for match in self.headers['If-None-Match'].split(','):
                 if match == '*':
                     if dc.exists(uri):
@@ -259,14 +258,14 @@ class DAVAuthProvider(OpenERPAuthProvider):
 try:
 
     if (config.get_misc('webdav','enable',True)):
-        directory = '/'+config.get_misc('webdav','vdir','webdav') 
+        directory = '/'+config.get_misc('webdav','vdir','webdav')
         handler = DAVHandler
         verbose = config.get_misc('webdav','verbose',True)
         handler.debug = config.get_misc('webdav','debug',True)
         _dc = { 'verbose' : verbose,
                 'directory' : directory,
                 'lockemulation' : False,
-                    
+
                 }
 
         conf = OpenDAVConfig(**_dc)
index ce1b5ee..018b180 100644 (file)
                                 </page>
                                 <page string="Body (HTML-Web Client Only)">
                                     <field name="body_html" nolabel="1" colspan="4" />
-                                    <!--<label string="Note: HTML body can't be edited with GTK desktop client." colspan="4"/>
-                                --></page>
-
+                                </page>
                             </notebook>
                         </page>
 
-
                         <page string="Attachments">
                             <group col="4">
                                 <separator colspan="4" string="Attachments" />
index 5f2f164..80cce83 100755 (executable)
@@ -31,8 +31,7 @@
                                                        </page>
                                                        <page string="Body (HTML)">
                                                                <field name="body_html" select="2" colspan="4" nolabel="1" />
-                                                               <!--<label string="Note: HTML body can't be edited with GTK desktop client." colspan="4"/>
-                                                       --></page>
+                                                       </page>
                                                        <page string="Attachments">
                                                                <label string="Add here all attachments of the current document you want to include in the e-mail." colspan="4"/>
                                                                <field name="attachment_ids" colspan="4" nolabel="1"/>
index 2c483a0..6b223b2 100644 (file)
@@ -2,17 +2,6 @@
 <openerp>
     <data>
     <!--  Need to merge this action in associations -->
-    <!-- <action
-        string="My Tasks"
-        name="%(project.action_view_task)d"
-        colspan="4"
-        height="200"
-        width="510"
-        domain="[('user_id', '=', uid),('state','in',('open','draft'))]"/>
-       <action
-                string="New members"
-                name="%(membership.action_report_partner_member_year_tree)d"
-                view_mode="graph,tree" colspan="4"/>-->
 
         <record model ="ir.ui.view" id="view_report_event_reg_graph">
             <field name="name">Registration Event report</field>
index 233f3a0..e82da17 100644 (file)
@@ -1,8 +1,6 @@
 <?xml version="1.0"?>
 <openerp>
     <data>
-        <!--menuitem name="Association" id="base.menu_association" icon="terp-calendar" sequence="9"/>
-        <menuitem name="Events Organisation" id="menu_event_main" parent="base.menu_association" /-->
         <menuitem name="Marketing" icon="terp-crm" id="base.marketing_menu" sequence="17"/>
         <menuitem name="Events Organisation" id="base.menu_event_main" parent="base.marketing_menu" />
 
@@ -56,7 +54,7 @@
                     </group>
                     <notebook colspan="4">
                     <page string="Event">
-                        <group colspan="4" col="4">                            
+                        <group colspan="4" col="4">
                             <separator string="Invoice Information" colspan="4"/>
                             <field name="product_id" on_change="onchange_product(product_id)" colspan="4"/>
                             <field name="unit_price"/>
                                 </group>
                             </group>
                         </group>
-                    </page>                   
+                    </page>
                     </notebook>
             </form>
             </field>
                                 <separator string="Invoice" colspan="4"/>
                                 <field name="event_product" attrs="{'required':[('tobe_invoiced','=',True)]}"/>
                                 <field name="partner_invoice_id" attrs="{'required':[('tobe_invoiced','=',True)]}" on_change="onchange_partner_invoice_id(event_id, partner_invoice_id)"/>
-                                <field name="invoice_id"/>                                
+                                <field name="invoice_id"/>
                            </group>
                             <separator string="Description" colspan="4"/>
                             <field name="description" colspan="4" nolabel="1"/>
                             <separator string="" colspan="4"/>
-                            <group col="8" colspan="4">                                
+                            <group col="8" colspan="4">
                                 <field name="state" select="1" colspan="2"/>
                                 <button name="button_reg_close" string="Close Registration" states="open" type="object" icon="gtk-close"/>
                                 <button name="check_confirm" string="Confirm Registration" states="draft" type="object" icon="gtk-apply"/>
                                 </form>
                             </field>
                             <group col="2" colspan="2" groups="base.group_extended">
-                               <separator string="Dates" colspan="2"/>                               
+                               <separator string="Dates" colspan="2"/>
                                <field name="date_closed"/>
                             </group>
                             <group col="2" colspan="2" groups="base.group_extended">
index d62332a..8212c90 100644 (file)
@@ -38,9 +38,9 @@
                 </graph>
             </field>
         </record>
-        
-              <!-- Event on Registration search view -->  
-        
+
+              <!-- Event on Registration search view -->
+
         <record model="ir.ui.view" id="view_report_event_registration_search">
             <field name="name">.search</field>
             <field name="model">report.event.registration</field>
@@ -60,7 +60,7 @@
                          separator="1"
                          domain="[('date','&lt;=', time.strftime('%%Y-%%m-%%d')), ('date','&gt;',(datetime.date.today()-datetime.timedelta(days=7)).strftime('%%Y-%%m-%%d'))]"
                          help="Tasks during last 7 days"/>
-                         
+
                     <separator orientation="vertical"/>
                       <filter icon="terp-document-new"
                         string="Draft"
@@ -68,7 +68,7 @@
                     <filter icon="terp-camera_test"
                         string="Confirm"
                         domain="[('state', '=', 'confirm')]"/>
-                    <separator orientation="vertical"/>    
+                    <separator orientation="vertical"/>
                         <field name="event_id" widget="selection"/>
                          <field name="type" widget="selection"/>
                          <field name="user_id" widget="selection">
@@ -87,7 +87,6 @@
                         <filter string="state" icon="terp-stock_effects-object-colorize" context="{'group_by':'state'}"/>
                         <separator orientation="vertical"/>
                         <filter string="Speaker" name="user" icon="terp-personal+" context="{'group_by': 'speaker_id'}"/>
-                        <!--filter string="Responsible" name="user" icon="terp-personal" context="{'group_by': 'user_id'}"/-->
                         <separator orientation="vertical" />
                         <filter string="Day" icon="terp-go-month"
                             domain="[]" context="{'group_by':'day'}"/>
             <field name="search_view_id" ref="view_report_event_registration_search"/>
             <field name="context">{"search_default_user":1,"search_default_month":1,'group_by_no_leaf':1,'group_by':[]}</field>
         </record>
-      
+
       <record model="ir.actions.act_window.view" id="action_report_event_registration_tree">
             <field name="sequence" eval="1"/>
             <field name="view_mode">tree</field>
             <field name="act_window_id" ref="action_report_event_registration"/>
        </record>
 
-        <!--<menuitem parent="menu_report_event" action="action_event_registration" id="menu_report_event_registration"/>-->
         <menuitem parent="base.menu_report_association" action="action_report_event_registration" id="menu_report_event_registration" sequence="3" groups="base.group_system,base.group_marketing_manager"/>
+
     <!-- end...  -->
     </data>
-</openerp>    
+</openerp>
index 9d2fbe7..8540c26 100644 (file)
@@ -31,7 +31,6 @@ class event_make_invoice(osv.osv_memory):
 
         'grouped': fields.boolean('Group the invoices'),
         'invoice_date':fields.date('Invoice Date'),
-#        'invoice_ids': fields.char('Invoice Ids', size=128), # Improve me
          }
 
     def view_init(self, cr, uid, fields, context=None):
index 9474340..e9dc2b9 100644 (file)
@@ -38,36 +38,36 @@ class email_server(osv.osv):
     _description = "POP/IMAP Server"
 
     _columns = {
-        'name':fields.char('Name', size=256, required=True, readonly=False), 
-        'active':fields.boolean('Active', required=False), 
+        'name':fields.char('Name', size=256, required=True, readonly=False),
+        'active':fields.boolean('Active', required=False),
         'state':fields.selection([
-            ('draft', 'Not Confirmed'), 
-            ('wating', 'Waiting for Verification'), 
-            ('done', 'Confirmed'), 
-        ], 'State', select=True, readonly=True), 
-        'server' : fields.char('Server', size=256, required=True, readonly=True, states={'draft':[('readonly', False)]}), 
-        'port' : fields.integer('Port', required=True, readonly=True, states={'draft':[('readonly', False)]}), 
+            ('draft', 'Not Confirmed'),
+            ('wating', 'Waiting for Verification'),
+            ('done', 'Confirmed'),
+        ], 'State', select=True, readonly=True),
+        'server' : fields.char('Server', size=256, required=True, readonly=True, states={'draft':[('readonly', False)]}),
+        'port' : fields.integer('Port', required=True, readonly=True, states={'draft':[('readonly', False)]}),
         'type':fields.selection([
-            ('pop', 'POP Server'), 
-            ('imap', 'IMAP Server'), 
-        ], 'Server Type', select=True, readonly=False), 
-        'is_ssl':fields.boolean('SSL ?', required=False), 
-        'attach':fields.boolean('Add Attachments ?', required=False), 
-        'date': fields.date('Date', readonly=True, states={'draft':[('readonly', False)]}), 
-        'user' : fields.char('User Name', size=256, required=True, readonly=True, states={'draft':[('readonly', False)]}), 
-        'password' : fields.char('Password', size=1024, invisible=True, required=True, readonly=True, states={'draft':[('readonly', False)]}), 
-        'note': fields.text('Description'), 
-        'action_id':fields.many2one('ir.actions.server', 'Reply Email', required=False, domain="[('state','=','email')]"), 
-        'object_id': fields.many2one('ir.model', "Model", required=True), 
-        'priority': fields.integer('Server Priority', readonly=True, states={'draft':[('readonly', False)]}, help="Priority between 0 to 10, select define the order of Processing"), 
-        'user_id':fields.many2one('res.users', 'User', required=False), 
+            ('pop', 'POP Server'),
+            ('imap', 'IMAP Server'),
+        ], 'Server Type', select=True, readonly=False),
+        'is_ssl':fields.boolean('SSL ?', required=False),
+        'attach':fields.boolean('Add Attachments ?', required=False),
+        'date': fields.date('Date', readonly=True, states={'draft':[('readonly', False)]}),
+        'user' : fields.char('User Name', size=256, required=True, readonly=True, states={'draft':[('readonly', False)]}),
+        'password' : fields.char('Password', size=1024, invisible=True, required=True, readonly=True, states={'draft':[('readonly', False)]}),
+        'note': fields.text('Description'),
+        'action_id':fields.many2one('ir.actions.server', 'Reply Email', required=False, domain="[('state','=','email')]"),
+        'object_id': fields.many2one('ir.model', "Model", required=True),
+        'priority': fields.integer('Server Priority', readonly=True, states={'draft':[('readonly', False)]}, help="Priority between 0 to 10, select define the order of Processing"),
+        'user_id':fields.many2one('res.users', 'User', required=False),
     }
     _defaults = {
-        'state': lambda *a: "draft", 
-        'active': lambda *a: True, 
-        'priority': lambda *a: 5, 
-        'date': lambda *a: time.strftime('%Y-%m-%d'), 
-        'user_id': lambda self, cr, uid, ctx: uid, 
+        'state': lambda *a: "draft",
+        'active': lambda *a: True,
+        'priority': lambda *a: 5,
+        'date': lambda *a: time.strftime('%Y-%m-%d'),
+        'user_id': lambda self, cr, uid, ctx: uid,
     }
 
     def check_duplicate(self, cr, uid, ids):
@@ -98,8 +98,6 @@ class email_server(osv.osv):
 
     def button_fetch_mail(self, cr, uid, ids, context={}):
         self.fetch_mail(cr, uid, ids)
-#        sendmail_thread = threading.Thread(target=self.fetch_mail, args=(cr, uid, ids))
-#        sendmail_thread.start()
         return True
 
     def _fetch_mails(self, cr, uid, ids=False, context={}):
@@ -125,7 +123,7 @@ class email_server(osv.osv):
 
                     imap_server.login(server.user, server.password)
                     imap_server.select()
-                    result, data = imap_server.search(None, '(UNSEEN)')                    
+                    result, data = imap_server.search(None, '(UNSEEN)')
                     for num in data[0].split():
                         result, data = imap_server.fetch(num, '(RFC822)')
                         res_id = email_tool.process_email(cr, uid, server.object_id.model, data[0][1], attach=server.attach, context=context)
@@ -180,11 +178,11 @@ class mailgate_message(osv.osv):
     _inherit = "mailgate.message"
 
     _columns = {
-        'server_id': fields.many2one('email.server', "Mail Server", readonly=True, select=True), 
+        'server_id': fields.many2one('email.server', "Mail Server", readonly=True, select=True),
         'type':fields.selection([
-            ('pop', 'POP Server'), 
-            ('imap', 'IMAP Server'), 
-        ], 'Server Type', select=True, readonly=True), 
+            ('pop', 'POP Server'),
+            ('imap', 'IMAP Server'),
+        ], 'Server Type', select=True, readonly=True),
     }
     _order = 'id desc'
 
index 2e4b376..e8e2251 100644 (file)
@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 ##############################################################################
-#    
+#
 #    OpenERP, Open Source Management Solution
 #    Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
 #
@@ -15,7 +15,7 @@
 #    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/>.     
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #
 ##############################################################################
 
@@ -26,8 +26,6 @@ class res_partner_address(osv.osv):
     _name = 'res.partner.address'
     _inherit = 'res.partner.address'
     _columns = {
-#       'google_map': fields.function(_get_url, method=True,
-#           string='Google Map', type='char',),
         }
 res_partner_address()
 # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
index fb9dcb4..596bb80 100644 (file)
@@ -125,7 +125,6 @@ class res_users(osv.osv):
                         JOIN hr_department as dept ON dept.id = emp.department_id \
                         WHERE res.user_id = %s AND emp.department_id IS NOT NULL AND dept.manager_id IS NOT NULL', (user_id,))
             ids_dept = [x[0] for x in cr.fetchall()]
-#            ids_dept = obj_dept.search(cr, uid, [('member_ids', 'in', [user_id])], context=context)
             parent_ids = []
             if ids_dept:
                 data_dept = obj_dept.read(cr, uid, ids_dept, ['manager_id'], context=context)
@@ -162,7 +161,6 @@ class res_users(osv.osv):
                             (SELECT emp.id FROM hr_employee \
                                 JOIN resource_resource r ON r.id = emp.resource_id WHERE r.user_id=' + str(user_id) + ') ')
             mgnt_dept_ids = [x[0] for x in cr.fetchall()]
-#            mgnt_dept_ids = obj_dept.search(cr, uid, [('manager_id', '=', user_id)], context=context)
             ids_dept = obj_dept.search(cr, uid, [('id', 'child_of', mgnt_dept_ids)], context=context)
             if ids_dept:
                 data_dept = obj_dept.read(cr, uid, ids_dept, ['member_ids'], context=context)
index d8ce599..5ebf9b8 100644 (file)
             <field name="res_model">hr.employee</field>
             <field name="view_type">form</field>
             <field name="view_mode">tree,form</field>
-<!--            <field name="domain">[('category_id','child_of',[active_id])]</field>-->
-<!--            <field name="context">{'category_id':active_id}</field>-->
         </record>
 
         <record id="hr_employee_category_open" model="ir.values">
index 2c0455e..b0113aa 100644 (file)
@@ -1,6 +1,6 @@
 # -*- coding: utf-8 -*-
 ##############################################################################
-#    
+#
 #    OpenERP, Open Source Management Solution
 #    Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
 #
@@ -15,7 +15,7 @@
 #    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/>.     
+#    along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #
 ##############################################################################
 
@@ -37,17 +37,8 @@ class attendance_print(report_sxw.rml_parse):
 
     def _get_employees(self, emp_ids):
         emp_obj_list = self.pool.get('hr.employee').browse(self.cr, self.uid, emp_ids)
-        return emp_obj_list    
-        
-#    def _sign(self, dt):
-#        if abs(dt.days) > 1:
-#            format = '%d day'+(((abs(dt.days)>=2) and 's') or '')+' %H:%M:%S'
-#        else:
-#            format = '%H:%M:%S'
-#        if dt.seconds<0:
-#            return dt.strftime('- '+format)
-#        else:
-#            return dt.strftime(format)
+        return emp_obj_list
+
 
     def _lst(self, employee_id, dt_from, dt_to, max, *args):
         self.cr.execute("select name as date, create_date, action, create_date-name as delay from hr_attendance where employee_id=%s and to_char(name,'YYYY-mm-dd')<=%s and to_char(name,'YYYY-mm-dd')>=%s and action IN (%s,%s) order by name", (employee_id, dt_to, dt_from, 'sign_in', 'sign_out'))
@@ -57,7 +48,6 @@ class attendance_print(report_sxw.rml_parse):
                 r['delay'] = -r['delay']
             temp = r['delay'].seconds
 
-#            r['delay'] = self._sign(r['delay'])
             r['delay'] = str(r['delay']).split('.')[0]
             if abs(temp) < max*60:
                 r['delay2'] = r['delay']
@@ -78,14 +68,13 @@ class attendance_print(report_sxw.rml_parse):
             total += r['delay']
             if abs(r['delay'].seconds) < max*60:
                 total2 += r['delay']
-        
+
         result_dict = {
                 'total': total and str(total).split('.')[0],
                 'total2': total2  and str(total2).split('.')[0]
                 }
-#        return (self._sign(total),total2 and self._sign(total2))
         return [result_dict]
-    
+
 report_sxw.report_sxw('report.hr.attendance.error', 'hr.employee', 'addons/hr_attendance/report/attendance_errors.rml', parser=attendance_print, header=2)
 
 # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
index ed7ff7a..b87a390 100644 (file)
@@ -2,45 +2,5 @@
 <openerp>
     <data>
 
-       <!--<record id="view_hr_attendance_week" model="ir.ui.view">
-            <field name="name">Attendance Report Week</field>
-            <field name="model">hr.attendance.week</field>
-            <field name="type">form</field>
-            <field name="arch" type="xml">
-                       <form string="Print Attendance Report Weekly">
-                           <group col="4" colspan="6">
-                       <separator string="Select a starting and a end date" colspan="4"/>
-                           <field name="init_date"/>
-                           <field name="end_date"/>
-                           <newline/>
-                               </group>
-                               <separator colspan="4"/>
-                           <group col="2" colspan="4">
-                       <button special="cancel"  string="Cancel" icon='gtk-cancel'/>
-                                       <button name="print_report" string="Print" colspan="1" type="object"  icon="gtk-yes"/>
-                               </group>
-                       </form>
-            </field>
-        </record>
-
-        <record id="action_hr_attendance_week" model="ir.actions.act_window">
-            <field name="name">Print Timesheet by week</field>
-            <field name="type">ir.actions.act_window</field>
-            <field name="res_model">hr.attendance.week</field>
-            <field name="view_type">form</field>
-            <field name="view_mode">form</field>
-            <field name="target">new</field>
-        </record>
-
-               <record model="ir.values" id="hr_attendance_week_values">
-            <field name="model_id" ref="hr.model_hr_employee" />
-            <field name="object" eval="1" />
-            <field name="name">Print Timesheet by week</field>
-            <field name="key2">client_print_multi</field>
-            <field name="value" eval="'ir.actions.act_window,' + str(ref('action_hr_attendance_week'))" />
-            <field name="key">action</field>
-            <field name="model">hr.employee</field>
-        </record> -->
-
        </data>
 </openerp>
index 2c5b290..eaad7d3 100644 (file)
     </data>
 
     <data>
-        <!--record id="survey_question_7" model="survey.question">
-            <field name="in_visible_answer_type">1</field>
-            <field name="validation_type">do_not_validate</field>
-            <field name="comment_valid_type">do_not_validate</field>
-            <field name="make_comment_field_err_msg">Please enter a comment.</field>
-            <field name="numeric_required_sum_err_msg">The choices need to add up to [enter sum here].</field>
-            <field eval="0" name="comment_column"/>
-            <field name="validation_valid_err_msg">The comment you entered is in an invalid format.</field>
-            <field eval="0" name="rating_allow_one_column_require"/>
-            <field name="req_error_msg">This question requires an answer.</field>
-            <field eval="2" name="sequence"/>
-            <field name="question">Process</field>
-            <field eval="0" name="is_require_answer"/>
-            <field name="type">comment</field>
-            <field name="comment_valid_err_msg">The comment you entered is in an invalid format.</field>
-            <field eval="0" name="make_comment_field"/>
-            <field eval="0" name="in_visible_menu_choice"/>
-            <field name="page_id" ref="survey_page_2"/>
-            <field name="comment_label">Other</field>
-            <field eval="0" name="in_visible_rating_weight"/>
-            <field eval="0" name="allow_comment"/>
-        </record-->
     </data>
 
     <data>
@@ -587,49 +565,6 @@ Once the form had been filled, the employee send it to his supervisor.
         </record>
     </data>
 
-    <!--data>
-        <record id="survey_question_42" model="survey.question">
-            <field name="in_visible_answer_type">1</field>
-            <field name="validation_type">do_not_validate</field>
-            <field name="comment_valid_type">do_not_validate</field>
-            <field name="make_comment_field_err_msg">Please enter a comment.</field>
-            <field name="numeric_required_sum_err_msg">The choices need to add up to [enter sum here].</field>
-            <field eval="0" name="comment_column"/>
-            <field name="validation_valid_err_msg">The comment you entered is in an invalid format.</field>
-            <field eval="0" name="rating_allow_one_column_require"/>
-            <field name="req_error_msg">This question requires an answer.</field>
-            <field eval="3" name="sequence"/>
-            <field name="question">Evaluation Process</field>
-            <field eval="0" name="is_require_answer"/>
-            <field name="type">descriptive_text</field>
-            <field name="comment_valid_err_msg">The comment you entered is in an invalid format.</field>
-            <field name="descriptive_text">1). At the outset of the appraisal time period:
-
-     * It is the joint responsibility of the employee and the supervisor (appraiser) to establish a feasible work plan for the coming year, including major employee responsibilities and corresponding benchmarks against which results will be evaluated.
-
-     * Critical or key elements of performance and professional development needs (if any), should also be noted at this time
-
-2). At the conclusion of the appraisal time period:
-
-     * The employee will be responsible for completing a draft of the Appraisal Form as a tool for self-evaluation and a starting point for the supervisor’s evaluation. The employee can add examples of achievements for each criterion.
-Once the form had been filled, the employee send it to his supervisor.
-
-     * It is the primary responsibility of the supervisor to gather the necessary input from the appropriate sources of feedback (internal and/or external customers, peers). In case of collaboration with OpenERP SA Belgium, the supervisor must receive completed evaluation form from the employee's Belgian project manager.
-
-     * The supervisor synthesizes and integrates all input into the completed appraisal. He motivates his evaluation in the ad hoc fields.
-
-     * The employee may choose to offer comments or explanation regarding the completed review.
-
-     * The supervisor send the form to the HR department in India and in Belgium.
-</field>
-            <field eval="0" name="make_comment_field"/>
-            <field eval="1" name="in_visible_menu_choice"/>
-            <field name="page_id" ref="hr_evaluation.survey_page_1"/>
-            <field name="comment_label">Other</field>
-            <field eval="1" name="in_visible_rating_weight"/>
-            <field eval="0" name="allow_comment"/>
-        </record>
-    </data-->
 
     <data>
         <record id="survey_question_17_1" model="survey.question">
@@ -1589,16 +1524,6 @@ Once the form had been filled, the employee send it to his supervisor.
         </record>
     </data>
 
-<!--    <data noupdate="1">-->
-<!--        <record id="survey_request_1" model="survey.request">-->
-<!--            <field name="state">waiting_answer</field>-->
-<!--            <field name="survey_id" ref="hr_evaluation.survey_2"/>-->
-<!--            <field name="user_id" ref="base.user_root"/>-->
-<!--            <field name="email">fp@tinyerp.com</field>-->
-<!--            <field name="date_deadline">2010-02-21</field>-->
-<!--        </record>-->
-<!--    </data>-->
-
     <data noupdate="1">
         <record id="hr_evaluation_plan_managersevaluationplan0" model="hr_evaluation.plan">
             <field eval="1" name="active"/>
@@ -1673,28 +1598,6 @@ Once the form had been filled, the employee send it to his supervisor.
         </record>
     </data>
 
-<!--    <data noupdate="1">-->
-<!--        <record id="hr_evaluation_interview_1" model="survey.request">-->
-<!--            <field name="state">waiting_answer</field>-->
-<!--            <field name="survey_id" ref="hr_evaluation.survey_2"/>-->
-<!--            <field name="user_id" ref="base.user_root"/>-->
-<!--            <field name="email">fp@tinyerp.com</field>-->
-<!--            <field name="date_deadline">2010-02-21</field>-->
-<!--        </record>-->
-<!--    </data>-->
-<!--    <data noupdate="1">-->
-<!--        <record id="hr_evaluation_evaluation_0" model="hr_evaluation.evaluation">-->
-<!--            <field name="rating">0</field>-->
-<!--            <field name="employee_id" ref="hr.employee1"/>-->
-<!--            <field name="plan_id" ref="hr_evaluation_plan_managersevaluationplan0"/>-->
-<!--            <field name="state">draft</field>-->
-<!--            <field eval="[(6,0,[ref('hr_evaluation_interview_1')])]" name="survey_request_ids"/>-->
-<!--            <field name="date">2010-01-21</field>-->
-<!--            <field name="phase_id" ref="hr_evaluation_plan_phase_sendtomanagers0"/>-->
-<!--            <field name="manager_id" ref="base.user_root"/>-->
-<!--        </record>-->
-<!--    </data>-->
-
                <data>
                  <record forcecreate="True" id="ir_cron_scheduler_evaluation" model="ir.cron">
                   <field name="name">Run Employee Evaluation</field>
index 440b1ef..45efab6 100644 (file)
             <field name="type">tree</field>
             <field name="arch" type="xml">
                 <tree colors="blue:state in ('draft');black:state in ('wait','progress');gray:state in('done','cancel')" string="Evaluation">
-                    <!--field name="create_date"/-->
                     <field name="employee_id"/>
                     <field name="plan_id"/>
                     <field name="date"/>
                     <separator string="State" colspan="4"/>
                     <group colspan="4" col="6">
                          <field name="state"/>
-                         <!--<button name="survey_req_draft" string="Set to Draft" states="cancel,done" type="object" icon="gtk-new"/>
-                        <button name="survey_req_waiting_answer" string="Waiting Answer" states="draft" type="object" icon="gtk-new"/>
-                        <button name="survey_req_done" string="Done" states="waiting_answer" type="object" icon="gtk-ok"/>
-                        <button name="survey_req_cancel" string="Cancelled" states="waiting_answer" type="object" icon="gtk-cancel"/>-->
                     </group>
                 </form>
             </field>
index 109e658..aa45f4a 100644 (file)
@@ -54,9 +54,8 @@
         ],
     'demo_xml': [
         'hr_expense_demo.xml',
-#       'hr.expense.expense.csv'
         ],
-    'test': ['test/test_hr_expense.yml'],            
+    'test': ['test/test_hr_expense.yml'],
     'installable': True,
     'active': False,
     'certificate': '0062479841789',
index 48ace8a..681a06c 100644 (file)
@@ -98,7 +98,6 @@ class hr_expense_expense(osv.osv):
         'company_id': lambda self, cr, uid, c: self.pool.get('res.users').browse(cr, uid, uid, c).company_id.id,
     }
     def expense_confirm(self, cr, uid, ids, *args):
-        #for exp in self.browse(cr, uid, ids):
         self.write(cr, uid, ids, {
             'state':'confirm',
             'date_confirm': time.strftime('%Y-%m-%d')
index 972cdca..cfeee83 100644 (file)
@@ -55,7 +55,6 @@
             <field name="name">refused</field>
             <field name="kind">function</field>
             <field name="action">expense_canceled()</field>
-<!--            <field name="flow_stop">True</field>-->
         </record>
 
         <record id="act_invoice" model="workflow.activity">
             <field name="role_id" ref="HR"/>
         </record>
 
-        <!--record model="workflow.transition" id="t3">
-                       <field name="act_from" ref="act_accepted" />
-                       <field name="act_to" ref="act_paid" />
-                       <field name="signal">paid</field>
-                       <field name="role_id" ref="HR"/>
-               </record-->
-
         <record id="t4" model="workflow.transition">
             <field name="act_from" ref="act_confirm"/>
             <field name="act_to" ref="act_refused"/>
index e093526..7d68b21 100644 (file)
@@ -29,7 +29,7 @@
     "description": """Human Ressources: Holidays tracking and workflow
 
     This module allows you to manage leaves and leaves requests.
-    Implements a dashboard for human resource management that includes.     
+    Implements a dashboard for human resource management that includes.
         * My Leaves
         * My Expenses
     Note that:
@@ -63,7 +63,6 @@
         'wizard/hr_holidays_summary_department_view.xml',
         'wizard/hr_holidays_summary_employees_view.xml',
         'board_hr_holidays_view.xml',
-        #'process/hr_holidays_process.xml'
         ],
     'demo_xml': ['hr_holidays_demo.xml',],
     'test': ['test/test_hr_holiday.yml'],
index 3a628b1..efd5df4 100644 (file)
@@ -430,20 +430,6 @@ class hr_holidays(osv.osv):
                 self.holidays_confirm(cr, uid, holiday_ids)
                 self.holidays_validate(cr, uid, holiday_ids)
 
-            #if record.holiday_status_id.categ_id and record.date_from and record.date_to and record.employee_id:
-#            if record.holiday_status_id.categ_id and record.date_from and record.date_to:
-#                vals={}
-#                vals['name']=record.name
-#                vals['categ_id']=record.holiday_status_id.categ_id.id
-#                epoch_c = time.mktime(time.strptime(record.date_to,'%Y-%m-%d %H:%M:%S'))
-#                epoch_d = time.mktime(time.strptime(record.date_from,'%Y-%m-%d %H:%M:%S'))
-#                diff_day = (epoch_c - epoch_d)/(3600*24)
-#                vals['duration'] = (diff_day) * 8
-#                vals['note'] = record.notes
-##                vals['user_id'] = record.user_id.id
-#                vals['date'] = record.date_from
-#                if record.holiday_type=='employee':
-#                    vals['user_id'] = record.user_id.id
             if record.holiday_status_id.categ_id and record.date_from and record.date_to and record.employee_id:
                 diff_day = self._get_number_of_days(record.date_from, record.date_to)
                 vals = {
index b29bf56..38d9b81 100644 (file)
@@ -36,7 +36,7 @@
         </record>
 
         <!-- Holidays: Leave Request -->
-        
+
         <record id="view_holiday_new_calendar" model="ir.ui.view">
             <field name="name">Leave Request</field>
             <field name="model">hr.holidays</field>
@@ -47,7 +47,7 @@
                 </calendar>
             </field>
         </record>
-    
+
         <record model="ir.ui.view" id="edit_holiday_new">
             <field name="name">Leave Request</field>
             <field name="model">hr.holidays</field>
                 <form string="Leaves Management">
                     <field name="name" />
                     <field name="holiday_status_id" />
-<!--                    <field name="holiday_type"/>
-                    <field name="category_id" required="1"/>
--->                    <field name="employee_id"  />
-                    <!--<field name="department_id"/>-->
                     <field name="type"/>
                     <field name="date_from" on_change="onchange_date_from(date_to, date_from)" attrs="{'readonly':[('type','=','add')], 'required':[('type','=','remove')]}"/>
                     <field name="date_to" on_change="onchange_date_to(date_from, date_to)" attrs="{'readonly':[('type','=','add')], 'required':[('type','=','remove')]}"/>
         </record>
 
         <!-- My leave dashboard -->
-<!--        <record model="ir.ui.view" id="view_my_leave_board_form">
-            <field name="name">hr.holidays.per.user.form</field>
-            <field name="model">hr.holidays.per.user</field>
-            <field name="type">form</field>
-            <field name="arch" type="xml">
-                <form string="My Leaves" >
-                    <field name="employee_id"/>
-                    <field name="user_id"/>
-                    <field name="holiday_status"/>
-                    <field name="max_leaves"/>
-                    <field name="leaves_taken" />
-                    <field name="remaining_leaves"/>
-                    <field name="notes" colspan="4"/>
-                </form>
-            </field>
-        </record>
--->
         <menuitem
             name="Holidays"
             parent="hr.menu_hr_root"
index b6b036e..6dcd55f 100644 (file)
         <field name="signal">second_validate</field>
     </record>
 
-    <!--<record model="workflow.transition" id="t9">
-        <field name="act_from" ref="act_validate" />
-        <field name="act_to" ref="act_refuse" />
-        <field name="signal">refuse</field>
-    </record>-->
-
     <record model="workflow.transition" id="t10">
         <field name="act_from" ref="act_validate1" />
         <field name="act_to" ref="act_refuse" />
index 5b14835..f3a17be 100644 (file)
@@ -232,14 +232,10 @@ class report_custom(report_rml):
                     emp_id[d] = obj_emp.search(cr, uid, [('user_id', '=', result[d][0])])
                     items = obj_emp.read(cr, uid, emp_id[d], ['id', 'name'])
                     for item in items:
-#                        if item['id'] in done:
-#                            continue
-#                        else:
                         if dept_done==0:
                             emp_xml += emp_create_xml(self, cr, uid, 1, holiday_type, row_id, dept.id, dept.name, som, eom)
                             row_id = row_id +1
                         dept_done=1
-#                        done[item['id']] = 1
                         emp_xml += emp_create_xml(self, cr, uid, 0, holiday_type, row_id, item['id'], item['name'], som, eom)
                         row_id = row_id +1
         # Computing the xml
index 0e5513b..7a6eaf1 100644 (file)
@@ -192,7 +192,6 @@ class payroll_register(osv.osv):
         'journal_id': fields.many2one('account.journal', 'Expanse Journal', required=True),
         'bank_journal_id': fields.many2one('account.journal', 'Bank Journal', required=True),
         'active':fields.boolean('Active', required=False),
-#        'advice_ids':fields.one2many('hr.payroll.advice', 'register_id', 'Bank Advice'),
         'company_id':fields.many2one('res.company', 'Company', required=False),
         'period_id': fields.many2one('account.period', 'Force Period', domain=[('state','<>','done')], help="Keep empty to use the period of the validation(Payslip) date."),
         'grows': fields.function(_calculate, method=True, store=True, multi='dc', string='Gross Salary', type='float', digits=(16, 4)),
@@ -301,7 +300,6 @@ class payroll_register(osv.osv):
                 }
                 id = advice_line_pool.create(cr, uid, pline, context=context)
 
-        #, 'advice_ids':[(6, 0, [pid])]
         self.write(cr, uid, ids, {'state':'confirm'}, context=context)
         return True
 
@@ -568,7 +566,6 @@ class company_contribution(osv.osv):
         'category_id':fields.many2one('hr.allounce.deduction.categoty', 'Heads', required=False),
         'name':fields.char('Name', size=256, required=True, readonly=False),
         'code':fields.char('Code', size=64, required=True, readonly=False),
-#        'include_in_salary':fields.boolean('Included in Salary ?', help='If company contribute on this deduction then should company contribution is also deducted from Employee Salary'),
         'gratuity':fields.boolean('Use for Gratuity ?', required=False),
         'line_ids':fields.one2many('company.contribution.line', 'contribution_id', 'Calculations', required=False),
         'register_id':fields.property(
@@ -587,16 +584,6 @@ class company_contribution(osv.osv):
             ('func','Function Calculation'),
         ],'Amount Type', select=True),
         'contribute_per':fields.float('Contribution', digits=(16, 4), help='Define Company contribution ratio 1.00=100% contribution, If Employee Contribute 5% then company will and here 0.50 defined then company will contribute 50% on employee 5% contribution'),
-#        'account_id':fields.property(
-#            'account.account',
-#            type='many2one',
-#            relation='account.account',
-#            string="Account",
-#            method=True,
-#            view_load=True,
-#            help="Expanse account where company expanse will be encoded",
-#            required=False
-#        ),
         'company_id':fields.many2one('res.company', 'Company', required=False),
         'active':fields.boolean('Active', required=False),
         'note': fields.text('Description'),
@@ -730,8 +717,6 @@ class hr_payslip(osv.osv):
                 obj[cd] = amount
 
                 contrib = 0.0
-#                if line.category_id.include_in_salary:
-#                    contrib = line.company_contrib
 
                 if line.type == 'allowance':
                     allow += amount
index 807e83d..fbfa2d1 100644 (file)
                         <group colspan="2" col="2">
                             <separator string="Personal Info" colspan="2"/>
                             <field name="pan_no" select="1"/>
-<!--                            <field name="bank_account"/>-->
                             <field name="bank_account_id"/>
                             <field name="place_of_birth"/>
                             <field name="children"/>
                         <separator colspan="2" string="Other Information"/>
                         <field name="company_id" select="1"/>
                         <field name="active" select="1"/>
-<!--                        <field name="include_in_salary" />-->
-<!--                        <field name="account_id" attrs="{'required': [('include_in_salary','=',True)]}"/>-->
                     </group>
                     <notebook colspan="4">
                         <page string="Function" attrs="{'readonly': [('amount_type','!=','func')]}">
         />
         <!-- End Company Contribution -->
 
-        <!-- Contract Form-->
-<!--        <record id="hr_contract.hr_contract_view_form" model="ir.ui.view">-->
-<!--            <field name="name">hr.contract.view.form</field>-->
-<!--            <field name="model">hr.contract</field>-->
-<!--            <field name="type">form</field>-->
-<!--            <field name="arch" type="xml">-->
-<!--                <form string="Contract">-->
-<!--                    <field name="employee_id"/>-->
-<!--                    <separator colspan="4" string="General Information"/>-->
-<!--                    <field colspan="4" name="name" select="1"/>-->
-<!--                    <newline/>-->
-<!--                    <separator colspan="4" string="Contract Duration"/>-->
-<!--                    <field name="function"/>-->
-<!--                    <field name="working_hours_per_day"/>-->
-<!--                    <field name="working_days_per_week"/>-->
-<!--                    <field name="date_start" select="1"/>-->
-<!--                    <field name="date_end" select="1"/>-->
-<!--                    -->
-<!--                    <separator colspan="4" string="Salary"/>-->
-<!--                    <field name="wage_type_id"/>-->
-<!--                    <field name="wage"/>-->
-<!--                    -->
-<!--                    <separator colspan="4" string="Notes"/>-->
-<!--                    <field colspan="4" name="notes" nolabel="1"/>-->
-<!--                    -->
-<!--                    <separator colspan="4" string="Passport and Visa"/>-->
-<!--                    <field name="permit_no"/>-->
-<!--                    <field name="passport_id"/>-->
-<!--                    <field name="visa_no"/>-->
-<!--                    <field name="visa_expire"/>-->
-<!--                </form>-->
-<!--            </field>-->
-<!--        </record>-->
-<!--        <record id="action_hr_contract" model="ir.actions.act_window">-->
-<!--            <field name="name">Employee Contract</field>-->
-<!--            <field name="res_model">hr.contract</field>-->
-<!--            <field name="view_type">form</field>-->
-<!--            <field name="view_mode">form,tree</field>-->
-<!--        </record>-->
-<!--        <menuitem -->
-<!--            action="action_hr_contract" -->
-<!--            name="Employee Contract" -->
-<!--            id="hr_menu_contract" -->
-<!--            parent="payroll_configure"-->
-<!--        />-->
-
         <record id="view_hr_bank_advice_tree" model="ir.ui.view">
             <field name="name">hr.payroll.advice.tree</field>
             <field name="model">hr.payroll.advice</field>
index beeb6de..550c77c 100755 (executable)
@@ -41,7 +41,6 @@ class rml_parse(report_sxw.rml_parse):
         })
 
     def comma_me(self,amount):
-        #print "#" + str(amount) + "#"
         if not amount:
             amount = 0.0
         if  type(amount) is float :
@@ -105,9 +104,8 @@ class rml_parse(report_sxw.rml_parse):
         else:
             return Stringer
         return Stringer
-    
+
     def explode_this(self,chaine,length):
-        #chaine = self.repair_string(chaine)
         chaine = rstrip(chaine)
         ast = list(chaine)
         i = length
@@ -116,13 +114,12 @@ class rml_parse(report_sxw.rml_parse):
             i = i + length
         chaine = str("".join(ast))
         return chaine
-    
+
     def repair_string(self,chaine):
         ast = list(chaine)
         UnicodeAst = []
         _previouslyfound = False
         i = 0
-        #print str(ast)
         while i < len(ast):
             elem = ast[i]
             try:
index bbbd263..8ef12aa 100644 (file)
             <field name="view_mode">form</field>
             <field name="target">new</field>
         </record>
-       <!-- <menuitem  id="menu_wizard_payroll_analysis" 
-            action="action_view_hr_payroll_create" 
-            parent="payroll_configure" 
-            name="Create Analytic Structure" />-->
 
        </data>
 </openerp>
\ No newline at end of file
index f07a049..f5a6897 100644 (file)
@@ -133,7 +133,6 @@ class hr_payslip(osv.osv):
             ded_rec = {
                 'move_id':move_id,
                 'name': name,
-                #'partner_id': partner_id,
                 'date': slip.date,
                 'account_id': slip.employee_id.property_bank_account.id,
                 'debit': 0.0,
@@ -293,7 +292,6 @@ class hr_payslip(osv.osv):
                 period_id = search_periods[0]
 
             move = {
-                #'name': slip.name,
                 'journal_id': slip.journal_id.id,
                 'period_id': period_id,
                 'date': slip.date,
@@ -409,140 +407,6 @@ class hr_payslip(osv.osv):
                 for contrub in line.category_id.contribute_ids:
                     print contrib.name, contrub.code, contrub.amount_type, contrib.contribute_per, line.total
 
-
-
-#                if line.company_contrib > 0:
-#                    company_contrib = line.company_contrib
-##                    if line.category_id.amount_type == 'per':
-##                        company_contrib = (amount * line.category_id.contribute_per)
-
-#                    narration = """Company Contribution of %s Encode same as a Company Expanse @ %s""" % (line.name, company_contrib)
-#                    move = {
-#                        #'name': slip.name,
-#                        'journal_id': slip.journal_id.id,
-#                        'period_id': period_id,
-#                        'date': slip.date,
-#                        'ref':slip.number,
-#                        'narration': narration
-#                    }
-#                    company_contrib_move_id = move_pool.create(cr, uid, move)
-#                    name = "[%s] - %s / %s - Company Contribution" % (line.code, line.name, slip.employee_id.name)
-#                    self.create_voucher(cr, uid, [slip.id], name, company_contrib_move_id)
-#
-#                    ded_deb = {
-#                        'move_id':company_contrib_move_id,
-#                        'name': name,
-#                        'date': slip.date,
-#                        'quantity':1,
-#                        'account_id': line.category_id.account_id.id,
-#                        'debit': company_contrib,
-#                        'credit' : 0.0,
-#                        'journal_id': slip.journal_id.id,
-#                        'period_id': period_id,
-#                        'ref':slip.number
-#                    }
-#                    line_ids += [movel_pool.create(cr, uid, ded_deb)]
-#                    ded_cre = {
-#                        'move_id':company_contrib_move_id,
-#                        'name': name,
-#                        'date': slip.date,
-#                        'quantity':1,
-#                        'account_id': line.category_id.register_id.account_id.id,
-#                        'debit': 0.0,
-#                        'credit' : company_contrib,
-#                        'journal_id': slip.journal_id.id,
-#                        'period_id': period_id,
-#                        'ref':slip.number
-#                    }
-#                    line_ids += [movel_pool.create(cr, uid, ded_cre)]
-#
-#                    if line.category_id.include_in_salary:
-#                        narration = """Company Contribution of %s Deducted from Employee %s""" % (line.name, company_contrib)
-#                        move = {
-#                            #'name': slip.name,
-#                            'journal_id': slip.journal_id.id,
-#                            'period_id': period_id,
-#                            'date': slip.date,
-#                            'ref':slip.number,
-#                            'narration': narration
-#                        }
-#                        include_in_salary_move_id = move_pool.create(cr, uid, move)
-#                        self.create_voucher(cr, uid, [slip.id], narration, include_in_salary_move_id)
-#
-#                        total_deduct += company_contrib
-#                        ded_deb = {
-#                            'move_id':include_in_salary_move_id,
-#                            'name': name,
-#                            'partner_id': partner_id,
-#                            'date': slip.date,
-#                            'quantity':1,
-#                            'account_id': partner.property_account_receivable.id,
-#                            'debit': company_contrib,
-#                            'credit' : 0.0,
-#                            'journal_id': slip.journal_id.id,
-#                            'period_id': period_id,
-#                            'ref':slip.number
-#                        }
-#                        line_ids += [movel_pool.create(cr, uid, ded_deb)]
-#                        ded_cre = {
-#                            'move_id':include_in_salary_move_id,
-#                            'name': name,
-#                            'date': slip.date,
-#                            'quantity':1,
-#                            'account_id': line.category_id.account_id.id,
-#                            'debit': 0.0,
-#                            'credit' : company_contrib,
-#                            'journal_id': slip.journal_id.id,
-#                            'period_id': period_id,
-#                            'ref':slip.number
-#                        }
-#                        line_ids += [movel_pool.create(cr, uid, ded_cre)]
-
-                #make an entry line to contribution register
-#                if line.category_id.register_id:
-#                    ctr = {
-#                        'register_id':line.category_id.register_id.id,
-#                        'name':line.name,
-#                        'code':line.code,
-#                        'employee_id':slip.employee_id.id,
-#                        'period_id':period_id,
-#                        'emp_deduction':amount,
-#                    }
-#                    if line.category_id.contribute:
-#                        ctr['comp_deduction'] = amount
-#
-#                    company = 0.0
-#                    employee = 0.0
-#                    if line.category_id.contribute and line.category_id.include_in_salary and line.category_id.amount_type == 'per':
-#                        new_amount = (amount * (line.category_id.contribute_per / (1+line.category_id.contribute_per)))
-#                        company = new_amount
-#                        employee = amount - company
-#
-#                    elif line.category_id.contribute and line.category_id.include_in_salary and line.category_id.amount_type == 'fix':
-#                        company = line.category_id.contribute_per
-#                        employee = amount - company
-
-#                    elif line.category_id.contribute and line.category_id.include_in_salary and line.category_id.amount_type == 'func':
-#                        company = self.pool.get('hr.allounce.deduction.categoty').execute_function(cr, uid, line.category_id.id, line.slip_id.basic, context)
-#                        employee = amount
-#
-#                    elif line.category_id.contribute and not line.category_id.include_in_salary and line.category_id.amount_type == 'per':
-#                        company = amount * line.category_id.contribute_per
-#                        employee = amount
-#
-#                    elif line.category_id.contribute and not line.category_id.include_in_salary and line.category_id.amount_type == 'fix':
-#                        company = line.category_id.contribute_per
-#                        employee = amount
-
-#                    elif line.category_id.contribute and not line.category_id.include_in_salary and line.category_id.amount_type == 'func':
-#                        company = self.pool.get('hr.allounce.deduction.categoty').execute_function(cr, uid, line.category_id.id, line.slip_id.basic, context)
-#                        employee = amount
-#
-#                    ctr['emp_deduction'] = employee
-#                    ctr['comp_deduction'] = company
-#
-#                    self.pool.get('hr.contibution.register.line').create(cr, uid, ctr)
-
             adj_move_id = False
             if total_deduct > 0:
                 move = {
index 084e811..e740aff 100644 (file)
@@ -39,7 +39,6 @@ system to store and search in your CV base.
         'wizard/hr_recruitment_create_partner_job_view.xml',
         'hr_recruitment_view.xml',
         'hr_recruitment_menu.xml',
-#        'report_hr_recruitment_view.xml',
         'security/hr_recruitment_security.xml',
         'security/ir.model.access.csv',
         'board_hr_recruitment_statistical_view.xml',
index 4a8cd5d..1532c03 100644 (file)
@@ -174,7 +174,6 @@ class hr_applicant(crm.crm_case, osv.osv):
         'active': lambda *a: 1,
         'stage_id': _get_stage,
         'user_id':  lambda self, cr, uid, context: uid,
-#        'user_id': crm.crm_case._get_default_user,
         'email_from': crm.crm_case. _get_default_email,
         'state': lambda *a: 'draft',
         'company_id': lambda s, cr, uid, c: s.pool.get('res.company')._company_default_get(cr, uid, 'crm.helpdesk', context=c),
index 04ef6dc..ad7e293 100644 (file)
                             <button name="case_reset" string="Reset to New" states="done,cancel" type="object" icon="gtk-convert"/>
                         </group>
                    </page>
-<!--                <page string="History" groups="base.group_extended">
-                       <field name="id"/>
-                       <field name="active"/>
-                    </page>  -->
                    <page string="Emails" groups="base.group_extended">
                        <group colspan="4">
                            <field colspan="4" name="email_cc" string="Global CC" widget="char"/>
index 4d39171..99d064a 100644 (file)
@@ -68,7 +68,6 @@ class job2phonecall(osv.osv_memory):
         if context is None:
             context = {}
         form = self.read(cr, uid, ids, [], context=context)[0]
-#        form = data['form']
         result = mod_obj._get_id(cr, uid, 'crm', 'view_crm_case_phonecalls_filter')
         res = mod_obj.read(cr, uid, result, ['res_id'], context=context)
         # Select the view
@@ -88,7 +87,6 @@ class job2phonecall(osv.osv_memory):
                         'categ_id' : form['category_id'],
                         'description' : form['note'],
                         'date' : form['deadline'],
-#                        'section_id' : form['section_id'],
                         'description':job.description,
                         'partner_id':job.partner_id.id,
                         'partner_address_id':job.partner_address_id.id,
@@ -99,8 +97,6 @@ class job2phonecall(osv.osv_memory):
                     }, context=context)
             new_phonecall = phonecall_case_obj.browse(cr, uid, new_phonecall_id, context=context)
             vals = {}
-#            if not job.case_id:
-#                vals.update({'phonecall_id' : new_phonecall.id})
             job_case_obj.write(cr, uid, [job.id], vals, context=context)
             job_case_obj.case_cancel(cr, uid, [job.id])
             phonecall_case_obj.case_open(cr, uid, [new_phonecall_id])
index f7c1625..95fe9c8 100644 (file)
             <field name="target">new</field>
         </record>
 
-               <!--<record model="ir.values" id="hr_recruitment_phonecall_values">
-            <field name="model_id" ref="model_hr_applicant" />
-            <field name="object" eval="1" />
-            <field name="name">Schedule Phone Call</field>
-            <field name="key2">client_action_multi</field>
-            <field name="value" eval="'ir.actions.act_window,' + str(ref('action_hr_recruitment_phonecall'))" />
-            <field name="key">action</field>
-            <field name="model">hr.applicant</field>
-        </record>-->
-
        </data>
 </openerp>
\ No newline at end of file
index 0819725..3e5f6c2 100644 (file)
             sequence="5" />
         <report auto="False" id="report_user_timesheet" menu="False" model="hr.employee" name="hr.analytical.timesheet" string="Employee timesheet" xsl="hr_timesheet/report/user_timesheet.xsl"/>
 
-        <!--<wizard id="wizard_hr_timesheet" menu="False" model="hr.employee" name="hr.analytical.timesheet" string="Employee Timesheet"/>
--->
-        <!--<menuitem id="next_id_48" name="Timesheet" parent="hr.menu_hr_reporting"/>-->
-       <!-- <menuitem action="wizard_hr_timesheet" id="menu_wizard_hr_timesheet" parent="next_id_48" type="wizard"
-            groups="base.group_hr_manager"/>-->
-        <!--<menuitem action="wizard_hr_timesheet" id="menu_wizard_hr_timesheet" parent="menu_hr_reporting_timesheet" type="wizard"
-
-            groups="base.group_hr_manager"
-            />-->
-       <!-- <wizard id="wizard_hr_timesheet_my" menu="False" model="hr.employee" name="hr.analytical.timesheet.my" string="Print My Timesheet"/>
-        <menuitem
-            action="wizard_hr_timesheet_my"
-            id="menu_wizard_hr_timesheet_my"
-            parent="menu_hr_reporting_timesheet"
-            type="wizard"
-            groups="base.group_hr_user"
-            />-->
-
         <report auto="False" id="report_users_timesheet" menu="False" model="hr.employee" name="hr.analytical.timesheet_users" string="Employees Timesheet" xsl="hr_timesheet/report/users_timesheet.xsl"/>
 
         <wizard id="wizard_hr_timesheet_users" menu="False" model="hr.employee" name="hr.analytical.timesheet_users" string="Employees Timesheet"/>
-        <!--<menuitem
-            action="wizard_hr_timesheet_users"
-            id="menu_wizard_hr_timesheet_users"
-            groups="base.group_hr_manager"
-            parent="menu_hr_reporting_timesheet" type="wizard"/>
--->
     </data>
 </openerp>
index 97e6c4e..ff37a62 100644 (file)
@@ -68,8 +68,6 @@
 
         </record>
 
-      <!-- <menuitem id="menu_act_hr_timesheet_line_today_form" parent="hr.menu_hr_root" name="Working Hours" />-->
-
         <record id="act_hr_timesheet_line_me_all_form" model="ir.actions.act_window">
             <field name="name">My Working Hours</field>
             <field name="type">ir.actions.act_window</field>
index fa36c03..ebc0846 100644 (file)
@@ -1,8 +1,5 @@
 <?xml version="1.0" encoding="utf-8"?>
 <openerp>
-    <data><!--
-        <wizard id="si_so" name="hr_timesheet.si_so" string="Sign in / Sign out by project"/>
-        <menuitem action="si_so"  id="menu_si_so" parent="hr_attendance.menu_hr_time_tracking" type="wizard"/>
--->
+    <data>
     </data>
 </openerp>
index 1bb7aee..9b9efa3 100644 (file)
@@ -1,10 +1,6 @@
 <?xml version="1.0" ?>
 <openerp>
     <data>
-        
-        <!--        
-            Process
-        -->
-        
+
     </data>
 </openerp>
\ No newline at end of file
index 98c48e3..3b110b5 100644 (file)
            <field name="target">new</field>
         </record>
 
-        <!--menuitem action="action_hr_timesheet_my"
-               id="menu_hr_timesheet_my"
-               parent="menu_hr_reporting_timesheet"
-               groups="hr.group_hr_user" sequence="4" icon="STOCK_PRINT"/-->
-
     </data>
 </openerp>
index eed0e97..3463dc9 100644 (file)
@@ -6,15 +6,8 @@
             name="Reporting"
             parent="hr.menu_hr_root"
             sequence="10" />
-<!--        <menuitem-->
-<!--            id="menu_hr_reporting_timesheet_invoice"-->
-<!--            name="Timesheet Invoice"-->
-<!--            parent="hr.menu_hr_reporting"-->
-<!--            sequence="5" />-->
         <report auto="False" id="account_analytic_account_cost_ledger" menu="False" model="account.analytic.account" name="hr.timesheet.invoice.account.analytic.account.cost_ledger" rml="account/project/report/cost_ledger.rml" string="Cost Ledger"/>
 
-        <!--<wizard id="account_analytic_account_cost_ledger_report" keyword="client_print_multi" model="account.analytic.account" name="hr.timesheet.invoice.account.analytic.account.cost_ledger.report" string="Cost Ledger"/>-->
-
         <report
             auto="False"
             id="report_analytical_profit"
             rml="hr_timesheet_invoice/report/account_analytic_profit.rml"
             string="Timesheet Profit"/>
 
-        <!--<wizard
-            id="account_analytic_profit"
-            menu="False"
-            model="account.analytic.line"
-            name="account.analytic.profit"
-            string="Timesheet Profit"
-            groups="account.group_account_manager"/>
-
-       <menuitem action="account_analytic_profit"
-           id="print_account_analytic_profit"
-           parent="menu_hr_reporting_timesheet_invoice"
-           type="wizard"
-           groups="base.group_hr_manager"/>-->
-
     </data>
 </openerp>
index 50ca292..3081675 100644 (file)
@@ -1,8 +1,6 @@
 <?xml version="1.0" encoding="utf-8"?>
 <openerp>
     <data>
-<!--        <wizard id="hr_timesheet_invoice_create" model="account.analytic.line" name="hr.timesheet.invoice.create" string="Invoice analytic lines"/>-->
-        <!--<wizard id="hr_timesheet_final_invoice_create" model="account.analytic.account" name="hr.timesheet.final.invoice.create" string="Final Invoice"/>-->
 
     </data>
 </openerp>
index d4e25e0..163e641 100644 (file)
@@ -98,7 +98,6 @@
             <field name="context">{'search_default_month':1,'search_default_User':1,'search_default_user_id':uid,'group_by_no_leaf':1,'group_by':[]}</field>
             <field name="search_view_id" ref="view_timesheet_line_search"/>
         </record>
-        <!--menuitem action="action_timesheet_line_stat_all" id="menu_report_timesheet_line_all" parent="hr.menu_hr_reporting"/-->
 
 
         <!-- Statistics report on timesheet by user -->
             <field name="context">{"search_default_user_id":uid}</field>
             <field name="search_view_id" ref="view_timesheet_user_search"/>
         </record>
-        <!-- <menuitem action="action_timesheet_user_stat_all" id="menu_report_timesheet_user_all" parent="hr.menu_hr_reporting"/> -->
 
         <!-- Statistics report on timesheets to invoice -->
 
             <field name="context">{"search_default_user_id":uid}</field>
             <field name="search_view_id" ref="view_timesheet_invoice_search"/>
         </record>
-       <!--  <menuitem action="action_timesheet_invoice_stat_all" id="menu_report_timesheet_invoice_all" parent="hr.menu_hr_reporting"/> -->
 
         <!-- Statistics report on daily timesheets per account -->
 
             <field name="context">{"search_default_user_id":uid}</field>
             <field name="search_view_id" ref="view_timesheet_account_date_search"/>
         </record>
-        <!--  <menuitem action="action_timesheet_account_date_stat_all" id="menu_report_timesheet_account_date_all" parent="hr.menu_hr_reporting"/>-->
 
         <!-- Statistics report on timesheets per account -->
 
             <field name="view_mode">graph,tree</field>
             <field name="search_view_id" ref="view_timesheet_account_search"/>
         </record>
-        <!-- <menuitem action="action_timesheet_account_stat_all" id="menu_report_timesheet_account_all" parent="hr.menu_hr_reporting"/> -->
 
         <act_window domain="[('user_id', '=', active_id)]" id="act_res_users_2_report_timesheet_user" name="Timesheets per day" res_model="report_timesheet.user" src_model="res.users"/>
 
             <field name="view_id" ref="view_random_timesheet_lines_tree"/>
             <field name="search_view_id" ref="view_random_timesheet_lines_search"/>
         </record>
-         <!--Time Tracking menu in project Management-->
-<!--         <menuitem
-                icon="terp-project"
-                id="base.menu_main_pm"
-                name="Project"
-                sequence="10"/>
-         <menuitem
-                id="base.menu_project_management_time_tracking"
-                name="Time Tracking"
-                parent="base.menu_main_pm"
-                sequence="3"/>
-        <menuitem
-                action="action_random_timesheet_lines_board"
-                id="menu_project_management_timesheet_lines_board"
-                parent="base.menu_project_management_time_tracking"
-                sequence="7"/-->
-      <!--<menuitem action="action_random_timesheet_lines_board" id="menu_hr_action_random_timesheet_lines_board"
-            parent="hr_attendance.menu_hr_time_tracking" groups="base.group_hr_manager"/>
-           <menuitem
-                action="action_random_timesheet_lines_board"
-                id="menu_hr_action_random_timesheet_lines_board"
-                name="Working Hours"
-                parent="hr_attendance.menu_hr_time_tracking"
-                groups="base.group_hr_manager" sequence="2"/>-->
     </data>
 </openerp>
index de46463..3212928 100644 (file)
@@ -57,7 +57,6 @@
             <field name="view_mode">tree,graph</field>
             <field name="domain">[('state','=','open')]</field>
         </record>
-<!--        <menuitem action="action_analytic_account_tree" id="menu_action_analytic_account_tree" parent="account.next_id_40"/>-->
 
         <record id="account_analytic_line_to_invoice_view_form" model="ir.ui.view">
             <field name="name">report.account.analytic.line.to.invoice</field>
             <field name="view_mode">tree,graph</field>
             <field name="search_view_id" ref="account_analytic_line_to_invoice_view_filter"/>
         </record>
-<!--        <menuitem action="action_account_analytic_line_to_invoice" id="account_analytic_lines_to_invoice_report" parent="account.next_id_40"/>-->
 
         <act_window domain="[('account_id', '=', active_id),('invoice_id','=',False),('to_invoice','&lt;&gt;',False)]" id="act_acc_analytic_acc_2_report_acc_analytic_line_to_invoice" name="Lines to Invoice" res_model="account.analytic.line" src_model="account.analytic.account"/>
 
index cf23ae1..71706d9 100644 (file)
             <field name="target">new</field>
         </record>
 
-<!--           <record model="ir.values" id="hr_timesheet_invoice_cost_ledger_values">
-            <field name="model_id" ref="model_account_analytic_account" />
-            <field name="object" eval="1" />
-            <field name="name">Cost Ledger</field>
-            <field name="key2">client_print_multi</field>
-            <field name="value" eval="'ir.actions.act_window,' + str(ref('action_hr_timesheet_invoice_cost_ledger'))" />
-            <field name="key">action</field>
-            <field name="model">account.analytic.account</field>
-        </record> -->
-
        </data>
 </openerp>
\ No newline at end of file
index 57a1e4a..4e1926f 100644 (file)
@@ -182,8 +182,6 @@ class hr_timesheet_invoice_create(osv.osv_memory):
                             details.append("%s" % (line['unit_amount'], ))
                     if data['name']:
                         details.append(line['name'])
-                    #if data['price']:
-                    #   details.append(abs(line['amount']))
                     note.append(u' - '.join(map(lambda x: unicode(x) or '',details)))
 
                 curr_line['note'] = "\n".join(map(lambda x: unicode(x) or '',note))
@@ -202,18 +200,6 @@ class hr_timesheet_invoice_create(osv.osv_memory):
         act_win['name'] = _('Invoices')
         return act_win
 
-#        return {
-#            'domain': "[('id','in', ["+','.join(map(str,invoices))+"])]",
-#            'name': _('Invoices'),
-#            'view_type': 'form',
-#            'view_mode': 'tree,form',
-#            'res_model': 'account.invoice',
-#            'view_id': False,
-#            'context': "{'type':'out_invoice'}",
-#            'type': 'ir.actions.act_window',
-#            'search_view_id': res['res_id']
-#        }
-
 
 hr_timesheet_invoice_create()
 
index 0c69af2..70d3618 100644 (file)
             </field>
         </record>
 
-     <!--   Add in projectboard
-        <record id="act_hr_timesheet_sheet" model="ir.actions.act_window">
-            <field name="name">Timesheets</field>
-            <field name="res_model">hr_timesheet_sheet.sheet</field>
-            <field name="domain">[('state','&lt;&gt;','done'),('user_id','in',department_users_get())]</field>
-            <field name="view_type">form</field>
-            <field name="view_id" ref="hr_timesheet_sheet_tree"/>
-        </record>
-    <record id="board_project_timesheet_form" model="ir.ui.view">
-            <field name="name">board.project.timesheet.form</field>
-            <field name="model">board.board</field>
-      <field name="inherit_id" ref="project.board_project_manager_form"/>
-            <field name="type">form</field>
-            <field name="arch" type="xml">
-        <xpath expr="/form/hpaned/child1" position="inside">
-          <action colspan="4" height="150" name="%(act_hr_timesheet_sheet)d" string="User's timesheets" width="510"/>
-        </xpath>
-            </field>
-        </record>-->
     </data>
 </openerp>
index c0e0d1d..250120c 100644 (file)
@@ -8,73 +8,12 @@
             <field eval="time.strftime('%Y-%m-15', time.localtime(time.mktime(time.localtime()[0:2] + (0,)*7)-1))" name="date_current"/>
             <field eval="time.strftime('%Y-%m-%d', time.localtime(time.mktime(time.localtime()[0:2] + (0,)*7)-1))" name="date_to"/>
         </record>
-        
+
         <record id="sheet1" model="hr_timesheet_sheet.sheet">
             <field name="name">Sheet 1</field>
             <field name="user_id" ref="base.user_root"/>
             <field eval="time.strftime('%Y-%m-%d')" name="date_current"/>
         </record>
-        
-        <!-- <record id="hr.attendance1" model="hr.attendance">
-            <field name="sheet_id" ref="sheet1"/>
-        </record>
-        <record id="hr.attendance2" model="hr.attendance">
-            <field name="sheet_id" ref="sheet1"/>
-        </record>
-        <record id="hr.attendance3" model="hr.attendance">
-            <field name="sheet_id" ref="sheet1"/>
-        </record>
-        <record id="hr.attendance4" model="hr.attendance">
-            <field name="sheet_id" ref="sheet1"/>
-        </record>
-        <record id="hr.attendance5" model="hr.attendance">
-            <field name="sheet_id" ref="sheet1"/>
-        </record>
-        <record id="hr.attendance6" model="hr.attendance">
-            <field name="sheet_id" ref="sheet1"/>
-        </record>
-        <record id="hr.attendance7" model="hr.attendance">
-            <field name="sheet_id" ref="sheet1"/>
-        </record>
-        <record id="hr.attendance8" model="hr.attendance">
-            <field name="sheet_id" ref="sheet1"/>
-        </record>
-        <record id="hr.attendance9" model="hr.attendance">
-            <field name="sheet_id" ref="sheet1"/>
-        </record>
-        <record id="hr.attendance10" model="hr.attendance">
-            <field name="sheet_id" ref="sheet1"/>
-        </record>
-        <record id="hr.attendance11" model="hr.attendance">
-            <field name="sheet_id" ref="sheet1"/>
-        </record>
-        <record id="hr.attendance12" model="hr.attendance">
-            <field name="sheet_id" ref="sheet1"/>
-        </record>
-        <record id="hr.attendance13" model="hr.attendance">
-            <field name="sheet_id" ref="sheet1"/>
-        </record>
-        <record id="hr.attendance14" model="hr.attendance">
-            <field name="sheet_id" ref="sheet1"/>
-        </record>
-        <record id="hr.attendance15" model="hr.attendance">
-            <field name="sheet_id" ref="sheet1"/>
-        </record>
-        <record id="hr.attendance16" model="hr.attendance">
-            <field name="sheet_id" ref="sheet1"/>
-        </record>
-        <record id="hr.attendance17" model="hr.attendance">
-            <field name="sheet_id" ref="sheet1"/>
-        </record>
-        <record id="hr.attendance18" model="hr.attendance">
-            <field name="sheet_id" ref="sheet1"/>
-        </record>
-        <record id="hr.attendance19" model="hr.attendance">
-            <field name="sheet_id" ref="sheet1"/>
-        </record>
-        <record id="hr.attendance20" model="hr.attendance">
-            <field name="sheet_id" ref="sheet1"/>
-        </record> -->
 
     </data>
 </openerp>
index 377e1df..e4c4fde 100644 (file)
                 </tree>
             </field>
         </record>
-<!--
-        <record id="hr_timesheet_day_form" model="ir.ui.view">
-            <field name="name">hr.timesheet.day.form</field>
-            <field name="model">hr_timesheet_sheet.sheet.day</field>
-            <field name="type">form</field>
-            <field name="arch" type="xml">
-                <form string="Timesheet by Days">
-                    <field name="sheet_id" select="1"/>
-                    <field name="name" select="1"/>
-                    <field name="total_timesheet"/>
-                    <field name="total_attendance" groups="hr_attendance.group_hr_attendance"/>
-                    <field name="total_difference" groups="hr_attendance.group_hr_attendance"/>
-                </form>
-            </field>
-        </record>
 
-        <record id="hr_timesheet_day_tree" model="ir.ui.view">
-            <field name="name">hr.timesheet.day.tree</field>
-            <field name="model">hr_timesheet_sheet.sheet.day</field>
-            <field name="type">tree</field>
-            <field name="arch" type="xml">
-                <tree colors="red:total_difference&lt;0.1;blue:total_difference&gt;=0.1" string="Timesheet by Days">
-                    <field name="sheet_id"/>
-                    <field name="name"/>
-                    <field name="total_timesheet" sum="Total Timesheet"/>
-                    <field name="total_attendance" sum="Total Attendance" groups="hr_attendance.group_hr_attendance"/>
-                    <field name="total_difference" sum="Total Difference" groups="hr_attendance.group_hr_attendance"/>
-                </tree>
-            </field>
-        </record>
--->
         <record id="hr_timesheet_sheet_form" model="ir.ui.view">
             <field name="name">hr.timesheet.sheet.form</field>
             <field name="model">hr_timesheet_sheet.sheet</field>
 
         <!--Time Tracking menu in project Management-->
         <menuitem icon="terp-project" id="base.menu_main_pm" name="Project" sequence="10"/>
-          <menuitem
+        <menuitem
              id="base.menu_project_management_time_tracking"
              name="Time Tracking"
              parent="base.menu_main_pm" sequence="5"/>
-         <menuitem action="hr_timesheet_sheet.act_hr_timesheet_sheet_form" id="menu_act_project_management_timesheet_sheet_form" parent="base.menu_project_management_time_tracking"
+        <menuitem action="hr_timesheet_sheet.act_hr_timesheet_sheet_form" id="menu_act_project_management_timesheet_sheet_form" parent="base.menu_project_management_time_tracking"
               sequence="5"/>
-        <!--<menuitem id="next_id_60" name="Timesheets" parent="hr.menu_hr_root"/>-->
         <menuitem action="act_hr_timesheet_sheet_form" id="menu_act_hr_timesheet_sheet_form" parent="hr_attendance.menu_hr_time_tracking"
              sequence="1"/>
 
         </record>
 
         <act_window domain="[('sheet_id', '=', active_id)]" id="act_hr_timesheet_sheet_sheet_by_day" name="Timesheet by Account" res_model="hr_timesheet_sheet.sheet.account" src_model="hr_timesheet_sheet.sheet"/>
-<!--         <act_window domain="[('sheet_id', '=', active_id)]" id="act_hr_timesheet_sheet_sheet_by_account" name="Timesheet by Day" res_model="hr_timesheet_sheet.sheet.day" src_model="hr_timesheet_sheet.sheet"/>  -->
-
 
         <act_window domain="[('sheet_id', '=', active_id)]" id="act_hr_timesheet_sheet_sheet_2_hr_analytic_timesheet" name="Timesheet Lines" res_model="hr.analytic.timesheet" src_model="hr_timesheet_sheet.sheet"/>
 
index 2bdad41..ef377c7 100644 (file)
@@ -1,13 +1,6 @@
 <?xml version="1.0"?>
 <openerp>
        <data>
-<!--           <record id="idea.menu_config" model="ir.ui.menu">-->
-<!--                   <field name="groups_id" eval="[(6,0,[ref('base.group_system')])]"/>-->
-<!--           </record>-->
-<!---->
-<!--           <record id="idea.menu_reporting" model="ir.ui.menu">-->
-<!--                   <field name="groups_id" eval="[(6,0,[ref('base.group_system')])]"/>-->
-<!--           </record>-->
 
     <record id="base.group_sale_salesman" model="res.groups">
         <field name="name">Sales / User</field>
index f4d7cdd..dc6c86f 100644 (file)
@@ -29,7 +29,6 @@
         <record id="user_type_tiers" model="account.account.type">
             <field name="name">Tiers</field>
             <field name="code">tiers</field>
-            <!-- <field name="report_type">?</field> -->
             <field name="close_method">balance</field>
         </record>
         <record id="user_type_tiers_receiv" model="account.account.type">
         <record id="user_type_tax" model="account.account.type">
             <field name="name">Tax</field>
             <field name="code">tax</field>
-            <!-- <field name="report_type">?</field> -->
             <field name="close_method">unreconciled</field>
         </record>
         <record id="user_type_financiers" model="account.account.type">
             <field name="name">Financier</field>
             <field name="code">financier</field>
-            <!-- <field name="report_type">?</field> -->
             <field name="close_method">balance</field>
         </record>
         <record id="user_type_charge" model="account.account.type">
index 415db0b..bc92086 100644 (file)
@@ -90,20 +90,6 @@ class partner_vat(osv.osv_memory):
 
             #it seems that this listing is only for belgian customers
             record['country'] = 'BE'
-            #...deprecated...
-            #~addr = pool.get('res.partner').address_get(cr, uid, [obj_partner.id], ['invoice'])
-
-            #~ if addr.get('invoice',False):
-                #~ads=pool.get('res.partner.address').browse(cr, uid, [addr['invoice']])[0]
-
-                #~ if ads.country_id:
-                    #~ record.append(ads.country_id.code)
-                #~ else:
-                    #~ error_message.append('Data Insufficient! : '+ 'The Partner "'+obj_partner.name + '"'' has no country associated with its Invoice address!')
-
-            #~ if len(record)<2:
-                #~ record.append('')
-                #~ error_message.append('Data Insufficient! : '+ 'The Partner "'+obj_partner.name + '"'' has no Invoice address!')
 
             record['amount'] = 0
             record['turnover'] = 0
@@ -120,7 +106,6 @@ class partner_vat(osv.osv_memory):
         model_data_ids = obj_model_data.search(cursor, user, [('model','=','ir.ui.view'), ('name','=','view_vat_listing')])
         resource_id = obj_model_data.read(cursor, user, model_data_ids, fields=['res_id'])[0]['res_id']
         return {
-#            'domain': "[('id','in', ["+','.join(map(str,data['form']['invoice_ids']))+"])]",
             'name': 'Vat Listing',
             'view_type': 'form',
             'view_mode': 'form',
index 256047a..1e90ac6 100644 (file)
@@ -52,24 +52,6 @@ class res_partner_bank(osv.osv):
         'dta_code': fields.char('DTA code', size=5),
     }
 
-#   def _default_value(self, cursor, user, field, context=None):
-#       if field in ('country_id', 'state_id'):
-#           value = False
-#       else:
-#           value = ''
-#       if not context.get('address', False):
-#           return value
-#       for ham, spam, address in context['address']:
-#           if 'type' in address.keys() :
-#               if address['type'] == 'default':
-#                   return address[field]
-#               elif not address['type']:
-#                   value = address[field]
-#           else :
-#               value = False
-#       return value
-
-
     def name_get(self, cr, uid, ids, context=None):
         if not len(ids):
             return []
index e792fe1..b9f4078 100644 (file)
@@ -102,7 +102,6 @@ class record:
                 value = self.post[field[0]]
             else :
                 pass
-                #raise Exception(field[0]+' not found !')
             try:
                 res = res + c_ljust(value, field[1])
             except :
index fad81d6..c79e189 100644 (file)
         <record model="account.account.type" id="account_type_closing">
             <field name="name">Autre : Cloture</field>
             <field name="code">closing</field>
-            <!-- <field name="report_type">?</field> -->
             <field name="close_method">none</field>
         </record>
         <record model="account.account.type" id="account_type_depreciation">
             <field name="name">PP : Amortissement</field>
             <field name="code">depreciation</field>
-            <!-- <field name="report_type">?</field> -->
             <field name="close_method">none</field>
         </record>
         <record model="account.account.type" id="account_type_financial_result">
             <field name="name">PP : Resultat financier</field>
             <field name="code">financial_result</field>
-            <!-- <field name="report_type">?</field> -->
             <field name="close_method">none</field>
         </record>
         <record model="account.account.type" id="account_type_financial_asset">
@@ -92,7 +89,6 @@
         <record model="account.account.type" id="account_type_non_ope_debts">
             <field name="name">Bilan : Dettes hors exploitation</field>
             <field name="code">non_ope_debts</field>
-             <!-- <field name="report_type">?</field> -->
             <field name="close_method">balance</field>
         </record>
 
         <record model="account.account.type" id="account_type_non_ope_result">
             <field name="name">PP : Resultat activites annexes</field>
             <field name="code">non_oper_result</field>
-            <!-- <field name="report_type">?</field> -->
             <field name="close_method">none</field>
         </record>
         <record model="account.account.type" id="account_type_other_payable">
         <record model="account.account.type" id="account_type_prov_reserve">
             <field name="name">Bilan : Provisions et reserves</field>
             <field name="code">provision_reserve</field>
-            <!-- <field name="report_type">?</field>-->
             <field name="close_method">balance</field>
         </record>
 
         <record model="account.account.type" id="account_type_purchase">
             <field name="name">PP : Achat de marchandise</field>
             <field name="code">purchase</field>
-            <!-- <field name="report_type">?</field>-->
             <field name="close_method">none</field>
         </record>
         <record model="account.account.type" id="account_type_report_result">
             <field name="name">Bilan : Resultat reporte</field>
             <field name="code">report_result</field>
-            <!-- <field name="report_type">?</field>-->
             <field name="close_method">balance</field>
         </record>
 
         <record model="account.account.type" id="account_type_consolidation">
             <field name="name">Autre : Consolidation</field>
             <field name="code">consolidation</field>
-            <!-- <field name="report_type">?</field>-->
             <field name="close_method">none</field>
         </record>
 
         <record model="account.account.type" id="account_type_other">
             <field name="name">Autre : Other</field>
             <field name="code">other</field>
-            <!-- <field name="report_type">?</field>-->
             <field name="close_method">none</field>
         </record>
 
         <record model="account.account.type" id="account_type_closed">
             <field name="name">Autre : Closed</field>
             <field name="code">closed</field>
-            <!-- <field name="report_type">?</field>-->
             <field name="close_method">none</field>
         </record>
 
index 6bb42c6..75f0cd8 100644 (file)
                                    <field name="user_type" ref="account_type_liability"/>
                                </record>
 
-               <!-- <record id="account.property_account_payable" model="ir.property">
-                   <field eval="'account.account,'+str(a_pay)" name="value"/>
-               </record>-->
-
                <record model="account.account.template" id="assets_view">
                    <field name="name">Assets</field>
                    <field name="code">10</field>
                                            <field name="user_type" ref="account_type_asset"/>
                                        </record>
 
-                                       <!-- <record id="account.property_account_receivable" model="ir.property">
-                                           <field eval="'account.account,'+str(a_recv)" name="value"/>
-                                       </record> -->
-
                                        <record id="ova" model="account.account.template">
                                            <field name="code">11003</field>
                                            <field name="name">Output VAT</field>
                    <field name="parent_id" ref="gpf"/>
                </record>
            
-                       <!-- <record id="account.property_account_income_categ" model="ir.property">
-                           <field eval="'account.account,'+str(a_sale)" name="value"/>
-                       </record> -->
-               
                        <record id="cos" model="account.account.template">
                            <field name="code">210</field>
                            <field name="name">Cost of Sales</field>
                         <field name="user_type" ref="account_type_expense"/>
                     </record>
                                
-                               <!-- <record id="account.property_account_expense_categ" model="ir.property">
-                                   <field eval="'account.account,'+str(a_expense)" name="value"/>
-                               </record> -->
     </data>
 </openerp>
index 0e69dd3..fd9f833 100644 (file)
@@ -686,29 +686,42 @@ class mrp_production(osv.osv):
         final_product_todo = []
 
         produced_qty = 0
+        if production_mode == 'consume_produce':
+            produced_qty = production_qty
+            
         for produced_product in production.move_created_ids2:
             if (produced_product.scraped) or (produced_product.product_id.id<>production.product_id.id):
                 continue
             produced_qty += produced_product.product_qty
 
-
         if production_mode in ['consume','consume_produce']:
             consumed_products = {}
+            check = {}
+            scraped = map(lambda x:x.scraped,production.move_lines2).count(True)
+            
             for consumed_product in production.move_lines2:
+                consumed = consumed_product.product_qty
                 if consumed_product.scraped:
                     continue
                 if not consumed_products.get(consumed_product.product_id.id, False):
-                    consumed_products[consumed_product.product_id.id] = 0
-                consumed_products[consumed_product.product_id.id] -= consumed_product.product_qty
-                
+                    consumed_products[consumed_product.product_id.id] = consumed_product.product_qty
+                    check[consumed_product.product_id.id] = 0
+                for f in production.product_lines:
+                    if f.product_id.id == consumed_product.product_id.id:
+                        if (len(production.move_lines2) - scraped) > len(production.product_lines):
+                            check[consumed_product.product_id.id] += consumed_product.product_qty
+                            consumed = check[consumed_product.product_id.id]
+                        rest_consumed = produced_qty * f.product_qty / production.product_qty - consumed 
+                        consumed_products[consumed_product.product_id.id] = rest_consumed
+            
             for raw_product in production.move_lines:
                 for f in production.product_lines:
-                    if f.product_id.id==raw_product.product_id.id:
+                    if f.product_id.id == raw_product.product_id.id:
                         consumed_qty = consumed_products.get(raw_product.product_id.id, 0)
-                        rest_qty = production_qty * f.product_qty / production.product_qty - consumed_qty
-                         
-                        if rest_qty > 0:
-                            stock_mov_obj.action_consume(cr, uid, [raw_product.id], rest_qty, production.location_src_id.id, context=context)
+                        if consumed_qty == 0:
+                            consumed_qty = production_qty * f.product_qty / production.product_qty
+                        if consumed_qty > 0:
+                            stock_mov_obj.action_consume(cr, uid, [raw_product.id], consumed_qty, production.location_src_id.id, context=context)
 
         if production_mode == 'consume_produce':
             # To produce remaining qty of final product
index 244d957..c76bc60 100644 (file)
@@ -181,7 +181,10 @@ class stock_location(osv.osv):
         'chained_journal_id': fields.many2one('stock.journal', 'Chained Journal'),
         'chained_location_id': fields.many2one('stock.location', 'Chained Location If Fixed'),
         'chained_location_type': fields.selection([('none', 'None'), ('customer', 'Customer'), ('fixed', 'Fixed Location')],
-            'Chained Location Type', required=True),
+            'Chained Location Type', required=True,
+            help="This field is set to determine the destination location.\n" \
+                "If the field is set to 'customer', the location is given by the properties of the partner form.\n"\
+                "If the field is set to 'fixed', the destination location is given by the field Location if link is fixed."),
         'chained_auto_packing': fields.selection(
             [('auto', 'Automatic Move'), ('manual', 'Manual Operation'), ('transparent', 'Automatic No Step Added')],
             'Automatic Move',