Created
December 10, 2019 11:06
-
-
Save Kcko/aad5f43d673aa09c868f0f83aeb764bb to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// @link: https://forum.nette.org/cs/32804-vyvolani-toggle-pri-zavreni-bootstrap-datepicker | |
$(':text[data-provide="datepicker"]').datepicker({ | |
language: 'cs' | |
}) | |
.on('hide', function(e) { | |
// `e` here contains the extra attributes | |
var defaultValue = e.currentTarget.defaultValue; | |
var value = e.currentTarget.value; | |
if(defaultValue == value) { | |
Nette.toggle('submit-container', false); | |
} else { | |
Nette.toggle('submit-container', true); | |
} | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment