From 9c7adb99413ece99a7f71fb01837ece81de55656 Mon Sep 17 00:00:00 2001 From: William Woodson Date: Sun, 21 Feb 2016 16:51:01 -0600 Subject: [PATCH] Cleaning up artifacts in modals on edit/copy/new for #143 --- static/js/app/campaigns.js | 6 ++++++ static/js/app/sending_profiles.js | 2 ++ static/js/app/templates.js | 1 + templates/campaigns.html | 4 ++-- templates/landing_pages.html | 2 +- templates/sending_profiles.html | 2 +- templates/templates.html | 2 +- 7 files changed, 14 insertions(+), 5 deletions(-) diff --git a/static/js/app/campaigns.js b/static/js/app/campaigns.js index 0ac1e4ed..4b3ff387 100644 --- a/static/js/app/campaigns.js +++ b/static/js/app/campaigns.js @@ -87,6 +87,12 @@ function sendTestEmail() { function dismiss() { $("#modal\\.flashes").empty() + $("#name").val("") + $("#template").val("") + $("#page").val("") + $("#url").val("") + $("#profile").val("") + $("#groupSelect").val("") $("#modal").modal('hide') $("#groupTable").dataTable().DataTable().clear().draw() } diff --git a/static/js/app/sending_profiles.js b/static/js/app/sending_profiles.js index 72edced0..76c29c09 100644 --- a/static/js/app/sending_profiles.js +++ b/static/js/app/sending_profiles.js @@ -69,10 +69,12 @@ function save(idx) { function dismiss() { $("#modal\\.flashes").empty() $("#name").val("") + $("#interface_type").val("SMTP") $("#from").val("") $("#host").val("") $("#username").val("") $("#password").val("") + $("#ignore_cert_errors").prop("checked", true) $("#modal").modal('hide') } diff --git a/static/js/app/templates.js b/static/js/app/templates.js index 14906a11..984f463e 100644 --- a/static/js/app/templates.js +++ b/static/js/app/templates.js @@ -64,6 +64,7 @@ function dismiss() { $("#modal\\.flashes").empty() $("#attachmentsTable").dataTable().DataTable().clear().draw() $("#name").val("") + $("#subject").val("") $("#text_editor").val("") $("#html_editor").val("") $("#modal").modal('hide') diff --git a/templates/campaigns.html b/templates/campaigns.html index 6e65dbba..7850a75e 100644 --- a/templates/campaigns.html +++ b/templates/campaigns.html @@ -65,7 +65,7 @@ diff --git a/templates/landing_pages.html b/templates/landing_pages.html index 25bba97a..c7fe1c10 100644 --- a/templates/landing_pages.html +++ b/templates/landing_pages.html @@ -63,7 +63,7 @@