Skip to content

Commit

Permalink
Merge pull request frappe#939 from Bloomstack/staging
Browse files Browse the repository at this point in the history
Merge staging into production
  • Loading branch information
sahil28297 authored Jan 8, 2021
2 parents 10dd839 + 8b79579 commit bc97ccf
Show file tree
Hide file tree
Showing 5 changed files with 96 additions and 283 deletions.
1 change: 1 addition & 0 deletions erpnext/selling/doctype/customer/customer_list.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
frappe.listview_settings['Customer'] = {
add_fields: ["customer_name", "territory", "customer_group", "customer_type", "image"],
ignore_user_default_filters: true
};
4 changes: 2 additions & 2 deletions erpnext/selling/doctype/quotation/quotation.json
Original file line number Diff line number Diff line change
Expand Up @@ -415,7 +415,7 @@
"oldfieldname": "quotation_details",
"oldfieldtype": "Table",
"options": "Quotation Item",
"reqd": 1,
"reqd": 0,
"width": "40px"
},
{
Expand Down Expand Up @@ -957,7 +957,7 @@
"idx": 82,
"is_submittable": 1,
"max_attachments": 1,
"modified": "2021-01-04 06:58:24.189403",
"modified": "2021-01-08 06:58:24.189403",
"modified_by": "Administrator",
"module": "Selling",
"name": "Quotation",
Expand Down
5 changes: 5 additions & 0 deletions erpnext/selling/doctype/quotation/quotation.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@ def on_submit(self):
#update enquiry status
self.update_opportunity()
self.update_lead()
self.check_items()

def on_cancel(self):
super(Quotation, self).on_cancel()
Expand All @@ -99,6 +100,10 @@ def on_cancel(self):
self.update_opportunity()
self.update_lead()

def check_items(self):
if not self.items:
frappe.throw(_("You cannot submit an empty Quotation."))

def print_other_charges(self,docname):
print_lst = []
for d in self.get('taxes'):
Expand Down
Loading

0 comments on commit bc97ccf

Please sign in to comment.