Pārlūkot izejas kodu

update tag insert by session

master
shenjiachi pirms 6 dienas
vecāks
revīzija
d96f2ffb31
2 mainītis faili ar 3 papildinājumiem un 3 dzēšanām
  1. +1
    -1
      src/dao/user_tag_records_dao.go
  2. +2
    -2
      src/implement/user_tag_records_implement.go

+ 1
- 1
src/dao/user_tag_records_dao.go Parādīt failu

@@ -10,6 +10,6 @@ type UserTagRecordsDao interface {
UserTagRecordsGetOneByParams(params map[string]interface{}) (*model.UserTagRecords, error)
UserTagRecordsUpdateBySession(session *xorm.Session, uid interface{}, user *model.UserTagRecords, forceColumns ...string) (int64, error)
UserTagRecordsDeleteBySession(session *xorm.Session, params map[string]interface{}) (int64, error)
UserTagRecordsBatchInsert(userTagRecord []*model.UserTagRecords) (int64, error)
UserTagRecordsBatchInsertBySession(session *xorm.Session, userTagRecord []*model.UserTagRecords) (int64, error)
UserTagRecordsFindByParams(params map[string]interface{}) (*[]model.UserTagRecords, error)
}

+ 2
- 2
src/implement/user_tag_records_implement.go Parādīt failu

@@ -52,8 +52,8 @@ func (u UserTagRecordsDb) UserTagRecordsDeleteBySession(session *xorm.Session, p
}
}

func (u UserTagRecordsDb) UserTagRecordsBatchInsert(userTagRecord []*model.UserTagRecords) (int64, error) {
affected, err := u.Db.Insert(userTagRecord)
func (u UserTagRecordsDb) UserTagRecordsBatchInsertBySession(session *xorm.Session, userTagRecord []*model.UserTagRecords) (int64, error) {
affected, err := session.Insert(userTagRecord)
if err != nil {
return 0, zhios_order_relate_logx.Error(err)
}


Notiek ielāde…
Atcelt
Saglabāt