Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
R
rjs_json_form
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Boris Kocherov
rjs_json_form
Commits
b4d52192
Commit
b4d52192
authored
Sep 26, 2018
by
Boris Kocherov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
make code better understandable
parent
795f8518
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
5 deletions
+5
-5
jsonform/gadget_json_generated_form_child.js
jsonform/gadget_json_generated_form_child.js
+5
-5
No files found.
jsonform/gadget_json_generated_form_child.js
View file @
b4d52192
...
@@ -841,7 +841,7 @@
...
@@ -841,7 +841,7 @@
});
});
}
}
function
render_field
(
gadget
,
key
,
path
,
schema_arr
,
json_document
,
root
,
options
)
{
function
render_field
(
gadget
,
property_name
,
path
,
schema_arr
,
json_document
,
root
,
options
)
{
var
type
,
var
type
,
div
,
div
,
delete_button
,
delete_button
,
...
@@ -870,8 +870,8 @@
...
@@ -870,8 +870,8 @@
options
=
options
||
{};
options
=
options
||
{};
type
=
options
.
type
;
type
=
options
.
type
;
if
(
path
&&
key
)
{
if
(
path
&&
property_name
)
{
first_path
=
path
+
encodeJsonPointer
(
key
);
first_path
=
path
+
encodeJsonPointer
(
property_name
);
}
else
{
}
else
{
first_path
=
""
;
first_path
=
""
;
}
}
...
@@ -916,7 +916,7 @@
...
@@ -916,7 +916,7 @@
if
(
schema
.
description
)
{
if
(
schema
.
description
)
{
div
.
title
=
schema
.
description
;
div
.
title
=
schema
.
description
;
}
}
// if (
key
&& !first_path) {
// if (
property_name
&& !first_path) {
if
(
options
.
delete_button
===
true
)
{
if
(
options
.
delete_button
===
true
)
{
delete_button
=
createElement
(
"
span
"
,
delete_button
=
createElement
(
"
span
"
,
{
"
class
"
:
"
ui-btn-icon-top ui-icon-trash-o
"
}
{
"
class
"
:
"
ui-btn-icon-top ui-icon-trash-o
"
}
...
@@ -936,7 +936,7 @@
...
@@ -936,7 +936,7 @@
}
}
}
}
label_text
=
[
key
,
schema_ob
.
title
]
label_text
=
[
property_name
,
schema_ob
.
title
]
.
filter
(
function
(
v
)
{
return
v
;
})
.
filter
(
function
(
v
)
{
return
v
;
})
.
join
(
"
"
)
.
join
(
"
"
)
// use non-breaking hyphen
// use non-breaking hyphen
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment