<?xml version="1.0"?>
<!--
/** 
 * Handles magento cart events
 */
-->
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:Event/etc/events.xsd">
    <event name="sales_order_place_before">
        <observer name="salesOrderPlaceBeforeApproveCart" instance="Bloyal\Calculatecart\Observer\ApproveCart" disabled="false" />
    </event>
    <event name="sales_order_place_after"> 
        <observer name="salesOrderPlaceAfterCommitCart" instance="Bloyal\Calculatecart\Observer\CommitCart" disabled="false" />
		<observer name="salesOrderPlaceAfterRedeemGiftcard" instance="Bloyal\Calculatecart\Observer\RedeemCaptureGiftcard" disabled="false" />
		<observer name="salesOrderPlaceAfterRedeemCapture" instance="Bloyal\Calculatecart\Observer\RedeemCaptureLoyaltyDollar" disabled="false" />
    </event>
    <event name="sales_model_service_quote_submit_before">
        <observer name="transferBloyalDiscount" instance="Bloyal\Calculatecart\Observer\AddBloyalDiscountToOrder" />
    </event>
	<event name="payment_method_is_active">
        <observer name="disable_giftcard_payment_tender" instance="Bloyal\Calculatecart\Observer\DisableGiftCardTender" disabled="true"/>
		<observer name="disable_loyaltydollar_payment" instance="Bloyal\Calculatecart\Observer\DisableLoyaltyDollarPM" />
    </event>
</config>