__( 'Order Notifications', 'aisp-order-tools-for-woocommerce' ), 'type' => 'title', 'desc' => __( 'Configure email notifications for pending orders and user registration.', 'aisp-order-tools-for-woocommerce' ), 'id' => 'aisp_otools_email_section_title', ], [ 'title' => __( 'New admin pending payment', 'aisp-order-tools-for-woocommerce' ), 'desc' => __( 'Enable this option to receive an email for new orders with pending payment.', 'aisp-order-tools-for-woocommerce' ), 'id' => 'aisp_otools_admin_pending_notification', 'type' => 'checkbox', 'default' => 'no', ], [ 'type' => 'sectionend', 'id' => 'aisp_otools_email_section_end', ], [ 'title' => __( 'Custom Email Subjects', 'aisp-order-tools-for-woocommerce' ), 'type' => 'title', 'desc' => __( 'Replace default WooCommerce email subjects for both customer and admin notifications.', 'aisp-order-tools-for-woocommerce' ), 'id' => 'aisp_otools_custom_subjects_title', ], [ 'title' => __( 'Enable custom email subjects', 'aisp-order-tools-for-woocommerce' ), 'desc' => __( 'Allow customization of email subjects for WooCommerce order notifications.', 'aisp-order-tools-for-woocommerce' ), 'id' => 'aisp_otools_enable_custom_email_subjects', 'type' => 'checkbox', 'default' => 'no', ], [ 'title' => __( 'Customer: Invoice (pending payment) subject', 'aisp-order-tools-for-woocommerce' ), 'id' => 'aisp_otools_subject_invoice_pending', 'type' => 'text', 'default' => __( 'Your order is awaiting payment', 'aisp-order-tools-for-woocommerce' ), 'desc_tip' => __( 'Used when the customer receives the invoice link for a pending order.', 'aisp-order-tools-for-woocommerce' ), 'class' => 'aisp-subject-field', ], [ 'title' => __( 'Customer: On-hold subject', 'aisp-order-tools-for-woocommerce' ), 'id' => 'aisp_otools_subject_on_hold', 'type' => 'text', 'default' => __( 'Your order is currently on hold', 'aisp-order-tools-for-woocommerce' ), 'desc_tip' => __( 'Subject for the "On hold" email sent to customers.', 'aisp-order-tools-for-woocommerce' ), 'class' => 'aisp-subject-field', ], [ 'title' => __( 'Customer: Processing subject', 'aisp-order-tools-for-woocommerce' ), 'id' => 'aisp_otools_subject_processing', 'type' => 'text', 'default' => __( 'We have received your payment for this order', 'aisp-order-tools-for-woocommerce' ), 'desc_tip' => __( 'Subject for the "Processing" email sent to customers.', 'aisp-order-tools-for-woocommerce' ), 'class' => 'aisp-subject-field', ], [ 'title' => __( 'Customer: Completed subject', 'aisp-order-tools-for-woocommerce' ), 'id' => 'aisp_otools_subject_completed', 'type' => 'text', 'default' => __( 'Your order is now complete', 'aisp-order-tools-for-woocommerce' ), 'desc_tip' => __( 'Subject for the "Completed" email sent to customers.', 'aisp-order-tools-for-woocommerce' ), 'class' => 'aisp-subject-field', ], [ 'title' => __( 'Admin pending invoice subject', 'aisp-order-tools-for-woocommerce' ), 'id' => 'aisp_otools_admin_subject_invoice_pending', 'type' => 'text', 'default' => __( 'New order awaiting payment', 'aisp-order-tools-for-woocommerce' ), 'desc_tip' => __( 'Subject for the "New pending order" email sent to admins.', 'aisp-order-tools-for-woocommerce' ), 'class' => 'aisp-subject-field', ], [ 'title' => __( 'Admin: New order (on-hold) subject', 'aisp-order-tools-for-woocommerce' ), 'id' => 'aisp_otools_admin_subject_on_hold', 'type' => 'text', 'default' => __( 'New order on hold – payment to be confirmed', 'aisp-order-tools-for-woocommerce' ), 'desc_tip' => __( 'Subject for admin "New order" emails when the order is on-hold.', 'aisp-order-tools-for-woocommerce' ), 'class' => 'aisp-subject-field', ], [ 'title' => __( 'Admin: New order (processing) subject', 'aisp-order-tools-for-woocommerce' ), 'id' => 'aisp_otools_admin_subject_processing', 'type' => 'text', 'default' => __( 'New paid order received', 'aisp-order-tools-for-woocommerce' ), 'desc_tip' => __( 'Subject for admin "New order" emails when the order is processing.', 'aisp-order-tools-for-woocommerce' ), 'class' => 'aisp-subject-field', ], [ 'type' => 'sectionend', 'id' => 'aisp_otools_custom_subjects_end', ], [ 'title' => __( 'Available Placeholder', 'aisp-order-tools-for-woocommerce' ), 'type' => 'title', 'id' => 'aisp_otools_placeholder_company_title', ], [ 'type' => 'aisp_html', 'id' => 'aisp_otools_placeholder_company', 'html' => '

Use the placeholder below inside your custom subjects or messages to automatically insert the customer\'s billing company name.

%company%

Example:

Your order for %company% is now ready for pickup.

', ], [ 'type' => 'sectionend', 'id' => 'aisp_otools_placeholders_end', ], [ 'title' => __( 'Pickup Notifications', 'aisp-order-tools-for-woocommerce' ), 'type' => 'title', 'desc' => __( 'Configure customer emails sent when a pickup order is completed.', 'aisp-order-tools-for-woocommerce' ), 'id' => 'aisp_otools_pickup_section_title', ], [ 'title' => __( 'Enable pickup email (customer)', 'aisp-order-tools-for-woocommerce' ), 'desc' => __( 'Send an email when an order with a pickup method is marked as completed.', 'aisp-order-tools-for-woocommerce' ), 'id' => 'aisp_otools_enable_email_pickup', 'type' => 'checkbox', 'default' => 'no', ], [ 'title' => __( 'Enable get direction', 'aisp-order-tools-for-woocommerce' ), 'desc' => __( 'Add a Google Maps directions link to the pickup email (single pickup location support).', 'aisp-order-tools-for-woocommerce' ), 'id' => 'aisp_otools_enable_get_direction_pickup_email', 'type' => 'checkbox', 'default' => 'no', ], [ 'title' => __( 'Pickup shipping methods', 'aisp-order-tools-for-woocommerce' ), 'desc' => __( 'Select which shipping methods should trigger the pickup email.', 'aisp-order-tools-for-woocommerce' ), 'id' => 'aisp_otools_pickup_methods', 'type' => 'multiselect', 'class' => 'wc-enhanced-select', 'options' => function_exists( 'AISP_OTOOLS\aisp_otools_get_shipping_methods_list' ) ? aisp_otools_get_shipping_methods_list() : [], 'default' => [ 'local_pickup' ], ], [ 'title' => __( 'Pickup email subject', 'aisp-order-tools-for-woocommerce' ), 'id' => 'aisp_otools_pickup_subject', 'type' => 'text', 'default' => __( 'Your order is ready for pickup', 'aisp-order-tools-for-woocommerce' ), 'desc_tip' => __( 'Customize the subject of the pickup email.', 'aisp-order-tools-for-woocommerce' ), ], [ 'title' => __( 'Pickup email message', 'aisp-order-tools-for-woocommerce' ), 'id' => 'aisp_otools_pickup_message', 'type' => 'textarea', 'default' => __( 'Your order is now ready for pickup at our store. You can come anytime during business hours.', 'aisp-order-tools-for-woocommerce' ), 'desc_tip' => __( 'Customize the pickup email content.', 'aisp-order-tools-for-woocommerce' ), 'custom_attributes' => [ 'rows' => '8' ], ], [ 'type' => 'sectionend', 'id' => 'aisp_otools_pickup_section_end', ], ]; return apply_filters( 'aisp_otools_notifications_settings', $settings ); } } add_action( 'admin_enqueue_scripts', function() { $css = ' input.aisp-subject-field { width: 450px !important; max-width: 100%; } '; wp_add_inline_style( 'woocommerce_admin_styles', $css ); } );