Action
rpress_fooditem_history_row_end
On this page
Fires at the end of each menu item row in the menu item history table.
Runs once per cart item of each order, inside the table row after the item name cell. Callbacks should echo td cells to add a trailing column.
Parameters#
| Parameter | Type | Description |
|---|---|---|
$payment_id | int | ID of the order the item belongs to. |
$fooditem_id | int | ID of the menu item in the order's cart details. |
Example#
add_action( 'rpress_fooditem_history_row_end', 'my_history_row_end', 10, 2 );
function my_history_row_end( $payment_id, $fooditem_id ) {
echo '<td><a href="' . esc_url( get_permalink( $fooditem_id ) ) . '">' . esc_html__( 'View', 'my-textdomain' ) . '</a></td>';
}
Source#
Fired from:
templates/history-fooditems.php(line 44)
See also#
Was this page helpful?
