fix: add a more descriptive message when no records are found (#18082)

* fix: add a more descriptive message when no records are found

* fix: translation by passing string to translation function
This commit is contained in:
Mangesh-Khairnar 2019-06-28 12:38:40 +05:30 committed by Nabin Hait
parent 130dcffcc8
commit 4000fb5bb8
3 changed files with 460 additions and 436 deletions

View File

@ -39,8 +39,6 @@ frappe.ui.form.on('Exchange Rate Revaluation', {
}); });
frm.events.get_total_gain_loss(frm); frm.events.get_total_gain_loss(frm);
refresh_field("accounts"); refresh_field("accounts");
} else {
frappe.msgprint(__("No records found"));
} }
} }
}); });

View File

@ -22,7 +22,7 @@ class ExchangeRateRevaluation(Document):
- flt(d.balance_in_base_currency, d.precision("balance_in_base_currency")) - flt(d.balance_in_base_currency, d.precision("balance_in_base_currency"))
total_gain_loss += flt(d.gain_loss, d.precision("gain_loss")) total_gain_loss += flt(d.gain_loss, d.precision("gain_loss"))
self.total_gain_loss = flt(total_gain_loss, self.precision("total_gain_loss")) self.total_gain_loss = flt(total_gain_loss, self.precision("total_gain_loss"))
def validate_mandatory(self): def validate_mandatory(self):
if not (self.company and self.posting_date): if not (self.company and self.posting_date):
frappe.throw(_("Please select Company and Posting Date to getting entries")) frappe.throw(_("Please select Company and Posting Date to getting entries"))
@ -33,8 +33,9 @@ class ExchangeRateRevaluation(Document):
company_currency = erpnext.get_company_currency(self.company) company_currency = erpnext.get_company_currency(self.company)
precision = get_field_precision(frappe.get_meta("Exchange Rate Revaluation Account") precision = get_field_precision(frappe.get_meta("Exchange Rate Revaluation Account")
.get_field("new_balance_in_base_currency"), company_currency) .get_field("new_balance_in_base_currency"), company_currency)
for d in self.get_accounts_from_gle():
account_details = self.get_accounts_from_gle()
for d in account_details:
current_exchange_rate = d.balance / d.balance_in_account_currency \ current_exchange_rate = d.balance / d.balance_in_account_currency \
if d.balance_in_account_currency else 0 if d.balance_in_account_currency else 0
new_exchange_rate = get_exchange_rate(d.account_currency, company_currency, self.posting_date) new_exchange_rate = get_exchange_rate(d.account_currency, company_currency, self.posting_date)
@ -52,6 +53,10 @@ class ExchangeRateRevaluation(Document):
"new_exchange_rate": new_exchange_rate, "new_exchange_rate": new_exchange_rate,
"new_balance_in_base_currency": new_balance_in_base_currency "new_balance_in_base_currency": new_balance_in_base_currency
}) })
if not accounts:
self.throw_invalid_response_message(account_details)
return accounts return accounts
def get_accounts_from_gle(self): def get_accounts_from_gle(self):
@ -83,11 +88,18 @@ class ExchangeRateRevaluation(Document):
return account_details return account_details
def throw_invalid_response_message(self, account_details):
if account_details:
message = _("No outstanding invoices require exchange rate revaluation")
else:
message = _("No outstanding invoices found")
frappe.msgprint(message)
def make_jv_entry(self): def make_jv_entry(self):
if self.total_gain_loss == 0: if self.total_gain_loss == 0:
return return
unrealized_exchange_gain_loss_account = frappe.get_cached_value('Company', self.company, unrealized_exchange_gain_loss_account = frappe.get_cached_value('Company', self.company,
"unrealized_exchange_gain_loss_account") "unrealized_exchange_gain_loss_account")
if not unrealized_exchange_gain_loss_account: if not unrealized_exchange_gain_loss_account:
frappe.throw(_("Please set Unrealized Exchange Gain/Loss Account in Company {0}") frappe.throw(_("Please set Unrealized Exchange Gain/Loss Account in Company {0}")

View File

@ -1,461 +1,475 @@
{ {
"allow_copy": 0, "allow_copy": 0,
"allow_events_in_timeline": 0, "allow_events_in_timeline": 0,
"allow_guest_to_view": 0, "allow_guest_to_view": 0,
"allow_import": 0, "allow_import": 0,
"allow_rename": 0, "allow_rename": 0,
"beta": 0, "beta": 0,
"creation": "2018-04-13 18:30:06.110433", "creation": "2018-04-13 18:30:06.110433",
"custom": 0, "custom": 0,
"docstatus": 0, "docstatus": 0,
"doctype": "DocType", "doctype": "DocType",
"document_type": "", "document_type": "",
"editable_grid": 1, "editable_grid": 1,
"engine": "InnoDB", "engine": "InnoDB",
"fields": [ "fields": [
{ {
"allow_bulk_edit": 0, "allow_bulk_edit": 0,
"allow_in_quick_entry": 0, "allow_in_quick_entry": 0,
"allow_on_submit": 0, "allow_on_submit": 0,
"bold": 0, "bold": 0,
"collapsible": 0, "collapsible": 0,
"columns": 0, "columns": 0,
"fieldname": "account", "fetch_if_empty": 0,
"fieldtype": "Link", "fieldname": "account",
"hidden": 0, "fieldtype": "Link",
"ignore_user_permissions": 0, "hidden": 0,
"ignore_xss_filter": 0, "ignore_user_permissions": 0,
"in_filter": 0, "ignore_xss_filter": 0,
"in_global_search": 0, "in_filter": 0,
"in_list_view": 1, "in_global_search": 0,
"in_standard_filter": 0, "in_list_view": 1,
"label": "Account", "in_standard_filter": 0,
"length": 0, "label": "Account",
"no_copy": 0, "length": 0,
"options": "Account", "no_copy": 0,
"permlevel": 0, "options": "Account",
"precision": "", "permlevel": 0,
"print_hide": 0, "precision": "",
"print_hide_if_no_value": 0, "print_hide": 0,
"read_only": 0, "print_hide_if_no_value": 0,
"remember_last_selected_value": 0, "read_only": 0,
"report_hide": 0, "remember_last_selected_value": 0,
"reqd": 1, "report_hide": 0,
"search_index": 0, "reqd": 1,
"set_only_once": 0, "search_index": 0,
"translatable": 0, "set_only_once": 0,
"translatable": 0,
"unique": 0 "unique": 0
}, },
{ {
"allow_bulk_edit": 0, "allow_bulk_edit": 0,
"allow_in_quick_entry": 0, "allow_in_quick_entry": 0,
"allow_on_submit": 0, "allow_on_submit": 0,
"bold": 0, "bold": 0,
"collapsible": 0, "collapsible": 0,
"columns": 0, "columns": 0,
"fieldname": "party_type", "fetch_if_empty": 0,
"fieldtype": "Link", "fieldname": "party_type",
"hidden": 0, "fieldtype": "Link",
"ignore_user_permissions": 0, "hidden": 0,
"ignore_xss_filter": 0, "ignore_user_permissions": 0,
"in_filter": 0, "ignore_xss_filter": 0,
"in_global_search": 0, "in_filter": 0,
"in_list_view": 0, "in_global_search": 0,
"in_standard_filter": 0, "in_list_view": 0,
"label": "Party Type", "in_standard_filter": 0,
"length": 0, "label": "Party Type",
"no_copy": 0, "length": 0,
"options": "DocType", "no_copy": 0,
"permlevel": 0, "options": "DocType",
"precision": "", "permlevel": 0,
"print_hide": 0, "precision": "",
"print_hide_if_no_value": 0, "print_hide": 0,
"read_only": 0, "print_hide_if_no_value": 0,
"remember_last_selected_value": 0, "read_only": 0,
"report_hide": 0, "remember_last_selected_value": 0,
"reqd": 0, "report_hide": 0,
"search_index": 0, "reqd": 0,
"set_only_once": 0, "search_index": 0,
"translatable": 0, "set_only_once": 0,
"translatable": 0,
"unique": 0 "unique": 0
}, },
{ {
"allow_bulk_edit": 0, "allow_bulk_edit": 0,
"allow_in_quick_entry": 0, "allow_in_quick_entry": 0,
"allow_on_submit": 0, "allow_on_submit": 0,
"bold": 0, "bold": 0,
"collapsible": 0, "collapsible": 0,
"columns": 0, "columns": 0,
"fieldname": "party", "fetch_if_empty": 0,
"fieldtype": "Dynamic Link", "fieldname": "party",
"hidden": 0, "fieldtype": "Dynamic Link",
"ignore_user_permissions": 0, "hidden": 0,
"ignore_xss_filter": 0, "ignore_user_permissions": 0,
"in_filter": 0, "ignore_xss_filter": 0,
"in_global_search": 0, "in_filter": 0,
"in_list_view": 0, "in_global_search": 0,
"in_standard_filter": 0, "in_list_view": 0,
"label": "Party", "in_standard_filter": 0,
"length": 0, "label": "Party",
"no_copy": 0, "length": 0,
"options": "party_type", "no_copy": 0,
"permlevel": 0, "options": "party_type",
"precision": "", "permlevel": 0,
"print_hide": 0, "precision": "",
"print_hide_if_no_value": 0, "print_hide": 0,
"read_only": 0, "print_hide_if_no_value": 0,
"remember_last_selected_value": 0, "read_only": 0,
"report_hide": 0, "remember_last_selected_value": 0,
"reqd": 0, "report_hide": 0,
"search_index": 0, "reqd": 0,
"set_only_once": 0, "search_index": 0,
"translatable": 0, "set_only_once": 0,
"translatable": 0,
"unique": 0 "unique": 0
}, },
{ {
"allow_bulk_edit": 0, "allow_bulk_edit": 0,
"allow_in_quick_entry": 0, "allow_in_quick_entry": 0,
"allow_on_submit": 0, "allow_on_submit": 0,
"bold": 0, "bold": 0,
"collapsible": 0, "collapsible": 0,
"columns": 0, "columns": 0,
"fieldname": "column_break_2", "fetch_if_empty": 0,
"fieldtype": "Column Break", "fieldname": "column_break_2",
"hidden": 0, "fieldtype": "Column Break",
"ignore_user_permissions": 0, "hidden": 0,
"ignore_xss_filter": 0, "ignore_user_permissions": 0,
"in_filter": 0, "ignore_xss_filter": 0,
"in_global_search": 0, "in_filter": 0,
"in_list_view": 0, "in_global_search": 0,
"in_standard_filter": 0, "in_list_view": 0,
"length": 0, "in_standard_filter": 0,
"no_copy": 0, "length": 0,
"permlevel": 0, "no_copy": 0,
"precision": "", "permlevel": 0,
"print_hide": 0, "precision": "",
"print_hide_if_no_value": 0, "print_hide": 0,
"read_only": 0, "print_hide_if_no_value": 0,
"remember_last_selected_value": 0, "read_only": 0,
"report_hide": 0, "remember_last_selected_value": 0,
"reqd": 0, "report_hide": 0,
"search_index": 0, "reqd": 0,
"set_only_once": 0, "search_index": 0,
"translatable": 0, "set_only_once": 0,
"translatable": 0,
"unique": 0 "unique": 0
}, },
{ {
"allow_bulk_edit": 0, "allow_bulk_edit": 0,
"allow_in_quick_entry": 0, "allow_in_quick_entry": 0,
"allow_on_submit": 0, "allow_on_submit": 0,
"bold": 0, "bold": 0,
"collapsible": 0, "collapsible": 0,
"columns": 0, "columns": 0,
"fieldname": "account_currency", "fetch_if_empty": 0,
"fieldtype": "Link", "fieldname": "account_currency",
"hidden": 0, "fieldtype": "Link",
"ignore_user_permissions": 0, "hidden": 0,
"ignore_xss_filter": 0, "ignore_user_permissions": 0,
"in_filter": 0, "ignore_xss_filter": 0,
"in_global_search": 0, "in_filter": 0,
"in_list_view": 0, "in_global_search": 0,
"in_standard_filter": 0, "in_list_view": 0,
"label": "Account Currency", "in_standard_filter": 0,
"length": 0, "label": "Account Currency",
"no_copy": 0, "length": 0,
"options": "Currency", "no_copy": 0,
"permlevel": 0, "options": "Currency",
"precision": "", "permlevel": 0,
"print_hide": 0, "precision": "",
"print_hide_if_no_value": 0, "print_hide": 0,
"read_only": 1, "print_hide_if_no_value": 0,
"remember_last_selected_value": 0, "read_only": 1,
"report_hide": 0, "remember_last_selected_value": 0,
"reqd": 0, "report_hide": 0,
"search_index": 0, "reqd": 0,
"set_only_once": 0, "search_index": 0,
"translatable": 0, "set_only_once": 0,
"translatable": 0,
"unique": 0 "unique": 0
}, },
{ {
"allow_bulk_edit": 0, "allow_bulk_edit": 0,
"allow_in_quick_entry": 0, "allow_in_quick_entry": 0,
"allow_on_submit": 0, "allow_on_submit": 0,
"bold": 0, "bold": 0,
"collapsible": 0, "collapsible": 0,
"columns": 0, "columns": 0,
"fieldname": "balance_in_account_currency", "fetch_if_empty": 0,
"fieldtype": "Currency", "fieldname": "balance_in_account_currency",
"hidden": 0, "fieldtype": "Currency",
"ignore_user_permissions": 0, "hidden": 0,
"ignore_xss_filter": 0, "ignore_user_permissions": 0,
"in_filter": 0, "ignore_xss_filter": 0,
"in_global_search": 0, "in_filter": 0,
"in_list_view": 0, "in_global_search": 0,
"in_standard_filter": 0, "in_list_view": 0,
"label": "Balance In Account Currency", "in_standard_filter": 0,
"length": 0, "label": "Balance In Account Currency",
"no_copy": 0, "length": 0,
"permlevel": 0, "no_copy": 0,
"precision": "", "options": "account_currency",
"print_hide": 0, "permlevel": 0,
"print_hide_if_no_value": 0, "precision": "",
"read_only": 1, "print_hide": 0,
"remember_last_selected_value": 0, "print_hide_if_no_value": 0,
"report_hide": 0, "read_only": 1,
"reqd": 0, "remember_last_selected_value": 0,
"search_index": 0, "report_hide": 0,
"set_only_once": 0, "reqd": 0,
"translatable": 0, "search_index": 0,
"set_only_once": 0,
"translatable": 0,
"unique": 0 "unique": 0
}, },
{ {
"allow_bulk_edit": 0, "allow_bulk_edit": 0,
"allow_in_quick_entry": 0, "allow_in_quick_entry": 0,
"allow_on_submit": 0, "allow_on_submit": 0,
"bold": 0, "bold": 0,
"collapsible": 0, "collapsible": 0,
"columns": 0, "columns": 0,
"fieldname": "balances", "fetch_if_empty": 0,
"fieldtype": "Section Break", "fieldname": "balances",
"hidden": 0, "fieldtype": "Section Break",
"ignore_user_permissions": 0, "hidden": 0,
"ignore_xss_filter": 0, "ignore_user_permissions": 0,
"in_filter": 0, "ignore_xss_filter": 0,
"in_global_search": 0, "in_filter": 0,
"in_list_view": 0, "in_global_search": 0,
"in_standard_filter": 0, "in_list_view": 0,
"label": "", "in_standard_filter": 0,
"length": 0, "label": "",
"no_copy": 0, "length": 0,
"permlevel": 0, "no_copy": 0,
"precision": "", "permlevel": 0,
"print_hide": 0, "precision": "",
"print_hide_if_no_value": 0, "print_hide": 0,
"read_only": 0, "print_hide_if_no_value": 0,
"remember_last_selected_value": 0, "read_only": 0,
"report_hide": 0, "remember_last_selected_value": 0,
"reqd": 0, "report_hide": 0,
"search_index": 0, "reqd": 0,
"set_only_once": 0, "search_index": 0,
"translatable": 0, "set_only_once": 0,
"translatable": 0,
"unique": 0 "unique": 0
}, },
{ {
"allow_bulk_edit": 0, "allow_bulk_edit": 0,
"allow_in_quick_entry": 0, "allow_in_quick_entry": 0,
"allow_on_submit": 0, "allow_on_submit": 0,
"bold": 0, "bold": 0,
"collapsible": 0, "collapsible": 0,
"columns": 0, "columns": 0,
"fieldname": "current_exchange_rate", "fetch_if_empty": 0,
"fieldtype": "Float", "fieldname": "current_exchange_rate",
"hidden": 0, "fieldtype": "Float",
"ignore_user_permissions": 0, "hidden": 0,
"ignore_xss_filter": 0, "ignore_user_permissions": 0,
"in_filter": 0, "ignore_xss_filter": 0,
"in_global_search": 0, "in_filter": 0,
"in_list_view": 0, "in_global_search": 0,
"in_standard_filter": 0, "in_list_view": 0,
"label": "Current Exchange Rate", "in_standard_filter": 0,
"length": 0, "label": "Current Exchange Rate",
"no_copy": 0, "length": 0,
"permlevel": 0, "no_copy": 0,
"precision": "", "permlevel": 0,
"print_hide": 0, "precision": "",
"print_hide_if_no_value": 0, "print_hide": 0,
"read_only": 1, "print_hide_if_no_value": 0,
"remember_last_selected_value": 0, "read_only": 1,
"report_hide": 0, "remember_last_selected_value": 0,
"reqd": 0, "report_hide": 0,
"search_index": 0, "reqd": 0,
"set_only_once": 0, "search_index": 0,
"translatable": 0, "set_only_once": 0,
"translatable": 0,
"unique": 0 "unique": 0
}, },
{ {
"allow_bulk_edit": 0, "allow_bulk_edit": 0,
"allow_in_quick_entry": 0, "allow_in_quick_entry": 0,
"allow_on_submit": 0, "allow_on_submit": 0,
"bold": 0, "bold": 0,
"collapsible": 0, "collapsible": 0,
"columns": 0, "columns": 0,
"fieldname": "balance_in_base_currency", "fetch_if_empty": 0,
"fieldtype": "Currency", "fieldname": "balance_in_base_currency",
"hidden": 0, "fieldtype": "Currency",
"ignore_user_permissions": 0, "hidden": 0,
"ignore_xss_filter": 0, "ignore_user_permissions": 0,
"in_filter": 0, "ignore_xss_filter": 0,
"in_global_search": 0, "in_filter": 0,
"in_list_view": 1, "in_global_search": 0,
"in_standard_filter": 0, "in_list_view": 1,
"label": "Balance In Base Currency", "in_standard_filter": 0,
"length": 0, "label": "Balance In Base Currency",
"no_copy": 0, "length": 0,
"permlevel": 0, "no_copy": 0,
"precision": "", "permlevel": 0,
"print_hide": 0, "precision": "",
"print_hide_if_no_value": 0, "print_hide": 0,
"read_only": 1, "print_hide_if_no_value": 0,
"remember_last_selected_value": 0, "read_only": 1,
"report_hide": 0, "remember_last_selected_value": 0,
"reqd": 0, "report_hide": 0,
"search_index": 0, "reqd": 0,
"set_only_once": 0, "search_index": 0,
"translatable": 0, "set_only_once": 0,
"translatable": 0,
"unique": 0 "unique": 0
}, },
{ {
"allow_bulk_edit": 0, "allow_bulk_edit": 0,
"allow_in_quick_entry": 0, "allow_in_quick_entry": 0,
"allow_on_submit": 0, "allow_on_submit": 0,
"bold": 0, "bold": 0,
"collapsible": 0, "collapsible": 0,
"columns": 0, "columns": 0,
"fieldname": "column_break_9", "fetch_if_empty": 0,
"fieldtype": "Column Break", "fieldname": "column_break_9",
"hidden": 0, "fieldtype": "Column Break",
"ignore_user_permissions": 0, "hidden": 0,
"ignore_xss_filter": 0, "ignore_user_permissions": 0,
"in_filter": 0, "ignore_xss_filter": 0,
"in_global_search": 0, "in_filter": 0,
"in_list_view": 0, "in_global_search": 0,
"in_standard_filter": 0, "in_list_view": 0,
"length": 0, "in_standard_filter": 0,
"no_copy": 0, "length": 0,
"permlevel": 0, "no_copy": 0,
"precision": "", "permlevel": 0,
"print_hide": 0, "precision": "",
"print_hide_if_no_value": 0, "print_hide": 0,
"read_only": 0, "print_hide_if_no_value": 0,
"remember_last_selected_value": 0, "read_only": 0,
"report_hide": 0, "remember_last_selected_value": 0,
"reqd": 0, "report_hide": 0,
"search_index": 0, "reqd": 0,
"set_only_once": 0, "search_index": 0,
"translatable": 0, "set_only_once": 0,
"translatable": 0,
"unique": 0 "unique": 0
}, },
{ {
"allow_bulk_edit": 0, "allow_bulk_edit": 0,
"allow_in_quick_entry": 0, "allow_in_quick_entry": 0,
"allow_on_submit": 0, "allow_on_submit": 0,
"bold": 0, "bold": 0,
"collapsible": 0, "collapsible": 0,
"columns": 0, "columns": 0,
"fieldname": "new_exchange_rate", "fetch_if_empty": 0,
"fieldtype": "Float", "fieldname": "new_exchange_rate",
"hidden": 0, "fieldtype": "Float",
"ignore_user_permissions": 0, "hidden": 0,
"ignore_xss_filter": 0, "ignore_user_permissions": 0,
"in_filter": 0, "ignore_xss_filter": 0,
"in_global_search": 0, "in_filter": 0,
"in_list_view": 1, "in_global_search": 0,
"in_standard_filter": 0, "in_list_view": 1,
"label": "New Exchange Rate", "in_standard_filter": 0,
"length": 0, "label": "New Exchange Rate",
"no_copy": 0, "length": 0,
"permlevel": 0, "no_copy": 0,
"precision": "", "permlevel": 0,
"print_hide": 0, "precision": "",
"print_hide_if_no_value": 0, "print_hide": 0,
"read_only": 0, "print_hide_if_no_value": 0,
"remember_last_selected_value": 0, "read_only": 0,
"report_hide": 0, "remember_last_selected_value": 0,
"reqd": 1, "report_hide": 0,
"search_index": 0, "reqd": 1,
"set_only_once": 0, "search_index": 0,
"translatable": 0, "set_only_once": 0,
"translatable": 0,
"unique": 0 "unique": 0
}, },
{ {
"allow_bulk_edit": 0, "allow_bulk_edit": 0,
"allow_in_quick_entry": 0, "allow_in_quick_entry": 0,
"allow_on_submit": 0, "allow_on_submit": 0,
"bold": 0, "bold": 0,
"collapsible": 0, "collapsible": 0,
"columns": 0, "columns": 0,
"fieldname": "new_balance_in_base_currency", "fetch_if_empty": 0,
"fieldtype": "Currency", "fieldname": "new_balance_in_base_currency",
"hidden": 0, "fieldtype": "Currency",
"ignore_user_permissions": 0, "hidden": 0,
"ignore_xss_filter": 0, "ignore_user_permissions": 0,
"in_filter": 0, "ignore_xss_filter": 0,
"in_global_search": 0, "in_filter": 0,
"in_list_view": 1, "in_global_search": 0,
"in_standard_filter": 0, "in_list_view": 1,
"label": "New Balance In Base Currency", "in_standard_filter": 0,
"length": 0, "label": "New Balance In Base Currency",
"no_copy": 0, "length": 0,
"permlevel": 0, "no_copy": 0,
"precision": "", "permlevel": 0,
"print_hide": 0, "precision": "",
"print_hide_if_no_value": 0, "print_hide": 0,
"read_only": 1, "print_hide_if_no_value": 0,
"remember_last_selected_value": 0, "read_only": 1,
"report_hide": 0, "remember_last_selected_value": 0,
"reqd": 0, "report_hide": 0,
"search_index": 0, "reqd": 0,
"set_only_once": 0, "search_index": 0,
"translatable": 0, "set_only_once": 0,
"translatable": 0,
"unique": 0 "unique": 0
}, },
{ {
"allow_bulk_edit": 0, "allow_bulk_edit": 0,
"allow_in_quick_entry": 0, "allow_in_quick_entry": 0,
"allow_on_submit": 0, "allow_on_submit": 0,
"bold": 0, "bold": 0,
"collapsible": 0, "collapsible": 0,
"columns": 0, "columns": 0,
"fieldname": "gain_loss", "fetch_if_empty": 0,
"fieldtype": "Currency", "fieldname": "gain_loss",
"hidden": 0, "fieldtype": "Currency",
"ignore_user_permissions": 0, "hidden": 0,
"ignore_xss_filter": 0, "ignore_user_permissions": 0,
"in_filter": 0, "ignore_xss_filter": 0,
"in_global_search": 0, "in_filter": 0,
"in_list_view": 1, "in_global_search": 0,
"in_standard_filter": 0, "in_list_view": 1,
"label": "Gain/Loss", "in_standard_filter": 0,
"length": 0, "label": "Gain/Loss",
"no_copy": 0, "length": 0,
"permlevel": 0, "no_copy": 0,
"precision": "", "permlevel": 0,
"print_hide": 0, "precision": "",
"print_hide_if_no_value": 0, "print_hide": 0,
"read_only": 1, "print_hide_if_no_value": 0,
"remember_last_selected_value": 0, "read_only": 1,
"report_hide": 0, "remember_last_selected_value": 0,
"reqd": 0, "report_hide": 0,
"search_index": 0, "reqd": 0,
"set_only_once": 0, "search_index": 0,
"translatable": 0, "set_only_once": 0,
"translatable": 0,
"unique": 0 "unique": 0
} }
], ],
"has_web_view": 0, "has_web_view": 0,
"hide_heading": 0, "hide_heading": 0,
"hide_toolbar": 0, "hide_toolbar": 0,
"idx": 0, "idx": 0,
"image_view": 0, "image_view": 0,
"in_create": 0, "in_create": 0,
"is_submittable": 0, "is_submittable": 0,
"issingle": 0, "issingle": 0,
"istable": 1, "istable": 1,
"max_attachments": 0, "max_attachments": 0,
"modified": "2019-01-07 16:52:07.327930", "modified": "2019-06-26 18:57:51.762345",
"modified_by": "Administrator", "modified_by": "Administrator",
"module": "Accounts", "module": "Accounts",
"name": "Exchange Rate Revaluation Account", "name": "Exchange Rate Revaluation Account",
"name_case": "", "name_case": "",
"owner": "Administrator", "owner": "Administrator",
"permissions": [], "permissions": [],
"quick_entry": 1, "quick_entry": 1,
"read_only": 0, "read_only": 0,
"read_only_onload": 0, "read_only_onload": 0,
"show_name_in_global_search": 0, "show_name_in_global_search": 0,
"sort_field": "modified", "sort_field": "modified",
"sort_order": "DESC", "sort_order": "DESC",
"track_changes": 1, "track_changes": 1,
"track_seen": 0, "track_seen": 0,
"track_views": 0 "track_views": 0
} }