actv 2.6.0 → 2.7.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
  SHA1:
3
- metadata.gz: 00e49e36011201dab079ac5b7e1606aa7c22b01f
4
- data.tar.gz: a6cc5f93fa4675cb5d68618acbba1ff930dc45a5
3
+ metadata.gz: baad6f4f9c172d6d5793d213e26d3f6ffc5088c2
4
+ data.tar.gz: db3acfb70e93f8dbda52748b597eb389ea05dc8b
5
5
  SHA512:
6
- metadata.gz: 545f9a4a663cbb7964ff6787a150a9d8b21196d027c24f19e84fa84c844c0a2e034cecd48ac9e351abf58940f7847419b1c30bb6e4dc7678794b23741148d198
7
- data.tar.gz: a47b90797b772d7b2e70207928c4045e0f6d833861fa22db964c8a72c9fa3998fc0bb9739ffa4a2810aed3a0f9ff0d313821344ecac6c94e17d0d8ea6f0d7fb2
6
+ metadata.gz: 666a458842f2708b6be73bb81128d10e264f3a2c25f7e120b4b855df2fa59937658a0e35293da6d16cf8371db76bd2362958687dbe8a7c6c9569d2928e9dd4cc
7
+ data.tar.gz: ba25786369fd418dd75a924273d0912591556cc9c5a54267f2bfca19d9be13c13bc4037bb24769b03bf71328dae07bb1d64cccd39bfe6e9fc964b5d4d8cf6bad
data/.travis.yml CHANGED
@@ -5,4 +5,6 @@ rvm:
5
5
  - "2.1"
6
6
  - jruby-19mode # JRuby in 1.9 mode
7
7
  - rbx-19mode
8
+ before_install:
9
+ - gem update bundler
8
10
  script: bundle exec rspec spec
data/lib/actv/asset.rb CHANGED
@@ -12,9 +12,12 @@ require 'actv/asset_seo_url'
12
12
  require 'actv/identity'
13
13
  require 'actv/place'
14
14
  require 'actv/recurrence'
15
+ require 'actv/asset_source_system'
15
16
 
16
17
  module ACTV
17
18
  class Asset < ACTV::Identity
19
+ include AssetSourceSystem
20
+
18
21
  @types = []
19
22
 
20
23
  attr_reader :assetGuid, :assetName, :assetDsc, :activityStartDate, :activityStartTime, :activityEndDate, :activityEndTime,
@@ -214,62 +217,6 @@ module ACTV
214
217
  self.evergreenAssetFlag.downcase == 'true' rescue false
215
218
  end
216
219
 
217
- def regcenter?
218
- self.sourceSystem[:legacyGuid].upcase == "EA4E860A-9DCD-4DAA-A7CA-4A77AD194F65" rescue false
219
- end
220
-
221
- def regcenter2?
222
- self.sourceSystem[:legacyGuid].upcase == "3BF82BBE-CF88-4E8C-A56F-78F5CE87E4C6" rescue false
223
- end
224
-
225
- def awendurance?
226
- self.sourceSystem[:legacyGuid].upcase == "DFAA997A-D591-44CA-9FB7-BF4A4C8984F1" rescue false
227
- end
228
-
229
- def awsports?
230
- self.sourceSystem[:legacyGuid].upcase == "F036B0FF-2B21-43A9-8C20-7F447D3AB105" rescue false
231
- end
232
-
233
- def awcamps?
234
- self.sourceSystem[:legacyGuid].upcase == "2B22B4E6-5AA4-44D7-BF06-F7A71F9FA8A6" rescue false
235
- end
236
-
237
- def awcamps30?
238
- self.sourceSystem[:legacyGuid].upcase == "89208DBA-F535-4950-880A-34A6888A184C" rescue false
239
- end
240
-
241
- def thriva?
242
- self.sourceSystem[:legacyGuid].upcase == "2BA50ABA-080E-4E3D-A01C-1B4F56648A2E" rescue false
243
- end
244
-
245
- def activenet?
246
- self.sourceSystem[:legacyGuid].upcase == "FB27C928-54DB-4ECD-B42F-482FC3C8681F" rescue false
247
- end
248
-
249
- def researched?
250
- self.sourceSystem[:legacyGuid].upcase == "B47B0828-23ED-4D85-BDF0-B22819F53332" rescue false
251
- end
252
-
253
- def acm?
254
- self.sourceSystem[:legacyGuid].upcase == "CA4EA0B1-7377-470D-B20D-BF6BEA23F040" rescue false
255
- end
256
-
257
- def leagueone?
258
- self.sourceSystem[:legacyGuid].upcase == "74742258-90FE-40ED-8A60-89F21DE93BFD" rescue false
259
- end
260
-
261
- def tennislinkteam?
262
- self.sourceSystem[:legacyGuid].upcase == "0206DC72-C167-4B39-B299-0F2A27D8CBEF" rescue false
263
- end
264
-
265
- def tennislinktournament?
266
- self.sourceSystem[:legacyGuid].upcase == "71D917DE-FA90-448A-90DA-C8852F7E03E2" rescue false
267
- end
268
-
269
- def tennislinkusta?
270
- self.sourceSystem[:legacyGuid].upcase == "3858B6E3-B52E-4E20-9A00-2AD8500B1BC3" rescue false
271
- end
272
-
273
220
  def kids?
274
221
  kids_friendly_source_system? && kids_interest?
275
222
  end
@@ -448,9 +395,5 @@ module ACTV
448
395
  interests = meta_interests.to_a.map(&:downcase)
449
396
  ['kids', 'family'].any? { |tag| interests.include? tag }
450
397
  end
451
-
452
- def kids_friendly_source_system?
453
- activenet? || awcamps30? || acm? || researched? || leagueone? || tennislinkteam? || tennislinktournament? || tennislinkusta?
454
- end
455
398
  end
456
399
  end
@@ -0,0 +1,30 @@
1
+ module ACTV
2
+ module AssetSourceSystem
3
+ SOURCE_SYSTEM_HASH = {
4
+ regcenter: "EA4E860A-9DCD-4DAA-A7CA-4A77AD194F65",
5
+ regcenter2: "3BF82BBE-CF88-4E8C-A56F-78F5CE87E4C6",
6
+ awendurance: "DFAA997A-D591-44CA-9FB7-BF4A4C8984F1",
7
+ awsports: "F036B0FF-2B21-43A9-8C20-7F447D3AB105",
8
+ awcamps: "2B22B4E6-5AA4-44D7-BF06-F7A71F9FA8A6",
9
+ awcamps30: "89208DBA-F535-4950-880A-34A6888A184C",
10
+ thriva: "2BA50ABA-080E-4E3D-A01C-1B4F56648A2E",
11
+ activenet: "FB27C928-54DB-4ECD-B42F-482FC3C8681F",
12
+ researched: "B47B0828-23ED-4D85-BDF0-B22819F53332",
13
+ acm: "CA4EA0B1-7377-470D-B20D-BF6BEA23F040",
14
+ leagueone: "74742258-90FE-40ED-8A60-89F21DE93BFD",
15
+ tennislinkteam: "0206DC72-C167-4B39-B299-0F2A27D8CBEF",
16
+ tennislinktournament: "71D917DE-FA90-448A-90DA-C8852F7E03E2",
17
+ tennislinkusta: "3858B6E3-B52E-4E20-9A00-2AD8500B1BC3"
18
+ }
19
+
20
+ SOURCE_SYSTEM_HASH.each_pair do |name, source_system_id|
21
+ define_method "#{name}?" do
22
+ sourceSystem[:legacyGuid].upcase == source_system_id rescue false
23
+ end
24
+ end
25
+
26
+ def kids_friendly_source_system?
27
+ activenet? || awcamps30? || acm? || researched? || leagueone? || tennislinkteam? || tennislinktournament? || tennislinkusta? || awendurance?
28
+ end
29
+ end
30
+ end
data/lib/actv/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module ACTV
2
- VERSION = "2.6.0"
2
+ VERSION = "2.7.0"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: actv
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.6.0
4
+ version: 2.7.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nathaniel Barnes
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-01-08 00:00:00.000000000 Z
11
+ date: 2016-01-27 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday
@@ -266,6 +266,7 @@ files:
266
266
  - lib/actv/asset_price.rb
267
267
  - lib/actv/asset_reference.rb
268
268
  - lib/actv/asset_seo_url.rb
269
+ - lib/actv/asset_source_system.rb
269
270
  - lib/actv/asset_stats_result.rb
270
271
  - lib/actv/asset_status.rb
271
272
  - lib/actv/asset_tag.rb
@@ -413,7 +414,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
413
414
  version: '0'
414
415
  requirements: []
415
416
  rubyforge_project:
416
- rubygems_version: 2.4.3
417
+ rubygems_version: 2.0.14
417
418
  signing_key:
418
419
  specification_version: 4
419
420
  summary: Active API