From 59fc039c77d45db18d80655ba3a9f4c2306b11eb Mon Sep 17 00:00:00 2001 From: Aditya Hase Date: Wed, 6 Feb 2019 13:08:51 +0530 Subject: [PATCH] style: Linting fixes --- .../account_balance_timeline.js | 84 +++++++++---------- .../account_balance_timeline.py | 1 - 2 files changed, 42 insertions(+), 43 deletions(-) diff --git a/erpnext/accounts/dashboard_chart_source/account_balance_timeline/account_balance_timeline.js b/erpnext/accounts/dashboard_chart_source/account_balance_timeline/account_balance_timeline.js index c9a046f557..3d0eacc06f 100644 --- a/erpnext/accounts/dashboard_chart_source/account_balance_timeline/account_balance_timeline.js +++ b/erpnext/accounts/dashboard_chart_source/account_balance_timeline/account_balance_timeline.js @@ -1,44 +1,44 @@ frappe.dashboard_chart_sources["Account Balance Timeline"] = { - method_path: "erpnext.accounts.dashboard_chart_source.account_balance_timeline.account_balance_timeline.get", - filters: [ - { - fieldname: "company", - label: __("Company"), - fieldtype: "Link", - options: "Company", - default: frappe.defaults.get_user_default("Company"), - reqd: 1 - }, - { - fieldname: "account", - label: __("Account"), - fieldtype: "Link", - options: "Account", - reqd: 1 - }, - { - fieldname: "timespan", - label: __("Period"), - fieldtype: "Select", - options: [ - {value: "Last Year", label: __("Last Year")}, - {value: "Last Quarter", label: __("Last Quarter")}, - {value: "Last Month", label: __("Last Month")}, - {value: "Last Week", label: __("Last Week")} - ], - reqd: 1 - }, - { - fieldname: "timegrain", - label: __("Periodicity"), - fieldtype: "Select", - options: [ - {value: "Quarterly", label: __("Quarterly")}, - {value: "Monthly", label: __("Monthly")}, - {value: "Weekly", label: __("Weekly")}, - {value: "Daily", label: __("Daily")} - ], - reqd: 1 - }, - ] + method_path: "erpnext.accounts.dashboard_chart_source.account_balance_timeline.account_balance_timeline.get", + filters: [ + { + fieldname: "company", + label: __("Company"), + fieldtype: "Link", + options: "Company", + default: frappe.defaults.get_user_default("Company"), + reqd: 1 + }, + { + fieldname: "account", + label: __("Account"), + fieldtype: "Link", + options: "Account", + reqd: 1 + }, + { + fieldname: "timespan", + label: __("Period"), + fieldtype: "Select", + options: [ + {value: "Last Year", label: __("Last Year")}, + {value: "Last Quarter", label: __("Last Quarter")}, + {value: "Last Month", label: __("Last Month")}, + {value: "Last Week", label: __("Last Week")} + ], + reqd: 1 + }, + { + fieldname: "timegrain", + label: __("Periodicity"), + fieldtype: "Select", + options: [ + {value: "Quarterly", label: __("Quarterly")}, + {value: "Monthly", label: __("Monthly")}, + {value: "Weekly", label: __("Weekly")}, + {value: "Daily", label: __("Daily")} + ], + reqd: 1 + }, + ] }; \ No newline at end of file diff --git a/erpnext/accounts/dashboard_chart_source/account_balance_timeline/account_balance_timeline.py b/erpnext/accounts/dashboard_chart_source/account_balance_timeline/account_balance_timeline.py index c2c2423805..f98a236388 100644 --- a/erpnext/accounts/dashboard_chart_source/account_balance_timeline/account_balance_timeline.py +++ b/erpnext/accounts/dashboard_chart_source/account_balance_timeline/account_balance_timeline.py @@ -4,7 +4,6 @@ from __future__ import unicode_literals from itertools import groupby from operator import itemgetter -import json import frappe from frappe.core.page.dashboard.dashboard import cache_source from frappe.utils import add_to_date, date_diff, getdate, nowdate