<template>
  <div>
    <div class="dialog-h-content scroll-h">

      <el-form ref="ref_form"
               :inline="true"
               :model="formData"
               class="form">

        <el-form-item label="服务类型"
                      prop="serviceTypeName"
                      label-width="150px"
                      style="display: block">
          <span>{{formData.serviceTypeName}}</span>

        </el-form-item>
        <el-form-item label="所属网格"
                      prop="gridName"
                      label-width="150px"
                      style="display: block">
          <span>{{formData.gridName}}</span>

        </el-form-item>
        <el-form-item label="申请人"
                      prop="applicantName"
                      label-width="150px"
                      style="display: block">
          <span>{{formData.areaCovered}}</span>

        </el-form-item>
        <el-form-item label="住址"
                      prop="capacity"
                      label-width="150px"
                      style="display: block">
          <span>{{formData.applicantAddress}}</span>
        </el-form-item>
        <el-form-item label="服务内容："
                      prop="principal"
                      label-width="150px"
                      style="display: block">
          <span>{{formData.applicantContent}}</span>
        </el-form-item>
        <el-form-item label="联系电话："
                      prop="mobile"
                      label-width="150px"
                      style="display: block">
          <span>{{formData.applicantMobile}}</span>
        </el-form-item>
        <el-form-item label="负责人："
                      style="display: block"
                      prop="address"
                      label-width="150px">
          <span>{{formData.principalName}}</span>
        </el-form-item>
        <el-form-item label="服务时间："
                      style="display: block"
                      prop="address"
                      label-width="150px">
          <span>{{formData.serviceTime}}</span>
        </el-form-item>
        <el-form-item label="备注："
                      style="display: block"
                      prop="address"
                      label-width="150px">
          <span>{{formData.remark}}</span>
        </el-form-item>
      </el-form>

    </div>
    <div class="div_btn">
      <el-button size="small"
                 @click="handleCancle">取 消</el-button>
    </div>
  </div>
</template>

<script>

import { Loading } from 'element-ui' // 引入Loading服务

var infoWindowList
var geocoder // 新建一个正逆地址解析类

let loading // 加载动画
export default {
  data () {
    return {
      formData: {},
    }
  },
  components: {},
  mounted () {
  },

  methods: {
    handleCancle () {

      this.$emit('diaClose')

    },

    async initForm (row) {
      this.startLoading()
      this.formData = { ...row }
      this.endLoading()

    },

    // 开启加载动画
    startLoading () {
      loading = Loading.service({
        lock: true, // 是否锁定
        text: '正在加载……', // 加载中需要显示的文字
        background: 'rgba(0,0,0,.7)' // 背景颜色
      })
    },
    // 结束加载动画
    endLoading () {
      // clearTimeout(timer);
      if (loading) {
        loading.close()
      }
    }
  },
  computed: {
  },
  props: {

  }
}
</script>
<style lang="scss" scoped >
@import "@/assets/scss/modules/visual/communityManageForm.scss";
</style>
<style scoped>
.detail_span {
  width: 500px;
  font-weight: bold;
  text-align: left;
  margin: 0 0;
  font-size: 16px;
}

.form {
  margin-top: 30px;
}
</style>


