thymeleaf múltiplo selecionado na edição

Estou mudando totalmente esta questão, pois parte dela foi respondidaaqui com grande ajuda de Avnish! Tom me enviou na direção certa, então obrigado Tom!

Meu problema é que não sei como solicitar ao Thymeleaf para pré-selecionar elementos do objeto ao editá-lo.

Deixe-me te mostrar:

Esta solução funciona:

<select class="form-control" id="parts" name="parts" multiple="multiple">
    <option th:each="part : ${partsAtribute}"
            th:selected="${servisAttribute.parts.contains(part)}"
            th:value="${part.id}"
            th:text="${part.name}">Part name</option>
</select>

Eu tentei isso:

<select class="form-control" th:field="*{parts}" multiple="multiple">
    <option th:each="part : ${partsAtribute}"
            th:field="*{parts}"
            th:value="${part.id}"
            th:text="${part.name}">Part name</option>
</select>

não funcionou. Eu também tentei isso:

<select class="form-control" th:field="*{{parts}}" multiple="multiple">
    <option th:each="part : ${partsAtribute}"
            th:field="*{parts}"
            th:value="${part.id}"
            th:text="${part.name}">Part name</option>
</select>

também não funcionou. Eu tentei removerth:field="*{parts}" da tag de opção, mesmo resultado ..

Se eu mudarth:value para${part} funciona, mas não envia uma sequência de ids como [2,4,5,6, ...], masPart instâncias como [Part @ 43b45j, Part @ we43y7, ...] ...

ATUALIZAR: Acabei de perceber que isso funciona se apenas uma parte for selecionada:

<select class="form-control" th:field="*{parts}" multiple="multiple">
    <option th:each="part : ${partsAtribute}"
            th:field="*{parts}"
            th:value="${part.id}"
            th:text="${part.name}">Part name</option>
</select>

Se várias partes forem selecionadas, ele não funcionará ...

questionAnswers(6)

yourAnswerToTheQuestion