diff --git a/app/controllers/estimate_controller.rb b/app/controllers/estimate_controller.rb index 8464dd6..78e4f00 100644 --- a/app/controllers/estimate_controller.rb +++ b/app/controllers/estimate_controller.rb @@ -36,7 +36,7 @@ class EstimateController < ApplicationController estimate = get_estimate begin - send_data estimate.pdf, filename: "estimate #{estimate.doc_number}.pdf", disposition: 'inline', type: "application/pdf" + send_data estimate.pdf, filename: "estimate #{estimate.doc_number}.pdf", disposition: :inline, type: "application/pdf" rescue redirect_to :back, flash: { error: "Estimate not found" } end @@ -49,7 +49,7 @@ class EstimateController < ApplicationController estimate = get_estimate begin - send_data estimate.pdf, filename: "estimate #{estimate.doc_number}.pdf", disposition: 'inline', type: "application/pdf" + send_data estimate.pdf, filename: "estimate #{estimate.doc_number}.pdf", disposition: :inline, type: "application/pdf" rescue redirect_to :back, flash: { error: "Estimate not found" } end diff --git a/app/controllers/invoice_controller.rb b/app/controllers/invoice_controller.rb index 4c06e18..dc7241b 100644 --- a/app/controllers/invoice_controller.rb +++ b/app/controllers/invoice_controller.rb @@ -45,7 +45,7 @@ class InvoiceController < ApplicationController ref = invoice.doc_number end - send_data @pdf, filename: "invoice #{ref}.pdf", disposition: 'inline', type: "application/pdf" + send_data @pdf, filename: "invoice #{ref}.pdf", disposition: :inline, type: "application/pdf" end rescue redirect_to :back, flash: { error: "Invoice not found" } diff --git a/app/controllers/qbo_controller.rb b/app/controllers/qbo_controller.rb index 8cd4026..a05455b 100644 --- a/app/controllers/qbo_controller.rb +++ b/app/controllers/qbo_controller.rb @@ -92,10 +92,10 @@ class QboController < ApplicationController data = params.as_json end # Process the information - entities = data['eventNotifications'][0]['dataChangeEvent']['entities'] + entities = data['eventNotifications'][0]['dataChangeEvent'][:entities] entities.each do |entity| - id = entity['id'].to_i - name = entity['name'] + id = entity[:id].to_i + name = entity[:name] logger.info "Casting #{name.constantize} to obj" @@ -106,7 +106,7 @@ class QboController < ApplicationController obj.destroy(entity['deletedId']) if entity['deletedId'] #Check to see if we are deleting a record - if entity['operation'].eql? "Delete" + if entity[:operation].eql? "Delete" obj.destroy(id) #if not then update! else diff --git a/app/models/concerns/quickbooks_oauth.rb b/app/models/concerns/quickbooks_oauth.rb index 2508f00..0a0138c 100644 --- a/app/models/concerns/quickbooks_oauth.rb +++ b/app/models/concerns/quickbooks_oauth.rb @@ -73,7 +73,7 @@ module QuickbooksOauth oauth_consumer_secret = Setting.plugin_redmine_qbo['settingsOAuthConsumerSecret'] # Are we are playing in the sandbox? - Quickbooks.sandbox_mode = Setting.plugin_redmine_qbo['sandbox'] ? true : false + Quickbooks.sandbox_mode = Setting.plugin_redmine_qbo[:sandbox] ? true : false logger.info "Sandbox mode: #{Quickbooks.sandbox_mode}" options = { diff --git a/app/views/customers/_form.html.erb b/app/views/customers/_form.html.erb index dbc4cf9..e9f2cf1 100644 --- a/app/views/customers/_form.html.erb +++ b/app/views/customers/_form.html.erb @@ -36,7 +36,7 @@ <%=t(:field_notes)%>:
- <%= content_tag 'span', id: "issue_description_and_toolbar" do %> + <%= content_tag :span, id: "issue_description_and_toolbar" do %> <%= f.text_area :notes, cols: 60, rows: 10, @@ -45,7 +45,7 @@ no_label: true %> <% end %>
- <%= wikitoolbar_for 'issue_description' %> + <%= wikitoolbar_for :issue_description %><%=l(:field_description)%>
diff --git a/app/views/issues/_list_simple.html.erb b/app/views/issues/_list_simple.html.erb index c7c2cc2..5a12624 100644 --- a/app/views/issues/_list_simple.html.erb +++ b/app/views/issues/_list_simple.html.erb @@ -9,7 +9,7 @@ <% for issue in issues %> -