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
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
francois
erp5
Commits
b09ac1af
Commit
b09ac1af
authored
Dec 06, 2016
by
Romain Courteaud
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[erp5_web_renderjs_ui] Use a document fragment to build the page content
parent
990a3253
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
23 deletions
+20
-23
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_launcher_js.js
...mplateItem/web_page_module/rjs_gadget_erp5_launcher_js.js
+20
-23
No files found.
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_launcher_js.js
View file @
b09ac1af
...
@@ -461,12 +461,10 @@
...
@@ -461,12 +461,10 @@
.
push
(
function
(
main_gadget
)
{
.
push
(
function
(
main_gadget
)
{
// Append loaded gadget in the page
// Append loaded gadget in the page
if
(
main_gadget
!==
undefined
)
{
if
(
main_gadget
!==
undefined
)
{
return
main_gadget
.
getElement
()
.
push
(
function
(
fragment
)
{
var
element
=
gadget
.
props
.
content_element
,
var
element
=
gadget
.
props
.
content_element
,
content_container
=
document
.
createElement
(
"
div
"
);
content_container
=
document
.
createDocumentFragment
(
);
content_container
.
className
=
"
ui-content
"
+
//
content_container.className = "ui-content " +
(
gadget
.
props
.
sub_header_class
||
""
);
//
(gadget.props.sub_header_class || "");
// reset subheader indicator
// reset subheader indicator
delete
gadget
.
props
.
sub_header_class
;
delete
gadget
.
props
.
sub_header_class
;
...
@@ -477,13 +475,12 @@
...
@@ -477,13 +475,12 @@
while
(
element
.
firstChild
)
{
while
(
element
.
firstChild
)
{
element
.
removeChild
(
element
.
firstChild
);
element
.
removeChild
(
element
.
firstChild
);
}
}
content_container
.
appendChild
(
frag
ment
);
content_container
.
appendChild
(
main_gadget
.
ele
ment
);
element
.
appendChild
(
content_container
);
element
.
appendChild
(
content_container
);
return
updateHeader
(
gadget
);
return
updateHeader
(
gadget
);
// XXX Drop notification
// XXX Drop notification
// return header_gadget.notifyLoaded();
// return header_gadget.notifyLoaded();
});
}
}
});
});
}
}
...
...
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