Intro Timestamp Differential

First report

{{ block "ReportInfo" .OldReport }}
Path {{ .Path }}
Jellyfin {{ .ServerInfo.Version }} on {{ .ServerInfo.OperatingSystem }}
Analysis Settings {{ printAnalysisSettings .PluginConfig }}
Introduction Requirements {{ printIntroductionReqs .PluginConfig }}
Start time {{ printTime .StartedAt }}
End time {{ printTime .FinishedAt }}
Duration {{ printDuration .Runtime }}
{{ end }}

Second report

{{ template "ReportInfo" .NewReport }}

Statistics

Total episodes
Never found
Changed
Gains
Losses

Settings



{{/* store a reference to the data before the range query */}} {{ $p := . }} {{/* sort the show names and iterate over them */}} {{ range $name := sortShows .OldReport.Shows }}
{{/* get the unsorted seasons for this show */}} {{ $seasons := index $p.OldReport.Shows $name }} {{/* log the show name and number of seasons */}} {{ $name }}
{{/* sort the seasons to ensure they display in numerical order */}} {{ range $seasonNumber := (sortSeasons $seasons) }}
Season {{ $seasonNumber }} {{/* compare each episode in the old report to the same episode in the new report */}} {{ range $episode := index $seasons $seasonNumber }} {{/* lookup and compare both episodes */}} {{ $comparison := compareEpisodes $episode.EpisodeId $p }} {{ $old := $comparison.Old }} {{ $new := $comparison.New }} {{/* set attributes indicating if an intro was found in the old and new reports */}}

{{ $episode.Title }}

Old: {{ $old.FormattedStart }} - {{ $old.FormattedEnd }} ({{ $old.Duration }}) (valid: {{ $old.Valid }})
New: {{ $new.FormattedStart }} - {{ $new.FormattedEnd }} ({{ $new.Duration }}) (valid: {{ $new.Valid }})
{{ if ne $comparison.WarningShort "okay" }} Warning: {{ $comparison.Warning }} {{ end }}


{{ end }}
{{ end }}
{{ end }}