From ecfbf460117f2622714ed972b22e9d7d942aba3b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=BA=8E=E8=82=96=E7=A3=8A?= <18851179580@163.com> Date: Thu, 12 Feb 2026 14:20:34 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E5=88=A0=E9=99=A4=E5=92=8C?= =?UTF-8?q?=E4=B8=BE=E6=8A=A5=E6=8E=A5=E5=8F=A3=E8=B0=83=E7=94=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/plugins/video/detail/detail.vue | 62 ++++++++++----------------- 1 file changed, 23 insertions(+), 39 deletions(-) diff --git a/pages/plugins/video/detail/detail.vue b/pages/plugins/video/detail/detail.vue index 4b7a8311..dcbd0e23 100644 --- a/pages/plugins/video/detail/detail.vue +++ b/pages/plugins/video/detail/detail.vue @@ -154,15 +154,15 @@ - + - - 取消 - 举报原因 - 确定 + + 取消 + 举报原因 + 确定 - + 举报原因* @@ -1263,12 +1263,13 @@ }, // 关闭下拉菜单 - handle_dropdown_item_click(comment_id, data) { + handle_dropdown_item_click(comment_id, obj) { + debugger; if (this.active_dropdown_id == comment_id) { this.active_dropdown_id = null; } // 处理不同操作 - if (data.action == 'delete') { + if (obj.type == 'delete') { // 确认删除 uni.showModal({ title: '确认删除', @@ -1276,11 +1277,11 @@ success: (res) => { if (res.confirm) { // 调用删除接口 - this.delete_comment(id); + this.delete_comment(comment_id); } } }); - } else if (data.action == 'report') { + } else if (obj.type == 'report') { // 举报评论 this.popup_report_status = true; this.report_comment_id = comment_id; @@ -1299,9 +1300,9 @@ const data = res.data; if (data.code == 0) { // 删除评论数据 - delete_comment_handle(comment_id); + this.delete_comment_handle(comment_id); // 显示删除成功提示 - app.globalData.showToast(this.$t('common.delete_success')); + app.globalData.showToast(this.$t('common.del_success')); } else { if (app.globalData.is_login_check(res.data)) { app.globalData.showToast(res.data.msg); @@ -1430,11 +1431,12 @@ // 获取选中的举报原因和具体类型 const main_reason = this.report_type_list[this.current_main_index]; const sub_reason = main_reason.data[this.current_sub_index]; + // 调用举报接口 uni.request({ url: app.globalData.get_request_url("report", "index", "video"), method: 'POST', data: { - id: comment_id, + id: this.report_comment_id, reason: main_reason.name, type: sub_reason }, @@ -1455,11 +1457,6 @@ } } }); - // 可以在这里调用API提交举报 - // this.submitReportToServer({ - // main_reason: main_reason.name, - // sub_reason: sub_reason - // }); }, mounted() { // 添加全局点击事件监听 @@ -1771,45 +1768,32 @@ } /* 新的举报弹窗样式 */ - .new-report-content { + .report-content { width: 100%; max-width: 750rpx; background-color: #fff; border-radius: 20rpx; } - .new-report-header { + .report-header { padding: 30rpx 40rpx; - border-bottom: 1rpx solid #eee; - background-color: #f8f8f8; + border-bottom: 1rpx solid #ddd; + background-color: #fff; } - .new-report-btn { + .report-btn { font-size: 32rpx; - padding: 12rpx 30rpx; - border-radius: 6rpx; color: #333; - font-weight: 500; } - .cancel-btn { - background-color: #f5f5f5; - border: 1rpx solid #ddd; - } - - .submit-btn { - background-color: #e74c3c; - color: #fff; - border: 1rpx solid #d32f2f; - } - - .new-report-title { + .report-title { font-size: 36rpx; font-weight: bold; + text-align: center; color: #333; } - .new-report-body { + .report-body { padding: 30rpx 40rpx; }