Commit 2f141f43 authored by Romain Courteaud's avatar Romain Courteaud

erp5_web_renderjs_ui: check that delete action keep the history

parent 1a828fb4
......@@ -191,7 +191,7 @@
update_action_title: options.form_definition.update_action_title,
// pass extended_search from previous view in case any gadget is curious
extended_search: extended_search,
redirect_to_parent: options.erp5_document._embedded._view.field_your_redirect_to_parent !== undefined
redirect_to_parent: options.erp5_document._embedded._view.your_redirect_to_parent !== undefined
});
});
})
......
......@@ -228,7 +228,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>982.26879.4100.14950</string> </value>
<value> <string>987.241.33421.16076</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -246,8 +246,8 @@
</tuple>
<state>
<tuple>
<float>1593667813.48</float>
<string>GMT+2</string>
<float>1601565340.43</float>
<string>UTC</string>
</tuple>
</state>
</object>
......
......@@ -57,7 +57,7 @@
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_notification" />
</tal:block>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" />
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_listbox_loaded" />
<!-- create 2 Foo lines, one has same id as parent -->
<tal:block tal:define="click_configuration python: {'text': 'Add'}">
......@@ -78,12 +78,7 @@
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/click_on_header_link" />
</tal:block>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" />
<tr>
<td>waitForElementPresent</td>
<td>//div[@data-gadget-scope="field_listbox"]</td>
<td></td>
</tr>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_listbox_loaded" />
<tal:block tal:define="click_configuration python: {'text': 'Add'}">
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/click_on_header_link" />
......@@ -164,12 +159,20 @@
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" />
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_listbox_loaded" />
<!-- Change the listbox sort, to ensure all custom search/sort parameters are kept after deleting a subobject -->
<tr>
<td>waitForElementPresent</td>
<td>//div[contains(@data-gadget-url, 'gadget_erp5_pt_form_view.html')]//div[@data-gadget-scope="field_listbox"]//tbody//a</td>
<td></td>
<td>click</td>
<td>//th/a[text()='Quantity']</td>
<td></td>
</tr>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" />
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_listbox_loaded" />
<tr>
<td>assertElementPresent</td><!-- verification -->
<td>//th[@class='ui-icon ui-icon-sort-amount-desc']/a[text()='Quantity']</td>
<td></td>
</tr>
<tr>
<td>click</td>
<td>//div[contains(@data-gadget-url, 'gadget_erp5_pt_form_view.html')]//div[@data-gadget-scope="field_listbox"]//tbody//a</td>
......@@ -177,11 +180,7 @@
</tr>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" />
<tr>
<td>waitForElementNotPresent</td>
<td>//div[@data-gadget-scope="field_listbox"]</td>
<td></td>
</tr>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/toggle_editable_mode" />
......@@ -205,6 +204,12 @@
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_listbox_loaded" />
<tr>
<td>assertElementPresent</td>
<td>//th[@class='ui-icon ui-icon-sort-amount-desc']/a[text()='Quantity']</td>
<td></td>
</tr>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/toggle_editable_mode" />
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" />
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_listbox_loaded" />
......@@ -222,11 +227,6 @@
</tr>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" />
<tr>
<td>waitForElementNotPresent</td>
<td>//div[@data-gadget-scope="field_listbox"]</td>
<td></td>
</tr>
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/toggle_editable_mode" />
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/wait_for_content_loaded" />
......@@ -253,6 +253,11 @@
<tal:block tal:define="pagination_configuration python: {'header': '(0)', 'footer': 'No records'}">
<tal:block metal:use-macro="here/Zuite_CommonTemplateForRenderjsUi/macros/check_listbox_pagination_text" />
</tal:block>
<tr>
<td>assertElementPresent</td>
<td>//th[@class='ui-icon ui-icon-sort-amount-desc']/a[text()='Quantity']</td>
<td></td>
</tr>
<!-- Wait for the action page and check no delete link is here-->
<tal:block tal:define="click_configuration python: {'text': 'Actions'}">
......@@ -265,6 +270,7 @@
<td>//a[text()='Delete Document']</td>
<td></td>
</tr>
</tbody></table>
</body>
</html>
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment