Merge pull request #20989 from frappe/fix-misc-14-5

This commit is contained in:
Suraj Shetty 2023-05-14 22:57:01 +05:30 committed by GitHub
commit af21fa6b37
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 8 deletions

View file

@ -137,13 +137,11 @@ frappe.ui.toolbar.Toolbar = class {
__("Generate Tracking URL")
);
frappe.model.with_doctype("RQ Job").then(() => {
if (frappe.perm.has_perm("RQ Job", 0, "read")) {
frappe.search.utils.make_function_searchable(function () {
frappe.set_route("List", "RQ Job");
}, __("Background Jobs"));
}
});
if (frappe.model.can_read("RQ Job")) {
frappe.search.utils.make_function_searchable(function () {
frappe.set_route("List", "RQ Job");
}, __("Background Jobs"));
}
}
}

View file

@ -84,7 +84,7 @@ $.extend(frappe, {
}
return $.ajax({
type: opts.type || "POST",
url: "/",
url: "/login",
data: opts.args,
dataType: "json",
headers: {