<template>
  <div>
    <!-- //扣分明细弹框 -->
    <DialogCom title="扣分明细" width="1200px" :visible.sync="monthNum">
      <el-form :inline="true" class="demo-form-inline">
        <el-row>
          <el-col :span="8">
            <el-form-item label="上级机构1">
              {{ monthNumeData.firstOrgName }}
            </el-form-item>
          </el-col>
          <el-col :span="8">
            <el-form-item label="上级机构2">
              {{ monthNumeData.secondOrgName }}
            </el-form-item>
          </el-col>
          <el-col :span="8">
            <el-form-item label="营业场所">
              {{ monthNumeData.orgTypeText }}
            </el-form-item>
          </el-col>
        </el-row>
        <el-row>
          <el-col :span="8">
            <el-form-item label="年月"> {{ monthNumeData.date }} </el-form-item>
          </el-col>
          <el-col :span="8">
            <el-form-item label="指标分类">
              {{ typeName }}
            </el-form-item>
          </el-col>
          <el-col :span="8">
            <el-form-item label=""> </el-form-item>
          </el-col>
        </el-row>
      </el-form>
      <el-table
        border
        height="650"
        pageSize="small"
        v-loading="loading"
        :data="itemTableList"
        align="center"
        fixed
      >
        <el-table-column label="事件单号" prop="id"> </el-table-column>
        <el-table-column label="事件名称" prop="taskName"> </el-table-column>
        <el-table-column label="执行机构" prop="orgName"> </el-table-column>
<!--        <el-table-column label="执行人员" prop="execManName"> </el-table-column>-->
        <el-table-column label="执行岗位" prop="execPostName"> </el-table-column>
        <el-table-column label="计划开始时间" prop="planTimeStart">
        </el-table-column>
        <el-table-column label="计划结束时间" prop="planTimeEnd">
        </el-table-column>
<!--        <el-table-column label="执行开始时间" prop="execTimeStart">
        </el-table-column>
        <el-table-column label="执行结束时间" prop="execTimeEnd">
        </el-table-column>
        <el-table-column label="状态" prop="execStatusText"> </el-table-column>-->
      </el-table>
      <div slot="footer" class="dialog-footer">
        <!-- <el-button type="primary" @click="onSubmit">确定</el-button> -->
        <el-button @click="onHide">关闭</el-button>
      </div>
    </DialogCom>
  </div>
</template>
<script>
import { getBysingleData } from "@/api/scorestatistics/scorestatistics.js";
export default {
  name: "SocWebPointsDialog",
  props: {
    monthNumeData: {},
  },
  data() {
    return {
      monthNum: false,
      typeName:'',
      loading:false,
      itemTableList: [],
    };
  },

  mounted() {},

  methods: {
    init(row) {
      this.monthNum = true;
      this.typeName=row.typeName
      this.loading=true
      getBysingleData({
        orgId: this.monthNumeData.orgId,
        date: this.monthNumeData.date,
        typeCode: row.typeCode,
      }).then((res) => {
        this.loading=false
        console.log(res);
        let {code,data,msg}=res
        this.itemTableList=data||[]
      });
    },
    onHide(){
      this.monthNum = false;
      this.itemTableList=[]
    }
  },
};
</script>
<style lang="scss" scoped></style>
