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
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Gabriel Monnerat
erp5
Commits
9cd36bec
Commit
9cd36bec
authored
Nov 23, 2020
by
Gabriel Monnerat
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
WIP erp5_web_renderjs_ui: show tools on module list
parent
b2c19a3f
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
25 additions
and
11 deletions
+25
-11
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_frontpage_js.js
...teItem/web_page_module/rjs_gadget_erp5_pt_frontpage_js.js
+23
-9
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_frontpage_js.xml
...eItem/web_page_module/rjs_gadget_erp5_pt_frontpage_js.xml
+2
-2
No files found.
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_frontpage_js.js
View file @
9cd36bec
...
@@ -52,7 +52,8 @@
...
@@ -52,7 +52,8 @@
// First, get the list of modules
// First, get the list of modules
return
gadget
.
jio_allDocs
({
return
gadget
.
jio_allDocs
({
select_list
:
select_list
,
select_list
:
select_list
,
query
:
'
(parent_uid:"0" AND meta_type:"ERP5 Folder" AND id:"%_module")
'
,
// XXX XXX XXX How to search tools only when developper mode is activated?
query
:
'
(parent_uid:"0" AND (meta_type:"ERP5 Folder" AND id:"%_module") OR (id:"portal_%"))
'
,
limit
:
1000
limit
:
1000
})
})
.
push
(
function
(
result_list
)
{
.
push
(
function
(
result_list
)
{
...
@@ -109,6 +110,7 @@
...
@@ -109,6 +110,7 @@
card_list
=
[],
card_list
=
[],
module_list
=
[],
module_list
=
[],
other_module_list
=
[],
other_module_list
=
[],
tool_list
=
[],
current_business_application_title
=
''
;
current_business_application_title
=
''
;
function
pushNewCard
()
{
function
pushNewCard
()
{
...
@@ -128,6 +130,11 @@
...
@@ -128,6 +130,11 @@
for
(
i
=
0
;
i
<
len
;
i
+=
1
)
{
for
(
i
=
0
;
i
<
len
;
i
+=
1
)
{
// Inject the module url into the document
// Inject the module url into the document
document_list
[
i
].
link
=
url_list
[
i
];
document_list
[
i
].
link
=
url_list
[
i
];
// Tools do not have any business application
// Workaround this limitation
if
(
document_list
[
i
].
id
.
indexOf
(
'
portal_
'
)
===
0
)
{
tool_list
.
push
(
document_list
[
i
]);
}
else
{
// Create card if needed
// Create card if needed
if
(
document_list
[
i
].
business_application_translated_title
!==
if
(
document_list
[
i
].
business_application_translated_title
!==
current_business_application_title
)
{
current_business_application_title
)
{
...
@@ -138,6 +145,7 @@
...
@@ -138,6 +145,7 @@
}
}
module_list
.
push
(
document_list
[
i
]);
module_list
.
push
(
document_list
[
i
]);
}
}
}
pushNewCard
();
pushNewCard
();
if
(
other_module_list
.
length
)
{
if
(
other_module_list
.
length
)
{
card_list
.
push
({
card_list
.
push
({
...
@@ -145,6 +153,12 @@
...
@@ -145,6 +153,12 @@
module_list
:
other_module_list
module_list
:
other_module_list
});
});
}
}
if
(
tool_list
.
length
)
{
card_list
.
push
({
business_application_translated_title
:
'
XXX Tools to translate
'
,
module_list
:
tool_list
});
}
generateCardList
(
gadget
.
element
.
querySelector
(
'
ul
'
),
card_list
);
generateCardList
(
gadget
.
element
.
querySelector
(
'
ul
'
),
card_list
);
...
...
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_frontpage_js.xml
View file @
9cd36bec
...
@@ -234,7 +234,7 @@
...
@@ -234,7 +234,7 @@
</item>
</item>
<item>
<item>
<key>
<string>
serial
</string>
</key>
<key>
<string>
serial
</string>
</key>
<value>
<string>
986.541
25.60966.30924
</string>
</value>
<value>
<string>
986.541
19.40309.54067
</string>
</value>
</item>
</item>
<item>
<item>
<key>
<string>
state
</string>
</key>
<key>
<string>
state
</string>
</key>
...
@@ -252,7 +252,7 @@
...
@@ -252,7 +252,7 @@
</tuple>
</tuple>
<state>
<state>
<tuple>
<tuple>
<float>
160095
7441.4
2
</float>
<float>
160095
2515.7
2
</float>
<string>
UTC
</string>
<string>
UTC
</string>
</tuple>
</tuple>
</state>
</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