Class: Lab::LabelsController
- Inherits:
-
ApplicationController
- Object
- ApplicationController
- ApplicationController
- Lab::LabelsController
- Defined in:
- app/controllers/lab/labels_controller.rb
Instance Method Summary collapse
Instance Method Details
#print_order_label ⇒ Object
7 8 9 10 11 12 13 14 15 |
# File 'app/controllers/lab/labels_controller.rb', line 7 def print_order_label order_id = params.require(:order_id) label = LabellingService::OrderLabel.new(order_id) send_data(label.print, type: 'application/label; charset=utf-8', stream: false, filename: "#{SecureRandom.hex(24)}.lbl", disposition: 'inline') end |