Browse Source

Merge branch 'dev/v1.1.1_tsz' of jianyu/web into feature/v1.1.1

汤世哲 3 months ago
parent
commit
8d00786044

+ 1 - 1
apps/mobile/src/views/article/components/OriginLink.vue

@@ -93,7 +93,7 @@ export default {
   },
   },
   created() {
   created() {
     window.t = this
     window.t = this
-    // this.eventBusListening()
+    this.eventBusListening()
   },
   },
   methods: {
   methods: {
     eventBusListening() {
     eventBusListening() {

+ 3 - 0
apps/mobile/src/views/common/pdfViewExample.vue

@@ -39,6 +39,8 @@ export default {
     ...mapGetters('user', ['getUserId'])
     ...mapGetters('user', ['getUserId'])
   },
   },
   created() {
   created() {
+    this.$toast.loading('加载中...')
+
     const { pdfUrl } = this.$route.query
     const { pdfUrl } = this.$route.query
     if (pdfUrl) {
     if (pdfUrl) {
       this.pdfUrl = decodeURIComponent(pdfUrl)
       this.pdfUrl = decodeURIComponent(pdfUrl)
@@ -83,6 +85,7 @@ export default {
         this.batchSize = 5 // 新增
         this.batchSize = 5 // 新增
 
 
         await this.loadBatchPages(container) // 新增
         await this.loadBatchPages(container) // 新增
+        this.$toast.clear()
         // 监听滚动事件
         // 监听滚动事件
         container.addEventListener('scroll', () => this.handleScroll(container))
         container.addEventListener('scroll', () => this.handleScroll(container))
       }
       }

+ 58 - 29
plugins/bind-phone-mobile/src/utils/appFn.js

@@ -7,7 +7,8 @@ import { copyText } from '@/utils'
 export function appCallPhone(phone) {
 export function appCallPhone(phone) {
   try {
   try {
     JyObj.callPhone(phone)
     JyObj.callPhone(phone)
-  } catch (e) {
+  }
+  catch (e) {
     console.warn('error: app call phone', e)
     console.warn('error: app call phone', e)
   }
   }
 }
 }
@@ -15,7 +16,8 @@ export function appCallPhone(phone) {
 export function appCallCopyText(text) {
 export function appCallCopyText(text) {
   try {
   try {
     JyObj.wirteRight(text)
     JyObj.wirteRight(text)
-  } catch (e) {
+  }
+  catch (e) {
     console.warn('error: app call copy text', e)
     console.warn('error: app call copy text', e)
     copyText(text)
     copyText(text)
   }
   }
@@ -27,9 +29,12 @@ export function appCallCopyText(text) {
  * @param title 窗口标题
  * @param title 窗口标题
  */
  */
 export function appCallOpenWindow(link, title = '剑鱼标讯') {
 export function appCallOpenWindow(link, title = '剑鱼标讯') {
+  if (!link)
+    return
   try {
   try {
     JyObj.openExternalLink(link, title)
     JyObj.openExternalLink(link, title)
-  } catch (e) {
+  }
+  catch (e) {
     console.warn('error: app call openExternalLink', e)
     console.warn('error: app call openExternalLink', e)
   }
   }
 }
 }
@@ -41,7 +46,8 @@ export function appCallOpenWindow(link, title = '剑鱼标讯') {
 export function appCallChangeTab(name) {
 export function appCallChangeTab(name) {
   try {
   try {
     JyObj.skipAppointTab(name)
     JyObj.skipAppointTab(name)
-  } catch (e) {
+  }
+  catch (e) {
     console.warn('error: app call skipAppointTab', e)
     console.warn('error: app call skipAppointTab', e)
   }
   }
 }
 }
@@ -53,7 +59,8 @@ export function appCallChangeTab(name) {
 export function appCallReloadTab(name, status = 1) {
 export function appCallReloadTab(name, status = 1) {
   try {
   try {
     JyObj.refreshAppointTab(name, status)
     JyObj.refreshAppointTab(name, status)
-  } catch (e) {
+  }
+  catch (e) {
     console.warn('error: app call refreshAppointTab', e)
     console.warn('error: app call refreshAppointTab', e)
   }
   }
 }
 }
@@ -67,7 +74,8 @@ export function appCallReloadTab(name, status = 1) {
 export function appCallBackTab(name) {
 export function appCallBackTab(name) {
   try {
   try {
     JyObj.backUrl(name)
     JyObj.backUrl(name)
-  } catch (e) {
+  }
+  catch (e) {
     console.warn('error: app call backUrl', e)
     console.warn('error: app call backUrl', e)
   }
   }
 }
 }
@@ -79,7 +87,8 @@ export function appCallBackTab(name) {
 export function appCallHideTab(type) {
 export function appCallHideTab(type) {
   try {
   try {
     JyObj.hiddenBottom(type)
     JyObj.hiddenBottom(type)
-  } catch (e) {
+  }
+  catch (e) {
     console.warn('error: app call hiddenBottom', e)
     console.warn('error: app call hiddenBottom', e)
   }
   }
 }
 }
@@ -91,7 +100,8 @@ export function appCallGetToken() {
   let result
   let result
   try {
   try {
     result = JyObj.getUserToken()
     result = JyObj.getUserToken()
-  } catch (e) {
+  }
+  catch (e) {
     console.warn('error: app call getUserToken', e)
     console.warn('error: app call getUserToken', e)
   }
   }
   return result
   return result
@@ -107,7 +117,8 @@ export function savePic(
 ) {
 ) {
   try {
   try {
     window.__compatibleAppFn(JyObj.savePic, imgbase64, tip)
     window.__compatibleAppFn(JyObj.savePic, imgbase64, tip)
-  } catch (e) {
+  }
+  catch (e) {
     console.warn('error: app call savePic', e)
     console.warn('error: app call savePic', e)
   }
   }
 }
 }
@@ -117,7 +128,8 @@ export function checkNoticePermission() {
   let status
   let status
   try {
   try {
     status = JyObj.IosCall('checkNoticePermission')
     status = JyObj.IosCall('checkNoticePermission')
-  } catch (e) {
+  }
+  catch (e) {
     console.warn('error: app call checkNoticePermission', e)
     console.warn('error: app call checkNoticePermission', e)
   }
   }
   return status
   return status
@@ -127,7 +139,8 @@ export function checkNoticePermission() {
 export function openSystemNotification() {
 export function openSystemNotification() {
   try {
   try {
     JyObj.openSystemNotification()
     JyObj.openSystemNotification()
-  } catch (e) {
+  }
+  catch (e) {
     console.warn('error: app call openSystemNotification', e)
     console.warn('error: app call openSystemNotification', e)
   }
   }
 }
 }
@@ -139,7 +152,8 @@ export function getAppVersion() {
   let version = ''
   let version = ''
   try {
   try {
     version = JyObj.getVersion()
     version = JyObj.getVersion()
-  } catch (e) {
+  }
+  catch (e) {
     console.warn('error: get app version failed', e)
     console.warn('error: get app version failed', e)
   }
   }
   return version || ''
   return version || ''
@@ -157,7 +171,8 @@ export function getAppVersion() {
 export function appDownLoadFile(filename, filetype, fileurl, filesize) {
 export function appDownLoadFile(filename, filetype, fileurl, filesize) {
   try {
   try {
     JyObj.downLoadFile(filename, filetype, fileurl, filesize)
     JyObj.downLoadFile(filename, filetype, fileurl, filesize)
-  } catch (e) {
+  }
+  catch (e) {
     console.warn('error: app ios download file failed', e)
     console.warn('error: app ios download file failed', e)
   }
   }
 }
 }
@@ -172,7 +187,8 @@ export function appHideRedSpotOnMenu(menu) {
   }
   }
   try {
   try {
     JyObj.hideRedSpotOnMenu(menu)
     JyObj.hideRedSpotOnMenu(menu)
-  } catch (e) {
+  }
+  catch (e) {
     console.warn('error: app hideRedSpotOnMenu failed', e)
     console.warn('error: app hideRedSpotOnMenu failed', e)
   }
   }
 }
 }
@@ -184,7 +200,8 @@ export function appHideRedSpotOnMenu(menu) {
 export function appSendMsgCount(num) {
 export function appSendMsgCount(num) {
   try {
   try {
     JyObj.sendMsgCount(num)
     JyObj.sendMsgCount(num)
-  } catch (e) {
+  }
+  catch (e) {
     console.warn('error: app sendMsgCount failed', e)
     console.warn('error: app sendMsgCount failed', e)
   }
   }
 }
 }
@@ -195,7 +212,8 @@ export function appSendMsgCount(num) {
 export function appOpenWeChartScan() {
 export function appOpenWeChartScan() {
   try {
   try {
     JyObj.openWeChartScan()
     JyObj.openWeChartScan()
-  } catch (e) {
+  }
+  catch (e) {
     console.warn('error: app openWeChartScan failed', e)
     console.warn('error: app openWeChartScan failed', e)
   }
   }
 }
 }
@@ -208,7 +226,8 @@ export function appOpenWeChartScan() {
 export function appClearHistory() {
 export function appClearHistory() {
   try {
   try {
     JyObj.clearHistory()
     JyObj.clearHistory()
-  } catch (e) {
+  }
+  catch (e) {
     console.warn('error: app clearHistory failed', e)
     console.warn('error: app clearHistory failed', e)
   }
   }
 }
 }
@@ -219,7 +238,8 @@ export function appClearHistory() {
 export function appSideslipOpen() {
 export function appSideslipOpen() {
   try {
   try {
     JyObj.sideslipOpen()
     JyObj.sideslipOpen()
-  } catch (e) {
+  }
+  catch (e) {
     console.warn('error: app sideslipOpen failed', e)
     console.warn('error: app sideslipOpen failed', e)
   }
   }
 }
 }
@@ -229,7 +249,8 @@ export function appSideslipOpen() {
 export function appSideslipClose() {
 export function appSideslipClose() {
   try {
   try {
     JyObj.sideslipClose()
     JyObj.sideslipClose()
-  } catch (e) {
+  }
+  catch (e) {
     console.warn('error: app sideslipClose failed', e)
     console.warn('error: app sideslipClose failed', e)
   }
   }
 }
 }
@@ -251,14 +272,16 @@ export function appShare(
 ) {
 ) {
   try {
   try {
     if (
     if (
-      window.__checkAppVersionCanRunTips &&
-      window.__checkAppVersionCanRunTips()
+      window.__checkAppVersionCanRunTips
+      && window.__checkAppVersionCanRunTips()
     ) {
     ) {
       JyObj.share(shareType, title, content, link, authTip)
       JyObj.share(shareType, title, content, link, authTip)
-    } else {
+    }
+    else {
       JyObj.share(shareType, title, content, link)
       JyObj.share(shareType, title, content, link)
     }
     }
-  } catch (e) {
+  }
+  catch (e) {
     console.warn('error: app call share', e)
     console.warn('error: app call share', e)
   }
   }
 }
 }
@@ -267,7 +290,8 @@ export function appShare(
 export function appGetPhoneBind() {
 export function appGetPhoneBind() {
   try {
   try {
     JyObj.getPhoneBind()
     JyObj.getPhoneBind()
-  } catch (e) {
+  }
+  catch (e) {
     console.warn('error: app call getPhoneBind', e)
     console.warn('error: app call getPhoneBind', e)
   }
   }
 }
 }
@@ -276,7 +300,8 @@ export function appGetPhoneBind() {
 export function appGetPushRid() {
 export function appGetPushRid() {
   try {
   try {
     JyObj.getPushRid()
     JyObj.getPushRid()
-  } catch (e) {
+  }
+  catch (e) {
     console.warn('error: app call getPushRid', e)
     console.warn('error: app call getPushRid', e)
   }
   }
 }
 }
@@ -285,7 +310,8 @@ export function appGetPushRid() {
 export function appGetOtherPushId() {
 export function appGetOtherPushId() {
   try {
   try {
     JyObj.getOtherPushId()
     JyObj.getOtherPushId()
-  } catch (e) {
+  }
+  catch (e) {
     console.warn('error: app call getOtherPushId', e)
     console.warn('error: app call getOtherPushId', e)
   }
   }
 }
 }
@@ -294,7 +320,8 @@ export function appGetOtherPushId() {
 export function appGetPhoneType() {
 export function appGetPhoneType() {
   try {
   try {
     JyObj.getPhoneType()
     JyObj.getPhoneType()
-  } catch (e) {
+  }
+  catch (e) {
     console.warn('error: app call getPhoneType', e)
     console.warn('error: app call getPhoneType', e)
   }
   }
 }
 }
@@ -303,7 +330,8 @@ export function appGetPhoneType() {
 export function appGetChannel() {
 export function appGetChannel() {
   try {
   try {
     JyObj.getChannel()
     JyObj.getChannel()
-  } catch (e) {
+  }
+  catch (e) {
     console.warn('error: app call getChannel', e)
     console.warn('error: app call getChannel', e)
   }
   }
 }
 }
@@ -312,7 +340,8 @@ export function appGetChannel() {
 export function appGetDeviceId() {
 export function appGetDeviceId() {
   try {
   try {
     JyObj.getDeviceId()
     JyObj.getDeviceId()
-  } catch (e) {
+  }
+  catch (e) {
     console.warn('error: app call getDeviceId', e)
     console.warn('error: app call getDeviceId', e)
   }
   }
 }
 }