Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Mathieu Loiseau
GameOfWords
Commits
648d915b
Commit
648d915b
authored
Aug 24, 2016
by
Mathieu Loiseau
Browse files
multi table bug
parent
1df07ab3
Changes
1
Show whitespace changes
Inline
Side-by-side
controllers/score.class.php
View file @
648d915b
...
...
@@ -19,9 +19,12 @@ class Score{
$this
->
db
->
query
(
$sql
);
if
(
$this
->
db
->
has_result
()){
while
(
$tempObj
=
$this
->
db
->
fetch_object
()){
$this
->
languages
[
$tempObj
->
langue
]
=
new
ScoreTable
(
$this
->
user
,
$tempObj
->
langue
);
$this
->
languages
[
$tempObj
->
langue
]
->
get_score_table
(
false
);
$this
->
languages
[
$tempObj
->
langue
]
=
$tempObj
->
langue
;
//new ScoreTable creates ather database queries, so we separate both processes
}
foreach
(
$this
->
languages
as
$lang
){
$this
->
languages
[
$lang
]
=
new
ScoreTable
(
$this
->
user
,
$lang
);
$this
->
languages
[
$lang
]
->
get_score_table
(
false
);
}
$this
->
languages
[
GlobalScoreTable
::
ALL_LANG
]
=
new
GlobalScoreTable
(
$this
->
user
);
...
...
Write
Preview
Markdown
is supported
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