Web UI keeps loading after branding changes

Carlos Mukoyi3 years ago

I have downloaded source code onto windows machine and edited the logo at login using IntelliJ
after building the code it runs successfully on my localhost with new logo.

When i copy the web folder to linux server with traccar instance.
The web app UI just keeps loading.

My log shows the server has started

2021-06-01 19:29:53  WARN: Port 5080 is disabled due to conflict
2021-06-01 19:29:53  INFO: jetty-9.4.36.v20210114; built: 2021-01-14T16:44:28.689Z; git: 238ec6997c7806b055319a6d11f8ae7564adc0de; jvm 11.0.8+10-LTS
2021-06-01 19:29:53  INFO: Started o.t.w.@750e2d33{/,null,AVAILABLE}
2021-06-01 19:29:53  INFO: DefaultSessionIdManager workerName=node0
2021-06-01 19:29:53  INFO: No SessionScavenger set, using defaults
2021-06-01 19:29:53  INFO: node0 Scavenging every 600000ms
2021-06-01 19:29:54  INFO: Started o.e.j.s.ServletContextHandler@5e9f1a4c{/,null,AVAILABLE}
2021-06-01 19:29:54  INFO: Started ServerConnector@7f9e8421{HTTP/1.1, (http/1.1)}{0.0.0.0:8082}
2021-06-01 19:29:54  INFO: Started @8671ms
2021-06-01 19:29:54  INFO: Health check enabled with period 480000
Anton Tananaev3 years ago

You should check browser console for errors.

Carlos Mukoyi3 years ago

I have but somehow i cant attach an image here wanted to show you

app.min.js:303 Uncaught TypeError: Cannot read property 'register' of undefined
    at Function.<anonymous> (app.min.js:303)
    at Ext.Inventory.processCreate (ext-all.js:22)
    at Ext.Inventory.processCreate (ext-all.js:22)
    at Function.<anonymous> (ext-all.js:22)
    at Function.onBeforeCreated (ext-all.js:22)
    at Function.doProcess (ext-all.js:22)
    at Function.process (ext-all.js:22)
    at new d (ext-all.js:22)
    at Ext.Inventory.create (ext-all.js:22)
    at Object.define (ext-all.js:22)
Carlos Mukoyi3 years ago
 function() {
    var projection;
    proj4.defs('BD-MC', '+proj\x3dmerc +lon_0\x3d0 +units\x3dm +ellps\x3dclrk66 +no_defs');
    proj4.defs('EPSG:3395', '+proj\x3dmerc +lon_0\x3d0 +k\x3d1 +x_0\x3d0 +y_0\x3d0 +datum\x3dWGS84 +units\x3dm +no_defs');
    *ol.proj.proj4.register(proj4);*
    (projection = ol.proj.get('EPSG:3395')) && projection.setExtent([-2.0037508342789244E7, -2.0037508342789244E7, 2.0037508342789244E7, 2.0037508342789244E7])
});
Ext.define('Traccar.DeviceImages', {
    singleton: !0,
    getImageSvg: function(color, zoom, angle, category) {
        var i, svg;
Anton Tananaev3 years ago

Seems like API is not working. Try opening http(s)://your-server/api/server and see what you get.

Carlos Mukoyi3 years ago
Uncaught TypeError: Cannot read property 'register' of undefined
Carlos Mukoyi3 years ago

I get from http(s)://your-server/api/server

{"id":1,"attributes":{},"registration":true,"readonly":false,"deviceReadonly":false,"map":null,"bingKey":null,"mapUrl":null,"latitude":0.0,"longitude":0.0,"zoom":0,"twelveHourFormat":false,"forceSettings":false,"coordinateFormat":null,"limitCommands":false,"poiLayer":null,"announcement":null,"version":"4.12"}
Anton Tananaev3 years ago

In that case I'm not sure. I guess you would have to debug to code to see where it breaks.

Carlos Mukoyi3 years ago
load.js:16 GET http://myIP:8082/app.min.js net::ERR_ABORTED 404 (Not Found)
Carlos Mukoyi3 years ago

is there a way for me to create the file app.min.js and place it on Linux server from my windows dev source code?

Anton Tananaev3 years ago

Have you read the documentation?

https://www.traccar.org/build-extjs/

Carlos Mukoyi3 years ago

I found and resolved my issue.
Created the app.min.js and placed it on the server.
Now works