Skip to content

Commit

Permalink
修复获取协作者列表 响应体异常、转移拥有者 请求体异常
Browse files Browse the repository at this point in the history
Signed-off-by: Vicente.Yu <^@^>
  • Loading branch information
Vicente.Yu committed Apr 19, 2024
1 parent be73f91 commit 1594b62
Show file tree
Hide file tree
Showing 3 changed files with 48 additions and 40 deletions.
56 changes: 30 additions & 26 deletions src/Ccm.Spec/PostDrivePermissionMemberListResponseDto.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,33 +13,37 @@ public record PostDrivePermissionMemberListResponseDto
/// <para>必填:否</para>
/// </summary>
[JsonPropertyName("members")]
public string? Members { get; set; }
public Member[]? Members { get; set; }

/// <summary>
/// <para>协作者类型 "user" or "chat"</para>
/// <para>必填:否</para>
/// </summary>
[JsonPropertyName("member_type")]
public string? MemberType { get; set; }
/// <summary></summary>
public record Member
{
/// <summary>
/// <para>协作者类型 "user" or "chat"</para>
/// <para>必填:否</para>
/// </summary>
[JsonPropertyName("member_type")]
public string? MemberType { get; set; }

/// <summary>
/// <para>协作者openid</para>
/// <para>必填:否</para>
/// </summary>
[JsonPropertyName("member_open_id")]
public string? MemberOpenId { get; set; }
/// <summary>
/// <para>协作者openid</para>
/// <para>必填:否</para>
/// </summary>
[JsonPropertyName("member_open_id")]
public string? MemberOpenId { get; set; }

/// <summary>
/// <para>协作者userid(仅当member_type="user"时有效)</para>
/// <para>必填:否</para>
/// </summary>
[JsonPropertyName("member_user_id")]
public string? MemberUserId { get; set; }
/// <summary>
/// <para>协作者userid(仅当member_type="user"时有效)</para>
/// <para>必填:否</para>
/// </summary>
[JsonPropertyName("member_user_id")]
public string? MemberUserId { get; set; }

/// <summary>
/// <para>协作者权限 (注意: **有"edit"权限的协作者一定有"view"权限**)</para>
/// <para>必填:否</para>
/// </summary>
[JsonPropertyName("perm")]
public string? Perm { get; set; }
}
/// <summary>
/// <para>协作者权限 (注意: **有"edit"权限的协作者一定有"view"权限**)</para>
/// <para>必填:否</para>
/// </summary>
[JsonPropertyName("perm")]
public string? Perm { get; set; }
}
}
30 changes: 17 additions & 13 deletions src/Ccm.Spec/PostDrivePermissionMemberTransferBodyDto.cs
Original file line number Diff line number Diff line change
Expand Up @@ -27,21 +27,25 @@ public record PostDrivePermissionMemberTransferBodyDto
/// <para>必填:是</para>
/// </summary>
[JsonPropertyName("owner")]
public string Owner { get; set; } = string.Empty;
public OwnerSuffix Owner { get; set; } = new();

/// <summary>
/// <para>用户类型,可选 **email、openid、userid、unionid**</para>
/// <para>必填:是</para>
/// </summary>
[JsonPropertyName("member_type")]
public string MemberType { get; set; } = string.Empty;
/// <summary></summary>
public record OwnerSuffix
{
/// <summary>
/// <para>用户类型,可选 **email、openid、userid、unionid**</para>
/// <para>必填:是</para>
/// </summary>
[JsonPropertyName("member_type")]
public string MemberType { get; set; } = string.Empty;

/// <summary>
/// <para>用户类型下的值,获取方式见 [如何获取不同的用户 ID](https://open.feishu.cn/document/home/user-identity-introduction/open-id)</para>
/// <para>必填:是</para>
/// </summary>
[JsonPropertyName("member_id")]
public string MemberId { get; set; } = string.Empty;
/// <summary>
/// <para>用户类型下的值,获取方式见 [如何获取不同的用户 ID](https://open.feishu.cn/document/home/user-identity-introduction/how-to-get)</para>
/// <para>必填:是</para>
/// </summary>
[JsonPropertyName("member_id")]
public string MemberId { get; set; } = string.Empty;
}

/// <summary>
/// <para>true 为转移后删除旧 owner 的权限,默认为false</para>
Expand Down
2 changes: 1 addition & 1 deletion src/FeishuNetSdk.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
<Copyright>MIT</Copyright>
<Description>适用于飞书开放平台的.Net开发包</Description>
<PackageLicenseFile>LICENSE</PackageLicenseFile>
<Version>2.1.9</Version>
<Version>2.1.9.1</Version>
</PropertyGroup>

<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
Expand Down

0 comments on commit 1594b62

Please sign in to comment.