From cc3f07175d93b5f4fbcc6fd8a87a563a7f8e1a7c Mon Sep 17 00:00:00 2001 From: zhangqian <zhangqian@123.com> Date: 星期二, 15 八月 2023 14:26:27 +0800 Subject: [PATCH] 服务单批量删除接口 --- api/v1/serviceOrder.go | 23 +++++++++++++++++++++++ 1 files changed, 23 insertions(+), 0 deletions(-) diff --git a/api/v1/serviceOrder.go b/api/v1/serviceOrder.go index f76babe..6675774 100644 --- a/api/v1/serviceOrder.go +++ b/api/v1/serviceOrder.go @@ -66,6 +66,29 @@ ctx.Ok() } +// BatchDelete +// @Tags 鏈嶅姟鍗曠鐞� +// @Summary 鎵归噺鍒犻櫎鏈嶅姟鍗� +// @Produce application/json +// @Param object body request.CommonIds true "鍙傛暟" +// @Success 200 {object} contextx.Response{} +// @Router /api/serviceOrder/delete [delete] +func (s *ServiceOrderApi) BatchDelete(c *gin.Context) { + var params request.CommonIds + ctx, ok := contextx.NewContext(c, ¶ms) + if !ok { + return + } + + errCode := service.NewServiceOrderService().BatchDeleteServiceOrder(params.Ids) + if errCode != ecode.OK { + ctx.Fail(errCode) + return + } + + ctx.Ok() +} + // Update // @Tags 鏈嶅姟鍗曠鐞� // @Summary 鏇存柊鏈嶅姟鍗� -- Gitblit v1.8.0