-
Notifications
You must be signed in to change notification settings - Fork 240
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Don't use Rails.application.assets #106
base: master
Are you sure you want to change the base?
Conversation
…oduct to get the name
In order to make customization of the build in template much easier, we introduce a generator that copy the templates into the app. Fixes spree-contrib#78
Remove selenium support and update poltergeist. Adds new settings store_pdf and storage_path Adds pdf file generation to order model. The order can now render itself to pdf. Delegate order controller show :pdf action to order. The controller now tells the order to render itself as pdf and to store it, if enabled. Fix pdf templates. Add javascript injection to install generator. Mention store pdf feature in readme Updates invoice number on pdf render in controller. Like before: it sets the invoice number to next incremential value, if enabled. Stub configuration for more reliable tests Fixes spree-contrib#80
Bump spree_core dependency from beta
as this can cause problems for precompiling
|
||
context 'with invoice number present' do | ||
before do | ||
order.invoice_number = "1000" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Prefer single-quoted strings when you don't need string interpolation or special symbols.
@@ -3,6 +3,10 @@ module Generators | |||
class InstallGenerator < Rails::Generators::Base | |||
class_option :auto_run_migrations, type: :boolean, default: true | |||
|
|||
def add_javascripts | |||
append_file "vendor/assets/javascripts/spree/backend/all.js", "//= require spree/backend/spree_print_invoice\n" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Prefer single-quoted strings when you don't need string interpolation or special symbols.
Use
asset_path
instead.See #105.