no message
Former-commit-id: bb9aff464c44b367567d43a98ce195f66d991c10 Former-commit-id: 87780e39f273719bae4732044d19fbb06c785059 Former-commit-id: f8ddafc12f29421cbc433f0742c937502160cf56
This commit is contained in:
@@ -6,6 +6,45 @@
|
|||||||
发送请求
|
发送请求
|
||||||
</el-button>
|
</el-button>
|
||||||
</template>
|
</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>
|
</Container>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@@ -15,28 +54,29 @@ export default {
|
|||||||
data () {
|
data () {
|
||||||
return {
|
return {
|
||||||
table: {
|
table: {
|
||||||
columns: [],
|
|
||||||
data: [],
|
data: [],
|
||||||
size: 'mini',
|
size: 'mini',
|
||||||
stripe: true,
|
stripe: true,
|
||||||
border: true
|
border: true
|
||||||
|
},
|
||||||
|
inputSetting: {
|
||||||
|
size: 'small',
|
||||||
|
style: {
|
||||||
|
maxWidth: '200px'
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
ajax () {
|
ajax () {
|
||||||
const mockData = Mock.mock({
|
this.table.data = Mock.mock({
|
||||||
'list|4-10': [{
|
'list|4-10': [{
|
||||||
'id|+1': 1,
|
'id|+1': 1,
|
||||||
'name': '@CNAME',
|
'name': '@CNAME',
|
||||||
'star|1-5': '★',
|
'address1': '@CITY',
|
||||||
'delFlag|1': [0, 1],
|
'address2': '@CITY'
|
||||||
'creatDate': '@DATE',
|
|
||||||
'address': '@CITY',
|
|
||||||
'zip': '@ZIP'
|
|
||||||
}]
|
}]
|
||||||
})
|
}).list
|
||||||
console.log(mockData)
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user