<?php
/**
 * PeachPay Square hooks
 *
 * @package PeachPay
 */

defined( 'ABSPATH' ) || exit;

add_filter( 'peachpay_register_feature', 'peachpay_square_register_feature' );
add_action( 'peachpay_settings_admin_action', 'peachpay_square_handle_admin_actions', 10, 1 );

add_action( 'wp_ajax_pp-square-applepay-domain-register', 'peachpay_square_handle_applepay_domain_registration' );
add_action( 'wp_ajax_pp-square-save-credentials', 'peachpay_square_handle_save_credentials' );
add_action( 'wp_ajax_pp-square-disconnect', 'peachpay_square_handle_disconnect' );

add_action( 'woocommerce_admin_order_data_after_billing_address', 'peachpay_square_display_order_transaction_details' );
add_action( 'woocommerce_admin_order_totals_after_total', 'peachpay_square_display_transaction_fee_lines' );
