From 6f9915cd17633e5c26a8ec4d0a1ffdcf0586c888 Mon Sep 17 00:00:00 2001 From: Rushabh Mehta Date: Wed, 16 Jan 2013 17:48:17 +0530 Subject: [PATCH 01/11] install from txt files, part 1 --- .../Journal Voucher/Journal Voucher.txt | 63 +- .../POS with write off/POS with write off.txt | 377 ++++------- accounts/GL Mapper/POS/POS.txt | 118 +++- .../Purchase Invoice with write off.txt | 80 +-- .../Purchase Invoice/Purchase Invoice.txt | 22 +- .../GL Mapper/Sales Invoice/Sales Invoice.txt | 82 ++- accounts/__init__.py | 5 - .../accounts/locale/_messages_doc.json | 17 - .../module_def/accounts/locale/hi-doc.json | 17 - .../accounts_browser/accounts_browser.txt | 1 - .../financial_statements.txt | 1 - buying/__init__.py | 7 - .../buying/locale/_messages_doc.json | 5 - buying/module_def/buying/locale/hi-doc.json | 5 - .../module_def/home/locale/_messages_doc.json | 9 - home/module_def/home/locale/hi-doc.json | 9 - hr/Deduction Type/Income Tax/Income Tax.txt | 1 - .../Professional Tax/Professional Tax.txt | 1 - .../Provident Fund/Provident Fund.txt | 1 - hr/Earning Type/Basic/Basic.txt | 1 - .../House Rent Allowance.txt | 1 - hr/Expense Type/Calls/Calls.txt | 1 - hr/Expense Type/Food/Food.txt | 1 - hr/Expense Type/Medical/Medical.txt | 1 - hr/Expense Type/Others/Others.txt | 1 - hr/Expense Type/Travel/Travel.txt | 1 - hr/Leave Type/Casual Leave/Casual Leave.txt | 1 - .../Compensatory Off/Compensatory Off.txt | 1 - .../Leave Without Pay/Leave Without Pay.txt | 1 - .../Privilege Leave/Privilege Leave.txt | 1 - hr/Leave Type/Sick Leave/Sick Leave.txt | 1 - hr/__init__.py | 8 - hr/module_def/hr/locale/_messages_doc.json | 4 - hr/module_def/hr/locale/hi-doc.json | 4 - manufacturing/__init__.py | 5 - .../manufacturing/locale/_messages_doc.json | 3 - .../manufacturing/locale/hi-doc.json | 3 - projects/__init__.py | 4 - .../projects/locale/_messages_doc.json | 4 - .../module_def/projects/locale/hi-doc.json | 4 - selling/__init__.py | 8 - .../selling/locale/_messages_doc.json | 11 - selling/module_def/selling/locale/hi-doc.json | 11 - selling/page/sales_browser/sales_browser.txt | 1 - setup/__init__.py | 5 - .../setup/locale/_messages_doc.json | 18 - setup/module_def/setup/locale/hi-doc.json | 18 - startup/install.py | 638 ++++++++++++++++++ .../All Item Groups/All Item Groups.txt | 1 - stock/Item Group/Default/Default.txt | 1 - stock/__init__.py | 3 + .../stock/locale/_messages_doc.json | 18 - stock/module_def/stock/locale/hi-doc.json | 18 - .../support/locale/_messages_doc.json | 5 - support/module_def/support/locale/hi-doc.json | 5 - .../utilities/locale/_messages_doc.json | 11 - .../module_def/utilities/locale/hi-doc.json | 11 - utilities/page/trash/trash.txt | 1 - .../website/locale/_messages_doc.json | 15 - website/module_def/website/locale/hi-doc.json | 14 - 60 files changed, 1098 insertions(+), 587 deletions(-) delete mode 100644 accounts/module_def/accounts/locale/_messages_doc.json delete mode 100644 accounts/module_def/accounts/locale/hi-doc.json delete mode 100644 buying/module_def/buying/locale/_messages_doc.json delete mode 100644 buying/module_def/buying/locale/hi-doc.json delete mode 100644 home/module_def/home/locale/_messages_doc.json delete mode 100644 home/module_def/home/locale/hi-doc.json delete mode 100644 hr/Deduction Type/Income Tax/Income Tax.txt delete mode 100644 hr/Deduction Type/Professional Tax/Professional Tax.txt delete mode 100644 hr/Deduction Type/Provident Fund/Provident Fund.txt delete mode 100644 hr/Earning Type/Basic/Basic.txt delete mode 100644 hr/Earning Type/House Rent Allowance/House Rent Allowance.txt delete mode 100644 hr/Expense Type/Calls/Calls.txt delete mode 100644 hr/Expense Type/Food/Food.txt delete mode 100644 hr/Expense Type/Medical/Medical.txt delete mode 100644 hr/Expense Type/Others/Others.txt delete mode 100644 hr/Expense Type/Travel/Travel.txt delete mode 100644 hr/Leave Type/Casual Leave/Casual Leave.txt delete mode 100644 hr/Leave Type/Compensatory Off/Compensatory Off.txt delete mode 100644 hr/Leave Type/Leave Without Pay/Leave Without Pay.txt delete mode 100644 hr/Leave Type/Privilege Leave/Privilege Leave.txt delete mode 100644 hr/Leave Type/Sick Leave/Sick Leave.txt delete mode 100644 hr/module_def/hr/locale/_messages_doc.json delete mode 100644 hr/module_def/hr/locale/hi-doc.json delete mode 100644 manufacturing/module_def/manufacturing/locale/_messages_doc.json delete mode 100644 manufacturing/module_def/manufacturing/locale/hi-doc.json delete mode 100644 projects/module_def/projects/locale/_messages_doc.json delete mode 100644 projects/module_def/projects/locale/hi-doc.json delete mode 100644 selling/module_def/selling/locale/_messages_doc.json delete mode 100644 selling/module_def/selling/locale/hi-doc.json delete mode 100644 setup/module_def/setup/locale/_messages_doc.json delete mode 100644 setup/module_def/setup/locale/hi-doc.json create mode 100644 startup/install.py delete mode 100644 stock/Item Group/All Item Groups/All Item Groups.txt delete mode 100644 stock/Item Group/Default/Default.txt delete mode 100644 stock/module_def/stock/locale/_messages_doc.json delete mode 100644 stock/module_def/stock/locale/hi-doc.json delete mode 100644 support/module_def/support/locale/_messages_doc.json delete mode 100644 support/module_def/support/locale/hi-doc.json delete mode 100644 utilities/module_def/utilities/locale/_messages_doc.json delete mode 100644 utilities/module_def/utilities/locale/hi-doc.json delete mode 100644 website/module_def/website/locale/_messages_doc.json delete mode 100644 website/module_def/website/locale/hi-doc.json diff --git a/accounts/GL Mapper/Journal Voucher/Journal Voucher.txt b/accounts/GL Mapper/Journal Voucher/Journal Voucher.txt index 1909477617..bf2ff1ad98 100644 --- a/accounts/GL Mapper/Journal Voucher/Journal Voucher.txt +++ b/accounts/GL Mapper/Journal Voucher/Journal Voucher.txt @@ -1 +1,62 @@ -[{'doc_type': 'Journal Voucher', 'modified_by': 'nabin@webnotestech.com', 'name': 'Journal Voucher', 'parent': None, 'creation': '2009-03-12 12:09:24', 'modified': '2010-04-30 17:56:41', 'module': 'Accounts', 'doctype': 'GL Mapper', 'idx': None, 'parenttype': None, 'owner': 'Administrator', 'docstatus': 0, 'parentfield': None}, {'creation': '2009-03-12 12:09:24', 'voucher_type': 'parent:doctype', 'doctype': 'GL Mapper Detail', 'owner': 'Administrator', 'cost_center': 'cost_center', 'voucher_no': 'parent:name', 'modified_by': 'nabin@webnotestech.com', 'against_voucher': "value:d.against_voucher or d.against_invoice or d.against_jv or ''", 'table_field': 'entries', 'transaction_date': 'parent:voucher_date', 'debit': 'debit', 'docstatus': 0, 'parent': 'Journal Voucher', 'company': 'parent:company', 'aging_date': 'parent:aging_date', 'fiscal_year': 'parent:fiscal_year', 'is_advance': 'is_advance', 'remarks': 'parent:remark', 'account': 'account', 'name': 'GLMDetail00001', 'idx': 1, 'against_voucher_type': "value:(d.against_voucher and 'Purchase Invoice') or (d.against_invoice and 'Sales Invoice') or (d.against_jv and 'Journal Voucher') or ''", 'modified': '2010-04-30 17:56:41', 'against': 'against_account', 'credit': 'credit', 'parenttype': 'GL Mapper', 'is_opening': 'parent:is_opening', 'posting_date': 'parent:posting_date', 'parentfield': 'fields'}, {'creation': '2009-06-11 11:09:11', 'voucher_type': 'doctype', 'doctype': 'GL Mapper Detail', 'owner': 'Administrator', 'cost_center': '', 'voucher_no': 'name', 'modified_by': 'nabin@webnotestech.com', 'against_voucher': '', 'table_field': '', 'transaction_date': 'voucher_date', 'debit': 'value:0', 'docstatus': 0, 'parent': 'Journal Voucher', 'company': 'company', 'aging_date': 'aging_date', 'fiscal_year': 'fiscal_year', 'is_advance': '', 'remarks': 'remark', 'account': 'tax_code', 'name': 'GLMDetail00009', 'idx': 2, 'against_voucher_type': None, 'modified': '2010-04-30 17:56:41', 'against': 'supplier_account', 'credit': 'ded_amount', 'parenttype': 'GL Mapper', 'is_opening': 'is_opening', 'posting_date': 'posting_date', 'parentfield': 'fields'}] +[ + { + "owner": "Administrator", + "docstatus": 0, + "creation": "2012-05-01 12:46:31", + "modified_by": "Administrator", + "modified": "2012-05-01 09:16:31" + }, + { + "doc_type": "Journal Voucher", + "name": "__common__", + "doctype": "GL Mapper" + }, + { + "name": "__common__", + "parent": "Journal Voucher", + "doctype": "GL Mapper Detail", + "parenttype": "GL Mapper", + "parentfield": "fields" + }, + { + "name": "Journal Voucher", + "doctype": "GL Mapper" + }, + { + "account": "account", + "doctype": "GL Mapper Detail", + "credit": "credit", + "against_voucher_type": "value:(d.against_voucher and 'Purchase Invoice') or (d.against_invoice and 'Sales Invoice') or (d.against_jv and 'Journal Voucher') or ''", + "company": "parent:company", + "debit": "debit", + "fiscal_year": "parent:fiscal_year", + "against": "against_account", + "voucher_type": "parent:doctype", + "against_voucher": "value:d.against_voucher or d.against_invoice or d.against_jv or ''", + "table_field": "entries", + "transaction_date": "parent:voucher_date", + "is_advance": "is_advance", + "aging_date": "parent:aging_date", + "is_opening": "parent:is_opening", + "remarks": "parent:remark", + "posting_date": "parent:posting_date", + "voucher_no": "parent:name", + "cost_center": "cost_center" + }, + { + "account": "tax_code", + "doctype": "GL Mapper Detail", + "company": "company", + "debit": "value:0", + "fiscal_year": "fiscal_year", + "against": "supplier_account", + "voucher_type": "doctype", + "credit": "ded_amount", + "transaction_date": "voucher_date", + "aging_date": "aging_date", + "is_opening": "is_opening", + "remarks": "remark", + "posting_date": "posting_date", + "voucher_no": "name" + } +] \ No newline at end of file diff --git a/accounts/GL Mapper/POS with write off/POS with write off.txt b/accounts/GL Mapper/POS with write off/POS with write off.txt index a6715c6c35..72b2305563 100644 --- a/accounts/GL Mapper/POS with write off/POS with write off.txt +++ b/accounts/GL Mapper/POS with write off/POS with write off.txt @@ -1,233 +1,148 @@ [ - { - 'creation': '2011-05-10 11:21:22', - 'doc_type': 'POS with write off', - 'docstatus': 0, - 'doctype': 'GL Mapper', - 'idx': None, - 'modified': '2011-05-10 11:21:22', - 'modified_by': 'Administrator', - 'name': 'POS with write off', - 'owner': 'Administrator', - 'parent': None, - 'parentfield': None, - 'parenttype': None - }, - { - 'account': 'income_account', - 'against': 'parent:debit_to', - 'against_voucher': None, - 'against_voucher_type': None, - 'aging_date': 'parent:aging_date', - 'company': 'parent:company', - 'cost_center': 'cost_center', - 'creation': '2011-05-10 11:21:22', - 'credit': 'amount', - 'debit': 'value:0', - 'docstatus': 0, - 'doctype': 'GL Mapper Detail', - 'fiscal_year': 'parent:fiscal_year', - 'idx': 1, - 'is_advance': None, - 'is_opening': 'parent:is_opening', - 'modified': '2011-05-10 11:21:22', - 'modified_by': 'Administrator', - 'name': '000002752', - 'owner': 'Administrator', - 'parent': 'POS with write off', - 'parentfield': 'fields', - 'parenttype': 'GL Mapper', - 'posting_date': 'parent:posting_date', - 'remarks': 'parent:remarks', - 'table_field': 'entries', - 'transaction_date': 'parent:voucher_date', - 'voucher_no': 'parent:name', - 'voucher_type': 'parent:doctype' - }, - { - 'account': 'account_head', - 'against': 'parent:debit_to', - 'against_voucher': None, - 'against_voucher_type': None, - 'aging_date': 'parent:aging_date', - 'company': 'parent:company', - 'cost_center': 'cost_center_other_charges', - 'creation': '2011-05-10 11:21:22', - 'credit': 'tax_amount', - 'debit': 'value:0', - 'docstatus': 0, - 'doctype': 'GL Mapper Detail', - 'fiscal_year': 'parent:fiscal_year', - 'idx': 2, - 'is_advance': None, - 'is_opening': 'parent:is_opening', - 'modified': '2011-05-10 11:21:22', - 'modified_by': 'Administrator', - 'name': '000002753', - 'owner': 'Administrator', - 'parent': 'POS with write off', - 'parentfield': 'fields', - 'parenttype': 'GL Mapper', - 'posting_date': 'parent:posting_date', - 'remarks': 'parent:remarks', - 'table_field': 'other_charges', - 'transaction_date': 'parent:voucher_date', - 'voucher_no': 'parent:name', - 'voucher_type': 'parent:doctype' - }, - { - 'account': 'debit_to', - 'against': 'against_income_account', - 'against_voucher': 'name', - 'against_voucher_type': 'doctype', - 'aging_date': 'aging_date', - 'company': 'company', - 'cost_center': None, - 'creation': '2011-05-10 11:21:22', - 'credit': 'value:0', - 'debit': 'grand_total', - 'docstatus': 0, - 'doctype': 'GL Mapper Detail', - 'fiscal_year': 'fiscal_year', - 'idx': 3, - 'is_advance': None, - 'is_opening': 'is_opening', - 'modified': '2011-05-10 11:21:22', - 'modified_by': 'Administrator', - 'name': '000002754', - 'owner': 'Administrator', - 'parent': 'POS with write off', - 'parentfield': 'fields', - 'parenttype': 'GL Mapper', - 'posting_date': 'posting_date', - 'remarks': 'remarks', - 'table_field': None, - 'transaction_date': 'voucher_date', - 'voucher_no': 'name', - 'voucher_type': 'doctype' - }, - { - 'account': 'debit_to', - 'against': 'cash_bank_account', - 'against_voucher': 'name', - 'against_voucher_type': 'doctype', - 'aging_date': 'aging_date', - 'company': 'company', - 'cost_center': None, - 'creation': '2011-05-10 11:21:22', - 'credit': 'paid_amount', - 'debit': 'value:0', - 'docstatus': 0, - 'doctype': 'GL Mapper Detail', - 'fiscal_year': 'fiscal_year', - 'idx': 4, - 'is_advance': None, - 'is_opening': 'is_opening', - 'modified': '2011-05-10 11:21:22', - 'modified_by': 'Administrator', - 'name': '000002755', - 'owner': 'Administrator', - 'parent': 'POS with write off', - 'parentfield': 'fields', - 'parenttype': 'GL Mapper', - 'posting_date': 'posting_date', - 'remarks': 'remarks', - 'table_field': None, - 'transaction_date': 'voucher_date', - 'voucher_no': 'name', - 'voucher_type': 'doctype' - }, - { - 'account': 'debit_to', - 'against': 'write_off_account', - 'against_voucher': 'name', - 'against_voucher_type': 'doctype', - 'aging_date': 'aging_date', - 'company': 'company', - 'cost_center': None, - 'creation': '2011-05-10 11:21:22', - 'credit': 'write_off_amount', - 'debit': 'value:0', - 'docstatus': 0, - 'doctype': 'GL Mapper Detail', - 'fiscal_year': 'fiscal_year', - 'idx': 5, - 'is_advance': None, - 'is_opening': 'is_opening', - 'modified': '2011-05-10 11:21:22', - 'modified_by': 'Administrator', - 'name': '000002758', - 'owner': 'Administrator', - 'parent': 'POS with write off', - 'parentfield': 'fields', - 'parenttype': 'GL Mapper', - 'posting_date': 'posting_date', - 'remarks': 'remarks', - 'table_field': None, - 'transaction_date': 'voucher_date', - 'voucher_no': 'name', - 'voucher_type': 'doctype' - }, - { - 'account': 'cash_bank_account', - 'against': 'debit_to', - 'against_voucher': None, - 'against_voucher_type': None, - 'aging_date': 'aging_date', - 'company': 'company', - 'cost_center': None, - 'creation': '2011-05-10 11:21:22', - 'credit': 'value:0', - 'debit': 'paid_amount', - 'docstatus': 0, - 'doctype': 'GL Mapper Detail', - 'fiscal_year': 'fiscal_year', - 'idx': 6, - 'is_advance': None, - 'is_opening': 'is_opening', - 'modified': '2011-05-10 11:21:22', - 'modified_by': 'Administrator', - 'name': '000002756', - 'owner': 'Administrator', - 'parent': 'POS with write off', - 'parentfield': 'fields', - 'parenttype': 'GL Mapper', - 'posting_date': 'posting_date', - 'remarks': 'remarks', - 'table_field': None, - 'transaction_date': 'voucher_date', - 'voucher_no': 'name', - 'voucher_type': 'doctype' - }, - { - 'account': 'write_off_account', - 'against': 'debit_to', - 'against_voucher': None, - 'against_voucher_type': None, - 'aging_date': 'aging_date', - 'company': 'company', - 'cost_center': 'write_off_cost_center', - 'creation': '2011-05-10 11:21:22', - 'credit': 'value:0', - 'debit': 'write_off_amount', - 'docstatus': 0, - 'doctype': 'GL Mapper Detail', - 'fiscal_year': 'fiscal_year', - 'idx': 7, - 'is_advance': None, - 'is_opening': 'is_opening', - 'modified': '2011-05-10 11:21:22', - 'modified_by': 'Administrator', - 'name': '000002757', - 'owner': 'Administrator', - 'parent': 'POS with write off', - 'parentfield': 'fields', - 'parenttype': 'GL Mapper', - 'posting_date': 'posting_date', - 'remarks': 'remarks', - 'table_field': None, - 'transaction_date': 'voucher_date', - 'voucher_no': 'name', - 'voucher_type': 'doctype' - } + { + "owner": "Administrator", + "docstatus": 0, + "creation": "2011-05-20 10:07:58", + "modified_by": "Administrator", + "modified": "2012-05-01 09:16:31" + }, + { + "doc_type": "POS with write off", + "name": "__common__", + "doctype": "GL Mapper" + }, + { + "name": "__common__", + "parent": "POS with write off", + "doctype": "GL Mapper Detail", + "parenttype": "GL Mapper", + "parentfield": "fields" + }, + { + "name": "POS with write off", + "doctype": "GL Mapper" + }, + { + "account": "income_account", + "doctype": "GL Mapper Detail", + "company": "parent:company", + "debit": "value:0", + "fiscal_year": "parent:fiscal_year", + "against": "parent:debit_to", + "voucher_type": "parent:doctype", + "credit": "amount", + "table_field": "entries", + "transaction_date": "parent:voucher_date", + "aging_date": "parent:aging_date", + "is_opening": "parent:is_opening", + "remarks": "parent:remarks", + "posting_date": "parent:posting_date", + "voucher_no": "parent:name", + "cost_center": "cost_center" + }, + { + "account": "account_head", + "doctype": "GL Mapper Detail", + "company": "parent:company", + "debit": "value:0", + "fiscal_year": "parent:fiscal_year", + "against": "parent:debit_to", + "voucher_type": "parent:doctype", + "credit": "tax_amount", + "table_field": "other_charges", + "transaction_date": "parent:voucher_date", + "aging_date": "parent:aging_date", + "is_opening": "parent:is_opening", + "remarks": "parent:remarks", + "posting_date": "parent:posting_date", + "voucher_no": "parent:name", + "cost_center": "cost_center_other_charges" + }, + { + "account": "debit_to", + "doctype": "GL Mapper Detail", + "against_voucher": "name", + "against_voucher_type": "doctype", + "company": "company", + "debit": "grand_total", + "fiscal_year": "fiscal_year", + "against": "against_income_account", + "voucher_type": "doctype", + "credit": "value:0", + "transaction_date": "voucher_date", + "aging_date": "aging_date", + "is_opening": "is_opening", + "remarks": "remarks", + "posting_date": "posting_date", + "voucher_no": "name" + }, + { + "account": "debit_to", + "doctype": "GL Mapper Detail", + "against_voucher": "name", + "against_voucher_type": "doctype", + "company": "company", + "debit": "value:0", + "fiscal_year": "fiscal_year", + "against": "cash_bank_account", + "voucher_type": "doctype", + "credit": "paid_amount", + "transaction_date": "voucher_date", + "aging_date": "aging_date", + "is_opening": "is_opening", + "remarks": "remarks", + "posting_date": "posting_date", + "voucher_no": "name" + }, + { + "account": "debit_to", + "doctype": "GL Mapper Detail", + "against_voucher": "name", + "against_voucher_type": "doctype", + "company": "company", + "debit": "value:0", + "fiscal_year": "fiscal_year", + "against": "write_off_account", + "voucher_type": "doctype", + "credit": "write_off_amount", + "transaction_date": "voucher_date", + "aging_date": "aging_date", + "is_opening": "is_opening", + "remarks": "remarks", + "posting_date": "posting_date", + "voucher_no": "name" + }, + { + "account": "cash_bank_account", + "doctype": "GL Mapper Detail", + "company": "company", + "debit": "paid_amount", + "fiscal_year": "fiscal_year", + "against": "debit_to", + "voucher_type": "doctype", + "credit": "value:0", + "transaction_date": "voucher_date", + "aging_date": "aging_date", + "is_opening": "is_opening", + "remarks": "remarks", + "posting_date": "posting_date", + "voucher_no": "name" + }, + { + "account": "write_off_account", + "doctype": "GL Mapper Detail", + "company": "company", + "debit": "write_off_amount", + "fiscal_year": "fiscal_year", + "against": "debit_to", + "voucher_type": "doctype", + "credit": "value:0", + "transaction_date": "voucher_date", + "aging_date": "aging_date", + "is_opening": "is_opening", + "remarks": "remarks", + "posting_date": "posting_date", + "voucher_no": "name", + "cost_center": "write_off_cost_center" + } ] \ No newline at end of file diff --git a/accounts/GL Mapper/POS/POS.txt b/accounts/GL Mapper/POS/POS.txt index dc95439642..0fca5e4aa2 100644 --- a/accounts/GL Mapper/POS/POS.txt +++ b/accounts/GL Mapper/POS/POS.txt @@ -1 +1,117 @@ -[{'doc_type': 'POS', 'modified_by': 'Administrator', 'name': 'POS', 'parent': None, 'creation': '2010-12-14 16:40:09', 'modified': '2010-12-14 20:15:04', 'doctype': 'GL Mapper', 'idx': None, 'parenttype': None, 'owner': 'Administrator', 'docstatus': 0, 'parentfield': None}, {'creation': '2010-12-14 16:40:09', 'voucher_type': 'parent:doctype', 'doctype': 'GL Mapper Detail', 'owner': 'Administrator', 'cost_center': 'cost_center', 'voucher_no': 'parent:name', 'modified_by': 'Administrator', 'against_voucher': None, 'table_field': 'entries', 'transaction_date': 'parent:voucher_date', 'debit': 'value:0', 'docstatus': 0, 'parent': 'POS', 'company': 'parent:company', 'aging_date': 'parent:aging_date', 'fiscal_year': 'parent:fiscal_year', 'is_advance': None, 'remarks': 'parent:remarks', 'account': 'income_account', 'name': 'GLMDetail00010', 'idx': 1, 'against_voucher_type': None, 'modified': '2010-12-14 20:15:04', 'against': 'parent:debit_to', 'credit': 'amount', 'parenttype': 'GL Mapper', 'is_opening': 'parent:is_opening', 'posting_date': 'parent:posting_date', 'parentfield': 'fields'}, {'creation': '2010-12-14 16:40:09', 'voucher_type': 'parent:doctype', 'doctype': 'GL Mapper Detail', 'owner': 'Administrator', 'cost_center': 'cost_center_other_charges', 'voucher_no': 'parent:name', 'modified_by': 'Administrator', 'against_voucher': None, 'table_field': 'other_charges', 'transaction_date': 'parent:voucher_date', 'debit': 'value:0', 'docstatus': 0, 'parent': 'POS', 'company': 'parent:company', 'aging_date': 'parent:aging_date', 'fiscal_year': 'parent:fiscal_year', 'is_advance': None, 'remarks': 'parent:remarks', 'account': 'account_head', 'name': 'GLMDetail00011', 'idx': 2, 'against_voucher_type': None, 'modified': '2010-12-14 20:15:04', 'against': 'parent:debit_to', 'credit': 'tax_amount', 'parenttype': 'GL Mapper', 'is_opening': 'parent:is_opening', 'posting_date': 'parent:posting_date', 'parentfield': 'fields'}, {'creation': '2010-12-14 16:40:09', 'voucher_type': 'doctype', 'doctype': 'GL Mapper Detail', 'owner': 'Administrator', 'cost_center': None, 'voucher_no': 'name', 'modified_by': 'Administrator', 'against_voucher': 'name', 'table_field': None, 'transaction_date': 'voucher_date', 'debit': 'grand_total', 'docstatus': 0, 'parent': 'POS', 'company': 'company', 'aging_date': 'aging_date', 'fiscal_year': 'fiscal_year', 'is_advance': None, 'remarks': 'remarks', 'account': 'debit_to', 'name': 'GLMDetail00012', 'idx': 3, 'against_voucher_type': 'doctype', 'modified': '2010-12-14 20:15:04', 'against': 'against_income_account', 'credit': 'value:0', 'parenttype': 'GL Mapper', 'is_opening': 'is_opening', 'posting_date': 'posting_date', 'parentfield': 'fields'}, {'creation': '2010-12-14 16:40:09', 'voucher_type': 'doctype', 'doctype': 'GL Mapper Detail', 'owner': 'Administrator', 'cost_center': '', 'voucher_no': 'name', 'modified_by': 'Administrator', 'against_voucher': 'name', 'table_field': None, 'transaction_date': 'voucher_date', 'debit': 'value:0', 'docstatus': 0, 'parent': 'POS', 'company': 'company', 'aging_date': 'aging_date', 'fiscal_year': 'fiscal_year', 'is_advance': None, 'remarks': 'remarks', 'account': 'debit_to', 'name': 'GLMDetail00013', 'idx': 4, 'against_voucher_type': 'doctype', 'modified': '2010-12-14 20:15:04', 'against': 'cash_bank_account', 'credit': 'paid_amount', 'parenttype': 'GL Mapper', 'is_opening': 'is_opening', 'posting_date': 'posting_date', 'parentfield': 'fields'}, {'creation': '2010-12-14 16:40:09', 'voucher_type': 'doctype', 'doctype': 'GL Mapper Detail', 'owner': 'Administrator', 'cost_center': '', 'voucher_no': 'name', 'modified_by': 'Administrator', 'against_voucher': '', 'table_field': None, 'transaction_date': 'voucher_date', 'debit': 'paid_amount', 'docstatus': 0, 'parent': 'POS', 'company': 'company', 'aging_date': 'aging_date', 'fiscal_year': 'fiscal_year', 'is_advance': None, 'remarks': 'remarks', 'account': 'cash_bank_account', 'name': 'GLMDetail00014', 'idx': 5, 'against_voucher_type': '', 'modified': '2010-12-14 20:15:04', 'against': 'debit_to', 'credit': 'value:0', 'parenttype': 'GL Mapper', 'is_opening': 'is_opening', 'posting_date': 'posting_date', 'parentfield': 'fields'}] \ No newline at end of file +[ + { + "owner": "Administrator", + "docstatus": 0, + "creation": "2010-12-15 08:39:20", + "modified_by": "Administrator", + "modified": "2012-05-01 09:16:31" + }, + { + "doc_type": "POS", + "name": "__common__", + "doctype": "GL Mapper" + }, + { + "name": "__common__", + "parent": "POS", + "doctype": "GL Mapper Detail", + "parenttype": "GL Mapper", + "parentfield": "fields" + }, + { + "name": "POS", + "doctype": "GL Mapper" + }, + { + "account": "income_account", + "doctype": "GL Mapper Detail", + "company": "parent:company", + "debit": "value:0", + "fiscal_year": "parent:fiscal_year", + "against": "parent:debit_to", + "voucher_type": "parent:doctype", + "credit": "amount", + "table_field": "entries", + "transaction_date": "parent:voucher_date", + "aging_date": "parent:aging_date", + "is_opening": "parent:is_opening", + "remarks": "parent:remarks", + "posting_date": "parent:posting_date", + "voucher_no": "parent:name", + "cost_center": "cost_center" + }, + { + "account": "account_head", + "doctype": "GL Mapper Detail", + "company": "parent:company", + "debit": "value:0", + "fiscal_year": "parent:fiscal_year", + "against": "parent:debit_to", + "voucher_type": "parent:doctype", + "credit": "tax_amount", + "table_field": "other_charges", + "transaction_date": "parent:voucher_date", + "aging_date": "parent:aging_date", + "is_opening": "parent:is_opening", + "remarks": "parent:remarks", + "posting_date": "parent:posting_date", + "voucher_no": "parent:name", + "cost_center": "cost_center_other_charges" + }, + { + "account": "debit_to", + "doctype": "GL Mapper Detail", + "against_voucher": "name", + "against_voucher_type": "doctype", + "company": "company", + "debit": "grand_total", + "fiscal_year": "fiscal_year", + "against": "against_income_account", + "voucher_type": "doctype", + "credit": "value:0", + "transaction_date": "voucher_date", + "aging_date": "aging_date", + "is_opening": "is_opening", + "remarks": "remarks", + "posting_date": "posting_date", + "voucher_no": "name" + }, + { + "account": "debit_to", + "doctype": "GL Mapper Detail", + "credit": "paid_amount", + "against_voucher_type": "doctype", + "company": "company", + "debit": "value:0", + "fiscal_year": "fiscal_year", + "against": "cash_bank_account", + "voucher_type": "doctype", + "against_voucher": "name", + "transaction_date": "voucher_date", + "aging_date": "aging_date", + "is_opening": "is_opening", + "remarks": "remarks", + "posting_date": "posting_date", + "voucher_no": "name", + "cost_center": "" + }, + { + "account": "cash_bank_account", + "doctype": "GL Mapper Detail", + "credit": "value:0", + "against_voucher_type": "", + "company": "company", + "debit": "paid_amount", + "fiscal_year": "fiscal_year", + "against": "debit_to", + "voucher_type": "doctype", + "against_voucher": "", + "transaction_date": "voucher_date", + "aging_date": "aging_date", + "is_opening": "is_opening", + "remarks": "remarks", + "posting_date": "posting_date", + "voucher_no": "name", + "cost_center": "" + } +] \ No newline at end of file diff --git a/accounts/GL Mapper/Purchase Invoice with write off/Purchase Invoice with write off.txt b/accounts/GL Mapper/Purchase Invoice with write off/Purchase Invoice with write off.txt index 05abfff9d7..f32b13b244 100644 --- a/accounts/GL Mapper/Purchase Invoice with write off/Purchase Invoice with write off.txt +++ b/accounts/GL Mapper/Purchase Invoice with write off/Purchase Invoice with write off.txt @@ -2,7 +2,7 @@ { "owner": "Administrator", "docstatus": 0, - "creation": "2012-04-30 19:55:05", + "creation": "2012-10-03 11:29:52", "modified_by": "Administrator", "modified": "2012-10-03 11:08:09" }, @@ -24,89 +24,89 @@ }, { "account": "expense_head", - "doctype": "GL Mapper Detail", "company": "parent:company", - "debit": "amount", "fiscal_year": "parent:fiscal_year", "against": "parent:credit_to", - "aging_date": "parent:aging_date", + "voucher_type": "parent:doctype", "credit": "value:0", "table_field": "entries", "transaction_date": "parent:voucher_date", - "voucher_type": "parent:doctype", - "is_opening": "parent:is_opening", + "aging_date": "parent:aging_date", + "doctype": "GL Mapper Detail", "remarks": "parent:remarks", - "posting_date": "parent:posting_date", + "is_opening": "parent:is_opening", "voucher_no": "parent:name", - "cost_center": "cost_center" + "debit": "amount", + "cost_center": "cost_center", + "posting_date": "parent:posting_date" }, { "account": "account_head", - "doctype": "GL Mapper Detail", "company": "parent:company", - "debit": "value:d.fields.get('category') != 'Valuation' and d.fields.get('add_deduct_tax') == 'Add' and d.fields.get('tax_amount') or 0", "fiscal_year": "parent:fiscal_year", "against": "parent:credit_to", - "aging_date": "parent:aging_date", + "voucher_type": "parent:doctype", "credit": "value:d.fields.get('category') != 'Valuation' and d.fields.get('add_deduct_tax') == 'Deduct' and d.fields.get('tax_amount') or 0", "table_field": "purchase_tax_details", "transaction_date": "parent:voucher_date", - "voucher_type": "parent:doctype", - "is_opening": "parent:is_opening", + "aging_date": "parent:aging_date", + "doctype": "GL Mapper Detail", "remarks": "parent:remarks", - "posting_date": "parent:posting_date", + "is_opening": "parent:is_opening", "voucher_no": "parent:name", - "cost_center": "cost_center" + "debit": "value:d.fields.get('category') != 'Valuation' and d.fields.get('add_deduct_tax') == 'Add' and d.fields.get('tax_amount') or 0", + "cost_center": "cost_center", + "posting_date": "parent:posting_date" }, { "account": "tax_code", - "doctype": "GL Mapper Detail", "company": "company", - "debit": "value:0", "fiscal_year": "fiscal_year", "against": "credit_to", - "aging_date": "aging_date", - "credit": "ded_amount", - "transaction_date": "voucher_date", "voucher_type": "doctype", - "is_opening": "is_opening", + "credit": "ded_amount", + "debit": "value:0", + "transaction_date": "voucher_date", + "aging_date": "aging_date", + "doctype": "GL Mapper Detail", "remarks": "remarks", - "posting_date": "posting_date", - "voucher_no": "name" + "is_opening": "is_opening", + "voucher_no": "name", + "posting_date": "posting_date" }, { "account": "credit_to", - "doctype": "GL Mapper Detail", - "credit": "total_amount_to_pay", + "against_voucher": "name", "against_voucher_type": "value:'Purchase Invoice'", "company": "company", - "debit": "value:0", "fiscal_year": "fiscal_year", "against": "against_expense_account", - "aging_date": "aging_date", - "against_voucher": "name", - "transaction_date": "voucher_date", "voucher_type": "doctype", - "is_opening": "is_opening", + "credit": "total_amount_to_pay", + "debit": "value:0", + "transaction_date": "voucher_date", + "aging_date": "aging_date", + "doctype": "GL Mapper Detail", "remarks": "remarks", - "posting_date": "posting_date", - "voucher_no": "name" + "is_opening": "is_opening", + "voucher_no": "name", + "posting_date": "posting_date" }, { "account": "write_off_account", - "doctype": "GL Mapper Detail", "company": "company", - "debit": "value:0", "fiscal_year": "fiscal_year", "against": "credit_to", - "aging_date": "aging_date", - "credit": "write_off_amount", - "transaction_date": "voucher_date", "voucher_type": "doctype", - "is_opening": "is_opening", + "credit": "write_off_amount", + "debit": "value:0", + "transaction_date": "voucher_date", + "aging_date": "aging_date", + "doctype": "GL Mapper Detail", "remarks": "remarks", - "posting_date": "posting_date", + "is_opening": "is_opening", "voucher_no": "name", - "cost_center": "write_off_cost_center" + "cost_center": "write_off_cost_center", + "posting_date": "posting_date" } ] \ No newline at end of file diff --git a/accounts/GL Mapper/Purchase Invoice/Purchase Invoice.txt b/accounts/GL Mapper/Purchase Invoice/Purchase Invoice.txt index 125116504d..b3dbdbf15c 100644 --- a/accounts/GL Mapper/Purchase Invoice/Purchase Invoice.txt +++ b/accounts/GL Mapper/Purchase Invoice/Purchase Invoice.txt @@ -2,7 +2,7 @@ { "owner": "Administrator", "docstatus": 0, - "creation": "2012-04-30 19:55:04", + "creation": "2012-10-03 11:29:52", "modified_by": "Administrator", "modified": "2012-10-03 11:07:26" }, @@ -29,11 +29,11 @@ "debit": "amount", "fiscal_year": "parent:fiscal_year", "against": "parent:credit_to", - "aging_date": "parent:aging_date", + "voucher_type": "parent:doctype", "credit": "value:0", "table_field": "entries", "transaction_date": "parent:voucher_date", - "voucher_type": "parent:doctype", + "aging_date": "parent:aging_date", "is_opening": "parent:is_opening", "remarks": "parent:remarks", "posting_date": "parent:posting_date", @@ -47,11 +47,11 @@ "debit": "value:d.fields.get('category') != 'Valuation' and d.fields.get('add_deduct_tax') == 'Add' and d.fields.get('tax_amount') or 0", "fiscal_year": "parent:fiscal_year", "against": "parent:credit_to", - "aging_date": "parent:aging_date", + "voucher_type": "parent:doctype", "credit": "value:d.fields.get('category') != 'Valuation' and d.fields.get('add_deduct_tax') == 'Deduct' and d.fields.get('tax_amount') or 0", "table_field": "purchase_tax_details", "transaction_date": "parent:voucher_date", - "voucher_type": "parent:doctype", + "aging_date": "parent:aging_date", "is_opening": "parent:is_opening", "remarks": "parent:remarks", "posting_date": "parent:posting_date", @@ -65,10 +65,10 @@ "debit": "value:0", "fiscal_year": "fiscal_year", "against": "credit_to", - "aging_date": "aging_date", + "voucher_type": "doctype", "credit": "ded_amount", "transaction_date": "voucher_date", - "voucher_type": "doctype", + "aging_date": "aging_date", "is_opening": "is_opening", "remarks": "remarks", "posting_date": "posting_date", @@ -77,16 +77,16 @@ { "account": "credit_to", "doctype": "GL Mapper Detail", - "credit": "total_amount_to_pay", + "against_voucher": "name", "against_voucher_type": "value:'Purchase Invoice'", "company": "company", "debit": "value:0", "fiscal_year": "fiscal_year", "against": "against_expense_account", - "aging_date": "aging_date", - "against_voucher": "name", - "transaction_date": "voucher_date", "voucher_type": "doctype", + "credit": "total_amount_to_pay", + "transaction_date": "voucher_date", + "aging_date": "aging_date", "is_opening": "is_opening", "remarks": "remarks", "posting_date": "posting_date", diff --git a/accounts/GL Mapper/Sales Invoice/Sales Invoice.txt b/accounts/GL Mapper/Sales Invoice/Sales Invoice.txt index 4a4df3c7e5..6057a27d8f 100644 --- a/accounts/GL Mapper/Sales Invoice/Sales Invoice.txt +++ b/accounts/GL Mapper/Sales Invoice/Sales Invoice.txt @@ -1 +1,81 @@ -[{'doc_type': 'Sales Invoice', 'modified_by': 'Administrator', 'name': 'Sales Invoice', 'parent': None, 'creation': '2009-03-12 12:09:24', 'modified': '2010-05-17 08:59:14', 'module': 'Accounts', 'doctype': 'GL Mapper', 'idx': None, 'parenttype': None, 'owner': 'Administrator', 'docstatus': 0, 'parentfield': None}, {'creation': '2009-03-12 12:09:24', 'voucher_type': 'parent:doctype', 'doctype': 'GL Mapper Detail', 'owner': 'Administrator', 'cost_center': 'cost_center', 'voucher_no': 'parent:name', 'modified_by': 'Administrator', 'against_voucher': None, 'table_field': 'entries', 'transaction_date': 'parent:voucher_date', 'debit': 'value:0', 'docstatus': 0, 'parent': 'Sales Invoice', 'company': 'parent:company', 'aging_date': 'parent:aging_date', 'fiscal_year': 'parent:fiscal_year', 'is_advance': None, 'remarks': 'parent:remarks', 'account': 'income_account', 'name': 'GLMDetail00006', 'idx': 1, 'against_voucher_type': None, 'modified': '2010-05-17 08:59:14', 'against': 'parent:debit_to', 'credit': 'amount', 'parenttype': 'GL Mapper', 'is_opening': 'parent:is_opening', 'posting_date': 'parent:posting_date', 'parentfield': 'fields'}, {'creation': '2009-03-12 12:09:24', 'voucher_type': 'parent:doctype', 'doctype': 'GL Mapper Detail', 'owner': 'Administrator', 'cost_center': 'cost_center_other_charges', 'voucher_no': 'parent:name', 'modified_by': 'Administrator', 'against_voucher': None, 'table_field': 'other_charges', 'transaction_date': 'parent:voucher_date', 'debit': 'value:0', 'docstatus': 0, 'parent': 'Sales Invoice', 'company': 'parent:company', 'aging_date': 'parent:aging_date', 'fiscal_year': 'parent:fiscal_year', 'is_advance': None, 'remarks': 'parent:remarks', 'account': 'account_head', 'name': 'GLMDetail00007', 'idx': 2, 'against_voucher_type': None, 'modified': '2010-05-17 08:59:14', 'against': 'parent:debit_to', 'credit': 'tax_amount', 'parenttype': 'GL Mapper', 'is_opening': 'parent:is_opening', 'posting_date': 'parent:posting_date', 'parentfield': 'fields'}, {'creation': '2009-03-12 12:09:24', 'voucher_type': 'doctype', 'doctype': 'GL Mapper Detail', 'owner': 'Administrator', 'cost_center': '', 'voucher_no': 'name', 'modified_by': 'Administrator', 'against_voucher': 'name', 'table_field': '', 'transaction_date': 'voucher_date', 'debit': 'grand_total', 'docstatus': 0, 'parent': 'Sales Invoice', 'company': 'company', 'aging_date': 'aging_date', 'fiscal_year': 'fiscal_year', 'is_advance': None, 'remarks': 'remarks', 'account': 'debit_to', 'name': 'GLMDetail00008', 'idx': 3, 'against_voucher_type': "value:'Sales Invoice'", 'modified': '2010-05-17 08:59:14', 'against': 'against_income_account', 'credit': 'value:0', 'parenttype': 'GL Mapper', 'is_opening': 'is_opening', 'posting_date': 'posting_date', 'parentfield': 'fields'}] \ No newline at end of file +[ + { + "owner": "Administrator", + "docstatus": 0, + "creation": "2010-08-08 17:09:36", + "modified_by": "Administrator", + "modified": "2012-05-01 09:16:31" + }, + { + "doc_type": "Receivable Voucher", + "name": "__common__", + "doctype": "GL Mapper" + }, + { + "name": "__common__", + "parent": "Sales Invoice", + "doctype": "GL Mapper Detail", + "parenttype": "GL Mapper", + "parentfield": "fields" + }, + { + "name": "Sales Invoice", + "doctype": "GL Mapper" + }, + { + "account": "income_account", + "doctype": "GL Mapper Detail", + "company": "parent:company", + "debit": "value:0", + "fiscal_year": "parent:fiscal_year", + "against": "parent:debit_to", + "voucher_type": "parent:doctype", + "credit": "amount", + "table_field": "entries", + "transaction_date": "parent:voucher_date", + "aging_date": "parent:aging_date", + "is_opening": "parent:is_opening", + "remarks": "parent:remarks", + "posting_date": "parent:posting_date", + "voucher_no": "parent:name", + "cost_center": "cost_center" + }, + { + "account": "account_head", + "doctype": "GL Mapper Detail", + "company": "parent:company", + "debit": "value:0", + "fiscal_year": "parent:fiscal_year", + "against": "parent:debit_to", + "voucher_type": "parent:doctype", + "credit": "tax_amount", + "table_field": "other_charges", + "transaction_date": "parent:voucher_date", + "aging_date": "parent:aging_date", + "is_opening": "parent:is_opening", + "remarks": "parent:remarks", + "posting_date": "parent:posting_date", + "voucher_no": "parent:name", + "cost_center": "cost_center_other_charges" + }, + { + "account": "debit_to", + "doctype": "GL Mapper Detail", + "credit": "value:0", + "against_voucher_type": "value:'Sales Invoice'", + "company": "company", + "debit": "grand_total", + "fiscal_year": "fiscal_year", + "against": "against_income_account", + "voucher_type": "doctype", + "against_voucher": "name", + "table_field": "", + "transaction_date": "voucher_date", + "aging_date": "aging_date", + "is_opening": "is_opening", + "remarks": "remarks", + "posting_date": "posting_date", + "voucher_no": "name", + "cost_center": "" + } +] \ No newline at end of file diff --git a/accounts/__init__.py b/accounts/__init__.py index 3fdf4ef926..707203f500 100644 --- a/accounts/__init__.py +++ b/accounts/__init__.py @@ -20,11 +20,6 @@ from webnotes.utils import flt from webnotes.model.code import get_obj from accounts.utils import get_balance_on -install_docs = [ - {"doctype":"Role", "role_name":"Accounts Manager", "name":"Accounts Manager"}, - {"doctype":"Role", "role_name":"Accounts User", "name":"Accounts User"} -] - @webnotes.whitelist() def get_default_bank_account(): """ diff --git a/accounts/module_def/accounts/locale/_messages_doc.json b/accounts/module_def/accounts/locale/_messages_doc.json deleted file mode 100644 index b587937a34..0000000000 --- a/accounts/module_def/accounts/locale/_messages_doc.json +++ /dev/null @@ -1,17 +0,0 @@ -[ - "Trial Balance", - "Voucher Import Tool", - "Track separate Income and Expense for product verticals or divisions.", - "Delivered Items To Be Billed", - "Heads (or groups) against which Accounting Entries are made and balances are maintained.", - "Standard tax template that can be applied to all Sales Transactions. This template can contain list of tax heads and also other expense / income heads like \"Shipping\", \"Insurance\", \"Handling\" etc.#### NoteThe tax rate you define here will be the standard tax rate for all **Items**. If there are **Items** that have different rates, they must be added in the **Item Tax** table in the **Item** master.#### Description of Columns1. Calculation Type: - This can be on **Net Total** (that is the sum of basic amount). - **On Previous Row Total / Amount** (for cumulative taxes or charges). If you select this option, the tax will be applied as a percentage of the previous row (in the tax table) amount or total. - **Actual** (as mentioned).2. Account Head: The Account ledger under which this tax will be booked3. Cost Center: If the tax / charge is an income (like shipping) or expense it needs to be booked against a Cost Center.4. Description: Description of the tax (that will be printed in invoices / quotes).5. Rate: Tax rate.6. Amount: Tax amount.7. Total: Cumulative total to this point.8. Enter Row: If based on \"Previous Row Total\" you can select the row number which will be taken as a base for this calculation (default is the previous row).9. Is this Tax included in Basic Rate?: If you check this, it means that this tax will not be shown below the item table, but will be included in the Basic Rate in your main item table. This is useful where you want give a flat price (inclusive of all taxes) price to customers.", - "Financial Statements", - "General Ledger", - "**Budget Distribution** helps you distribute your budget across months if you have seasonality in your business.To distribute a budget using this distribution, set this **Budget Distribution** in the **Cost Center**", - "Accounts Home", - "Ordered Items To Be Billed", - "**Fiscal Year** represents a Financial Year. All accounting entries and other major transactions are tracked against **Fiscal Year**.", - "Financial Analytics", - "Accounts Browser", - "Standard tax template that can be applied to all Purchase Transactions. This template can contain list of tax heads and also other expense heads like \"Shipping\", \"Insurance\", \"Handling\" etc.#### NoteThe tax rate you define here will be the standard tax rate for all **Items**. If there are **Items** that have different rates, they must be added in the **Item Tax** table in the **Item** master.#### Description of Columns1. Calculation Type: - This can be on **Net Total** (that is the sum of basic amount). - **On Previous Row Total / Amount** (for cumulative taxes or charges). If you select this option, the tax will be applied as a percentage of the previous row (in the tax table) amount or total. - **Actual** (as mentioned).2. Account Head: The Account ledger under which this tax will be booked3. Cost Center: If the tax / charge is an income (like shipping) or expense it needs to be booked against a Cost Center.4. Description: Description of the tax (that will be printed in invoices / quotes).5. Rate: Tax rate.6. Amount: Tax amount.7. Total: Cumulative total to this point.8. Enter Row: If based on \"Previous Row Total\" you can select the row number which will be taken as a base for this calculation (default is the previous row).9. Consider Tax or Charge for: In this section you can specify if the tax / charge is only for valuation (not a part of total) or only for total (does not add value to the item) or for both.10. Add or Deduct: Whether you want to add or deduct the tax." -] \ No newline at end of file diff --git a/accounts/module_def/accounts/locale/hi-doc.json b/accounts/module_def/accounts/locale/hi-doc.json deleted file mode 100644 index df51c84b28..0000000000 --- a/accounts/module_def/accounts/locale/hi-doc.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "**Budget Distribution** helps you distribute your budget across months if you have seasonality in your business.To distribute a budget using this distribution, set this **Budget Distribution** in the **Cost Center**": "** \u092c\u091c\u091f \u0935\u093f\u0924\u0930\u0923 ** \u092e\u0926\u0926 \u0915\u0930\u0924\u093e \u0939\u0948 \u0914\u0930 \u0906\u092a \u092e\u0939\u0940\u0928\u0947 \u092d\u0930 \u092e\u0947\u0902 \u0906\u092a\u0915\u093e \u092c\u091c\u091f \u0935\u093f\u0924\u0930\u093f\u0924 \u0905\u0917\u0930 \u0906\u092a \u0905\u092a\u0928\u0947 business.To \u092e\u0947\u0902 \u0907\u0938 \u0935\u093f\u0924\u0930\u0923 \u0915\u093e \u0909\u092a\u092f\u094b\u0917 \u0915\u0930 \u092c\u091c\u091f \u0939\u0948, \u0907\u0938 \u092c\u091c\u091f ** \u0935\u093f\u0924\u0930\u0923 \u0938\u0947\u091f ** ** ** \u0932\u093e\u0917\u0924 \u0915\u0947\u0902\u0926\u094d\u0930 \u092e\u0947\u0902 \u0935\u093f\u0924\u0930\u093f\u0924 \u092e\u094c\u0938\u092e \u0939\u0948", - "**Fiscal Year** represents a Financial Year. All accounting entries and other major transactions are tracked against **Fiscal Year**.": "** \u0935\u093f\u0924\u094d\u0924 \u0935\u0930\u094d\u0937 ** \u090f\u0915 \u0935\u093f\u0924\u094d\u0924\u0940\u092f \u0935\u0930\u094d\u0937 \u0915\u093e \u092a\u094d\u0930\u0924\u093f\u0928\u093f\u0927\u093f\u0924\u094d\u0935 \u0915\u0930\u0924\u093e \u0939\u0948. \u0938\u092d\u0940 \u0932\u0947\u0916\u093e \u092a\u094d\u0930\u0935\u093f\u0937\u094d\u091f\u093f\u092f\u094b\u0902 \u0914\u0930 \u0905\u0928\u094d\u092f \u092a\u094d\u0930\u092e\u0941\u0916 \u0932\u0947\u0928\u0926\u0947\u0928 ** \u0935\u093f\u0924\u094d\u0924 \u0935\u0930\u094d\u0937 \u0915\u0947 \u0916\u093f\u0932\u093e\u092b \u091f\u094d\u0930\u0948\u0915 \u0915\u0930 \u0930\u0939\u0947 \u0939\u0948\u0902.", - "Accounts Browser": "\u0932\u0947\u0916\u093e \u092c\u094d\u0930\u093e\u0909\u091c\u093c\u0930", - "Accounts Home": "\u0932\u0947\u0916\u093e \u0918\u0930", - "Delivered Items To Be Billed": "\u0935\u093f\u0924\u0930\u093f\u0924 \u0915\u0930\u0928\u0947 \u0915\u0947 \u0932\u093f\u090f \u092c\u093f\u0932 \u0906\u0907\u091f\u092e", - "Financial Analytics": "\u0935\u093f\u0924\u094d\u0924\u0940\u092f \u0935\u093f\u0936\u094d\u0932\u0947\u0937\u093f\u0915\u0940", - "Financial Statements": "\u0935\u093f\u0924\u094d\u0924\u0940\u092f \u0935\u093f\u0935\u0930\u0923", - "General Ledger": "\u0938\u093e\u092e\u093e\u0928\u094d\u092f \u0916\u093e\u0924\u093e", - "Heads (or groups) against which Accounting Entries are made and balances are maintained.": "(\u092f\u093e \u0938\u092e\u0942\u0939) \u092a\u094d\u0930\u092e\u0941\u0916\u094b\u0902 \u0915\u0947 \u0916\u093f\u0932\u093e\u092b \u091c\u094b \u0932\u0947\u0916\u093e \u092a\u094d\u0930\u0935\u093f\u0937\u094d\u091f\u093f\u092f\u093e\u0902 \u092c\u0928\u093e \u0930\u0939\u0947 \u0939\u0948\u0902 \u0914\u0930 \u0936\u0947\u0937 \u0930\u093e\u0936\u093f \u092c\u0928\u093e\u090f \u0930\u0916\u093e \u091c\u093e\u0924\u093e \u0939\u0948.", - "Ordered Items To Be Billed": "\u0939\u093f\u0938\u093e\u092c \u0938\u0947 \u092c\u093f\u0932\u093f\u0902\u0917 \u0915\u093f\u090f \u0906\u0907\u091f\u092e", - "Standard tax template that can be applied to all Purchase Transactions. This template can contain list of tax heads and also other expense heads like \"Shipping\", \"Insurance\", \"Handling\" etc.#### NoteThe tax rate you define here will be the standard tax rate for all **Items**. If there are **Items** that have different rates, they must be added in the **Item Tax** table in the **Item** master.#### Description of Columns1. Calculation Type: - This can be on **Net Total** (that is the sum of basic amount). - **On Previous Row Total / Amount** (for cumulative taxes or charges). If you select this option, the tax will be applied as a percentage of the previous row (in the tax table) amount or total. - **Actual** (as mentioned).2. Account Head: The Account ledger under which this tax will be booked3. Cost Center: If the tax / charge is an income (like shipping) or expense it needs to be booked against a Cost Center.4. Description: Description of the tax (that will be printed in invoices / quotes).5. Rate: Tax rate.6. Amount: Tax amount.7. Total: Cumulative total to this point.8. Enter Row: If based on \"Previous Row Total\" you can select the row number which will be taken as a base for this calculation (default is the previous row).9. Consider Tax or Charge for: In this section you can specify if the tax / charge is only for valuation (not a part of total) or only for total (does not add value to the item) or for both.10. Add or Deduct: Whether you want to add or deduct the tax.": "\u092e\u093e\u0928\u0915 \u0915\u0930 \u091f\u0947\u092e\u094d\u092a\u0932\u0947\u091f \u0939\u0948 \u0915\u093f \u0938\u092d\u0940 \u0916\u0930\u0940\u0926 \u0932\u0947\u0928\u0926\u0947\u0928 \u0915\u0947 \u0932\u093f\u090f \u0932\u093e\u0917\u0942 \u0915\u093f\u092f\u093e \u091c\u093e \u0938\u0915\u0924\u093e \u0939\u0948. \u0907\u0938 \u091f\u0947\u092e\u094d\u092a\u0932\u0947\u091f \u0915\u0947 "\u0928\u094c\u0935\u0939\u0928" \u0915\u0940 \u0924\u0930\u0939 \u0915\u0930 \u092d\u0940 \u0938\u093f\u0930 \u0914\u0930 \u0905\u0928\u094d\u092f \u0916\u0930\u094d\u091a \u0938\u093f\u0930 \u0938\u0942\u091a\u0940, "\u092c\u0940\u092e\u093e", "\u0939\u0948\u0902\u0921\u0932\u093f\u0902\u0917" \u0939\u094b\u0924\u0947 \u0939\u0948\u0902 \u0906\u0926\u093f # # # # NoteThe \u0915\u0930 \u0924\u0941\u092e \u092f\u0939\u093e\u0901 \u0915\u094b \u092a\u0930\u093f\u092d\u093e\u0937\u093f\u0924 \u0915\u0930\u0928\u0947 \u0915\u0947 \u0932\u093f\u090f \u092e\u093e\u0928\u0915 \u0926\u0930 \u0915\u0930 \u0915\u0940 \u0926\u0930 \u0938\u092d\u0940 ** \u0906\u0907\u091f\u092e \u0915\u0947 \u0932\u093f\u090f \u0915\u0930\u0947\u0902\u0917\u0947 \u0915\u0930 \u0938\u0915\u0924\u0947 \u0939\u0948\u0902 . \u0905\u0917\u0930 \u0935\u0939\u093e\u0901 ** ** \u0906\u0907\u091f\u092e \u0939\u0948 \u0915\u093f \u0905\u0932\u0917 \u0926\u0930\u094b\u0902 \u0915\u0930 \u0930\u0939\u0947 \u0939\u0948\u0902, \u0935\u0947 \u0906\u0907\u091f\u092e ** \u092e\u0947\u0902 \u0906\u0907\u091f\u092e ** \u0924\u093e\u0932\u093f\u0915\u093e ** \u091f\u0948\u0915\u094d\u0938 \u092e\u0947\u0902 \u091c\u094b\u0921\u093c\u093e \u091c\u093e\u0928\u093e \u091a\u093e\u0939\u093f\u090f Columns1 \u0915\u093e \u0935\u093f\u0935\u0930\u0923 ** \u092e\u093e\u0938\u094d\u091f\u0930. # # # #. \u0917\u0923\u0928\u093e \u0915\u0947 \u092a\u094d\u0930\u0915\u093e\u0930: - \u092f\u0939 ** \u0928\u0947\u091f \u0915\u0941\u0932 \u092a\u0930 \u0939\u094b \u0938\u0915\u0924\u093e \u0939\u0948 (\u0915\u093f \u092e\u0942\u0932 \u0930\u093e\u0936\u093f \u0915\u093e \u092f\u094b\u0917 \u0939\u0948). - ** / \u092a\u093f\u091b\u0932\u093e \u092a\u0902\u0915\u094d\u0924\u093f \u092a\u0930 \u0915\u0941\u0932 ** \u0930\u093e\u0936\u093f (\u0938\u0902\u091a\u092f\u0940 \u0915\u0930\u094b\u0902 \u092f\u093e \u0936\u0941\u0932\u094d\u0915\u094b\u0902 \u0915\u0947 \u0932\u093f\u090f). \u092f\u0926\u093f \u0906\u092a \u0907\u0938 \u0935\u093f\u0915\u0932\u094d\u092a \u0915\u093e \u091a\u092f\u0928 \u0915\u0930\u0924\u0947 \u0939\u0948\u0902, \u0915\u0930 \u092a\u093f\u091b\u0932\u0947 \u092a\u0902\u0915\u094d\u0924\u093f \u0915\u0947 \u090f\u0915 \u092a\u094d\u0930\u0924\u093f\u0936\u0924 (\u0915\u0930 \u0924\u093e\u0932\u093f\u0915\u093e \u092e\u0947\u0902) \u092f\u093e \u0915\u0941\u0932 \u0930\u093e\u0936\u093f \u0915\u0947 \u0930\u0942\u092a \u092e\u0947\u0902 \u0932\u093e\u0917\u0942 \u0915\u093f\u092f\u093e \u091c\u093e\u090f\u0917\u093e. - ** \u0938\u092e\u093e\u091a\u093e (\u0915\u0947 \u0930\u0942\u092a \u092e\u0947\u0902 \u0909\u0932\u094d\u0932\u0947\u0916 \u0915\u093f\u092f\u093e \u0939\u0948) ** .2. \u0916\u093e\u0924\u093e \u0938\u093f\u0930: \u0916\u093e\u0924\u093e \u092c\u0939\u0940 \u0916\u093e\u0924\u093e \u0939\u0948 \u091c\u093f\u0938\u0915\u0947 \u0924\u0939\u0924 \u092f\u0939 \u0915\u0930 booked3 \u0939\u094b\u0917\u093e. \u0932\u093e\u0917\u0924 \u0915\u0947\u0902\u0926\u094d\u0930: \u092f\u0926\u093f \u0915\u0930 \u092a\u094d\u0930\u092d\u093e\u0930\u0940 / \u090f\u0915 \u0936\u093f\u092a\u093f\u0902\u0917 \u091c\u0948\u0938\u0947 \u0906\u092f \u092f\u093e \u0916\u0930\u094d\u091a \u0939\u0948 \u092f\u0939 \u090f\u0915 Center.4 \u0932\u093e\u0917\u0924 \u0915\u0947 \u0916\u093f\u0932\u093e\u092b \u0906\u0930\u0915\u094d\u0937\u0923 \u0915\u0940 \u091c\u0930\u0942\u0930\u0924 \u0939\u0948. \u0935\u093f\u0935\u0930\u0923: \u0915\u0930 \u0915\u093e \u0935\u093f\u0935\u0930\u0923 (\u0915\u093f \u091a\u093e\u0932\u093e\u0928 / \u0909\u0926\u094d\u0927\u0930\u0923 \u092e\u0947\u0902 \u092e\u0941\u0926\u094d\u0930\u093f\u0924 \u0915\u093f\u092f\u093e \u091c\u093e\u090f\u0917\u093e) 0.5. \u0926\u0930: rate.6 \u0915\u0930. \u0930\u093e\u0936\u093f: amount.7 \u0915\u0930. \u0915\u0941\u0932: point.8 \u0907\u0938 \u0938\u0902\u091a\u092f\u0940 \u0915\u0941\u0932. \u092a\u0902\u0915\u094d\u0924\u093f \u0926\u0930\u094d\u091c \u0915\u0930\u0947\u0902: \u092f\u0926\u093f "\u092a\u093f\u091b\u0932\u0940 \u092a\u0902\u0915\u094d\u0924\u093f \u0915\u0941\u0932" \u0915\u0947 \u0906\u0927\u093e\u0930 \u092a\u0930 \u0906\u092a \u092a\u0902\u0915\u094d\u0924\u093f \u0938\u0902\u0916\u094d\u092f\u093e \u0939\u0948 \u091c\u094b \u0907\u0938 \u0917\u0923\u0928\u093e (\u092a\u093f\u091b\u0932\u0940 \u092a\u0902\u0915\u094d\u0924\u093f \u092e\u0942\u0932\u092d\u0942\u0924 \u0939\u0948) .9 \u0915\u0947 \u0932\u093f\u090f \u090f\u0915 \u0906\u0927\u093e\u0930 \u0915\u0947 \u0930\u0942\u092a \u092e\u0947\u0902 \u0932\u0947 \u091c\u093e\u092f\u093e \u091c\u093e\u090f\u0917\u093e \u0915\u093e \u091a\u092f\u0928 \u0915\u0930 \u0938\u0915\u0924\u0947 \u0939\u0948\u0902. \u0915\u0947 \u0932\u093f\u090f \u091f\u0948\u0915\u094d\u0938 \u092f\u093e \u0936\u0941\u0932\u094d\u0915 \u092a\u0930 \u0935\u093f\u091a\u093e\u0930 \u0915\u0930\u0947\u0902: \u0907\u0938 \u0905\u0928\u0941\u092d\u093e\u0917 \u092e\u0947\u0902 \u0906\u092a \u0905\u0917\u0930 \u0915\u0930 \u092a\u094d\u0930\u092d\u093e\u0930\u0940 / \u092e\u0942\u0932\u094d\u092f\u093e\u0902\u0915\u0928 (\u0915\u0941\u0932 \u0915\u093e \u090f\u0915 \u0939\u093f\u0938\u094d\u0938\u093e \u0928\u0939\u0940\u0902) \u0915\u0947 \u0932\u093f\u090f \u0915\u0947\u0935\u0932 \u090f\u0915 \u092f\u093e \u0915\u0947\u0935\u0932 \u0915\u0941\u0932 \u0915\u0947 \u0932\u093f\u090f \u0928\u093f\u0930\u094d\u0926\u093f\u0937\u094d\u091f \u0915\u0930 \u0938\u0915\u0924\u0947 \u0939\u0948\u0902 (\u0906\u0907\u091f\u092e \u0915\u094b \u091c\u094b\u0921\u093c \u0928\u0939\u0940\u0902 \u092e\u093e\u0928) \u092f\u093e both.10 \u0915\u0947 \u0932\u093f\u090f. \u091c\u094b\u0921\u093c\u0947\u0902 \u092f\u093e \u0918\u091f\u093e: \u091a\u093e\u0939\u0947 \u0906\u092a \u091c\u094b\u0921\u093c \u0938\u0915\u0924\u0947 \u0939\u0948\u0902 \u092f\u093e \u0918\u091f\u093e \u0915\u0930 \u0915\u0930\u0928\u093e \u091a\u093e\u0939\u0924\u0947 \u0939\u0948\u0902.", - "Standard tax template that can be applied to all Sales Transactions. This template can contain list of tax heads and also other expense / income heads like \"Shipping\", \"Insurance\", \"Handling\" etc.#### NoteThe tax rate you define here will be the standard tax rate for all **Items**. If there are **Items** that have different rates, they must be added in the **Item Tax** table in the **Item** master.#### Description of Columns1. Calculation Type: - This can be on **Net Total** (that is the sum of basic amount). - **On Previous Row Total / Amount** (for cumulative taxes or charges). If you select this option, the tax will be applied as a percentage of the previous row (in the tax table) amount or total. - **Actual** (as mentioned).2. Account Head: The Account ledger under which this tax will be booked3. Cost Center: If the tax / charge is an income (like shipping) or expense it needs to be booked against a Cost Center.4. Description: Description of the tax (that will be printed in invoices / quotes).5. Rate: Tax rate.6. Amount: Tax amount.7. Total: Cumulative total to this point.8. Enter Row: If based on \"Previous Row Total\" you can select the row number which will be taken as a base for this calculation (default is the previous row).9. Is this Tax included in Basic Rate?: If you check this, it means that this tax will not be shown below the item table, but will be included in the Basic Rate in your main item table. This is useful where you want give a flat price (inclusive of all taxes) price to customers.": "\u092e\u093e\u0928\u0915 \u0915\u0930 \u091f\u0947\u092e\u094d\u092a\u0932\u0947\u091f \u0939\u0948 \u0915\u093f \u0938\u092d\u0940 \u092c\u093f\u0915\u094d\u0930\u0940 \u0932\u0947\u0928\u0926\u0947\u0928 \u0915\u0947 \u0932\u093f\u090f \u0932\u093e\u0917\u0942 \u0915\u093f\u092f\u093e \u091c\u093e \u0938\u0915\u0924\u093e \u0939\u0948. \u0907\u0938 \u091f\u0947\u092e\u094d\u092a\u0932\u0947\u091f \u0915\u0930 \u092a\u094d\u0930\u092e\u0941\u0916\u094b\u0902 \u0915\u0940 \u0938\u0942\u091a\u0940 \u092e\u0947\u0902 \u0914\u0930 \u092d\u0940 \u0924\u0930\u0939 "\u0928\u094c\u0935\u0939\u0928" \u0905\u0928\u094d\u092f \u0935\u094d\u092f\u092f / \u0906\u092f \u0938\u093f\u0930, "\u092c\u0940\u092e\u093e", "\u0939\u0948\u0902\u0921\u0932\u093f\u0902\u0917" \u0906\u0926\u093f # # # # NoteThe \u0915\u0930 \u0926\u0930 \u0924\u0941\u092e \u092f\u0939\u093e\u0901 \u0915\u094b \u092a\u0930\u093f\u092d\u093e\u0937\u093f\u0924 \u092e\u093e\u0928\u0915 \u0938\u092d\u0940 ** \u0906\u0907\u091f\u092e \u0915\u0947 \u0932\u093f\u090f \u0915\u0930 \u0915\u0940 \u0926\u0930 \u0939\u094b\u0917\u093e \u0936\u093e\u092e\u093f\u0932 \u0915\u0930 \u0938\u0915\u0924\u0947 \u0939\u0948\u0902 **. \u0905\u0917\u0930 \u0935\u0939\u093e\u0901 ** ** \u0906\u0907\u091f\u092e \u0939\u0948 \u0915\u093f \u0905\u0932\u0917 \u0926\u0930\u094b\u0902 \u0915\u0930 \u0930\u0939\u0947 \u0939\u0948\u0902, \u0935\u0947 \u0906\u0907\u091f\u092e ** \u092e\u0947\u0902 \u0906\u0907\u091f\u092e ** \u0924\u093e\u0932\u093f\u0915\u093e ** \u091f\u0948\u0915\u094d\u0938 \u092e\u0947\u0902 \u091c\u094b\u0921\u093c\u093e \u091c\u093e\u0928\u093e \u091a\u093e\u0939\u093f\u090f Columns1 \u0915\u093e \u0935\u093f\u0935\u0930\u0923 ** \u092e\u093e\u0938\u094d\u091f\u0930. # # # #. \u0917\u0923\u0928\u093e \u0915\u0947 \u092a\u094d\u0930\u0915\u093e\u0930: - \u092f\u0939 ** \u0928\u0947\u091f \u0915\u0941\u0932 \u092a\u0930 \u0939\u094b \u0938\u0915\u0924\u093e \u0939\u0948 (\u0915\u093f \u092e\u0942\u0932 \u0930\u093e\u0936\u093f \u0915\u093e \u092f\u094b\u0917 \u0939\u0948). - ** / \u092a\u093f\u091b\u0932\u093e \u092a\u0902\u0915\u094d\u0924\u093f \u092a\u0930 \u0915\u0941\u0932 ** \u0930\u093e\u0936\u093f (\u0938\u0902\u091a\u092f\u0940 \u0915\u0930\u094b\u0902 \u092f\u093e \u0936\u0941\u0932\u094d\u0915\u094b\u0902 \u0915\u0947 \u0932\u093f\u090f). \u092f\u0926\u093f \u0906\u092a \u0907\u0938 \u0935\u093f\u0915\u0932\u094d\u092a \u0915\u093e \u091a\u092f\u0928 \u0915\u0930\u0924\u0947 \u0939\u0948\u0902, \u0915\u0930 \u092a\u093f\u091b\u0932\u0947 \u092a\u0902\u0915\u094d\u0924\u093f \u0915\u0947 \u090f\u0915 \u092a\u094d\u0930\u0924\u093f\u0936\u0924 (\u0915\u0930 \u0924\u093e\u0932\u093f\u0915\u093e \u092e\u0947\u0902) \u092f\u093e \u0915\u0941\u0932 \u0930\u093e\u0936\u093f \u0915\u0947 \u0930\u0942\u092a \u092e\u0947\u0902 \u0932\u093e\u0917\u0942 \u0915\u093f\u092f\u093e \u091c\u093e\u090f\u0917\u093e. - ** \u0938\u092e\u093e\u091a\u093e (\u0915\u0947 \u0930\u0942\u092a \u092e\u0947\u0902 \u0909\u0932\u094d\u0932\u0947\u0916 \u0915\u093f\u092f\u093e \u0939\u0948) ** .2. \u0916\u093e\u0924\u093e \u0938\u093f\u0930: \u0916\u093e\u0924\u093e \u092c\u0939\u0940 \u0916\u093e\u0924\u093e \u0939\u0948 \u091c\u093f\u0938\u0915\u0947 \u0924\u0939\u0924 \u092f\u0939 \u0915\u0930 booked3 \u0939\u094b\u0917\u093e. \u0932\u093e\u0917\u0924 \u0915\u0947\u0902\u0926\u094d\u0930: \u092f\u0926\u093f \u0915\u0930 \u092a\u094d\u0930\u092d\u093e\u0930\u0940 / \u090f\u0915 \u0936\u093f\u092a\u093f\u0902\u0917 \u091c\u0948\u0938\u0947 \u0906\u092f \u092f\u093e \u0916\u0930\u094d\u091a \u0939\u0948 \u092f\u0939 \u090f\u0915 Center.4 \u0932\u093e\u0917\u0924 \u0915\u0947 \u0916\u093f\u0932\u093e\u092b \u0906\u0930\u0915\u094d\u0937\u0923 \u0915\u0940 \u091c\u0930\u0942\u0930\u0924 \u0939\u0948. \u0935\u093f\u0935\u0930\u0923: \u0915\u0930 \u0915\u093e \u0935\u093f\u0935\u0930\u0923 (\u0915\u093f \u091a\u093e\u0932\u093e\u0928 / \u0909\u0926\u094d\u0927\u0930\u0923 \u092e\u0947\u0902 \u092e\u0941\u0926\u094d\u0930\u093f\u0924 \u0915\u093f\u092f\u093e \u091c\u093e\u090f\u0917\u093e) 0.5. \u0926\u0930: rate.6 \u0915\u0930. \u0930\u093e\u0936\u093f: amount.7 \u0915\u0930. \u0915\u0941\u0932: point.8 \u0907\u0938 \u0938\u0902\u091a\u092f\u0940 \u0915\u0941\u0932. \u092a\u0902\u0915\u094d\u0924\u093f \u0926\u0930\u094d\u091c \u0915\u0930\u0947\u0902: \u092f\u0926\u093f "\u092a\u093f\u091b\u0932\u0940 \u092a\u0902\u0915\u094d\u0924\u093f \u0915\u0941\u0932" \u0915\u0947 \u0906\u0927\u093e\u0930 \u092a\u0930 \u0906\u092a \u092a\u0902\u0915\u094d\u0924\u093f \u0938\u0902\u0916\u094d\u092f\u093e \u0939\u0948 \u091c\u094b \u0907\u0938 \u0917\u0923\u0928\u093e (\u092a\u093f\u091b\u0932\u0940 \u092a\u0902\u0915\u094d\u0924\u093f \u092e\u0942\u0932\u092d\u0942\u0924 \u0939\u0948) .9 \u0915\u0947 \u0932\u093f\u090f \u090f\u0915 \u0906\u0927\u093e\u0930 \u0915\u0947 \u0930\u0942\u092a \u092e\u0947\u0902 \u0932\u0947 \u091c\u093e\u092f\u093e \u091c\u093e\u090f\u0917\u093e \u0915\u093e \u091a\u092f\u0928 \u0915\u0930 \u0938\u0915\u0924\u0947 \u0939\u0948\u0902. \u0907\u0938 \u091f\u0948\u0915\u094d\u0938 \u092e\u0942\u0932 \u0926\u0930 \u092e\u0947\u0902 \u0936\u093e\u092e\u093f\u0932: \u092f\u0926\u093f \u0906\u092a \u0907\u0938 \u091a\u0947\u0915, \u0907\u0938\u0915\u093e \u092e\u0924\u0932\u092c \u0939\u0948 \u0915\u093f \u0907\u0938 \u0915\u0930 \u0906\u0907\u091f\u092e \u092e\u0947\u091c \u0915\u0947 \u0928\u0940\u091a\u0947 \u0928\u0939\u0940\u0902 \u0926\u093f\u0916\u093e\u092f\u093e \u091c\u093e\u090f\u0917\u093e, \u0932\u0947\u0915\u093f\u0928 \u0905\u092a\u0928\u0947 \u092e\u0941\u0916\u094d\u092f \u0906\u0907\u091f\u092e \u0924\u093e\u0932\u093f\u0915\u093e \u092e\u0947\u0902 \u092e\u0942\u0932 \u0926\u0930 \u092e\u0947\u0902 \u0936\u093e\u092e\u093f\u0932 \u0915\u093f\u092f\u093e \u091c\u093e\u090f\u0917\u093e. \u092f\u0939 \u0909\u092a\u092f\u094b\u0917\u0940 \u0939\u0948, \u091c\u0939\u093e\u0902 \u0906\u092a \u090f\u0915 \u092b\u094d\u0932\u0948\u091f \u0915\u0940 \u0915\u0940\u092e\u0924 \u0926\u0947 (\u0938\u092d\u0940 \u0915\u0930\u094b\u0902 \u0938\u0939\u093f\u0924) \u0917\u094d\u0930\u093e\u0939\u0915\u094b\u0902 \u0915\u0947 \u0932\u093f\u090f \u0915\u0940\u092e\u0924 \u091a\u093e\u0939\u0924\u0947 \u0939\u0948\u0902.", - "Track separate Income and Expense for product verticals or divisions.": "\u0905\u0932\u0917 \u0914\u0930 \u0909\u0924\u094d\u092a\u093e\u0926 \u0915\u093e\u0930\u094d\u092f\u0915\u094d\u0937\u0947\u0924\u094d\u0930 \u092f\u093e \u0935\u093f\u092d\u093e\u091c\u0928 \u0915\u0947 \u0932\u093f\u090f \u0906\u092f \u0914\u0930 \u0916\u0930\u094d\u091a \u0939\u0941\u090f.", - "Trial Balance": "\u0936\u0947\u0937 - \u092a\u0930\u0940\u0915\u094d\u0937\u0923", - "Voucher Import Tool": "\u0935\u093e\u0909\u091a\u0930 \u0906\u092f\u093e\u0924 \u0909\u092a\u0915\u0930\u0923" -} \ No newline at end of file diff --git a/accounts/page/accounts_browser/accounts_browser.txt b/accounts/page/accounts_browser/accounts_browser.txt index 38dc643c39..35a345ba8e 100644 --- a/accounts/page/accounts_browser/accounts_browser.txt +++ b/accounts/page/accounts_browser/accounts_browser.txt @@ -9,7 +9,6 @@ { "name": "__common__", "module": "Accounts", - "show_in_menu": 0, "page_name": "Accounts Browser", "doctype": "Page", "standard": "Yes" diff --git a/accounts/page/financial_statements/financial_statements.txt b/accounts/page/financial_statements/financial_statements.txt index 152aa40540..7796103143 100644 --- a/accounts/page/financial_statements/financial_statements.txt +++ b/accounts/page/financial_statements/financial_statements.txt @@ -9,7 +9,6 @@ { "name": "__common__", "module": "Accounts", - "show_in_menu": 0, "page_name": "Financial Statements", "doctype": "Page", "standard": "Yes" diff --git a/buying/__init__.py b/buying/__init__.py index d9bbbcc487..e69de29bb2 100644 --- a/buying/__init__.py +++ b/buying/__init__.py @@ -1,7 +0,0 @@ -from __future__ import unicode_literals -install_docs = [ - {"doctype":"Role", "role_name":"Purchase Manager", "name":"Purchase Manager"}, - {"doctype":"Role", "role_name":"Purchase User", "name":"Purchase User"}, - {"doctype":"Role", "role_name":"Purchase Master Manager", "name":"Purchase Master Manager"}, - {"doctype":"Role", "role_name":"Supplier", "name":"Supplier"} -] diff --git a/buying/module_def/buying/locale/_messages_doc.json b/buying/module_def/buying/locale/_messages_doc.json deleted file mode 100644 index c606d9da24..0000000000 --- a/buying/module_def/buying/locale/_messages_doc.json +++ /dev/null @@ -1,5 +0,0 @@ -[ - "Supplier of Goods or Services.", - "Buying Home", - "Purchase Analytics" -] \ No newline at end of file diff --git a/buying/module_def/buying/locale/hi-doc.json b/buying/module_def/buying/locale/hi-doc.json deleted file mode 100644 index 3c21e9592b..0000000000 --- a/buying/module_def/buying/locale/hi-doc.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "Buying Home": "\u0918\u0930 \u0916\u0930\u0940\u0926\u0928\u093e", - "Purchase Analytics": "\u0916\u0930\u0940\u0926 \u0935\u093f\u0936\u094d\u0932\u0947\u0937\u093f\u0915\u0940", - "Supplier of Goods or Services.": "\u0938\u093e\u092e\u093e\u0928 \u092f\u093e \u0938\u0947\u0935\u093e\u0913\u0902 \u0915\u0940 \u092a\u094d\u0930\u0926\u093e\u092f\u0915." -} \ No newline at end of file diff --git a/home/module_def/home/locale/_messages_doc.json b/home/module_def/home/locale/_messages_doc.json deleted file mode 100644 index b310f7cca0..0000000000 --- a/home/module_def/home/locale/_messages_doc.json +++ /dev/null @@ -1,9 +0,0 @@ -[ - "Event Updates", - "My Company", - "Desktop", - "Attributions", - "dashboard", - "Activity", - "Latest Updates" -] \ No newline at end of file diff --git a/home/module_def/home/locale/hi-doc.json b/home/module_def/home/locale/hi-doc.json deleted file mode 100644 index 09205d14a4..0000000000 --- a/home/module_def/home/locale/hi-doc.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "Activity": "\u0938\u0915\u094d\u0930\u093f\u092f\u0924\u093e", - "Attributions": "Attributions", - "Desktop": "\u0921\u0947\u0938\u094d\u0915\u091f\u0949\u092a", - "Event Updates": "\u0918\u091f\u0928\u093e \u0905\u0926\u094d\u092f\u0924\u0928", - "Latest Updates": "\u0928\u0935\u0940\u0928\u0924\u092e \u0905\u0926\u094d\u092f\u0924\u0928", - "My Company": "\u092e\u0947\u0930\u0940 \u0915\u0902\u092a\u0928\u0940", - "dashboard": "\u0921\u0948\u0936\u092c\u094b\u0930\u094d\u0921" -} \ No newline at end of file diff --git a/hr/Deduction Type/Income Tax/Income Tax.txt b/hr/Deduction Type/Income Tax/Income Tax.txt deleted file mode 100644 index 182c9b132e..0000000000 --- a/hr/Deduction Type/Income Tax/Income Tax.txt +++ /dev/null @@ -1 +0,0 @@ -[{'modified_by': 'harshada@webnotestech.com', 'name': 'Income Tax', 'parent': None, 'description': 'Income Tax', 'creation': '2010-04-02 10:33:23', 'is_active': 'Yes', 'modified': '2010-04-05 12:53:07', 'module': 'Payroll', 'doctype': 'Deduction Type', 'idx': None, 'parenttype': None, 'deduction_name': 'Income Tax', 'trash_reason': None, 'owner': 'Administrator', 'docstatus': 0, 'parentfield': None}] \ No newline at end of file diff --git a/hr/Deduction Type/Professional Tax/Professional Tax.txt b/hr/Deduction Type/Professional Tax/Professional Tax.txt deleted file mode 100644 index b5e886c9a0..0000000000 --- a/hr/Deduction Type/Professional Tax/Professional Tax.txt +++ /dev/null @@ -1 +0,0 @@ -[{'modified_by': 'harshada@webnotestech.com', 'name': 'Professional Tax', 'parent': None, 'description': 'Professional Tax', 'creation': '2010-04-02 10:34:14', 'is_active': 'Yes', 'modified': '2010-04-05 12:52:59', 'module': 'Payroll', 'doctype': 'Deduction Type', 'idx': None, 'parenttype': None, 'deduction_name': 'Professional Tax', 'trash_reason': None, 'owner': 'Administrator', 'docstatus': 0, 'parentfield': None}] \ No newline at end of file diff --git a/hr/Deduction Type/Provident Fund/Provident Fund.txt b/hr/Deduction Type/Provident Fund/Provident Fund.txt deleted file mode 100644 index 77fd26f8ce..0000000000 --- a/hr/Deduction Type/Provident Fund/Provident Fund.txt +++ /dev/null @@ -1 +0,0 @@ -[{'modified_by': 'harshada@webnotestech.com', 'name': 'Provident Fund', 'parent': None, 'description': 'Provident fund', 'creation': '2010-04-02 10:32:23', 'is_active': 'Yes', 'modified': '2010-04-05 12:52:52', 'module': 'Payroll', 'doctype': 'Deduction Type', 'idx': None, 'parenttype': None, 'deduction_name': 'Provident Fund', 'trash_reason': None, 'owner': 'Administrator', 'docstatus': 0, 'parentfield': None}] \ No newline at end of file diff --git a/hr/Earning Type/Basic/Basic.txt b/hr/Earning Type/Basic/Basic.txt deleted file mode 100644 index e0243f5280..0000000000 --- a/hr/Earning Type/Basic/Basic.txt +++ /dev/null @@ -1 +0,0 @@ -[{'modified_by': 'harshada@webnotestech.com', 'name': 'Basic', 'parent': None, 'description': 'Basic', 'creation': '2010-04-02 10:29:08', 'is_active': 'Yes', 'modified': '2010-04-05 12:52:35', 'earning_name': 'Basic', 'doctype': 'Earning Type', 'taxable': 'Yes', 'idx': None, 'parenttype': None, 'trash_reason': None, 'module': 'Payroll', 'exemption_limit': None, 'owner': 'Administrator', 'docstatus': 0, 'parentfield': None}] \ No newline at end of file diff --git a/hr/Earning Type/House Rent Allowance/House Rent Allowance.txt b/hr/Earning Type/House Rent Allowance/House Rent Allowance.txt deleted file mode 100644 index 760c4d8a09..0000000000 --- a/hr/Earning Type/House Rent Allowance/House Rent Allowance.txt +++ /dev/null @@ -1 +0,0 @@ -[{'modified_by': 'harshada@webnotestech.com', 'name': 'House Rent Allowance', 'parent': None, 'description': 'House Rent Allowance', 'creation': '2010-04-02 10:29:29', 'is_active': 'Yes', 'modified': '2010-04-05 12:33:19', 'earning_name': 'House Rent Allowance', 'doctype': 'Earning Type', 'taxable': 'No', 'idx': None, 'parenttype': None, 'trash_reason': None, 'module': 'Payroll', 'exemption_limit': None, 'owner': 'Administrator', 'docstatus': 0, 'parentfield': None}] \ No newline at end of file diff --git a/hr/Expense Type/Calls/Calls.txt b/hr/Expense Type/Calls/Calls.txt deleted file mode 100644 index 5cf53d6b21..0000000000 --- a/hr/Expense Type/Calls/Calls.txt +++ /dev/null @@ -1 +0,0 @@ -[{'modified_by': 'harshada@webnotestech.com', 'name': 'Calls', 'parent': None, 'description': None, 'creation': '2010-08-23 18:26:38', 'modified': '2010-08-23 18:26:38', 'module': 'Payroll', 'doctype': 'Expense Claim Type', 'idx': None, 'parenttype': None, 'owner': 'harshada@webnotestech.com', 'docstatus': 0, 'expense_type': 'Calls', 'parentfield': None}] \ No newline at end of file diff --git a/hr/Expense Type/Food/Food.txt b/hr/Expense Type/Food/Food.txt deleted file mode 100644 index c09f21f7ee..0000000000 --- a/hr/Expense Type/Food/Food.txt +++ /dev/null @@ -1 +0,0 @@ -[{'modified_by': 'harshada@webnotestech.com', 'name': 'Food', 'parent': None, 'description': None, 'creation': '2010-08-23 18:26:30', 'modified': '2010-08-23 18:26:30', 'module': 'Payroll', 'doctype': 'Expense Claim Type', 'idx': None, 'parenttype': None, 'owner': 'harshada@webnotestech.com', 'docstatus': 0, 'expense_type': 'Food', 'parentfield': None}] \ No newline at end of file diff --git a/hr/Expense Type/Medical/Medical.txt b/hr/Expense Type/Medical/Medical.txt deleted file mode 100644 index 754af611f8..0000000000 --- a/hr/Expense Type/Medical/Medical.txt +++ /dev/null @@ -1 +0,0 @@ -[{'modified_by': 'harshada@webnotestech.com', 'name': 'Medical', 'parent': None, 'description': None, 'creation': '2010-08-23 18:26:49', 'modified': '2010-08-23 18:26:49', 'module': 'Payroll', 'doctype': 'Expense Claim Type', 'idx': None, 'parenttype': None, 'owner': 'harshada@webnotestech.com', 'docstatus': 0, 'expense_type': 'Medical', 'parentfield': None}] \ No newline at end of file diff --git a/hr/Expense Type/Others/Others.txt b/hr/Expense Type/Others/Others.txt deleted file mode 100644 index 509d6528cf..0000000000 --- a/hr/Expense Type/Others/Others.txt +++ /dev/null @@ -1 +0,0 @@ -[{'modified_by': 'harshada@webnotestech.com', 'name': 'Others', 'parent': None, 'description': None, 'creation': '2010-09-20 12:16:45', 'modified': '2010-09-20 12:16:45', 'module': 'Payroll', 'doctype': 'Expense Claim Type', 'idx': None, 'parenttype': None, 'owner': 'harshada@webnotestech.com', 'docstatus': 0, 'expense_type': 'Others', 'parentfield': None}] \ No newline at end of file diff --git a/hr/Expense Type/Travel/Travel.txt b/hr/Expense Type/Travel/Travel.txt deleted file mode 100644 index c21e4b63fb..0000000000 --- a/hr/Expense Type/Travel/Travel.txt +++ /dev/null @@ -1 +0,0 @@ -[{'modified_by': 'harshada@webnotestech.com', 'name': 'Travel', 'parent': None, 'description': None, 'creation': '2010-09-20 12:16:45', 'modified': '2010-09-20 12:16:45', 'module': 'Payroll', 'doctype': 'Expense Claim Type', 'idx': None, 'parenttype': None, 'owner': 'harshada@webnotestech.com', 'docstatus': 0, 'expense_type': 'Travel', 'parentfield': None}] \ No newline at end of file diff --git a/hr/Leave Type/Casual Leave/Casual Leave.txt b/hr/Leave Type/Casual Leave/Casual Leave.txt deleted file mode 100644 index fbd55a5dcc..0000000000 --- a/hr/Leave Type/Casual Leave/Casual Leave.txt +++ /dev/null @@ -1 +0,0 @@ -[{'leave_type_name': 'Casual Leave', 'modified_by': 'Administrator', 'name': 'Casual Leave', 'parent': None, 'is_encash': 1, 'creation': '2010-04-02 10:52:32', 'is_active': 'Yes', 'modified': '2010-04-02 10:52:32', 'is_carry_forward': 1, 'doctype': 'Leave Type', 'max_days_allowed': '3', 'idx': None, 'parenttype': None, 'trash_reason': None, 'module': 'Payroll', 'owner': 'Administrator', 'docstatus': 0, 'parentfield': None}] \ No newline at end of file diff --git a/hr/Leave Type/Compensatory Off/Compensatory Off.txt b/hr/Leave Type/Compensatory Off/Compensatory Off.txt deleted file mode 100644 index 896b3e2f21..0000000000 --- a/hr/Leave Type/Compensatory Off/Compensatory Off.txt +++ /dev/null @@ -1 +0,0 @@ -[{'leave_type_name': 'Compensatory Off', 'modified_by': 'Administrator', 'name': 'Compensatory Off', 'parent': None, 'is_encash': None, 'creation': '2010-04-02 10:59:30', 'is_active': 'Yes', 'modified': '2010-04-02 10:59:30', 'is_carry_forward': None, 'doctype': 'Leave Type', 'max_days_allowed': None, 'idx': None, 'parenttype': None, 'trash_reason': None, 'module': 'Payroll', 'owner': 'Administrator', 'docstatus': 0, 'parentfield': None}] \ No newline at end of file diff --git a/hr/Leave Type/Leave Without Pay/Leave Without Pay.txt b/hr/Leave Type/Leave Without Pay/Leave Without Pay.txt deleted file mode 100644 index 04fa7077a0..0000000000 --- a/hr/Leave Type/Leave Without Pay/Leave Without Pay.txt +++ /dev/null @@ -1 +0,0 @@ -[{'leave_type_name': 'Leave Without Pay', 'modified_by': 'Administrator', 'name': 'Leave Without Pay', 'parent': None, 'is_encash': None, 'creation': '2010-04-02 10:57:37', 'is_active': 'Yes', 'modified': '2010-04-02 10:57:37', 'is_carry_forward': None, 'doctype': 'Leave Type', 'max_days_allowed': None, 'idx': None, 'parenttype': None, 'trash_reason': None, 'module': 'Payroll', 'owner': 'Administrator', 'docstatus': 0, 'parentfield': None}] \ No newline at end of file diff --git a/hr/Leave Type/Privilege Leave/Privilege Leave.txt b/hr/Leave Type/Privilege Leave/Privilege Leave.txt deleted file mode 100644 index 7024c50181..0000000000 --- a/hr/Leave Type/Privilege Leave/Privilege Leave.txt +++ /dev/null @@ -1 +0,0 @@ -[{'leave_type_name': 'Privilege Leave', 'modified_by': 'Administrator', 'name': 'Privilege Leave', 'parent': None, 'is_encash': 1, 'creation': '2010-04-02 10:53:16', 'is_active': 'Yes', 'modified': '2010-04-02 10:53:16', 'is_carry_forward': None, 'doctype': 'Leave Type', 'max_days_allowed': None, 'idx': None, 'parenttype': None, 'trash_reason': None, 'module': 'Payroll', 'owner': 'Administrator', 'docstatus': 0, 'parentfield': None}] \ No newline at end of file diff --git a/hr/Leave Type/Sick Leave/Sick Leave.txt b/hr/Leave Type/Sick Leave/Sick Leave.txt deleted file mode 100644 index 2ccb3bac6f..0000000000 --- a/hr/Leave Type/Sick Leave/Sick Leave.txt +++ /dev/null @@ -1 +0,0 @@ -[{'leave_type_name': 'Sick Leave', 'modified_by': 'Administrator', 'name': 'Sick Leave', 'parent': None, 'is_encash': None, 'creation': '2010-04-02 10:54:12', 'is_active': 'Yes', 'modified': '2010-04-02 10:54:12', 'is_carry_forward': None, 'doctype': 'Leave Type', 'max_days_allowed': None, 'idx': None, 'parenttype': None, 'trash_reason': None, 'module': 'Payroll', 'owner': 'Administrator', 'docstatus': 0, 'parentfield': None}] \ No newline at end of file diff --git a/hr/__init__.py b/hr/__init__.py index 429c71955b..e69de29bb2 100644 --- a/hr/__init__.py +++ b/hr/__init__.py @@ -1,8 +0,0 @@ -from __future__ import unicode_literals -install_docs = [ - {"doctype":"Role", "role_name":"Employee", "name":"Employee"}, - {"doctype":"Role", "role_name":"HR Manager", "name":"HR Manager"}, - {"doctype":"Role", "role_name":"HR User", "name":"HR User"}, - {"doctype":"Role", "role_name":"Leave Approver", "name":"Leave Approver"}, - {"doctype":"Role", "role_name":"Expense Approver", "name":"Expense Approver"}, -] diff --git a/hr/module_def/hr/locale/_messages_doc.json b/hr/module_def/hr/locale/_messages_doc.json deleted file mode 100644 index 4b57a153b7..0000000000 --- a/hr/module_def/hr/locale/_messages_doc.json +++ /dev/null @@ -1,4 +0,0 @@ -[ - "Apply / Approve Leaves", - "Human Resources Home" -] \ No newline at end of file diff --git a/hr/module_def/hr/locale/hi-doc.json b/hr/module_def/hr/locale/hi-doc.json deleted file mode 100644 index 4465c6e04f..0000000000 --- a/hr/module_def/hr/locale/hi-doc.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "Apply / Approve Leaves": "\u092a\u0924\u094d\u0924\u093f\u092f\u093e\u0902 \u0932\u093e\u0917\u0942 / \u0938\u094d\u0935\u0940\u0915\u0943\u0924", - "Human Resources Home": "\u092e\u093e\u0928\u0935 \u0939\u094b\u092e \u0938\u0902\u0938\u093e\u0927\u0928" -} \ No newline at end of file diff --git a/manufacturing/__init__.py b/manufacturing/__init__.py index 07594ad89c..e69de29bb2 100644 --- a/manufacturing/__init__.py +++ b/manufacturing/__init__.py @@ -1,5 +0,0 @@ -from __future__ import unicode_literals -install_docs = [ - {"doctype":"Role", "role_name":"Manufacturing Manager", "name":"Manufacturing Manager"}, - {"doctype":"Role", "role_name":"Manufacturing User", "name":"Manufacturing User"}, -] diff --git a/manufacturing/module_def/manufacturing/locale/_messages_doc.json b/manufacturing/module_def/manufacturing/locale/_messages_doc.json deleted file mode 100644 index f4be93eba5..0000000000 --- a/manufacturing/module_def/manufacturing/locale/_messages_doc.json +++ /dev/null @@ -1,3 +0,0 @@ -[ - "Manufacturing Home" -] \ No newline at end of file diff --git a/manufacturing/module_def/manufacturing/locale/hi-doc.json b/manufacturing/module_def/manufacturing/locale/hi-doc.json deleted file mode 100644 index 9e128ec0f5..0000000000 --- a/manufacturing/module_def/manufacturing/locale/hi-doc.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "Manufacturing Home": "\u0935\u093f\u0928\u093f\u0930\u094d\u092e\u093e\u0923 \u0939\u094b\u092e" -} \ No newline at end of file diff --git a/projects/__init__.py b/projects/__init__.py index 8f35855de8..e69de29bb2 100644 --- a/projects/__init__.py +++ b/projects/__init__.py @@ -1,4 +0,0 @@ -from __future__ import unicode_literals -install_docs = [ - {"doctype":"Role", "role_name":"Projects User", "name":"Projects User"}, -] diff --git a/projects/module_def/projects/locale/_messages_doc.json b/projects/module_def/projects/locale/_messages_doc.json deleted file mode 100644 index da33435bc9..0000000000 --- a/projects/module_def/projects/locale/_messages_doc.json +++ /dev/null @@ -1,4 +0,0 @@ -[ - "Projects Home", - "Projects" -] \ No newline at end of file diff --git a/projects/module_def/projects/locale/hi-doc.json b/projects/module_def/projects/locale/hi-doc.json deleted file mode 100644 index 6ec7020c39..0000000000 --- a/projects/module_def/projects/locale/hi-doc.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "Projects": "\u092a\u0930\u093f\u092f\u094b\u091c\u0928\u093e\u0913\u0902", - "Projects Home": "\u092a\u0930\u093f\u092f\u094b\u091c\u0928\u093e\u0913\u0902 \u0918\u0930" -} \ No newline at end of file diff --git a/selling/__init__.py b/selling/__init__.py index beb4975e62..e69de29bb2 100644 --- a/selling/__init__.py +++ b/selling/__init__.py @@ -1,8 +0,0 @@ -from __future__ import unicode_literals -install_docs = [ - {"doctype":"Role", "role_name":"Customer", "name":"Customer"}, - {"doctype":"Role", "role_name":"Partner", "name":"Partner"}, - {"doctype":"Role", "role_name":"Sales Manager", "name":"Sales Manager"}, - {"doctype":"Role", "role_name":"Sales Master Manager", "name":"Sales Master Manager"}, - {"doctype":"Role", "role_name":"Sales User", "name":"Sales User"}, -] diff --git a/selling/module_def/selling/locale/_messages_doc.json b/selling/module_def/selling/locale/_messages_doc.json deleted file mode 100644 index 59d6c9815c..0000000000 --- a/selling/module_def/selling/locale/_messages_doc.json +++ /dev/null @@ -1,11 +0,0 @@ -[ - "Sales Orders Pending To Be Delivered", - "Customer Addresses And Contacts", - "Buyer of Goods and Services.", - "Sales Dashboard", - "Potential Sales Deal", - "Selling Home", - "Sales Analytics", - "Keep Track of Sales Campaigns. Keep track of Leads, Quotations, Sales Order etc from Campaigns to gauge Return on Investment. ", - "Sales Browser" -] \ No newline at end of file diff --git a/selling/module_def/selling/locale/hi-doc.json b/selling/module_def/selling/locale/hi-doc.json deleted file mode 100644 index 785f4df60d..0000000000 --- a/selling/module_def/selling/locale/hi-doc.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "Buyer of Goods and Services.": "\u0938\u093e\u092e\u093e\u0928 \u0914\u0930 \u0938\u0947\u0935\u093e\u0913\u0902 \u0915\u0947 \u0916\u0930\u0940\u0926\u093e\u0930.", - "Customer Addresses And Contacts": "\u0917\u094d\u0930\u093e\u0939\u0915 \u0915\u0947 \u092a\u0924\u0947 \u0914\u0930 \u0938\u0902\u092a\u0930\u094d\u0915", - "Keep Track of Sales Campaigns. Keep track of Leads, Quotations, Sales Order etc from Campaigns to gauge Return on Investment. ": "\u092c\u093f\u0915\u094d\u0930\u0940 \u0905\u092d\u093f\u092f\u093e\u0928 \u0915\u093e \u091f\u094d\u0930\u0948\u0915 \u0930\u0916\u0947\u0902. \u092c\u093f\u0915\u094d\u0930\u0940\u0938\u0942\u0924\u094d\u0930, \u0915\u094b\u091f\u0947\u0936\u0928, \u0905\u092d\u093f\u092f\u093e\u0928 \u0938\u0947 \u092c\u093f\u0915\u094d\u0930\u0940 \u0906\u0926\u0947\u0936 \u0906\u0926\u093f \u0915\u0930\u0928\u0947 \u0915\u0947 \u0932\u093f\u090f \u0928\u093f\u0935\u0947\u0936 \u092a\u0930 \u0935\u093e\u092a\u0938\u0940 \u0917\u0947\u091c \u091f\u094d\u0930\u0948\u0915 \u0930\u0916\u0947\u0902.", - "Potential Sales Deal": "\u0938\u0902\u092d\u093e\u0935\u093f\u0924 \u092c\u093f\u0915\u094d\u0930\u0940 \u0938\u094c\u0926\u093e", - "Sales Analytics": "\u092c\u093f\u0915\u094d\u0930\u0940 \u0935\u093f\u0936\u094d\u0932\u0947\u0937\u093f\u0915\u0940", - "Sales Browser": "\u092c\u093f\u0915\u094d\u0930\u0940 \u092c\u094d\u0930\u093e\u0909\u091c\u093c\u0930", - "Sales Dashboard": "\u092c\u093f\u0915\u094d\u0930\u0940 \u0921\u0948\u0936\u092c\u094b\u0930\u094d\u0921", - "Sales Orders Pending To Be Delivered": "\u0935\u093f\u0915\u094d\u0930\u092f \u0906\u0926\u0947\u0936 \u0926\u093f\u092f\u093e \u091c\u093e \u0932\u0902\u092c\u093f\u0924", - "Selling Home": "\u0918\u0930 \u092c\u0947\u091a\u0928\u093e" -} \ No newline at end of file diff --git a/selling/page/sales_browser/sales_browser.txt b/selling/page/sales_browser/sales_browser.txt index eb212d4163..4b9eecf3cd 100644 --- a/selling/page/sales_browser/sales_browser.txt +++ b/selling/page/sales_browser/sales_browser.txt @@ -9,7 +9,6 @@ { "name": "__common__", "module": "Selling", - "show_in_menu": 0, "page_name": "Sales Browser", "doctype": "Page", "standard": "Yes" diff --git a/setup/__init__.py b/setup/__init__.py index 749205251f..e69de29bb2 100644 --- a/setup/__init__.py +++ b/setup/__init__.py @@ -1,5 +0,0 @@ -from __future__ import unicode_literals -install_docs = [ - {'doctype':'Role', 'role_name': 'System Manager', 'name': 'System Manager'}, - {'doctype':'Role', 'role_name': 'Analytics', 'name': 'Analytics'} -] diff --git a/setup/module_def/setup/locale/_messages_doc.json b/setup/module_def/setup/locale/_messages_doc.json deleted file mode 100644 index d08bf11f63..0000000000 --- a/setup/module_def/setup/locale/_messages_doc.json +++ /dev/null @@ -1,18 +0,0 @@ -[ - "Item Classification", - "Webforms", - "Modules Setup", - "Email Settings for Outgoing and Incoming Emails.", - "Standard Terms and Conditions that can be added to Sales and Purchases.Examples:1. Validity of the offer.1. Payment Terms (In Advance, On Credit, part advance etc).1. What is extra (or payable by the Customer).1. Safety / usage warning.1. Warranty if any.1. Returns Policy.1. Terms of shipping, if applicable.1. Ways of addressing disputes, indemnity, liability, etc.1. Address and Contact of your Company.", - "Price List Master", - "**Currency** Master", - "Send automatic emails to Contacts on Submitting transactions.", - "Setup", - "Send regular summary reports via Email.", - "A third party distributor / dealer / commission agent / affiliate / reseller who sells the companies products for a commission.", - "Classification of Customers by region", - "Set prefix for numbering series on your transactions", - "All Sales Transactions can be tagged against multiple **Sales Persons** so that you can set and monitor targets.", - "Permission Engine", - "Legal Entity / Subsidiary with a separate Chart of Accounts belonging to the Organization." -] \ No newline at end of file diff --git a/setup/module_def/setup/locale/hi-doc.json b/setup/module_def/setup/locale/hi-doc.json deleted file mode 100644 index 69e8616a21..0000000000 --- a/setup/module_def/setup/locale/hi-doc.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "**Currency** Master": "** \u092e\u0941\u0926\u094d\u0930\u093e ** \u092e\u093e\u0938\u094d\u091f\u0930", - "A third party distributor / dealer / commission agent / affiliate / reseller who sells the companies products for a commission.": "\u090f\u0915 \u0924\u0940\u0938\u0930\u0947 \u092a\u0915\u094d\u0937 \u0915\u0947 \u0935\u093f\u0924\u0930\u0915 / \u0921\u0940\u0932\u0930 / \u0915\u092e\u0940\u0936\u0928 \u090f\u091c\u0947\u0902\u091f / \u0938\u0939\u092c\u0926\u094d\u0927 / \u092a\u0941\u0928\u0930\u094d\u0935\u093f\u0915\u094d\u0930\u0947\u0924\u093e \u091c\u094b \u090f\u0915 \u0906\u092f\u094b\u0917 \u0915\u0947 \u0932\u093f\u090f \u0915\u0902\u092a\u0928\u093f\u092f\u094b\u0902 \u0915\u0947 \u0909\u0924\u094d\u092a\u093e\u0926\u094b\u0902 \u0915\u094b \u092c\u0947\u091a\u0924\u093e \u0939\u0948.", - "All Sales Transactions can be tagged against multiple **Sales Persons** so that you can set and monitor targets.": "\u0938\u092d\u0940 \u092c\u093f\u0915\u094d\u0930\u0940 \u0932\u0947\u0928\u0926\u0947\u0928 \u0915\u0908 ** \u092c\u093f\u0915\u094d\u0930\u0940 \u0935\u094d\u092f\u0915\u094d\u0924\u093f\u092f\u094b\u0902 ** \u0907\u0924\u0928\u0940 \u0939\u0948 \u0915\u093f \u0906\u092a \u0938\u0947\u091f \u0914\u0930 \u0932\u0915\u094d\u0937\u094d\u092f\u094b\u0902 \u0915\u0940 \u0928\u093f\u0917\u0930\u093e\u0928\u0940 \u0915\u0930 \u0938\u0915\u0924\u0947 \u0939\u0948\u0902 \u0915\u0947 \u0916\u093f\u0932\u093e\u092b \u091a\u093f\u0939\u094d\u0928\u093f\u0924 \u0915\u093f\u092f\u093e \u091c\u093e \u0938\u0915\u0924\u093e \u0939\u0948.", - "Classification of Customers by region": "\u0917\u094d\u0930\u093e\u0939\u0915 \u0915\u0947 \u0915\u094d\u0937\u0947\u0924\u094d\u0930 \u0926\u094d\u0935\u093e\u0930\u093e \u0935\u0930\u094d\u0917\u0940\u0915\u0930\u0923", - "Email Settings for Outgoing and Incoming Emails.": "\u0928\u093f\u0935\u0930\u094d\u0924\u092e\u093e\u0928 \u0914\u0930 \u0906\u0928\u0947 \u0935\u093e\u0932\u0940 \u0908\u092e\u0947\u0932 \u0915\u0947 \u0932\u093f\u090f \u0908\u092e\u0947\u0932 \u0938\u0947\u091f\u093f\u0902\u0917\u094d\u0938.", - "Item Classification": "\u0906\u0907\u091f\u092e \u0935\u0930\u094d\u0917\u0940\u0915\u0930\u0923", - "Legal Entity / Subsidiary with a separate Chart of Accounts belonging to the Organization.": "\u0915\u093e\u0928\u0942\u0928\u0940 \u0938\u0902\u0917\u0920\u0928 \u0938\u0947 \u0938\u0902\u092c\u0902\u0927\u093f\u0924 \u0916\u093e\u0924\u094b\u0902 \u0915\u0940 \u090f\u0915 \u0905\u0932\u0917 \u091a\u093e\u0930\u094d\u091f \u0915\u0947 \u0938\u093e\u0925 \u0907\u0915\u093e\u0908 / \u0938\u0939\u093e\u092f\u0915.", - "Modules Setup": "\u092e\u0949\u0921\u094d\u092f\u0942\u0932 \u0938\u0947\u091f\u0905\u092a", - "Permission Engine": "\u0905\u0928\u0941\u092e\u0924\u093f \u0907\u0902\u091c\u0928", - "Price List Master": "\u092e\u0942\u0932\u094d\u092f \u0938\u0942\u091a\u0940 \u092e\u093e\u0938\u094d\u091f\u0930", - "Send automatic emails to Contacts on Submitting transactions.": "\u0932\u0947\u0928\u0926\u0947\u0928 \u092d\u0947\u091c\u0928\u0947 \u092a\u0930 \u0938\u0902\u092a\u0930\u094d\u0915 \u0915\u0930\u0928\u0947 \u0915\u0947 \u0932\u093f\u090f \u0938\u094d\u0935\u0924: \u0908\u092e\u0947\u0932 \u092d\u0947\u091c\u0947\u0902.", - "Send regular summary reports via Email.": "\u0908\u092e\u0947\u0932 \u0915\u0947 \u092e\u093e\u0927\u094d\u092f\u092e \u0938\u0947 \u0928\u093f\u092f\u092e\u093f\u0924 \u0930\u0942\u092a \u0938\u0947 \u0938\u093e\u0930\u093e\u0902\u0936 \u0930\u093f\u092a\u094b\u0930\u094d\u091f \u092d\u0947\u091c\u0947\u0902.", - "Set prefix for numbering series on your transactions": "\u0905\u092a\u0928\u0947 \u0932\u0947\u0928\u0926\u0947\u0928 \u092a\u0930 \u0936\u094d\u0930\u0943\u0902\u0916\u0932\u093e \u0928\u0902\u092c\u0930\u093f\u0902\u0917 \u0915\u0947 \u0932\u093f\u090f \u0909\u092a\u0938\u0930\u094d\u0917 \u0938\u0947\u091f", - "Setup": "\u0935\u094d\u092f\u0935\u0938\u094d\u0925\u093e", - "Standard Terms and Conditions that can be added to Sales and Purchases.Examples:1. Validity of the offer.1. Payment Terms (In Advance, On Credit, part advance etc).1. What is extra (or payable by the Customer).1. Safety / usage warning.1. Warranty if any.1. Returns Policy.1. Terms of shipping, if applicable.1. Ways of addressing disputes, indemnity, liability, etc.1. Address and Contact of your Company.": "1: \u092e\u093e\u0928\u0915 \u0928\u093f\u092f\u092e\u094b\u0902 \u0914\u0930 \u0936\u0930\u094d\u0924\u094b\u0902 \u0915\u093f \u092c\u093f\u0915\u094d\u0930\u0940 \u0914\u0930 Purchases.Examples \u0915\u0947 \u0932\u093f\u090f \u091c\u094b\u0921\u093c\u093e \u091c\u093e \u0938\u0915\u0924\u093e \u0939\u0948. Offer.1 \u0915\u0940 \u0935\u0948\u0927\u0924\u093e. \u092d\u0941\u0917\u0924\u093e\u0928 (\u090f\u0921\u0935\u093e\u0902\u0938 \u092e\u0947\u0902, \u0915\u094d\u0930\u0947\u0921\u093f\u091f, \u092d\u093e\u0917 \u0905\u0917\u094d\u0930\u093f\u092e \u0906\u0926\u093f) \u0936\u0930\u094d\u0924\u0947\u0902 .1. \u0915\u094d\u092f\u093e (\u092f\u093e \u0917\u094d\u0930\u093e\u0939\u0915 \u0926\u094d\u0935\u093e\u0930\u093e \u0926\u0947\u092f) \u0905\u0924\u093f\u0930\u093f\u0915\u094d\u0924 .1 \u0939\u0948. / \u0938\u0941\u0930\u0915\u094d\u0937\u093e warning.1 \u0909\u092a\u092f\u094b\u0917. \u0935\u093e\u0930\u0902\u091f\u0940 \u0905\u0917\u0930 any.1. Policy.1 \u0926\u0947\u0924\u093e \u0939\u0948. \u0936\u093f\u092a\u093f\u0902\u0917 \u0915\u0947 applicable.1 \u0905\u0917\u0930 \u0936\u0930\u094d\u0924\u0947\u0902. \u0935\u093f\u0935\u093e\u0926\u094b\u0902 \u0915\u094b \u0938\u0902\u092c\u094b\u0927\u093f\u0924 \u0915\u0930\u0928\u0947 \u0915\u0947 \u0924\u0930\u0940\u0915\u0947, \u0915\u094d\u0937\u0924\u093f\u092a\u0942\u0930\u094d\u0924\u093f, \u0926\u093e\u092f\u093f\u0924\u094d\u0935, etc.1. \u092a\u0924\u093e \u0939\u0948 \u0914\u0930 \u0905\u092a\u0928\u0940 \u0915\u0902\u092a\u0928\u0940 \u0915\u0947 \u0938\u0902\u092a\u0930\u094d\u0915 \u0915\u0930\u0947\u0902.", - "Webforms": "WebForms" -} \ No newline at end of file diff --git a/startup/install.py b/startup/install.py new file mode 100644 index 0000000000..b25f524745 --- /dev/null +++ b/startup/install.py @@ -0,0 +1,638 @@ +from __future__ import unicode_literals + +import webnotes + +def pre_import(): + make_modules() + make_roles() + webnotes.reload_doc("utilities", "doctype", "gl_mapper") + webnotes.reload_doc("utilities", "doctype", "gl_mapper_detail") + +def make_modules(): + modules = [ + " Home", + " System", + " Utilities", + " Website", + " Setup", + " Selling", + " Buying", + " Projects", + " Accounts", + " Stock", + " Support", + " HR", + " Manufacturing"] + + for m in modules: + doc = webnotes.doc(fielddata = { + "doctype": "Module Def", + "module_name": m, + "disabled":"No" + }) + doc.insert() + +def make_roles(): + roles = [ + "Accounts Manager", + "Accounts User", + "Analytics", + "Auditor", + "Blogger", + "Customer", + "Employee", + "Expense Approver", + "HR Manager", + "HR User", + "Leave Approver", + "Maintenance Manager", + "Maintenance User", + "Manufacturing Manager", + "Manufacturing User", + "Material Manager", + "Material Master Manager", + "Material User", + "Partner", + "Projects User", + "Purchase Manager", + "Purchase Master Manager", + "Purchase User", + "Quality Manager", + "Sales Manager", + "Sales Master Manager", + "Sales User", + "Supplier", + "Support Manager", + "Support Team", + ] + for r in roles: + doc = webnotes.doc(fielddata = { + "doctype":"Role", + "role_name": r + }) + doc.insert() + +def post_import(): + records = [ + # item group + {'doctype': 'Item Group', 'item_group_name': 'All Item Groups', 'is_group': 'Yes', 'name': 'All Item Groups', 'parent_item_group': ''}, + {'doctype': 'Item Group', 'item_group_name': 'Default', 'is_group': 'No', 'name': 'Default', 'parent_item_group': 'All Item Groups'}, + + # deduction type + {'doctype': 'Deduction Type', 'name': 'Income Tax', 'description': 'Income Tax', 'deduction_name': 'Income Tax'}, + {'doctype': 'Deduction Type', 'name': 'Professional Tax', 'description': 'Professional Tax', 'deduction_name': 'Professional Tax'}, + {'doctype': 'Deduction Type', 'name': 'Provident Fund', 'description': 'Provident fund', 'deduction_name': 'Provident Fund'}, + + # earning type + {'doctype': 'Earning Type', 'name': 'Basic', 'description': 'Basic', 'earning_name': 'Basic', 'taxable': 'Yes'}, + {'doctype': 'Earning Type', 'name': 'House Rent Allowance', 'description': 'House Rent Allowance', 'earning_name': 'House Rent Allowance', 'taxable': 'No'}, + + # expense claim type + {'doctype': 'Expense Claim Type', 'name': 'Calls', 'expense_type': 'Calls'}, + {'doctype': 'Expense Claim Type', 'name': 'Food', 'expense_type': 'Food'}, + {'doctype': 'Expense Claim Type', 'name': 'Medical', 'expense_type': 'Medical'}, + {'doctype': 'Expense Claim Type', 'name': 'Others', 'expense_type': 'Others'}, + {'doctype': 'Expense Claim Type', 'name': 'Travel', 'expense_type': 'Travel'}, + + # leave type + {'doctype': 'Leave Type', 'leave_type_name': 'Casual Leave', 'name': 'Casual Leave', 'is_encash': 1, 'is_carry_forward': 1, 'max_days_allowed': '3', }, + {'doctype': 'Leave Type', 'leave_type_name': 'Compensatory Off', 'name': 'Compensatory Off', 'is_encash': 0, 'is_carry_forward': 0, }, + {'doctype': 'Leave Type', 'leave_type_name': 'Sick Leave', 'name': 'Sick Leave', 'is_encash': 0, 'is_carry_forward': 0, }, + {'doctype': 'Leave Type', 'leave_type_name': 'Privilege Leave', 'name': 'Privilege Leave', 'is_encash': 0, 'is_carry_forward': 0, }, + {'doctype': 'Leave Type', 'leave_type_name': 'Leave Without Pay', 'name': 'Leave Without Pay', 'is_encash': 0, 'is_carry_forward': 0, 'is_lwp':1}, + + # territory + {'doctype': 'Territory', 'territory_name': 'All Territories', 'is_group': 'Yes', 'name': 'All Territories', 'parent_territory': ''}, + {'doctype': 'Territory', 'territory_name': 'Default', 'is_group': 'No', 'name': 'Default', 'parent_territory': 'All Territories'}, + + # customer group + {'doctype': 'Customer Group', 'customer_group_name': 'All Customer Groups', 'is_group': 'Yes', 'name': 'All Customer Groups', 'parent_customer_group': ''}, + {'doctype': 'Customer Group', 'customer_group_name': 'Default Customer Group', 'is_group': 'No', 'name': 'Default Customer Group', 'parent_customer_group': 'All Customer Groups'}, + + # supplier type + {'doctype': 'Supplier Type', 'name': 'Default Supplier Type', 'supplier_type': 'Default Supplier Type'}, + + # Price List + {'doctype': 'Price List', 'name': 'Default Price List', 'price_list_name': 'Default Price List'}, + {'doctype': 'Price List', 'name': 'Standard', 'price_list_name': 'Standard'}, + + # warehouse type + {'doctype': 'Warehouse Type', 'name': 'Default Warehouse Type', 'warehouse_type': 'Default Warehouse Type'}, + {'doctype': 'Warehouse Type', 'name': 'Fixed Asset', 'warehouse_type': 'Fixed Asset'}, + {'doctype': 'Warehouse Type', 'name': 'Reserved', 'warehouse_type': 'Reserved'}, + {'doctype': 'Warehouse Type', 'name': 'Rejected', 'warehouse_type': 'Rejected'}, + {'doctype': 'Warehouse Type', 'name': 'Sample', 'warehouse_type': 'Sample'}, + {'doctype': 'Warehouse Type', 'name': 'Stores', 'warehouse_type': 'Stores'}, + {'doctype': 'Warehouse Type', 'name': 'WIP Warehouse', 'warehouse_type': 'WIP Warehouse'}, + + # warehouse + {'doctype': 'Warehouse', 'warehouse_name': 'Default Warehouse', 'name': 'Default Warehouse', 'warehouse_type': 'Default Warehouse Type'}, + + # Workstation + {'doctype': 'Workstation', 'name': 'Default Workstation', 'workstation_name': 'Default Workstation', 'warehouse': 'Default Warehouse'}, + + # Sales Person + {'doctype': 'Sales Person', 'name': 'All Sales Persons', 'sales_person_name': 'All Sales Persons', 'is_group': "Yes", "parent_sales_person": ""}, + + # UOM + {'uom_name': 'Box', 'doctype': 'UOM', 'name': 'Box'}, + {'uom_name': 'Ft', 'doctype': 'UOM', 'name': 'Ft'}, + {'uom_name': 'Kg', 'doctype': 'UOM', 'name': 'Kg'}, + {'uom_name': 'Ltr', 'doctype': 'UOM', 'name': 'Ltr'}, + {'uom_name': 'Meter', 'doctype': 'UOM', 'name': 'Meter'}, + {'uom_name': 'Mtr', 'doctype': 'UOM', 'name': 'Mtr'}, + {'uom_name': 'Nos', 'doctype': 'UOM', 'name': 'Nos'}, + {'uom_name': 'Pair', 'doctype': 'UOM', 'name': 'Pair'}, + {'uom_name': 'Set', 'doctype': 'UOM', 'name': 'Set'}, + {'uom_name': 'T', 'doctype': 'UOM', 'name': 'T'}, + + # Currency + {'currency_name': 'AED', 'doctype': 'Currency', 'name': 'AED'}, + {'currency_name': 'AFN', 'doctype': 'Currency', 'name': 'AFN'}, + {'currency_name': 'ALL', 'doctype': 'Currency', 'name': 'ALL'}, + {'currency_name': 'AMD', 'doctype': 'Currency', 'name': 'AMD'}, + {'currency_name': 'ANG', 'doctype': 'Currency', 'name': 'ANG'}, + {'currency_name': 'AOA', 'doctype': 'Currency', 'name': 'AOA'}, + {'currency_name': 'ARS', 'doctype': 'Currency', 'name': 'ARS'}, + {'currency_name': 'AUD', 'doctype': 'Currency', 'name': 'AUD'}, + {'currency_name': 'AZN', 'doctype': 'Currency', 'name': 'AZN'}, + {'currency_name': 'BAM', 'doctype': 'Currency', 'name': 'BAM'}, + {'currency_name': 'BBD', 'doctype': 'Currency', 'name': 'BBD'}, + {'currency_name': 'BDT', 'doctype': 'Currency', 'name': 'BDT'}, + {'currency_name': 'BGN', 'doctype': 'Currency', 'name': 'BGN'}, + {'currency_name': 'BHD', 'doctype': 'Currency', 'name': 'BHD'}, + {'currency_name': 'BIF', 'doctype': 'Currency', 'name': 'BIF'}, + {'currency_name': 'BMD', 'doctype': 'Currency', 'name': 'BMD'}, + {'currency_name': 'BND', 'doctype': 'Currency', 'name': 'BND'}, + {'currency_name': 'BOB', 'doctype': 'Currency', 'name': 'BOB'}, + {'currency_name': 'BRL', 'doctype': 'Currency', 'name': 'BRL'}, + {'currency_name': 'BSD', 'doctype': 'Currency', 'name': 'BSD'}, + {'currency_name': 'BTN', 'doctype': 'Currency', 'name': 'BTN'}, + {'currency_name': 'BWP', 'doctype': 'Currency', 'name': 'BWP'}, + {'currency_name': 'BYR', 'doctype': 'Currency', 'name': 'BYR'}, + {'currency_name': 'BZD', 'doctype': 'Currency', 'name': 'BZD'}, + {'currency_name': 'CAD', 'doctype': 'Currency', 'name': 'CAD'}, + {'currency_name': 'CDF', 'doctype': 'Currency', 'name': 'CDF'}, + {'currency_name': 'CFA', 'doctype': 'Currency', 'name': 'CFA'}, + {'currency_name': 'CFP', 'doctype': 'Currency', 'name': 'CFP'}, + {'currency_name': 'CHF', 'doctype': 'Currency', 'name': 'CHF'}, + {'currency_name': 'CLP', 'doctype': 'Currency', 'name': 'CLP'}, + {'currency_name': 'CNY', 'doctype': 'Currency', 'name': 'CNY'}, + {'currency_name': 'COP', 'doctype': 'Currency', 'name': 'COP'}, + {'currency_name': 'CRC', 'doctype': 'Currency', 'name': 'CRC'}, + {'currency_name': 'CUC', 'doctype': 'Currency', 'name': 'CUC'}, + {'currency_name': 'CZK', 'doctype': 'Currency', 'name': 'CZK'}, + {'currency_name': 'DJF', 'doctype': 'Currency', 'name': 'DJF'}, + {'currency_name': 'DKK', 'doctype': 'Currency', 'name': 'DKK'}, + {'currency_name': 'DOP', 'doctype': 'Currency', 'name': 'DOP'}, + {'currency_name': 'DZD', 'doctype': 'Currency', 'name': 'DZD'}, + {'currency_name': 'EEK', 'doctype': 'Currency', 'name': 'EEK'}, + {'currency_name': 'EGP', 'doctype': 'Currency', 'name': 'EGP'}, + {'currency_name': 'ERN', 'doctype': 'Currency', 'name': 'ERN'}, + {'currency_name': 'ETB', 'doctype': 'Currency', 'name': 'ETB'}, + {'currency_name': 'EUR', 'doctype': 'Currency', 'name': 'EUR'}, + {'currency_name': 'FJD', 'doctype': 'Currency', 'name': 'FJD'}, + {'currency_name': 'FKP', 'doctype': 'Currency', 'name': 'FKP'}, + {'currency_name': 'FMG', 'doctype': 'Currency', 'name': 'FMG'}, + {'currency_name': 'GBP', 'doctype': 'Currency', 'name': 'GBP'}, + {'currency_name': 'GEL', 'doctype': 'Currency', 'name': 'GEL'}, + {'currency_name': 'GHS', 'doctype': 'Currency', 'name': 'GHS'}, + {'currency_name': 'GIP', 'doctype': 'Currency', 'name': 'GIP'}, + {'currency_name': 'GMD', 'doctype': 'Currency', 'name': 'GMD'}, + {'currency_name': 'GNF', 'doctype': 'Currency', 'name': 'GNF'}, + {'currency_name': 'GQE', 'doctype': 'Currency', 'name': 'GQE'}, + {'currency_name': 'GTQ', 'doctype': 'Currency', 'name': 'GTQ'}, + {'currency_name': 'GYD', 'doctype': 'Currency', 'name': 'GYD'}, + {'currency_name': 'HKD', 'doctype': 'Currency', 'name': 'HKD'}, + {'currency_name': 'HNL', 'doctype': 'Currency', 'name': 'HNL'}, + {'currency_name': 'HRK', 'doctype': 'Currency', 'name': 'HRK'}, + {'currency_name': 'HTG', 'doctype': 'Currency', 'name': 'HTG'}, + {'currency_name': 'HUF', 'doctype': 'Currency', 'name': 'HUF'}, + {'currency_name': 'IDR', 'doctype': 'Currency', 'name': 'IDR'}, + {'currency_name': 'ILS', 'doctype': 'Currency', 'name': 'ILS'}, + {'currency_name': 'INR', 'doctype': 'Currency', 'name': 'INR'}, + {'currency_name': 'IQD', 'doctype': 'Currency', 'name': 'IQD'}, + {'currency_name': 'IRR', 'doctype': 'Currency', 'name': 'IRR'}, + {'currency_name': 'ISK', 'doctype': 'Currency', 'name': 'ISK'}, + {'currency_name': 'JMD', 'doctype': 'Currency', 'name': 'JMD'}, + {'currency_name': 'JOD', 'doctype': 'Currency', 'name': 'JOD'}, + {'currency_name': 'JPY', 'doctype': 'Currency', 'name': 'JPY'}, + {'currency_name': 'KES', 'doctype': 'Currency', 'name': 'KES'}, + {'currency_name': 'KGS', 'doctype': 'Currency', 'name': 'KGS'}, + {'currency_name': 'KHR', 'doctype': 'Currency', 'name': 'KHR'}, + {'currency_name': 'KMF', 'doctype': 'Currency', 'name': 'KMF'}, + {'currency_name': 'KPW', 'doctype': 'Currency', 'name': 'KPW'}, + {'currency_name': 'KRW', 'doctype': 'Currency', 'name': 'KRW'}, + {'currency_name': 'KWD', 'doctype': 'Currency', 'name': 'KWD'}, + {'currency_name': 'KYD', 'doctype': 'Currency', 'name': 'KYD'}, + {'currency_name': 'KZT', 'doctype': 'Currency', 'name': 'KZT'}, + {'currency_name': 'LAK', 'doctype': 'Currency', 'name': 'LAK'}, + {'currency_name': 'LBP', 'doctype': 'Currency', 'name': 'LBP'}, + {'currency_name': 'LKR', 'doctype': 'Currency', 'name': 'LKR'}, + {'currency_name': 'LRD', 'doctype': 'Currency', 'name': 'LRD'}, + {'currency_name': 'LSL', 'doctype': 'Currency', 'name': 'LSL'}, + {'currency_name': 'LTL', 'doctype': 'Currency', 'name': 'LTL'}, + {'currency_name': 'LVL', 'doctype': 'Currency', 'name': 'LVL'}, + {'currency_name': 'LYD', 'doctype': 'Currency', 'name': 'LYD'}, + {'currency_name': 'MAD', 'doctype': 'Currency', 'name': 'MAD'}, + {'currency_name': 'MDL', 'doctype': 'Currency', 'name': 'MDL'}, + {'currency_name': 'MGA', 'doctype': 'Currency', 'name': 'MGA'}, + {'currency_name': 'MKD', 'doctype': 'Currency', 'name': 'MKD'}, + {'currency_name': 'MMK', 'doctype': 'Currency', 'name': 'MMK'}, + {'currency_name': 'MNT', 'doctype': 'Currency', 'name': 'MNT'}, + {'currency_name': 'MOP', 'doctype': 'Currency', 'name': 'MOP'}, + {'currency_name': 'MRO', 'doctype': 'Currency', 'name': 'MRO'}, + {'currency_name': 'MUR', 'doctype': 'Currency', 'name': 'MUR'}, + {'currency_name': 'MVR', 'doctype': 'Currency', 'name': 'MVR'}, + {'currency_name': 'MWK', 'doctype': 'Currency', 'name': 'MWK'}, + {'currency_name': 'MXN', 'doctype': 'Currency', 'name': 'MXN'}, + {'currency_name': 'MYR', 'doctype': 'Currency', 'name': 'MYR'}, + {'currency_name': 'MZM', 'doctype': 'Currency', 'name': 'MZM'}, + {'currency_name': 'NAD', 'doctype': 'Currency', 'name': 'NAD'}, + {'currency_name': 'NGN', 'doctype': 'Currency', 'name': 'NGN'}, + {'currency_name': 'NIO', 'doctype': 'Currency', 'name': 'NIO'}, + {'currency_name': 'NOK', 'doctype': 'Currency', 'name': 'NOK'}, + {'currency_name': 'NPR', 'doctype': 'Currency', 'name': 'NPR'}, + {'currency_name': 'NRs', 'doctype': 'Currency', 'name': 'NRs'}, + {'currency_name': 'NZD', 'doctype': 'Currency', 'name': 'NZD'}, + {'currency_name': 'OMR', 'doctype': 'Currency', 'name': 'OMR'}, + {'currency_name': 'PAB', 'doctype': 'Currency', 'name': 'PAB'}, + {'currency_name': 'PEN', 'doctype': 'Currency', 'name': 'PEN'}, + {'currency_name': 'PGK', 'doctype': 'Currency', 'name': 'PGK'}, + {'currency_name': 'PHP', 'doctype': 'Currency', 'name': 'PHP'}, + {'currency_name': 'PKR', 'doctype': 'Currency', 'name': 'PKR'}, + {'currency_name': 'PLN', 'doctype': 'Currency', 'name': 'PLN'}, + {'currency_name': 'PYG', 'doctype': 'Currency', 'name': 'PYG'}, + {'currency_name': 'QAR', 'doctype': 'Currency', 'name': 'QAR'}, + {'currency_name': 'RMB', 'doctype': 'Currency', 'name': 'RMB'}, + {'currency_name': 'RON', 'doctype': 'Currency', 'name': 'RON'}, + {'currency_name': 'RSD', 'doctype': 'Currency', 'name': 'RSD'}, + {'currency_name': 'RUB', 'doctype': 'Currency', 'name': 'RUB'}, + {'currency_name': 'RWF', 'doctype': 'Currency', 'name': 'RWF'}, + {'currency_name': 'SAR', 'doctype': 'Currency', 'name': 'SAR'}, + {'currency_name': 'SCR', 'doctype': 'Currency', 'name': 'SCR'}, + {'currency_name': 'SDG', 'doctype': 'Currency', 'name': 'SDG'}, + {'currency_name': 'SDR', 'doctype': 'Currency', 'name': 'SDR'}, + {'currency_name': 'SEK', 'doctype': 'Currency', 'name': 'SEK'}, + {'currency_name': 'SGD', 'doctype': 'Currency', 'name': 'SGD'}, + {'currency_name': 'SHP', 'doctype': 'Currency', 'name': 'SHP'}, + {'currency_name': 'SOS', 'doctype': 'Currency', 'name': 'SOS'}, + {'currency_name': 'SRD', 'doctype': 'Currency', 'name': 'SRD'}, + {'currency_name': 'STD', 'doctype': 'Currency', 'name': 'STD'}, + {'currency_name': 'SYP', 'doctype': 'Currency', 'name': 'SYP'}, + {'currency_name': 'SZL', 'doctype': 'Currency', 'name': 'SZL'}, + {'currency_name': 'THB', 'doctype': 'Currency', 'name': 'THB'}, + {'currency_name': 'TJS', 'doctype': 'Currency', 'name': 'TJS'}, + {'currency_name': 'TMT', 'doctype': 'Currency', 'name': 'TMT'}, + {'currency_name': 'TND', 'doctype': 'Currency', 'name': 'TND'}, + {'currency_name': 'TRY', 'doctype': 'Currency', 'name': 'TRY'}, + {'currency_name': 'TTD', 'doctype': 'Currency', 'name': 'TTD'}, + {'currency_name': 'TWD', 'doctype': 'Currency', 'name': 'TWD'}, + {'currency_name': 'TZS', 'doctype': 'Currency', 'name': 'TZS'}, + {'currency_name': 'UAE', 'doctype': 'Currency', 'name': 'UAE'}, + {'currency_name': 'UAH', 'doctype': 'Currency', 'name': 'UAH'}, + {'currency_name': 'UGX', 'doctype': 'Currency', 'name': 'UGX'}, + {'currency_name': 'USD', 'doctype': 'Currency', 'name': 'USD'}, + {'currency_name': 'UY', 'doctype': 'Currency', 'name': 'UY'}, + {'currency_name': 'UZS', 'doctype': 'Currency', 'name': 'UZS'}, + {'currency_name': 'VEB', 'doctype': 'Currency', 'name': 'VEB'}, + {'currency_name': 'VND', 'doctype': 'Currency', 'name': 'VND'}, + {'currency_name': 'VUV', 'doctype': 'Currency', 'name': 'VUV'}, + {'currency_name': 'WST', 'doctype': 'Currency', 'name': 'WST'}, + {'currency_name': 'XAF', 'doctype': 'Currency', 'name': 'XAF'}, + {'currency_name': 'XCD', 'doctype': 'Currency', 'name': 'XCD'}, + {'currency_name': 'XDR', 'doctype': 'Currency', 'name': 'XDR'}, + {'currency_name': 'XOF', 'doctype': 'Currency', 'name': 'XOF'}, + {'currency_name': 'XPF', 'doctype': 'Currency', 'name': 'XPF'}, + {'currency_name': 'YEN', 'doctype': 'Currency', 'name': 'YEN'}, + {'currency_name': 'YER', 'doctype': 'Currency', 'name': 'YER'}, + {'currency_name': 'YTL', 'doctype': 'Currency', 'name': 'YTL'}, + {'currency_name': 'ZAR', 'doctype': 'Currency', 'name': 'ZAR'}, + {'currency_name': 'ZMK', 'doctype': 'Currency', 'name': 'ZMK'}, + {'currency_name': 'ZWR', 'doctype': 'Currency', 'name': 'ZWR'}, + + # Country + {'country_name': 'Afghanistan', 'doctype': 'Country', 'name': 'Afghanistan'}, + {'country_name': 'Albania', 'doctype': 'Country', 'name': 'Albania'}, + {'country_name': 'Algeria', 'doctype': 'Country', 'name': 'Algeria'}, + {'country_name': 'Andorra', 'doctype': 'Country', 'name': 'Andorra'}, + {'country_name': 'Angola', 'doctype': 'Country', 'name': 'Angola'}, + {'country_name': 'Antarctica', 'doctype': 'Country', 'name': 'Antarctica'}, + {'country_name': 'Antigua and Barbuda', 'doctype': 'Country', 'name': 'Antigua and Barbuda'}, + {'country_name': 'Argentina', 'doctype': 'Country', 'name': 'Argentina'}, + {'country_name': 'Armenia', 'doctype': 'Country', 'name': 'Armenia'}, + {'country_name': 'Australia', 'doctype': 'Country', 'name': 'Australia'}, + {'country_name': 'Austria', 'doctype': 'Country', 'name': 'Austria'}, + {'country_name': 'Azerbaijan', 'doctype': 'Country', 'name': 'Azerbaijan'}, + {'country_name': 'Bahamas', 'doctype': 'Country', 'name': 'Bahamas'}, + {'country_name': 'Bahrain', 'doctype': 'Country', 'name': 'Bahrain'}, + {'country_name': 'Bangladesh', 'doctype': 'Country', 'name': 'Bangladesh'}, + {'country_name': 'Barbados', 'doctype': 'Country', 'name': 'Barbados'}, + {'country_name': 'Belarus', 'doctype': 'Country', 'name': 'Belarus'}, + {'country_name': 'Belgium', 'doctype': 'Country', 'name': 'Belgium'}, + {'country_name': 'Belize', 'doctype': 'Country', 'name': 'Belize'}, + {'country_name': 'Benin', 'doctype': 'Country', 'name': 'Benin'}, + {'country_name': 'Bermuda', 'doctype': 'Country', 'name': 'Bermuda'}, + {'country_name': 'Bhutan', 'doctype': 'Country', 'name': 'Bhutan'}, + {'country_name': 'Bolivia', 'doctype': 'Country', 'name': 'Bolivia'}, + {'country_name': 'Bosnia and Herzegovina', 'doctype': 'Country', 'name': 'Bosnia and Herzegovina'}, + {'country_name': 'Botswana', 'doctype': 'Country', 'name': 'Botswana'}, + {'country_name': 'Brazil', 'doctype': 'Country', 'name': 'Brazil'}, + {'country_name': 'Brunei', 'doctype': 'Country', 'name': 'Brunei'}, + {'country_name': 'Bulgaria', 'doctype': 'Country', 'name': 'Bulgaria'}, + {'country_name': 'Burkina Faso', 'doctype': 'Country', 'name': 'Burkina Faso'}, + {'country_name': 'Burma', 'doctype': 'Country', 'name': 'Burma'}, + {'country_name': 'Burundi', 'doctype': 'Country', 'name': 'Burundi'}, + {'country_name': 'Cambodia', 'doctype': 'Country', 'name': 'Cambodia'}, + {'country_name': 'Cameroon', 'doctype': 'Country', 'name': 'Cameroon'}, + {'country_name': 'Canada', 'doctype': 'Country', 'name': 'Canada'}, + {'country_name': 'Cape Verde', 'doctype': 'Country', 'name': 'Cape Verde'}, + {'country_name': 'Central African Republic', 'doctype': 'Country', 'name': 'Central African Republic'}, + {'country_name': 'Chad', 'doctype': 'Country', 'name': 'Chad'}, + {'country_name': 'Chile', 'doctype': 'Country', 'name': 'Chile'}, + {'country_name': 'China', 'doctype': 'Country', 'name': 'China'}, + {'country_name': 'Colombia', 'doctype': 'Country', 'name': 'Colombia'}, + {'country_name': 'Comoros', 'doctype': 'Country', 'name': 'Comoros'}, + {'country_name': 'Congo, Democratic Republic', 'doctype': 'Country', 'name': 'Congo, Democratic Republic'}, + {'country_name': 'Congo, Republic of the', 'doctype': 'Country', 'name': 'Congo, Republic of the'}, + {'country_name': 'Costa Rica', 'doctype': 'Country', 'name': 'Costa Rica'}, + {'country_name': 'Cote dIvoire', 'doctype': 'Country', 'name': 'Cote dIvoire'}, + {'country_name': 'Croatia', 'doctype': 'Country', 'name': 'Croatia'}, + {'country_name': 'Cuba', 'doctype': 'Country', 'name': 'Cuba'}, + {'country_name': 'Cyprus', 'doctype': 'Country', 'name': 'Cyprus'}, + {'country_name': 'Czech Republic', 'doctype': 'Country', 'name': 'Czech Republic'}, + {'country_name': 'Denmark', 'doctype': 'Country', 'name': 'Denmark'}, + {'country_name': 'Djibouti', 'doctype': 'Country', 'name': 'Djibouti'}, + {'country_name': 'Dominica', 'doctype': 'Country', 'name': 'Dominica'}, + {'country_name': 'Dominican Republic', 'doctype': 'Country', 'name': 'Dominican Republic'}, + {'country_name': 'East Timor', 'doctype': 'Country', 'name': 'East Timor'}, + {'country_name': 'Ecuador', 'doctype': 'Country', 'name': 'Ecuador'}, + {'country_name': 'Egypt', 'doctype': 'Country', 'name': 'Egypt'}, + {'country_name': 'El Salvador', 'doctype': 'Country', 'name': 'El Salvador'}, + {'country_name': 'Equatorial Guinea', 'doctype': 'Country', 'name': 'Equatorial Guinea'}, + {'country_name': 'Eritrea', 'doctype': 'Country', 'name': 'Eritrea'}, + {'country_name': 'Estonia', 'doctype': 'Country', 'name': 'Estonia'}, + {'country_name': 'Ethiopia', 'doctype': 'Country', 'name': 'Ethiopia'}, + {'country_name': 'Fiji', 'doctype': 'Country', 'name': 'Fiji'}, + {'country_name': 'Finland', 'doctype': 'Country', 'name': 'Finland'}, + {'country_name': 'France', 'doctype': 'Country', 'name': 'France'}, + {'country_name': 'Gabon', 'doctype': 'Country', 'name': 'Gabon'}, + {'country_name': 'Gambia', 'doctype': 'Country', 'name': 'Gambia'}, + {'country_name': 'Georgia', 'doctype': 'Country', 'name': 'Georgia'}, + {'country_name': 'Germany', 'doctype': 'Country', 'name': 'Germany'}, + {'country_name': 'Ghana', 'doctype': 'Country', 'name': 'Ghana'}, + {'country_name': 'Greece', 'doctype': 'Country', 'name': 'Greece'}, + {'country_name': 'Greenland', 'doctype': 'Country', 'name': 'Greenland'}, + {'country_name': 'Grenada', 'doctype': 'Country', 'name': 'Grenada'}, + {'country_name': 'Guatemala', 'doctype': 'Country', 'name': 'Guatemala'}, + {'country_name': 'Guinea', 'doctype': 'Country', 'name': 'Guinea'}, + {'country_name': 'Guinea-Bissa', 'doctype': 'Country', 'name': 'Guinea-Bissa'}, + {'country_name': 'Guyana', 'doctype': 'Country', 'name': 'Guyana'}, + {'country_name': 'Haiti', 'doctype': 'Country', 'name': 'Haiti'}, + {'country_name': 'Honduras', 'doctype': 'Country', 'name': 'Honduras'}, + {'country_name': 'Hong Kong', 'doctype': 'Country', 'name': 'Hong Kong'}, + {'country_name': 'Hungary', 'doctype': 'Country', 'name': 'Hungary'}, + {'country_name': 'Iceland', 'doctype': 'Country', 'name': 'Iceland'}, + {'country_name': 'India', 'doctype': 'Country', 'name': 'India'}, + {'country_name': 'Indonesia', 'doctype': 'Country', 'name': 'Indonesia'}, + {'country_name': 'Iran', 'doctype': 'Country', 'name': 'Iran'}, + {'country_name': 'Iraq', 'doctype': 'Country', 'name': 'Iraq'}, + {'country_name': 'Ireland', 'doctype': 'Country', 'name': 'Ireland'}, + {'country_name': 'Israel', 'doctype': 'Country', 'name': 'Israel'}, + {'country_name': 'Italy', 'doctype': 'Country', 'name': 'Italy'}, + {'country_name': 'Jamaica', 'doctype': 'Country', 'name': 'Jamaica'}, + {'country_name': 'Japan', 'doctype': 'Country', 'name': 'Japan'}, + {'country_name': 'Jordan', 'doctype': 'Country', 'name': 'Jordan'}, + {'country_name': 'Kazakhstan', 'doctype': 'Country', 'name': 'Kazakhstan'}, + {'country_name': 'Kenya', 'doctype': 'Country', 'name': 'Kenya'}, + {'country_name': 'Kiribati', 'doctype': 'Country', 'name': 'Kiribati'}, + {'country_name': 'Korea, North', 'doctype': 'Country', 'name': 'Korea, North'}, + {'country_name': 'Korea, South', 'doctype': 'Country', 'name': 'Korea, South'}, + {'country_name': 'Kuwait', 'doctype': 'Country', 'name': 'Kuwait'}, + {'country_name': 'Kyrgyzstan', 'doctype': 'Country', 'name': 'Kyrgyzstan'}, + {'country_name': 'Laos', 'doctype': 'Country', 'name': 'Laos'}, + {'country_name': 'Latvia', 'doctype': 'Country', 'name': 'Latvia'}, + {'country_name': 'Lebanon', 'doctype': 'Country', 'name': 'Lebanon'}, + {'country_name': 'Lesotho', 'doctype': 'Country', 'name': 'Lesotho'}, + {'country_name': 'Liberia', 'doctype': 'Country', 'name': 'Liberia'}, + {'country_name': 'Libya', 'doctype': 'Country', 'name': 'Libya'}, + {'country_name': 'Liechtenstein', 'doctype': 'Country', 'name': 'Liechtenstein'}, + {'country_name': 'Lithuania', 'doctype': 'Country', 'name': 'Lithuania'}, + {'country_name': 'Luxembourg', 'doctype': 'Country', 'name': 'Luxembourg'}, + {'country_name': 'Macedonia', 'doctype': 'Country', 'name': 'Macedonia'}, + {'country_name': 'Madagascar', 'doctype': 'Country', 'name': 'Madagascar'}, + {'country_name': 'Malawi', 'doctype': 'Country', 'name': 'Malawi'}, + {'country_name': 'Malaysia', 'doctype': 'Country', 'name': 'Malaysia'}, + {'country_name': 'Maldives', 'doctype': 'Country', 'name': 'Maldives'}, + {'country_name': 'Mali', 'doctype': 'Country', 'name': 'Mali'}, + {'country_name': 'Malta', 'doctype': 'Country', 'name': 'Malta'}, + {'country_name': 'Marshall Islands', 'doctype': 'Country', 'name': 'Marshall Islands'}, + {'country_name': 'Mauritania', 'doctype': 'Country', 'name': 'Mauritania'}, + {'country_name': 'Mauritius', 'doctype': 'Country', 'name': 'Mauritius'}, + {'country_name': 'Mexico', 'doctype': 'Country', 'name': 'Mexico'}, + {'country_name': 'Micronesia', 'doctype': 'Country', 'name': 'Micronesia'}, + {'country_name': 'Moldova', 'doctype': 'Country', 'name': 'Moldova'}, + {'country_name': 'Monaco', 'doctype': 'Country', 'name': 'Monaco'}, + {'country_name': 'Mongolia', 'doctype': 'Country', 'name': 'Mongolia'}, + {'country_name': 'Morocco', 'doctype': 'Country', 'name': 'Morocco'}, + {'country_name': 'Mozambique', 'doctype': 'Country', 'name': 'Mozambique'}, + {'country_name': 'Namibia', 'doctype': 'Country', 'name': 'Namibia'}, + {'country_name': 'Naur', 'doctype': 'Country', 'name': 'Naur'}, + {'country_name': 'Nepal', 'doctype': 'Country', 'name': 'Nepal'}, + {'country_name': 'Netherlands', 'doctype': 'Country', 'name': 'Netherlands'}, + {'country_name': 'New Zealand', 'doctype': 'Country', 'name': 'New Zealand'}, + {'country_name': 'Nicaragua', 'doctype': 'Country', 'name': 'Nicaragua'}, + {'country_name': 'Niger', 'doctype': 'Country', 'name': 'Niger'}, + {'country_name': 'Nigeria', 'doctype': 'Country', 'name': 'Nigeria'}, + {'country_name': 'North Korea', 'doctype': 'Country', 'name': 'North Korea'}, + {'country_name': 'Norway', 'doctype': 'Country', 'name': 'Norway'}, + {'country_name': 'Oman', 'doctype': 'Country', 'name': 'Oman'}, + {'country_name': 'Pakistan', 'doctype': 'Country', 'name': 'Pakistan'}, + {'country_name': 'Panama', 'doctype': 'Country', 'name': 'Panama'}, + {'country_name': 'Papua New Guinea', 'doctype': 'Country', 'name': 'Papua New Guinea'}, + {'country_name': 'Paraguay', 'doctype': 'Country', 'name': 'Paraguay'}, + {'country_name': 'Per', 'doctype': 'Country', 'name': 'Per'}, + {'country_name': 'Philippines', 'doctype': 'Country', 'name': 'Philippines'}, + {'country_name': 'Poland', 'doctype': 'Country', 'name': 'Poland'}, + {'country_name': 'Portugal', 'doctype': 'Country', 'name': 'Portugal'}, + {'country_name': 'Qatar', 'doctype': 'Country', 'name': 'Qatar'}, + {'country_name': 'Romania', 'doctype': 'Country', 'name': 'Romania'}, + {'country_name': 'Russia', 'doctype': 'Country', 'name': 'Russia'}, + {'country_name': 'Rwanda', 'doctype': 'Country', 'name': 'Rwanda'}, + {'country_name': 'Samoa', 'doctype': 'Country', 'name': 'Samoa'}, + {'country_name': 'San Marino', 'doctype': 'Country', 'name': 'San Marino'}, + {'country_name': ' Sao Tome', 'doctype': 'Country', 'name': 'Sao Tome'}, + {'country_name': 'Saudi Arabia', 'doctype': 'Country', 'name': 'Saudi Arabia'}, + {'country_name': 'Senegal', 'doctype': 'Country', 'name': 'Senegal'}, + {'country_name': 'Serbia and Montenegro', 'doctype': 'Country', 'name': 'Serbia and Montenegro'}, + {'country_name': 'Seychelles', 'doctype': 'Country', 'name': 'Seychelles'}, + {'country_name': 'Sierra Leone', 'doctype': 'Country', 'name': 'Sierra Leone'}, + {'country_name': 'Singapore', 'doctype': 'Country', 'name': 'Singapore'}, + {'country_name': 'Slovakia', 'doctype': 'Country', 'name': 'Slovakia'}, + {'country_name': 'Slovenia', 'doctype': 'Country', 'name': 'Slovenia'}, + {'country_name': 'Solomon Islands', 'doctype': 'Country', 'name': 'Solomon Islands'}, + {'country_name': 'Somalia', 'doctype': 'Country', 'name': 'Somalia'}, + {'country_name': 'South Africa', 'doctype': 'Country', 'name': 'South Africa'}, + {'country_name': 'South Korea', 'doctype': 'Country', 'name': 'South Korea'}, + {'country_name': 'Spain', 'doctype': 'Country', 'name': 'Spain'}, + {'country_name': 'Sri Lanka', 'doctype': 'Country', 'name': 'Sri Lanka'}, + {'country_name': 'Sudan', 'doctype': 'Country', 'name': 'Sudan'}, + {'country_name': 'Suriname', 'doctype': 'Country', 'name': 'Suriname'}, + {'country_name': 'Swaziland', 'doctype': 'Country', 'name': 'Swaziland'}, + {'country_name': 'Sweden', 'doctype': 'Country', 'name': 'Sweden'}, + {'country_name': 'Switzerland', 'doctype': 'Country', 'name': 'Switzerland'}, + {'country_name': 'Syria', 'doctype': 'Country', 'name': 'Syria'}, + {'country_name': 'Taiwan', 'doctype': 'Country', 'name': 'Taiwan'}, + {'country_name': 'Tajikistan', 'doctype': 'Country', 'name': 'Tajikistan'}, + {'country_name': 'Tanzania', 'doctype': 'Country', 'name': 'Tanzania'}, + {'country_name': 'Thailand', 'doctype': 'Country', 'name': 'Thailand'}, + {'country_name': 'Togo', 'doctype': 'Country', 'name': 'Togo'}, + {'country_name': 'Tonga', 'doctype': 'Country', 'name': 'Tonga'}, + {'country_name': 'Trinidad and Tobago', 'doctype': 'Country', 'name': 'Trinidad and Tobago'}, + {'country_name': 'Tunisia', 'doctype': 'Country', 'name': 'Tunisia'}, + {'country_name': 'Turkey', 'doctype': 'Country', 'name': 'Turkey'}, + {'country_name': 'Turkmenistan', 'doctype': 'Country', 'name': 'Turkmenistan'}, + {'country_name': 'Uganda', 'doctype': 'Country', 'name': 'Uganda'}, + {'country_name': 'Ukraine', 'doctype': 'Country', 'name': 'Ukraine'}, + {'country_name': 'United Arab Emirates', 'doctype': 'Country', 'name': 'United Arab Emirates'}, + {'country_name': 'United Kingdom', 'doctype': 'Country', 'name': 'United Kingdom'}, + {'country_name': 'United States', 'doctype': 'Country', 'name': 'United States'}, + {'country_name': 'Uruguay', 'doctype': 'Country', 'name': 'Uruguay'}, + {'country_name': 'Uzbekistan', 'doctype': 'Country', 'name': 'Uzbekistan'}, + {'country_name': 'Vanuat', 'doctype': 'Country', 'name': 'Vanuat'}, + {'country_name': 'Venezuela', 'doctype': 'Country', 'name': 'Venezuela'}, + {'country_name': 'Vietnam', 'doctype': 'Country', 'name': 'Vietnam'}, + {'country_name': 'Yemen', 'doctype': 'Country', 'name': 'Yemen'}, + {'country_name': 'Zambia', 'doctype': 'Country', 'name': 'Zambia'}, + {'country_name': 'Zimbabwe', 'doctype': 'Country', 'name': 'Zimbabwe'}, + + # State + {'state_name': 'Alabama', 'country': 'United States', 'doctype': 'State', 'name': 'Alabama'}, + {'state_name': 'Alaska', 'country': 'United States', 'doctype': 'State', 'name': 'Alaska'}, + {'state_name': 'Andaman and Nicobar Islands', 'country': 'India', 'doctype': 'State', 'name': 'Andaman and Nicobar Islands'}, + {'state_name': 'Andhra Pradesh', 'country': 'India', 'doctype': 'State', 'name': 'Andhra Pradesh'}, + {'state_name': 'Arizona', 'country': 'United States', 'doctype': 'State', 'name': 'Arizona'}, + {'state_name': 'Arkansas', 'country': 'United States', 'doctype': 'State', 'name': 'Arkansas'}, + {'state_name': 'Arunachal Pradesh', 'country': 'India', 'doctype': 'State', 'name': 'Arunachal Pradesh'}, + {'state_name': 'Assam', 'country': 'India', 'doctype': 'State', 'name': 'Assam'}, + {'state_name': 'Beijing ', 'country': 'China', 'doctype': 'State', 'name': 'Beijing'}, + {'state_name': 'Bihar', 'country': 'India', 'doctype': 'State', 'name': 'Bihar'}, + {'state_name': 'California', 'country': 'United States', 'doctype': 'State', 'name': 'California'}, + {'state_name': 'Chandigarh', 'country': 'India', 'doctype': 'State', 'name': 'Chandigarh'}, + {'state_name': 'Changchun ', 'country': 'China', 'doctype': 'State', 'name': 'Changchun'}, + {'state_name': 'Chengde', 'country': 'China', 'doctype': 'State', 'name': 'Chengde'}, + {'state_name': 'Chengdu', 'country': 'China', 'doctype': 'State', 'name': 'Chengdu'}, + {'state_name': 'Chhattisgarh', 'country': 'India', 'doctype': 'State', 'name': 'Chhattisgarh'}, + {'state_name': 'Chongqing ', 'country': 'China', 'doctype': 'State', 'name': 'Chongqing'}, + {'state_name': 'Colorado', 'country': 'United States', 'doctype': 'State', 'name': 'Colorado'}, + {'state_name': 'Connecticut', 'country': 'United States', 'doctype': 'State', 'name': 'Connecticut'}, + {'state_name': 'Dadra and Nagar Haveli', 'country': 'India', 'doctype': 'State', 'name': 'Dadra and Nagar Haveli'}, + {'state_name': 'Dalian', 'country': 'China', 'doctype': 'State', 'name': 'Dalian'}, + {'state_name': 'Daman and Di', 'country': 'India', 'doctype': 'State', 'name': 'Daman and Di'}, + {'state_name': 'Delaware', 'country': 'United States', 'doctype': 'State', 'name': 'Delaware'}, + {'state_name': 'Delhi', 'country': 'India', 'doctype': 'State', 'name': 'Delhi'}, + {'state_name': 'Dongguan ', 'country': 'China', 'doctype': 'State', 'name': 'Dongguan'}, + {'state_name': 'Dunhuang ', 'country': 'China', 'doctype': 'State', 'name': 'Dunhuang'}, + {'state_name': 'Florida', 'country': 'United States', 'doctype': 'State', 'name': 'Florida'}, + {'state_name': 'Georgia', 'country': 'United States', 'doctype': 'State', 'name': 'Georgia'}, + {'state_name': 'Goa', 'country': 'India', 'doctype': 'State', 'name': 'Goa'}, + {'state_name': 'Guangzho', 'country': 'China', 'doctype': 'State', 'name': 'Guangzho'}, + {'state_name': 'Guilin ', 'country': 'China', 'doctype': 'State', 'name': 'Guilin'}, + {'state_name': 'Gujarat', 'country': 'India', 'doctype': 'State', 'name': 'Gujarat'}, + {'state_name': 'Hangzhou', 'country': 'China', 'doctype': 'State', 'name': 'Hangzhou'}, + {'state_name': 'Harbin', 'country': 'China', 'doctype': 'State', 'name': 'Harbin'}, + {'state_name': 'Haryana', 'country': 'India', 'doctype': 'State', 'name': 'Haryana'}, + {'state_name': 'Hawaii', 'country': 'United States', 'doctype': 'State', 'name': 'Hawaii'}, + {'state_name': 'Hefei ', 'country': 'China', 'doctype': 'State', 'name': 'Hefei'}, + {'state_name': 'Himachal Pradesh', 'country': 'India', 'doctype': 'State', 'name': 'Himachal Pradesh'}, + {'state_name': 'Idaho', 'country': 'United States', 'doctype': 'State', 'name': 'Idaho'}, + {'state_name': 'Illinois', 'country': 'United States', 'doctype': 'State', 'name': 'Illinois'}, + {'state_name': 'Indiana', 'country': 'United States', 'doctype': 'State', 'name': 'Indiana'}, + {'state_name': 'Iowa', 'country': 'United States', 'doctype': 'State', 'name': 'Iowa'}, + {'state_name': 'Jammu and Kashmir', 'country': 'India', 'doctype': 'State', 'name': 'Jammu and Kashmir'}, + {'state_name': 'Jharkhand', 'country': 'India', 'doctype': 'State', 'name': 'Jharkhand'}, + {'state_name': 'Jinan ', 'country': 'China', 'doctype': 'State', 'name': 'Jinan'}, + {'state_name': 'Kansas', 'country': 'United States', 'doctype': 'State', 'name': 'Kansas'}, + {'state_name': 'Karnataka', 'country': 'India', 'doctype': 'State', 'name': 'Karnataka'}, + {'state_name': 'Kashi', 'country': 'China', 'doctype': 'State', 'name': 'Kashi'}, + {'state_name': 'Kentucky', 'country': 'United States', 'doctype': 'State', 'name': 'Kentucky'}, + {'state_name': 'Kerala', 'country': 'India', 'doctype': 'State', 'name': 'Kerala'}, + {'state_name': 'Kowloon ', 'country': 'China', 'doctype': 'State', 'name': 'Kowloon'}, + {'state_name': 'Kunming ', 'country': 'China', 'doctype': 'State', 'name': 'Kunming'}, + {'state_name': 'Lakshadweep', 'country': 'India', 'doctype': 'State', 'name': 'Lakshadweep'}, + {'state_name': 'Lanzho', 'country': 'China', 'doctype': 'State', 'name': 'Lanzho'}, + {'state_name': 'Lijiang City ', 'country': 'China', 'doctype': 'State', 'name': 'Lijiang City'}, + {'state_name': 'Louisiana', 'country': 'United States', 'doctype': 'State', 'name': 'Louisiana'}, + {'state_name': 'Madhya Pradesh', 'country': 'India', 'doctype': 'State', 'name': 'Madhya Pradesh'}, + {'state_name': 'Maharashtra', 'country': 'India', 'doctype': 'State', 'name': 'Maharashtra'}, + {'state_name': 'Maine', 'country': 'United States', 'doctype': 'State', 'name': 'Maine'}, + {'state_name': 'Manipur', 'country': 'India', 'doctype': 'State', 'name': 'Manipur'}, + {'state_name': 'Maryland', 'country': 'United States', 'doctype': 'State', 'name': 'Maryland'}, + {'state_name': 'Massachusetts', 'country': 'United States', 'doctype': 'State', 'name': 'Massachusetts'}, + {'state_name': 'Meghalaya', 'country': 'India', 'doctype': 'State', 'name': 'Meghalaya'}, + {'state_name': 'Michigan', 'country': 'United States', 'doctype': 'State', 'name': 'Michigan'}, + {'state_name': 'Minnesota', 'country': 'United States', 'doctype': 'State', 'name': 'Minnesota'}, + {'state_name': 'Mississippi', 'country': 'United States', 'doctype': 'State', 'name': 'Mississippi'}, + {'state_name': 'Missouri', 'country': 'United States', 'doctype': 'State', 'name': 'Missouri'}, + {'state_name': 'Mizoram', 'country': 'India', 'doctype': 'State', 'name': 'Mizoram'}, + {'state_name': 'Montana', 'country': 'United States', 'doctype': 'State', 'name': 'Montana'}, + {'state_name': 'Nagaland', 'country': 'India', 'doctype': 'State', 'name': 'Nagaland'}, + {'state_name': 'Nanchang ', 'country': 'China', 'doctype': 'State', 'name': 'Nanchang'}, + {'state_name': 'Nanjing', 'country': 'China', 'doctype': 'State', 'name': 'Nanjing'}, + {'state_name': 'Nebraska', 'country': 'United States', 'doctype': 'State', 'name': 'Nebraska'}, + {'state_name': 'Nevada', 'country': 'United States', 'doctype': 'State', 'name': 'Nevada'}, + {'state_name': 'New Hampshire', 'country': 'United States', 'doctype': 'State', 'name': 'New Hampshire'}, + {'state_name': 'New Jersey', 'country': 'United States', 'doctype': 'State', 'name': 'New Jersey'}, + {'state_name': 'New Mexico', 'country': 'United States', 'doctype': 'State', 'name': 'New Mexico'}, + {'state_name': 'New York', 'country': 'United States', 'doctype': 'State', 'name': 'New York'}, + {'state_name': 'Ningbo ', 'country': 'China', 'doctype': 'State', 'name': 'Ningbo'}, + {'state_name': 'North Carolina', 'country': 'United States', 'doctype': 'State', 'name': 'North Carolina'}, + {'state_name': 'North Dakota', 'country': 'United States', 'doctype': 'State', 'name': 'North Dakota'}, + {'state_name': 'Ohio', 'country': 'United States', 'doctype': 'State', 'name': 'Ohio'}, + {'state_name': 'Oklahoma', 'country': 'United States', 'doctype': 'State', 'name': 'Oklahoma'}, + {'state_name': 'Oregon', 'country': 'United States', 'doctype': 'State', 'name': 'Oregon'}, + {'state_name': 'Orissa', 'country': 'India', 'doctype': 'State', 'name': 'Orissa'}, + {'state_name': 'Pennsylvania', 'country': 'United States', 'doctype': 'State', 'name': 'Pennsylvania'}, + {'state_name': 'Puducherry', 'country': 'India', 'doctype': 'State', 'name': 'Puducherry'}, + {'state_name': 'Punjab', 'country': 'India', 'doctype': 'State', 'name': 'Punjab'}, + {'state_name': 'Qingdao ', 'country': 'China', 'doctype': 'State', 'name': 'Qingdao'}, + {'state_name': 'Quf', 'country': 'China', 'doctype': 'State', 'name': 'Quf'}, + {'state_name': 'Rajasthan', 'country': 'India', 'doctype': 'State', 'name': 'Rajasthan'}, + {'state_name': 'Rhode Island', 'country': 'United States', 'doctype': 'State', 'name': 'Rhode Island'}, + {'state_name': 'Sanya ', 'country': 'China', 'doctype': 'State', 'name': 'Sanya'}, + {'state_name': 'Shanghai ', 'country': 'China', 'doctype': 'State', 'name': 'Shanghai'}, + {'state_name': 'Shenyang', 'country': 'China', 'doctype': 'State', 'name': 'Shenyang'}, + {'state_name': 'Shenzhen', 'country': 'China', 'doctype': 'State', 'name': 'Shenzhen'}, + {'state_name': 'Sikkim', 'country': 'India', 'doctype': 'State', 'name': 'Sikkim'}, + {'state_name': 'South Carolina', 'country': 'United States', 'doctype': 'State', 'name': 'South Carolina'}, + {'state_name': 'South Dakota', 'country': 'United States', 'doctype': 'State', 'name': 'South Dakota'}, + {'state_name': 'Suzho', 'country': 'China', 'doctype': 'State', 'name': 'Suzho'}, + {'state_name': 'Tamil Nad', 'country': 'India', 'doctype': 'State', 'name': 'Tamil Nad'}, + {'state_name': 'Tennessee', 'country': 'United States', 'doctype': 'State', 'name': 'Tennessee'}, + {'state_name': 'Texas', 'country': 'United States', 'doctype': 'State', 'name': 'Texas'}, + {'state_name': 'Tianjin', 'country': 'China', 'doctype': 'State', 'name': 'Tianjin'}, + {'state_name': 'Tripura', 'country': 'India', 'doctype': 'State', 'name': 'Tripura'}, + {'state_name': 'Turpan', 'country': 'China', 'doctype': 'State', 'name': 'Turpan'}, + {'state_name': 'Urumqi', 'country': 'China', 'doctype': 'State', 'name': 'Urumqi'}, + {'state_name': 'Utah', 'country': 'United States', 'doctype': 'State', 'name': 'Utah'}, + {'state_name': 'Uttar Pradesh', 'country': 'India', 'doctype': 'State', 'name': 'Uttar Pradesh'}, + {'state_name': 'Uttarakhand', 'country': 'India', 'doctype': 'State', 'name': 'Uttarakhand'}, + {'state_name': 'Vermont', 'country': 'United States', 'doctype': 'State', 'name': 'Vermont'}, + {'state_name': 'Virginia', 'country': 'United States', 'doctype': 'State', 'name': 'Virginia'}, + {'state_name': 'Washington', 'country': 'United States', 'doctype': 'State', 'name': 'Washington'}, + {'state_name': 'West Bengal', 'country': 'India', 'doctype': 'State', 'name': 'West Bengal'}, + {'state_name': 'West Virginia', 'country': 'United States', 'doctype': 'State', 'name': 'West Virginia'}, + {'state_name': 'Wisconsin', 'country': 'United States', 'doctype': 'State', 'name': 'Wisconsin'}, + {'state_name': 'Wuhan', 'country': 'China', 'doctype': 'State', 'name': 'Wuhan'}, + {'state_name': 'Wuxi', 'country': 'China', 'doctype': 'State', 'name': 'Wuxi'}, + {'state_name': 'Wyoming', 'country': 'United States', 'doctype': 'State', 'name': 'Wyoming'}, + {'state_name': 'Xiamen', 'country': 'China', 'doctype': 'State', 'name': 'Xiamen'}, + {'state_name': 'Xian', 'country': 'China', 'doctype': 'State', 'name': 'Xian'}, + {'state_name': 'Zhongshan ', 'country': 'China', 'doctype': 'State', 'name': 'Zhongshan'}, + + ] + + for r in records: + doc = webnotes.doc(r) + doc.insert() + \ No newline at end of file diff --git a/stock/Item Group/All Item Groups/All Item Groups.txt b/stock/Item Group/All Item Groups/All Item Groups.txt deleted file mode 100644 index f03fa1ad2f..0000000000 --- a/stock/Item Group/All Item Groups/All Item Groups.txt +++ /dev/null @@ -1 +0,0 @@ -[{'creation': '2010-07-16 11:03:21', 'doctype': 'Item Group', 'lft': 1, 'owner': 'harshada@webnotestech.com', 'rgt': 286, 'company_abbr': None, 'docstatus': 0, 'item_group_name': 'All Item Groups', 'description': None, 'parent': None, 'is_group': 'Yes', 'company': None, 'show_in_catalogue': None, 'group_or_ledger': None, 'modified_by': 'harshada@webnotestech.com', 'group_name': None, 'trash_reason': None, 'name': 'All Item Groups', 'idx': None, 'modified': '2010-07-16 11:03:21', 'parent_item_group': '', 'old_parent': '', 'parenttype': None, 'parentfield': None}] \ No newline at end of file diff --git a/stock/Item Group/Default/Default.txt b/stock/Item Group/Default/Default.txt deleted file mode 100644 index c0b6207752..0000000000 --- a/stock/Item Group/Default/Default.txt +++ /dev/null @@ -1 +0,0 @@ -[{'creation': '2010-07-05 16:08:14', 'doctype': 'Item Group', 'lft': 76, 'owner': 'nabin@webnotestech.com', 'rgt': 77, 'company_abbr': None, 'docstatus': 0, 'item_group_name': 'Default', 'description': None, 'parent': None, 'is_group': 'No', 'company': None, 'show_in_catalogue': None, 'group_or_ledger': None, 'modified_by': 'nabin@webnotestech.com', 'group_name': None, 'trash_reason': None, 'name': 'Default', 'idx': None, 'modified': '2010-07-05 16:08:14', 'parent_item_group': 'All Item Groups', 'old_parent': '', 'parenttype': None, 'parentfield': None}] \ No newline at end of file diff --git a/stock/__init__.py b/stock/__init__.py index 7c2a0d4493..feb55c7222 100644 --- a/stock/__init__.py +++ b/stock/__init__.py @@ -4,4 +4,7 @@ install_docs = [ {"doctype":"Role", "role_name":"Material Master Manager", "name":"Material Master Manager"}, {"doctype":"Role", "role_name":"Material User", "name":"Material User"}, {"doctype":"Role", "role_name":"Quality Manager", "name":"Quality Manager"}, + {"doctype":"Item Group", "item_group_name":"All Item Groups", "is_group":"Yes"}, + {"doctype":"Item Group", "item_group_name":"Default", + "parent_item_group":"All Item Groups", "is_group":"No"}, ] diff --git a/stock/module_def/stock/locale/_messages_doc.json b/stock/module_def/stock/locale/_messages_doc.json deleted file mode 100644 index 410ce5fab8..0000000000 --- a/stock/module_def/stock/locale/_messages_doc.json +++ /dev/null @@ -1,18 +0,0 @@ -[ - "Ordered Items To Be Delivered", - "A logical Warehouse against which stock entries are made.", - "For the convenience of customers, these codes can be used in print formats like Invoices and Delivery Notes", - "Featured Item in Item Group", - "Stock Analytics", - "Distinct unit of an Item", - "Stock Home", - "Item-Wise Price List", - "Aggregate group of **Items** into another **Item**. This is useful if you are bundling a certain **Items** into a package and you maintain stock of the packed **Items** and not the aggregate **Item**. The package **Item** will have \"Is Stock Item\" as \"No\" and \"Is Sales Item\" as \"Yes\".For Example: If you are selling Laptops and Backpacks separately and have a special price if the customer buys both, then the Laptop + Backpack will be a new Sales BOM Item.Note: BOM = Bill of Materials", - "Stock Level", - "Table for Item that will be shown in Web Site", - "Stock Ageing", - "Stock Balance", - "A Product or a Service that is bought, sold or kept in stock.", - "Generate packing slips for packages to be delivered. Used to notify package number, package contents and its weight.", - "Stock Ledger" -] \ No newline at end of file diff --git a/stock/module_def/stock/locale/hi-doc.json b/stock/module_def/stock/locale/hi-doc.json deleted file mode 100644 index 0d8538c983..0000000000 --- a/stock/module_def/stock/locale/hi-doc.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "A Product or a Service that is bought, sold or kept in stock.": "\u090f\u0915 \u0909\u0924\u094d\u092a\u093e\u0926 \u092f\u093e \u0938\u0947\u0935\u093e \u0939\u0948 \u0915\u093f \u0916\u0930\u0940\u0926\u093e \u0939\u0948, \u092c\u0947\u091a\u093e \u092f\u093e \u0938\u094d\u091f\u0949\u0915 \u092e\u0947\u0902 \u0930\u0916\u093e.", - "A logical Warehouse against which stock entries are made.": "\u090f\u0915 \u0924\u093e\u0930\u094d\u0915\u093f\u0915 \u0935\u0947\u092f\u0930\u0939\u093e\u0909\u0938 \u0915\u0947 \u0916\u093f\u0932\u093e\u092b \u091c\u094b \u0936\u0947\u092f\u0930 \u092a\u094d\u0930\u0935\u093f\u0937\u094d\u091f\u093f\u092f\u094b\u0902 \u092c\u0928\u093e \u0930\u0939\u0947 \u0939\u0948\u0902.", - "Aggregate group of **Items** into another **Item**. This is useful if you are bundling a certain **Items** into a package and you maintain stock of the packed **Items** and not the aggregate **Item**. The package **Item** will have \"Is Stock Item\" as \"No\" and \"Is Sales Item\" as \"Yes\".For Example: If you are selling Laptops and Backpacks separately and have a special price if the customer buys both, then the Laptop + Backpack will be a new Sales BOM Item.Note: BOM = Bill of Materials": "** \u0906\u0907\u091f\u092e \u0915\u0947 \u0938\u0915\u0932 \u0938\u092e\u0942\u0939 \u092e\u0947\u0902 \u090f\u0915 \u0914\u0930 \u0906\u0907\u091f\u092e ** **. \u092f\u0939 \u0909\u092a\u092f\u094b\u0917\u0940 \u0939\u0948 \u0905\u0917\u0930 \u0906\u092a \u090f\u0915 \u092a\u0948\u0915\u0947\u091c \u092e\u0947\u0902 ** \u0915\u0941\u091b ** \u0906\u0907\u091f\u092e bundling \u0939\u0948\u0902 \u0914\u0930 \u0906\u092a \u092a\u0948\u0915 ** \u0914\u0930 \u0928\u0939\u0940\u0902 \u0915\u0941\u0932 ** \u0906\u0907\u091f\u092e ** ** \u0906\u0907\u091f\u092e \u0915\u0947 \u0938\u094d\u091f\u0949\u0915 \u0915\u094b \u092c\u0928\u093e\u090f \u0930\u0916\u0928\u0947. \u092a\u0948\u0915\u0947\u091c ** \u0906\u0907\u091f\u092e ** \u0939\u0948 "\u0938\u094d\u091f\u0949\u0915 \u0906\u0907\u091f\u092e \u0939\u0948" "\u0928\u0939\u0940\u0902" \u0915\u0947 \u0930\u0942\u092a \u092e\u0947\u0902 \u0914\u0930 \u0915\u0947 \u0930\u0942\u092a \u092e\u0947\u0902 "\u0939\u093e\u0901" "\u092c\u093f\u0915\u094d\u0930\u0940 \u0906\u0907\u091f\u092e \u0939\u0948," \u0909\u0926\u093e\u0939\u0930\u0923 \u0915\u0947 \u0932\u093f\u090f: \u092f\u0926\u093f \u0906\u092a \u0932\u0948\u092a\u091f\u0949\u092a \u0914\u0930 Backpacks \u092c\u0947\u091a \u0930\u0939\u0947 \u0939\u0948\u0902 \u0914\u0930 \u0905\u0932\u0917 \u0938\u0947 \u090f\u0915 \u0935\u093f\u0936\u0947\u0937 \u092e\u0942\u0932\u094d\u092f \u0939\u0948 \u0905\u0917\u0930 \u0917\u094d\u0930\u093e\u0939\u0915 \u0926\u094b\u0928\u094b\u0902 \u0916\u0930\u0940\u0926\u0924\u093e BOM = \u0935\u093f\u0927\u0947\u092f\u0915 \u0915\u0940 \u0938\u093e\u092e\u0917\u094d\u0930\u0940:, \u0924\u094b \u090f\u0915 \u0928\u092f\u093e \u0932\u0948\u092a\u091f\u0949\u092a + \u092c\u0948\u0917 \u092c\u093f\u0915\u094d\u0930\u0940 \u092c\u0940\u0913\u090f\u092e Item.Note \u0939\u094b\u0917\u093e", - "Distinct unit of an Item": "\u090f\u0915 \u0906\u0907\u091f\u092e \u0915\u0940 \u0905\u0932\u0917 \u0907\u0915\u093e\u0908", - "Featured Item in Item Group": "\u0906\u0907\u091f\u092e \u0938\u092e\u0942\u0939 \u092e\u0947\u0902 \u091a\u093f\u0924\u094d\u0930\u093f\u0924 \u0906\u0907\u091f\u092e", - "For the convenience of customers, these codes can be used in print formats like Invoices and Delivery Notes": "\u0917\u094d\u0930\u093e\u0939\u0915\u094b\u0902 \u0915\u0940 \u0938\u0941\u0935\u093f\u0927\u093e \u0915\u0947 \u0932\u093f\u090f \u0907\u0928 \u0915\u094b\u0921 \u092a\u094d\u0930\u093f\u0902\u091f \u0938\u094d\u0935\u0930\u0942\u092a\u094b\u0902 \u092e\u0947\u0902 \u091a\u093e\u0932\u093e\u0928 \u0914\u0930 \u0935\u093f\u0924\u0930\u0923 \u0928\u094b\u091f \u0915\u0940 \u0924\u0930\u0939 \u0907\u0938\u094d\u0924\u0947\u092e\u093e\u0932 \u0915\u093f\u092f\u093e \u091c\u093e \u0938\u0915\u0924\u093e \u0939\u0948", - "Generate packing slips for packages to be delivered. Used to notify package number, package contents and its weight.": "\u0926\u093f\u092f\u093e \u091c\u093e \u0938\u0902\u0915\u0941\u0932 \u0915\u0947 \u0932\u093f\u090f \u0928\u093f\u0915\u0932 \u091c\u093e\u0924\u093e \u0939\u0948 \u092a\u0948\u0915\u093f\u0902\u0917 \u0909\u0924\u094d\u092a\u0928\u094d\u0928 \u0915\u0930\u0924\u093e \u0939\u0948. \u092a\u0948\u0915\u0947\u091c \u0938\u0902\u0916\u094d\u092f\u093e, \u092a\u0948\u0915\u0947\u091c \u0938\u093e\u092e\u0917\u094d\u0930\u0940 \u0914\u0930 \u0905\u092a\u0928\u0947 \u0935\u091c\u0928 \u0915\u094b \u0938\u0942\u091a\u093f\u0924 \u0915\u0930\u0928\u0947 \u0915\u0947 \u0932\u093f\u090f \u0915\u093f\u092f\u093e \u091c\u093e\u0924\u093e \u0939\u0948.", - "Item-Wise Price List": "\u0906\u0907\u091f\u092e \u0935\u093e\u0930 \u092e\u0942\u0932\u094d\u092f \u0938\u0942\u091a\u0940", - "Ordered Items To Be Delivered": "\u0939\u093f\u0938\u093e\u092c \u0938\u0947 \u0926\u093f\u092f\u093e \u091c\u093e \u0906\u0907\u091f\u092e", - "Stock Ageing": "\u0938\u094d\u091f\u0949\u0915 \u092c\u0942\u0922\u093c\u0947", - "Stock Analytics": "\u0938\u094d\u091f\u0949\u0915 \u0935\u093f\u0936\u094d\u0932\u0947\u0937\u093f\u0915\u0940", - "Stock Balance": "\u092c\u093e\u0915\u0940 \u0938\u094d\u091f\u093e\u0915", - "Stock Home": "\u0938\u094d\u091f\u0949\u0915 \u0939\u094b\u092e", - "Stock Ledger": "\u0938\u094d\u091f\u0949\u0915 \u0932\u0947\u091c\u0930", - "Stock Level": "\u0938\u094d\u091f\u0949\u0915 \u0938\u094d\u0924\u0930", - "Table for Item that will be shown in Web Site": "\u091f\u0947\u092c\u0932 \u0906\u0907\u091f\u092e \u0915\u0947 \u0932\u093f\u090f \u0939\u0948 \u0915\u093f \u0935\u0947\u092c \u0938\u093e\u0907\u091f \u092e\u0947\u0902 \u0926\u093f\u0916\u093e\u092f\u093e \u091c\u093e\u090f\u0917\u093e" -} \ No newline at end of file diff --git a/support/module_def/support/locale/_messages_doc.json b/support/module_def/support/locale/_messages_doc.json deleted file mode 100644 index 42c31f02b1..0000000000 --- a/support/module_def/support/locale/_messages_doc.json +++ /dev/null @@ -1,5 +0,0 @@ -[ - "Create and Send Newsletters", - "Support Analytics", - "Support Home" -] \ No newline at end of file diff --git a/support/module_def/support/locale/hi-doc.json b/support/module_def/support/locale/hi-doc.json deleted file mode 100644 index 8994af41b2..0000000000 --- a/support/module_def/support/locale/hi-doc.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "Create and Send Newsletters": "\u0938\u092e\u093e\u091a\u093e\u0930\u092a\u0924\u094d\u0930\u093f\u0915\u093e\u090f\u0901 \u092c\u0928\u093e\u090f\u0901 \u0914\u0930 \u092d\u0947\u091c\u0947\u0902", - "Support Analytics": "\u0938\u092e\u0930\u094d\u0925\u0928 \u0935\u093f\u0936\u094d\u0932\u0947\u0937\u093f\u0915\u0940", - "Support Home": "\u0938\u092e\u0930\u094d\u0925\u0928 \u092e\u0941\u0916" -} \ No newline at end of file diff --git a/utilities/module_def/utilities/locale/_messages_doc.json b/utilities/module_def/utilities/locale/_messages_doc.json deleted file mode 100644 index 9289abe2b8..0000000000 --- a/utilities/module_def/utilities/locale/_messages_doc.json +++ /dev/null @@ -1,11 +0,0 @@ -[ - "Users", - "To Do", - "Markdown Reference", - "Messages", - "question-view", - "WIP Monitor", - "questions", - "Calendar", - "Trash" -] \ No newline at end of file diff --git a/utilities/module_def/utilities/locale/hi-doc.json b/utilities/module_def/utilities/locale/hi-doc.json deleted file mode 100644 index 4a7d1cdc90..0000000000 --- a/utilities/module_def/utilities/locale/hi-doc.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "Calendar": "\u0915\u0948\u0932\u0947\u0902\u0921\u0930", - "Markdown Reference": "Markdown \u0938\u0902\u0926\u0930\u094d\u092d", - "Messages": "\u0938\u0902\u0926\u0947\u0936", - "To Do": "\u0915\u0930\u0928\u0947 \u0915\u0947 \u0932\u093f\u090f \u0915\u094d\u092f\u093e", - "Trash": "\u0915\u091a\u0930\u093e \u092a\u0947\u091f\u0940", - "Users": "\u0909\u092a\u092f\u094b\u0917\u0915\u0930\u094d\u0924\u093e", - "WIP Monitor": "WIP \u092e\u0949\u0928\u093f\u091f\u0930", - "question-view": "\u0938\u0935\u093e\u0932 \u0926\u0943\u0936\u094d\u092f", - "questions": "\u0938\u0935\u093e\u0932\u094b\u0902" -} \ No newline at end of file diff --git a/utilities/page/trash/trash.txt b/utilities/page/trash/trash.txt index 4be9065e82..a13e1b6ac7 100644 --- a/utilities/page/trash/trash.txt +++ b/utilities/page/trash/trash.txt @@ -9,7 +9,6 @@ { "name": "__common__", "module": "Utilities", - "show_in_menu": 0, "page_name": "Trash", "doctype": "Page", "standard": "Yes" diff --git a/website/module_def/website/locale/_messages_doc.json b/website/module_def/website/locale/_messages_doc.json deleted file mode 100644 index 7e41f2b659..0000000000 --- a/website/module_def/website/locale/_messages_doc.json +++ /dev/null @@ -1,15 +0,0 @@ -[ - "Settings for Product Catalog on the website", - "", - "Settings for Contact Us Page", - "Cross Listing of Item in multiple groups", - "A Product is shown on the website and is linked to an item.", - "Product Category for website", - "Slideshow like display for the website", - "Page to show on the website", - "Settings for the About Us Page", - "Website Home", - "Unsubscribe", - "Set your background color, font and image (tiled)", - "Script to attach to all web pages." -] \ No newline at end of file diff --git a/website/module_def/website/locale/hi-doc.json b/website/module_def/website/locale/hi-doc.json deleted file mode 100644 index de0957c6ff..0000000000 --- a/website/module_def/website/locale/hi-doc.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "A Product is shown on the website and is linked to an item.": "\u090f\u0915 \u0909\u0924\u094d\u092a\u093e\u0926 \u0915\u0940 \u0935\u0947\u092c\u0938\u093e\u0907\u091f \u092a\u0930 \u0926\u093f\u0916\u093e\u092f\u093e \u091c\u093e\u0924\u093e \u0939\u0948 \u0914\u0930 \u090f\u0915 \u0906\u0907\u091f\u092e \u0915\u0947 \u0932\u093f\u090f \u091c\u0941\u0921\u093c\u093e \u0939\u0941\u0906 \u0939\u0948.", - "Cross Listing of Item in multiple groups": "\u0915\u0908 \u0938\u092e\u0942\u0939\u094b\u0902 \u092e\u0947\u0902 \u0906\u0907\u091f\u092e \u0932\u093f\u0938\u094d\u091f\u093f\u0902\u0917 \u092a\u093e\u0930", - "Page to show on the website": "\u0935\u0947\u092c\u0938\u093e\u0907\u091f \u092a\u0930 \u0926\u093f\u0916\u093e\u0928\u0947 \u0915\u0947 \u0932\u093f\u090f", - "Product Category for website": "\u0935\u0947\u092c\u0938\u093e\u0907\u091f \u0915\u0947 \u0932\u093f\u090f \u0909\u0924\u094d\u092a\u093e\u0926 \u0936\u094d\u0930\u0947\u0923\u0940", - "Script to attach to all web pages.": "\u0938\u094d\u0915\u094d\u0930\u093f\u092a\u094d\u091f \u0938\u092d\u0940 \u0935\u0947\u092c \u092a\u0943\u0937\u094d\u0920\u094b\u0902 \u0915\u0947 \u0932\u093f\u090f \u0926\u0947\u0924\u0947 \u0939\u0948\u0902.", - "Set your background color, font and image (tiled)": "\u0905\u092a\u0928\u0940 \u092a\u0943\u0937\u094d\u0920\u092d\u0942\u092e\u093f \u0930\u0902\u0917, \u092b\u093c\u0949\u0928\u094d\u091f \u0914\u0930 \u091b\u0935\u093f (\u091f\u093e\u0907\u0932\u094b\u0902) \u0938\u0947\u091f", - "Settings for Contact Us Page": "\u0939\u092e\u0938\u0947 \u0938\u0902\u092a\u0930\u094d\u0915 \u0915\u0930\u0947\u0902 \u092a\u0943\u0937\u094d\u0920 \u0915\u0947 \u0932\u093f\u090f \u0938\u0947\u091f\u093f\u0902\u0917\u094d\u0938", - "Settings for Product Catalog on the website": "\u0935\u0947\u092c\u0938\u093e\u0907\u091f \u092a\u0930 \u0909\u0924\u094d\u092a\u093e\u0926 \u0915\u0948\u091f\u0932\u0949\u0917 \u0915\u0947 \u0932\u093f\u090f \u0938\u0947\u091f\u093f\u0902\u0917\u094d\u0938", - "Settings for the About Us Page": "\u0939\u092e\u093e\u0930\u0947 \u092c\u093e\u0930\u0947 \u092e\u0947\u0902 \u092a\u0943\u0937\u094d\u0920 \u0915\u0947 \u0932\u093f\u090f \u0938\u0947\u091f\u093f\u0902\u0917\u094d\u0938", - "Slideshow like display for the website": "\u0935\u0947\u092c\u0938\u093e\u0907\u091f \u0915\u0947 \u0932\u093f\u090f \u092a\u094d\u0930\u0926\u0930\u094d\u0936\u0928 \u0915\u0940 \u0924\u0930\u0939 \u0938\u094d\u0932\u093e\u0907\u0921 \u0936\u094b", - "Unsubscribe": "\u0938\u0926\u0938\u094d\u092f\u0924\u093e \u0930\u0926\u094d\u0926 \u0915\u0930\u0947\u0902", - "Website Home": "\u0935\u0947\u092c\u0938\u093e\u0907\u091f \u0915\u0947 \u0939\u094b\u092e" -} \ No newline at end of file From 64d7c4b2d56db4698ab1dd590f755a7e6bb0b215 Mon Sep 17 00:00:00 2001 From: Nabin Hait Date: Thu, 17 Jan 2013 12:22:59 +0530 Subject: [PATCH 02/11] fixes in get_incoming_rate --- stock/utils.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/stock/utils.py b/stock/utils.py index e7702a89fd..46dd9d01a9 100644 --- a/stock/utils.py +++ b/stock/utils.py @@ -111,7 +111,7 @@ def get_fifo_rate(previous_stock_queue, qty): else: outgoing_cost = 0 qty_to_pop = abs(qty) - while qty_to_pop: + while qty_to_pop and previous_stock_queue: batch = previous_stock_queue[0] if 0 < batch[0] <= qty_to_pop: # if batch qty > 0 @@ -124,8 +124,8 @@ def get_fifo_rate(previous_stock_queue, qty): outgoing_cost += flt(qty_to_pop) * flt(batch[1]) batch[0] -= qty_to_pop qty_to_pop = 0 - - return outgoing_cost / abs(qty) + # if queue gets blank and qty_to_pop remaining, get average rate of full queue + return outgoing_cost / abs(qty) - qty_to_pop def get_valid_serial_nos(sr_nos, qty=0, item_code=''): """split serial nos, validate and return list of valid serial nos""" From 35b6d94c0660c82c2db43c5346621ea7580acb62 Mon Sep 17 00:00:00 2001 From: Nabin Hait Date: Thu, 17 Jan 2013 12:31:09 +0530 Subject: [PATCH 03/11] automatic purchase request from production planning tool --- .../production_plan_item.txt | 4 +- .../production_planning_tool.py | 125 ++++++++++-------- .../production_planning_tool.txt | 11 +- 3 files changed, 84 insertions(+), 56 deletions(-) diff --git a/manufacturing/doctype/production_plan_item/production_plan_item.txt b/manufacturing/doctype/production_plan_item/production_plan_item.txt index 6ae2a04f5a..2cb2a59f8b 100644 --- a/manufacturing/doctype/production_plan_item/production_plan_item.txt +++ b/manufacturing/doctype/production_plan_item/production_plan_item.txt @@ -2,9 +2,9 @@ { "owner": "Administrator", "docstatus": 0, - "creation": "2012-12-20 18:14:55", + "creation": "2013-01-16 14:48:56", "modified_by": "Administrator", - "modified": "2012-12-24 19:37:34" + "modified": "2013-01-17 11:21:46" }, { "istable": 1, diff --git a/manufacturing/doctype/production_planning_tool/production_planning_tool.py b/manufacturing/doctype/production_planning_tool/production_planning_tool.py index fa08789b91..a6c8458f3f 100644 --- a/manufacturing/doctype/production_planning_tool/production_planning_tool.py +++ b/manufacturing/doctype/production_planning_tool/production_planning_tool.py @@ -16,7 +16,7 @@ from __future__ import unicode_literals import webnotes -from webnotes.utils import cstr, flt, nowdate +from webnotes.utils import cstr, flt, cint, nowdate, add_days from webnotes.model.doc import addchild, Document from webnotes.model.wrapper import getlist from webnotes.model.code import get_obj @@ -275,7 +275,6 @@ class DocType: and bom_item.item_code = item.name group by item_code """, (flt(bom_dict[bom]), bom)) - self.make_items_dict(fl_bom_items) def make_items_dict(self, item_list): @@ -301,60 +300,82 @@ class DocType: return item_list def raise_purchase_request(self): - def _get_projected_qty(items): - item_projected_qty = webnotes.conn.sql("""select item_code, sum(projected_qty) - from `tabBin` where item_code in (%s) group by item_code""" % - (", ".join(["%s"]*len(items)),), tuple(items)) - - return dict(item_projected_qty) + """ + Raise Purchase Request if projected qty is less than qty required + Requested qty should be shortage qty considering minimum order qty + """ + if not self.doc.purchase_request_for_warehouse: + webnotes.msgprint("Please enter Warehouse for which Purchase Request will be raised", + raise_exception=1) - item_dict = self.get_raw_materials() - item_projected_qty = _get_projected_qty(item_dict.keys()) + bom_dict = self.get_distinct_items_and_boms()[0] + self.get_raw_materials(bom_dict) + item_projected_qty = self.get_projected_qty() from accounts.utils import get_fiscal_year - fiscal_year = get_fiscal_year(nowdate()) + fiscal_year = get_fiscal_year(nowdate())[0] - items_to_be_requested = [] - for item in item_dict: - if flt(item_dict[item][0]) > item_projected_qty[item]: + items_to_be_requested = webnotes._dict() + for item in self.item_dict: + if flt(self.item_dict[item][0]) > item_projected_qty[item]: # shortage - requested_qty = flt(item_dict[item][0]) - item_projected_qty[item] + requested_qty = flt(self.item_dict[item][0]) - item_projected_qty[item] # comsider minimum order qty - requested_qty = requested_qty > flt(item_dict[item][3]) and \ - requested_qty or flt(item_dict[item][3]) - items_to_be_requested.append({ - "item_code": item, - "qty": requested_qty, - "description": item_dict[item][1], - "stock_uom": item_dict[item][2] - }) - webnotes.errprint(items_to_be_requested) - self.insert_purchase_request(items_to_be_requested, fiscal_year) + requested_qty = requested_qty > flt(self.item_dict[item][3]) and \ + requested_qty or flt(self.item_dict[item][3]) + items_to_be_requested[item] = requested_qty - def insert_purchase_request(self, items, fiscal_year): - for item in items: - item_wrapper = webnotes.model_wrapper("Item", args.item_code) - pr = [ - { - "doctype": "Purchase Request", - "naming_series": "IDT", - "transaction_date": nowdate(), - "status": "Draft", - "company": self.doc.company, - "fiscal_year": fiscal_year, - "requested_by": webnotes.session.user, - "remark": "Automatically raised from Production Planning Tool" - }, - { - "doctype": "Purchase Request Item", - "item_code": item.item_code, - "item_name": item_wrapper.doc.item_name, - "description": item.description, - "uom": item.stock_uom, - "item_group": item_wrapper.doc.item_group, - "brand": item_wrapper.doc.brand, - "qty": item.qty, - - - } - ] \ No newline at end of file + self.insert_purchase_request(items_to_be_requested, fiscal_year) + + def get_projected_qty(self): + items = self.item_dict.keys() + item_projected_qty = webnotes.conn.sql("""select item_code, sum(projected_qty) + from `tabBin` where item_code in (%s) group by item_code""" % + (", ".join(["%s"]*len(items)),), tuple(items)) + + return dict(item_projected_qty) + + def insert_purchase_request(self, items_to_be_requested, fiscal_year): + purchase_request_list = [] + if items_to_be_requested: + for item in items_to_be_requested: + item_wrapper = webnotes.model_wrapper("Item", item) + pr_doclist = [ + { + "doctype": "Purchase Request", + "__islocal": 1, + "naming_series": "IDT", + "transaction_date": nowdate(), + "status": "Draft", + "company": self.doc.company, + "fiscal_year": fiscal_year, + "requested_by": webnotes.session.user, + "remark": "Automatically raised from Production Planning Tool" + }, + { + "doctype": "Purchase Request Item", + "__islocal": 1, + "parentfield": "indent_details", + "item_code": item, + "item_name": item_wrapper.doc.item_name, + "description": item_wrapper.doc.description, + "uom": item_wrapper.doc.stock_uom, + "item_group": item_wrapper.doc.item_group, + "brand": item_wrapper.doc.brand, + "qty": items_to_be_requested[item], + "schedule_date": add_days(nowdate(), cint(item_wrapper.doc.lead_time_days)), + "warehouse": self.doc.purchase_request_for_warehouse + } + ] + pr_wrapper = webnotes.model_wrapper(pr_doclist) + pr_wrapper.ignore_permissions = 1 + pr_wrapper.submit() + purchase_request_list.append(pr_wrapper.doc.name) + + if purchase_request_list: + pur_req = ["""%s""" % \ + (p, p) for p in purchase_request_list] + webnotes.msgprint("Following Purchase Request created successfully: \n%s" % + "\n".join(pur_req)) + else: + webnotes.msgprint("Nothing to request") \ No newline at end of file diff --git a/manufacturing/doctype/production_planning_tool/production_planning_tool.txt b/manufacturing/doctype/production_planning_tool/production_planning_tool.txt index 7eb0a2da11..d4a0d94774 100644 --- a/manufacturing/doctype/production_planning_tool/production_planning_tool.txt +++ b/manufacturing/doctype/production_planning_tool/production_planning_tool.txt @@ -4,7 +4,7 @@ "docstatus": 0, "creation": "2013-01-16 14:48:56", "modified_by": "Administrator", - "modified": "2013-01-16 15:46:26" + "modified": "2013-01-17 11:39:55" }, { "read_only": 1, @@ -199,7 +199,14 @@ "fieldtype": "Column Break" }, { - "description": "Raise Purchase Request automatically for items which are \"Out of Stock\" considering already requested, already ordered qty and minimum order qty", + "doctype": "DocField", + "label": "Purchase Request For Warehouse", + "fieldname": "purchase_request_for_warehouse", + "fieldtype": "Link", + "options": "Warehouse" + }, + { + "description": "Items to be requested which are \"Out of Stock\" considering all warehouses based on projected qty and minimum order qty", "doctype": "DocField", "label": "Raise Purchase Request", "fieldname": "raise_purchase_request", From feee2520933ca46e5934eef91d1a9776f95c32fe Mon Sep 17 00:00:00 2001 From: Nabin Hait Date: Thu, 17 Jan 2013 13:03:30 +0530 Subject: [PATCH 04/11] fixes in website page_name for item --- stock/doctype/item/item.py | 2 +- website/utils.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/stock/doctype/item/item.py b/stock/doctype/item/item.py index 38ff797291..cca814ff08 100644 --- a/stock/doctype/item/item.py +++ b/stock/doctype/item/item.py @@ -77,7 +77,7 @@ class DocType: def update_website(self): from website.utils import update_page_name - update_page_name(self.doc, self.doc.item_name) + update_page_name(self.doc, self.doc.name + " " + self.doc.item_name) from website.helpers.product import invalidate_cache_for invalidate_cache_for(self.doc.item_group) diff --git a/website/utils.py b/website/utils.py index 96fbdc8dc9..4dafd08c05 100644 --- a/website/utils.py +++ b/website/utils.py @@ -97,7 +97,7 @@ def page_name(title): import re name = title.lower() name = re.sub('[~!@#$%^&*()<>,."\']', '', name) - return '-'.join(name.split()[:8]) + return '-'.join(name.split()) def update_page_name(doc, title): """set page_name and check if it is unique""" From 80c681294ca12b17e399054e98930ab82fd2554a Mon Sep 17 00:00:00 2001 From: Nabin Hait Date: Thu, 17 Jan 2013 13:24:51 +0530 Subject: [PATCH 05/11] fixes in website page naming --- website/utils.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/website/utils.py b/website/utils.py index 4dafd08c05..6963b76f5a 100644 --- a/website/utils.py +++ b/website/utils.py @@ -97,7 +97,14 @@ def page_name(title): import re name = title.lower() name = re.sub('[~!@#$%^&*()<>,."\']', '', name) - return '-'.join(name.split()) + name = re.sub('[:/]', '-', name) + + name = '-'.join(name.split()) + + # replace repeating hyphens + name = re.sub(r"(-)\1+", r"\1", name) + + return name def update_page_name(doc, title): """set page_name and check if it is unique""" From 1b4f56c57f6ee646f4148e428e926c725bad3fb6 Mon Sep 17 00:00:00 2001 From: Nabin Hait Date: Thu, 17 Jan 2013 17:01:51 +0530 Subject: [PATCH 06/11] fixes in c-form --- accounts/doctype/c_form/c_form.py | 80 +++++++++++----------- stock/doctype/packing_slip/packing_slip.py | 5 +- stock/stock_ledger.py | 11 ++- 3 files changed, 45 insertions(+), 51 deletions(-) diff --git a/accounts/doctype/c_form/c_form.py b/accounts/doctype/c_form/c_form.py index a1cc9e8373..bff68f7c1c 100644 --- a/accounts/doctype/c_form/c_form.py +++ b/accounts/doctype/c_form/c_form.py @@ -18,11 +18,7 @@ from __future__ import unicode_literals import webnotes from webnotes.utils import flt, getdate from webnotes.model.doc import make_autoname -from webnotes.model.wrapper import getlist, copy_doclist -from webnotes import msgprint - -sql = webnotes.conn.sql - +from webnotes.model.wrapper import getlist class DocType: def __init__(self,d,dl): @@ -31,53 +27,57 @@ class DocType: def autoname(self): self.doc.name = make_autoname(self.doc.naming_series + '.#####') + def validate(self): + """Validate invoice that c-form is applicable + and no other c-form is received for that""" + + for d in getlist(self.doclist, 'invoice_details'): + inv = webnotes.conn.sql("""select c_form_applicable, c_form_no from + `tabSales Invoice` where name = %s""", d.invoice_no) + + if not inv: + webnotes.msgprint("Invoice: %s is not exists in the system, please check." % + d.invoice_no, raise_exception=1) + + elif inv[0][0] != 'Yes': + webnotes.msgprint("C-form is not applicable for Invoice: %s" % + d.invoice_no, raise_exception=1) + + elif inv[0][1] and inv[0][1] != self.doc.name: + webnotes.msgprint("""Invoice %s is tagged in another C-form: %s. + If you want to change C-form no for this invoice, + please remove invoice no from the previous c-form and then try again""" % + (d.invoice_no, inv[0][1]), raise_exception=1) def on_update(self): """ Update C-Form No on invoices""" - - if len(getlist(self.doclist, 'invoice_details')): - inv = "'" + "', '".join([d.invoice_no for d in getlist(self.doclist, 'invoice_details')]) + "'" - sql("""update `tabSales Invoice` set c_form_no = '%s', modified ='%s' - where name in (%s)"""%(self.doc.name, self.doc.modified, inv)) - sql("""update `tabSales Invoice` set c_form_no = '', modified = %s where name not - in (%s) and ifnull(c_form_no, '') = %s""", (self.doc.modified, self.doc.name, inv)) + inv = [d.invoice_no for d in getlist(self.doclist, 'invoice_details')] + if inv: + webnotes.conn.sql("""update `tabSales Invoice` set c_form_no=%s, modified=%s + where name in (%s)""" % ('%s', '%s', ', '.join(['%s'] * len(inv))), + tuple([self.doc.name, self.doc.modified] + inv), debug=1) + + webnotes.conn.sql("""update `tabSales Invoice` set c_form_no = '', modified = %s + where name not in (%s) and ifnull(c_form_no, '') = %s""" % + ('%s', ', '.join(['%s'*len(inv)]), '%s'), + tuple([self.doc.modified] + inv + [self.doc.name]), debug=1) else: - msgprint("Please enter atleast 1 invoice in the table below", raise_exception=1) + webnotes.msgprint("Please enter atleast 1 invoice in the table", raise_exception=1) - self.calculate_total_invoiced_amount() + self.set_total_invoiced_amount() - def calculate_total_invoiced_amount(self): - total = 0 - for d in getlist(self.doclist, 'invoice_details'): - total += flt(d.grand_total) + def set_total_invoiced_amount(self): + total = sum([flt(d.total) for d in getlist(self.doclist, 'invoice_details')]) webnotes.conn.set(self.doc, 'total_invoiced_amount', total) - def get_invoice_details(self, invoice_no): """ Pull details from invoices for referrence """ - inv = sql("""select posting_date, territory, net_total, grand_total from - `tabSales Invoice` where name = %s""", invoice_no) - ret = { + inv = webnotes.conn.sql("""select posting_date, territory, net_total, grand_total + from `tabSales Invoice` where name = %s""", invoice_no) + return { 'invoice_date' : inv and getdate(inv[0][0]).strftime('%Y-%m-%d') or '', 'territory' : inv and inv[0][1] or '', 'net_total' : inv and flt(inv[0][2]) or '', 'grand_total' : inv and flt(inv[0][3]) or '' - } - return ret - - - def validate_invoice(self): - """Validate invoice that c-form is applicable and no other c-form is - received for that""" - - for d in getlist(self.doclist, 'invoice_details'): - inv = sql("""select c_form_applicable, c_form_no from - `tabSales Invoice` where name = %s""", invoice_no) - if not inv: - msgprint("Invoice: %s is not exists in the system, please check." % d.invoice_no, raise_exception=1) - elif inv[0][0] != 'Yes': - msgprint("C-form is not applicable for Invoice: %s" % d.invoice_no, raise_exception=1) - elif inv[0][1] and inv[0][1] != self.doc.name: - msgprint("""Invoice %s is tagged in another C-form: %s. \nIf you want to change C-form no for this invoice, - please remove invoice no from the previous c-form and then try again""" % (d.invoice_no, inv[0][1]), raise_exception=1) + } \ No newline at end of file diff --git a/stock/doctype/packing_slip/packing_slip.py b/stock/doctype/packing_slip/packing_slip.py index 7ef7d367a0..b90b0e6c76 100644 --- a/stock/doctype/packing_slip/packing_slip.py +++ b/stock/doctype/packing_slip/packing_slip.py @@ -117,7 +117,7 @@ class DocType: from `tabDelivery Note Item` dni where parent=%s and item_code in (%s) group by item_code""" % ("%s", ", ".join(["%s"]*len(items))), - tuple([self.doc.delivery_note] + items), as_dict=1, debug=1) + tuple([self.doc.delivery_note] + items), as_dict=1) ps_item_qty = dict([[d.item_code, d.qty] for d in self.doclist]) @@ -170,9 +170,6 @@ class DocType: webnotes.msgprint("Invalid new packed quantity for item %s. \ Please try again or contact support@erpnext.com" % item['item_code'], raise_exception=1) - delivery_note_item = webnotes.conn.get_value("Delivery Note Item", { - "parent": self.doc.delivery_note, "item_code": item["item_code"]}) - webnotes.conn.sql("""\ UPDATE `tabDelivery Note Item` SET packed_qty = %s diff --git a/stock/stock_ledger.py b/stock/stock_ledger.py index ffb6692df9..26f03c6478 100644 --- a/stock/stock_ledger.py +++ b/stock/stock_ledger.py @@ -54,16 +54,13 @@ def update_entries_after(args, verbose=1): if not validate_negative_stock(qty_after_transaction, sle): qty_after_transaction += flt(sle.actual_qty) continue - + if sle.serial_no: - valuation_rate = get_serialized_values(qty_after_transaction, sle, - valuation_rate) + valuation_rate = get_serialized_values(qty_after_transaction, sle, valuation_rate) elif valuation_method == "Moving Average": - valuation_rate = get_moving_average_values(qty_after_transaction, sle, - valuation_rate) + valuation_rate = get_moving_average_values(qty_after_transaction, sle, valuation_rate) else: - valuation_rate = get_fifo_values(qty_after_transaction, sle, - stock_queue) + valuation_rate = get_fifo_values(qty_after_transaction, sle, stock_queue) qty_after_transaction += flt(sle.actual_qty) From 144ba186d3f2deacf7a38639dff7fa864dc591ed Mon Sep 17 00:00:00 2001 From: Nabin Hait Date: Thu, 17 Jan 2013 17:20:08 +0530 Subject: [PATCH 07/11] fixes in c-form --- accounts/doctype/c_form/c_form.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/accounts/doctype/c_form/c_form.py b/accounts/doctype/c_form/c_form.py index bff68f7c1c..1bea635c92 100644 --- a/accounts/doctype/c_form/c_form.py +++ b/accounts/doctype/c_form/c_form.py @@ -59,7 +59,7 @@ class DocType: webnotes.conn.sql("""update `tabSales Invoice` set c_form_no = '', modified = %s where name not in (%s) and ifnull(c_form_no, '') = %s""" % - ('%s', ', '.join(['%s'*len(inv)]), '%s'), + ('%s', ', '.join(['%s']*len(inv)), '%s'), tuple([self.doc.modified] + inv + [self.doc.name]), debug=1) else: webnotes.msgprint("Please enter atleast 1 invoice in the table", raise_exception=1) From a81010a5b31e202abd1dcbe77c43f0c8b9be8e49 Mon Sep 17 00:00:00 2001 From: Nabin Hait Date: Thu, 17 Jan 2013 17:25:55 +0530 Subject: [PATCH 08/11] removed debug mode --- accounts/doctype/c_form/c_form.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/accounts/doctype/c_form/c_form.py b/accounts/doctype/c_form/c_form.py index 1bea635c92..4575653699 100644 --- a/accounts/doctype/c_form/c_form.py +++ b/accounts/doctype/c_form/c_form.py @@ -55,12 +55,12 @@ class DocType: if inv: webnotes.conn.sql("""update `tabSales Invoice` set c_form_no=%s, modified=%s where name in (%s)""" % ('%s', '%s', ', '.join(['%s'] * len(inv))), - tuple([self.doc.name, self.doc.modified] + inv), debug=1) + tuple([self.doc.name, self.doc.modified] + inv)) webnotes.conn.sql("""update `tabSales Invoice` set c_form_no = '', modified = %s where name not in (%s) and ifnull(c_form_no, '') = %s""" % ('%s', ', '.join(['%s']*len(inv)), '%s'), - tuple([self.doc.modified] + inv + [self.doc.name]), debug=1) + tuple([self.doc.modified] + inv + [self.doc.name])) else: webnotes.msgprint("Please enter atleast 1 invoice in the table", raise_exception=1) From db7139a6496ba60e4227cfe2f6231cfd20228124 Mon Sep 17 00:00:00 2001 From: Rushabh Mehta Date: Thu, 17 Jan 2013 18:22:22 +0530 Subject: [PATCH 09/11] started fresh install and added country_info --- accounts/doctype/account/account.txt | 86 ++- accounts/doctype/gl_control/gl_control.py | 2 +- .../journal_voucher/journal_voucher.js | 2 - .../journal_voucher/journal_voucher.txt | 61 +- .../purchase_invoice/purchase_invoice.js | 1 - .../doctype/sales_invoice/sales_invoice.js | 1 - .../voucher_wise_tax_details.js | 2 +- buying/doctype/supplier/supplier.py | 9 +- .../january_2013/change_patch_structure.py | 12 + patches/january_2013/update_country_info.py | 27 + .../reset_appraisal_permissions.py | 4 +- .../custom_script_delete_permission.py | 8 +- patches/patch_list.py | 716 ++++-------------- public/js/complete_setup.js | 412 +--------- public/js/queries.js | 4 +- selling/doctype/customer/customer.py | 7 +- selling/doctype/quotation/quotation.js | 2 +- setup/doctype/company/company.py | 3 +- setup/doctype/country/country.txt | 55 +- setup/doctype/currency/currency.txt | 85 ++- setup/doctype/setup_control/setup_control.py | 74 +- startup/install.py | 604 ++------------- .../sales_and_purchase_return_tool.js | 1 - 23 files changed, 476 insertions(+), 1702 deletions(-) create mode 100644 patches/january_2013/change_patch_structure.py create mode 100644 patches/january_2013/update_country_info.py diff --git a/accounts/doctype/account/account.txt b/accounts/doctype/account/account.txt index c6f85e1aad..e93631bd61 100644 --- a/accounts/doctype/account/account.txt +++ b/accounts/doctype/account/account.txt @@ -2,20 +2,20 @@ { "owner": "Administrator", "docstatus": 0, - "creation": "2012-11-16 10:32:50", + "creation": "2013-01-17 12:30:10", "modified_by": "Administrator", - "modified": "2012-12-03 11:26:49" + "modified": "2013-01-17 13:16:31" }, { "in_create": 1, + "allow_rename": 1, + "description": "Heads (or groups) against which Accounting Entries are made and balances are maintained.", "search_fields": "debit_or_credit, group_or_ledger", "module": "Accounts", - "document_type": "Master", - "description": "Heads (or groups) against which Accounting Entries are made and balances are maintained.", - "name": "__common__", - "allow_rename": 1, "doctype": "DocType", - "allow_copy": 1 + "allow_copy": 1, + "document_type": "Master", + "name": "__common__" }, { "name": "__common__", @@ -28,8 +28,8 @@ "name": "__common__", "parent": "Account", "amend": 0, - "submit": 0, "doctype": "DocPerm", + "submit": 0, "read": 1, "parenttype": "DocType", "parentfield": "permissions" @@ -139,32 +139,28 @@ "doctype": "DocField", "label": "Parent Account", "oldfieldname": "parent_account", - "trigger": "Client", + "options": "Account", "fieldname": "parent_account", "fieldtype": "Link", "search_index": 1, - "options": "Account", "permlevel": 0 }, { "description": "Setting Account Type helps in selecting this Account in transactions.", "oldfieldtype": "Select", - "colour": "White:FFF", "doctype": "DocField", "label": "Account Type", "oldfieldname": "account_type", - "permlevel": 0, - "trigger": "Client", + "options": "\nFixed Asset Account\nBank or Cash\nExpense Account\nTax\nIncome Account\nChargeable", "fieldname": "account_type", "fieldtype": "Select", "search_index": 0, - "in_filter": 1, - "options": "\nFixed Asset Account\nBank or Cash\nExpense Account\nTax\nIncome Account\nChargeable" + "permlevel": 0, + "in_filter": 1 }, { "description": "Rate at which this tax is applied", "oldfieldtype": "Currency", - "colour": "White:FFF", "doctype": "DocField", "label": "Rate", "oldfieldname": "tax_rate", @@ -177,7 +173,6 @@ { "description": "If the account is frozen, entries are allowed for the \"Account Manager\" only.", "oldfieldtype": "Select", - "colour": "White:FFF", "doctype": "DocField", "label": "Frozen", "oldfieldname": "freeze_account", @@ -189,7 +184,6 @@ { "print_hide": 1, "oldfieldtype": "Int", - "colour": "White:FFF", "doctype": "DocField", "label": "Credit Days", "oldfieldname": "credit_days", @@ -212,7 +206,6 @@ { "description": "If this Account represents a Customer, Supplier or Employee, set it here.", "oldfieldtype": "Select", - "colour": "White:FFF", "doctype": "DocField", "label": "Master Type", "oldfieldname": "master_type", @@ -226,98 +219,127 @@ "doctype": "DocField", "label": "Master Name", "oldfieldname": "master_name", - "trigger": "Client", + "options": "[Select]", "fieldname": "master_name", "fieldtype": "Link", - "options": "[Select]", + "permlevel": 0 + }, + { + "read_only": 1, + "print_hide": 1, + "doctype": "DocField", + "label": "Lft", + "fieldname": "lft", + "fieldtype": "Int", + "hidden": 1, + "permlevel": 0 + }, + { + "read_only": 1, + "print_hide": 1, + "doctype": "DocField", + "label": "Rgt", + "fieldname": "rgt", + "fieldtype": "Int", + "hidden": 1, + "permlevel": 0 + }, + { + "read_only": 1, + "print_hide": 1, + "doctype": "DocField", + "label": "Old Parent", + "fieldname": "old_parent", + "fieldtype": "Data", + "hidden": 1, "permlevel": 0 }, { "create": 0, "doctype": "DocPerm", "write": 1, - "cancel": 0, "role": "Auditor", + "cancel": 0, "permlevel": 0 }, { "create": 0, "doctype": "DocPerm", "write": 0, - "cancel": 0, "role": "Auditor", + "cancel": 0, "permlevel": 2 }, { "create": 0, "doctype": "DocPerm", "write": 0, - "cancel": 0, "role": "Auditor", + "cancel": 0, "permlevel": 1 }, { "create": 0, "doctype": "DocPerm", "write": 0, - "cancel": 0, "role": "Sales User", + "cancel": 0, "permlevel": 0 }, { "create": 0, "doctype": "DocPerm", "write": 0, - "cancel": 0, "role": "Purchase User", + "cancel": 0, "permlevel": 0 }, { "create": 0, "doctype": "DocPerm", "write": 1, - "cancel": 0, "role": "Accounts User", + "cancel": 0, "permlevel": 0 }, { "create": 1, "doctype": "DocPerm", "write": 1, - "cancel": 1, "role": "Accounts Manager", + "cancel": 1, "permlevel": 0 }, { "create": 0, "doctype": "DocPerm", "write": 0, - "cancel": 0, "role": "Accounts User", + "cancel": 0, "permlevel": 1 }, { "create": 0, "doctype": "DocPerm", "write": 0, - "cancel": 0, "role": "Accounts Manager", + "cancel": 0, "permlevel": 1 }, { "create": 0, "doctype": "DocPerm", "write": 1, - "cancel": 0, "role": "Accounts Manager", + "cancel": 0, "permlevel": 2 }, { "create": 0, "doctype": "DocPerm", "write": 0, - "cancel": 0, "role": "Accounts User", + "cancel": 0, "permlevel": 2 } ] \ No newline at end of file diff --git a/accounts/doctype/gl_control/gl_control.py b/accounts/doctype/gl_control/gl_control.py index 44cab1e7a8..b33a291e1d 100644 --- a/accounts/doctype/gl_control/gl_control.py +++ b/accounts/doctype/gl_control/gl_control.py @@ -218,7 +218,7 @@ class DocType: and (t2.against_invoice is null or t2.against_invoice = '') and (t2.against_jv is null or t2.against_jv = '') and t2.account = '%s' and t2.is_advance = 'Yes' and t1.docstatus = 1 - order by t1.voucher_date """ % (dr_or_cr,account_head)) + order by t1.posting_date""" % (dr_or_cr,account_head)) # clear advance table obj.doclist = obj.doc.clear_table(obj.doclist,table_field_name) # Create advance table diff --git a/accounts/doctype/journal_voucher/journal_voucher.js b/accounts/doctype/journal_voucher/journal_voucher.js index b00fc25aed..7e1ffda973 100644 --- a/accounts/doctype/journal_voucher/journal_voucher.js +++ b/accounts/doctype/journal_voucher/journal_voucher.js @@ -15,8 +15,6 @@ // along with this program. If not, see . cur_frm.cscript.onload = function(doc, cdt, cdn) { - if (!doc.voucher_date) doc.voucher_date = dateutil.obj_to_str(new Date()); - cur_frm.cscript.load_defaults(doc, cdt, cdn); } diff --git a/accounts/doctype/journal_voucher/journal_voucher.txt b/accounts/doctype/journal_voucher/journal_voucher.txt index ad0004f829..b30c4db432 100644 --- a/accounts/doctype/journal_voucher/journal_voucher.txt +++ b/accounts/doctype/journal_voucher/journal_voucher.txt @@ -2,14 +2,14 @@ { "owner": "Administrator", "docstatus": 0, - "creation": "2012-12-03 17:26:38", + "creation": "2013-01-17 12:30:11", "modified_by": "Administrator", - "modified": "2012-12-04 18:47:42" + "modified": "2013-01-17 14:27:43" }, { - "is_submittable": 1, "autoname": "naming_series:", "name": "__common__", + "is_submittable": 1, "search_fields": "voucher_type,posting_date, due_date, cheque_no", "module": "Accounts", "doctype": "DocType", @@ -47,7 +47,6 @@ "description": "To manage multiple series please go to Setup > Manage Series", "no_copy": 1, "oldfieldtype": "Select", - "colour": "White:FFF", "doctype": "DocField", "label": "Series", "oldfieldname": "naming_series", @@ -103,8 +102,8 @@ }, { "print_hide": 0, - "allow_on_submit": 1, "oldfieldtype": "Table", + "allow_on_submit": 1, "doctype": "DocField", "label": "Entries", "oldfieldname": "entries", @@ -163,7 +162,6 @@ "oldfieldtype": "Button", "doctype": "DocField", "label": "Make Difference Entry", - "trigger": "Client", "fieldname": "get_balance", "fieldtype": "Button", "permlevel": 0 @@ -179,15 +177,14 @@ "description": "eg. Cheque Number", "no_copy": 1, "oldfieldtype": "Data", - "colour": "White:FFF", "doctype": "DocField", "label": "Reference Number", "oldfieldname": "cheque_no", "fieldname": "cheque_no", "fieldtype": "Data", "search_index": 1, - "in_filter": 1, - "permlevel": 0 + "permlevel": 0, + "in_filter": 1 }, { "no_copy": 1, @@ -291,12 +288,10 @@ "print_hide": 1, "default": "No", "oldfieldtype": "Select", - "colour": "White:FFF", "doctype": "DocField", "label": "Is Opening", "oldfieldname": "is_opening", "permlevel": 0, - "trigger": "Client", "fieldname": "is_opening", "fieldtype": "Select", "search_index": 1, @@ -308,7 +303,6 @@ "description": "For opening invoice entry, this date will reflect in the period-wise aging report.", "no_copy": 0, "oldfieldtype": "Date", - "colour": "White:FFF", "doctype": "DocField", "label": "Aging Date", "oldfieldname": "aging_date", @@ -320,7 +314,6 @@ "print_hide": 1, "default": "Accounts Receivable", "depends_on": "eval:doc.voucher_type == 'Write Off Voucher'", - "colour": "White:FFF", "doctype": "DocField", "label": "Write Off Based On", "options": "Accounts Receivable\nAccounts Payable", @@ -332,7 +325,6 @@ { "print_hide": 1, "depends_on": "eval:doc.voucher_type == 'Write Off Voucher'", - "colour": "White:FFF", "doctype": "DocField", "label": "Write Off Amount <=", "fieldname": "write_off_amount", @@ -343,30 +335,11 @@ { "print_hide": 1, "depends_on": "eval:doc.voucher_type == 'Write Off Voucher'", - "colour": "White:FFF", "doctype": "DocField", "label": "Get Outstanding Invoices", - "trigger": "Server", + "options": "get_outstanding_invoices", "fieldname": "get_outstanding_invoices", "fieldtype": "Button", - "options": "get_outstanding_invoices", - "permlevel": 0 - }, - { - "print_hide": 0, - "description": "Date of entry (not posting to ledgers)", - "default": "Today", - "oldfieldtype": "Date", - "colour": "White:FFF", - "doctype": "DocField", - "label": "Voucher Date", - "oldfieldname": "voucher_date", - "no_copy": 1, - "fieldname": "voucher_date", - "fieldtype": "Date", - "search_index": 1, - "reqd": 1, - "in_filter": 1, "permlevel": 0 }, { @@ -442,13 +415,11 @@ "print_hide": 1, "no_copy": 1, "oldfieldtype": "Link", - "colour": "White:FFF", "allow_on_submit": 1, "doctype": "DocField", "label": "Select Print Heading", "oldfieldname": "select_print_heading", "permlevel": 0, - "trigger": "Client", "fieldname": "select_print_heading", "fieldtype": "Link", "options": "Print Heading", @@ -493,16 +464,14 @@ "print_hide": 1, "no_copy": 1, "oldfieldtype": "Link", - "colour": "White:FFF", "doctype": "DocField", "label": "Supplier Account", "oldfieldname": "supplier_account", - "permlevel": 0, - "trigger": "Client", + "options": "Account", "fieldname": "supplier_account", "fieldtype": "Link", "hidden": 0, - "options": "Account" + "permlevel": 0 }, { "amend": 1, @@ -510,8 +479,8 @@ "doctype": "DocPerm", "submit": 1, "write": 1, - "cancel": 1, "role": "Accounts User", + "cancel": 1, "permlevel": 0 }, { @@ -520,8 +489,8 @@ "doctype": "DocPerm", "submit": 0, "write": 0, - "cancel": 0, "role": "Accounts User", + "cancel": 0, "permlevel": 1 }, { @@ -530,8 +499,8 @@ "doctype": "DocPerm", "submit": 0, "write": 0, - "cancel": 0, "role": "Accounts Manager", + "cancel": 0, "permlevel": 1 }, { @@ -540,8 +509,8 @@ "doctype": "DocPerm", "submit": 1, "write": 1, - "cancel": 1, "role": "Accounts Manager", + "cancel": 1, "permlevel": 0 }, { @@ -550,8 +519,8 @@ "doctype": "DocPerm", "submit": 0, "write": 0, - "cancel": 0, "role": "Auditor", + "cancel": 0, "permlevel": 0 }, { @@ -560,8 +529,8 @@ "doctype": "DocPerm", "submit": 0, "write": 0, - "cancel": 0, "role": "Auditor", + "cancel": 0, "permlevel": 1 } ] \ No newline at end of file diff --git a/accounts/doctype/purchase_invoice/purchase_invoice.js b/accounts/doctype/purchase_invoice/purchase_invoice.js index 4188b9fdbc..528ac85d9f 100644 --- a/accounts/doctype/purchase_invoice/purchase_invoice.js +++ b/accounts/doctype/purchase_invoice/purchase_invoice.js @@ -21,7 +21,6 @@ wn.require('app/accounts/doctype/purchase_taxes_and_charges_master/purchase_taxe wn.require('app/buying/doctype/purchase_common/purchase_common.js'); cur_frm.cscript.onload = function(doc,dt,dn) { - if(!doc.voucher_date) set_multiple(dt,dn,{voucher_date:get_today()}); if(!doc.posting_date) set_multiple(dt,dn,{posting_date:get_today()}); } diff --git a/accounts/doctype/sales_invoice/sales_invoice.js b/accounts/doctype/sales_invoice/sales_invoice.js index eab1d4744d..8df91a5cb4 100644 --- a/accounts/doctype/sales_invoice/sales_invoice.js +++ b/accounts/doctype/sales_invoice/sales_invoice.js @@ -31,7 +31,6 @@ wn.require('app/utilities/doctype/sms_control/sms_control.js'); cur_frm.cscript.onload = function(doc,dt,dn) { if(!doc.customer && doc.debit_to) wn.meta.get_docfield(dt, 'debit_to', dn).print_hide = 0; if (doc.__islocal) { - //if(!doc.voucher_date) set_multiple(dt,dn,{voucher_date:get_today()}); if(!doc.due_date) set_multiple(dt,dn,{due_date:get_today()}); if(!doc.posting_date) set_multiple(dt,dn,{posting_date:get_today()}); if(!doc.currency && sys_defaults.currency) set_multiple(dt,dn,{currency:sys_defaults.currency}); diff --git a/accounts/search_criteria/voucher_wise_tax_details/voucher_wise_tax_details.js b/accounts/search_criteria/voucher_wise_tax_details/voucher_wise_tax_details.js index 9489630658..09a4498237 100644 --- a/accounts/search_criteria/voucher_wise_tax_details/voucher_wise_tax_details.js +++ b/accounts/search_criteria/voucher_wise_tax_details/voucher_wise_tax_details.js @@ -45,7 +45,7 @@ report.get_query = function() { date_fld = 'transaction_date'; if(based_on == 'Sales Invoice') { based_on = 'Sales Invoice'; - date_fld = 'voucher_date'; + date_fld = 'posting_date'; } sp_cond = ''; diff --git a/buying/doctype/supplier/supplier.py b/buying/doctype/supplier/supplier.py index f8de83f79e..75031c93c9 100644 --- a/buying/doctype/supplier/supplier.py +++ b/buying/doctype/supplier/supplier.py @@ -85,7 +85,14 @@ class DocType(TransactionBase): return g def add_account(self, ac, par, abbr): - arg = {'account_name':ac,'parent_account':par, 'group_or_ledger':'Group', 'company':self.doc.company,'account_type':'','tax_rate':'0'} + arg = { + 'account_name':ac, + 'parent_account':par, + 'group_or_ledger':'Group', + 'company':self.doc.company, + 'account_type':'', + 'tax_rate':'0' + } t = get_obj('GL Control').add_ac(cstr(arg)) msgprint("Created Group " + t) diff --git a/patches/january_2013/change_patch_structure.py b/patches/january_2013/change_patch_structure.py new file mode 100644 index 0000000000..37c4f087f3 --- /dev/null +++ b/patches/january_2013/change_patch_structure.py @@ -0,0 +1,12 @@ +import webnotes + +def execute(): + webnotes.reload_doc("core", "doctype", "patch_log") + for d in webnotes.conn.sql("""select patch from __PatchLog"""): + webnotes.doc({ + "doctype": "Patch Log", + "patch": d[0] + }).insert() + + webnotes.conn.commit() + webnotes.conn.sql("drop table __PatchLog") \ No newline at end of file diff --git a/patches/january_2013/update_country_info.py b/patches/january_2013/update_country_info.py new file mode 100644 index 0000000000..d0619f34d6 --- /dev/null +++ b/patches/january_2013/update_country_info.py @@ -0,0 +1,27 @@ +from __future__ import unicode_literals + +import webnotes + +def execute(): + from webnotes.country_info import get_all + data = get_all() + + webnotes.reload_doc("setup", "doctype", "country") + webnotes.reload_doc("setup", "doctype", "currency") + + for c in webnotes.conn.sql("""select name from tabCountry"""): + if c[0] in data: + info = webnotes._dict(data[c[0]]) + doc = webnotes.doc("Country", c[0]) + doc.date_format = info.date_format or "dd-mm-yyyy" + doc.time_zones = "\n".join(info.timezones or []) + doc.save() + + if webnotes.conn.exists("Currency", info.currency): + doc = webnotes.doc("Currency", info.currency) + doc.fields.update({ + "fraction": info.currency_fraction, + "symbol": info.currency_symbol, + "fraction_units": info.currency_fraction_units + }) + doc.save() diff --git a/patches/november_2012/reset_appraisal_permissions.py b/patches/november_2012/reset_appraisal_permissions.py index 2a73dc93cf..a9468a6769 100644 --- a/patches/november_2012/reset_appraisal_permissions.py +++ b/patches/november_2012/reset_appraisal_permissions.py @@ -1,5 +1,3 @@ import webnotes def execute(): - webnotes.conn.sql("""delete from tabDocPerm where parent='Appraisal'""") - from webnotes.model.sync import sync - sync("hr", "appraisal", force=True) \ No newline at end of file + webnotes.reset_perms("Appraisal") diff --git a/patches/october_2012/custom_script_delete_permission.py b/patches/october_2012/custom_script_delete_permission.py index cb704d094f..c515b04ba0 100644 --- a/patches/october_2012/custom_script_delete_permission.py +++ b/patches/october_2012/custom_script_delete_permission.py @@ -1,9 +1,3 @@ import webnotes def execute(): - webnotes.conn.sql("""delete from `tabDocPerm` where parent='Custom Script'""") - webnotes.conn.commit() - - from webnotes.model.sync import sync - sync("core", "custom_script", force=1) - - webnotes.conn.begin() \ No newline at end of file + webnotes.reset_perms("Custom Script") diff --git a/patches/patch_list.py b/patches/patch_list.py index 819fd2580b..e5e9d87ffc 100644 --- a/patches/patch_list.py +++ b/patches/patch_list.py @@ -16,586 +16,138 @@ from __future__ import unicode_literals patch_list = [ - { - 'patch_module': 'patches.mar_2012', - 'patch_file': 'so_rv_mapper_fix', - 'description': 'SO-RV duplicate mapper entry removal' - }, - { - 'patch_module': 'patches.mar_2012', - 'patch_file': 'clean_property_setter', - 'description': 'Patch related to property setter cleanup' - }, - { - 'patch_module': 'patches.jan_mar_2012', - 'patch_file': 'sync_ref_db', - 'description': 'Deletes non required doctypes' - }, - { - 'patch_module': 'patches.april_2012', - 'patch_file': 'naming_series_patch', - 'description': 'Move naming series options into property setter' - }, - { - 'patch_module': 'patches.jan_mar_2012', - 'patch_file': 'rename_dt', - 'description': 'Rename DocType Patch' - }, - { - 'patch_module': 'patches.mar_2012', - 'patch_file': 'cleanup_control_panel', - 'description': 'Remove email related fields from Control Panel' - }, - { - 'patch_module': 'patches.mar_2012', - 'patch_file': 'doctype_get_refactor', - 'description': 'Patch related to doctype get refactoring' - }, - { - 'patch_module': 'patches.mar_2012', - 'patch_file': 'delete_docformat', - 'description': 'Deletes DocFormat from database' - }, - { - 'patch_module': 'patches.mar_2012', - 'patch_file': 'usertags', - 'description': 'Adds _user_tags columns to tables' - }, - { - 'patch_module': 'patches.april_2012', - 'patch_file': 'reload_c_form', - 'description': 'Added attchemnt option and total field' - }, - { - 'patch_module': 'patches.april_2012', - 'patch_file': 'after_sync_cleanup', - 'description': 'cleanup after sync' - }, - { - 'patch_module': 'patches.april_2012', - 'patch_file': 'remove_default_from_rv_detail', - 'description': '' - }, - { - 'patch_module': 'patches.april_2012', - 'patch_file': 'update_role_in_address', - 'description': 'updated roles in address' - }, - { - 'patch_module': 'patches.april_2012', - 'patch_file': 'update_permlevel_in_address', - 'description': 'updated permlevel in address' - }, - { - 'patch_module': 'patches.april_2012', - 'patch_file': 'update_appraisal_permission', - 'description': 'updated permission in appraisal' - }, - { - 'patch_module': 'patches.april_2012', - 'patch_file': 'serial_no_fixes', - 'description': 'fixes for sle creation while import' - }, - { - 'patch_module': 'patches.april_2012', - 'patch_file': 'repost_stock_for_posting_time', - 'description': 'repost stock for posting time 00:00:seconds' - }, - { - 'patch_module': 'patches.may_2012', - 'patch_file': 'cleanup_property_setter', - 'description': 'cleanup_property_setter' - }, - { - 'patch_module': 'patches.may_2012', - 'patch_file': 'rename_prev_doctype', - 'description': 'rename prev doctype fix' - }, - { - 'patch_module': 'patches.may_2012', - 'patch_file': 'cleanup_notification_control', - 'description': 'cleanup notification control' - }, - { - 'patch_module': 'patches.may_2012', - 'patch_file': 'renamedt_in_custom_search_criteria', - 'description': 'raname dt in custom search criteria' - }, - { - 'patch_module': 'patches.may_2012', - 'patch_file': 'stock_reco_patch', - 'description': 'stock reco patch: store diff info in field' - }, - { - 'patch_module': 'patches.may_2012', - 'patch_file': 'reload_reports', - 'description': 'reload reports: itemwise sales/delivery details' - }, - { - 'patch_module': 'patches.may_2012', - 'patch_file': 'page_role_series_fix', - 'description': 'reset series of page role at max' - }, - { - 'patch_module': 'patches.may_2012', - 'patch_file': 'reload_sales_invoice_pf', - 'description': 'Reload sales invoice print formats' - }, - { - 'patch_module': 'patches.may_2012', - 'patch_file': 'std_pf_readonly', - 'description': 'Make standard print formats readonly for system manager' - }, - { - 'patch_module': 'patches.may_2012', - 'patch_file': 'reload_so_pending_items', - 'description': 'reload so pending items' - }, - { - 'patch_module': 'patches.may_2012', - 'patch_file': 'customize_form_cleanup', - 'description': 'cleanup customize form records' - }, - { - 'patch_module': 'patches.may_2012', - 'patch_file': 'cs_server_readonly', - 'description': 'Make server custom script readonly for system manager' - }, - { - 'patch_module': 'patches.may_2012', - 'patch_file': 'clear_session_cache', - 'description': 'clears session cache as shifting to json format' - }, - { - 'patch_module': 'patches.may_2012', - 'patch_file': 'same_purchase_rate_patch', - 'description': 'Main same rate throughout pur cycle: in global defaults, by default set true' - }, - { - 'patch_module': 'patches.may_2012', - 'patch_file': 'create_report_manager_role', - 'description': 'Create report manager role if not exists' - }, - { - 'patch_module': 'patches.may_2012', - 'patch_file': 'reload_customer_address_contact', - 'description': 'Reload report customer address contact' - }, - { - 'patch_module': 'patches.may_2012', - 'patch_file': 'profile_perm_patch', - 'description': 'Make profile readonly for role All' - }, - { - 'patch_module': 'patches.may_2012', - 'patch_file': 'remove_euro_currency', - 'description': 'Remove EURO currency and replace with EUR' - }, - { - 'patch_module': 'patches.may_2012', - 'patch_file': 'remove_communication_log', - 'description': 'Remove Communication Log and replace it with Communication' - }, - { - 'patch_module': 'patches.june_2012', - 'patch_file': 'barcode_in_feature_setup', - 'description': 'Track item by barcode' - }, - { - 'patch_module': 'patches.june_2012', - 'patch_file': 'copy_uom_for_pur_inv_item', - 'description': 'Copy uom for pur inv item from PO and PR item table' - }, - { - 'patch_module': 'patches.june_2012', - 'patch_file': 'fetch_organization_from_lead', - 'description': 'Fetch organization from lead in quote' - }, - { - 'patch_module': 'patches.june_2012', - 'patch_file': 'reports_list_permission', - 'description': 'allow read permission to all for report list' - }, - { - 'patch_module': 'patches.june_2012', - 'patch_file': 'support_ticket_autoreply', - 'description': 'New Send Autoreply checkbox in Email Settings' - }, - { - 'patch_module': 'patches.june_2012', - 'patch_file': 'series_unique_patch', - 'description': "add unique constraint to series table's name column" - }, - { - 'patch_module': 'patches.june_2012', - 'patch_file': 'set_recurring_type', - 'description': "set recurring type as monthly in old" - }, - { - 'patch_module': 'patches.june_2012', - 'patch_file': 'alter_tabsessions', - 'description': "alter tabsessions to change user column definition" - }, - { - 'patch_module': 'patches.june_2012', - 'patch_file': 'delete_old_parent_entries', - 'description': "delete entries of child table having parent like old_par%% or ''" - }, - { - 'patch_module': 'patches.april_2012', - 'patch_file': 'delete_about_contact', - 'description': "delete depracated doctypes of website module" - }, - { - 'patch_module': 'patches.july_2012', - 'patch_file': 'reload_pr_po_mapper', - 'description': "order date should be greater than equal to request date" - }, - { - 'patch_module': 'patches.july_2012', - 'patch_file': 'address_contact_perms', - 'description': "sync address contact perms" - }, - { - 'patch_module': 'patches.july_2012', - 'patch_file': 'packing_list_cleanup_and_serial_no', - 'description': "packing list cleanup and serial no status update" - }, - { - 'patch_module': 'patches.july_2012', - 'patch_file': 'deprecate_import_data_control', - 'description': "deprecate doctype - Import Data Control and page - Import Data" - }, - { - 'patch_module': 'patches.july_2012', - 'patch_file': 'default_freeze_account', - 'description': "set default freeze_account as 'No' where NULL" - }, - { - 'patch_module': 'patches.july_2012', - 'patch_file': 'update_purchase_tax', - 'description': "rename options in purchase taxes and charges" - }, - { 'patch_module': 'patches.june_2012', - 'patch_file': 'cms2', - 'description': 'cms2 release patches' - }, - { 'patch_module': 'patches.july_2012', - 'patch_file': 'auth_table', - 'description': 'create new __Auth table' - }, - { - 'patch_module': 'patches.july_2012', - 'patch_file': 'remove_event_role_owner_match', - 'description': "Remove Owner match from Event DocType's Permissions" - }, - { - 'patch_module': 'patches.july_2012', - 'patch_file': 'deprecate_bulk_rename', - 'description': "Remove Bulk Rename Tool" - }, - { - 'patch_module': 'patches.july_2012', - 'patch_file': 'blog_guest_permission', - }, - { - 'patch_module': 'patches.july_2012', - 'patch_file': 'bin_permission', - }, - { - 'patch_module': 'patches.july_2012', - 'patch_file': 'project_patch_repeat', - }, - { - 'patch_module': 'patches.july_2012', - 'patch_file': 'repost_stock_due_to_wrong_packing_list', - }, - { - 'patch_module': 'patches.july_2012', - 'patch_file': 'supplier_quotation', - }, - { - 'patch_module': 'patches.august_2012', - 'patch_file': 'report_supplier_quotations', - }, - { - 'patch_module': 'patches.august_2012', - 'patch_file': 'task_allocated_to_assigned', - }, - { - 'patch_module': 'patches.august_2012', - 'patch_file': 'change_profile_permission', - }, - { - 'patch_module': 'patches.august_2012', - 'patch_file': 'changed_blog_date_format', - }, - { - 'patch_module': 'patches.august_2012', - 'patch_file': 'repost_billed_amt', - }, - { - 'patch_module': 'patches.august_2012', - 'patch_file': 'remove_cash_flow_statement', - }, - { - 'patch_module': 'patches.september_2012', - 'patch_file': 'stock_report_permissions_for_accounts', - }, - { - 'patch_module': 'patches.september_2012', - 'patch_file': 'communication_delete_permission', - }, - { - 'patch_module': 'patches.september_2012', - 'patch_file': 'all_permissions_patch', - }, - { - 'patch_module': 'patches.september_2012', - 'patch_file': 'customer_permission_patch', - }, - { - 'patch_module': 'patches.september_2012', - 'patch_file': 'add_stock_ledger_entry_index', - }, - { - 'patch_module': 'patches.september_2012', - 'patch_file': 'plot_patch', - }, - { - 'patch_module': 'patches.september_2012', - 'patch_file': 'event_permission', - }, - { - 'patch_module': 'patches.september_2012', - 'patch_file': 'repost_stock', - }, - { - 'patch_module': 'patches.september_2012', - 'patch_file': 'reload_gross_profit', - }, - { - 'patch_module': 'patches.september_2012', - 'patch_file': 'rebuild_trees', - }, - { - 'patch_module': 'patches.september_2012', - 'patch_file': 'deprecate_account_balance', - }, - { - 'patch_module': 'patches.september_2012', - 'patch_file': 'profile_delete_permission', - }, - { - 'patch_module': 'patches.october_2012', - 'patch_file': 'update_permission', - }, - { - 'patch_module': 'patches.october_2012', - 'patch_file': 'reload_gl_mapper', - }, - { - 'patch_module': 'patches.october_2012', - 'patch_file': 'fix_wrong_vouchers', - }, - { - 'patch_module': 'patches.october_2012', - 'patch_file': 'remove_old_customer_contact_address', - }, - { - 'patch_module': 'patches.october_2012', - 'patch_file': 'company_fiscal_year_docstatus_patch', - }, - { - 'patch_module': 'patches.october_2012', - 'patch_file': 'update_account_property', - }, - { - 'patch_module': 'patches.october_2012', - 'patch_file': 'remove_old_trial_bal', - }, - { - 'patch_module': 'patches.october_2012', - 'patch_file': 'fix_cancelled_gl_entries', - }, - { - 'patch_module': 'patches.october_2012', - 'patch_file': 'custom_script_delete_permission', - }, - { - 'patch_module': 'patches.november_2012', - 'patch_file': 'custom_field_insert_after', - }, - { - 'patch_module': 'patches.november_2012', - 'patch_file': 'delete_item_sales_register1', - }, - { - 'patch_module': 'patches.november_2012', - 'patch_file': 'rename_employee_leave_balance_report', - }, - { - 'patch_module': 'patches.november_2012', - 'patch_file': 'report_permissions', - }, - { - 'patch_module': 'patches.november_2012', - 'patch_file': 'customer_issue_allocated_to_assigned', - }, - { - 'patch_module': 'patches.november_2012', - 'patch_file': 'reset_appraisal_permissions', - }, - { - 'patch_module': 'patches.november_2012', - 'patch_file': 'disable_cancelled_profiles', - }, - { - 'patch_module': 'patches.november_2012', - 'patch_file': 'remove_old_unbilled_items_report', - }, - { - 'patch_module': 'patches.november_2012', - 'patch_file': 'support_ticket_response_to_communication', - }, - { - 'patch_module': 'patches.november_2012', - 'patch_file': 'cancelled_bom_patch', - }, - { - 'patch_module': 'patches.november_2012', - 'patch_file': 'communication_sender_and_recipient', - }, - { - 'patch_module': 'patches.november_2012', - 'patch_file': 'update_delivered_billed_percentage_for_pos', - }, - { - 'patch_module': 'patches.november_2012', - 'patch_file': 'add_theme_to_profile', - }, - { - 'patch_module': 'patches.november_2012', - 'patch_file': 'add_employee_field_in_employee', - }, - { - 'patch_module': 'patches.november_2012', - 'patch_file': 'leave_application_cleanup', - }, - { - 'patch_module': 'patches.november_2012', - 'patch_file': 'production_order_patch', - }, - { - 'patch_module': 'patches.november_2012', - 'patch_file': 'gle_floating_point_issue', - }, - { - 'patch_module': 'patches.december_2012', - 'patch_file': 'deprecate_tds', - }, - { - 'patch_module': 'patches.december_2012', - 'patch_file': 'expense_leave_reload', - }, - { - 'patch_module': 'patches.december_2012', - 'patch_file': 'repost_ordered_qty', - }, - { - 'patch_module': 'patches.december_2012', - 'patch_file': 'repost_projected_qty', - }, - { - 'patch_module': 'patches.december_2012', - 'patch_file': 'reload_debtors_creditors_ledger', - }, - { - 'patch_module': 'patches.december_2012', - 'patch_file': 'website_cache_refactor', - }, - { - 'patch_module': 'patches.december_2012', - 'patch_file': 'production_cleanup', - }, - { - 'patch_module': 'patches.december_2012', - 'patch_file': 'fix_default_print_format', - }, - { - 'patch_module': 'patches.december_2012', - 'patch_file': 'file_list_rename', - }, - { - 'patch_module': 'patches.december_2012', - 'patch_file': 'replace_createlocal', - }, - { - 'patch_module': 'patches.december_2012', - 'patch_file': 'clear_web_cache', - }, - { - 'patch_module': 'patches.december_2012', - 'patch_file': 'remove_quotation_next_contact', - }, - { - 'patch_module': 'patches.december_2012', - 'patch_file': 'stock_entry_cleanup', - }, - { - 'patch_module': 'patches.december_2012', - 'patch_file': 'production_order_naming_series', - }, - { - 'patch_module': 'patches.december_2012', - 'patch_file': 'rebuild_item_group_tree', - }, - { - 'patch_module': 'patches.december_2012', - 'patch_file': 'address_title', - }, - { - 'patch_module': 'patches.december_2012', - 'patch_file': 'delete_form16_print_format', - }, - { - 'patch_module': 'patches.december_2012', - 'patch_file': 'remove_project_mapper', - }, - { - 'patch_module': 'patches.december_2012', - 'patch_file': 'update_print_width', - }, - { - 'patch_module': 'patches.january_2013', - 'patch_file': 'remove_bad_permissions', - }, - { - 'patch_module': 'patches.january_2013', - 'patch_file': 'deprecate_stock_search_criteria', - }, - { - 'patch_module': 'patches.january_2013', - 'patch_file': 'remove_support_search_criteria', - }, - { - 'patch_module': 'patches.january_2013', - 'patch_file': 'holiday_list_patch', - }, - { - 'patch_module': 'patches.january_2013', - 'patch_file': 'stock_reconciliation_patch', - }, - { - 'patch_module': 'patches.january_2013', - 'patch_file': 'report_permission', - }, - { - 'patch_module': 'patches.january_2013', - 'patch_file': 'give_report_permission_on_read', - }, - { - 'patch_module': 'patches.january_2013', - 'patch_file': 'update_closed_on', - }, + "patches.mar_2012.so_rv_mapper_fix", + "patches.mar_2012.clean_property_setter", + "patches.jan_mar_2012.sync_ref_db", + "patches.april_2012.naming_series_patch", + "patches.jan_mar_2012.rename_dt", + "patches.mar_2012.cleanup_control_panel", + "patches.mar_2012.doctype_get_refactor", + "patches.mar_2012.delete_docformat", + "patches.mar_2012.usertags", + "patches.april_2012.reload_c_form", + "patches.april_2012.after_sync_cleanup", + "patches.april_2012.remove_default_from_rv_detail", + "patches.april_2012.update_role_in_address", + "patches.april_2012.update_permlevel_in_address", + "patches.april_2012.update_appraisal_permission", + "patches.april_2012.serial_no_fixes", + "patches.april_2012.repost_stock_for_posting_time", + "patches.may_2012.cleanup_property_setter", + "patches.may_2012.rename_prev_doctype", + "patches.may_2012.cleanup_notification_control", + "patches.may_2012.renamedt_in_custom_search_criteria", + "patches.may_2012.stock_reco_patch", + "patches.may_2012.reload_reports", + "patches.may_2012.page_role_series_fix", + "patches.may_2012.reload_sales_invoice_pf", + "patches.may_2012.std_pf_readonly", + "patches.may_2012.reload_so_pending_items", + "patches.may_2012.customize_form_cleanup", + "patches.may_2012.cs_server_readonly", + "patches.may_2012.clear_session_cache", + "patches.may_2012.same_purchase_rate_patch", + "patches.may_2012.create_report_manager_role", + "patches.may_2012.reload_customer_address_contact", + "patches.may_2012.profile_perm_patch", + "patches.may_2012.remove_euro_currency", + "patches.may_2012.remove_communication_log", + "patches.june_2012.barcode_in_feature_setup", + "patches.june_2012.copy_uom_for_pur_inv_item", + "patches.june_2012.fetch_organization_from_lead", + "patches.june_2012.reports_list_permission", + "patches.june_2012.support_ticket_autoreply", + "patches.june_2012.series_unique_patch", + "patches.june_2012.set_recurring_type", + "patches.june_2012.alter_tabsessions", + "patches.june_2012.delete_old_parent_entries", + "patches.april_2012.delete_about_contact", + "patches.july_2012.reload_pr_po_mapper", + "patches.july_2012.address_contact_perms", + "patches.july_2012.packing_list_cleanup_and_serial_no", + "patches.july_2012.deprecate_import_data_control", + "patches.july_2012.default_freeze_account", + "patches.july_2012.update_purchase_tax", + "patches.june_2012.cms2", + "patches.july_2012.auth_table", + "patches.july_2012.remove_event_role_owner_match", + "patches.july_2012.deprecate_bulk_rename", + "patches.july_2012.blog_guest_permission", + "patches.july_2012.bin_permission", + "patches.july_2012.project_patch_repeat", + "patches.july_2012.repost_stock_due_to_wrong_packing_list", + "patches.july_2012.supplier_quotation", + "patches.august_2012.report_supplier_quotations", + "patches.august_2012.task_allocated_to_assigned", + "patches.august_2012.change_profile_permission", + "patches.august_2012.changed_blog_date_format", + "patches.august_2012.repost_billed_amt", + "patches.august_2012.remove_cash_flow_statement", + "patches.september_2012.stock_report_permissions_for_accounts", + "patches.september_2012.communication_delete_permission", + "patches.september_2012.all_permissions_patch", + "patches.september_2012.customer_permission_patch", + "patches.september_2012.add_stock_ledger_entry_index", + "patches.september_2012.plot_patch", + "patches.september_2012.event_permission", + "patches.september_2012.repost_stock", + "patches.september_2012.reload_gross_profit", + "patches.september_2012.rebuild_trees", + "patches.september_2012.deprecate_account_balance", + "patches.september_2012.profile_delete_permission", + "patches.october_2012.update_permission", + "patches.october_2012.reload_gl_mapper", + "patches.october_2012.fix_wrong_vouchers", + "patches.october_2012.remove_old_customer_contact_address", + "patches.october_2012.company_fiscal_year_docstatus_patch", + "patches.october_2012.update_account_property", + "patches.october_2012.remove_old_trial_bal", + "patches.october_2012.fix_cancelled_gl_entries", + "patches.october_2012.custom_script_delete_permission", + "patches.november_2012.custom_field_insert_after", + "patches.november_2012.delete_item_sales_register1", + "patches.november_2012.rename_employee_leave_balance_report", + "patches.november_2012.report_permissions", + "patches.november_2012.customer_issue_allocated_to_assigned", + "patches.november_2012.reset_appraisal_permissions", + "patches.november_2012.disable_cancelled_profiles", + "patches.november_2012.remove_old_unbilled_items_report", + "patches.november_2012.support_ticket_response_to_communication", + "patches.november_2012.cancelled_bom_patch", + "patches.november_2012.communication_sender_and_recipient", + "patches.november_2012.update_delivered_billed_percentage_for_pos", + "patches.november_2012.add_theme_to_profile", + "patches.november_2012.add_employee_field_in_employee", + "patches.november_2012.leave_application_cleanup", + "patches.november_2012.production_order_patch", + "patches.november_2012.gle_floating_point_issue", + "patches.december_2012.deprecate_tds", + "patches.december_2012.expense_leave_reload", + "patches.december_2012.repost_ordered_qty", + "patches.december_2012.repost_projected_qty", + "patches.december_2012.reload_debtors_creditors_ledger", + "patches.december_2012.website_cache_refactor", + "patches.december_2012.production_cleanup", + "patches.december_2012.fix_default_print_format", + "patches.december_2012.file_list_rename", + "patches.december_2012.replace_createlocal", + "patches.december_2012.clear_web_cache", + "patches.december_2012.remove_quotation_next_contact", + "patches.december_2012.stock_entry_cleanup", + "patches.december_2012.production_order_naming_series", + "patches.december_2012.rebuild_item_group_tree", + "patches.december_2012.address_title", + "patches.december_2012.delete_form16_print_format", + "patches.december_2012.remove_project_mapper", + "patches.december_2012.update_print_width", + "patches.january_2013.remove_bad_permissions", + "patches.january_2013.deprecate_stock_search_criteria", + "patches.january_2013.remove_support_search_criteria", + "patches.january_2013.holiday_list_patch", + "patches.january_2013.stock_reconciliation_patch", + "patches.january_2013.report_permission", + "patches.january_2013.give_report_permission_on_read", + "patches.january_2013.update_closed_on", + "patches.january_2013.change_patch_structure", + "patches.january_2013.update_country_info", ] \ No newline at end of file diff --git a/public/js/complete_setup.js b/public/js/complete_setup.js index d00abb6f0a..f5d06722c6 100644 --- a/public/js/complete_setup.js +++ b/public/js/complete_setup.js @@ -37,14 +37,14 @@ $.extend(erpnext.complete_setup, { {fieldname:'fy_start', label:'Financial Year Start Date', fieldtype:'Select', description:'Your financial year begins on"', reqd:1, options: erpnext.complete_setup.fy_start_list.join('\n')}, + {fieldname:'country', label: 'Country', reqd:1, + options: "", fieldtype: 'Select'}, {fieldname:'currency', label: 'Default Currency', reqd:1, - options: erpnext.complete_setup.currency_list.join('\n'), fieldtype: 'Select'}, + options: "Currency", fieldtype: 'Link'}, + {fieldname:'timezone', label: 'Time Zone', reqd:1, + options: "", fieldtype: 'Select'}, {fieldname:'industry', label: 'Industry', reqd:1, options: erpnext.complete_setup.industry_list.join('\n'), fieldtype: 'Select'}, - {fieldname:'country', label: 'Country', reqd:1, - options: erpnext.complete_setup.country_list.join('\n'), fieldtype: 'Select'}, - {fieldname:'timezone', label: 'Time Zone', reqd:1, - options: '', fieldtype: 'Select'}, {fieldname:'update', label:'Setup',fieldtype:'Button'}, ], }); @@ -54,6 +54,15 @@ $.extend(erpnext.complete_setup, { $('header').toggle(false); // hide toolbar } + wn.call({ + method:"webnotes.country_info.get_all", + callback: function(data) { + erpnext.country_info = data.message; + d.get_input("country").empty() + .add_options([""].concat(keys(data.message).sort())); + } + }) + // on clicking update d.fields_dict.update.input.onclick = function() { var data = d.get_values(); @@ -74,12 +83,19 @@ $.extend(erpnext.complete_setup, { var $timezone = $(d.fields_dict.timezone.input); $timezone.empty(); if(country){ - var timezone_list = erpnext.complete_setup.timezone_dict[country]; - if(timezone_list.length > 1) { - timezone_list = [""].concat(timezone_list); + var timezone_list = erpnext.country_info[country].timezones; + if(timezone_list.length==0) { + timezone_list = $.map(erpnext.country_info, function(m) { + return m.timezones + }); } - $timezone.add_options(timezone_list); + $timezone.empty().add_options(timezone_list); + + console.log(d.get_input("currency")) + + d.get_input("currency").val(erpnext.country_info[country].currency); } + }; // company name already set @@ -104,374 +120,12 @@ $.extend(erpnext.complete_setup, { }, fy_start_list: ['', '1st Jan', '1st Apr', '1st Jul', '1st Oct'], - - currency_list: ['', 'AED', 'AFN', 'ALL', 'AMD', 'ANG', 'AOA', 'ARS', 'AUD', 'AZN', - 'BAM', 'BBD', 'BDT', 'BGN', 'BHD', 'BIF', 'BMD', 'BND', 'BOB', 'BRL', 'BSD', 'BTN', 'BYR', - 'BZD', 'CAD', 'CDF', 'CFA', 'CFP', 'CHF', 'CLP', 'CNY', 'COP', 'CRC', 'CUC', 'CZK', 'DJF', - 'DKK', 'DOP', 'DZD', 'EEK', 'EGP', 'ERN', 'ETB', 'EUR', 'EURO', 'FJD', 'FKP', 'FMG', 'GBP', - 'GEL', 'GHS', 'GIP', 'GMD', 'GNF', 'GQE', 'GTQ', 'GYD', 'HKD', 'HNL', 'HRK', 'HTG', 'HUF', - 'IDR', 'ILS', 'INR', 'IQD', 'IRR', 'ISK', 'JMD', 'JOD', 'JPY', 'KES', 'KGS', 'KHR', 'KMF', - 'KPW', 'KRW', 'KWD', 'KYD', 'KZT', 'LAK', 'LBP', 'LKR', 'LRD', 'LSL', 'LTL', 'LVL', 'LYD', - 'MAD', 'MDL', 'MGA', 'MKD', 'MMK', 'MNT', 'MOP', 'MRO', 'MUR', 'MVR', 'MWK', 'MXN', 'MYR', - 'MZM', 'NAD', 'NGN', 'NIO', 'NOK', 'NPR', 'NRs', 'NZD', 'OMR', 'PAB', 'PEN', 'PGK', 'PHP', - 'PKR', 'PLN', 'PYG', 'QAR', 'RMB', 'RON', 'RSD', 'RUB', 'RWF', 'SAR', 'SCR', 'SDG', 'SDR', - 'SEK', 'SGD', 'SHP', 'SOS', 'SRD', 'STD', 'SYP', 'SZL', 'THB', 'TJS', 'TMT', 'TND', 'TRY', - 'TTD', 'TWD', 'TZS', 'UAE', 'UAH', 'UGX', 'USD', 'USh', 'UYU', 'UZS', 'VEB', 'VND', 'VUV', - 'WST', 'XAF', 'XCD', 'XDR', 'XOF', 'XPF', 'YEN', 'YER', 'YTL', 'ZAR', 'ZMK', 'ZWR'], - - industry_list: ['', 'Aerospace and Defence', 'Agriculture', 'Apparel', 'Automobile', - 'Banking', 'Biotechnology', 'Chemical', 'Communications', 'Consulting', 'Customer Service', - 'Education', 'Electronics', 'Energy', 'Engineering', 'Entertainment', 'Environmental', - 'Finance', 'Food and Beverage', 'Government', 'Healthcare', 'Hospitality', - 'Information Technology', 'Insurance', 'Machinery', 'Manufacturing', 'Media', - 'Not For Profit', 'Recreation', 'Retail', 'Shipping', 'Technology', - 'Telecommunications', 'Transportation', 'Trading', 'Utilities', 'Other'], - - country_list: ["", 'Afghanistan', 'Albania', 'Algeria', 'Andorra', 'Angola', 'Antigua and Barbuda', - 'Argentina', 'Armenia', 'Australia', 'Austria', 'Azerbaijan', 'Bahamas', 'Bahrain', - 'Bangladesh', 'Barbados', 'Belarus', 'Belgium', 'Belize', 'Benin', 'Bhutan', 'Bolivia', - 'Bosnia and Herzegovina', 'Botswana', 'Brazil', 'Brunei Darussalam', 'Bulgaria', - 'Burkina Faso', 'Burundi', 'Cambodia', 'Cameroon', 'Canada', 'Cape Verde', - 'Central African Republic', 'Chad', 'Chile', 'Colombia', 'Comoros', 'Costa Rica', - 'Croatia', 'Cuba', 'Cyprus', 'Czech Republic', "C\xc3\xb4te d'Ivoire", - 'Democratic Republic of the Congo', 'Denmark', 'Djibouti', 'Dominica', - 'Dominican Republic', 'East Timor', 'Ecuador', 'Egypt', 'El Salvador', - 'Equatorial Guinea', 'Eritrea', 'Estonia', 'Ethiopia', 'Federated States of Micronesia', - 'Fiji', 'Finland', 'France', 'Gabon', 'Georgia', 'Germany', 'Ghana', 'Greece', - 'Grenada', 'Guatemala', 'Guinea', 'Guinea-Bissau', 'Guyana', 'Haiti', 'Honduras', 'Hong Kong', - 'Hungary', 'Iceland', 'India', 'Indonesia', 'Iran', 'Iraq', 'Israel', 'Italy', - 'Jamaica', 'Japan', 'Jordan', 'Kazakhstan', 'Kenya', 'Kingdom of the Netherlands', - 'Kiribati', 'Kuwait', 'Kyrgyzstan', 'Laos', 'Latvia', 'Lebanon', 'Lesotho', 'Liberia', - 'Libya', 'Liechtenstein', 'Lithuania', 'Luxembourg', 'Macedonia', 'Madagascar', 'Malawi', - 'Malaysia', 'Maldives', 'Mali', 'Malta', 'Marshall Islands', 'Mauritania', 'Mauritius', - 'Mexico', 'Moldova', 'Monaco', 'Mongolia', 'Montenegro', 'Morocco', 'Mozambique', - 'Myanmar', 'Namibia', 'Nauru', 'Nepal', 'New Zealand', 'Nicaragua', 'Niger', 'Nigeria', - 'North Korea', 'Norway', 'Oman', 'Pakistan', 'Palau', 'Panama', 'Papua New Guinea', - 'Paraguay', "China", 'Peru', 'Philippines', 'Poland', 'Portugal', - 'Qatar', 'Republic of Ireland', 'Republic of the Congo', 'Romania', 'Russia', 'Rwanda', - 'Saint Kitts and Nevis', 'Saint Lucia', 'Saint Vincent and the Grenadines', 'Samoa', - 'San Marino', 'Saudi Arabia', 'Senegal', 'Serbia', 'Seychelles', 'Sierra Leone', - 'Singapore', 'Slovakia', 'Slovenia', 'Solomon Islands', 'Somalia', 'South Africa', - 'South Korea', 'Spain', 'Sri Lanka', 'Sudan', 'Suriname', 'Swaziland', 'Sweden', - 'Switzerland', 'Syria', 'S\xc3\xa3o Tom\xc3\xa9 and Pr\xc3\xadncipe', 'Tajikistan', - 'Tanzania', 'Thailand', 'The Gambia', 'Togo', 'Tonga', 'Trinidad and Tobago', 'Tunisia', - 'Turkey', 'Turkmenistan', 'Tuvalu', 'Uganda', 'Ukraine', 'United Arab Emirates', - 'United Kingdom', 'United States', 'Uruguay', 'Uzbekistan', 'Vanuatu', 'Vatican City', - 'Venezuela', 'Vietnam', 'Yemen', 'Zambia', 'Zimbabwe'], - - timezone_dict: { - 'Afghanistan': ['Asia/Kabul'], - 'Albania': ['Europe/Tirane'], - 'Algeria': ['Africa/Algiers'], - 'Andorra': ['Europe/Andorra'], - 'Angola': ['Africa/Luanda'], - 'Antigua and Barbuda': ['America/Antigua'], - 'Argentina': ['America/Argentina/Buenos_Aires', - 'America/Argentina/Cordoba', - 'America/Argentina/Jujuy', - 'America/Argentina/Tucuman', - 'America/Argentina/Catamarca', - 'America/Argentina/La_Rioja', - 'America/Argentina/San_Juan', - 'America/Argentina/Mendoza', - 'America/Argentina/Rio_Gallegos', - 'America/Argentina/Ushuaia'], - 'Armenia': ['Asia/Yerevan'], - 'Australia': ['Australia/Lord_Howe', - 'Australia/Hobart', - 'Australia/Currie', - 'Australia/Melbourne', - 'Australia/Sydney', - 'Australia/Broken_Hill', - 'Australia/Brisbane', - 'Australia/Lindeman', - 'Australia/Adelaide', - 'Australia/Darwin', - 'Australia/Perth'], - 'Austria': ['Europe/Vienna'], - 'Azerbaijan': ['Asia/Baku'], - 'Bahamas': ['America/Nassau'], - 'Bahrain': ['Asia/Bahrain'], - 'Bangladesh': ['Asia/Dhaka'], - 'Barbados': ['America/Barbados'], - 'Belarus': ['Europe/Minsk'], - 'Belgium': ['Europe/Brussels'], - 'Belize': ['America/Belize'], - 'Benin': ['Africa/Porto-Novo'], - 'Bhutan': ['Asia/Thimphu'], - 'Bolivia': ['America/La_Paz'], - 'Bosnia and Herzegovina': ['Europe/Sarajevo'], - 'Botswana': ['Africa/Gaborone'], - 'Brazil': ['America/Noronha', - 'America/Belem', - 'America/Fortaleza', - 'America/Recife', - 'America/Araguaina', - 'America/Maceio', - 'America/Bahia', - 'America/Sao_Paulo', - 'America/Campo_Grande', - 'America/Cuiaba', - 'America/Porto_Velho', - 'America/Boa_Vista', - 'America/Manaus', - 'America/Eirunepe', - 'America/Rio_Branco'], - 'Brunei Darussalam': ['Asia/Brunei'], - 'Bulgaria': ['Europe/Sofia'], - 'Burkina Faso': ['Africa/Ouagadougou'], - 'Burundi': ['Africa/Bujumbura'], - 'Cambodia': ['Asia/Phnom_Penh'], - 'Cameroon': ['Africa/Douala'], - 'Canada': ['America/St_Johns', - 'America/Halifax', - 'America/Glace_Bay', - 'America/Moncton', - 'America/Goose_Bay', - 'America/Blanc-Sablon', - 'America/Montreal', - 'America/Toronto', - 'America/Nipigon', - 'America/Thunder_Bay', - 'America/Pangnirtung', - 'America/Iqaluit', - 'America/Atikokan', - 'America/Rankin_Inlet', - 'America/Winnipeg', - 'America/Rainy_River', - 'America/Cambridge_Bay', - 'America/Regina', - 'America/Swift_Current', - 'America/Edmonton', - 'America/Yellowknife', - 'America/Inuvik', - 'America/Dawson_Creek', - 'America/Vancouver', - 'America/Whitehorse', - 'America/Dawson'], - 'Cape Verde': ['Atlantic/Cape_Verde'], - 'Central African Republic': ['Africa/Bangui'], - 'Chad': ['Africa/Ndjamena'], - 'China': ['Asia/Shanghai', - 'Asia/Harbin', - 'Asia/Chongqing', - 'Asia/Urumqi', - 'Asia/Kashgar'], - 'Chile': ['America/Santiago', 'Pacific/Easter'], - 'Colombia': ['America/Bogota'], - 'Comoros': ['Indian/Comoro'], - 'Costa Rica': ['America/Costa_Rica'], - 'Croatia': ['Europe/Zagreb'], - 'Cuba': ['America/Havana'], - 'Cyprus': ['Asia/Nicosia'], - 'Czech Republic': ['Europe/Prague'], - "C\xc3\xb4te d'Ivoire": ['Africa/Abidjan'], - 'Democratic Republic of the Congo': ['Africa/Kinshasa', 'Africa/Lubumbashi'], - 'Denmark': ['Europe/Copenhagen'], - 'Djibouti': ['Africa/Djibouti'], - 'Dominica': ['America/Dominica'], - 'Dominican Republic': ['America/Santo_Domingo'], - 'East Timor': ['Asia/Dili'], - 'Ecuador': ['America/Guayaquil', 'Pacific/Galapagos'], - 'Egypt': ['Africa/Cairo'], - 'El Salvador': ['America/El_Salvador'], - 'Equatorial Guinea': ['Africa/Malabo'], - 'Eritrea': ['Africa/Asmera'], - 'Estonia': ['Europe/Tallinn'], - 'Ethiopia': ['Africa/Addis_Ababa'], - 'Federated States of Micronesia': ['Pacific/Truk', - 'Pacific/Ponape', - 'Pacific/Kosrae'], - 'Fiji': ['Pacific/Fiji'], - 'Finland': ['Europe/Helsinki'], - 'France': ['Europe/Paris'], - 'Gabon': ['Africa/Libreville'], - 'Georgia': ['Asia/Tbilisi'], - 'Germany': ['Europe/Berlin'], - 'Ghana': ['Africa/Accra'], - 'Greece': ['Europe/Athens'], - 'Grenada': ['America/Grenada'], - 'Guatemala': ['America/Guatemala'], - 'Guinea': ['Africa/Conakry'], - 'Guinea-Bissau': ['Africa/Bissau'], - 'Guyana': ['America/Guyana'], - 'Haiti': ['America/Guatemala'], - 'Honduras': ['America/Tegucigalpa'], - 'Hong Kong': ['Asia/Hong_Kong'], - 'Hungary': ['Europe/Budapest'], - 'Iceland': ['Atlantic/Reykjavik'], - 'India': ['Asia/Calcutta'], - 'Indonesia': ['Asia/Jakarta', - 'Asia/Pontianak', - 'Asia/Makassar', - 'Asia/Jayapura'], - 'Iran': ['Asia/Tehran'], - 'Iraq': ['Asia/Baghdad'], - 'Israel': ['Asia/Jerusalem'], - 'Italy': ['Europe/Rome'], - 'Jamaica': ['America/Jamaica'], - 'Japan': ['Asia/Tokyo'], - 'Jordan': ['Asia/Amman'], - 'Kazakhstan': ['Asia/Almaty', - 'Asia/Qyzylorda', - 'Asia/Aqtobe', - 'Asia/Aqtau', - 'Asia/Oral'], - 'Kenya': ['Africa/Nairobi'], - 'Kingdom of the Netherlands': ['Europe/Amsterdam'], - 'Kiribati': ['Pacific/Tarawa', 'Pacific/Enderbury', 'Pacific/Kiritimati'], - 'Kuwait': ['Asia/Kuwait'], - 'Kyrgyzstan': ['Asia/Bishkek'], - 'Laos': ['Asia/Vientiane'], - 'Latvia': ['Europe/Riga'], - 'Lebanon': ['Asia/Beirut'], - 'Lesotho': ['Africa/Maseru'], - 'Liberia': ['Africa/Monrovia'], - 'Libya': ['Africa/Tripoli'], - 'Liechtenstein': ['Europe/Vaduz'], - 'Lithuania': ['Europe/Vilnius'], - 'Luxembourg': ['Europe/Luxembourg'], - 'Macedonia': ['Europe/Skopje'], - 'Madagascar': ['Indian/Antananarivo'], - 'Malawi': ['Africa/Blantyre'], - 'Malaysia': ['Asia/Kuala_Lumpur', 'Asia/Kuching'], - 'Maldives': ['Indian/Maldives'], - 'Mali': ['Africa/Bamako'], - 'Malta': ['Europe/Malta'], - 'Marshall Islands': ['Pacific/Majuro', 'Pacific/Kwajalein'], - 'Mauritania': ['Africa/Nouakchott'], - 'Mauritius': ['Indian/Mauritius'], - 'Mexico': ['America/Mexico_City', - 'America/Cancun', - 'America/Merida', - 'America/Monterrey', - 'America/Mazatlan', - 'America/Chihuahua', - 'America/Hermosillo', - 'America/Tijuana'], - 'Moldova': ['Europe/Chisinau'], - 'Monaco': ['Europe/Monaco'], - 'Mongolia': ['Asia/Ulaanbaatar', 'Asia/Hovd', 'Asia/Choibalsan'], - 'Montenegro': ['Europe/Podgorica'], - 'Morocco': ['Africa/Casablanca'], - 'Mozambique': ['Africa/Maputo'], - 'Myanmar': ['Asia/Rangoon'], - 'Namibia': ['Africa/Windhoek'], - 'Nauru': ['Pacific/Nauru'], - 'Nepal': ['Asia/Katmandu'], - 'New Zealand': ['Pacific/Auckland', 'Pacific/Chatham'], - 'Nicaragua': ['America/Managua'], - 'Niger': ['Africa/Niamey'], - 'Nigeria': ['Africa/Lagos'], - 'North Korea': ['Asia/Pyongyang'], - 'Norway': ['Europe/Oslo'], - 'Oman': ['Asia/Muscat'], - 'Pakistan': ['Asia/Karachi'], - 'Palau': ['Pacific/Palau'], - 'Panama': ['America/Panama'], - 'Papua New Guinea': ['Pacific/Port_Moresby'], - 'Paraguay': ['America/Asuncion'], - 'Peru': ['America/Lima'], - 'Philippines': ['Asia/Manila'], - 'Poland': ['Europe/Warsaw'], - 'Portugal': ['Europe/Lisbon', 'Atlantic/Madeira', 'Atlantic/Azores'], - 'Qatar': ['Asia/Qatar'], - 'Republic of Ireland': ['Europe/Dublin'], - 'Republic of the Congo': ['Africa/Brazzaville'], - 'Romania': ['Europe/Bucharest'], - 'Russia': ['Europe/Kaliningrad', - 'Europe/Moscow', - 'Europe/Volgograd', - 'Europe/Samara', - 'Asia/Yekaterinburg', - 'Asia/Omsk', - 'Asia/Novosibirsk', - 'Asia/Krasnoyarsk', - 'Asia/Irkutsk', - 'Asia/Yakutsk', - 'Asia/Vladivostok', - 'Asia/Sakhalin', - 'Asia/Magadan', - 'Asia/Kamchatka', - 'Asia/Anadyr'], - 'Rwanda': ['Africa/Kigali'], - 'Saint Kitts and Nevis': ['America/St_Kitts'], - 'Saint Lucia': ['America/St_Lucia'], - 'Saint Vincent and the Grenadines': ['America/St_Vincent'], - 'Samoa': ['Pacific/Apia'], - 'San Marino': ['Europe/San_Marino'], - 'Saudi Arabia': ['Asia/Riyadh'], - 'Senegal': ['Africa/Dakar'], - 'Serbia': ['Europe/Belgrade'], - 'Seychelles': ['Indian/Mahe'], - 'Sierra Leone': ['Africa/Freetown'], - 'Singapore': ['Asia/Singapore'], - 'Slovakia': ['Europe/Bratislava'], - 'Slovenia': ['Europe/Ljubljana'], - 'Solomon Islands': ['Pacific/Guadalcanal'], - 'Somalia': ['Africa/Mogadishu'], - 'South Africa': ['Africa/Johannesburg'], - 'South Korea': ['Asia/Seoul'], - 'Spain': ['Europe/Madrid', 'Africa/Ceuta', 'Atlantic/Canary'], - 'Sri Lanka': ['Asia/Colombo'], - 'Sudan': ['Africa/Khartoum'], - 'Suriname': ['America/Paramaribo'], - 'Swaziland': ['Africa/Mbabane'], - 'Sweden': ['Europe/Stockholm'], - 'Switzerland': ['Europe/Zurich'], - 'Syria': ['Asia/Damascus'], - 'S\xc3\xa3o Tom\xc3\xa9 and Pr\xc3\xadncipe': ['Africa/Sao_Tome'], - 'Tajikistan': ['Asia/Dushanbe'], - 'Tanzania': ['Africa/Dar_es_Salaam'], - 'Thailand': ['Asia/Bangkok'], - 'The Gambia': ['Africa/Banjul'], - 'Togo': ['Africa/Lome'], - 'Tonga': ['Pacific/Tongatapu'], - 'Trinidad and Tobago': ['America/Port_of_Spain'], - 'Tunisia': ['Africa/Tunis'], - 'Turkey': ['Europe/Istanbul'], - 'Turkmenistan': ['Asia/Ashgabat'], - 'Tuvalu': ['Pacific/Funafuti'], - 'Uganda': ['Africa/Kampala'], - 'Ukraine': ['Europe/Kiev', - 'Europe/Uzhgorod', - 'Europe/Zaporozhye', - 'Europe/Simferopol'], - 'United Arab Emirates': ['Asia/Dubai'], - 'United Kingdom': ['Europe/London'], - 'United States': ['America/New_York', - 'America/Detroit', - 'America/Kentucky/Louisville', - 'America/Kentucky/Monticello', - 'America/Indiana/Indianapolis', - 'America/Indiana/Marengo', - 'America/Indiana/Knox', - 'America/Indiana/Vevay', - 'America/Chicago', - 'America/Indiana/Vincennes', - 'America/Indiana/Petersburg', - 'America/Menominee', - 'America/North_Dakota/Center', - 'America/North_Dakota/New_Salem', - 'America/Denver', - 'America/Boise', - 'America/Shiprock', - 'America/Phoenix', - 'America/Los_Angeles', - 'America/Anchorage', - 'America/Juneau', - 'America/Yakutat', - 'America/Nome', - 'America/Adak', - 'Pacific/Honolulu'], - 'Uruguay': ['America/Montevideo'], - 'Uzbekistan': ['Asia/Samarkand', 'Asia/Tashkent'], - 'Vanuatu': ['Pacific/Efate'], - 'Vatican City': ['Europe/Vatican'], - 'Venezuela': ['America/Caracas'], - 'Vietnam': ['Asia/Saigon'], - 'Yemen': ['Asia/Aden'], - 'Zambia': ['Africa/Lusaka'], - 'Zimbabwe': ['Africa/Harare'], - }, + + industry_list: ['', 'Aerospace and Defence', 'Agriculture', 'Apparel', 'Automobile', + 'Banking', 'Biotechnology', 'Chemical', 'Communications', 'Consulting', 'Customer Service', + 'Education', 'Electronics', 'Energy', 'Engineering', 'Entertainment', 'Environmental', + 'Finance', 'Food and Beverage', 'Government', 'Healthcare', 'Hospitality', + 'Information Technology', 'Insurance', 'Machinery', 'Manufacturing', 'Media', + 'Not For Profit', 'Recreation', 'Retail', 'Shipping', 'Technology', + 'Telecommunications', 'Transportation', 'Trading', 'Utilities', 'Other'], }); \ No newline at end of file diff --git a/public/js/queries.js b/public/js/queries.js index a6a79b5a02..e15e6867b4 100644 --- a/public/js/queries.js +++ b/public/js/queries.js @@ -53,9 +53,9 @@ erpnext.utils.lead_query = function() { // searches for customer erpnext.utils.customer_query = function() { if(sys_defaults.cust_master_name == "Customer Name") { - var fields = ["name", "customer_group", "country", "territory"]; + var fields = ["name", "customer_group", "territory"]; } else { - var fields = ["name", "customer_name", "customer_group", "country", "territory"]; + var fields = ["name", "customer_name", "customer_group", "territory"]; } return "select " + fields.join(", ") + " from `tabCustomer` where docstatus < 2 and \ diff --git a/selling/doctype/customer/customer.py b/selling/doctype/customer/customer.py index a3c9612419..8218b19bed 100644 --- a/selling/doctype/customer/customer.py +++ b/selling/doctype/customer/customer.py @@ -123,7 +123,7 @@ class DocType(TransactionBase): abbr = self.get_company_abbr() if not sql("select name from tabAccount where name=%s", (self.doc.name + " - " + abbr)): parent_account = self.get_receivables_group() - arg = {'account_name':self.doc.name,'parent_account': parent_account, 'group_or_ledger':'Ledger', 'company':self.doc.company,'account_type':'','tax_rate':'0','master_type':'Customer','master_name':self.doc.name,'address':self.doc.address} + arg = {'account_name':self.doc.name,'parent_account': parent_account, 'group_or_ledger':'Ledger', 'company':self.doc.company,'account_type':'','tax_rate':'0','master_type':'Customer','master_name':self.doc.name} # create ac = get_obj('GL Control').add_ac(cstr(arg)) @@ -172,11 +172,6 @@ class DocType(TransactionBase): pass def on_update(self): - # create customer addr - #self.create_customer_address() - # create customer contact - #self.create_customer_contact() - # update lead status self.update_lead_status() # create account head self.create_account_head() diff --git a/selling/doctype/quotation/quotation.js b/selling/doctype/quotation/quotation.js index 330e4e7e16..48367da8ab 100644 --- a/selling/doctype/quotation/quotation.js +++ b/selling/doctype/quotation/quotation.js @@ -299,7 +299,7 @@ cur_frm.fields_dict['quotation_details'].grid.get_field('item_code').get_query= and si_item.item_code = item.name \ and si.docstatus = 1 \ and si.customer = \"%(cust)s\" \ - order by si.voucher_date desc \ + order by si.posting_date desc \ limit 1 \ ) as sales_rate, \ item.item_name, item.description \ diff --git a/setup/doctype/company/company.py b/setup/doctype/company/company.py index e570b72814..124c3e48e9 100644 --- a/setup/doctype/company/company.py +++ b/setup/doctype/company/company.py @@ -162,7 +162,6 @@ class DocType: ac = Document('Account') for d in self.fld_dict.keys(): ac.fields[d] = (d == 'parent_account' and lst[self.fld_dict[d]]) and lst[self.fld_dict[d]] +' - '+ self.doc.abbr or lst[self.fld_dict[d]] - ac.old_parent = '' ac_obj = get_obj(doc=ac) ac_obj.doc.freeze_account='No' ac_obj.doc.master_type = '' @@ -199,7 +198,7 @@ class DocType: # --------------------------------------------------- def create_default_cost_center(self): glc = get_obj('GL Control') - cc_list = [{'cost_center_name':'Root','company_name':self.doc.name,'company_abbr':self.doc.abbr,'group_or_ledger':'Group','parent_cost_center':'','old_parent':''}, {'cost_center_name':'Default CC Ledger','company_name':self.doc.name,'company_abbr':self.doc.abbr,'group_or_ledger':'Ledger','parent_cost_center':'Root - ' + self.doc.abbr,'old_parent':''}] + cc_list = [{'cost_center_name':'Root','company_name':self.doc.name,'company_abbr':self.doc.abbr,'group_or_ledger':'Group','parent_cost_center':''}, {'cost_center_name':'Default CC Ledger','company_name':self.doc.name,'company_abbr':self.doc.abbr,'group_or_ledger':'Ledger','parent_cost_center':'Root - ' + self.doc.abbr}] for c in cc_list: glc.add_cc(str(c)) diff --git a/setup/doctype/country/country.txt b/setup/doctype/country/country.txt index c3e130322f..87a9d609cf 100644 --- a/setup/doctype/country/country.txt +++ b/setup/doctype/country/country.txt @@ -2,35 +2,24 @@ { "owner": "Administrator", "docstatus": 0, - "creation": "2012-03-27 14:36:19", + "creation": "2013-01-17 17:02:24", "modified_by": "Administrator", - "modified": "2012-03-27 14:36:19" + "modified": "2013-01-17 17:04:08" }, { - "section_style": "Simple", - "in_create": 0, - "module": "Setup", - "server_code_error": " ", - "document_type": "Master", "read_only": 0, "autoname": "field:country_name", - "name": "__common__", - "colour": "White:FFF", + "in_create": 0, "doctype": "DocType", - "show_in_menu": 0, - "version": 11 + "module": "Setup", + "document_type": "Master", + "name": "__common__" }, { - "parent": "Country", - "oldfieldtype": "Data", - "oldfieldname": "country_name", - "reqd": 1, "name": "__common__", + "parent": "Country", "doctype": "DocField", - "label": "Country Name", "parenttype": "DocType", - "fieldname": "country_name", - "fieldtype": "Data", "permlevel": 0, "parentfield": "fields" }, @@ -49,12 +38,33 @@ "name": "Country", "doctype": "DocType" }, + { + "oldfieldtype": "Data", + "doctype": "DocField", + "label": "Country Name", + "oldfieldname": "country_name", + "fieldname": "country_name", + "fieldtype": "Data", + "reqd": 1 + }, + { + "doctype": "DocField", + "label": "Date Format", + "fieldname": "date_format", + "fieldtype": "Data" + }, + { + "doctype": "DocField", + "label": "Time Zones", + "fieldname": "time_zones", + "fieldtype": "Text" + }, { "amend": 0, - "cancel": 0, - "role": "Sales Master Manager", "doctype": "DocPerm", - "submit": 0 + "submit": 0, + "role": "Sales Master Manager", + "cancel": 0 }, { "role": "Purchase Master Manager", @@ -67,8 +77,5 @@ { "role": "HR Manager", "doctype": "DocPerm" - }, - { - "doctype": "DocField" } ] \ No newline at end of file diff --git a/setup/doctype/currency/currency.txt b/setup/doctype/currency/currency.txt index bc3af25b09..fd75525874 100644 --- a/setup/doctype/currency/currency.txt +++ b/setup/doctype/currency/currency.txt @@ -2,36 +2,24 @@ { "owner": "Administrator", "docstatus": 0, - "creation": "2012-07-03 13:30:55", + "creation": "2013-01-17 12:30:28", "modified_by": "Administrator", - "modified": "2012-07-11 16:11:45" + "modified": "2013-01-17 16:24:59" }, { - "section_style": "Simple", - "description": "**Currency** Master", - "module": "Setup", - "allow_trash": 1, - "server_code_error": " ", - "in_create": 0, "read_only": 0, "autoname": "field:currency_name", - "name": "__common__", - "colour": "White:FFF", + "in_create": 0, + "description": "**Currency** Master", "doctype": "DocType", - "show_in_menu": 0, - "version": 1 + "module": "Setup", + "name": "__common__" }, { - "parent": "Currency", - "oldfieldtype": "Data", - "oldfieldname": "currency_name", - "reqd": 1, "name": "__common__", + "parent": "Currency", "doctype": "DocField", - "label": "Currency Name", "parenttype": "DocType", - "fieldname": "currency_name", - "fieldtype": "Data", "permlevel": 0, "parentfield": "fields" }, @@ -39,9 +27,7 @@ "name": "__common__", "parent": "Currency", "read": 1, - "create": 1, "doctype": "DocPerm", - "write": 1, "parenttype": "DocType", "permlevel": 0, "parentfield": "permissions" @@ -51,25 +37,44 @@ "doctype": "DocType" }, { - "cancel": 1, - "role": "Accounts Manager", + "oldfieldtype": "Data", + "doctype": "DocField", + "label": "Currency Name", + "oldfieldname": "currency_name", + "fieldname": "currency_name", + "fieldtype": "Data", + "reqd": 1 + }, + { + "doctype": "DocField", + "label": "Fraction", + "fieldname": "fraction", + "fieldtype": "Data" + }, + { + "doctype": "DocField", + "label": "Fraction Units", + "fieldname": "fraction_units", + "fieldtype": "Int" + }, + { + "doctype": "DocField", + "label": "Symbol", + "fieldname": "symbol", + "fieldtype": "Data" + }, + { + "amend": 0, + "create": 1, + "doctype": "DocPerm", + "submit": 0, + "write": 1, + "report": 1, + "role": "System Manager", + "cancel": 1 + }, + { + "role": "All", "doctype": "DocPerm" - }, - { - "amend": 0, - "cancel": 1, - "role": "Sales Master Manager", - "doctype": "DocPerm", - "submit": 0 - }, - { - "amend": 0, - "cancel": 0, - "role": "Purchase Master Manager", - "doctype": "DocPerm", - "submit": 0 - }, - { - "doctype": "DocField" } ] \ No newline at end of file diff --git a/setup/doctype/setup_control/setup_control.py b/setup/doctype/setup_control/setup_control.py index 3c073dafc1..4bc36481d5 100644 --- a/setup/doctype/setup_control/setup_control.py +++ b/setup/doctype/setup_control/setup_control.py @@ -50,33 +50,37 @@ class DocType: master_dict = {'Fiscal Year':{ 'year': curr_fiscal_year, 'year_start_date': fy_start_date, - 'company': args.get('company_name')}} + }} self.create_records(master_dict) # Company - master_dict = {'Company':{'company_name':args.get('company_name'), - 'abbr':args.get('company_abbr'), - 'default_currency':args.get('currency') - }} + master_dict = {'Company': { + 'company_name':args.get('company_name'), + 'abbr':args.get('company_abbr'), + 'default_currency':args.get('currency') + }} self.create_records(master_dict) - def_args = {'current_fiscal_year':curr_fiscal_year, - 'default_currency': args.get('currency'), - 'default_company':args.get('company_name'), - 'default_valuation_method':'FIFO', - 'default_stock_uom':'Nos', - 'date_format':'dd-mm-yyyy', - 'default_currency_format':'Lacs', - 'so_required':'No', - 'dn_required':'No', - 'po_required':'No', - 'pr_required':'No', - 'emp_created_by':'Naming Series', - 'cust_master_name':'Customer Name', - 'supp_master_name':'Supplier Name', - 'default_currency_format': \ - (args.get('currency')=='INR') and 'Lacs' or 'Millions' - } + def_args = { + 'current_fiscal_year':curr_fiscal_year, + 'default_currency': args.get('currency'), + "default_fraction_currency": webnotes.conn.get_value("Currency", + args.get("currency"), "fraction"), + 'default_company':args.get('company_name'), + 'default_valuation_method':'FIFO', + 'default_stock_uom':'Nos', + 'date_format': webnotes.conn.get_value("Country", + args.get("country"), "date_format"), + 'so_required':'No', + 'dn_required':'No', + 'po_required':'No', + 'pr_required':'No', + 'emp_created_by':'Naming Series', + 'cust_master_name':'Customer Name', + 'supp_master_name':'Supplier Name', + 'default_currency_format': \ + (args.get('currency')=='INR') and 'Lacs' or 'Millions' + } # Set self.set_defaults(def_args) @@ -185,8 +189,6 @@ class DocType: return fy, stdt, abbr - # Create Company and Fiscal Year - # ------------------------------- def create_records(self, master_dict): for d in master_dict.keys(): rec = Document(d) @@ -234,18 +236,12 @@ class DocType: on duplicate key update `password`=password(%s)""", (user_email, pwd, pwd)) - self.add_roles(pr) - - def add_roles(self, pr): - roles_list = ['Accounts Manager', 'Accounts User', 'Blogger', 'HR Manager', 'HR User', 'Maintenance User', 'Maintenance Manager', 'Material Manager', 'Material User', 'Material Master Manager', 'Manufacturing Manager', 'Manufacturing User', 'Projects User', 'Purchase Manager', 'Purchase User', 'Purchase Master Manager', 'Quality Manager', 'Sales Manager', 'Sales User', 'Sales Master Manager', 'Support Manager', 'Support Team', 'System Manager', 'Website Manager'] - for r in roles_list: - d = addchild(pr, 'userroles', 'UserRole') - d.role = r - d.save(1) - - # Add roles to Administrator profile - pr = Document('Profile','Administrator') - for r in roles_list: - d = addchild(pr,'userroles', 'UserRole') - d.role = r - d.save(1) \ No newline at end of file + self.add_all_roles_to(pr.name) + +def add_all_roles_to(name): + profile = webnotes.doc("Profile", name) + for role in webnotes.conn.sql("""select name from tabRole"""): + if role[0] not in ["Administrator", "Guest", "All", "Customer", "Supplier", "Partner"]: + d = profile.addchild("userroles", "UserRole") + d.role = role[0] + d.insert() \ No newline at end of file diff --git a/startup/install.py b/startup/install.py index b25f524745..e24f815c04 100644 --- a/startup/install.py +++ b/startup/install.py @@ -3,26 +3,18 @@ from __future__ import unicode_literals import webnotes def pre_import(): + webnotes.conn.begin() make_modules() make_roles() + webnotes.conn.commit() webnotes.reload_doc("utilities", "doctype", "gl_mapper") webnotes.reload_doc("utilities", "doctype", "gl_mapper_detail") def make_modules(): modules = [ - " Home", - " System", - " Utilities", - " Website", - " Setup", - " Selling", - " Buying", - " Projects", - " Accounts", - " Stock", - " Support", - " HR", - " Manufacturing"] + " Home", " System", " Utilities", " Website", " Setup", + " Selling", " Buying", " Projects", " Accounts", " Stock", + " Support", " HR", " Manufacturing"] for m in modules: doc = webnotes.doc(fielddata = { @@ -34,45 +26,78 @@ def make_modules(): def make_roles(): roles = [ - "Accounts Manager", - "Accounts User", - "Analytics", - "Auditor", - "Blogger", - "Customer", - "Employee", - "Expense Approver", - "HR Manager", - "HR User", - "Leave Approver", - "Maintenance Manager", - "Maintenance User", - "Manufacturing Manager", - "Manufacturing User", - "Material Manager", - "Material Master Manager", - "Material User", - "Partner", - "Projects User", - "Purchase Manager", - "Purchase Master Manager", - "Purchase User", - "Quality Manager", - "Sales Manager", - "Sales Master Manager", - "Sales User", - "Supplier", - "Support Manager", - "Support Team", - ] + "Accounts Manager", "Accounts User", "Analytics", "Auditor", + "Blogger", "Customer", "Employee", "Expense Approver", + "HR Manager", "HR User", "Leave Approver", "Maintenance Manager", + "Maintenance User", "Manufacturing Manager", "Manufacturing User", + "Material Manager", "Material Master Manager", "Material User", + "Partner", "Projects User", "Purchase Manager", "Purchase Master Manager", + "Purchase User", "Quality Manager", "Sales Manager", + "Sales Master Manager", "Sales User", "Supplier", "Support Manager", + "Support Team"] + for r in roles: doc = webnotes.doc(fielddata = { "doctype":"Role", "role_name": r }) doc.insert() - + def post_import(): + webnotes.conn.begin() + # feature setup + import_defaults() + import_country_and_currency() + + # home page + webnotes.conn.set_value('Control Panel', None, 'home_page', 'desktop') + + # features + feature_setup() + + # all roles to Administrator + from setup.doctype.setup_control.setup_control import add_all_roles_to + add_all_roles_to("Administrator") + + webnotes.conn.commit() + +def feature_setup(): + """save global defaults and features setup""" + doc = webnotes.doc("Features Setup", "Features Setup") + + # store value as 1 for all these fields + flds = ['fs_item_serial_nos', 'fs_item_batch_nos', 'fs_brands', 'fs_item_barcode', + 'fs_item_advanced', 'fs_packing_details', 'fs_item_group_in_details', + 'fs_exports', 'fs_imports', 'fs_discounts', 'fs_purchase_discounts', + 'fs_after_sales_installations', 'fs_projects', 'fs_sales_extras', + 'fs_recurring_invoice', 'fs_pos', 'fs_manufacturing', 'fs_quality', + 'fs_page_break', 'fs_more_info' + ] + doc.fields.update(dict(zip(flds, [1]*len(flds)))) + doc.save() + +def import_country_and_currency(): + from webnotes.country_info import get_all + data = get_all() + for name in data: + country = webnotes._dict(data[name]) + webnotes.doc({ + "doctype": "Country", + "country_name": name, + "date_format": country.date_format or "dd-mm-yyyy", + "time_zones": "\n".join(country.timezones or []) + }).insert() + + if country.currency: + webnotes.doc({ + "doctype": "Currency", + "currency_name": country.currency, + "fraction": country.currency_fraction, + "symbol": country.currency_symbol, + "fraction_units": country.currency_fraction_units + }).insert() + +def import_defaults(): records = [ # item group {'doctype': 'Item Group', 'item_group_name': 'All Item Groups', 'is_group': 'Yes', 'name': 'All Item Groups', 'parent_item_group': ''}, @@ -135,6 +160,7 @@ def post_import(): {'doctype': 'Sales Person', 'name': 'All Sales Persons', 'sales_person_name': 'All Sales Persons', 'is_group': "Yes", "parent_sales_person": ""}, # UOM + {'uom_name': 'Unit', 'doctype': 'UOM', 'name': 'Unit'}, {'uom_name': 'Box', 'doctype': 'UOM', 'name': 'Box'}, {'uom_name': 'Ft', 'doctype': 'UOM', 'name': 'Ft'}, {'uom_name': 'Kg', 'doctype': 'UOM', 'name': 'Kg'}, @@ -144,492 +170,8 @@ def post_import(): {'uom_name': 'Nos', 'doctype': 'UOM', 'name': 'Nos'}, {'uom_name': 'Pair', 'doctype': 'UOM', 'name': 'Pair'}, {'uom_name': 'Set', 'doctype': 'UOM', 'name': 'Set'}, - {'uom_name': 'T', 'doctype': 'UOM', 'name': 'T'}, - - # Currency - {'currency_name': 'AED', 'doctype': 'Currency', 'name': 'AED'}, - {'currency_name': 'AFN', 'doctype': 'Currency', 'name': 'AFN'}, - {'currency_name': 'ALL', 'doctype': 'Currency', 'name': 'ALL'}, - {'currency_name': 'AMD', 'doctype': 'Currency', 'name': 'AMD'}, - {'currency_name': 'ANG', 'doctype': 'Currency', 'name': 'ANG'}, - {'currency_name': 'AOA', 'doctype': 'Currency', 'name': 'AOA'}, - {'currency_name': 'ARS', 'doctype': 'Currency', 'name': 'ARS'}, - {'currency_name': 'AUD', 'doctype': 'Currency', 'name': 'AUD'}, - {'currency_name': 'AZN', 'doctype': 'Currency', 'name': 'AZN'}, - {'currency_name': 'BAM', 'doctype': 'Currency', 'name': 'BAM'}, - {'currency_name': 'BBD', 'doctype': 'Currency', 'name': 'BBD'}, - {'currency_name': 'BDT', 'doctype': 'Currency', 'name': 'BDT'}, - {'currency_name': 'BGN', 'doctype': 'Currency', 'name': 'BGN'}, - {'currency_name': 'BHD', 'doctype': 'Currency', 'name': 'BHD'}, - {'currency_name': 'BIF', 'doctype': 'Currency', 'name': 'BIF'}, - {'currency_name': 'BMD', 'doctype': 'Currency', 'name': 'BMD'}, - {'currency_name': 'BND', 'doctype': 'Currency', 'name': 'BND'}, - {'currency_name': 'BOB', 'doctype': 'Currency', 'name': 'BOB'}, - {'currency_name': 'BRL', 'doctype': 'Currency', 'name': 'BRL'}, - {'currency_name': 'BSD', 'doctype': 'Currency', 'name': 'BSD'}, - {'currency_name': 'BTN', 'doctype': 'Currency', 'name': 'BTN'}, - {'currency_name': 'BWP', 'doctype': 'Currency', 'name': 'BWP'}, - {'currency_name': 'BYR', 'doctype': 'Currency', 'name': 'BYR'}, - {'currency_name': 'BZD', 'doctype': 'Currency', 'name': 'BZD'}, - {'currency_name': 'CAD', 'doctype': 'Currency', 'name': 'CAD'}, - {'currency_name': 'CDF', 'doctype': 'Currency', 'name': 'CDF'}, - {'currency_name': 'CFA', 'doctype': 'Currency', 'name': 'CFA'}, - {'currency_name': 'CFP', 'doctype': 'Currency', 'name': 'CFP'}, - {'currency_name': 'CHF', 'doctype': 'Currency', 'name': 'CHF'}, - {'currency_name': 'CLP', 'doctype': 'Currency', 'name': 'CLP'}, - {'currency_name': 'CNY', 'doctype': 'Currency', 'name': 'CNY'}, - {'currency_name': 'COP', 'doctype': 'Currency', 'name': 'COP'}, - {'currency_name': 'CRC', 'doctype': 'Currency', 'name': 'CRC'}, - {'currency_name': 'CUC', 'doctype': 'Currency', 'name': 'CUC'}, - {'currency_name': 'CZK', 'doctype': 'Currency', 'name': 'CZK'}, - {'currency_name': 'DJF', 'doctype': 'Currency', 'name': 'DJF'}, - {'currency_name': 'DKK', 'doctype': 'Currency', 'name': 'DKK'}, - {'currency_name': 'DOP', 'doctype': 'Currency', 'name': 'DOP'}, - {'currency_name': 'DZD', 'doctype': 'Currency', 'name': 'DZD'}, - {'currency_name': 'EEK', 'doctype': 'Currency', 'name': 'EEK'}, - {'currency_name': 'EGP', 'doctype': 'Currency', 'name': 'EGP'}, - {'currency_name': 'ERN', 'doctype': 'Currency', 'name': 'ERN'}, - {'currency_name': 'ETB', 'doctype': 'Currency', 'name': 'ETB'}, - {'currency_name': 'EUR', 'doctype': 'Currency', 'name': 'EUR'}, - {'currency_name': 'FJD', 'doctype': 'Currency', 'name': 'FJD'}, - {'currency_name': 'FKP', 'doctype': 'Currency', 'name': 'FKP'}, - {'currency_name': 'FMG', 'doctype': 'Currency', 'name': 'FMG'}, - {'currency_name': 'GBP', 'doctype': 'Currency', 'name': 'GBP'}, - {'currency_name': 'GEL', 'doctype': 'Currency', 'name': 'GEL'}, - {'currency_name': 'GHS', 'doctype': 'Currency', 'name': 'GHS'}, - {'currency_name': 'GIP', 'doctype': 'Currency', 'name': 'GIP'}, - {'currency_name': 'GMD', 'doctype': 'Currency', 'name': 'GMD'}, - {'currency_name': 'GNF', 'doctype': 'Currency', 'name': 'GNF'}, - {'currency_name': 'GQE', 'doctype': 'Currency', 'name': 'GQE'}, - {'currency_name': 'GTQ', 'doctype': 'Currency', 'name': 'GTQ'}, - {'currency_name': 'GYD', 'doctype': 'Currency', 'name': 'GYD'}, - {'currency_name': 'HKD', 'doctype': 'Currency', 'name': 'HKD'}, - {'currency_name': 'HNL', 'doctype': 'Currency', 'name': 'HNL'}, - {'currency_name': 'HRK', 'doctype': 'Currency', 'name': 'HRK'}, - {'currency_name': 'HTG', 'doctype': 'Currency', 'name': 'HTG'}, - {'currency_name': 'HUF', 'doctype': 'Currency', 'name': 'HUF'}, - {'currency_name': 'IDR', 'doctype': 'Currency', 'name': 'IDR'}, - {'currency_name': 'ILS', 'doctype': 'Currency', 'name': 'ILS'}, - {'currency_name': 'INR', 'doctype': 'Currency', 'name': 'INR'}, - {'currency_name': 'IQD', 'doctype': 'Currency', 'name': 'IQD'}, - {'currency_name': 'IRR', 'doctype': 'Currency', 'name': 'IRR'}, - {'currency_name': 'ISK', 'doctype': 'Currency', 'name': 'ISK'}, - {'currency_name': 'JMD', 'doctype': 'Currency', 'name': 'JMD'}, - {'currency_name': 'JOD', 'doctype': 'Currency', 'name': 'JOD'}, - {'currency_name': 'JPY', 'doctype': 'Currency', 'name': 'JPY'}, - {'currency_name': 'KES', 'doctype': 'Currency', 'name': 'KES'}, - {'currency_name': 'KGS', 'doctype': 'Currency', 'name': 'KGS'}, - {'currency_name': 'KHR', 'doctype': 'Currency', 'name': 'KHR'}, - {'currency_name': 'KMF', 'doctype': 'Currency', 'name': 'KMF'}, - {'currency_name': 'KPW', 'doctype': 'Currency', 'name': 'KPW'}, - {'currency_name': 'KRW', 'doctype': 'Currency', 'name': 'KRW'}, - {'currency_name': 'KWD', 'doctype': 'Currency', 'name': 'KWD'}, - {'currency_name': 'KYD', 'doctype': 'Currency', 'name': 'KYD'}, - {'currency_name': 'KZT', 'doctype': 'Currency', 'name': 'KZT'}, - {'currency_name': 'LAK', 'doctype': 'Currency', 'name': 'LAK'}, - {'currency_name': 'LBP', 'doctype': 'Currency', 'name': 'LBP'}, - {'currency_name': 'LKR', 'doctype': 'Currency', 'name': 'LKR'}, - {'currency_name': 'LRD', 'doctype': 'Currency', 'name': 'LRD'}, - {'currency_name': 'LSL', 'doctype': 'Currency', 'name': 'LSL'}, - {'currency_name': 'LTL', 'doctype': 'Currency', 'name': 'LTL'}, - {'currency_name': 'LVL', 'doctype': 'Currency', 'name': 'LVL'}, - {'currency_name': 'LYD', 'doctype': 'Currency', 'name': 'LYD'}, - {'currency_name': 'MAD', 'doctype': 'Currency', 'name': 'MAD'}, - {'currency_name': 'MDL', 'doctype': 'Currency', 'name': 'MDL'}, - {'currency_name': 'MGA', 'doctype': 'Currency', 'name': 'MGA'}, - {'currency_name': 'MKD', 'doctype': 'Currency', 'name': 'MKD'}, - {'currency_name': 'MMK', 'doctype': 'Currency', 'name': 'MMK'}, - {'currency_name': 'MNT', 'doctype': 'Currency', 'name': 'MNT'}, - {'currency_name': 'MOP', 'doctype': 'Currency', 'name': 'MOP'}, - {'currency_name': 'MRO', 'doctype': 'Currency', 'name': 'MRO'}, - {'currency_name': 'MUR', 'doctype': 'Currency', 'name': 'MUR'}, - {'currency_name': 'MVR', 'doctype': 'Currency', 'name': 'MVR'}, - {'currency_name': 'MWK', 'doctype': 'Currency', 'name': 'MWK'}, - {'currency_name': 'MXN', 'doctype': 'Currency', 'name': 'MXN'}, - {'currency_name': 'MYR', 'doctype': 'Currency', 'name': 'MYR'}, - {'currency_name': 'MZM', 'doctype': 'Currency', 'name': 'MZM'}, - {'currency_name': 'NAD', 'doctype': 'Currency', 'name': 'NAD'}, - {'currency_name': 'NGN', 'doctype': 'Currency', 'name': 'NGN'}, - {'currency_name': 'NIO', 'doctype': 'Currency', 'name': 'NIO'}, - {'currency_name': 'NOK', 'doctype': 'Currency', 'name': 'NOK'}, - {'currency_name': 'NPR', 'doctype': 'Currency', 'name': 'NPR'}, - {'currency_name': 'NRs', 'doctype': 'Currency', 'name': 'NRs'}, - {'currency_name': 'NZD', 'doctype': 'Currency', 'name': 'NZD'}, - {'currency_name': 'OMR', 'doctype': 'Currency', 'name': 'OMR'}, - {'currency_name': 'PAB', 'doctype': 'Currency', 'name': 'PAB'}, - {'currency_name': 'PEN', 'doctype': 'Currency', 'name': 'PEN'}, - {'currency_name': 'PGK', 'doctype': 'Currency', 'name': 'PGK'}, - {'currency_name': 'PHP', 'doctype': 'Currency', 'name': 'PHP'}, - {'currency_name': 'PKR', 'doctype': 'Currency', 'name': 'PKR'}, - {'currency_name': 'PLN', 'doctype': 'Currency', 'name': 'PLN'}, - {'currency_name': 'PYG', 'doctype': 'Currency', 'name': 'PYG'}, - {'currency_name': 'QAR', 'doctype': 'Currency', 'name': 'QAR'}, - {'currency_name': 'RMB', 'doctype': 'Currency', 'name': 'RMB'}, - {'currency_name': 'RON', 'doctype': 'Currency', 'name': 'RON'}, - {'currency_name': 'RSD', 'doctype': 'Currency', 'name': 'RSD'}, - {'currency_name': 'RUB', 'doctype': 'Currency', 'name': 'RUB'}, - {'currency_name': 'RWF', 'doctype': 'Currency', 'name': 'RWF'}, - {'currency_name': 'SAR', 'doctype': 'Currency', 'name': 'SAR'}, - {'currency_name': 'SCR', 'doctype': 'Currency', 'name': 'SCR'}, - {'currency_name': 'SDG', 'doctype': 'Currency', 'name': 'SDG'}, - {'currency_name': 'SDR', 'doctype': 'Currency', 'name': 'SDR'}, - {'currency_name': 'SEK', 'doctype': 'Currency', 'name': 'SEK'}, - {'currency_name': 'SGD', 'doctype': 'Currency', 'name': 'SGD'}, - {'currency_name': 'SHP', 'doctype': 'Currency', 'name': 'SHP'}, - {'currency_name': 'SOS', 'doctype': 'Currency', 'name': 'SOS'}, - {'currency_name': 'SRD', 'doctype': 'Currency', 'name': 'SRD'}, - {'currency_name': 'STD', 'doctype': 'Currency', 'name': 'STD'}, - {'currency_name': 'SYP', 'doctype': 'Currency', 'name': 'SYP'}, - {'currency_name': 'SZL', 'doctype': 'Currency', 'name': 'SZL'}, - {'currency_name': 'THB', 'doctype': 'Currency', 'name': 'THB'}, - {'currency_name': 'TJS', 'doctype': 'Currency', 'name': 'TJS'}, - {'currency_name': 'TMT', 'doctype': 'Currency', 'name': 'TMT'}, - {'currency_name': 'TND', 'doctype': 'Currency', 'name': 'TND'}, - {'currency_name': 'TRY', 'doctype': 'Currency', 'name': 'TRY'}, - {'currency_name': 'TTD', 'doctype': 'Currency', 'name': 'TTD'}, - {'currency_name': 'TWD', 'doctype': 'Currency', 'name': 'TWD'}, - {'currency_name': 'TZS', 'doctype': 'Currency', 'name': 'TZS'}, - {'currency_name': 'UAE', 'doctype': 'Currency', 'name': 'UAE'}, - {'currency_name': 'UAH', 'doctype': 'Currency', 'name': 'UAH'}, - {'currency_name': 'UGX', 'doctype': 'Currency', 'name': 'UGX'}, - {'currency_name': 'USD', 'doctype': 'Currency', 'name': 'USD'}, - {'currency_name': 'UY', 'doctype': 'Currency', 'name': 'UY'}, - {'currency_name': 'UZS', 'doctype': 'Currency', 'name': 'UZS'}, - {'currency_name': 'VEB', 'doctype': 'Currency', 'name': 'VEB'}, - {'currency_name': 'VND', 'doctype': 'Currency', 'name': 'VND'}, - {'currency_name': 'VUV', 'doctype': 'Currency', 'name': 'VUV'}, - {'currency_name': 'WST', 'doctype': 'Currency', 'name': 'WST'}, - {'currency_name': 'XAF', 'doctype': 'Currency', 'name': 'XAF'}, - {'currency_name': 'XCD', 'doctype': 'Currency', 'name': 'XCD'}, - {'currency_name': 'XDR', 'doctype': 'Currency', 'name': 'XDR'}, - {'currency_name': 'XOF', 'doctype': 'Currency', 'name': 'XOF'}, - {'currency_name': 'XPF', 'doctype': 'Currency', 'name': 'XPF'}, - {'currency_name': 'YEN', 'doctype': 'Currency', 'name': 'YEN'}, - {'currency_name': 'YER', 'doctype': 'Currency', 'name': 'YER'}, - {'currency_name': 'YTL', 'doctype': 'Currency', 'name': 'YTL'}, - {'currency_name': 'ZAR', 'doctype': 'Currency', 'name': 'ZAR'}, - {'currency_name': 'ZMK', 'doctype': 'Currency', 'name': 'ZMK'}, - {'currency_name': 'ZWR', 'doctype': 'Currency', 'name': 'ZWR'}, - - # Country - {'country_name': 'Afghanistan', 'doctype': 'Country', 'name': 'Afghanistan'}, - {'country_name': 'Albania', 'doctype': 'Country', 'name': 'Albania'}, - {'country_name': 'Algeria', 'doctype': 'Country', 'name': 'Algeria'}, - {'country_name': 'Andorra', 'doctype': 'Country', 'name': 'Andorra'}, - {'country_name': 'Angola', 'doctype': 'Country', 'name': 'Angola'}, - {'country_name': 'Antarctica', 'doctype': 'Country', 'name': 'Antarctica'}, - {'country_name': 'Antigua and Barbuda', 'doctype': 'Country', 'name': 'Antigua and Barbuda'}, - {'country_name': 'Argentina', 'doctype': 'Country', 'name': 'Argentina'}, - {'country_name': 'Armenia', 'doctype': 'Country', 'name': 'Armenia'}, - {'country_name': 'Australia', 'doctype': 'Country', 'name': 'Australia'}, - {'country_name': 'Austria', 'doctype': 'Country', 'name': 'Austria'}, - {'country_name': 'Azerbaijan', 'doctype': 'Country', 'name': 'Azerbaijan'}, - {'country_name': 'Bahamas', 'doctype': 'Country', 'name': 'Bahamas'}, - {'country_name': 'Bahrain', 'doctype': 'Country', 'name': 'Bahrain'}, - {'country_name': 'Bangladesh', 'doctype': 'Country', 'name': 'Bangladesh'}, - {'country_name': 'Barbados', 'doctype': 'Country', 'name': 'Barbados'}, - {'country_name': 'Belarus', 'doctype': 'Country', 'name': 'Belarus'}, - {'country_name': 'Belgium', 'doctype': 'Country', 'name': 'Belgium'}, - {'country_name': 'Belize', 'doctype': 'Country', 'name': 'Belize'}, - {'country_name': 'Benin', 'doctype': 'Country', 'name': 'Benin'}, - {'country_name': 'Bermuda', 'doctype': 'Country', 'name': 'Bermuda'}, - {'country_name': 'Bhutan', 'doctype': 'Country', 'name': 'Bhutan'}, - {'country_name': 'Bolivia', 'doctype': 'Country', 'name': 'Bolivia'}, - {'country_name': 'Bosnia and Herzegovina', 'doctype': 'Country', 'name': 'Bosnia and Herzegovina'}, - {'country_name': 'Botswana', 'doctype': 'Country', 'name': 'Botswana'}, - {'country_name': 'Brazil', 'doctype': 'Country', 'name': 'Brazil'}, - {'country_name': 'Brunei', 'doctype': 'Country', 'name': 'Brunei'}, - {'country_name': 'Bulgaria', 'doctype': 'Country', 'name': 'Bulgaria'}, - {'country_name': 'Burkina Faso', 'doctype': 'Country', 'name': 'Burkina Faso'}, - {'country_name': 'Burma', 'doctype': 'Country', 'name': 'Burma'}, - {'country_name': 'Burundi', 'doctype': 'Country', 'name': 'Burundi'}, - {'country_name': 'Cambodia', 'doctype': 'Country', 'name': 'Cambodia'}, - {'country_name': 'Cameroon', 'doctype': 'Country', 'name': 'Cameroon'}, - {'country_name': 'Canada', 'doctype': 'Country', 'name': 'Canada'}, - {'country_name': 'Cape Verde', 'doctype': 'Country', 'name': 'Cape Verde'}, - {'country_name': 'Central African Republic', 'doctype': 'Country', 'name': 'Central African Republic'}, - {'country_name': 'Chad', 'doctype': 'Country', 'name': 'Chad'}, - {'country_name': 'Chile', 'doctype': 'Country', 'name': 'Chile'}, - {'country_name': 'China', 'doctype': 'Country', 'name': 'China'}, - {'country_name': 'Colombia', 'doctype': 'Country', 'name': 'Colombia'}, - {'country_name': 'Comoros', 'doctype': 'Country', 'name': 'Comoros'}, - {'country_name': 'Congo, Democratic Republic', 'doctype': 'Country', 'name': 'Congo, Democratic Republic'}, - {'country_name': 'Congo, Republic of the', 'doctype': 'Country', 'name': 'Congo, Republic of the'}, - {'country_name': 'Costa Rica', 'doctype': 'Country', 'name': 'Costa Rica'}, - {'country_name': 'Cote dIvoire', 'doctype': 'Country', 'name': 'Cote dIvoire'}, - {'country_name': 'Croatia', 'doctype': 'Country', 'name': 'Croatia'}, - {'country_name': 'Cuba', 'doctype': 'Country', 'name': 'Cuba'}, - {'country_name': 'Cyprus', 'doctype': 'Country', 'name': 'Cyprus'}, - {'country_name': 'Czech Republic', 'doctype': 'Country', 'name': 'Czech Republic'}, - {'country_name': 'Denmark', 'doctype': 'Country', 'name': 'Denmark'}, - {'country_name': 'Djibouti', 'doctype': 'Country', 'name': 'Djibouti'}, - {'country_name': 'Dominica', 'doctype': 'Country', 'name': 'Dominica'}, - {'country_name': 'Dominican Republic', 'doctype': 'Country', 'name': 'Dominican Republic'}, - {'country_name': 'East Timor', 'doctype': 'Country', 'name': 'East Timor'}, - {'country_name': 'Ecuador', 'doctype': 'Country', 'name': 'Ecuador'}, - {'country_name': 'Egypt', 'doctype': 'Country', 'name': 'Egypt'}, - {'country_name': 'El Salvador', 'doctype': 'Country', 'name': 'El Salvador'}, - {'country_name': 'Equatorial Guinea', 'doctype': 'Country', 'name': 'Equatorial Guinea'}, - {'country_name': 'Eritrea', 'doctype': 'Country', 'name': 'Eritrea'}, - {'country_name': 'Estonia', 'doctype': 'Country', 'name': 'Estonia'}, - {'country_name': 'Ethiopia', 'doctype': 'Country', 'name': 'Ethiopia'}, - {'country_name': 'Fiji', 'doctype': 'Country', 'name': 'Fiji'}, - {'country_name': 'Finland', 'doctype': 'Country', 'name': 'Finland'}, - {'country_name': 'France', 'doctype': 'Country', 'name': 'France'}, - {'country_name': 'Gabon', 'doctype': 'Country', 'name': 'Gabon'}, - {'country_name': 'Gambia', 'doctype': 'Country', 'name': 'Gambia'}, - {'country_name': 'Georgia', 'doctype': 'Country', 'name': 'Georgia'}, - {'country_name': 'Germany', 'doctype': 'Country', 'name': 'Germany'}, - {'country_name': 'Ghana', 'doctype': 'Country', 'name': 'Ghana'}, - {'country_name': 'Greece', 'doctype': 'Country', 'name': 'Greece'}, - {'country_name': 'Greenland', 'doctype': 'Country', 'name': 'Greenland'}, - {'country_name': 'Grenada', 'doctype': 'Country', 'name': 'Grenada'}, - {'country_name': 'Guatemala', 'doctype': 'Country', 'name': 'Guatemala'}, - {'country_name': 'Guinea', 'doctype': 'Country', 'name': 'Guinea'}, - {'country_name': 'Guinea-Bissa', 'doctype': 'Country', 'name': 'Guinea-Bissa'}, - {'country_name': 'Guyana', 'doctype': 'Country', 'name': 'Guyana'}, - {'country_name': 'Haiti', 'doctype': 'Country', 'name': 'Haiti'}, - {'country_name': 'Honduras', 'doctype': 'Country', 'name': 'Honduras'}, - {'country_name': 'Hong Kong', 'doctype': 'Country', 'name': 'Hong Kong'}, - {'country_name': 'Hungary', 'doctype': 'Country', 'name': 'Hungary'}, - {'country_name': 'Iceland', 'doctype': 'Country', 'name': 'Iceland'}, - {'country_name': 'India', 'doctype': 'Country', 'name': 'India'}, - {'country_name': 'Indonesia', 'doctype': 'Country', 'name': 'Indonesia'}, - {'country_name': 'Iran', 'doctype': 'Country', 'name': 'Iran'}, - {'country_name': 'Iraq', 'doctype': 'Country', 'name': 'Iraq'}, - {'country_name': 'Ireland', 'doctype': 'Country', 'name': 'Ireland'}, - {'country_name': 'Israel', 'doctype': 'Country', 'name': 'Israel'}, - {'country_name': 'Italy', 'doctype': 'Country', 'name': 'Italy'}, - {'country_name': 'Jamaica', 'doctype': 'Country', 'name': 'Jamaica'}, - {'country_name': 'Japan', 'doctype': 'Country', 'name': 'Japan'}, - {'country_name': 'Jordan', 'doctype': 'Country', 'name': 'Jordan'}, - {'country_name': 'Kazakhstan', 'doctype': 'Country', 'name': 'Kazakhstan'}, - {'country_name': 'Kenya', 'doctype': 'Country', 'name': 'Kenya'}, - {'country_name': 'Kiribati', 'doctype': 'Country', 'name': 'Kiribati'}, - {'country_name': 'Korea, North', 'doctype': 'Country', 'name': 'Korea, North'}, - {'country_name': 'Korea, South', 'doctype': 'Country', 'name': 'Korea, South'}, - {'country_name': 'Kuwait', 'doctype': 'Country', 'name': 'Kuwait'}, - {'country_name': 'Kyrgyzstan', 'doctype': 'Country', 'name': 'Kyrgyzstan'}, - {'country_name': 'Laos', 'doctype': 'Country', 'name': 'Laos'}, - {'country_name': 'Latvia', 'doctype': 'Country', 'name': 'Latvia'}, - {'country_name': 'Lebanon', 'doctype': 'Country', 'name': 'Lebanon'}, - {'country_name': 'Lesotho', 'doctype': 'Country', 'name': 'Lesotho'}, - {'country_name': 'Liberia', 'doctype': 'Country', 'name': 'Liberia'}, - {'country_name': 'Libya', 'doctype': 'Country', 'name': 'Libya'}, - {'country_name': 'Liechtenstein', 'doctype': 'Country', 'name': 'Liechtenstein'}, - {'country_name': 'Lithuania', 'doctype': 'Country', 'name': 'Lithuania'}, - {'country_name': 'Luxembourg', 'doctype': 'Country', 'name': 'Luxembourg'}, - {'country_name': 'Macedonia', 'doctype': 'Country', 'name': 'Macedonia'}, - {'country_name': 'Madagascar', 'doctype': 'Country', 'name': 'Madagascar'}, - {'country_name': 'Malawi', 'doctype': 'Country', 'name': 'Malawi'}, - {'country_name': 'Malaysia', 'doctype': 'Country', 'name': 'Malaysia'}, - {'country_name': 'Maldives', 'doctype': 'Country', 'name': 'Maldives'}, - {'country_name': 'Mali', 'doctype': 'Country', 'name': 'Mali'}, - {'country_name': 'Malta', 'doctype': 'Country', 'name': 'Malta'}, - {'country_name': 'Marshall Islands', 'doctype': 'Country', 'name': 'Marshall Islands'}, - {'country_name': 'Mauritania', 'doctype': 'Country', 'name': 'Mauritania'}, - {'country_name': 'Mauritius', 'doctype': 'Country', 'name': 'Mauritius'}, - {'country_name': 'Mexico', 'doctype': 'Country', 'name': 'Mexico'}, - {'country_name': 'Micronesia', 'doctype': 'Country', 'name': 'Micronesia'}, - {'country_name': 'Moldova', 'doctype': 'Country', 'name': 'Moldova'}, - {'country_name': 'Monaco', 'doctype': 'Country', 'name': 'Monaco'}, - {'country_name': 'Mongolia', 'doctype': 'Country', 'name': 'Mongolia'}, - {'country_name': 'Morocco', 'doctype': 'Country', 'name': 'Morocco'}, - {'country_name': 'Mozambique', 'doctype': 'Country', 'name': 'Mozambique'}, - {'country_name': 'Namibia', 'doctype': 'Country', 'name': 'Namibia'}, - {'country_name': 'Naur', 'doctype': 'Country', 'name': 'Naur'}, - {'country_name': 'Nepal', 'doctype': 'Country', 'name': 'Nepal'}, - {'country_name': 'Netherlands', 'doctype': 'Country', 'name': 'Netherlands'}, - {'country_name': 'New Zealand', 'doctype': 'Country', 'name': 'New Zealand'}, - {'country_name': 'Nicaragua', 'doctype': 'Country', 'name': 'Nicaragua'}, - {'country_name': 'Niger', 'doctype': 'Country', 'name': 'Niger'}, - {'country_name': 'Nigeria', 'doctype': 'Country', 'name': 'Nigeria'}, - {'country_name': 'North Korea', 'doctype': 'Country', 'name': 'North Korea'}, - {'country_name': 'Norway', 'doctype': 'Country', 'name': 'Norway'}, - {'country_name': 'Oman', 'doctype': 'Country', 'name': 'Oman'}, - {'country_name': 'Pakistan', 'doctype': 'Country', 'name': 'Pakistan'}, - {'country_name': 'Panama', 'doctype': 'Country', 'name': 'Panama'}, - {'country_name': 'Papua New Guinea', 'doctype': 'Country', 'name': 'Papua New Guinea'}, - {'country_name': 'Paraguay', 'doctype': 'Country', 'name': 'Paraguay'}, - {'country_name': 'Per', 'doctype': 'Country', 'name': 'Per'}, - {'country_name': 'Philippines', 'doctype': 'Country', 'name': 'Philippines'}, - {'country_name': 'Poland', 'doctype': 'Country', 'name': 'Poland'}, - {'country_name': 'Portugal', 'doctype': 'Country', 'name': 'Portugal'}, - {'country_name': 'Qatar', 'doctype': 'Country', 'name': 'Qatar'}, - {'country_name': 'Romania', 'doctype': 'Country', 'name': 'Romania'}, - {'country_name': 'Russia', 'doctype': 'Country', 'name': 'Russia'}, - {'country_name': 'Rwanda', 'doctype': 'Country', 'name': 'Rwanda'}, - {'country_name': 'Samoa', 'doctype': 'Country', 'name': 'Samoa'}, - {'country_name': 'San Marino', 'doctype': 'Country', 'name': 'San Marino'}, - {'country_name': ' Sao Tome', 'doctype': 'Country', 'name': 'Sao Tome'}, - {'country_name': 'Saudi Arabia', 'doctype': 'Country', 'name': 'Saudi Arabia'}, - {'country_name': 'Senegal', 'doctype': 'Country', 'name': 'Senegal'}, - {'country_name': 'Serbia and Montenegro', 'doctype': 'Country', 'name': 'Serbia and Montenegro'}, - {'country_name': 'Seychelles', 'doctype': 'Country', 'name': 'Seychelles'}, - {'country_name': 'Sierra Leone', 'doctype': 'Country', 'name': 'Sierra Leone'}, - {'country_name': 'Singapore', 'doctype': 'Country', 'name': 'Singapore'}, - {'country_name': 'Slovakia', 'doctype': 'Country', 'name': 'Slovakia'}, - {'country_name': 'Slovenia', 'doctype': 'Country', 'name': 'Slovenia'}, - {'country_name': 'Solomon Islands', 'doctype': 'Country', 'name': 'Solomon Islands'}, - {'country_name': 'Somalia', 'doctype': 'Country', 'name': 'Somalia'}, - {'country_name': 'South Africa', 'doctype': 'Country', 'name': 'South Africa'}, - {'country_name': 'South Korea', 'doctype': 'Country', 'name': 'South Korea'}, - {'country_name': 'Spain', 'doctype': 'Country', 'name': 'Spain'}, - {'country_name': 'Sri Lanka', 'doctype': 'Country', 'name': 'Sri Lanka'}, - {'country_name': 'Sudan', 'doctype': 'Country', 'name': 'Sudan'}, - {'country_name': 'Suriname', 'doctype': 'Country', 'name': 'Suriname'}, - {'country_name': 'Swaziland', 'doctype': 'Country', 'name': 'Swaziland'}, - {'country_name': 'Sweden', 'doctype': 'Country', 'name': 'Sweden'}, - {'country_name': 'Switzerland', 'doctype': 'Country', 'name': 'Switzerland'}, - {'country_name': 'Syria', 'doctype': 'Country', 'name': 'Syria'}, - {'country_name': 'Taiwan', 'doctype': 'Country', 'name': 'Taiwan'}, - {'country_name': 'Tajikistan', 'doctype': 'Country', 'name': 'Tajikistan'}, - {'country_name': 'Tanzania', 'doctype': 'Country', 'name': 'Tanzania'}, - {'country_name': 'Thailand', 'doctype': 'Country', 'name': 'Thailand'}, - {'country_name': 'Togo', 'doctype': 'Country', 'name': 'Togo'}, - {'country_name': 'Tonga', 'doctype': 'Country', 'name': 'Tonga'}, - {'country_name': 'Trinidad and Tobago', 'doctype': 'Country', 'name': 'Trinidad and Tobago'}, - {'country_name': 'Tunisia', 'doctype': 'Country', 'name': 'Tunisia'}, - {'country_name': 'Turkey', 'doctype': 'Country', 'name': 'Turkey'}, - {'country_name': 'Turkmenistan', 'doctype': 'Country', 'name': 'Turkmenistan'}, - {'country_name': 'Uganda', 'doctype': 'Country', 'name': 'Uganda'}, - {'country_name': 'Ukraine', 'doctype': 'Country', 'name': 'Ukraine'}, - {'country_name': 'United Arab Emirates', 'doctype': 'Country', 'name': 'United Arab Emirates'}, - {'country_name': 'United Kingdom', 'doctype': 'Country', 'name': 'United Kingdom'}, - {'country_name': 'United States', 'doctype': 'Country', 'name': 'United States'}, - {'country_name': 'Uruguay', 'doctype': 'Country', 'name': 'Uruguay'}, - {'country_name': 'Uzbekistan', 'doctype': 'Country', 'name': 'Uzbekistan'}, - {'country_name': 'Vanuat', 'doctype': 'Country', 'name': 'Vanuat'}, - {'country_name': 'Venezuela', 'doctype': 'Country', 'name': 'Venezuela'}, - {'country_name': 'Vietnam', 'doctype': 'Country', 'name': 'Vietnam'}, - {'country_name': 'Yemen', 'doctype': 'Country', 'name': 'Yemen'}, - {'country_name': 'Zambia', 'doctype': 'Country', 'name': 'Zambia'}, - {'country_name': 'Zimbabwe', 'doctype': 'Country', 'name': 'Zimbabwe'}, - - # State - {'state_name': 'Alabama', 'country': 'United States', 'doctype': 'State', 'name': 'Alabama'}, - {'state_name': 'Alaska', 'country': 'United States', 'doctype': 'State', 'name': 'Alaska'}, - {'state_name': 'Andaman and Nicobar Islands', 'country': 'India', 'doctype': 'State', 'name': 'Andaman and Nicobar Islands'}, - {'state_name': 'Andhra Pradesh', 'country': 'India', 'doctype': 'State', 'name': 'Andhra Pradesh'}, - {'state_name': 'Arizona', 'country': 'United States', 'doctype': 'State', 'name': 'Arizona'}, - {'state_name': 'Arkansas', 'country': 'United States', 'doctype': 'State', 'name': 'Arkansas'}, - {'state_name': 'Arunachal Pradesh', 'country': 'India', 'doctype': 'State', 'name': 'Arunachal Pradesh'}, - {'state_name': 'Assam', 'country': 'India', 'doctype': 'State', 'name': 'Assam'}, - {'state_name': 'Beijing ', 'country': 'China', 'doctype': 'State', 'name': 'Beijing'}, - {'state_name': 'Bihar', 'country': 'India', 'doctype': 'State', 'name': 'Bihar'}, - {'state_name': 'California', 'country': 'United States', 'doctype': 'State', 'name': 'California'}, - {'state_name': 'Chandigarh', 'country': 'India', 'doctype': 'State', 'name': 'Chandigarh'}, - {'state_name': 'Changchun ', 'country': 'China', 'doctype': 'State', 'name': 'Changchun'}, - {'state_name': 'Chengde', 'country': 'China', 'doctype': 'State', 'name': 'Chengde'}, - {'state_name': 'Chengdu', 'country': 'China', 'doctype': 'State', 'name': 'Chengdu'}, - {'state_name': 'Chhattisgarh', 'country': 'India', 'doctype': 'State', 'name': 'Chhattisgarh'}, - {'state_name': 'Chongqing ', 'country': 'China', 'doctype': 'State', 'name': 'Chongqing'}, - {'state_name': 'Colorado', 'country': 'United States', 'doctype': 'State', 'name': 'Colorado'}, - {'state_name': 'Connecticut', 'country': 'United States', 'doctype': 'State', 'name': 'Connecticut'}, - {'state_name': 'Dadra and Nagar Haveli', 'country': 'India', 'doctype': 'State', 'name': 'Dadra and Nagar Haveli'}, - {'state_name': 'Dalian', 'country': 'China', 'doctype': 'State', 'name': 'Dalian'}, - {'state_name': 'Daman and Di', 'country': 'India', 'doctype': 'State', 'name': 'Daman and Di'}, - {'state_name': 'Delaware', 'country': 'United States', 'doctype': 'State', 'name': 'Delaware'}, - {'state_name': 'Delhi', 'country': 'India', 'doctype': 'State', 'name': 'Delhi'}, - {'state_name': 'Dongguan ', 'country': 'China', 'doctype': 'State', 'name': 'Dongguan'}, - {'state_name': 'Dunhuang ', 'country': 'China', 'doctype': 'State', 'name': 'Dunhuang'}, - {'state_name': 'Florida', 'country': 'United States', 'doctype': 'State', 'name': 'Florida'}, - {'state_name': 'Georgia', 'country': 'United States', 'doctype': 'State', 'name': 'Georgia'}, - {'state_name': 'Goa', 'country': 'India', 'doctype': 'State', 'name': 'Goa'}, - {'state_name': 'Guangzho', 'country': 'China', 'doctype': 'State', 'name': 'Guangzho'}, - {'state_name': 'Guilin ', 'country': 'China', 'doctype': 'State', 'name': 'Guilin'}, - {'state_name': 'Gujarat', 'country': 'India', 'doctype': 'State', 'name': 'Gujarat'}, - {'state_name': 'Hangzhou', 'country': 'China', 'doctype': 'State', 'name': 'Hangzhou'}, - {'state_name': 'Harbin', 'country': 'China', 'doctype': 'State', 'name': 'Harbin'}, - {'state_name': 'Haryana', 'country': 'India', 'doctype': 'State', 'name': 'Haryana'}, - {'state_name': 'Hawaii', 'country': 'United States', 'doctype': 'State', 'name': 'Hawaii'}, - {'state_name': 'Hefei ', 'country': 'China', 'doctype': 'State', 'name': 'Hefei'}, - {'state_name': 'Himachal Pradesh', 'country': 'India', 'doctype': 'State', 'name': 'Himachal Pradesh'}, - {'state_name': 'Idaho', 'country': 'United States', 'doctype': 'State', 'name': 'Idaho'}, - {'state_name': 'Illinois', 'country': 'United States', 'doctype': 'State', 'name': 'Illinois'}, - {'state_name': 'Indiana', 'country': 'United States', 'doctype': 'State', 'name': 'Indiana'}, - {'state_name': 'Iowa', 'country': 'United States', 'doctype': 'State', 'name': 'Iowa'}, - {'state_name': 'Jammu and Kashmir', 'country': 'India', 'doctype': 'State', 'name': 'Jammu and Kashmir'}, - {'state_name': 'Jharkhand', 'country': 'India', 'doctype': 'State', 'name': 'Jharkhand'}, - {'state_name': 'Jinan ', 'country': 'China', 'doctype': 'State', 'name': 'Jinan'}, - {'state_name': 'Kansas', 'country': 'United States', 'doctype': 'State', 'name': 'Kansas'}, - {'state_name': 'Karnataka', 'country': 'India', 'doctype': 'State', 'name': 'Karnataka'}, - {'state_name': 'Kashi', 'country': 'China', 'doctype': 'State', 'name': 'Kashi'}, - {'state_name': 'Kentucky', 'country': 'United States', 'doctype': 'State', 'name': 'Kentucky'}, - {'state_name': 'Kerala', 'country': 'India', 'doctype': 'State', 'name': 'Kerala'}, - {'state_name': 'Kowloon ', 'country': 'China', 'doctype': 'State', 'name': 'Kowloon'}, - {'state_name': 'Kunming ', 'country': 'China', 'doctype': 'State', 'name': 'Kunming'}, - {'state_name': 'Lakshadweep', 'country': 'India', 'doctype': 'State', 'name': 'Lakshadweep'}, - {'state_name': 'Lanzho', 'country': 'China', 'doctype': 'State', 'name': 'Lanzho'}, - {'state_name': 'Lijiang City ', 'country': 'China', 'doctype': 'State', 'name': 'Lijiang City'}, - {'state_name': 'Louisiana', 'country': 'United States', 'doctype': 'State', 'name': 'Louisiana'}, - {'state_name': 'Madhya Pradesh', 'country': 'India', 'doctype': 'State', 'name': 'Madhya Pradesh'}, - {'state_name': 'Maharashtra', 'country': 'India', 'doctype': 'State', 'name': 'Maharashtra'}, - {'state_name': 'Maine', 'country': 'United States', 'doctype': 'State', 'name': 'Maine'}, - {'state_name': 'Manipur', 'country': 'India', 'doctype': 'State', 'name': 'Manipur'}, - {'state_name': 'Maryland', 'country': 'United States', 'doctype': 'State', 'name': 'Maryland'}, - {'state_name': 'Massachusetts', 'country': 'United States', 'doctype': 'State', 'name': 'Massachusetts'}, - {'state_name': 'Meghalaya', 'country': 'India', 'doctype': 'State', 'name': 'Meghalaya'}, - {'state_name': 'Michigan', 'country': 'United States', 'doctype': 'State', 'name': 'Michigan'}, - {'state_name': 'Minnesota', 'country': 'United States', 'doctype': 'State', 'name': 'Minnesota'}, - {'state_name': 'Mississippi', 'country': 'United States', 'doctype': 'State', 'name': 'Mississippi'}, - {'state_name': 'Missouri', 'country': 'United States', 'doctype': 'State', 'name': 'Missouri'}, - {'state_name': 'Mizoram', 'country': 'India', 'doctype': 'State', 'name': 'Mizoram'}, - {'state_name': 'Montana', 'country': 'United States', 'doctype': 'State', 'name': 'Montana'}, - {'state_name': 'Nagaland', 'country': 'India', 'doctype': 'State', 'name': 'Nagaland'}, - {'state_name': 'Nanchang ', 'country': 'China', 'doctype': 'State', 'name': 'Nanchang'}, - {'state_name': 'Nanjing', 'country': 'China', 'doctype': 'State', 'name': 'Nanjing'}, - {'state_name': 'Nebraska', 'country': 'United States', 'doctype': 'State', 'name': 'Nebraska'}, - {'state_name': 'Nevada', 'country': 'United States', 'doctype': 'State', 'name': 'Nevada'}, - {'state_name': 'New Hampshire', 'country': 'United States', 'doctype': 'State', 'name': 'New Hampshire'}, - {'state_name': 'New Jersey', 'country': 'United States', 'doctype': 'State', 'name': 'New Jersey'}, - {'state_name': 'New Mexico', 'country': 'United States', 'doctype': 'State', 'name': 'New Mexico'}, - {'state_name': 'New York', 'country': 'United States', 'doctype': 'State', 'name': 'New York'}, - {'state_name': 'Ningbo ', 'country': 'China', 'doctype': 'State', 'name': 'Ningbo'}, - {'state_name': 'North Carolina', 'country': 'United States', 'doctype': 'State', 'name': 'North Carolina'}, - {'state_name': 'North Dakota', 'country': 'United States', 'doctype': 'State', 'name': 'North Dakota'}, - {'state_name': 'Ohio', 'country': 'United States', 'doctype': 'State', 'name': 'Ohio'}, - {'state_name': 'Oklahoma', 'country': 'United States', 'doctype': 'State', 'name': 'Oklahoma'}, - {'state_name': 'Oregon', 'country': 'United States', 'doctype': 'State', 'name': 'Oregon'}, - {'state_name': 'Orissa', 'country': 'India', 'doctype': 'State', 'name': 'Orissa'}, - {'state_name': 'Pennsylvania', 'country': 'United States', 'doctype': 'State', 'name': 'Pennsylvania'}, - {'state_name': 'Puducherry', 'country': 'India', 'doctype': 'State', 'name': 'Puducherry'}, - {'state_name': 'Punjab', 'country': 'India', 'doctype': 'State', 'name': 'Punjab'}, - {'state_name': 'Qingdao ', 'country': 'China', 'doctype': 'State', 'name': 'Qingdao'}, - {'state_name': 'Quf', 'country': 'China', 'doctype': 'State', 'name': 'Quf'}, - {'state_name': 'Rajasthan', 'country': 'India', 'doctype': 'State', 'name': 'Rajasthan'}, - {'state_name': 'Rhode Island', 'country': 'United States', 'doctype': 'State', 'name': 'Rhode Island'}, - {'state_name': 'Sanya ', 'country': 'China', 'doctype': 'State', 'name': 'Sanya'}, - {'state_name': 'Shanghai ', 'country': 'China', 'doctype': 'State', 'name': 'Shanghai'}, - {'state_name': 'Shenyang', 'country': 'China', 'doctype': 'State', 'name': 'Shenyang'}, - {'state_name': 'Shenzhen', 'country': 'China', 'doctype': 'State', 'name': 'Shenzhen'}, - {'state_name': 'Sikkim', 'country': 'India', 'doctype': 'State', 'name': 'Sikkim'}, - {'state_name': 'South Carolina', 'country': 'United States', 'doctype': 'State', 'name': 'South Carolina'}, - {'state_name': 'South Dakota', 'country': 'United States', 'doctype': 'State', 'name': 'South Dakota'}, - {'state_name': 'Suzho', 'country': 'China', 'doctype': 'State', 'name': 'Suzho'}, - {'state_name': 'Tamil Nad', 'country': 'India', 'doctype': 'State', 'name': 'Tamil Nad'}, - {'state_name': 'Tennessee', 'country': 'United States', 'doctype': 'State', 'name': 'Tennessee'}, - {'state_name': 'Texas', 'country': 'United States', 'doctype': 'State', 'name': 'Texas'}, - {'state_name': 'Tianjin', 'country': 'China', 'doctype': 'State', 'name': 'Tianjin'}, - {'state_name': 'Tripura', 'country': 'India', 'doctype': 'State', 'name': 'Tripura'}, - {'state_name': 'Turpan', 'country': 'China', 'doctype': 'State', 'name': 'Turpan'}, - {'state_name': 'Urumqi', 'country': 'China', 'doctype': 'State', 'name': 'Urumqi'}, - {'state_name': 'Utah', 'country': 'United States', 'doctype': 'State', 'name': 'Utah'}, - {'state_name': 'Uttar Pradesh', 'country': 'India', 'doctype': 'State', 'name': 'Uttar Pradesh'}, - {'state_name': 'Uttarakhand', 'country': 'India', 'doctype': 'State', 'name': 'Uttarakhand'}, - {'state_name': 'Vermont', 'country': 'United States', 'doctype': 'State', 'name': 'Vermont'}, - {'state_name': 'Virginia', 'country': 'United States', 'doctype': 'State', 'name': 'Virginia'}, - {'state_name': 'Washington', 'country': 'United States', 'doctype': 'State', 'name': 'Washington'}, - {'state_name': 'West Bengal', 'country': 'India', 'doctype': 'State', 'name': 'West Bengal'}, - {'state_name': 'West Virginia', 'country': 'United States', 'doctype': 'State', 'name': 'West Virginia'}, - {'state_name': 'Wisconsin', 'country': 'United States', 'doctype': 'State', 'name': 'Wisconsin'}, - {'state_name': 'Wuhan', 'country': 'China', 'doctype': 'State', 'name': 'Wuhan'}, - {'state_name': 'Wuxi', 'country': 'China', 'doctype': 'State', 'name': 'Wuxi'}, - {'state_name': 'Wyoming', 'country': 'United States', 'doctype': 'State', 'name': 'Wyoming'}, - {'state_name': 'Xiamen', 'country': 'China', 'doctype': 'State', 'name': 'Xiamen'}, - {'state_name': 'Xian', 'country': 'China', 'doctype': 'State', 'name': 'Xian'}, - {'state_name': 'Zhongshan ', 'country': 'China', 'doctype': 'State', 'name': 'Zhongshan'}, - + {'uom_name': 'Hour', 'doctype': 'UOM', 'name': 'Hour'}, + {'uom_name': 'Minute', 'doctype': 'UOM', 'name': 'Minute'}, ] for r in records: diff --git a/stock/doctype/sales_and_purchase_return_tool/sales_and_purchase_return_tool.js b/stock/doctype/sales_and_purchase_return_tool/sales_and_purchase_return_tool.js index 7547b6a0dc..138d19bc97 100644 --- a/stock/doctype/sales_and_purchase_return_tool/sales_and_purchase_return_tool.js +++ b/stock/doctype/sales_and_purchase_return_tool/sales_and_purchase_return_tool.js @@ -211,7 +211,6 @@ cur_frm.cscript.make_jv = function(doc, dr_or_cr, children) { jv.fiscal_year = sys_defaults.fiscal_year; jv.is_opening = 'No'; jv.posting_date = doc.return_date; - jv.voucher_date = dateutil.obj_to_str(new Date()); // Add children if(children) { From 1efaf841c48fc3faac05a167cc4a17ab9c4a6e31 Mon Sep 17 00:00:00 2001 From: Nabin Hait Date: Thu, 17 Jan 2013 18:26:58 +0530 Subject: [PATCH 10/11] payment reconciliation fixes --- accounts/doctype/gl_control/gl_control.py | 46 +++++++------ .../payment_to_invoice_matching_tool.py | 65 +++++++++---------- 2 files changed, 55 insertions(+), 56 deletions(-) diff --git a/accounts/doctype/gl_control/gl_control.py b/accounts/doctype/gl_control/gl_control.py index 44cab1e7a8..b268486c45 100644 --- a/accounts/doctype/gl_control/gl_control.py +++ b/accounts/doctype/gl_control/gl_control.py @@ -17,14 +17,11 @@ from __future__ import unicode_literals import webnotes -from webnotes.utils import cstr, flt, get_defaults, now, sendmail -from webnotes.model import db_exists +from webnotes.utils import cstr, flt, get_defaults from webnotes.model.doc import Document, addchild -from webnotes.model.wrapper import getlist, copy_doclist +from webnotes.model.wrapper import getlist from webnotes.model.code import get_obj from webnotes import msgprint -from webnotes.utils.email_lib import sendmail - from utilities.transaction_base import TransactionBase @@ -55,9 +52,6 @@ class DocType: return flt(bal) - - # Add a new account - # ----------------- def add_ac(self,arg): arg = eval(arg) ac = Document('Account') @@ -113,14 +107,23 @@ class DocType: # Make a dictionary(le) for every gl entry and append to a list(self.entries) #---------------------------------------------------------------------------- def make_single_entry(self,parent,d,le_map,cancel, merge_entries): - if self.get_val(le_map['account'], d, parent) and (self.get_val(le_map['debit'], d, parent) or self.get_val(le_map['credit'], d, parent)): - flist = ['account','cost_center','against','debit','credit','remarks','voucher_type','voucher_no','posting_date','fiscal_year','against_voucher','against_voucher_type','company','is_opening', 'aging_date'] + if self.get_val(le_map['account'], d, parent) and \ + (self.get_val(le_map['debit'], d, parent) \ + or self.get_val(le_map['credit'], d, parent)): + flist = ['account', 'cost_center', 'against', 'debit', 'credit', 'remarks', + 'voucher_type', 'voucher_no', 'posting_date', 'fiscal_year', 'against_voucher', + 'against_voucher_type', 'company', 'is_opening', 'aging_date'] # Check budget before gl entry #check budget only if account is expense account - is_expense_acct = webnotes.conn.sql("select name from tabAccount where is_pl_account='Yes' and debit_or_credit='Debit' and name=%s",self.get_val(le_map['account'], d, parent)) + is_expense_acct = webnotes.conn.sql("""select name from tabAccount + where is_pl_account='Yes' and debit_or_credit='Debit' + and name=%s""",self.get_val(le_map['account'], d, parent)) + if is_expense_acct and self.get_val(le_map['cost_center'], d, parent): - get_obj('Budget Control').check_budget([self.get_val(le_map[k], d, parent) for k in flist if k in ['account','cost_center','debit','credit','posting_date','fiscal_year','company']],cancel) + get_obj('Budget Control').check_budget([self.get_val(le_map[k], d, parent) + for k in flist if k in ['account', 'cost_center', 'debit', + 'credit', 'posting_date', 'fiscal_year', 'company']],cancel) # Create new GL entry object and map values le = Document('GL Entry') @@ -135,6 +138,7 @@ class DocType: same_head.credit = flt(same_head.credit) + flt(le.credit) else: self.entries.append(le) + def manage_debit_credit(self, cancel): total_debit, total_credit = 0, 0 @@ -158,6 +162,7 @@ class DocType: # update total debit / credit total_debit += flt(le.debit, 2) total_credit += flt(le.credit, 2) + webnotes.errprint([le.account, le.debit, le.credit]) diff = flt(total_debit - total_credit, 2) if abs(diff)==0.01: @@ -191,8 +196,11 @@ class DocType: for le_map in le_map_list: if le_map['table_field']: for d in getlist(doclist,le_map['table_field']): + webnotes.errprint([d.fields]) # purchase_tax_details is the table of other charges in purchase cycle - if le_map['table_field'] != 'purchase_tax_details' or (le_map['table_field'] == 'purchase_tax_details' and d.fields.get('category') != 'Valuation'): + if le_map['table_field'] != 'purchase_tax_details' or \ + (le_map['table_field'] == 'purchase_tax_details' and \ + d.fields.get('category') != 'Valuation'): self.make_single_entry(doc,d,le_map,cancel, merge_entries) else: self.make_single_entry(None,doc,le_map,cancel, merge_entries) @@ -309,9 +317,6 @@ class DocType: return -###################################################################################################################### - - #------------------------------------------ def reconcile_against_document(self, args): """ Cancel JV, Update aginst document, split if required and resubmit jv @@ -329,6 +334,7 @@ class DocType: d['against_fld'] = against_fld[d['against_voucher_type']] # cancel JV + webnotes.errprint("cancel") jv_obj = get_obj('Journal Voucher', d['voucher_no'], with_children=1) self.make_gl_entries(jv_obj.doc, jv_obj.doclist, cancel =1, adv_adj =1) @@ -336,10 +342,10 @@ class DocType: self.update_against_doc(d, jv_obj) # re-submit JV + webnotes.errprint("resubmit") jv_obj = get_obj('Journal Voucher', d['voucher_no'], with_children =1) self.make_gl_entries(jv_obj.doc, jv_obj.doclist, cancel = 0, adv_adj =1) - #------------------------------------------ def update_against_doc(self, d, jv_obj): """ Updates against document, if partial amount splits into rows @@ -347,9 +353,10 @@ class DocType: webnotes.conn.sql(""" update `tabJournal Voucher Detail` t1, `tabJournal Voucher` t2 - set t1.%(dr_or_cr)s = '%(allocated_amt)s', t1.%(against_fld)s = '%(against_voucher)s', t2.modified = now() + set t1.%(dr_or_cr)s = '%(allocated_amt)s', + t1.%(against_fld)s = '%(against_voucher)s', t2.modified = now() where t1.name = '%(voucher_detail_no)s' and t1.parent = t2.name""" % d) - + if d['allocated_amt'] < d['unadjusted_amt']: jvd = webnotes.conn.sql("select cost_center, balance, against_account, is_advance from `tabJournal Voucher Detail` where name = '%s'" % d['voucher_detail_no']) # new entry with balance amount @@ -364,7 +371,6 @@ class DocType: ch.docstatus = 1 ch.save(1) - #------------------------------------------ def check_if_jv_modified(self, args): """ check if there is already a voucher reference diff --git a/accounts/doctype/payment_to_invoice_matching_tool/payment_to_invoice_matching_tool.py b/accounts/doctype/payment_to_invoice_matching_tool/payment_to_invoice_matching_tool.py index e72d23eff3..ee33c3a188 100644 --- a/accounts/doctype/payment_to_invoice_matching_tool/payment_to_invoice_matching_tool.py +++ b/accounts/doctype/payment_to_invoice_matching_tool/payment_to_invoice_matching_tool.py @@ -18,40 +18,37 @@ from __future__ import unicode_literals import webnotes from webnotes.utils import flt -from webnotes.model import db_exists from webnotes.model.doc import addchild -from webnotes.model.wrapper import getlist, copy_doclist +from webnotes.model.wrapper import getlist from webnotes.model.code import get_obj from webnotes import msgprint -sql = webnotes.conn.sql - - - class DocType: def __init__(self, doc, doclist): self.doc = doc self.doclist = doclist - self.acc_type = self.doc.account and sql("select debit_or_credit from `tabAccount` where name = %s", self.doc.account)[0][0].lower() or '' + self.acc_type = self.doc.account and webnotes.conn.sql("""select debit_or_credit + from `tabAccount` where name = %s""", self.doc.account)[0][0].lower() or '' self.dt = { 'Sales Invoice': 'Sales Invoice', 'Purchase Invoice': 'Purchase Invoice', 'Journal Voucher': 'Journal Voucher' } - #-------------------------------------------------- def get_voucher_details(self): - tot_amt = sql(""" + tot_amt = webnotes.conn.sql(""" select sum(%s) from `tabGL Entry` where voucher_type = %s and voucher_no = %s - and account = %s and ifnull(is_cancelled, 'No') = 'No' - """% (self.acc_type, '%s', '%s', '%s'), (self.dt[self.doc.voucher_type], self.doc.voucher_no, self.doc.account)) + and account = %s and ifnull(is_cancelled, 'No') = 'No'""" % + (self.acc_type, '%s', '%s', '%s'), + (self.dt[self.doc.voucher_type], self.doc.voucher_no, self.doc.account)) - outstanding = sql(""" + outstanding = webnotes.conn.sql(""" select sum(%s) - sum(%s) from `tabGL Entry` where against_voucher = %s and voucher_no != %s - and account = %s and ifnull(is_cancelled, 'No') = 'No' - """ % ((self.acc_type == 'debit' and 'credit' or 'debit'), self.acc_type, '%s', '%s', '%s'), (self.doc.voucher_no, self.doc.voucher_no, self.doc.account)) + and account = %s and ifnull(is_cancelled, 'No') = 'No'""" % + ((self.acc_type == 'debit' and 'credit' or 'debit'), self.acc_type, '%s', '%s', '%s'), + (self.doc.voucher_no, self.doc.voucher_no, self.doc.account)) ret = { 'total_amount': flt(tot_amt[0][0]) or 0, @@ -60,8 +57,6 @@ class DocType: return ret - - #-------------------------------------------------- def get_payment_entries(self): """ Get payment entries for the account and period @@ -72,7 +67,6 @@ class DocType: gle = self.get_gl_entries() self.create_payment_table(gle) - #-------------------------------------------------- def get_gl_entries(self): self.validate_mandatory() dc = self.acc_type == 'debit' and 'credit' or 'debit' @@ -80,41 +74,40 @@ class DocType: cond = self.doc.from_date and " and t1.posting_date >= '" + self.doc.from_date + "'" or "" cond += self.doc.to_date and " and t1.posting_date <= '" + self.doc.to_date + "'"or "" - cond += self.doc.amt_greater_than and ' and t2.' + dc+' >= ' + self.doc.amt_greater_than or '' - cond += self.doc.amt_less_than and ' and t2.' + dc+' <= ' + self.doc.amt_less_than or '' + cond += self.doc.amt_greater_than and \ + ' and t2.' + dc+' >= ' + self.doc.amt_greater_than or '' + cond += self.doc.amt_less_than and \ + ' and t2.' + dc+' <= ' + self.doc.amt_less_than or '' - gle = sql(""" - select t1.name as voucher_no, t1.posting_date, t1.total_debit as total_amt, sum(ifnull(t2.credit, 0)) - sum(ifnull(t2.debit, 0)) as amt_due, t1.remark, t2.against_account, t2.name as voucher_detail_no + gle = webnotes.conn.sql(""" + select t1.name as voucher_no, t1.posting_date, t1.total_debit as total_amt, + sum(ifnull(t2.credit, 0)) - sum(ifnull(t2.debit, 0)) as amt_due, t1.remark, + t2.against_account, t2.name as voucher_detail_no from `tabJournal Voucher` t1, `tabJournal Voucher Detail` t2 - where t1.name = t2.parent - and t1.docstatus = 1 - and t2.account = %s - and ifnull(t2.against_voucher, '')='' and ifnull(t2.against_invoice, '')='' and ifnull(t2.against_jv, '')='' - and t2.%s > 0 - %s - group by t1.name, t2.name - """% ('%s', dc, cond), self.doc.account, as_dict=1) + where t1.name = t2.parent and t1.docstatus = 1 and t2.account = %s + and ifnull(t2.against_voucher, '')='' and ifnull(t2.against_invoice, '')='' + and ifnull(t2.against_jv, '')='' and t2.%s > 0 %s group by t1.name, t2.name """ % + ('%s', dc, cond), self.doc.account, as_dict=1) return gle - #-------------------------------------------------- def create_payment_table(self, gle): for d in gle: - ch = addchild(self.doc, 'ir_payment_details', 'Payment to Invoice Matching Tool Detail', self.doclist) + ch = addchild(self.doc, 'ir_payment_details', + 'Payment to Invoice Matching Tool Detail', self.doclist) ch.voucher_no = d.get('voucher_no') ch.posting_date = d.get('posting_date') - ch.amt_due = self.acc_type == 'debit' and flt(d.get('amt_due')) or -1*flt(d.get('amt_due')) + ch.amt_due = self.acc_type == 'debit' and flt(d.get('amt_due')) \ + or -1*flt(d.get('amt_due')) ch.total_amt = flt(d.get('total_amt')) ch.against_account = d.get('against_account') ch.remarks = d.get('remark') ch.voucher_detail_no = d.get('voucher_detail_no') - #-------------------------------------------------- def validate_mandatory(self): if not self.doc.account: msgprint("Please select Account first", raise_exception=1) - #-------------------------------------------------- def reconcile(self): """ Links booking and payment voucher @@ -122,7 +115,8 @@ class DocType: 2. split into multiple rows if partially adjusted, assign against voucher 3. submit payment voucher """ - if not self.doc.voucher_no or not sql("select name from `tab%s` where name = %s" %(self.dt[self.doc.voucher_type], '%s'), self.doc.voucher_no): + if not self.doc.voucher_no or not webnotes.conn.sql("""select name from `tab%s` + where name = %s""" % (self.dt[self.doc.voucher_type], '%s'), self.doc.voucher_no): msgprint("Please select valid Voucher No to proceed", raise_exception=1) lst = [] @@ -142,7 +136,6 @@ class DocType: lst.append(args) - if lst: get_obj('GL Control').reconcile_against_document(lst) msgprint("Successfully allocated.") From 16546d25e7408472bfcc704cee1ce0af8cf23b39 Mon Sep 17 00:00:00 2001 From: Nabin Hait Date: Thu, 17 Jan 2013 18:43:54 +0530 Subject: [PATCH 11/11] gl control cleanup[ --- accounts/doctype/gl_control/gl_control.py | 7 ------- 1 file changed, 7 deletions(-) diff --git a/accounts/doctype/gl_control/gl_control.py b/accounts/doctype/gl_control/gl_control.py index 89d2e13bf9..53ee9ffad8 100644 --- a/accounts/doctype/gl_control/gl_control.py +++ b/accounts/doctype/gl_control/gl_control.py @@ -129,7 +129,6 @@ class DocType: le = Document('GL Entry') for k in flist: le.fields[k] = self.get_val(le_map[k], d, parent) - # if there is already an entry in this account then just add it to that entry same_head = self.check_if_in_list(le) if same_head and merge_entries: @@ -162,7 +161,6 @@ class DocType: # update total debit / credit total_debit += flt(le.debit, 2) total_credit += flt(le.credit, 2) - webnotes.errprint([le.account, le.debit, le.credit]) diff = flt(total_debit - total_credit, 2) if abs(diff)==0.01: @@ -196,7 +194,6 @@ class DocType: for le_map in le_map_list: if le_map['table_field']: for d in getlist(doclist,le_map['table_field']): - webnotes.errprint([d.fields]) # purchase_tax_details is the table of other charges in purchase cycle if le_map['table_field'] != 'purchase_tax_details' or \ (le_map['table_field'] == 'purchase_tax_details' and \ @@ -208,8 +205,6 @@ class DocType: # save entries self.save_entries(cancel, adv_adj, update_outstanding) - - # set as cancelled if cancel: vt = self.get_val(le_map['voucher_type'], doc, doc) @@ -334,7 +329,6 @@ class DocType: d['against_fld'] = against_fld[d['against_voucher_type']] # cancel JV - webnotes.errprint("cancel") jv_obj = get_obj('Journal Voucher', d['voucher_no'], with_children=1) self.make_gl_entries(jv_obj.doc, jv_obj.doclist, cancel =1, adv_adj =1) @@ -342,7 +336,6 @@ class DocType: self.update_against_doc(d, jv_obj) # re-submit JV - webnotes.errprint("resubmit") jv_obj = get_obj('Journal Voucher', d['voucher_no'], with_children =1) self.make_gl_entries(jv_obj.doc, jv_obj.doclist, cancel = 0, adv_adj =1)