diff --git a/src/main/java/org/springframework/cheapy/model/Client.java b/src/main/java/org/springframework/cheapy/model/Client.java index e9f56687d..6f4533166 100644 --- a/src/main/java/org/springframework/cheapy/model/Client.java +++ b/src/main/java/org/springframework/cheapy/model/Client.java @@ -145,13 +145,6 @@ public class Client extends BaseEntity { this.description = description; } - public Municipio getMunicipio() { - return municipio; - } - - public void setMunicipio(Municipio municipio) { - this.municipio = municipio; - } public Code getCode() { return cod; diff --git a/src/main/less/cheapy.less b/src/main/less/cheapy.less index a6a211767..6e05e3f98 100644 --- a/src/main/less/cheapy.less +++ b/src/main/less/cheapy.less @@ -642,3 +642,4 @@ hr { @import "typography.less"; @import "header.less"; @import "responsive.less"; +@import "starRating.less" diff --git a/src/main/less/starRating.less b/src/main/less/starRating.less new file mode 100644 index 000000000..0cf338fc6 --- /dev/null +++ b/src/main/less/starRating.less @@ -0,0 +1,40 @@ +.rating { + display: flex; + flex-direction: row-reverse; + justify-content: flex-end + } + + .rating>input { + display: none + } + + .rating>label { + position: relative; + width: 1em; + font-size: 200%; + color: #FFD600; + cursor: pointer + } + + .rating>label::before { + content: "\2605"; + position: absolute; + opacity: 0 + } + + .rating>label:hover:before, + .rating>label:hover~label:before { + opacity: 1 !important + } + + .rating>input:checked~label:before { + opacity: 1 + } + + .rating:hover>input:checked~label:before { + opacity: 0.4 + } + + + + \ No newline at end of file diff --git a/src/main/webapp/WEB-INF/jsp/reviews/createOrUpdateReviewForm.jsp b/src/main/webapp/WEB-INF/jsp/reviews/createOrUpdateReviewForm.jsp index 93f628af0..ac2b3af7a 100644 --- a/src/main/webapp/WEB-INF/jsp/reviews/createOrUpdateReviewForm.jsp +++ b/src/main/webapp/WEB-INF/jsp/reviews/createOrUpdateReviewForm.jsp @@ -14,7 +14,8 @@
- + +
diff --git a/src/main/webapp/WEB-INF/jsp/reviews/reviewsList.jsp b/src/main/webapp/WEB-INF/jsp/reviews/reviewsList.jsp index 394e6fbbe..da8323d41 100644 --- a/src/main/webapp/WEB-INF/jsp/reviews/reviewsList.jsp +++ b/src/main/webapp/WEB-INF/jsp/reviews/reviewsList.jsp @@ -4,6 +4,7 @@ <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %> <%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %> <%@ taglib prefix="cheapy" tagdir="/WEB-INF/tags" %> +<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %> @@ -26,6 +27,7 @@ + <%-- --%> @@ -34,7 +36,10 @@ - + + + + @@ -51,6 +56,7 @@ + diff --git a/src/main/webapp/WEB-INF/jsp/reviews/reviewsShow.jsp b/src/main/webapp/WEB-INF/jsp/reviews/reviewsShow.jsp index b13c31115..bfbf2c3d1 100644 --- a/src/main/webapp/WEB-INF/jsp/reviews/reviewsShow.jsp +++ b/src/main/webapp/WEB-INF/jsp/reviews/reviewsShow.jsp @@ -6,25 +6,28 @@ <%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %> <%@ taglib prefix="sec" uri="http://www.springframework.org/security/tags" %> +<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %>

+ - + + - +
- +
diff --git a/src/main/webapp/WEB-INF/tags/ratingStar.tag b/src/main/webapp/WEB-INF/tags/ratingStar.tag new file mode 100644 index 000000000..6d6bcb83d --- /dev/null +++ b/src/main/webapp/WEB-INF/tags/ratingStar.tag @@ -0,0 +1,37 @@ +<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %> +<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %> +<%@ taglib prefix="spring" uri="http://www.springframework.org/tags" %> +<%@ taglib uri = "http://java.sun.com/jsp/jstl/functions" prefix = "fn" %> +<%@ attribute name="name" required="true" rtexprvalue="true" + description="Name of corresponding property in bean object" %> +<%@ attribute name="disabled" required="false" rtexprvalue="true" + description="Disable the input" %> +<%@ attribute name="label" required="true" rtexprvalue="true" + description="Label appears in red color if input is considered as invalid after submission" %> +<%@ attribute name="placeholder" required="false" rtexprvalue="true" + description="Example for input field" %> + + + + +
+ + + +
+
+ + + + + + +
+ + + + ${status.errorMessage} + +
+
+
diff --git a/src/main/webapp/WEB-INF/tags/showStars.tag b/src/main/webapp/WEB-INF/tags/showStars.tag new file mode 100644 index 000000000..f68844d5c --- /dev/null +++ b/src/main/webapp/WEB-INF/tags/showStars.tag @@ -0,0 +1,18 @@ +<%@tag import="com.sun.org.apache.xalan.internal.xsltc.compiler.sym"%> +<%@ tag language="java" pageEncoding="ISO-8859-1"%> +<%@ attribute name="value" required="true" rtexprvalue="true" type="Integer" + description="Number of starts" %> +<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %> +<%@ taglib prefix="spring" uri="http://www.springframework.org/tags" %> +
+ + +
+ /> + /> + /> + /> + /> +
+ +