graph_starter 0.9.2 → 0.9.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 53c9a32b3cbb8e38d7fe5f4c22d8527467e0b7f4
4
- data.tar.gz: 6f14b707978baa388f539620d7fc6777c38d9948
3
+ metadata.gz: e98f3c7ee6475a49cb99d72b761c13d3a790ff83
4
+ data.tar.gz: 70c586c7ab39e375eb2283835faa2ba534faa465
5
5
  SHA512:
6
- metadata.gz: 2ad7fed5e72ffe6f2f494534cc818c73d9cc3dfe50ec78c04dcb34d27344282ed186bd5f813662ecce92dde31fdfad36ca5329b1cac4ea4b9803ab79091af7ac
7
- data.tar.gz: 55fe1204a0e1a7dad5d32b1a07bc936eb93981da47b1771e531e9974bc1f32adbd47f673a8de6bd4398590046b854a2d4057ec9203d3ed160a5f44833778824e
6
+ metadata.gz: 32003ffb3bb3bbc43ab83e046b317332a7cda0a51342aef9e7223dbf947b3599576f197c5b5fc9ec0f7f69edcd364cf4143d0c2451150e8218990b32257ba112
7
+ data.tar.gz: 900d2853774e51b3bf0baad68387a137528f3bb394237460b7e9a00821aafa22814d887223336d814e6046d526df5b8641e2bed0bc571289924195d9a7fc260e
@@ -25,7 +25,10 @@
25
25
  - field_name = (association.type == :has_many ? "#{name.to_s.singularize}_ids" : "#{name}_id")
26
26
  - target_class = association.target_class
27
27
  - options = target_class.as(:n).pluck(target_class.name_property, target_class.id_property_name)
28
- = f.select field_name, options, {}, class: 'ui fluid search dropdown', multiple: ''
28
+
29
+ - html_options = {class: 'ui fluid search dropdown'}
30
+ - html_options[:multiple] = '' if association.type == :has_many
31
+ = f.select field_name, options, {}, html_options
29
32
 
30
33
  javascript:
31
34
  $('.ui.dropdown').dropdown()
@@ -1,10 +1,11 @@
1
- #menu.ui.secondary.pointing.menu
2
- = link_to 'Home', '/', class: "item #{'active' if request.path == '/'}"
3
- - config = GraphStarter::CONFIG
4
- - menu_models = config.menu_models && config.menu_models.map(&:to_s)
5
- - GraphStarter::Asset.descendants.sort_by {|m| (menu_models || []).index(m.name) || 0 }.each do |model_class|
6
- - next if menu_models && !model_class.name.in?(menu_models)
7
- - path = graph_starter.assets_path(model_slug: model_class.model_slug)
8
- = link_to model_class.name.tableize.humanize, path, class: "item #{'active' if request.path.match(/^#{path}/)}"
1
+ - unless @hide_menu
2
+ #menu.ui.secondary.pointing.menu
3
+ = link_to 'Home', '/', class: "item #{'active' if request.path == '/'}"
4
+ - config = GraphStarter::CONFIG
5
+ - menu_models = config.menu_models && config.menu_models.map(&:to_s)
6
+ - GraphStarter::Asset.descendants.sort_by {|m| (menu_models || []).index(m.name) || 0 }.each do |model_class|
7
+ - next if menu_models && !model_class.name.in?(menu_models)
8
+ - path = graph_starter.assets_path(model_slug: model_class.model_slug)
9
+ = link_to model_class.name.tableize.humanize, path, class: "item #{'active' if request.path.match(/^#{path}/)}"
9
10
 
10
- = render 'layouts/graph_starter/custom_menu'
11
+ = render 'layouts/graph_starter/custom_menu'
@@ -1,3 +1,3 @@
1
1
  module GraphStarter
2
- VERSION = "0.9.2"
2
+ VERSION = "0.9.4"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: graph_starter
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.9.2
4
+ version: 0.9.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brian Underwood
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-11-06 00:00:00.000000000 Z
11
+ date: 2015-11-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails