Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5
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
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Laurent S
erp5
Commits
4bcd41ff
Commit
4bcd41ff
authored
Feb 16, 2015
by
Sven Franck
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
erp5_web_renderjs_ui: re-enable allow_create, not active for now
parent
436184d3
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
22 additions
and
14 deletions
+22
-14
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_relationstringfield_js.xml
...eb_page_module/rjs_gadget_erp5_relationstringfield_js.xml
+22
-14
No files found.
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_relationstringfield_js.xml
View file @
4bcd41ff
...
...
@@ -173,14 +173,14 @@ promiseEventListener */\n
\n
subfield = document.createElement("input");\n
subfield.setAttribute("type", "hidden");\n
subfield.setAttribute("name", field_json.relation_
item_key
);\n
subfield.setAttribute("name", field_json.relation_
field_id
);\n
subfield.setAttribute("value", "_newContent_" + info);\n
\n
default_subfield = document.createElement("input");\n
default_subfield.setAttribute("type", "hidden");\n
default_subfield.setAttribute(\n
"name",\n
"default_subfield_" + field_json.key + "_relation"\n
"default_subfield_" + field_json.key + "_relation
:int
"\n
);\n
default_subfield.setAttribute("value", 0);\n
\n
...
...
@@ -319,11 +319,13 @@ promiseEventListener */\n
props.spinner.className =
"ui-hidden-accessible"
;\n
no_results =
result_dict.total_rows
===
0;\n
\n
//
show
"new"
tag\n
//
show
"new"
tag,
clicking
it
will
remove
it
and
reset
the
field!\n
//
XXX
Not
active
-
reset
should
be
handled
by
a
generic
reset
method!\n
if
(no_results
&&
field_json.allow_creation)
{\n
return
new
RSVP.Queue()\n
.push(function
()
{\n
props.wrapper.appendChild(createNewTag(my_gadget));\n
my_gadget.property_dict.valid =
true;\n
return
notifyChange(my_gadget);\n
})\n
.push(function
()
{\n
...
...
@@ -333,12 +335,19 @@ promiseEventListener */\n
promiseEventListener(tag,
"tap",
true)\n
]);\n
})\n
.push(function
()
{\n
var
original_value =
field_json.value
||
field_json.default
||
"";\n
clearResults(my_gadget);\n
props.wrapper.querySelector("input")
.value =
original_value;\n
return
triggerAutocomplete(my_gadget,
original_value);\n
});\n
.push(function
(my_event_to_clear)
{\n
var
wrapper,\n
tag_list,\n
original_value;\n
\n
my_event_to_clear.preventDefault();\n
original_value =
field_json.value
||
field_json.default
||
"";\n
wrapper =
props.wrapper;\n
wrapper.querySelector("input")
.value =
original_value;\n
tag_list =
wrapper.querySelector(".ui-tag-list");\n
tag_list.parentNode.removeChild(tag_list);\n
return
setRelationJump(my_gadget,
undefined);\n
})\n
}\n
\n
//
default
autocomplete\n
...
...
@@ -367,9 +376,8 @@ promiseEventListener */\n
var
element,\n
jump_url;\n
\n
if
(my_selection_event)
{\n
\n
//
take
entered
text,
set
to
input
and
clear
list
options\n
//
take
entered
text,
set
to
input
and
clear
list
options\n
if
(my_selection_event
&&
my_selection_event.target)
{\n
element =
my_selection_event.target;\n
jump_url =
element.getAttribute("data-relative-url");\n
props.selected_uid =
element.getAttribute("name");\n
...
...
@@ -745,7 +753,7 @@ promiseEventListener */\n
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
941.
954.47433.61593
</string>
</value>
<value>
<string>
941.
1041.20854.22596
</string>
</value>
</item>
<item>
<key>
<string>
state
</string>
</key>
...
...
@@ -763,7 +771,7 @@ promiseEventListener */\n
</tuple>
<state>
<tuple>
<float>
1424
099091.91
</float>
<float>
1424
104195.48
</float>
<string>
GMT
</string>
</tuple>
</state>
...
...
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