嗨,如何从下面的 html 中为这两个列表 event[] 和 qty[] 设置命令对象约束可为空、空白和自定义?
<div class="row-1">
<select name="event[]" class="form-control ">
<option selected="">abc</option>
<option selected="">def</option>
</select>
<input name="qty[]" >
</div>
<div class="row-2">
<select name="event[]" class="form-control ">
<option selected="">ghi</option>
<option selected="">jkl</option>
</select>
<input name="qty[]" >
</div>
class someCommand implements Validateable {
List eventComponent
List qty
static constraints = {
}
}