1
0
mirror of synced 2024-11-24 04:46:02 +03:00

improve makefile, time disable form

This commit is contained in:
DmitryZagorulko 2018-09-28 17:06:50 +03:00
parent 73efd7209b
commit 304d66ee78
2 changed files with 5 additions and 2 deletions

View File

@ -23,6 +23,7 @@ jenkins_test: migrate_test
@echo "==> Running tests (result in test-report.xml)" @echo "==> Running tests (result in test-report.xml)"
@go get -v -u github.com/jstemmer/go-junit-report @go get -v -u github.com/jstemmer/go-junit-report
@go test ./... -v -cpu 2 -race | /go/bin/go-junit-report -set-exit-code > ./test-report.xml @go test ./... -v -cpu 2 -race | /go/bin/go-junit-report -set-exit-code > ./test-report.xml
@go mod tidy
fmt: fmt:
@echo "==> Running gofmt" @echo "==> Running gofmt"

View File

@ -122,7 +122,9 @@ function send(url, data, callback) {
M.toast({ M.toast({
html: res.responseJSON.error, html: res.responseJSON.error,
displayLength: 1000, displayLength: 1000,
completeCallback: enableForm() completeCallback: function(){
enableForm()
}
}) })
} }
} }
@ -203,7 +205,7 @@ $( document ).ready(function() {
function disableForm(elem) { function disableForm(elem) {
$(document).find('button.btn').addClass('disabled'); $(document).find('button.btn').addClass('disabled');
elem.find(".material-icons").addClass('animate'); elem.find(".material-icons").addClass('animate');
$("form :input").find(":input").prop("disabled", true); $("form :input").prop("disabled", true);
} }
function enableForm() { function enableForm() {