express_admin 1.6.1 → 1.6.2

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: b7506c6470c547440b995022d7e43a0870e104c3
4
- data.tar.gz: 5af377c17f7a68e8b803a2f0abbc1b01d04f6606
3
+ metadata.gz: 707d79b70437794485e68269636b019ed519b409
4
+ data.tar.gz: 421297d6d814654bb04624de86bd06edece46960
5
5
  SHA512:
6
- metadata.gz: 0811310b3ad2e10e76b0e2d72f9d6e8d9698880fbec890a4f90018a700d4b7a49016163528c707956202274ca572f99b1611b830f4a29438581dfaf8711a3211
7
- data.tar.gz: e69ee46045156ce056db8438deb34489984e9a5b52a9bb6988ebb308ab4026d9e68998f5a480a714c13470bc8d658598a7caef0e102724ac1548aafd248b5c3d
6
+ metadata.gz: 0e3ca274eb1714b8f6e4cd5fb26db88051ab4e8fe59714493d930aa0f132cce2ec4eb0d668441056d448b9a5492e4e59481f9d38da4e2145a6fb3ffbee08eb8b
7
+ data.tar.gz: 1fc7d52884145fe37656d7ff4d6b5d5588d1bd7a753459a224017d0f4a74870b11015aec38bf6fce374bb919b3c520d66e3e176354ed3b0575643d7a15524456
@@ -115,7 +115,7 @@ module ExpressAdmin
115
115
  def cell_value(item, accessor)
116
116
  value = if accessor.respond_to?(:call)
117
117
  begin
118
- accessor.call(item).html_safe
118
+ accessor.call(item).try(:html_safe)
119
119
  rescue
120
120
  'Error: '+$!.to_s
121
121
  end
@@ -87,14 +87,14 @@ module ExpressAdmin
87
87
  build_resource
88
88
  load_collection
89
89
  respond_to do |format|
90
- format.html { render :index, layout: defaults[:layout] }
90
+ format.html { render index_view, layout: defaults[:layout] }
91
91
  end
92
92
  end
93
93
 
94
94
  def new
95
95
  build_resource
96
96
  respond_to do |format|
97
- format.html { render :new, layout: defaults[:layout] }
97
+ format.html { render new_view, layout: defaults[:layout] }
98
98
  end
99
99
  end
100
100
 
@@ -106,7 +106,7 @@ module ExpressAdmin
106
106
  end
107
107
  else
108
108
  respond_to do |format|
109
- format.html { render :new, layout: defaults[:layout] }
109
+ format.html { render new_view, layout: defaults[:layout] }
110
110
  end
111
111
  end
112
112
  end
@@ -115,14 +115,14 @@ module ExpressAdmin
115
115
  load_resource
116
116
  load_collection
117
117
  respond_to do |format|
118
- format.html { render :show, layout: defaults[:layout] }
118
+ format.html { render show_view, layout: defaults[:layout] }
119
119
  end
120
120
  end
121
121
 
122
122
  def edit
123
123
  load_resource
124
124
  respond_to do |format|
125
- format.html { render :edit, layout: defaults[:layout] }
125
+ format.html { render edit_view, layout: defaults[:layout] }
126
126
  end
127
127
  end
128
128
 
@@ -134,7 +134,7 @@ module ExpressAdmin
134
134
  end
135
135
  else
136
136
  respond_to do |format|
137
- format.html { render :edit, layout: defaults[:layout] }
137
+ format.html { render edit_view, layout: defaults[:layout] }
138
138
  end
139
139
  end
140
140
  end
@@ -148,6 +148,23 @@ module ExpressAdmin
148
148
  end
149
149
 
150
150
  protected
151
+
152
+ def edit_view
153
+ :edit
154
+ end
155
+
156
+ def new_view
157
+ :new
158
+ end
159
+
160
+ def show_view
161
+ :show
162
+ end
163
+
164
+ def index_view
165
+ :index
166
+ end
167
+
151
168
  def resource_path
152
169
  proxy = route_proxy
153
170
  proxy ||= self
@@ -1,3 +1,3 @@
1
1
  module ExpressAdmin
2
- VERSION = "1.6.1"
2
+ VERSION = "1.6.2"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: express_admin
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.6.1
4
+ version: 1.6.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Steven Talcott Smith