scaffold_pico 1.1.5 → 1.1.6

Sign up to get free protection for your applications and to get access to all the features.
Files changed (39) hide show
  1. checksums.yaml +4 -4
  2. data/LICENSE.txt +0 -0
  3. data/README.md +2 -2
  4. data/lib/scaffold/cli.rb +0 -0
  5. data/lib/scaffold/erb_context.rb +0 -0
  6. data/lib/scaffold/generators/base_generator.rb +0 -0
  7. data/lib/scaffold/generators/controller_generator.rb +0 -0
  8. data/lib/scaffold/generators/fabricator_generator.rb +0 -0
  9. data/lib/scaffold/generators/locales_generator.rb +0 -0
  10. data/lib/scaffold/generators/models_generator.rb +0 -0
  11. data/lib/scaffold/generators/routes_generator.rb +0 -0
  12. data/lib/scaffold/generators/views_generator.rb +0 -0
  13. data/lib/scaffold/main.rb +0 -0
  14. data/lib/scaffold/models/resource.rb +0 -0
  15. data/lib/scaffold/rails.rb +0 -0
  16. data/lib/scaffold/services/controller.rb +10 -2
  17. data/lib/scaffold/services/nested_in_resources.rb +0 -0
  18. data/lib/scaffold/services/path.rb +0 -0
  19. data/lib/scaffold/services/resource.rb +0 -0
  20. data/lib/scaffold/services/route.rb +0 -0
  21. data/lib/scaffold/services/view.rb +0 -0
  22. data/lib/scaffold/template_engines/slim.rb +0 -0
  23. data/lib/scaffold_pico.rb +0 -0
  24. data/lib/templates/pico/controller.rb.erb +0 -0
  25. data/lib/templates/pico/fabricators/fabrication.rb.erb +0 -0
  26. data/lib/templates/pico/locales/bg.scaffold_pico.yml.erb +0 -0
  27. data/lib/templates/pico/locales/en.scaffold_pico.yml.erb +0 -0
  28. data/lib/templates/pico/model.rb.erb +0 -0
  29. data/lib/templates/pico/views/materialize/slim/_form.html.slim.erb +0 -0
  30. data/lib/templates/pico/views/materialize/slim/edit.html.slim.erb +0 -0
  31. data/lib/templates/pico/views/materialize/slim/index.html.slim.erb +1 -1
  32. data/lib/templates/pico/views/materialize/slim/new.html.slim.erb +0 -0
  33. data/lib/templates/pico/views/materialize/slim/show.html.slim.erb +0 -0
  34. data/lib/templates/pico/views/zurb/slim/_form.html.slim.erb +0 -0
  35. data/lib/templates/pico/views/zurb/slim/edit.html.slim.erb +0 -0
  36. data/lib/templates/pico/views/zurb/slim/index.html.slim.erb +0 -0
  37. data/lib/templates/pico/views/zurb/slim/new.html.slim.erb +0 -0
  38. data/lib/templates/pico/views/zurb/slim/show.html.slim.erb +0 -0
  39. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: f7bf0ebf5a68034b8518d22a937ab8fa981bf9d9
4
- data.tar.gz: '06804700be5657251830719fb3bafeb884519aaf'
3
+ metadata.gz: 05cb9ae933761d5c005549a9b394100a715856d5
4
+ data.tar.gz: 55c7e30fb9c60eda9a0d36678e7141f6c291390b
5
5
  SHA512:
6
- metadata.gz: 95cceedb5fa0ee9fbc17379b6f960259867450d722b73c60be88fda28bd1897ad063263a4e813010cd6306509a3004371c08bd8dffbb36e0af2eb21ffbd068cd
7
- data.tar.gz: 1fb21fb5b70b53dbb8140b51565dfcc869186c6bd563a16face7e34ebf1d9a2b7d31b65f206eda3223114a80f95f7a1fe7002a074705ad486cc437d1c6afe14c
6
+ metadata.gz: 83426759ac134ba0e6d7bb1289de61b250ec3ed22bb9b0e0d9e67380027d93f03efb726a3d6fe193bd3df93bc39142fdfa25e4e7296015840c1b878241d28af5
7
+ data.tar.gz: 3c28e4b8d4238e4b6ab72255c71c3fb71b371922bd85201222e23832c30509bbf98a0414763946f1c492d67ba1ea0a023758e9768f713eb3d2e2fd3dffa9c9a5
File without changes
data/README.md CHANGED
@@ -49,12 +49,12 @@ There is no need to have it in your gem file.
49
49
  If you want to change something you can override/change
50
50
 
51
51
  RAILS_ROOT/config/locales/en.scaffold_pico.yml
52
- RAILS_ROOT/lib/templates/pico
52
+ RAILS_ROOT/lib/templates/pico/
53
53
  /controller.rb
54
54
  /search.rb
55
55
  /fabricators
56
56
  fabrication.rb.erb
57
- /views
57
+ /views/{materialize|zurb} <<< Note !
58
58
  /materialize
59
59
  _form.html.slim.erb
60
60
  edit.html.slim.erb
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
@@ -50,11 +50,19 @@ module Scaffold
50
50
 
51
51
  # which fields will be visible on the index page
52
52
  def index_fields
53
- @rails.choice[:index_fields].blank? ? @rails.resource.fields.keys : @rails.choice[:index_fields]
53
+ if @rails.choice[:index_fields].blank?
54
+ @rails.resource.fields.keys
55
+ else
56
+ @rails.choice[:index_fields].collect{|field| field.split(':').first}
57
+ end
54
58
  end
55
59
 
56
60
  def search_fields
57
- @rails.choice[:search_fields].blank? ? @rails.resource.fields.keys : @rails.choice[:search_fields]
61
+ if @rails.choice[:search_fields].blank?
62
+ @rails.resource.fields.keys
63
+ else
64
+ @rails.choice[:search_fields].collect{|field| field.split(':').first}
65
+ end
58
66
  end
59
67
 
60
68
  # convert company => company_id
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
@@ -55,4 +55,4 @@
55
55
  .card-action
56
56
  = link_to t('scaffold.index.search.reset'), url_for(<%= @rails.path.collection %>), class: 'waves-effect waves-light btn lime lighten-5 black-text'
57
57
  = form.submit t('scaffold.index.search.button'), class: 'right waves-effect waves-light btn'
58
- .clearfix
58
+ .clearfix
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: scaffold_pico
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.5
4
+ version: 1.1.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - gudata
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-03-04 00:00:00.000000000 Z
11
+ date: 2018-04-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport