mirror of
https://github.com/rickbarrette/redmine_qbo.git
synced 2025-11-08 08:54:23 -05:00
Fixed routes and paths
This commit is contained in:
@@ -30,7 +30,7 @@ class QboController < ApplicationController
|
||||
# Called when the user requests that Redmine to connect to QBO
|
||||
#
|
||||
def authenticate
|
||||
callback = "https://rickbarrette.org/redmine/oauth_callback"
|
||||
callback = request.base_url + qbo_oauth_callback_path
|
||||
token = $qb_oauth_consumer.get_request_token(:oauth_callback => callback)
|
||||
session[:qb_request_token] = token
|
||||
redirect_to("https://appcenter.intuit.com/Connect/Begin?oauth_token=#{token.token}") and return
|
||||
@@ -58,7 +58,7 @@ class QboController < ApplicationController
|
||||
if qbo.save!
|
||||
redirect_to plugin_settings_path(:redmine_qbo), :flash => { :notice => "Successfully connected to Quickbooks" }
|
||||
else
|
||||
redirect_to plugin_settings_path(:redmine_qbo), :flash => { :error => "Errorn_settings_path" }
|
||||
redirect_to plugin_settings_path(:redmine_qbo), :flash => { :error => "Error" }
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
@@ -55,4 +55,4 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI
|
||||
Note: You need to authenticate after saving your key and secret above
|
||||
<br/>
|
||||
|
||||
<%= link_to "Authenticate", authenticate_path, :method => :get %>
|
||||
<%= link_to "Authenticate", qbo_authenticate_path, :method => :get %>
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
# See: http://guides.rubyonrails.org/routing.html
|
||||
#
|
||||
|
||||
get 'authenticate', :to => 'qbo#authenticate'
|
||||
get 'oauth_callback', :to => 'qbo#oauth_callback'
|
||||
get 'qbo/authenticate', :to => 'qbo#authenticate'
|
||||
get 'qbo/oauth_callback', :to => 'qbo#oauth_callback'
|
||||
|
||||
get 'qbo_sync', :to => 'qbo#sync'
|
||||
get 'qop/qbo_sync', :to => 'qbo#sync'
|
||||
|
||||
Reference in New Issue
Block a user