fix: redirect after login, todo filters (#25521)
* Revert "fix: default filter setup on todo list (#25455)"
This reverts commit 396bc4102e.
* Revert "Revert "fix: default filter setup on todo list (#25455)""
This reverts commit 5e6b6997d526446760c42e7e812ceef5fe416492.
* test: wait longer for filters to apply
* fix: route redirects after login
* test: use clear_filters
* fix: don't set default filters on ToDo
This messes with previous filters logic.
This commit is contained in:
parent
ea0b266409
commit
571ca34eca
5 changed files with 4 additions and 11 deletions
|
|
@ -36,9 +36,8 @@ context("Awesome Bar", () => {
|
|||
cy.get(".title-text").should("contain", "To Do");
|
||||
cy.wait(200); // Wait a bit longer before checking the filter.
|
||||
cy.get('[data-original-title="ID"] > input').should("have.value", "%test%");
|
||||
});
|
||||
|
||||
it("filter preserved, now finds something else", () => {
|
||||
// filter preserved, now finds something else
|
||||
cy.visit("/app/todo");
|
||||
cy.get(".title-text").should("contain", "To Do");
|
||||
cy.wait(200); // Wait a bit longer before checking the filter.
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ context("List Paging", () => {
|
|||
|
||||
it("test load more with count selection buttons", () => {
|
||||
cy.visit("/app/todo/view/report");
|
||||
cy.get(".filter-x-button").click();
|
||||
cy.clear_filters();
|
||||
|
||||
cy.get(".list-paging-area .list-count").should("contain.text", "20 of");
|
||||
cy.get(".list-paging-area .btn-more").click();
|
||||
|
|
|
|||
|
|
@ -450,7 +450,7 @@ Cypress.Commands.add("click_menu_button", (name) => {
|
|||
|
||||
Cypress.Commands.add("clear_filters", () => {
|
||||
cy.get(".filter-x-button").click({ force: true });
|
||||
cy.wait(500);
|
||||
cy.wait(1000);
|
||||
});
|
||||
|
||||
Cypress.Commands.add("click_modal_primary_button", (btn_name) => {
|
||||
|
|
|
|||
|
|
@ -3,12 +3,6 @@ frappe.listview_settings["ToDo"] = {
|
|||
add_fields: ["reference_type", "reference_name"],
|
||||
|
||||
onload: function (me) {
|
||||
if (!Object.keys(frappe.route_options).length) {
|
||||
frappe.route_options = {
|
||||
allocated_to: frappe.session.user,
|
||||
status: "Open",
|
||||
};
|
||||
}
|
||||
me.page.set_title(__("To Do"));
|
||||
},
|
||||
|
||||
|
|
|
|||
|
|
@ -42,7 +42,7 @@ html, body {
|
|||
<script>
|
||||
frappe.ready(function() {
|
||||
if (window.location.hash || window.location.href.includes('/app')) {
|
||||
localStorage.setItem('session_last_route', window.location.pathname + window.location.hash + window.location.search);
|
||||
localStorage.setItem('session_last_route', window.location.pathname);
|
||||
}
|
||||
|
||||
$('.btn-primary').focus();
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue