From 6184eaa30e83dea5d06a8bdd11c0ed6450b8f93e Mon Sep 17 00:00:00 2001 From: skiffer-git <44203734@qq.com> Date: Sat, 16 Apr 2022 21:32:53 +0800 Subject: [PATCH] organization --- internal/api/organization/organization.go | 1 - pkg/base_info/organization_api_struct.go | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/internal/api/organization/organization.go b/internal/api/organization/organization.go index 8a651af47..413928a64 100644 --- a/internal/api/organization/organization.go +++ b/internal/api/organization/organization.go @@ -25,7 +25,6 @@ func CreateDepartment(c *gin.Context) { } req := &rpc.CreateDepartmentReq{DepartmentInfo: &open_im_sdk.Department{}} utils.CopyStructFields(req, ¶ms) - utils.CopyStructFields(req.DepartmentInfo, params.Department) err, opUserID := token_verify.ParseTokenGetUserID(c.Request.Header.Get("token"), req.OperationID) req.OpUserID = opUserID if err != nil { diff --git a/pkg/base_info/organization_api_struct.go b/pkg/base_info/organization_api_struct.go index a52a84f65..0289b2f81 100644 --- a/pkg/base_info/organization_api_struct.go +++ b/pkg/base_info/organization_api_struct.go @@ -13,7 +13,7 @@ type CreateDepartmentResp struct { } type UpdateDepartmentReq struct { - open_im_sdk.Department + *open_im_sdk.Department DepartmentID string `json:"departmentID" binding:"required"` OperationID string `json:"operationID" binding:"required"` }