Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Mathieu Loiseau
MagicWord
Commits
9da6f14d
Commit
9da6f14d
authored
Jun 01, 2018
by
arnaudbey
Browse files
decrease threshold and make ppl play the more filled grids first
parent
8f211eec
Changes
2
Hide whitespace changes
Inline
Side-by-side
application/src/MagicWordBundle/Repository/GameRepository.php
View file @
9da6f14d
...
...
@@ -26,7 +26,8 @@ class GameRepository extends \Doctrine\ORM\EntityRepository
WHERE a.round = r
AND a.player = :user
)
AND SIZE(g.foundableForms) > 200"
;
AND SIZE(g.foundableForms) > 150
ORDER BY SIZE(g.foundableForms) DESC"
;
$query
=
$em
->
createQuery
(
$dql
);
$query
->
setParameter
(
'user'
,
$user
)
...
...
application/src/MagicWordBundle/Repository/GridRepository.php
View file @
9da6f14d
...
...
@@ -56,7 +56,7 @@ class GridRepository extends \Doctrine\ORM\EntityRepository
$em
=
$this
->
_em
;
$dql
=
"SELECT grid FROM MagicWordBundle\Entity\Grid grid
WHERE grid.language = :language
AND SIZE(grid.foundableForms) >
2
50
AND SIZE(grid.foundableForms) >
1
50
AND NOT EXISTS (
SELECT round FROM MagicWordBundle\Entity\Round round
INNER JOIN round.game game
...
...
@@ -79,7 +79,8 @@ class GridRepository extends \Doctrine\ORM\EntityRepository
WHERE a.round = r
AND r.grid = grid
AND a.player = :player
)"
;
)
ORDER BY SIZE(grid.foundableForms) DESC"
;
$query
=
$em
->
createQuery
(
$dql
);
$query
->
setParameter
(
'player'
,
$player
)
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment