diff options
| author | Ian Gilfillan <ian@greenman.co.za> | 2016-07-11 22:24:20 +0000 | 
|---|---|---|
| committer | Ian Gilfillan <ian@greenman.co.za> | 2016-07-11 22:24:20 +0000 | 
| commit | c30141e10fb9eb9ff4be8fa87d49d3a86abe1a3d (patch) | |
| tree | d9a92d7b2730b9373125d83697c5c639636d99b8 /h-source/Application/Include/myFunctions.php | |
| parent | 55505848eaf681e378e0a34af204da10566254e9 (diff) | |
Sort each hardware category by compatibility
Diffstat (limited to 'h-source/Application/Include/myFunctions.php')
| -rw-r--r-- | h-source/Application/Include/myFunctions.php | 28 | 
1 files changed, 27 insertions, 1 deletions
| diff --git a/h-source/Application/Include/myFunctions.php b/h-source/Application/Include/myFunctions.php index 903c013..c4a220b 100644 --- a/h-source/Application/Include/myFunctions.php +++ b/h-source/Application/Include/myFunctions.php @@ -124,13 +124,39 @@ function getOrderByClause($string)  		case 'compatibility':  			$orderBy = 'compatibility, hardware.id_hard desc';  			break; +		case 'compatibility-desc': +                        $orderBy = 'compatibility desc, hardware.id_hard desc'; +                        break; +		case 'wifi-works': +			$orderBy = 'wifi_works desc, hardware.id_hard desc'; +			break; +		case 'video-card-works': +                        $orderBy = 'video_card_works desc, hardware.id_hard desc'; +                        break; +		case 'sound-card-works': +                        $orderBy = 'sound_card_works desc, hardware.id_hard desc'; +                        break; +		case 'webcam-works': +                        $orderBy = 'webcam_works desc, hardware.id_hard desc'; +                        break; +		case 'bluetooth-works': +                        $orderBy = 'bluetooth_works desc, hardware.id_hard desc'; +                        break; +		case 'fingerprint-works': +                        $orderBy = 'fingerprint_works desc, hardware.id_hard desc'; +                        break; +		case 'ethernet-works': +                        $orderBy = 'ethernet_card_works desc, hardware.id_hard desc'; +                        break; +		case 'sdcard-works': +                        $orderBy = 'sd_card_works desc, hardware.id_hard desc'; +                        break;  		case 'undef':  			$orderBy = 'compatibility, hardware.id_hard desc';  			break;  		default:  			$orderBy = 'compatibility, hardware.id_hard desc';  	} -	  	return $orderBy;  } | 
