[Git][noosfero/noosfero][master] 3 commits: oauth_client: fix edit action in provider's crud
Bráulio Bhavamitra
gitlab at mg.gitlab.com
Thu Mar 24 18:34:50 BRT 2016
Bráulio Bhavamitra pushed to branch master at Noosfero / noosfero
Commits:
1774945b by Lucas Kanashiro at 2016-03-23T13:38:22-03:00
oauth_client: fix edit action in provider's crud
Signed-off-by: Lucas Kanashiro <kanashiro.duarte at gmail.com>
Signed-off-by: Macartur Sousa <macartur.sc at gmail.com>
- - - - -
eb6f15d0 by Lucas Kanashiro at 2016-03-23T13:38:22-03:00
oauth_client: add callback config in documentation
Signed-off-by: Lucas Kanashiro <kanashiro.duarte at gmail.com>
Signed-off-by: Macartur Sousa <macartur.sc at gmail.com>
- - - - -
6781aeb3 by Bráulio Bhavamitra at 2016-03-24T21:33:57+00:00
Merge branch 'improve_oauth_client' into 'master'
Improve oauth client
This MR is related to oauth-client plugin. Fix a bug in edit of providers and improve documentation. Making this plugin up-to-date.
See merge request !821
- - - - -
3 changed files:
- plugins/oauth_client/README.md
- plugins/oauth_client/models/oauth_client_plugin/provider.rb
- plugins/oauth_client/views/oauth_client_plugin_admin/edit.html.erb
Changes:
=====================================
plugins/oauth_client/README.md
=====================================
--- a/plugins/oauth_client/README.md
+++ b/plugins/oauth_client/README.md
@@ -33,6 +33,14 @@ Facebook
[Create Facebook application](https://developers.facebook.com/docs/facebook-login/v2.1)
+Callback
+========
+
+This is the callback path that you need to use in your app configuration:
+
+/plugin/oauth_client/public/callback
+
+
Varnish Settings
================
If varnish has been used in your stack, you've to bypass the cache for signup page and prevent cookies to be removed when calling the oauth_client plugin callback. E.g.:
=====================================
plugins/oauth_client/models/oauth_client_plugin/provider.rb
=====================================
--- a/plugins/oauth_client/models/oauth_client_plugin/provider.rb
+++ b/plugins/oauth_client/models/oauth_client_plugin/provider.rb
@@ -11,7 +11,7 @@ class OauthClientPlugin::Provider < ActiveRecord::Base
settings_items :client_options, type: Hash
attr_accessible :name, :strategy, :enabled, :site, :image_builder,
- :environment, :environment_id,
+ :environment, :environment_id, :options,
:client_id, :client_secret, :client_options
scope :enabled, -> { where enabled: true }
=====================================
plugins/oauth_client/views/oauth_client_plugin_admin/edit.html.erb
=====================================
--- a/plugins/oauth_client/views/oauth_client_plugin_admin/edit.html.erb
+++ b/plugins/oauth_client/views/oauth_client_plugin_admin/edit.html.erb
@@ -1,7 +1,7 @@
<h1><%= _('Oauth Client Settings') %></h1>
<h3><%= _('Edit Provider') %></h3>
-<%= form_for @provider, :url => {:action => 'edit'}, :method => 'post' do |f| %>
+<%= form_for @provider, :url => {:action => 'edit', :id => @provider.id}, :method => 'post' do |f| %>
<div class="enabled">
<%= labelled_form_field f.check_box(:enabled) + _('Enabled'), '' %>
View it on GitLab: https://gitlab.com/noosfero/noosfero/compare/763189acb5555817ba2a5b37938b04c1c5d49e6e...6781aeb365503606813c0320665819917a51abbf
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listas.softwarelivre.org/pipermail/noosfero-dev/attachments/20160324/0c13630c/attachment-0001.html>
More information about the Noosfero-dev
mailing list