I am trying to get & apply a filter from logged user’s custom field “City”,
So in sales invoice list view, data in logged user’s field city will be set as filter. (No user permission but just a filter require)
How to get exact filter data from logged user? This is how I am trying from sales_invoice_list
I am trying to get & apply a filter from logged user’s custom field “City”,
So in sales invoice list view, data in logged user’s field city will be set as filter. (No user permission but just a filter require)
How to get exact filter data from logged user? This is how I am trying
frappe.listview_settings['Sales Invoice'] = {
onload: function(listview) {
if (!frappe.route_options){
frappe.route_options = {
"City": ["=", frappe.session.user.city]
};
}
}
};