social_stream-base 0.10.11 → 0.11.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -12,7 +12,7 @@ class User < ActiveRecord::Base
12
12
  :foreign_key => :user_author_id
13
13
 
14
14
  # Setup accessible (or protected) attributes for your model
15
- attr_accessible :name, :email, :password, :password_confirmation, :remember_me, :profile_attributes
15
+ attr_accessible :name, :email, :password, :password_confirmation, :language, :remember_me, :profile_attributes
16
16
 
17
17
  validates_presence_of :email
18
18
 
@@ -85,3 +85,29 @@ $(".user_edit").validate({errorClass: "validation_error"});
85
85
  <% end%>
86
86
  </div>
87
87
  </div>
88
+ <div class="block" id="lang_form">
89
+ <div class="header">
90
+ <div class="header_text">
91
+ <%= t("account.lang.change")%>
92
+ </div>
93
+ <div class="header_icon_right">
94
+ <%= link_to (image_tag('btn/edit.png')), "javascript:showSettings(\"lang_form\");" %>
95
+ </div>
96
+ </div>
97
+ <div id="lang_form_briefing" class="settings_briefing content">
98
+ <div class="form_row">
99
+ <%= t('settings.lang_change.briefing')%>
100
+ </div>
101
+ </div>
102
+ <div class="content settings_content" id="lang_form_content" style="display:none;">
103
+ <%= form_for(resource, :as => resource_name, :url => registration_path(resource_name), :html => { :method => :put, :id => 'form_lang' }) do |f| %>
104
+ <div class="form_row">
105
+ <div class="form_label"><%= f.label :language %></div>
106
+ <div class="form_field">
107
+ <%= f.select :language, I18n.available_locales.map{|l| [ l.to_s, l.to_s ] }, { }, { :class => 'form_lang', :onchange => "$(\'#form_lang\').submit();" } %>
108
+ </div>
109
+ </div>
110
+ <% end%>
111
+ </div>
112
+ </div>
113
+
@@ -18,4 +18,5 @@
18
18
  <%= render :partial => "settings/api_key" %>
19
19
  <% end %>
20
20
  <%= render :partial => "settings/contacts" %>
21
- <%= render :partial => "delete_account"%>
21
+ <%= render :partial => "delete_account"%>
22
+
@@ -11,9 +11,9 @@
11
11
  </div>
12
12
  <div class="activity_objects">
13
13
  <%= link_to post do%>
14
- <% text = excerpt(strip_tags(post.text),get_search_query_words.first,:radius => 180) %>
14
+ <% text = excerpt(strip_tags(post.text),get_search_query_words.first,:radius => 180) || "" %>
15
15
  <% if text.length < 400 %>
16
- <% text = excerpt(strip_tags(post.text),get_search_query_words.first,:radius => 540 - text.length) %>
16
+ <% text = excerpt(strip_tags(post.text),get_search_query_words.first,:radius => 540 - text.length) || "" %>
17
17
  <% end %>
18
18
  <%= highlight(text,get_search_query_words) %>
19
19
  <% end %>
@@ -6,9 +6,9 @@
6
6
  <div class="sub-block">
7
7
  <div class="brief">
8
8
  <%= link_to post do%>
9
- <% text = excerpt(strip_tags(post.text),get_search_query_words.first,:radius => 25) %>
9
+ <% text = excerpt(strip_tags(post.text),get_search_query_words.first,:radius => 25) || "" %>
10
10
  <% if text.length < 60 %>
11
- <% text = excerpt(strip_tags(post.text),get_search_query_words.first,:radius => 30 + (60 - text.length)) %>
11
+ <% text = excerpt(strip_tags(post.text),get_search_query_words.first,:radius => 30 + (60 - text.length)) || "" %>
12
12
  <% end %>
13
13
  <%= highlight(text,get_search_query_words) %>
14
14
  <% end %>
@@ -9,6 +9,8 @@ en:
9
9
  edit: "Edit account"
10
10
  email:
11
11
  change: "Change email address"
12
+ lang:
13
+ change: "Change language"
12
14
  one: "Account"
13
15
  password:
14
16
  change: "Change password"
@@ -429,6 +431,8 @@ en:
429
431
  briefing: "Lets you cancel your account"
430
432
  email_change:
431
433
  briefing: "Change your email"
434
+ lang_change:
435
+ briefing: "Change your language"
432
436
  error: "Some errors raised when saving your changes"
433
437
  for: "Settings for"
434
438
  main: "Settings"
@@ -0,0 +1,13 @@
1
+ class AddLanguageField < ActiveRecord::Migration
2
+ def self.up
3
+ change_table "users" do |t|
4
+ t.string "language", :default => "en"
5
+ end
6
+ end
7
+
8
+ def self.down
9
+ change_table :users do |t|
10
+ t.remove "language"
11
+ end
12
+ end
13
+ end
@@ -1,5 +1,5 @@
1
1
  module SocialStream
2
2
  module Base
3
- VERSION = "0.10.11".freeze
3
+ VERSION = "0.11.0".freeze
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: social_stream-base
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.10.11
4
+ version: 0.11.0
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -10,11 +10,11 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2011-12-19 00:00:00.000000000Z
13
+ date: 2011-12-21 00:00:00.000000000Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: rails
17
- requirement: &71821000 !ruby/object:Gem::Requirement
17
+ requirement: &73136640 !ruby/object:Gem::Requirement
18
18
  none: false
19
19
  requirements:
20
20
  - - ! '>='
@@ -22,10 +22,10 @@ dependencies:
22
22
  version: 3.1.0
23
23
  type: :runtime
24
24
  prerelease: false
25
- version_requirements: *71821000
25
+ version_requirements: *73136640
26
26
  - !ruby/object:Gem::Dependency
27
27
  name: ancestry
28
- requirement: &71819570 !ruby/object:Gem::Requirement
28
+ requirement: &73136200 !ruby/object:Gem::Requirement
29
29
  none: false
30
30
  requirements:
31
31
  - - ~>
@@ -33,10 +33,10 @@ dependencies:
33
33
  version: 1.2.3
34
34
  type: :runtime
35
35
  prerelease: false
36
- version_requirements: *71819570
36
+ version_requirements: *73136200
37
37
  - !ruby/object:Gem::Dependency
38
38
  name: foreigner
39
- requirement: &71816970 !ruby/object:Gem::Requirement
39
+ requirement: &73135840 !ruby/object:Gem::Requirement
40
40
  none: false
41
41
  requirements:
42
42
  - - ~>
@@ -44,10 +44,10 @@ dependencies:
44
44
  version: 1.1.1
45
45
  type: :runtime
46
46
  prerelease: false
47
- version_requirements: *71816970
47
+ version_requirements: *73135840
48
48
  - !ruby/object:Gem::Dependency
49
49
  name: devise
50
- requirement: &71812580 !ruby/object:Gem::Requirement
50
+ requirement: &72916670 !ruby/object:Gem::Requirement
51
51
  none: false
52
52
  requirements:
53
53
  - - ~>
@@ -55,10 +55,10 @@ dependencies:
55
55
  version: 1.4.5
56
56
  type: :runtime
57
57
  prerelease: false
58
- version_requirements: *71812580
58
+ version_requirements: *72916670
59
59
  - !ruby/object:Gem::Dependency
60
60
  name: inherited_resources
61
- requirement: &71810970 !ruby/object:Gem::Requirement
61
+ requirement: &72916170 !ruby/object:Gem::Requirement
62
62
  none: false
63
63
  requirements:
64
64
  - - ~>
@@ -66,10 +66,10 @@ dependencies:
66
66
  version: 1.3.0
67
67
  type: :runtime
68
68
  prerelease: false
69
- version_requirements: *71810970
69
+ version_requirements: *72916170
70
70
  - !ruby/object:Gem::Dependency
71
71
  name: stringex
72
- requirement: &71808930 !ruby/object:Gem::Requirement
72
+ requirement: &72915610 !ruby/object:Gem::Requirement
73
73
  none: false
74
74
  requirements:
75
75
  - - ~>
@@ -77,10 +77,10 @@ dependencies:
77
77
  version: 1.3.0
78
78
  type: :runtime
79
79
  prerelease: false
80
- version_requirements: *71808930
80
+ version_requirements: *72915610
81
81
  - !ruby/object:Gem::Dependency
82
82
  name: avatars_for_rails
83
- requirement: &71805600 !ruby/object:Gem::Requirement
83
+ requirement: &72915190 !ruby/object:Gem::Requirement
84
84
  none: false
85
85
  requirements:
86
86
  - - ~>
@@ -88,10 +88,10 @@ dependencies:
88
88
  version: 0.2.0
89
89
  type: :runtime
90
90
  prerelease: false
91
- version_requirements: *71805600
91
+ version_requirements: *72915190
92
92
  - !ruby/object:Gem::Dependency
93
93
  name: jquery-rails
94
- requirement: &71803790 !ruby/object:Gem::Requirement
94
+ requirement: &72914810 !ruby/object:Gem::Requirement
95
95
  none: false
96
96
  requirements:
97
97
  - - ~>
@@ -99,10 +99,10 @@ dependencies:
99
99
  version: 1.0.9
100
100
  type: :runtime
101
101
  prerelease: false
102
- version_requirements: *71803790
102
+ version_requirements: *72914810
103
103
  - !ruby/object:Gem::Dependency
104
104
  name: cancan
105
- requirement: &71800840 !ruby/object:Gem::Requirement
105
+ requirement: &72914410 !ruby/object:Gem::Requirement
106
106
  none: false
107
107
  requirements:
108
108
  - - ~>
@@ -110,10 +110,10 @@ dependencies:
110
110
  version: 1.6.4
111
111
  type: :runtime
112
112
  prerelease: false
113
- version_requirements: *71800840
113
+ version_requirements: *72914410
114
114
  - !ruby/object:Gem::Dependency
115
115
  name: kaminari
116
- requirement: &71795240 !ruby/object:Gem::Requirement
116
+ requirement: &72914050 !ruby/object:Gem::Requirement
117
117
  none: false
118
118
  requirements:
119
119
  - - ~>
@@ -121,10 +121,10 @@ dependencies:
121
121
  version: 0.12.4
122
122
  type: :runtime
123
123
  prerelease: false
124
- version_requirements: *71795240
124
+ version_requirements: *72914050
125
125
  - !ruby/object:Gem::Dependency
126
126
  name: omniauth
127
- requirement: &75480620 !ruby/object:Gem::Requirement
127
+ requirement: &72913690 !ruby/object:Gem::Requirement
128
128
  none: false
129
129
  requirements:
130
130
  - - ~>
@@ -132,10 +132,10 @@ dependencies:
132
132
  version: 0.2.6
133
133
  type: :runtime
134
134
  prerelease: false
135
- version_requirements: *75480620
135
+ version_requirements: *72913690
136
136
  - !ruby/object:Gem::Dependency
137
137
  name: mailboxer
138
- requirement: &72560340 !ruby/object:Gem::Requirement
138
+ requirement: &72913320 !ruby/object:Gem::Requirement
139
139
  none: false
140
140
  requirements:
141
141
  - - ~>
@@ -143,10 +143,10 @@ dependencies:
143
143
  version: 0.5.4
144
144
  type: :runtime
145
145
  prerelease: false
146
- version_requirements: *72560340
146
+ version_requirements: *72913320
147
147
  - !ruby/object:Gem::Dependency
148
148
  name: acts-as-taggable-on
149
- requirement: &72700230 !ruby/object:Gem::Requirement
149
+ requirement: &72913000 !ruby/object:Gem::Requirement
150
150
  none: false
151
151
  requirements:
152
152
  - - ~>
@@ -154,10 +154,10 @@ dependencies:
154
154
  version: 2.0.6
155
155
  type: :runtime
156
156
  prerelease: false
157
- version_requirements: *72700230
157
+ version_requirements: *72913000
158
158
  - !ruby/object:Gem::Dependency
159
159
  name: formtastic
160
- requirement: &72726980 !ruby/object:Gem::Requirement
160
+ requirement: &72912630 !ruby/object:Gem::Requirement
161
161
  none: false
162
162
  requirements:
163
163
  - - ~>
@@ -165,10 +165,10 @@ dependencies:
165
165
  version: 1.2.3
166
166
  type: :runtime
167
167
  prerelease: false
168
- version_requirements: *72726980
168
+ version_requirements: *72912630
169
169
  - !ruby/object:Gem::Dependency
170
170
  name: simple-navigation
171
- requirement: &72746400 !ruby/object:Gem::Requirement
171
+ requirement: &72912350 !ruby/object:Gem::Requirement
172
172
  none: false
173
173
  requirements:
174
174
  - - ~>
@@ -176,10 +176,10 @@ dependencies:
176
176
  version: 3.5.1
177
177
  type: :runtime
178
178
  prerelease: false
179
- version_requirements: *72746400
179
+ version_requirements: *72912350
180
180
  - !ruby/object:Gem::Dependency
181
181
  name: resque
182
- requirement: &72806740 !ruby/object:Gem::Requirement
182
+ requirement: &72911980 !ruby/object:Gem::Requirement
183
183
  none: false
184
184
  requirements:
185
185
  - - ~>
@@ -187,10 +187,10 @@ dependencies:
187
187
  version: 1.19.0
188
188
  type: :runtime
189
189
  prerelease: false
190
- version_requirements: *72806740
190
+ version_requirements: *72911980
191
191
  - !ruby/object:Gem::Dependency
192
192
  name: modernizr-rails
193
- requirement: &72912080 !ruby/object:Gem::Requirement
193
+ requirement: &72911620 !ruby/object:Gem::Requirement
194
194
  none: false
195
195
  requirements:
196
196
  - - ~>
@@ -198,10 +198,10 @@ dependencies:
198
198
  version: 2.0.6
199
199
  type: :runtime
200
200
  prerelease: false
201
- version_requirements: *72912080
201
+ version_requirements: *72911620
202
202
  - !ruby/object:Gem::Dependency
203
203
  name: thinking-sphinx
204
- requirement: &73400440 !ruby/object:Gem::Requirement
204
+ requirement: &72911260 !ruby/object:Gem::Requirement
205
205
  none: false
206
206
  requirements:
207
207
  - - ~>
@@ -209,10 +209,10 @@ dependencies:
209
209
  version: 2.0.8
210
210
  type: :runtime
211
211
  prerelease: false
212
- version_requirements: *73400440
212
+ version_requirements: *72911260
213
213
  - !ruby/object:Gem::Dependency
214
214
  name: sass-rails
215
- requirement: &73593660 !ruby/object:Gem::Requirement
215
+ requirement: &72910810 !ruby/object:Gem::Requirement
216
216
  none: false
217
217
  requirements:
218
218
  - - ~>
@@ -220,10 +220,10 @@ dependencies:
220
220
  version: 3.1.0
221
221
  type: :runtime
222
222
  prerelease: false
223
- version_requirements: *73593660
223
+ version_requirements: *72910810
224
224
  - !ruby/object:Gem::Dependency
225
225
  name: rails_autolink
226
- requirement: &74481920 !ruby/object:Gem::Requirement
226
+ requirement: &72910060 !ruby/object:Gem::Requirement
227
227
  none: false
228
228
  requirements:
229
229
  - - ~>
@@ -231,10 +231,10 @@ dependencies:
231
231
  version: 1.0.4
232
232
  type: :runtime
233
233
  prerelease: false
234
- version_requirements: *74481920
234
+ version_requirements: *72910060
235
235
  - !ruby/object:Gem::Dependency
236
236
  name: social_cheesecake
237
- requirement: &74575480 !ruby/object:Gem::Requirement
237
+ requirement: &72909740 !ruby/object:Gem::Requirement
238
238
  none: false
239
239
  requirements:
240
240
  - - ~>
@@ -242,10 +242,10 @@ dependencies:
242
242
  version: 0.0.4
243
243
  type: :runtime
244
244
  prerelease: false
245
- version_requirements: *74575480
245
+ version_requirements: *72909740
246
246
  - !ruby/object:Gem::Dependency
247
247
  name: capybara
248
- requirement: &74635780 !ruby/object:Gem::Requirement
248
+ requirement: &72909420 !ruby/object:Gem::Requirement
249
249
  none: false
250
250
  requirements:
251
251
  - - ~>
@@ -253,10 +253,10 @@ dependencies:
253
253
  version: 0.3.9
254
254
  type: :development
255
255
  prerelease: false
256
- version_requirements: *74635780
256
+ version_requirements: *72909420
257
257
  - !ruby/object:Gem::Dependency
258
258
  name: sqlite3-ruby
259
- requirement: &74695990 !ruby/object:Gem::Requirement
259
+ requirement: &72909110 !ruby/object:Gem::Requirement
260
260
  none: false
261
261
  requirements:
262
262
  - - ! '>='
@@ -264,10 +264,10 @@ dependencies:
264
264
  version: '0'
265
265
  type: :development
266
266
  prerelease: false
267
- version_requirements: *74695990
267
+ version_requirements: *72909110
268
268
  - !ruby/object:Gem::Dependency
269
269
  name: ruby-debug19
270
- requirement: &74773250 !ruby/object:Gem::Requirement
270
+ requirement: &72908770 !ruby/object:Gem::Requirement
271
271
  none: false
272
272
  requirements:
273
273
  - - ! '>='
@@ -275,10 +275,10 @@ dependencies:
275
275
  version: '0'
276
276
  type: :development
277
277
  prerelease: false
278
- version_requirements: *74773250
278
+ version_requirements: *72908770
279
279
  - !ruby/object:Gem::Dependency
280
280
  name: rspec-rails
281
- requirement: &74857020 !ruby/object:Gem::Requirement
281
+ requirement: &72812420 !ruby/object:Gem::Requirement
282
282
  none: false
283
283
  requirements:
284
284
  - - ~>
@@ -286,10 +286,10 @@ dependencies:
286
286
  version: 2.6.1
287
287
  type: :development
288
288
  prerelease: false
289
- version_requirements: *74857020
289
+ version_requirements: *72812420
290
290
  - !ruby/object:Gem::Dependency
291
291
  name: factory_girl
292
- requirement: &74933620 !ruby/object:Gem::Requirement
292
+ requirement: &72812040 !ruby/object:Gem::Requirement
293
293
  none: false
294
294
  requirements:
295
295
  - - ~>
@@ -297,10 +297,10 @@ dependencies:
297
297
  version: 1.3.2
298
298
  type: :development
299
299
  prerelease: false
300
- version_requirements: *74933620
300
+ version_requirements: *72812040
301
301
  - !ruby/object:Gem::Dependency
302
302
  name: forgery
303
- requirement: &75012360 !ruby/object:Gem::Requirement
303
+ requirement: &72811730 !ruby/object:Gem::Requirement
304
304
  none: false
305
305
  requirements:
306
306
  - - ~>
@@ -308,10 +308,10 @@ dependencies:
308
308
  version: 0.4.2
309
309
  type: :development
310
310
  prerelease: false
311
- version_requirements: *75012360
311
+ version_requirements: *72811730
312
312
  - !ruby/object:Gem::Dependency
313
313
  name: ci_reporter
314
- requirement: &75089200 !ruby/object:Gem::Requirement
314
+ requirement: &72811420 !ruby/object:Gem::Requirement
315
315
  none: false
316
316
  requirements:
317
317
  - - ~>
@@ -319,10 +319,10 @@ dependencies:
319
319
  version: 1.6.4
320
320
  type: :development
321
321
  prerelease: false
322
- version_requirements: *75089200
322
+ version_requirements: *72811420
323
323
  - !ruby/object:Gem::Dependency
324
324
  name: nifty-generators
325
- requirement: &75186920 !ruby/object:Gem::Requirement
325
+ requirement: &72811150 !ruby/object:Gem::Requirement
326
326
  none: false
327
327
  requirements:
328
328
  - - ~>
@@ -330,7 +330,7 @@ dependencies:
330
330
  version: 0.4.5
331
331
  type: :development
332
332
  prerelease: false
333
- version_requirements: *75186920
333
+ version_requirements: *72811150
334
334
  description: ! 'Social Stream is a Ruby on Rails engine providing your application
335
335
  with social networking features and activity streams.
336
336
 
@@ -817,6 +817,7 @@ files:
817
817
  - db/migrate/20110712142140_remove_permission_function.rb
818
818
  - db/migrate/20110912074426_add_reject_relation.rb
819
819
  - db/migrate/20111124100618_object_actors.rb
820
+ - db/migrate/20111221103509_add_language_field.rb
820
821
  - lib/acts_as_taggable_on/acts_as_taggable_on/dirty.rb
821
822
  - lib/acts_as_taggable_on/social_stream.rb
822
823
  - lib/generators/social_stream/base/install_generator.rb
@@ -988,9 +989,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
988
989
  version: '0'
989
990
  requirements: []
990
991
  rubyforge_project:
991
- rubygems_version: 1.8.12
992
+ rubygems_version: 1.8.10
992
993
  signing_key:
993
994
  specification_version: 3
994
995
  summary: Basic features for Social Stream, the core for building social network websites
995
996
  test_files: []
996
- has_rdoc: