From 85e44b4247d6b3e1df83898b922c8392f1d8fb7b Mon Sep 17 00:00:00 2001 From: Anand Doshi Date: Thu, 6 Dec 2012 15:14:51 +0530 Subject: [PATCH] fix in voucher import tool --- accounts/page/voucher_import_tool/voucher_import_tool.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/accounts/page/voucher_import_tool/voucher_import_tool.py b/accounts/page/voucher_import_tool/voucher_import_tool.py index 5f66c7acbd..4afa41af7d 100644 --- a/accounts/page/voucher_import_tool/voucher_import_tool.py +++ b/accounts/page/voucher_import_tool/voucher_import_tool.py @@ -6,9 +6,11 @@ from webnotes.utils import flt def get_template(): """download template""" template_type = webnotes.form_dict.get('type') - from webnotes.model.doctype import get_property - naming_options = get_property("Journal Voucher", "naming_series", "options") - voucher_type = get_property("Journal Voucher", "voucher_type", "options") + + doctypelist = webnotes.get_doctype("Journal Voucher") + naming_options = doctypelist.get_options("naming_series") + voucher_type = doctypelist.get_options("voucher_type") + if template_type=="Two Accounts": extra_note = "" columns = '''"Naming Series","Voucher Type","Posting Date","Amount","Debit Account","Credit Account","Cost Center","Against Sales Invoice","Against Purchase Invoice","Against Journal Voucher","Remarks","Due Date","Ref Number","Ref Date"'''