BlitterStudio / MB_SubSonic

MusicBee SubSonic plugin
GNU General Public License v3.0
115 stars 13 forks source link

Feature: Save Playlists to Subsonic server #18

Closed andocromn closed 5 years ago

andocromn commented 7 years ago

I would like the ability to save playlists from musicbee back to a playlist on the subsonic server. This doesn't seem to be currently implemented

midwan commented 7 years ago

If the API supports it, I can add the functionality in the plugin itself, but it must also be supported by MusicBee otherwise nothing will happen. :)

I'll look into it and update you when I have more news.

andocromn commented 7 years ago

the subsonic rest API does have support for createPlayist and updatePlaylist calls. I use these myself through the python API http://www.subsonic.org/pages/api.jsp#createPlaylist

let me know if I can help

midwan commented 7 years ago

Great, then at least we can proceed with the plugin's side of things. I'm currently a little busy with other projects, so it might take me a while to get back into this. If you feel like it, you can take a look as well (Pull requests are welcome!) until then.

midwan commented 5 years ago

Coming back to this after a long time (sorry!)... :)

I know how to implement this from Subsonic's side, but I don't have enough documentation from MusicBee's side. I've asked Steven on the forum there, to see if he can provide some more information. https://getmusicbee.com/forum/index.php?topic=1972.msg155207#msg155207

midwan commented 5 years ago

@andocromn Steven will be looking into this over the next few weeks, so we'll have to wait until there's support for it through MusicBee's API.

midwan commented 5 years ago

@andocromn This is now implemented in v2.26 with 5bb68ab62d222abca281bdb7831bbf29bc9b4e3e

Notes:

andocromn commented 5 years ago

@midwan Thank you for the continued work on this project. I've installed the updated versions however I'm not seeing the feature. How does it work?

midwan commented 5 years ago

@andocromn The idea is that you create a new playlist in MusicBee, and that gets saved in Subsonic as well. And if you delete one from MusicBee, it also gets deleted from Subsonic.

But this will work only with v3.3 of MusicBee as mentioned above, as previous versions didn't have the necessary hooks in the API.

andocromn commented 5 years ago

OK that time it worked. I was able to save the playlist in Musicbee and the playlist was created on the Subsonic server. It is not displayed under Subsonic in Musicbee, but I do see it in the web ui so I'm guessing this is just a matter of refresh so nbd.

The delete functionality works too, although it feels a bit wrinkly to delete from the Musicbee list and have it delete in Subsonic. as opposed to deleting from the Computer\Subsonic tree. This also limits it to only being able to delete playlists it created, right? Out of curiosity, how is it tracking the playlist associations? If I previously had playlists in Musicbee and Subsonic both named RockNRoll but otherwise distinct, would it delete both anyway?

Mostly just feedback / trivia. Overall great work and effective implementation, Thank you for the great work. I had just confused myself by looking for a specifically for a new control that would allow me to save to the server. Otherwise the user would normally just experience saving a playlist resulting in it being saved on the server, which is really cool

midwan commented 5 years ago

@andocromn The playlists are tracked by using their IDs, which is stored in one of the Custom fields in MusicBee. We could change the functionality of Delete, but then you wouldn't have any way of deleting a playlist from Subsonic, without going there and doing so manually... I thought it would make more sense to be able to delete a playlist you created, in both places.

andocromn commented 5 years ago

Sounds good to me. its great that MusicBee has those custom fields, thanks again