inline_forms 1.6.57 → 1.6.58
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.
checksums.yaml
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
---
|
|
2
2
|
!binary "U0hBMQ==":
|
|
3
3
|
metadata.gz: !binary |-
|
|
4
|
-
|
|
4
|
+
NmM0ZjljOTYxMzQzYzUwODczYmNlMzZmN2I3ZmJhY2IyYTYxYmQyNg==
|
|
5
5
|
data.tar.gz: !binary |-
|
|
6
|
-
|
|
7
|
-
|
|
6
|
+
NjNhYTM2MTQwZTZmNTZmNmU5ZjM3NTk2N2ViZjgzMWE5MzJhYjc4MA==
|
|
7
|
+
SHA512:
|
|
8
8
|
metadata.gz: !binary |-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
MWM1YWMzY2Q3OWFjZDE5NmJhMWE1MDY5NjUxMjZlZjkxYmZhMzNiM2JlMDhh
|
|
10
|
+
OGNiODM5NDIzODFhMjcxZTQ5YzM5ZjE1YzM4OTQ2MzhmNjZiZjA4ZTkwN2M3
|
|
11
|
+
YTg3NmUyZjljNzNjM2M0YWQ3NDRiMmUzOWY5NzE1NDhmOGNhMzg=
|
|
12
12
|
data.tar.gz: !binary |-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
13
|
+
MzU0YzA4YTE1MzVlYjdjYzUxOGYzMzhlMDk4YjU2NGZhOGQ5YTdmY2NlNTUy
|
|
14
|
+
ZmQxZDVjOTU2MTI4OGRiYzRlZTkxZjQ3MDEwODIyNGQ3ZGQ5M2YzYTRiYzU0
|
|
15
|
+
ZWZiNTJhYzQyZGJkZDI4ZGZhYjg0MjIxZmI2OGY1ZTAxMTY3MWM=
|
|
@@ -9,9 +9,8 @@ class InlineFormsApplicationController < ActionController::Base
|
|
|
9
9
|
#set the locale based on the subdomain
|
|
10
10
|
def set_locale
|
|
11
11
|
I18n.locale = extract_locale_from_subdomain || I18n.default_locale
|
|
12
|
-
|
|
13
12
|
end
|
|
14
|
-
|
|
13
|
+
|
|
15
14
|
# Get locale code from request subdomain (like http://it.application.local:3000)
|
|
16
15
|
def extract_locale_from_subdomain
|
|
17
16
|
locale = request.subdomains.first
|
|
@@ -9,13 +9,14 @@ def text_area_show(object, attribute)
|
|
|
9
9
|
cktext_area_tag(
|
|
10
10
|
attribute,
|
|
11
11
|
object[attribute],
|
|
12
|
-
:
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
12
|
+
:id => "textarea_#{object.class.name.underscore}_#{object.id}_#{attribute.to_s}",
|
|
13
|
+
:ckeditor => { :width => '100%',
|
|
14
|
+
:height => '200px',
|
|
15
|
+
:toolbar => "None",
|
|
16
|
+
:readOnly => "true",
|
|
17
|
+
:resize_enabled => "false",
|
|
18
|
+
:toolbarCanCollapse => "false"
|
|
19
|
+
}
|
|
19
20
|
) +
|
|
20
21
|
image_tag( 'glass_plate.gif',
|
|
21
22
|
:class => "glass_plate",
|
|
@@ -31,9 +32,10 @@ def text_area_edit(object, attribute)
|
|
|
31
32
|
cktext_area_tag(
|
|
32
33
|
attribute,
|
|
33
34
|
object[attribute],
|
|
34
|
-
:
|
|
35
|
-
|
|
36
|
-
|
|
35
|
+
:id => "textarea_#{object.class.name.underscore}_#{object.id}_#{attribute.to_s}",
|
|
36
|
+
:ckeditor => { :width => '100%',
|
|
37
|
+
:height => '200px'
|
|
38
|
+
}
|
|
37
39
|
)
|
|
38
40
|
else
|
|
39
41
|
text_area_tag attribute, object[attribute], :class => 'attribute_text_area'
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
<% @BUTTONS_UNDER = [ "text_area" ] %>
|
|
1
2
|
<%= form_tag send(@object.class.to_s.underscore + '_path', :update => @update_span,
|
|
2
3
|
:attribute => @attribute,
|
|
3
4
|
:form_element => @form_element,
|
|
@@ -7,23 +8,49 @@
|
|
|
7
8
|
:class => "edit_form",
|
|
8
9
|
:abide => true,
|
|
9
10
|
:remote => true do -%>
|
|
10
|
-
|
|
11
|
-
<div class="
|
|
12
|
-
|
|
11
|
+
<% if @BUTTONS_UNDER.include? @form_element %>
|
|
12
|
+
<div class="row collapse">
|
|
13
|
+
<div class="small-12 columns">
|
|
14
|
+
<%= send("#{@form_element}_edit", @object, @attribute) %>
|
|
15
|
+
</div>
|
|
13
16
|
</div>
|
|
14
|
-
<div class="
|
|
15
|
-
|
|
17
|
+
<div class="row collapse">
|
|
18
|
+
<div class="small-9 columns">
|
|
19
|
+
|
|
20
|
+
</div>
|
|
21
|
+
<div class="small-1 columns">
|
|
22
|
+
<%= submit_tag "ok", :class => "postfix button"-%>
|
|
23
|
+
</div>
|
|
24
|
+
<div class="small-2 columns">
|
|
25
|
+
<%= link_to( send( @object.class.to_s.underscore + '_path', :update => @update_span || "field_#{@attribute}_#{@object.id.to_s}",
|
|
26
|
+
:attribute => @attribute,
|
|
27
|
+
:form_element => @form_element,
|
|
28
|
+
:sub_id => @sub_id ),
|
|
29
|
+
:method => :get, # this is going to the show method!
|
|
30
|
+
:remote => true ) do %>
|
|
31
|
+
<input type="button" name="cancel" value="cancel" class="button alert postfix radius" />
|
|
32
|
+
<% end %>
|
|
33
|
+
</div>
|
|
16
34
|
</div>
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
35
|
+
<% else %>
|
|
36
|
+
<div class="row collapse">
|
|
37
|
+
<div class="small-9 columns">
|
|
38
|
+
<%= send("#{@form_element}_edit", @object, @attribute) %>
|
|
39
|
+
</div>
|
|
40
|
+
<div class="small-1 columns">
|
|
41
|
+
<%= submit_tag "ok", :class => "postfix button"-%>
|
|
42
|
+
</div>
|
|
43
|
+
<div class="small-2 columns">
|
|
44
|
+
<%= link_to( send( @object.class.to_s.underscore + '_path', :update => @update_span || "field_#{@attribute}_#{@object.id.to_s}",
|
|
45
|
+
:attribute => @attribute,
|
|
46
|
+
:form_element => @form_element,
|
|
47
|
+
:sub_id => @sub_id ),
|
|
48
|
+
:method => :get, # this is going to the show method!
|
|
49
|
+
:remote => true ) do %>
|
|
50
|
+
<input type="button" name="cancel" value="cancel" class="button alert postfix radius" />
|
|
51
|
+
<% end %>
|
|
52
|
+
</div>
|
|
26
53
|
</div>
|
|
27
|
-
|
|
54
|
+
<% end%>
|
|
28
55
|
|
|
29
56
|
<% end -%>
|
data/lib/inline_forms/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: inline_forms
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.6.
|
|
4
|
+
version: 1.6.58
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Ace Suares
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2014-02-
|
|
11
|
+
date: 2014-02-22 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: rvm
|
|
@@ -288,7 +288,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
288
288
|
version: '0'
|
|
289
289
|
requirements: []
|
|
290
290
|
rubyforge_project: inline_forms
|
|
291
|
-
rubygems_version: 2.
|
|
291
|
+
rubygems_version: 2.1.9
|
|
292
292
|
signing_key:
|
|
293
293
|
specification_version: 4
|
|
294
294
|
summary: Inline editing of forms.
|