chore: mass trailing whitespace and EOF fixes

This commit is contained in:
Ankush Menat
2021-08-19 13:41:10 +05:30
parent 869e36c33a
commit 4551d7d602
1190 changed files with 1352 additions and 1604 deletions

View File

@@ -55,4 +55,3 @@ def get_default_energy_point_rules():
'points': rule.get('points'),
'user_field': rule.get('user_field') or 'owner'
} for doctype, rule in doctype_rule_map.items()]

View File

@@ -24,4 +24,3 @@ def get_default_success_action():
'first_success_message': get_first_success_message(doctype),
'next_actions': 'new\nprint\nemail'
} for doctype in doctype_list]

View File

@@ -1,13 +1,13 @@
// Copyright (c) 2015, Frappe Technologies Pvt. Ltd. and Contributors
// License: GNU General Public License v3. See license.txt
//--------- ONLOAD -------------
cur_frm.cscript.onload = function(doc, cdt, cdn) {
}
cur_frm.cscript.refresh = function(doc, cdt, cdn) {
}
}

View File

@@ -21,4 +21,4 @@ def get_brand_defaults(item, company):
row.pop("name")
return row
return frappe._dict()
return frappe._dict()

View File

@@ -4,4 +4,4 @@ from __future__ import unicode_literals
import frappe
test_records = frappe.get_test_records('Brand')
test_records = frappe.get_test_records('Brand')

View File

@@ -313,4 +313,3 @@ var disbale_coa_fields = function(frm, bool=true) {
frm.set_df_property("chart_of_accounts", "read_only", bool);
frm.set_df_property("existing_company", "read_only", bool);
}

View File

@@ -108,7 +108,7 @@ class Company(NestedSet):
frappe.flags.country_change = True
self.create_default_accounts()
self.create_default_warehouses()
if not frappe.db.get_value("Cost Center", {"is_group": 0, "company": self.name}):
self.create_default_cost_center()

View File

@@ -37,4 +37,4 @@ def get_data():
'items': ['Project']
}
]
}
}

View File

@@ -30,4 +30,4 @@ frappe.treeview_settings["Company"] = {
onload: function(treeview) {
treeview.make_tree();
}
};
};

View File

@@ -130,4 +130,3 @@ def create_test_lead_in_company(company):
lead.company = company
lead.save()
return lead.name

View File

@@ -22,4 +22,4 @@ QUnit.test("Test: Company [SetUp]", function (assert) {
'chart of cost centers created'),
() => done()
]);
});
});

View File

@@ -16,4 +16,4 @@ QUnit.test("Test: Company", function (assert) {
() => done()
]);
});
});

View File

@@ -30,4 +30,4 @@ def get_parent_customer_groups(customer_group):
order by lft asc""", (lft, rgt), as_dict=True)
def on_doctype_update():
frappe.db.add_index("Customer Group", ["lft", "rgt"])
frappe.db.add_index("Customer Group", ["lft", "rgt"])

View File

@@ -1,3 +1,3 @@
frappe.treeview_settings["Customer Group"] = {
ignore_fields:["parent_customer_group"]
}
}

View File

@@ -7,4 +7,4 @@ test_ignore = ["Price List"]
import frappe
test_records = frappe.get_test_records('Customer Group')
test_records = frappe.get_test_records('Customer Group')

View File

@@ -28,4 +28,4 @@ frappe.ui.form.on("Email Digest", {
});
}
}
});
});

View File

@@ -32,4 +32,3 @@ def get_random_quote():
]
return random.choice(quotes)

View File

@@ -180,8 +180,8 @@
<br>
</div>
{% endif %}
<!-- Purchase Order Items Overdue -->
<!-- Purchase Order Items Overdue -->
{% if purchase_orders_items_overdue_list %}
<h4 style="{{ section_head }}" class="text-center">{{ _("Purchase Order Items not received on time") }}</h4>
<div>
@@ -254,6 +254,6 @@
<div class="text-center">
<br><br><span class="text-danger">Please take necessary action</span>
</div>
{% endif %}
{% endif %}
</div>

View File

@@ -1,3 +1,3 @@
frappe.treeview_settings["Item Group"] = {
ignore_fields:["parent_item_group"]
}
}

View File

@@ -1,13 +1,13 @@
// Copyright (c) 2015, Frappe Technologies Pvt. Ltd. and Contributors
// License: GNU General Public License v3. See license.txt
//--------- ONLOAD -------------
cur_frm.cscript.onload = function(doc, cdt, cdn) {
}
cur_frm.cscript.refresh = function(doc, cdt, cdn) {
}
}

View File

@@ -7,4 +7,4 @@ import frappe
from frappe.model.document import Document
class PrintHeading(Document):
pass
pass

View File

@@ -4,4 +4,4 @@ from __future__ import unicode_literals
import frappe
test_records = frappe.get_test_records('Print Heading')
test_records = frappe.get_test_records('Print Heading')

View File

@@ -1,13 +1,13 @@
// Copyright (c) 2015, Frappe Technologies Pvt. Ltd. and Contributors
// License: GNU General Public License v3. See license.txt
//--------- ONLOAD -------------
cur_frm.cscript.onload = function(doc, cdt, cdn) {
}
cur_frm.cscript.refresh = function(doc, cdt, cdn) {
}
}

View File

@@ -7,4 +7,4 @@ import frappe
from frappe.model.document import Document
class QuotationLostReason(Document):
pass
pass

View File

@@ -4,4 +4,4 @@ from __future__ import unicode_literals
import frappe
test_records = frappe.get_test_records('Quotation Lost Reason')
test_records = frappe.get_test_records('Quotation Lost Reason')

View File

@@ -12,4 +12,4 @@ def get_data():
'items': ['Sales Order', 'Delivery Note', 'Sales Invoice']
},
]
}
}

View File

@@ -9,4 +9,4 @@ frappe.treeview_settings["Sales Person"] = {
{fieldtype:'Check', fieldname:'is_group', label:__('Group Node'),
description: __("Further nodes can be only created under 'Group' type nodes")}
],
}
}

View File

@@ -1,4 +1,4 @@
frappe.treeview_settings["Supplier Group"] = {
breadcrumbs: "Buying",
ignore_fields:["parent_supplier_group"]
};
};

View File

@@ -7,4 +7,4 @@ import frappe
from frappe.model.document import Document
class TargetDetail(Document):
pass
pass

View File

@@ -1,13 +1,13 @@
// Copyright (c) 2015, Frappe Technologies Pvt. Ltd. and Contributors
// License: GNU General Public License v3. See license.txt
//--------- ONLOAD -------------
cur_frm.cscript.onload = function(doc, cdt, cdn) {
}
cur_frm.cscript.refresh = function(doc, cdt, cdn) {
}
}

View File

@@ -24,6 +24,6 @@ def get_terms_and_conditions(template_name, doc):
doc = json.loads(doc)
terms_and_conditions = frappe.get_doc("Terms and Conditions", template_name)
if terms_and_conditions.terms:
return frappe.render_template(terms_and_conditions.terms, doc)
return frappe.render_template(terms_and_conditions.terms, doc)

View File

@@ -36,4 +36,4 @@ cur_frm.fields_dict['parent_territory'].get_query = function(doc,cdt,cdn) {
['Territory', 'name', '!=', doc.territory_name]
]
}
}
}

View File

@@ -24,4 +24,4 @@ class Territory(NestedSet):
self.validate_one_root()
def on_doctype_update():
frappe.db.add_index("Territory", ["lft", "rgt"])
frappe.db.add_index("Territory", ["lft", "rgt"])

View File

@@ -1,3 +1,3 @@
frappe.treeview_settings["Territory"] = {
ignore_fields:["parent_territory"]
}
}

View File

@@ -23,7 +23,7 @@ class TestTransactionDeletionRecord(unittest.TestCase):
contains_company = True
break
self.assertTrue(contains_company)
def test_no_of_docs_is_correct(self):
for i in range(5):
create_task('Dunder Mifflin Paper Co')
@@ -40,13 +40,13 @@ class TestTransactionDeletionRecord(unittest.TestCase):
'company' : 'Dunder Mifflin Paper Co'
})
self.assertEqual(tasks_containing_company, [])
def create_company(company_name):
company = frappe.get_doc({
'doctype': 'Company',
'company_name': company_name,
'default_currency': 'INR'
})
})
company.insert(ignore_if_duplicate = True)
def create_transaction_deletion_request(company):

View File

@@ -4,7 +4,7 @@
frappe.ui.form.on('Transaction Deletion Record', {
onload: function(frm) {
if (frm.doc.docstatus == 0) {
let doctypes_to_be_ignored_array;
let doctypes_to_be_ignored_array;
frappe.call({
method: 'erpnext.setup.doctype.transaction_deletion_record.transaction_deletion_record.get_doctypes_to_be_ignored',
callback: function(r) {
@@ -25,15 +25,15 @@ frappe.ui.form.on('Transaction Deletion Record', {
frm.fields_dict['doctypes_to_be_ignored'].grid.set_column_disp('no_of_docs', false);
frm.refresh_field('doctypes_to_be_ignored');
}
});
function populate_doctypes_to_be_ignored(doctypes_to_be_ignored_array, frm) {
if (!(frm.doc.doctypes_to_be_ignored)) {
var i;
for (i = 0; i < doctypes_to_be_ignored_array.length; i++) {
for (i = 0; i < doctypes_to_be_ignored_array.length; i++) {
frm.add_child('doctypes_to_be_ignored', {
doctype_name: doctypes_to_be_ignored_array[i]
doctype_name: doctypes_to_be_ignored_array[i]
});
}
}

View File

@@ -9,4 +9,4 @@ frappe.listview_settings['Transaction Deletion Record'] = {
return [__("Completed"), "green"];
}
}
};
};

View File

@@ -1,13 +1,13 @@
// Copyright (c) 2015, Frappe Technologies Pvt. Ltd. and Contributors
// License: GNU General Public License v3. See license.txt
//--------- ONLOAD -------------
cur_frm.cscript.onload = function(doc, cdt, cdn) {
}
cur_frm.cscript.refresh = function(doc, cdt, cdn) {
}
}

View File

@@ -7,4 +7,4 @@ import frappe
from frappe.model.document import Document
class UOM(Document):
pass
pass

View File

@@ -9,4 +9,4 @@ import frappe
from frappe.model.document import Document
class WebsiteItemGroup(Document):
pass
pass

View File

@@ -173,4 +173,4 @@ def test_sample():
frappe.db.sql('delete from tabProject')
frappe.db.sql('delete from tabTask')
make_projects('Education')
import_notification()
import_notification()

View File

@@ -145,7 +145,7 @@ def make_taxes_and_charges_template(company_name, doctype, template):
doc = frappe.get_doc(template)
# Data in country wise json is already pre validated, hence validations can be ignored
# Data in country wise json is already pre validated, hence validations can be ignored
# Ingone validations to make doctypes faster
doc.flags.ignore_links = True
doc.flags.ignore_validate = True
@@ -177,7 +177,7 @@ def make_item_tax_template(company_name, template):
doc = frappe.get_doc(template)
# Data in country wise json is already pre validated, hence validations can be ignored
# Data in country wise json is already pre validated, hence validations can be ignored
# Ingone validations to make doctypes faster
doc.flags.ignore_links = True
doc.flags.ignore_validate = True