暫無描述

index.html 2.1KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="UTF-8">
  5. <meta content="yes" name="apple-mobile-web-app-capable">
  6. <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0,minimum-scale=1.0,user-scalable=0" />
  7. <title>最奇葩的请假理由</title>
  8. <script src="public/weChatShare.js?v=3"></script>
  9. <script src="http://res.wx.qq.com/open/js/jweixin-1.0.0.js"></script>
  10. <link rel="stylesheet" type="text/css" href="public/public_css.css?v=6"/>
  11. <style type="text/css">
  12. body{ min-height:100vh;background: #EECD02;}
  13. .container{height:6.66rem;background: url(images/index2.png) no-repeat;background-size: 100% 100%;}
  14. .leave_submit{width:2.54rem;height:0.955rem;margin:auto;background:url(images/btn.png) no-repeat;background-size:100%;position: absolute; top: 4.9rem;left: 0;right: 0;}
  15. </style>
  16. <script type="text/javascript">
  17. document.documentElement.style.fontSize = 100 * (document.documentElement.clientWidth/375) + "px";
  18. window.onresize = function(){
  19. document.documentElement.style.fontSize = 100 * (document.documentElement.clientWidth/375) + "px";
  20. }
  21. </script>
  22. </head>
  23. <body>
  24. <div class="container">
  25. <div class="leave_submit"></div>
  26. </div>
  27. </body>
  28. </html>
  29. <script type="text/javascript" src="public/jquery-2.1.0.js"></script>
  30. <script type="text/javascript">
  31. var flag = true;
  32. $().ready(function(){
  33. shareFriend();
  34. })
  35. $(".leave_submit").click(function(){
  36. window.location.href = 'leaveInfo.html'
  37. })
  38. function shareFriend () {
  39. //微信sdk分享验证信息
  40. $.ajax({
  41. type:"post",
  42. url:"/api/V2/jsonConfig",
  43. dataType:"json",
  44. data:{
  45. url:location.href
  46. },
  47. success: function (res) {
  48. if(res && res.code == 0){
  49. wexinPay(location.href,res.res,() => {
  50. // 分享成功
  51. $(".shareMask").css('display','none')
  52. },() => {
  53. showMsg("分享失败")
  54. flag = false;
  55. },() => {
  56. //微信审核为通过
  57. flag = false;
  58. })
  59. }else{
  60. flag = false;
  61. }
  62. if(!flag){
  63. //分享不成功
  64. setTimeout(function () {
  65. $(".shareMask").css('display','none')
  66. },3000)
  67. }
  68. }
  69. })
  70. }
  71. </script>