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
alecs_myu
erp5
Commits
bddcb668
Commit
bddcb668
authored
Dec 21, 2018
by
Romain Courteaud
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[erp5_web_renderjs_ui] Selecting nothing means all are selected
Same behaviour than xhtml style
parent
27126964
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
18 additions
and
13 deletions
+18
-13
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_form_list_js.js
...teItem/web_page_module/rjs_gadget_erp5_pt_form_list_js.js
+9
-4
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_form_list_js.xml
...eItem/web_page_module/rjs_gadget_erp5_pt_form_list_js.xml
+2
-2
bt5/erp5_web_renderjs_ui_test/PathTemplateItem/portal_tests/renderjs_ui_page_templates_zuite/testFormListExcludeItemWithoutSelecting.zpt
...mplates_zuite/testFormListExcludeItemWithoutSelecting.zpt
+5
-5
bt5/erp5_web_renderjs_ui_test/PathTemplateItem/portal_tests/renderjs_ui_page_templates_zuite/testFormListIncludeItemWithoutSelecting.zpt
...mplates_zuite/testFormListIncludeItemWithoutSelecting.zpt
+2
-2
No files found.
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_form_list_js.js
View file @
bddcb668
...
@@ -205,25 +205,30 @@
...
@@ -205,25 +205,30 @@
.
allowPublicAcquisition
(
"
triggerListboxSelectAction
"
,
function
triggerListboxSelectAction
(
argument_list
)
{
.
allowPublicAcquisition
(
"
triggerListboxSelectAction
"
,
function
triggerListboxSelectAction
(
argument_list
)
{
var
action
=
argument_list
[
0
],
var
action
=
argument_list
[
0
],
uid_list
=
argument_list
[
1
],
checked_uid_list
=
argument_list
[
1
],
unchecked_uid_list
=
argument_list
[
2
],
gadget
=
this
,
gadget
=
this
,
i
,
i
,
search_query
,
search_query
,
query_list
=
[];
query_list
=
[];
if
((
action
===
'
include
'
)
||
(
action
===
'
exclude
'
))
{
if
((
action
===
'
include
'
)
||
(
action
===
'
exclude
'
))
{
if
(
uid_list
.
length
===
0
)
{
if
(
checked_uid_list
.
length
===
0
)
{
// If nothing is checked, use all unchecked values (same as xhtml style)
checked_uid_list
=
unchecked_uid_list
;
}
if
(
checked_uid_list
.
length
===
0
)
{
// XXX Queries do not correctly handle empty uid list
// XXX Queries do not correctly handle empty uid list
return
gadget
.
redirect
({
return
gadget
.
redirect
({
command
:
'
reload
'
command
:
'
reload
'
});
});
}
}
for
(
i
=
0
;
i
<
uid_list
.
length
;
i
+=
1
)
{
for
(
i
=
0
;
i
<
checked_
uid_list
.
length
;
i
+=
1
)
{
query_list
.
push
(
new
SimpleQuery
({
query_list
.
push
(
new
SimpleQuery
({
key
:
"
catalog.uid
"
,
key
:
"
catalog.uid
"
,
type
:
"
simple
"
,
type
:
"
simple
"
,
operator
:
(
action
===
'
include
'
)
?
"
=
"
:
"
!=
"
,
operator
:
(
action
===
'
include
'
)
?
"
=
"
:
"
!=
"
,
value
:
uid_list
[
i
]
value
:
checked_
uid_list
[
i
]
}));
}));
}
}
if
(
gadget
.
state
.
extended_search
)
{
if
(
gadget
.
state
.
extended_search
)
{
...
...
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_form_list_js.xml
View file @
bddcb668
...
@@ -230,7 +230,7 @@
...
@@ -230,7 +230,7 @@
</item>
</item>
<item>
<item>
<key>
<string>
serial
</string>
</key>
<key>
<string>
serial
</string>
</key>
<value>
<string>
972.271
21.4308.45824
</string>
</value>
<value>
<string>
972.271
45.17258.43178
</string>
</value>
</item>
</item>
<item>
<item>
<key>
<string>
state
</string>
</key>
<key>
<string>
state
</string>
</key>
...
@@ -248,7 +248,7 @@
...
@@ -248,7 +248,7 @@
</tuple>
</tuple>
<state>
<state>
<tuple>
<tuple>
<float>
154523
2470.9
</float>
<float>
154523
3919.1
</float>
<string>
UTC
</string>
<string>
UTC
</string>
</tuple>
</tuple>
</state>
</state>
...
...
bt5/erp5_web_renderjs_ui_test/PathTemplateItem/portal_tests/renderjs_ui_page_templates_zuite/testFormListExcludeItemWithoutSelecting.zpt
View file @
bddcb668
...
@@ -100,7 +100,7 @@
...
@@ -100,7 +100,7 @@
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_listbox_loaded"
/>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_listbox_loaded"
/>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/assert_listbox_not_selectable"
/>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/assert_listbox_not_selectable"
/>
<tal:block
tal:define=
"pagination_configuration python: {'header': '(1 - 3 /
10)', 'footer': 'Records 1 - 3 / 10
'}"
>
<tal:block
tal:define=
"pagination_configuration python: {'header': '(1 - 3 /
7)', 'footer': 'Records 1 - 3 / 7
'}"
>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/check_listbox_pagination_text"
/>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/check_listbox_pagination_text"
/>
</tal:block>
</tal:block>
...
@@ -122,18 +122,18 @@
...
@@ -122,18 +122,18 @@
</tal:block>
</tal:block>
<!-- Check the listbox cell -->
<!-- Check the listbox cell -->
<tal:block
tal:define=
"cell_configuration python: {'text': 'Title
0
', 'line': 0, 'index': 1}"
>
<tal:block
tal:define=
"cell_configuration python: {'text': 'Title
3
', 'line': 0, 'index': 1}"
>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/check_listbox_cell_text"
/>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/check_listbox_cell_text"
/>
</tal:block>
</tal:block>
<tal:block
tal:define=
"cell_configuration python: {'text': 'Title
1
', 'line': 1, 'index': 1}"
>
<tal:block
tal:define=
"cell_configuration python: {'text': 'Title
4
', 'line': 1, 'index': 1}"
>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/check_listbox_cell_text"
/>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/check_listbox_cell_text"
/>
</tal:block>
</tal:block>
<tal:block
tal:define=
"cell_configuration python: {'text': 'Title
2
', 'line': 2, 'index': 1}"
>
<tal:block
tal:define=
"cell_configuration python: {'text': 'Title
5
', 'line': 2, 'index': 1}"
>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/check_listbox_cell_text"
/>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/check_listbox_cell_text"
/>
</tal:block>
</tal:block>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/triggle_filter_and"
/>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/triggle_filter_and"
/>
<tal:block
tal:define=
"filter_section_configuration python: {'key': 'TEXT', 'value': 'title', 'index':
0
}"
>
<tal:block
tal:define=
"filter_section_configuration python: {'key': 'TEXT', 'value': 'title', 'index':
3
}"
>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/check_filter_section"
/>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/check_filter_section"
/>
</tal:block>
</tal:block>
...
...
bt5/erp5_web_renderjs_ui_test/PathTemplateItem/portal_tests/renderjs_ui_page_templates_zuite/testFormListIncludeItemWithoutSelecting.zpt
View file @
bddcb668
...
@@ -100,7 +100,7 @@
...
@@ -100,7 +100,7 @@
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_listbox_loaded"
/>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_listbox_loaded"
/>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/assert_listbox_not_selectable"
/>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/assert_listbox_not_selectable"
/>
<tal:block
tal:define=
"pagination_configuration python: {'header': '(
1 - 3 / 10)', 'footer': 'Records 1 - 3 / 10
'}"
>
<tal:block
tal:define=
"pagination_configuration python: {'header': '(
3)', 'footer': '3 Records
'}"
>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/check_listbox_pagination_text"
/>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/check_listbox_pagination_text"
/>
</tal:block>
</tal:block>
...
@@ -133,7 +133,7 @@
...
@@ -133,7 +133,7 @@
</tal:block>
</tal:block>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/triggle_filter_and"
/>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/triggle_filter_and"
/>
<tal:block
tal:define=
"filter_section_configuration python: {'key': 'TEXT', 'value': 'title', 'index':
0
}"
>
<tal:block
tal:define=
"filter_section_configuration python: {'key': 'TEXT', 'value': 'title', 'index':
1
}"
>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/check_filter_section"
/>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/check_filter_section"
/>
</tal:block>
</tal:block>
...
...
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