import moment from 'moment';
import LimitbodyCheck from '~/components/business/limitbody/model/check.js';
export default {
  data() {
    return {
      rules3: {
/*				...new LimitbodyCheck(this).check,
        ".vrfflg": null,
        "nidgrp.blk.atxexptxt": null,
        "nidgrp.blk.exptxt": null,
        "nidgrp.rec.atxinr": null,
        "nidgrp.rec.secuilflg": null,
        "nidgrp.cbs.max.cur": null,
        "nidgrp.rec.fingua": null,
        "nidgrp.con.pts.extkey": null,
        "nidgrp.con.adrelc": null,
        "nidgrp.con.namelc": null,
        "nidgrp.con.dbfadrblkcn": null,
        "nidgrp.con.pts.adrblk": null,
        "nidgrp.rec.purposin": null,
        "nidgrp.rec.liatypc": null,
        "nidgrp.blk.preper": null,
        "nidgrp.blk.atxpreper": null,
        "nidgrp.rec.expdat": [
          {
            validator: (rule, value, callback) => {
							if(this.model.nidgrp.rec.expflg == '' && !value){
								callback(new Error('必输项'))
							}else if (moment(value).diff(moment(this.model.nidgrp.rec.inudat), 'days') < 0) {
                callback(new Error('输入日期不得小于保函生效日期!'))
              } else {
                callback()
              }
            }, trigger: ['blur', 'change']
          }
        ],
        "nidgrp.rec.bdbdbr": null,
        "checknomust": [
          {
            validator: (rule, value, callback) => {
              var msg = '';
              if ( this.model.nidgrp.rec.bdbdbr == '') msg = '"被担保人法定代表人"';
              if ( this.model.nidgrp.rec.bdbrdz == '') msg = msg + '"被担保人地址"';
              if ( this.model.nidgrp.rec.bdbrdh == '') msg = msg + '"被担保人联系电话"';
              if ( this.model.nidgrp.rec.dbyhdb == '') msg = msg + '"担保银行法定代表人"';
              if ( this.model.nidgrp.rec.dbyhdz == '') msg = msg + '"担保银行地址"';
              if ( this.model.nidgrp.rec.sqrdbr == '') msg = msg + '"申请人法定代表人"';
              if ( this.model.nidgrp.rec.sqradr == '') msg = msg + '"申请人地址"';
              if ( this.model.nidgrp.rec.sqrtel == '') msg = msg + '"申请人联系电话"';
              if ( this.model.nidgrp.rec.sqqydm == '') msg = msg + '"申请人企业代码"';
              if(msg != '') {
                // this.$alert(msg + '不输入,可能被海关拒收!', '提示', {
                //   confirmButtonText: '确定',
                //   callback: action => {
                //     callback()
                //   }
                // });

                  this.$confirm(msg + '不输入,可能被海关拒收!是否继续?', '提示', {
                    confirmButtonText: '确定',
                    cancelButtonText: '取消',
                    type: 'warning'
                    }).then(() => {
                      callback()
                    }).catch(() => {
                      
                    }
                  );
              } else {
                callback()
              }
            }, trigger: 'blur'
          }
        ],
        "nidgrp.rec.expflg": null,
        "nidgrp.rec.deloric": null,
        "nidgrp.adv.adrelc": null,
        "nidgrp.adv.namelc": null,
        "nidgrp.adv.dbfadrblkcn": null,
        "cnybop.libflg": null,
        "nidgrp.rec.ownref": null,
        "nidgrp.rec.exptyp": null,
        "nidgrp.rec.orcdatc": null,
        "nidgrp.rec.stdwrduilc": null,
        "nidgrp.rec.segtyp": null,
        "nidgrp.rec.tendat": null,
        "nidgrp.rec.giduil": null,
        "nidgrp.rec.gtxinrc": null,
        "nitp.prepercmodflg": null,
        "nidgrp.apc.pts.extkey": null,
        "nidgrp.apc.adrelc": null,
        "nidgrp.apc.namelc": null,
        "nidgrp.apc.dbfadrblkcn": null,
        "nidgrp.apc.pts.adrblk": null,
        "nidgrp.rec.gartyp": null,
        "nitp.gidtxtmodflg": null,
        "nidgrp.bec.pts.extkey": null,
        "nidgrp.bec.adrelc": null,
        "nidgrp.bec.namelc": null,
        "nidgrp.bec.dbfadrblkcn": null,
        "nidgrp.bec.pts.adrblk": null,
        "nidgrp.rec.revflg": null,
        "nitp.prepermodflg": null,
        "nidgrp.ben.pts.adrblk": null,
        "nidgrp.blk.gtxgidtxtc": null,
        "nidgrp.rec.gtxinr": null,
        "nidgrp.blk.gtxgidtxt": null,
        "nidgrp.blk.gidtxt": null,
        "nidgrp.cnr.pts.extkey": null,
        "nidgrp.cnr.adrelc": null,
        "nidgrp.cnr.namelc": null,
        "nidgrp.cnr.dbfadrblkcn": null,
        "nidgrp.cnr.pts.adrblk": null,
        "nidgrp.apl.adrelc": null,
        "nidgrp.apl.namelc": null,
        "nidgrp.apl.dbfadrblkcn": null,
        "nitp.covgodsrvcmodflg": null,
        "nidgrp.rec.autrnwflgc": null,
        "nidgrp.atb.pts.extkey": null,
        "nidgrp.rec.stdwrdc": null,
        "nidgrp.ben.pts.extkey": null,
        "nidgrp.rec.orcdat": null,
        "nidgrp.rec.orcratc": null,
        "nidgrp.cbs.mac.cur": null,
        "nidgrp.rec.orcamtc": null,
        "nidgrp.cbs.mac.amt": null,
        "nidgrp.rec.bustyp": null,
        "nidgrp.blk.gidtxtc": null,
				"nidgrp.rec.mannum": null,
				"addbcb.label5":  [
					{type: "string",validator: (rule, value, callback) => {
            if (this.model.addbcb.label5 == '') {
              callback(new Error('必输项'))
            } else {
              callback()
            }
          }, trigger: 'change'} ,
				],
				"addbcb.label6":  [
					{type: "string",validator: (rule, value, callback) => {
            if (this.model.addbcb.label6 == '') {
              callback(new Error('必输项'))
            } else {
              callback()
            }
          }, trigger: 'change'} ,
        ],
				"nidgrp.bdb.pts.extkey": [
					{  type: "string",validator: (rule, value, callback) => {
            // if (this.model.nidgrp.rec.fenlishi!='') {
            //   callback(new Error('必输项'))
            // } else {
              callback()
            //}
          }, trigger: 'change'},
				],
				"nidgrp.bdb.pts.nam": [
					{  type: "string",validator: (rule, value, callback) => {
            if (this.model.nidgrp.rec.fenlishi!='' && this.model.nidgrp.bdb.pts.nam =='') {
              callback(new Error('必输项'))
            } else {
              callback()
            }
          }, trigger: 'change'},
        ],
        "nidgrp.rec.orccur": null,
        "nitp.exptxtmodflg": null,
        "nidgrp.blk.liatxtc": null,
        "nidgrp.blk.atxliatxtc": null,
        "cnybop.vouflg": null,
        "nidgrp.atb.adrelc": null,
        "nidgrp.atb.namelc": null,
        "nidgrp.atb.dbfadrblkcn": null,
        "nidgrp.atb.pts.adrblk": null,
        "nidgrp.cbs.mac2.amt": null,
        "nitp.usr.extkey": null,
        "nidgrp.rec.liadat": null,
        "nidgrp.rec. legfrm": null,
        "nidgrp.adv.pts.adrblk": null,
        ".recp.pubp.founds7": null,
        ".recp.pubp.founds6": null,
        ".recp.pubp.founds5": null,
        ".recp.pubp.founds4": null,
        ".recp.pubp.founds8": null,
        ".recp.pubp.founds3": null,
        ".recp.pubp.founds2": null,
        ".recp.pubp.founds1": null,
        ".recgrp.bas.thyn": null,
        "nidgrp.iss.pts.extkey": null,
        "nidgrp.iss.adrelc": null,
        "nidgrp.iss.namelc": null,
        "nidgrp.iss.dbfadrblkcn": null,
        "nitp.inc760": null,
        ".recgrp.bas.bencountrycode": null,
        "cnybop.traflg": null,
        "nidgrp.blk.covgodsrv": null,
        "nidgrp.blk.atxcovgodsrv": null,
        "nidgrp.blk.atxcovgodsrvc": null,
        "nidgrp.blk.covgodsrvc": null,
        "nidgrp.rec.orccurc": null,
        "nitp.gidtxtmodflgc": null,
        ".recgrp.bas.bentype": null,
        ".recgrp.bas.guarantype": null,
        ".recgrp.bas.maindebtmanner": null,
        ".dclflg": null,
        "nidgrp.rec.cnfsta": null,
        "nidgrp.cbs.cnf.amt": null,
        "nidgrp.rec.partcon": null,
        "nidgrp.cbs.cnf.cur": null,
        ".cfaflg": null,
        "nidgrp.rec.transferc": null,
        "nidgrp.rec.inudat": [
          {
            validator: (rule, value, callback) => {
            
                callback()
							
            }, trigger: ['blur', 'change']
					},
        ],
        "nidgrp.ctc.pts.extkey": null,
        "nidgrp.ctc.adrelc": null,
        "nidgrp.ctc.namelc": null,
        "nidgrp.ctc.dbfadrblkcn": null,
        "nidgrp.ctr.pts.adrblk": null,
        "nidgrp.blk.preperc": null,
        "nidgrp.blk.atxpreperc": null,
        "nidgrp.rec.gartypc": null,
        "nidgrp.rec.legfrmc": null,
        "nitp.aamp.aammod.addamtflg": null,
        "nidgrp.rec.rmbflg": null,
        "nidgrp.rec.reccnfdet": null,
        "nidgrp.ctr.pts.extkey": null,
        ".recgrp.bas.guaranamount": null,
        "addbcb.pwtyp8": null,
        "nidgrp.avc.pts.extkey": null,
        "nidgrp.rec.orddat": null,
        "addbcb.bcbtyp6": null,
        "nidgrp.ctr.adrelc": null,
        "nidgrp.ctr.namelc": null,
        "nidgrp.ctr.dbfadrblkcn": null,
        "nidgrp.rec.delori": null,
        ".recgrp.bas.cgyn": null,
        ".recgrp.bas.actiontype": null,
        ".recp.pubp.acp": null,
        "nidgrp.rec.jurlawc": null,
        "nidgrp.rec.fenlishi": null,
        "nidgrp.ctc.pts.adrblk": null,
        "nidgrp.cbs.opn1.amt": null,
        "nidgrp.rec.trmdat": null,
        "nidgrp.bdb.adrelc": null,
        "nidgrp.bdb.namelc": null,
        "nidgrp.bdb.dbfadrblkcn": null,
        "nidgrp.bdb.pts.adrblk": null,
        ".recp.pubp.cousel1.guedparecompcode": null,
        "nitp.inccormsgflg": null,
        "nidgrp.rec.aplnam": null,
        "nidgrp.avc.pts.nam": null,
        "nitp.apcsupflg": null,
        "nidgrp.rec.trmdatc": null,
        "nidgrp.rec.tendatc": null,
        "nidgrp.blk.addamtcovc": null,
        "nidgrp.cbs.mac2.cur": null,
        "nitp.aacp.aacmod.addamtflg": null,
        "nidgrp.rec.cnfdat": null,
        "nidgrp.ben.adrelc": null,
        "nidgrp.ben.namelc": null,
        "nidgrp.ben.dbfadrblkcn": null,
        "addbcb.bccls1": null,
        ".recgrp.bas.issuecountrycode": null,
        "nitp.covgodsrvmodflg": null,
        "cnybop.cnyvou.sreversecountrycode": null,
        "nidgrp.rec.liaflg": null,
        "nitp.aplsupflg": null,
        "nidgrp.rec.deltoc": null,
        "nidgrp.rec.transfer": null,
        "nidgrp.rec.stacty": null,
        ".recgrp.bas.guedcouncode": null,
        "nidgrp.blk.apprul": null,
        "nitp.drpreflg": null,
        "nidgrp.rec.tenclsdat": null,
        "nidgrp.rec.orcamt": null,
        "nidgrp.rec.cnfdet": null,
        ".basflg": null,
        "nidgrp.rec.delto": null,
        "cnybop.cnyflg": null,
        "cnybop.cnyvou.svouchercountrycode": null,
        "nidgrp.rec.orcrat": null,
        "nidgrp.iss.pts.adrblk": null,
        ".recgrp.bas.cgcouncode": null,
        ".recgrp.bas.guedtype": null,
        "nidgrp.rec.tenclsdatc": null,
        ".recgrp.bas.maindebtmaturity": null,
        ".recgrp.bas.maindebtcondate": null,
        "nidgrp.rec.aplnam": null,
        "nidgrp.rec.vrfdat": null,
        "cnybop.outflg": null,
        "cnybop.cnyvou.svoucheecountrycode": null,
        "nidgrp.rec.opndatc": null,
        "cnybop.cnyvou.sdebtorcountrycode": null,
        "cnybop.cnyvou.cvouchdirection": null,
        "nitp.lettername": null,
        "nidgrp.blk.apprulc": null,
        "nidgrp.rec.autrnwflg": null,
        "nidgrp.rec.sndto": null,
        "setmod.glemod.glepan": null,
        ".cfap": null,
        ".recp.dclp": null,
        ".recp.dclp.actiontype": null,
        ".recp.dclp.actiondesc": null,
        "cnybop.voup": null,
        "nitp.preperp": null,

        ".vrfflg": null,
        "nidgrp.rec.atxinr": null,
        "nidgrp.rec.secuilflg": null,


        "nidgrp.rec.purposin": null,
        "nidgrp.rec.liatypc": null,
        "nidgrp.rec.expflg": null,
        "nidgrp.rec.deloric": null,
        "cnybop.libflg": null,
        "nidgrp.rec.exptyp": null,
        "nidgrp.rec.stdwrduilc": null,
        "nidgrp.rec.segtyp": null,
        "nidgrp.rec.giduil": null,
        "nidgrp.rec.gtxinrc": null,
        "nitp.prepercmodflg": null,

        "nitp.gidtxtmodflg": null,
        "nidgrp.rec.revflg": null,
        "nitp.prepermodflg": null,
        "nidgrp.rec.gtxinr": null,
        "nitp.covgodsrvcmodflg": null,
        "nidgrp.rec.autrnwflgc": null,
        "nidgrp.rec.stdwrdc": null,

        "nidgrp.cbs.mac.cur": null,
        "nidgrp.rec.bustyp": null,
        "nidgrp.rec.orccur": null,
        "nitp.exptxtmodflg": null,
        "cnybop.vouflg": null,
        "nidgrp.rec.legfrm": null,
        ".recp.pubp.founds7": null,
        ".recp.pubp.founds6": null,
        ".recp.pubp.founds5": null,
        ".recp.pubp.founds4": null,
        ".recp.pubp.founds8": null,
        ".recp.pubp.founds3": null,
        ".recp.pubp.founds2": null,
        ".recp.pubp.founds1": null,
        ".recgrp.bas.thyn": null,
        "nitp.inc760": null,
        "cnybop.traflg": null,
        "nidgrp.rec.orccurc": null,
        "nitp.gidtxtmodflgc": null,
        ".recgrp.bas.bentype": null,
        ".recgrp.bas.guarantype": null,
        ".recgrp.bas.maindebtmanner": null,
        ".dclflg": null,
        "nidgrp.rec.cnfsta": null,
        ".cfaflg": null,
        "nidgrp.rec.transferc": null,

        "nidgrp.rec.legfrmc": null,
        "nitp.aamp.aammod.addamtflg": null,
        "nidgrp.rec.rmbflg": null,
        "nidgrp.rec.reccnfdet": null,
        "addbcb.pwtyp8": null,
        "addbcb.bcbtyp6": null,
        "nidgrp.rec.delori": null,
        ".recgrp.bas.cgyn": null,
        ".recgrp.bas.actiontype": null,
        ".recp.pubp.acp": null,
        "nidgrp.rec.jurlawc": null,
        "nidgrp.rec.fenlishi": null,
        "nitp.inccormsgflg": null,
        "nitp.apcsupflg": null,
        "nidgrp.rec.jurlaws20": null,
        "nitp.aacp.aacmod.addamtflg": null,
        "addbcb.bccls1": null,
        "nitp.covgodsrvmodflg": null,
        "nidgrp.rec.liaflg": null,
        "nitp.liatxtcmodflg": null,
        "nitp.aplsupflg": null,
        "nidgrp.rec.deltoc": null,
        "nidgrp.rec.transfer": null,
        "nidgrp.rec.stacty": null,
        "nitp.drpreflg": null,
        "nidgrp.rec.cnfdet": null,
        ".basflg": null,
        "nidgrp.rec.delto": null,
        "cnybop.cnyflg": null,
        ".recgrp.bas.guedtype": null,
        "cnybop.outflg": null,
        "cnybop.cnyvou.cvouchdirection": null,
        "nidgrp.rec.autrnwflg": null,
        "nidgrp.rec.sndto": null,
        "setmod.glemod.glepan": null,
        ".cfap": null,
        ".recp.dclp": null,
        ".recp.dclp.actiontype": null,
        "cnybop.voup": null,
        "nitp.preperp": null,
        //====开立方式========================================
        "nidgrp.rec.fingua": [
          { type: "string", required: true, message: "必输项" },
          { max: 3, message: "长度不能超过3" }
        ],
        "nidgrp.rec.ownref": [
          { type: "string", required: true, message: "必输项" },
          { max: 16, message: "长度不能超过16" }
				],
				"nidgrp.rec.sqrnam": [
          { type: "string", required: true, message: "必输项" },
          { max: 200, message: "长度不能超过200" }
        ],
        //====基本信息========================================
        "nitp.usr.extkey": [
          { type: "string", required: false, message: "必输项" },
          { max: 8, message: "长度不能超过8" }
        ],
        "nidgrp.cbs.max.cur": [
          { type: "string", required: true, message: "必输项" },
        ],
        "nidgrp.cbs.max.amt": [
          { type: "string", required: true, message: "必输项" },
          { max: 18, message: "整数位不能超过15位" },
          {
            validator (rule, value, callback) {
              if (value <= 0) {
                return callback(new Error('金额必须为正数'));
              } else {
                //校验通过
                callback();
              }
            }, trigger: ['blur', 'change']
          }
        ],
        "nidgrp.cbs.opn1.cur": [
          { type: "string", required: false, message: "必输项" },
          { max: 3, message: "长度不能超过3" }
        ],
        "nidgrp.cbs.opn1.amt": [
          { type: "string", required: false, message: "必输项" },
          { max: 18, message: "整数位不能超过15位" },
        ],
        "nidgrp.rec.hndtyp": [
          { type: "string", required: true, message: "必输项" },
        ],
        "nidgrp.rec.gartyp": [
          { type: "string", required: true, message: "必输项" },
          { max: 4, message: "长度不能超过4" }
        ],
        "nitp.lettername": [
          { type: "string", required: false, message: "必输项" },
          { max: 60, message: "长度不能超过60" }
        ],
        "nidgrp.blk.apprultxt": [
          { type: "string", required: false, message: "必输项" },
          { max: 35, message: "长度不能超过35" }
        ],
        "nidgrp.rec.vrfdat": [
          { type: "string", required: false, message: "输入正确的日期" }
        ],
        "nidgrp.rec.orddat": [
          { type: "string", required: false, message: "输入正确的日期" }
        ],
        "nidgrp.rec.opndat": [
					{ type: "string", required: true, message: "输入正确的日期" },
					{
            validator: (rule, value, callback) => {
						 if(moment(value).diff(moment(new Date()), 'hours') > 0){
								callback(new Error('输入日期不得大于当前日!'))
							}else {
                callback()
              }
            }, trigger: ['blur', 'change']
          }
				],
				"nidgrp.rec.iscrotra": [
          {  type: "string",validator: (rule, value, callback) => {
            if (this.model.nidgrp.rec.hndtyp =='OT' && !value) {
              callback(new Error('必输项'))
            } else {
              callback()
            }
          }, trigger: ['blur', 'change']} ,
        ],
        "nidgrp.rec.liadat": [
          { type: "string", required: false, message: "输入正确的日期" }
        ],
        "nidgrp.rec.aplnam": [
          { type: "string", required: false, message: "必输项" },
          { max: 40, message: "长度不能超过40" }
        ],
        "nidgrp.rec.nam": [
          { type: "string", required: false, message: "必输项" },
          { max: 40, message: "长度不能超过40" }
        ],
        "nidgrp.rec.zsjzts": [
          { type: "string", required: true, message: "必输项" },
          { max: 8, message: "长度不能超过8" }
        ],
        "nidgrp.rec.beyzd1": [
          { type: "string", required: true, message: "必输项" },
          {
            validator: (rule, value, callback) => {
              if (value.length !=17 &&  value.length !=21) {
                callback(new Error('账号长度错误'))
              } else {
                callback()
              }
            }, trigger: ['blur']
          }
        ],
        "nidgrp.rec.dbyhdh": [
          { type: "string", required: true, message: "必输项" }
        ],
        "nidgrp.rec.sqrtel": [
          { type: "string", required: false, message: "必输项" }
        ],
        "nidgrp.rec.bdbrmc": [
          { type: "string", required: true, message: "必输项" }
        ],
        "nidgrp.rec.cunqii": [
          { type: "string", required: true, message: "必输项" }
        ],
        "nidgrp.rec.idcode": [
          { type: "string", required: true, message: "必输项" },
					{
            validator: (rule, value, callback) => {
              if (value.length !=9 &&  value.length !=18) {
                callback(new Error('账号长度错误'))
              } else {
                callback()
              }
            }, trigger: ['blur']
          }
        ],

        //=============================================================================
        // "nidgrp.blk.exptxt":[
        //     {type: "string", required: true, message: "必输项"},
        //     {max: 780,message:"长度不能超过780"}
        // ],
        // "nidgrp.blk.atxexptxt":[
        //     {type: "string", required: true, message: "必输项"},
        //     {max: 65,message:"长度不能超过65"}
        // ],
        // "nidgrp.blk.liatxtc":[
        //     {type: "string", required: true, message: "必输项"},
        //     {max: 780,message:"长度不能超过780"}
        // ],
        // "nidgrp.blk.atxliatxtc":[
        //     {type: "string", required: true, message: "必输项"},
        //     {max: 65,message:"长度不能超过65"}
        // ],
        //=============================================================================

        //====当事人描述========================================
        // "nidgrp.apl.pts.ref": [
        //   { type: "string", required: false, message: "必输项" },
        //   { max: 16, message: "长度不能超过16" }
        // ],
        //"nidgrp.apl.pts.extkey": [
         // { type: "string", required: true, message: "必输项1" },
          // {  type: "string",validator: (rule, value, callback) => {
          //   if (this.model.nidgrp.rec.hndtyp!='OT' && this.model.nidgrp.apl.pts.extkey=='') {
          //     callback(new Error('必输项'))
          //   } else {
          //     callback()
          //   }
          // }, trigger: 'change'} ,
          // { max: 16, message: "长度不能超过16" }
          // ],
        // "nidgrp.apl.pts.nam": [
				// 	{  type: "string",validator: (rule, value, callback) => {
        //     if (this.model.nidgrp.rec.hndtyp=='OT' && this.model.nidgrp.apl.pts.nam =='') {
        //       callback(new Error('必输项'))
        //     } else {
        //       callback()
        //     }
        //   }, trigger: 'change'},
				// ],
				"nidgrp.apl.pts.cnnam": [
					{ max: 16, message: "长度不能超过16" }
				],
        "nidgrp.apl.namelc": [
          { type: "string", required: true, message: "必输项" },
          { max: 40, message: "长度不能超过40" }
        ],
        "nidgrp.apl.pts.adrblk": [
          { max: 140, message: "长度不能超过140" }
        ],
        "nidgrp.apl.dbfadrblkcn": [
          { type: "string", required: false, message: "必输项" },
          { max: 140, message: "长度不能超过140" }
        ],
        "nidgrp.apl.adrelc": [
          { type: "string", required: false, message: "必输项" },
          { max: 140, message: "长度不能超过140" }
        ],
        "nidgrp.con.pts.ref": [
          { type: "string", required: false, message: "必输项" },
          { max: 16, message: "长度不能超过16" }
				],
				"nidgrp.rec.projectname": [
          { type: "string", required: true, message: "必输项" },
          { max: 100, message: "长度不能超过100" }
        ],
        "nidgrp.con.pts.extkey": [
          // { type: "string", required: false, message: "必输项" },
          {  type: "string",validator: (rule, value, callback) => {
            if (this.model.nidgrp.rec.hndtyp=='OT' && this.model.nidgrp.con.pts.extkey=='') {
              callback(new Error('必输项'))
            } else {
              callback()
            }
          }, trigger: 'change'} ,
          { max: 16, message: "长度不能超过16" }
        ],
        "nidgrp.con.namelc": [
          // { type: "string", required: false, message: "必输项" },
          {  type: "string",validator: (rule, value, callback) => {
            if (this.model.nidgrp.rec.hndtyp=='OT' && this.model.nidgrp.con.namelc=='') {
              callback(new Error('必输项'))
            } else {
              callback()
            }
          }, trigger: 'change'} ,
          { max: 40, message: "长度不能超过40" }
        ],
        "nidgrp.con.pts.adrblk": [
          { type: "string", required: false, message: "必输项" },
          { max: 140, message: "长度不能超过140" }
        ],
        "nidgrp.con.dbfadrblkcn": [
          { type: "string", required: false, message: "必输项" },
          { max: 140, message: "长度不能超过140" }
        ],
        "nidgrp.con.adrelc": [
          { type: "string", required: false, message: "必输项" },
          { max: 140, message: "长度不能超过140" }
        ],
        "nidgrp.iss.pts.ref": [
          { type: "string", required: false, message: "必输项" },
          { max: 16, message: "长度不能超过16" }
        ],
        "nidgrp.iss.pts.extkey": [
          { type: "string", required: false, message: "必输项" },
          { max: 16, message: "长度不能超过16" }
        ],
        "nidgrp.iss.namelc": [
          { type: "string", required: false, message: "必输项" },
          { max: 40, message: "长度不能超过40" }
        ],
        "nidgrp.iss.pts.adrblk": [
          { type: "string", required: false, message: "必输项" },
          { max: 140, message: "长度不能超过140" }
        ],
        "nidgrp.iss.dbfadrblkcn": [
          { type: "string", required: false, message: "必输项" },
          { max: 140, message: "长度不能超过140" }
        ],
        "nidgrp.iss.adrelc": [
          { type: "string", required: false, message: "必输项" },
          { max: 140, message: "长度不能超过140" }
        ],
        "nidgrp.ctr.pts.ref": [
          { type: "string", required: false, message: "必输项" },
          { max: 16, message: "长度不能超过16" }
        ],
        "nidgrp.ctr.pts.extkey": [
          { type: "string", required: false, message: "必输项" },
          { max: 16, message: "长度不能超过16" }
        ],
        "nidgrp.ctr.namelc": [
          { type: "string", required: false, message: "必输项" },
          { max: 40, message: "长度不能超过40" }
        ],
        "nidgrp.ctr.pts.adrblk": [
          { type: "string", required: false, message: "必输项" },
          { max: 140, message: "长度不能超过140" }
        ],
        "nidgrp.ctr.dbfadrblkcn": [
          { type: "string", required: false, message: "必输项" },
          { max: 140, message: "长度不能超过140" }
        ],
        "nidgrp.ctr.adrelc": [
          { type: "string", required: false, message: "必输项" },
          { max: 140, message: "长度不能超过140" }
        ],
        "nidgrp.ben.pts.ref": [
          { type: "string", required: false, message: "必输项" ,trigger: ['change', 'blur']},
          { max: 16, message: "长度不能超过16" }
        ],
        "nidgrp.ben.pts.extkey": [
          { type: "string", required: true, message: "必输项" },
          { max: 16, message: "长度不能超过16" }
        ],
        "nidgrp.ben.namelc": [
          { type: "string", required: true, message: "必输项" },
          { max: 40, message: "长度不能超过40" }
        ],
        "nidgrp.ben.pts.adrblk": [
          { type: "string", required: false, message: "必输项" },
          { max: 140, message: "长度不能超过140" }
        ],
        "nidgrp.ben.dbfadrblkcn": [
          { type: "string", required: false, message: "必输项" },
          { max: 140, message: "长度不能超过140" }
        ],
        "nidgrp.ben.adrelc": [
          { type: "string", required: false, message: "必输项" },
          { max: 140, message: "长度不能超过140" }
        ],
        "nidgrp.adv.pts.ref": [
          { type: "string", required: false, message: "必输项" },
          { max: 16, message: "长度不能超过16" }
        ],
        "nidgrp.adv.pts.extkey": [
					{ 
						validator: (rule, value, callback) => {
							if (this.model.nidgrp.rec.hndtyp!='OL' && this.model.nidgrp.adv.pts.extkey=='') {
								callback(new Error('必输项'))
							} else {
								callback()
							}
						},
						trigger: ['change', 'blur']
					},
          { max: 16, message: "长度不能超过16" }
        ],
        "nidgrp.adv.namelc": [
					{  type: "string",validator: (rule, value, callback) => {
            if (this.model.nidgrp.rec.hndtyp!='OL' || this.model.nidgrp.rec.hndtyp=='') {
              callback(new Error('必输项'))
            } else {
              callback()
            }
          }, trigger: 'change'} ,
          { max: 40, message: "长度不能超过40" }
        ],
        "nidgrp.adv.pts.adrblk": [
          { type: "string", required: false, message: "必输项" },
          { max: 140, message: "长度不能超过140" }
        ],
        "nidgrp.adv.dbfadrblkcn": [
          { type: "string", required: false, message: "必输项" },
          { max: 140, message: "长度不能超过140" }
        ],
        "nidgrp.adv.adrelc": [
          { type: "string", required: false, message: "必输项" },
          { max: 140, message: "长度不能超过140" }
        ],

        //===演示/交付=============================
        "nidgrp.rec.deloritxt": [
          { type: "string", required: false, message: "必输项" },
          { max: 35, message: "长度不能超过35" }
        ],
        "nidgrp.blk.deltoadr": [
          { type: "string", required: false, message: "必输项" },
          { max: 210, message: "长度不能超过210" }
        ],
        "nidgrp.blk.trfcond": [
          { type: "string", required: false, message: "必输项" },
          { max: 6630, message: "长度不能超过6630" }
        ],
        "nidgrp.blk.feetxt": [
          { type: "string", required: true, message: "必输项" },
          { max: 210, message: "长度不能超过210" }
        ],
        "nidgrp.blk.preper": [
          { type: "string", required: true, message: "必输项" },
          { max: 6500, message: "长度不能超过6500" }
        ],
        "nidgrp.blk.atxpreper": [
          { type: "string", required: true, message: "必输项" },
          { max: 65, message: "长度不能超过65" }
        ],


        //===详细信息=============================
        "nidgrp.rec.orcref": [
          { type: "string", required: true, message: "必输项" },
          { max: 100, message: "长度不能超过100" }
        ],
        "nidgrp.rec.orcdat": [
          { type: "string", required: false, message: "输入正确的日期" }
        ],
        "nidgrp.rec.tenclsdat": [
          { type: "string", required: false, message: "输入正确的日期" }
        ],
        "nidgrp.blk.covgodsrv": [
          { type: "string", required: true, message: "必输项" },
          { max: 350, message: "长度不能超过350" }
        ],
        "nidgrp.blk.atxcovgodsrvc": [
          { type: "string", required: true, message: "必输项" },
          { max: 65, message: "长度不能超过65" }
        ],
        "nidgrp.rec.orcrat": [
          { type: "string", required: false, message: "必输项" },
          { max: 14, message: "长度不能超过14" }
        ],
        "nidgrp.rec.orcamt": [
          { type: "string", required: false, message: "必输项" },
          { max: 18, message: "整数位不能超过15位" },
        ],
        "nidgrp.blk.orcplc": [
          { type: "string", required: false, message: "必输项" },
          { max: 140, message: "长度不能超过140" }
        ],
        "nidgrp.rec.acc": [
          { type: "string", required: false, message: "必输项" },
          { max: 35, message: "长度不能超过35" }
        ],
        "nidgrp.rec.jurlaw": [
          { type: "string", required: false, message: "必输项" },
          { max: 35, message: "长度不能超过35" }
        ],
        "nidgrp.rec.jurplc": [
          { type: "string", required: false, message: "必输项" },
          { max: 35, message: "长度不能超过35" }
        ],
        "nidgrp.rec.projname": [
          { type: "string", required: true, message: "必输项" },
          { max: 100, message: "长度不能超过100" }
        ],
        "nidgrp.rec.guatyp": [
          { type: "string", required: true, message: "必输项" },
        ],
        "nidgrp.rec.tenref": [
          { type: "string", required: false, message: "必输项" },
          { max: 35, message: "长度不能超过35" }
        ],
        "nidgrp.rec.tendat": [
          { type: "string", required: false, message: "输入正确的日期" }
        ],
        "nidgrp.rec.trmdat": [
          { type: "string", required: false, message: "输入正确的日期" }
        ],
        "nidgrp.rec.mannum": [
          { type: "string", required: false, message: "必输项" },
          { max: 12, message: "长度不能超过12" }
        ],
        "nidgrp.rec.wahnum": [
          { type: "string", required: false, message: "必输项" },
          { max: 20, message: "长度不能超过20" }
        ],
        "nidgrp.rec.bennam": [
          { type: "string", required: false, message: "必输项" },
          { max: 80, message: "长度不能超过80" }
        ],
        "nidgrp.rec.bngcod": [
          { type: "string", required: false, message: "必输项" },
          { max: 10, message: "长度不能超过10" }
        ],
        "nidgrp.rec.juscod": [
          { type: "string", required: false, message: "必输项" },
          { max: 10, message: "长度不能超过10" }
        ],
        "nidgrp.rec.bilvvv": null,
        "nitp.indirectswiadd": [
          { type: "string", required: true, message: "必输项" },
          { max: 9750, message: "长度不能超过9750" }
        ],
        "nidgrp.blk.addinf": [
          { type: "string", required: false, message: "必输项" },
          { max: 700, message: "长度不能超过700" }
        ],
        "nidgrp.rec.remark": [
          { type: "string", required: true, message: "必输项" },
          { max: 245, message: "长度不能超过245" }
        ],
				"nidgrp.rec.countrycod":[
					{  type: "string",required: true, message: "必输项", trigger: 'change' }
				]*/
      }
    }
  }
}