about.vue 5.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232
  1. <template>
  2. <view>
  3. <view class="line"></view>
  4. <view class="logo-box">
  5. <image :src="$imageURL+'/bigdata_app'+'/image/c9b4eb88c03b2f7460e8479e80f40fc.png'" mode="widthFix"></image>
  6. <view class="version">
  7. <view>
  8. 云飞物联网
  9. </view>
  10. <view>
  11. V{{id}}
  12. </view>
  13. </view>
  14. </view>
  15. <view class="line"></view>
  16. <view class="part">
  17. <view class="info-item">
  18. <text class="tit">技术支持</text>
  19. <text class="val">河南云飞科技发展有限公司</text>
  20. </view>
  21. <view class="divide"></view>
  22. <view class="info-item">
  23. <text class="tit">关注微信</text>
  24. <text class="val">河南云飞科技发展有限公司</text>
  25. </view>
  26. </view>
  27. <view class="line"></view>
  28. <view class="part">
  29. <view class="info-item">
  30. <text class="tit">公司官网</text>
  31. <text class="val">www.hnyfkj.cn</text>
  32. </view>
  33. <view class="divide"></view>
  34. <view class="info-item">
  35. <text class="tit">业务合作</text>
  36. <text class="val">400-690-7990</text>
  37. </view>
  38. <view class="divide"></view>
  39. <view class="info-item">
  40. <text class="tit">公司邮箱</text>
  41. <text class="val">hnyf826@163.com</text>
  42. </view>
  43. </view>
  44. <view class="line"></view>
  45. <!-- <view class="part">
  46. <view class="info-item" @click="renewal">
  47. <text class="tit">版本更新</text>
  48. <u-icon name="arrow-right"></u-icon>
  49. </view>
  50. </view> -->
  51. <view class="line"></view>
  52. <view class="record">
  53. <view class="info-item" @click="record">
  54. <text class="tit">更新记录</text>
  55. <u-icon name="arrow-right"></u-icon>
  56. </view>
  57. </view>
  58. <view class="bottom">
  59. ©河南云飞科技发展有限公司
  60. </view>
  61. <u-modal title="升级中请勿随意操作" :show-confirm-button="false" v-model="showA" :content="contentA">
  62. <view class="upgradeBox">
  63. <u-line-progress v-show="isShow" active-color="#19be6b" :striped="true" :percent="percentNum" :striped-active="true"></u-line-progress>
  64. </view>
  65. </u-modal>
  66. </view>
  67. </template>
  68. <script>
  69. export default {
  70. data() {
  71. return {
  72. id:'',
  73. versions:'',
  74. showA: false, //
  75. contentA: '',
  76. isShow: false, //进度条
  77. percentNum: 0, //在线下载进度
  78. }
  79. },
  80. methods: {
  81. async getEquipList() {
  82. const res = await this.$myRequest({
  83. url: '/api/api_gateway?method=home.homes.app_version_record',
  84. data: {
  85. ret:"first"
  86. }
  87. })
  88. console.log(res)
  89. this.id = res[0].app_num
  90. },
  91. // this.versions = Number(res[0].app_num.match(/\d+/g).join(""))
  92. // var ids = Number(this.id.match(/\d+/g).join(""))
  93. // if (this.versions > ids) {
  94. // uni.showModal({
  95. // title: '提示',
  96. // content: '检测到有新版本,是否更新?',
  97. // success: (res) => {
  98. // if (res.confirm) {
  99. // console.log('用户点击确定');
  100. // this.showA = true
  101. // this.isShow = true
  102. // this.upgrade()
  103. // } else if (res.cancel) {
  104. // plus.runtime.quit();
  105. // console.log('用户点击取消');
  106. // }
  107. // }
  108. // })
  109. // }else{
  110. // uni.showToast({
  111. // title:"当前版本已是最新版本",
  112. // icon:"none"
  113. // })
  114. // }
  115. // },
  116. // renewal(){
  117. // this.getEquipList()
  118. // },
  119. // upgrade() {
  120. // console.log(this.appName)
  121. // var url = "http://dev.hnyfwlw.com/app_file/" + this.appName
  122. // console.log(url)
  123. // const downloadTask = uni.downloadFile({
  124. // url: url, //仅为示例,并非真实的资源
  125. // success: (res) => {
  126. // console.log(res)
  127. // if (res.statusCode === 200) {
  128. // console.log('下载成功');
  129. // console.log('安装包下载成功,即将安装:' + JSON.stringify(res, null, 4));
  130. // plus.runtime.openFile(res.tempFilePath);
  131. // }
  132. // },
  133. // fail: (err) => {
  134. // console.log(err)
  135. // },
  136. // complete: (com) => {
  137. // console.log(com)
  138. // }
  139. // });
  140. // downloadTask.onProgressUpdate((res) => {
  141. // this.percentNum = res.progress
  142. // if (res.progress == 100) {
  143. // console.log('下载完成了')
  144. // plus.runtime.quit();
  145. // }
  146. // });
  147. // },
  148. record(){
  149. uni.navigateTo({
  150. url:"../record/record"
  151. })
  152. }
  153. },
  154. onLoad(){
  155. this.getEquipList()
  156. },
  157. onShow() {
  158. // this.id = plus.runtime.version
  159. },
  160. onBackPress(option){
  161. // uni.redirectTo({
  162. // url:"../index/index"
  163. // })
  164. // 返回上一页面
  165. uni.navigateBack({
  166. delta: 1
  167. })
  168. }
  169. }
  170. </script>
  171. <style lang="scss">
  172. page {
  173. background:$uni-bg-color-grey;
  174. }
  175. .line{
  176. height:16rpx;
  177. width:100%;
  178. background:$uni-bg-color-grey;
  179. }
  180. .bottom{
  181. height:190rpx;
  182. line-height:190rpx;
  183. font-size:8px;
  184. text-align: center;
  185. }
  186. .logo-box{
  187. background:#fff;
  188. text-align: center;
  189. padding:80rpx 0;
  190. image{
  191. width:150rpx;
  192. }
  193. .version{
  194. font-size:24rpx;
  195. margin-top:20rpx;
  196. }
  197. }
  198. .part{
  199. background:#fff;
  200. padding:0 40rpx;
  201. .divide{
  202. width:100%;
  203. height:1px;
  204. background:$uni-bg-color-grey;
  205. }
  206. .info-item{
  207. display:flex;
  208. justify-content: space-between;
  209. line-height:100rpx;
  210. .tit{font-size:14px}
  211. .val{
  212. font-size:12px;
  213. color:#666;
  214. }
  215. }
  216. }
  217. .record{
  218. background:#fff;
  219. padding:0 40rpx;
  220. .info-item{
  221. display:flex;
  222. justify-content: space-between;
  223. line-height:100rpx;
  224. .tit{font-size:14px}
  225. }
  226. }
  227. .upgradeBox {
  228. padding: 15rpx;
  229. }
  230. </style>