@saooti/octopus-sdk 40.2.19 → 41.0.0-SNAPSHOT
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 +2 -3
- package/src/App.vue +68 -88
- package/src/components/composable/player/usePlayerLive.ts +12 -3
- package/src/components/composable/player/usePlayerLogic.ts +6 -6
- package/src/components/composable/podcasts/usePodcastView.ts +3 -3
- package/src/components/composable/useInit.ts +2 -2
- package/src/components/composable/useMetaTitleWatch.ts +2 -2
- package/src/components/display/accessibility/AccessibilityModal.vue +56 -68
- package/src/components/display/categories/CategoryChooser.vue +142 -145
- package/src/components/display/categories/CategoryFilter.vue +172 -198
- package/src/components/display/categories/CategoryList.vue +122 -147
- package/src/components/display/comments/CommentInput.vue +100 -122
- package/src/components/display/comments/CommentList.vue +169 -191
- package/src/components/display/comments/CommentName.vue +35 -45
- package/src/components/display/comments/CommentParentInfo.vue +28 -34
- package/src/components/display/comments/CommentPlayer.vue +38 -50
- package/src/components/display/comments/CommentSection.vue +85 -103
- package/src/components/display/comments/item/CommentBasicView.vue +48 -61
- package/src/components/display/comments/item/CommentItem.vue +101 -116
- package/src/components/display/comments/item/CommentMoreActions.vue +174 -189
- package/src/components/display/comments/item/CommentMoreActionsAdmin.vue +1 -3
- package/src/components/display/comments/like/LikeButton.vue +36 -41
- package/src/components/display/comments/like/LikeSection.vue +128 -136
- package/src/components/display/comments/modal/CheckIdentityModal.vue +35 -40
- package/src/components/display/comments/modal/EditCommentModal.vue +72 -78
- package/src/components/display/comments/modal/RecaptchaModal.vue +58 -63
- package/src/components/display/comments/modal/ReportAbuseModal.vue +59 -66
- package/src/components/display/edit/EditBox.vue +6 -9
- package/src/components/display/edit/EditBoxRadio.vue +1 -5
- package/src/components/display/emission/EmissionInlineList.vue +82 -97
- package/src/components/display/emission/EmissionItem.vue +57 -69
- package/src/components/display/emission/EmissionList.vue +192 -218
- package/src/components/display/emission/EmissionPlayerItem.vue +47 -64
- package/src/components/display/emission/EmissionPresentationItem.vue +44 -54
- package/src/components/display/emission/EmissionPresentationList.vue +51 -61
- package/src/components/display/filter/AdvancedSearch.vue +154 -176
- package/src/components/display/filter/CategorySearchFilter.vue +43 -46
- package/src/components/display/filter/DateFilter.vue +76 -91
- package/src/components/display/filter/MonetizableFilter.vue +27 -30
- package/src/components/display/filter/ProductorSearch.vue +87 -90
- package/src/components/display/filter/RubriqueChoice.vue +58 -63
- package/src/components/display/filter/RubriqueFilter.vue +154 -169
- package/src/components/display/filter/SearchOrder.vue +35 -35
- package/src/components/display/list/ListPaginate.vue +80 -93
- package/src/components/display/list/PaginateParams.vue +36 -40
- package/src/components/display/list/PaginateSection.vue +113 -124
- package/src/components/display/list/SwiperList.vue +97 -109
- package/src/components/display/live/CountDown.vue +15 -9
- package/src/components/display/live/CountdownOctopus.vue +16 -10
- package/src/components/display/live/LiveHorizontalList.vue +95 -103
- package/src/components/display/live/LiveItem.vue +65 -73
- package/src/components/display/live/LiveList.vue +125 -137
- package/src/components/display/live/RadioCurrently.vue +66 -73
- package/src/components/display/live/RadioImage.vue +39 -50
- package/src/components/display/live/RadioItem.vue +9 -14
- package/src/components/display/live/RadioList.vue +39 -53
- package/src/components/display/live/RadioPlanning.vue +210 -222
- package/src/components/display/organisation/OrganisationChooser.vue +116 -122
- package/src/components/display/organisation/OrganisationChooserLight.vue +44 -52
- package/src/components/display/participant/ParticipantInlineList.vue +42 -58
- package/src/components/display/participant/ParticipantItem.vue +66 -74
- package/src/components/display/participant/ParticipantList.vue +119 -141
- package/src/components/display/playlist/PlaylistItem.vue +33 -46
- package/src/components/display/playlist/PlaylistList.vue +118 -144
- package/src/components/display/playlist/PodcastList.vue +79 -101
- package/src/components/display/playlist/PodcastPlaylistInlineList.vue +58 -70
- package/src/components/display/podcastmaker/PodcastmakerHeader.vue +21 -22
- package/src/components/display/podcasts/AnimatorsItem.vue +15 -16
- package/src/components/display/podcasts/DownloadPodcastButton.vue +21 -29
- package/src/components/display/podcasts/ParticipantDescription.vue +22 -24
- package/src/components/display/podcasts/PodcastFilterList.vue +48 -53
- package/src/components/display/podcasts/PodcastImage.vue +96 -99
- package/src/components/display/podcasts/PodcastInlineList.vue +30 -28
- package/src/components/display/podcasts/PodcastInlineListTemplate.vue +107 -114
- package/src/components/display/podcasts/PodcastIsPlaying.vue +4 -12
- package/src/components/display/podcasts/PodcastItem.vue +48 -63
- package/src/components/display/podcasts/PodcastItemInfo.vue +19 -35
- package/src/components/display/podcasts/PodcastList.vue +183 -206
- package/src/components/display/podcasts/PodcastModuleBox.vue +100 -137
- package/src/components/display/podcasts/PodcastPlannedSpinner.vue +4 -6
- package/src/components/display/podcasts/PodcastPlayBar.vue +50 -61
- package/src/components/display/podcasts/PodcastPlayBasicButton.vue +38 -41
- package/src/components/display/podcasts/PodcastPlayButton.vue +164 -175
- package/src/components/display/podcasts/PodcastRawTranscript.vue +69 -80
- package/src/components/display/podcasts/PodcastRubriqueList.vue +35 -38
- package/src/components/display/podcasts/PodcastSwiperList.vue +100 -110
- package/src/components/display/podcasts/TagList.vue +48 -50
- package/src/components/display/podcasts/VideoModuleBox.vue +13 -24
- package/src/components/display/rubriques/RubriqueChooser.vue +135 -140
- package/src/components/display/rubriques/RubriqueList.vue +140 -160
- package/src/components/display/sharing/ChooseEpisodesNumber.vue +34 -33
- package/src/components/display/sharing/FormatSwitch.vue +16 -11
- package/src/components/display/sharing/PlayerAnonymousModal.vue +24 -27
- package/src/components/display/sharing/PlayerCommonParameters.vue +20 -13
- package/src/components/display/sharing/PlayerParameters.vue +69 -71
- package/src/components/display/sharing/QrCode.vue +55 -67
- package/src/components/display/sharing/ShareAnonymous.vue +160 -178
- package/src/components/display/sharing/ShareDistribution.vue +103 -117
- package/src/components/display/sharing/ShareNewsletter.vue +154 -161
- package/src/components/display/sharing/SharePlayer.vue +273 -295
- package/src/components/display/sharing/SharePlayerColors.vue +25 -16
- package/src/components/display/sharing/SharePlayerRadio.vue +61 -69
- package/src/components/display/sharing/SharePlayerTypes.vue +176 -176
- package/src/components/display/sharing/ShareSocialsButtons.vue +63 -75
- package/src/components/display/sharing/SubscribeButtons.vue +184 -207
- package/src/components/display/studio/RecordingItemButton.vue +1 -4
- package/src/components/form/ClassicCheckbox.vue +26 -30
- package/src/components/form/ClassicContentEditable.vue +37 -33
- package/src/components/form/ClassicCopyButton.vue +40 -44
- package/src/components/form/ClassicDatePicker.vue +114 -114
- package/src/components/form/ClassicEmojiPicker.vue +20 -28
- package/src/components/form/ClassicInputText.vue +116 -120
- package/src/components/form/ClassicLoading.vue +7 -12
- package/src/components/form/ClassicMultiselect.vue +106 -116
- package/src/components/form/ClassicRadio.vue +21 -16
- package/src/components/form/ClassicRadioLabel.vue +23 -22
- package/src/components/form/ClassicSearch.vue +24 -19
- package/src/components/form/ClassicSelect.vue +47 -38
- package/src/components/form/ClassicWysiwyg.vue +116 -123
- package/src/components/icons/AmazonMusicIcon.vue +7 -10
- package/src/components/icons/ApplePodcastIcon.vue +7 -11
- package/src/components/icons/BlueSkyIcon.vue +8 -11
- package/src/components/icons/DeezerIcon.vue +8 -11
- package/src/components/icons/EditFtpIcon.vue +8 -11
- package/src/components/icons/IHeartIcon.vue +8 -11
- package/src/components/icons/PlayVideoIcon.vue +7 -10
- package/src/components/icons/PlayerFmIcon.vue +7 -10
- package/src/components/icons/PocketCastIcon.vue +8 -11
- package/src/components/icons/PodcastAddictIcon.vue +7 -10
- package/src/components/icons/RadiolineIcon.vue +8 -11
- package/src/components/icons/TuninIcon.vue +8 -11
- package/src/components/icons/XIcon.vue +7 -10
- package/src/components/misc/AcpmImage.vue +6 -7
- package/src/components/misc/ClassicAccordion.vue +26 -31
- package/src/components/misc/ClassicLazy.vue +86 -90
- package/src/components/misc/ClassicNav.vue +16 -20
- package/src/components/misc/ClassicPopover.vue +266 -282
- package/src/components/misc/ClassicSpinner.vue +5 -27
- package/src/components/misc/ErrorMessage.vue +11 -12
- package/src/components/misc/FooterGarSection.vue +33 -41
- package/src/components/misc/FooterSection.vue +109 -130
- package/src/components/misc/HomeDropdown.vue +83 -105
- package/src/components/misc/MobileMenu.vue +101 -111
- package/src/components/misc/ProgressBar.vue +53 -62
- package/src/components/misc/TopBar.vue +97 -120
- package/src/components/misc/TopBarMainContent.vue +114 -133
- package/src/components/misc/modal/ClassicModal.vue +40 -33
- package/src/components/misc/modal/ClassicModalInBody.vue +34 -28
- package/src/components/misc/modal/ClipboardModal.vue +27 -30
- package/src/components/misc/modal/ContractPreviewModal.vue +64 -62
- package/src/components/misc/modal/MessageModal.vue +50 -47
- package/src/components/misc/modal/NewsletterModal.vue +30 -31
- package/src/components/misc/modal/QrCodeModal.vue +21 -21
- package/src/components/misc/modal/ShareModalPlayer.vue +43 -52
- package/src/components/misc/player/PlayerCompact.vue +6 -4
- package/src/components/misc/player/PlayerComponent.vue +8 -9
- package/src/components/misc/player/PlayerLarge.vue +9 -8
- package/src/components/misc/player/ads/AdsProgressBar.vue +8 -11
- package/src/components/misc/player/ads/AdsSkipButton.vue +24 -30
- package/src/components/misc/player/chaptering/ChapteringModal.vue +44 -54
- package/src/components/misc/player/chaptering/PlayerChaptering.vue +50 -62
- package/src/components/misc/player/elements/PlayerImage.vue +51 -57
- package/src/components/misc/player/elements/PlayerPlayButton.vue +81 -92
- package/src/components/misc/player/elements/PlayerSpeedButton.vue +23 -27
- package/src/components/misc/player/elements/PlayerTitle.vue +85 -111
- package/src/components/misc/player/progressbar/PlayerProgressBar.vue +18 -29
- package/src/components/misc/player/progressbar/PodcastProgressBar.vue +45 -56
- package/src/components/misc/player/radio/RadioHistory.vue +80 -99
- package/src/components/misc/player/radio/RadioProgressBar.vue +43 -54
- package/src/components/misc/player/video/PlayerVideo.vue +27 -40
- package/src/components/misc/player/video/PlayerVideoDigiteka.vue +32 -37
- package/src/components/misc/player/video/PlayerVideoHls.vue +199 -198
- package/src/components/misc/player/video/PlayerYoutubeEmbed.vue +10 -12
- package/src/components/pages/CategoryPage.vue +28 -33
- package/src/components/pages/EmissionPage.vue +99 -132
- package/src/components/pages/EmissionsPage.vue +2 -0
- package/src/components/pages/Error403Page.vue +21 -20
- package/src/components/pages/HomePage.vue +91 -100
- package/src/components/pages/LivesPage.vue +35 -37
- package/src/components/pages/MapPage.vue +209 -241
- package/src/components/pages/PageLogout.vue +8 -11
- package/src/components/pages/PageNotFound.vue +9 -5
- package/src/components/pages/ParticipantPage.vue +82 -110
- package/src/components/pages/ParticipantsPage.vue +3 -0
- package/src/components/pages/PlaylistPage.vue +97 -115
- package/src/components/pages/PlaylistsPage.vue +9 -2
- package/src/components/pages/PodcastPage.vue +223 -238
- package/src/components/pages/PodcastsPage.vue +9 -2
- package/src/components/pages/RadioPage.vue +56 -70
- package/src/components/pages/RubriquePage.vue +7 -3
- package/src/components/pages/SearchPage.vue +31 -36
- package/src/components/pages/TagPage.vue +11 -9
- package/src/components/pages/VideoPage.vue +14 -11
- package/src/helper/displayHelper.ts +1 -1
- package/src/i18n.ts +2 -2
- package/src/main.ts +1 -1
- package/src/stores/class/general/player.ts +1 -0
- package/public/css/fonts/icomoon.eot +0 -0
- package/public/css/fonts/icomoon.svg +0 -113
- package/public/css/fonts/icomoon.ttf +0 -0
- package/public/css/fonts/icomoon.woff +0 -0
- package/public/css/fonts/icomoon.woff2 +0 -0
- package/public/css/fonts/style.css +0 -352
- package/sonarqube-scanner.js +0 -10
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
name: 'emission',
|
|
9
9
|
params: { emissionId: emission.emissionId },
|
|
10
10
|
}"
|
|
11
|
-
:title="
|
|
11
|
+
:title="t('Series name page', { name: emission.name })"
|
|
12
12
|
class="d-flex-column flex-grow-1 text-dark"
|
|
13
13
|
:class="isVertical ? 'flex-column' : ''"
|
|
14
14
|
>
|
|
@@ -18,9 +18,10 @@
|
|
|
18
18
|
:height="isVertical ? '400' : '250'"
|
|
19
19
|
:class="isVertical ? 'img-box-bigger' : ''"
|
|
20
20
|
class="img-box"
|
|
21
|
-
|
|
21
|
+
aria-hidden="true"
|
|
22
|
+
alt=""
|
|
22
23
|
|
|
23
|
-
:title="
|
|
24
|
+
:title="t('Emission name image', { name: emission.name })"
|
|
24
25
|
/>
|
|
25
26
|
<div class="classic-element-text">
|
|
26
27
|
<div class="element-name mb-2 basic-line-clamp">
|
|
@@ -43,64 +44,53 @@
|
|
|
43
44
|
</article>
|
|
44
45
|
</template>
|
|
45
46
|
|
|
46
|
-
<script lang="ts">
|
|
47
|
-
import { useFilterStore } from "../../../stores/FilterStore";
|
|
47
|
+
<script setup lang="ts">
|
|
48
48
|
import {useResizePhone} from "../../composable/useResizePhone";
|
|
49
49
|
import { Emission } from "@/stores/class/general/emission";
|
|
50
50
|
import {useImageProxy} from "../../composable/useImageProxy";
|
|
51
51
|
import displayHelper from "../../../helper/displayHelper";
|
|
52
|
-
import {
|
|
53
|
-
import {
|
|
54
|
-
export default defineComponent({
|
|
55
|
-
name: "EmissionItem",
|
|
52
|
+
import { nextTick, useTemplateRef, watch } from "vue";
|
|
53
|
+
import { useI18n } from "vue-i18n";
|
|
56
54
|
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
},
|
|
62
|
-
|
|
63
|
-
const { isPhone } = useResizePhone();
|
|
64
|
-
const { useProxyImageUrl } = useImageProxy();
|
|
65
|
-
return { isPhone, useProxyImageUrl }
|
|
66
|
-
},
|
|
55
|
+
//Props
|
|
56
|
+
const props = defineProps({
|
|
57
|
+
emission: { default: () => ({}), type: Object as () => Emission },
|
|
58
|
+
isVertical: { default: false, type: Boolean },
|
|
59
|
+
isDescription: { default: false, type: Boolean },
|
|
60
|
+
})
|
|
67
61
|
|
|
62
|
+
//Data
|
|
63
|
+
const descriptionEmissionRef = useTemplateRef('descriptionEmission');
|
|
64
|
+
const descriptionEmissionContainerRef = useTemplateRef('descriptionEmissionContainer');
|
|
68
65
|
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
},
|
|
98
|
-
methods:{
|
|
99
|
-
urlify(text:string|undefined){
|
|
100
|
-
return displayHelper.urlify(text);
|
|
101
|
-
},
|
|
102
|
-
}
|
|
103
|
-
});
|
|
66
|
+
|
|
67
|
+
//Composables
|
|
68
|
+
const { t } = useI18n();
|
|
69
|
+
const { isPhone } = useResizePhone();
|
|
70
|
+
const { useProxyImageUrl } = useImageProxy();
|
|
71
|
+
|
|
72
|
+
//Watch
|
|
73
|
+
watch(isPhone, async () => {
|
|
74
|
+
nextTick(() => {
|
|
75
|
+
if (!props.isDescription || isPhone.value) {
|
|
76
|
+
return;
|
|
77
|
+
}
|
|
78
|
+
const emissionDesc = descriptionEmissionRef?.value as HTMLElement;
|
|
79
|
+
const emissionDescContainer = descriptionEmissionContainerRef?.value as HTMLElement;
|
|
80
|
+
if (
|
|
81
|
+
emissionDesc &&
|
|
82
|
+
emissionDescContainer &&
|
|
83
|
+
emissionDesc.clientHeight > emissionDescContainer.clientHeight
|
|
84
|
+
) {
|
|
85
|
+
emissionDescContainer.classList.add("after-element-description");
|
|
86
|
+
}
|
|
87
|
+
});
|
|
88
|
+
}, {immediate: true});
|
|
89
|
+
|
|
90
|
+
//Methods
|
|
91
|
+
function urlify(text:string|undefined){
|
|
92
|
+
return displayHelper.urlify(text);
|
|
93
|
+
}
|
|
104
94
|
</script>
|
|
105
95
|
<style lang="scss">
|
|
106
96
|
.octopus-app {
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
<div class="d-flex flex-column p-3">
|
|
3
3
|
<h2 class="mb-3">{{ title }}</h2>
|
|
4
4
|
<ClassicLoading
|
|
5
|
-
:loading-text="loading ?
|
|
6
|
-
:error-text="error ?
|
|
5
|
+
:loading-text="loading ? t('Loading emissions ...') : undefined"
|
|
6
|
+
:error-text="error ? t(`Error`) : undefined"
|
|
7
7
|
/>
|
|
8
8
|
<template v-if="!loading && !error">
|
|
9
9
|
<div class="d-flex flex-nowrap align-items-stretch overflow-phone-auto">
|
|
@@ -57,79 +57,69 @@
|
|
|
57
57
|
</div>
|
|
58
58
|
</template>
|
|
59
59
|
|
|
60
|
-
<script lang="ts">
|
|
60
|
+
<script setup lang="ts">
|
|
61
61
|
import classicApi from "../../../api/classicApi";
|
|
62
62
|
import {useErrorHandler} from "../../composable/useErrorHandler";
|
|
63
63
|
import ClassicLoading from "../../form/ClassicLoading.vue";
|
|
64
64
|
import { Emission } from "@/stores/class/general/emission";
|
|
65
|
-
import { defineAsyncComponent,
|
|
65
|
+
import { defineAsyncComponent, onMounted, Ref, ref } from "vue";
|
|
66
66
|
import { AxiosError } from "axios";
|
|
67
67
|
import {useResizePhone} from "../../composable/useResizePhone";
|
|
68
68
|
import { ListClassicReturn } from "@/stores/class/general/listReturn";
|
|
69
|
+
import { useI18n } from "vue-i18n";
|
|
69
70
|
const EmissionItemPresentation = defineAsyncComponent(
|
|
70
71
|
() => import("./EmissionPresentationItem.vue"),
|
|
71
72
|
);
|
|
72
|
-
export default defineComponent({
|
|
73
|
-
name: "EmissionPresentationList",
|
|
74
|
-
components: {
|
|
75
|
-
ClassicLoading,
|
|
76
|
-
EmissionItemPresentation,
|
|
77
|
-
},
|
|
78
73
|
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
},
|
|
74
|
+
//Props
|
|
75
|
+
const props = defineProps({
|
|
76
|
+
organisationId: { default: undefined, type: String },
|
|
77
|
+
title: { default: "", type: String },
|
|
78
|
+
href: { default: undefined, type: String },
|
|
79
|
+
buttonText: { default: undefined, type: String },
|
|
80
|
+
isDescription: { default: false, type: Boolean },
|
|
81
|
+
rubriquesId: { default: [], type: Array<number> },
|
|
82
|
+
})
|
|
87
83
|
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
84
|
+
//Data
|
|
85
|
+
const loading = ref(true);
|
|
86
|
+
const error = ref(false);
|
|
87
|
+
const allEmissions: Ref<Array<Emission>> = ref([]);
|
|
88
|
+
|
|
89
|
+
//Composables
|
|
90
|
+
const { t } = useI18n();
|
|
91
|
+
const { isPhone } = useResizePhone();
|
|
92
|
+
const {handle403} = useErrorHandler();
|
|
93
93
|
|
|
94
|
-
|
|
95
|
-
return {
|
|
96
|
-
loading: true as boolean,
|
|
97
|
-
error: false as boolean,
|
|
98
|
-
allEmissions: [] as Array<Emission>,
|
|
99
|
-
};
|
|
100
|
-
},
|
|
94
|
+
onMounted(()=>fetchNext())
|
|
101
95
|
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
this.loading = false;
|
|
130
|
-
},
|
|
131
|
-
},
|
|
132
|
-
});
|
|
96
|
+
|
|
97
|
+
//Methods
|
|
98
|
+
async function fetchNext(): Promise<void> {
|
|
99
|
+
loading.value = true;
|
|
100
|
+
try {
|
|
101
|
+
const data = await classicApi.fetchData<ListClassicReturn<Emission>>({
|
|
102
|
+
api: 0,
|
|
103
|
+
path: "emission/search",
|
|
104
|
+
parameters: {
|
|
105
|
+
first: 0,
|
|
106
|
+
size: 5,
|
|
107
|
+
organisationId: props.organisationId,
|
|
108
|
+
sort: "LAST_PODCAST_DESC",
|
|
109
|
+
rubriqueId: props.rubriquesId
|
|
110
|
+
},
|
|
111
|
+
specialTreatement: true,
|
|
112
|
+
});
|
|
113
|
+
allEmissions.value = allEmissions.value.concat(
|
|
114
|
+
data.result.filter((em: Emission | null) => null !== em),
|
|
115
|
+
);
|
|
116
|
+
loading.value = false;
|
|
117
|
+
} catch (errorWs) {
|
|
118
|
+
handle403(errorWs as AxiosError);
|
|
119
|
+
error.value = true;
|
|
120
|
+
}
|
|
121
|
+
loading.value = false;
|
|
122
|
+
}
|
|
133
123
|
</script>
|
|
134
124
|
<style lang="scss">
|
|
135
125
|
.octopus-app {
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
class="d-flex justify-content-center align-items-center mb-3 text-secondary btn-transparent"
|
|
5
5
|
@click="clickShowFilters"
|
|
6
6
|
>
|
|
7
|
-
<div>{{
|
|
7
|
+
<div>{{ t("Advanced filters") }}</div>
|
|
8
8
|
<ChevronDownIcon :class="{ 'arrow-transform': showFilters }" />
|
|
9
9
|
</button>
|
|
10
10
|
<Transition name="advanced-search">
|
|
@@ -15,10 +15,10 @@
|
|
|
15
15
|
>
|
|
16
16
|
<fieldset class="d-flex flex-column flex-grow-3">
|
|
17
17
|
<legend class="text-primary mb-2">
|
|
18
|
-
{{
|
|
18
|
+
{{ t("Filter") }}
|
|
19
19
|
</legend>
|
|
20
20
|
<MonetizableFilter
|
|
21
|
-
v-if="!isPodcastmaker && !platformEducation"
|
|
21
|
+
v-if="!isPodcastmaker && !generalStore.platformEducation"
|
|
22
22
|
:is-emission="isEmission"
|
|
23
23
|
:monetisable="monetisable"
|
|
24
24
|
@update:monetisable="updateMonetisable"
|
|
@@ -51,14 +51,14 @@
|
|
|
51
51
|
v-if="isSelectValidity"
|
|
52
52
|
:text-init="validity"
|
|
53
53
|
id-select="valid-episodes-select"
|
|
54
|
-
:label="
|
|
54
|
+
:label="t('Episodes to validate')+' :'"
|
|
55
55
|
:display-label="true"
|
|
56
56
|
class-label="flex-shrink-0 me-1"
|
|
57
57
|
class="d-flex align-items-center mt-3 mb-0"
|
|
58
58
|
:options="[
|
|
59
|
-
{ title:
|
|
60
|
-
{ title:
|
|
61
|
-
{ title:
|
|
59
|
+
{ title: t('Display only episodes to validate'), value: 'false' },
|
|
60
|
+
{ title: t('Display episodes to validate'), value: '' },
|
|
61
|
+
{ title: t('Do not display episodes to validate'), value: 'true' },
|
|
62
62
|
]"
|
|
63
63
|
@update:text-init="updateValidity"
|
|
64
64
|
/>
|
|
@@ -67,7 +67,7 @@
|
|
|
67
67
|
:text-init="onlyVideo"
|
|
68
68
|
class="flex-shrink-0 mt-3"
|
|
69
69
|
id-checkbox="only-video-checkbox"
|
|
70
|
-
:label="
|
|
70
|
+
:label="t('Show only episodes with video')"
|
|
71
71
|
@update:text-init="updateOnlyVideo"
|
|
72
72
|
/>
|
|
73
73
|
</fieldset>
|
|
@@ -81,16 +81,16 @@
|
|
|
81
81
|
</div>
|
|
82
82
|
</template>
|
|
83
83
|
|
|
84
|
-
<script lang="ts">
|
|
84
|
+
<script setup lang="ts">
|
|
85
85
|
import ChevronDownIcon from "vue-material-design-icons/ChevronDown.vue";
|
|
86
86
|
import {useOrgaComputed} from "../../composable/useOrgaComputed";
|
|
87
87
|
import { useAuthStore } from "../../../stores/AuthStore";
|
|
88
88
|
import { useFilterStore } from "../../../stores/FilterStore";
|
|
89
89
|
import { useRubriquesFilterParam } from "../../composable/route/useRubriquesFilterParam";
|
|
90
90
|
import { RubriquageFilter } from "@/stores/class/rubrique/rubriquageFilter";
|
|
91
|
-
import {
|
|
92
|
-
import { mapState } from "pinia";
|
|
91
|
+
import { defineAsyncComponent, ref, computed, watch } from "vue";
|
|
93
92
|
import { useGeneralStore } from "../../../stores/GeneralStore";
|
|
93
|
+
import { useI18n } from "vue-i18n";
|
|
94
94
|
const MonetizableFilter = defineAsyncComponent(
|
|
95
95
|
() => import("./MonetizableFilter.vue"),
|
|
96
96
|
);
|
|
@@ -108,175 +108,153 @@ const ClassicCheckbox = defineAsyncComponent(
|
|
|
108
108
|
);
|
|
109
109
|
const DateFilter = defineAsyncComponent(() => import("./DateFilter.vue"));
|
|
110
110
|
const SearchOrder = defineAsyncComponent(() => import("./SearchOrder.vue"));
|
|
111
|
-
export default defineComponent({
|
|
112
|
-
components: {
|
|
113
|
-
MonetizableFilter,
|
|
114
|
-
CategorySearchFilter,
|
|
115
|
-
RubriqueFilter,
|
|
116
|
-
ClassicCheckbox,
|
|
117
|
-
DateFilter,
|
|
118
|
-
SearchOrder,
|
|
119
|
-
ChevronDownIcon,
|
|
120
|
-
ClassicSelect
|
|
121
|
-
},
|
|
122
|
-
props: {
|
|
123
|
-
organisationId: { default: undefined, type: String },
|
|
124
|
-
isEmission: { default: false, type: Boolean },
|
|
125
|
-
includeHidden: { default: false, type: Boolean },
|
|
126
|
-
sort: { default: "DATE", type: String },
|
|
127
|
-
onlyVideo: { default: false, type: Boolean },
|
|
128
|
-
monetisable: { default: "UNDEFINED", type: String },
|
|
129
|
-
iabId: { default: undefined, type: Number },
|
|
130
|
-
searchPattern: { default: "", type: String },
|
|
131
|
-
fromDate: { default: undefined, type: String },
|
|
132
|
-
toDate: { default: undefined, type: String },
|
|
133
|
-
validity: { default: 'true', type: String },
|
|
134
|
-
rubriqueFilter: {
|
|
135
|
-
default: () => [],
|
|
136
|
-
type: Array as () => Array<RubriquageFilter>,
|
|
137
|
-
},
|
|
138
|
-
},
|
|
139
111
|
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
data() {
|
|
157
|
-
return {
|
|
158
|
-
showFilters: false as boolean,
|
|
159
|
-
firstLoaded: false as boolean,
|
|
160
|
-
};
|
|
112
|
+
//Props
|
|
113
|
+
const props = defineProps({
|
|
114
|
+
organisationId: { default: undefined, type: String },
|
|
115
|
+
isEmission: { default: false, type: Boolean },
|
|
116
|
+
includeHidden: { default: false, type: Boolean },
|
|
117
|
+
sort: { default: "DATE", type: String },
|
|
118
|
+
onlyVideo: { default: false, type: Boolean },
|
|
119
|
+
monetisable: { default: "UNDEFINED", type: String },
|
|
120
|
+
iabId: { default: undefined, type: Number },
|
|
121
|
+
searchPattern: { default: "", type: String },
|
|
122
|
+
fromDate: { default: undefined, type: String },
|
|
123
|
+
toDate: { default: undefined, type: String },
|
|
124
|
+
validity: { default: 'true', type: String },
|
|
125
|
+
rubriqueFilter: {
|
|
126
|
+
default: () => [],
|
|
127
|
+
type: Array as () => Array<RubriquageFilter>,
|
|
161
128
|
},
|
|
129
|
+
})
|
|
162
130
|
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
filterIab = { iabId: undefined };
|
|
227
|
-
}
|
|
228
|
-
this.updateRouteParamAdvanced({
|
|
229
|
-
...{ i: value ? value.toString() : undefined },
|
|
230
|
-
...filterIab,
|
|
231
|
-
});
|
|
232
|
-
},
|
|
233
|
-
updateSort(value: string) {
|
|
234
|
-
this.$emit("update:sort", value);
|
|
235
|
-
this.updateRouteParamAdvanced({ s: value });
|
|
236
|
-
},
|
|
237
|
-
updateIncludeHidden(value: boolean) {
|
|
238
|
-
this.$emit("update:includeHidden", value);
|
|
239
|
-
this.updateRouteParamAdvanced({ h: value.toString() });
|
|
240
|
-
},
|
|
241
|
-
updateValidity(value: boolean) {
|
|
242
|
-
this.$emit("update:validity", value);
|
|
243
|
-
this.updateRouteParamAdvanced({ vl: value.toString() });
|
|
244
|
-
},
|
|
245
|
-
updateOnlyVideo(value: boolean) {
|
|
246
|
-
this.$emit("update:onlyVideo", value);
|
|
247
|
-
this.updateRouteParamAdvanced({ v: value ? "true" : undefined });
|
|
248
|
-
},
|
|
249
|
-
updateDates(value: {
|
|
250
|
-
from: string | undefined;
|
|
251
|
-
to: string | undefined;
|
|
252
|
-
}): void {
|
|
253
|
-
this.$emit("update:fromDate", value.from);
|
|
254
|
-
this.$emit("update:toDate", value.to);
|
|
255
|
-
this.updateRouteParamAdvanced({ from: value.from, to: value.to });
|
|
256
|
-
},
|
|
257
|
-
updateRubriquageFilter(value: Array<RubriquageFilter>) {
|
|
258
|
-
this.$emit("update:rubriqueFilter", value);
|
|
259
|
-
let filterRubriques = {};
|
|
260
|
-
const valueString = this.stringifyRubriquesFilter(value);
|
|
261
|
-
if (
|
|
262
|
-
this.filterRubrique.length &&
|
|
263
|
-
this.stringifyRubriquesFilter(this.filterRubrique) !== valueString
|
|
264
|
-
) {
|
|
265
|
-
filterRubriques = { rubriquesId: undefined };
|
|
266
|
-
}
|
|
267
|
-
this.updateRouteParamAdvanced({
|
|
268
|
-
...{ r: valueString.length ? valueString : undefined },
|
|
269
|
-
...filterRubriques,
|
|
270
|
-
});
|
|
271
|
-
},
|
|
272
|
-
clickShowFilters(): void {
|
|
273
|
-
if (!this.firstLoaded) {
|
|
274
|
-
this.firstLoaded = true;
|
|
275
|
-
}
|
|
276
|
-
this.showFilters = !this.showFilters;
|
|
277
|
-
},
|
|
278
|
-
},
|
|
131
|
+
//Emits
|
|
132
|
+
const emit = defineEmits([
|
|
133
|
+
"update:toDate",
|
|
134
|
+
"update:fromDate",
|
|
135
|
+
"update:monetisable",
|
|
136
|
+
"update:iabId",
|
|
137
|
+
"update:sort",
|
|
138
|
+
"update:includeHidden",
|
|
139
|
+
"update:validity",
|
|
140
|
+
"update:rubriqueFilter",
|
|
141
|
+
"update:onlyVideo",
|
|
142
|
+
]);
|
|
143
|
+
|
|
144
|
+
//Data
|
|
145
|
+
const showFilters = ref(false);
|
|
146
|
+
const firstLoaded = ref(false);
|
|
147
|
+
|
|
148
|
+
|
|
149
|
+
//Composables
|
|
150
|
+
const { t } = useI18n();
|
|
151
|
+
const { isPodcastmaker, isEditRights } = useOrgaComputed();
|
|
152
|
+
const { stringifyRubriquesFilter,updateRouteParamAdvanced } = useRubriquesFilterParam();
|
|
153
|
+
const generalStore = useGeneralStore();
|
|
154
|
+
const filterStore = useFilterStore();
|
|
155
|
+
const authStore = useAuthStore();
|
|
156
|
+
|
|
157
|
+
|
|
158
|
+
//Computed
|
|
159
|
+
const organisationRight = computed(() => isEditRights(props.organisationId));
|
|
160
|
+
const organisation = computed(() => props.organisationId ?? filterStore.filterOrgaId);
|
|
161
|
+
const textNotVisible = computed(() => props.isEmission ? t("Consider podcasts no visible"): t("See podcasts no visible"));
|
|
162
|
+
const isSelectValidity = computed(() => {
|
|
163
|
+
return (
|
|
164
|
+
undefined !== organisation.value &&
|
|
165
|
+
organisationRight.value &&
|
|
166
|
+
authStore.isRoleContribution &&
|
|
167
|
+
!isPodcastmaker &&
|
|
168
|
+
!props.isEmission &&
|
|
169
|
+
props.includeHidden
|
|
170
|
+
);
|
|
171
|
+
});
|
|
172
|
+
|
|
173
|
+
|
|
174
|
+
//Watch
|
|
175
|
+
watch(organisation, async () => {
|
|
176
|
+
const hidden =undefined !== organisation.value && organisationRight.value &&!props.isEmission;
|
|
177
|
+
if (hidden !== props.includeHidden) {
|
|
178
|
+
updateIncludeHidden(hidden);
|
|
179
|
+
}
|
|
180
|
+
});
|
|
181
|
+
watch(()=>props.searchPattern, (value: string) => {
|
|
182
|
+
const search = value.trim();
|
|
183
|
+
let valSort = "SCORE"
|
|
184
|
+
if(search.length <= 3){
|
|
185
|
+
valSort = props.isEmission? "LAST_PODCAST_DESC" : "DATE";
|
|
186
|
+
}
|
|
187
|
+
if (valSort !== props.sort) {
|
|
188
|
+
emit("update:sort", valSort);
|
|
189
|
+
}
|
|
190
|
+
updateRouteParamAdvanced({
|
|
191
|
+
q: search.length ? search : undefined,
|
|
192
|
+
s: valSort,
|
|
193
|
+
});
|
|
279
194
|
});
|
|
195
|
+
|
|
196
|
+
|
|
197
|
+
//Methods
|
|
198
|
+
function updateMonetisable(value: string): void {
|
|
199
|
+
emit("update:monetisable", value);
|
|
200
|
+
updateRouteParamAdvanced({ m: "UNDEFINED" !== value ? value : undefined });
|
|
201
|
+
}
|
|
202
|
+
function updateIab(value: number | undefined) {
|
|
203
|
+
emit("update:iabId", 0 !== value ? value : undefined);
|
|
204
|
+
let filterIab = {};
|
|
205
|
+
if (filterStore.filterIab && filterStore.filterIab.id !== value) {
|
|
206
|
+
filterIab = { iabId: undefined };
|
|
207
|
+
}
|
|
208
|
+
updateRouteParamAdvanced({
|
|
209
|
+
...{ i: value ? value.toString() : undefined },
|
|
210
|
+
...filterIab,
|
|
211
|
+
});
|
|
212
|
+
}
|
|
213
|
+
function updateSort(value: string) {
|
|
214
|
+
emit("update:sort", value);
|
|
215
|
+
updateRouteParamAdvanced({ s: value });
|
|
216
|
+
}
|
|
217
|
+
function updateIncludeHidden(value: boolean) {
|
|
218
|
+
emit("update:includeHidden", value);
|
|
219
|
+
updateRouteParamAdvanced({ h: value.toString() });
|
|
220
|
+
}
|
|
221
|
+
function updateValidity(value: boolean) {
|
|
222
|
+
emit("update:validity", value);
|
|
223
|
+
updateRouteParamAdvanced({ vl: value.toString() });
|
|
224
|
+
}
|
|
225
|
+
function updateOnlyVideo(value: boolean) {
|
|
226
|
+
emit("update:onlyVideo", value);
|
|
227
|
+
updateRouteParamAdvanced({ v: value ? "true" : undefined });
|
|
228
|
+
}
|
|
229
|
+
function updateDates(value: {
|
|
230
|
+
from: string | undefined;
|
|
231
|
+
to: string | undefined;
|
|
232
|
+
}): void {
|
|
233
|
+
emit("update:fromDate", value.from);
|
|
234
|
+
emit("update:toDate", value.to);
|
|
235
|
+
updateRouteParamAdvanced({ from: value.from, to: value.to });
|
|
236
|
+
}
|
|
237
|
+
function updateRubriquageFilter(value: Array<RubriquageFilter>) {
|
|
238
|
+
emit("update:rubriqueFilter", value);
|
|
239
|
+
let filterRubriques = {};
|
|
240
|
+
const valueString = stringifyRubriquesFilter(value);
|
|
241
|
+
if (
|
|
242
|
+
filterStore.filterRubrique.length &&
|
|
243
|
+
stringifyRubriquesFilter(filterStore.filterRubrique) !== valueString
|
|
244
|
+
) {
|
|
245
|
+
filterRubriques = { rubriquesId: undefined };
|
|
246
|
+
}
|
|
247
|
+
updateRouteParamAdvanced({
|
|
248
|
+
...{ r: valueString.length ? valueString : undefined },
|
|
249
|
+
...filterRubriques,
|
|
250
|
+
});
|
|
251
|
+
}
|
|
252
|
+
function clickShowFilters(): void {
|
|
253
|
+
if (!firstLoaded.value) {
|
|
254
|
+
firstLoaded.value = true;
|
|
255
|
+
}
|
|
256
|
+
showFilters.value = !showFilters.value;
|
|
257
|
+
}
|
|
280
258
|
</script>
|
|
281
259
|
<style lang="scss">
|
|
282
260
|
.octopus-app {
|