ShokoAnime / ShokoOnPlex

Repository for Shoko On Plex, a Plex channel plugin.
http://shokoanime.com/plex/
22 stars 5 forks source link

tie plex user to jmm user #18

Closed saitoh183 closed 8 years ago

saitoh183 commented 8 years ago

this would allow for easier management of watched status for a multiuser environment. Because users dont always remember to switch accounts when they open the pluging

maxpiva commented 8 years ago

Last time i check, plex is unable to scrobble channels (watch/unwatch) only his own sections. Maybe some clever python programmer can help us out. So we can link all we want but the watch/unwatch status from plex will be not propagated to JMM users, till this is resolved first.

CuddleBear92 commented 8 years ago

well i think its more meant for the settings file so each plex user has its own plugin settings file. that way we can have more than one JMM server on one plex server. aswell as each plex user can set up different JMM users that will track their own watchstates.

atleast that is what we talked about on Discord.

maxpiva commented 8 years ago

Hmm, problem is, plugin settings should be hardcoded, we cannot populate them with jmm users, but we could in fact do a kinda selection first time and, after, generate a extra category in the list to switch users. Or better, if we could make plex forward the current logged plex user to jmm, if we can do that, we could in fact map plex users to jmm users in jmm and the problem will be solved. I'll explore the last avenue :)

CuddleBear92 commented 8 years ago

good to hear that you are on it! <3

maxpiva commented 8 years ago

Okey, got it, thanks Fiddler ;)

    xml = XML.ElementFromURL("https://plex.tv/users/account", headers={'X-Plex-Token': Request.Headers['X-Plex-Token']})
    username = xml.xpath('/user')[0].get('title')