user-about.html 5.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="utf-8">
  5. <title>关于-创业帮</title>
  6. <meta name="keywords" content="关于-创业帮">
  7. <meta name="description" content="关于-创业帮">
  8. <meta content="width=device-width,minimum-scale=1.0,maximum-scale=1.0,shrink-to-fit=no,user-scalable=no" name="viewport" viewport="cover">
  9. <meta name="apple-mobile-web-app-capable" content="yes">
  10. <meta name="apple-mobile-web-app-status-bar-style" content="black-translucent">
  11. <meta content="telephone=no" name="format-detection">
  12. <meta content="email=no" name="format-detection">
  13. <meta name="apple-mobile-web-app-title" content="关于-创业帮">
  14. <meta http-equiv="Cache-Control" content="no-siteapp">
  15. <link rel="stylesheet" href="./static/css/main.css">
  16. </head>
  17. <body class="bgc-back pt0" style="padding-top:0;">
  18. <div id="app" v-cloak>
  19. <van-nav-bar class="user_rank_explan_title user_title_normal" left-arrow title="关于创业帮" v-if="toptitleisshow" @click-left="goback">
  20. <template #left> <img src="./static/images/left.png" alt=""></template>
  21. </van-nav-bar>
  22. <div class="bt8f7f7f7 tc pt32 pb32" v-cloak><img class="logo-about pb8" src="./static/images/logo-text.png" alt="">
  23. <div class="f12 c999">版本:V{{curversion}}</div>
  24. </div>
  25. <van-cell-group :border="false" v-cloak>
  26. <van-cell title="用户协议" value="" is-link @click="goagreement"></van-cell>
  27. <van-cell title="隐私政策" value="" is-link @click="policy"></van-cell>
  28. </van-cell-group>
  29. <van-dialog style="border-radius:4px;" v-model="closegestureisshow" confirm-button-color="#ff502a" width="70%" message="是否更新到新的版本" show-cancel-button @confirm="closegesture" @cancel="unclosegesture"> </van-dialog>
  30. <van-dialog style="border-radius:4px;" v-model="dialogisshow" title="版本过低" confirm-button-color="#00000" message="请重新下载或更新最新版本" @confirm="isgroup"> </van-dialog>
  31. </div>
  32. <script src="./static/js/klm-vv.min.js"></script>
  33. <script src="./static/js/appfunc.min.js"></script>
  34. <script src="./static/js/klm-axios-config.js"></script>
  35. <script src="./static/js/publicfn.js"></script>
  36. <script>
  37. // 通过 CDN 引入时不会自动注册 Lazyload 组件
  38. // 可以通过下面的方式手动注册
  39. Vue.use(vant.Lazyload);
  40. // 在 #app 标签下渲染一个按钮组件
  41. let app = new Vue({
  42. el: '#app',
  43. data() {
  44. return {
  45. dialogisshow:false,
  46. closegestureisshow:false,
  47. toptitleisshow:false,
  48. active: 0,
  49. curversion: '1.1.2',
  50. version: '1.1.2',
  51. hasNew: false,
  52. downloadUrl:'',
  53. };
  54. },
  55. async created() {
  56. this.toptitleisshow = toptitleisshow;
  57. this.curversion = PublicLib.GetAppVersion();
  58. this.getversion();
  59. this.versionsfn();
  60. },
  61. methods: {
  62. async versionsfn(){
  63. const val = PublicLib.GetAppVersion();
  64. const versionsnum = this.splitjoin(val);
  65. console.log(versionsnum)
  66. const type = browsertype.versions.ios ? 'ios' : 'android';
  67. const res = await getRequest('api/v1/appversion/detail?t='+Math.random(6),JSON.stringify({VersionNum:val,ClientType:type,Role:2}));
  68. res.data.VersionNum = !res.data.VersionNum? '1.0.1' : res.data.VersionNum;
  69. const onlineversionsnum = this.splitjoin(res.data.VersionNum);
  70. if(Number(versionsnum) < Number(onlineversionsnum)){
  71. this.dialogisshow = true;
  72. if('ios'){
  73. //做升级版本处理
  74. this.groupUrl = 'https://apps.apple.com/cn/app/%E5%AE%A2%E5%B0%8F%E7%88%BD%E5%88%9B%E5%AE%A2%E7%89%88/id1606114555'
  75. }else{
  76. this.groupUrl = 'https://a.app.qq.com/o/simple.jsp?pkgname=com.kexiaoshuang.creator#fromopen&opened'
  77. };
  78. };
  79. },
  80. splitjoin(str){
  81. return str.split('.').join('');
  82. },
  83. isgroup(){
  84. PublicLib.GotoUrlByBrowse(this.groupUrl);
  85. },
  86. async getversion(){
  87. const type = browsertype.versions.ios ? 'ios' : 'android';
  88. const res = await getRequest('api/v1/appversion/detail?t='+Math.random(6),JSON.stringify({VersionNum:this.curversion,ClientType:type,Role:2}));
  89. this.version = res.data.VersionNum;
  90. this.downloadUrl = res.data.DownloadUrl;
  91. const that = this;
  92. if(this.version !== this.curversion){
  93. that.hasNew = true;
  94. }else {
  95. that.hasNew = false;
  96. };
  97. },
  98. goback(){
  99. PublicLib.GoBack({Level:1});
  100. },
  101. goagreement(){
  102. PublicLib.Goto({Url:'user-maker-agreement'});
  103. },
  104. policy(){
  105. PublicLib.Goto({Url:'user-maker-policy'});
  106. },
  107. upload(){
  108. if(this.hasNew){
  109. this.closegestureisshow = true;
  110. //- PublicLib.ShowDialog({
  111. //- Title:'',
  112. //- Message:'是否更新到新的版本',
  113. //- ConfirmText:'确定',
  114. //- CancelText:'暂不',
  115. //- confirmButtonColor:'#FFD500',
  116. //- ConfirmAction:'app.downloadfn()',
  117. //- CanelAction:''
  118. //- });
  119. }
  120. },
  121. unclosegesture(){
  122. this.closegestureisshow = false;
  123. },
  124. closegesture(){
  125. PublicLib.Goto({Url:this.downloadUrl, Jump: 1});
  126. },
  127. }
  128. });
  129. </script>
  130. </body>
  131. </html>