src/Libraries/Validations/TermCampaignValidation.php
/**
     * Checks if campaign is valid for current time.
     *
     * @return bool
     */
Checks if campaign is valid for current time.
@return bool
Checks if campaign is valid for current time . @return bool
private function isCampaignTimeValid ()
    {
        $couponAppliedAt = $this->request->coupon_applied_at ?? DateUtil::getDateTime();
        return ( $this->term->valid_from <= $couponAppliedAt && $this->term->valid_to >= $couponAppliedAt );
    }
private function isCampaignTimeValid ( ) { $ couponAppliedAt = $ this -> request -> coupon_applied_at ?? DateUtil :: getDateTime ( ) ; return ( $ this -> term -> valid_from <= $ couponAppliedAt && $ this -> term -> valid_to >= $ couponAppliedAt ) ; }
Checks if campaign is valid for current time.
Checks if campaign is valid for current time .