MongoDB: show value of _id field instead of class name
This commit is contained in:
parent
7d83d0ecb9
commit
dc4485f0a9
|
@ -56,12 +56,13 @@ if (isset($_GET["mongo"])) {
|
||||||
$this->_charset[$key] = 63;
|
$this->_charset[$key] = 63;
|
||||||
}
|
}
|
||||||
$row[$key] =
|
$row[$key] =
|
||||||
|
(is_a($val, 'MongoId') ? 'ObjectId("' . strval($val) . '")':
|
||||||
(is_a($val, 'MongoDate') ? gmdate("Y-m-d H:i:s", $val->sec) . " GMT" :
|
(is_a($val, 'MongoDate') ? gmdate("Y-m-d H:i:s", $val->sec) . " GMT" :
|
||||||
(is_a($val, 'MongoBinData') ? $val->bin : //! allow downloading
|
(is_a($val, 'MongoBinData') ? $val->bin : //! allow downloading
|
||||||
(is_a($val, 'MongoRegex') ? strval($val) :
|
(is_a($val, 'MongoRegex') ? strval($val) :
|
||||||
(is_object($val) ? get_class($val) : // MongoMinKey, MongoMaxKey
|
(is_object($val) ? get_class($val) : // MongoMinKey, MongoMaxKey
|
||||||
$val
|
$val
|
||||||
))));
|
)))));
|
||||||
}
|
}
|
||||||
$this->_rows[] = $row;
|
$this->_rows[] = $row;
|
||||||
foreach ($row as $key => $val) {
|
foreach ($row as $key => $val) {
|
||||||
|
|
Loading…
Reference in a new issue