diff --git a/accounts/doctype/account/account.txt b/accounts/doctype/account/account.txt index 9ce509c1785..b29c61782fd 100644 --- a/accounts/doctype/account/account.txt +++ b/accounts/doctype/account/account.txt @@ -12,7 +12,7 @@ # These values are common for all DocType { - '_last_update': '1308829300', + '_last_update': '1309508836', 'allow_copy': 1, 'allow_trash': 1, 'colour': 'White:FFF', @@ -179,7 +179,7 @@ 'oldfieldtype': 'Data', 'permlevel': 1, 'reqd': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -225,7 +225,7 @@ 'options': '\nLedger\nGroup', 'permlevel': 1, 'reqd': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -259,7 +259,7 @@ 'oldfieldname': 'debit_or_credit', 'oldfieldtype': 'Data', 'permlevel': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -274,7 +274,7 @@ 'oldfieldtype': 'Select', 'options': 'Yes\nNo', 'permlevel': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -344,7 +344,7 @@ 'options': 'Company', 'permlevel': 1, 'reqd': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField diff --git a/accounts/doctype/account_balance/account_balance.txt b/accounts/doctype/account_balance/account_balance.txt index a53def25be1..1d23bb2fa1e 100644 --- a/accounts/doctype/account_balance/account_balance.txt +++ b/accounts/doctype/account_balance/account_balance.txt @@ -174,7 +174,7 @@ 'oldfieldname': 'fiscal_year', 'oldfieldtype': 'Link', 'options': 'Fiscal Year', - 'search_index': 1 + 'search_index': 0 }, # DocField diff --git a/accounts/doctype/cost_center/cost_center.txt b/accounts/doctype/cost_center/cost_center.txt index ce39929003f..fab2dd5f4d1 100644 --- a/accounts/doctype/cost_center/cost_center.txt +++ b/accounts/doctype/cost_center/cost_center.txt @@ -182,6 +182,7 @@ 'options': 'Company', 'permlevel': 0, 'reqd': 1, + 'search_index': 0, 'trigger': 'Client' }, @@ -227,7 +228,8 @@ 'oldfieldname': 'distribution_id', 'oldfieldtype': 'Link', 'options': 'Budget Distribution', - 'permlevel': 0 + 'permlevel': 0, + 'search_index': 0 }, # DocField diff --git a/accounts/doctype/fiscal_year/fiscal_year.txt b/accounts/doctype/fiscal_year/fiscal_year.txt index fe02b343109..4a7f49ac828 100644 --- a/accounts/doctype/fiscal_year/fiscal_year.txt +++ b/accounts/doctype/fiscal_year/fiscal_year.txt @@ -182,7 +182,7 @@ 'oldfieldtype': 'Link', 'options': 'Company', 'permlevel': 0, - 'search_index': 1 + 'search_index': 0 }, # DocField diff --git a/accounts/doctype/gl_entry/gl_entry.txt b/accounts/doctype/gl_entry/gl_entry.txt index 7278c4d13ad..776cbb3decf 100644 --- a/accounts/doctype/gl_entry/gl_entry.txt +++ b/accounts/doctype/gl_entry/gl_entry.txt @@ -12,7 +12,7 @@ # These values are common for all DocType { - '_last_update': '1294312170', + '_last_update': '1309508838', 'autoname': 'GL.#######', 'colour': 'White:FFF', 'doctype': 'DocType', @@ -119,7 +119,7 @@ 'label': 'Aging Date', 'oldfieldname': 'aging_date', 'oldfieldtype': 'Date', - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -221,7 +221,7 @@ 'oldfieldname': 'voucher_type', 'oldfieldtype': 'Select', 'options': 'Journal Voucher\nReceivable Voucher\nPayable Voucher', - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -262,7 +262,7 @@ 'oldfieldname': 'is_cancelled', 'oldfieldtype': 'Select', 'options': 'No\nYes', - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -276,7 +276,7 @@ 'oldfieldname': 'is_opening', 'oldfieldtype': 'Select', 'options': 'No\nYes', - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -304,7 +304,7 @@ 'oldfieldname': 'fiscal_year', 'oldfieldtype': 'Select', 'options': 'link:Fiscal Year', - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -318,6 +318,6 @@ 'oldfieldname': 'company', 'oldfieldtype': 'Link', 'options': 'Company', - 'search_index': 1 + 'search_index': 0 } ] \ No newline at end of file diff --git a/accounts/doctype/journal_voucher/journal_voucher.txt b/accounts/doctype/journal_voucher/journal_voucher.txt deleted file mode 100644 index c40be8f7286..00000000000 --- a/accounts/doctype/journal_voucher/journal_voucher.txt +++ /dev/null @@ -1,802 +0,0 @@ -# DocType, Journal Voucher -[ - - # These values are common in all dictionaries - { - 'creation': '2010-08-08 17:09:06', - 'docstatus': 0, - 'modified': '2011-07-15 14:37:05', - 'modified_by': 'Administrator', - 'owner': 'Administrator' - }, - - # These values are common for all DocType - { - '_last_update': '1310533805', - 'colour': 'White:FFF', - 'doctype': 'DocType', - 'module': 'Accounts', - 'name': '__common__', - 'search_fields': 'voucher_type,posting_date, due_date, cheque_no', - 'section_style': 'Tabbed', - 'server_code_error': ' ', - 'show_in_menu': 0, - 'subject': ' ', - 'tag_fields': 'voucher_type', - 'version': 308 - }, - - # These values are common for all DocField - { - 'doctype': 'DocField', - 'name': '__common__', - 'parent': 'Journal Voucher', - 'parentfield': 'fields', - 'parenttype': 'DocType' - }, - - # These values are common for all DocPerm - { - 'doctype': 'DocPerm', - 'name': '__common__', - 'parent': 'Journal Voucher', - 'parentfield': 'permissions', - 'parenttype': 'DocType', - 'read': 1 - }, - - # DocType, Journal Voucher - { - 'doctype': 'DocType', - 'name': 'Journal Voucher' - }, - - # DocPerm - { - 'amend': 0, - 'cancel': 0, - 'create': 0, - 'doctype': 'DocPerm', - 'idx': 1, - 'permlevel': 1, - 'role': 'Accounts Manager', - 'submit': 0, - 'write': 0 - }, - - # DocPerm - { - 'amend': 1, - 'cancel': 1, - 'create': 1, - 'doctype': 'DocPerm', - 'idx': 2, - 'permlevel': 0, - 'role': 'Accounts Manager', - 'submit': 1, - 'write': 1 - }, - - # DocPerm - { - 'amend': 1, - 'cancel': 1, - 'create': 1, - 'doctype': 'DocPerm', - 'idx': 3, - 'permlevel': 0, - 'role': 'Accounts User', - 'submit': 1, - 'write': 1 - }, - - # DocPerm - { - 'amend': 0, - 'cancel': 0, - 'create': 0, - 'doctype': 'DocPerm', - 'idx': 4, - 'permlevel': 1, - 'role': 'Accounts User', - 'submit': 0, - 'write': 0 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldtype': 'Section Break', - 'idx': 1, - 'label': 'Basic Info', - 'oldfieldtype': 'Section Break', - 'permlevel': 0 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldtype': 'Section Break', - 'idx': 2, - 'label': '1. Select Series and Dates', - 'oldfieldtype': 'Section Break', - 'options': 'Simple', - 'permlevel': 0 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldtype': 'Column Break', - 'idx': 3, - 'oldfieldtype': 'Column Break', - 'permlevel': 0, - 'width': '50%' - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'voucher_type', - 'fieldtype': 'Select', - 'idx': 4, - 'in_filter': 1, - 'label': 'Voucher Type', - 'oldfieldname': 'voucher_type', - 'oldfieldtype': 'Select', - 'options': '\nJournal Entry\nBank Voucher\nCash Voucher\nCredit Card Voucher\nDebit Note\nCredit Note\nContra Voucher\nExcise Voucher\nWrite Off Voucher\nLoan Receipt', - 'permlevel': 0, - 'print_hide': 0, - 'search_index': 1 - }, - - # DocField - { - 'colour': 'White:FFF', - 'depends_on': "eval:doc.voucher_type == 'Write Off Voucher'", - 'doctype': 'DocField', - 'fieldname': 'write_off_amount', - 'fieldtype': 'Currency', - 'idx': 5, - 'label': 'Write Off Amount <=', - 'permlevel': 0, - 'print_hide': 1, - 'report_hide': 1 - }, - - # DocField - { - 'colour': 'White:FFF', - 'default': 'Accounts Receivable', - 'depends_on': "eval:doc.voucher_type == 'Write Off Voucher'", - 'doctype': 'DocField', - 'fieldname': 'write_off_based_on', - 'fieldtype': 'Select', - 'idx': 6, - 'label': 'Write Off Based On', - 'options': 'Accounts Receivable\nAccounts Payable', - 'permlevel': 0, - 'print_hide': 1, - 'report_hide': 1 - }, - - # DocField - { - 'colour': 'White:FFF', - 'description': 'To manage multiple series please go to Setup > Manage Series', - 'doctype': 'DocField', - 'fieldname': 'naming_series', - 'fieldtype': 'Select', - 'idx': 7, - 'label': 'Series', - 'no_copy': 1, - 'oldfieldname': 'naming_series', - 'oldfieldtype': 'Select', - 'options': 'JV', - 'permlevel': 0, - 'print_hide': 1, - 'reqd': 1 - }, - - # DocField - { - 'colour': 'White:FFF', - 'default': 'Today', - 'doctype': 'DocField', - 'fieldname': 'voucher_date', - 'fieldtype': 'Date', - 'idx': 8, - 'in_filter': 1, - 'label': 'Voucher Date', - 'no_copy': 1, - 'oldfieldname': 'voucher_date', - 'oldfieldtype': 'Date', - 'permlevel': 0, - 'print_hide': 0, - 'reqd': 1, - 'search_index': 1 - }, - - # DocField - { - 'description': 'The date at which current entry will get or has actually executed.', - 'doctype': 'DocField', - 'fieldname': 'posting_date', - 'fieldtype': 'Date', - 'idx': 9, - 'in_filter': 1, - 'label': 'Posting Date', - 'no_copy': 1, - 'oldfieldname': 'posting_date', - 'oldfieldtype': 'Date', - 'permlevel': 0, - 'reqd': 1, - 'search_index': 1 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'due_date', - 'fieldtype': 'Date', - 'idx': 10, - 'label': 'Due Date', - 'oldfieldname': 'due_date', - 'oldfieldtype': 'Date', - 'permlevel': 0, - 'print_hide': 0 - }, - - # DocField - { - 'description': 'The date at which current entry is corrected in the system.', - 'doctype': 'DocField', - 'fieldname': 'amendment_date', - 'fieldtype': 'Date', - 'idx': 11, - 'label': 'Amendment Date', - 'no_copy': 1, - 'oldfieldname': 'amendment_date', - 'oldfieldtype': 'Date', - 'permlevel': 0, - 'print_hide': 1 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'amended_from', - 'fieldtype': 'Link', - 'idx': 12, - 'label': 'Amended From', - 'no_copy': 1, - 'oldfieldname': 'amended_from', - 'oldfieldtype': 'Link', - 'options': 'Journal Voucher', - 'permlevel': 1, - 'print_hide': 1 - }, - - # DocField - { - 'colour': 'White:FFF', - 'depends_on': "eval:doc.voucher_type == 'Write Off Voucher'", - 'doctype': 'DocField', - 'fieldtype': 'Button', - 'idx': 13, - 'label': 'Get Outstanding Invoices', - 'options': 'get_outstanding_invoices', - 'permlevel': 0, - 'print_hide': 1, - 'trigger': 'Server' - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldtype': 'Column Break', - 'idx': 14, - 'oldfieldtype': 'Column Break', - 'permlevel': 0, - 'width': '50%' - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'cheque_no', - 'fieldtype': 'Data', - 'idx': 15, - 'in_filter': 1, - 'label': 'Cheque No', - 'no_copy': 1, - 'oldfieldname': 'cheque_no', - 'oldfieldtype': 'Data', - 'permlevel': 0, - 'search_index': 1 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'cheque_date', - 'fieldtype': 'Date', - 'idx': 16, - 'label': 'Cheque Date', - 'no_copy': 1, - 'oldfieldname': 'cheque_date', - 'oldfieldtype': 'Date', - 'permlevel': 0 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'clearance_date', - 'fieldtype': 'Date', - 'idx': 17, - 'in_filter': 1, - 'label': 'Clearance Date', - 'no_copy': 1, - 'oldfieldname': 'clearance_date', - 'oldfieldtype': 'Date', - 'permlevel': 1, - 'print_hide': 0, - 'search_index': 1 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'user_remark', - 'fieldtype': 'Small Text', - 'idx': 18, - 'in_filter': 1, - 'label': 'User Remark', - 'no_copy': 1, - 'oldfieldname': 'user_remark', - 'oldfieldtype': 'Small Text', - 'permlevel': 0 - }, - - # DocField - { - 'description': 'User Remark will be added to Auto Remark', - 'doctype': 'DocField', - 'fieldname': 'remark', - 'fieldtype': 'Small Text', - 'idx': 19, - 'label': 'Remark', - 'no_copy': 1, - 'oldfieldname': 'remark', - 'oldfieldtype': 'Small Text', - 'permlevel': 1, - 'reqd': 0 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldtype': 'Section Break', - 'idx': 20, - 'label': '2. Add / Edit GL Entries', - 'oldfieldtype': 'Section Break', - 'options': 'Simple', - 'permlevel': 0 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'entries', - 'fieldtype': 'Table', - 'idx': 21, - 'label': 'Entries', - 'oldfieldname': 'entries', - 'oldfieldtype': 'Table', - 'options': 'Journal Voucher Detail', - 'permlevel': 0, - 'print_hide': 0 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldtype': 'Button', - 'idx': 22, - 'label': 'Get Balance', - 'oldfieldtype': 'Button', - 'permlevel': 0, - 'trigger': 'Client' - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'total_debit', - 'fieldtype': 'Currency', - 'idx': 23, - 'in_filter': 1, - 'label': 'Total Debit', - 'no_copy': 1, - 'oldfieldname': 'total_debit', - 'oldfieldtype': 'Currency', - 'permlevel': 1 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'total_credit', - 'fieldtype': 'Currency', - 'idx': 24, - 'in_filter': 1, - 'label': 'Total Credit', - 'no_copy': 1, - 'oldfieldname': 'total_credit', - 'oldfieldtype': 'Currency', - 'permlevel': 1 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'difference', - 'fieldtype': 'Currency', - 'idx': 25, - 'label': 'Difference', - 'no_copy': 1, - 'oldfieldname': 'difference', - 'oldfieldtype': 'Currency', - 'permlevel': 1, - 'print_hide': 1 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldtype': 'Section Break', - 'idx': 26, - 'label': 'Addtional Info', - 'oldfieldtype': 'Section Break', - 'permlevel': 0 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldtype': 'Column Break', - 'idx': 27, - 'oldfieldtype': 'Column Break', - 'permlevel': 0, - 'width': '50%' - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'bill_no', - 'fieldtype': 'Data', - 'idx': 28, - 'label': 'Bill No', - 'oldfieldname': 'bill_no', - 'oldfieldtype': 'Data', - 'permlevel': 0, - 'print_hide': 1 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'bill_date', - 'fieldtype': 'Date', - 'idx': 29, - 'label': 'Bill Date', - 'oldfieldname': 'bill_date', - 'oldfieldtype': 'Date', - 'permlevel': 0, - 'print_hide': 1 - }, - - # DocField - { - 'colour': 'White:FFF', - 'default': 'No', - 'doctype': 'DocField', - 'fieldname': 'is_opening', - 'fieldtype': 'Select', - 'idx': 30, - 'in_filter': 1, - 'label': 'Is Opening', - 'oldfieldname': 'is_opening', - 'oldfieldtype': 'Select', - 'options': 'No\nYes', - 'permlevel': 0, - 'print_hide': 1, - 'search_index': 1, - 'trigger': 'Client' - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'aging_date', - 'fieldtype': 'Date', - 'idx': 31, - 'label': 'Aging Date', - 'no_copy': 0, - 'oldfieldname': 'aging_date', - 'oldfieldtype': 'Date', - 'permlevel': 0, - 'print_hide': 1 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'cancel_reason', - 'fieldtype': 'Data', - 'idx': 32, - 'label': 'Cancel Reason', - 'no_copy': 1, - 'oldfieldname': 'cancel_reason', - 'oldfieldtype': 'Data', - 'permlevel': 1, - 'print_hide': 1 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'pay_to_recd_from', - 'fieldtype': 'Data', - 'hidden': 0, - 'idx': 33, - 'label': 'Pay To / Recd From', - 'no_copy': 1, - 'permlevel': 0, - 'print_hide': 1, - 'report_hide': 1 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'total_amount', - 'fieldtype': 'Data', - 'hidden': 0, - 'idx': 34, - 'label': 'Total Amount', - 'no_copy': 1, - 'permlevel': 1, - 'print_hide': 1, - 'report_hide': 1 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'total_amount_in_words', - 'fieldtype': 'Data', - 'hidden': 0, - 'idx': 35, - 'label': 'Total Amount in Words', - 'no_copy': 1, - 'permlevel': 1, - 'print_hide': 1, - 'report_hide': 1 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldtype': 'Column Break', - 'idx': 36, - 'oldfieldtype': 'Column Break', - 'permlevel': 0, - 'width': '50%' - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'fiscal_year', - 'fieldtype': 'Select', - 'idx': 37, - 'in_filter': 1, - 'label': 'Fiscal Year', - 'oldfieldname': 'fiscal_year', - 'oldfieldtype': 'Select', - 'options': 'link:Fiscal Year', - 'permlevel': 0, - 'print_hide': 1, - 'reqd': 1, - 'search_index': 1 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'company', - 'fieldtype': 'Link', - 'idx': 38, - 'in_filter': 1, - 'label': 'Company', - 'oldfieldname': 'company', - 'oldfieldtype': 'Link', - 'options': 'Company', - 'permlevel': 0, - 'print_hide': 1, - 'reqd': 1, - 'search_index': 1 - }, - - # DocField - { - 'allow_on_submit': 1, - 'colour': 'White:FFF', - 'doctype': 'DocField', - 'fieldname': 'select_print_heading', - 'fieldtype': 'Link', - 'idx': 39, - 'label': 'Select Print Heading', - 'no_copy': 1, - 'oldfieldname': 'select_print_heading', - 'oldfieldtype': 'Link', - 'options': 'Print Heading', - 'permlevel': 0, - 'print_hide': 1, - 'report_hide': 1, - 'trigger': 'Client' - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldtype': 'Section Break', - 'idx': 40, - 'oldfieldtype': 'Section Break', - 'options': 'Simple', - 'permlevel': 0 - }, - - # DocField - { - 'allow_on_submit': 1, - 'doctype': 'DocField', - 'fieldtype': 'Button', - 'idx': 41, - 'label': 'View Ledger Entry', - 'oldfieldtype': 'Button', - 'permlevel': 0, - 'print_hide': 1, - 'trigger': 'Client' - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldtype': 'Section Break', - 'idx': 42, - 'label': 'TDS', - 'oldfieldtype': 'Section Break', - 'permlevel': 0, - 'print_hide': 0 - }, - - # DocField - { - 'default': 'No', - 'doctype': 'DocField', - 'fieldname': 'tds_applicable', - 'fieldtype': 'Select', - 'idx': 43, - 'in_filter': 1, - 'label': 'TDS Applicable', - 'no_copy': 1, - 'oldfieldname': 'tds_applicable', - 'oldfieldtype': 'Select', - 'options': '\nYes\nNo', - 'permlevel': 0, - 'print_hide': 1, - 'search_index': 1 - }, - - # DocField - { - 'colour': 'White:FFF', - 'doctype': 'DocField', - 'fieldname': 'tds_category', - 'fieldtype': 'Select', - 'hidden': 0, - 'idx': 44, - 'in_filter': 1, - 'label': 'TDS Category', - 'no_copy': 1, - 'oldfieldname': 'tds_category', - 'oldfieldtype': 'Select', - 'options': 'link:TDS Category', - 'permlevel': 0, - 'print_hide': 1, - 'search_index': 1, - 'trigger': 'Client' - }, - - # DocField - { - 'colour': 'White:FFF', - 'doctype': 'DocField', - 'fieldname': 'supplier_account', - 'fieldtype': 'Link', - 'hidden': 0, - 'idx': 45, - 'label': 'Supplier Account', - 'no_copy': 1, - 'oldfieldname': 'supplier_account', - 'oldfieldtype': 'Link', - 'options': 'Account', - 'permlevel': 0, - 'print_hide': 1, - 'trigger': 'Client' - }, - - # DocField - { - 'colour': 'White:FFF', - 'doctype': 'DocField', - 'fieldtype': 'Button', - 'idx': 46, - 'label': 'Get TDS', - 'no_copy': 0, - 'oldfieldtype': 'Button', - 'permlevel': 0, - 'trigger': 'Client' - }, - - # DocField - { - 'colour': 'White:FFF', - 'description': 'Tax Code will be populated based on account head mentioned in TDS Category master', - 'doctype': 'DocField', - 'fieldname': 'tax_code', - 'fieldtype': 'Link', - 'idx': 47, - 'label': 'TDS Account Head', - 'no_copy': 1, - 'oldfieldname': 'tax_code', - 'oldfieldtype': 'Link', - 'options': 'Account', - 'permlevel': 0, - 'print_hide': 1 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'rate', - 'fieldtype': 'Currency', - 'idx': 48, - 'label': 'Rate', - 'no_copy': 1, - 'oldfieldname': 'rate', - 'oldfieldtype': 'Currency', - 'permlevel': 0, - 'print_hide': 1, - 'trigger': 'Client' - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'ded_amount', - 'fieldtype': 'Currency', - 'idx': 49, - 'label': 'Amount', - 'no_copy': 1, - 'oldfieldname': 'ded_amount', - 'oldfieldtype': 'Currency', - 'permlevel': 0, - 'print_hide': 1, - 'trigger': 'Client' - } -] \ No newline at end of file diff --git a/accounts/doctype/journal_voucher_detail/journal_voucher_detail.txt b/accounts/doctype/journal_voucher_detail/journal_voucher_detail.txt index 39da0841f72..4a350c21f4b 100644 --- a/accounts/doctype/journal_voucher_detail/journal_voucher_detail.txt +++ b/accounts/doctype/journal_voucher_detail/journal_voucher_detail.txt @@ -69,7 +69,7 @@ 'oldfieldtype': 'Link', 'options': 'Cost Center', 'permlevel': 0, - 'search_index': 1, + 'search_index': 0, 'width': '180px' }, diff --git a/accounts/doctype/payable_voucher/payable_voucher.txt b/accounts/doctype/payable_voucher/payable_voucher.txt index c330e8d5087..c77db19dd23 100644 --- a/accounts/doctype/payable_voucher/payable_voucher.txt +++ b/accounts/doctype/payable_voucher/payable_voucher.txt @@ -12,7 +12,7 @@ # These values are common for all DocType { - '_last_update': '1308741898', + '_last_update': '1309508838', 'colour': 'White:FFF', 'doctype': 'DocType', 'module': 'Accounts', @@ -221,6 +221,7 @@ 'options': 'Supplier', 'permlevel': 0, 'print_hide': 1, + 'search_index': 1, 'trigger': 'Client' }, @@ -326,7 +327,7 @@ 'oldfieldtype': 'Date', 'permlevel': 0, 'reqd': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -342,7 +343,7 @@ 'oldfieldtype': 'Date', 'permlevel': 0, 'print_hide': 0, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -378,7 +379,7 @@ 'permlevel': 0, 'print_hide': 1, 'reqd': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -394,7 +395,7 @@ 'permlevel': 0, 'print_hide': 1, 'reqd': 0, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -690,7 +691,7 @@ 'options': 'No\nYes', 'permlevel': 0, 'print_hide': 1, - 'search_index': 1, + 'search_index': 0, 'trigger': 'Client' }, @@ -768,7 +769,7 @@ 'permlevel': 0, 'print_hide': 1, 'reqd': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -785,7 +786,7 @@ 'permlevel': 0, 'print_hide': 1, 'reqd': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -1084,7 +1085,7 @@ 'oldfieldtype': 'Currency', 'permlevel': 1, 'print_hide': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField diff --git a/accounts/doctype/period_closing_voucher/period_closing_voucher.txt b/accounts/doctype/period_closing_voucher/period_closing_voucher.txt index e5bb1a274a4..58508871e7a 100644 --- a/accounts/doctype/period_closing_voucher/period_closing_voucher.txt +++ b/accounts/doctype/period_closing_voucher/period_closing_voucher.txt @@ -147,7 +147,8 @@ 'oldfieldtype': 'Select', 'options': 'link:Fiscal Year', 'permlevel': 0, - 'reqd': 1 + 'reqd': 1, + 'search_index': 1 }, # DocField diff --git a/accounts/doctype/pos_setting/pos_setting.txt b/accounts/doctype/pos_setting/pos_setting.txt index 7b1b9fa5a88..3809d67608c 100755 --- a/accounts/doctype/pos_setting/pos_setting.txt +++ b/accounts/doctype/pos_setting/pos_setting.txt @@ -172,7 +172,8 @@ 'oldfieldname': 'company', 'oldfieldtype': 'Link', 'options': 'Company', - 'reqd': 1 + 'reqd': 1, + 'search_index': 0 }, # DocField @@ -193,7 +194,8 @@ 'oldfieldname': 'customer_account', 'oldfieldtype': 'Link', 'options': 'Account', - 'reqd': 0 + 'reqd': 0, + 'search_index': 0 }, # DocField @@ -206,7 +208,8 @@ 'oldfieldname': 'cash_bank_account', 'oldfieldtype': 'Link', 'options': 'Account', - 'reqd': 1 + 'reqd': 1, + 'search_index': 0 }, # DocField @@ -219,7 +222,8 @@ 'oldfieldname': 'income_account', 'oldfieldtype': 'Link', 'options': 'Account', - 'reqd': 1 + 'reqd': 1, + 'search_index': 0 }, # DocField @@ -232,7 +236,8 @@ 'oldfieldname': 'warehouse', 'oldfieldtype': 'Link', 'options': 'Warehouse', - 'reqd': 1 + 'reqd': 1, + 'search_index': 0 }, # DocField @@ -245,7 +250,8 @@ 'oldfieldname': 'cost_center', 'oldfieldtype': 'Link', 'options': 'Cost Center', - 'reqd': 1 + 'reqd': 1, + 'search_index': 0 }, # DocField @@ -257,7 +263,8 @@ 'label': 'Charge', 'oldfieldname': 'charge', 'oldfieldtype': 'Link', - 'options': 'Other Charges' + 'options': 'Other Charges', + 'search_index': 0 }, # DocField @@ -282,7 +289,8 @@ 'label': 'Terms', 'oldfieldname': 'tc_name', 'oldfieldtype': 'Link', - 'options': 'Term' + 'options': 'Term', + 'search_index': 0 }, # DocField diff --git a/accounts/doctype/purchase_tax_detail/purchase_tax_detail.txt b/accounts/doctype/purchase_tax_detail/purchase_tax_detail.txt index 583a97f2606..ed67ba2f0bd 100644 --- a/accounts/doctype/purchase_tax_detail/purchase_tax_detail.txt +++ b/accounts/doctype/purchase_tax_detail/purchase_tax_detail.txt @@ -151,6 +151,7 @@ 'oldfieldtype': 'Link', 'options': 'Cost Center', 'permlevel': 0, + 'search_index': 0, 'trigger': 'Client' }, diff --git a/accounts/doctype/pv_detail/pv_detail.txt b/accounts/doctype/pv_detail/pv_detail.txt index 0243d71bbec..1e05160261b 100644 --- a/accounts/doctype/pv_detail/pv_detail.txt +++ b/accounts/doctype/pv_detail/pv_detail.txt @@ -111,7 +111,7 @@ 'options': 'Item Group', 'permlevel': 1, 'print_hide': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField diff --git a/accounts/doctype/receivable_voucher/receivable_voucher.txt b/accounts/doctype/receivable_voucher/receivable_voucher.txt index bcad9cc31c5..f2f9eafb20b 100644 --- a/accounts/doctype/receivable_voucher/receivable_voucher.txt +++ b/accounts/doctype/receivable_voucher/receivable_voucher.txt @@ -12,7 +12,7 @@ # These values are common for all DocType { - '_last_update': '1308741898', + '_last_update': '1309508839', 'change_log': '1. Change in pull_details method dt.-26-06-2009', 'colour': 'White:FFF', 'doctype': 'DocType', @@ -323,7 +323,7 @@ 'oldfieldtype': 'Date', 'permlevel': 0, 'reqd': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -342,7 +342,7 @@ 'oldfieldtype': 'Date', 'permlevel': 0, 'reqd': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -433,7 +433,7 @@ 'permlevel': 0, 'print_hide': 1, 'reqd': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -903,7 +903,7 @@ 'options': 'No\nYes', 'permlevel': 0, 'print_hide': 1, - 'search_index': 1, + 'search_index': 0, 'trigger': 'Client' }, @@ -1027,7 +1027,7 @@ 'permlevel': 0, 'print_hide': 1, 'reqd': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -1045,7 +1045,7 @@ 'permlevel': 0, 'print_hide': 1, 'reqd': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -1116,7 +1116,7 @@ 'permlevel': 1, 'print_hide': 1, 'reqd': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField diff --git a/accounts/doctype/rv_detail/rv_detail.txt b/accounts/doctype/rv_detail/rv_detail.txt index 6950ca921a7..94a45837c1f 100644 --- a/accounts/doctype/rv_detail/rv_detail.txt +++ b/accounts/doctype/rv_detail/rv_detail.txt @@ -243,6 +243,7 @@ 'permlevel': 0, 'print_hide': 1, 'reqd': 1, + 'search_index': 1, 'trigger': 'Client', 'width': '120px' }, @@ -262,6 +263,7 @@ 'permlevel': 0, 'print_hide': 1, 'reqd': 0, + 'search_index': 1, 'trigger': 'Client', 'width': '120px' }, diff --git a/accounts/doctype/rv_tax_detail/rv_tax_detail.txt b/accounts/doctype/rv_tax_detail/rv_tax_detail.txt index 94846cb3c76..a9326a02861 100644 --- a/accounts/doctype/rv_tax_detail/rv_tax_detail.txt +++ b/accounts/doctype/rv_tax_detail/rv_tax_detail.txt @@ -80,7 +80,8 @@ 'oldfieldname': 'cost_center_other_charges', 'oldfieldtype': 'Link', 'options': 'Cost Center', - 'permlevel': 0 + 'permlevel': 0, + 'search_index': 0 }, # DocField diff --git a/accounts/doctype/tds_category_account/tds_category_account.txt b/accounts/doctype/tds_category_account/tds_category_account.txt index 88ee39a70d1..6f6022b243f 100644 --- a/accounts/doctype/tds_category_account/tds_category_account.txt +++ b/accounts/doctype/tds_category_account/tds_category_account.txt @@ -51,7 +51,7 @@ 'label': 'Company', 'oldfieldname': 'company', 'options': 'Company', - 'search_index': 1 + 'search_index': 0 }, # DocField diff --git a/accounts/doctype/tds_payment/tds_payment.txt b/accounts/doctype/tds_payment/tds_payment.txt index abd4b0cdc07..8d0edfb10da 100644 --- a/accounts/doctype/tds_payment/tds_payment.txt +++ b/accounts/doctype/tds_payment/tds_payment.txt @@ -207,7 +207,7 @@ 'options': 'link:Fiscal Year', 'permlevel': 0, 'reqd': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -269,7 +269,7 @@ 'oldfieldtype': 'Link', 'options': 'Company', 'permlevel': 0, - 'search_index': 1, + 'search_index': 0, 'trigger': 'Client' }, diff --git a/accounts/search_criteria/accounts_payable/accounts_payable.py b/accounts/search_criteria/accounts_payable/accounts_payable.py index 53fff081ed4..8c07b68b45e 100644 --- a/accounts/search_criteria/accounts_payable/accounts_payable.py +++ b/accounts/search_criteria/accounts_payable/accounts_payable.py @@ -2,134 +2,145 @@ # ------------------------------------------------------------------ if not filter_values.get('posting_date') or not filter_values.get('posting_date1'): - msgprint("Please select From Posting Date and To Posting Date ") - raise Exception + msgprint("Please select From Posting Date and To Posting Date ") + raise Exception else: - from_date = filter_values.get('posting_date') - to_date = filter_values.get('posting_date1') + from_date = filter_values.get('posting_date') + to_date = filter_values.get('posting_date1') if not filter_values['range_1'] or not filter_values['range_2'] or not filter_values['range_3'] or not filter_values['range_4']: - msgprint("Please select aging ranges in no of days in 'More Filters' ") - raise Exception + msgprint("Please select aging ranges in no of days in 'More Filters' ") + raise Exception # validate Range range_list = ['range_1','range_2','range_3','range_4'] for r in range(len(range_list)-1): - if not cint(filter_values[range_list[r]]) < cint(filter_values[range_list[r + 1]]): - msgprint("Range %s should be less than Range %s." % (cstr(r+1),cstr(r+2))) - raise Exception + if not cint(filter_values[range_list[r]]) < cint(filter_values[range_list[r + 1]]): + msgprint("Range %s should be less than Range %s." % (cstr(r+1),cstr(r+2))) + raise Exception - + # Add columns # ------------------------------------------------------------------ data = [['Aging Date','Date','80px',''], - ['Transaction Date','Date','80px',''], - ['Account','Data','120px',''], - ['Against Voucher Type','Data','120px',''], - ['Against Voucher','Data','120px',''], - ['Voucher Type','Data','120px',''], - ['Voucher No','Data','120px',''], - ['Remarks','Data','160px',''], - ['Supplier Type', 'Data', '80px', ''], - ['Due Date', 'Data', '80px', ''], - ['Bill No','Data','80px',''], - ['Bill Date','Data','80px',''], - ['Opening Amt','Currency','120px',''], - ['Outstanding Amt','Currency','120px',''], - ['Age (Days)', 'Currency', '150px', ''], - ['0-'+cstr(filter_values['range_1']),'Currency','100px',''], - [cstr(cint(filter_values['range_1']) + 1)+ '-' +cstr(filter_values['range_2']),'Currency','100px',''], - [cstr(cint(filter_values['range_2']) + 1)+ '-' +cstr(filter_values['range_3']),'Currency','100px',''], - [cstr(cint(filter_values['range_3']) + 1)+ '-' +cstr(filter_values['range_4']),'Currency','100px',''], - [cstr(filter_values['range_4']) + '-Above','Currency','100px','']] - + ['Transaction Date','Date','80px',''], + ['Account','Data','120px',''], + ['Against Voucher Type','Data','120px',''], + ['Against Voucher','Data','120px',''], + ['Voucher Type','Data','120px',''], + ['Voucher No','Data','120px',''], + ['Remarks','Data','160px',''], + ['Supplier Type', 'Data', '80px', ''], + ['Due Date', 'Data', '80px', ''], + ['Bill No','Data','80px',''], + ['Bill Date','Data','80px',''], + ['Opening Amt','Currency','120px',''], + ['Outstanding Amt','Currency','120px',''], + ['Age (Days)', 'Currency', '150px', ''], + ['0-'+cstr(filter_values['range_1']),'Currency','100px',''], + [cstr(cint(filter_values['range_1']) + 1)+ '-' +cstr(filter_values['range_2']),'Currency','100px',''], + [cstr(cint(filter_values['range_2']) + 1)+ '-' +cstr(filter_values['range_3']),'Currency','100px',''], + [cstr(cint(filter_values['range_3']) + 1)+ '-' +cstr(filter_values['range_4']),'Currency','100px',''], + [cstr(filter_values['range_4']) + '-Above','Currency','100px','']] + for d in data: - colnames.append(d[0]) - coltypes.append(d[1]) - colwidths.append(d[2]) - coloptions.append(d[3]) - col_idx[d[0]] = len(colnames)-1 - + colnames.append(d[0]) + coltypes.append(d[1]) + colwidths.append(d[2]) + coloptions.append(d[3]) + col_idx[d[0]] = len(colnames)-1 + # ageing based on # ------------------------------------------------------------------ aging_based_on = 'Aging Date' if filter_values.has_key('aging_based_on') and filter_values['aging_based_on']: - aging_based_on = filter_values['aging_based_on'].split(NEWLINE)[-1] + aging_based_on = filter_values['aging_based_on'].split(NEWLINE)[-1] -if len(res) > 600 and from_export == 0: - msgprint("This is a very large report and cannot be shown in the browser as it is likely to make your browser very slow.Please select Account or click on 'Export' to open in excel") - raise Exception +if len(res) > 600 and from_export == 0: + msgprint("This is a very large report and cannot be shown in the browser as it is likely to make your browser very slow.Please select Account or click on 'Export' to open in excel") + raise Exception # ------------------------------------------------------------------ # main loop starts here # ------------------------------------------------------------------ +# get supplier type +supp_type_dict = {} +for each in sql("select t2.name, t1.supplier_type from tabSupplier t1, tabAccount t2 where t1.name = t2.account_name group by t2.name"): + supp_type_dict[each[0]] = each[1] + +# get due_date, bill_no, bill_date from PV +pv_dict = {} +for t in sql("select name, due_date, bill_no, bill_date from `tabPayable Voucher` group by name"): + pv_dict[t[0]] = [cstr(t[1]), t[2], cstr(t[3])] + +# pv outside this period +pv_outside_period = [d[0] for d in sql("select distinct name from `tabPayable Voucher` where (posting_date < '%s' or posting_date > '%s') and docstatus = 1" % (from_date, to_date))] + + out = [] total_booking_amt, total_outstanding_amt = 0,0 for r in res: - # get supplier type - supplier_type = sql("select t1.supplier_type from tabSupplier t1, tabAccount t2 where t1.name = t2.account_name and t2.name = '%s'" % r[col_idx['Account']]) - r.append(supplier_type and cstr(supplier_type[0][0]) or '') + outstanding_amt, due_date, bill_no, bill_date, cond = 0, '','','', '' + booking_amt = r.pop(8) + + # supplier type + r.append(supp_type_dict.get(r[col_idx['Account']], '')) + + # if entry against Payable Voucher + if r[col_idx['Against Voucher']] and r[col_idx['Voucher Type']] == 'Payable Voucher': + r += pv_dict.get(r[col_idx['Voucher No']], ['', '', '']) + cond = " and ifnull(against_voucher, '') = '%s'" % r[col_idx['Against Voucher']] - outstanding_amt, booking_amt, due_date, bill_no, bill_date, cond = 0,0, '','','', '' + # if entry against JV & and not adjusted within period + elif r[col_idx['Against Voucher Type']] == 'Payable Voucher' and r[col_idx['Against Voucher']] in pv_outside_period: + booking_amt = 0 + cond = " and voucher_no = '%s' and ifnull(against_voucher, '') = '%s'" % (r[col_idx['Voucher No']], r[col_idx['Against Voucher']]) + + # if un-adjusted + elif not r[col_idx['Against Voucher']]: + booking_amt = 0 + cond = " and ((voucher_no = '%s' and ifnull(against_voucher, '') = '') or (ifnull(against_voucher, '') = '%s' and voucher_type = 'Journal Voucher'))" % (r[col_idx['Voucher No']], r[col_idx['Voucher No']]) - # if entry against Payable Voucher - if r[col_idx['Against Voucher']] and r[col_idx['Voucher Type']] == 'Payable Voucher': - due_date, bill_no, bill_date = [cstr(t) for t in sql("select due_date,bill_no,bill_date from `tabPayable Voucher` where name = %s", r[col_idx['Voucher No']])[0]] + if cond: + outstanding_amt = flt(sql("select sum(ifnull(credit, 0))-sum(ifnull(debit, 0)) from `tabGL Entry` where account = '%s' and ifnull(is_cancelled, 'No') = 'No' and posting_date <= '%s' %s" % (r[col_idx['Account']], to_date, cond))[0][0] or 0) - # get opening - booking_amt = sql("select credit from `tabGL Entry` where account = %s and voucher_no = %s and is_cancelled = 'No'", (r[col_idx['Account']], r[col_idx['Voucher No']])) - booking_amt = booking_amt and flt(booking_amt[0][0]) or 0 + # add to total outstanding + total_outstanding_amt += flt(outstanding_amt) - cond = " and against_voucher = '%s' and against_voucher is not null" % r[col_idx['Against Voucher']] + # add to total booking amount + if outstanding_amt and r[col_idx['Voucher Type']] == 'Payable Voucher' and r[col_idx['Against Voucher']]: + total_booking_amt += flt(booking_amt) - # if entry against JV & and not adjusted within period - elif r[col_idx['Against Voucher Type']] == 'Payable Voucher' and sql("select name from `tabPayable Voucher` where name = '%s' and (posting_date < '%s' or posting_date > '%s') and docstatus = 1" % (r[col_idx['Against Voucher']], from_date, to_date)): - cond = " and voucher_no = '%s' and ifnull(against_voucher, '') = '%s'" % (r[col_idx['Voucher No']], r[col_idx['Against Voucher']]) - - # if un-adjusted - elif not r[col_idx['Against Voucher']]: - cond = " and ((voucher_no = '%s' and ifnull(against_voucher, '') = '') or (ifnull(against_voucher, '') = '%s' and voucher_type = 'Journal Voucher'))" % (r[col_idx['Voucher No']], r[col_idx['Voucher No']]) + r += [booking_amt, outstanding_amt] + + # split into date ranges + val_l1 = val_l2 = val_l3 = val_l4 = val_l5_above= 0 + if r[col_idx[aging_based_on]]: + diff = (getdate(to_date) - getdate(r[col_idx[aging_based_on]])).days + if diff < cint(filter_values['range_1']): + val_l1 = outstanding_amt + if diff >= cint(filter_values['range_1']) and diff < cint(filter_values['range_2']): + val_l2 = outstanding_amt + if diff >= cint(filter_values['range_2']) and diff < cint(filter_values['range_3']): + val_l3 = outstanding_amt + if diff >= cint(filter_values['range_3']) and diff < cint(filter_values['range_4']): + val_l4 = outstanding_amt + if diff >= cint(filter_values['range_4']): + val_l5_above = outstanding_amt - if cond: - outstanding_amt = flt(sql("select sum(ifnull(credit, 0))-sum(ifnull(debit, 0)) from `tabGL Entry` where account = '%s' and ifnull(is_cancelled, 'No') = 'No' and posting_date <= '%s' %s" % (r[col_idx['Account']], to_date, cond))[0][0] or 0) + r += [diff, val_l1, val_l2, val_l3, val_l4, val_l5_above] - # add to total outstanding - total_outstanding_amt += flt(outstanding_amt) - - # add to total booking amount - if outstanding_amt and r[col_idx['Voucher Type']] == 'Payable Voucher' and r[col_idx['Against Voucher']]: - total_booking_amt += flt(booking_amt) - - r += [due_date, bill_no, bill_date, booking_amt, outstanding_amt] - - # split into date ranges - val_l1 = val_l2 = val_l3 = val_l4 = val_l5_above= 0 - if r[col_idx[aging_based_on]]: - diff = (getdate(to_date) - getdate(r[col_idx[aging_based_on]])).days - if diff < cint(filter_values['range_1']): - val_l1 = outstanding_amt - if diff >= cint(filter_values['range_1']) and diff < cint(filter_values['range_2']): - val_l2 = outstanding_amt - if diff >= cint(filter_values['range_2']) and diff < cint(filter_values['range_3']): - val_l3 = outstanding_amt - if diff >= cint(filter_values['range_3']) and diff < cint(filter_values['range_4']): - val_l4 = outstanding_amt - if diff >= cint(filter_values['range_4']): - val_l5_above = outstanding_amt - - r += [diff, val_l1, val_l2, val_l3, val_l4, val_l5_above] - - # Only show that entry which has outstanding - if abs(flt(outstanding_amt)) > 0.001: - out.append(r) - -if len(out) > 300 and from_export == 0: - msgprint("This is a very large report and cannot be shown in the browser as it is likely to make your browser very slow.Please select Account or click on 'Export' to open in excel") - raise Exception + # Only show that entry which has outstanding + if abs(flt(outstanding_amt)) > 0.001: + out.append(r) + +if len(out) > 300 and from_export == 0: + msgprint("This is a very large report and cannot be shown in the browser as it is likely to make your browser very slow.Please select Account or click on 'Export' to open in excel") + raise Exception # Append Extra rows to RES diff --git a/accounts/search_criteria/accounts_payable/accounts_payable.sql b/accounts/search_criteria/accounts_payable/accounts_payable.sql index 520535f51f1..2054b1e7f0e 100644 --- a/accounts/search_criteria/accounts_payable/accounts_payable.sql +++ b/accounts/search_criteria/accounts_payable/accounts_payable.sql @@ -1,26 +1,11 @@ -SELECT * -FROM ( - -SELECT a.posting_date, a.voucher_no, a.account, a.credit AS inv_amount, ifnull( a.credit, 0 ) - ifnull( b.debit, 0 ) AS outstanding -FROM ( - -SELECT gl . * -FROM `tabGL Entry` gl, `tabAccount` acc -WHERE gl.account = acc.name -AND acc.master_type = 'Supplier' -AND ifnull( gl.is_cancelled, 'No' ) = 'No' -AND gl.credit >0 -AND gl.posting_date <= current_date -)a -LEFT JOIN ( - -SELECT against_voucher, account, sum( debit ) AS debit -FROM `tabGL Entry` -WHERE ifnull( is_cancelled, 'No' ) = 'No' -AND posting_date <= current_date -GROUP BY against_voucher, account -)b ON a.voucher_no = b.against_voucher -AND a.account = b.account -)c -WHERE outstanding !=0 -ORDER BY posting_date, voucher_no \ No newline at end of file +SELECT DISTINCT `tabGL Entry`.`Aging_date`,`tabGL Entry`.`transaction_date`,`tabGL Entry`.`account`, `tabGL Entry`.`against_voucher_type`, `tabGL Entry`.`against_voucher`,`tabGL Entry`.`voucher_type`,`tabGL Entry`.`voucher_no`, `tabGL Entry`.`remarks`, `tabGL Entry`.`credit` +FROM `tabGL Entry`,`tabAccount` +WHERE `tabGL Entry`.`posting_date`>= '%(posting_date)s' + AND `tabGL Entry`.`posting_date`<= '%(posting_date1)s' + AND `tabGL Entry`.`account` LIKE '%(account)s%%' + AND `tabGL Entry`.`company` LIKE '%(company)s%%' + AND ((ifnull(`tabGL Entry`.voucher_type,'') = 'Payable Voucher' and `tabGL Entry`.credit>0) OR `tabGL Entry`.voucher_type = 'Journal Voucher') + AND `tabGL Entry`.`is_cancelled` = 'No' + AND `tabAccount`.master_type = 'Supplier' + AND `tabAccount`.name = `tabGL Entry`.account + ORDER BY `tabGL Entry`.`posting_date` diff --git a/buying/doctype/indent/indent.txt b/buying/doctype/indent/indent.txt index 93767a8d208..cd6c91296c1 100644 --- a/buying/doctype/indent/indent.txt +++ b/buying/doctype/indent/indent.txt @@ -282,6 +282,7 @@ 'oldfieldtype': 'Data', 'options': 'Sales Order', 'permlevel': 0, + 'search_index': 0, 'width': '100px' }, @@ -338,7 +339,7 @@ 'permlevel': 0, 'print_hide': 1, 'reqd': 1, - 'search_index': 1, + 'search_index': 0, 'width': '150px' }, @@ -357,7 +358,7 @@ 'permlevel': 0, 'print_hide': 1, 'reqd': 1, - 'search_index': 1, + 'search_index': 0, 'width': '150px' }, @@ -487,7 +488,8 @@ 'options': 'Term', 'permlevel': 0, 'print_hide': 1, - 'report_hide': 1 + 'report_hide': 1, + 'search_index': 0 }, # DocField diff --git a/buying/doctype/indent_detail/indent_detail.txt b/buying/doctype/indent_detail/indent_detail.txt index c81b9cf4b25..c207266bbbb 100644 --- a/buying/doctype/indent_detail/indent_detail.txt +++ b/buying/doctype/indent_detail/indent_detail.txt @@ -85,7 +85,7 @@ 'oldfieldtype': 'Data', 'permlevel': 0, 'reqd': 1, - 'search_index': 1, + 'search_index': 0, 'width': '100px' }, @@ -132,6 +132,7 @@ 'options': 'Brand', 'permlevel': 1, 'print_hide': 1, + 'search_index': 0, 'width': '100px' }, @@ -151,7 +152,7 @@ 'permlevel': 1, 'print_hide': 1, 'reqd': 0, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -199,6 +200,7 @@ 'options': 'UOM', 'permlevel': 1, 'reqd': 1, + 'search_index': 0, 'width': '50px' }, diff --git a/buying/doctype/po_detail/po_detail.txt b/buying/doctype/po_detail/po_detail.txt index 9e4d790c0df..71d78df1f3e 100644 --- a/buying/doctype/po_detail/po_detail.txt +++ b/buying/doctype/po_detail/po_detail.txt @@ -54,7 +54,7 @@ 'permlevel': 0, 'print_hide': 1, 'reqd': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -89,7 +89,7 @@ 'permlevel': 0, 'print_hide': 1, 'reqd': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -182,6 +182,7 @@ 'permlevel': 0, 'print_hide': 0, 'reqd': 1, + 'search_index': 0, 'trigger': 'Client', 'width': '100px' }, @@ -331,7 +332,8 @@ 'oldfieldtype': 'Link', 'options': 'Brand', 'permlevel': 1, - 'print_hide': 1 + 'print_hide': 1, + 'search_index': 0 }, # DocField @@ -348,7 +350,7 @@ 'options': 'Item Group', 'permlevel': 1, 'print_hide': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField diff --git a/buying/doctype/qa_inspection_report/qa_inspection_report.txt b/buying/doctype/qa_inspection_report/qa_inspection_report.txt index 5febdec44ef..10890dc8461 100644 --- a/buying/doctype/qa_inspection_report/qa_inspection_report.txt +++ b/buying/doctype/qa_inspection_report/qa_inspection_report.txt @@ -206,7 +206,8 @@ 'oldfieldtype': 'Link', 'options': 'Serial No', 'permlevel': 0, - 'print_hide': 0 + 'print_hide': 0, + 'search_index': 0 }, # DocField @@ -219,7 +220,8 @@ 'oldfieldname': 'batch_no', 'oldfieldtype': 'Link', 'options': 'Batch', - 'permlevel': 0 + 'permlevel': 0, + 'search_index': 0 }, # DocField @@ -255,7 +257,7 @@ 'options': 'Delivery Note', 'permlevel': 0, 'print_hide': 0, - 'search_index': 1 + 'search_index': 0 }, # DocField diff --git a/buying/doctype/supplier/supplier.txt b/buying/doctype/supplier/supplier.txt index b7797e548fb..a7a08c3a07d 100644 --- a/buying/doctype/supplier/supplier.txt +++ b/buying/doctype/supplier/supplier.txt @@ -5,7 +5,7 @@ { 'creation': '2010-08-08 17:09:26', 'docstatus': 0, - 'modified': '2011-05-10 17:42:21', + 'modified': '2011-07-19 16:18:58', 'modified_by': 'Administrator', 'owner': 'Administrator' }, @@ -25,7 +25,7 @@ 'show_in_menu': 0, 'subject': ' ', 'tag_fields': 'supplier_type', - 'version': 86 + 'version': 87 }, # These values are common for all DocField @@ -163,24 +163,11 @@ 'permlevel': 0 }, - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'supplier_status', - 'fieldtype': 'Select', - 'idx': 6, - 'label': 'Supplier Status', - 'oldfieldname': 'supplier_status', - 'oldfieldtype': 'Select', - 'options': '\nApproved\nUnapproved', - 'permlevel': 0 - }, - # DocField { 'doctype': 'DocField', 'fieldtype': 'Section Break', - 'idx': 7, + 'idx': 6, 'label': 'Address & Contacts', 'oldfieldtype': 'Column Break', 'permlevel': 0 @@ -192,7 +179,7 @@ 'depends_on': 'eval:doc.__islocal', 'doctype': 'DocField', 'fieldtype': 'HTML', - 'idx': 8, + 'idx': 7, 'label': 'Address Desc', 'options': 'Addresses will appear only when you save the supplier', 'permlevel': 0 @@ -203,7 +190,7 @@ 'colour': 'White:FFF', 'doctype': 'DocField', 'fieldtype': 'HTML', - 'idx': 9, + 'idx': 8, 'label': 'Address HTML', 'permlevel': 1 }, @@ -212,7 +199,7 @@ { 'doctype': 'DocField', 'fieldtype': 'Column Break', - 'idx': 10, + 'idx': 9, 'permlevel': 0, 'width': '50%' }, @@ -223,7 +210,7 @@ 'depends_on': 'eval:doc.__islocal', 'doctype': 'DocField', 'fieldtype': 'HTML', - 'idx': 11, + 'idx': 10, 'label': 'Contact Desc', 'options': 'Contact Details will appear only when you save the supplier', 'permlevel': 0 @@ -233,7 +220,7 @@ { 'doctype': 'DocField', 'fieldtype': 'HTML', - 'idx': 12, + 'idx': 11, 'label': 'Contact HTML', 'permlevel': 1 }, @@ -242,7 +229,7 @@ { 'doctype': 'DocField', 'fieldtype': 'Section Break', - 'idx': 13, + 'idx': 12, 'label': 'More Info', 'oldfieldtype': 'Section Break', 'permlevel': 0 @@ -255,7 +242,7 @@ 'doctype': 'DocField', 'fieldname': 'company', 'fieldtype': 'Link', - 'idx': 14, + 'idx': 13, 'in_filter': 1, 'label': 'Company', 'oldfieldname': 'company', @@ -263,7 +250,7 @@ 'options': 'Company', 'permlevel': 0, 'reqd': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -273,7 +260,7 @@ 'doctype': 'DocField', 'fieldname': 'supplier_details', 'fieldtype': 'Text', - 'idx': 15, + 'idx': 14, 'label': 'Supplier Details', 'oldfieldname': 'supplier_details', 'oldfieldtype': 'Code', @@ -284,7 +271,7 @@ { 'doctype': 'DocField', 'fieldtype': 'Column Break', - 'idx': 16, + 'idx': 15, 'permlevel': 0, 'width': '50%' }, @@ -294,7 +281,7 @@ 'doctype': 'DocField', 'fieldname': 'credit_days', 'fieldtype': 'Int', - 'idx': 17, + 'idx': 16, 'label': 'Credit Days', 'permlevel': 0 }, @@ -304,7 +291,7 @@ 'doctype': 'DocField', 'fieldname': 'website', 'fieldtype': 'Data', - 'idx': 18, + 'idx': 17, 'label': 'Website', 'oldfieldname': 'website', 'oldfieldtype': 'Data', @@ -317,7 +304,7 @@ 'depends_on': 'eval:!doc.__islocal', 'doctype': 'DocField', 'fieldtype': 'Section Break', - 'idx': 19, + 'idx': 18, 'label': 'Transaction History', 'oldfieldtype': 'Section Break', 'permlevel': 0 @@ -329,7 +316,7 @@ 'depends_on': 'eval:!doc.__islocal', 'doctype': 'DocField', 'fieldtype': 'HTML', - 'idx': 20, + 'idx': 19, 'label': 'History HTML', 'oldfieldtype': 'HTML', 'permlevel': 0 @@ -340,7 +327,7 @@ 'doctype': 'DocField', 'fieldname': 'trash_reason', 'fieldtype': 'Small Text', - 'idx': 21, + 'idx': 20, 'label': 'Trash Reason', 'oldfieldname': 'trash_reason', 'oldfieldtype': 'Small Text', diff --git a/favicon.ico b/favicon.ico new file mode 100644 index 00000000000..8b2106b847e Binary files /dev/null and b/favicon.ico differ diff --git a/hr/doctype/attendance/attendance.txt b/hr/doctype/attendance/attendance.txt index a52225e7a57..4f189b1cdcf 100644 --- a/hr/doctype/attendance/attendance.txt +++ b/hr/doctype/attendance/attendance.txt @@ -141,7 +141,7 @@ 'oldfieldtype': 'Select', 'options': '\nPresent\nAbsent\nHalf Day', 'reqd': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -193,7 +193,7 @@ 'oldfieldname': 'att_date', 'oldfieldtype': 'Date', 'reqd': 1, - 'search_index': 0 + 'search_index': 1 }, # DocField diff --git a/hr/doctype/educational_qualifications/educational_qualifications.txt b/hr/doctype/educational_qualifications/educational_qualifications.txt index 21f4a9adf1c..d57139bdf81 100644 --- a/hr/doctype/educational_qualifications/educational_qualifications.txt +++ b/hr/doctype/educational_qualifications/educational_qualifications.txt @@ -75,7 +75,7 @@ 'oldfieldtype': 'Select', 'options': '\nGraduate\nPost Graduate\nUnder Graduate', 'reqd': 0, - 'search_index': 1 + 'search_index': 0 }, # DocField diff --git a/hr/doctype/employee/employee.txt b/hr/doctype/employee/employee.txt index cbe281d8377..49a494b99b1 100644 --- a/hr/doctype/employee/employee.txt +++ b/hr/doctype/employee/employee.txt @@ -173,7 +173,8 @@ 'oldfieldname': 'employee_name', 'oldfieldtype': 'Data', 'permlevel': 0, - 'reqd': 1 + 'reqd': 1, + 'search_index': 1 }, # DocField @@ -275,7 +276,7 @@ 'options': '\nActive\nLeft', 'permlevel': 0, 'reqd': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -408,7 +409,8 @@ 'oldfieldtype': 'Link', 'options': 'Department', 'permlevel': 0, - 'reqd': 1 + 'reqd': 1, + 'search_index': 1 }, # DocField diff --git a/hr/doctype/expense_voucher/expense_voucher.txt b/hr/doctype/expense_voucher/expense_voucher.txt index 0f7812e87c6..596d4b5c500 100644 --- a/hr/doctype/expense_voucher/expense_voucher.txt +++ b/hr/doctype/expense_voucher/expense_voucher.txt @@ -189,7 +189,7 @@ 'oldfieldname': 'employee_name', 'oldfieldtype': 'Data', 'permlevel': 1, - 'search_index': 1, + 'search_index': 0, 'width': '150px' }, diff --git a/hr/doctype/leave_allocation/leave_allocation.txt b/hr/doctype/leave_allocation/leave_allocation.txt index 0b0c96c25d4..b147a7fb023 100644 --- a/hr/doctype/leave_allocation/leave_allocation.txt +++ b/hr/doctype/leave_allocation/leave_allocation.txt @@ -136,7 +136,7 @@ 'in_filter': 1, 'label': 'Employee Name', 'permlevel': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField diff --git a/hr/doctype/leave_application/leave_application.txt b/hr/doctype/leave_application/leave_application.txt index 11d01e6ba11..06b4170eb4c 100644 --- a/hr/doctype/leave_application/leave_application.txt +++ b/hr/doctype/leave_application/leave_application.txt @@ -3,9 +3,9 @@ # These values are common in all dictionaries { - 'creation': '2011-02-17 13:25:56', + 'creation': '2011-02-10 14:10:08', 'docstatus': 0, - 'modified': '2011-07-08 13:28:15', + 'modified': '2011-07-11 12:48:49', 'modified_by': 'Administrator', 'owner': 'Administrator' }, @@ -54,28 +54,28 @@ # DocPerm { - 'amend': 0, - 'cancel': 0, + 'amend': 1, + 'cancel': 1, 'create': 1, 'doctype': 'DocPerm', 'idx': 1, + 'match': 'owner', 'permlevel': 0, - 'role': 'Employee', - 'submit': 0, + 'submit': 1, 'write': 1 }, # DocPerm { - 'amend': 1, - 'cancel': 1, - 'create': 1, + 'amend': 0, + 'cancel': 0, + 'create': 0, 'doctype': 'DocPerm', 'idx': 2, + 'match': 'owner', 'permlevel': 0, - 'role': 'HR User', - 'submit': 1, - 'write': 1 + 'submit': 0, + 'write': 0 }, # DocPerm @@ -86,6 +86,19 @@ 'doctype': 'DocPerm', 'idx': 3, 'permlevel': 0, + 'role': 'HR User', + 'submit': 1, + 'write': 1 + }, + + # DocPerm + { + 'amend': 1, + 'cancel': 1, + 'create': 1, + 'doctype': 'DocPerm', + 'idx': 4, + 'permlevel': 0, 'role': 'HR Manager', 'submit': 1, 'write': 1 @@ -93,28 +106,18 @@ # DocPerm { - 'amend': 0, - 'cancel': 0, - 'create': 0, 'doctype': 'DocPerm', - 'idx': 4, + 'idx': 5, 'permlevel': 1, - 'role': 'HR User', - 'submit': 0, - 'write': 0 + 'role': 'HR User' }, # DocPerm { - 'amend': 0, - 'cancel': 0, - 'create': 0, 'doctype': 'DocPerm', - 'idx': 5, + 'idx': 6, 'permlevel': 1, - 'role': 'HR Manager', - 'submit': 0, - 'write': 0 + 'role': 'HR Manager' }, # DocField @@ -149,7 +152,7 @@ 'in_filter': 1, 'label': 'Employee Name', 'permlevel': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -201,7 +204,7 @@ 'options': 'link:Fiscal Year', 'permlevel': 0, 'reqd': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -234,6 +237,7 @@ 'idx': 10, 'label': 'From Date', 'permlevel': 0, + 'search_index': 1, 'trigger': 'Client' }, @@ -246,6 +250,7 @@ 'idx': 11, 'label': 'To Date', 'permlevel': 0, + 'search_index': 1, 'trigger': 'Client' }, diff --git a/hr/doctype/salary_slip/salary_slip.txt b/hr/doctype/salary_slip/salary_slip.txt deleted file mode 100644 index 2886e424b59..00000000000 --- a/hr/doctype/salary_slip/salary_slip.txt +++ /dev/null @@ -1,614 +0,0 @@ -# DocType, Salary Slip -[ - - # These values are common in all dictionaries - { - 'creation': '2010-08-08 17:09:20', - 'docstatus': 0, - 'modified': '2011-07-14 16:07:20', - 'modified_by': 'Administrator', - 'owner': 'Administrator' - }, - - # These values are common for all DocType - { - '_last_update': '1310019491', - 'colour': 'White:FFF', - 'doctype': 'DocType', - 'module': 'HR', - 'name': '__common__', - 'section_style': 'Simple', - 'server_code_error': ' ', - 'show_in_menu': 0, - 'subject': 'For %(employee_name)s, %(designation)s', - 'version': 392 - }, - - # These values are common for all DocField - { - 'doctype': 'DocField', - 'name': '__common__', - 'parent': 'Salary Slip', - 'parentfield': 'fields', - 'parenttype': 'DocType' - }, - - # These values are common for all DocPerm - { - 'doctype': 'DocPerm', - 'name': '__common__', - 'parent': 'Salary Slip', - 'parentfield': 'permissions', - 'parenttype': 'DocType', - 'read': 1 - }, - - # DocType, Salary Slip - { - 'doctype': 'DocType', - 'name': 'Salary Slip' - }, - - # DocPerm - { - 'amend': 0, - 'cancel': 0, - 'create': 0, - 'doctype': 'DocPerm', - 'match': 'owner', - 'permlevel': 0, - 'role': 'Employee', - 'submit': 0, - 'write': 0 - }, - - # DocPerm - { - 'amend': 0, - 'cancel': 0, - 'create': 0, - 'doctype': 'DocPerm', - 'match': 'owner', - 'permlevel': 0, - 'role': 'Employee', - 'submit': 0, - 'write': 0 - }, - - # DocPerm - { - 'amend': 0, - 'create': 1, - 'doctype': 'DocPerm', - 'idx': 3, - 'permlevel': 0, - 'role': 'HR User', - 'submit': 1, - 'write': 1 - }, - - # DocPerm - { - 'amend': 1, - 'cancel': 1, - 'create': 1, - 'doctype': 'DocPerm', - 'idx': 4, - 'permlevel': 0, - 'role': 'HR Manager', - 'submit': 1, - 'write': 1 - }, - - # DocPerm - { - 'doctype': 'DocPerm', - 'idx': 5, - 'permlevel': 1, - 'role': 'HR User' - }, - - # DocPerm - { - 'doctype': 'DocPerm', - 'idx': 6, - 'permlevel': 1, - 'role': 'HR Manager' - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldtype': 'Section Break', - 'idx': 1, - 'label': 'Basic Info', - 'oldfieldtype': 'Section Break', - 'permlevel': 0 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldtype': 'Column Break', - 'idx': 2, - 'oldfieldtype': 'Column Break', - 'permlevel': 0, - 'width': '50%' - }, - - # DocField - { - 'colour': 'White:FFF', - 'doctype': 'DocField', - 'fieldname': 'employee', - 'fieldtype': 'Link', - 'idx': 3, - 'in_filter': 1, - 'label': 'Employee', - 'oldfieldname': 'employee', - 'oldfieldtype': 'Link', - 'options': 'Employee', - 'permlevel': 0, - 'reqd': 1, - 'search_index': 0 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'employee_name', - 'fieldtype': 'Data', - 'idx': 4, - 'in_filter': 1, - 'label': 'Employee Name', - 'oldfieldname': 'employee_name', - 'oldfieldtype': 'Data', - 'permlevel': 1, - 'reqd': 1 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'department', - 'fieldtype': 'Link', - 'idx': 5, - 'in_filter': 1, - 'label': 'Department', - 'oldfieldname': 'department', - 'oldfieldtype': 'Link', - 'options': 'Department', - 'permlevel': 1, - 'reqd': 0, - 'search_index': 1 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'designation', - 'fieldtype': 'Link', - 'idx': 6, - 'in_filter': 1, - 'label': 'Designation', - 'oldfieldname': 'designation', - 'oldfieldtype': 'Link', - 'options': 'Designation', - 'permlevel': 1, - 'search_index': 1 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'branch', - 'fieldtype': 'Link', - 'idx': 7, - 'in_filter': 1, - 'label': 'Branch', - 'oldfieldname': 'branch', - 'oldfieldtype': 'Link', - 'options': 'Branch', - 'permlevel': 1, - 'search_index': 1 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'grade', - 'fieldtype': 'Link', - 'idx': 8, - 'in_filter': 1, - 'label': 'Grade', - 'oldfieldname': 'grade', - 'oldfieldtype': 'Link', - 'options': 'Grade', - 'permlevel': 1, - 'search_index': 1 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'pf_no', - 'fieldtype': 'Data', - 'idx': 9, - 'label': 'PF No.', - 'oldfieldname': 'pf_no', - 'oldfieldtype': 'Data', - 'permlevel': 1 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'esic_no', - 'fieldtype': 'Data', - 'idx': 10, - 'label': 'ESIC No.', - 'oldfieldname': 'esic_no', - 'oldfieldtype': 'Data', - 'permlevel': 1 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'letter_head', - 'fieldtype': 'Link', - 'idx': 11, - 'label': 'Letter Head', - 'options': 'Letter Head', - 'permlevel': 0 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldtype': 'Column Break', - 'idx': 12, - 'oldfieldtype': 'Column Break', - 'permlevel': 0, - 'width': '50%' - }, - - # DocField - { - 'colour': 'White:FFF', - 'doctype': 'DocField', - 'fieldname': 'fiscal_year', - 'fieldtype': 'Link', - 'idx': 13, - 'in_filter': 1, - 'label': 'Fiscal Year', - 'oldfieldname': 'fiscal_year', - 'oldfieldtype': 'Data', - 'options': 'Fiscal Year', - 'permlevel': 0, - 'reqd': 1, - 'search_index': 1 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'company', - 'fieldtype': 'Select', - 'idx': 14, - 'in_filter': 1, - 'label': 'Company', - 'options': 'link:Company', - 'permlevel': 0, - 'reqd': 1 - }, - - # DocField - { - 'colour': 'White:FFF', - 'doctype': 'DocField', - 'fieldname': 'month', - 'fieldtype': 'Select', - 'idx': 15, - 'in_filter': 1, - 'label': 'Month', - 'oldfieldname': 'month', - 'oldfieldtype': 'Select', - 'options': '\n01\n02\n03\n04\n05\n06\n07\n08\n09\n10\n11\n12', - 'permlevel': 0, - 'reqd': 1, - 'search_index': 1, - 'trigger': 'Client', - 'width': '37%' - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'total_days_in_month', - 'fieldtype': 'Data', - 'idx': 16, - 'label': 'Total days in month', - 'oldfieldname': 'total_days_in_month', - 'oldfieldtype': 'Int', - 'permlevel': 1, - 'reqd': 1 - }, - - # DocField - { - 'colour': 'White:FFF', - 'doctype': 'DocField', - 'fieldname': 'leave_without_pay', - 'fieldtype': 'Currency', - 'idx': 17, - 'label': 'Leave Without Pay', - 'oldfieldname': 'leave_without_pay', - 'oldfieldtype': 'Currency', - 'permlevel': 0, - 'trigger': 'Client' - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'payment_days', - 'fieldtype': 'Float', - 'idx': 18, - 'label': 'Payment days', - 'oldfieldname': 'payment_days', - 'oldfieldtype': 'Float', - 'permlevel': 1, - 'reqd': 1 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'bank_name', - 'fieldtype': 'Data', - 'idx': 19, - 'label': 'Bank Name', - 'oldfieldname': 'bank_name', - 'oldfieldtype': 'Data', - 'permlevel': 1 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'bank_account_no', - 'fieldtype': 'Data', - 'idx': 20, - 'label': 'Bank Account No.', - 'oldfieldname': 'bank_account_no', - 'oldfieldtype': 'Data', - 'permlevel': 1 - }, - - # DocField - { - 'colour': 'White:FFF', - 'doctype': 'DocField', - 'fieldname': 'email_check', - 'fieldtype': 'Check', - 'idx': 21, - 'label': 'Email', - 'no_copy': 1, - 'oldfieldname': 'email_check', - 'oldfieldtype': 'Check', - 'permlevel': 0, - 'print_hide': 1, - 'report_hide': 1 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'amended_from', - 'fieldtype': 'Data', - 'hidden': 0, - 'idx': 22, - 'label': 'Amended From', - 'no_copy': 1, - 'oldfieldname': 'amended_from', - 'oldfieldtype': 'Data', - 'permlevel': 0, - 'print_hide': 1, - 'report_hide': 0 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'amendment_date', - 'fieldtype': 'Date', - 'hidden': 0, - 'idx': 23, - 'label': 'Amendment Date', - 'no_copy': 1, - 'oldfieldname': 'amendment_date', - 'oldfieldtype': 'Date', - 'permlevel': 0, - 'print_hide': 1, - 'report_hide': 0 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldtype': 'Section Break', - 'idx': 24, - 'label': 'Earning & Deduction', - 'oldfieldtype': 'Section Break', - 'permlevel': 0 - }, - - # DocField - { - 'colour': 'White:FFF', - 'doctype': 'DocField', - 'fieldtype': 'Column Break', - 'idx': 25, - 'label': 'Earning', - 'oldfieldtype': 'Column Break', - 'permlevel': 0, - 'reqd': 0, - 'width': '50%' - }, - - # DocField - { - 'colour': 'White:FFF', - 'doctype': 'DocField', - 'fieldname': 'earning_details', - 'fieldtype': 'Table', - 'idx': 26, - 'label': 'Earning Details', - 'oldfieldname': 'earning_details', - 'oldfieldtype': 'Table', - 'options': 'SS Earning Detail', - 'permlevel': 0 - }, - - # DocField - { - 'colour': 'White:FFF', - 'doctype': 'DocField', - 'fieldtype': 'Column Break', - 'idx': 27, - 'label': 'Deduction', - 'oldfieldtype': 'Column Break', - 'permlevel': 0, - 'width': '50%' - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'deduction_details', - 'fieldtype': 'Table', - 'idx': 28, - 'label': 'Deduction Details', - 'oldfieldname': 'deduction_details', - 'oldfieldtype': 'Table', - 'options': 'SS Deduction Detail', - 'permlevel': 0 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldtype': 'Section Break', - 'idx': 29, - 'label': 'Totals', - 'oldfieldtype': 'Section Break', - 'permlevel': 0 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldtype': 'Column Break', - 'idx': 30, - 'oldfieldtype': 'Column Break', - 'permlevel': 0, - 'width': '50%' - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'arrear_amount', - 'fieldtype': 'Currency', - 'idx': 31, - 'label': 'Arrear Amount', - 'oldfieldname': 'arrear_amount', - 'oldfieldtype': 'Currency', - 'permlevel': 0 - }, - - # DocField - { - 'colour': 'White:FFF', - 'doctype': 'DocField', - 'fieldname': 'leave_encashment_amount', - 'fieldtype': 'Currency', - 'idx': 32, - 'label': 'Leave Encashment Amount', - 'oldfieldname': 'encashment_amount', - 'oldfieldtype': 'Currency', - 'permlevel': 0 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'gross_pay', - 'fieldtype': 'Currency', - 'idx': 33, - 'label': 'Gross Pay', - 'oldfieldname': 'gross_pay', - 'oldfieldtype': 'Currency', - 'permlevel': 1 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'total_deduction', - 'fieldtype': 'Currency', - 'idx': 34, - 'label': 'Total Deduction', - 'oldfieldname': 'total_deduction', - 'oldfieldtype': 'Currency', - 'permlevel': 1 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldtype': 'Column Break', - 'idx': 35, - 'oldfieldtype': 'Column Break', - 'permlevel': 0, - 'width': '50%' - }, - - # DocField - { - 'colour': 'White:FFF', - 'description': 'Gross Pay + Arrear Amount +Encashment Amount - Total Deduction', - 'doctype': 'DocField', - 'fieldname': 'net_pay', - 'fieldtype': 'Currency', - 'idx': 36, - 'label': 'Net Pay', - 'oldfieldname': 'net_pay', - 'oldfieldtype': 'Currency', - 'permlevel': 1 - }, - - # DocField - { - 'doctype': 'DocField', - 'fieldname': 'rounded_total', - 'fieldtype': 'Currency', - 'idx': 37, - 'label': 'Rounded Total', - 'permlevel': 1 - }, - - # DocField - { - 'description': 'Net Pay (in words) will be visible once you save the Salary Slip.', - 'doctype': 'DocField', - 'fieldname': 'total_in_words', - 'fieldtype': 'Data', - 'idx': 38, - 'label': 'Total in words', - 'oldfieldname': 'net_pay_in_words', - 'oldfieldtype': 'Data', - 'permlevel': 1 - } -] \ No newline at end of file diff --git a/knowledge_base/doctype/question/question.txt b/knowledge_base/doctype/question/question.txt index 428d269fe99..187789ce6fc 100644 --- a/knowledge_base/doctype/question/question.txt +++ b/knowledge_base/doctype/question/question.txt @@ -115,7 +115,8 @@ 'label': 'Tag 1', 'oldfieldname': 'tag_1', 'oldfieldtype': 'Link', - 'options': 'Question Tag' + 'options': 'Question Tag', + 'search_index': 0 }, # DocField @@ -136,7 +137,8 @@ 'label': 'Tag 2', 'oldfieldname': 'tag_2', 'oldfieldtype': 'Link', - 'options': 'Question Tag' + 'options': 'Question Tag', + 'search_index': 0 }, # DocField @@ -148,7 +150,8 @@ 'label': 'Tag 3', 'oldfieldname': 'tag_3', 'oldfieldtype': 'Link', - 'options': 'Question Tag' + 'options': 'Question Tag', + 'search_index': 0 }, # DocField diff --git a/patches/index_patch.py b/patches/index_patch.py index 8f6c4f2d810..3ef8ec367ae 100644 --- a/patches/index_patch.py +++ b/patches/index_patch.py @@ -2,6 +2,9 @@ This patch removes wrong indexs and add proper indexes in tables """ +import webnotes +sql = webnotes.conn.sql +from webnotes.utils import cint, cstr def create_proper_index(): from webnotes.modules.export_module import export_to_files @@ -264,29 +267,29 @@ def create_proper_index(): 'Print Heading': [], 'TDS Rate Detail': ['category'] } - - for dt in dt_index_fields.keys(): - current_index = sql("show indexes from `tab%s`" % dt) + #sql("commit") # only required if run from login + exist_dt = [cstr(d[0]) for d in sql("select name from `tabDocType`")] - proper_index = dt_index_fields[dt] + for dt in [d for d in dt_index_fields.keys() if d in exist_dt]: + try: + current_index = sql("show indexes from `tab%s`" % dt) - for d in current_index: - if d[4] not in ['name', 'parent', 'parenttype']: - if d[4] not in proper_index: - sql("ALTER TABLE `tab%s` DROP INDEX %s" % (dt, d[4])) - sql("start transaction") - sql("UPDATE `tabDocField` SET search_index = 0 WHERE fieldname = '%s' AND parent = '%s'" % (d[4], dt)) - sql("commit") - else: - proper_index.remove(d[4]) + proper_index = dt_index_fields[dt] - for d in proper_index: - sql("ALTER TABLE `tab%s` ADD INDEX ( `%s` ) " % (dt, d)) - sql("start transaction") - sql("UPDATE `tabDocField` SET search_index = 1 WHERE fieldname = '%s' AND parent = '%s'" % (d, dt)) - sql("commit") - - sql("start transaction") - dt_module = sql("select module from `tabDocType` where name = '%s'" % dt)[0][0] - export_to_files(record_list = [['DocType', dt]], record_module = dt_module) - sql("commit") + for d in current_index: + if d[4] not in ['name', 'parent', 'parenttype']: + if d[4] not in proper_index: + sql("ALTER TABLE `tab%s` DROP INDEX %s" % (dt, d[4])) + sql("start transaction") + sql("UPDATE `tabDocField` SET search_index = 0 WHERE fieldname = '%s' AND parent = '%s'" % (d[4], dt)) + sql("commit") + else: + proper_index.remove(d[4]) + + for d in proper_index: + sql("ALTER TABLE `tab%s` ADD INDEX ( `%s` ) " % (dt, d)) + sql("start transaction") + sql("UPDATE `tabDocField` SET search_index = 1 WHERE fieldname = '%s' AND parent = '%s'" % (d, dt)) + sql("commit") + except: + continue diff --git a/patches/patch.py b/patches/patch.py index 384ee2a0032..3f6c93e0c11 100644 --- a/patches/patch.py +++ b/patches/patch.py @@ -1,13 +1,12 @@ # REMEMBER to update this # ======================== -last_patch = 326 +last_patch = 330 #------------------------------------------- def execute(patch_no): import webnotes - from webnotes.modules.import_module import import_from_files from webnotes.modules.module_manager import reload_doc from webnotes.model.code import get_obj @@ -1298,3 +1297,37 @@ def execute(patch_no): # load the new billing page if cint(webnotes.conn.get_value('Control Panel',None,'sync_with_gateway')): reload_doc('server_tools','page','billing') + elif patch_no == 327: + # patch for support email settings now moved to email settings + reload_doc('setup','doctype','email_settings') + + # map fields from support to email settings + field_map = { + 'support_email': 'email', + 'support_host':'host', + 'support_username': 'username', + 'support_password': 'password', + 'support_use_ssl': 'use_ssl', + 'sync_support_mails': 'integrate_incoming', + 'signature': 'support_signature' + } + + for key in field_map: + webnotes.conn.set_value('Email Settings',None,key, \ + webnotes.conn.get_value('Support Email Settings',None,field_map[key])) + + # delete support email settings + from webnotes.model import delete_doc + delete_doc('DocType', 'Support Email Settings') + + reload_doc('support','doctype','support_ticket') + sql("delete from tabDocField where fieldname='problem_description' and parent='Support Ticket'") + elif patch_no == 328: + if webnotes.conn.get_value('Control Panel', None, 'account_id') != 'axjanak2011': + sql("delete from `tabDocField` where fieldname = 'supplier_status' and parent = 'Supplier'") + elif patch_no == 329: + from index_patch import create_proper_index + create_proper_index() + elif patch_no == 330: + reload_doc('utilities', 'doctype', 'rename_tool') + reload_doc('utilities', 'doctype', 'bulk_rename_tool') diff --git a/production/doctype/bill_of_materials/bill_of_materials.txt b/production/doctype/bill_of_materials/bill_of_materials.txt index 4e788d7cdb5..37d8b69491b 100644 --- a/production/doctype/bill_of_materials/bill_of_materials.txt +++ b/production/doctype/bill_of_materials/bill_of_materials.txt @@ -12,6 +12,7 @@ # These values are common for all DocType { + '_last_update': '1309508837', 'allow_attach': 0, 'allow_copy': 0, 'allow_email': 0, diff --git a/production/doctype/bom_operation/bom_operation.txt b/production/doctype/bom_operation/bom_operation.txt index 873faec352c..9bc7f9e32f6 100644 --- a/production/doctype/bom_operation/bom_operation.txt +++ b/production/doctype/bom_operation/bom_operation.txt @@ -114,6 +114,7 @@ 'options': 'Workstation', 'permlevel': 0, 'reqd': 1, + 'search_index': 0, 'trigger': 'Client' }, diff --git a/production/doctype/bom_replace_utility_detail/bom_replace_utility_detail.txt b/production/doctype/bom_replace_utility_detail/bom_replace_utility_detail.txt index ab18e44accb..d36f26ba0ac 100644 --- a/production/doctype/bom_replace_utility_detail/bom_replace_utility_detail.txt +++ b/production/doctype/bom_replace_utility_detail/bom_replace_utility_detail.txt @@ -99,6 +99,7 @@ 'oldfieldname': 'bom_created', 'oldfieldtype': 'Link', 'options': 'Bill Of Materials', - 'permlevel': 1 + 'permlevel': 1, + 'search_index': 0 } ] \ No newline at end of file diff --git a/production/doctype/flat_bom_detail/flat_bom_detail.txt b/production/doctype/flat_bom_detail/flat_bom_detail.txt index 4b8812b44eb..73393005fb2 100644 --- a/production/doctype/flat_bom_detail/flat_bom_detail.txt +++ b/production/doctype/flat_bom_detail/flat_bom_detail.txt @@ -162,7 +162,8 @@ 'label': 'Stock UOM', 'oldfieldname': 'stock_uom', 'oldfieldtype': 'Link', - 'options': 'UOM' + 'options': 'UOM', + 'search_index': 0 }, # DocField diff --git a/production/doctype/pp_detail/pp_detail.txt b/production/doctype/pp_detail/pp_detail.txt index 61a34bdf76c..482fae23ca4 100644 --- a/production/doctype/pp_detail/pp_detail.txt +++ b/production/doctype/pp_detail/pp_detail.txt @@ -131,7 +131,7 @@ 'oldfieldtype': 'Date', 'permlevel': 0, 'reqd': 1, - 'search_index': 1, + 'search_index': 0, 'width': '100px' }, @@ -146,6 +146,7 @@ 'oldfieldtype': 'Link', 'options': 'Bill Of Materials', 'permlevel': 0, + 'search_index': 0, 'width': '100px' }, diff --git a/production/doctype/production_order/production_order.txt b/production/doctype/production_order/production_order.txt index 7df63971d41..c927edfae1d 100644 --- a/production/doctype/production_order/production_order.txt +++ b/production/doctype/production_order/production_order.txt @@ -180,6 +180,7 @@ 'options': 'Bill Of Materials', 'permlevel': 1, 'reqd': 1, + 'search_index': 0, 'trigger': 'Client' }, @@ -306,7 +307,8 @@ 'oldfieldtype': 'Link', 'options': 'Warehouse', 'permlevel': 0, - 'reqd': 1 + 'reqd': 1, + 'search_index': 0 }, # DocField @@ -323,7 +325,8 @@ 'oldfieldtype': 'Link', 'options': 'Warehouse', 'permlevel': 0, - 'reqd': 1 + 'reqd': 1, + 'search_index': 0 }, # DocField @@ -367,7 +370,8 @@ 'oldfieldtype': 'Link', 'options': 'Company', 'permlevel': 0, - 'reqd': 1 + 'reqd': 1, + 'search_index': 0 }, # DocField diff --git a/production/doctype/update_delivery_date_detail/update_delivery_date_detail.txt b/production/doctype/update_delivery_date_detail/update_delivery_date_detail.txt index f8499ce4a77..646a97ee0af 100644 --- a/production/doctype/update_delivery_date_detail/update_delivery_date_detail.txt +++ b/production/doctype/update_delivery_date_detail/update_delivery_date_detail.txt @@ -86,7 +86,8 @@ 'oldfieldname': 'state', 'oldfieldtype': 'Link', 'options': 'State', - 'permlevel': 0 + 'permlevel': 0, + 'search_index': 0 }, # DocField @@ -100,7 +101,8 @@ 'oldfieldtype': 'Link', 'options': 'Territory', 'permlevel': 1, - 'print_hide': 1 + 'print_hide': 1, + 'search_index': 0 }, # DocField diff --git a/projects/doctype/project/project.txt b/projects/doctype/project/project.txt index b1442468898..3d57e12b919 100644 --- a/projects/doctype/project/project.txt +++ b/projects/doctype/project/project.txt @@ -94,7 +94,8 @@ 'oldfieldname': 'project_name', 'oldfieldtype': 'Data', 'permlevel': 0, - 'reqd': 1 + 'reqd': 1, + 'search_index': 1 }, # DocField @@ -112,7 +113,7 @@ 'options': 'Open\nCompleted\nCancelled', 'permlevel': 0, 'reqd': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -356,7 +357,7 @@ 'oldfieldname': 'customer_name', 'oldfieldtype': 'Data', 'permlevel': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -401,6 +402,7 @@ 'options': 'Territory', 'permlevel': 0, 'reqd': 0, + 'search_index': 0, 'trigger': 'Client' }, @@ -438,7 +440,8 @@ 'oldfieldname': 'customer_group', 'oldfieldtype': 'Link', 'options': 'Customer Group', - 'permlevel': 1 + 'permlevel': 1, + 'search_index': 0 }, # DocField diff --git a/projects/doctype/timesheet/timesheet.txt b/projects/doctype/timesheet/timesheet.txt index 462b64bc284..839da19ad1a 100644 --- a/projects/doctype/timesheet/timesheet.txt +++ b/projects/doctype/timesheet/timesheet.txt @@ -145,7 +145,8 @@ 'oldfieldtype': 'Link', 'options': 'Profile', 'permlevel': 0, - 'reqd': 1 + 'reqd': 1, + 'search_index': 0 }, # DocField diff --git a/projects/doctype/timesheet_detail/timesheet_detail.txt b/projects/doctype/timesheet_detail/timesheet_detail.txt index a96c14b9ff4..0098228ff10 100644 --- a/projects/doctype/timesheet_detail/timesheet_detail.txt +++ b/projects/doctype/timesheet_detail/timesheet_detail.txt @@ -75,6 +75,7 @@ 'options': 'Activity Type', 'permlevel': 0, 'reqd': 1, + 'search_index': 0, 'width': '200px' }, diff --git a/selling/doctype/customer/customer.txt b/selling/doctype/customer/customer.txt index 364b148fafb..24271ee688c 100644 --- a/selling/doctype/customer/customer.txt +++ b/selling/doctype/customer/customer.txt @@ -5,14 +5,14 @@ { 'creation': '2010-08-08 17:08:56', 'docstatus': 0, - 'modified': '2011-05-26 17:31:31', + 'modified': '2011-07-20 10:42:05', 'modified_by': 'Administrator', 'owner': 'Administrator' }, # These values are common for all DocType { - '_last_update': '1306834669', + '_last_update': '1309508837', 'allow_print': 0, 'allow_trash': 1, 'colour': 'White:FFF', @@ -26,7 +26,7 @@ 'show_in_menu': 0, 'subject': "eval:'%(customer_name)s'=='%(name)s' ? ' ' : '%(customer_name)s'", 'tag_fields': 'customer_group,customer_type', - 'version': 431 + 'version': 433 }, # These values are common for all DocField @@ -176,7 +176,7 @@ 'idx': 4, 'label': 'Series', 'no_copy': 1, - 'options': '\nCUST\nCUSTMUM', + 'options': '\nCUST\nCUSTMUM\nCUSTOM', 'permlevel': 0, 'print_hide': 0 }, @@ -340,7 +340,7 @@ 'options': 'Company', 'permlevel': 0, 'reqd': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField diff --git a/selling/doctype/enquiry/enquiry.txt b/selling/doctype/enquiry/enquiry.txt index c13ad46956d..260e077bae7 100644 --- a/selling/doctype/enquiry/enquiry.txt +++ b/selling/doctype/enquiry/enquiry.txt @@ -187,7 +187,7 @@ 'permlevel': 0, 'print_hide': 1, 'reqd': 0, - 'search_index': 0, + 'search_index': 1, 'trigger': 'Client' }, @@ -244,6 +244,7 @@ 'options': 'Lead', 'permlevel': 0, 'print_hide': 1, + 'search_index': 1, 'trigger': 'Client' }, @@ -326,6 +327,7 @@ 'oldfieldtype': 'Date', 'permlevel': 0, 'reqd': 1, + 'search_index': 1, 'width': '50px' }, @@ -405,7 +407,7 @@ 'permlevel': 0, 'print_hide': 1, 'reqd': 1, - 'search_index': 1, + 'search_index': 0, 'trigger': 'Client' }, @@ -426,7 +428,7 @@ 'permlevel': 0, 'print_hide': 1, 'reqd': 0, - 'search_index': 1, + 'search_index': 0, 'trigger': 'Client' }, @@ -492,7 +494,7 @@ 'permlevel': 0, 'print_hide': 1, 'reqd': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -509,7 +511,7 @@ 'permlevel': 0, 'print_hide': 1, 'reqd': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField diff --git a/selling/doctype/enquiry_detail/enquiry_detail.txt b/selling/doctype/enquiry_detail/enquiry_detail.txt index bd9275b93ba..284b43642c9 100644 --- a/selling/doctype/enquiry_detail/enquiry_detail.txt +++ b/selling/doctype/enquiry_detail/enquiry_detail.txt @@ -90,7 +90,8 @@ 'oldfieldname': 'item_group', 'oldfieldtype': 'Link', 'options': 'Item Group', - 'print_hide': 1 + 'print_hide': 1, + 'search_index': 0 }, # DocField @@ -104,7 +105,8 @@ 'oldfieldname': 'brand', 'oldfieldtype': 'Link', 'options': 'Brand', - 'print_hide': 1 + 'print_hide': 1, + 'search_index': 0 }, # DocField @@ -140,6 +142,7 @@ 'label': 'UOM', 'oldfieldname': 'uom', 'oldfieldtype': 'Link', - 'options': 'UOM' + 'options': 'UOM', + 'search_index': 0 } ] \ No newline at end of file diff --git a/selling/doctype/installation_note/installation_note.txt b/selling/doctype/installation_note/installation_note.txt index adfce208b1c..8feb2f59913 100644 --- a/selling/doctype/installation_note/installation_note.txt +++ b/selling/doctype/installation_note/installation_note.txt @@ -201,7 +201,7 @@ 'oldfieldtype': 'Data', 'permlevel': 1, 'reqd': 0, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -257,7 +257,7 @@ 'permlevel': 0, 'print_hide': 1, 'reqd': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -292,7 +292,8 @@ 'oldfieldname': 'inst_date', 'oldfieldtype': 'Date', 'permlevel': 0, - 'reqd': 1 + 'reqd': 1, + 'search_index': 1 }, # DocField @@ -340,7 +341,7 @@ 'permlevel': 0, 'print_hide': 1, 'reqd': 1, - 'search_index': 1, + 'search_index': 0, 'trigger': 'Client' }, diff --git a/selling/doctype/installed_item_details/installed_item_details.txt b/selling/doctype/installed_item_details/installed_item_details.txt index 7971cb52d2e..3b4632c56fe 100644 --- a/selling/doctype/installed_item_details/installed_item_details.txt +++ b/selling/doctype/installed_item_details/installed_item_details.txt @@ -140,7 +140,7 @@ 'oldfieldtype': 'Data', 'permlevel': 1, 'print_hide': 1, - 'search_index': 1, + 'search_index': 0, 'width': '150px' }, diff --git a/selling/doctype/lead/lead.txt b/selling/doctype/lead/lead.txt index a476c66577b..23873236a59 100644 --- a/selling/doctype/lead/lead.txt +++ b/selling/doctype/lead/lead.txt @@ -188,7 +188,7 @@ 'options': "\nExisting Customer\nReference\nAdvertisement\nCold Calling\nExhibition\nSupplier Reference\nMass Mailing\nCustomer's Vendor\nCampaign\nWebsite", 'permlevel': 0, 'reqd': 1, - 'search_index': 1, + 'search_index': 0, 'trigger': 'Client' }, @@ -239,7 +239,7 @@ 'oldfieldtype': 'Data', 'permlevel': 0, 'reqd': 0, - 'search_index': 1, + 'search_index': 0, 'trigger': 'Client' }, @@ -350,7 +350,7 @@ 'options': '\nHot\nWarm\nCold', 'permlevel': 0, 'reqd': 0, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -616,7 +616,7 @@ 'oldfieldtype': 'Link', 'options': 'Profile', 'permlevel': 0, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -633,7 +633,7 @@ 'options': '\nLower Income\nMiddle Income\nUpper Income', 'permlevel': 0, 'reqd': 0, - 'search_index': 1 + 'search_index': 0 }, # DocField diff --git a/selling/doctype/quotation/quotation.txt b/selling/doctype/quotation/quotation.txt index e198b86086f..6763c2df254 100644 --- a/selling/doctype/quotation/quotation.txt +++ b/selling/doctype/quotation/quotation.txt @@ -414,7 +414,7 @@ 'permlevel': 0, 'print_hide': 0, 'reqd': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -435,7 +435,7 @@ 'permlevel': 1, 'print_hide': 1, 'reqd': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -520,7 +520,7 @@ 'permlevel': 0, 'print_hide': 1, 'reqd': 1, - 'search_index': 1, + 'search_index': 0, 'trigger': 'Client' }, @@ -539,7 +539,7 @@ 'permlevel': 0, 'print_hide': 1, 'reqd': 0, - 'search_index': 1, + 'search_index': 0, 'trigger': 'Client' }, @@ -584,7 +584,7 @@ 'permlevel': 0, 'print_hide': 1, 'reqd': 1, - 'search_index': 1, + 'search_index': 0, 'trigger': 'Client', 'width': '100px' }, @@ -1035,7 +1035,7 @@ 'permlevel': 0, 'print_hide': 1, 'reqd': 1, - 'search_index': 1, + 'search_index': 0, 'trigger': 'Client', 'width': '150px' }, @@ -1055,7 +1055,7 @@ 'permlevel': 0, 'print_hide': 1, 'reqd': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField diff --git a/selling/doctype/quotation_detail/quotation_detail.txt b/selling/doctype/quotation_detail/quotation_detail.txt index 074443bd267..23c86fab4f6 100644 --- a/selling/doctype/quotation_detail/quotation_detail.txt +++ b/selling/doctype/quotation_detail/quotation_detail.txt @@ -73,7 +73,7 @@ 'permlevel': 0, 'print_hide': 1, 'reqd': 1, - 'search_index': 1, + 'search_index': 0, 'width': '150px' }, @@ -260,7 +260,7 @@ 'options': 'Item Group', 'permlevel': 1, 'print_hide': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -276,7 +276,7 @@ 'options': 'Brand', 'permlevel': 1, 'print_hide': 1, - 'search_index': 1, + 'search_index': 0, 'width': '150px' }, diff --git a/selling/doctype/return_detail/return_detail.txt b/selling/doctype/return_detail/return_detail.txt index 7091b3f3821..4c1e2f721c7 100644 --- a/selling/doctype/return_detail/return_detail.txt +++ b/selling/doctype/return_detail/return_detail.txt @@ -75,7 +75,8 @@ 'oldfieldname': 'uom', 'oldfieldtype': 'Link', 'options': 'UOM', - 'permlevel': 1 + 'permlevel': 1, + 'search_index': 0 }, # DocField diff --git a/selling/doctype/sales_order_detail/sales_order_detail.txt b/selling/doctype/sales_order_detail/sales_order_detail.txt index e89768c6ecf..7e46d74af15 100644 --- a/selling/doctype/sales_order_detail/sales_order_detail.txt +++ b/selling/doctype/sales_order_detail/sales_order_detail.txt @@ -394,7 +394,7 @@ 'options': 'Brand', 'permlevel': 1, 'print_hide': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField @@ -410,7 +410,7 @@ 'options': 'Item Group', 'permlevel': 1, 'print_hide': 1, - 'search_index': 1 + 'search_index': 0 }, # DocField diff --git a/setup/doctype/authorization_rule/authorization_rule.txt b/setup/doctype/authorization_rule/authorization_rule.txt index ef20f3621a3..a4364956ae5 100644 --- a/setup/doctype/authorization_rule/authorization_rule.txt +++ b/setup/doctype/authorization_rule/authorization_rule.txt @@ -79,7 +79,8 @@ 'oldfieldname': 'company', 'oldfieldtype': 'Link', 'options': 'Company', - 'reqd': 0 + 'reqd': 0, + 'search_index': 0 }, # DocField @@ -157,7 +158,8 @@ 'label': 'Applicable To (Employee)', 'oldfieldname': 'to_emp', 'oldfieldtype': 'Link', - 'options': 'Employee' + 'options': 'Employee', + 'search_index': 0 }, # DocField @@ -171,7 +173,8 @@ 'label': 'Applicable To (Designation)', 'oldfieldname': 'to_designation', 'oldfieldtype': 'Link', - 'options': 'Designation' + 'options': 'Designation', + 'search_index': 0 }, # DocField diff --git a/setup/doctype/company/company.txt b/setup/doctype/company/company.txt index a7498d6e057..15ba781a67e 100644 --- a/setup/doctype/company/company.txt +++ b/setup/doctype/company/company.txt @@ -5,7 +5,7 @@ { 'creation': '2010-08-08 17:08:55', 'docstatus': 0, - 'modified': '2011-07-06 11:42:34', + 'modified': '2011-07-01 17:43:29', 'modified_by': 'Administrator', 'owner': 'Administrator' }, diff --git a/setup/doctype/email_settings/email_settings.py b/setup/doctype/email_settings/email_settings.py index 12c24646e1a..37de7bcb18d 100644 --- a/setup/doctype/email_settings/email_settings.py +++ b/setup/doctype/email_settings/email_settings.py @@ -1,44 +1,42 @@ -# Please edit this list and import only required elements import webnotes - -from webnotes.utils import add_days, add_months, add_years, cint, cstr, date_diff, default_fields, flt, fmt_money, formatdate, generate_hash, getTraceback, get_defaults, get_first_day, get_last_day, getdate, has_common, month_name, now, nowdate, replace_newlines, sendmail, set_default, str_esc_quote, user_format, validate_email_add -from webnotes.model import db_exists -from webnotes.model.doc import Document, addchild, removechild, getchildren, make_autoname, SuperDocType -from webnotes.model.doclist import getlist, copy_doclist -from webnotes.model.code import get_obj, get_server_obj, run_server_obj, updatedb, check_syntax -from webnotes import session, form, is_testing, msgprint, errprint - -set = webnotes.conn.set sql = webnotes.conn.sql -get_value = webnotes.conn.get_value -in_transaction = webnotes.conn.in_transaction -convert_to_lists = webnotes.conn.convert_to_lists -# ----------------------------------------------------------------------------------------- - +from webnotes.utils import cint, cstr class DocType: - def __init__(self,doc,doclist): - self.doc,self.doclist = doc,doclist + def __init__(self,doc,doclist): + self.doc,self.doclist = doc,doclist - def set_vals(self): - res = sql("select field, value from `tabSingles` where doctype = 'Control Panel' and field IN ('outgoing_mail_server','mail_login','mail_password','auto_email_id','mail_port','use_ssl')") - ret = {} - for r in res: - ret[cstr(r[0])]=r[1] and cstr(r[1]) or '' - - return str(ret) + def set_vals(self): + res = sql("select field, value from `tabSingles` where doctype = 'Control Panel' and field IN ('outgoing_mail_server','mail_login','mail_password','auto_email_id','mail_port','use_ssl')") + ret = {} + for r in res: + ret[cstr(r[0])]=r[1] and cstr(r[1]) or '' + + return str(ret) - def on_update(self): - if self.doc.outgoing_mail_server: - sql("update `tabSingles` set value ='%s' where doctype = 'Control Panel' and field = 'outgoing_mail_server'"%self.doc.outgoing_mail_server) - if self.doc.mail_login: - sql("update `tabSingles` set value ='%s' where doctype = 'Control Panel' and field = 'mail_login'"%self.doc.mail_login) - if self.doc.mail_password: - sql("update `tabSingles` set value ='%s' where doctype = 'Control Panel' and field = 'mail_password'"%self.doc.mail_password) - if self.doc.auto_email_id: - sql("update `tabSingles` set value ='%s' where doctype = 'Control Panel' and field = 'auto_email_id'"%self.doc.auto_email_id) - if self.doc.mail_port: - sql("update `tabSingles` set value ='%s' where doctype = 'Control Panel' and field = 'mail_port'"%self.doc.mail_port) - if self.doc.use_ssl: - sql("update `tabSingles` set value ='%s' where doctype = 'Control Panel' and field = 'use_ssl'"%self.doc.use_ssl) \ No newline at end of file + def set_cp_value(self, key): + """ + Update value in control panel + """ + if self.doc.fields.get(key): + webnotes.conn.set_value('Control Panel', None, key, self.doc.fields[key]) + + def on_update(self): + """ + Sets or cancels the event in the scheduler + """ + # update control panel + for f in ('outgoing_mail_server', 'mail_login', 'mail_password', 'auto_email_id', 'mail_port', 'use_ssl'): + self.set_cp_value(f) + + # setup scheduler for support emails + if cint(self.doc.sync_support_mails): + if not (self.doc.support_host and self.doc.support_username and self.doc.support_password): + webnotes.msgprint("You must give the incoming POP3 settings for support emails to activiate mailbox integration", raise_exception=1) + + from webnotes.utils.scheduler import set_event + set_event('support.doctype.support_ticket.get_support_mails', 60*5, 1) + else: + from webnotes.utils.scheduler import cancel_event + cancel_event('support.doctype.support_ticket.get_support_mails') \ No newline at end of file diff --git a/setup/doctype/email_settings/email_settings.txt b/setup/doctype/email_settings/email_settings.txt index 31bc93285f1..ef6efe609f7 100644 --- a/setup/doctype/email_settings/email_settings.txt +++ b/setup/doctype/email_settings/email_settings.txt @@ -5,14 +5,14 @@ { 'creation': '2010-08-08 17:08:59', 'docstatus': 0, - 'modified': '2011-01-04 11:21:25', - 'modified_by': 'umair@iwebnotes.com', + 'modified': '2011-07-25 15:03:51', + 'modified_by': 'Administrator', 'owner': 'harshada@webnotestech.com' }, # These values are common for all DocType { - '_last_update': '1307707462', + '_last_update': '1311586371', 'allow_copy': 1, 'allow_email': 1, 'allow_print': 1, @@ -24,7 +24,7 @@ 'name': '__common__', 'section_style': 'Simple', 'server_code_error': ' ', - 'version': 27 + 'version': 34 }, # These values are common for all DocField @@ -69,12 +69,29 @@ 'idx': 2 }, + # DocField + { + 'doctype': 'DocField', + 'fieldtype': 'Section Break', + 'idx': 1, + 'label': 'Outgoing Mails' + }, + + # DocField + { + 'doctype': 'DocField', + 'fieldtype': 'HTML', + 'idx': 2, + 'label': '1', + 'options': '