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
Levin Zimmermann
erp5
Commits
f25237bf
Commit
f25237bf
authored
May 07, 2021
by
Romain Courteaud
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
erp5_web_renderjs_ui: do not include useless parameters in the url
fixup
nexedi/erp5@e21968ba
parent
cde13458
Changes
8
Show whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
34 additions
and
24 deletions
+34
-24
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_global_js.js
...TemplateItem/web_page_module/rjs_gadget_erp5_global_js.js
+12
-5
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_global_js.xml
...emplateItem/web_page_module/rjs_gadget_erp5_global_js.xml
+2
-2
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_action_js.js
...ateItem/web_page_module/rjs_gadget_erp5_page_action_js.js
+2
-2
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_action_js.xml
...teItem/web_page_module/rjs_gadget_erp5_page_action_js.xml
+2
-2
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_panel_js.js
...hTemplateItem/web_page_module/rjs_gadget_erp5_panel_js.js
+8
-6
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_panel_js.xml
...TemplateItem/web_page_module/rjs_gadget_erp5_panel_js.xml
+2
-2
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_tabpage_js.js
...lateItem/web_page_module/rjs_gadget_erp5_pt_tabpage_js.js
+4
-3
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_tabpage_js.xml
...ateItem/web_page_module/rjs_gadget_erp5_pt_tabpage_js.xml
+2
-2
No files found.
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_global_js.js
View file @
f25237bf
...
...
@@ -172,6 +172,7 @@
action_type
,
current_href
,
class_name
,
extra_options
,
options
,
command
,
group_mapping
=
{},
...
...
@@ -256,29 +257,35 @@
group_mapping
[
group
][
i
].
action_type
.
indexOf
(
"
_raw
"
)
!==
-
1
)
{
command
=
"
raw
"
;
options
=
{
title
:
group_mapping
[
group
][
i
].
title
,
url
:
group_mapping
[
group
][
i
].
href
};
extra_options
=
{
title
:
group_mapping
[
group
][
i
].
title
};
}
else
{
command
=
command_mapping
[
group
]
||
default_command_mapping
[
group
];
options
=
{
title
:
group_mapping
[
group
][
i
].
title
,
class_name
:
class_name
,
jio_key
:
jio_key
,
view
:
group_mapping
[
group
][
i
].
href
,
editable
:
editable_mapping
[
group
]
};
extra_options
=
{
title
:
group_mapping
[
group
][
i
].
title
,
class_name
:
class_name
};
}
if
(
group
===
"
view
"
)
{
// Views in ERP5 must be forms but because of
// OfficeJS we keep it empty for different default
options
.
page
=
undefined
;
}
url_mapping
[
group
].
push
({
extra_options
.
url_kw
=
{
command
:
command
,
absolute_url
:
command
===
"
raw
"
?
true
:
false
,
options
:
options
});
};
url_mapping
[
group
].
push
(
extra_options
);
}
}
}
...
...
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_global_js.xml
View file @
f25237bf
...
...
@@ -234,7 +234,7 @@
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
99
0.47062.36646.8226
</string>
</value>
<value>
<string>
99
1.63236.62412.49203
</string>
</value>
</item>
<item>
<key>
<string>
state
</string>
</key>
...
...
@@ -252,7 +252,7 @@
</tuple>
<state>
<tuple>
<float>
16
15825369.82
</float>
<float>
16
20739824.54
</float>
<string>
UTC
</string>
</tuple>
</state>
...
...
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_action_js.js
View file @
f25237bf
...
...
@@ -101,7 +101,7 @@
for
(
i
=
0
;
i
<
group_list
.
length
;
i
+=
2
)
{
for
(
j
=
0
;
j
<
group_list
[
i
].
length
;
j
+=
1
)
{
url_for_kw_list
.
push
(
group_list
[
i
][
j
]);
url_for_kw_list
.
push
(
group_list
[
i
][
j
]
.
url_kw
);
}
}
...
...
@@ -125,7 +125,7 @@
link_list
=
[];
for
(
j
=
0
;
j
<
group_list
[
i
].
length
;
j
+=
1
)
{
link_list
.
push
({
title
:
group_list
[
i
][
j
].
options
.
title
,
title
:
group_list
[
i
][
j
].
title
,
link
:
result_dict
.
url_list
[
k
]
});
k
+=
1
;
...
...
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_page_action_js.xml
View file @
f25237bf
...
...
@@ -234,7 +234,7 @@
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
99
0.5865.43433.1774
</string>
</value>
<value>
<string>
99
1.59072.18419.59613
</string>
</value>
</item>
<item>
<key>
<string>
state
</string>
</key>
...
...
@@ -252,7 +252,7 @@
</tuple>
<state>
<tuple>
<float>
16
13612772.39
</float>
<float>
16
20395667.38
</float>
<string>
UTC
</string>
</tuple>
</state>
...
...
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_panel_js.js
View file @
f25237bf
...
...
@@ -24,12 +24,12 @@
dd_element
=
document
.
createElement
(
'
dd
'
);
dd_element
.
setAttribute
(
'
class
'
,
'
document-listview
'
);
a_element
=
document
.
createElement
(
'
a
'
);
if
(
action_list
[
i
].
options
&&
action_list
[
i
].
options
.
class_name
)
{
if
(
action_list
[
i
].
class_name
)
{
// Avoid add class='undefined' in HTML
a_element
.
setAttribute
(
'
class
'
,
action_list
[
i
].
options
.
class_name
);
a_element
.
setAttribute
(
'
class
'
,
action_list
[
i
].
class_name
);
}
a_element
.
href
=
href_list
[
index
+
i
];
a_element
.
textContent
=
action_list
[
i
].
options
.
title
;
a_element
.
textContent
=
action_list
[
i
].
title
;
dd_element
.
appendChild
(
a_element
);
fragment
.
appendChild
(
dd_element
);
}
...
...
@@ -277,7 +277,9 @@
parameter_list
=
view_list
.
concat
(
workflow_list
).
concat
(
action_list
).
concat
(
clone_list
).
concat
(
jump_list
);
).
concat
(
clone_list
).
concat
(
jump_list
).
map
(
function
(
options
)
{
return
options
.
url_kw
;
});
return
RSVP
.
all
([
gadget
.
getUrlForList
(
parameter_list
),
gadget
.
getTranslationList
([
'
Views
'
,
'
Workflows
'
,
'
Actions
'
,
...
...
@@ -311,11 +313,11 @@
var
extra_menu_list
=
JSON
.
parse
(
gadget
.
state
.
extra_menu_list
),
href_list
=
[];
for
(
i
=
0
;
i
<
extra_menu_list
.
length
;
i
+=
1
)
{
extra_menu_list
[
i
].
options
=
{
href_list
.
push
(
extra_menu_list
[
i
].
href
);
extra_menu_list
[
i
]
=
{
"
class_name
"
:
extra_menu_list
[
i
].
active
?
"
active
"
:
""
,
"
title
"
:
extra_menu_list
[
i
].
title
};
href_list
.
push
(
extra_menu_list
[
i
].
href
);
}
appendDt
(
dl_fragment
,
translation_list
[
0
],
'
globe
'
,
extra_menu_list
,
href_list
,
0
);
...
...
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_panel_js.xml
View file @
f25237bf
...
...
@@ -234,7 +234,7 @@
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
99
0.38408.14.44134
</string>
</value>
<value>
<string>
99
1.63550.23294.43315
</string>
</value>
</item>
<item>
<key>
<string>
state
</string>
</key>
...
...
@@ -252,7 +252,7 @@
</tuple>
<state>
<tuple>
<float>
16
15306118.36
</float>
<float>
16
20660511.51
</float>
<string>
UTC
</string>
</tuple>
</state>
...
...
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_tabpage_js.js
View file @
f25237bf
...
...
@@ -113,7 +113,8 @@
view_list
=
group_mapping
.
view
;
jump_list
=
group_mapping
.
action_object_jio_jump
;
url_for_kw_list
=
url_for_kw_list
.
concat
(
view_list
).
concat
(
jump_list
);
url_for_kw_list
=
url_for_kw_list
.
concat
(
view_list
).
concat
(
jump_list
)
.
map
(
function
(
options
)
{
return
options
.
url_kw
;
});
url_for_kw_list
.
push
({
command
:
'
cancel_dialog_with_history
'
});
return
RSVP
.
hash
({
...
...
@@ -131,14 +132,14 @@
for
(
i
=
0
;
i
<
view_list
.
length
;
i
+=
1
)
{
tab_list
.
push
({
title
:
view_list
[
i
].
options
.
title
,
title
:
view_list
[
i
].
title
,
link
:
result_dict
.
url_list
[
j
]
});
j
+=
1
;
}
for
(
i
=
0
;
i
<
jump_list
.
length
;
i
+=
1
)
{
jump_action_list
.
push
({
title
:
jump_list
[
i
].
options
.
title
,
title
:
jump_list
[
i
].
title
,
link
:
result_dict
.
url_list
[
j
]
});
j
+=
1
;
...
...
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_tabpage_js.xml
View file @
f25237bf
...
...
@@ -234,7 +234,7 @@
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
99
0.58741.8.3606
1
</string>
</value>
<value>
<string>
99
1.63294.25048.802
1
</string>
</value>
</item>
<item>
<key>
<string>
state
</string>
</key>
...
...
@@ -252,7 +252,7 @@
</tuple>
<state>
<tuple>
<float>
16
16691370.71
</float>
<float>
16
20645031.39
</float>
<string>
UTC
</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