|
@@ -55,7 +55,7 @@ func CountReport(record RecordCountDTO) (traceId string, err error) {
|
|
|
return
|
|
|
}
|
|
|
currTime := time.Now()
|
|
|
- dbRecord.ReadDurationSeconds = currTime.Sub(dbRecord.ClickTime).Milliseconds()
|
|
|
+ dbRecord.ReadDurationSeconds = int64(currTime.Sub(dbRecord.ClickTime).Seconds())
|
|
|
err = userDao.UpdateSourceClicks(dbRecord)
|
|
|
}
|
|
|
if err != nil {
|
|
@@ -88,7 +88,7 @@ func CountMedia(record RecordCountDTO, mediaType string) (traceId string, err er
|
|
|
return
|
|
|
}
|
|
|
currTime := time.Now()
|
|
|
- dbRecord.ReadDurationSeconds = currTime.Sub(dbRecord.ClickTime).Milliseconds()
|
|
|
+ dbRecord.ReadDurationSeconds = int64(currTime.Sub(dbRecord.ClickTime).Seconds())
|
|
|
err = userDao.UpdateSourceClicks(dbRecord)
|
|
|
}
|
|
|
if err != nil {
|