Rushabh Mehta | 793ba6b | 2014-02-14 15:47:51 +0530 | [diff] [blame] | 1 | from frappe import _ |
Anand Doshi | 0c4ef64 | 2014-03-04 11:15:08 +0530 | [diff] [blame] | 2 | from frappe.widgets.moduleview import add_setup_section |
Rushabh Mehta | c4ec534 | 2014-02-07 19:04:19 +0530 | [diff] [blame] | 3 | |
| 4 | data = [ |
| 5 | { |
Anand Doshi | 64f2ccd | 2014-03-03 19:28:30 +0530 | [diff] [blame] | 6 | "label": _("Tools"), |
| 7 | "icon": "icon-wrench", |
| 8 | "items": [ |
| 9 | { |
| 10 | "type": "doctype", |
| 11 | "name": "Global Defaults", |
| 12 | "label": _("Global Settings"), |
| 13 | "description": _("Set the Date & Number Formats, Default Currency, Current Fiscal Year, etc."), |
| 14 | "hide_count": True |
| 15 | } |
| 16 | ] |
| 17 | }, |
| 18 | { |
Rushabh Mehta | c4ec534 | 2014-02-07 19:04:19 +0530 | [diff] [blame] | 19 | "label": _("Customize"), |
| 20 | "icon": "icon-glass", |
| 21 | "items": [ |
| 22 | { |
| 23 | "type": "doctype", |
| 24 | "name": "Features Setup", |
| 25 | "description": _("Show / Hide features like Serial Nos, POS etc.") |
| 26 | }, |
| 27 | { |
| 28 | "type": "doctype", |
| 29 | "name": "Authorization Rule", |
| 30 | "description": _("Create rules to restrict transactions based on values.") |
| 31 | }, |
| 32 | { |
| 33 | "type": "doctype", |
| 34 | "name": "Notification Control", |
| 35 | "label": _("Email Notifications"), |
| 36 | "description": _("Automatically compose message on submission of transactions.") |
| 37 | } |
| 38 | ] |
| 39 | }, |
| 40 | { |
| 41 | "label": _("Email"), |
| 42 | "icon": "icon-envelope", |
| 43 | "items": [ |
| 44 | { |
| 45 | "type": "doctype", |
| 46 | "name": "Email Digest", |
| 47 | "description": _("Create and manage daily, weekly and monthly email digests.") |
| 48 | }, |
| 49 | { |
| 50 | "type": "doctype", |
Anand Doshi | e30511d | 2014-03-03 20:32:20 +0530 | [diff] [blame] | 51 | "name": "Support Email Settings", |
Rushabh Mehta | c4ec534 | 2014-02-07 19:04:19 +0530 | [diff] [blame] | 52 | "description": _("Setup incoming server for support email id. (e.g. support@example.com)") |
| 53 | }, |
| 54 | { |
| 55 | "type": "doctype", |
| 56 | "name": "Sales Email Settings", |
| 57 | "description": _("Setup incoming server for sales email id. (e.g. sales@example.com)") |
| 58 | }, |
| 59 | { |
| 60 | "type": "doctype", |
| 61 | "name": "Jobs Email Settings", |
| 62 | "description": _("Setup incoming server for jobs email id. (e.g. jobs@example.com)") |
| 63 | }, |
| 64 | ] |
| 65 | }, |
| 66 | { |
| 67 | "label": _("Masters"), |
| 68 | "icon": "icon-star", |
| 69 | "items": [ |
| 70 | { |
| 71 | "type": "doctype", |
| 72 | "name": "Company", |
| 73 | "description": _("Company (not Customer or Supplier) master.") |
| 74 | }, |
| 75 | { |
| 76 | "type": "doctype", |
| 77 | "name": "Item", |
| 78 | "description": _("Item master.") |
| 79 | }, |
| 80 | { |
| 81 | "type": "doctype", |
| 82 | "name": "Customer", |
| 83 | "description": _("Customer master.") |
| 84 | }, |
| 85 | { |
| 86 | "type": "doctype", |
| 87 | "name": "Supplier", |
| 88 | "description": _("Supplier master.") |
| 89 | }, |
| 90 | { |
| 91 | "type": "doctype", |
| 92 | "name": "Contact", |
| 93 | "description": _("Contact master.") |
| 94 | }, |
| 95 | { |
| 96 | "type": "doctype", |
| 97 | "name": "Address", |
| 98 | "description": _("Address master.") |
| 99 | }, |
| 100 | ] |
| 101 | }, |
Rushabh Mehta | c4ec534 | 2014-02-07 19:04:19 +0530 | [diff] [blame] | 102 | ] |
Anand Doshi | f5794f1 | 2014-03-03 15:05:28 +0530 | [diff] [blame] | 103 | |
| 104 | def get_data(): |
| 105 | out = list(data) |
| 106 | |
| 107 | for module, label, icon in ( |
| 108 | ("accounts", _("Accounts"), "icon-money"), |
| 109 | ("stock", _("Stock"), "icon-truck"), |
| 110 | ("selling", _("Selling"), "icon-tag"), |
| 111 | ("buying", _("Buying"), "icon-shopping-cart"), |
| 112 | ("hr", _("Human Resources"), "icon-group"), |
Anand Doshi | 0c4ef64 | 2014-03-04 11:15:08 +0530 | [diff] [blame] | 113 | ("support", _("Support"), "icon-phone")): |
Anand Doshi | f5794f1 | 2014-03-03 15:05:28 +0530 | [diff] [blame] | 114 | |
Anand Doshi | 0c4ef64 | 2014-03-04 11:15:08 +0530 | [diff] [blame] | 115 | add_setup_section(out, "erpnext", module, label, icon) |
| 116 | |
Anand Doshi | f5794f1 | 2014-03-03 15:05:28 +0530 | [diff] [blame] | 117 | return out |