aboutsummaryrefslogtreecommitdiff
path: root/src/main
diff options
context:
space:
mode:
Diffstat (limited to 'src/main')
-rw-r--r--src/main/java/org/traccar/web/client/Traccar.java6
-rw-r--r--src/main/java/org/traccar/web/client/view/ArchivePanel.java8
-rw-r--r--src/main/resources/META-INF/persistence_debug.xml (renamed from src/main/resources/META-INF/persistence.xml)6
-rw-r--r--src/main/resources/META-INF/persistence_release.xml12
-rw-r--r--src/main/webapp/WEB-INF/jetty-web.xml10
-rw-r--r--src/main/webapp/WEB-INF/web.xml2
6 files changed, 23 insertions, 21 deletions
diff --git a/src/main/java/org/traccar/web/client/Traccar.java b/src/main/java/org/traccar/web/client/Traccar.java
index 68f633cf..2bb84f4a 100644
--- a/src/main/java/org/traccar/web/client/Traccar.java
+++ b/src/main/java/org/traccar/web/client/Traccar.java
@@ -27,8 +27,8 @@ public class Traccar implements EntryPoint, LoginController.LoginHandler {
*/
@Override
public void onModuleLoad() {
- //new LoginController().login(this);
- onLogin(); // TODO: remove from production
+ new LoginController().login(this);
+ //onLogin(); // TODO: remove from production
/*try {
GlobalDatabaseService.getInstance().getPositions(
@@ -71,7 +71,7 @@ public class Traccar implements EntryPoint, LoginController.LoginHandler {
devicePanel.setWidth("20%");
devicePanel.setShowResizeBar(true);
- devicePanel.updateDevices(testDevices()); // TODO: remove from production
+ //devicePanel.updateDevices(testDevices()); // TODO: remove from production
mapPanel = new MapPanel();
mapPanel.setWidth("80%");
diff --git a/src/main/java/org/traccar/web/client/view/ArchivePanel.java b/src/main/java/org/traccar/web/client/view/ArchivePanel.java
index b2ce329d..3929be2e 100644
--- a/src/main/java/org/traccar/web/client/view/ArchivePanel.java
+++ b/src/main/java/org/traccar/web/client/view/ArchivePanel.java
@@ -1,12 +1,12 @@
package org.traccar.web.client.view;
-import com.smartgwt.client.widgets.toolbar.ToolStrip;
+import com.smartgwt.client.widgets.form.fields.DateTimeItem;
+import com.smartgwt.client.widgets.form.fields.SelectItem;
import com.smartgwt.client.widgets.grid.ListGrid;
import com.smartgwt.client.widgets.grid.ListGridField;
import com.smartgwt.client.widgets.layout.SectionStack;
import com.smartgwt.client.widgets.layout.SectionStackSection;
-import com.smartgwt.client.widgets.form.fields.SelectItem;
-import com.smartgwt.client.widgets.form.fields.DateTimeItem;
+import com.smartgwt.client.widgets.toolbar.ToolStrip;
import com.smartgwt.client.widgets.toolbar.ToolStripButton;
/**
@@ -18,7 +18,7 @@ public class ArchivePanel extends SectionStack {
private ListGrid list;
public ArchivePanel() {
- SectionStackSection section = new SectionStackSection("Archive");
+ SectionStackSection section = new SectionStackSection("Archive");
section.setCanCollapse(false);
section.setExpanded(true);
diff --git a/src/main/resources/META-INF/persistence.xml b/src/main/resources/META-INF/persistence_debug.xml
index e4573c9a..a070dfac 100644
--- a/src/main/resources/META-INF/persistence.xml
+++ b/src/main/resources/META-INF/persistence_debug.xml
@@ -3,14 +3,14 @@
xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_2_0.xsd"
version="2.0">
<persistence-unit name="traccar">
- <provider>org.hibernate.ejb.HibernatePersistence</provider>
+ <!--<jta-data-source>java:/DefaultDS</jta-data-source>-->
<properties>
- <property name="hibernate.show_sql" value="true"/>
<property name="hibernate.connection.driver_class" value="com.mysql.jdbc.Driver"/>
<property name="hibernate.connection.url" value="jdbc:mysql://localhost/test"/>
<property name="hibernate.connection.username" value="root"/>
<property name="hibernate.connection.password" value="root"/>
- <property name="hibernate.dialect" value="org.hibernate.dialect.MySQLDialect"/>
+ <property name="hibernate.show_sql" value="true"/>
+ <!--<property name="hibernate.dialect" value="org.hibernate.dialect.MySQLDialect"/>-->
<property name="hibernate.hbm2ddl.auto" value="validate"/>
</properties>
</persistence-unit>
diff --git a/src/main/resources/META-INF/persistence_release.xml b/src/main/resources/META-INF/persistence_release.xml
new file mode 100644
index 00000000..dc5ac2db
--- /dev/null
+++ b/src/main/resources/META-INF/persistence_release.xml
@@ -0,0 +1,12 @@
+<persistence xmlns="http://java.sun.com/xml/ns/persistence"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_2_0.xsd"
+ version="2.0">
+ <persistence-unit name="traccar">
+ <jta-data-source>java:/DefaultDS</jta-data-source>
+ <properties>
+ <property name="hibernate.show_sql" value="true"/>
+ <property name="hibernate.hbm2ddl.auto" value="validate"/>
+ </properties>
+ </persistence-unit>
+</persistence>
diff --git a/src/main/webapp/WEB-INF/jetty-web.xml b/src/main/webapp/WEB-INF/jetty-web.xml
deleted file mode 100644
index f959e1b3..00000000
--- a/src/main/webapp/WEB-INF/jetty-web.xml
+++ /dev/null
@@ -1,10 +0,0 @@
-<Configure class="org.mortbay.jetty.webapp.WebAppContext">
- <Get name="securityHandler">
- <Set name="userRealm">
- <New class="org.mortbay.jetty.security.HashUserRealm">
- <Set name="name">Test Realm</Set>
- <Set name="config"><SystemProperty name="jetty.home" default="."/>/src/test/realm.properties</Set>
- </New>
- </Set>
- </Get>
-</Configure>
diff --git a/src/main/webapp/WEB-INF/web.xml b/src/main/webapp/WEB-INF/web.xml
index a7412ce9..5c46f87c 100644
--- a/src/main/webapp/WEB-INF/web.xml
+++ b/src/main/webapp/WEB-INF/web.xml
@@ -25,7 +25,7 @@
<login-config>
<auth-method>BASIC</auth-method>
</login-config>-->
-
+
<servlet>
<servlet-name>databaseService</servlet-name>
<servlet-class>org.traccar.web.server.database.DatabaseServiceImpl</servlet-class>