You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

83 lines
3.4 KiB

  1. -
  2. In order to test the Excel General Ledger webkit wizard I will print report on all the journals
  3. -
  4. !python {model: account.account}: |
  5. ctx = {}
  6. data_dict = {'chart_account_id': ref('account.chart0'),
  7. 'journal_ids': self.pool['account.journal'].search(cr, uid, []),
  8. }
  9. ctx.update({'model': 'account.account',
  10. 'active_ids': [ref('account.chart0')],
  11. 'active_id': ref('account.chart0')})
  12. from openerp.tools import test_reports
  13. test_reports.try_report_action(
  14. cr, uid,
  15. 'account_journal_report_xls.action_print_journal_by_fiscalyear_xls',
  16. wiz_data=data_dict,
  17. context=ctx,
  18. wiz_buttons='xls_export',
  19. our_module='account_journal_report_xls')
  20. -
  21. In order to test the Excel General Ledger webkit wizard I will print report with entries sorted by date
  22. -
  23. !python {model: account.account}: |
  24. ctx = {}
  25. data_dict = {'chart_account_id': ref('account.chart0'),
  26. 'journal_ids': self.pool['account.journal'].search(cr, uid, []),
  27. 'sort_selection': 'l.date',
  28. }
  29. ctx.update({'model': 'account.account',
  30. 'active_ids': [ref('account.chart0')],
  31. 'active_id': ref('account.chart0')})
  32. from openerp.tools import test_reports
  33. test_reports.try_report_action(
  34. cr, uid,
  35. 'account_journal_report_xls.action_print_journal_by_fiscalyear_xls',
  36. wiz_data=data_dict,
  37. context=ctx,
  38. wiz_buttons='xls_export',
  39. our_module='account_journal_report_xls')
  40. -
  41. In order to test the Excel General Ledger webkit wizard I will print report without grouped entries
  42. -
  43. !python {model: account.account}: |
  44. ctx = {}
  45. data_dict = {'chart_account_id': ref('account.chart0'),
  46. 'journal_ids': self.pool['account.journal'].search(cr, uid, []),
  47. 'group_entries': False,
  48. }
  49. ctx.update({'model': 'account.account',
  50. 'active_ids': [ref('account.chart0')],
  51. 'active_id': ref('account.chart0')})
  52. from openerp.tools import test_reports
  53. test_reports.try_report_action(
  54. cr, uid,
  55. 'account_journal_report_xls.action_print_journal_by_fiscalyear_xls',
  56. wiz_data=data_dict,
  57. context=ctx,
  58. wiz_buttons='xls_export',
  59. our_module='account_journal_report_xls')
  60. -
  61. In order to test the Excel General Ledger webkit wizard I will print report with currency
  62. -
  63. !python {model: account.account}: |
  64. ctx = {}
  65. data_dict = {'chart_account_id': ref('account.chart0'),
  66. 'journal_ids': self.pool['account.journal'].search(cr, uid, []),
  67. 'amount_currency': False,
  68. }
  69. ctx.update({'model': 'account.account',
  70. 'active_ids': [ref('account.chart0')],
  71. 'active_id': ref('account.chart0')})
  72. from openerp.tools import test_reports
  73. test_reports.try_report_action(
  74. cr, uid,
  75. 'account_journal_report_xls.action_print_journal_by_fiscalyear_xls',
  76. wiz_data=data_dict,
  77. context=ctx,
  78. wiz_buttons='xls_export',
  79. our_module='account_journal_report_xls')