erp_commerce 3.0.8 → 3.0.9
Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,57 @@
|
|
1
|
+
class AddCreditCardBizTxnAcctTypes
|
2
|
+
|
3
|
+
def self.up
|
4
|
+
# add credit card account types as biz txn account types
|
5
|
+
if (BizTxnAcctType.find_by_internal_identifier('credit_card_account').nil?)
|
6
|
+
@credit_card_account = BizTxnAcctType.create(
|
7
|
+
:description => 'Credit Card Account',
|
8
|
+
:internal_identifier => 'credit_card_account',
|
9
|
+
)
|
10
|
+
end
|
11
|
+
|
12
|
+
if (BizTxnAcctType.find_by_internal_identifier('amex').nil?)
|
13
|
+
@type = BizTxnAcctType.create(
|
14
|
+
:description => 'American Express',
|
15
|
+
:internal_identifier => 'amex',
|
16
|
+
)
|
17
|
+
@type.move_to_child_of @credit_card_account
|
18
|
+
end
|
19
|
+
|
20
|
+
if (BizTxnAcctType.find_by_internal_identifier('dinersclub').nil?)
|
21
|
+
@type = BizTxnAcctType.create(
|
22
|
+
:description => 'Diners Club',
|
23
|
+
:internal_identifier => 'dinersclub',
|
24
|
+
)
|
25
|
+
@type.move_to_child_of @credit_card_account
|
26
|
+
end
|
27
|
+
|
28
|
+
if (BizTxnAcctType.find_by_internal_identifier('discover').nil?)
|
29
|
+
@type = BizTxnAcctType.create(
|
30
|
+
:description => 'Discover',
|
31
|
+
:internal_identifier => 'discover',
|
32
|
+
)
|
33
|
+
@type.move_to_child_of @credit_card_account
|
34
|
+
end
|
35
|
+
|
36
|
+
if (BizTxnAcctType.find_by_internal_identifier('mastercard').nil?)
|
37
|
+
@type = BizTxnAcctType.create(
|
38
|
+
:description => 'MasterCard',
|
39
|
+
:internal_identifier => 'mastercard',
|
40
|
+
)
|
41
|
+
@type.move_to_child_of @credit_card_account
|
42
|
+
end
|
43
|
+
|
44
|
+
if (BizTxnAcctType.find_by_internal_identifier('visa').nil?)
|
45
|
+
@type = BizTxnAcctType.create(
|
46
|
+
:description => 'Visa',
|
47
|
+
:internal_identifier => 'visa',
|
48
|
+
)
|
49
|
+
@type.move_to_child_of @credit_card_account
|
50
|
+
end
|
51
|
+
end
|
52
|
+
|
53
|
+
def self.down
|
54
|
+
#remove data here
|
55
|
+
end
|
56
|
+
|
57
|
+
end
|
data/lib/erp_commerce/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: erp_commerce
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.0.
|
4
|
+
version: 3.0.9
|
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-
|
12
|
+
date: 2013-04-10 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: aasm
|
@@ -153,6 +153,7 @@ files:
|
|
153
153
|
- app/widgets/shopping_cart/views/price_summary.html.erb
|
154
154
|
- config/routes.rb
|
155
155
|
- db/data_migrations/20101011152441_payment_gateway_actions.rb
|
156
|
+
- db/data_migrations/20130408200643_add_credit_card_biz_txn_acct_types.rb
|
156
157
|
- db/migrate/20100823174238_erp_commerce_base.rb
|
157
158
|
- db/migrate/20100913154134_setup_payments.rb
|
158
159
|
- db/migrate/20101103132342_pricing_migrations.rb
|