package com.lantone.qc.kernel.catalogue.yiwu.behospitalized;

import com.lantone.qc.kernel.catalogue.QCCatalogue;
import com.lantone.qc.kernel.util.CatalogueUtil;
import com.lantone.qc.pub.model.InputInfo;
import com.lantone.qc.pub.model.OutputInfo;
import org.springframework.stereotype.Component;

import java.util.Map;


/**
 * @ClassName : BEH0424
 * @Description :  入院记录联系电话未填写
 * @Author : 楼辉荣
 * @Date: 2020-03-06 17:28
 */
@Component
public class BEH0424 extends QCCatalogue {
    public void start(InputInfo inputInfo, OutputInfo outputInfo) {
        status.set("0");
        if (inputInfo.getBeHospitalizedDoc() == null) {
            return;
        }
        Map<String, String> structureMap = inputInfo.getBeHospitalizedDoc().getStructureMap();
        if(structureMap != null){
            //String phone = structureMap.get("电话");
            String contactNumber = structureMap.get("联系电话");
            if(/*CatalogueUtil.isEmpty(phone) && */CatalogueUtil.isEmpty(contactNumber)){
                status.set("-1");
            }
        }

    }
}