# acymailing/11.0.3/back/Views/Automation/tmpl/listing.php

AcyMailing – An Ultimate Newsletter Plugin and Marketing Automation Solution for WordPress, version 11.0.3. 183 lines.

- Page: https://pluginprobe.com/plugins/acymailing/11.0.3/code/back/Views/Automation/tmpl/listing.php
- Raw: https://pluginprobe.com/plugins/acymailing/11.0.3/raw/back/Views/Automation/tmpl/listing.php
- Modified: 2026-08-03T10:18:54+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/acymailing/11.0.3/code/back/Views/Automation/tmpl/listing.php#L10-L20`.

```php
<?php
// phpcs:disable WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound -- View file, its variables are local to the include scope, not true globals.
defined('ABSPATH') || die('Restricted Access');
?>
<form id="acym_form" action="<?php echo esc_url(acym_completeLink(acym_getVar('cmd', 'ctrl'))); ?>" method="post" name="acyForm">
    <?php
    $isEmpty = empty($data['allAutomations']) && empty($data['search']) && empty($data['tag']) && empty($data['status']);
    if (!$isEmpty) {
        $data['toolbar']->displayToolbar($data);
    }
    ?>
	<div id="acym__automation" class="acym__content">
        <?php if ($isEmpty) { ?>
			<div class="grid-x text-center acym__listing__empty">
				<h1 class="cell acym__listing__empty__title"><?php echo esc_html(acym_translation('ACYM_YOU_DONT_HAVE_ANY_AUTOMATION')); ?></h1>
				<h1 class="cell acym__listing__empty__subtitle"><?php echo esc_html(acym_translation('ACYM_CREATE_ONE_AND_LET_ACYMAILING_DO_IT')); ?></h1>
				<div class="cell medium-4 hide-for-small-only"></div>
				<div class="cell medium-4 grid-x grid-margin-x align-center">
					<div class="cell small-6 padding-bottom-1">
						<button type="button" class="button button-secondary acy_button_submit" data-task="edit" data-step="action">
                            <?php echo esc_html(acym_translation('ACYM_NEW_MASS_ACTION')); ?>
						</button>
					</div>
					<div class="cell small-6 padding-bottom-1">
						<button type="button" class="button acy_button_submit" data-task="edit" data-step="info">
                            <?php echo esc_html(acym_translation('ACYM_CREATE_AUTOMATION')); ?>
						</button>
					</div>
				</div>
			</div>
        <?php } else { ?>
            <?php if (empty($data['allAutomations'])) { ?>
				<h1 class="cell acym__listing__empty__search__title text-center"><?php echo esc_html(acym_translation('ACYM_NO_RESULTS_FOUND')); ?></h1>
            <?php } else { ?>
				<div class="cell grid-x margin-top-1">
					<div class="grid-x acym__listing__actions cell margin-bottom-1">
                        <?php
                        $actions = [
                            'setActive' => acym_translation('ACYM_ENABLE'),
                            'setInactive' => acym_translation('ACYM_DISABLE'),
                            'triggerAutomation' => acym_translation('ACYM_TRIGGER'),
                            'duplicate' => acym_translation('ACYM_DUPLICATE'),
                            'delete' => acym_translation('ACYM_DELETE'),
                        ];
                        acym_listingActions($actions, acym_translation('ACYM_BE_CAREFUL_THIS_DELETE_ELEMENTS_LINKED_AUTOMATION'));
                        ?>
					</div>
					<div class="grid-x cell align-justify">
						<div class="cell grid-x large-shrink acym_vcenter">
                            <?php
                            $options = [
                                '' => ['ACYM_ALL', $data["automationNumberPerStatus"]["all"]],
                                'active' => ['ACYM_ACTIVE', $data["automationNumberPerStatus"]["active"]],
                                'inactive' => ['ACYM_INACTIVE', $data["automationNumberPerStatus"]["inactive"]],
                            ];
                            acym_filterStatus($options, $data['status'], 'automation_status');
                            ?>
						</div>
						<div class="cell large-shrink acym_listing_sort-by">
                            <?php
                            if (empty($data['ordering'])) {
                                $data['ordering'] = 'ordering';
                            }
                            if (empty($data['orderingSortOrder'])) {
                                $data['orderingSortOrder'] = 'asc';
                            }
                            acym_sortBy(
                                [
                                    'id' => acym_strtolower(acym_translation('ACYM_ID')),
                                    'name' => acym_translation('ACYM_NAME'),
                                    'active' => acym_translation('ACYM_ACTIVE'),
                                    'ordering' => acym_translation('ACYM_ORDERING'),
                                ],
                                'automation',
                                $data['ordering'],
                                $data['orderingSortOrder']
                            ); ?>
						</div>
					</div>
				</div>
				<div class="grid-x acym__listing acym__sortable__listing acym__automation__listing cell grid-x" data-sort-ctrl="automation">
					<div class="grid-x cell acym__listing__header">
						<div class="medium-shrink small-1 cell">
							<input id="checkbox_all" type="checkbox" name="checkbox_all">
						</div>
						<div class="grid-x medium-auto small-11 cell acym__listing__header__title__container">
							<div class="medium-1 small-1 hide-for-small-only cell acym__listing__header__title">
							</div>
							<div class="medium-5 small-9 cell acym__listing__header__title">
                                <?php echo esc_html(acym_translation('ACYM_AUTOMATION')); ?>
							</div>
							<div class="medium-auto hide-for-small-only cell acym__listing__header__title">
                                <?php echo esc_html(acym_translation('ACYM_DESCRIPTION')); ?>
							</div>
							<div class="medium-2 text-center hide-for-small-only cell acym__listing__header__title">
                                <?php echo esc_html(acym_translation('ACYM_ACTIVE')); ?>
							</div>
							<div class="medium-2 text-center hide-for-small-only cell acym__listing__header__title">
                                <?php echo esc_html(acym_translation('ACYM_ACTION')); ?>
							</div>
							<div class="medium-1 text-center hide-for-small-only cell acym__listing__header__title">
                                <?php echo esc_html(acym_translation('ACYM_ID')); ?>
							</div>
						</div>
					</div>
                    <?php foreach ($data['allAutomations'] as $automation) { ?>
						<div data-acy-elementid="<?php echo esc_attr($automation->id); ?>" class="grid-x cell align-middle acym__listing__row"
						     data-id-element="<?php echo esc_attr($automation->id); ?>">
							<div class="medium-shrink small-1 cell">
								<input id="checkbox_<?php echo esc_attr($automation->id); ?>"
								       type="checkbox"
								       name="elements_checked[]"
								       value="<?php echo esc_attr($automation->id); ?>">
							</div>
							<div class="grid-x medium-auto small-11 cell acym__listing__title__container">
								<div class="medium-1 small-1 cell acym_vcenter align-center acym__automation__listing__handle acym__listing__handle">
									<div class="grabbable acym__sortable__listing__handle grid-x">
										<i class="acymicon-ellipsis-h cell acym__color__dark-gray"></i>
										<i class="acymicon-ellipsis-h cell acym__color__dark-gray"></i>
									</div>
								</div>
								<div class="grid-x medium-5 small-9 cell acym__listing__title">
									<a class="cell auto" href="<?php echo esc_url(acym_completeLink('automation&task=edit&step=info&id=').esc_attr($automation->id)); ?>">
										<h6><?php echo esc_html(acym_translation($automation->name)); ?></h6>
									</a>
								</div>
								<div class="medium-auto hide-for-small-only cell grid-x">
									<h6 class="cell acym__listing__text">
                                        <?php
                                        $automation->description = empty($automation->description) ? '' : acym_translation($automation->description);
                                        if (strlen($automation->description) >= 50) {
                                            acym_tooltip(
                                                [
                                                    'hoveredText' => substr($automation->description, 0, 50),
                                                    'textShownInTooltip' => $automation->description,
                                                ]
                                            ).'...';
                                        } else {
                                            echo esc_html($automation->description);
                                        }
                                        ?>
									</h6>
								</div>
								<div class="medium-2 cell acym__listing__controls grid-x">
									<div class="text-center cell">
                                        <?php
                                        $class = $automation->active == 1 ? 'acymicon-check-circle acym__color__green' : 'acymicon-times-circle acym__color__red';
                                        $newvalue = $automation->active == 1 ? 0 : 1;
                                        echo '<i data-acy-table="automation" data-acy-field="active" data-acy-elementid="'.esc_attr(
                                                $automation->id
                                            ).'" data-acy-newvalue="'.esc_attr($newvalue).'" class="acym_toggleable '.esc_attr($class).'"></i>';
                                        ?>
									</div>
								</div>
								<div class="medium-2 hide-for-small-only cell grid-x acym_vcenter align-center">
                                    <?php if (!empty($automation->type_trigger) && $automation->type_trigger === 'classic') { ?>
										<i class="cursor-pointer acymicon-paper-plane fastActions"
										   data-action="triggerAutomation"
										   data-acy-elementid="<?php echo esc_attr($automation->id); ?>"
										   title="<?php echo esc_attr(acym_translation('ACYM_TRIGGER')); ?>"></i>
                                    <?php } else { ?>
                                        <?php acym_tooltip(
                                            [
                                                'hoveredText' => '<i class="acymicon-paper-plane acym__color__medium-gray"></i>',
                                                'textShownInTooltip' => acym_translation('ACYM_MANUAL_TRIGGER_NOT_AVAILABLE_FOR_THIS_TYPE'),
                                            ]
                                        ); ?>
                                    <?php } ?>
								</div>
								<div class="medium-1 hide-for-small-only grid-x">
									<h6 class="cell text-center acym__listing__text"><?php echo esc_html($automation->id); ?></h6>
								</div>
							</div>
						</div>
                    <?php } ?>
                    <?php $data['pagination']->display('automation'); ?>
				</div>
            <?php }
        } ?>
	</div>
    <?php acym_formOptions(); ?>
</form>

```
