<template>
  <CTitlePage
    :ind="ind"
    :table="table"
    :showBarSelection="showBarSelection"
    @clickButtBar="clickButtBar"
  >
    <div class="bi-border-all">
      <div class="q-ma-xs q-gutter-xs">
        <div v-if="showFilterPersonal" class="text-center">
          <q-btn-toggle
            v-if="myoptions.length > 0"
            v-model="myrecfiltertoggle"
            push
            glossy
            toggle-color="primary"
            :options="myoptions"
          />
        </div>

        <CGridTableRec
          ref="myGridRef"
          v-if="searchList.length > 0"
          :prop_mytable="table"
          :options="tools.optionsTable(table)"
          :prop_mytitlenew="tools.getTitleAnnuncio(table)"
          prop_mytitle=""
          :prop_mycolumns="col"
          :prop_colkey="prop_colkey"
          :col_title="col_title"
          :col_footer="col_footer"
          :col_tabfooter="col_tabfooter"
          :vertical="costanti.VISUTABLE_LISTA"
          :prop_pagination="mypagination"
          :showType="showType"
          :hint="hint"
          :nodataLabel="noMsgRecord"
          :prop_search="true"
          :finder="true"
          labelElemFind="trovati"
          :choose_visutype="visuType"
          :butt_modif_new="true && !noButtAdd"
          :noresultLabel="
            t('grid.nosearchfound') +
            ' ' +
            (showMap ? t('grid.intheareamap') : '')
          "
          :arrfilters="arrfilterand"
          :filtercustom="filtercustom"
          :prop_searchList="searchList"
          :defaultnewrec="tools.getdefaultnewrec(table)"
          labelBtnAddRow="NONE"
          :prop_SortFieldsAvailable="mySortFieldsAvailable()"
          :labelBtnAddExtra="labelBtnAddExtra"
          :extraparams="tools.extraparams(table, { myrecfiltertoggle })"
          :prop_showMap="showMap"
          @clickButtBar="clickButtBar"
        >
        </CGridTableRec>
      </div>

      <q-page-scroller
        position="bottom-right"
        :scroll-offset="850"
        :offset="[18, 18]"
        style="opacity: 0.3"
      >
        <q-btn fab icon="keyboard_arrow_up" color="accent" />
      </q-page-scroller>
    </div>
  </CTitlePage>
</template>

<script lang="ts" src="./CFinder.ts">
</script>
<style lang="scss" scoped>
@import "./CFinder.scss";
</style>
