@saooti/octopus-sdk 35.2.15 → 35.2.17
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 +1 -1
- package/src/components/display/live/LiveItem.vue +1 -1
- package/src/components/display/podcasts/PodcastInlineListClassic.vue +17 -11
- package/src/components/display/podcasts/PodcastInlineListTemplate.vue +13 -7
- package/src/components/pages/Podcast.vue +2 -2
- package/src/stores/ParamSdkStore.ts +1 -1
package/package.json
CHANGED
|
@@ -156,19 +156,25 @@ export default defineComponent({
|
|
|
156
156
|
},
|
|
157
157
|
methods: {
|
|
158
158
|
async fetchRecommendations(): Promise<void>{
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
159
|
+
try {
|
|
160
|
+
const podcastIdsArray = await octopusApi.fetchDataPublicWithParams<Array<number>>(13, 'get_predicts',{
|
|
161
|
+
reco: this.podcastId,
|
|
162
|
+
n_neightbors: 5,
|
|
163
|
+
});
|
|
164
|
+
for (let podcastIdReco of podcastIdsArray) {
|
|
165
|
+
try {
|
|
166
|
+
const entirePodcast = await octopusApi.fetchData<Podcast>(0, 'podcast/'+podcastIdReco);
|
|
167
|
+
this.allPodcasts.push(entirePodcast);
|
|
168
|
+
} catch {
|
|
169
|
+
//If doesn't exist, do nothing
|
|
170
|
+
}
|
|
169
171
|
}
|
|
172
|
+
this.totalCount = podcastIdsArray.length;
|
|
173
|
+
this.loading = false;
|
|
174
|
+
} catch {
|
|
175
|
+
this.allPodcasts=[];
|
|
176
|
+
this.totalCount = 0;
|
|
170
177
|
}
|
|
171
|
-
this.totalCount = podcastIdsArray.length;
|
|
172
178
|
this.loading = false;
|
|
173
179
|
},
|
|
174
180
|
async fetchNext(): Promise<void> {
|
|
@@ -78,6 +78,7 @@ import { RouteLocationRaw } from 'vue-router';
|
|
|
78
78
|
import { useFilterStore } from '@/stores/FilterStore';
|
|
79
79
|
import { mapState, mapActions } from 'pinia';
|
|
80
80
|
import { Rubrique } from '@/stores/class/rubrique/rubrique';
|
|
81
|
+
import { Rubriquage } from '@/stores/class/rubrique/rubriquage';
|
|
81
82
|
export default defineComponent({
|
|
82
83
|
name: 'PodcastInlineListTemplate',
|
|
83
84
|
|
|
@@ -158,13 +159,18 @@ export default defineComponent({
|
|
|
158
159
|
nameRubrique: ''
|
|
159
160
|
};
|
|
160
161
|
if(this.filterRubriquage.length){
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
162
|
+
this.filterRubriquage.forEach((element:Rubriquage) => {
|
|
163
|
+
const rubriqueChosen = element.rubriques.find((element: Rubrique) => element.rubriqueId === rubriqueChosenId);
|
|
164
|
+
if(rubriqueChosen){
|
|
165
|
+
filterToAdd = {
|
|
166
|
+
rubriquageId: element.rubriquageId??0,
|
|
167
|
+
rubriqueId: rubriqueChosenId,
|
|
168
|
+
nameRubriquage: element.title,
|
|
169
|
+
nameRubrique: rubriqueChosen.name
|
|
170
|
+
};
|
|
171
|
+
return;
|
|
172
|
+
}
|
|
173
|
+
});
|
|
168
174
|
}
|
|
169
175
|
const newFilter: Array<RubriquageFilter> = Array.from(this.filterRubrique);
|
|
170
176
|
newFilter.push(filterToAdd);
|
|
@@ -71,10 +71,10 @@
|
|
|
71
71
|
:title="$t('More episodes of this emission')"
|
|
72
72
|
:button-text="$t('All podcast emission button')"
|
|
73
73
|
/>
|
|
74
|
-
|
|
74
|
+
<PodcastInlineList
|
|
75
75
|
:podcast-id="podcastId"
|
|
76
76
|
:title="$t('Suggested listening')"
|
|
77
|
-
/>
|
|
77
|
+
/>
|
|
78
78
|
<PodcastInlineList
|
|
79
79
|
v-for="c in categories"
|
|
80
80
|
:key="c.id"
|