<el-form-item
v-for="(domain, index) in dynamicValidateForm.domains"
:label="'域名' + index"
:key="domain.key"
:prop="'domains.' + index + '.value'"
:rules="{
required: true, message: '域名不能為空', trigger: 'blur'
}"
>
<el-input v-model="domain.value"></el-input><el-button @click.prevent="removeDomain(domain)">刪除</el-button>
</el-form-item>疑惑的地方::prop="'domains.' + index + '.value'"為什么prop中是'domains.+index+.value'而不是'dynamicValidateForm.domains+index+.value'或者'domain.value'?示例,請分別運行三段注釋
- 1 回答
- 0 關注
- 5070 瀏覽
添加回答
舉報
0/150
提交
取消