diff --git a/YD_Event.Application/CitizenSports/CitizenSportsPlatformService.cs b/YD_Event.Application/CitizenSports/CitizenSportsPlatformService.cs index 149d7b1..92feed0 100644 --- a/YD_Event.Application/CitizenSports/CitizenSportsPlatformService.cs +++ b/YD_Event.Application/CitizenSports/CitizenSportsPlatformService.cs @@ -353,6 +353,19 @@ public sealed class CitizenSportsPlatformService : ITransient TypeName = x.TypeName, PlayerCount = x.Players.Count }).ToList(), + Players = prepared.Groups.SelectMany(group => group.Players.Select(player => new CitizenSportsPlayerPreview + { + TypeName = group.TypeName, + PlayerId = player.PlayerId, + CardNumber = player.CardNumber, + CardType = player.CardType, + PlayerName = player.PlayerName, + PlayerSex = player.PlayerSex, + PlayerPhone = player.PlayerPhone, + PlayerBirth = player.PlayerBirth, + GroupName = player.GroupName, + DeleteStatus = player.DeleteStatus + })).ToList(), Errors = prepared.Errors }; diff --git a/YD_Event.Application/CitizenSports/Dtos/CitizenSportsSyncDtos.cs b/YD_Event.Application/CitizenSports/Dtos/CitizenSportsSyncDtos.cs index 1bfb7d5..0d77257 100644 --- a/YD_Event.Application/CitizenSports/Dtos/CitizenSportsSyncDtos.cs +++ b/YD_Event.Application/CitizenSports/Dtos/CitizenSportsSyncDtos.cs @@ -37,7 +37,7 @@ public class CitizenSportsExecuteInput : CitizenSportsSyncInput } /// -/// 同步预览结果,不返回证件号、手机号等敏感信息。 +/// 同步预览结果,包含实际待上传的运动员明细。 /// public class CitizenSportsPreviewOutput { @@ -49,6 +49,7 @@ public class CitizenSportsPreviewOutput public int TypeCount { get; set; } public bool CanUpload => Errors.Count == 0 && UploadRecordCount > 0; public List Types { get; set; } = []; + public List Players { get; set; } = []; public List Errors { get; set; } = []; } @@ -58,6 +59,23 @@ public class CitizenSportsTypePreview public int PlayerCount { get; set; } } +/// +/// 实际发送给市民运动会平台的运动员数据。 +/// +public class CitizenSportsPlayerPreview +{ + public string TypeName { get; set; } = string.Empty; + public string PlayerId { get; set; } = string.Empty; + public string CardNumber { get; set; } = string.Empty; + public string CardType { get; set; } = string.Empty; + public string PlayerName { get; set; } = string.Empty; + public string? PlayerSex { get; set; } + public string? PlayerPhone { get; set; } + public string? PlayerBirth { get; set; } + public string? GroupName { get; set; } + public int DeleteStatus { get; set; } +} + public class CitizenSportsValidationError { public long RegistrationPersonId { get; set; }