class uc_coupon_handler_field_value in Ubercart Discount Coupons 6
Same name and namespace in other branches
- 7.3 views/uc_coupon_handler_field_value.inc \uc_coupon_handler_field_value
- 7.2 views/uc_coupon_handler_field_value.inc \uc_coupon_handler_field_value
Return a coupon value as price or percentage.
Hierarchy
- class \uc_coupon_handler_field_value extends \views_handler_field_numeric
Expanded class hierarchy of uc_coupon_handler_field_value
1 string reference to 'uc_coupon_handler_field_value'
- uc_coupon_views_data in views/
uc_coupon.views.inc - Implementation of hook_views_data().
File
- views/
uc_coupon_handler_field_value.inc, line 11 - Views handler: Coupon value field.
View source
class uc_coupon_handler_field_value extends views_handler_field_numeric {
function render($values) {
$coupon = new stdClass();
$coupon->value = $values->{$this->field_alias};
$coupon->type = $values->{$this->aliases['type']};
return uc_coupon_format_discount($coupon);
}
}