Fix some dashbiard issues

This commit is contained in:
James Brooks
2016-02-01 19:26:00 +00:00
parent 2c26bd7396
commit 3e834f0104
3 changed files with 5 additions and 7 deletions

File diff suppressed because one or more lines are too long

View File

@@ -1,4 +1,4 @@
{
"dist/css/all.css": "dist/css/all-0a0328c0cc.css",
"dist/js/all.js": "dist/js/all-47747ca921.js"
"dist/js/all.js": "dist/js/all-e705b7b737.js"
}

View File

@@ -40,10 +40,8 @@ $(function() {
$('[data-method]').not(".disabled").append(function() {
var methodForm = "\n";
methodForm += "<form action='" + $(this).attr('href') + "' method='POST' style='display:none'>\n";
methodForm += " <input type='hidden' name='_method' value='" + $(this).attr('data-method') + "'>\n";
if ($(this).attr('data-token')) {
methodForm += "<input type='hidden' name='_token' value='" + $(this).attr('data-token') + "'>\n";
}
methodForm += "<input type='hidden' name='_method' value='" + $(this).attr('data-method') + "'>\n";
methodForm += "<input type='hidden' name='_token' value='" + $('meta[name=token]').attr('content') + "'>\n";
methodForm += "</form>\n";
return methodForm;
})