ack_rocket_cms 0.7.5.1 → 0.7.5.2

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: 8a54f2f0a203569ea4c0b9d28e1b922ff781b87d
4
- data.tar.gz: a71430c56911ca3ff01418e83d4ab2ceb4095397
3
+ metadata.gz: ec774db647ab685e73a3a63f4c747cdabd10d317
4
+ data.tar.gz: d1ce5bc5c4bc708298f4ae8cb39733b586f4f32b
5
5
  SHA512:
6
- metadata.gz: 71d4e0849d89ba93af2786866f20e522178fdb570ed95fba9630b06af77d945e653dc4603495fd2422d5fb9a762d5c9bbd5001e6b8d7ee6ad9a1ff88e10ad20e
7
- data.tar.gz: 559d5e4a7a44bd81e7f6c576d8d77a36b199744ea11cf9bfcb00f5fa9c014b9be5cdeaf1f3509bce458a10cc6a1e9a893028a93bb8225422070f80f176add37a
6
+ metadata.gz: 1f44ad69726b3e48315c87872d1c3a104462ce3cba439b741e2a83e86e1c434dd2fde86821d7cd435480971a0ce46ede0f401bea1836084079835d5bb907f008
7
+ data.tar.gz: 4355ee4cebe1a84442e3948ded4b834e765a32b2fc85798535647889c6cb537e01854289f118e51793dcf5bcd1087049f0a645dbd5207d98f8c77057f3639415
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- ack_rocket_cms (0.7.5.1)
4
+ ack_rocket_cms (0.7.5.2)
5
5
  addressable
6
6
  ckeditor
7
7
  coffee-rails
@@ -203,7 +203,7 @@ GEM
203
203
  sprockets (>= 2.8, < 4.0)
204
204
  sprockets-rails (>= 2.0, < 4.0)
205
205
  tilt (~> 1.1)
206
- simple-navigation (3.14.0)
206
+ simple-navigation (4.0.1)
207
207
  activesupport (>= 2.3.2)
208
208
  simple_form (3.1.0)
209
209
  actionpack (~> 4.0)
@@ -14,6 +14,7 @@ en:
14
14
  sitemap_data: 'Sitemap data'
15
15
  edit: Edit
16
16
  send: Send
17
+ format_time: "%-m/%-d/%Y"
17
18
  m:
18
19
  enabled: 'added to menu "%{menu}"'
19
20
  disabled: 'deleted from menu "%{menu}"'
@@ -14,6 +14,7 @@ ru:
14
14
  sitemap_data: 'Данные для карты сайта'
15
15
  edit: Редактировать
16
16
  send: Отправить
17
+ format_time: "%d.%m.%Y"
17
18
  m:
18
19
  enabled: 'добавлено в меню "%{menu}"'
19
20
  disabled: 'удалено из меню "%{menu}"'
@@ -31,7 +31,7 @@ module RocketCMS
31
31
  }
32
32
  end
33
33
 
34
- def page_config
34
+ def page_config(fields = {})
35
35
  Proc.new {
36
36
  RocketCMS.apply_patches self
37
37
  navigation_label I18n.t('rs.cms')
@@ -69,6 +69,13 @@ module RocketCMS
69
69
  end
70
70
  field :text_slug
71
71
  end
72
+ fields.each_pair do |name, type|
73
+ if type.nil?
74
+ field name
75
+ else
76
+ field name, type
77
+ end
78
+ end
72
79
  group :seo, &RocketCMS.seo_config
73
80
  group :sitemap_data, &RocketCMS.sitemap_data_config
74
81
  end
@@ -108,7 +115,7 @@ module RocketCMS
108
115
  }
109
116
  end
110
117
 
111
- def news_config
118
+ def news_config(fields = {})
112
119
  Proc.new {
113
120
  navigation_label I18n.t('rs.cms')
114
121
  list do
@@ -139,6 +146,13 @@ module RocketCMS
139
146
 
140
147
  edit do
141
148
  field :content, :ck_editor
149
+ fields.each_pair do |name, type|
150
+ if type.nil?
151
+ field name
152
+ else
153
+ field name, type
154
+ end
155
+ end
142
156
  RocketCMS.apply_patches self
143
157
  group :seo, &RocketCMS.seo_config
144
158
  group :sitemap_data, &RocketCMS.sitemap_data_config
@@ -180,12 +194,10 @@ module RocketCMS
180
194
  }
181
195
  end
182
196
 
183
- def embedded_image_config
197
+ def embedded_image_config(fields = {})
184
198
  RocketCMS.embedded_element_config(
185
199
  nil,
186
- {
187
- image: nil
188
- }
200
+ {image: nil}.merge(fields)
189
201
  )
190
202
  end
191
203
 
@@ -212,7 +224,7 @@ module RocketCMS
212
224
  }
213
225
  end
214
226
 
215
- def image_config(without_gallery = false)
227
+ def image_config(without_gallery = false, fields = {})
216
228
  Proc.new {
217
229
  navigation_label I18n.t('rs.gallery')
218
230
  field :enabled, :toggle
@@ -221,6 +233,13 @@ module RocketCMS
221
233
  end
222
234
  field :name, :string
223
235
  field :image
236
+ fields.each_pair do |name, type|
237
+ if type.nil?
238
+ field name
239
+ else
240
+ field name, type
241
+ end
242
+ end
224
243
  }
225
244
  end
226
245
  end
@@ -42,7 +42,7 @@ module RocketCMS
42
42
  time.strftime('%Y-%m-%d')
43
43
  end
44
44
  def format_date
45
- time.strftime('%d.%m.%Y')
45
+ time.strftime(I18n.t('rs.format_time'))
46
46
  end
47
47
  end
48
48
  end
@@ -1,3 +1,3 @@
1
1
  module RocketCMS
2
- VERSION = "0.7.5.1"
2
+ VERSION = "0.7.5.2"
3
3
  end
data/template.rb CHANGED
@@ -95,7 +95,7 @@ create_file '.gitignore' do <<-TEXT
95
95
  /log/*.log
96
96
  /tmp/*
97
97
  /public/assets
98
- /public/ckeditor
98
+ /public/ckeditor_assets
99
99
  TEXT
100
100
  end
101
101
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ack_rocket_cms
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.7.5.1
4
+ version: 0.7.5.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - glebtv
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2015-04-02 00:00:00.000000000 Z
12
+ date: 2015-04-06 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: bundler