功能细节调整
This commit is contained in:
@ -4,7 +4,7 @@
|
||||
<custom-navbar title="操作视频" :showBack="true" backgroundColor="#202020" color="#FFFFFF"></custom-navbar>
|
||||
<view class="device-page" :style="{ paddingTop: navBarHeight + 'px' }">
|
||||
<scroll-view scroll-y>
|
||||
<uni-swipe-action>
|
||||
<uni-swipe-action ref="swipeAction">
|
||||
<block v-for="(item, index) in videoList" :key="index">
|
||||
<uni-swipe-action-item :right-options="item.showConfirm ? confirmOptions : deleteOptions"
|
||||
@click="handleSwipeClick($event, index,item)" class="content">
|
||||
@ -86,8 +86,8 @@
|
||||
// 如果是确认删除操作
|
||||
if (content.text === '确认删除') {
|
||||
let ids = item.id
|
||||
let data ={
|
||||
ids:item.id
|
||||
let data = {
|
||||
ids: item.id
|
||||
}
|
||||
deleteOperationVideo(ids).then((res) => {
|
||||
if (res.code == 200) {
|
||||
@ -96,6 +96,8 @@
|
||||
icon: 'success'
|
||||
});
|
||||
this.getData()
|
||||
// 关闭所有滑动项
|
||||
this.$refs.swipeAction.closeAll();
|
||||
} else {
|
||||
uni.showToast({
|
||||
title: res.msg,
|
||||
@ -164,6 +166,13 @@
|
||||
},
|
||||
onShow() {
|
||||
this.getData()
|
||||
// 关闭所有滑动项
|
||||
// 使用$nextTick确保组件已渲染
|
||||
this.$nextTick(() => {
|
||||
if (this.$refs.swipeAction) {
|
||||
this.$refs.swipeAction.closeAll();
|
||||
}
|
||||
});
|
||||
},
|
||||
onLoad(options) {
|
||||
this.deviceID = options.id
|
||||
|
Reference in New Issue
Block a user