admini 0.2.0 → 0.2.1

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: b54a44f81ceacbb98218300cb0915549dd4c521a
4
- data.tar.gz: 2efb51f3cc96b43615c00c772d266ae267d52932
3
+ metadata.gz: 5c06008337ecd8476cb30f39298f8a162579ac68
4
+ data.tar.gz: 0fb4c9ca5ab44343a8d7313afff22fec7c93b6bb
5
5
  SHA512:
6
- metadata.gz: ed58c33259ae1e04a3426a5b5cba4de0e7c7b02b39a51de3e6668ee268258b17fea6a10bb31c67aec7a084207764123d301d2a2e76d130be2f1ad6213b7c0182
7
- data.tar.gz: 9729485865f0afc978230496c313253e9b18034fe46c82232451670173d7fb43a5cb9e3d62ac5d1e4c0187caf3d4290cc3cbfb6f3e659391dedf8aaef98c1e7d
6
+ metadata.gz: 8b8a5af21d18a56c835bc6b0d340e93edc16a53b57efabad6ba87865dbf969ac89daa877724beb37e4574228953aa65ae5225e8f466466eb4af518b63323023d
7
+ data.tar.gz: 33d720d8ddbbc43bff779d7d5c3a7b75808c4ee7382d573f0e3c783e6333e155a43b2d112b70d5a5dfae496407c8521df6934cc54a66472b9c931c54902e3017
data/README.md CHANGED
@@ -140,7 +140,6 @@ Here is an example that renders a title with link to post instead of just title.
140
140
  ```ruby
141
141
  class Admin::PostsController < Admin::ApplicationController
142
142
  include Admini::Resources
143
- include ActionView::Helpers::UrlHelper
144
143
 
145
144
  private
146
145
 
@@ -151,7 +150,7 @@ class Admin::PostsController < Admin::ApplicationController
151
150
  else
152
151
  post_path(resource)
153
152
  end
154
- link_to resource.title, path
153
+ view_context.link_to resource.title, path
155
154
  end
156
155
  end
157
156
  ```
@@ -332,11 +331,6 @@ class Admin::ApplicationController < ActionController::Base
332
331
  end
333
332
  ```
334
333
 
335
- ## ToDo
336
-
337
- - [ ] Add spec
338
- - [ ] Improve README (Because I'm not good at English :no_good:)
339
-
340
334
  ## Need help?
341
335
 
342
336
  Feel free to ask me in [Issues](https://github.com/kami-zh/admini/issues) or [author's twitter](https://twitter.com/kami_zh).
@@ -103,7 +103,7 @@ module Admini
103
103
  unless search_attributes.include?(params[:attribute].try(:to_sym))
104
104
  return
105
105
  end
106
- @resources = @resources.where("#{params[:attribute]} LIKE ?", "%#{params[:value]}%")
106
+ @resources = @resources.where("LOWER(#{params[:attribute]}) LIKE ?", "%#{params[:value].downcase}%")
107
107
  end
108
108
 
109
109
  def index_attributes
@@ -1,3 +1,3 @@
1
1
  module Admini
2
- VERSION = '0.2.0'
2
+ VERSION = '0.2.1'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: admini
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - kami
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-10-04 00:00:00.000000000 Z
11
+ date: 2016-10-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: actionview