Merge branch 'master' of bitbucket.org:code2lab/sxrestaurant

This commit is contained in:
Yan
2017-06-12 18:33:23 +06:30
9 changed files with 571 additions and 8 deletions

View File

@@ -263,4 +263,8 @@ class Sale < ApplicationRecord
def generate_custom_id
self.sale_id = SeedGenerator.generate_id(self.class.name, "SAL")
end
def self.get_receipt_no_list(from,to)
sale = Sale.where("sale_status=? and receipt_date between ? and ?","completed",from,to)
end
end