discourse_subscription_client 0.1.0.pre14 → 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 07afbdfba495c751b1a4f98c5ab657e5f0e044613e525ed806a438a97d41e994
4
- data.tar.gz: 790e0abe8336eeb2f53eeb0f49a975d0f2a5a9054b6bc56bee6435d76474c563
3
+ metadata.gz: 3750d66a3de88f59b270847293b0ded796268e3b3cd9953ed2dfee929b0799dd
4
+ data.tar.gz: a40360ba776ce0478877662ca1f001ed0bf156dff8c23d7e5b2f1ce4aa263299
5
5
  SHA512:
6
- metadata.gz: 4d63f530f372e9fe425ca8584ed89b64ae2b95815ee61de495c2b77946b6e379ade75705bb225d6f89433f9ea0fbcd6f643c67dec0f3f7f6f593f23d97aaed6c
7
- data.tar.gz: 9875787a8a6de21f0fe8d9482f82cd3045dd73a9394e2d6d2ba6d2b3892d569162628b2eed2e5974200aab3ea6e3c9833a00e1f91c9042d643267d1b59d3df22
6
+ metadata.gz: 8d7e939a6f795d8363025defeea70551d59ffbd86754ba56691ec0fa85a01ae9d35b2cc9fb667b77f689663c7d43998fb443773c32c67ad8b2ea37a6622417cc
7
+ data.tar.gz: 4c2cdc67e91ce4b727afc46c30ac8232c0a3da85f7db8bce14d650f4246bdfe19f5bc0d3bbd1f09f6a42b5416bd5b7ece3613be4a71a9e88966f2365a53c9eea
@@ -11,6 +11,8 @@ module DiscourseSubscriptionClient
11
11
  end
12
12
 
13
13
  def authorize
14
+ session[:final_landing_path] = params[:final_landing_path]
15
+
14
16
  request_id = DiscourseSubscriptionClient::Authorization.request_id(@supplier.id)
15
17
  cookies[:user_api_request_id] = request_id
16
18
  redirect_to DiscourseSubscriptionClient::Authorization.url(current_user, @supplier, request_id).to_s,
@@ -36,7 +38,11 @@ module DiscourseSubscriptionClient
36
38
 
37
39
  DiscourseSubscriptionClient::Subscriptions.update
38
40
 
39
- redirect_to "/admin/plugins/subscription-client/subscriptions"
41
+ if !session[:final_landing_path].blank?
42
+ redirect_to session[:final_landing_path]
43
+ else
44
+ redirect_to "/admin/plugins"
45
+ end
40
46
  end
41
47
 
42
48
  def destroy
@@ -215,8 +215,3 @@ end
215
215
  # created_at :datetime not null
216
216
  # updated_at :datetime not null
217
217
  #
218
- # Indexes
219
- #
220
- # index_subscription_client_notices_on_notice_subject (notice_subject_type,notice_subject_id)
221
- # sc_unique_notices (notice_type,notice_subject_type,notice_subject_id,changed_at) UNIQUE
222
- #
@@ -1,4 +1,18 @@
1
1
  # frozen_string_literal: true
2
2
 
3
+ # == Schema Information
4
+ #
5
+ # Table name: subscription_client_requests
6
+ #
7
+ # id :bigint not null, primary key
8
+ # request_id :bigint
9
+ # request_type :string
10
+ # expired_at :datetime
11
+ # message :string
12
+ # count :integer
13
+ # response :json
14
+ # created_at :datetime not null
15
+ # updated_at :datetime not null
16
+ #
3
17
  class SubscriptionClientRequest < ActiveRecord::Base
4
18
  end
@@ -16,12 +16,3 @@ end
16
16
  # created_at :datetime not null
17
17
  # updated_at :datetime not null
18
18
  #
19
- # Indexes
20
- #
21
- # index_subscription_client_resources_on_supplier_id (supplier_id)
22
- # index_subscription_client_resources_on_supplier_id_and_name (supplier_id,name) UNIQUE
23
- #
24
- # Foreign Keys
25
- #
26
- # fk_rails_... (supplier_id => subscription_client_suppliers.id)
27
- #
@@ -48,12 +48,3 @@ end
48
48
  # created_at :datetime not null
49
49
  # updated_at :datetime not null
50
50
  #
51
- # Indexes
52
- #
53
- # index_subscription_client_subscriptions_on_resource_id (resource_id)
54
- # sc_unique_subscriptions (resource_id,product_id,price_id) UNIQUE
55
- #
56
- # Foreign Keys
57
- #
58
- # fk_rails_... (resource_id => subscription_client_resources.id)
59
- #
@@ -50,9 +50,5 @@ end
50
50
  # authorized_at :datetime
51
51
  # created_at :datetime not null
52
52
  # updated_at :datetime not null
53
- #
54
- # Indexes
55
- #
56
- # index_subscription_client_suppliers_on_url (url) UNIQUE
57
- # index_subscription_client_suppliers_on_user_id (user_id)
53
+ # products :json
58
54
  #
@@ -24,7 +24,7 @@ module DiscourseSubscriptionClient
24
24
  config.after_initialize do
25
25
  gem_root = File.expand_path("../..", __dir__)
26
26
 
27
- ActiveRecord::Tasks::DatabaseTasks.migrations_paths << "#{gem_root}/db/migrate" unless Rails.env.test?
27
+ ActiveRecord::Tasks::DatabaseTasks.migrations_paths << "#{gem_root}/db/migrate"
28
28
 
29
29
  %w[
30
30
  ./request
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module DiscourseSubscriptionClient
4
- VERSION = "0.1.0.pre14"
4
+ VERSION = "0.1.0"
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: discourse_subscription_client
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0.pre14
4
+ version: 0.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Angus McLeod
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-07-05 00:00:00.000000000 Z
11
+ date: 2023-11-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: active_model_serializers
@@ -126,14 +126,14 @@ dependencies:
126
126
  name: rails
127
127
  requirement: !ruby/object:Gem::Requirement
128
128
  requirements:
129
- - - ">="
129
+ - - "~>"
130
130
  - !ruby/object:Gem::Version
131
131
  version: 7.0.4.1
132
132
  type: :development
133
133
  prerelease: false
134
134
  version_requirements: !ruby/object:Gem::Requirement
135
135
  requirements:
136
- - - ">="
136
+ - - "~>"
137
137
  - !ruby/object:Gem::Version
138
138
  version: 7.0.4.1
139
139
  - !ruby/object:Gem::Dependency
@@ -278,7 +278,7 @@ metadata:
278
278
  homepage_uri: https://github.com/paviliondev/discourse_subscription_client
279
279
  source_code_uri: https://github.com/paviliondev/discourse_subscription_client
280
280
  changelog_uri: https://github.com/paviliondev/discourse_subscription_client
281
- post_install_message:
281
+ post_install_message:
282
282
  rdoc_options: []
283
283
  require_paths:
284
284
  - lib
@@ -289,12 +289,12 @@ required_ruby_version: !ruby/object:Gem::Requirement
289
289
  version: 2.6.0
290
290
  required_rubygems_version: !ruby/object:Gem::Requirement
291
291
  requirements:
292
- - - ">"
292
+ - - ">="
293
293
  - !ruby/object:Gem::Version
294
- version: 1.3.1
294
+ version: '0'
295
295
  requirements: []
296
- rubygems_version: 3.4.6
297
- signing_key:
296
+ rubygems_version: 3.3.26
297
+ signing_key:
298
298
  specification_version: 4
299
299
  summary: Discourse plugin subscription client.
300
300
  test_files: []