mirror of https://github.com/Chocobozzz/PeerTube
Reload my videos after delete
parent
a00a8f09f9
commit
06be7ed0b2
|
@ -88,7 +88,8 @@ export class MyAccountVideosComponent extends AbstractVideoList implements OnIni
|
||||||
.subscribe(
|
.subscribe(
|
||||||
res => {
|
res => {
|
||||||
this.notificationsService.success('Success', `${toDeleteVideosIds.length} videos deleted.`)
|
this.notificationsService.success('Success', `${toDeleteVideosIds.length} videos deleted.`)
|
||||||
this.buildVideoPages()
|
this.abortSelectionMode()
|
||||||
|
this.reloadVideos()
|
||||||
},
|
},
|
||||||
|
|
||||||
err => this.notificationsService.error('Error', err.message)
|
err => this.notificationsService.error('Error', err.message)
|
||||||
|
@ -103,8 +104,7 @@ export class MyAccountVideosComponent extends AbstractVideoList implements OnIni
|
||||||
.subscribe(
|
.subscribe(
|
||||||
status => {
|
status => {
|
||||||
this.notificationsService.success('Success', `Video ${video.name} deleted.`)
|
this.notificationsService.success('Success', `Video ${video.name} deleted.`)
|
||||||
this.spliceVideosById(video.id)
|
this.reloadVideos()
|
||||||
this.buildVideoPages()
|
|
||||||
},
|
},
|
||||||
|
|
||||||
error => this.notificationsService.error('Error', error.message)
|
error => this.notificationsService.error('Error', error.message)
|
||||||
|
|
|
@ -5,7 +5,6 @@ import * as parseTorrent from 'parse-torrent'
|
||||||
import { join } from 'path'
|
import { join } from 'path'
|
||||||
import * as Sequelize from 'sequelize'
|
import * as Sequelize from 'sequelize'
|
||||||
import {
|
import {
|
||||||
AfterDestroy,
|
|
||||||
AllowNull,
|
AllowNull,
|
||||||
BeforeDestroy,
|
BeforeDestroy,
|
||||||
BelongsTo,
|
BelongsTo,
|
||||||
|
@ -32,7 +31,11 @@ import { Video, VideoDetails, VideoFile } from '../../../shared/models/videos'
|
||||||
import { VideoFilter } from '../../../shared/models/videos/video-query.type'
|
import { VideoFilter } from '../../../shared/models/videos/video-query.type'
|
||||||
import { activityPubCollection } from '../../helpers/activitypub'
|
import { activityPubCollection } from '../../helpers/activitypub'
|
||||||
import {
|
import {
|
||||||
createTorrentPromise, peertubeTruncate, renamePromise, statPromise, unlinkPromise,
|
createTorrentPromise,
|
||||||
|
peertubeTruncate,
|
||||||
|
renamePromise,
|
||||||
|
statPromise,
|
||||||
|
unlinkPromise,
|
||||||
writeFilePromise
|
writeFilePromise
|
||||||
} from '../../helpers/core-utils'
|
} from '../../helpers/core-utils'
|
||||||
import { isActivityPubUrlValid } from '../../helpers/custom-validators/activitypub/misc'
|
import { isActivityPubUrlValid } from '../../helpers/custom-validators/activitypub/misc'
|
||||||
|
|
Loading…
Reference in New Issue