@@ -205,6 +205,26 @@ func (self *EventServiceImpl) JoinEvent(payload *EventJoinPayload) (result *Even
|
||||
}
|
||||
attendenceData.SetRole("normal")
|
||||
|
||||
if payload.Data.KycId != "" {
|
||||
kycUUID, err := uuid.Parse(payload.Data.KycId)
|
||||
if err != nil {
|
||||
return &EventJoinResult{
|
||||
Common: shared.CommonResult{
|
||||
HttpCode: 400,
|
||||
Exception: new(exception.Builder).
|
||||
SetStatus(exception.StatusUser).
|
||||
SetService(exception.ServiceEvent).
|
||||
SetEndpoint(exception.EndpointEventServiceJoin).
|
||||
SetType(exception.TypeCommon).
|
||||
SetOriginal(exception.CommonErrorUuidParseFailed).
|
||||
SetError(err).
|
||||
Throw(payload.Context),
|
||||
},
|
||||
}
|
||||
}
|
||||
attendenceData.SetKycId(kycUUID)
|
||||
}
|
||||
|
||||
attendanceId, err := attendenceData.Create(payload.Context)
|
||||
if err != nil {
|
||||
return &EventJoinResult{
|
||||
|
||||
Reference in New Issue
Block a user