表格示例错乱bug

Former-commit-id: 55509c807e43c9c9173906d9f6859ce7cd16a4dd [formerly 55509c807e43c9c9173906d9f6859ce7cd16a4dd [formerly 55509c807e43c9c9173906d9f6859ce7cd16a4dd [formerly 55509c807e43c9c9173906d9f6859ce7cd16a4dd [formerly bf3ccb939de81df011acbfd7416748259cd1583c [formerly ae7370ed3f65db3257495a8bd5f052eb9e095513]]]]]
Former-commit-id: 2a9bf374333363740328b54efb2425954f4d3235
Former-commit-id: f81df7d26b3ffcaf6a2c70af0c824ec5b884b811
Former-commit-id: f4f8ff4cb317a23e2c08b638dc9aca59f20429e8 [formerly cbbda628e9b1bed507046f926f4a6ce78492bd60]
Former-commit-id: 4b68663d61558131642ea27489ee12b3da3b6ded
Former-commit-id: 562364039d7156c5d96d61b85ec42bf25fef7db7
Former-commit-id: b9d640cba58769028f78b591095855b8cf6bb767
Former-commit-id: 72ede8b88b42b913d1d8453fdb546954561056f5
Former-commit-id: 6c87b7b7aa205f9adb6fd5825624b7195c6954aa
This commit is contained in:
liyang
2018-07-22 19:44:05 +08:00
parent 4bb3422148
commit 5c64754622
20 changed files with 26 additions and 3 deletions

View File

@@ -22,6 +22,7 @@
<script>
export default {
title: '基础表格',
index: 1,
data () {
return {
tableData: [

View File

@@ -35,6 +35,7 @@
<script>
export default {
title: '单选',
index: 10,
data () {
return {
tableData: [{

View File

@@ -36,6 +36,7 @@
<script>
export default {
title: '多选',
index: 11,
data () {
return {
tableData3: [{

View File

@@ -27,6 +27,7 @@
<script>
export default {
title: '排序',
index: 12,
data () {
return {
tableData: [{

View File

@@ -40,6 +40,7 @@
<script>
export default {
title: '筛选',
index: 13,
data () {
return {
tableData: [{

View File

@@ -40,6 +40,7 @@
<script>
export default {
title: '自定义列模板',
index: 14,
data () {
return {
tableData: [{

View File

@@ -47,6 +47,7 @@
<script>
export default {
title: '展开行',
index: 15,
data () {
return {
tableData5: [{

View File

@@ -65,6 +65,7 @@
<script>
export default {
title: '表尾合计行',
index: 16,
data () {
return {
tableData6: [{

View File

@@ -64,6 +64,7 @@
<script>
export default {
title: '合并行或列',
index: 17,
data () {
return {
tableData6: [{

View File

@@ -26,6 +26,7 @@
<script>
export default {
title: '自定义索引',
index: 18,
data () {
return {
tableData: [{

View File

@@ -23,6 +23,7 @@
<script>
export default {
title: '带斑马纹表格',
index: 2,
data () {
return {
tableData: [{

View File

@@ -23,6 +23,7 @@
<script>
export default {
title: '带边框表格',
index: 3,
data () {
return {
tableData: [{

View File

@@ -23,6 +23,7 @@
<script>
export default {
title: '带状态表格',
index: 4,
methods: {
tableRowClassName ({row, rowIndex}) {
if (rowIndex === 1) {

View File

@@ -24,6 +24,7 @@
<script>
export default {
title: '固定表头',
index: 5,
data () {
return {
tableData3: [{

View File

@@ -49,6 +49,7 @@
<script>
export default {
title: '固定列',
index: 6,
methods: {
handleClick (row) {
console.log(row)

View File

@@ -40,6 +40,7 @@
<script>
export default {
title: '固定列和表头',
index: 7,
data () {
return {
tableData3: [{

View File

@@ -53,6 +53,7 @@
<script>
export default {
title: '流体高度',
index: 8,
methods: {
deleteRow (index, rows) {
rows.splice(index, 1)

View File

@@ -42,6 +42,7 @@
<script>
export default {
title: '多级表头',
index: 9,
data () {
return {
tableData3: [{

View File

@@ -15,14 +15,18 @@
</template>
<script>
import sortby from 'lodash.sortby'
const req = context => context.keys().map(context)
const tables = req(require.context('./components', true, /\.vue$/))
const components = {}
const tableList = []
tables.forEach((table, index) => {
components[`d2-demo-el-table-${index + 1}`] = table.default
sortby(tables.map(e => ({
component: e.default,
index: e.default.index
})), ['index']).forEach((table, index) => {
components[`d2-demo-el-table-${index + 1}`] = table.component
tableList.push({
title: table.default.title,
title: table.component.title,
component: `d2-demo-el-table-${index + 1}`
})
})