Skip to end of metadata
Go to start of metadata

 

场景

强制用户使用企业微信访问报表

 

方法

  1. 创建一个报表: 企业微信提示;   本报表用于提示用户使用企业微信访问报表
  2. 平台管理->系统设置->全局报表页脚本->开启
  3. 编辑"全局报表页脚本"

    var ua= window.navigator.userAgent.toLowerCase();
    //检查是不是企业微信
    var isQywx =  (ua.match(/MicroMessenger/i) == 'micromessenger') && (ua.match(/wxwork/i) == 'wxwork');
    //企业微信提示页面的报表ID
    var reportId = "f6a5477ec3994c978aff9e7aefe6e2da";
    if(!isQywx && reportObject.id !== reportId){
    	//跳转到提示报表
        window.location.href=contextPath+"/view/report.do?reportId="+reportId;
    }

    请将脚本中的 reportId = "xxx" 中的xxx换成真实的企业微信提示报表ID

     

     

 

 

  • No labels