Added version display to layout page footer
This commit is contained in:
parent
6f7ae313ce
commit
200b27e03c
4
pom.xml
4
pom.xml
|
@ -7,7 +7,7 @@
|
||||||
|
|
||||||
<groupId>com.mousetech.gourmet</groupId>
|
<groupId>com.mousetech.gourmet</groupId>
|
||||||
<artifactId>gourmetj</artifactId>
|
<artifactId>gourmetj</artifactId>
|
||||||
<version>0.3.0</version>
|
<version>0.3.1</version>
|
||||||
<packaging>jar</packaging>
|
<packaging>jar</packaging>
|
||||||
|
|
||||||
<name>GourmetJ</name>
|
<name>GourmetJ</name>
|
||||||
|
@ -17,7 +17,7 @@
|
||||||
<parent>
|
<parent>
|
||||||
<groupId>org.springframework.boot</groupId>
|
<groupId>org.springframework.boot</groupId>
|
||||||
<artifactId>spring-boot-starter-parent</artifactId>
|
<artifactId>spring-boot-starter-parent</artifactId>
|
||||||
<version>3.2.2</version>
|
<version>3.2.3</version>
|
||||||
<relativePath /> <!-- lookup parent from repository -->
|
<relativePath /> <!-- lookup parent from repository -->
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
|
|
|
@ -3,6 +3,8 @@ package com.mousetech.gourmetj;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
|
import org.springframework.beans.factory.annotation.Value;
|
||||||
|
|
||||||
import jakarta.enterprise.context.ApplicationScoped;
|
import jakarta.enterprise.context.ApplicationScoped;
|
||||||
import jakarta.faces.model.SelectItem;
|
import jakarta.faces.model.SelectItem;
|
||||||
import jakarta.inject.Named;
|
import jakarta.inject.Named;
|
||||||
|
@ -47,5 +49,12 @@ public class AppBean {
|
||||||
new SelectItem(RecipeSearchType.rst_BY_INGREDIENT.ordinal(),
|
new SelectItem(RecipeSearchType.rst_BY_INGREDIENT.ordinal(),
|
||||||
"Ingredient"));
|
"Ingredient"));
|
||||||
return list;
|
return list;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Value("${appVersion}")
|
||||||
|
String appVersion = "Not Supplied.";
|
||||||
|
|
||||||
|
public String getAppVersion() {
|
||||||
|
return appVersion;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -18,7 +18,7 @@
|
||||||
</h:head>
|
</h:head>
|
||||||
<h:body>
|
<h:body>
|
||||||
<h1>
|
<h1>
|
||||||
<ui:insert name="title">Gourmet Recipe Manager (web version)</ui:insert>
|
<ui:insert name="title">Gourmet Recipe Manager (web version #{appBean.appVersion})</ui:insert>
|
||||||
</h1>
|
</h1>
|
||||||
<p:ajaxStatus onerror="PF('opError').show()"/>
|
<p:ajaxStatus onerror="PF('opError').show()"/>
|
||||||
<ui:insert name="content">
|
<ui:insert name="content">
|
||||||
|
@ -28,10 +28,11 @@
|
||||||
</ui:insert>
|
</ui:insert>
|
||||||
<!-- -->
|
<!-- -->
|
||||||
<div id="footer">
|
<div id="footer">
|
||||||
|
<h:outputText value="Version #{appBean.appVersion}"/><br/>
|
||||||
(C) 2021, 2024 Tim Holloway, Licensed under
|
(C) 2021, 2024 Tim Holloway, Licensed under
|
||||||
the Common Development and Distribution License (CDDL).
|
the Common Development and Distribution License (CDDL).
|
||||||
<p>Based on Gourmet Recipe Manager by T.
|
<p>Based on Gourmet Recipe Manager by T.
|
||||||
Hinkle</p>
|
Hinkle.</p>
|
||||||
</div>
|
</div>
|
||||||
<!-- -->
|
<!-- -->
|
||||||
</h:body>
|
</h:body>
|
||||||
|
|
|
@ -21,6 +21,9 @@ spring:
|
||||||
ddl-auto: none
|
ddl-auto: none
|
||||||
database-platform: org.hibernate.dialect.MySQLDialect
|
database-platform: org.hibernate.dialect.MySQLDialect
|
||||||
|
|
||||||
|
# From Maven POM:
|
||||||
|
appVersion: "@project.version@"
|
||||||
|
|
||||||
# Tracking-modes prevent URL rewrite jsessionid on Primecases
|
# Tracking-modes prevent URL rewrite jsessionid on Primecases
|
||||||
# resources. Which causes "400" errors on initial main.jsf fetch.
|
# resources. Which causes "400" errors on initial main.jsf fetch.
|
||||||
server:
|
server:
|
||||||
|
|
Loading…
Reference in New Issue
Block a user