ADVANCED_COUPONS_USER_RECEIVES_CREDIT::define_trigger()
Define and register the trigger by pushing it into the Automator object
Source Source
File: src/integrations/advanced-coupons/triggers/advanced-coupons-user-receives-credit.php
public function define_trigger() { $trigger = array( 'author' => Automator()->get_author_name(), 'support_link' => Automator()->get_author_support_link( $this->trigger_code, 'integration/advanced-coupons/' ), 'integration' => self::$integration, 'code' => $this->trigger_code, /* translators: Logged-in trigger - Advanced Coupons */ 'sentence' => sprintf( esc_attr__( 'A user receives {{greater than, less than, or equal to:%1$s}} {{a specific amount:%2$s}} of store credit', 'uncanny-automator' ), $this->trigger_meta, 'ACFWC_AMOUNT' ), /* translators: Logged-in trigger - Advanced Coupons */ 'select_option_name' => esc_attr__( 'A user receives {{greater than, less than, or equal to}} {{a specific amount}} of store credit', 'uncanny-automator' ), 'action' => 'acfw_create_store_credit_entry', 'priority' => 10, 'accepted_args' => 1, 'validation_function' => array( $this, 'user_receives_credit' ), 'options_callback' => array( $this, 'load_options' ), ); Automator()->register->trigger( $trigger ); }
Expand full source code Collapse full source code View on Github