5
function getDevice($id) {
6
$db = Factory::Database();
14
id = '" . intval($id) . "'
17
if ($row = $res->fetch_object()) {
18
$row->simSize = ucfirst($row->simSize);
19
$row->simLocked = !! $row->simLocked;
20
$row->hasInspect = !! $row->hasInspect;
21
$row->hasWifi = !! $row->hasWifi;
22
$row->otherBrowsers = explode(',', $row->otherBrowsers);
23
$row->otherBrowsers = array_combine($row->otherBrowsers, $row->otherBrowsers);
25
switch($row->deviceType) {
26
case 'mobile': $row->type = 'Phone'; break;
27
case 'tablet': $row->type = 'Tablet'; break;
28
case 'media': $row->type = 'Media player'; break;
29
case 'netbook': $row->type = 'Netbook'; break;
30
case 'laptop': $row->type = 'Laptop'; break;
31
case 'ereader': $row->type = 'E-reader'; break;
32
case 'gaming': $row->type = 'Gaming'; break;
33
case 'pda': $row->type = 'PDA'; break;
34
case 'television': $row->type = 'Television'; break;
35
default: $row->type = 'Other';
38
if ($row->defaultFingerprint) {
39
$row->defaultResults = Results::getByUniqueId($row->defaultFingerprint);
b'\\ No newline at end of file'