Skip to content

Commit

Permalink
Ya debería funcionar correctamente
Browse files Browse the repository at this point in the history
  • Loading branch information
CANCI0 committed Apr 23, 2024
1 parent ab24e78 commit 1b81073
Show file tree
Hide file tree
Showing 6 changed files with 28 additions and 4 deletions.
2 changes: 1 addition & 1 deletion questionservice/question-service.js
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ app.post("/questions", async (req, res) => {
const tematicasValidas =
temas.length !== 0
? temas
: ["paises", "literatura", "cine", "arte", "programacion"];
: ["paises", "literatura", "cine", "arte", "programacion", "futbolistas", "clubes", "baloncestistas", "politica", "videojuegos"];
const cantidadPreguntas = parseInt(n, 10);
const data = gen.getQuestionsPost(tematicasValidas, cantidadPreguntas, locale);
res.json(data);
Expand Down
3 changes: 1 addition & 2 deletions questionservice/questionGen/GenericGenerator.js
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,7 @@ class GenericGenerator {
}
LIMIT 10000
`;

console.log(sparqlQuery);

const url = `https://query.wikidata.org/sparql?query=${encodeURIComponent(
sparqlQuery
)}&format=json`;
Expand Down
2 changes: 1 addition & 1 deletion webapp/src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ const root = ReactDOM.createRoot(r);

localStorage.setItem(
"selectedThemes",
JSON.stringify(["paises", "literatura", "cine", "arte", "programacion"])
JSON.stringify(["paises", "literatura", "cine", "arte", "programacion", "futbolistas", "clubes", "baloncestistas", "politica", "videojuegos"])
);
localStorage.setItem("clasicoTime", 10);
localStorage.setItem("clasicoPreguntas", 10);
Expand Down
5 changes: 5 additions & 0 deletions webapp/src/locales/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,11 @@
"cinema": "Cinema",
"art": "Art",
"programming": "Programming",
"futbolistas": "Football players",
"clubes": "Footbal clubs",
"baloncestistas": "Basketball players",
"politica": "Politics",
"videojuegos": "Videogames",
"save": "Apply Changes",
"timeBetweenClassic": "Time Between Questions (Classic)",
"questionCountClassic": "Number of Questions (Classic)",
Expand Down
5 changes: 5 additions & 0 deletions webapp/src/locales/es.json
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,11 @@
"cinema": "Cine",
"art": "Arte",
"programming": "Programación",
"futbolistas": "Futbolistas",
"clubes": "Clubes de fútbol",
"baloncestistas": "Jugadores de baloncesto",
"politica": "Política",
"videojuegos": "Videojuegos",
"save": "Aplicar cambios",
"timeBetweenClassic": "Tiempo entre preguntas (Clásico)",
"questionCountClassic": "Número de preguntas (Clásico)",
Expand Down
15 changes: 15 additions & 0 deletions webapp/src/pages/Config/Config.js
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,21 @@ const Config = () => {
<Checkbox id="programacion" mb={2}>
{t('pages.config.programming')}
</Checkbox>
<Checkbox id="futbolistas" mb={2}>
{t('pages.config.futbolistas')}
</Checkbox>
<Checkbox id="clubes" mb={2}>
{t('pages.config.clubes')}
</Checkbox>
<Checkbox id="baloncestistas" mb={2}>
{t('pages.config.baloncestistas')}
</Checkbox>
<Checkbox id="politica" mb={2}>
{t('pages.config.politica')}
</Checkbox>
<Checkbox id="videojuegos" mb={2}>
{t('pages.config.videojuegos')}
</Checkbox>
</Stack>
</Box>

Expand Down

0 comments on commit 1b81073

Please sign in to comment.