rails_admin_json_editor 0.0.21 → 0.0.22
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 +4 -4
- data/app/assets/javascripts/rails_admin_json_editor/rails_admin_json_editor.js +3 -2
- data/app/assets/stylesheets/rails_admin_json_editor/rails_admin_json_editor.css.scss +4 -4
- data/app/views/rails_admin_json_editor/main/_form_json_editor.html.erb +2 -8
- data/lib/rails_admin_json_editor/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 968f91b2616b5b8173d266e6cd6e234f6a70c26d
|
4
|
+
data.tar.gz: 6055ffcb8c8b200c33d69f1a65c697b26499a67f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: cca48806246ba0c9f448692363aac96a26261e43031a99e98e509f0d4b6c99ecd11a2755e5e119a4c145d1cbfe10980531234eeae57f13aa427b66df7ab8cbf9
|
7
|
+
data.tar.gz: ad0f98bd509ea66418cf319cdfb278e18e94ce1df02a3117b393a4f7f4bcf5a1200bbb362854a6b7fa6c9765b05214910e46857e24e2636611d9cbdd9401dfa3
|
@@ -125,7 +125,6 @@ $(document).on('rails_admin.dom_ready', function() {
|
|
125
125
|
properties: {}
|
126
126
|
};
|
127
127
|
|
128
|
-
console.log('enableGuids', enableGuids);
|
129
128
|
if(enableGuids) {
|
130
129
|
obj.guid = guid();
|
131
130
|
}
|
@@ -135,7 +134,9 @@ $(document).on('rails_admin.dom_ready', function() {
|
|
135
134
|
},
|
136
135
|
computed: {
|
137
136
|
result: function() {
|
138
|
-
|
137
|
+
var result = { components: this.components };
|
138
|
+
$(this.$el).trigger('json-editor:changed', result);
|
139
|
+
return result;
|
139
140
|
}
|
140
141
|
},
|
141
142
|
components: components
|
@@ -30,9 +30,9 @@ body.rails_admin .form-horizontal.denser .json-editor {
|
|
30
30
|
|
31
31
|
.guid {
|
32
32
|
display: inline-block;
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
margin
|
33
|
+
font-size: 12px;
|
34
|
+
background: #F8F8F8;
|
35
|
+
padding: 0.1em 0.5em;
|
36
|
+
margin: 0 0 -2px 5px;
|
37
37
|
}
|
38
38
|
}
|
@@ -11,7 +11,8 @@
|
|
11
11
|
<script type="text/x-template" id="template-fields-for-<%= model.name %>">
|
12
12
|
<div class="component">
|
13
13
|
<legend>
|
14
|
-
|
14
|
+
<span class="model-label"><%= model.label %></span>
|
15
|
+
<pre class="guid" v-text="component.guid"></pre>
|
15
16
|
|
16
17
|
<div class="btn-group btn-group-sm pull-right">
|
17
18
|
<% if field.orderable %>
|
@@ -37,13 +38,6 @@
|
|
37
38
|
<div v-show="expanded">
|
38
39
|
<%= content_tag :p, model.help, class: "help-block" unless model.help.nil? %>
|
39
40
|
|
40
|
-
<div v-if="component.guid" class="control-group row">
|
41
|
-
<label class="col-sm-2 control-label">Identifier</label>
|
42
|
-
<div class="col-sm-10">
|
43
|
-
<pre class="guid" v-text="component.model_name + ' | ' + component.guid"></pre>
|
44
|
-
</div>
|
45
|
-
</div>
|
46
|
-
|
47
41
|
<% model.fields.each do |f| %>
|
48
42
|
<div class="control-group row <%= f.css_class %>">
|
49
43
|
<label class="col-sm-2 control-label"><%= f.label %></label>
|