Function __global->_points_refund_calculate
Definitions
sources/points2.php
- Calculate how many points will be refunded to the recipient.
- Visibility: public
- Is abstract?: No
- Is static?: No
- Is final?: No
- Returns: array
Parameters
| Name | Type | Passed by reference? | Variadic? | Default | Set | Range | Description |
|---|---|---|---|---|---|---|---|
| $total_points | integer | No | No | required parameter | N/A | N/A | The total number of points to refund (includes gift points when applicable) |
| $amount_gift_points | integer | No | No | 0 | N/A | N/A | The strict number of $total_points which should be refunded |
Returns
- Duple containing the number of regular points (key 0) and number of gift points (key 1) that should be refunded
- Type: array
- Set: N/A
- Range: N/A
Preview
Code (PHP)
/**
* Calculate how many points will be refunded to the recipient.
*
* @param integer $total_points The total number of points to refund (includes gift points when applicable)
* @param integer $amount_gift_points The strict number of $total_points which should be refunded
* @return array Duple containing the number of regular points (key 0) and number of gift points (key 1) that should be refunded
*/
function _points_refund_calculate(int $total_points, int $amount_gift_points = 0) : array
* Calculate how many points will be refunded to the recipient.
*
* @param integer $total_points The total number of points to refund (includes gift points when applicable)
* @param integer $amount_gift_points The strict number of $total_points which should be refunded
* @return array Duple containing the number of regular points (key 0) and number of gift points (key 1) that should be refunded
*/
function _points_refund_calculate(int $total_points, int $amount_gift_points = 0) : array

