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.

65 lines
4.1 KiB

  1. -
  2. In order to test the PDF General Ledger webkit wizard I will print report with default setting
  3. -
  4. !python {model: account.account}: |
  5. ctx={}
  6. data_dict = {'chart_account_id':ref('account.chart0')}
  7. ctx.update({'model': 'account.account','active_ids':[ref('account.chart0')],'active_id':ref('account.chart0')})
  8. from openerp.tools import test_reports
  9. test_reports.try_report_action(cr, uid, 'action_account_general_ledger_menu_webkit',wiz_data=data_dict, context=ctx, our_module='account_financial_report_webkit')
  10. -
  11. In order to test the PDF General Ledger webkit wizard I will print report with posted move
  12. -
  13. !python {model: account.account}: |
  14. ctx={}
  15. data_dict = {'chart_account_id':ref('account.chart0'), 'target_move': 'posted'}
  16. ctx.update({'model': 'account.account','active_ids':[ref('account.chart0')],'active_id':ref('account.chart0')})
  17. from openerp.tools import test_reports
  18. test_reports.try_report_action(cr, uid, 'action_account_general_ledger_menu_webkit',wiz_data=data_dict, context=ctx, our_module='account_financial_report_webkit')
  19. -
  20. In order to test the PDF General Ledger webkit wizard I will print report with transactions or non zero balance
  21. -
  22. !python {model: account.account}: |
  23. ctx={}
  24. data_dict = {'chart_account_id':ref('account.chart0'), 'display_account': 'bal_mix'}
  25. ctx.update({'model': 'account.account','active_ids':[ref('account.chart0')],'active_id':ref('account.chart0')})
  26. from openerp.tools import test_reports
  27. test_reports.try_report_action(cr, uid, 'action_account_general_ledger_menu_webkit',wiz_data=data_dict, context=ctx, our_module='account_financial_report_webkit')
  28. -
  29. In order to test the PDF General Ledger webkit wizard I will print report with inital balance and currency ammount
  30. -
  31. !python {model: account.account}: |
  32. ctx={}
  33. data_dict = {'chart_account_id':ref('account.chart0'), 'amount_currency': 1}
  34. ctx.update({'model': 'account.account','active_ids':[ref('account.chart0')],'active_id':ref('account.chart0')})
  35. from openerp.tools import test_reports
  36. test_reports.try_report_action(cr, uid, 'action_account_general_ledger_menu_webkit',wiz_data=data_dict, context=ctx, our_module='account_financial_report_webkit')
  37. #Filter by date
  38. -
  39. In order to test the PDF General Ledger webkit wizard I will print report with inital balance and currency ammount and I filter by date of the first tree month
  40. -
  41. !python {model: account.account}: |
  42. from datetime import datetime
  43. ctx={}
  44. data_dict = {'chart_account_id':ref('account.chart0'),'amount_currency': 1, 'chart_account_id': 1, 'date_from': '%s-01-01' %(datetime.now().year),
  45. 'date_to':'%s-04-01' %(datetime.now().year), 'display_account': 'bal_all', 'filter': 'filter_date',}
  46. ctx.update({'model': 'account.account','active_ids':[ref('account.chart0')],'active_id':ref('account.chart0')})
  47. from openerp.tools import test_reports
  48. test_reports.try_report_action(cr, uid, 'action_account_general_ledger_menu_webkit',wiz_data=data_dict, context=ctx, our_module='account_financial_report_webkit')
  49. -
  50. In order to test the PDF General Ledger webkit wizard I will print report with inital balance and currency ammount and I filter by date of the first tree month
  51. -
  52. !python {model: account.account}: |
  53. from datetime import datetime
  54. ctx={}
  55. data_dict = {'chart_account_id':ref('account.chart0'),'amount_currency': 1, 'chart_account_id': 1, 'date_from': '%s-01-01' %(datetime.now().year),
  56. 'date_to':'%s-04-01' %(datetime.now().year), 'display_account': 'bal_all', 'filter': 'filter_date',}
  57. ctx.update({'model': 'account.account','active_ids':[ref('account.chart0')],'active_id':ref('account.chart0')})
  58. from openerp.tools import test_reports
  59. test_reports.try_report_action(cr, uid, 'action_account_general_ledger_menu_webkit',wiz_data=data_dict, context=ctx, our_module='account_financial_report_webkit')
  60. # I still have to parse report content but for this I need accounting data on multiple exercises and faor all fiscal year