lato_core 1.1.4 → 1.1.5

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: 0fb7a358b1909e82ef4fa43cfc1de23c7b621eac
4
- data.tar.gz: 68f037cb514630e032f7b395e644fc573767a281
3
+ metadata.gz: ba0a4023ceccfb7daaf63f882fb780605f60cab9
4
+ data.tar.gz: aeb6e60f8b9f83b8dd45c0971fb679cc816e338c
5
5
  SHA512:
6
- metadata.gz: 5ebe6c3b45a65df5aee321005052bdb7afe21d3dc1253742aa350f8dcc8b7745f29266fa8dca6a1e5f47bc9b62168e206d12778787a90b7cc96363d067e7841c
7
- data.tar.gz: 4995a8de37d5ae175ecb33f806fed0927e6950b2a963da2151c58c0cd0148a584745269b409147254db450384669bb13c4ae94594c00c1697ad1b4a0737d0f64
6
+ metadata.gz: 32fa2e150940132017c1198ba59d9a1586dc04eca9e94e66eb2af5cc3dd15331bf0e74df7f0c273ace68b49aee4cd67753f432754f0467c4b11334149973e5a1
7
+ data.tar.gz: d015cb4c8956c54daca74f4c15fa95912ffa9305d54d7e2beb62e4fdf5126fb67df94194d301a0e95a4e25e74bf362b07b498f855711c09cebf1b03539012d16
File without changes
File without changes
@@ -26,24 +26,11 @@ module LatoCore
26
26
  before_create do
27
27
  username.downcase!
28
28
  email.downcase!
29
-
30
- set_admin_permission
31
29
  end
32
30
 
33
31
  before_update do
34
32
  username.downcase!
35
33
  email.downcase!
36
-
37
- set_admin_permission
38
- end
39
-
40
- # Private functions
41
- ############################################################################
42
-
43
- # This function set permission to 10 for first superuser.
44
- private def set_admin_permission
45
- first_user = LatoCore::Superuser.first
46
- self.permission = 10 if first_user && self.id === first_user.id
47
34
  end
48
35
 
49
36
  end
@@ -24,7 +24,7 @@
24
24
  <div class="login-logo"><%= image_tag login_logo %></div>
25
25
  <% end %>
26
26
 
27
- <%= form_tag(lato_core.exec_login_path, method: "post", class: 'lato-form') do %>
27
+ <%= form_tag(lato_core.exec_login_path, method: "post", class: 'lato-form login-form') do %>
28
28
 
29
29
  <%=raw view(:input, :text).new(name: 'username',
30
30
  label: CORE_LANG['vocabolary']['username']) %>
@@ -11,7 +11,7 @@ new_button = view(:component, :button).new(title: CORE_LANG['vocabolary']['new']
11
11
 
12
12
  actionbar = view(:layout, :actionbar).new(title: CORE_LANG['vocabolary']['users'],
13
13
  widgets: [
14
- {component: searchbar, align: :right},
14
+ {component: searchbar, align: :left},
15
15
  {component: new_button, align: :right}
16
16
  ])
17
17
 
@@ -68,6 +68,6 @@
68
68
 
69
69
  </div>
70
70
 
71
- <%= f.submit CORE_LANG['vocabolary']['save'], class: 'lato-button' %>
71
+ <%= f.submit CORE_LANG['vocabolary']['save'], class: 'lato-button', data: { disable_with: false } %>
72
72
 
73
73
  <% end %>
File without changes
File without changes
data/config/example.yml CHANGED
File without changes
@@ -7,9 +7,9 @@ CORE_LANG = core_loadModuleLanguages('lato_core')
7
7
  # Create first user if not exist
8
8
 
9
9
  if ActiveRecord::Base.connection.table_exists? 'lato_core_superusers'
10
-
11
- LatoCore::Superuser.create(name: 'Admin', username: 'lato',
12
- email: 'lato@mail.com', permission: 10, password: 'password',
13
- password_confirmation: 'password')
14
-
10
+ if LatoCore::Superuser.where(permission: 10).empty?
11
+ LatoCore::Superuser.create(name: 'Admin', username: 'lato',
12
+ email: 'lato@mail.com', permission: 10, password: 'password',
13
+ password_confirmation: 'password')
14
+ end
15
15
  end
File without changes
File without changes
data/lang/en.yml CHANGED
File without changes
File without changes
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lato_core
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.4
4
+ version: 1.1.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Gregorio Galante, Antonio Dal Cin, Riccardo Zanutta
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-10-28 00:00:00.000000000 Z
11
+ date: 2017-09-17 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -107,7 +107,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
107
107
  version: '0'
108
108
  requirements: []
109
109
  rubyforge_project:
110
- rubygems_version: 2.5.1
110
+ rubygems_version: 2.6.12
111
111
  signing_key:
112
112
  specification_version: 4
113
113
  summary: Lato module for basic functions