supercharged 2.0.3 → 2.0.4

Sign up to get free protection for your applications and to get access to all the features.
@@ -14,7 +14,7 @@ class Supercharged::GatewayNotificationsController < ApplicationController
14
14
  elsif !@notification.acknowledge
15
15
  "acknowledge_failed"
16
16
  elsif !@notification.charge
17
- "charge not found"
17
+ "charge_not_found"
18
18
  end
19
19
 
20
20
  if error
@@ -27,7 +27,7 @@ class Supercharged::GatewayNotificationsController < ApplicationController
27
27
  @notification.charge.update_attribute(:error, error)
28
28
  end
29
29
 
30
- head :bad_request
30
+ redirect_to new_charge_url, alert: "#{I18n.t("supercharged.gateway_controller.error.failed")}: #{I18n.t("supercharged.gateway_controller.error.#{error}")}"
31
31
  else
32
32
  persistent_logger.info("Success")
33
33
  @notification.approve
@@ -0,0 +1,8 @@
1
+ en:
2
+ supercharged:
3
+ gateway_controller:
4
+ error:
5
+ failed: "Charge not completed"
6
+ not_completed: "not completed on the gateway"
7
+ acknowledge_failed: "acknowledge failed"
8
+ charge_not_found: "charge not found"
@@ -0,0 +1,8 @@
1
+ th:
2
+ supercharged:
3
+ gateway_controller:
4
+ error:
5
+ failed: "ไม่สามารถเรียกเก็บเงินได้"
6
+ not_completed: "ไม่สามารถเรียกเก็บเงินจาก gateway"
7
+ acknowledge_failed: "การตอบรับล้มเหลว"
8
+ charge_not_found: "ไม่พบการเรียกเก็บเงิน"
@@ -1,3 +1,3 @@
1
1
  module Supercharged
2
- VERSION = "2.0.3"
2
+ VERSION = "2.0.4"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: supercharged
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.3
4
+ version: 2.0.4
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2013-09-03 00:00:00.000000000 Z
12
+ date: 2013-10-11 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rails
@@ -187,6 +187,8 @@ files:
187
187
  - app/models/gateway_response.rb
188
188
  - app/models/payment_state_transition.rb
189
189
  - app/models/supercharged/charge/base.rb
190
+ - config/locales/en.yml
191
+ - config/locales/th.yml
190
192
  - config/routes.rb
191
193
  - lib/generators/supercharged/migrations_generator.rb
192
194
  - lib/generators/supercharged/templates/install_migration.rb
@@ -218,7 +220,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
218
220
  version: '0'
219
221
  segments:
220
222
  - 0
221
- hash: 1751232940266769247
223
+ hash: -682491328917340782
222
224
  required_rubygems_version: !ruby/object:Gem::Requirement
223
225
  none: false
224
226
  requirements:
@@ -227,7 +229,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
227
229
  version: '0'
228
230
  segments:
229
231
  - 0
230
- hash: 1751232940266769247
232
+ hash: -682491328917340782
231
233
  requirements: []
232
234
  rubyforge_project:
233
235
  rubygems_version: 1.8.23