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
Labels
Merge Requests
138
Merge Requests
138
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
Jobs
Commits
Open sidebar
nexedi
erp5
Commits
8f2221ca
Commit
8f2221ca
authored
Apr 22, 2021
by
Gabriel Monnerat
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
erp5_web_renderjs_ui: Display notification when there is only a required field blocking the form
parent
baf5d3aa
Changes
17
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
17 changed files
with
1220 additions
and
29 deletions
+1220
-29
bt5/erp5_ui_test/ActionTemplateItem/portal_types/Foo/view_with_validation_error_field.xml
...tem/portal_types/Foo/view_with_validation_error_field.xml
+79
-0
bt5/erp5_ui_test/SkinTemplateItem/portal_skins/erp5_ui_test/Foo_viewWithValidationError.xml
...portal_skins/erp5_ui_test/Foo_viewWithValidationError.xml
+158
-0
bt5/erp5_ui_test/SkinTemplateItem/portal_skins/erp5_ui_test/Foo_viewWithValidationError/your_first_failure.xml
...i_test/Foo_viewWithValidationError/your_first_failure.xml
+264
-0
bt5/erp5_ui_test/SkinTemplateItem/portal_skins/erp5_ui_test/Foo_viewWithValidationError/your_second_failure.xml
..._test/Foo_viewWithValidationError/your_second_failure.xml
+264
-0
bt5/erp5_ui_test/SkinTemplateItem/portal_skins/erp5_ui_test/Foo_viewWithValidationError/your_third_failure.xml
...i_test/Foo_viewWithValidationError/your_third_failure.xml
+272
-0
bt5/erp5_ui_test/bt/template_action_path_list
bt5/erp5_ui_test/bt/template_action_path_list
+2
-1
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_form_dialog_html.html
.../web_page_module/rjs_gadget_erp5_pt_form_dialog_html.html
+6
-0
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_form_dialog_html.xml
...m/web_page_module/rjs_gadget_erp5_pt_form_dialog_html.xml
+2
-2
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_form_dialog_js.js
...Item/web_page_module/rjs_gadget_erp5_pt_form_dialog_js.js
+9
-1
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_form_dialog_js.xml
...tem/web_page_module/rjs_gadget_erp5_pt_form_dialog_js.xml
+2
-2
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_form_view_editable_html.html
...ge_module/rjs_gadget_erp5_pt_form_view_editable_html.html
+1
-3
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_form_view_editable_html.xml
...age_module/rjs_gadget_erp5_pt_form_view_editable_html.xml
+2
-2
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_form_view_editable_js.js
...b_page_module/rjs_gadget_erp5_pt_form_view_editable_js.js
+11
-1
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_form_view_editable_js.xml
..._page_module/rjs_gadget_erp5_pt_form_view_editable_js.xml
+2
-2
bt5/erp5_web_renderjs_ui_test/PathTemplateItem/portal_tests/renderjs_ui_page_templates_zuite/testFormDialogWorkflowWithMultipleValidationError.zpt
...ite/testFormDialogWorkflowWithMultipleValidationError.zpt
+8
-15
bt5/erp5_web_renderjs_ui_test/PathTemplateItem/portal_tests/renderjs_ui_page_templates_zuite/testFormViewWithMultipleValidationError.xml
...mplates_zuite/testFormViewWithMultipleValidationError.xml
+58
-0
bt5/erp5_web_renderjs_ui_test/PathTemplateItem/portal_tests/renderjs_ui_page_templates_zuite/testFormViewWithMultipleValidationError.zpt
...mplates_zuite/testFormViewWithMultipleValidationError.zpt
+80
-0
No files found.
bt5/erp5_ui_test/ActionTemplateItem/portal_types/Foo/view_with_validation_error_field.xml
0 → 100644
View file @
8f2221ca
<?xml version="1.0"?>
<ZopeData>
<record
id=
"1"
aka=
"AAAAAAAAAAE="
>
<pickle>
<global
name=
"ActionInformation"
module=
"Products.CMFCore.ActionInformation"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
action
</string>
</key>
<value>
<persistent>
<string
encoding=
"base64"
>
AAAAAAAAAAI=
</string>
</persistent>
</value>
</item>
<item>
<key>
<string>
categories
</string>
</key>
<value>
<tuple>
<string>
action_type/object_view
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
category
</string>
</key>
<value>
<string>
object_view
</string>
</value>
</item>
<item>
<key>
<string>
condition
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
description
</string>
</key>
<value>
<string>
View With Validation Error
</string>
</value>
</item>
<item>
<key>
<string>
icon
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
view_with_validation_error_field
</string>
</value>
</item>
<item>
<key>
<string>
permissions
</string>
</key>
<value>
<tuple>
<string>
View
</string>
</tuple>
</value>
</item>
<item>
<key>
<string>
priority
</string>
</key>
<value>
<float>
5.0
</float>
</value>
</item>
<item>
<key>
<string>
title
</string>
</key>
<value>
<string>
View With Validation Error
</string>
</value>
</item>
<item>
<key>
<string>
visible
</string>
</key>
<value>
<int>
1
</int>
</value>
</item>
</dictionary>
</pickle>
</record>
<record
id=
"2"
aka=
"AAAAAAAAAAI="
>
<pickle>
<global
name=
"Expression"
module=
"Products.CMFCore.Expression"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
text
</string>
</key>
<value>
<string>
string:${object_url}/Foo_viewWithValidationError
</string>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
bt5/erp5_ui_test/SkinTemplateItem/portal_skins/erp5_ui_test/Foo_viewWithValidationError.xml
0 → 100644
View file @
8f2221ca
<?xml version="1.0"?>
<ZopeData>
<record
id=
"1"
aka=
"AAAAAAAAAAE="
>
<pickle>
<global
name=
"ERP5 Form"
module=
"erp5.portal_type"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_bind_names
</string>
</key>
<value>
<object>
<klass>
<global
name=
"NameAssignments"
module=
"Shared.DC.Scripts.Bindings"
/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key>
<string>
_asgns
</string>
</key>
<value>
<dictionary/>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key>
<string>
_objects
</string>
</key>
<value>
<tuple/>
</value>
</item>
<item>
<key>
<string>
action
</string>
</key>
<value>
<string>
Base_edit
</string>
</value>
</item>
<item>
<key>
<string>
action_title
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
description
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
edit_order
</string>
</key>
<value>
<list/>
</value>
</item>
<item>
<key>
<string>
encoding
</string>
</key>
<value>
<string>
UTF-8
</string>
</value>
</item>
<item>
<key>
<string>
enctype
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
group_list
</string>
</key>
<value>
<list>
<string>
left
</string>
<string>
right
</string>
<string>
center
</string>
<string>
bottom
</string>
<string>
hidden
</string>
</list>
</value>
</item>
<item>
<key>
<string>
groups
</string>
</key>
<value>
<dictionary>
<item>
<key>
<string>
bottom
</string>
</key>
<value>
<list/>
</value>
</item>
<item>
<key>
<string>
center
</string>
</key>
<value>
<list/>
</value>
</item>
<item>
<key>
<string>
hidden
</string>
</key>
<value>
<list/>
</value>
</item>
<item>
<key>
<string>
left
</string>
</key>
<value>
<list>
<string>
your_first_failure
</string>
<string>
your_second_failure
</string>
<string>
your_third_failure
</string>
</list>
</value>
</item>
<item>
<key>
<string>
right
</string>
</key>
<value>
<list/>
</value>
</item>
</dictionary>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
Foo_viewWithValidationError
</string>
</value>
</item>
<item>
<key>
<string>
method
</string>
</key>
<value>
<string>
POST
</string>
</value>
</item>
<item>
<key>
<string>
name
</string>
</key>
<value>
<string>
Foo_viewWithValidationError
</string>
</value>
</item>
<item>
<key>
<string>
pt
</string>
</key>
<value>
<string>
form_view
</string>
</value>
</item>
<item>
<key>
<string>
row_length
</string>
</key>
<value>
<int>
4
</int>
</value>
</item>
<item>
<key>
<string>
stored_encoding
</string>
</key>
<value>
<string>
UTF-8
</string>
</value>
</item>
<item>
<key>
<string>
title
</string>
</key>
<value>
<string>
Validation Error
</string>
</value>
</item>
<item>
<key>
<string>
unicode_mode
</string>
</key>
<value>
<int>
0
</int>
</value>
</item>
<item>
<key>
<string>
update_action
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
update_action_title
</string>
</key>
<value>
<string></string>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
bt5/erp5_ui_test/SkinTemplateItem/portal_skins/erp5_ui_test/Foo_viewWithValidationError/your_first_failure.xml
0 → 100644
View file @
8f2221ca
This diff is collapsed.
Click to expand it.
bt5/erp5_ui_test/SkinTemplateItem/portal_skins/erp5_ui_test/Foo_viewWithValidationError/your_second_failure.xml
0 → 100644
View file @
8f2221ca
This diff is collapsed.
Click to expand it.
bt5/erp5_ui_test/SkinTemplateItem/portal_skins/erp5_ui_test/Foo_viewWithValidationError/your_third_failure.xml
0 → 100644
View file @
8f2221ca
This diff is collapsed.
Click to expand it.
bt5/erp5_ui_test/bt/template_action_path_list
View file @
8f2221ca
...
...
@@ -59,3 +59,4 @@ Foo | view_printout_form
Foo | view_proxy_field
Foo | view_relation_field
Foo | view_url_parameter_dialog
Foo | view_with_validation_error_field
\ No newline at end of file
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_form_dialog_html.html
View file @
8f2221ca
<!DOCTYPE html>
<html>
<head>
<!--
data-i18n=Update
data-i18n=Proceed
data-i18n=Cancel
data-i18n=Please fill all required fields to submit
-->
<meta
http-equiv=
"Content-type"
content=
"text/html; charset=utf-8"
/>
<meta
name=
"viewport"
content=
"width=device-width"
/>
<title>
ERP5 PT Form Dialog
</title>
...
...
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_form_dialog_html.xml
View file @
8f2221ca
...
...
@@ -238,7 +238,7 @@
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
9
78.11125.30548.29832
</string>
</value>
<value>
<string>
9
91.40916.23937.38946
</string>
</value>
</item>
<item>
<key>
<string>
state
</string>
</key>
...
...
@@ -256,7 +256,7 @@
</tuple>
<state>
<tuple>
<float>
1
581694316.93
</float>
<float>
1
619388750.92
</float>
<string>
UTC
</string>
</tuple>
</state>
...
...
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_form_dialog_js.js
View file @
8f2221ca
...
...
@@ -45,7 +45,13 @@
.
push
(
function
(
is_valid
)
{
if
(
!
is_valid
)
{
enableButton
();
return
;
return
gadget
.
translate
(
"
Please fill all required fields to submit
"
)
.
push
(
function
(
message
)
{
return
gadget
.
notifyChange
({
"
message
"
:
message
,
"
status
"
:
"
error
"
});
});
}
return
getContent
.
apply
(
gadget
)
.
push
(
function
(
content_dict
)
{
...
...
@@ -154,6 +160,8 @@
.
declareAcquiredMethod
(
"
getUrlParameter
"
,
"
getUrlParameter
"
)
.
declareAcquiredMethod
(
"
updateHeader
"
,
"
updateHeader
"
)
.
declareAcquiredMethod
(
"
getTranslationList
"
,
"
getTranslationList
"
)
.
declareAcquiredMethod
(
"
translate
"
,
"
translate
"
)
.
declareAcquiredMethod
(
"
notifyChange
"
,
"
notifyChange
"
)
.
declareAcquiredMethod
(
"
submitContent
"
,
"
submitContent
"
)
.
allowPublicAcquisition
(
"
submitDialogWithCustomDialogMethod
"
,
submitDialogWithCustomDialogMethod
)
...
...
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_form_dialog_js.xml
View file @
8f2221ca
...
...
@@ -228,7 +228,7 @@
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
9
87.241.33421.16076
</string>
</value>
<value>
<string>
9
91.43808.38688.31368
</string>
</value>
</item>
<item>
<key>
<string>
state
</string>
</key>
...
...
@@ -246,7 +246,7 @@
</tuple>
<state>
<tuple>
<float>
16
01565340.43
</float>
<float>
16
19563339.95
</float>
<string>
UTC
</string>
</tuple>
</state>
...
...
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_form_view_editable_html.html
View file @
8f2221ca
...
...
@@ -2,9 +2,7 @@
<html>
<head>
<!--
data-i18n=Action not handled
data-i18n=Nothing selected
data-i18n=Copied
data-i18n=Please fill all required fields to submit
-->
<meta
http-equiv=
"Content-type"
content=
"text/html; charset=utf-8"
/>
<meta
name=
"viewport"
content=
"width=device-width"
/>
...
...
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_form_view_editable_html.xml
View file @
8f2221ca
...
...
@@ -238,7 +238,7 @@
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
9
74.48721.18403.49049
</string>
</value>
<value>
<string>
9
91.42429.55366.24695
</string>
</value>
</item>
<item>
<key>
<string>
state
</string>
</key>
...
...
@@ -256,7 +256,7 @@
</tuple>
<state>
<tuple>
<float>
1
554191271.73
</float>
<float>
1
619479605.66
</float>
<string>
UTC
</string>
</tuple>
</state>
...
...
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_form_view_editable_js.js
View file @
8f2221ca
...
...
@@ -9,6 +9,7 @@
.
declareAcquiredMethod
(
"
submitContent
"
,
"
submitContent
"
)
.
declareAcquiredMethod
(
"
getUrlForList
"
,
"
getUrlForList
"
)
.
declareAcquiredMethod
(
"
redirect
"
,
"
redirect
"
)
.
declareAcquiredMethod
(
"
translate
"
,
"
translate
"
)
.
declareAcquiredMethod
(
"
updateHeader
"
,
"
updateHeader
"
)
.
declareAcquiredMethod
(
"
notifyChange
"
,
"
notifyChange
"
)
.
declareAcquiredMethod
(
'
isDesktopMedia
'
,
'
isDesktopMedia
'
)
...
...
@@ -157,7 +158,16 @@
})
.
push
(
function
(
is_valid
)
{
if
(
!
is_valid
)
{
return
gadget
.
translate
(
"
Please fill all required fields to submit
"
)
.
push
(
function
(
message
)
{
return
gadget
.
notifyChange
({
"
message
"
:
message
,
"
status
"
:
"
error
"
});
})
.
push
(
function
()
{
return
null
;
});
}
return
gadget
.
getContent
();
})
...
...
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_gadget_erp5_pt_form_view_editable_js.xml
View file @
8f2221ca
...
...
@@ -234,7 +234,7 @@
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
9
79.2796.18260.40345
</string>
</value>
<value>
<string>
9
91.43808.38688.31368
</string>
</value>
</item>
<item>
<key>
<string>
state
</string>
</key>
...
...
@@ -252,7 +252,7 @@
</tuple>
<state>
<tuple>
<float>
1
570779670.8
</float>
<float>
1
619563288.81
</float>
<string>
UTC
</string>
</tuple>
</state>
...
...
bt5/erp5_web_renderjs_ui_test/PathTemplateItem/portal_tests/renderjs_ui_page_templates_zuite/testFormDialogWorkflowWithMultipleValidationError.zpt
View file @
8f2221ca
...
...
@@ -48,16 +48,14 @@
</tr>
<!-- Fill long string to provoke form validation failure -->
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/submit_dialog"
/>
<tal:block
tal:define=
"notification_configuration python: {'class': 'error', 'text': 'Please fill all required fields to submit'}"
>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_notification"
/>
</tal:block>
<tr>
<td>
fireEvent
</td>
<td>
//input[@name="field_your_sixth_failure"]
</td>
<td>
focus
</td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//div[@data-gadget-url="${renderjs_url}/gadget_erp5_label_field.html"][6]/div/span
</td>
<td></td>
</tr>
<tr>
<td>
assertElementPresent
</td>
<td>
//div[@data-gadget-url="${renderjs_url}/gadget_erp5_label_field.html"][6]/div/span[contains(text(), "Please fill out this field.")]
</td>
...
...
@@ -78,11 +76,10 @@
<td>
field_your_sixth_failure
</td>
<td>
ABCD
</td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//div[@data-gadget-url="${renderjs_url}/gadget_erp5_label_field.html"][8]/div/div/label[@class="is-invalid"][1]
</td>
<td></td>
</tr>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/submit_dialog"
/>
<tal:block
tal:define=
"notification_configuration python: {'class': 'error', 'text': 'Please fill all required fields to submit'}"
>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_notification"
/>
</tal:block>
<tr>
<td>
assertElementPresent
</td>
<td>
//div[@data-gadget-url="${renderjs_url}/gadget_erp5_label_field.html"][8]/div/div/label[@class="is-invalid"][1]
</td>
...
...
@@ -98,11 +95,7 @@
<td>
//input[@name="field_your_eighth_failure" and @value="A"]
</td>
<td>
focus
</td>
</tr>
<tr>
<td>
waitForElementPresent
</td>
<td>
//div[@data-gadget-url="${renderjs_url}/gadget_erp5_label_field.html"][8]/div/span[contains(text(), "Input is required but no input given.")]
</td>
<td></td>
</tr>
<tr>
<td>
assertElementPresent
</td>
<td>
//div[@data-gadget-url="${renderjs_url}/gadget_erp5_label_field.html"][8]/div/span[contains(text(), "Input is required but no input given.")]
</td>
...
...
bt5/erp5_web_renderjs_ui_test/PathTemplateItem/portal_tests/renderjs_ui_page_templates_zuite/testFormViewWithMultipleValidationError.xml
0 → 100644
View file @
8f2221ca
<?xml version="1.0"?>
<ZopeData>
<record
id=
"1"
aka=
"AAAAAAAAAAE="
>
<pickle>
<global
name=
"ZopePageTemplate"
module=
"Products.PageTemplates.ZopePageTemplate"
/>
</pickle>
<pickle>
<dictionary>
<item>
<key>
<string>
_bind_names
</string>
</key>
<value>
<object>
<klass>
<global
name=
"NameAssignments"
module=
"Shared.DC.Scripts.Bindings"
/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key>
<string>
_asgns
</string>
</key>
<value>
<dictionary>
<item>
<key>
<string>
name_subpath
</string>
</key>
<value>
<string>
traverse_subpath
</string>
</value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key>
<string>
content_type
</string>
</key>
<value>
<string>
text/html
</string>
</value>
</item>
<item>
<key>
<string>
expand
</string>
</key>
<value>
<int>
0
</int>
</value>
</item>
<item>
<key>
<string>
id
</string>
</key>
<value>
<string>
testFormViewWithMultipleValidationError
</string>
</value>
</item>
<item>
<key>
<string>
output_encoding
</string>
</key>
<value>
<string>
utf-8
</string>
</value>
</item>
<item>
<key>
<string>
title
</string>
</key>
<value>
<unicode></unicode>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
bt5/erp5_web_renderjs_ui_test/PathTemplateItem/portal_tests/renderjs_ui_page_templates_zuite/testFormViewWithMultipleValidationError.zpt
0 → 100644
View file @
8f2221ca
<html
xmlns:tal=
"http://xml.zope.org/namespaces/tal"
xmlns:metal=
"http://xml.zope.org/namespaces/metal"
>
<head>
<meta
http-equiv=
"Content-Type"
content=
"text/html; charset=UTF-8"
>
<title>
Test Workflow Transition with Invalid Form
</title>
</head>
<body>
<table
cellpadding=
"1"
cellspacing=
"1"
border=
"1"
>
<thead>
<tr><td
rowspan=
"1"
colspan=
"3"
>
Test Workflow Transition with Invalid Form
</td></tr>
</thead><tbody>
<tal:block
metal:use-macro=
"here/PTZuite_CommonTemplate/macros/init"
/>
<tr>
<td>
store
</td>
<td>
${base_url}/web_site_module/renderjs_runner
</td>
<td>
renderjs_url
</td>
</tr>
<tr>
<td>
open
</td>
<td>
${renderjs_url}/#/foo_module/1?editable=1
</td>
<td></td>
</tr>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_app_loaded"
/>
<tal:block
tal:define=
"click_configuration python: {'text': 'View With Validation Error'}"
>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/click_on_panel_link"
/>
</tal:block>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded"
/>
<tr>
<td>
fireEvent
</td>
<td>
//input[@name="field_your_third_failure"]
</td>
<td>
focus
</td>
</tr>
<tr>
<td>
assertElementNotPresent
</td>
<td>
//div[@data-gadget-url="${renderjs_url}/gadget_erp5_label_field.html"][3]/div/span
</td>
<td></td>
</tr>
<tr>
<td>
fireEvent
</td>
<td>
//input[@name="field_your_third_failure"]
</td>
<td>
blur
</td>
</tr>
<!-- Fill long string to provoke form validation failure -->
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/click_save"
/>
<tal:block
tal:define=
"notification_configuration python: {'class': 'error', 'text': 'Please fill all required fields to submit'}"
>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_notification"
/>
</tal:block>
<tr>
<td>
fireEvent
</td>
<td>
//input[@name="field_your_third_failure"]
</td>
<td>
focus
</td>
</tr>
<tr>
<td>
assertElementPresent
</td>
<td>
//div[@data-gadget-url="${renderjs_url}/gadget_erp5_label_field.html"][3]/div/span[contains(text(), "Please fill out this field.")]
</td>
<td></td>
</tr>
<tr>
<td>
fireEvent
</td>
<td>
//input[@name="field_your_third_failure"]
</td>
<td>
blur
</td>
</tr>
<tr>
<td>
assertElementNotPresent
</td>
<td>
//div[@data-gadget-url="${renderjs_url}/gadget_erp5_label_field.html"][3]/div/span[contains(text(), "Please fill out this field.")]
</td>
<td></td>
</tr>
<tr>
<td>
type
</td>
<td>
field_your_third_failure
</td>
<td>
ABCD
</td>
</tr>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/click_save"
/>
<tal:block
tal:define=
"notification_configuration python: {'class': 'error', 'text': 'Input data has errors.'}"
>
<tal:block
metal:use-macro=
"here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_notification"
/>
</tal:block>
</tbody>
</table>
</body>
</html>
\ No newline at end of file
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