index.html 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="utf-8" />
  5. <meta http-equiv="X-UA-Compatible" content="IE=edge" />
  6. <meta name="viewport" content="width=device-width,initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no, viewport-fit=cover" />
  7. <script src="./static/vue.min.js" rel="preload" as="script"></script>
  8. <script src="./static/axios@0.21.0.min.js" rel="preload" as="script"></script>
  9. <title>报表</title>
  10. <style>
  11. [v-cloak] {
  12. display: none;
  13. }
  14. body {
  15. /* IOS禁止微信调整字体大小 */
  16. -webkit-text-size-adjust: 100% !important;
  17. }
  18. </style>
  19. <script>
  20. // 安卓的解决方案是通过 WeixinJSBridge 对象将网页的字体大小设置为默认大小,并且重写设置字体大小的方法,让用户不能在该网页下设置字体大小:
  21. (function() {
  22. // title
  23. document.title = "业绩报表";
  24. if (
  25. typeof WeixinJSBridge == "object" &&
  26. typeof WeixinJSBridge.invoke == "function"
  27. ) {
  28. handleFontSize();
  29. } else {
  30. if (document.addEventListener) {
  31. document.addEventListener(
  32. "WeixinJSBridgeReady",
  33. handleFontSize,
  34. false
  35. );
  36. } else if (document.attachEvent) {
  37. document.attachEvent("WeixinJSBridgeReady", handleFontSize);
  38. document.attachEvent("onWeixinJSBridgeReady", handleFontSize);
  39. }
  40. }
  41. function handleFontSize() {
  42. // 设置网页字体为默认大小
  43. WeixinJSBridge.invoke("setFontSizeCallback", {
  44. fontSize: 0
  45. });
  46. // 重写设置网页字体大小的事件
  47. WeixinJSBridge.on("menu:setfont", function() {
  48. WeixinJSBridge.invoke("setFontSizeCallback", {
  49. fontSize: 0
  50. });
  51. });
  52. }
  53. })();
  54. </script>
  55. </head>
  56. <body>
  57. <noscript>
  58. <strong
  59. >We're sorry but pingyiweb doesn't work properly without JavaScript
  60. enabled. Please enable it to continue.</strong
  61. >
  62. </noscript>
  63. <div id="app"></div>
  64. <!-- built files will be auto injected -->
  65. </body>
  66. </html>