2 ) );
list( $aieo_wf_tm_open, $aieo_wf_tm_close ) = AIEO_DMM_UI::card( array(
'anchor' => 'workflows-sending',
'icon' => 'send',
'title' => __( 'Sending', 'ai-eshop-optimizer' ),
'description' => __( 'Whether each channel sends nothing, sends to the testers only, or sends to every customer the workflows reach.', 'ai-eshop-optimizer' ),
'col' => 1,
) );
echo $aieo_wf_tm_open . AIEO_DMM_Workflows::sending_body() . $aieo_wf_tm_close;
list( $aieo_wf_tm_open, $aieo_wf_tm_close ) = AIEO_DMM_UI::card( array(
'anchor' => 'workflows-testers',
'icon' => 'user-round-check',
'title' => __( 'Testers', 'ai-eshop-optimizer' ),
'description' => __( 'The people who receive the workflows\' real messages and coupons while a channel is in Test.', 'ai-eshop-optimizer' ),
'col' => 2,
'footer' => \Rooster\Admin\Ui::button( __( 'Save testers', 'ai-eshop-optimizer' ), array( 'variant' => 'primary', 'attrs' => array( 'id' => 'aieo-wf-testers-save' ) ) ),
) );
echo $aieo_wf_tm_open . AIEO_DMM_Workflows::testers_body() . $aieo_wf_tm_close;
rooster_admin_band_close();
}
?>
'workflows-campaigns-workflows',
'icon' => 'workflow',
'title' => __( 'Workflows', 'ai-eshop-optimizer' ),
'description' => __( 'The automated email and push sequences, what starts each one and whether it is active.', 'ai-eshop-optimizer' ),
'flush' => true,
'tools' => \Rooster\Admin\Ui::button( __( 'New workflow', 'ai-eshop-optimizer' ), array( 'size' => 'sm', 'icon' => 'plus', 'attrs' => array( 'id' => 'aieo-wf-new' ) ) ),
) );
echo $aieo_wf_open;
?>
true, 'icon' => 'lock' ) ); ?>
'workflows-test-runs',
'icon' => 'flask-conical',
'title' => __( 'Test runs and coupons', 'ai-eshop-optimizer' ),
'description' => __( 'What the workflows did for the testers: each test run, and the real coupons minted for them.', 'ai-eshop-optimizer' ),
'flush' => true,
'footer' => \Rooster\Admin\Ui::button( __( 'Remove test coupons', 'ai-eshop-optimizer' ), array( 'variant' => 'destructive', 'attrs' => array( 'id' => 'aieo-wf-test-coupons-remove' ) + \Rooster\Admin\States::confirm_attrs( 'aieo-wf-test-coupons-dialog' ) ) ),
) );
echo $aieo_wf_tl_open . AIEO_DMM_Workflows::test_log_body() . $aieo_wf_tl_close;
echo \Rooster\Admin\States::confirm(
'aieo-wf-test-coupons-dialog',
'delete',
__( 'Remove every test coupon?', 'ai-eshop-optimizer' ),
'
' . esc_html__( 'The testers\' coupons are deleted from WooCommerce, so their codes stop working. Customers\' coupons are not touched.', 'ai-eshop-optimizer' ) . '
',
array( 'confirm' => __( 'Remove test coupons', 'ai-eshop-optimizer' ) )
);
echo \Rooster\Admin\Ui::dialog(
'aieo-wf-golive-dialog',
__( 'Go live?', 'ai-eshop-optimizer' ),
'',
array(
'footer' => \Rooster\Admin\Ui::button( __( 'Cancel them and go live', 'ai-eshop-optimizer' ), array( 'variant' => 'primary', 'attrs' => array( 'data-aieo-golive' => 'cancel' ) ) )
. ' ' . \Rooster\Admin\Ui::button( __( 'Keep the last 7 days\' and go live', 'ai-eshop-optimizer' ), array( 'attrs' => array( 'data-aieo-golive' => 'keep', 'id' => 'aieo-wf-golive-keep' ) ) )
. ' ' . \Rooster\Admin\Ui::button( __( 'Stay as it is', 'ai-eshop-optimizer' ), array( 'attrs' => array( 'data-ra-dialog-close' => '', 'data-aieo-golive' => 'stay' ) ) ),
)
);
echo \Rooster\Admin\Ui::dialog(
'aieo-wf-tester-dialog',
__( 'Run for a tester', 'ai-eshop-optimizer' ),
'
' . esc_html__( 'A real run of this workflow for the tester, starting now: real messages on every channel they can receive, a real coupon locked to them, and real waits.', 'ai-eshop-optimizer' ) . '
'
. ''
. '',
array(
'wide' => true,
'confirm' => '',
'cancel' => __( 'Close', 'ai-eshop-optimizer' ),
)
);
echo \Rooster\Admin\Ui::dialog(
'aieo-wf-test-dialog',
__( 'Send a test of this campaign', 'ai-eshop-optimizer' ),
'
' . esc_html__( 'Delivered to this address only: it bypasses the paused engine and the opt-out list. An offer\'s coupon is a preview coupon, locked to this address.', 'ai-eshop-optimizer' ) . '