<template>
    <v-layout column fill-height>


            <v-toolbar  class="pa-1 mb-2" color="blue lighten-3" dark height="50px">
              <v-toolbar-title>STATUS ANTRIAN</v-toolbar-title>
              <v-spacer></v-spacer>

            </v-toolbar>


            <v-card class="pa-1 p-left-side grow" grow>
                <v-card-text class="pa-0">
                    <v-layout row wrap>

                        <v-flex >
                        <v-data-table :headers="headers" :items="patients"   :loading="isLoading" hide-actions class="elevation-1">
                           <template slot="items" slot-scope="props">
                              <td  v-bind:class="{'amber lighten-4':props.item.selected}" @click="selectMe(props.item)">{{ props.item.layanan }}</td>
                               <td  v-bind:class="{'amber lighten-4':props.item.selected}" @click="selectMe(props.item)">{{ props.item.antrian }}</td>
                                <td  v-bind:class="{'amber lighten-4':props.item.selected}" @click="selectMe(props.item)">{{ props.item.serve }}</td>

                             </template>

                        </v-data-table>
                        </v-flex>

                    </v-layout>
                </v-card-text>



            </v-card>
    </v-layout>

</template>

<style scoped>
table.v-table tbody td,table.v-table tbody th {
   height: 40px;
}

table.v-table thead tr {
   height: 40px;
}
</style>

<script>
module.exports = {
   data() {
      return {
         query: "",
         items: [],
         headers: [
            {
               text: "Layanan",
               align: "Center",
               sortable: false,
               value: "mr",
               width: "25%",
               class: " blue lighten-4"
            },
            {
               text: "Total Antrian",
               align: "Center",
               sortable: false,
               value: "lab",
               width: "10%",
               class: "blue lighten-4"
            },
            {
               text: "Sisa Antrian",
               align: "Center",
               sortable: false,
               value: "name",
               width: "10%",
               class: "blue lighten-4"
            }
         ],


         isLoading: true,
         patients: [
         {"layanan":"Ambil Hasil","antrian":"3", "serve": "2","action":""},
         {"layanan":"Pasien Rekanan","antrian":"5", "serve": "2","action":""},
         {"layanan":"Pasien Umum","antrian":"7", "serve": "2","action":""},

       ]
      };
   }
}
</script>
