feat: add short_code field to device login API
- Add optional short_code parameter to DeviceLoginRequest - Add ShortCode field to Device model - Save short_code to database during device registration - Add database migration for user_device.short_code column - Fix duplicate variable declaration in routes.go
This commit is contained in:
@@ -197,6 +197,7 @@ func (l *DeviceLoginLogic) registerUserAndDevice(req *types.DeviceLoginRequest)
|
||||
UserId: userInfo.Id,
|
||||
UserAgent: req.UserAgent,
|
||||
Identifier: req.Identifier,
|
||||
ShortCode: req.ShortCode,
|
||||
Enabled: true,
|
||||
Online: false,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user