拖拽排序
... 2021-7-29 Less than 1 minute
# 拖拽排序
<!-- 导入需要的包 (一定要放到index.html中的head标签里) -->
<script src="https://cdn.staticfile.net/Sortable/1.10.0-rc2/Sortable.min.js"></script>
1
2
2
Copy
<!-- 导入需要的包 (一定要放到index.html中的head标签里) -->
<script src="https://cdn.staticfile.net/Sortable/1.10.0-rc2/Sortable.min.js"></script>
sortable
设置为true
即可同时开启行和列的拖拽功能
<avue-crud :option="option" :data="data"></avue-crud>
<script>
export default {
data(){
return {
data:[{
text1:'内容1-1',
text2:'内容1-2'
},{
text1:'内容2-1',
text2:'内容2-2'
},{
text1:'内容3-1',
text2:'内容3-2'
}],
option:{
sortable:true,
column: [{
label: '列内容1',
prop: 'text1',
}, {
label: '列内容2',
prop: 'text2',
}]
}
}
}
}
</script>
This app can be installed on your PC or mobile device. This will allow this web app to look and behave like any other installed app. You will find it in your app lists and be able to pin it to your home screen, start menus or task bars. This installed web app will also be able to safely interact with other apps and your operating system.