<!-- Page de détails d'un IBAN (Edit mode) -->

<template>
  <main>
    <v-skeleton-loader
      v-if="fetchState.pending"
      type="text"
    />
    <FormOrganizationBankAccount :id="id" v-else></FormOrganizationBankAccount>
  </main>
</template>

<script lang="ts">
import {defineComponent, useContext} from '@nuxtjs/composition-api'
import {useDataUtils} from "~/composables/data/useDataUtils";
import {BankAccount} from "~/models/Core/BankAccount";

export default defineComponent({
  name: 'EditBankAccount',
  setup () {
    const {$dataProvider, route} = useContext()
    const {getItemToEdit} = useDataUtils($dataProvider)
    const {id, fetchState} = getItemToEdit(route, BankAccount)

    return {
      id,
      fetchState
    }
  }
})
</script>
<style>
</style>
