podverse-orm 5.0.0-beta.4 → 5.0.0-beta.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +4 -4
- package/dist/src/config/index.d.ts +0 -12
- package/dist/src/config/index.js +0 -15
- package/dist/src/db/index.d.ts +0 -2
- package/dist/src/db/index.js +0 -209
- package/dist/src/entities/account/account.d.ts +0 -8
- package/dist/src/entities/account/account.js +0 -47
- package/dist/src/entities/account/accountAdminRoles.d.ts +0 -7
- package/dist/src/entities/account/accountAdminRoles.js +0 -37
- package/dist/src/entities/account/accountAppStorePurchase.d.ts +0 -26
- package/dist/src/entities/account/accountAppStorePurchase.js +0 -113
- package/dist/src/entities/account/accountCredentials.d.ts +0 -7
- package/dist/src/entities/account/accountCredentials.js +0 -37
- package/dist/src/entities/account/accountFCMDevice.d.ts +0 -6
- package/dist/src/entities/account/accountFCMDevice.js +0 -33
- package/dist/src/entities/account/accountFollowingAccount.d.ts +0 -7
- package/dist/src/entities/account/accountFollowingAccount.js +0 -38
- package/dist/src/entities/account/accountFollowingAddByRSSChannel.d.ts +0 -8
- package/dist/src/entities/account/accountFollowingAddByRSSChannel.js +0 -41
- package/dist/src/entities/account/accountFollowingChannel.d.ts +0 -8
- package/dist/src/entities/account/accountFollowingChannel.js +0 -39
- package/dist/src/entities/account/accountFollowingPlaylist.d.ts +0 -8
- package/dist/src/entities/account/accountFollowingPlaylist.js +0 -39
- package/dist/src/entities/account/accountGooglePlayPurchase.d.ts +0 -14
- package/dist/src/entities/account/accountGooglePlayPurchase.js +0 -65
- package/dist/src/entities/account/accountMembership.d.ts +0 -4
- package/dist/src/entities/account/accountMembership.js +0 -27
- package/dist/src/entities/account/accountMembershipStatus.d.ts +0 -8
- package/dist/src/entities/account/accountMembershipStatus.js +0 -39
- package/dist/src/entities/account/accountNotification.d.ts +0 -8
- package/dist/src/entities/account/accountNotification.js +0 -39
- package/dist/src/entities/account/accountPayPalOrder.d.ts +0 -7
- package/dist/src/entities/account/accountPayPalOrder.js +0 -37
- package/dist/src/entities/account/accountProfile.d.ts +0 -7
- package/dist/src/entities/account/accountProfile.js +0 -37
- package/dist/src/entities/account/accountResetPassword.d.ts +0 -7
- package/dist/src/entities/account/accountResetPassword.js +0 -37
- package/dist/src/entities/account/accountUPDevice.d.ts +0 -8
- package/dist/src/entities/account/accountUPDevice.js +0 -41
- package/dist/src/entities/account/accountVerification.d.ts +0 -7
- package/dist/src/entities/account/accountVerification.js +0 -37
- package/dist/src/entities/category.d.ts +0 -6
- package/dist/src/entities/category.js +0 -35
- package/dist/src/entities/channel/channel.d.ts +0 -19
- package/dist/src/entities/channel/channel.js +0 -100
- package/dist/src/entities/channel/channelAbout.d.ts +0 -13
- package/dist/src/entities/channel/channelAbout.js +0 -59
- package/dist/src/entities/channel/channelCategory.d.ts +0 -6
- package/dist/src/entities/channel/channelCategory.js +0 -34
- package/dist/src/entities/channel/channelChat.d.ts +0 -9
- package/dist/src/entities/channel/channelChat.js +0 -45
- package/dist/src/entities/channel/channelDescription.d.ts +0 -6
- package/dist/src/entities/channel/channelDescription.js +0 -34
- package/dist/src/entities/channel/channelFunding.d.ts +0 -7
- package/dist/src/entities/channel/channelFunding.js +0 -37
- package/dist/src/entities/channel/channelImage.d.ts +0 -8
- package/dist/src/entities/channel/channelImage.js +0 -41
- package/dist/src/entities/channel/channelInternalSettings.d.ts +0 -6
- package/dist/src/entities/channel/channelInternalSettings.js +0 -33
- package/dist/src/entities/channel/channelItunesType.d.ts +0 -9
- package/dist/src/entities/channel/channelItunesType.js +0 -49
- package/dist/src/entities/channel/channelLicense.d.ts +0 -7
- package/dist/src/entities/channel/channelLicense.js +0 -38
- package/dist/src/entities/channel/channelLocation.d.ts +0 -8
- package/dist/src/entities/channel/channelLocation.js +0 -42
- package/dist/src/entities/channel/channelPerson.d.ts +0 -11
- package/dist/src/entities/channel/channelPerson.js +0 -64
- package/dist/src/entities/channel/channelPodroll.d.ts +0 -5
- package/dist/src/entities/channel/channelPodroll.js +0 -29
- package/dist/src/entities/channel/channelPodrollRemoteItem.d.ts +0 -9
- package/dist/src/entities/channel/channelPodrollRemoteItem.js +0 -45
- package/dist/src/entities/channel/channelPublisher.d.ts +0 -5
- package/dist/src/entities/channel/channelPublisher.js +0 -29
- package/dist/src/entities/channel/channelPublisherRemoteItem.d.ts +0 -9
- package/dist/src/entities/channel/channelPublisherRemoteItem.js +0 -45
- package/dist/src/entities/channel/channelRemoteItem.d.ts +0 -9
- package/dist/src/entities/channel/channelRemoteItem.js +0 -45
- package/dist/src/entities/channel/channelSeason.d.ts +0 -8
- package/dist/src/entities/channel/channelSeason.js +0 -42
- package/dist/src/entities/channel/channelSocialInteract.d.ts +0 -10
- package/dist/src/entities/channel/channelSocialInteract.js +0 -49
- package/dist/src/entities/channel/channelTrailer.d.ts +0 -12
- package/dist/src/entities/channel/channelTrailer.js +0 -55
- package/dist/src/entities/channel/channelTxt.d.ts +0 -7
- package/dist/src/entities/channel/channelTxt.js +0 -37
- package/dist/src/entities/channel/channelValue.d.ts +0 -8
- package/dist/src/entities/channel/channelValue.js +0 -41
- package/dist/src/entities/channel/channelValueRecipient.d.ts +0 -12
- package/dist/src/entities/channel/channelValueRecipient.js +0 -57
- package/dist/src/entities/clip.d.ts +0 -15
- package/dist/src/entities/clip.js +0 -71
- package/dist/src/entities/feed/feed.d.ts +0 -14
- package/dist/src/entities/feed/feed.js +0 -59
- package/dist/src/entities/feed/feedFlagStatus.d.ts +0 -14
- package/dist/src/entities/feed/feedFlagStatus.js +0 -52
- package/dist/src/entities/feed/feedLog.d.ts +0 -9
- package/dist/src/entities/feed/feedLog.js +0 -44
- package/dist/src/entities/item/item.d.ts +0 -18
- package/dist/src/entities/item/item.js +0 -82
- package/dist/src/entities/item/itemAbout.d.ts +0 -10
- package/dist/src/entities/item/itemAbout.js +0 -47
- package/dist/src/entities/item/itemChapter.d.ts +0 -13
- package/dist/src/entities/item/itemChapter.js +0 -67
- package/dist/src/entities/item/itemChapterLocation.d.ts +0 -8
- package/dist/src/entities/item/itemChapterLocation.js +0 -42
- package/dist/src/entities/item/itemChaptersFeed.d.ts +0 -9
- package/dist/src/entities/item/itemChaptersFeed.js +0 -42
- package/dist/src/entities/item/itemChaptersFeedLog.d.ts +0 -9
- package/dist/src/entities/item/itemChaptersFeedLog.js +0 -44
- package/dist/src/entities/item/itemChat.d.ts +0 -9
- package/dist/src/entities/item/itemChat.js +0 -45
- package/dist/src/entities/item/itemContentLink.d.ts +0 -7
- package/dist/src/entities/item/itemContentLink.js +0 -37
- package/dist/src/entities/item/itemDescription.d.ts +0 -6
- package/dist/src/entities/item/itemDescription.js +0 -34
- package/dist/src/entities/item/itemEnclosure.d.ts +0 -14
- package/dist/src/entities/item/itemEnclosure.js +0 -65
- package/dist/src/entities/item/itemEnclosureIntegrity.d.ts +0 -7
- package/dist/src/entities/item/itemEnclosureIntegrity.js +0 -37
- package/dist/src/entities/item/itemEnclosureSource.d.ts +0 -7
- package/dist/src/entities/item/itemEnclosureSource.js +0 -37
- package/dist/src/entities/item/itemFunding.d.ts +0 -7
- package/dist/src/entities/item/itemFunding.js +0 -37
- package/dist/src/entities/item/itemImage.d.ts +0 -8
- package/dist/src/entities/item/itemImage.js +0 -41
- package/dist/src/entities/item/itemItunesEpisodeType.d.ts +0 -10
- package/dist/src/entities/item/itemItunesEpisodeType.js +0 -48
- package/dist/src/entities/item/itemLicense.d.ts +0 -7
- package/dist/src/entities/item/itemLicense.js +0 -38
- package/dist/src/entities/item/itemLocation.d.ts +0 -8
- package/dist/src/entities/item/itemLocation.js +0 -42
- package/dist/src/entities/item/itemPerson.d.ts +0 -11
- package/dist/src/entities/item/itemPerson.js +0 -64
- package/dist/src/entities/item/itemSeason.d.ts +0 -9
- package/dist/src/entities/item/itemSeason.js +0 -43
- package/dist/src/entities/item/itemSeasonEpisode.d.ts +0 -7
- package/dist/src/entities/item/itemSeasonEpisode.js +0 -37
- package/dist/src/entities/item/itemSocialInteract.d.ts +0 -10
- package/dist/src/entities/item/itemSocialInteract.js +0 -49
- package/dist/src/entities/item/itemSoundbite.d.ts +0 -10
- package/dist/src/entities/item/itemSoundbite.js +0 -55
- package/dist/src/entities/item/itemTranscript.d.ts +0 -9
- package/dist/src/entities/item/itemTranscript.js +0 -45
- package/dist/src/entities/item/itemTxt.d.ts +0 -7
- package/dist/src/entities/item/itemTxt.js +0 -37
- package/dist/src/entities/item/itemValue.d.ts +0 -8
- package/dist/src/entities/item/itemValue.js +0 -41
- package/dist/src/entities/item/itemValueRecipient.d.ts +0 -12
- package/dist/src/entities/item/itemValueRecipient.js +0 -57
- package/dist/src/entities/item/itemValueTimeSplit.d.ts +0 -9
- package/dist/src/entities/item/itemValueTimeSplit.js +0 -45
- package/dist/src/entities/item/itemValueTimeSplitRecipient.d.ts +0 -12
- package/dist/src/entities/item/itemValueTimeSplitRecipient.js +0 -57
- package/dist/src/entities/item/itemValueTimeSplitRemoteItem.d.ts +0 -9
- package/dist/src/entities/item/itemValueTimeSplitRemoteItem.js +0 -45
- package/dist/src/entities/liveItem/liveItem.d.ts +0 -10
- package/dist/src/entities/liveItem/liveItem.js +0 -47
- package/dist/src/entities/liveItem/liveItemStatus.d.ts +0 -10
- package/dist/src/entities/liveItem/liveItemStatus.js +0 -43
- package/dist/src/entities/medium.d.ts +0 -26
- package/dist/src/entities/medium.js +0 -78
- package/dist/src/entities/membershipClaimToken.d.ts +0 -8
- package/dist/src/entities/membershipClaimToken.js +0 -41
- package/dist/src/entities/playlist/playlist.d.ts +0 -16
- package/dist/src/entities/playlist/playlist.js +0 -75
- package/dist/src/entities/playlist/playlistResourceBase.d.ts +0 -6
- package/dist/src/entities/playlist/playlistResourceBase.js +0 -34
- package/dist/src/entities/playlist/playlistResourceClip.d.ts +0 -5
- package/dist/src/entities/playlist/playlistResourceClip.js +0 -26
- package/dist/src/entities/playlist/playlistResourceItem.d.ts +0 -5
- package/dist/src/entities/playlist/playlistResourceItem.js +0 -26
- package/dist/src/entities/playlist/playlistResourceItemAddByRSS.d.ts +0 -4
- package/dist/src/entities/playlist/playlistResourceItemAddByRSS.js +0 -24
- package/dist/src/entities/playlist/playlistResourceItemChapter.d.ts +0 -5
- package/dist/src/entities/playlist/playlistResourceItemChapter.js +0 -26
- package/dist/src/entities/playlist/playlistResourceItemSoundbite.d.ts +0 -5
- package/dist/src/entities/playlist/playlistResourceItemSoundbite.js +0 -26
- package/dist/src/entities/queue/queue.d.ts +0 -7
- package/dist/src/entities/queue/queue.js +0 -35
- package/dist/src/entities/queue/queueResourceBase.d.ts +0 -9
- package/dist/src/entities/queue/queueResourceBase.js +0 -45
- package/dist/src/entities/queue/queueResourceClip.d.ts +0 -5
- package/dist/src/entities/queue/queueResourceClip.js +0 -27
- package/dist/src/entities/queue/queueResourceItem.d.ts +0 -5
- package/dist/src/entities/queue/queueResourceItem.js +0 -27
- package/dist/src/entities/queue/queueResourceItemAddByRSS.d.ts +0 -4
- package/dist/src/entities/queue/queueResourceItemAddByRSS.js +0 -25
- package/dist/src/entities/queue/queueResourceItemChapter.d.ts +0 -5
- package/dist/src/entities/queue/queueResourceItemChapter.js +0 -27
- package/dist/src/entities/queue/queueResourceItemSoundbite.d.ts +0 -5
- package/dist/src/entities/queue/queueResourceItemSoundbite.js +0 -27
- package/dist/src/entities/sharableStatus.d.ts +0 -4
- package/dist/src/entities/sharableStatus.js +0 -27
- package/dist/src/index.d.ts +0 -149
- package/dist/src/index.js +0 -165
- package/dist/src/lib/applyProperties.d.ts +0 -1
- package/dist/src/lib/applyProperties.js +0 -12
- package/dist/src/lib/filterImageDtosByHighestWidth.d.ts +0 -6
- package/dist/src/lib/filterImageDtosByHighestWidth.js +0 -17
- package/dist/src/lib/hasDifferentValues.d.ts +0 -1
- package/dist/src/lib/hasDifferentValues.js +0 -29
- package/dist/src/lib/typeORMTypes.d.ts +0 -2
- package/dist/src/lib/typeORMTypes.js +0 -5
- package/dist/src/services/base/baseManyService.d.ts +0 -17
- package/dist/src/services/base/baseManyService.js +0 -116
- package/dist/src/services/base/baseOneService.d.ts +0 -12
- package/dist/src/services/base/baseOneService.js +0 -55
- package/dist/src/services/base/baseRemoteItemsService.d.ts +0 -11
- package/dist/src/services/base/baseRemoteItemsService.js +0 -81
- package/dist/src/services/channel/channel.d.ts +0 -28
- package/dist/src/services/channel/channel.js +0 -58
- package/dist/src/services/channel/channelAbout.d.ts +0 -19
- package/dist/src/services/channel/channelAbout.js +0 -28
- package/dist/src/services/channel/channelChat.d.ts +0 -15
- package/dist/src/services/channel/channelChat.js +0 -28
- package/dist/src/services/channel/channelDescription.d.ts +0 -12
- package/dist/src/services/channel/channelDescription.js +0 -28
- package/dist/src/services/channel/channelFunding.d.ts +0 -14
- package/dist/src/services/channel/channelFunding.js +0 -38
- package/dist/src/services/channel/channelImage.d.ts +0 -14
- package/dist/src/services/channel/channelImage.js +0 -41
- package/dist/src/services/channel/channelLicense.d.ts +0 -13
- package/dist/src/services/channel/channelLicense.js +0 -28
- package/dist/src/services/channel/channelLocation.d.ts +0 -14
- package/dist/src/services/channel/channelLocation.js +0 -28
- package/dist/src/services/channel/channelPerson.d.ts +0 -17
- package/dist/src/services/channel/channelPerson.js +0 -38
- package/dist/src/services/channel/channelPodroll.d.ts +0 -10
- package/dist/src/services/channel/channelPodroll.js +0 -28
- package/dist/src/services/channel/channelPodrollRemoteItem.d.ts +0 -15
- package/dist/src/services/channel/channelPodrollRemoteItem.js +0 -36
- package/dist/src/services/channel/channelPublisher.d.ts +0 -9
- package/dist/src/services/channel/channelPublisher.js +0 -28
- package/dist/src/services/channel/channelPublisherRemoteItem.d.ts +0 -14
- package/dist/src/services/channel/channelPublisherRemoteItem.js +0 -36
- package/dist/src/services/channel/channelRemoteItem.d.ts +0 -15
- package/dist/src/services/channel/channelRemoteItem.js +0 -36
- package/dist/src/services/channel/channelSeason.d.ts +0 -15
- package/dist/src/services/channel/channelSeason.js +0 -48
- package/dist/src/services/channel/channelSocialInteract.d.ts +0 -17
- package/dist/src/services/channel/channelSocialInteract.js +0 -38
- package/dist/src/services/channel/channelTrailer.d.ts +0 -18
- package/dist/src/services/channel/channelTrailer.js +0 -38
- package/dist/src/services/channel/channelTxt.d.ts +0 -14
- package/dist/src/services/channel/channelTxt.js +0 -38
- package/dist/src/services/channel/channelValue.d.ts +0 -15
- package/dist/src/services/channel/channelValue.js +0 -38
- package/dist/src/services/channel/channelValueRecipient.d.ts +0 -19
- package/dist/src/services/channel/channelValueRecipient.js +0 -38
- package/dist/src/services/feed/feed.d.ts +0 -23
- package/dist/src/services/feed/feed.js +0 -92
- package/dist/src/services/feed/feedFlagStatus.d.ts +0 -5
- package/dist/src/services/feed/feedFlagStatus.js +0 -27
- package/dist/src/services/feed/feedLog.d.ts +0 -14
- package/dist/src/services/feed/feedLog.js +0 -28
- package/dist/src/services/item/item.d.ts +0 -28
- package/dist/src/services/item/item.js +0 -113
- package/dist/src/services/item/itemAbout.d.ts +0 -16
- package/dist/src/services/item/itemAbout.js +0 -28
- package/dist/src/services/item/itemChapter.d.ts +0 -16
- package/dist/src/services/item/itemChapter.js +0 -45
- package/dist/src/services/item/itemChaptersFeed.d.ts +0 -13
- package/dist/src/services/item/itemChaptersFeed.js +0 -28
- package/dist/src/services/item/itemChaptersFeedLog.d.ts +0 -14
- package/dist/src/services/item/itemChaptersFeedLog.js +0 -28
- package/dist/src/services/item/itemChat.d.ts +0 -15
- package/dist/src/services/item/itemChat.js +0 -28
- package/dist/src/services/item/itemContentLink.d.ts +0 -13
- package/dist/src/services/item/itemContentLink.js +0 -38
- package/dist/src/services/item/itemDescription.d.ts +0 -12
- package/dist/src/services/item/itemDescription.js +0 -28
- package/dist/src/services/item/itemEnclosure.d.ts +0 -21
- package/dist/src/services/item/itemEnclosure.js +0 -38
- package/dist/src/services/item/itemEnclosureIntegrity.d.ts +0 -13
- package/dist/src/services/item/itemEnclosureIntegrity.js +0 -28
- package/dist/src/services/item/itemEnclosureSource.d.ts +0 -14
- package/dist/src/services/item/itemEnclosureSource.js +0 -38
- package/dist/src/services/item/itemFunding.d.ts +0 -13
- package/dist/src/services/item/itemFunding.js +0 -38
- package/dist/src/services/item/itemImage.d.ts +0 -14
- package/dist/src/services/item/itemImage.js +0 -41
- package/dist/src/services/item/itemLicense.d.ts +0 -13
- package/dist/src/services/item/itemLicense.js +0 -28
- package/dist/src/services/item/itemLocation.d.ts +0 -14
- package/dist/src/services/item/itemLocation.js +0 -28
- package/dist/src/services/item/itemPerson.d.ts +0 -17
- package/dist/src/services/item/itemPerson.js +0 -38
- package/dist/src/services/item/itemSeason.d.ts +0 -13
- package/dist/src/services/item/itemSeason.js +0 -28
- package/dist/src/services/item/itemSeasonEpisode.d.ts +0 -13
- package/dist/src/services/item/itemSeasonEpisode.js +0 -28
- package/dist/src/services/item/itemSocialInteract.d.ts +0 -17
- package/dist/src/services/item/itemSocialInteract.js +0 -38
- package/dist/src/services/item/itemSoundbite.d.ts +0 -16
- package/dist/src/services/item/itemSoundbite.js +0 -43
- package/dist/src/services/item/itemTranscript.d.ts +0 -14
- package/dist/src/services/item/itemTranscript.js +0 -38
- package/dist/src/services/item/itemTxt.d.ts +0 -14
- package/dist/src/services/item/itemTxt.js +0 -38
- package/dist/src/services/item/itemValue.d.ts +0 -15
- package/dist/src/services/item/itemValue.js +0 -38
- package/dist/src/services/item/itemValueRecipient.d.ts +0 -19
- package/dist/src/services/item/itemValueRecipient.js +0 -38
- package/dist/src/services/item/itemValueTimeSplit.d.ts +0 -16
- package/dist/src/services/item/itemValueTimeSplit.js +0 -38
- package/dist/src/services/item/itemValueTimeSplitRecipient.d.ts +0 -19
- package/dist/src/services/item/itemValueTimeSplitRecipient.js +0 -38
- package/dist/src/services/item/itemValueTimeSplitRemoteItem.d.ts +0 -14
- package/dist/src/services/item/itemValueTimeSplitRemoteItem.js +0 -28
- package/dist/src/services/liveItem/liveItem.d.ts +0 -14
- package/dist/src/services/liveItem/liveItem.js +0 -28
- package/dist/src/services/medium.d.ts +0 -5
- package/dist/src/services/medium.js +0 -25
package/dist/src/index.js
DELETED
|
@@ -1,165 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
-
};
|
|
16
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./config"), exports);
|
|
18
|
-
__exportStar(require("./db"), exports);
|
|
19
|
-
__exportStar(require("./entities/account/account"), exports);
|
|
20
|
-
__exportStar(require("./entities/account/accountAdminRoles"), exports);
|
|
21
|
-
__exportStar(require("./entities/account/accountAppStorePurchase"), exports);
|
|
22
|
-
__exportStar(require("./entities/account/accountCredentials"), exports);
|
|
23
|
-
__exportStar(require("./entities/account/accountFCMDevice"), exports);
|
|
24
|
-
__exportStar(require("./entities/account/accountFollowingAccount"), exports);
|
|
25
|
-
__exportStar(require("./entities/account/accountFollowingAddByRSSChannel"), exports);
|
|
26
|
-
__exportStar(require("./entities/account/accountFollowingChannel"), exports);
|
|
27
|
-
__exportStar(require("./entities/account/accountFollowingPlaylist"), exports);
|
|
28
|
-
__exportStar(require("./entities/account/accountGooglePlayPurchase"), exports);
|
|
29
|
-
__exportStar(require("./entities/account/accountMembership"), exports);
|
|
30
|
-
__exportStar(require("./entities/account/accountMembershipStatus"), exports);
|
|
31
|
-
__exportStar(require("./entities/account/accountNotification"), exports);
|
|
32
|
-
__exportStar(require("./entities/account/accountPayPalOrder"), exports);
|
|
33
|
-
__exportStar(require("./entities/account/accountProfile"), exports);
|
|
34
|
-
__exportStar(require("./entities/account/accountResetPassword"), exports);
|
|
35
|
-
__exportStar(require("./entities/account/accountUPDevice"), exports);
|
|
36
|
-
__exportStar(require("./entities/account/accountVerification"), exports);
|
|
37
|
-
__exportStar(require("./entities/channel/channel"), exports);
|
|
38
|
-
__exportStar(require("./entities/channel/channelAbout"), exports);
|
|
39
|
-
__exportStar(require("./entities/channel/channelCategory"), exports);
|
|
40
|
-
__exportStar(require("./entities/channel/channelChat"), exports);
|
|
41
|
-
__exportStar(require("./entities/channel/channelDescription"), exports);
|
|
42
|
-
__exportStar(require("./entities/channel/channelFunding"), exports);
|
|
43
|
-
__exportStar(require("./entities/channel/channelImage"), exports);
|
|
44
|
-
__exportStar(require("./entities/channel/channelInternalSettings"), exports);
|
|
45
|
-
__exportStar(require("./entities/channel/channelItunesType"), exports);
|
|
46
|
-
__exportStar(require("./entities/channel/channelLicense"), exports);
|
|
47
|
-
__exportStar(require("./entities/channel/channelLocation"), exports);
|
|
48
|
-
__exportStar(require("./entities/channel/channelPerson"), exports);
|
|
49
|
-
__exportStar(require("./entities/channel/channelPodroll"), exports);
|
|
50
|
-
__exportStar(require("./entities/channel/channelPodrollRemoteItem"), exports);
|
|
51
|
-
__exportStar(require("./entities/channel/channelPublisher"), exports);
|
|
52
|
-
__exportStar(require("./entities/channel/channelPublisherRemoteItem"), exports);
|
|
53
|
-
__exportStar(require("./entities/channel/channelRemoteItem"), exports);
|
|
54
|
-
__exportStar(require("./entities/channel/channelSeason"), exports);
|
|
55
|
-
__exportStar(require("./entities/channel/channelSocialInteract"), exports);
|
|
56
|
-
__exportStar(require("./entities/channel/channelTrailer"), exports);
|
|
57
|
-
__exportStar(require("./entities/channel/channelTxt"), exports);
|
|
58
|
-
__exportStar(require("./entities/channel/channelValue"), exports);
|
|
59
|
-
__exportStar(require("./entities/channel/channelValueRecipient"), exports);
|
|
60
|
-
__exportStar(require("./entities/feed/feed"), exports);
|
|
61
|
-
__exportStar(require("./entities/feed/feedFlagStatus"), exports);
|
|
62
|
-
__exportStar(require("./entities/feed/feedLog"), exports);
|
|
63
|
-
__exportStar(require("./entities/item/item"), exports);
|
|
64
|
-
__exportStar(require("./entities/item/itemAbout"), exports);
|
|
65
|
-
__exportStar(require("./entities/item/itemChapter"), exports);
|
|
66
|
-
__exportStar(require("./entities/item/itemChapterLocation"), exports);
|
|
67
|
-
__exportStar(require("./entities/item/itemChaptersFeed"), exports);
|
|
68
|
-
__exportStar(require("./entities/item/itemChaptersFeedLog"), exports);
|
|
69
|
-
__exportStar(require("./entities/item/itemChat"), exports);
|
|
70
|
-
__exportStar(require("./entities/item/itemContentLink"), exports);
|
|
71
|
-
__exportStar(require("./entities/item/itemDescription"), exports);
|
|
72
|
-
__exportStar(require("./entities/item/itemEnclosure"), exports);
|
|
73
|
-
__exportStar(require("./entities/item/itemEnclosureIntegrity"), exports);
|
|
74
|
-
__exportStar(require("./entities/item/itemEnclosureSource"), exports);
|
|
75
|
-
__exportStar(require("./entities/item/itemFunding"), exports);
|
|
76
|
-
__exportStar(require("./entities/item/itemImage"), exports);
|
|
77
|
-
__exportStar(require("./entities/item/itemItunesEpisodeType"), exports);
|
|
78
|
-
__exportStar(require("./entities/item/itemLicense"), exports);
|
|
79
|
-
__exportStar(require("./entities/item/itemLocation"), exports);
|
|
80
|
-
__exportStar(require("./entities/item/itemPerson"), exports);
|
|
81
|
-
__exportStar(require("./entities/item/itemSeason"), exports);
|
|
82
|
-
__exportStar(require("./entities/item/itemSeasonEpisode"), exports);
|
|
83
|
-
__exportStar(require("./entities/item/itemSocialInteract"), exports);
|
|
84
|
-
__exportStar(require("./entities/item/itemSoundbite"), exports);
|
|
85
|
-
__exportStar(require("./entities/item/itemTranscript"), exports);
|
|
86
|
-
__exportStar(require("./entities/item/itemTxt"), exports);
|
|
87
|
-
__exportStar(require("./entities/item/itemValue"), exports);
|
|
88
|
-
__exportStar(require("./entities/item/itemValueRecipient"), exports);
|
|
89
|
-
__exportStar(require("./entities/item/itemValueTimeSplit"), exports);
|
|
90
|
-
__exportStar(require("./entities/item/itemValueTimeSplitRecipient"), exports);
|
|
91
|
-
__exportStar(require("./entities/item/itemValueTimeSplitRemoteItem"), exports);
|
|
92
|
-
__exportStar(require("./entities/liveItem/liveItem"), exports);
|
|
93
|
-
__exportStar(require("./entities/liveItem/liveItemStatus"), exports);
|
|
94
|
-
__exportStar(require("./entities/playlist/playlist"), exports);
|
|
95
|
-
__exportStar(require("./entities/playlist/playlistResourceBase"), exports);
|
|
96
|
-
__exportStar(require("./entities/playlist/playlistResourceClip"), exports);
|
|
97
|
-
__exportStar(require("./entities/playlist/playlistResourceItem"), exports);
|
|
98
|
-
__exportStar(require("./entities/playlist/playlistResourceItemAddByRSS"), exports);
|
|
99
|
-
__exportStar(require("./entities/playlist/playlistResourceItemChapter"), exports);
|
|
100
|
-
__exportStar(require("./entities/playlist/playlistResourceItemSoundbite"), exports);
|
|
101
|
-
__exportStar(require("./entities/queue/queue"), exports);
|
|
102
|
-
__exportStar(require("./entities/queue/queueResourceBase"), exports);
|
|
103
|
-
__exportStar(require("./entities/queue/queueResourceClip"), exports);
|
|
104
|
-
__exportStar(require("./entities/queue/queueResourceItem"), exports);
|
|
105
|
-
__exportStar(require("./entities/queue/queueResourceItemAddByRSS"), exports);
|
|
106
|
-
__exportStar(require("./entities/queue/queueResourceItemChapter"), exports);
|
|
107
|
-
__exportStar(require("./entities/queue/queueResourceItemSoundbite"), exports);
|
|
108
|
-
__exportStar(require("./entities/category"), exports);
|
|
109
|
-
__exportStar(require("./entities/clip"), exports);
|
|
110
|
-
__exportStar(require("./entities/medium"), exports);
|
|
111
|
-
__exportStar(require("./entities/membershipClaimToken"), exports);
|
|
112
|
-
__exportStar(require("./entities/sharableStatus"), exports);
|
|
113
|
-
__exportStar(require("./lib/typeORMTypes"), exports);
|
|
114
|
-
__exportStar(require("./services/channel/channel"), exports);
|
|
115
|
-
__exportStar(require("./services/channel/channelAbout"), exports);
|
|
116
|
-
__exportStar(require("./services/channel/channelChat"), exports);
|
|
117
|
-
__exportStar(require("./services/channel/channelDescription"), exports);
|
|
118
|
-
__exportStar(require("./services/channel/channelFunding"), exports);
|
|
119
|
-
__exportStar(require("./services/channel/channelImage"), exports);
|
|
120
|
-
__exportStar(require("./services/channel/channelLicense"), exports);
|
|
121
|
-
__exportStar(require("./services/channel/channelLocation"), exports);
|
|
122
|
-
__exportStar(require("./services/channel/channelPerson"), exports);
|
|
123
|
-
__exportStar(require("./services/channel/channelPodroll"), exports);
|
|
124
|
-
__exportStar(require("./services/channel/channelPodrollRemoteItem"), exports);
|
|
125
|
-
__exportStar(require("./services/channel/channelPublisher"), exports);
|
|
126
|
-
__exportStar(require("./services/channel/channelPublisherRemoteItem"), exports);
|
|
127
|
-
__exportStar(require("./services/channel/channelRemoteItem"), exports);
|
|
128
|
-
__exportStar(require("./services/channel/channelSeason"), exports);
|
|
129
|
-
__exportStar(require("./services/channel/channelSocialInteract"), exports);
|
|
130
|
-
__exportStar(require("./services/channel/channelTrailer"), exports);
|
|
131
|
-
__exportStar(require("./services/channel/channelTxt"), exports);
|
|
132
|
-
__exportStar(require("./services/channel/channelValue"), exports);
|
|
133
|
-
__exportStar(require("./services/channel/channelValueRecipient"), exports);
|
|
134
|
-
__exportStar(require("./services/feed/feed"), exports);
|
|
135
|
-
__exportStar(require("./services/feed/feedFlagStatus"), exports);
|
|
136
|
-
__exportStar(require("./services/feed/feedLog"), exports);
|
|
137
|
-
__exportStar(require("./services/item/item"), exports);
|
|
138
|
-
__exportStar(require("./services/item/itemAbout"), exports);
|
|
139
|
-
__exportStar(require("./services/item/itemChapter"), exports);
|
|
140
|
-
__exportStar(require("./services/item/itemChaptersFeed"), exports);
|
|
141
|
-
__exportStar(require("./services/item/itemChaptersFeedLog"), exports);
|
|
142
|
-
__exportStar(require("./services/item/itemChat"), exports);
|
|
143
|
-
__exportStar(require("./services/item/itemContentLink"), exports);
|
|
144
|
-
__exportStar(require("./services/item/itemDescription"), exports);
|
|
145
|
-
__exportStar(require("./services/item/itemEnclosure"), exports);
|
|
146
|
-
__exportStar(require("./services/item/itemEnclosureIntegrity"), exports);
|
|
147
|
-
__exportStar(require("./services/item/itemEnclosureSource"), exports);
|
|
148
|
-
__exportStar(require("./services/item/itemFunding"), exports);
|
|
149
|
-
__exportStar(require("./services/item/itemImage"), exports);
|
|
150
|
-
__exportStar(require("./services/item/itemLicense"), exports);
|
|
151
|
-
__exportStar(require("./services/item/itemLocation"), exports);
|
|
152
|
-
__exportStar(require("./services/item/itemPerson"), exports);
|
|
153
|
-
__exportStar(require("./services/item/itemSeason"), exports);
|
|
154
|
-
__exportStar(require("./services/item/itemSeasonEpisode"), exports);
|
|
155
|
-
__exportStar(require("./services/item/itemSocialInteract"), exports);
|
|
156
|
-
__exportStar(require("./services/item/itemSoundbite"), exports);
|
|
157
|
-
__exportStar(require("./services/item/itemTranscript"), exports);
|
|
158
|
-
__exportStar(require("./services/item/itemTxt"), exports);
|
|
159
|
-
__exportStar(require("./services/item/itemValue"), exports);
|
|
160
|
-
__exportStar(require("./services/item/itemValueRecipient"), exports);
|
|
161
|
-
__exportStar(require("./services/item/itemValueTimeSplit"), exports);
|
|
162
|
-
__exportStar(require("./services/item/itemValueTimeSplitRecipient"), exports);
|
|
163
|
-
__exportStar(require("./services/item/itemValueTimeSplitRemoteItem"), exports);
|
|
164
|
-
__exportStar(require("./services/liveItem/liveItem"), exports);
|
|
165
|
-
__exportStar(require("./services/medium"), exports);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function applyProperties<T>(target: T, source: Partial<T>): T;
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.applyProperties = applyProperties;
|
|
4
|
-
function applyProperties(target, source) {
|
|
5
|
-
Object.keys(source).forEach(key => {
|
|
6
|
-
const value = source[key];
|
|
7
|
-
if (value !== undefined) {
|
|
8
|
-
target[key] = value;
|
|
9
|
-
}
|
|
10
|
-
});
|
|
11
|
-
return target;
|
|
12
|
-
}
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.filterDtosByHighestWidth = filterDtosByHighestWidth;
|
|
4
|
-
function filterDtosByHighestWidth(dtos) {
|
|
5
|
-
const dtoMap = new Map();
|
|
6
|
-
for (const dto of dtos) {
|
|
7
|
-
if (!dto.url)
|
|
8
|
-
continue;
|
|
9
|
-
const existingDto = dtoMap.get(dto.url);
|
|
10
|
-
if (!existingDto ||
|
|
11
|
-
(dto.image_width_size !== undefined && dto.image_width_size !== null &&
|
|
12
|
-
(existingDto.image_width_size === null || dto.image_width_size > existingDto.image_width_size))) {
|
|
13
|
-
dtoMap.set(dto.url, dto);
|
|
14
|
-
}
|
|
15
|
-
}
|
|
16
|
-
return Array.from(dtoMap.values());
|
|
17
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function hasDifferentValues<T>(entity: T, dto: Partial<T>): boolean;
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.hasDifferentValues = hasDifferentValues;
|
|
4
|
-
function hasDifferentValues(entity, dto) {
|
|
5
|
-
return Object.keys(dto).some(key => {
|
|
6
|
-
const entityValue = entity[key];
|
|
7
|
-
const dtoValue = dto[key];
|
|
8
|
-
const normalizedEntityValue = isNumeric(entityValue) ? Number(entityValue) : entityValue;
|
|
9
|
-
const normalizedDtoValue = isNumeric(dtoValue) ? Number(dtoValue) : dtoValue;
|
|
10
|
-
if (isObjectWithId(normalizedEntityValue) && isNumeric(normalizedDtoValue)) {
|
|
11
|
-
return normalizedEntityValue.id !== normalizedDtoValue;
|
|
12
|
-
}
|
|
13
|
-
if (isObjectWithId(dtoValue) && isNumeric(normalizedEntityValue)) {
|
|
14
|
-
return dtoValue.id !== normalizedEntityValue;
|
|
15
|
-
}
|
|
16
|
-
if (isObjectWithId(normalizedEntityValue) && isObjectWithId(normalizedDtoValue)) {
|
|
17
|
-
return normalizedEntityValue.id !== normalizedDtoValue.id;
|
|
18
|
-
}
|
|
19
|
-
return normalizedEntityValue !== normalizedDtoValue;
|
|
20
|
-
});
|
|
21
|
-
}
|
|
22
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
23
|
-
function isNumeric(value) {
|
|
24
|
-
return !isNaN(value) && value !== null && value !== '';
|
|
25
|
-
}
|
|
26
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
27
|
-
function isObjectWithId(value) {
|
|
28
|
-
return value && typeof value === 'object' && 'id' in value;
|
|
29
|
-
}
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.EntityManager = void 0;
|
|
4
|
-
const typeorm_1 = require("typeorm");
|
|
5
|
-
Object.defineProperty(exports, "EntityManager", { enumerable: true, get: function () { return typeorm_1.EntityManager; } });
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import { EntityManager, FindManyOptions, FindOneOptions, ObjectLiteral, Repository } from "typeorm";
|
|
2
|
-
export declare class BaseManyService<T extends ObjectLiteral, K extends keyof T> {
|
|
3
|
-
protected repository: Repository<T>;
|
|
4
|
-
protected parentEntityKey: K;
|
|
5
|
-
protected targetEntity: {
|
|
6
|
-
new (): T;
|
|
7
|
-
};
|
|
8
|
-
private transactionalEntityManager?;
|
|
9
|
-
constructor(targetEntity: {
|
|
10
|
-
new (): T;
|
|
11
|
-
}, parentEntityKey: K, transactionalEntityManager?: EntityManager);
|
|
12
|
-
_getAll(parentEntity: T[K], config?: FindManyOptions<T>): Promise<T[]>;
|
|
13
|
-
_get(parentEntity: T[K], whereKeyValues: Record<string, unknown>, config?: FindOneOptions<T>): Promise<T | null>;
|
|
14
|
-
_update(parentEntity: T[K], whereKeys: (keyof T)[], dto: Partial<T>, config?: FindOneOptions<T>, existingEntity?: T): Promise<T>;
|
|
15
|
-
_updateMany(parentEntity: T[K], whereKeys: (keyof T)[], dtos: Partial<T>[], config?: FindOneOptions<T>): Promise<T[]>;
|
|
16
|
-
_deleteAll(value: T[K]): Promise<void>;
|
|
17
|
-
}
|
|
@@ -1,116 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
-
});
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.BaseManyService = void 0;
|
|
13
|
-
const podverse_helpers_1 = require("podverse-helpers");
|
|
14
|
-
const db_1 = require("@/db");
|
|
15
|
-
const applyProperties_1 = require("@/lib/applyProperties");
|
|
16
|
-
const hasDifferentValues_1 = require("@/lib/hasDifferentValues");
|
|
17
|
-
class BaseManyService {
|
|
18
|
-
constructor(targetEntity, parentEntityKey, transactionalEntityManager) {
|
|
19
|
-
this.targetEntity = targetEntity;
|
|
20
|
-
this.parentEntityKey = parentEntityKey;
|
|
21
|
-
this.repository = db_1.AppDataSource.getRepository(targetEntity);
|
|
22
|
-
this.transactionalEntityManager = transactionalEntityManager;
|
|
23
|
-
}
|
|
24
|
-
_getAll(parentEntity, config) {
|
|
25
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
26
|
-
const where = { [this.parentEntityKey]: parentEntity };
|
|
27
|
-
return this.repository.find(Object.assign({ where }, config));
|
|
28
|
-
});
|
|
29
|
-
}
|
|
30
|
-
_get(parentEntity, whereKeyValues, config) {
|
|
31
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
32
|
-
const where = Object.assign({ [this.parentEntityKey]: parentEntity }, whereKeyValues);
|
|
33
|
-
return this.repository.findOne(Object.assign({ where }, config));
|
|
34
|
-
});
|
|
35
|
-
}
|
|
36
|
-
_update(parentEntity, whereKeys, dto, config, existingEntity) {
|
|
37
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
38
|
-
var _a;
|
|
39
|
-
const whereObject = {};
|
|
40
|
-
whereKeys.forEach(key => {
|
|
41
|
-
if (key in dto) {
|
|
42
|
-
whereObject[key] = dto[key];
|
|
43
|
-
}
|
|
44
|
-
});
|
|
45
|
-
let entity = existingEntity || null;
|
|
46
|
-
if (!entity) {
|
|
47
|
-
entity = yield this._get(parentEntity, whereObject, config);
|
|
48
|
-
}
|
|
49
|
-
if (!entity) {
|
|
50
|
-
entity = new this.targetEntity();
|
|
51
|
-
entity[this.parentEntityKey] = parentEntity;
|
|
52
|
-
}
|
|
53
|
-
else if (!(0, hasDifferentValues_1.hasDifferentValues)(entity, dto)) {
|
|
54
|
-
return entity;
|
|
55
|
-
}
|
|
56
|
-
entity = (0, applyProperties_1.applyProperties)(entity, dto);
|
|
57
|
-
podverse_helpers_1.logger.debug(`Updating entity ${JSON.stringify(entity)}`);
|
|
58
|
-
podverse_helpers_1.logger.debug(`With DTO ${JSON.stringify(dto)}`);
|
|
59
|
-
return ((_a = this.transactionalEntityManager) !== null && _a !== void 0 ? _a : this.repository).save(entity);
|
|
60
|
-
});
|
|
61
|
-
}
|
|
62
|
-
_updateMany(parentEntity, whereKeys, dtos, config) {
|
|
63
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
64
|
-
var _a, _b;
|
|
65
|
-
const existingEntities = yield this._getAll(parentEntity);
|
|
66
|
-
const existingIdentifiers = dtos.map((dto) => {
|
|
67
|
-
let identifier = {};
|
|
68
|
-
for (const whereKey of whereKeys) {
|
|
69
|
-
identifier[whereKey] = dto[whereKey];
|
|
70
|
-
}
|
|
71
|
-
return identifier;
|
|
72
|
-
});
|
|
73
|
-
const updatedEntities = [];
|
|
74
|
-
// This prevents entries with duplicate unique constraint values
|
|
75
|
-
// from attempting to be saved (which would cause a whole transaction to rollback).
|
|
76
|
-
const uniqueIdentifiers = new Set();
|
|
77
|
-
const uniqueDtos = dtos.filter(dto => {
|
|
78
|
-
const identifier = whereKeys.map(key => dto[key]).join('|');
|
|
79
|
-
if (uniqueIdentifiers.has(identifier)) {
|
|
80
|
-
return false;
|
|
81
|
-
}
|
|
82
|
-
else {
|
|
83
|
-
uniqueIdentifiers.add(identifier);
|
|
84
|
-
return true;
|
|
85
|
-
}
|
|
86
|
-
});
|
|
87
|
-
for (const uniqueDto of uniqueDtos) {
|
|
88
|
-
const matchingEntity = existingEntities.find(entity => whereKeys.every(key => entity[key] === uniqueDto[key]));
|
|
89
|
-
const updatedEntity = yield this._update(parentEntity, whereKeys, uniqueDto, config, matchingEntity);
|
|
90
|
-
updatedEntities.push(updatedEntity);
|
|
91
|
-
}
|
|
92
|
-
yield ((_a = this.transactionalEntityManager) !== null && _a !== void 0 ? _a : this.repository).save(updatedEntities);
|
|
93
|
-
const entitiesToDelete = existingEntities.filter(existingEntity => {
|
|
94
|
-
let identifier = {};
|
|
95
|
-
for (const whereKey of whereKeys) {
|
|
96
|
-
identifier[whereKey] = existingEntity[whereKey];
|
|
97
|
-
}
|
|
98
|
-
return !existingIdentifiers.some(existingIdentifier => JSON.stringify(existingIdentifier) === JSON.stringify(identifier));
|
|
99
|
-
});
|
|
100
|
-
if (entitiesToDelete.length > 0) {
|
|
101
|
-
yield ((_b = this.transactionalEntityManager) !== null && _b !== void 0 ? _b : this.repository).remove(entitiesToDelete);
|
|
102
|
-
}
|
|
103
|
-
return updatedEntities;
|
|
104
|
-
});
|
|
105
|
-
}
|
|
106
|
-
_deleteAll(value) {
|
|
107
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
108
|
-
var _a;
|
|
109
|
-
const rowsToDelete = yield this._getAll(value);
|
|
110
|
-
if (rowsToDelete) {
|
|
111
|
-
yield ((_a = this.transactionalEntityManager) !== null && _a !== void 0 ? _a : this.repository).remove(rowsToDelete);
|
|
112
|
-
}
|
|
113
|
-
});
|
|
114
|
-
}
|
|
115
|
-
}
|
|
116
|
-
exports.BaseManyService = BaseManyService;
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { EntityManager, FindOneOptions, ObjectLiteral, Repository } from "typeorm";
|
|
2
|
-
export declare class BaseOneService<T extends ObjectLiteral, K extends keyof T> {
|
|
3
|
-
private parentEntityKey;
|
|
4
|
-
protected repository: Repository<T>;
|
|
5
|
-
private transactionalEntityManager?;
|
|
6
|
-
constructor(entity: {
|
|
7
|
-
new (): T;
|
|
8
|
-
}, parentEntityKey: K, transactionalEntityManager?: EntityManager);
|
|
9
|
-
_get(parentEntity: T[K], config?: FindOneOptions<T>): Promise<T | null>;
|
|
10
|
-
_update(parentEntity: T[K], dto: Partial<T>, config?: FindOneOptions<T>): Promise<T>;
|
|
11
|
-
_delete(parentEntity: T[K]): Promise<void>;
|
|
12
|
-
}
|
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
-
});
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.BaseOneService = void 0;
|
|
13
|
-
const podverse_helpers_1 = require("podverse-helpers");
|
|
14
|
-
const db_1 = require("@/db");
|
|
15
|
-
const applyProperties_1 = require("@/lib/applyProperties");
|
|
16
|
-
const hasDifferentValues_1 = require("@/lib/hasDifferentValues");
|
|
17
|
-
class BaseOneService {
|
|
18
|
-
constructor(entity, parentEntityKey, transactionalEntityManager) {
|
|
19
|
-
this.parentEntityKey = parentEntityKey;
|
|
20
|
-
this.repository = db_1.AppDataSource.getRepository(entity);
|
|
21
|
-
this.transactionalEntityManager = transactionalEntityManager;
|
|
22
|
-
}
|
|
23
|
-
_get(parentEntity, config) {
|
|
24
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
25
|
-
const where = { [this.parentEntityKey]: parentEntity };
|
|
26
|
-
return this.repository.findOne(Object.assign({ where }, config));
|
|
27
|
-
});
|
|
28
|
-
}
|
|
29
|
-
_update(parentEntity, dto, config) {
|
|
30
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
31
|
-
var _a;
|
|
32
|
-
let entity = yield this._get(parentEntity, config);
|
|
33
|
-
if (!entity) {
|
|
34
|
-
entity = new this.repository.target();
|
|
35
|
-
entity[this.parentEntityKey] = parentEntity;
|
|
36
|
-
}
|
|
37
|
-
else if (!(0, hasDifferentValues_1.hasDifferentValues)(entity, dto)) {
|
|
38
|
-
return entity;
|
|
39
|
-
}
|
|
40
|
-
entity = (0, applyProperties_1.applyProperties)(entity, dto);
|
|
41
|
-
podverse_helpers_1.logger.debug(`Updating entity ${JSON.stringify(entity)}`);
|
|
42
|
-
podverse_helpers_1.logger.debug(`With DTO ${JSON.stringify(dto)}`);
|
|
43
|
-
return ((_a = this.transactionalEntityManager) !== null && _a !== void 0 ? _a : this.repository).save(entity);
|
|
44
|
-
});
|
|
45
|
-
}
|
|
46
|
-
_delete(parentEntity) {
|
|
47
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
48
|
-
const rowToDelete = yield this._get(parentEntity);
|
|
49
|
-
if (rowToDelete) {
|
|
50
|
-
yield this.repository.remove(rowToDelete);
|
|
51
|
-
}
|
|
52
|
-
});
|
|
53
|
-
}
|
|
54
|
-
}
|
|
55
|
-
exports.BaseOneService = BaseOneService;
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { FindOneOptions, ObjectLiteral } from "typeorm";
|
|
2
|
-
import { BaseManyService } from "@/services/base/baseManyService";
|
|
3
|
-
export declare class BaseRemoteItemsService<T extends ObjectLiteral, K extends keyof T> extends BaseManyService<T, K> {
|
|
4
|
-
getAll(parentEntity: T[K]): Promise<T[]>;
|
|
5
|
-
getByItemGuid(parentEntity: T[K], item_guid: keyof T): Promise<T | null>;
|
|
6
|
-
getByFeedGuid(parentEntity: T[K], feed_guid: keyof T): Promise<T | null>;
|
|
7
|
-
getByFeedUrl(parentEntity: T[K], feed_url: keyof T): Promise<T | null>;
|
|
8
|
-
get(parentEntity: T[K], dto: Partial<T>): Promise<T | null>;
|
|
9
|
-
update(parentEntity: T[K], dto: Partial<T>, config?: FindOneOptions<T>): Promise<T>;
|
|
10
|
-
updateMany(parentEntity: T[K], dtos: Partial<T>[], config?: FindOneOptions<T>): Promise<T[]>;
|
|
11
|
-
}
|
|
@@ -1,81 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
-
});
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.BaseRemoteItemsService = void 0;
|
|
13
|
-
const baseManyService_1 = require("@/services/base/baseManyService");
|
|
14
|
-
class BaseRemoteItemsService extends baseManyService_1.BaseManyService {
|
|
15
|
-
getAll(parentEntity) {
|
|
16
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
17
|
-
const where = { [this.parentEntityKey]: parentEntity };
|
|
18
|
-
return this.repository.find({ where });
|
|
19
|
-
});
|
|
20
|
-
}
|
|
21
|
-
getByItemGuid(parentEntity, item_guid) {
|
|
22
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
23
|
-
const where = {
|
|
24
|
-
[this.parentEntityKey]: parentEntity,
|
|
25
|
-
item_guid
|
|
26
|
-
};
|
|
27
|
-
return this.repository.findOne({ where });
|
|
28
|
-
});
|
|
29
|
-
}
|
|
30
|
-
getByFeedGuid(parentEntity, feed_guid) {
|
|
31
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
32
|
-
const where = {
|
|
33
|
-
[this.parentEntityKey]: parentEntity,
|
|
34
|
-
feed_guid
|
|
35
|
-
};
|
|
36
|
-
return this.repository.findOne({ where });
|
|
37
|
-
});
|
|
38
|
-
}
|
|
39
|
-
getByFeedUrl(parentEntity, feed_url) {
|
|
40
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
41
|
-
const where = {
|
|
42
|
-
[this.parentEntityKey]: parentEntity,
|
|
43
|
-
feed_url
|
|
44
|
-
};
|
|
45
|
-
return this.repository.findOne({ where });
|
|
46
|
-
});
|
|
47
|
-
}
|
|
48
|
-
get(parentEntity, dto) {
|
|
49
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
50
|
-
if (dto.item_guid) {
|
|
51
|
-
return this.getByItemGuid(parentEntity, dto.item_guid);
|
|
52
|
-
}
|
|
53
|
-
else if (dto.feed_guid) {
|
|
54
|
-
return this.getByFeedGuid(parentEntity, dto.feed_guid);
|
|
55
|
-
}
|
|
56
|
-
else if (dto.feed_url) {
|
|
57
|
-
return this.getByFeedUrl(parentEntity, dto.feed_url);
|
|
58
|
-
}
|
|
59
|
-
return null;
|
|
60
|
-
});
|
|
61
|
-
}
|
|
62
|
-
update(parentEntity, dto, config) {
|
|
63
|
-
const _super = Object.create(null, {
|
|
64
|
-
_update: { get: () => super._update }
|
|
65
|
-
});
|
|
66
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
67
|
-
const whereKeys = ['feed_guid', 'feed_url', 'item_guid'];
|
|
68
|
-
return _super._update.call(this, parentEntity, whereKeys, dto, config);
|
|
69
|
-
});
|
|
70
|
-
}
|
|
71
|
-
updateMany(parentEntity, dtos, config) {
|
|
72
|
-
const _super = Object.create(null, {
|
|
73
|
-
_updateMany: { get: () => super._updateMany }
|
|
74
|
-
});
|
|
75
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
76
|
-
const whereKeys = ['feed_guid', 'feed_url', 'item_guid'];
|
|
77
|
-
return _super._updateMany.call(this, parentEntity, whereKeys, dtos, config);
|
|
78
|
-
});
|
|
79
|
-
}
|
|
80
|
-
}
|
|
81
|
-
exports.BaseRemoteItemsService = BaseRemoteItemsService;
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
import { Channel } from '@/entities/channel/channel';
|
|
2
|
-
import { Feed } from '@/entities/feed/feed';
|
|
3
|
-
import { MediumEnum } from '@/entities/medium';
|
|
4
|
-
import { Repository } from 'typeorm';
|
|
5
|
-
type ChannelInitializeDto = {
|
|
6
|
-
feed: Feed;
|
|
7
|
-
podcast_index_id: number;
|
|
8
|
-
};
|
|
9
|
-
type ChannelDto = {
|
|
10
|
-
slug?: string | null;
|
|
11
|
-
podcast_guid?: string | null;
|
|
12
|
-
title: string | null;
|
|
13
|
-
sortable_title: string | null;
|
|
14
|
-
medium?: MediumEnum | null;
|
|
15
|
-
has_podcast_index_value?: boolean;
|
|
16
|
-
hidden?: boolean;
|
|
17
|
-
marked_for_deletion?: boolean;
|
|
18
|
-
};
|
|
19
|
-
export declare class ChannelService {
|
|
20
|
-
protected repository: Repository<Channel>;
|
|
21
|
-
constructor();
|
|
22
|
-
get(id: number): Promise<Channel | null>;
|
|
23
|
-
_getByIdText(id_text: string): Promise<Channel | null>;
|
|
24
|
-
getByPodcastIndexId(podcast_index_id: number): Promise<Channel | null>;
|
|
25
|
-
getOrCreateByPodcastIndexId(dto: ChannelInitializeDto): Promise<Channel>;
|
|
26
|
-
update(id: number, dto: ChannelDto): Promise<Channel>;
|
|
27
|
-
}
|
|
28
|
-
export {};
|
|
@@ -1,58 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
-
});
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.ChannelService = void 0;
|
|
13
|
-
const channel_1 = require("@/entities/channel/channel");
|
|
14
|
-
const applyProperties_1 = require("@/lib/applyProperties");
|
|
15
|
-
const db_1 = require("@/db");
|
|
16
|
-
class ChannelService {
|
|
17
|
-
constructor() {
|
|
18
|
-
this.repository = db_1.AppDataSource.getRepository(channel_1.Channel);
|
|
19
|
-
}
|
|
20
|
-
get(id) {
|
|
21
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
22
|
-
return this.repository.findOne({ where: { id } });
|
|
23
|
-
});
|
|
24
|
-
}
|
|
25
|
-
_getByIdText(id_text) {
|
|
26
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
27
|
-
return this.repository.findOne({ where: { id_text } });
|
|
28
|
-
});
|
|
29
|
-
}
|
|
30
|
-
getByPodcastIndexId(podcast_index_id) {
|
|
31
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
32
|
-
return this.repository.findOne({ where: { podcast_index_id } });
|
|
33
|
-
});
|
|
34
|
-
}
|
|
35
|
-
getOrCreateByPodcastIndexId(dto) {
|
|
36
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
37
|
-
let channel = yield this.getByPodcastIndexId(dto.podcast_index_id);
|
|
38
|
-
if (!channel) {
|
|
39
|
-
channel = new channel_1.Channel();
|
|
40
|
-
channel.feed_id = dto.feed.id;
|
|
41
|
-
channel.podcast_index_id = dto.podcast_index_id;
|
|
42
|
-
channel = yield this.repository.save(channel);
|
|
43
|
-
}
|
|
44
|
-
return channel;
|
|
45
|
-
});
|
|
46
|
-
}
|
|
47
|
-
update(id, dto) {
|
|
48
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
49
|
-
let channel = yield this.get(id);
|
|
50
|
-
if (!channel) {
|
|
51
|
-
channel = new channel_1.Channel();
|
|
52
|
-
}
|
|
53
|
-
channel = (0, applyProperties_1.applyProperties)(channel, dto);
|
|
54
|
-
return this.repository.save(channel);
|
|
55
|
-
});
|
|
56
|
-
}
|
|
57
|
-
}
|
|
58
|
-
exports.ChannelService = ChannelService;
|