2019-10-05 20:01:06 +02:00
|
|
|
<template>
|
|
|
|
<div id="pricing">
|
2021-01-04 22:11:11 +01:00
|
|
|
<div class="loading" v-if="!products.length">
|
2021-06-01 22:46:15 +02:00
|
|
|
<span>{{ $t('default.Loading…') }}</span>
|
2019-10-05 20:01:06 +02:00
|
|
|
</div>
|
|
|
|
<Product
|
|
|
|
v-else
|
2021-01-04 22:11:11 +01:00
|
|
|
v-for="product in products"
|
2019-10-05 20:01:06 +02:00
|
|
|
v-bind:key="product.uuid"
|
|
|
|
:product="product"
|
|
|
|
/>
|
|
|
|
</div>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
<script>
|
|
|
|
|
|
|
|
import Product from 'vuejs/components/Content/Product'
|
|
|
|
import { mapState, mapActions } from 'vuex'
|
|
|
|
|
|
|
|
export default {
|
|
|
|
name: "Pricing",
|
|
|
|
// data() {
|
|
|
|
// return {
|
|
|
|
// items:[],
|
|
|
|
// page:0
|
|
|
|
// }
|
|
|
|
// },
|
|
|
|
computed: {
|
|
|
|
...mapState({
|
2021-01-04 22:11:11 +01:00
|
|
|
products: state => state.Pages.products
|
2019-10-05 20:01:06 +02:00
|
|
|
})
|
|
|
|
},
|
|
|
|
created(){
|
2021-01-04 22:11:11 +01:00
|
|
|
if(!this.products.length)
|
|
|
|
this.getProducts()
|
2019-10-05 20:01:06 +02:00
|
|
|
},
|
|
|
|
methods: {
|
|
|
|
...mapActions({
|
2021-01-04 22:11:11 +01:00
|
|
|
getProducts: 'Pages/getProducts'
|
2019-10-05 20:01:06 +02:00
|
|
|
})
|
|
|
|
},
|
|
|
|
components: {
|
|
|
|
Product
|
|
|
|
}
|
|
|
|
}
|
|
|
|
</script>
|
|
|
|
<style lang="scss" scoped>
|
|
|
|
</style>
|