[POS] Minor fixes
This commit is contained in:
parent
2cb7a9f235
commit
c65c38d293
@ -93,4 +93,10 @@ cur_frm.cscript.buying = function() {
|
||||
//Dynamically change the description based on type of margin
|
||||
cur_frm.cscript.type = function(doc){
|
||||
cur_frm.set_df_property('rate', 'description', doc.type=='Percentage'?'In Percentage %':'In Amount')
|
||||
}
|
||||
}
|
||||
|
||||
frappe.ui.form.on('Pricing Rule', 'price_or_discount', function(frm){
|
||||
if(frm.doc.price_or_discount == 'Price') {
|
||||
frm.set_value('for_price_list', "")
|
||||
}
|
||||
})
|
@ -134,12 +134,14 @@ def get_customers(pos_profile, doc):
|
||||
return customer_list
|
||||
|
||||
def get_pricing_rules(doc):
|
||||
pricing_rules = ""
|
||||
if doc.ignore_pricing_rule == 0:
|
||||
return frappe.db.sql(""" Select * from `tabPricing Rule` where docstatus < 2 and disable = 0
|
||||
and selling = 1 and ifnull(company, '') in (%(company)s, '') and
|
||||
ifnull(for_price_list, '') in (%(price_list)s, '') and %(date)s between
|
||||
ifnull(valid_from, '2000-01-01') and ifnull(valid_upto, '2500-12-31') order by priority desc, name desc""",
|
||||
{'company': doc.company, 'price_list': doc.selling_price_list, 'date': nowdate()}, as_dict=1)
|
||||
pricing_rules = frappe.db.sql(""" Select * from `tabPricing Rule` where docstatus < 2 and disable = 0
|
||||
and selling = 1 and ifnull(company, '') in (%(company)s, '') and
|
||||
ifnull(for_price_list, '') in (%(price_list)s, '') and %(date)s between
|
||||
ifnull(valid_from, '2000-01-01') and ifnull(valid_upto, '2500-12-31') order by priority desc, name desc""",
|
||||
{'company': doc.company, 'price_list': doc.selling_price_list, 'date': nowdate()}, as_dict=1)
|
||||
return pricing_rules
|
||||
|
||||
@frappe.whitelist()
|
||||
def make_invoice(doc_list):
|
||||
|
@ -1,15 +0,0 @@
|
||||
<div class="text-center" style="padding: 40px;">
|
||||
<img src="/assets/erpnext/images/pos.svg"
|
||||
style="width: 100px; height: 100px; margin-bottom: 30px; opacity: 0.2" class="text-muted">
|
||||
<p>{%= __("Select type of transaction") %}</p>
|
||||
<p class="select-type" style="margin: auto; max-width: 300px; margin-bottom: 30px;">
|
||||
|
||||
</p>
|
||||
<p style="margin-bottom: 30px;">
|
||||
<button class="btn btn-primary btn-lg">{%= __("Start") %}</button>
|
||||
</p>
|
||||
<p class="pos-setting-message hide">
|
||||
<a class="btn btn-default btn-sm" href="#Form/POS Profile/New POS Profile">
|
||||
{%= __("Make new POS Profile") %}</a>
|
||||
</p>
|
||||
</div>
|
Loading…
x
Reference in New Issue
Block a user