diff options
author | emkael <emkael@tlen.pl> | 2020-11-26 23:11:03 +0100 |
---|---|---|
committer | emkael <emkael@tlen.pl> | 2020-11-26 23:11:03 +0100 |
commit | 88edd69bf07b18e83d78b70191d8a730885bcaa2 (patch) | |
tree | b6ba8a10ff7d1ceaa4182785d3eb2379b53cd3a4 /http | |
parent | b17af1816fcc0b5803fcba813350ce6eb1381c79 (diff) |
Aiding stretching points to 100% of contestants
Diffstat (limited to 'http')
-rw-r--r-- | http/pkle2020a.php | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/http/pkle2020a.php b/http/pkle2020a.php index 4a8d9e8..00def57 100644 --- a/http/pkle2020a.php +++ b/http/pkle2020a.php @@ -161,6 +161,14 @@ function submitit(ev){ document.getElementsByName("typ")[0].select(); } } + + function obnizka(procent) { + var progi = [ procent / 25, procent / 5 * 2, procent ]; + for (var i = 0; i < 3; i++) { + document.getElementsByName("pru"+(i+1))[0].value = Math.round(progi[i]); + } + return false; + } --> </script> </head> @@ -245,7 +253,7 @@ function submitit(ev){ </tr> <tr> <td> </td> - <td colspan="2"><table cellspacing="0" cellpadding="0"><tr><td align="right" style="width:50px"><input type="text" id="pru1" name="pru1" style="width:18px" value="2">%</td><td align="right" style="width:25px"><input type="text" id="pru2" name="pru2" style="width:18px" value="20">%</td><td align="right" style="width:55px"><input type="text" id="pru3" name="pru3" style="width:18px" value="50">%</td></tr></table></td> + <td colspan="2"><table cellspacing="0" cellpadding="0"><tr><td align="right" style="width:50px"><input type="text" id="pru1" name="pru1" style="width:25px" value="2">%</td><td align="right" style="width:25px"><input type="text" id="pru2" name="pru2" style="width:25px" value="20">%</td><td align="right" style="width:55px"><input type="text" id="pru3" name="pru3" style="width:25px" value="50">%</td></tr></table></td> </tr> <tr><td colspan="5"> </td></tr> @@ -268,6 +276,10 @@ function submitit(ev){ <td align="CENTER" valign=top>SUMA WK<br /> <input type="text" id="swk" name="swk" maxlength="7" style="width:70px" onblur="valiuc(this,3)"><br /> <small>Suma WK wszystkich<br />zawodników.</small></td> + <td valign="top" align="center"> + <button onclick="return obnizka(100)" style="width:100%">Rozciągnij obniżkę na wszystkich uczestników</button><br /> + <button onclick="return obnizka(50)" style="width:100%">Przywróć domyślną obniżkę do 50% uczestników</button> + </td> </tr> <tr> <td><br/> |