说好的IE11兼容javascript中的常量类型 const 呢 ?可能并没有完全兼容

 

项目中需要一个问题采用google没问题,在本地jetty启动,IE11也可以正常访问,然而当我将项目打成WAR包,放到server(linux环境)上时,

报错如下:

console

debugger

 

代码如下:

function equitySecTypeHandler(form, secType) {
    
    // error here    
    const COMMON_STOCK = "Common Stocks";
    const SHARES_ETF = "Listed shares / ETF without complex features";
    
    var prdRiskRating = form.getValue('prdRiskRating');
    var complexPrd = form.getValue('complexPrd');
    var derivatives = form.getValue('derivatives');
    var sfcSpecifiedJuris = form.getValue('sfcSpecifiedJuris');
    var piPrdFlag = form.getValue('piPrdFlag');
    var prdClassification = form.getValue('prdClassification');
    var equitySecType = form.getValue('equitySecType');
    
    clearExtraTab(form);
    var returnBean = new Object();
    if(secType == null) {
        return returnBean;
    }
    
    if(equitySecTypeMap[equitySecType] == COMMON_STOCK) {
        returnBean.complexPrd = 'N';
        returnBean.derivatives = 'N';
        for(var key in prdClassificationMap){
            if(prdClassificationMap[key] == SHARES_ETF) {
                returnBean.prdClassification = key;
                break;
            }
        }
        returnBean.piPrdFlag = 'N';
    }
    return returnBean;
}

View Code

 

注释掉const语句,问题解决

posted on 2019-03-15 19:59 allinfocus 阅读() 评论() 编辑 收藏
版权声明:本文为allinfocus原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。
本文链接:https://www.cnblogs.com/allinfocus/p/10539198.html