From a785de78ce6a77f2416e5a915d958c0221bb0466 Mon Sep 17 00:00:00 2001
From: Leo VIALLON-GALINIER <leo.viallon@vln-glr.fr>
Date: Wed, 27 May 2020 21:04:59 +0200
Subject: [PATCH] Add info 1st player

---
 db.py                 | 1 +
 static/game_script.js | 3 +++
 2 files changed, 4 insertions(+)

diff --git a/db.py b/db.py
index cdc6255..d1c2aff 100644
--- a/db.py
+++ b/db.py
@@ -132,6 +132,7 @@ class Game(db.Model):
         r['cumul'] = [self.cumul_0, self.cumul_1]
         r['partie'] = self.partie
         r['admin'] = self.admin
+        r['distributeur'] = self.distributeur
         return r
 
     def serialize_state(self, user):
diff --git a/static/game_script.js b/static/game_script.js
index a6ce3da..26c3b12 100644
--- a/static/game_script.js
+++ b/static/game_script.js
@@ -142,6 +142,9 @@ var set_players = function(){
         if(jeu['players'][i]==jeu['admin']){
             name = name + '&nbsp;*';
         }
+        if(i==jeu['distributeur']){
+            name = name + '&nbsp;(1)';
+        }
         k = (i+6-jeu['nr'])%4;
         $('#joueur-'+k).html(name);
     }