ALTER TABLE `tblemailtemplates_static` ADD `used_in_cp` TINYINT(1) NOT NULL DEFAULT '1' AFTER `active`;

UPDATE tblemailtemplates_static SET used_in_cp = 0 WHERE slug IN (
    'new-ticket-opened-admin',
    'ticket-reply',
    'ticket-autoresponse',
    'new-ticket-created-staff',
    'ticket-reply-to-admin',
    'task-commented',
    'task-added-attachment',
    'task-added-as-follower',
    'auto-close-ticket',
    'contact-forgot-password',
    'contact-password-reseted',
    'contact-set-password',
    'task-added-attachment-to-contacts',
    'task-commented-to-contacts',
    'new-lead-assigned',
    'ticket-assigned-to-admin',
    'new-client-registered-to-admin',
    'new-web-to-lead-form-submitted',
    'two-factor-authentication',
    'task-status-change-to-staff',
    'task-status-change-to-contacts',
    'reminder-email-staff',
    'client-registration-confirmed',
    'contact-verification-email',
    'new-customer-profile-file-uploaded-to-staff',
    'event-notification-to-staff'
);
DELETE FROM tblemailtemplates WHERE slug IN (
    'new-ticket-opened-admin',
    'ticket-reply',
    'ticket-autoresponse',
    'new-ticket-created-staff',
    'ticket-reply-to-admin',
    'task-commented',
    'task-added-attachment',
    'task-added-as-follower',
    'auto-close-ticket',
    'contact-forgot-password',
    'contact-password-reseted',
    'contact-set-password',
    'task-added-attachment-to-contacts',
    'task-commented-to-contacts',
    'new-lead-assigned',
    'ticket-assigned-to-admin',
    'new-client-registered-to-admin',
    'new-web-to-lead-form-submitted',
    'two-factor-authentication',
    'task-status-change-to-staff',
    'task-status-change-to-contacts',
    'reminder-email-staff',
    'client-registration-confirmed',
    'contact-verification-email',
    'new-customer-profile-file-uploaded-to-staff',
    'event-notification-to-staff'
);