mirror of
https://github.com/stashapp/stash.git
synced 2025-12-18 04:44:37 +03:00
Add duration statistics to stats page (#1626)
This commit is contained in:
@@ -274,6 +274,10 @@ func (qb *sceneQueryBuilder) Size() (float64, error) {
|
||||
return qb.runSumQuery("SELECT SUM(cast(size as double)) as sum FROM scenes", nil)
|
||||
}
|
||||
|
||||
func (qb *sceneQueryBuilder) Duration() (float64, error) {
|
||||
return qb.runSumQuery("SELECT SUM(cast(duration as double)) as sum FROM scenes", nil)
|
||||
}
|
||||
|
||||
func (qb *sceneQueryBuilder) CountByStudioID(studioID int) (int, error) {
|
||||
args := []interface{}{studioID}
|
||||
return qb.runCountQuery(qb.buildCountQuery(scenesForStudioQuery), args)
|
||||
|
||||
Reference in New Issue
Block a user