cybele 1.9.1 → 1.9.2

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.
Files changed (34) hide show
  1. checksums.yaml +4 -4
  2. data/lib/cybele/app_builder.rb +5 -1
  3. data/lib/cybele/generators/app_generator.rb +5 -0
  4. data/lib/cybele/version.rb +1 -1
  5. data/templates/.env.production.erb +2 -2
  6. data/templates/.env.staging.erb +2 -2
  7. data/templates/Procfile.erb +2 -0
  8. data/templates/app/assets/javascripts/application.js.coffee +2 -0
  9. data/templates/app/assets/javascripts/hq/application.js.coffee +2 -1
  10. data/templates/app/controllers/application_controller.rb.erb +2 -2
  11. data/templates/app/controllers/concerns/basic_authentication.rb +1 -1
  12. data/templates/app/controllers/user/{profiles_controller.rb → profile_controller.rb} +3 -3
  13. data/templates/app/controllers/user/user_application_controller.rb +7 -1
  14. data/templates/app/views/devise/registrations/edit.html.haml +1 -1
  15. data/templates/app/views/devise/registrations/new.html.haml +1 -1
  16. data/templates/app/views/hq/admins/_form.html.haml +1 -1
  17. data/templates/app/views/hq/cities/_city.html.haml +3 -3
  18. data/templates/app/views/hq/cities/_form.html.haml +1 -1
  19. data/templates/app/views/hq/countries/_country.html.haml +3 -3
  20. data/templates/app/views/hq/countries/_form.html.haml +1 -1
  21. data/templates/app/views/hq/users/_form.html.haml +1 -1
  22. data/templates/app/views/layouts/application.html.haml.erb +33 -7
  23. data/templates/app/views/user/{profiles → profile}/_form.html.haml +1 -1
  24. data/templates/app/views/user/profile/edit.html.haml +3 -0
  25. data/templates/app/views/user/profile/show.html.haml +18 -0
  26. data/templates/app/views/welcome/index.html.haml.erb +1 -0
  27. data/templates/config/locales/view.tr.yml +2 -0
  28. data/templates/config/routes.erb +1 -1
  29. data/templates/cybele_Gemfile +1 -1
  30. data/templates/lib/tasks/dev.rake +1 -2
  31. metadata +8 -8
  32. data/dump.rdb +0 -1
  33. data/templates/app/views/user/profiles/edit.html.haml +0 -3
  34. data/templates/app/views/user/profiles/show.html.haml +0 -15
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: cdcd06663bdb0df45eb3e29884129fd320c3efaf
4
- data.tar.gz: b029a782bdf9ba6083d91d264de8c377ea99df8b
3
+ metadata.gz: fa062022414d0248bd5804895bd7a2223a514491
4
+ data.tar.gz: c7681adc4d608ce615ff051d53a1a297f8aa0936
5
5
  SHA512:
6
- metadata.gz: e26bf635d99f1a6639301b31d45068bba474ac08e5a1d312abaf41b55f5b5e7f846b5a9295b02cb2a5bb8c456a5a4ba6301cfd303acfdae4162ec0afed28b217
7
- data.tar.gz: 1d18bb27704b38a0409fecf4d417fde08f842d2fded66616ea88e0d306ce4c5389a9219d7b1f80cee384b210583c82840cdee08d88922f5dcb6e5426419a68ef
6
+ metadata.gz: 4671bab4d05d2c92a8393ca639f0723415ccb98037fca519b7c44ac9ea05f2fef3c86055d6930e66c0221ca6bc3677d420cd5997ab10f3e83aef495c0510fda7
7
+ data.tar.gz: 5f8f81bdc8be924509b8d071fcb64d7a0018c2efd6a148816748548b700e98b4b0e33466c8716429d067286c4115412e5322cd408974742e2638306245f915a9
@@ -336,11 +336,14 @@ set :project_domain, "staging.example.com"'
336
336
  end
337
337
  end
338
338
 
339
- # Nor using
340
339
  def setup_recipes
341
340
  generate 'recipes_matic:install'
342
341
  end
343
342
 
343
+ def setup_client_side_validations
344
+ generate 'client_side_validations:install'
345
+ end
346
+
344
347
  def update_secret_token
345
348
  remove_file 'config/initializers/secret_token.rb', force: true
346
349
  template 'config/initializers/secret_token.erb', 'config/initializers/secret_token.rb'
@@ -440,6 +443,7 @@ set :project_domain, "staging.example.com"'
440
443
  template '.env.production.erb', '.env.production', force: true
441
444
  template '.env.staging.erb', '.env.staging', force: true
442
445
  template 'env.sample.erb', 'env.sample', force: true
446
+ template 'Procfile.erb', 'Procfile', force: true
443
447
 
444
448
  # Library files
445
449
  directory 'lib/tasks', 'lib/tasks'
@@ -205,6 +205,11 @@ module Cybele
205
205
  build :setup_recipes
206
206
  end
207
207
 
208
+ def setup_client_side_validations
209
+ say 'Setup client_side_validations'
210
+ build :setup_client_side_validations
211
+ end
212
+
208
213
  def setup_secret_token
209
214
  say 'Setup secret token'
210
215
  build :update_secret_token
@@ -1,5 +1,5 @@
1
1
  module Cybele
2
2
  RAILS_VERSION = '~> 4.2.6'
3
3
  RUBY_VERSION = IO.read("#{File.dirname(__FILE__)}/../../.ruby-version").strip
4
- VERSION = '1.9.1'
4
+ VERSION = '1.9.2'
5
5
  end
@@ -5,7 +5,7 @@ SMTP_USER_NAME=admin@<%= app_name %>.com
5
5
  SMTP_ADDRESS=smtp.sendgrid.net
6
6
 
7
7
  BASIC_AUTH_IS_ACTIVE=no
8
- S3_BUCKET_NAME=<%= app_name %>-v3
9
- AWS_RAW_URL=<%= app_name %>-v3.s3.amazonaws.com
8
+ S3_BUCKET_NAME=<%= app_name %>
9
+ AWS_RAW_URL=<%= app_name %>.s3.amazonaws.com
10
10
  AWS_ACCESS_KEY_ID=
11
11
  AWS_SECRET_ACCESS_KEY=
@@ -5,7 +5,7 @@ SMTP_USER_NAME=admin@<%= app_name %>.com
5
5
  SMTP_ADDRESS=smtp.sendgrid.net
6
6
 
7
7
  BASIC_AUTH_IS_ACTIVE=yes
8
- S3_BUCKET_NAME=<%= app_name %>-v3-staging
9
- AWS_RAW_URL=<%= app_name %>-v3-staging.s3.amazonaws.com
8
+ S3_BUCKET_NAME=<%= app_name %>-staging
9
+ AWS_RAW_URL=<%= app_name %>-staging.s3.amazonaws.com
10
10
  AWS_ACCESS_KEY_ID=
11
11
  AWS_SECRET_ACCESS_KEY=
@@ -0,0 +1,2 @@
1
+ web: bin/rails server -p $PORT -e $RAILS_ENV
2
+ worker: bundle exec sidekiq -C config/sidekiq.yml
@@ -19,6 +19,8 @@
19
19
  #= require jquery.datetimepicker
20
20
  #= require nprogress
21
21
  #= require trix
22
+ #= require rails.validations
23
+ #= require rails.validations.simple_form
22
24
 
23
25
  class @App
24
26
 
@@ -20,7 +20,8 @@
20
20
  #= require trix
21
21
  #= require jquery.datetimepicker
22
22
  #= require nprogress
23
-
23
+ #= require rails.validations
24
+ #= require rails.validations.simple_form
24
25
 
25
26
  class @App
26
27
  @tooltip = ->
@@ -12,7 +12,7 @@ class ApplicationController < ActionController::Base
12
12
 
13
13
  # Prevent CSRF attacks by raising an exception.
14
14
  # For APIs, you may want to use :null_session instead.
15
- before_filter :set_audit_user
15
+ before_filter :set_audit_user, :set_user_time_zone
16
16
  protect_from_forgery with: :exception
17
17
 
18
18
  def server_error(exception)
@@ -27,7 +27,7 @@ class ApplicationController < ActionController::Base
27
27
  protected
28
28
 
29
29
  def set_user_time_zone
30
- Time.zone = current_user.time_zone if student_signed_in? && current_student.time_zone.present?
30
+ Time.zone = current_user.time_zone if user_signed_in? && current_user.time_zone.present?
31
31
  end
32
32
 
33
33
  def devise_parameter_sanitizer
@@ -8,7 +8,7 @@ module BasicAuthentication
8
8
  private
9
9
 
10
10
  def authenticate
11
- if Rails.env.staging? and ENV['BASIC_AUTH_IS_ACTIVE'] == 'yes'
11
+ if ENV['BASIC_AUTH_IS_ACTIVE'] == 'yes'
12
12
  authenticate_or_request_with_http_basic do |username, password|
13
13
  username == Settings.basic_auth.username && password == Settings.basic_auth.password
14
14
  end
@@ -1,11 +1,11 @@
1
- class User::ProfilesController < User::UserApplicationController
1
+ class User::ProfileController < User::UserApplicationController
2
2
 
3
3
  before_action :set_profile, only: [:show, :edit, :update]
4
4
  add_breadcrumb I18n.t('dock.profile'), :user_profile_path
5
5
 
6
6
  def show
7
7
  add_breadcrumb @profile.full_name, user_profile_path
8
- respond_with([:user, @profile])
8
+ respond_with(:user, @profile)
9
9
  end
10
10
 
11
11
  def edit
@@ -14,7 +14,7 @@ class User::ProfilesController < User::UserApplicationController
14
14
 
15
15
  def update
16
16
  @profile.update(profile_params)
17
- respond_with([:user, @profile], location: user_profile_path)
17
+ respond_with(:user, @profile, location: user_profile_path)
18
18
  end
19
19
 
20
20
  private
@@ -4,12 +4,18 @@ class User::UserApplicationController < ActionController::Base
4
4
 
5
5
  # layout 'user/application'
6
6
  layout 'application'
7
- before_filter :set_audit_user
7
+ before_filter :set_audit_user, :set_user_time_zone
8
8
  before_action :authenticate_user!
9
9
 
10
10
  self.responder = ApplicationResponder
11
11
  respond_to :html, :json
12
12
 
13
+ protected
14
+
15
+ def set_user_time_zone
16
+ Time.zone = current_user.time_zone if current_user.time_zone.present?
17
+ end
18
+
13
19
  private
14
20
 
15
21
  def set_audit_user
@@ -1,6 +1,6 @@
1
1
  %h2
2
2
  = t('devise.registration.title', model: resource.class.model_name.human )
3
- = simple_form_for(resource, as: resource_name, url: registration_path(resource_name), html: { method: :put }) do |f|
3
+ = simple_form_for(resource, as: resource_name, url: registration_path(resource_name), html: { method: :put }, validate: true) do |f|
4
4
  = f.error_notification
5
5
  .form-inputs
6
6
  = f.input :email, required: true, autofocus: true
@@ -10,7 +10,7 @@
10
10
  %h3.text-center
11
11
  = t('view.or')
12
12
  %hr/
13
- = simple_form_for(resource, as: resource_name, url: registration_path(resource_name)) do |f|
13
+ = simple_form_for(resource, as: resource_name, url: registration_path(resource_name), validate: true) do |f|
14
14
  = f.error_notification
15
15
  .form-inputs
16
16
  = f.input :email
@@ -3,7 +3,7 @@
3
3
  %i.icon-edit.icon-large
4
4
  = yield :form_title
5
5
  .panel-body
6
- = simple_form_for([:hq, @admin]) do |f|
6
+ = simple_form_for([:hq, @admin], validate: true) do |f|
7
7
  = f.error_notification
8
8
 
9
9
  .form-inputs
@@ -4,9 +4,9 @@
4
4
  %td= city.country.name
5
5
  %td=l city.created_at
6
6
  %td.action
7
- = link_to([:hq, city], class: 'btn btn-success', toogle: 'tooltip', title: t('tooltips.zoom')) do
7
+ = link_to([:hq, city], class: 'btn btn-success', data: { toggle: :tooltip}, title: t('tooltips.zoom')) do
8
8
  %i.icon-eye-open
9
- = link_to(edit_hq_city_path(city) , class: 'btn btn-info') do
9
+ = link_to(edit_hq_city_path(city) , class: 'btn btn-info', data: { toggle: :tooltip }, title: t('tooltips.edit')) do
10
10
  %i.icon-edit
11
- = link_to([:hq, city], class: 'btn btn-danger', method: :delete, data: { confirm: t('tooltips.are_you_sure') }) do
11
+ = link_to([:hq, city], class: 'btn btn-danger', method: :delete, data: { confirm: t('tooltips.are_you_sure'), toggle: :tooltip }, title: t('tooltips.delete')) do
12
12
  %i.icon-trash
@@ -3,7 +3,7 @@
3
3
  %i.icon-edit.icon-large
4
4
  = yield :form_title
5
5
  .panel-body
6
- = simple_form_for([:hq, @city]) do |f|
6
+ = simple_form_for([:hq, @city], validate: true) do |f|
7
7
  = f.error_notification
8
8
 
9
9
  .form-inputs
@@ -3,9 +3,9 @@
3
3
  %td= country.name
4
4
  %td=l country.created_at
5
5
  %td.action
6
- = link_to([:hq, country], class: 'btn btn-success', toogle: 'tooltip', title: t('tooltips.zoom')) do
6
+ = link_to([:hq, country], class: 'btn btn-success', data: { toggle: :tooltip}, title: t('tooltips.zoom')) do
7
7
  %i.icon-eye-open
8
- = link_to(edit_hq_country_path(country) , class: 'btn btn-info') do
8
+ = link_to(edit_hq_country_path(country) , class: 'btn btn-info', data: { toggle: :tooltip }, title: t('tooltips.edit')) do
9
9
  %i.icon-edit
10
- = link_to([:hq, country], class: 'btn btn-danger', method: :delete, data: { confirm: t('tooltips.are_you_sure') }) do
10
+ = link_to([:hq, country], class: 'btn btn-danger', method: :delete, data: { confirm: t('tooltips.are_you_sure'), toggle: :tooltip }, title: t('tooltips.delete')) do
11
11
  %i.icon-trash
@@ -3,7 +3,7 @@
3
3
  %i.icon-edit.icon-large
4
4
  = yield :form_title
5
5
  .panel-body
6
- = simple_form_for([:hq, @country]) do |f|
6
+ = simple_form_for([:hq, @country], validate: true) do |f|
7
7
  = f.error_notification
8
8
 
9
9
  .form-inputs
@@ -3,7 +3,7 @@
3
3
  %i.icon-edit.icon-large
4
4
  = yield :form_title
5
5
  .panel-body
6
- = simple_form_for([:hq, @user]) do |f|
6
+ = simple_form_for([:hq, @user], validate: true) do |f|
7
7
  = f.error_notification
8
8
 
9
9
  .form-inputs
@@ -16,13 +16,39 @@
16
16
  %body
17
17
  = render 'layouts/partials/warnings'
18
18
  .container-narrow
19
- .masthead
20
- %ul.nav.nav-pills.pull-right
21
- %li.active
22
- %a{href: "/"}
23
- = t('navbar.home_page')
24
- %h3.muted= link_to "<%= app_name.capitalize %>", root_path
25
- %hr/
19
+ %nav.navbar.navbar-default
20
+ .container-fluid
21
+ / Brand and toggle get grouped for better mobile display
22
+ .navbar-header
23
+ %button.navbar-toggle.collapsed{"aria-expanded" => "false", "data-target" => "#bs-example-navbar-collapse-1", "data-toggle" => "collapse", :type => "button"}
24
+ %span.sr-only Toggle navigation
25
+ %span.icon-bar
26
+ %span.icon-bar
27
+ %span.icon-bar
28
+ = link_to root_path, class: 'navbar-brand' do
29
+ %i.fa.fa-home
30
+ = "<%= app_name.capitalize %>"
31
+ / Collect the nav links, forms, and other content for toggling
32
+ #bs-example-navbar-collapse-1.collapse.navbar-collapse
33
+ %ul.nav.navbar-nav.navbar-right
34
+ - if user_signed_in?
35
+ %li
36
+ = link_to destroy_user_session_path, method: :delete do
37
+ %i.fa.fa-sign-out
38
+ = t('navbar.sign_out')
39
+ %li
40
+ = link_to user_profile_path(current_user) do
41
+ %i.fa.fa-user
42
+ = t('navbar.profile')
43
+ - else
44
+ %li
45
+ = link_to new_user_session_path do
46
+ %i.fa.fa-pencil-square-o{"aria-hidden" => "true"}
47
+ = t('navbar.signin')
48
+ %li
49
+ = link_to new_user_registration_path do
50
+ %i.fa.fa-user{"aria-hidden" => "true"}
51
+ = t('navbar.signup')
26
52
  = render partial: 'layouts/partials/messages'
27
53
  = yield
28
54
  %hr/
@@ -3,7 +3,7 @@
3
3
  %i.icon-edit.icon-large
4
4
  = yield :form_title
5
5
  .panel-body
6
- = simple_form_for([:user, @profile], url: user_profile_path) do |f|
6
+ = simple_form_for([:user, @profile], url: user_profile_path, validate: true) do |f|
7
7
  = f.error_notification
8
8
 
9
9
  .form-inputs
@@ -0,0 +1,3 @@
1
+ - content_for :form_title do
2
+ = t('tt.edit', resource_name: User.model_name.human)
3
+ = render 'form'
@@ -0,0 +1,18 @@
1
+ .panel.panel-default
2
+ .panel-heading
3
+ %i.icon-edit.icon-large
4
+ = t('tt.show', resource_name: User.model_name.human)
5
+ .panel-body
6
+ = show_for @profile do |s|
7
+ = s.attribute :name
8
+ = s.attribute :surname
9
+ = s.attribute :email
10
+ = s.attribute :created_at
11
+ = s.attribute :updated_at
12
+ .panel-footer
13
+ = link_to root_path, class: 'btn-link' do
14
+ %i.fa.fa-arrow-left
15
+ = t('btn.back')
16
+ = link_to edit_user_profile_path(@profile), class: 'btn btn-link' do
17
+ %i.fa.fa-pencil
18
+ = t('navbar.edit_profile_info')
@@ -10,6 +10,7 @@
10
10
  %strong Email:
11
11
  = current_user.email
12
12
  = link_to t('navbar.edit_login_info'), edit_user_registration_path, class: 'btn btn-large'
13
+ = link_to t('navbar.profile'), user_profile_path(current_user), class: 'btn btn-link'
13
14
  - else
14
15
  = link_to t('navbar.signup'), new_user_registration_path, class: 'btn btn-large btn-success'
15
16
  = link_to t('navbar.signin'), new_user_session_path, class: 'btn btn-large'
@@ -34,8 +34,10 @@ tr:
34
34
  signin: Giriş Yap
35
35
  sign_out: Çıkış yap
36
36
  edit_login_info: Giriş bilgilerini güncelle
37
+ edit_profile_info: Profil bilgilerini güncelle
37
38
  home_page: Anasayfa
38
39
  admin_portal: Yönetici Portalı
40
+ profile: Profil
39
41
  tooltips:
40
42
  delete: Sil
41
43
  are_you_sure: Devam etmek istedğinize emin misiniz?
@@ -38,7 +38,7 @@ Rails.application.routes.draw do
38
38
  namespace :user do
39
39
  root to: 'dashboard#index'
40
40
  resources :dashboard, only: [:index]
41
- resources :profile, only: [:index, :edit, :update]
41
+ resources :profile, only: [:show, :edit, :update]
42
42
  end
43
43
 
44
44
  # Common pages
@@ -65,7 +65,6 @@ group :development, :test do
65
65
  gem 'katip'
66
66
  gem 'capybara'
67
67
  gem 'bullet'
68
- gem 'sinatra', require: nil
69
68
  gem 'quiet_assets'
70
69
  end
71
70
 
@@ -86,6 +85,7 @@ gem 'puma', '~> 3.4.0'
86
85
  gem 'sidekiq', '~> 4.1'
87
86
  gem 'devise-async', '~> 0.10.1'
88
87
  gem 'sidekiq-cron', '~> 0.4.2'
88
+ gem 'sinatra', require: nil
89
89
 
90
90
  # Comand line execution
91
91
  gem 'cocaine', '~> 0.5.8'
@@ -8,8 +8,7 @@ namespace :dev do
8
8
  Rake::Task['db:drop'].execute
9
9
  Rake::Task['db:create'].execute
10
10
  Rake::Task['db:migrate'].execute
11
- Rake::Task['dev:initial'].execute
12
- Rake::Task['db:seed'].execute
11
+ Rake::Task['dev:seed'].execute
13
12
  end
14
13
 
15
14
  desc 'seed test data'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cybele
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.9.1
4
+ version: 1.9.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - lab2023
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-06-22 00:00:00.000000000 Z
11
+ date: 2016-08-03 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake
@@ -73,13 +73,13 @@ files:
73
73
  - SECURITY.md
74
74
  - bin/cybele
75
75
  - cybele.gemspec
76
- - dump.rdb
77
76
  - lib/cybele/app_builder.rb
78
77
  - lib/cybele/generators/app_generator.rb
79
78
  - lib/cybele/version.rb
80
79
  - templates/.env.local.erb
81
80
  - templates/.env.production.erb
82
81
  - templates/.env.staging.erb
82
+ - templates/Procfile.erb
83
83
  - templates/README.md.erb
84
84
  - templates/app/assets/javascripts/application.js.coffee
85
85
  - templates/app/assets/javascripts/hq/application.js.coffee
@@ -99,7 +99,7 @@ files:
99
99
  - templates/app/controllers/hq/users_controller.rb
100
100
  - templates/app/controllers/user/dashboard_controller.rb
101
101
  - templates/app/controllers/user/passwords_controller.rb
102
- - templates/app/controllers/user/profiles_controller.rb
102
+ - templates/app/controllers/user/profile_controller.rb
103
103
  - templates/app/controllers/user/registrations_controller.rb
104
104
  - templates/app/controllers/user/sessions_controller.rb
105
105
  - templates/app/controllers/user/user_application_controller.rb
@@ -187,9 +187,9 @@ files:
187
187
  - templates/app/views/user/dashboard/index.html.haml
188
188
  - templates/app/views/user/passwords/edit.html.haml
189
189
  - templates/app/views/user/passwords/new.html.haml
190
- - templates/app/views/user/profiles/_form.html.haml
191
- - templates/app/views/user/profiles/edit.html.haml
192
- - templates/app/views/user/profiles/show.html.haml
190
+ - templates/app/views/user/profile/_form.html.haml
191
+ - templates/app/views/user/profile/edit.html.haml
192
+ - templates/app/views/user/profile/show.html.haml
193
193
  - templates/app/views/user/registrations/edit.html.haml
194
194
  - templates/app/views/user/sessions/new.html.haml
195
195
  - templates/app/views/user_mailer/login_info.html.haml
@@ -264,7 +264,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
264
264
  version: '0'
265
265
  requirements: []
266
266
  rubyforge_project:
267
- rubygems_version: 2.6.2
267
+ rubygems_version: 2.5.1
268
268
  signing_key:
269
269
  specification_version: 4
270
270
  summary: Rails 4.x template with responder, simple form, haml, exception notification,
data/dump.rdb DELETED
@@ -1 +0,0 @@
1
- REDIS0006�ܳC�Z��V
@@ -1,3 +0,0 @@
1
- - content_for :form_title do
2
- = t('tt.edit', resource_name: user.model_name.human)
3
- = render 'form'
@@ -1,15 +0,0 @@
1
- - content_for :toolbar do
2
- = link_to edit_user_profile_path, class: 'btn btn-default' do
3
- %i.icon-pencil
4
- = t('action_button.edit')
5
- .panel.panel-default
6
- .panel-heading
7
- %i.icon-edit.icon-large
8
- = t('tt.show', resource_name: user.model_name.human)
9
- .panel-body
10
- = show_for @profile do |s|
11
- = s.attribute :name
12
- = s.attribute :surname
13
- = s.attribute :email
14
- = s.attribute :created_at
15
- = s.attribute :updated_at