Skip to content

Commit

Permalink
Set recorded.recgroupid (in addition to recgroup) for new recordings.
Browse files Browse the repository at this point in the history
Otherwise, recgroupid gets the row default of 1.  The only impact I've
seen so far of the incorrect code is that in the Watch Recordings
screen, "Menu > Storage Options > Change Recording Group" may show
incorrect item counts for the recording groups.

One way to correct the recgroupid values is to "Change group filter"
to the recording group, highlight All Programs, add to playlist, then
"Playlist Options > Storage Options > Change Recording Group" and
select the current recording group (which should already be
highlighted).
  • Loading branch information
stichnot committed Jun 7, 2015
1 parent de66bcd commit dc8c52f
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions mythtv/libs/libmythtv/recordinginfo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1044,7 +1044,7 @@ bool RecordingInfo::InsertProgram(RecordingInfo *pg,
" stars, previouslyshown, originalairdate, "
" findid, transcoder, playgroup, recpriority, "
" basename, progstart, progend, profile, "
" duplicate, storagegroup, inputname) "
" duplicate, storagegroup, inputname, recgroupid) "
"VALUES"
" (:CHANID, :STARTS, :ENDS, :TITLE, "
" :SUBTITLE, :DESC, :SEASON, :EPISODE, "
Expand All @@ -1053,7 +1053,7 @@ bool RecordingInfo::InsertProgram(RecordingInfo *pg,
" :STARS, :REPEAT, :ORIGAIRDATE, "
" :FINDID, :TRANSCODER, :PLAYGROUP, :RECPRIORITY, "
" :BASENAME, :PROGSTART, :PROGEND, :PROFILE, "
" 0, :STORGROUP, :INPUTNAME) "
" 0, :STORGROUP, :INPUTNAME, :RECGROUPID) "
);

if (pg->rectype == kOverrideRecord)
Expand Down Expand Up @@ -1093,6 +1093,7 @@ bool RecordingInfo::InsertProgram(RecordingInfo *pg,
query.bindValue(":PROGEND", pg->endts);
query.bindValue(":PROFILE", null_to_empty(rule->m_recProfile));
query.bindValue(":INPUTNAME", inputname);
query.bindValue(":RECGROUP", GetRecgroupID(pg->recgroup));

bool ok = query.exec() && (query.numRowsAffected() > 0);
if (ok)
Expand Down

0 comments on commit dc8c52f

Please sign in to comment.