fix dumb things in last commit

pull/75/head^2
William Woodson 2016-01-17 13:25:13 -06:00
parent 45ac3db452
commit fa5a5c65af
3 changed files with 3 additions and 4 deletions

View File

@ -47,7 +47,7 @@ function deleteCampaign() {
if (confirm("Are you sure you want to delete: " + campaign.name + "?")) { if (confirm("Are you sure you want to delete: " + campaign.name + "?")) {
api.campaignId.delete(campaign.id) api.campaignId.delete(campaign.id)
.success(function(msg) { .success(function(msg) {
document.location.href = '/campaigns' location.href = '/campaigns'
}) })
.error(function(e) { .error(function(e) {
$("#modal\\.flashes").empty().append("<div style=\"text-align:center\" class=\"alert alert-danger\">\ $("#modal\\.flashes").empty().append("<div style=\"text-align:center\" class=\"alert alert-danger\">\

View File

@ -14,8 +14,7 @@ function deleteCampaign(idx) {
api.campaignId.delete(campaigns[idx].id) api.campaignId.delete(campaigns[idx].id)
.success(function(data) { .success(function(data) {
successFlash(data.message) successFlash(data.message)
load() location.reload()
//location.reload()
}) })
} }
} }

View File

@ -127,7 +127,7 @@
</div> </div>
</div> </div>
{{end}} {{end}}
{{define "scripts"}}i {{define "scripts"}}
<script src="/js/hogan.js"></script> <script src="/js/hogan.js"></script>
<script src="/js/typeahead.min.js"></script> <script src="/js/typeahead.min.js"></script>
<script src="/js/app/campaigns.js"></script> <script src="/js/app/campaigns.js"></script>