diff --git a/erpnext/config/setup.py b/erpnext/config/setup.py index a660942f87..5ad6403906 100644 --- a/erpnext/config/setup.py +++ b/erpnext/config/setup.py @@ -77,11 +77,6 @@ def get_data(): "label": _("Customize"), "icon": "icon-glass", "items": [ - { - "type": "doctype", - "name": "Features Setup", - "description": _("Show / Hide features like Serial Nos, POS etc.") - }, { "type": "doctype", "name": "Authorization Rule", diff --git a/erpnext/controllers/print_settings.py b/erpnext/controllers/print_settings.py index 5d27b03485..25ae1b2d88 100644 --- a/erpnext/controllers/print_settings.py +++ b/erpnext/controllers/print_settings.py @@ -12,7 +12,7 @@ def print_settings_for_item_table(doc): } doc.hide_in_print_layout = ["uom", "stock_uom"] - doc.flags.compact_item_print = cint(frappe.db.get_value("Features Setup", None, "compact_item_print")) + doc.flags.compact_item_print = cint(frappe.db.get_value("Print Settings", None, "compact_item_print")) if doc.flags.compact_item_print: doc.print_templates["description"] = "templates/print_formats/includes/item_table_description.html" diff --git a/erpnext/patches.txt b/erpnext/patches.txt index 3ee0158abf..4758325195 100644 --- a/erpnext/patches.txt +++ b/erpnext/patches.txt @@ -259,7 +259,8 @@ erpnext.patches.v6_20x.remove_fiscal_year_from_holiday_list erpnext.patches.v6_24.map_customer_address_to_shipping_address_on_po erpnext.patches.v6_27.fix_recurring_order_status erpnext.patches.v6_20x.remove_customer_supplier_roles +erpnext.patches.v6_20x.update_product_bundle_description erpnext.patches.v7_0.update_party_status erpnext.patches.v7_0.update_item_projected -erpnext.patches.v6_20x.update_product_bundle_description erpnext.patches.v7_0.fix_duplicate_icons +erpnext.patches.v7_0.remove_features_setup diff --git a/erpnext/patches/v6_20x/set_compact_print.py b/erpnext/patches/v6_20x/set_compact_print.py index 4ba1aea96f..495407f0e0 100644 --- a/erpnext/patches/v6_20x/set_compact_print.py +++ b/erpnext/patches/v6_20x/set_compact_print.py @@ -1,5 +1,8 @@ from __future__ import unicode_literals import frappe +from erpnext.setup.install import create_compact_item_print_custom_field + def execute(): - frappe.db.set_value("Features Setup", None, "compact_item_print", 1) + create_compact_item_print_custom_field() + frappe.db.set_value("Print Settings", None, "compact_item_print", 1) diff --git a/erpnext/patches/v7_0/remove_features_setup.py b/erpnext/patches/v7_0/remove_features_setup.py new file mode 100644 index 0000000000..2e7f893ae9 --- /dev/null +++ b/erpnext/patches/v7_0/remove_features_setup.py @@ -0,0 +1,24 @@ +import frappe + +from erpnext.setup.install import create_compact_item_print_custom_field + +def execute(): + if not frappe.db.get_value("Features Setup", None, "fs_item_barcode"): + # hide barcode fields + frappe.make_property_setter(dict(fieldname='barcode', property='hidden', value=1)) + + create_compact_item_print_custom_field() + + compact_item_print = frappe.db.get_value("Features Setup", None, "compact_item_print") + frappe.db.set_value("Print Settings", None, "compact_item_print", compact_item_print) + + # remove defaults + frappe.db.sql("""delete from tabDefaultValue where defkey in ('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', 'fs_pos_view', 'compact_item_print')""") + + frappe.delete_doc('DocType', 'Features Setup') diff --git a/erpnext/public/build.json b/erpnext/public/build.json index 9a949f2c3c..03c381a85e 100644 --- a/erpnext/public/build.json +++ b/erpnext/public/build.json @@ -8,7 +8,6 @@ ], "js/erpnext.min.js": [ "public/js/conf.js", - "public/js/feature_setup.js", "public/js/utils.js", "public/js/queries.js", "public/js/sms_manager.js", diff --git a/erpnext/public/js/feature_setup.js b/erpnext/public/js/feature_setup.js deleted file mode 100644 index 6dfc962059..0000000000 --- a/erpnext/public/js/feature_setup.js +++ /dev/null @@ -1,227 +0,0 @@ -// Copyright (c) 2015, Frappe Technologies Pvt. Ltd. and Contributors -// License: GNU General Public License v3. See license.txt - -/* features setup "Dictionary", "Script" -Dictionary Format - 'projects': { - 'Sales Order': { - 'fields':['project'], - 'items':['projected_qty'] - }, - 'Purchase Order': { - 'fields':['project'] - } - } -// ====================================================================*/ -frappe.provide("erpnext.feature_setup"); -erpnext.feature_setup.feature_dict = { - 'fs_projects': { - 'BOM': {'fields':['project']}, - 'Delivery Note': {'fields':['project']}, - 'Purchase Invoice': {'items':['project']}, - 'Production Order': {'fields':['project']}, - 'Purchase Order': {'items':['project']}, - 'Purchase Receipt': {'items':['project']}, - 'Sales Invoice': {'fields':['project']}, - 'Sales Order': {'fields':['project']}, - 'Stock Entry': {'fields':['project']}, - 'Timesheet': {'timesheet_details':['project']} - }, - 'fs_discounts': { - 'Delivery Note': {'items':['discount_percentage']}, - 'Quotation': {'items':['discount_percentage']}, - 'Sales Invoice': {'items':['discount_percentage']}, - 'Sales Order': {'items':['discount_percentage','price_list_rate']} - }, - 'fs_purchase_discounts': { - 'Purchase Order': {'items':['base_price_list_rate', 'discount_percentage', 'price_list_rate']}, - 'Purchase Receipt': {'items':['base_price_list_rate', 'discount_percentage', 'price_list_rate']}, - 'Purchase Invoice': {'items':['base_price_list_rate', 'discount_percentage', 'price_list_rate']} - }, - 'fs_brands': { - 'Delivery Note': {'items':['brand']}, - 'Material Request': {'items':['brand']}, - 'Item': {'fields':['brand']}, - 'Purchase Order': {'items':['brand']}, - 'Purchase Invoice': {'items':['brand']}, - 'Quotation': {'items':['brand']}, - 'Sales Invoice': {'items':['brand']}, - 'Product Bundle': {'fields':['new_item_brand']}, - 'Sales Order': {'items':['brand']}, - 'Serial No': {'fields':['brand']} - }, - 'fs_after_sales_installations': { - 'Delivery Note': {'fields':['installation_status','per_installed'],'items':['installed_qty']} - }, - 'fs_item_batch_nos': { - 'Delivery Note': {'items':['batch_no']}, - 'Item': {'fields':['has_batch_no']}, - 'Purchase Receipt': {'items':['batch_no']}, - 'Quality Inspection': {'fields':['batch_no']}, - 'Sales and Pruchase Return Wizard': {'return_details':['batch_no']}, - 'Sales Invoice': {'items':['batch_no']}, - 'Stock Entry': {'items':['batch_no']}, - 'Stock Ledger Entry': {'fields':['batch_no']} - }, - 'fs_item_serial_nos': { - 'Warranty Claim': {'fields':['serial_no']}, - 'Delivery Note': {'items':['serial_no'],'packed_items':['serial_no']}, - 'Installation Note': {'items':['serial_no']}, - 'Item': {'fields':['has_serial_no']}, - 'Maintenance Schedule': {'items':['serial_no'],'schedules':['serial_no']}, - 'Maintenance Visit': {'purposes':['serial_no']}, - 'Purchase Receipt': {'items':['serial_no']}, - 'Quality Inspection': {'fields':['item_serial_no']}, - 'Sales and Pruchase Return Wizard': {'return_details':['serial_no']}, - 'Sales Invoice': {'items':['serial_no']}, - 'Stock Entry': {'items':['serial_no']}, - 'Stock Ledger Entry': {'fields':['serial_no']} - }, - 'fs_item_barcode': { - 'Item': {'fields': ['barcode']}, - 'Delivery Note': {'items': ['barcode']}, - 'Sales Invoice': {'items': ['barcode']}, - 'Stock Entry': {'items': ['barcode']}, - 'Purchase Receipt': {'items': ['barcode']} - }, - 'fs_item_group_in_details': { - 'Delivery Note': {'items':['item_group']}, - 'Opportunity': {'items':['item_group']}, - 'Material Request': {'items':['item_group']}, - 'Item': {'fields':['item_group']}, - 'Global Defaults': {'fields':['default_item_group']}, - 'Purchase Order': {'items':['item_group']}, - 'Purchase Receipt': {'items':['item_group']}, - 'Purchase Voucher': {'items':['item_group']}, - 'Quotation': {'items':['item_group']}, - 'Sales Invoice': {'items':['item_group']}, - 'Product Bundle': {'fields':['serial_no']}, - 'Sales Order': {'items':['item_group']}, - 'Serial No': {'fields':['item_group']}, - 'Sales Partner': {'targets':['item_group']}, - 'Sales Person': {'targets':['item_group']}, - 'Territory': {'targets':['item_group']} - }, - 'fs_page_break': { - 'Delivery Note': {'items':['page_break'],'packed_items':['page_break']}, - 'Material Request': {'items':['page_break']}, - 'Purchase Order': {'items':['page_break']}, - 'Purchase Receipt': {'items':['page_break']}, - 'Purchase Voucher': {'items':['page_break']}, - 'Quotation': {'items':['page_break']}, - 'Sales Invoice': {'items':['page_break']}, - 'Sales Order': {'items':['page_break']} - }, - 'fs_exports': { - 'Delivery Note': { - 'fields': ['conversion_rate','currency','base_grand_total','base_in_words','base_rounded_total', - 'base_total', 'base_net_total', 'base_discount_amount', 'base_total_taxes_and_charges'], - 'items': ['base_price_list_rate','base_amount','base_rate', 'base_net_rate', 'base_net_amount'] - }, - 'POS Profile': {'fields':['conversion_rate','currency']}, - 'Quotation': { - 'fields': ['conversion_rate','currency','base_grand_total','base_in_words','base_rounded_total', - 'base_total', 'base_net_total', 'base_discount_amount', 'base_total_taxes_and_charges'], - 'items': ['base_price_list_rate','base_amount','base_rate', 'base_net_rate', 'base_net_amount'] - }, - 'Sales Invoice': { - 'fields': ['conversion_rate','currency','base_grand_total','base_in_words','base_rounded_total', - 'base_total', 'base_net_total', 'base_discount_amount', 'base_total_taxes_and_charges'], - 'items': ['base_price_list_rate','base_amount','base_rate', 'base_net_rate', 'base_net_amount'] - }, - 'Product Bundle': {'fields':['currency']}, - 'Sales Order': { - 'fields': ['conversion_rate','currency','base_grand_total','base_in_words','base_rounded_total', - 'base_total', 'base_net_total', 'base_discount_amount', 'base_total_taxes_and_charges'], - 'items': ['base_price_list_rate','base_amount','base_rate', 'base_net_rate', 'base_net_amount'] - } - }, - - 'fs_imports': { - 'Purchase Invoice': { - 'fields': ['conversion_rate', 'currency', 'base_grand_total', 'base_discount_amount', - 'base_in_words', 'base_total', 'base_net_total', 'base_taxes_and_charges_added', - 'base_taxes_and_charges_deducted', 'base_total_taxes_and_charges'], - 'items': ['base_price_list_rate', 'base_amount','base_rate', 'base_net_rate', 'base_net_amount'] - }, - 'Purchase Order': { - 'fields': ['conversion_rate','currency', 'base_grand_total', 'base_discount_amount', - 'base_in_words', 'base_total', 'base_net_total', 'base_taxes_and_charges_added', - 'base_taxes_and_charges_deducted', 'base_total_taxes_and_charges'], - 'items': ['base_price_list_rate', 'base_amount','base_rate', 'base_net_rate', 'base_net_amount'] - }, - 'Purchase Receipt': { - 'fields': ['conversion_rate', 'currency','base_grand_total', 'base_in_words', 'base_total', - 'base_net_total', 'base_taxes_and_charges_added', 'base_taxes_and_charges_deducted', - 'base_total_taxes_and_charges', 'base_discount_amount'], - 'items': ['base_price_list_rate','base_amount','base_rate', 'base_net_rate', 'base_net_amount'] - }, - 'Supplier Quotation': { - 'fields': ['conversion_rate', 'currency','base_grand_total', 'base_in_words', 'base_total', - 'base_net_total', 'base_taxes_and_charges_added', 'base_taxes_and_charges_deducted', - 'base_total_taxes_and_charges', 'base_discount_amount'], - 'items': ['base_price_list_rate','base_amount','base_rate', 'base_net_rate', 'base_net_amount'] - } - }, - - 'fs_item_advanced': { - 'Item': {'fields':['customer_items']} - }, - 'fs_sales_extras': { - 'Address': {'fields':['sales_partner']}, - 'Contact': {'fields':['sales_partner']}, - 'Customer': {'fields':['sales_team']}, - 'Delivery Note': {'fields':['sales_team']}, - 'Item': {'fields':['customer_items']}, - 'Sales Invoice': {'fields':['sales_team']}, - 'Sales Order': {'fields':['sales_team']} - }, - 'fs_more_info': { - "Warranty Claim": {"fields": ["more_info"]}, - 'Material Request': {'fields':['more_info']}, - 'Lead': {'fields':['more_info']}, - 'Opportunity': {'fields':['more_info']}, - 'Purchase Invoice': {'fields':['more_info']}, - 'Purchase Order': {'fields':['more_info']}, - 'Purchase Receipt': {'fields':['more_info']}, - 'Supplier Quotation': {'fields':['more_info']}, - 'Quotation': {'fields':['more_info']}, - 'Sales Invoice': {'fields':['more_info']}, - 'Sales Order': {'fields':['more_info']}, - 'Delivery Note': {'fields':['more_info']}, - }, - 'fs_quality': { - 'Item': {'fields':['inspection_criteria','inspection_required']}, - 'Purchase Receipt': {'items':['qa_no']} - }, - 'fs_manufacturing': { - 'Item': {'fields':['manufacturing']} - }, - 'fs_pos': { - 'Sales Invoice': {'fields':['is_pos']} - }, - 'fs_recurring_invoice': { - 'Sales Invoice': {'fields': ['recurring_invoice']} - } -} - -$(document).bind('form_refresh', function() { - var feature_dict = erpnext.feature_setup.feature_dict; - for(var sys_feat in sys_defaults) { - if(sys_defaults[sys_feat]=='0' - && (sys_feat in feature_dict)) { //"Features to hide" exists - if(cur_frm.doc.doctype in feature_dict[sys_feat]) { - for(var fort in feature_dict[sys_feat][cur_frm.doc.doctype]) { - if(fort=='fields') { - hide_field(feature_dict[sys_feat][cur_frm.doc.doctype][fort]); - } else if(cur_frm.fields_dict[fort]) { - cur_frm.fields_dict[fort].grid.set_column_disp(feature_dict[sys_feat][cur_frm.doc.doctype][fort], false); - } else { - msgprint(__('Grid "')+fort+__('" does not exists')); - } - } - } - - } - } -}) diff --git a/erpnext/setup/doctype/features_setup/README.md b/erpnext/setup/doctype/features_setup/README.md deleted file mode 100644 index 4bdea47086..0000000000 --- a/erpnext/setup/doctype/features_setup/README.md +++ /dev/null @@ -1 +0,0 @@ -Settings for enabling / disabling certain features that will result in smaller forms. \ No newline at end of file diff --git a/erpnext/setup/doctype/features_setup/__init__.py b/erpnext/setup/doctype/features_setup/__init__.py deleted file mode 100644 index baffc48825..0000000000 --- a/erpnext/setup/doctype/features_setup/__init__.py +++ /dev/null @@ -1 +0,0 @@ -from __future__ import unicode_literals diff --git a/erpnext/setup/doctype/features_setup/features_setup.js b/erpnext/setup/doctype/features_setup/features_setup.js deleted file mode 100644 index a637a8e785..0000000000 --- a/erpnext/setup/doctype/features_setup/features_setup.js +++ /dev/null @@ -1,5 +0,0 @@ -frappe.ui.form.on('Features Setup', { - refresh: function(frm) { - - } -}); diff --git a/erpnext/setup/doctype/features_setup/features_setup.json b/erpnext/setup/doctype/features_setup/features_setup.json deleted file mode 100644 index 56be6b0ccd..0000000000 --- a/erpnext/setup/doctype/features_setup/features_setup.json +++ /dev/null @@ -1,833 +0,0 @@ -{ - "allow_copy": 0, - "allow_import": 0, - "allow_rename": 0, - "creation": "2012-12-20 12:50:49", - "custom": 0, - "docstatus": 0, - "doctype": "DocType", - "fields": [ - { - "allow_on_submit": 0, - "bold": 0, - "collapsible": 0, - "fieldname": "materials", - "fieldtype": "Section Break", - "hidden": 0, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_filter": 0, - "in_list_view": 0, - "label": "Item", - "length": 0, - "no_copy": 0, - "permlevel": 0, - "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, - "collapsible": 0, - "description": "To track item in sales and purchase documents based on their serial nos. This is can also used to track warranty details of the product.", - "fieldname": "fs_item_serial_nos", - "fieldtype": "Check", - "hidden": 0, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_filter": 0, - "in_list_view": 1, - "label": "Item Serial Nos", - "length": 0, - "no_copy": 0, - "permlevel": 0, - "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, - "collapsible": 0, - "description": "To track items in sales and purchase documents with batch nos. \"Preferred Industry: Chemicals\"", - "fieldname": "fs_item_batch_nos", - "fieldtype": "Check", - "hidden": 0, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_filter": 0, - "in_list_view": 1, - "label": "Item Batch Nos", - "length": 0, - "no_copy": 0, - "permlevel": 0, - "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, - "collapsible": 0, - "description": "To track brand name in the following documents Delivery Note, Opportunity, Material Request, Item, Purchase Order, Purchase Voucher, Purchaser Receipt, Quotation, Sales Invoice, Product Bundle, Sales Order, Serial No", - "fieldname": "fs_brands", - "fieldtype": "Check", - "hidden": 0, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_filter": 0, - "in_list_view": 1, - "label": "Brands", - "length": 0, - "no_copy": 0, - "permlevel": 0, - "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, - "collapsible": 0, - "description": "To track items using barcode. You will be able to enter items in Delivery Note and Sales Invoice by scanning barcode of item.", - "fieldname": "fs_item_barcode", - "fieldtype": "Check", - "hidden": 0, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_filter": 0, - "in_list_view": 1, - "label": "Item Barcode", - "length": 0, - "no_copy": 0, - "permlevel": 0, - "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, - "collapsible": 0, - "fieldname": "column_break0", - "fieldtype": "Column Break", - "hidden": 0, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_filter": 0, - "in_list_view": 0, - "length": 0, - "no_copy": 0, - "permlevel": 0, - "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, - "collapsible": 0, - "description": "To maintain the customer wise item code and to make them searchable based on their code use this option", - "fieldname": "fs_item_advanced", - "fieldtype": "Check", - "hidden": 0, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_filter": 0, - "in_list_view": 0, - "label": "Item Advanced", - "length": 0, - "no_copy": 0, - "permlevel": 0, - "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, - "collapsible": 0, - "description": "To get Item Group in details table", - "fieldname": "fs_item_group_in_details", - "fieldtype": "Check", - "hidden": 0, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_filter": 0, - "in_list_view": 0, - "label": "Item Groups in Details", - "length": 0, - "no_copy": 0, - "permlevel": 0, - "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, - "collapsible": 0, - "description": "If checked, only Description, Quantity, Rate and Amount are shown in print of Item table. Any extra field is shown under 'Description' column.", - "fieldname": "compact_item_print", - "fieldtype": "Check", - "hidden": 0, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_filter": 0, - "in_list_view": 0, - "label": "Compact Item Print", - "length": 0, - "no_copy": 0, - "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, - "collapsible": 0, - "fieldname": "sales_and_purchase", - "fieldtype": "Section Break", - "hidden": 0, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_filter": 0, - "in_list_view": 0, - "label": "Sales and Purchase", - "length": 0, - "no_copy": 0, - "permlevel": 0, - "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, - "collapsible": 0, - "description": "All export related fields like currency, conversion rate, export total, export grand total etc are available in Delivery Note, POS, Quotation, Sales Invoice, Sales Order etc.", - "fieldname": "fs_exports", - "fieldtype": "Check", - "hidden": 0, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_filter": 0, - "in_list_view": 0, - "label": "Exports", - "length": 0, - "no_copy": 0, - "permlevel": 0, - "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, - "collapsible": 0, - "description": "All import related fields like currency, conversion rate, import total, import grand total etc are available in Purchase Receipt, Supplier Quotation, Purchase Invoice, Purchase Order etc.", - "fieldname": "fs_imports", - "fieldtype": "Check", - "hidden": 0, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_filter": 0, - "in_list_view": 0, - "label": "Imports", - "length": 0, - "no_copy": 0, - "permlevel": 0, - "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, - "collapsible": 0, - "fieldname": "column_break1", - "fieldtype": "Column Break", - "hidden": 0, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_filter": 0, - "in_list_view": 0, - "length": 0, - "no_copy": 0, - "permlevel": 0, - "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, - "collapsible": 0, - "description": "Field available in Delivery Note, Quotation, Sales Invoice, Sales Order", - "fieldname": "fs_discounts", - "fieldtype": "Check", - "hidden": 0, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_filter": 0, - "in_list_view": 0, - "label": "Sales Discounts", - "length": 0, - "no_copy": 0, - "permlevel": 0, - "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, - "collapsible": 0, - "description": "Discount Fields will be available in Purchase Order, Purchase Receipt, Purchase Invoice", - "fieldname": "fs_purchase_discounts", - "fieldtype": "Check", - "hidden": 0, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_filter": 0, - "in_list_view": 0, - "label": "Purchase Discounts", - "length": 0, - "no_copy": 0, - "permlevel": 0, - "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, - "collapsible": 0, - "description": "To track any installation or commissioning related work after sales", - "fieldname": "fs_after_sales_installations", - "fieldtype": "Check", - "hidden": 0, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_filter": 0, - "in_list_view": 0, - "label": "After Sale Installations", - "length": 0, - "no_copy": 0, - "permlevel": 0, - "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, - "collapsible": 0, - "description": "Available in BOM, Delivery Note, Purchase Invoice, Production Order, Purchase Order, Purchase Receipt, Sales Invoice, Sales Order, Stock Entry, Timesheet", - "fieldname": "fs_projects", - "fieldtype": "Check", - "hidden": 0, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_filter": 0, - "in_list_view": 0, - "label": "Projects", - "length": 0, - "no_copy": 0, - "permlevel": 0, - "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, - "collapsible": 0, - "description": "If you have Sales Team and Sale Partners (Channel Partners) they can be tagged and maintain their contribution in the sales activity", - "fieldname": "fs_sales_extras", - "fieldtype": "Check", - "hidden": 0, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_filter": 0, - "in_list_view": 0, - "label": "Sales Extras", - "length": 0, - "no_copy": 0, - "permlevel": 0, - "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, - "collapsible": 0, - "fieldname": "accounts", - "fieldtype": "Section Break", - "hidden": 0, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_filter": 0, - "in_list_view": 0, - "label": "Accounts", - "length": 0, - "no_copy": 0, - "permlevel": 0, - "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, - "collapsible": 0, - "description": "Check if you need automatic recurring invoices. After submitting any sales invoice, Recurring section will be visible.", - "fieldname": "fs_recurring_invoice", - "fieldtype": "Check", - "hidden": 0, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_filter": 0, - "in_list_view": 0, - "label": "Recurring Invoice", - "length": 0, - "no_copy": 0, - "permlevel": 0, - "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, - "collapsible": 0, - "fieldname": "column_break2", - "fieldtype": "Column Break", - "hidden": 0, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_filter": 0, - "in_list_view": 0, - "length": 0, - "no_copy": 0, - "permlevel": 0, - "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, - "collapsible": 0, - "description": "To enable \"Point of Sale\" features", - "fieldname": "fs_pos", - "fieldtype": "Check", - "hidden": 0, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_filter": 0, - "in_list_view": 0, - "label": "Point of Sale", - "length": 0, - "no_copy": 0, - "permlevel": 0, - "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, - "collapsible": 0, - "description": "To enable \"Point of Sale\" view", - "fieldname": "fs_pos_view", - "fieldtype": "Check", - "hidden": 0, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_filter": 0, - "in_list_view": 0, - "label": "POS View", - "length": 0, - "no_copy": 0, - "permlevel": 0, - "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, - "collapsible": 0, - "fieldname": "production", - "fieldtype": "Section Break", - "hidden": 0, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_filter": 0, - "in_list_view": 0, - "label": "Manufacturing", - "length": 0, - "no_copy": 0, - "permlevel": 0, - "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, - "collapsible": 0, - "description": "If you involve in manufacturing activity. Enables Item 'Is Manufactured'", - "fieldname": "fs_manufacturing", - "fieldtype": "Check", - "hidden": 0, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_filter": 0, - "in_list_view": 0, - "label": "Manufacturing", - "length": 0, - "no_copy": 0, - "permlevel": 0, - "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, - "collapsible": 0, - "fieldname": "column_break3", - "fieldtype": "Column Break", - "hidden": 0, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_filter": 0, - "in_list_view": 0, - "length": 0, - "no_copy": 0, - "permlevel": 0, - "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, - "collapsible": 0, - "description": "If you follow Quality Inspection. Enables Item QA Required and QA No in Purchase Receipt", - "fieldname": "fs_quality", - "fieldtype": "Check", - "hidden": 0, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_filter": 0, - "in_list_view": 0, - "label": "Quality", - "length": 0, - "no_copy": 0, - "permlevel": 0, - "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, - "collapsible": 0, - "fieldname": "miscelleneous", - "fieldtype": "Section Break", - "hidden": 0, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_filter": 0, - "in_list_view": 0, - "label": "Miscelleneous", - "length": 0, - "no_copy": 0, - "permlevel": 0, - "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, - "collapsible": 0, - "description": "If you have long print formats, this feature can be used to split the page to be printed on multiple pages with all headers and footers on each page", - "fieldname": "fs_page_break", - "fieldtype": "Check", - "hidden": 0, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_filter": 0, - "in_list_view": 0, - "label": "Page Break", - "length": 0, - "no_copy": 0, - "permlevel": 0, - "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, - "collapsible": 0, - "fieldname": "column_break4", - "fieldtype": "Column Break", - "hidden": 0, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_filter": 0, - "in_list_view": 0, - "length": 0, - "no_copy": 0, - "permlevel": 0, - "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, - "collapsible": 0, - "fieldname": "fs_more_info", - "fieldtype": "Check", - "hidden": 0, - "ignore_user_permissions": 0, - "ignore_xss_filter": 0, - "in_filter": 0, - "in_list_view": 0, - "label": "More Information", - "length": 0, - "no_copy": 0, - "permlevel": 0, - "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 - } - ], - "hide_heading": 0, - "hide_toolbar": 0, - "icon": "icon-glass", - "idx": 1, - "in_create": 0, - "in_dialog": 0, - "is_submittable": 0, - "issingle": 1, - "istable": 0, - "max_attachments": 0, - "modified": "2016-04-06 03:45:40.152486", - "modified_by": "Administrator", - "module": "Setup", - "name": "Features Setup", - "name_case": "Title Case", - "owner": "Administrator", - "permissions": [ - { - "amend": 0, - "apply_user_permissions": 0, - "cancel": 0, - "create": 1, - "delete": 0, - "email": 1, - "export": 0, - "if_owner": 0, - "import": 0, - "permlevel": 0, - "print": 1, - "read": 1, - "report": 0, - "role": "System Manager", - "set_user_permissions": 0, - "share": 1, - "submit": 0, - "write": 1 - }, - { - "amend": 0, - "apply_user_permissions": 0, - "cancel": 0, - "create": 1, - "delete": 0, - "email": 1, - "export": 0, - "if_owner": 0, - "import": 0, - "permlevel": 0, - "print": 1, - "read": 1, - "report": 0, - "role": "Administrator", - "set_user_permissions": 0, - "share": 1, - "submit": 0, - "write": 1 - } - ], - "read_only": 0, - "read_only_onload": 0, - "sort_order": "ASC", - "track_seen": 0 -} \ No newline at end of file diff --git a/erpnext/setup/doctype/features_setup/features_setup.py b/erpnext/setup/doctype/features_setup/features_setup.py deleted file mode 100644 index 1ac0f74894..0000000000 --- a/erpnext/setup/doctype/features_setup/features_setup.py +++ /dev/null @@ -1,17 +0,0 @@ -# Copyright (c) 2015, Frappe Technologies Pvt. Ltd. and Contributors -# License: GNU General Public License v3. See license.txt - -from __future__ import unicode_literals -from frappe.model.document import Document - -class FeaturesSetup(Document): - - def validate(self): - """ - update settings in defaults - """ - from frappe.model import default_fields - from frappe.utils import set_default - for key in self.meta.get_valid_columns(): - if key not in default_fields: - set_default(key, self.get(key)) diff --git a/erpnext/setup/install.py b/erpnext/setup/install.py index 1402168855..3337b1f1b6 100644 --- a/erpnext/setup/install.py +++ b/erpnext/setup/install.py @@ -4,6 +4,7 @@ from __future__ import unicode_literals import frappe +from frappe import _ default_mail_footer = """
Sent via ERPNext
""" @@ -11,7 +12,7 @@ default_mail_footer = """