Vue.component('fangshi-detail-6', {
    template: `<div class="mt40">
    <button class="button" @click="editBtn()">编辑</button>
    <p class="c-f20 mb10" style="text-align: center;">新生儿家庭访视记录表</p>
    <div class="ui-grid p10 setradio">
        <div class="ui-col-1">
            <div class="ui-grid">
                <div class="ui-col-0">姓名:</div>
                <div class="ui-col-1">
                    <el-input :readonly="!editable" v-model="newbornData.sick_NAME" placeholder="" clearable></el-input>
                </div>
            </div>
        </div>
        <div class="ui-col-1">
            <div class="ui-grid">
                <div class="ui-col-0">户籍:&emsp;</div>
                <div class="ui-col-1">
                    <el-radio-group v-model="newbornData.help_ORGANIZATION_FLAG" :disabled="!editable">
                        <el-radio label="1" :disabled="!editable">本市</el-radio>
                        <el-radio label="2" :disabled="!editable">省内</el-radio>
                        <el-radio label="3" :disabled="!editable">省外</el-radio>
                    </el-radio-group>
                </div>
            </div>
        </div>
        <div class="ui-col-1">
            <div class="ui-grid">
                <div class="ui-col-0">卡号:</div>
                <div class="ui-col-1">
                    <el-input :readonly="!editable" v-model="newbornData.number_NO" placeholder="" clearable></el-input>
                </div>

            </div>
        </div>
    </div>
    <table class="table table-bordered">
        <tr>
            <td class="col-w120 c-t-center">性别</td>
            <td>
                <el-radio-group v-model="newbornData.sick_SEX">
                    <div>
                        <el-radio :disabled="!editable" label="0">未知的性别</el-radio>
                        <el-radio :disabled="!editable" label="1">男</el-radio>
                    </div>
                    <div class="mt10">
                        <el-radio :disabled="!editable" label="2">女</el-radio>
                        <el-radio :disabled="!editable" label="9">未说明的性别</el-radio>
                    </div>
                </el-radio-group>
            </td>
            <td colspan="2">
                <div class="ui-grid">
                    <div class="ui-col-0">
                        出生日期:
                    </div>
                    <div class="ui-col-1">
                        <el-date-picker :readonly="!editable" v-model="newbornData.birthday" type="date" placeholder="选择日期">
                        </el-date-picker>
                    </div>
                </div>
            </td>
            <td>
                <div class="ui-grid">
                    <div class="ui-col-0">
                        户籍地址:
                    </div>
                    <div class="ui-col-1">
                        <el-input :readonly="!editable" v-model="newbornData.permanent_RESIDENCE_ADDRESS" placeholder="" clearable></el-input>
                    </div>
                </div>

            </td>
        </tr>
        <tr>
            <td class="col-w120 c-t-center">母亲身份证号</td>
            <td>
                <el-input :readonly="!editable" v-model="newbornData.mother_IDENTITY_CARD_NO" placeholder="" clearable></el-input>
            </td>
            <td class="c-t-center">家庭住址</td>
            <td colspan="2">
                <el-input :readonly="!editable" v-model="newbornData.mother_ADDRESS" placeholder="" clearable></el-input>
            </td>
        </tr>
        <tr>
            <td class="col-w120 c-t-center">母 亲</td>
            <td>
                <div class="ui-grid">
                    <div class="ui-col-0">
                        姓名
                    </div>
                    <div class="ui-col-1">
                        <el-input :readonly="!editable" v-model="newbornData.mother_NAME" placeholder="" clearable></el-input>
                    </div>
                </div>
            </td>
            <td>
                <div class="ui-grid">
                    <div class="ui-col-0">
                        职业
                    </div>
                    <div class="ui-col-1">
                        <el-input :readonly="!editable" v-model="newbornData.mother_OCCUPATION" placeholder="" clearable></el-input>
                    </div>
                </div>
            </td>
            <td>
                <div class="ui-grid">
                    <div class="ui-col-0">
                        联系电话
                    </div>
                    <div class="ui-col-1">
                        <el-input type="number" :readonly="!editable" v-model="newbornData.mother_PHONE" placeholder=""></el-input>
                    </div>
                </div>
            </td>
            <td>
                <div class="ui-grid">
                    <div class="ui-col-0">
                        出生日期
                    </div>
                    <div class="ui-col-1">
                        <el-date-picker :readonly="!editable" v-model="newbornData.mother_BIRTHDAY" type="date" placeholder="选择日期">
                        </el-date-picker>
                    </div>
                </div>
            </td>
        </tr>
        <tr>
            <td class="col-w120 c-t-center">父 亲</td>
            <td>
                <div class="ui-grid">
                    <div class="ui-col-0">
                        姓名
                    </div>
                    <div class="ui-col-1">
                        <el-input :readonly="!editable" v-model="newbornData.father_NAME" placeholder="" clearable></el-input>
                    </div>
                </div>
            </td>
            <td>
                <div class="ui-grid">
                    <div class="ui-col-0">
                        职业
                    </div>
                    <div class="ui-col-1">
                        <el-input :readonly="!editable" v-model="newbornData.father_OCCUPATION" placeholder="" clearable></el-input>
                    </div>
                </div>
            </td>
            <td>
                <div class="ui-grid">
                    <div class="ui-col-0">
                        联系电话
                    </div>
                    <div class="ui-col-1">
                        <el-input type="number" :readonly="!editable" v-model="newbornData.father_PHONE"></el-input>
                    </div>
                </div>
            </td>
            <td>
                <div class="ui-grid">
                    <div class="ui-col-0">
                        出生日期
                    </div>
                    <div class="ui-col-1">
                        <el-date-picker :readonly="!editable" v-model="newbornData.father_BIRTHDAY" type="date" placeholder="选择日期">
                        </el-date-picker>
                    </div>
                </div>
            </td>
        </tr>
        <tr>
            <td colspan="2" class="setinput c-t-center">出生孕周
                <el-input style="width:70px;" type="number" :readonly="!editable" v-model="newbornData.birth_PREGNANCY_WEEK"></el-input>
                周
            </td>
            <td colspan="3">
                <div class="ui-grid">
                    <div class="ui-col-0">
                        母亲妊娠期患病情况：
                    </div>
                    <div class="ui-col-1">
                        <el-radio-group v-model="newbornData.pregnancy_SICK">
                            <el-radio :disabled="!editable" label="1">糖尿病</el-radio>
                            <el-radio :disabled="!editable" label="2">妊娠期高血压</el-radio>
                            <el-radio :disabled="!editable" label="3" class="setinput">其他
                                <el-input type="text" :readonly="pregnancy_SICK_CIRCS_other||!editable" v-model="newbornData.pregnancy_SICK_CIRCS" clearable></el-input>
                            </el-radio>
                        </el-radio-group>
                    </div>
                </div>
            </td>
        </tr>
        <tr>
            <td class="col-w120 c-t-center setinput">助产机构名称:
                <el-input style="width:120px;" type="text" :readonly="!editable" v-model="newbornData.help_ORGANIZATION_NAME" clearable></el-input>
            </td>
            <td class="c-t-center">
                出院时间
                <div class="setPicker">
                    <el-date-picker :readonly="!editable" v-model="newbornData.discharged_DATE" type="date"  value-format="yyyy-MM-dd" placeholder="选择日期">
                    </el-date-picker>
                </div>
            </td>
            <td colspan="2">
                出生情况：
                <el-checkbox-group v-model="delivery_WAY_check" :disabled="!editable">
                    <el-checkbox style="margin-left: 30px;" label="1">顺产</el-checkbox>
                    <el-checkbox label="2">胎头吸引</el-checkbox>
                    <el-checkbox label="3">产钳</el-checkbox>
                    <el-checkbox label="4">剖宫</el-checkbox>
                    <el-checkbox label="5">双多胎</el-checkbox>
                    <el-checkbox label="6">臀位</el-checkbox>
                    <el-checkbox class="setinput" label="7">
                        <el-input type="text" :readonly="birth_OTHER||!editable" v-model="newbornData.birth_OTHER" placeholder="其他" clearable></el-input>
                    </el-checkbox>
                </el-checkbox-group>

            </td>
            <td>
                新生儿窒息:
                <el-radio-group v-model="newbornData.suffocation" :disabled="!editable">
                    <el-radio :disabled="!editable" label="1">无</el-radio>
                    <el-radio :disabled="!editable" label="2">有</el-radio>
                </el-radio-group>
                <div class="setinput">
                    （Apgar 评分：1分钟
                    <el-input style="width:70px;" type="number" :readonly="!editable" v-model="newbornData.apgar_O"></el-input>分，5分钟
                    <el-input style="width:70px;" type="number" :readonly="!editable" v-model="newbornData.apgar_F"></el-input>分，不详
                    <el-input style="width:70px;" type="number" :readonly="!editable" v-model="newbornData.apgar_N"></el-input>）
                </div>
            </td>
        </tr>
        <tr>
            <td colspan="2" class="c-t-center">新生儿病史:
                <el-input :readonly="!editable" v-model="newbornData.blessedevent_MEDICAL_HISTORY" placeholder="" clearable></el-input>
            </td>
            <td class="c-t-center">诊治机构:
                <el-input :readonly="!editable" v-model="newbornData.help_OUT_ORGANIZATION" placeholder="" clearable></el-input>
            </td>
            <td colspan="2">计划免疫情况:
                <el-radio-group v-model="newbornData.plan_IMMUNE">
                    <el-radio :disabled="!editable" label="1">卡介苗</el-radio>
                    <el-radio :disabled="!editable" label="2">乙肝疫苗</el-radio>
                    <el-radio :disabled="!editable" label="3">以上两种</el-radio>
                    <el-radio :disabled="!editable" label="4">未种</el-radio>
                </el-radio-group>
            </td>
        </tr>
        <tr>
            <td colspan="2">
                <div class="ui-grid">
                    <div class="ui-col-0">
                        新生儿出生体重:
                    </div>
                    <div class="ui-col-1 setinput">
                        <el-input style="width: 70px;" type="number" :readonly="!editable" v-model="newbornData.blessedevent_BIRTH_WEIGHT" :step="0.1"></el-input>
                        kg
                    </div>
                </div>
            </td>
            <td>
                <div class="ui-grid">
                    <div class="ui-col-0">
                        出生身长:
                    </div>
                    <div class="ui-col-1 setinput">
                        <el-input style="width: 70px;" type="number" :readonly="!editable" v-model="newbornData.birth_BODY_LENGTH"></el-input>cm
                    </div>
                </div>
            </td>
            <td colspan="2">是否有畸形：
                <el-radio-group :disabled="!editable" v-model="newbornData.deformity_NULL">
                    <el-radio :disabled="!editable" label="1">无</el-radio>
                    <el-radio :disabled="!editable" label="2">有</el-radio>
                </el-radio-group>
            </td>
        </tr>
        <tr>
            <td class="c-t-center" colspan="5">
                *********** 第二次访视以上八行信息不需要重复填写 ***********
            </td>
        </tr>
        <tr>
            <td colspan="5">
                新生儿疾病筛查：
                <el-checkbox-group v-model="SCREENING_check" :disabled="!editable">
                    <el-checkbox label="1">未进行</el-checkbox>
                    <el-checkbox label="2">检查均阴性</el-checkbox>
                    <el-checkbox label="3">甲低</el-checkbox>
                    <el-checkbox label="4">苯丙酮尿症</el-checkbox>
                    <el-checkbox label="5" class="setinput">其他遗传代谢病
                        <el-input style="width: 100px;" type="text" :readonly="SCREENING_3_dis||!editable" v-model="newbornData.screening_ABNORMAL"
                            clearable></el-input>
                    </el-checkbox>
                    <el-checkbox label="6">已查无结果</el-checkbox>
                </el-checkbox-group>
            </td>
        </tr>
        <tr>
            <td colspan="4">
                新生儿听力筛查：
                <el-radio-group :disabled="!editable" v-model="newbornData.hearing">
                    <el-radio :disabled="!editable" label="1">通过</el-radio>
                    <el-radio :disabled="!editable" label="2">未通过</el-radio>
                    <el-radio :disabled="!editable" label="3">未筛查</el-radio>
                    <el-radio :disabled="!editable" label="4">不详</el-radio>
                    <el-radio :disabled="!editable" label="5">已查无结果</el-radio>
                </el-radio-group>
            </td>
            <td colspan="1" class="setinput">
                目前体重
                <el-input style="width: 70px;" type="number" :readonly="!editable" v-model="newbornData.now_WEIGHT"></el-input>
                kg
            </td>
        </tr>
        <tr>
            <td colspan="3">
                喂养方式：
                <el-radio-group :disabled="!editable" v-model="newbornData.feed_TYPE">
                    <el-radio :disabled="!editable" label="1">纯母乳</el-radio>
                    <el-radio :disabled="!editable" label="2">部分母乳</el-radio>
                    <el-radio :disabled="!editable" label="3">人工</el-radio>
                </el-radio-group>
            </td>
            <td colspan="1" class="setinput">
                吃奶量
                <el-input style="width: 70px;" type="number" :readonly="!editable" v-model="newbornData.eat_MILE_AMOUNT"></el-input> ml/次
            </td>
            <td colspan="1" class="setinput">
                吃奶次数
                <el-input style="width: 70px;" type="number" :readonly="!editable" v-model="newbornData.eat_MILE_TIME"></el-input>次/日
            </td>
        </tr>
        <tr>
            <td colspan="3">
                呕吐：
                <el-radio-group :disabled="!editable" v-model="newbornData.vomit">
                    <el-radio :disabled="!editable" v-model="radio" label="1">无</el-radio>
                    <el-radio :disabled="!editable" v-model="radio" label="2">有</el-radio>
                </el-radio-group>
            </td>
            <td colspan="1">
                大便：
                <el-radio-group :disabled="!editable" v-model="newbornData.vulnus">
                    <el-radio :disabled="!editable" v-model="radio" label="1">糊状</el-radio>
                    <el-radio :disabled="!editable" v-model="radio" label="2">稀</el-radio>
                    <el-radio :disabled="!editable" v-model="radio" label="3">其他</el-radio>
                </el-radio-group>
            </td>
            <td colspan="1" class="setinput">
                大便次数
                <el-input style="width: 70px;" type="number" :readonly="!editable" v-model="newbornData.vulnus_TIME"></el-input> 次/日
            </td>
        </tr>
        <tr>
            <td colspan="3" class="setinput">
                体温：
                <el-input style="width: 70px;" type="number" :readonly="!editable" v-model="newbornData.body_TEMPERATURE"></el-input>
                ℃
            </td>
            <td colspan="1" class="setinput">
                心率：
                <el-input style="width: 70px;" type="number" :readonly="!editable" v-model="newbornData.pulse_FREQUENCY"></el-input>
                次/分钟
            </td>
            <td colspan="1" class="setinput">
                呼吸频率
                <el-input style="width: 70px;" type="number" :readonly="!editable" v-model="newbornData.breath_FREQUENCY"></el-input>
                次/分钟
            </td>
        </tr>
        <tr>
            <td colspan="3">面色：
                <el-radio-group :disabled="!editable" v-model="newbornData.complexion">
                    <el-radio :disabled="!editable" label="1">红润</el-radio>
                    <el-radio :disabled="!editable" label="2">黄染</el-radio>
                    <el-radio :disabled="!editable" label="3" class="setinput">其他
                        <el-input style="width: 120px;" type="text" :readonly="complexion_NULL_dis||!editable" v-model="newbornData.complexion_NULL"
                            clearable></el-input>
                    </el-radio>
                </el-radio-group>
            </td>
            <td colspan="2">黄疸部位：
                <el-radio-group :disabled="!editable" v-model="newbornData.face">
                    <el-radio :disabled="!editable" label="1">面部</el-radio>
                    <el-radio :disabled="!editable" label="2">躯干</el-radio>
                    <el-radio :disabled="!editable" label="3">四肢</el-radio>
                    <el-radio :disabled="!editable" label="4">手足</el-radio>
                </el-radio-group>
            </td>
        </tr>
        <tr>
            <td colspan="5" class="setinput">
                前囟
                <el-input style="width: 70px;" type="number" :readonly="!editable" v-model="newbornData.bregma_FRONT"></el-input>
                &nbsp;cm&nbsp;✖
                <el-input style="width: 70px;" type="number" :readonly="!editable" v-model="newbornData.bregma_BACK"></el-input> &nbsp;cm &emsp;
                <el-radio-group :disabled="!editable" v-model="newbornData.bregma">
                    <el-radio :disabled="!editable" label="1">正常</el-radio>
                    <el-radio :disabled="!editable" label="2">膨隆</el-radio>
                    <el-radio :disabled="!editable" label="3">凹陷</el-radio>
                    <el-radio :disabled="!editable" label="4">其他
                <el-input style="width: 120px;" type="text" :readonly="bregma_other_dis||!editable" v-model="newbornData.bregma_PERFORMANCE"
                    clearable></el-input>
                </el-radio>
                </el-radio-group>
            </td>
        </tr>
        <tr>
            <td class="table2Td" colspan="5">
                <table class="table2">
                    <tr>
                        <td>眼外观：
                            <el-radio-group :disabled="!editable" v-model="newbornData.eye">
                                <el-radio :disabled="!editable" label="1">未见异常</el-radio>
                                <el-radio :disabled="!editable" label="2" class="setinput">异常
                                    <el-input type="text" :readonly="eye_NULL_dis||!editable" v-model="newbornData.eye_NULL" clearable></el-input>
                                </el-radio>
                            </el-radio-group>
                        </td>
                        <td>四肢活动度：
                            <el-radio-group :disabled="!editable" v-model="newbornData.limbs">
                                <el-radio :disabled="!editable" label="1">未见异常</el-radio>
                                <el-radio :disabled="!editable" label="2" class="setinput">异常
                                    <el-input type="text" :readonly="limbs_NULL_dis||!editable" v-model="newbornData.limbs_NULL" clearable></el-input>
                                </el-radio>
                            </el-radio-group>
                        </td>
                    </tr>
                    <tr>
                        <td>耳外观：
                            <el-radio-group :disabled="!editable" v-model="newbornData.ear">
                                <el-radio :disabled="!editable" label="1">未见异常</el-radio>
                                <el-radio :disabled="!editable" label="2" class="setinput">异常
                                    <el-input type="text" :readonly="ear_FACE_dis||!editable" v-model="newbornData.ear_FACE" clearable></el-input>
                                </el-radio>
                            </el-radio-group>
                        </td>
                        <td>颈部包块：
                            <el-radio-group :disabled="!editable" v-model="newbornData.neck_PACK">
                                <el-radio :disabled="!editable" label="1">无</el-radio>
                                <el-radio :disabled="!editable" label="2" class="setinput">有
                                    <el-input type="text" :readonly="neck_PACK_NULL_dis||!editable" v-model="newbornData.neck_PACK_NULL" clearable></el-input>
                                </el-radio>
                            </el-radio-group>
                        </td>
                    </tr>
                    <tr>
                        <td>鼻：
                            <el-radio-group :disabled="!editable" v-model="newbornData.nose">
                                <el-radio :disabled="!editable" label="1">未见异常</el-radio>
                                <el-radio :disabled="!editable" label="2" class="setinput">异常
                                    <el-input type="text" :readonly="nose_PERFORMANCE_dis||!editable" v-model="newbornData.nose_PERFORMANCE" clearable></el-input>
                                </el-radio>
                            </el-radio-group>
                        </td>
                        <td>皮肤：
                            <el-radio-group :disabled="!editable" v-model="newbornData.skin">
                                <el-radio :disabled="!editable" label="1">未见异常</el-radio>
                                <el-radio :disabled="!editable" label="2">湿疹</el-radio>
                                <el-radio :disabled="!editable" label="3">糜烂</el-radio>
                                <el-radio :disabled="!editable" label="4" class="setinput">其他
                                    <el-input type="text" :readonly="skin_PERFORMANCE_dis||!editable" v-model="newbornData.skin_PERFORMANCE" clearable></el-input>
                                </el-radio>
                            </el-radio-group>
                        </td>
                    </tr>
                    <tr>
                        <td>口腔：
                            <el-radio-group :disabled="!editable" v-model="newbornData.oral">
                                <el-radio :disabled="!editable" label="1">未见异常</el-radio>
                                <el-radio :disabled="!editable" label="2" class="setinput">异常
                                    <el-input type="text" :readonly="oral_PERFORMANCE_dis||!editable" v-model="newbornData.oral_PERFORMANCE" clearable></el-input>
                                </el-radio>
                            </el-radio-group>
                        </td>
                        <td>肛门：
                            <el-radio-group :disabled="!editable" v-model="newbornData.anus">
                                <el-radio :disabled="!editable" label="1">未见异常</el-radio>
                                <el-radio :disabled="!editable" label="2" class="setinput">异常
                                    <el-input type="text" :readonly="anus_PERFORMANCE_dis||!editable" v-model="newbornData.anus_PERFORMANCE" clearable></el-input>
                                </el-radio>
                            </el-radio-group>
                        </td>
                    </tr>
                    <tr>
                        <td>心肺听诊：
                            <el-radio-group :disabled="!editable" v-model="newbornData.heart">
                                <el-radio :disabled="!editable" label="1">未见异常</el-radio>
                                <el-radio :disabled="!editable" label="2" class="setinput">异常
                                    <el-input type="text" :readonly="heart_PERFORMANCE_dis||!editable" v-model="newbornData.heart_PERFORMANCE" clearable></el-input>
                                </el-radio>
                            </el-radio-group>
                        </td>
                        <td>外生殖器：
                            <el-radio-group :disabled="!editable" v-model="newbornData.genitalia">
                                <el-radio :disabled="!editable" label="1">未见异常</el-radio>
                                <el-radio :disabled="!editable" label="2" class="setinput">异常
                                    <el-input type="text" :readonly="genitalia_NULL_dis||!editable" v-model="newbornData.genitalia_NULL" clearable></el-input>
                                </el-radio>
                            </el-radio-group>
                        </td>
                    </tr>
                    <tr>
                        <td>腹部触诊：
                            <el-radio-group :disabled="!editable" v-model="newbornData.abdomen">
                                <el-radio :disabled="!editable" label="1">未见异常</el-radio>
                                <el-radio :disabled="!editable" label="2" class="setinput">异常
                                    <el-input type="text" :readonly="abdomen_NULL_dis||!editable" v-model="newbornData.abdomen_NULL" clearable></el-input>
                                </el-radio>
                            </el-radio-group>
                        </td>
                        <td>脊柱：
                            <el-radio-group :disabled="!editable" v-model="newbornData.vertebral">
                                <el-radio :disabled="!editable" label="1">未见异常</el-radio>
                                <el-radio :disabled="!editable" label="2" class="setinput">异常
                                    <el-input type="text" :readonly="vertebral_NULL_dis||!editable" v-model="newbornData.vertebral_NULL" clearable></el-input>
                                </el-radio>
                            </el-radio-group>
                        </td>
                    </tr>
                    <tr>
                        <td>脐带：
                            <el-radio-group :disabled="!editable" v-model="newbornData.umbilical">
                                <el-radio :disabled="!editable" v-model="radio" label="1">未脱</el-radio>
                                <el-radio :disabled="!editable" v-model="radio" label="2">脱落</el-radio>
                                <el-radio :disabled="!editable" v-model="radio" label="3">脐部有渗出</el-radio>
                                <el-radio :disabled="!editable" v-model="radio" label="4" class="setinput">其他
                                    <el-input type="text" style="width:120px" :readonly="umbilical_NULL_dis||!editable" v-model="newbornData.umbilical_NULL" clearable></el-input>
                                </el-radio>
                            </el-radio-group>
                        </td>
                        <td class="setinput">
                            <div class="ui-grid">
                                <div class="ui-col-0">其他：</div>
                                <div class="ui-col-1">
                                    <el-input type="text" :readonly="!editable" v-model="newbornData.other" clearable></el-input>
                                </div>
                            </div>
                        </td>
                    </tr>
                </table>
            </td>
        </tr>
        <tr>
            <td colspan="5">
                转诊意见:
                <el-radio-group :disabled="!editable" v-model="newbornData.referral">
                    <el-radio :disabled="!editable" v-model="radio" label="1">无</el-radio>
                    <el-radio :disabled="!editable" v-model="radio" label="2">有</el-radio>
                </el-radio-group>

                <div class="setinput ui-grid">
                    <div class="ui-col-0">
                        原因：
                    </div>
                    <div class="ui-col-1">
                        <el-input type="text" :readonly="!editable" v-model="newbornData.referral_reason" clearable></el-input>
                    </div>
                </div>
                <div class="ui-grid">
                    <div class="ui-col-1 ui-grid setinput">
                        <div class="ui-col-0">
                            机构:
                        </div>
                        <div class="ui-col-1">
                            <el-input type="text" :readonly="!editable" v-model="newbornData.organization_org_name" clearable></el-input>
                        </div>
                    </div>
                    <div class="ui-col-1 ui-grid setinput">
                        <div class="ui-col-0">
                            科室:
                        </div>
                        <div class="ui-col-1">
                            <el-input type="text" :readonly="!editable" v-model="newbornData.organization" clearable></el-input>
                        </div>
                    </div>
                </div>
            </td>
        </tr>
        <tr>
            <td colspan="5" class="setinput">
                <div class="ui-grid">
                    <div class="ui-col-0">
                        指导：
                    </div>
                    <div class="ui-col-1">
                        <el-checkbox-group v-model="guide_check" :disabled="!editable">
                            <el-checkbox label="1">喂养指导</el-checkbox>
                            <el-checkbox label="2">发育指导</el-checkbox>
                            <el-checkbox label="3">防病指导</el-checkbox>
                            <el-checkbox label="4">预防伤害指导</el-checkbox>
                            <el-checkbox label="5">口腔保健指导</el-checkbox>
                            <el-checkbox label="6">其他
                                <el-input type="text" :readonly="other_GUIDE_CONTENT_dis||!editable" v-model="newbornData.other_GUIDE_CONTENT" clearable></el-input>
                            </el-checkbox>
                        </el-checkbox-group>
                    </div>
                </div>
            </td>
        </tr>
        <tr>
            <td colspan="2">
                <div class="ui-grid">
                    <div class="ui-col-0">
                        本次访视日期
                    </div>
                    <div class="ui-col-1">
                        <el-date-picker :readonly="!editable" v-model="newbornData.this_INTERVIEW_DATE" type="date" placeholder="选择日期">
                        </el-date-picker>
                    </div>
                </div>

            </td>
            <td colspan="3">
                <div class="ui-grid">
                    <div class="ui-col-0">
                        下次随访地点
                    </div>
                    <div class="ui-col-1">
                        <el-input :readonly="!editable" v-model="newbornData.next_VISITING_ADDRESS" placeholder="" clearable></el-input>
                    </div>
                </div>
            </td>
        </tr>
        <tr>
            <td colspan="2">
                <div class="ui-grid">
                    <div class="ui-col-0">
                        下次访视日期
                    </div>
                    <div class="ui-col-1">
                        <el-date-picker :readonly="!editable" v-model="newbornData.next_VISITING_DATE" type="date" placeholder="选择日期">
                        </el-date-picker>
                    </div>
                </div>
            </td>
            <td colspan="3">
                <div class="ui-grid">
                    <div class="ui-col-1 ui-grid setinput">
                        <div class="ui-col-0">
                            随访医生签名:
                        </div>
                        <div class="ui-col-1">
                            <el-input type="text" :readonly="!editable" v-model="newbornData.visiting_DOCTOR" clearable></el-input>
                        </div>
                    </div>
                    <div class="ui-col-1 ui-grid setinput">
                        <div class="ui-col-0">
                            家属确认签字:
                        </div>
                        <div class="ui-col-1">
                            <el-input type="text" :readonly="!editable" v-model="newbornData.family_SIGN" clearable></el-input>
                        </div>
                    </div>
                </div>
            </td>
        </tr>
    </table>
    </div>
        `,
    props: ['followupid', 'version'],
    data: function () {
        return {
            editable: false,
            isEditBtn: true,
            birth_OTHER: true,
            pregnancy_SICK_CIRCS_other: true,
            SCREENING_3_dis: true,
            bregma_other_dis: true,
            eye_NULL_dis: true,
            limbs_NULL_dis: true,
            complexion_NULL_dis: true,
            ear_FACE_dis: true,
            neck_PACK_NULL_dis: true,
            nose_PERFORMANCE_dis: true,
            skin_PERFORMANCE_dis: true,
            oral_PERFORMANCE_dis: true,
            anus_PERFORMANCE_dis: true,
            heart_PERFORMANCE_dis: true,
            genitalia_NULL_dis: true,
            abdomen_NULL_dis: true,
            vertebral_NULL_dis: true,
            umbilical_NULL_dis: true,
            other_GUIDE_CONTENT_dis: true,
            delivery_WAY_check: [],
            SCREENING_check: [],
            guide_check: [],
            data2: "",
            radio: "",
            input: '',
            name: '',
            number: '',
            newbornData: {}
        }
    },
    computed: {
        pregnancy_SICK: function () {
            return this.newbornData.pregnancy_SICK
        },
        bregma: function () {
            return this.newbornData.bregma
        },
        complexion: function () {
            return this.newbornData.complexion
        },
        eye: function () {
            return this.newbornData.eye
        },
        limbs: function () {
            return this.newbornData.limbs
        },
        neck_PACK: function () {
            return this.newbornData.neck_PACK
        },
        ear: function () {
            return this.newbornData.ear
        },
        nose: function () {
            return this.newbornData.nose
        },
        skin: function () {
            return this.newbornData.skin
        },
        oral: function () {
            return this.newbornData.oral
        },
        anus: function () {
            return this.newbornData.anus
        },
        heart: function () {
            return this.newbornData.heart
        },
        genitalia: function () {
            return this.newbornData.genitalia
        },
        abdomen: function () {
            return this.newbornData.abdomen
        },
        vertebral: function () {
            return this.newbornData.vertebral
        },
        umbilical: function () {
            return this.newbornData.umbilical
        }

    },
    watch: {
        umbilical: function (i) {
            var a = i ? i.toString().indexOf('4') : ''
            if (a > -1) {
                this.umbilical_NULL_dis = false
            } else {
                this.umbilical_NULL_dis = true
                this.newbornData.umbilical_NULL = ''
            }
        },
        vertebral: function (i) {
            var a = i ? i.toString().indexOf('2') : ''
            if (a > -1) {
                this.vertebral_NULL_dis = false
            } else {
                this.vertebral_NULL_dis = true
                this.newbornData.vertebral_NULL = ''
            }
        },
        abdomen: function (i) {
            var a = i ? i.toString().indexOf('2') : ''
            if (a > -1) {
                this.abdomen_NULL_dis = false
            } else {
                this.abdomen_NULL_dis = true
                this.newbornData.abdomen_NULL = ''
            }
        },
        genitalia: function (i) {
            var a = i ? i.toString().indexOf('2') : ''
            if (a > -1) {
                this.genitalia_NULL_dis = false
            } else {
                this.genitalia_NULL_dis = true
                this.newbornData.genitalia_NULL = ''
            }
        },
        heart: function (i) {
            var a = i ? i.toString().indexOf('2') : ''
            if (a > -1) {
                this.heart_PERFORMANCE_dis = false
            } else {
                this.heart_PERFORMANCE_dis = true
                this.newbornData.heart_PERFORMANCE = ''
            }
        },
        anus: function (i) {
            var a = i ? i.toString().indexOf('2') : ''
            if (a > -1) {
                this.anus_PERFORMANCE_dis = false
            } else {
                this.anus_PERFORMANCE_dis = true
                this.newbornData.anus_PERFORMANCE = ''
            }
        },
        oral: function (i) {
            var a = i ? i.toString().indexOf('2') : ""
            if (a > -1) {
                this.oral_PERFORMANCE_dis = false
            } else {
                this.oral_PERFORMANCE_dis = true
                this.newbornData.oral_PERFORMANCE = ''
            }
        },
        skin: function (i) {
            var a = i ? i.toString().indexOf('4') : ''
            if (a > -1) {
                this.skin_PERFORMANCE_dis = false
            } else {
                this.skin_PERFORMANCE_dis = true
                this.newbornData.skin_PERFORMANCE = ''
            }

        },
        nose: function (i) {
            var a = i ? i.toString().indexOf('2') : ''
            if (a > -1) {
                this.nose_PERFORMANCE_dis = false
            } else {
                this.nose_PERFORMANCE_dis = true
                this.newbornData.nose_PERFORMANCE = ''
            }
        },
        neck_PACK: function (i) {
            var a = i ? i.toString().indexOf('2') : ''
            if (a > -1) {
                this.neck_PACK_NULL_dis = false
            } else {
                this.neck_PACK_NULL_dis = true
                this.newbornData.neck_PACK_NULL = ''
            }

        },
        limbs: function (i) {
            var a = i ? i.toString().indexOf('2') : ''
            if (a > -1) {
                this.limbs_NULL_dis = false
            } else {
                this.limbs_NULL_dis = true
                this.newbornData.limbs_NULL = ''
            }
        },
        ear: function (i) {
            var a = i ? i.toString().indexOf('2') : ''
            if (a > -1) {
                this.ear_FACE_dis = false
            } else {
                this.ear_FACE_dis = true
                this.newbornData.ear_FACE = ''
            }
        },
        limbs: function (i) {
            var a = i ? i.toString().indexOf('2') : ''
            if (a > -1) {
                this.limbs_NULL_dis = false
            } else {
                this.limbs_NULL_dis = true
                this.newbornData.limbs_NULL = ''
            }
        },
        eye: function (i) {
            var a = i ? i.toString().indexOf('2') : ''
            if (a > -1) {
                this.eye_NULL_dis = false
            } else {
                this.eye_NULL_dis = true
                this.newbornData.eye_NULL = ''
            }
        },
        pregnancy_SICK: function (i) {
            var a = i ? i.toString().indexOf('3') : ''
            if (a > -1) {
                this.pregnancy_SICK_CIRCS_other = false
            } else {
                this.pregnancy_SICK_CIRCS_other = true
                this.newbornData.pregnancy_SICK_CIRCS = ''
            }
        },
        bregma: function (i) {
            var a = i ? i.toString().indexOf('4') : ''
            if (a > -1) {
                this.bregma_other_dis = false
            } else {
                this.bregma_other_dis = true
                this.newbornData.bregma_PERFORMANCE = ''

            }
        },
        complexion: function (i) {
            var a = i ? i.toString().indexOf('3') : ''
            if (a > -1) {
                this.complexion_NULL_dis = false
            } else {
                this.complexion_NULL_dis = true
                this.newbornData.complexion_NULL = ''
            }
        },
        delivery_WAY_check: function (i) {
            var a = i ? i.toString().indexOf('7') : ''
            if (a > -1) {
                this.birth_OTHER = false
            } else {
                this.birth_OTHER = true
                this.newbornData.birth_OTHER = ''
            }
        },
        SCREENING_check: function (i) {
            var a = i ? i.toString().indexOf('5') : ''
            if (a > -1) {
                this.SCREENING_3_dis = false
            } else {
                this.SCREENING_3_dis = true
                this.newbornData.screening_ABNORMAL = ''
            }
        },
        guide_check: function (i) {
            var a = i.toString().indexOf('6')
            if (a > -1) {
                this.other_GUIDE_CONTENT_dis = false
            } else {
                this.other_GUIDE_CONTENT_dis = true
                this.other_GUIDE_CONTENT = ''
            }
        }
    },

    mounted: function () {
        this.getData()
    },
    methods: {
        getData: function () {
            var vm = this
            fangshiAPI.getNewbornFamilyVisitRecord({ followupId: this.followupid || '2' }).then(function (res) {
                if (res.status == 200) {
                    var data = res.data
                    if (data != null) {
                        vm.newbornData = data
                        var vmN = vm.newbornData
                        vmN.help_ORGANIZATION_FLAG = data.help_ORGANIZATION_FLAG ? data.help_ORGANIZATION_FLAG.toString() : ''
                        vmN.sick_SEX = data.sick_SEX ? data.sick_SEX.toString() : ''
                        vmN.pregnancy_SICK = data.pregnancy_SICK?data.pregnancy_SICK.toString():''
                        vm.delivery_WAY_check = data.delivery_WAY ? data.delivery_WAY.split(',') : [];
                        vmN.suffocation = data.suffocation ? data.suffocation.toString() : ''
                        vmN.plan_IMMUNE = data.plan_IMMUNE ? data.plan_IMMUNE.toString() : ''
                        vmN.deformity_NULL = data.deformity_NULL ? data.deformity_NULL.toString() : ''
                        vmN.hearing = data.hearing ? data.hearing.toString() : ''
                        vmN.feed_TYPE = data.feed_TYPE ? data.feed_TYPE.toString() : ''
                        vmN.vomit = data.vomit ? data.vomit.toString() : ''
                        vmN.vulnus = data.vulnus ? data.vulnus.toString() : ''
                        vmN.vulnus_TIME = data.vulnus_TIME ? data.vulnus_TIME.toString() : ''
                        vmN.body_TEMPERATURE = data.body_TEMPERATURE ? data.body_TEMPERATURE.toString() : ""
                        vmN.complexion = data.complexion ? data.complexion.toString() : ""
                        vmN.face = data.face ? data.face.toString() : ''
                        vmN.bregma = data.bregma ? data.bregma.toString() : ''
                        vmN.eye = data.eye ? data.eye.toString() : ''
                        vmN.limbs = data.limbs ? data.limbs.toString() : ''
                        vmN.ear = data.ear ? data.ear.toString() : ''
                        vmN.nose = data.nose ? data.nose.toString() : ''
                        vmN.neck_PACK = data.neck_PACK ? data.neck_PACK.toString() : ''
                        vmN.skin = data.skin ? data.skin.toString() : ""
                        vmN.oral = data.oral ? data.oral.toString() : ''
                        vmN.anus = data.anus ? data.anus.toString() : ""
                        vmN.heart = data.heart ? data.heart.toString() : ''
                        vmN.genitalia = data.genitalia ? data.genitalia.toString() : ''
                        vmN.abdomen = data.abdomen ? data.abdomen.toString() : ""
                        vmN.vertebral = data.vertebral ? data.vertebral.toString() : ''
                        vmN.referral = data.referral ? data.referral.toString() : ''
                        vmN.umbilical = data.umbilical ? data.umbilical.toString() : ''
                        if (data.screening_4 == 1) {
                            vm.SCREENING_check.push('1')
                        } if (data.screening_5 == 1) {
                            vm.SCREENING_check.push('2')
                        } if (data.screening_1 == 1) {
                            vm.SCREENING_check.push('3')
                        } if (data.screening_2 == 1) {
                            vm.SCREENING_check.push('4')
                        } if (data.screening_3 == 1) {
                            vm.SCREENING_check.push('5')
                        } if (data.screening_6 == 1) {
                            vm.SCREENING_check.push('6')
                        }

                        if (data.feed_GUID == 1) {
                            vm.guide_check.push('1')
                        } if (data.growup_GUID == 1) {
                            vm.guide_check.push('2')
                        } if (data.prevention_DEFORMITY_GUID == 1) {
                            vm.guide_check.push('3')
                        } if (data.prevention_HURT_GUID == 1) {
                            vm.guide_check.push('4')
                        } if (data.oral_CAVITY_GUID == 1) {
                            vm.guide_check.push('5')
                        } if (data.other_GUIDE == 1) {
                            vm.guide_check.push('6')
                        }

                    }

                } else {
                    top.toastr.error(res.msg);
                }
            })
        },
        editData: function () {
            var vm = this
            var vmN = this.newbornData
            vmN.delivery_WAY = vm.delivery_WAY_check.join(',')
            vm.SCREENING_check.map(i => {
                if (i == '1') {
                    vmN.screening_4 = 1
                } if (i == '2') {
                    vmN.screening_5 = 1
                } if (i == '3') {
                    vmN.SCREENING_3 = 1
                } if (i == '4') {
                    vmN.screening_2 = 1
                } if (i == '5') {
                    vmN.screening_3 = 1
                } if (i == '6') {
                    vmN.screening_6 = 1
                }
            })
            vm.guide_check.map(i => {
                if (i == '1') {
                    vmN.feed_GUID = 1
                } if (i == '2') {
                    vmN.growup_GUID = 1
                } if (i == '3') {
                    vmN.prevention_DEFORMITY_GUID = 1
                } if (i == '4') {
                    vmN.prevention_HURT_GUID = 1
                } if (i == '5') {
                    vmN.oral_CAVITY_GUID = 1
                } if (i == '6') {
                    vmN.other_GUIDE = 1
                }
            })
            vmN.create_time = null
            vmN.version = this.version
            fangshiAPI.saveNewbornFamilyVisitRecord({ followupId: this.followupid || '2', newbornFamilyVisitRecordData: JSON.stringify(vmN) }).then(function (res) {
                if (res.status == 200) {
                    top.toastr.info('保存成功')
                } else {
                    top.toastr.error(res.msg);
                }
            })
        },
        editBtn: function () {
            this.isEditBtn = !this.isEditBtn
            if (this.isEditBtn == true) {
                var btn = document.getElementsByClassName('button')[2]
                btn.innerHTML = '编辑'
                this.editable = false
                this.editData()
            } else if (this.isEditBtn == false) {
                var btn = document.getElementsByClassName('button')[2]
                btn.innerHTML = '保存'
                this.editable = true
            }
        }
    }

})