function _uc_coupon_sort_products in Ubercart Discount Coupons 6
Same name and namespace in other branches
- 7.3 uc_coupon.module \_uc_coupon_sort_products()
- 7.2 uc_coupon.module \_uc_coupon_sort_products()
1 string reference to '_uc_coupon_sort_products'
- uc_coupon_calculate_discounts in ./
uc_coupon.module - Find items that a coupon will apply to and calculate the discounts.
File
- ./
uc_coupon.module, line 755 - Provides discount coupons for Ubercart.
Code
function _uc_coupon_sort_products($a, $b) {
if ($a->altered_price == $b->altered_price) {
return 0;
}
return $a->altered_price > $b->altered_price ? 1 : -1;
}