hasgeek / hasgeek.tv

Hasgeek TV
http://hasgeek.tv
16 stars 6 forks source link

Automatic playlist for all videos #60

Open jace opened 11 years ago

jace commented 11 years ago

Channels should have an automatic playlist named "stream"* (tentatively) where all videos are automatically added.

This playlist is created when you upload your first video to a channel. It's where your videos go if you don't pick a playlist to add them to (more on that below).

The Channel page now gets an "Add video" link which goes to /<channel>/new/stream, which provides the same New Video form and makes the stream playlist along with the video. The /new/stream URL rides on top of the new slug (which is not allowed in playlist names) without adding another reserved keyword. Using /stream/new will prevent stream from being renamed. HGTV allows automatic playlists to be renamed.

When a video is added to a playlist via the "Add Video" link, it is also added to the stream playlist.

User actions such as Like/Star/AddTo etc do not add videos to the stream. The stream is only for videos originally uploaded to each channel.

jace commented 11 years ago

@kracekumar, If you can fix the issues I've raised in the comments, we can close this.

jace commented 11 years ago

@kracekumar Is there any situation where the video will already be in the stream playlist, and doing a simple stream.videos.append(video) will cause a database unique constraint error?

kracekumar commented 11 years ago

@jace I tried this condition, it didn't create any issue. I have fixed all the issue, now my branch needs rework to merge.

kracekumar commented 11 years ago

@jace stream.videos.append(video) raises database unique constraint now !