Open list from a list in list view

I have two DocTypes Project and Time Sheet
in Project list view I want to add a button on each row which shows me List of Time Sheet where project belongs to that row from project list for which the button is clicked.

how is it possible?

Hi @Umair_Mehmood,

That for, Please apply the client script for Project Listview.


frappe.listview_settings['Project'] = {
    button: {
        show: function (doc) {
        get_label: function () {
            return __("View Timesheet", null, "Access");
        get_description: function (doc) {
            return __("View Timesheet of {0}", [`${}`]);
        action: function (doc) {

When clicking on view timesheet then automatically filter set in Timesheet doctype.


I hope this helps.

Thank You!