Перепробовал все вариации пути, но картинка не отображается, в чем может быть проблема?
<div class="main-container">
<div class="icon">
<img th:src="@{/images/assignment.png}" th:alt="#{lang.assign}" alt="Соглашение"/>
</div>
<div class="title" th:text="#{lang.assign}">Соглашение</div>
<div class="description" th:utext="#{lang.agreement.text(${offerUrl})}"></div>
<form th:action="@{/agreement/assign}" method="post">
<input type="hidden" name="userId" th:value="${userId}"/>
<input type="hidden" name="offerId" th:value="${offerId}"/>
<button type="submit" class="btn-continue" th:text="#{lang.button.continue}">Подтвердить</button>
</for
UDP: Возможно блокирует security, но там все открыто:
@Configuration
@EnableWebSecurity
public class SecurityConfig extends WebSecurityConfigurerAdapter {
@Override
protected void configure(HttpSecurity http) throws Exception {
http
.cors().disable()
.csrf().disable();
}
@Override
public void configure(WebSecurity web) {
web
.ignoring()
.antMatchers("/**");
}
}
@Configuration
public class WebMvcConfig implements WebMvcConfigurer {
private static final String MESSAGES_BASENAME = "classpath:langs/lang";
private static final String DEFAULT_ENCODING = "UTF-8";
@Bean(name = "localeResolver")
public LocaleResolver getLocaleResolver() {
return new UrlLocaleResolver();
}
@Bean(name = "messageSource")
public MessageSource getMessageResource() {
ReloadableResourceBundleMessageSource messageResource = new ReloadableResourceBundleMessageSource();
messageResource.setBasename(MESSAGES_BASENAME);
messageResource.setDefaultEncoding(DEFAULT_ENCODING);
return messageResource;
}
@Override
public void addInterceptors(InterceptorRegistry registry) {
LocaleChangeInterceptor localeInterceptor = new LocaleChangeInterceptor();
localeInterceptor.setParamName("lang");
registry.addInterceptor(localeInterceptor)
.addPathPatterns("/*")
.excludePathPatterns("/images/**", "/css/**", "/js/**", "/webjars/**");
}
}