处理医生银行卡返回为null问题

This commit is contained in:
wucongxing 2023-07-21 13:45:31 +08:00
parent a434046216
commit 927115f3a0
2 changed files with 5 additions and 5 deletions

View File

@ -89,7 +89,7 @@ type GetUserDoctor struct {
Hospital *hospitalResponse.Hospital `json:"hospital"` // 医院
UserDoctorInfo *userDoctorInfoResponse.UserDoctorInfo `json:"user_doctor_info"` // 医生详情
DoctorExpertise []*doctorExpertiseResponse.DoctorExpertise `json:"doctor_expertise"` // 医生专长
DoctorBankCard *doctorBankCardResponse.DoctorBankCard `json:"doctor_bank_card"` // 医生银行卡
DoctorBankCard doctorBankCardResponse.DoctorBankCard `json:"doctor_bank_card"` // 医生银行卡
}
// getUserDoctorPendingPage 身份审核-获取医生列表-分页

View File

@ -1115,15 +1115,16 @@ func (r *UserDoctorService) GetUserDoctorExpertiseByDoctorId(doctorId int64) ([]
}
// GetUserDoctorBankByDoctorId 获取医生银行卡
func (r *UserDoctorService) GetUserDoctorBankByDoctorId(doctorId int64) (*doctorBankCardResponse.DoctorBankCard, error) {
func (r *UserDoctorService) GetUserDoctorBankByDoctorId(doctorId int64) (doctorBankCardResponse.DoctorBankCard, error) {
var doctorExpertisesResponse doctorBankCardResponse.DoctorBankCard
// 获取医生银行卡
doctorBankCardDao := dao.DoctorBankCardDao{}
doctorBankCard, err := doctorBankCardDao.GetDoctorBankCardByDoctorId(doctorId)
if err != nil && doctorBankCard == nil {
return nil, nil
return doctorExpertisesResponse, nil
}
doctorExpertisesResponse := &doctorBankCardResponse.DoctorBankCard{
doctorExpertisesResponse = doctorBankCardResponse.DoctorBankCard{
BankCardId: strconv.FormatInt(doctorBankCard.BankCardId, 10),
DoctorId: strconv.FormatInt(doctorBankCard.DoctorId, 10),
BankId: strconv.FormatInt(doctorBankCard.BankId, 10),
@ -1691,7 +1692,6 @@ func (r *UserDoctorService) PutMulti(doctorId int64, req requests.PutMulti) (boo
if req.MultiPointStatus == 1 {
userDoctorData["multi_point_status"] = 1
userDoctorData["multi_point_fail_reason"] = ""
}
// 修改医生数据