Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
E
ecommerce-ui
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
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
ecommerce-ui
Commits
43b37318
Commit
43b37318
authored
Mar 04, 2014
by
Sven Franck
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
added in-page panel for Cedric
parent
86d59f3f
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
29 additions
and
6 deletions
+29
-6
data/person.json
data/person.json
+15
-2
js/erp5_loader.js
js/erp5_loader.js
+14
-4
No files found.
data/person.json
View file @
43b37318
...
...
@@ -15,8 +15,21 @@
"generate"
:
"gadget"
,
"type"
:
"listbox"
,
"href"
:
"person_overview"
}
],
},{
"generate"
:
"widget"
,
"type"
:
"panel"
,
"id"
:
"cedric"
,
"theme"
:
"slapos-white"
,
"property_dict"
:
{
"close"
:
null
},
"children"
:
[{
"type"
:
"p"
,
"direct"
:
{},
"attributes"
:
{},
"logic"
:
{
"text"
:
"Hello Cedric"
}
}]
}],
"new"
:
[
{
"generate"
:
"gadget"
,
...
...
js/erp5_loader.js
View file @
43b37318
...
...
@@ -3330,8 +3330,8 @@
// add to DOM if scoped
if
(
url_dict
.
data_url
)
{
util
.
getPanel
(
url_dict
.
data_url
).
appendChild
(
panel
);
return
undefined
;
//
util.getPanel(url_dict.data_url).appendChild(panel);
return
panel
;
}
else
{
document
.
body
.
insertBefore
(
panel
,
document
.
body
.
children
[
0
]);
}
...
...
@@ -4281,7 +4281,7 @@
// NOTE: we are defaulting to fixed JQM toolbars! layout
factory
.
page
=
function
(
content_dict
,
url_dict
,
create
)
{
var
i
,
j
,
last
,
wrapper
,
split_url
,
promises
=
[],
container
,
target
,
view
,
render
,
encoded
;
view
,
render
,
encoded
,
temp
;
container
=
util
.
getPage
(
url_dict
.
data_url
);
view
=
(
url_dict
&&
url_dict
.
mode
)
?
url_dict
.
mode
:
"
default
"
;
...
...
@@ -4308,8 +4308,12 @@
util
.
error
(
"
page: Element not found
"
);
util
.
loader
(
""
,
"
status_dict.not_found
"
,
"
ban-circle
"
);
}
if
(
util
.
testForString
(
"
panel
"
,
promises
[
j
].
className
))
{
temp
=
promises
[
j
];
}
else
{
target
.
appendChild
(
promises
[
j
]);
}
}
// page does not exist
if
(
container
===
null
||
create
===
true
)
{
...
...
@@ -4366,6 +4370,12 @@
}
}
// add panel
if
(
temp
)
{
container
.
appendChild
(
temp
);
$
(
temp
).
panel
();
}
// update header before changing to a new page/or back to home
if
(
create
!==
false
)
{
app
.
setPageTitle
(
...
...
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