Spamworldpro Mini Shell
Spamworldpro


Server : Apache
System : Linux server2.corals.io 4.18.0-348.2.1.el8_5.x86_64 #1 SMP Mon Nov 15 09:17:08 EST 2021 x86_64
User : corals ( 1002)
PHP Version : 7.4.33
Disable Function : exec,passthru,shell_exec,system
Directory :  /home/corals/ts.corals.io/frontend/components/Reports/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : /home/corals/ts.corals.io/frontend/components/Reports/BaseReportTable.vue
<template>
  <div>
    <h6>{{ title }}</h6>
    <b-skeleton-table v-if="!data"
                      :rows="4"
                      :columns="4"
                      :table-props="{ bordered: true, striped: true }">
    </b-skeleton-table>
    <div class="table-responsive" v-else>
      <table class="table table-striped table-condensed">
        <tr v-for="(Record,Index) in data" :key="Index"
            :class="getRowClass(Record,Index)">
          <template v-if="Index === 'no_data'">
            <td :colspan="Object.keys(data.header).length" class="text-center">
              No Data Found
            </td>
          </template>
          <template v-for="(value,key) in Record">
            <td v-if="value.code ==='nav_to'">
              <nuxt-link :to="value.attr.route + '?period='+ form.period+(form.client_name ? '&client='+form.client_name : '')
              +(form.project_name? '&project='+form.project_name : '')">
                {{ value.attr.label }}
              </nuxt-link>
            </td>
            <td v-else>
              {{ value }}
            </td>
          </template>
        </tr>
      </table>
    </div>
  </div>
</template>

<script>
export default {
  name: 'BaseReportTable',
  components: {},
  props: {
    title: {
      required: true
    },
    data: {
      required: true,
    },
    form: {
      required: true
    },
  },
  methods: {
    getRowClass(Record, Index) {
      if (Index === 'header') {
        return 'bg-secondary text-white';
      }

      if (Index === 'footer') {
        return 'bg-info text-white';
      }
    },
  }
}
</script>

Spamworldpro Mini