Debug
This commit is contained in:
parent
38270bf738
commit
32a15a581f
@ -427,63 +427,62 @@ foreach($tabExtract as $key)
|
||||
//Add original key
|
||||
$tabEntete[] = $key;
|
||||
|
||||
//Ajout à la requete SQL
|
||||
foreach($tabDico as $element => $select)
|
||||
{
|
||||
if ( array_key_exists('db', $select) && array_key_exists($key, $select['cle']) )
|
||||
{
|
||||
$elementsup = $select['cle'][$key];
|
||||
|
||||
if ( is_array($elementsup) && array_key_exists('table', $elementsup) ) {
|
||||
|
||||
//Specify supplemental head
|
||||
$tabEntete[] = $key.'Lib';
|
||||
|
||||
//Load generic table - always return array('code', 'label')
|
||||
if ( is_array($elementsup['table']) ) {
|
||||
|
||||
${'tab'.ucfirst($key)} = $elementsup['table'];
|
||||
|
||||
} else {
|
||||
|
||||
$stmt = $dbMetier->query($elementsup['table']);
|
||||
${'tab'.ucfirst($key)} = $stmt->fetchAll();
|
||||
|
||||
}
|
||||
|
||||
if( array_key_exists('sql', $select['cle'][$key]) && $select['cle'][$key]['sql']!='' ) {
|
||||
$strKey = $select['cle'][$key]['sql'];
|
||||
}
|
||||
|
||||
} elseif ( $select['cle'][$key]!='' ) {
|
||||
|
||||
$strKey = $select['cle'][$key];
|
||||
|
||||
}
|
||||
|
||||
//If string exist add supplemental fields for the sql request
|
||||
if (isset(${$element.'Fields'})){ ${$element.'Fields'}.= ', '; }
|
||||
|
||||
if ($strKey!==false){
|
||||
${$element.'Fields'}.= $strKey;
|
||||
} else {
|
||||
${$element.'Fields'}.= $key;
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
|
||||
echo $key."\n";
|
||||
if ( $element == 'data' && in_array($key, $select) )
|
||||
{
|
||||
${$key.'Data'} = $values;
|
||||
echo $key.'Data';
|
||||
var_dump($values);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
//Ajout à la requete SQL
|
||||
foreach($tabDico as $element => $select)
|
||||
{
|
||||
if ( array_key_exists('db', $select) && array_key_exists($key, $select['cle']) )
|
||||
{
|
||||
$elementsup = $select['cle'][$key];
|
||||
|
||||
if ( is_array($elementsup) && array_key_exists('table', $elementsup) ) {
|
||||
|
||||
//Specify supplemental head
|
||||
$tabEntete[] = $key.'Lib';
|
||||
|
||||
//Load generic table - always return array('code', 'label')
|
||||
if ( is_array($elementsup['table']) ) {
|
||||
|
||||
${'tab'.ucfirst($key)} = $elementsup['table'];
|
||||
|
||||
} else {
|
||||
|
||||
$stmt = $dbMetier->query($elementsup['table']);
|
||||
${'tab'.ucfirst($key)} = $stmt->fetchAll();
|
||||
|
||||
}
|
||||
|
||||
if( array_key_exists('sql', $select['cle'][$key]) && $select['cle'][$key]['sql']!='' ) {
|
||||
$strKey = $select['cle'][$key]['sql'];
|
||||
}
|
||||
|
||||
} elseif ( $select['cle'][$key]!='' ) {
|
||||
|
||||
$strKey = $select['cle'][$key];
|
||||
|
||||
}
|
||||
|
||||
//If string exist add supplemental fields for the sql request
|
||||
if (isset(${$element.'Fields'})){ ${$element.'Fields'}.= ', '; }
|
||||
|
||||
if ($strKey!==false){
|
||||
${$element.'Fields'}.= $strKey;
|
||||
} else {
|
||||
${$element.'Fields'}.= $key;
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
|
||||
echo $key."\n";
|
||||
if ( $element == 'data' && in_array($key, $select) )
|
||||
{
|
||||
${$key.'Data'} = $values;
|
||||
echo $key.'Data';
|
||||
var_dump($values);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
//Ajout colonne obligatoire
|
||||
|
Loading…
Reference in New Issue
Block a user