info get profile

This commit is contained in:
eson 2023-09-27 12:12:28 +08:00
parent 8654ab3ecd
commit 943eba6f1a

View File

@ -93,14 +93,18 @@ func (a *FsAddressModel) SettingUserDefaultAddress(ctx context.Context, userId i
return err
}
err = tx.Where("`user_id` = ? and `status` = 1 and `address_id` = ? ", userId, addressId).
err = tx.Where("`user_id` = ? and `status` = 1 and `address_id` = ?", userId, addressId).
UpdateColumn("ltime", now.AddDate(250, 0, 0)).
UpdateColumn("utime", now).Error
if err != nil {
return err
}
err = tx.Where(" `user_id` = ? and `status` = 1 and `address_id` != ? and `ltime` > ? ", userId, addressId, now.AddDate(10, 0, 0)).
err = tx.Where("`user_id` = ? and `status` = 1 and `address_id` != ? and `ltime` > ?", userId, addressId, now.AddDate(10, 0, 0)).Take(nil).Error
if err != nil {
logx.Error(err)
}
err = tx.Where("`user_id` = ? and `status` = 1 and `address_id` != ? and `ltime` > ?", userId, addressId, now.AddDate(10, 0, 0)).
UpdateColumn("ltime", now).Error
if err != nil {
logx.Error(err)