<template>
  <el-col :span="10">
     <el-table :data="tableData" border>
       <el-table-column align="center" prop="note_name" :label="$t('note.table.note_name')" />
       <el-table-column align="center" prop="paper_name" :label="$t('note.table.paper_name')" />
       <el-table-column align="center" :label="$t('action')">
         <template slot-scope="scope">
           <el-button>{{$t('button.edit')}}</el-button>
           <el-button type="danger" @click="del">{{$t('button.del')}}</el-button>
         </template>
       </el-table-column>
     </el-table>

    <div class="block center mt1">
      <el-pagination
        layout="prev, pager, next"
        :total="1000">
      </el-pagination>
    </div>
  </el-col>
</template>

<script lang="ts">
  import Vue from 'vue'

  export default Vue.extend({
    name: 'note',
    data(){
      return {
        tableData:[{
            note_name:'笔记',
            paper_name: '《论文》'
        }]
      }
    },
    methods:{
      del(){
        this.$confirm(this.$t('note.tip.confirm_del').toString(),this.$t('tip').toString(),{
          confirmButtonText:this.$t('button.ok').toString(),
          cancelButtonText:this.$t('button.cancel').toString()
        })
      }
    }
  })
</script>
