1
0
Fork 0
mirror of https://gitlab.com/bramw/baserow.git synced 2025-04-05 21:55:24 +00:00
bramw_baserow/web-frontend/modules/database/components/view/grid/GridViewHeader.vue
2021-04-08 14:30:26 +00:00

60 lines
1.3 KiB
Vue

<template>
<ul v-if="!tableLoading" class="header__filter header__filter--full-width">
<li class="header__filter-item">
<GridViewHide
:view="view"
:fields="fields"
:read-only="readOnly"
:store-prefix="storePrefix"
></GridViewHide>
</li>
<li class="header__filter-item header__filter-item--right">
<ViewSearch
:view="view"
:fields="fields"
:primary="primary"
:store-prefix="storePrefix"
@refresh="$emit('refresh', $event)"
></ViewSearch>
</li>
</ul>
</template>
<script>
import { mapState } from 'vuex'
import GridViewHide from '@baserow/modules/database/components/view/grid/GridViewHide'
import ViewSearch from '@baserow/modules/database/components/view/ViewSearch'
export default {
name: 'GridViewHeader',
components: { GridViewHide, ViewSearch },
props: {
view: {
type: Object,
required: true,
},
fields: {
type: Array,
required: true,
},
primary: {
type: Object,
required: true,
},
readOnly: {
type: Boolean,
required: true,
},
storePrefix: {
type: String,
required: true,
},
},
computed: {
...mapState({
tableLoading: (state) => state.table.loading,
}),
},
}
</script>