@@ -76,6 +76,13 @@ class WooTab extends WC_Settings_Page implements Hookable {
7676 */
7777 const EMAIL_FIELD = 'cc_woo_store_information_contact_email ' ;
7878
79+ /**
80+ * Store checkbox location.
81+ *
82+ * @since 2021-07-26
83+ */
84+ const CHECKBOX_LOCATION = 'cc_woo_store_information_checkbox_location ' ;
85+
7986 /**
8087 * Settings section ID.
8188 *
@@ -474,6 +481,17 @@ private function get_store_information_settings() {
474481 'true ' => esc_html__ ( 'Yes - check this box by default ' , 'cc-woo ' ),
475482 ],
476483 ],
484+ [
485+ 'title ' => esc_html__ ( 'Checkbox Filter Location ' , 'cc-woo ' ),
486+ 'desc ' => esc_html__ ( 'Change filter location where checkbox is rendered. ' , 'cc-woo ' ),
487+ 'type ' => 'select ' ,
488+ 'id ' => self ::CHECKBOX_LOCATION ,
489+ 'default ' => 'false ' ,
490+ 'options ' => [
491+ 'woocommerce_after_checkout_billing_form ' => esc_html__ ( 'woocommerce_after_checkout_billing_form ' , 'cc-woo ' ),
492+ 'woocommerce_review_order_before_submit ' => esc_html__ ( 'woocommerce_review_order_before_submit ' , 'cc-woo ' ),
493+ ],
494+ ],
477495 [
478496 'type ' => 'sectionend ' ,
479497 'id ' => 'cc_woo_store_information_settings ' ,
@@ -643,7 +661,8 @@ private function meets_connect_requirements() {
643661 get_option ( self ::STORE_NAME_FIELD , '' ),
644662 get_option ( self ::CURRENCY_FIELD , '' ),
645663 get_option ( self ::COUNTRY_CODE_FIELD ),
646- get_option ( self ::EMAIL_FIELD )
664+ get_option ( self ::EMAIL_FIELD ),
665+ get_option ( self ::CHECKBOX_LOCATION )
647666 );
648667
649668 $ validator = new SettingsValidator ( $ model );
0 commit comments