Skip to content

Commit bbc9bf6

Browse files
committed
remarks
1 parent 93d0ad4 commit bbc9bf6

File tree

3 files changed

+10
-7
lines changed

3 files changed

+10
-7
lines changed

src/main/java/ru/mystamps/web/dao/impl/JdbcCountryDao.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,7 @@ public class JdbcCountryDao implements CountryDao {
8080
@Value("${country.find_last_created_by_user}")
8181
private String findLastCreatedByUserSql;
8282

83+
@SuppressWarnings("PMD.LongVariable")
8384
@Value("${country.find_popular_country_from_user_collection}")
8485
private String findPopularCountryInCollectionSql;
8586

src/main/resources/sql/country_dao_queries.properties

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -85,15 +85,17 @@ ORDER BY CASE WHEN 'ru' = :lang THEN COALESCE(c.name_ru, c.name) ELSE c.name END
8585
country.find_last_created_by_user = \
8686
SELECT c.slug \
8787
FROM series s \
88-
JOIN countries c ON c.id = s.country_id \
88+
JOIN countries c \
89+
ON c.id = s.country_id \
8990
WHERE s.created_by = :created_by \
90-
ORDER BY s.created_at DESC\
91-
LIMIT 1
91+
ORDER BY s.created_at DESC \
92+
LIMIT 1
9293

9394
country.find_popular_country_from_user_collection = \
9495
SELECT c.slug \
95-
FROM series s \
96-
JOIN countries c ON c.id = s.country_id \
96+
FROM collections c \
97+
JOIN collections_series cs ON c.id = cs.collection_id \
98+
WHERE c.user_id = :user_id \
9799
GROUP BY country_id \
98100
ORDER BY COUNT(*) DESC\
99101
LIMIT 1

src/main/webapp/WEB-INF/views/series/add.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -203,8 +203,8 @@ <h3 th:text="${#strings.capitalize(add_series)}">
203203
/*/-->
204204
</div>
205205

206-
<small togglz:active="INFO_COUNTRY_SERIES" id="js-guess-country-link" th:style="'display: none;'">
207-
<a tabindex="-1" th:text="#{t_guess_country}" href="javascript:void(0)">Guess a country</a>
206+
<small togglz:active="INFO_COUNTRY_SERIES">
207+
<a tabindex="-1" th:text="#{t_guess_country}" href="javascript:void(0)" id="js-guess-country-link" th:style="'display: none;'">Guess a country</a>
208208
</small>
209209
</div>
210210

0 commit comments

Comments
 (0)