Jelajahi Sumber

fix: ios微信分享链接问题

cuiyalong 4 tahun lalu
induk
melakukan
557ca0c302

+ 1 - 3
jydocs-mobile/src/api/main.ts

@@ -122,9 +122,7 @@ export function getListDetail (data: any) {
 }
 
 // 获取绑定的手机号
-
-export function getAccountInfo (data: any) {
-  data = qs.stringify(data)
+export function getAccountInfo () {
   return $request({
     baseURL: '',
     url: '/jypay/user/getAccountInfo',

+ 2 - 3
jydocs-mobile/src/components/docs-card/Price.vue

@@ -28,15 +28,14 @@ export default class Price extends Vue {
 .price-container {
   display: flex;
   align-items: center;
-  @include diy-icon('iconLogoLight', 22, 22);
+  @include diy-icon('iconLogoLight', 20, 20);
 
   .p-r {
     margin-left: 4px;
-    font-size: 18px;
+    font-size: 14px;
     color: #ff3a20;
     &.bought {
       color: $color_main;
-      font-size: 14px;
     }
   }
 }

+ 2 - 2
jydocs-mobile/src/store/modules/main.ts

@@ -239,9 +239,9 @@ const modulesOption: modulesOption = {
       } catch (error) {}
     },
     // 获取绑定手机号
-    async getAccountInfo (state, data) {
+    async getAccountInfo () {
       try {
-        const res = await getAccountInfo(data)
+        const res = await getAccountInfo()
         return res.data
       } catch (error) {}
     }

+ 1 - 0
jydocs-mobile/src/utils/index.ts

@@ -12,6 +12,7 @@ Vue.prototype.$env = {
   isAndroid: isAndroidOrIos === 'android',
   isIOS: isAndroidOrIos === 'ios'
 }
+Vue.prototype.$firstUrl = location.href.split('#')[0]
 
 // 正式环境下屏蔽console.log
 if (process.env.NODE_ENV === 'production') {

+ 3 - 4
jydocs-mobile/src/utils/wxShare.ts

@@ -13,7 +13,6 @@ declare module 'vue/types/vue' {
 
 const inWeiXinBrowser = isWeiXinBrowser()
 const isAndroidOrIos = androidOrIOS()
-const firstUrl = location.href.split('#')[0]
 
 export async function getSdkSign (url: string) {
   const sdkInfo = await getWxSdkSign({ url })
@@ -40,10 +39,10 @@ export async function weChatShare (options: any) {
 
   const device = isAndroidOrIos
   // 获取并注册sdkSign
-  const url = location.href.split('#')[0]
+  let url = location.href.split('#')[0]
   if (device === 'ios') {
-    // url = firstUrl
-    console.log(firstUrl)
+    url = (Vue as any).$firstUrl
+    console.log(url)
   }
   const wxSdk: any = await getSdkSign(url)
   Vue.prototype.$wxSdk = wxSdk

+ 13 - 4
jydocs-mobile/src/views/Home.vue

@@ -12,12 +12,12 @@
           <div class="flex flex-r-c center left">
             <van-icon :name="'diy-' + item.type" />
             <div class="flex">
-              <div class="van-ellipsis">{{item.title}}</div>
+              <div class="van-ellipsis d-title">{{item.title}}</div>
             </div>
           </div>
           <div class="right-info flex-r-c center right">
             <van-icon name="diy-iconJianYu" />
-            <span>{{item.money}}</span>
+            <span class="price-text">{{item.money}}</span>
           </div>
         </div>
         </van-skeleton>
@@ -34,12 +34,12 @@
           <div class="flex flex-r-c center left">
             <van-icon :name="'diy-' + item.type" />
             <div class="flex">
-              <div class="van-ellipsis">{{item.title}}</div>
+              <div class="van-ellipsis d-title">{{item.title}}</div>
             </div>
           </div>
           <div class="right-info flex-r-c center right">
             <van-icon name="diy-iconJianYu" />
-            <span>{{item.money}}</span>
+            <span class="price-text">{{item.money}}</span>
           </div>
         </div>
         </van-skeleton>
@@ -148,6 +148,15 @@ export default class extends Vue {
   padding-bottom: 40px;
   box-sizing: border-box;
 
+  .d-title {
+    font-size: 14px;
+    line-height: 20px;
+  }
+  .price-text {
+    font-size: 13px;
+    line-height: 28px;
+  }
+
   ::v-deep .van-loading-skeleton {
     &.line-style {
       .van-skeleton__row {

+ 0 - 1
jydocs-mobile/src/views/Search.vue

@@ -165,7 +165,6 @@ export default class extends Vue {
   }
 
   onFocus () {
-    console.log('fffff')
     const dom = document.querySelector('#mySearch input') as HTMLInputElement
     if (dom) {
       this.$nextTick(() => {

+ 0 - 1
jydocs-mobile/src/views/details/details.vue

@@ -190,7 +190,6 @@ export default class extends Vue {
   }
 
   updateText (data: any) {
-    // console.log(data)
     switch (data.type) {
       case 'count': {
         ;(document.getElementById('page_count') as HTMLDivElement).textContent = data.value

+ 0 - 6
jydocs-mobile/src/views/purchase/purchase.vue

@@ -140,12 +140,6 @@ export default class extends Vue {
 
   // 判断按钮是否可以点击
   iptValue () {
-    let bool = this.validator(this.tel)
-    if (this.tel === '') {
-      bool = true
-    } else {
-      bool = false
-    }
     this.getBool(this.validator(this.tel))
   }
 

+ 1 - 1
jydocs-mobile/src/views/purchase/purchasesuccess.vue

@@ -62,7 +62,7 @@ export default class extends Vue {
     currency: 0
   }
 
-  beforeRouteLeave (to, from, next) {
+  beforeRouteLeave (to: any, from: any, next: any) {
     if (this.timer) {
       clearInterval(this.timer)
     }

+ 1 - 0
jydocs-pc/src/components/NoData.vue

@@ -24,6 +24,7 @@ export default {
   text-align: center;
   .el-image {
     width: 220px;
+    overflow: visible;
   }
   .tip-text {
     margin-top: 14px;

+ 1 - 1
jydocs-pc/src/views/purchase/purchase.vue

@@ -116,7 +116,7 @@ export default {
     docTypeIcon () {
       const t = docTypeConvert(this.response.docFileType)
       return `el-icon-jy-${t}`
-    },
+    }
   },
   methods: {
     // 文档信息