From 0b5dbd202d75e04ae30536b6cbcb2e2d02f470f0 Mon Sep 17 00:00:00 2001 From: Ruud Date: Sun, 29 Apr 2012 17:31:12 +0200 Subject: [PATCH] Return more info for in_wanted and in_library. fixes #175 --- couchpotato/core/plugins/movie/static/search.js | 4 ++-- couchpotato/core/providers/movie/_modifier/main.py | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/couchpotato/core/plugins/movie/static/search.js b/couchpotato/core/plugins/movie/static/search.js index 10381b56..8d6b2af7 100644 --- a/couchpotato/core/plugins/movie/static/search.js +++ b/couchpotato/core/plugins/movie/static/search.js @@ -326,9 +326,9 @@ Block.Search.Item = new Class({ 'src': self.info.images.poster[0] }) : null, self.info.in_wanted ? new Element('span.in_wanted', { - 'text': 'Already in wanted list: ' + self.info.in_wanted.label + 'text': 'Already in wanted list: ' + self.info.in_wanted.profile.label }) : (self.info.in_library ? new Element('span.in_library', { - 'text': 'Already in library: ' + self.info.in_library.label + 'text': 'Already in library: ' + self.info.in_library.profile.label }) : null), self.title_select = new Element('select', { 'name': 'title' diff --git a/couchpotato/core/providers/movie/_modifier/main.py b/couchpotato/core/providers/movie/_modifier/main.py index f131adf7..527c7b98 100644 --- a/couchpotato/core/providers/movie/_modifier/main.py +++ b/couchpotato/core/providers/movie/_modifier/main.py @@ -55,11 +55,11 @@ class MovieResultModifier(Plugin): for movie in l.movies: if movie.status_id == active_status['id']: - temp['in_wanted'] = movie.profile.to_dict() + temp['in_wanted'] = fireEvent('movie.get', movie.id, single = True) for release in movie.releases: if release.status_id == done_status['id']: - temp['in_library'] = release.quality.to_dict() + temp['in_library'] = fireEvent('movie.get', movie.id, single = True) except: log.error('Tried getting more info on searched movies: %s' % traceback.format_exc())