Commit 57ca022c authored by Nico Schallehn's avatar Nico Schallehn

debug

parent d1412166
......@@ -56,8 +56,8 @@ class MediaDBViewerAPI{
}
else{
// Wenn irgenein filter gesetzt ist...
if( isset($GET_arr['imdbID']) OR isset($GET_arr['3d']) OR isset($GET_arr['GenreID']) OR isset($GET_arr['Genre']) OR
isset($GET_arr['SchauspielerID']) OR isset($GET_arr['Schauspieler']) ){
if( (isset($GET_arr['imdbID']) OR isset($GET_arr['3d']) OR isset($GET_arr['GenreID']) OR isset($GET_arr['Genre']) OR
isset($GET_arr['SchauspielerID']) OR isset($GET_arr['Schauspieler']) ) AND $GET_arr['Table'] == "Filme" ){ // Filterung nur für Tablle Filme!!
$first = true;
$Where = "WHERE ";
if(isset($GET_arr['imdbID']) AND is_numeric($GET_arr['imdbID'])){
......@@ -91,10 +91,6 @@ class MediaDBViewerAPI{
$Where .= (strlen($GenreArr["imdbIDs"])>0?($first?"":" AND ").str_replace(",)", ")", 'imdbID in ('.$GenreArr["imdbIDs"].')'): ($first?" 0 ":""));
$first = false;
}
//TODO Hier weiter!!
if(isset($GET_arr['SchauspielerID'])){
$Query = 'SELECT group_concat(fs.imdbID) AS imdbIDs FROM FilmSchauspieler AS fs JOIN Schauspieler AS s ON fs.schauspielerID = s.schauspielerID WHERE s.schauspielerID IN ('.$GET_arr['SchauspielerID'].') ';
$this->DebugOut( $Query);
......@@ -135,7 +131,14 @@ class MediaDBViewerAPI{
//echo $GET_arr['Spalten'];
$Query= "SELECT ".$this->iset($GET_arr['Spalten'], "*").
/* wenn Genre oder Schauspieler gefordert sind, aber die imdbID nicht in der Spaltenliste ist... */
if((($ListGenre OR $ListSchauspieler) AND !in_array("imdbID", $SpaltenArr) AND ($this->iset($GET_arr['Spalten'], "*") != "*" ))){
$Select = "imdbID,".$GET_arr['Spalten'];
}else{
$Select = $this->iset($GET_arr['Spalten'], "*");
}
$Query= "SELECT ".$Select.
" FROM ".$GET_arr['Table']." "
.$Where
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment