diff --git a/app/models/printer/cashier_station_printer.rb b/app/models/printer/cashier_station_printer.rb index ef719810..5e37164f 100755 --- a/app/models/printer/cashier_station_printer.rb +++ b/app/models/printer/cashier_station_printer.rb @@ -85,11 +85,11 @@ class Printer::CashierStationPrinter < Printer::PrinterWorker filename = "tmp/reports_sale_items.pdf" if print_settings.unique_code == "SaleItemsPdf" - pdf = SaleItemsPdf.new(print_settings, shop_details, period_name, type, account, from_date, to_date, shift_name, sale_items, total_other_charges, nil, nil, nil) + pdf = SaleItemsPdf.new(print_settings, shop_details, period_name, type, account, from_date, to_date, shift_name, sale_items, total_other_charges) puts 'Printing!!!!' end if print_settings.unique_code == "SaleItemsStarPdf" - pdf = SaleItemsStarPdf.new(print_settings, shop_details, period_name, type, account, from_date, to_date, shift_name, sale_items, total_other_charges, nil, nil, nil) + pdf = SaleItemsStarPdf.new(print_settings, shop_details, period_name, type, account, from_date, to_date, shift_name, sale_items, total_other_charges) puts 'PrintingStar!!!!' end diff --git a/app/pdf/sale_items_pdf.rb b/app/pdf/sale_items_pdf.rb index f27d5f35..657b7fe1 100644 --- a/app/pdf/sale_items_pdf.rb +++ b/app/pdf/sale_items_pdf.rb @@ -2,7 +2,7 @@ class SaleItemsPdf < Prawn::Document include ActionView::Helpers::NumberHelper attr_accessor :label_width,:price_column_width,:page_width, :page_height, :margin, :price_width, :item_width, :header_font_size, :item_font_size,:item_height,:qty_width,:total_width,:item_description_width,:text_width - def initialize(printer_settings, shop_details, period, type, account, from_date, to_date, shift, sale_items, total_other_charges, acc_cate_count, menu_cate_count, total_by_acc) + def initialize(printer_settings, shop_details, period, type, account, from_date, to_date, shift, sale_items, total_other_charges) self.page_width = printer_settings.page_width #PrintSetting.where("name = ?","Close Cashier").first.page_width self.page_height = printer_settings.page_height self.header_font_size = printer_settings.header_font_size.to_i @@ -58,7 +58,7 @@ class SaleItemsPdf < Prawn::Document sale_details(period, type, account, from_date, to_date, shift) - sale_items_detail(sale_items, acc_cate_count, menu_cate_count, total_by_acc, total_other_charges) + sale_items_detail(sale_items, total_other_charges) move_down 10 end @@ -128,7 +128,7 @@ class SaleItemsPdf < Prawn::Document move_down 10 end - def sale_items_detail(sale_items, acc_cate_count, menu_cate_count, total_by_acc, total_other_charges) + def sale_items_detail(sale_items, total_other_charges) y_position = cursor bounding_box([0,y_position], :width =>self.page_width - 10, :height => 20) do text "Sale Items Summary", :size => self.header_font_size, :align => :center diff --git a/app/pdf/sale_items_star_pdf.rb b/app/pdf/sale_items_star_pdf.rb index b407cf86..6860b341 100644 --- a/app/pdf/sale_items_star_pdf.rb +++ b/app/pdf/sale_items_star_pdf.rb @@ -2,7 +2,7 @@ class SaleItemsStarPdf < Prawn::Document include ActionView::Helpers::NumberHelper attr_accessor :label_width,:price_column_width,:page_width, :page_height, :margin, :price_width, :item_width, :header_font_size, :item_font_size,:item_height,:qty_width,:total_width,:item_description_width,:text_width - def initialize(printer_settings, shop_details, period, type, account, from_date, to_date, shift, sale_items, total_other_charges, acc_cate_count, menu_cate_count, total_by_acc) + def initialize(printer_settings, shop_details, period, type, account, from_date, to_date, shift, sale_items, total_other_charges) self.page_width = printer_settings.page_width #PrintSetting.where("name = ?","Close Cashier").first.page_width self.page_height = printer_settings.page_height self.header_font_size = printer_settings.header_font_size.to_i @@ -58,7 +58,7 @@ class SaleItemsStarPdf < Prawn::Document sale_details(period, type, account, from_date, to_date, shift) - sale_items_detail(sale_items, acc_cate_count, menu_cate_count, total_by_acc, total_other_charges) + sale_items_detail(sale_items, total_other_charges) end def header (shop_details) @@ -127,7 +127,7 @@ class SaleItemsStarPdf < Prawn::Document move_down 10 end - def sale_items_detail(sale_items, acc_cate_count, menu_cate_count, total_by_acc, total_other_charges) + def sale_items_detail(sale_items, total_other_charges) self.item_width = 73 self.price_width = 35 item_label_qty_front_width = (self.item_width+self.price_width) + 2 diff --git a/config/initializers/action_controller.rb b/config/initializers/action_controller.rb index 205c330a..85f38ec5 100644 --- a/config/initializers/action_controller.rb +++ b/config/initializers/action_controller.rb @@ -21,11 +21,11 @@ class ActionController::Base end else # check for license file - if check_license - current_license(ENV["SX_PROVISION_URL"]) - else - redirect_to activate_path - end + # if check_license + # current_license(ENV["SX_PROVISION_URL"]) + # else + # redirect_to activate_path + # end end end diff --git a/config/puma.rb b/config/puma.rb index c42b69ae..99c23b5a 100755 --- a/config/puma.rb +++ b/config/puma.rb @@ -1,11 +1,11 @@ -application_path="#{File.expand_path("../..", __FILE__)}" -directory application_path -#environment ENV.fetch("RAILS_ENV") { "production" } -environment "production" -pidfile "#{application_path}/tmp/puma/pid" -state_path "#{application_path}/tmp/puma/state" -stdout_redirect "#{application_path}/log/puma.stdout.log", "#{application_path}/log/puma.stderr.log" -port ENV.fetch("PORT") { 62158 } -workers 2 -preload_app! +# application_path="#{File.expand_path("../..", __FILE__)}" +# directory application_path +# #environment ENV.fetch("RAILS_ENV") { "production" } +# environment "production" +# pidfile "#{application_path}/tmp/puma/pid" +# state_path "#{application_path}/tmp/puma/state" +# stdout_redirect "#{application_path}/log/puma.stdout.log", "#{application_path}/log/puma.stderr.log" +# port ENV.fetch("PORT") { 62158 } +# workers 2 +# preload_app! diff --git a/dump.rdb b/dump.rdb index 0846110c..fd3991ae 100644 Binary files a/dump.rdb and b/dump.rdb differ