Merge branch 'neilLasrado-drip-emails' into develop

This commit is contained in:
Anand Doshi 2016-03-08 20:22:45 +05:30
commit c62927ad5d
3 changed files with 68 additions and 59 deletions

View File

@ -22,6 +22,15 @@ function load_erpnext_slides() {
placeholder:__('e.g. "Build tools for builders"'), reqd:1},
{fieldname:'bank_account', label: __('Bank Account'), fieldtype:'Data',
placeholder: __('e.g. "XYZ National Bank"'), reqd:1 },
{fieldname:'domain', label: __('Domain'), fieldtype:'Select',
options: [
__("Distribution"),
__("Manufacturing"),
__("Retail"),
__("Services"),
__("Education"),
__("Other")
], reqd:1},
{fieldname:'chart_of_accounts', label: __('Chart of Accounts'),
options: "", fieldtype: 'Select'},

View File

@ -136,31 +136,6 @@
"set_only_once": 0,
"unique": 0
},
{
"allow_on_submit": 0,
"bold": 0,
"collapsible": 0,
"fieldname": "country",
"fieldtype": "Link",
"hidden": 0,
"ignore_user_permissions": 0,
"ignore_xss_filter": 0,
"in_filter": 0,
"in_list_view": 1,
"label": "Country",
"length": 0,
"no_copy": 0,
"options": "Country",
"permlevel": 0,
"print_hide": 0,
"print_hide_if_no_value": 0,
"read_only": 0,
"report_hide": 0,
"reqd": 1,
"search_index": 0,
"set_only_once": 0,
"unique": 0
},
{
"allow_on_submit": 0,
"bold": 0,
@ -175,7 +150,7 @@
"label": "Domain",
"length": 0,
"no_copy": 0,
"options": "Distribution\nManufacturing\nRetail\nServices\nEducation",
"options": "Distribution\nManufacturing\nRetail\nServices\nEducation\nOther",
"permlevel": 0,
"print_hide": 0,
"print_hide_if_no_value": 0,
@ -262,6 +237,32 @@
"set_only_once": 0,
"unique": 0
},
{
"allow_on_submit": 0,
"bold": 0,
"collapsible": 0,
"fieldname": "default_terms",
"fieldtype": "Link",
"hidden": 0,
"ignore_user_permissions": 0,
"ignore_xss_filter": 0,
"in_filter": 0,
"in_list_view": 0,
"label": "Default Terms",
"length": 0,
"no_copy": 0,
"options": "Terms and Conditions",
"permlevel": 0,
"precision": "",
"print_hide": 0,
"print_hide_if_no_value": 0,
"read_only": 0,
"report_hide": 0,
"reqd": 0,
"search_index": 0,
"set_only_once": 0,
"unique": 0
},
{
"allow_on_submit": 0,
"bold": 0,
@ -286,6 +287,31 @@
"set_only_once": 0,
"unique": 0
},
{
"allow_on_submit": 0,
"bold": 0,
"collapsible": 0,
"fieldname": "country",
"fieldtype": "Link",
"hidden": 0,
"ignore_user_permissions": 0,
"ignore_xss_filter": 0,
"in_filter": 0,
"in_list_view": 1,
"label": "Country",
"length": 0,
"no_copy": 0,
"options": "Country",
"permlevel": 0,
"print_hide": 0,
"print_hide_if_no_value": 0,
"read_only": 0,
"report_hide": 0,
"reqd": 1,
"search_index": 0,
"set_only_once": 0,
"unique": 0
},
{
"allow_on_submit": 0,
"bold": 0,
@ -336,32 +362,6 @@
"set_only_once": 0,
"unique": 0
},
{
"allow_on_submit": 0,
"bold": 0,
"collapsible": 0,
"fieldname": "default_terms",
"fieldtype": "Link",
"hidden": 0,
"ignore_user_permissions": 0,
"ignore_xss_filter": 0,
"in_filter": 0,
"in_list_view": 0,
"label": "Default Terms",
"length": 0,
"no_copy": 0,
"options": "Terms and Conditions",
"permlevel": 0,
"precision": "",
"print_hide": 0,
"print_hide_if_no_value": 0,
"read_only": 0,
"report_hide": 0,
"reqd": 0,
"search_index": 0,
"set_only_once": 0,
"unique": 0
},
{
"allow_on_submit": 0,
"bold": 0,
@ -1235,8 +1235,8 @@
"istable": 0,
"max_attachments": 0,
"menu_index": 0,
"modified": "2016-03-02 02:24:21.343229",
"modified_by": "Administrator",
"modified": "2016-03-08 20:21:46.331870",
"modified_by": "anand@erpnext.com",
"module": "Setup",
"name": "Company",
"owner": "Administrator",

View File

@ -19,7 +19,7 @@ def setup_complete(args=None):
frappe.throw(_("Setup Already Complete!!"))
install_fixtures.install(args.get("country"))
create_fiscal_year_and_company(args)
create_users(args)
set_defaults(args)
@ -63,22 +63,22 @@ def create_fiscal_year_and_company(args):
'year_end_date': args.get('fy_end_date'),
}).insert()
args["curr_fiscal_year"] = curr_fiscal_year
# Company
if (args.get('company_name')):
if (args.get('company_name')):
frappe.get_doc({
"doctype":"Company",
'domain': args.get("industry"),
'company_name':args.get('company_name').strip(),
'abbr':args.get('company_abbr'),
'default_currency':args.get('currency'),
'country': args.get('country'),
'chart_of_accounts': args.get(('chart_of_accounts')),
'domain': args.get('domain')
}).insert()
# Bank Account
create_bank_account(args)
def create_bank_account(args):
if args.get("bank_account"):
company_name = args.get('company_name').strip()