<template>
  <div style="display:flex">
    <div style="flex:2">
      <el-table :data="NotReportedPatient" stripe style="width: 100%">
        <el-table-column prop="username" label="患者姓名" />
        <el-table-column prop="gender" label="性别" />
        <el-table-column prop="phonenumber" label="联系方式" />
        <el-table-column prop="userid" style="width: 1px" ></el-table-column>
        <el-table-column label="操作">
          <template #default="scope">
            <el-button size="small" type="" @click="remind(scope.row)">一键提醒</el-button>
          </template>
        </el-table-column>
      </el-table>
    </div>
  </div>
</template>

<script>
import request from "@/utils/request";

export default {
  name: "NotReported",
  mounted:function (){
    this.loadNotReported();
  },
  data(){
    return{
      NotReportedPatient:[
        {

        }
      ]
    }
  },
  methods:{
    loadNotReported(){
      request.get("/worker/selectNoReport").then(res=>{this.NotReportedPatient=res.data})
    },
    remind(row){
      request.get("/sendMessage",{params:{
        senderid:"111111111111111111",
            message:"您今日尚未上报健康数据",
            receiverid:row.userid
      }})
    }
  }
}
</script>

<style scoped>

</style>