scrivito_sdk 0.30.0.rc1 → 0.30.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: fbff45be246233cd7451a407ed46408c36322d0d
4
- data.tar.gz: fb419781d2d22902ebf33cac737e83aab5fab40e
3
+ metadata.gz: fd0c1ffc8470dc6f7ca27d29bd2d635ceae5c5a1
4
+ data.tar.gz: 588a8a4d6d2628c11a5925ea7020bd2267f4b3f5
5
5
  SHA512:
6
- metadata.gz: 688e86b1a099cc1a3dd3c53817be88772167f87fb28fb27c9f5c3aa513bcafff5170a62df30dd174a0d95d103834f6c25871d350d2c3c8d2b2c8d7276b957f4b
7
- data.tar.gz: abcea67939882a5911bde30834f84f854397a00fe26ec123f3bba27ad276e19177e507f29d04fff5517ab3e55cdfc3f7cb73e58d60a7b7cf533a147510719246
6
+ metadata.gz: 62b5c246878323c56f14dd6851ab1f237734d69789df04174a08f9a5b8aadb78c59318c79cd136405752a381713fd50aaea949611402ed4c6437236d570469da
7
+ data.tar.gz: fca203f4ff776702065138977207743d0a7cdbe99235d01a0f3ee523d8d3119624771cec4c8e85ea88d46d5ece989a684e1ea4d8ffe2f504d49160c286ddf0d4
@@ -78,17 +78,18 @@ module ScrivitoHelper
78
78
  end
79
79
 
80
80
  #
81
- # Calculates an HTML image tag of an image storeg in the CMS for inplace editing.
81
+ # Calculates an HTML image tag of an image stored in the CMS for inplace editing.
82
82
  #
83
83
  # @api public
84
84
  #
85
85
  # @note If you do not specify an HTML +alt+ attribute, the helper method will use
86
86
  # +display_title+ of the target object
87
87
  #
88
- # @param [Obj] obj Obj with an attribute of type +LinkList+
89
- # @param [String, Symbol] field_name Name of +LinkList+, +reference+ or +link+ attribute,
90
- # which contains the image
91
- # @param [Hash] tag_options Additional HTML attributes for the tag
88
+ # @param [Obj] obj Obj with a +link_list+, +reference+, +link+ or +binary+ attribute
89
+ # @param [String, Symbol, Hash] field_name_or_tag_options Name of +link_list+, +reference+, +link+, or +binary+
90
+ # attribute, which contains the image or additional HTML attributes for the tag
91
+ # @param [Hash] tag_or_editing_options Additional HTML attributes for the tag or
92
+ # the editing options if no +field_name+ was given
92
93
  # @param [Hash] editing_options Additional options for inplace editing
93
94
  # @option editing_options [String] :placeholder ('/assets/scrivito/image_placeholder.png') URL
94
95
  # or path to image to be displayed if target is missing
@@ -99,17 +100,33 @@ module ScrivitoHelper
99
100
  # scrivito_image_tag @obj, :my_linklist, {}, placeholder: image_path('my_placeholder.png')
100
101
  # scrivito_image_tag @obj, :my_linklist, {class: 'my_image'}, placeholder: 'http://placehold.it/350x150'
101
102
  #
102
- # @example Create image tag for reference attributes.
103
+ # @example Create image tag for a reference attribute.
103
104
  # scrivito_image_tag @obj, :my_reference
104
105
  #
105
- # @example Create image tag for link attributes.
106
+ # @example Create image tag for a link attribute.
106
107
  # scrivito_image_tag @obj, :my_link
107
108
  #
109
+ # @example Create image tag for a binary attribute
110
+ # scrivito_image_tag @obj, :my_binary
111
+ #
112
+ # @example Create image tag for a binary object
113
+ # scrivito_image_tag @image
114
+ #
108
115
  # @return [String] HTML image tag
109
116
  #
110
- def scrivito_image_tag(obj, field_name, tag_options = {}, editing_options = {})
117
+ # @raise [ScrivitoError] if +field_name+ is not set and obj is not binary
118
+ #
119
+ def scrivito_image_tag(obj, field_name_or_tag_options=nil,
120
+ tag_or_editing_options = {}, editing_options = {})
121
+ field_name, tag_options, editing_options =
122
+ if field_name_or_tag_options.is_a?(Hash)
123
+ [nil, field_name_or_tag_options, tag_or_editing_options]
124
+ else
125
+ [field_name_or_tag_options, tag_or_editing_options, editing_options]
126
+ end
127
+
111
128
  options = Scrivito::ImageTagHelper.new(self).options(obj, field_name,
112
- tag_options.symbolize_keys, editing_options.symbolize_keys)
129
+ tag_options.with_indifferent_access, editing_options.with_indifferent_access)
113
130
  scrivito_tag('img', obj, field_name, options)
114
131
  end
115
132
 
@@ -14802,12 +14802,7 @@ var scrivito = {};
14802
14802
  };
14803
14803
 
14804
14804
  var build_cms_element = function(dom_element) {
14805
- var cms_element = scrivito.cms_element.from_dom_element(dom_element);
14806
- if (cms_element) {
14807
- return cms_element;
14808
- } else {
14809
- $.error('Can not call "scrivito" method on a non-cms tag');
14810
- }
14805
+ return scrivito.cms_element.from_dom_element(dom_element);
14811
14806
  };
14812
14807
 
14813
14808
  var save_content = function(dom_element, content) {
@@ -14846,19 +14841,24 @@ var scrivito = {};
14846
14841
  };
14847
14842
  };
14848
14843
 
14849
- // @api public
14850
- $.fn.scrivito = function(method, content) {
14851
- switch (method) {
14852
- case 'save':
14853
- return save_content($(this), content);
14854
- case 'content':
14855
- return get_original_content($(this));
14856
- case 'menu':
14857
- return get_menu($(this));
14858
- default:
14859
- $.error('Unknown method "' + method + '"');
14844
+ $.extend(scrivito, {
14845
+ // @api public
14846
+ jquery_plugin: function(method, content) {
14847
+ switch (method) {
14848
+ case 'save':
14849
+ return save_content($(this), content);
14850
+ case 'content':
14851
+ return get_original_content($(this));
14852
+ case 'menu':
14853
+ return get_menu($(this));
14854
+ default:
14855
+ $.error('Unknown method "' + method + '"');
14856
+ }
14860
14857
  }
14861
- };
14858
+ });
14859
+
14860
+ $.fn.scrivito = scrivito.jquery_plugin;
14861
+
14862
14862
  }());
14863
14863
  (function() {
14864
14864
  var callbacks = {};
@@ -15925,6 +15925,8 @@ $(function() {
15925
15925
  scrivito.cms_element.definitions.push(scrivito.child_list_element);
15926
15926
  });
15927
15927
  (function() {
15928
+ var expando = "scrivito_cms_element";
15929
+
15928
15930
  $.extend(scrivito, {
15929
15931
  cms_element: {
15930
15932
  create_instance: function(dom_element) {
@@ -15955,13 +15957,27 @@ $(function() {
15955
15957
  },
15956
15958
 
15957
15959
  from_dom_element: function(dom_element) {
15958
- var cms_element = scrivito.cms_element.create_instance(dom_element);
15960
+ if (!dom_element || !dom_element.jquery || dom_element.length === 0) {
15961
+ $.error("Expected a jquery instance with exactly one element, " +
15962
+ "instead got " + dom_element);
15963
+ }
15959
15964
 
15960
- var instance;
15961
- _.find(scrivito.cms_element.definitions, function(definition) {
15962
- instance = definition.create_instance(cms_element);
15963
- return instance;
15964
- });
15965
+ var instance = dom_element[0][expando];
15966
+
15967
+ if (!instance) {
15968
+ var cms_element = scrivito.cms_element.create_instance(dom_element);
15969
+
15970
+ _.find(scrivito.cms_element.definitions, function(definition) {
15971
+ instance = definition.create_instance(cms_element);
15972
+ return instance;
15973
+ });
15974
+
15975
+ if (!instance) {
15976
+ $.error("This dom element is not a scrivito tag.");
15977
+ }
15978
+
15979
+ dom_element[0][expando] = instance;
15980
+ }
15965
15981
 
15966
15982
  return instance;
15967
15983
  },
@@ -6,8 +6,7 @@ module Scrivito
6
6
  source_root File.expand_path('../templates', __FILE__)
7
7
 
8
8
  def self.next_migration_number(dirname)
9
- migration_number = current_migration_number(dirname) + 1
10
- [Time.now.utc.strftime('%Y%m%d%H%M%S'), '%.14d' % migration_number].max
9
+ Scrivito::Migration.next_migration_number(current_migration_number(dirname))
11
10
  end
12
11
 
13
12
  def copy_initializer
@@ -24,8 +23,8 @@ module Scrivito
24
23
  end
25
24
 
26
25
  def copy_migration
27
- destination_path = File.join(Scrivito::Configuration.migration_path, 'install_scrivito.rb')
28
- migration_template 'scrivito/migrate/install_scrivito.rb', destination_path
26
+ migration_template 'scrivito/migrate/install_scrivito_migration.rb',
27
+ File.join(Scrivito::Configuration.migration_path, 'install_scrivito_migration.rb')
29
28
  end
30
29
 
31
30
  def copy_page_resources
@@ -3,7 +3,7 @@
3
3
 
4
4
  <%= scrivito_tag_list :ul, Obj.homepage, :toclist do |list, page| %>
5
5
  <%= list.tag :li do %>
6
- <%= link_to page[:title].presence || '(Untitled)', scrivito_path(page) %>
6
+ <%= link_to page.display_title, scrivito_path(page) %>
7
7
  <% end %>
8
8
  <% end %>
9
9
 
@@ -1,4 +1,4 @@
1
- class InstallScrivito < Scrivito::Migration
1
+ class InstallScrivitoMigration < Scrivito::Migration
2
2
  def up
3
3
  Scrivito::ObjClass.create(name: 'Page', attributes: [
4
4
  {name: 'title', type: 'string'},
@@ -1,16 +1,18 @@
1
1
  module Scrivito
2
- class MigrationGenerator < ::Rails::Generators::NamedBase
3
- include ::Rails::Generators::Migration
2
+ module Generators
3
+ class MigrationGenerator < ::Rails::Generators::NamedBase
4
+ include ::Rails::Generators::Migration
4
5
 
5
- source_root File.expand_path('../templates', __FILE__)
6
+ source_root File.expand_path('../templates', __FILE__)
6
7
 
7
- def self.next_migration_number(dirname)
8
- Time.now.utc.strftime('%Y%m%d%H%M%S')
9
- end
8
+ def self.next_migration_number(dirname)
9
+ Scrivito::Migration.next_migration_number(current_migration_number(dirname))
10
+ end
10
11
 
11
- def create_migration_file
12
- base_path = Scrivito::Configuration.migration_path
13
- migration_template('migration.erb', File.join(base_path, "#{file_name}.rb"))
12
+ def generate_migration
13
+ migration_template 'migration.erb',
14
+ File.join(Scrivito::Configuration.migration_path, "#{file_name}_migration.rb")
15
+ end
14
16
  end
15
17
  end
16
18
  end
@@ -1,4 +1,4 @@
1
- class <%= class_name %> < ::Scrivito::Migration
1
+ class <%= class_name %>Migration < ::Scrivito::Migration
2
2
  def up
3
3
  # This migration file allows to create and modify object class definitions or to change the CMS
4
4
  # content programatically. All Scrivito SDK classes and methods are available and arbitrary Ruby
@@ -15,7 +15,7 @@ class <%= class_name %> < ::Scrivito::Migration
15
15
  # To get you started, here is a list of the most common SDK methods to alter the CMS content.
16
16
  #
17
17
  # @example Create a new non-binary obj class named "Homepage" that has a "string" attribute named "locale".
18
- # Scrivito::ObjClass.create(name: 'Homepage', is_binary: false, attributes: [
18
+ # Scrivito::ObjClass.create(name: 'Homepage', attributes: [
19
19
  # {name: 'locale', type: :string}
20
20
  # ])
21
21
  #
@@ -0,0 +1,32 @@
1
+ module Scrivito
2
+ module Generators
3
+ class PageGenerator < ::Rails::Generators::NamedBase
4
+ include ::Rails::Generators::Migration
5
+
6
+ source_root File.expand_path('../templates', __FILE__)
7
+
8
+ def self.next_migration_number(dirname)
9
+ Scrivito::Migration.next_migration_number(current_migration_number(dirname))
10
+ end
11
+
12
+ def create_model
13
+ template 'model.erb', "app/models/#{file_name}.rb"
14
+ end
15
+
16
+ def generate_migration
17
+ migration_template 'migration.erb',
18
+ File.join(Scrivito::Configuration.migration_path, "create_#{file_name}_migration.rb")
19
+ end
20
+
21
+ def create_controller
22
+ template 'controller.erb', "app/controllers/#{file_name}_controller.rb"
23
+ end
24
+
25
+ def create_views
26
+ copy_file 'index.html.erb', "app/views/#{file_name}/index.html.erb"
27
+ copy_file 'details.html.erb', "app/views/#{file_name}/details.html.erb"
28
+ template 'thumbnail.html.erb', "app/views/#{file_name}/thumbnail.html.erb"
29
+ end
30
+ end
31
+ end
32
+ end
@@ -0,0 +1,2 @@
1
+ class <%= class_name %>Controller < CmsController
2
+ end
@@ -0,0 +1 @@
1
+ <%= scrivito_tag :div, @obj, :title %>
@@ -0,0 +1,8 @@
1
+ <%= scrivito_tag_list :ul, @obj, :toclist do |list, child| %>
2
+ <%= list.tag :li do %>
3
+ <%= link_to child.display_title, scrivito_path(child) %>
4
+ <% end %>
5
+ <% end %>
6
+
7
+ <%= scrivito_tag :h1, @obj, :title %>
8
+ <%= scrivito_tag :div, @obj, :body %>
@@ -0,0 +1,9 @@
1
+ class Create<%= class_name %>Migration < ::Scrivito::Migration
2
+ def up
3
+ Scrivito::ObjClass.create(name: '<%= class_name %>', attributes: [
4
+ {name: 'title', type: :string},
5
+ {name: 'body', type: :widget},
6
+ {name: 'child_order', type: :referencelist},
7
+ ])
8
+ end
9
+ end
@@ -0,0 +1,9 @@
1
+ class <%= class_name %> < Obj
2
+ #
3
+ # = Scrivito Attributes
4
+ #
5
+ # title: string
6
+ # body: widget
7
+ # child_order: referencelist
8
+ #
9
+ end
@@ -0,0 +1,3 @@
1
+ <%%= scrivito_thumbnail '<%= class_name %>', :content do %>
2
+ <%= class_name %> Page
3
+ <%% end %>
@@ -1,12 +1,7 @@
1
- class Create<%= class_name %> < ::Scrivito::Migration
1
+ class Create<%= class_name %>Migration < ::Scrivito::Migration
2
2
  def up
3
- Scrivito::ObjClass.create(
4
- name: '<%= class_name %>',
5
- is_binary: false,
6
- title: '<%= class_name.underscore.humanize %>',
7
- # attributes: [
8
- # { name: 'example', type: :string },
9
- # ]
10
- )
3
+ Scrivito::ObjClass.create(name: '<%= class_name %>', attributes: [
4
+ # {name: 'example', type: :string},
5
+ ])
11
6
  end
12
7
  end
@@ -1,3 +1,3 @@
1
1
  <%%= scrivito_thumbnail '<%= class_name %>' do %>
2
- <% class_name %> Widget
2
+ <%= class_name %> Widget
3
3
  <%% end %>
@@ -6,25 +6,22 @@ module Scrivito
6
6
  source_root File.expand_path('../templates', __FILE__)
7
7
 
8
8
  def self.next_migration_number(dirname)
9
- max = current_migration_number(dirname)
10
- Scrivito::Migration.next_migration_number(max)
9
+ Scrivito::Migration.next_migration_number(current_migration_number(dirname))
11
10
  end
12
11
 
13
- def generate_model
14
- template('model.erb', "app/models/#{file_name}.rb")
12
+ def create_model
13
+ template 'model.erb', "app/models/#{file_name}.rb"
15
14
  end
16
15
 
17
- def generate_views
18
- path = "app/views/#{file_name}"
19
-
20
- template('show.html.erb', "#{path}/show.html.erb")
21
- template('details.html.erb', "#{path}/details.html.erb")
22
- template('thumbnail.html.erb', "#{path}/thumbnail.html.erb")
16
+ def create_views
17
+ template 'show.html.erb', "app/views/#{file_name}/show.html.erb"
18
+ template 'details.html.erb', "app/views/#{file_name}/details.html.erb"
19
+ template 'thumbnail.html.erb', "app/views/#{file_name}/thumbnail.html.erb"
23
20
  end
24
21
 
25
22
  def generate_migration
26
- base_path = Scrivito::Configuration.migration_path
27
- migration_template('migration.erb', File.join(base_path, "/create_#{file_name}.rb"))
23
+ migration_template 'migration.erb',
24
+ File.join(Scrivito::Configuration.migration_path, "create_#{file_name}_migration.rb")
28
25
  end
29
26
  end
30
27
  end
@@ -484,12 +484,9 @@ module Scrivito
484
484
  # handled differently in that they are not rendered using the normal layout
485
485
  # but sent as a file. Examples of binary resources are Images or PDFs.
486
486
  #
487
- # By default every Obj that has an attribute +blob+ of the type +binary+ is
487
+ # Every Obj that has an attribute +blob+ of the type +binary+ is
488
488
  # considered a binary
489
489
  #
490
- # @note you can override this method to indicate that an Obj is binary,
491
- # if the default behavior doesn't fit your needs
492
- #
493
490
  # @return true if this Obj represents a binary resource.
494
491
  def binary?
495
492
  if obj_type = read_attribute('_obj_type')
@@ -663,9 +660,9 @@ module Scrivito
663
660
  # This method is intended for Objs that represent binary resources like
664
661
  # images or pdf documents. If this Obj represents a binary file, an instance
665
662
  # of {Binary} is returned.
666
- # The default implementation returns the attribute "blob" (if available and
667
- # of type +binary+).
668
- # @note You may override this method in your subclasses.
663
+ #
664
+ # This method returns the attribute +blob+ if it is of the type +binary+.
665
+ #
669
666
  # @return [Binary, nil]
670
667
  def binary
671
668
  self[:blob] if self[:blob].is_a?(Binary)
@@ -46,6 +46,8 @@ class CmsRouting < Struct.new(:request, :main_app)
46
46
  else
47
47
  return LINK_TO_EMPTY_LINKLIST
48
48
  end
49
+ elsif target.is_a?(Binary)
50
+ target.url
49
51
  else
50
52
  raise "scrivito_path or scrivito_url was called with an instance of #{target.class}. "+
51
53
  "It must only be called with an Obj or a Link or a non-empty LinkList."
@@ -68,7 +70,7 @@ class CmsRouting < Struct.new(:request, :main_app)
68
70
  else
69
71
  if obj.binary? && editing_context.display_mode != "editing"
70
72
  if obj.binary_url
71
- self.class.match_protocol(obj.binary_url, request)
73
+ obj.binary_url
72
74
  else
73
75
  LINK_TO_EMPTY_BLOB
74
76
  end
@@ -4,19 +4,33 @@ class ImageTagHelper < Struct.new(:view_context)
4
4
 
5
5
  def self.display_title(target)
6
6
  if target.respond_to?(:display_title)
7
- return target.display_title
7
+ target.display_title
8
8
  elsif target.respond_to?(:first) && target.first.respond_to?(:display_title)
9
- return target.first.display_title
9
+ target.first.display_title
10
+ elsif target.respond_to?(:filename)
11
+ target.filename
10
12
  end
11
13
  end
12
14
 
13
15
  def options(obj, field_name, tag_options, editing_options)
16
+ if field_name.nil?
17
+ field_name = determine_field_name(obj)
18
+ end
19
+
14
20
  tag_options.reverse_merge(src: scrivito_image_tag_src(obj, field_name, editing_options),
15
21
  alt: scrivito_image_tag_alt(obj, field_name))
16
22
  end
17
23
 
18
24
  private
19
25
 
26
+ def determine_field_name(obj)
27
+ if obj.binary?
28
+ :blob
29
+ else
30
+ raise ScrivitoError, "when omitting `field_name' you have to pass a binary obj"
31
+ end
32
+ end
33
+
20
34
  def scrivito_image_tag_src(obj, field_name, editing_options)
21
35
  scrivito_image_tag_path(obj, field_name) || editing_options[:placeholder] ||
22
36
  view_context.image_path('scrivito/image_placeholder.png')
@@ -31,8 +45,8 @@ class ImageTagHelper < Struct.new(:view_context)
31
45
  field_value = obj[field_name]
32
46
 
33
47
  case field_type
34
- when 'reference' then field_value && view_context.scrivito_path(field_value)
35
- when 'link' then field_value && view_context.scrivito_path(field_value)
48
+ when 'link', 'binary', 'reference'
49
+ field_value && view_context.scrivito_path(field_value)
36
50
  when 'linklist'
37
51
  path = view_context.scrivito_path(field_value)
38
52
  path == CmsRouting::LINK_TO_EMPTY_LINKLIST ? nil : path
@@ -48,14 +48,9 @@ module Scrivito
48
48
  end
49
49
  end
50
50
 
51
- def next_migration_number(max)
52
- timestamp = Time.now.utc.strftime("%Y%m%d%H%M%S").to_i
53
-
54
- if max >= timestamp
55
- timestamp = max + 1
56
- end
57
-
58
- timestamp
51
+ def next_migration_number(current_migration_number)
52
+ migration_number = current_migration_number + 1
53
+ [Time.now.utc.strftime('%Y%m%d%H%M%S'), '%.14d' % migration_number].max
59
54
  end
60
55
  end
61
56
 
@@ -12,7 +12,7 @@ module Scrivito
12
12
  #
13
13
  # @api public
14
14
  #
15
- # @param target [Obj, Link, Array<Link>]
15
+ # @param target [Obj, Link, Array<Link>, Binary]
16
16
  # If +target+ is an +Array+ of +Links+, it must be non-empty.
17
17
  # The first {Link} from the +Array+ will be used.
18
18
  # @param options [Hash] include url settings such as path parameters or protocol.
@@ -28,7 +28,7 @@ module Scrivito
28
28
  #
29
29
  # @api public
30
30
  #
31
- # @param target [Obj, Link, Array<Link>]
31
+ # @param target [Obj, Link, Array<Link>, Binary]
32
32
  # If +target+ is an +Array+ of +Links+, it must be non-empty.
33
33
  # The first {Link} from the +Array+ will be used.
34
34
  # @param options [Hash] include url settings such as path parameters or protocol.
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: scrivito_sdk
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.30.0.rc1
4
+ version: 0.30.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Infopark AG
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-10-31 00:00:00.000000000 Z
11
+ date: 2014-11-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: addressable
@@ -225,10 +225,17 @@ files:
225
225
  - lib/generators/scrivito/install/templates/app/views/text_widget/show.html.erb
226
226
  - lib/generators/scrivito/install/templates/app/views/text_widget/thumbnail.html.erb
227
227
  - lib/generators/scrivito/install/templates/config/initializers/scrivito.rb
228
- - lib/generators/scrivito/install/templates/scrivito/migrate/install_scrivito.rb
228
+ - lib/generators/scrivito/install/templates/scrivito/migrate/install_scrivito_migration.rb
229
229
  - lib/generators/scrivito/migration/USAGE
230
230
  - lib/generators/scrivito/migration/migration_generator.rb
231
231
  - lib/generators/scrivito/migration/templates/migration.erb
232
+ - lib/generators/scrivito/page/page_generator.rb
233
+ - lib/generators/scrivito/page/templates/controller.erb
234
+ - lib/generators/scrivito/page/templates/details.html.erb
235
+ - lib/generators/scrivito/page/templates/index.html.erb
236
+ - lib/generators/scrivito/page/templates/migration.erb
237
+ - lib/generators/scrivito/page/templates/model.erb
238
+ - lib/generators/scrivito/page/templates/thumbnail.html.erb
232
239
  - lib/generators/scrivito/widget/templates/details.html.erb
233
240
  - lib/generators/scrivito/widget/templates/migration.erb
234
241
  - lib/generators/scrivito/widget/templates/model.erb
@@ -347,9 +354,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
347
354
  version: 2.0.0
348
355
  required_rubygems_version: !ruby/object:Gem::Requirement
349
356
  requirements:
350
- - - '>'
357
+ - - '>='
351
358
  - !ruby/object:Gem::Version
352
- version: 1.3.1
359
+ version: '0'
353
360
  requirements: []
354
361
  rubyforge_project:
355
362
  rubygems_version: 2.2.2