Browse Source

fix après merge

Vincent GUFFON 4 years ago
parent
commit
8c5ff46645
2 changed files with 10 additions and 3 deletions
  1. 5 3
      pages/subscription.vue
  2. 5 0
      yarn.lock

+ 5 - 3
pages/subscription.vue

@@ -338,7 +338,7 @@ Page 'Mon abonnement'
 import { defineComponent, useFetch, useContext, ref, Ref } from '@nuxtjs/composition-api'
 import { $organizationProfile } from '~/services/profile/organizationProfile'
 import { QUERY_TYPE } from '~/types/enums'
-import { DolibarrAccount, MobytUserStatus } from '~/types/interfaces'
+import {ApiResponse, DolibarrAccount, MobytUserStatus} from '~/types/interfaces'
 
 export default defineComponent({
   name: 'Subscription',
@@ -352,10 +352,11 @@ export default defineComponent({
     // fetch the dolibarr account's data
     useFetch(async () => {
       try {
-        dolibarrAccount.value = await $dataProvider.invoke({
+        const reponse:ApiResponse = await $dataProvider.invoke({
           type: QUERY_TYPE.DEFAULT,
           url: 'dolibarr/account/' + id
         })
+        dolibarrAccount.value = reponse.data as DolibarrAccount
       } catch (Error) {
         // eslint-disable-next-line no-console
         console.error('Error: Dolibarr account not found')
@@ -365,10 +366,11 @@ export default defineComponent({
     // fetch the mobyt status
     useFetch(async () => {
       try {
-        mobytStatus.value = await $dataProvider.invoke({
+        const reponse:ApiResponse = await $dataProvider.invoke({
           type: QUERY_TYPE.DEFAULT,
           url: 'mobyt/status/' + id
         })
+        mobytStatus.value = reponse.data as MobytUserStatus
       } catch (Error) {
         // eslint-disable-next-line no-console
         console.error('Error: Mobyt status not found')

+ 5 - 0
yarn.lock

@@ -12937,6 +12937,11 @@ vuetify-loader@^1.7.2:
     file-loader "^6.2.0"
     loader-utils "^2.0.0"
 
+vuetify@^2.2.11:
+  version "2.5.13"
+  resolved "https://registry.yarnpkg.com/vuetify/-/vuetify-2.5.13.tgz#b04f52f8c3f5713a43a25dc5be6945cd2676ec82"
+  integrity sha512-MfEkGq+wR3oa/BjHgonACp21aihgM17pCs7YBAsa/w87VnLKRgds1v/Rgtcq/pkIIH7yTV+XG3icQWpRgrKCiQ==
+
 vuetify@^2.5.3:
   version "2.5.10"
   resolved "https://registry.yarnpkg.com/vuetify/-/vuetify-2.5.10.tgz#165cb3de9dbffbc94bc775aa2f698eb9fa89eabe"