gotransverse-tract-api 0.1.2 → 0.1.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: e136ed93de32f0dc8a13c76f362f9cdd24ad4457
4
- data.tar.gz: b0f04900756ca56d5721773f80e51ef4890274ec
3
+ metadata.gz: 428eb65f3391a15ecbd6d8ea365279f04f3703a1
4
+ data.tar.gz: d4d5e187560e9fe8954018f4fb88a8d37f431d4a
5
5
  SHA512:
6
- metadata.gz: aa9de324e988989664f018d6c2dd9eb9ff41deed33c5cba7391f41427df4988dfa9838f29bb9fd3efcd355134a1e7a812a208926668374fefa336b69e0394096
7
- data.tar.gz: ab8c0bc5acf68940438afca5339727faeed5703aaf484441328410523771545ddfa3cb0dfcb091f88f62f9e58fca8cf52c8e2bd839e5bf3d8337b923bdfffb57
6
+ metadata.gz: 79ba20a0621ac7d169cf9456c434eadcada54ea939e39ad38f84a494b01988177c3a6cf274d6c11d9ed3853e55d866f19c357931068559373ef9909797461866
7
+ data.tar.gz: 118bf4a58e46df1ff1c94dd66e7f29270516b73da990a52551f9dc60a3078b8c1c84830cf2d367fb6a375cdf78c5bf7461cc6decf0435b6b768c17209cbc66c4
data/README.md CHANGED
@@ -89,8 +89,8 @@ Please keep version number increments under control :)
89
89
 
90
90
  ## Authors
91
91
 
92
- Julien DeFrance
93
- Ravikumar Gudipati
92
+ * Julien DeFrance
93
+ * Ravikumar Gudipati
94
94
 
95
95
 
96
96
  ## Donations
@@ -4,12 +4,70 @@ module GoTransverseTractApi
4
4
 
5
5
  class Agreement
6
6
 
7
- def self.find_all
8
- GoTransverseTractApi.get_response_for(self)
9
- end
7
+ class << self
8
+ def find_all
9
+ GoTransverseTractApi.get_response_for(self)
10
+ end
11
+
12
+ #
13
+ # @param {Long} eid
14
+ #
15
+ def find_by_eid eid
16
+ GoTransverseTractApi.get_response_for(self, {eid: eid})
17
+ end
18
+
19
+ #
20
+ # @param {String} name
21
+ #
22
+ def find_by_name name
23
+ GoTransverseTractApi.get_response_for(self, {name: name})
24
+ end
25
+
26
+ #
27
+ # @param {Long} product_eid
28
+ #
29
+ def find_by_product_eid product_eid
30
+ GoTransverseTractApi.get_response_for(self, {product_eid: product_eid})
31
+ end
32
+
33
+ #
34
+ # @param {String} status
35
+ #
36
+ def find_by_status status
37
+ GoTransverseTractApi.get_response_for(self, {status: status})
38
+ end
10
39
 
40
+ #
41
+ # @param {String} termination_fee_currency_type
42
+ #
43
+ def find_by_termination_fee_currency_type termination_fee_currency_type
44
+ GoTransverseTractApi.get_response_for(self, {termination_fee_currency_type: termination_fee_currency_type})
45
+ end
46
+
47
+ #
48
+ # @param {String} max_termination_fee_currency_type
49
+ #
50
+ def find_by_max_termination_fee_currency_type max_termination_fee_currency_type
51
+ GoTransverseTractApi.get_response_for(self, {max_termination_fee_currency_type: max_termination_fee_currency_type})
52
+ end
53
+
54
+ #
55
+ # @param {Date} from_date
56
+ #
57
+ def find_by_from_date from_date
58
+ GoTransverseTractApi.get_response_for(self, {from_date: from_date})
59
+ end
60
+
61
+ #
62
+ # @param {Date} thru_date
63
+ #
64
+ def find_by_thru_date thru_date
65
+ GoTransverseTractApi.get_response_for(self, {thru_date: thru_date})
66
+ end
67
+
68
+ end
11
69
  end
12
70
 
13
71
  end
14
72
 
15
- end
73
+ end
@@ -4,12 +4,42 @@ module GoTransverseTractApi
4
4
 
5
5
  class BillCycle
6
6
 
7
- def self.find_all
8
- GoTransverseTractApi.get_response_for(self)
7
+ class << self
8
+ def find_all
9
+ GoTransverseTractApi.get_response_for(self)
10
+ end
11
+
12
+ #
13
+ # @param {Long} eid
14
+ #
15
+ def find_by_eid eid
16
+ GoTransverseTractApi.get_response_for(self, {eid: eid})
17
+ end
18
+
19
+ #
20
+ # @param {String} name
21
+ #
22
+ def find_by_name name
23
+ GoTransverseTractApi.get_response_for(self, {name: name})
24
+ end
25
+
26
+ #
27
+ # @param {String} type
28
+ #
29
+ def find_by_type type
30
+ GoTransverseTractApi.get_response_for(self, {type: type})
31
+ end
32
+
33
+ #
34
+ # @param {String} status
35
+ #
36
+ def find_by_status status
37
+ GoTransverseTractApi.get_response_for(self, {status: status})
38
+ end
9
39
  end
10
40
 
11
41
  end
12
42
 
13
43
  end
14
44
 
15
- end
45
+ end
@@ -4,12 +4,35 @@ module GoTransverseTractApi
4
4
 
5
5
  class BillingAccountCategory
6
6
 
7
- def self.find_all
8
- GoTransverseTractApi.get_response_for(self)
7
+ class << self
8
+ def find_all
9
+ GoTransverseTractApi.get_response_for(self)
10
+ end
11
+
12
+ #
13
+ # @param {Long} eid
14
+ #
15
+ def find_by_eid eid
16
+ GoTransverseTractApi.get_response_for(self, {eid: eid})
17
+ end
18
+
19
+ #
20
+ # @param {String} desc
21
+ #
22
+ def find_by_desc desc
23
+ GoTransverseTractApi.get_response_for(self, {desc: desc})
24
+ end
25
+
26
+ #
27
+ # @param {String} status
28
+ #
29
+ def find_by_status status
30
+ GoTransverseTractApi.get_response_for(self, {status: status})
31
+ end
9
32
  end
10
33
 
11
34
  end
12
35
 
13
36
  end
14
37
 
15
- end
38
+ end
@@ -4,8 +4,61 @@ module GoTransverseTractApi
4
4
 
5
5
  class OrderItemCharge
6
6
 
7
+ class << self
8
+
9
+ #
10
+ # @param {Long} eid
11
+ #
12
+ def find_by_eid eid
13
+ GoTransverseTractApi.get_response_for(self, {eid: eid})
14
+ end
15
+
16
+ #
17
+ # @param {Long} order_eid
18
+ #
19
+ def find_by_order_eid order_eid
20
+ GoTransverseTractApi.get_response_for(self, {order_eid: order_eid})
21
+ end
22
+
23
+ #
24
+ # @param {Long} order_item_eid
25
+ #
26
+ def find_by_order_item_eid order_item_eid
27
+ GoTransverseTractApi.get_response_for(self, {order_item_eid: order_item_eid})
28
+ end
29
+
30
+ #
31
+ # @param {Long} account_num
32
+ #
33
+ def find_by_account_num account_num
34
+ GoTransverseTractApi.get_response_for(self, {account_num: account_num})
35
+ end
36
+
37
+ #
38
+ # @param {Long} billing_account_eid
39
+ #
40
+ def find_by_billing_account_eid billing_account_eid
41
+ GoTransverseTractApi.get_response_for(self, {billing_account_eid: billing_account_eid})
42
+ end
43
+
44
+ #
45
+ # @param {String} not_to_invoice
46
+ #
47
+ def find_by_not_to_invoice not_to_invoice
48
+ GoTransverseTractApi.get_response_for(self, {not_to_invoice: not_to_invoice})
49
+ end
50
+
51
+ #
52
+ # @param {Boolean} invoiced
53
+ #
54
+ def find_by_invoiced invoiced
55
+ GoTransverseTractApi.get_response_for(self, {invoiced: invoiced})
56
+ end
57
+
58
+ end
59
+
7
60
  end
8
61
 
9
62
  end
10
63
 
11
- end
64
+ end
@@ -29,8 +29,24 @@ module GoTransverseTractApi
29
29
  GoTransverseTractApi.get_response_for(self, {billing_account_eid: billing_account_eid})
30
30
  end
31
31
 
32
+ #
33
+ # @param {Long} eid
34
+ # @param {Nokogiri::XML::Document} address
35
+ #
36
+ def self.add_address eid, address
37
+ GoTransverseTractApi.post_request_for(self, {eid: eid}, address.to_s, "addAddress")
38
+ end
39
+
40
+ #
41
+ # @param {Long} eid
42
+ # @param {Nokogiri::XML::Document} organization
43
+ #
44
+ def self.update eid, organization
45
+ GoTransverseTractApi.put_request_for(self, {eid: eid}, organization.to_s)
46
+ end
47
+
32
48
  end
33
49
 
34
50
  end
35
51
 
36
- end
52
+ end
@@ -4,6 +4,10 @@ module GoTransverseTractApi
4
4
 
5
5
  class PartyCategory
6
6
 
7
+ def self.find_all
8
+ GoTransverseTractApi.get_response_for(self)
9
+ end
10
+
7
11
  #
8
12
  # @param {Long} eid
9
13
  #
@@ -36,4 +40,4 @@ module GoTransverseTractApi
36
40
 
37
41
  end
38
42
 
39
- end
43
+ end
@@ -41,7 +41,7 @@ module GoTransverseTractApi
41
41
  # @param {Nokogiri::XML::Document} people
42
42
  #
43
43
  def self.update eid, people
44
- GoTransverseTractApi.put_response_for(self, {eid: eid}, people.to_s)
44
+ GoTransverseTractApi.put_request_for(self, {eid: eid}, people.to_s)
45
45
  end
46
46
 
47
47
  #
@@ -49,11 +49,27 @@ module GoTransverseTractApi
49
49
  # @param {Nokogiri::XML::Document} address
50
50
  #
51
51
  def self.add_address eid, address
52
- GoTransverseTractApi.post_response_for(self, {eid: eid}, address.to_s, "addAddress")
52
+ GoTransverseTractApi.post_request_for(self, {eid: eid}, address.to_s, "addAddress")
53
+ end
54
+
55
+ #
56
+ # @param {Long} eid
57
+ # @param {Nokogiri::XML::Document} person
58
+ #
59
+ def self.add_person eid, person
60
+ GoTransverseTractApi.post_request_for(self, {eid: eid}, person.to_s, "addPerson")
61
+ end
62
+
63
+ #
64
+ # @param {Long} eid
65
+ # @param {Nokogiri::XML::Document} person
66
+ #
67
+ def self.remove_person eid, person
68
+ GoTransverseTractApi.post_request_for(self, {eid: eid}, person.to_s, "removePerson")
53
69
  end
54
70
 
55
71
  end
56
72
 
57
73
  end
58
74
 
59
- end
75
+ end
@@ -4,8 +4,33 @@ module GoTransverseTractApi
4
4
 
5
5
  class ProductRelation
6
6
 
7
+ class << self
8
+
9
+ #
10
+ # @param {Long} eid
11
+ #
12
+ def find_by_eid eid
13
+ GoTransverseTractApi.get_response_for(self, {eid: eid})
14
+ end
15
+
16
+ #
17
+ # @param {Long} product_eid
18
+ #
19
+ def find_by_product_eid product_eid
20
+ GoTransverseTractApi.get_response_for(self, {product_eid: product_eid})
21
+ end
22
+
23
+ #
24
+ # @param {String} type
25
+ #
26
+ def find_by_type type
27
+ GoTransverseTractApi.get_response_for(self, {type: type})
28
+ end
29
+
30
+ end
31
+
7
32
  end
8
33
 
9
34
  end
10
35
 
11
- end
36
+ end
@@ -4,8 +4,82 @@ module GoTransverseTractApi
4
4
 
5
5
  class RenewalOrder
6
6
 
7
+ class << self
8
+
9
+ #
10
+ # @param {Long} eid
11
+ #
12
+ def find_by_eid eid
13
+ GoTransverseTractApi.get_response_for(self, {eid: eid})
14
+ end
15
+
16
+ #
17
+ # @param {Long} order_num
18
+ #
19
+ def find_by_order_num order_num
20
+ GoTransverseTractApi.get_response_for(self, {order_num: order_num})
21
+ end
22
+
23
+ #
24
+ # @param {Long} billing_account_eid
25
+ #
26
+ def find_by_billing_account_eid billing_account_eid
27
+ GoTransverseTractApi.get_response_for(self, {billing_account_eid: billing_account_eid})
28
+ end
29
+
30
+ #
31
+ # @param {Long} account_num
32
+ #
33
+ def find_by_account_num account_num
34
+ GoTransverseTractApi.get_response_for(self, {account_num: account_num})
35
+ end
36
+
37
+ #
38
+ # @param {Long} external_account_num
39
+ #
40
+ def find_by_external_account_num external_account_num
41
+ GoTransverseTractApi.get_response_for(self, {external_account_num: external_account_num})
42
+ end
43
+
44
+ #
45
+ # @param {Date} order_date
46
+ #
47
+ def find_by_order_date order_date
48
+ GoTransverseTractApi.get_response_for(self, {order_date: order_date})
49
+ end
50
+
51
+ #
52
+ # @param {String} referral
53
+ #
54
+ def find_by_referral referral
55
+ GoTransverseTractApi.get_response_for(self, {referral: referral})
56
+ end
57
+
58
+ #
59
+ # @param {Long} purchase_order_number
60
+ #
61
+ def find_by_purchase_order_number purchase_order_number
62
+ GoTransverseTractApi.get_response_for(self, {purchase_order_number: purchase_order_number})
63
+ end
64
+
65
+ #
66
+ # @param {Date} renewal_date
67
+ #
68
+ def find_by_renewal_date renewal_date
69
+ GoTransverseTractApi.get_response_for(self, {renewal_date: renewal_date})
70
+ end
71
+
72
+ #
73
+ # @param {Long} custom_field_value_eid
74
+ #
75
+ def find_by_custom_field_value_eid custom_field_value_eid
76
+ GoTransverseTractApi.get_response_for(self, {custom_field_value_eid: custom_field_value_eid})
77
+ end
78
+
79
+ end
80
+
7
81
  end
8
82
 
9
83
  end
10
84
 
11
- end
85
+ end
@@ -4,8 +4,124 @@ module GoTransverseTractApi
4
4
 
5
5
  class SalesOrder
6
6
 
7
+ class << self
8
+
9
+ #
10
+ # @param {Long} eid
11
+ #
12
+ def find_by_eid eid
13
+ GoTransverseTractApi.get_response_for(self, {eid: eid})
14
+ end
15
+
16
+ #
17
+ # @param {Long} order_num
18
+ #
19
+ def find_by_order_num order_num
20
+ GoTransverseTractApi.get_response_for(self, {order_num: order_num})
21
+ end
22
+
23
+ #
24
+ # @param {Long} billing_account_eid
25
+ #
26
+ def find_by_billing_account_eid billing_account_eid
27
+ GoTransverseTractApi.get_response_for(self, {billing_account_eid: billing_account_eid})
28
+ end
29
+
30
+ #
31
+ # @param {Long} account_num
32
+ #
33
+ def find_by_account_num account_num
34
+ GoTransverseTractApi.get_response_for(self, {account_num: account_num})
35
+ end
36
+
37
+ #
38
+ # @param {Long} external_account_num
39
+ #
40
+ def find_by_external_account_num external_account_num
41
+ GoTransverseTractApi.get_response_for(self, {external_account_num: external_account_num})
42
+ end
43
+
44
+ #
45
+ # @param {Date} order_date
46
+ #
47
+ def find_by_order_date order_date
48
+ GoTransverseTractApi.get_response_for(self, {order_date: order_date})
49
+ end
50
+
51
+ #
52
+ # @param {String} referral
53
+ #
54
+ def find_by_referral referral
55
+ GoTransverseTractApi.get_response_for(self, {referral: referral})
56
+ end
57
+
58
+ #
59
+ # @param {Long} purchase_order_num
60
+ #
61
+ def find_by_purchase_order_num purchase_order_num
62
+ GoTransverseTractApi.get_response_for(self, {purchase_order_num: purchase_order_num})
63
+ end
64
+
65
+ #
66
+ # @param {String} status
67
+ #
68
+ def find_by_status status
69
+ GoTransverseTractApi.get_response_for(self, {status: status})
70
+ end
71
+
72
+ #
73
+ # @param {Long} custom_field_value_eid
74
+ #
75
+ def find_by_custom_field_value_eid custom_field_value_eid
76
+ GoTransverseTractApi.get_response_for(self, {custom_field_value_eid: custom_field_value_eid})
77
+ end
78
+
79
+ #
80
+ # @param {Long} eid
81
+ # @param {Long} sequence
82
+ # @param {Nokogiri::XML::Document} sales_order
83
+ #
84
+ def approve eid, sequence, sales_order
85
+ GoTransverseTractApi.post_request_for(self, {eid: eid}, sales_order.to_s, "item/#{sequence}/approve")
86
+ end
87
+
88
+ #
89
+ # @param {Long} eid
90
+ # @param {Long} sequence
91
+ # @param {Nokogiri::XML::Document} sales_order
92
+ #
93
+ def deny eid, sequence, sales_order
94
+ GoTransverseTractApi.post_request_for(self, {eid: eid}, sales_order.to_s, "item/#{sequence}/deny")
95
+ end
96
+
97
+ #
98
+ # @param {Long} eid
99
+ # @param {Nokogiri::XML::Document} sales_order
100
+ #
101
+ def self.add_custom_field_value eid, sales_order
102
+ GoTransverseTractApi.post_request_for(self, {eid: eid}, sales_order.to_s, "addCustomFieldValue")
103
+ end
104
+
105
+ #
106
+ # @param {Long} eid
107
+ # @param {Nokogiri::XML::Document} sales_order
108
+ #
109
+ def self.remove_custom_field_value eid, sales_order
110
+ GoTransverseTractApi.post_request_for(self, {eid: eid}, sales_order.to_s, "removeCustomFieldValue")
111
+ end
112
+
113
+ #
114
+ # @param {Nokogiri::XML::Document} person
115
+ #
116
+ def self.create_sales_order sales_order
117
+ GoTransverseTractApi.post_request_for(self, {}, sales_order.to_s, "")
118
+ end
119
+
120
+
121
+ end
122
+
7
123
  end
8
124
 
9
125
  end
10
126
 
11
- end
127
+ end
@@ -1,6 +1,6 @@
1
1
  module GoTransverseTractApi
2
2
 
3
- VERSION = "0.1.2"
3
+ VERSION = "0.1.3"
4
4
  TARGET_API_VERSION = "1.28"
5
5
 
6
6
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gotransverse-tract-api
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2
4
+ version: 0.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Julien DeFrance