diff options
author | tsmgeek <tsmgeek@gmail.com> | 2017-08-22 00:21:29 +0100 |
---|---|---|
committer | tsmgeek <tsmgeek@gmail.com> | 2017-08-22 00:21:29 +0100 |
commit | fdf35488b5b3cd5725c6c2e179b65377d30c6577 (patch) | |
tree | da0b3927f3049475cd67977fe093d198920c1c37 /web/app/view/dialog/CalendarController.js | |
parent | f8b98b236fd676fe8945d942842640ddea5bbac8 (diff) | |
parent | e0bb9b92d07176677b3043530660af3bc30774d7 (diff) | |
download | trackermap-web-fdf35488b5b3cd5725c6c2e179b65377d30c6577.tar.gz trackermap-web-fdf35488b5b3cd5725c6c2e179b65377d30c6577.tar.bz2 trackermap-web-fdf35488b5b3cd5725c6c2e179b65377d30c6577.zip |
Merge from upstream, change .eslintrc.json
Diffstat (limited to 'web/app/view/dialog/CalendarController.js')
-rw-r--r-- | web/app/view/dialog/CalendarController.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/web/app/view/dialog/CalendarController.js b/web/app/view/dialog/CalendarController.js index 14d8294a..fb8cbff6 100644 --- a/web/app/view/dialog/CalendarController.js +++ b/web/app/view/dialog/CalendarController.js @@ -26,12 +26,12 @@ Ext.define('Traccar.view.dialog.CalendarController', { reader = new FileReader(); reader.onload = function (event) { fileField.up('window').lookupReference('dataField').setValue( - btoa(String.fromCharCode.apply(null, new Uint8Array(event.target.result)))); + event.target.result.substr(event.target.result.indexOf(',') + 1)); }; reader.onerror = function (event) { Traccar.app.showError(event.target.error); }; - reader.readAsArrayBuffer(fileField.fileInputEl.dom.files[0]); + reader.readAsDataURL(fileField.fileInputEl.dom.files[0]); } } }); |