|
|
|
@@ -44,7 +44,11 @@ func (l *InfoListLogic) InfoList(in *pcmCore.InfoListReq) (*pcmCore.InfoListResp |
|
|
|
result := pcmCore.InfoListResp{} |
|
|
|
// 查询p端类型 |
|
|
|
var kind string |
|
|
|
l.svcCtx.DbEngin.Raw("select type as kind from sc_participant_phy_info where id = ?", in.ParticipantId).Scan(&kind) |
|
|
|
tx := l.svcCtx.DbEngin.Raw("select type as kind from sc_participant_phy_info where id = ?", in.ParticipantId).Scan(&kind) |
|
|
|
if tx.Error != nil { |
|
|
|
logx.Error(tx.Error) |
|
|
|
return nil, tx.Error |
|
|
|
} |
|
|
|
// 查询云智超中的数据列表 |
|
|
|
switch kind { |
|
|
|
case constants.HPC: |
|
|
|
@@ -66,6 +70,7 @@ func (l *InfoListLogic) InfoList(in *pcmCore.InfoListReq) (*pcmCore.InfoListResp |
|
|
|
func findModelList(participantId int64, dbEngin *gorm.DB, data interface{}) error { |
|
|
|
tx := dbEngin.Where("participant_id = ? AND status NOT IN ?", participantId, []string{"Deleted", "Succeeded", "Completed", "Failed"}).Find(data) |
|
|
|
if tx.Error != nil { |
|
|
|
logx.Error(tx.Error) |
|
|
|
return tx.Error |
|
|
|
} |
|
|
|
return nil |
|
|
|
|