function _uc_quote_type_sort in Ubercart 8.4
Same name and namespace in other branches
- 5 shipping/uc_quote/uc_quote.module \_uc_quote_type_sort()
- 6.2 shipping/uc_quote/uc_quote.module \_uc_quote_type_sort()
- 7.3 shipping/uc_quote/uc_quote.module \_uc_quote_type_sort()
Callback for uasort().
1 string reference to '_uc_quote_type_sort'
- uc_quote_shipping_type_options in shipping/
uc_quote/ uc_quote.module - Returns an options array of shipping types.
File
- shipping/
uc_quote/ uc_quote.module, line 568 - The controller module for fulfillment modules that process physical goods.
Code
function _uc_quote_type_sort($a, $b) {
$aw = $a['weight'];
$bw = $b['weight'];
if ($aw == $bw) {
return strcasecmp($a['id'], $b['id']);
}
else {
return $aw < $bw ? -1 : 1;
}
}