<template>
    <currency-component section="PrimaryCurrenciesSection" primary :data="this.currency"></currency-component>
</template>

<script>
    import CurrencyComponent from "./CurrencyComponent";
    export default {
        components: {CurrencyComponent},
        data(){
          return {
              currency: {
                  country: {
                      name: '',
                      short_code: ''
                  },
                  short_code: ''
              },
          }
        },
        created(){
            this.submit(this.route('api.currency.primary.show'), 'get', 'PrimaryCurrenciesSection', false, false)
        },
        methods: {
            successHandler(response){
                this.currency = response.payload.data;
            }
        }

    }
</script>
