stbaldricks 4.1.0 → 4.2.0

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: 336cd76e0bcf54005d5e887e6f6afb31306fec42
4
- data.tar.gz: 533e2e92c77acd554e356f66c87e4690f25ad523
3
+ metadata.gz: c94c5f49f5f3c5fda4ed688cef55f67fdfad14d3
4
+ data.tar.gz: bc14f9659a826452313431588104d9bc517a187f
5
5
  SHA512:
6
- metadata.gz: 47a7675ffcf537a25ca5b92b440c8afb70c6d81b9c41a7eee133830e0a24284c996a5decbe32979fe7ae086e056eed729808207842fc737b7e08224ff4aefec8
7
- data.tar.gz: 5595a3ad9d7ae8e5f47370e4a9fa4a3a91eb1cbaa225c204874523f9c2a648f3aa7fd8ba3abd9265f7ca7cac7cf078fef9464fa30a87958ea7971b6ab5b8ff6b
6
+ metadata.gz: 32856f5b3cb6a973fcd8753304f76ce51c069ba8f86c2e60f803f34b6ed29a257959ec79431a632c1a81faecd0e907a5f474fea6a2e6e597dcd1a3dfc8f61aa7
7
+ data.tar.gz: 98e3052a8616492e38e080363444721b8cb2b3ac2b1370edf954aa97ced091d5e43b5d89319927777d7dbde65937f418180408d55f534a8b9b4ecc70c93f2187
@@ -22,6 +22,13 @@ module SBF
22
22
  PENDING = 'pending'
23
23
  end
24
24
 
25
+ module Category
26
+ ATHLETICS = 'athletics'
27
+ CELEBRATION = 'celebration'
28
+ SALE = 'sale'
29
+ OTHER = 'other'
30
+ end
31
+
25
32
  module HowCreated
26
33
  WEBSITE = 'website'
27
34
  ADMIN_CONTROL_PANEL = 'admin_control_panel'
@@ -76,6 +83,19 @@ module SBF
76
83
  HTMLEntities.new.decode(@name)
77
84
  end
78
85
  end
86
+
87
+ class FullEvent < SBF::Client::FullEvent; end
88
+
89
+ class PartialEvent < SBF::Client::PartialEvent
90
+ def to_hash
91
+ entity_hash = super
92
+
93
+ # Fundraisers do not require an event but are still reliant on an event year
94
+ entity_hash.delete(:id) if id.nil?
95
+
96
+ entity_hash
97
+ end
98
+ end
79
99
  end
80
100
 
81
101
  class PartialFundraiser < Fundraiser
@@ -86,15 +106,16 @@ module SBF
86
106
  attr_accessor :id
87
107
  attr_accessor :status
88
108
  attr_accessor :title
109
+ attr_accessor :category
89
110
  attr_accessor :display_name_override
90
111
  attr_reader :display_name
91
- entity_attr_accessor :owner, 'SBF::Client::FullPerson'
112
+ entity_attr_accessor :owner, 'SBF::Client::FullPerson', 'SBF::Client::PartialPerson'
92
113
  attr_accessor :start_date, :end_date
93
114
  attr_accessor :start_time, :end_time
94
115
  attr_accessor :offline_donation_uuid, :offline_donation_form
95
116
  attr_accessor :fundraising_goal, :fundraising_message
96
117
  entity_attr_accessor :fundraising_page, 'SBF::Client::FundraisingPage', nil, true
97
- entity_attr_accessor :event, 'SBF::Client::FullEvent', 'SBF::Client::PartialEvent', true
118
+ entity_attr_accessor :event, 'SBF::Client::Fundraiser::FullEvent', 'SBF::Client::Fundraiser::PartialEvent', true
98
119
  entity_attr_accessor :team, 'SBF::Client::FullTeam', 'SBF::Client::PartialTeam', true
99
120
  entity_attr_accessor :fund, 'SBF::Client::FullFund', 'SBF::Client::PartialFund', true
100
121
  attr_accessor :fund_relationship_type
@@ -1,5 +1,5 @@
1
1
  module SBF
2
2
  module Client
3
- VERSION = '4.1.0'
3
+ VERSION = '4.2.0'
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: stbaldricks
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.1.0
4
+ version: 4.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Firespring
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-09-01 00:00:00.000000000 Z
11
+ date: 2017-09-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activemodel
@@ -215,7 +215,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
215
215
  version: '0'
216
216
  requirements: []
217
217
  rubyforge_project:
218
- rubygems_version: 2.6.13
218
+ rubygems_version: 2.6.12
219
219
  signing_key:
220
220
  specification_version: 4
221
221
  summary: St. Baldrick's Foundation Ruby Client Library