diff --git a/resource/web/main_index.tmpl b/resource/web/main_index.tmpl index 547b10f4..49db3256 100755 --- a/resource/web/main_index.tmpl +++ b/resource/web/main_index.tmpl @@ -108,7 +108,7 @@ {{/showSubNav}} {{#showSubNav}}
{{/showSubNav}} - {{^showSubNav}}
{{/showSubNav}} + {{^showSubNav}}
{{/showSubNav}} {{alerts}} {{content}}
diff --git a/resource/web/map.tmpl b/resource/web/map.tmpl new file mode 100755 index 00000000..1a100907 --- /dev/null +++ b/resource/web/map.tmpl @@ -0,0 +1,12 @@ + + + + + + + + + + + \ No newline at end of file diff --git a/src/se/hal/HalServer.java b/src/se/hal/HalServer.java index 6b835142..e568715b 100755 --- a/src/se/hal/HalServer.java +++ b/src/se/hal/HalServer.java @@ -76,6 +76,8 @@ public class HalServer { HalHttpPage.getRootNav().createSubNav("Events").setWeight(100); pages = new ArrayList<>(); pages.addAll(Arrays.asList(new HalHttpPage[]{ + new MapHttpPage(), + new SensorOverviewHttpPage(), new SensorConfigHttpPage(), diff --git a/src/se/hal/page/MapHttpPage.java b/src/se/hal/page/MapHttpPage.java new file mode 100755 index 00000000..244a00dd --- /dev/null +++ b/src/se/hal/page/MapHttpPage.java @@ -0,0 +1,26 @@ +package se.hal.page; + +import se.hal.intf.HalHttpPage; +import zutil.io.file.FileUtil; +import zutil.parser.Templator; + +import java.util.Map; + +/** + * Created by Ziver on 2016-06-23. + */ +public class MapHttpPage extends HalHttpPage { + private static final String TEMPLATE = "resource/web/map.tmpl"; + + + public MapHttpPage() { + super("map"); + super.getRootNav().createSubNav(this.getId(), "Map").setWeight(-100); + super.showSubNav(false); + } + + @Override + public Templator httpRespond(Map session, Map cookie, Map request) throws Exception { + return new Templator(FileUtil.find(TEMPLATE)); + } +}