fixed order get_total_refunded() method

This commit is contained in:
claudiosmweb 2014-07-20 23:48:23 -03:00
parent d2340a5cef
commit 299c12bd57
1 changed files with 3 additions and 1 deletions

View File

@ -62,9 +62,11 @@ class WC_Order extends WC_Abstract_Order {
FROM $wpdb->postmeta AS postmeta
INNER JOIN $wpdb->posts AS posts ON ( posts.post_type = 'shop_order_refund' AND posts.post_parent = %d )
WHERE postmeta.meta_key = '_refund_amount'
GROUP BY posts.ID
AND postmeta.post_id = posts.ID
", $this->id ) );
error_log( print_r( $this->id, true ) );
return $total;
}
}