Skip to content

Commit 336f402

Browse files
committed
perf: refine
1 parent 279d43f commit 336f402

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

mock/article.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ for (let i = 0; i < count; i++) {
1818
forecast: '@float(0, 100, 2, 2)',
1919
importance: '@integer(1, 3)',
2020
'type|1': ['CN', 'US', 'JP', 'EU'],
21-
'status|1': ['published', 'draft', 'deleted'],
21+
'status|1': ['published', 'draft'],
2222
display_time: '@datetime',
2323
comment_disabled: true,
2424
pageviews: '@integer(300, 5000)',

src/views/table/complex-table.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -319,8 +319,8 @@ export default {
319319
const tempData = Object.assign({}, this.temp)
320320
tempData.timestamp = +new Date(tempData.timestamp) // change Thu Nov 30 2017 16:41:05 GMT+0800 (CST) to 1512031311464
321321
updateArticle(tempData).then(() => {
322-
const index = this.list.findIndex(v => v.id === this.temp.id)
323-
this.list.splice(index, 1, this.temp)
322+
const index = this.list.findIndex(v => v.id === this.temp.id)
323+
this.list.splice(index, 1, this.temp)
324324
this.dialogFormVisible = false
325325
this.$notify({
326326
title: 'Success',

0 commit comments

Comments
 (0)