my_forum 0.0.1.beta42 → 0.0.1.beta43

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 50b1db333d9e70df0dc190ede0c0ca5fd0c07b02
4
- data.tar.gz: 416c97311f6a6383395f7d845dcc6c27a1f1cb49
3
+ metadata.gz: 898dfc20ccc1570159c8b166757647cd1561ac69
4
+ data.tar.gz: 3d36e03985b31c140e2c2d32eb92557cd3df6026
5
5
  SHA512:
6
- metadata.gz: 14eb269a8a94b0537d0ae1833a6d6baa639ce6953bd7ee65eae87e0911a65714938dc4af99344a27559fd60f2aafcd65a3308dde0646698dd758621600cad564
7
- data.tar.gz: 79aa72eb79131a5bef00bfe0696c437a727f274fa277c618f4019f26b1cc151b623479ed8ee7c36b8cc1c073bc07f95cf16f7392f31c96f8d7ed310fe747e0f3
6
+ metadata.gz: 7e251953aa891fef3009d0a77de913a8958962db75616b89a04a780b02373e0cea92a77664b34d2edc464f3ba762da3d5390e548dd6374f16f843ac9c88685ad
7
+ data.tar.gz: 286758629f312cb16c798682f04cc5dbaf6b87a168cdd8c93bd19135af5b1851cfa9c3c40dff348280c50870beeb4a1b6e7265d7b97fe675ac8ab3b436cf991c
@@ -21,6 +21,8 @@ module MyForum
21
21
  current_user.update(attr => params[:user][attr]) if params[:user][attr]
22
22
  end
23
23
 
24
+ flash[:notice] = t('.successfully_updated')
25
+
24
26
  redirect_to edit_user_path(current_user)
25
27
  end
26
28
 
@@ -30,7 +32,7 @@ module MyForum
30
32
  @user.user_groups << UserGroup::MEMBER_GROUP
31
33
  @user.save
32
34
  session[:user_id] = @user.id
33
- redirect_to root_path
35
+ redirect_to edit_user_path(@user)
34
36
  else
35
37
  render :new
36
38
  end
@@ -22,7 +22,8 @@ module MyForum
22
22
  end
23
23
 
24
24
  def online_users
25
- User.online.pluck(:login).join(', ')
25
+ users_list = User.online.pluck(:login).join(', ')
26
+ users_list.blank? ? I18n.t('my_forum.no_online_users') : users_list
26
27
  end
27
28
 
28
29
  def today_was_users
@@ -2,7 +2,6 @@
2
2
 
3
3
  .row
4
4
  .col-md-4
5
-
6
5
  = errors_for(current_user)
7
6
 
8
7
  = form_for current_user, url: user_path(current_user), role: 'form' do |form|
@@ -33,4 +32,9 @@
33
32
  - additional_info_attrs.each do |attr|
34
33
  .form-group= form.text_field attr, value: current_user.send(attr), class: 'name form-control', placeholder: t("my_forum.additional_info.#{attr.to_s}")
35
34
 
36
- = form.submit t('.update'), class: 'btn btn-primary btn-sm'
35
+ = form.submit t('.update'), class: 'btn btn-primary btn-sm'
36
+
37
+ %br
38
+ .row
39
+ .col-md-12.text-center
40
+ =link_to t('.back_to_the_forum'), root_path, class: 'btn btn-sm btn-success'
@@ -1,6 +1,7 @@
1
1
  ru:
2
2
  today: "Сегодня"
3
3
  my_forum:
4
+ no_online_users: 'никого нет :('
4
5
  pm:
5
6
  sent: 'Сообщение отправленно'
6
7
  mailer:
@@ -142,6 +143,9 @@ ru:
142
143
  update: 'Обновить'
143
144
  update_avatar: 'Обновить аватар'
144
145
  edit_additional_info: 'Дополнительная информация'
146
+ back_to_the_forum: 'Вернуться на форум'
147
+ update:
148
+ successfully_updated: 'Данные обновлены'
145
149
 
146
150
 
147
151
  private_messages:
@@ -1,3 +1,3 @@
1
1
  module MyForum
2
- VERSION = "0.0.1.beta42"
2
+ VERSION = "0.0.1.beta43"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: my_forum
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1.beta42
4
+ version: 0.0.1.beta43
5
5
  platform: ruby
6
6
  authors:
7
7
  - Vitaly Omelchenko
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-01-11 00:00:00.000000000 Z
11
+ date: 2016-01-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails