优化帖子删除接口及按钮事件冒泡处理

This commit is contained in:
wangqiao
2025-09-15 22:16:12 +08:00
parent ec5cddae61
commit fd31274a21
2 changed files with 2 additions and 2 deletions

View File

@ -49,7 +49,7 @@ export const getChannelPosts = (params: { id: number }) => {
* @return {Promise} * @return {Promise}
*/ */
export const postsDelete = (params: { id: number }) => { export const postsDelete = (params: { id: number }) => {
return useDollarFetchRequest.del<IResponse<boolean>>('/prod-api/app-api/business/posts/delete', { params }) return useDollarFetchRequest.del<IResponse<boolean>>('/prod-api/app-api/business/posts/delete?id=' + params.id, {})
} }
/** /**
* 获取帖子详情 * 获取帖子详情

View File

@ -20,7 +20,7 @@
<div class="w-[100px] flex flex-shrink-0 items-center justify-end"> <div class="w-[100px] flex flex-shrink-0 items-center justify-end">
<span class="ellipsis text-[13px] color-[#96999f]">{{ item.creatorName }}</span> <span class="ellipsis text-[13px] color-[#96999f]">{{ item.creatorName }}</span>
<!-- 删除 --> <!-- 删除 -->
<el-button v-if="false" type="danger" size="small" @click="handleDelete(item.postsId)">删除</el-button> <el-button v-if="false" type="danger" size="small" @click.stop="handleDelete(item.postsId)">删除</el-button>
</div> </div>
</div> </div>
</div> </div>