1
0
Fork 0
mirror of https://github.com/Chocobozzz/PeerTube.git synced 2025-10-05 19:42:24 +02:00

Add comments controller

This commit is contained in:
Chocobozzz 2017-12-22 10:50:07 +01:00
parent 6d85247028
commit bf1f650817
No known key found for this signature in database
GPG key ID: 583A612D890159BE
11 changed files with 464 additions and 99 deletions

View file

@ -3,17 +3,18 @@ import { ActorModel } from '../../models/activitypub/actor'
import { ActorFollowModel } from '../../models/activitypub/actor-follow'
import { VideoModel } from '../../models/video/video'
import { VideoAbuseModel } from '../../models/video/video-abuse'
import { VideoCommentModel } from '../../models/video/video-comment'
function getVideoActivityPubUrl (video: VideoModel) {
return CONFIG.WEBSERVER.URL + '/videos/watch/' + video.uuid
}
function getVideoChannelActivityPubUrl (videoChannelUUID: string) {
return CONFIG.WEBSERVER.URL + '/video-channels/' + videoChannelUUID
function getVideoCommentActivityPubUrl (video: VideoModel, videoComment: VideoCommentModel) {
return CONFIG.WEBSERVER.URL + '/videos/watch/' + video.uuid + '#comment-' + videoComment.id
}
function getApplicationActivityPubUrl () {
return CONFIG.WEBSERVER.URL + '/application/peertube'
function getVideoChannelActivityPubUrl (videoChannelUUID: string) {
return CONFIG.WEBSERVER.URL + '/video-channels/' + videoChannelUUID
}
function getAccountActivityPubUrl (accountName: string) {
@ -63,7 +64,6 @@ function getUndoActivityPubUrl (originalUrl: string) {
}
export {
getApplicationActivityPubUrl,
getVideoActivityPubUrl,
getVideoChannelActivityPubUrl,
getAccountActivityPubUrl,
@ -75,5 +75,6 @@ export {
getUndoActivityPubUrl,
getVideoViewActivityPubUrl,
getVideoLikeActivityPubUrl,
getVideoDislikeActivityPubUrl
getVideoDislikeActivityPubUrl,
getVideoCommentActivityPubUrl
}