Compare commits
3 Commits
6cd253d5f0
...
fc073de1de
Author | SHA1 | Date | |
---|---|---|---|
fc073de1de | |||
1d945977dc | |||
1fda84bdef |
@ -89,7 +89,7 @@ def apply_brute_force(players, preferences):
|
||||
print(result[2])
|
||||
|
||||
# team_table(score, team0, team1)
|
||||
return best_score[0]
|
||||
return best_percentage[0]
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
|
@ -200,9 +200,17 @@ function App() {
|
||||
{SubmitButton({ person, players })}
|
||||
<p>now: click submit.</p>
|
||||
</div>
|
||||
<p className="read-the-docs">
|
||||
suggested teams are not updated right away. don't try to hack the
|
||||
algorithm ;D
|
||||
</p>
|
||||
{TeamTables()}
|
||||
<p className="read-the-docs">
|
||||
something not working? message <a href="https://t.me/x0124816">me</a>.
|
||||
sources:{" "}
|
||||
<a href="https://git.0124816.xyz/julius/teambuilding" key="gitea">
|
||||
<img src="gitea.svg" alt="gitea" height="20" />
|
||||
</a>
|
||||
</p>
|
||||
</>
|
||||
);
|
||||
|
@ -1,4 +1,3 @@
|
||||
import * as React from "react";
|
||||
import Table from "@mui/material/Table";
|
||||
import TableBody from "@mui/material/TableBody";
|
||||
import TableCell from "@mui/material/TableCell";
|
||||
@ -8,12 +7,14 @@ import TableRow from "@mui/material/TableRow";
|
||||
import Paper from "@mui/material/Paper";
|
||||
import data from "./table.json";
|
||||
|
||||
type Row = [player: string, fulfilled: number, total: number];
|
||||
|
||||
export default function TeamTables() {
|
||||
return (
|
||||
<>
|
||||
{Object.keys(data).map((teamname) => (
|
||||
{Object.entries(data).map(([teamname, rows]) => (
|
||||
<>
|
||||
<h1>{teamname as String}</h1>
|
||||
<h1>{teamname}</h1>
|
||||
<TableContainer component={Paper}>
|
||||
<Table
|
||||
sx={{ m: "8px auto" }}
|
||||
@ -27,7 +28,7 @@ export default function TeamTables() {
|
||||
</TableRow>
|
||||
</TableHead>
|
||||
<TableBody>
|
||||
{data[teamname].map((row) => (
|
||||
{(rows as Row[]).map((row: Row) => (
|
||||
<TableRow
|
||||
key={row[0]}
|
||||
sx={{ "&:last-child td, &:last-child th": { border: 0 } }}
|
||||
|
Loading…
Reference in New Issue
Block a user