[setup] new page + minor fixes

This commit is contained in:
Rushabh Mehta
2013-06-26 17:20:12 +05:30
parent f49f82083f
commit 2f7e1abd0f
7 changed files with 505 additions and 339 deletions

View File

@@ -22,8 +22,12 @@ def boot_session(bootinfo):
"Notification Control").get_values()
# if no company, show a dialog box to create a new company
bootinfo['setup_complete'] = webnotes.conn.sql("""select name from
tabCompany limit 1""") and 'Yes' or 'No'
bootinfo["customer_count"] = webnotes.conn.sql("""select count(*) from tabCustomer""")[0][0]
if not bootinfo["customer_count"]:
bootinfo['setup_complete'] = webnotes.conn.sql("""select name from
tabCompany limit 1""") and 'Yes' or 'No'
# load subscription info
import conf

View File

@@ -135,13 +135,7 @@ def import_defaults():
# 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',
"buying_or_selling": "Selling"},
{'doctype': 'Price List', 'name': 'Standard', 'price_list_name': 'Standard',
"buying_or_selling": "Selling"},
# warehouse type
{'doctype': 'Warehouse Type', 'name': 'Default Warehouse Type', 'warehouse_type': 'Default Warehouse Type'},
{'doctype': 'Warehouse Type', 'name': 'Fixed Asset', 'warehouse_type': 'Fixed Asset'},