diff options
author | Iván Ávalos <avalos@disroot.org> | 2021-09-24 21:41:24 -0500 |
---|---|---|
committer | Iván Ávalos <avalos@disroot.org> | 2021-09-24 21:41:24 -0500 |
commit | 8ea200832fa869f90d8c4242b13db4fa4d3a193d (patch) | |
tree | df07c0d74db2ba07f7967b8fe3a89d7a42553e45 /web | |
parent | b8bbb84ca42f45e28df583d9a229b9311e8662a2 (diff) | |
download | etbsa-traccar-web-8ea200832fa869f90d8c4242b13db4fa4d3a193d.tar.gz etbsa-traccar-web-8ea200832fa869f90d8c4242b13db4fa4d3a193d.tar.bz2 etbsa-traccar-web-8ea200832fa869f90d8c4242b13db4fa4d3a193d.zip |
If SVG is not found for device category, it defaults to 'default'
Diffstat (limited to 'web')
-rw-r--r-- | web/app/DeviceImages.js | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/web/app/DeviceImages.js b/web/app/DeviceImages.js index af45ce9..9b837e8 100644 --- a/web/app/DeviceImages.js +++ b/web/app/DeviceImages.js @@ -22,7 +22,8 @@ Ext.define('Traccar.DeviceImages', { getImageSvg: function (color, zoom, angle, category) { var i, info, svg, width, height, rotateTransform, scaleTransform, fill; - info = Ext.getStore('DeviceImages').findRecord('key', category || 'default', 0, false, false, true); + info = Ext.getStore('DeviceImages').findRecord('key', category || 'default', 0, false, false, true) || + Ext.getStore('DeviceImages').findRecord('key', 'default', false, false, true); svg = Ext.clone(info.get('svg')); if (!svg) { svg = this.cloneDocument(info.get('svg')); |