Skip to content

Commit 48b0076

Browse files
authored
Merge pull request #45 from zhangchunlin/master
apijson-table: fix value overwrite problem
2 parents 8844488 + c8689e5 commit 48b0076

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

uliweb_apijson/apijson/templates/vue/inc_apijson_table.html

+4-1
Original file line numberDiff line numberDiff line change
@@ -424,8 +424,11 @@
424424
add: function(){
425425
for (var k in this.add_items){
426426
var d = this.add_items[k]
427-
d.value = null
428427
d.component = d.component || "input"
428+
if (!(d.hasOwnProperty('value'))) {
429+
dvalues = {input:'',checkbox:false}
430+
d.value = dvalues[d.component]
431+
}
429432
}
430433
if (this.hook_add!=null) {
431434
this.hook_add(this)

0 commit comments

Comments
 (0)