# Homepage & Status Panel Examples

**URL:** <https://forum.inductiveautomation.com/t/homepage-status-panel-examples/3993>\
**Category:** Module Development\
**Created:** [February 13, 2012, 9:14pm UTC](https://forum.inductiveautomation.com/t/homepage-status-panel-examples/3993 "2012-02-13T21:14:13Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![bryan\_cook](https://avatars.discourse-cdn.com/v4/letter/b/a8b319/32.png) [@bryan\_cook](https://forum.inductiveautomation.com/u/bryan_cook)\
**Post date:** [February 13, 2012, 9:14pm UTC](https://forum.inductiveautomation.com/t/homepage-status-panel-examples/3993/1 "2012-02-13T21:14:13Z")

</div>

I'd like to create a homepage and status panel for my module and could use guidance. I noticed that the Programmer's Guide mentions example projects ...

> [@](#):
>
> What is Wicket?  
> Wicket is a Java web development framework, and is the framework that the Ignition gateway is built on. It provides a way to model web components as Java objects, and separate programming concerns from display concerns. In many cases, Ignition takes care of building wicket components for you, but occasionally it is necessary or desirable to make your own. In these cases, it is most common to create Panels, which are fragments of pages. The example projects show how to create several different panels.
> 
> For more information about Wicket, see the project home page at [wicket.apache.org/](http://wicket.apache.org/)

... but I can't seem to locate any examples in the SDK example projects. Looking through Wicket's page, I'm a bit overwhelmed as to where to begin, what specifically to be looking for, etc. Could someone direct me to a good example, be it in the SDK example projects or elsewhere?

Thanks!

---

<div class="post-metadata">

**Author:** ![bryan\_cook](https://avatars.discourse-cdn.com/v4/letter/b/a8b319/32.png) [@bryan\_cook](https://forum.inductiveautomation.com/u/bryan_cook)\
**Post date:** [February 14, 2012, 3:53am UTC](https://forum.inductiveautomation.com/t/homepage-status-panel-examples/3993/2 "2012-02-14T03:53:10Z")

</div>

Welp, I took a stab at it .. didn't have any success though ..

I created ModuleWebPanel which extends Panel ...

```auto
import org.apache.wicket.markup.html.basic.Label;
import org.apache.wicket.markup.html.panel.Panel;

public class ModuleWebPanel extends Panel {

	private static final long serialVersionUID = 1L;

	public ModuleWebPanel(String id) {
		super(id);
		add(new Label("message", "Hello World!"));
	}
}
```

I created ModuleWebPanel.html ...

```auto
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.sourceforge.net/">
	<body>
		<wicket:panel>
			<div class='homepage-item'>
				<span wicket:id="message">Messages goes here</span>
			</div>
		</wicket:panel>
	</body>
</html>
```

I created ModuleHomepagePanelDescriptor which extends AbstractHomepagePanelDescriptor ...

```auto
import org.apache.wicket.markup.html.panel.Panel;
import com.inductiveautomation.ignition.gateway.model.AbstractHomepagePanelDescriptor;

public class ModuleHomepagePanelDescriptor extends AbstractHomepagePanelDescriptor {

	public ModuleHomepagePanelDescriptor() {
		super(ModuleWebPanel.class.getSimpleName(), 
		      ModuleWebPanel.class.getSimpleName(), 
		      1);
	}
	
	public Panel newPanel(String id) {
		return new ModuleWebPanel(id);
	}
}
```

I've got the following in my class that extends AbstractGatewayModuleHook ...

```auto
@Override
public List<? extends IHomepagePanelDescriptor> getHomepagePanels()
    {
	    return Arrays.asList(new ModuleHomepagePanelDescriptor());
    }
```

When I build and deploy, I get the following error logged ...

> [@](#):
>
> Markup of type 'html' for component 'com.blah.blah.blah.ignition.web.ModuleWebPanel' not found. Enable debug messages for org.apache.wicket.util.resource to get a list of all filenames tried.: [MarkupContainer [Component id = contents]]  
> org.apache.wicket.markup.MarkupNotFoundException: Markup of type 'html' for component 'com.blah.blah.blah.ignition.web.ModuleWebPanel' not found. Enable debug messages for org.apache.wicket.util.resource to get a list of all filenames tried.: [MarkupContainer [Component id = contents]]  
> at org.apache.wicket.markup.MarkupCache.getMarkupStream(MarkupCache.java:227)  
> at org.apache.wicket.MarkupContainer.getAssociatedMarkupStream(MarkupContainer.java:351)  
> at org.apache.wicket.MarkupContainer.renderAssociatedMarkup(MarkupContainer.java:632)  
> at org.apache.wicket.markup.html.panel.Panel.onComponentTagBody(Panel.java:114)  
> at org.apache.wicket.Component.renderComponent(Component.java:2619)  
> at org.apache.wicket.MarkupContainer.onRender(MarkupContainer.java:1512)  
> at org.apache.wicket.Component.render(Component.java:2450)  
> at org.apache.wicket.MarkupContainer.renderNext(MarkupContainer.java:1414)  
> at org.apache.wicket.MarkupContainer.renderComponentTagBody(MarkupContainer.java:1577)  
> [snip]

I've confirmed that the ModuleWebPanel.html resides next to ModuleWebPanel.class within the .jar within the .modl.

.. that's about as far as my Google-fu can take me tonight 🙂

---

<div class="post-metadata">

**Author:** ![Carl.Gould](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/carl.gould/32/7262_2.png) [@Carl.Gould](https://forum.inductiveautomation.com/u/Carl.Gould)\
**Post date:** [February 14, 2012, 5:57pm UTC](https://forum.inductiveautomation.com/t/homepage-status-panel-examples/3993/3 "2012-02-14T17:57:49Z")

</div>

Well, first of all, nice job - you got it all 100% right. (Wicket has a bit of a learning curve, it’s true)

I copied and pasted your code into mine and guess what - everything worked great! Triple check for type-o’s in the names of your \*.java and \*.html files. Not sure how far along you are on other stuff, but you could zip up your whole eclipse project folder and send it to us if you’d like.

---

<div class="post-metadata">

**Author:** ![bryan\_cook](https://avatars.discourse-cdn.com/v4/letter/b/a8b319/32.png) [@bryan\_cook](https://forum.inductiveautomation.com/u/bryan_cook)\
**Post date:** [February 14, 2012, 6:27pm UTC](https://forum.inductiveautomation.com/t/homepage-status-panel-examples/3993/4 "2012-02-14T18:27:02Z")

</div>

> [@Carl.Gould](#):
>
> Well, first of all, nice job - you got it all 100% right. (Wicket has a bit of a learning curve, it's true).

Definitely, I barely understand some of the code I wrote above 🙂

I've sent an email titled "RE: Module Developers Forum Post #7630" to the support email with my project attached .. chopped out some stuff so the attachment wasn't monstrous, (I've detailed what within the email). We haven't done much at all with the project so it shouldn't be hard to find where everything is.

Appreciate the help, thanks!

---

<div class="post-metadata">

**Author:** ![bryan\_cook](https://avatars.discourse-cdn.com/v4/letter/b/a8b319/32.png) [@bryan\_cook](https://forum.inductiveautomation.com/u/bryan_cook)\
**Post date:** [February 21, 2012, 3:42pm UTC](https://forum.inductiveautomation.com/t/homepage-status-panel-examples/3993/5 "2012-02-21T15:42:39Z")

</div>

Success! Looks like it was developer error, had my line within getHomepagePanels() commented out!

So, my next question … what’s with the text? 🙂 I’ve actually noticed this on the Configure page when I had the OEE module installed, (the heading within the left pane). I’m using Google Chrome to access these pages.

---

<div class="post-metadata">

**Author:** ![Colby.Clegg](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/colby.clegg/32/3282_2.png) [@Colby.Clegg](https://forum.inductiveautomation.com/u/Colby.Clegg)\
**Post date:** [February 21, 2012, 6:40pm UTC](https://forum.inductiveautomation.com/t/homepage-status-panel-examples/3993/6 "2012-02-21T18:40:57Z")

</div>

That’s what happens when the system is looking for a localization bundle key that doesn’t exist.

The constructor of AbstractHomepagePanelDescriptor expects you to give it a bundle key for the title. You’re passing it “ModuleWebPanel.class.getSimpleName()” for both the panel id and the title. When it can’t find the key, it returns the passed in value with question marks around it (which doesn’t always render very attractively).

The solution is to set up a localization bundle for your project. Check out “Localization” under Getting Started\>Key Concepts in the programmer’s guide, and let me know if you still have questions after that.

Regards,

---

<div class="post-metadata">

**Author:** ![bloeper](https://avatars.discourse-cdn.com/v4/letter/b/ac91a4/32.png) [@bloeper](https://forum.inductiveautomation.com/u/bloeper)\
**Post date:** [February 22, 2012, 3:26am UTC](https://forum.inductiveautomation.com/t/homepage-status-panel-examples/3993/7 "2012-02-22T03:26:22Z")

</div>

The Programmer’s Guide says “To aid with the translation process, Inductive Automation is developing a translation toolkit and localization portal that will be available to module developers by the 3rd quarter of 2011.” Is this available? I looked around on the Inductive site, but couldn’t find anything more on it.

---

<div class="post-metadata">

**Author:** ![Colby.Clegg](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/colby.clegg/32/3282_2.png) [@Colby.Clegg](https://forum.inductiveautomation.com/u/Colby.Clegg)\
**Post date:** [February 22, 2012, 4:46pm UTC](https://forum.inductiveautomation.com/t/homepage-status-panel-examples/3993/8 "2012-02-22T16:46:35Z")

</div>

Did we say that? When will I learn not to put timeframes on things… 😆

So, it’s halfway there. The “toolkit” consists of: python scripts to manage property files, a web interface/web service for loading them to the tool, and then the translation tool itself. Of these, the scripts and the tool do exist, but only for Ignition itself right now. We’ll have to do some work before they’re available to module authors, though I would like to get to this soon.

In the mean time, I’ve added you to the Localization group, so you can see what the tool looks like (you should now be able to see the localization forum, which has info on how to get to it).

Regards,

---

<div class="post-metadata">

**Author:** ![bloeper](https://avatars.discourse-cdn.com/v4/letter/b/ac91a4/32.png) [@bloeper](https://forum.inductiveautomation.com/u/bloeper)\
**Post date:** [February 22, 2012, 5:08pm UTC](https://forum.inductiveautomation.com/t/homepage-status-panel-examples/3993/9 "2012-02-22T17:08:35Z")

</div>

I’m glad I’m not the only one who gets caught up with timeframes 🙂 I’ll take a look around the Localization stuff and am sure I’ll have more questions. Thanks!

---

<div class="post-metadata">

**Author:** ![jose](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/jose/32/11908_2.png) [@jose](https://forum.inductiveautomation.com/u/jose)\
**Post date:** [November 20, 2019, 2:24pm UTC](https://forum.inductiveautomation.com/t/homepage-status-panel-examples/3993/10 "2019-11-20T14:24:11Z")

</div>

So how would I access / view this page? It doesn’t seem to show up at anywhere automatically do I have to somehow add a menu?  
Sorry for the old bump
