dengbiao vor 3 Monaten
Ursprung
Commit
9963d7d4a3
2 geänderte Dateien mit 13 neuen und 0 gelöschten Zeilen
  1. +1
    -0
      src/dao/super_cloud_issuance_user_robot_bind_follow_dao.go
  2. +12
    -0
      src/implement/super_cloud_issuance_user_robot_bind_follow_db.go

+ 1
- 0
src/dao/super_cloud_issuance_user_robot_bind_follow_dao.go Datei anzeigen

@@ -7,6 +7,7 @@ import (

type SuperCloudIssuanceUserRobotBindFollowDao interface {
GetCloudIssuanceUserRobotBindFollow(id int) (m *models.SuperCloudIssuanceUserRobotBindFollow, err error)
GetCloudIssuanceUserRobotBindFollowById(id int) (m *models.SuperCloudIssuanceUserRobotBindFollow, err error)
GetCloudIssuanceUserRobotBindFollowByChatRoomId(chatRoomId string, robotId int) (m *models.SuperCloudIssuanceUserRobotBindFollow, err error)
InsertCloudIssuanceUserRobotBindFollow(m *models.SuperCloudIssuanceUserRobotBindFollow) (id int, err error)
SaveCloudIssuanceUserRobotBindFollow(id interface{}, m *models.SuperCloudIssuanceUserRobotBindFollow, forceColums ...string) (affected int64, err error)


+ 12
- 0
src/implement/super_cloud_issuance_user_robot_bind_follow_db.go Datei anzeigen

@@ -65,6 +65,18 @@ func (s SuperCloudIssuanceUserRobotBindFollowDb) GetCloudIssuanceUserRobotBindFo
return m, nil
}

func (s SuperCloudIssuanceUserRobotBindFollowDb) GetCloudIssuanceUserRobotBindFollowById(id int) (m *models.SuperCloudIssuanceUserRobotBindFollow, err error) {
m = new(models.SuperCloudIssuanceUserRobotBindFollow)
has, err := s.Db.Where("id =?", id).Get(m)
if err != nil {
return nil, zhios_order_relate_logx.Error(err)
}
if has == false {
return nil, nil
}
return m, nil
}

func (s SuperCloudIssuanceUserRobotBindFollowDb) GetCloudIssuanceUserRobotBindFollowByChatRoomId(chatRoomId string, robotId int) (m *models.SuperCloudIssuanceUserRobotBindFollow, err error) {
m = new(models.SuperCloudIssuanceUserRobotBindFollow)
has, err := s.Db.Where("chat_room_id =? AND robot_id = ? AND state = 1", chatRoomId, robotId).Get(m)


Laden…
Abbrechen
Speichern