no message

Former-commit-id: bb9aff464c44b367567d43a98ce195f66d991c10
Former-commit-id: 87780e39f273719bae4732044d19fbb06c785059
Former-commit-id: f8ddafc12f29421cbc433f0742c937502160cf56
This commit is contained in:
李杨
2018-03-23 11:00:48 +08:00
parent aca71e9251
commit c48a2fbb82

View File

@@ -6,6 +6,45 @@
发送请求
</el-button>
</template>
<el-table v-bind="table">
<el-table-column
prop="id"
label="id"
width="50"
align="center">
</el-table-column>
<el-table-column
prop="name"
label="姓名"
width="100">
<template slot-scope="scope">
<el-input
v-bind="inputSetting"
placeholder="姓名">
</el-input>
</template>
</el-table-column>
<el-table-column
prop="address1"
label="出生地">
<template slot-scope="scope">
<el-input
v-bind="inputSetting"
placeholder="出生地">
</el-input>
</template>
</el-table-column>
<el-table-column
prop="address2"
label="现居地">
<template slot-scope="scope">
<el-input
v-bind="inputSetting"
placeholder="现居地">
</el-input>
</template>
</el-table-column>
</el-table>
</Container>
</template>
@@ -15,28 +54,29 @@ export default {
data () {
return {
table: {
columns: [],
data: [],
size: 'mini',
stripe: true,
border: true
},
inputSetting: {
size: 'small',
style: {
maxWidth: '200px'
}
}
}
},
methods: {
ajax () {
const mockData = Mock.mock({
this.table.data = Mock.mock({
'list|4-10': [{
'id|+1': 1,
'name': '@CNAME',
'star|1-5': '',
'delFlag|1': [0, 1],
'creatDate': '@DATE',
'address': '@CITY',
'zip': '@ZIP'
'address1': '@CITY',
'address2': '@CITY'
}]
})
console.log(mockData)
}).list
}
}
}