fixed spaces in textarea
This commit is contained in:
parent
a38b817f20
commit
08dc4bcb47
|
@ -83,7 +83,7 @@ public class InternArticleController {
|
||||||
@RequestParam(value = "price_netto", required = true) String pricenetto,
|
@RequestParam(value = "price_netto", required = true) String pricenetto,
|
||||||
@RequestParam(value = "reorderMaxPrice", required = true) String reorderMaxPrice,
|
@RequestParam(value = "reorderMaxPrice", required = true) String reorderMaxPrice,
|
||||||
@RequestParam(value = "autobuy", required = true) Boolean shouldReorder,
|
@RequestParam(value = "autobuy", required = true) Boolean shouldReorder,
|
||||||
@RequestParam(value = "categories", required = true) String categories,
|
@RequestParam(value = "categorie", required = true) String categories,
|
||||||
@RequestParam(value = "img", required = true) MultipartFile imgFile) {
|
@RequestParam(value = "img", required = true) MultipartFile imgFile) {
|
||||||
|
|
||||||
Article tmpArticle = articleRepository.findArticleById(id); // get the old article
|
Article tmpArticle = articleRepository.findArticleById(id); // get the old article
|
||||||
|
@ -93,7 +93,7 @@ public class InternArticleController {
|
||||||
tmpArticle.categories.clear();
|
tmpArticle.categories.clear();
|
||||||
|
|
||||||
// loop through all categories strings and create a new category if a new one;
|
// loop through all categories strings and create a new category if a new one;
|
||||||
// also adds the categorys to the article
|
// also adds the categories to the article
|
||||||
for (String category : separatedCategories) {
|
for (String category : separatedCategories) {
|
||||||
tmpArticle.categories.add(categoryRepository.findCategoryByName(category.trim())
|
tmpArticle.categories.add(categoryRepository.findCategoryByName(category.trim())
|
||||||
.orElseGet(() -> new Category(category.trim())));
|
.orElseGet(() -> new Category(category.trim())));
|
||||||
|
|
|
@ -70,9 +70,9 @@
|
||||||
<p>
|
<p>
|
||||||
Bitte jede Kategorien in eine eigene Zeile
|
Bitte jede Kategorien in eine eigene Zeile
|
||||||
</p>
|
</p>
|
||||||
<textarea name="categories" id="categories" class="full-width" rows="6"th:inline="text">[[${ArticleID.categorie}]]
|
<textarea name="categorie" id="categorie" class="full-width" required rows="6"th:inline="text" th:field="${ArticleID.categorie}">
|
||||||
|
|
||||||
</textarea>
|
</textarea>
|
||||||
</div>
|
</div>
|
||||||
<div class="s">
|
<div class="s">
|
||||||
<p>
|
<p>
|
||||||
|
@ -93,7 +93,7 @@
|
||||||
</div>
|
</div>
|
||||||
<p class="l">
|
<p class="l">
|
||||||
<label for="description">Beschreibung</label>
|
<label for="description">Beschreibung</label>
|
||||||
<textarea name="description" id="description" class="full-width" rows="15" th:inline="text">[[${ArticleID.description}]]
|
<textarea name="description" id="description" class="full-width" required th:field="${ArticleID.description}" rows="15" th:inline="text">
|
||||||
</textarea>
|
</textarea>
|
||||||
</p>
|
</p>
|
||||||
<div class="l">
|
<div class="l">
|
||||||
|
|
Reference in New Issue