<template>


  <div>
    <!--  客户信息-->
    <a-page-header
      style="background-color: #FFFFFF;margin-bottom:10px"
      title="入网信息登记详情"
      sub-title=""
      @back="back"
    >
      <a-descriptions :title="model.phone" :column="3" :bordered="false">
        <a-descriptions-item label="创建人">{{ model.createBy }}</a-descriptions-item>
        <a-descriptions-item label="创建时间">{{ model.createTime }}</a-descriptions-item>
        <a-descriptions-item label="更新人">{{ model.updateBy }}</a-descriptions-item>
        <a-descriptions-item label="更新时间">{{ model.updateTime }}</a-descriptions-item>
        <a-descriptions-item label="研判结果" :span="2">{{ model.numberResults == 1 ? '非高危' :  model.numberResults  == 2 ? '已报蓝紫名单' : '已报关停'}}</a-descriptions-item>
      </a-descriptions>
    </a-page-header>


    <!--  入网信息登记表单-->
    <a-card style="margin-bottom:10px">
      <div>
        <a-form-model
          ref="form"
          :label-col="labelCol"
          :wrapper-col="wrapperCol"
          :model="model"
          :rules="rules"
        >
          <div>
            <a-divider orientation="left">填写营业厅入网提示卡
            </a-divider>
            <a-row>
              <a-col :span="8">
                <a-form-model-item label="拨测联系电话" prop="userOpenState" v-bind="labelCol2">
                  <span style="color: #0a0a09">{{model.phone}}</span>
                </a-form-model-item>
              </a-col>


              <a-col :span="8">
                <a-form-model-item label="联电归属地" prop="userOpenState" v-bind="labelCol2">
                  <span style="color: #0a0a09">{{model.address}}</span>
                </a-form-model-item>
              </a-col>
            </a-row>

            <a-row>
              <a-col :span="12">
                <a-form-model-item label="拨测结果" prop="userOpenState" v-bind="labelCol1Results">
                  <a-radio-group :disabled="true" v-model="model.calltestResults" button-style="solid">
                    <a-radio value="1">关机</a-radio>
                    <a-radio value="2">未接通</a-radio>
                    <a-radio value="3">可接通不知晓入网事宜</a-radio>
                    <a-radio value="4">可接通认可办理</a-radio>
                  </a-radio-group>
                </a-form-model-item>
              </a-col>
            </a-row>

            <a-row>
              <a-col :span="8">
                <a-form-model-item label="证件地址(到村/小区)" prop="userOpenState" v-bind="labelCol2">
                  <span style="color: #0a0a09">{{model.idCardAddress}}</span>
                </a-form-model-item>
              </a-col>
              <a-col :span="8">
                <a-form-model-item label="现住地址(到村/小区)" prop="userOpenState" v-bind="labelCol2">
                  <span style="color: #0a0a09">{{model.currentAddress}}</span>
                </a-form-model-item>
              </a-col>
            </a-row>

            <a-row>
              <a-col :span="8">
                <a-form-model-item label="客户现用号码" prop="userOpenState" v-bind="labelCol2">
                  <a-radio-group :disabled="true" v-model="model.operator" button-style="solid">
                    <a-radio value="1">本地运营商</a-radio>
                    <a-radio value="2">异地运营商</a-radio>
                  </a-radio-group>
                </a-form-model-item>
              </a-col>
              <a-col :span="8">
                <a-form-model-item label="运营商类型" prop="userOpenState" v-bind="labelCol2">
                  <a-radio-group :disabled="true" v-model="model.operatorType" button-style="solid">
                    <a-radio value="1">移动</a-radio>
                    <a-radio value="2">联通</a-radio>
                    <a-radio value="3">电信</a-radio>
                    <a-radio value="4">其他</a-radio>
                  </a-radio-group>
                </a-form-model-item>
              </a-col>
            </a-row>

            <a-row>
              <a-col :span="8">
                <a-form-model-item label="现用号码使用年限" prop="userOpenState" v-bind="labelCol2">
                  <a-radio-group v-model="model.useLife" button-style="solid">
                    <span style="color: #0a0a09">{{model.useLife}}</span>
                  </a-radio-group>
                </a-form-model-item>
              </a-col>
              <a-col :span="8">
                <a-form-model-item label="现用号码使用用途" prop="userOpenState" v-bind="labelCol2">
                  <a-radio-group v-model="model.phonePurpose" button-style="solid">
                    <span style="color: #0a0a09">{{model.phonePurpose}}</span>
                  </a-radio-group>
                </a-form-model-item>
              </a-col>
            </a-row>
          </div>


        </a-form-model>
      </div>
    </a-card>
    <!--    排查内容-->
    <a-card style="margin-bottom:10px">
      <div>
        <a-divider orientation="left">排查内容</a-divider>
        <a-list size="large" bordered>
          <template>
            <a-list-item>
              <a-col :span="12">
                <a-form-model-item label="1、客户名下无电信号码" prop="userOpenState" v-bind="labelCol1Pro">
                  <a-radio-group :disabled="true" v-model="model.isDxNumber" button-style="solid">
                    <span style="color: #0a0a09">{{model.isDxNumber == 1 ? '是' : '否' }}</span>
                  </a-radio-group>
                </a-form-model-item>

                <a-form-model-item label="备注" prop="userOpenState" v-bind="labelCol1Pro">
                  <span style="color: #0a0a09">{{model.isDxNumberNote}}</span>
                </a-form-model-item>
              </a-col>
            </a-list-item>

            <a-list-item>
              <a-col :span="12">
                <a-form-model-item label="2、申请号码办理征信类、融合宽带业务" prop="userOpenState" v-bind="labelCol1ProMax">
                  <a-radio-group v-model="model.isBroadband" button-style="solid">
                    <span style="color: #0a0a09">{{model.isBroadband == 1 ? '是' : '否' }}</span>
                  </a-radio-group>
                </a-form-model-item>

                <a-form-model-item label="备注" prop="userOpenState" v-bind="labelCol1Pro">
                  <span style="color: #0a0a09">{{model.isBroadbandNote}}</span>
                </a-form-model-item>
              </a-col>
            </a-list-item>

            <a-list-item>
              <a-col :span="12">
                <a-form-model-item label="3、申请号码使用用途异常" prop="userOpenState" v-bind="labelCol1Pro">
                  <a-radio-group v-model="model.isUseTo" button-style="solid">
                    <span style="color: #0a0a09">{{model.isUseTo == 1 ? '是' : '否' }}</span>
                  </a-radio-group>
                </a-form-model-item>

                <a-form-model-item label="备注" prop="userOpenState" v-bind="labelCol1Pro">
                  <span style="color: #0a0a09">{{model.isUseToNote}}</span>
                </a-form-model-item>
              </a-col>
            </a-list-item>

            <a-list-item>
              <a-col :span="12">
                <a-form-model-item label="4、客户名下号码存在异常高频率充值、退费" prop="userOpenState" v-bind="labelCol1ProMax">
                  <a-radio-group v-model="model.isRefund" button-style="solid">
                    <span style="color: #0a0a09">{{model.isRefund == 1 ? '是' : '否' }}</span>
                  </a-radio-group>
                </a-form-model-item>

                <a-form-model-item label="备注" prop="userOpenState" v-bind="labelCol1Pro">
                  <span style="color: #0a0a09">{{model.userOpenState}}</span>
                </a-form-model-item>
              </a-col>
            </a-list-item>

            <a-list-item>
              <a-col :span="12">
                <a-form-model-item label="5、客户名下已有号码（含已注销号码）存在各类关停" prop="userOpenState" v-bind="labelCol1ProMax">
                  <a-radio-group v-model="model.isShutDown" button-style="solid">
                    <span style="color: #0a0a09">{{model.isShutDown == 1 ? '是' : '否' }}</span>
                  </a-radio-group>
                </a-form-model-item>

                <a-form-model-item label="备注" prop="userOpenState" v-bind="labelCol1Pro">
                  <span style="color: #0a0a09">{{model.isShutDownNote}}</span>
                </a-form-model-item>
              </a-col>
            </a-list-item>

            <a-list-item>
              <a-col :span="12">
                <a-form-model-item label="6、客户名下在用号码无使用记录，仍要求新办号码" prop="userOpenState" v-bind="labelCol1ProMax">
                  <a-radio-group v-model="model.isNewly" button-style="solid">
                    <span style="color: #0a0a09">{{model.isNewly == 1 ? '是' : '否' }}</span>
                  </a-radio-group>
                </a-form-model-item>

                <a-form-model-item label="备注" prop="userOpenState" v-bind="labelCol1Pro">
                  <span style="color: #0a0a09">{{model.isNewlyNote}}</span>
                </a-form-model-item>
              </a-col>
            </a-list-item>

            <a-list-item>
              <a-col :span="12">
                <a-form-model-item label="7、在多个渠道多频次入网的异常情况" prop="userOpenState" v-bind="labelCol1ProMax">
                  <a-radio-group v-model="model.isChannel" button-style="solid">
                    <span style="color: #0a0a09">{{model.isChannel == 1 ? '是' : '否' }}</span>
                  </a-radio-group>
                </a-form-model-item>

                <a-form-model-item label="备注" prop="userOpenState" v-bind="labelCol1Pro">
                  <span style="color: #0a0a09">{{model.isChannelNote}}</span>
                </a-form-model-item>
              </a-col>
            </a-list-item>

            <a-list-item>
              <a-col :span="12">
                <a-form-model-item label="8、黑名单到期客户新入网的高危疑似涉诈号码" prop="userOpenState" v-bind="labelCol1ProMax">
                  <a-radio-group v-model="model.isInvolvingFraud" button-style="solid">
                    <span style="color: #0a0a09">{{model.isInvolvingFraud == 1 ? '是' : '否' }}</span>
                  </a-radio-group>
                </a-form-model-item>

                <a-form-model-item label="备注" prop="userOpenState" v-bind="labelCol1Pro">
                  <span style="color: #0a0a09">{{model.isInvolvingFraudNote}}</span>
                </a-form-model-item>
              </a-col>
            </a-list-item>


          </template>
        </a-list>
      </div>
    </a-card>
    <!--    研判结果-->
    <a-card style="margin-bottom:10px">
      <div>
        <a-divider orientation="left">研判结果</a-divider>
        <a-col :span="12">
          <a-form-model-item label="是否将高危号码上报蓝、紫名单或不可复开关停" prop="userOpenState" v-bind="labelCol1ProMaxPlus">
            <a-radio-group disabled v-model="model.numberResults" button-style="solid">
              <a-radio value="1">非高危</a-radio>
              <a-radio value="2">已报蓝紫名单</a-radio>
              <a-radio value="3">已报关停</a-radio>
            </a-radio-group>
          </a-form-model-item>
        </a-col>
      </div>
    </a-card>


  </div>
</template>

<script>
import {httpAction, postAction, getAction} from "@api/manage";

export default {
  name: "registrationDetails",
  inject: ['closeCurrent'],
  data() {
    return {
      addIng: false,
      url: {
        "add": "/businessReminderCard/add",
        "editById": "/businessReminderCard/editById",
        "queryById": "/businessReminderCard/queryById",
      },
      labelCol: {span: 2},
      wrapperCol: {span: 23},
      // 1列
      labelCol1: {
        labelCol: {
          xs: {span: 24},
          sm: {span: 2},
        },
        wrapperCol: {
          xs: {span: 24},
          sm: {span: 21},
        }
      },
      labelCol1Pro: {
        labelCol: {
          span: 8
        },
        wrapperCol: {
          span: 15
        }
      },
      labelCol1Results: {
        labelCol: {
          span: 5
        },
        wrapperCol: {
          span: 15
        }
      },
      labelCol1ProMax: {
        labelCol: {
          span: 8
        },
        wrapperCol: {
          span: 15
        }
      },
      labelCol1ProMaxPlus: {
        labelCol: {
          span: 12
        },
        wrapperCol: {
          span: 12
        }
      },
      // 2列
      labelCol2: {
        labelCol: {
          span: 7
        },
        wrapperCol: {
          span: 16
        }
      },
      //表单验证
      rules: {},
      //表单信息
      model: {
        id: null,
        phone: null,
      },
    }
  },
  created() {
    this.model.id = this.$route.query.id;
  },
  mounted() {
    this.queryById();
  },
  methods: {
    back(){
      //关闭当前页
      this.$router.go(-1);
      this.closeCurrent();
    },

    /**获取详情*/
    queryById() {
      let that = this;
      let data = {
        "id": that.model.id
      }
      getAction(that.url.queryById, data).then((res) => {
        if (res.success) {
          let result = res.result;
          if (result != null) {
            for (var i in result) {
              that.model[i] = result[i] == null ? null : result[i].toString();
            }
          }
        }
      })
    },


    /**充值表单*/
    clearModel() {
      this.model = {}
      this.current = 0;
    },
  },
}
</script>

<style scoped>

</style>