1
0
This commit is contained in:
syui 2024-04-02 23:02:45 +09:00
parent 1ecbce4b16
commit 014af81a92
Signed by: syui
GPG Key ID: 5417CFEBAD92DF56
2 changed files with 4 additions and 4 deletions

View File

@ -693,8 +693,8 @@ func (h *OgentHandler) UpdateMa(ctx context.Context, req *UpdateMaReq, params Up
// DeleteMa handles DELETE /mas/{id} requests.
func (h *OgentHandler) DeleteMa(ctx context.Context, params DeleteMaParams) (DeleteMaRes, error) {
err := h.client.Ma.DeleteOneID(0).Exec(ctx)
//err := h.client.Ma.DeleteOneID(params.ID).Exec(ctx)
//err := h.client.Ma.DeleteOneID(0).Exec(ctx)
err := h.client.Ma.DeleteOneID(params.ID).Exec(ctx)
if err != nil {
switch {
case ent.IsNotFound(err):

View File

@ -693,8 +693,8 @@ func (h *OgentHandler) UpdateMa(ctx context.Context, req *UpdateMaReq, params Up
// DeleteMa handles DELETE /mas/{id} requests.
func (h *OgentHandler) DeleteMa(ctx context.Context, params DeleteMaParams) (DeleteMaRes, error) {
err := h.client.Ma.DeleteOneID(0).Exec(ctx)
//err := h.client.Ma.DeleteOneID(params.ID).Exec(ctx)
//err := h.client.Ma.DeleteOneID(0).Exec(ctx)
err := h.client.Ma.DeleteOneID(params.ID).Exec(ctx)
if err != nil {
switch {
case ent.IsNotFound(err):