diff --git a/public/js/ff/accounts/create.js b/public/js/ff/accounts/create.js new file mode 100644 index 0000000000..675a5fe730 --- /dev/null +++ b/public/js/ff/accounts/create.js @@ -0,0 +1,20 @@ +/* + * create.js + * Copyright (c) 2017 thegrumpydictator@gmail.com + * This software may be modified and distributed under the terms of the Creative Commons Attribution-ShareAlike 4.0 International License. + * + * See the LICENSE file for details. + */ + +/** global: Modernizr */ + +$(document).ready(function () { + "use strict"; + if (!Modernizr.inputtypes.date) { + $('input[type="date"]').datepicker( + { + dateFormat: 'yy-mm-dd' + } + ); + } +}); diff --git a/public/js/ff/accounts/edit.js b/public/js/ff/accounts/edit.js new file mode 100644 index 0000000000..675a5fe730 --- /dev/null +++ b/public/js/ff/accounts/edit.js @@ -0,0 +1,20 @@ +/* + * create.js + * Copyright (c) 2017 thegrumpydictator@gmail.com + * This software may be modified and distributed under the terms of the Creative Commons Attribution-ShareAlike 4.0 International License. + * + * See the LICENSE file for details. + */ + +/** global: Modernizr */ + +$(document).ready(function () { + "use strict"; + if (!Modernizr.inputtypes.date) { + $('input[type="date"]').datepicker( + { + dateFormat: 'yy-mm-dd' + } + ); + } +}); diff --git a/public/js/ff/bills/create.js b/public/js/ff/bills/create.js new file mode 100644 index 0000000000..675a5fe730 --- /dev/null +++ b/public/js/ff/bills/create.js @@ -0,0 +1,20 @@ +/* + * create.js + * Copyright (c) 2017 thegrumpydictator@gmail.com + * This software may be modified and distributed under the terms of the Creative Commons Attribution-ShareAlike 4.0 International License. + * + * See the LICENSE file for details. + */ + +/** global: Modernizr */ + +$(document).ready(function () { + "use strict"; + if (!Modernizr.inputtypes.date) { + $('input[type="date"]').datepicker( + { + dateFormat: 'yy-mm-dd' + } + ); + } +}); diff --git a/public/js/ff/bills/edit.js b/public/js/ff/bills/edit.js new file mode 100644 index 0000000000..675a5fe730 --- /dev/null +++ b/public/js/ff/bills/edit.js @@ -0,0 +1,20 @@ +/* + * create.js + * Copyright (c) 2017 thegrumpydictator@gmail.com + * This software may be modified and distributed under the terms of the Creative Commons Attribution-ShareAlike 4.0 International License. + * + * See the LICENSE file for details. + */ + +/** global: Modernizr */ + +$(document).ready(function () { + "use strict"; + if (!Modernizr.inputtypes.date) { + $('input[type="date"]').datepicker( + { + dateFormat: 'yy-mm-dd' + } + ); + } +}); diff --git a/public/js/ff/export/index.js b/public/js/ff/export/index.js index 006afca9ba..e7af126f51 100644 --- a/public/js/ff/export/index.js +++ b/public/js/ff/export/index.js @@ -8,7 +8,7 @@ * See the LICENSE file for details. */ -/** global: jobKey */ +/** global: jobKey, Modernizr */ var intervalId = 0; @@ -21,6 +21,14 @@ $(function () { // - return false, $('#export').submit(startExport); + + if (!Modernizr.inputtypes.date) { + $('input[type="date"]').datepicker( + { + dateFormat: 'yy-mm-dd' + } + ); + } } ); diff --git a/public/js/ff/piggy-banks/create.js b/public/js/ff/piggy-banks/create.js new file mode 100644 index 0000000000..675a5fe730 --- /dev/null +++ b/public/js/ff/piggy-banks/create.js @@ -0,0 +1,20 @@ +/* + * create.js + * Copyright (c) 2017 thegrumpydictator@gmail.com + * This software may be modified and distributed under the terms of the Creative Commons Attribution-ShareAlike 4.0 International License. + * + * See the LICENSE file for details. + */ + +/** global: Modernizr */ + +$(document).ready(function () { + "use strict"; + if (!Modernizr.inputtypes.date) { + $('input[type="date"]').datepicker( + { + dateFormat: 'yy-mm-dd' + } + ); + } +}); diff --git a/public/js/ff/piggy-banks/edit.js b/public/js/ff/piggy-banks/edit.js new file mode 100644 index 0000000000..675a5fe730 --- /dev/null +++ b/public/js/ff/piggy-banks/edit.js @@ -0,0 +1,20 @@ +/* + * create.js + * Copyright (c) 2017 thegrumpydictator@gmail.com + * This software may be modified and distributed under the terms of the Creative Commons Attribution-ShareAlike 4.0 International License. + * + * See the LICENSE file for details. + */ + +/** global: Modernizr */ + +$(document).ready(function () { + "use strict"; + if (!Modernizr.inputtypes.date) { + $('input[type="date"]').datepicker( + { + dateFormat: 'yy-mm-dd' + } + ); + } +}); diff --git a/public/js/ff/preferences/index.js b/public/js/ff/preferences/index.js new file mode 100644 index 0000000000..675a5fe730 --- /dev/null +++ b/public/js/ff/preferences/index.js @@ -0,0 +1,20 @@ +/* + * create.js + * Copyright (c) 2017 thegrumpydictator@gmail.com + * This software may be modified and distributed under the terms of the Creative Commons Attribution-ShareAlike 4.0 International License. + * + * See the LICENSE file for details. + */ + +/** global: Modernizr */ + +$(document).ready(function () { + "use strict"; + if (!Modernizr.inputtypes.date) { + $('input[type="date"]').datepicker( + { + dateFormat: 'yy-mm-dd' + } + ); + } +}); diff --git a/public/js/ff/rules/select-transactions.js b/public/js/ff/rules/select-transactions.js new file mode 100644 index 0000000000..675a5fe730 --- /dev/null +++ b/public/js/ff/rules/select-transactions.js @@ -0,0 +1,20 @@ +/* + * create.js + * Copyright (c) 2017 thegrumpydictator@gmail.com + * This software may be modified and distributed under the terms of the Creative Commons Attribution-ShareAlike 4.0 International License. + * + * See the LICENSE file for details. + */ + +/** global: Modernizr */ + +$(document).ready(function () { + "use strict"; + if (!Modernizr.inputtypes.date) { + $('input[type="date"]').datepicker( + { + dateFormat: 'yy-mm-dd' + } + ); + } +}); diff --git a/public/js/ff/tags/create-edit.js b/public/js/ff/tags/create-edit.js index 397f49ccef..7184b17ae2 100644 --- a/public/js/ff/tags/create-edit.js +++ b/public/js/ff/tags/create-edit.js @@ -5,12 +5,19 @@ * * See the LICENSE file for details. */ -/** global: zoomLevel, latitude, longitude, google, apiKey, doPlaceMarker */ +/** global: zoomLevel, latitude, longitude, google, apiKey, doPlaceMarker, Modernizr */ $(function () { "use strict"; $('#clearLocation').click(clearLocation); + if (!Modernizr.inputtypes.date) { + $('input[type="date"]').datepicker( + { + dateFormat: 'yy-mm-dd' + } + ); + } }); diff --git a/public/js/ff/transactions/split/edit.js b/public/js/ff/transactions/split/edit.js index 159be4f745..19fffbdf4b 100644 --- a/public/js/ff/transactions/split/edit.js +++ b/public/js/ff/transactions/split/edit.js @@ -7,7 +7,7 @@ */ -/** global: originalSum, accounting, what */ +/** global: originalSum, accounting, what, Modernizr */ var destAccounts = {}; var srcAccounts = {}; @@ -57,6 +57,14 @@ $(document).ready(function () { $('input[name$="][amount]"]').on('input', calculateSum); + + if (!Modernizr.inputtypes.date) { + $('input[type="date"]').datepicker( + { + dateFormat: 'yy-mm-dd' + } + ); + } }); diff --git a/resources/views/accounts/create.twig b/resources/views/accounts/create.twig index e1ccc79fd7..0c6d28238c 100644 --- a/resources/views/accounts/create.twig +++ b/resources/views/accounts/create.twig @@ -67,3 +67,13 @@ {% endblock %} +{% block scripts %} + + + +{% endblock %} + +{% block styles %} + + +{% endblock %} \ No newline at end of file diff --git a/resources/views/accounts/edit.twig b/resources/views/accounts/edit.twig index d849fa50d4..53784429a1 100644 --- a/resources/views/accounts/edit.twig +++ b/resources/views/accounts/edit.twig @@ -77,3 +77,13 @@ {{ Form.close|raw }} {% endblock %} +{% block scripts %} + + + +{% endblock %} + +{% block styles %} + + +{% endblock %} \ No newline at end of file diff --git a/resources/views/bills/create.twig b/resources/views/bills/create.twig index 69ccaa19fb..071771ab32 100644 --- a/resources/views/bills/create.twig +++ b/resources/views/bills/create.twig @@ -61,7 +61,12 @@ {% block styles %} + + {% endblock %} {% block scripts %} + + + {% endblock %} diff --git a/resources/views/bills/edit.twig b/resources/views/bills/edit.twig index 53c1d7a717..dcda9c47e0 100644 --- a/resources/views/bills/edit.twig +++ b/resources/views/bills/edit.twig @@ -60,7 +60,12 @@ {% endblock %} {% block styles %} + + {% endblock %} {% block scripts %} + + + {% endblock %} diff --git a/resources/views/export/index.twig b/resources/views/export/index.twig index f5fcd3dadf..afe83f4c9c 100644 --- a/resources/views/export/index.twig +++ b/resources/views/export/index.twig @@ -100,5 +100,11 @@ + + {% endblock %} +{% block styles %} + + +{% endblock %} \ No newline at end of file diff --git a/resources/views/piggy-banks/create.twig b/resources/views/piggy-banks/create.twig index 4d462164bc..e144dc9838 100644 --- a/resources/views/piggy-banks/create.twig +++ b/resources/views/piggy-banks/create.twig @@ -54,3 +54,13 @@ {% endblock %} +{% block scripts %} + + + +{% endblock %} + +{% block styles %} + + +{% endblock %} \ No newline at end of file diff --git a/resources/views/piggy-banks/edit.twig b/resources/views/piggy-banks/edit.twig index 35f8f26cc5..df25b8aebc 100644 --- a/resources/views/piggy-banks/edit.twig +++ b/resources/views/piggy-banks/edit.twig @@ -56,3 +56,13 @@ {{ Form.close|raw }} {% endblock %} +{% block scripts %} + + + +{% endblock %} + +{% block styles %} + + +{% endblock %} \ No newline at end of file diff --git a/resources/views/preferences/index.twig b/resources/views/preferences/index.twig index bf15783830..5432d9887f 100644 --- a/resources/views/preferences/index.twig +++ b/resources/views/preferences/index.twig @@ -272,3 +272,13 @@ {% endblock %} +{% block scripts %} + + + +{% endblock %} + +{% block styles %} + + +{% endblock %} \ No newline at end of file diff --git a/resources/views/rules/rule-group/select-transactions.twig b/resources/views/rules/rule-group/select-transactions.twig index 6fc61bf15e..e33b186cd9 100644 --- a/resources/views/rules/rule-group/select-transactions.twig +++ b/resources/views/rules/rule-group/select-transactions.twig @@ -40,3 +40,13 @@ {% endblock %} +{% block scripts %} + + + +{% endblock %} + +{% block styles %} + + +{% endblock %} \ No newline at end of file diff --git a/resources/views/tags/create.twig b/resources/views/tags/create.twig index 1864f85843..8d85dcc86a 100644 --- a/resources/views/tags/create.twig +++ b/resources/views/tags/create.twig @@ -84,5 +84,11 @@ + + {% endblock %} +{% block styles %} + + +{% endblock %} \ No newline at end of file diff --git a/resources/views/tags/edit.twig b/resources/views/tags/edit.twig index 99366b5546..4012de4137 100644 --- a/resources/views/tags/edit.twig +++ b/resources/views/tags/edit.twig @@ -87,5 +87,11 @@ + + {% endblock %} +{% block styles %} + + +{% endblock %} \ No newline at end of file diff --git a/resources/views/transactions/split/edit.twig b/resources/views/transactions/split/edit.twig index d811f4798e..e78dffb4ab 100644 --- a/resources/views/transactions/split/edit.twig +++ b/resources/views/transactions/split/edit.twig @@ -299,6 +299,8 @@ {% endblock %} {% block styles %} + + {% endblock %} {% block scripts %} + + {% endblock %}