Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

print_buttons option was removed in pull request #3, now restored

  • Loading branch information...
commit aca3bba7c09388698fd1eb81d3c8ff483ad8dc89 1 parent a16cbbe
Brad Folkens authored April 04, 2012
1  app/models/spree/print_invoice_configuration.rb
... ...
@@ -1,5 +1,6 @@
1 1
 module Spree
2 2
   class PrintInvoiceConfiguration < Preferences::Configuration
  3
+    preference :print_buttons, :string, :default => 'invoice'
3 4
     preference :print_invoice_logo_path, :string, :default => Spree::Config[:admin_interface_logo]
4 5
   end
5 6
 end
2  app/views/spree/admin/orders/_print_buttons.html.erb
... ...
@@ -1,5 +1,5 @@
1 1
 <% if @order.completed_at? %>
2  
-  <% buttons = "invoice" 
  2
+  <% buttons = Spree::PrintInvoice::Config[:print_buttons] 
3 3
      buttons = buttons.split(",").collect{|b| b.strip } %>
4 4
   <%  buttons.each do |button| %>
5 5
     <%= button_link_to('Invoice', spree.admin_order_path(@order, :pdf , :template => button)) %>

0 notes on commit aca3bba

Please sign in to comment.
Something went wrong with that request. Please try again.