From 1a66b8280bc778994bdb2b90beaeda1894065d54 Mon Sep 17 00:00:00 2001 From: Mia Lu Date: Sun, 28 Apr 2024 15:25:30 +0200 Subject: [PATCH] Remove payoff graph and chart from Info page (to make things simpler) --- _static/info.js | 58 -------------------------------------- introduction/Proposal.html | 2 +- live_bargaining/Info.html | 29 ------------------- 3 files changed, 1 insertion(+), 88 deletions(-) delete mode 100644 _static/info.js diff --git a/_static/info.js b/_static/info.js deleted file mode 100644 index 6ab6985..0000000 --- a/_static/info.js +++ /dev/null @@ -1,58 +0,0 @@ -let numPlayers = 3; - -let prod_fct = js_vars.prod_fct; -let prod_fct_labels = js_vars.prod_fct_labels; -let lastPlayerIsDummy = prod_fct.length == numPlayers - 1; - -// Payoff chart -const ctx = document.getElementById('payoff-chart'); - -let chart = new Chart(ctx, { - type: 'bar', - data: { - labels: prod_fct_labels.map(s => s.split('
')), - datasets: [{ - label: "Group's value", - data: prod_fct, - borderWidth: 1, - borderColor: "#056fb7", - backgroundColor: "#5994c7" - }] - }, - options: { - responsive: true, - scales: { - y: { - beginAtZero: true - }, - x: { - title: { - text: "Group members", - display: true - } - } - }, - maintainAspectRatio: false, - plugins: { - legend: { - display: false - }, - } - } -}); - -// Payoff table -payoffTableHeader = document.getElementById('payoff-table-header'); -payoffTableRow = document.getElementById('payoff-table-values'); - -prod_fct.forEach(function (payoff, i) { - let headerCell = document.createElement("th"); - headerCell.innerHTML = prod_fct_labels[i]; - headerCell.style.textAlign = 'center'; - payoffTableHeader.appendChild(headerCell) - - let valueCell = payoffTableRow.insertCell(); - valueCell.innerHTML = payoff; - valueCell.style.textAlign = 'center'; -}); - diff --git a/introduction/Proposal.html b/introduction/Proposal.html index b253c0d..7c95202 100644 --- a/introduction/Proposal.html +++ b/introduction/Proposal.html @@ -39,7 +39,7 @@

Group budgets

{{ endif }}

- For the size of the budget of each possible group, you will see a table and a corresponding graph like the one below ("Group budgets"). + This information is also summarized in a table and a corresponding graph for reference during the discussion and bargaining phase (see below: "Group budgets").

diff --git a/live_bargaining/Info.html b/live_bargaining/Info.html index 9cb6748..9614710 100644 --- a/live_bargaining/Info.html +++ b/live_bargaining/Info.html @@ -16,32 +16,6 @@

{{ endif }} -

In this round you are Player {{ player_name }}.

- Remember, payoffs are determined as follows: - -
- - - - - - {{ if not last_player_is_dummy }} - - {{ endif }} - - - - - - - -
Group members
Group's budget
-
- -
-
-

-

You will now have exactly five minutes to discuss and bargain with the other players. After the five minutes end, accepted proposals become final. @@ -50,7 +24,4 @@ {{ next_button}} - - - {{ endblock }} \ No newline at end of file