Mercurial > public > ssdtforms
view src/main/java/org/ssdt_ohio/devel/forms/components/Layout.java @ 0:f4f8570d1c56
initial OTP form
author | smith@nwoca.org |
---|---|
date | Mon, 12 Nov 2012 16:29:11 +0000 |
parents | |
children |
line wrap: on
line source
package org.ssdt_ohio.devel.forms.components; import com.trsvax.bootstrap.annotations.Exclude; import org.apache.tapestry5.*; import org.apache.tapestry5.annotations.*; import org.apache.tapestry5.ioc.annotations.*; import org.apache.tapestry5.BindingConstants; import org.apache.tapestry5.SymbolConstants; @Exclude(stylesheet = {"core"}) @Import(stylesheet = {"classpath:/com/trsvax/bootstrap/assets/bootstrap/css/bootstrap.css", "classpath:/com/trsvax/bootstrap/assets/bootstrap/css/bootstrap-responsive.css", "context:layout/layout.css"}, library = {"classpath:/com/trsvax/bootstrap/assets/bootstrap/js/bootstrap.js"}) public class Layout { /** * The page title, for the <title> element and the <h1> element. */ @Property @Parameter(required = true, defaultPrefix = BindingConstants.LITERAL) private String title; @Property private String pageName; @Inject private ComponentResources resources; @Property @Inject @Symbol(SymbolConstants.APPLICATION_VERSION) private String appVersion; public String getClassForPageName() { return resources.getPageName().equalsIgnoreCase(pageName) ? "current_page_item" : null; } public String[] getPageNames() { return new String[]{"Index", "OneTwentyPayment"}; } }