govuk_content_models 43.0.1 → 43.1.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: 54b7d713506a0afb97612ae9222dbbbce18e8f07
4
- data.tar.gz: 04fe73a18bf538aa18919191dda6922b96d375fa
3
+ metadata.gz: 410586eb880e0e1c9d3863f8af2a96e449fae543
4
+ data.tar.gz: d998db618fbd7add4adbec1f39ba80a1f8d6bd26
5
5
  SHA512:
6
- metadata.gz: 87a0c5f42cb3d6536ff9a7df7681cd648e8ede6b6f79965f3d2868b6a4348a71e8a3e648ba61543249e0aef78dade031415613542939adc826cf7c199ab3d421
7
- data.tar.gz: 4b18ffb4d9babfcd4415a15af0b0fd3a49fb1ec138ea2d91a39234a695be245ccf1f5a3136572b720c31fa7bd524c6268498ceeff968c0ed529d37f6c84488f7
6
+ metadata.gz: 1779b8d48794e322128b9e5afa911411ce376ec62e08997587c5a1f7d24b05a6bde14bb262080cf81b6d04a7b6f7caf2634383767f0ba081cebdf5a2671437a6
7
+ data.tar.gz: d527048768ab9857204e9b69266b27d3b4ac6c5dbf92dc7abccfe80351cccdee0201b615cd0a5682e362d5794d8c7a2fab38d337c517110c5ddccc34633d3377
data/CHANGELOG.md CHANGED
@@ -1,5 +1,9 @@
1
1
  # CHANGELOG
2
2
 
3
+ ## 43.1.0
4
+
5
+ - Add list of retired formats to Artefact
6
+
3
7
  ## 43.0.1
4
8
 
5
9
  - Expose the display_start_time of a Downtime object
@@ -118,6 +118,8 @@ class Artefact
118
118
  "written_statement"],
119
119
  }.freeze
120
120
 
121
+ RETIRED_FORMATS = ["video"]
122
+
121
123
  FORMATS = FORMATS_BY_DEFAULT_OWNING_APP.values.flatten
122
124
 
123
125
  def self.default_app_for_format(format)
@@ -100,9 +100,14 @@ class Edition
100
100
  end
101
101
 
102
102
  def can_create_new_edition?
103
+ return false if retired_format?
103
104
  !scheduled_for_publishing? && subsequent_siblings.in_progress.empty?
104
105
  end
105
106
 
107
+ def retired_format?
108
+ Artefact::RETIRED_FORMATS.include? format.downcase
109
+ end
110
+
106
111
  def major_updates_in_series
107
112
  history.published.major_updates
108
113
  end
@@ -1,4 +1,4 @@
1
1
  module GovukContentModels
2
2
  # Changing this causes Jenkins to tag and release the gem into the wild
3
- VERSION = "43.0.1"
3
+ VERSION = "43.1.0"
4
4
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: govuk_content_models
3
3
  version: !ruby/object:Gem::Version
4
- version: 43.0.1
4
+ version: 43.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Paul Battley
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-03-13 00:00:00.000000000 Z
11
+ date: 2017-03-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bson_ext