【modify】使用ESLint格式化代码

This commit is contained in:
zer0Black
2023-03-01 09:33:58 +08:00
parent 694855ae8b
commit 63369b8b87
400 changed files with 42942 additions and 43132 deletions
+39 -39
View File
@@ -25,51 +25,51 @@
</template>
<script>
import draggable from 'vuedraggable'
import ARow from 'ant-design-vue/es/grid/Row'
import ACol from 'ant-design-vue/es/grid/Col'
import draggable from 'vuedraggable'
import ARow from 'ant-design-vue/es/grid/Row'
import ACol from 'ant-design-vue/es/grid/Col'
export default {
name: 'ImgDragSort',
components:{
ACol,
ARow,
draggable
export default {
name: 'ImgDragSort',
components: {
ACol,
ARow,
draggable
},
data () {
return {
description: '图片拖拽排序',
spinning: false,
// 数据集
dataSource: [
{ id: '000', sort: 0, filePath: 'https://static.jero.com/upload/test/1_1588149743473.jpg' },
{ id: '111', sort: 1, filePath: 'https://static.jero.com/upload/test/u27356337152749454924fm27gp0_1588149731821.jpg' },
{ id: '222', sort: 2, filePath: 'https://static.jero.com/upload/test/u24454681402491956848fm27gp0_1588149712663.jpg' },
{ id: '333', sort: 3, filePath: 'https://static.jero.com/temp/国炬软件logo_1606575029126.png' },
{ id: '444', sort: 4, filePath: 'https://static.jero.com/upload/test/u8891206113801177793fm27gp0_1588149704459.jpg' }
],
oldDateSource: [],
newDateSource: []
}
},
created () {
this.oldDateSource = this.dataSource
},
methods: {
end: function (evt) {
console.log('拖动前的位置' + evt.oldIndex)
console.log('拖动后的位置' + evt.newIndex)
},
data() {
return {
description: '图片拖拽排序',
spinning: false,
//数据集
dataSource: [
{id:'000',sort: 0,filePath: 'https://static.jero.com/upload/test/1_1588149743473.jpg'},
{id:'111',sort: 1,filePath: 'https://static.jero.com/upload/test/u27356337152749454924fm27gp0_1588149731821.jpg'},
{id:'222',sort: 2,filePath: 'https://static.jero.com/upload/test/u24454681402491956848fm27gp0_1588149712663.jpg'},
{id:'333',sort: 3,filePath: 'https://static.jero.com/temp/国炬软件logo_1606575029126.png'},
{id:'444',sort: 4,filePath: 'https://static.jero.com/upload/test/u8891206113801177793fm27gp0_1588149704459.jpg'}
],
oldDateSource:[],
newDateSource:[],
}
},
created(){
this.oldDateSource = this.dataSource;
},
methods:{
end: function (evt) {
console.log("拖动前的位置"+evt.oldIndex);
console.log("拖动后的位置"+evt.newIndex);
},
sureChange(){
for(var i=0;i<this.dataSource.length;i++){
this.dataSource[i].sort = i;
}
this.newDateSource = this.dataSource;
sureChange () {
for (var i = 0; i < this.dataSource.length; i++) {
this.dataSource[i].sort = i
}
this.newDateSource = this.dataSource
}
}
}
</script>
<style scoped>
</style>
</style>