@
Lunatixz - Just wanted to drop by and say congrats on a job well done. This looks amazing. I've since cut the cord and gotten rid of cable so I hadn't worked on this stuff in a while but you have taken it and really run with it!
By the way. I see CP and SB support on your TODO list. Did I ever send you the code for CouchPotato and SickBeard integration I did with the TVGuide mods I was working on? If not, let me know. They were isolated Python classes so it should port just fine to here. Actually, now that I think about it, I might have been committing to GitHub. I'll check, but anyway, great work!
EDIT
Yep, I did commit them to my TVGuide fork. Feel free to grab them for what you're doing. There is a class for couchpotato.py, sickbeard.py, tmdb.py and tvdb.py.
https://github.com/robnewton/script.tvgu...s/lib/apis
You can see there was a simple record via sickbeard implementation in the TVGuide EPG:
https://github.com/robnewton/script.tvgu...de.py#L442
Code:
elif activeMenuOption['ActionId'] == ProgramAction.RECORD_EPISODE:
sbAPI = SickBeard(ADDON.getSetting('sickbeard.baseurl'),ADDON.getSetting('sickbeard.apikey'))
if sbAPI.isShowManaged(program.seriesId) == False:
if sbAPI.addNewShow(program.seriesId) == True:
self.database.setShowAsSickBeardManaged(program.seriesId)
for n in range(1, 10):
if sbAPI.setEpisodeStatus(program.seriesId, program.seasonNumber, program.episodeNumber, 'wanted'):
self.database.setShowAsSickBeardManaged(program.seriesId)
break
sleep(1)
self.onRedrawEPG(self.channelIdx, self.viewStartDate)
pass
elif activeMenuOption['ActionId'] == ProgramAction.RECORD_SERIES:
sbAPI = SickBeard(ADDON.getSetting('sickbeard.baseurl'),ADDON.getSetting('sickbeard.apikey'))
if sbAPI.addNewShow(program.seriesId) == True:
self.database.setShowAsSickBeardManaged(program.seriesId)
self.onRedrawEPG(self.channelIdx, self.viewStartDate)
pass
elif activeMenuOption['ActionId'] == ProgramAction.RECORD_SERIES_W_OPTIONS:
sbAPI = SickBeard(ADDON.getSetting('sickbeard.baseurl'),ADDON.getSetting('sickbeard.apikey'))
if sbAPI.addNewShow(program.seriesId) == True:
self.database.setShowAsSickBeardManaged(program.seriesId)
self.onRedrawEPG(self.channelIdx, self.viewStartDate)
pass