Added custom date (reason: firefox never love date inputs)
This commit is contained in:
@@ -20,12 +20,12 @@
|
||||
<br>
|
||||
|
||||
<label for="expired_at">Berlaku dari: </label>
|
||||
<input type="date" name="valid_at" value="{{ timestamp }}">
|
||||
<input id="left" name="valid_at" value="{{ timestamp }}">
|
||||
|
||||
<br>
|
||||
|
||||
<label for="expired_at">Berlaku sampai: </label>
|
||||
<input type="date" name="expired_at" value="{{ timestamp }}">
|
||||
<input id="right" name="expired_at" value="{{ timestamp }}">
|
||||
|
||||
<br>
|
||||
</div>
|
||||
@@ -55,4 +55,15 @@
|
||||
</form>
|
||||
</section>
|
||||
</main>
|
||||
|
||||
<script>
|
||||
rome(left, {
|
||||
dateValidator: rome.val.beforeEq(right),
|
||||
time: false
|
||||
});
|
||||
rome(right, {
|
||||
dateValidator: rome.val.afterEq(left),
|
||||
time: false
|
||||
});
|
||||
</script>
|
||||
{% endblock %}
|
||||
|
||||
Reference in New Issue
Block a user