From 9134dfcedc309a25a00cbd4b45a8e26b07c709ea Mon Sep 17 00:00:00 2001 From: cristianpela Date: Thu, 31 Dec 2020 19:56:52 +0200 Subject: [PATCH] #302 Fixed Broken Contract Agenda Button on Contributor Dashboard. --- src/main/resources/public/js/getContributor.js | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/main/resources/public/js/getContributor.js b/src/main/resources/public/js/getContributor.js index 1b6178a7..5cbe782f 100644 --- a/src/main/resources/public/js/getContributor.js +++ b/src/main/resources/public/js/getContributor.js @@ -15,7 +15,14 @@ function getContributorDashboard() { $("#contributorDashboard").removeClass("d-none"); $("#contributorDashboard").addClass("show"); $("#contractsTable .contractAgenda").each(function () { - $(this).on("click", () => { + $(this).on("click", function() { + var data = $("#contractsTable").DataTable().row($(this).parents('tr')).data() + var contract = { + id: { + repoFullName: $(data[0]).text(), + role: data[1] + } + } getTasksOfContract(contract); getInvoicesOfContract(contract); });