@saooti/octopus-sdk 31.0.25 → 31.0.26

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/README.md CHANGED
@@ -573,7 +573,14 @@ See [Configuration Reference](https://cli.vuejs.org/config/).
573
573
  * 30.0.74 Error locales en allemand (je sens que ça va être fun cette histoire)
574
574
  * 30.0.75 Parlement
575
575
  * 30.0.76 Space
576
-
576
+ * 30.0.77 V-Calendar bloque version
577
+ * 30.0.78 a -> word-break
578
+ * 30.0.79 DownloadId player
579
+ * 30.0.80 DownloadId player
580
+ * 30.0.81 DownloadId player
581
+ * 30.0.82 Cherry pick Color Qr code
582
+ * 30.0.83 Locales parlement
583
+ * 30.0.84 Une émission non visible n'apparaît pas dans la page émission
577
584
 
578
585
  * 31.0.0 Passage en 31
579
586
  * 31.0.1 Ajout pocket casts
@@ -601,3 +608,5 @@ See [Configuration Reference](https://cli.vuejs.org/config/).
601
608
  * 31.0.23 Qr Code option noir
602
609
  * 31.0.24 Amélioration accessibilité
603
610
  * 31.0.25 Erreur audioUrl
611
+ * 31.0.26 Erreur 403 page expose
612
+
package/index.ts CHANGED
@@ -12,6 +12,7 @@ import Search from "./src/components/pages/Search.vue";
12
12
  import Home from "./src/components/pages/Home.vue";
13
13
  import Category from "./src/components/pages/Category.vue";
14
14
  import Rubrique from "./src/components/pages/Rubrique.vue";
15
+ import Error403Page from "./src/components/pages/Error403Page.vue";
15
16
  //Misc
16
17
  import Footer from "./src/components/misc/Footer.vue";
17
18
  import LeftMenu from "./src/components/misc/LeftMenu.vue";
@@ -116,7 +117,8 @@ const components = {
116
117
  ClassicLoading,
117
118
  AdvancedSearch,
118
119
  PodcastPlaylistInlineList,
119
- ClassicSelect
120
+ ClassicSelect,
121
+ Error403Page
120
122
  }
121
123
 
122
124
  export default components;
@@ -171,5 +173,6 @@ export {
171
173
  ClassicLoading,
172
174
  AdvancedSearch,
173
175
  PodcastPlaylistInlineList,
174
- ClassicSelect
176
+ ClassicSelect,
177
+ Error403Page
175
178
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@saooti/octopus-sdk",
3
- "version": "31.0.25",
3
+ "version": "31.0.26",
4
4
  "private": false,
5
5
  "description": "Javascript SDK for using octopus",
6
6
  "author": "Saooti",
@@ -145,7 +145,7 @@ export default defineComponent({
145
145
  },
146
146
  resizeWindow(): void {
147
147
  const categoryList = (this.$refs.categoryListContainer as HTMLElement);
148
- if(null === categoryList){
148
+ if(null === categoryList ||!categoryList){
149
149
  return;
150
150
  }
151
151
  categoryList.style.justifyContent = 'flex-start';
@@ -172,10 +172,10 @@ export default defineComponent({
172
172
  isTo: false as boolean,
173
173
  fromDate: moment().subtract(10, 'days').toISOString() as string,
174
174
  toDate: moment().toISOString() as string,
175
- isNotVisible: false as boolean,
175
+ isNotVisible: this.includeHidden as boolean,
176
176
  isNotValidate: false as boolean,
177
177
  showFilters: false as boolean,
178
- sort: '' as string,
178
+ sort: this.sortCriteria as string,
179
179
  };
180
180
  },
181
181
 
@@ -268,16 +268,6 @@ export default defineComponent({
268
268
  this.sort = this.sortCriteria;
269
269
  },
270
270
  },
271
-
272
- created() {
273
- if (!this.isEmission) {
274
- this.isNotVisible = this.includeHidden;
275
- }
276
- },
277
-
278
- mounted() {
279
- this.sort = this.sortCriteria;
280
- },
281
271
  methods: {
282
272
  updateFromDate(): void {
283
273
  if (
@@ -138,9 +138,6 @@ export default defineComponent({
138
138
  async onKeepOrganisation(): Promise<void> {
139
139
  if(!this.organisationId){return}
140
140
  if (!this.keepOrganisation) {
141
- if (this.$route.query.productor !== this.organisationId) {
142
- this.$router.push({ query: { productor: this.organisationId } });
143
- }
144
141
  await this.selectOrganisation(this.organisationId);
145
142
  return;
146
143
  }
@@ -4,29 +4,24 @@
4
4
  class="default-multiselect-width organisation-chooser-light"
5
5
  :style="{ width: width }"
6
6
  >
7
- <template v-if="!privateOrganisation">
8
- <select
9
- :id="'organisation_chooser_light' + page"
10
- v-model="actual"
11
- class="mb-0 c-hand border-0"
12
- @change="onOrganisationSelected"
13
- >
14
- <option :value="organisation.id">
15
- {{ organisation.name }}
16
- </option>
17
- <option :value="-1">
18
- {{ $t('No organisation filter') }}
19
- </option>
20
- </select>
21
- <label
22
- :for="'organisation_chooser_light' + page"
23
- class="d-inline"
24
- :title="$t('select productor')"
25
- />
26
- </template>
27
- <template v-else>
28
- {{ organisation.name }}
29
- </template>
7
+ <select
8
+ :id="'organisation_chooser_light' + page"
9
+ v-model="actual"
10
+ class="mb-0 c-hand border-0"
11
+ @change="onOrganisationSelected"
12
+ >
13
+ <option :value="organisation.id">
14
+ {{ organisation.name }}
15
+ </option>
16
+ <option :value="-1">
17
+ {{ $t('No organisation filter') }}
18
+ </option>
19
+ </select>
20
+ <label
21
+ :for="'organisation_chooser_light' + page"
22
+ class="d-inline"
23
+ :title="$t('select productor')"
24
+ />
30
25
  </div>
31
26
  </template>
32
27
 
@@ -48,7 +43,6 @@ export default defineComponent({
48
43
  actual: -1 as number|string,
49
44
  organisation: undefined as Organisation|undefined,
50
45
  init: false as boolean,
51
- privateOrganisation: false as boolean
52
46
  };
53
47
  },
54
48
 
@@ -82,7 +76,6 @@ export default defineComponent({
82
76
  const data = await octopusApi.fetchOrganisation(this.value);
83
77
  this.organisation = data;
84
78
  this.actual = data.id;
85
- this.privateOrganisation = "PUBLIC"!==data.privacy;
86
79
  this.init = true;
87
80
  },
88
81
  },
@@ -177,14 +177,11 @@ export default defineComponent({
177
177
  this.$emit('update:displayMenu', false);
178
178
  },
179
179
  async onOrganisationSelected(organisation: Organisation|undefined) {
180
- const queries = this.$route.query;
181
180
  if (organisation && organisation.id) {
182
- if (queries.productor !== organisation.id) {
183
- this.$router.push({ query: {...queries, ...{productor: organisation.id} } });
184
- }
185
181
  await this.selectOrganisation(organisation.id);
186
182
  } else {
187
183
  if (this.$route.query.productor) {
184
+ const queries = this.$route.query;
188
185
  this.$router.push({ query: {...queries, ...{productor: undefined} } });
189
186
  }
190
187
  this.$store.commit('filterOrga', { orgaId: undefined });
@@ -238,15 +238,12 @@ export default defineComponent({
238
238
  }
239
239
  },
240
240
  async onOrganisationSelected(organisation: Organisation | undefined): Promise<void> {
241
- const queries = this.$route.query;
242
241
  if (organisation && organisation.id) {
243
- if (this.$route.query.productor !== organisation.id) {
244
- this.$router.push({ query: {...queries, ...{productor: organisation.id} } });
245
- }
246
242
  await this.selectOrganisation(organisation.id);
247
243
  } else {
248
244
  this.organisationId = undefined;
249
245
  if (this.$route.query.productor) {
246
+ const queries = this.$route.query;
250
247
  this.$router.push({ query: { ...queries, ...{productor: undefined} } });
251
248
  }
252
249
  this.$store.commit('filterOrga', { orgaId: undefined });
File without changes
@@ -23,6 +23,8 @@ export const orgaFilter = defineComponent({
23
23
  }),
24
24
  isLive: isLive
25
25
  });
26
+ const queries = this.$route.query;
27
+ this.$router.replace({ query: {...queries, ...{productor: organisationId} } });
26
28
  } catch (error) {
27
29
  this.handle403((error as AxiosError));
28
30
  }
@@ -23,6 +23,7 @@
23
23
  :is-search-bar="isProductorSearch"
24
24
  :sort-criteria="sortEmission"
25
25
  :organisation-id="organisationId"
26
+ :includeHidden="includeHidden"
26
27
  @updateCategory="updateCategory"
27
28
  @updateRubriquageFilter="updateRubriquageFilter"
28
29
  @updateMonetization="updateMonetization"
@@ -43,7 +44,6 @@
43
44
  :sort="sortEmission"
44
45
  :include-hidden="includeHidden"
45
46
  :iab-id="iabId"
46
-
47
47
  :rubrique-id="rubriqueId"
48
48
  :rubriquage-id="rubriquageId"
49
49
  :no-rubriquage-id="noRubriquageId"
@@ -106,6 +106,28 @@ export default defineComponent({
106
106
  titlePage(): string|undefined {
107
107
  return state.emissionsPage.titlePage;
108
108
  },
109
+ authenticated(): boolean {
110
+ return (state.generalParameters.authenticated as boolean);
111
+ },
112
+ myOrganisationId(): string|undefined {
113
+ return state.generalParameters.organisationId;
114
+ },
115
+ organisationRight(): boolean {
116
+ if (
117
+ (this.authenticated && this.myOrganisationId === this.organisationId) ||
118
+ state.generalParameters.isAdmin
119
+ )
120
+ return true;
121
+ return false;
122
+ },
123
+ filterOrga(): string|undefined {
124
+ return this.$store.state.filter.organisationId;
125
+ },
126
+ organisation(): string|undefined {
127
+ if (this.organisationId) return this.organisationId;
128
+ if (this.filterOrga) return this.filterOrga;
129
+ return undefined;
130
+ },
109
131
  },
110
132
 
111
133
  created() {
@@ -117,6 +139,9 @@ export default defineComponent({
117
139
  } else if (this.$store.state.filter.organisationId) {
118
140
  this.organisationId = this.$store.state.filter.organisationId;
119
141
  }
142
+ if (this.organisation && this.organisationRight) {
143
+ this.includeHidden = true;
144
+ }
120
145
  if(this.rubriqueFilter.length){
121
146
  this.updateRubriquageFilter(this.rubriqueFilter);
122
147
  }
@@ -35,6 +35,7 @@
35
35
  :reset-rubriquage="resetRubriquage"
36
36
  :is-search-bar="isProductorSearch"
37
37
  :sort-criteria="sortCriteria"
38
+ :includeHidden="includeHidden"
38
39
  :organisation-id="organisationId"
39
40
  @updateCategory="updateCategory"
40
41
  @updateRubriquageFilter="updateRubriquageFilter"
package/src/locale/en.ts CHANGED
@@ -70,7 +70,7 @@ export default{
70
70
  'Episode name image': "Episode {name} image",
71
71
  'More episodes of this emission': "More episodes from this series",
72
72
  'More episodes of this category : {name}': "More episodes from this category : {name}",
73
- 'All podcast emission button': "All podcast from this series",
73
+ 'All podcast emission button': "All podcasts from this series",
74
74
  Duration: 'Duration : {duration}',
75
75
  Animator: 'Host',
76
76
  'No category filter': 'No category filter',