mirror of
https://github.com/stashapp/stash.git
synced 2025-12-17 04:14:39 +03:00
Scene play and o-counter history view and editing (#4532)
Co-authored-by: randemgame <61895715+randemgame@users.noreply.github.com>
This commit is contained in:
@@ -1012,10 +1012,6 @@ func makeSceneFile(i int) *models.VideoFile {
|
||||
}
|
||||
}
|
||||
|
||||
func getScenePlayCount(index int) int {
|
||||
return index % 5
|
||||
}
|
||||
|
||||
func getScenePlayDuration(index int) float64 {
|
||||
if index%5 == 0 {
|
||||
return 0
|
||||
@@ -1032,15 +1028,6 @@ func getSceneResumeTime(index int) float64 {
|
||||
return float64(index%5) * 1.2
|
||||
}
|
||||
|
||||
func getSceneLastPlayed(index int) *time.Time {
|
||||
if index%5 == 0 {
|
||||
return nil
|
||||
}
|
||||
|
||||
t := time.Date(2020, 1, index%5, 1, 2, 3, 0, time.UTC)
|
||||
return &t
|
||||
}
|
||||
|
||||
func makeScene(i int) *models.Scene {
|
||||
title := getSceneTitle(i)
|
||||
details := getSceneStringValue(i, "Details")
|
||||
@@ -1073,7 +1060,6 @@ func makeScene(i int) *models.Scene {
|
||||
getSceneEmptyString(i, urlField),
|
||||
}),
|
||||
Rating: getIntPtr(rating),
|
||||
OCounter: getOCounter(i),
|
||||
Date: getObjectDate(i),
|
||||
StudioID: studioID,
|
||||
GalleryIDs: models.NewRelatedIDs(gids),
|
||||
@@ -1083,9 +1069,7 @@ func makeScene(i int) *models.Scene {
|
||||
StashIDs: models.NewRelatedStashIDs([]models.StashID{
|
||||
sceneStashID(i),
|
||||
}),
|
||||
PlayCount: getScenePlayCount(i),
|
||||
PlayDuration: getScenePlayDuration(i),
|
||||
LastPlayedAt: getSceneLastPlayed(i),
|
||||
ResumeTime: getSceneResumeTime(i),
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user