Эх сурвалжийг харах

fix: 三级页客户端弹窗问题调试3

Signed-off-by: tangshizhe <48740614+tangshizhe@users.noreply.github.com>
tangshizhe 3 сар өмнө
parent
commit
eb28bdc460

+ 0 - 19
apps/mobile/src/api/modules/pay.js

@@ -405,22 +405,3 @@ export function vipGiftDetailAjax(data) {
     data
   })
 }
-
-export function creditReportEntSearch(data) {
-  data = qs.stringify(data)
-  return request({
-    url: '/subscribepay/bidCreditReport/entSearch',
-    method: 'POST',
-    data
-  })
-}
-
-// 企业信用报告生成时间配置
-export function creditReportTime(data) {
-  data = qs.stringify(data)
-  return request({
-    url: '/subscribepay/config',
-    method: 'POST',
-    data
-  })
-}

BIN
apps/mobile/src/assets/image/example-min.pdf


BIN
apps/mobile/src/assets/image/example.pdf


BIN
apps/mobile/src/assets/image/reportanalysis/credit-corner-bg.png


+ 1 - 13
apps/mobile/src/assets/js/productLink.js

@@ -12,18 +12,6 @@ export const productLinks = {
       app: '/jyapp/front/dataExport/toOrderDetail'
     }
   },
-  bidCreditRepoetLink: {
-    pay: {
-      wx: '/weixin/pay/checkout_bidcreditreport',
-      h5: '/jyapp/pay/checkout_bidcreditreport',
-      app: '/jyapp/pay/checkout_bidcreditreport'
-    },
-    orderDetail: {
-      wx: '/front/wx_bidcreditreport/wxToOrderDetail',
-      h5: '/jyapp/front/bidcreditreport/toOrderDetail',
-      app: '/jyapp/front/bidcreditreport/toOrderDetail'
-    }
-  },
   // VIP订阅
   vipSubLink: {
     pay: {
@@ -237,7 +225,7 @@ export const productLinks = {
       app: '/jyapp/common/enterpriseAnalysis/orderDetail'
     }
   },
-  // 产品类型:业主采购分析报告下载包
+  //产品类型:业主采购分析报告下载包
   ownerAnalysisLink: {
     pay: {
       wx: '/weixin/pay/checkout_ownerAnalysis',

+ 1 - 1
apps/mobile/src/main.js

@@ -11,7 +11,7 @@ import store from './store'
 import 'virtual:uno.css'
 import 'vant/lib/index.less'
 import '@/assets/style/index.scss'
-import 'core-js/stable/promise/with-resolvers'
+
 import 'dayjs/locale/zh-cn'
 
 import '@/utils/prototype'

+ 1 - 10
apps/mobile/src/router/modules/common.js

@@ -32,7 +32,7 @@ export default [
       title: '区域'
     }
   },
-  //
+  //  
   {
     path: '/vipsubscribeRights',
     name: 'vipsubscribeRights',
@@ -41,14 +41,5 @@ export default [
       header: true,
       title: '会员服务列表'
     }
-  },
-  {
-    path: '/pdfview',
-    name: 'pdfview',
-    component: () => import('@/views/common/pdfViewExample.vue'),
-    meta: {
-      header: true,
-      title: '投标企业信用报告样例'
-    }
   }
 ]

+ 0 - 17
apps/mobile/src/router/modules/order.js

@@ -114,23 +114,6 @@ export default [
           desc: () => import('@/views/order/components/bigmember/Introduction')
         })
       },
-      {
-        path: 'creditreport',
-        name: 'createCreditReportOrder',
-        meta: {
-          header: true,
-          productId: 150,
-          title: '购买投标企业信用报告'
-        },
-        components: createRouterNamedComponents({
-          default: () =>
-            import('@/views/create-order/components/creditreport/Default'),
-          activity: null,
-          form: null,
-          footer: () =>
-            import('@/views/create-order/components/creditreport/Footer')
-        })
-      },
       {
         path: 'datareport',
         name: 'createDataReportOrder',

+ 1 - 14
apps/mobile/src/store/modules/createOrder.js

@@ -69,7 +69,6 @@ const productNameMap = {
   115: '采购单位画像包',
   117: '数据报告',
   118: '剑鱼文库会员',
-  150: '投标企业信用报告',
   203: '市场分析定制报告下载包',
   201: '企业中标分析报告下载包',
   202: '业主采购分析报告下载包'
@@ -131,7 +130,6 @@ export default {
        * 113 省份订阅包
        * 114 附件下载包
        * 115 采购单位画像包
-       * 150 投标企业信用报告
        */
       id: -1,
       // 当前产品请求附加参数信息
@@ -176,13 +174,9 @@ export default {
       amount: false,
       submit: false
     },
-    isShowGiftNotice: false,
-    bidCreditReportInfo: {} // 投标企业信用报告信息
+    isShowGiftNotice: false
   }),
   mutations: {
-    SAVE_BID_CREDIT_REPORT_INFO(state, info) {
-      state.bidCreditReportInfo = info
-    },
     /**
      * 设置产品列表及更新下属信息
      * @param state
@@ -196,7 +190,6 @@ export default {
       state.productSpec.maps = productSpecMap
       state.product.index = defaultIndex
     },
-
     /**
      * 更新指定的产品规格信息
      * @param state
@@ -429,9 +422,6 @@ export default {
         )
       )
     },
-    async saveBidCreditReportInfo({ commit }, info) {
-      await commit('SAVE_BID_CREDIT_REPORT_INFO', Object.assign({}, info))
-    },
     // 根据商品ID、扩展等参数获取商品类型、规格等详细信息
     async getProductInfo({ commit, dispatch, getters, state }, payload) {
       // 合并一些请求参数
@@ -753,9 +743,6 @@ export default {
     }
   },
   getters: {
-    getBidCreditReportInfo(state) {
-      return state.bidCreditReportInfo
-    },
     // 用于提交订单的数据
     submitHooks(state) {
       return state.hooks.submit

+ 0 - 1
apps/mobile/src/utils/callFn/appFn.js

@@ -29,7 +29,6 @@ export function appCallCopyText(text) {
  * @param title 窗口标题
  */
 export function appCallOpenWindow(link, title = '剑鱼标讯') {
-  console.log('appCallOpenWindow', link, title)
   try {
     JyObj.openExternalLink(link, title)
   }

+ 15 - 56
apps/mobile/src/views/article/components/ContentHeader.vue

@@ -39,22 +39,13 @@
         参标人:{{ cbPersonText }}
       </span>
       <!-- 无参标人和时间一行 -->
-      <div v-else-if="showRenMaiButton" class="sub-info-line">
-        <div v-if="showCreditReport" class="creditreport-button" @click="creditReport">
-          <span class="creditreport-text">投标企业信用报告</span>
-        </div>
-        <div
-          class="relationship-button"
-          @click="findRenMai"
-        >
-          <span class="relationship-icon j-icon j-base-icon icon-renmai" />
-          <span class="relationship-text">找人脉</span>
-        </div>
-      </div>
-      <div v-else class="sub-info-line">
-        <div v-if="showCreditReport" class="creditreport-button" @click="creditReport">
-          <span class="creditreport-text">投标企业信用报告</span>
-        </div>
+      <div
+        v-else-if="showRenMaiButton"
+        class="relationship-button"
+        @click="findRenMai"
+      >
+        <span class="relationship-icon j-icon j-base-icon icon-renmai" />
+        <span class="relationship-text">找人脉</span>
       </div>
     </div>
     <div v-if="showRenMaiButton2" class="sub-info-line">
@@ -148,9 +139,6 @@ export default {
         return ''
       }
     },
-    showCreditReport() {
-      return articleTypeArr.includes(this.content?._ob?.topType || this.content?._ob?.subType || '')
-    },
     showRenMaiButton() {
       if (this.IsSunPublishContent) {
         return ''
@@ -167,6 +155,7 @@ export default {
       return this.otherModel.collectionTags
     }
   },
+  created() {},
   methods: {
     async onCollectionTagClick(tag) {
       if (this.beforeLeavePage) {
@@ -180,6 +169,7 @@ export default {
     },
     async checkHasRemMaiPower() {
       this.renmai.loading = true
+      console.log('checkHasRemMaiPower')
       try {
         const res = await getUserResource()
         if (res && Array.isArray(res.data)) {
@@ -193,25 +183,6 @@ export default {
         this.renmai.loading = false
       }
     },
-    creditReport() {
-      const buyer = this.summary?.buyers[0]?.name
-      const typeName = this.content?._ob?.topType || this.content?._ob?.subType
-      const breaker_name = `投标企业信用报告_${typeName}`
-      // 区分标讯类型埋点
-      try {
-        window.__EasyJTrack.addTrack(breaker_name, {
-          breaker_name
-        })
-      }
-      catch (e) {
-        console.log(e)
-      }
-      this.$router.push({
-        path: '/order/create/creditreport',
-        query: buyer ? { buyer } : {}
-      })
-    },
-
     async findRenMai() {
       const hasPower = await this.checkHasRemMaiPower()
       if (hasPower) {
@@ -324,32 +295,20 @@ export default {
 }
 
 .sub-info-line-r {
-  display: flex;
-  align-items: center;
-}
-.creditreport-button {
-  display: flex;
-  align-items: center;
-  justify-content: space-between;
-  margin-right: 10px;
-  padding: 2px 8px;
-  line-height: 20px;
-  color: #fff;
-  background: linear-gradient(to right, #5FD4E3, #28C1E2);
-  border-radius: 4px;
+  position: relative;
 }
 .relationship-button {
-  // position: relative;
-  // right: -16px;
-  // top: 0;
+  position: relative;
+  right: -16px;
+  top: 0;
   display: flex;
   align-items: center;
   justify-content: space-between;
   padding: 2px 12px;
   height: 24px;
   color: #fff;
-  background: linear-gradient(to right, #5FD4E3, #28C1E2);
-  border-radius: 4px;
+  background-color: $main;
+  border-radius: 14px 0 0 14px;
   .j-icon {
     margin-right: 4px;
     width: 12px;

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

@@ -1,9 +1,9 @@
 <template>
   <span class="origin-link-container">
     <span
-      v-bound-phone="bindPhoneViewOrigin()"
       class="highlight-text origin-link clickable"
       @click="viewOriginLink"
+      v-bound-phone="bindPhoneViewOrigin()"
     >
       查看原文链接
     </span>
@@ -23,7 +23,8 @@
         <span
           class="highlight-text"
           @click="leaveInfo('article_original_more_membership')"
-        >升级大会员 ></span>
+          >升级大会员 ></span
+        >
       </p>
     </van-dialog>
     <van-dialog
@@ -75,7 +76,7 @@ export default {
   },
   computed: {
     ...mapState({
-      content: state => state.article.mainModel.content
+      content: (state) => state.article.mainModel.content
     }),
     ...mapGetters('user', ['isFree']),
     url() {
@@ -120,8 +121,7 @@ export default {
             source: this.$env.platform.toUpperCase()
           }
         })
-      }
-      else {
+      } else {
         const loading = this.$toast.loading()
         try {
           const {
@@ -134,23 +134,19 @@ export default {
             if (data.url) {
               this.o_url = data.url
               this.openUrlAuth()
-            }
-            else if (data.status === 1) {
+            } else if (data.status === 1) {
               this.leaveInfo('article_original_one', {
                 signId: encodeURIComponent(this.id),
                 article: this.extractString(location.href)
               })
-            }
-            else if (data.status === 2) {
+            } else if (data.status === 2) {
               this.dialog.show = true
-            }
-            else if (data.status === 3) {
+            } else if (data.status === 3) {
               this.leaveInfo('article_original_more', {
                 signId: encodeURIComponent(this.id),
                 article: this.extractString(location.href)
               })
-            }
-            else if (data.status === 4) {
+            } else if (data.status === 4) {
               this.$dialog
                 .confirm({
                   title: '暂无更多查看原文链接权限',
@@ -169,16 +165,13 @@ export default {
                   }
                   openAppOrWxPage(LINKS.客服)
                 })
-            }
-            else {
+            } else {
               this.$toast(data.msg)
             }
-          }
-          else {
+          } else {
             console.log(msg)
           }
-        }
-        catch (error) {
+        } catch (error) {
           loading.clear()
         }
       }
@@ -193,8 +186,7 @@ export default {
       return getArticleOriginalText(param)
     },
     async openUrlAuth() {
-      if (!this.url)
-        return
+      if (!this.url) return
       if (this.toBCustom) {
         return this.openUrl()
       }
@@ -208,8 +200,7 @@ export default {
             this.dialog.see = true
             return
           }
-        }
-        catch (error) {
+        } catch (error) {
           console.log(error)
         }
       }
@@ -226,26 +217,22 @@ export default {
           if (data.url) {
             this.o_url = data.url
             this.openUrlAuth()
-          }
-          else {
+          } else {
             if (msg) {
               console.log(msg)
             }
           }
         }
-      }
-      catch (error) {
+      } catch (error) {
         console.log(error)
       }
     },
     openUrl() {
-      if (!this.url)
-        return
+      if (!this.url) return
       const { inApp } = this.$envs
       if (inApp) {
         appCallOpenWindow(this.url, '查看原文')
-      }
-      else {
+      } else {
         this.clickA(this.url)
       }
     },

+ 46 - 74
apps/mobile/src/views/article/content.vue

@@ -14,7 +14,7 @@ small-tab
           class="j-main article-content-main"
           :class="{
             'show-underline': otherModel.hasProject,
-            'no-scroll': showBindPhone,
+            'no-scroll': showBindPhone
           }"
           @click="onScrollWrapperClick"
           @scroll.passive="onScroll"
@@ -325,13 +325,13 @@ export default {
   },
   computed: {
     ...mapState({
-      preAgentInfo: state => state.article.preAgentInfo,
-      content: state => state.article.mainModel.content,
-      summary: state => state.article.mainModel.summary,
-      mainModel: state => state.article.mainModel,
-      expandModel: state => state.article.expandModel,
-      otherModel: state => state.article.otherModel,
-      bindPhone: state => state.article.bindPhone
+      preAgentInfo: (state) => state.article.preAgentInfo,
+      content: (state) => state.article.mainModel.content,
+      summary: (state) => state.article.mainModel.summary,
+      mainModel: (state) => state.article.mainModel,
+      expandModel: (state) => state.article.expandModel,
+      otherModel: (state) => state.article.otherModel,
+      bindPhone: (state) => state.article.bindPhone
     }),
     IsCustomTopNet() {
       return this.content.IsCustomTopNet || false
@@ -375,8 +375,7 @@ export default {
           show: this.content.isCanRead, // 是否展示全部内容
           showContentModule: this.hasPowerToReadSunPublishContent
         }
-      }
-      else {
+      } else {
         return {
           show: this.content.isCanRead,
           showContentModule: true
@@ -402,10 +401,10 @@ export default {
       return this.mainModel.moduleShow
     },
     advancedModuleShow() {
-      const { tbService, customerRecommend, timeline, zbRecommend }
-        = this.expandModel.moduleShow
-      const toBCustom
-        = this.IsCustomTopNet || this.IsSunPublishContent || this.yyszbContent
+      const { tbService, customerRecommend, timeline, zbRecommend } =
+        this.expandModel.moduleShow
+      const toBCustom =
+        this.IsCustomTopNet || this.IsSunPublishContent || this.yyszbContent
       return Object.assign({}, this.expandModel.moduleShow, {
         tbService: toBCustom ? false : tbService,
         customerRecommend: toBCustom ? false : customerRecommend,
@@ -424,8 +423,7 @@ export default {
       // 如果是有权限用户(权限7),则有数据展示,无数据不展示。无权限7用户则一直展示,展示广告引导
       if (this.hasCustomerModulePower) {
         return this.advancedModuleShow.customerRecommend
-      }
-      else {
+      } else {
         return true
       }
     },
@@ -493,31 +491,26 @@ export default {
           }
           this.checkNpsView()
         })
-      }
-      else {
+      } else {
         try {
           await this.getPreAgentInfo()
           const { data, msg } = await this.getBaseInfo()
           if (data) {
             this.finishLoading()
-          }
-          else {
+          } else {
             this.finishLoading()
             this.isError = true
             // 无效参数 = d解析错误
             // 未查到当前招标信息 = 文章不存在
             if (msg.includes('未查到当前招标信息')) {
               this.errorText = '由于相关部门要求,该信息已下架,敬请原谅'
-            }
-            else {
+            } else {
               this.errorText = '该页面信息不存在'
             }
           }
-        }
-        catch (error) {
+        } catch (error) {
           console.error(error)
-        }
-        finally {
+        } finally {
           // console.log('基础接口请求完成')
         }
         if (this.canReadConf.show) {
@@ -541,8 +534,7 @@ export default {
       let subType = ''
       try {
         subType = this.content?._ob?.subType
-      }
-      catch (error) {
+      } catch (error) {
         console.log(error)
       }
       let prefix = ''
@@ -552,8 +544,7 @@ export default {
       const newTitle = prefix + title
       if (otherTitle) {
         this.postMessageToMiniProgram(otherTitle)
-      }
-      else {
+      } else {
         this.postMessageToMiniProgram(newTitle)
       }
     },
@@ -567,8 +558,7 @@ export default {
             title
           }
         })
-      }
-      catch (e) {
+      } catch (e) {
         console.log(e)
       }
     },
@@ -580,8 +570,7 @@ export default {
     },
     appHeaderActions() {
       const { $envs } = this
-      if (!$envs.inApp)
-        return
+      if (!$envs.inApp) return
       if (this.yyszbContent) {
         return
       }
@@ -609,11 +598,9 @@ export default {
       // project-name事件委托
       if (checkUnderline.status) {
         this.clickKeywordUnderline(e)
-      }
-      else if (e.target.classList.contains('free-view')) {
+      } else if (e.target.classList.contains('free-view')) {
         this.clickFreeView(e)
-      }
-      else if (e.target.className.includes('third-party-popover')) {
+      } else if (e.target.className.includes('third-party-popover')) {
         this.popup.thirdPartyVerify = true
       }
     },
@@ -631,8 +618,7 @@ export default {
             this.goMemberFollowPage()
           }
         })
-      }
-      else if (checkWinnerName.status) {
+      } else if (checkWinnerName.status) {
         this.goToEntPortraitPage(checkWinnerName.target)
       }
     },
@@ -652,8 +638,7 @@ export default {
             industry: _ob ? _ob.buyerClass : undefined
           }
         })
-      }
-      else {
+      } else {
         openAppOrWxPage(LINKS.项目详情页)
       }
     },
@@ -664,12 +649,11 @@ export default {
         ?.replace(/\?/g, '%3F')
       if (!id) {
         return this.$toast('暂无数据')
-      }
-      else {
-        const noPower
-          = !this.bigMemberPower.includes(4)
-          && !this.bigMemberPower.includes(12)
-          && !this.bigMemberPower.includes(13)
+      } else {
+        const noPower =
+          !this.bigMemberPower.includes(4) &&
+          !this.bigMemberPower.includes(12) &&
+          !this.bigMemberPower.includes(13)
         if (this.isMember && noPower) {
           if (eName) {
             this.beforeLeavePage()
@@ -678,12 +662,10 @@ export default {
               app: LINKS.旧版企业信息前缀.app + eName,
               h5: LINKS.旧版企业信息前缀.h5 + eName
             })
-          }
-          else {
+          } else {
             return this.$toast('暂无数据')
           }
-        }
-        else {
+        } else {
           this.beforeLeavePage()
           sessionStorage.removeItem('$data-ent_portrait')
           openAppOrWxPage(LINKS.企业画像页面, {
@@ -729,14 +711,12 @@ export default {
       if (this.$envs.inWX) {
         try {
           await this.getShareInfoReq()
-        }
-        catch (error) {
+        } catch (error) {
           console.log(error)
         }
         await this.calcWxShareInfo()
         this.initShareMixin()
-      }
-      else {
+      } else {
         this.getShareInfoReq()
       }
     },
@@ -773,8 +753,7 @@ export default {
       if (window.location.href.includes('open_infocontent')) {
         const query = window.location.search.slice(1)
         link += `${query}`
-      }
-      else {
+      } else {
         link += '&source=wx_infocontentshare'
       }
 
@@ -791,22 +770,19 @@ export default {
             subhref = `${add1}/content/${encryptid}${add2}`
             this.wxShareCache.subhref = subhref
           }
-        }
-        catch (error) {
+        } catch (error) {
           console.warn(error)
         }
       }
 
       if (encryptid) {
         link = subhref
-      }
-      else {
+      } else {
         link = window.location.href
       }
       if (!link.includes('?')) {
         link += '?'
-      }
-      else {
+      } else {
         link += '&'
       }
       if (!encryptid) {
@@ -851,14 +827,12 @@ export default {
           link += `${location.search}&source=app_infocontentshare&from=${
             this.shareInfoRes.userId || ''
           }`
-        }
-        else {
+        } else {
           link += `?source=app_infocontentshare&from=${
             this.shareInfoRes.userId || ''
           }`
         }
-      }
-      else if (shareType === 3) {
+      } else if (shareType === 3) {
         // 分享到朋友圈
         link += '&qrcodeType=app_infocontent_timeline_z'
         shareTitle = this.getRandomShareText()
@@ -870,8 +844,7 @@ export default {
       // this.shareConf.link = link
       if (this.$envs.inApp && shareToWx) {
         this.refreshShareLink(this.domainConf.wx)
-      }
-      else {
+      } else {
         this.refreshShareLink()
       }
     },
@@ -894,8 +867,7 @@ export default {
     },
     checkNpsView() {
       const targetVm = this.$refs.npsCard
-      if (!targetVm)
-        return
+      if (!targetVm) return
       const target = targetVm.$el
       const scrollWrapper = this.$refs.scrollWrapper
       const visible = isElementInScrollArea(target, scrollWrapper)
@@ -906,9 +878,9 @@ export default {
     checkTestBindPhone(name, next) {
       this.$testBindPhone({
         props: {
-          name
+          name: name
         },
-        next
+        next: next
       })
     }
   }

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

@@ -1,133 +0,0 @@
-<template>
-  <div class="pdf-view-example j-contanter">
-    <div id="pdf-view-container" class="j-main" />
-    <div v-if="!getUserId" class="j-footer">
-      <a href="/jyapp/free/login?url=/jy_mobile/order/create/creditreport&activity=bidCreditReportPreview" class="adsense-container">
-        <AdSingle
-          ad="app-credit-report-sample"
-          :show-tag="false"
-          :show-close-icon="false"
-          class="adsense-container"
-        />
-      </a>
-    </div>
-  </div>
-</template>
-
-<script>
-import { mapGetters } from 'vuex'
-import * as pdfjsLib from 'pdfjs-dist/build/pdf'
-import AdSingle from '@/components/ad/Ad'
-import { getAssetsFile } from '@/utils'
-import 'pdfjs-dist/build/pdf.worker.mjs'
-
-export default {
-  name: 'PdfViewExample',
-  components: {
-    AdSingle
-  },
-  data() {
-    return {
-      pdfUrl: '',
-      pdf: null,
-      totalPages: 0,
-      currentPage: 1, // 新增
-      batchSize: 5 // 新增
-    }
-  },
-  computed: {
-    ...mapGetters('user', ['getUserId'])
-  },
-  created() {
-    this.$toast.loading('加载中...')
-
-    const { pdfUrl } = this.$route.query
-    if (pdfUrl) {
-      this.pdfUrl = decodeURIComponent(pdfUrl)
-    }
-    else {
-      const pdfAssets = getAssetsFile('example-min.pdf')
-      // this.pdfUrl = 'https://cdn-common.jianyu360.cn/cdn/assets/file/example.pdf'
-      this.pdfUrl = pdfAssets
-    }
-  },
-  mounted() {
-    const container = document.getElementById('pdf-view-container')
-
-    this.loadPdf(this.pdfUrl, container)
-    // 监听窗口的 resize 事件,实现自适应效果
-    window.addEventListener('resize', () => {
-      container.innerHTML = ''
-      this.loadPdf(this.pdfUrl, container)
-    })
-  },
-  methods: {
-    async loadPdf(pdfUrl, container) {
-      try {
-        const loadingTask = pdfjsLib.getDocument({
-          url: pdfUrl,
-          disableRange: true,
-          disableAutoFetch: false, // 启动自动分块加载
-          workerSrc: 'pdfjs-dist/build/pdf.worker.mjs',
-          // 添加缓存头
-          httpHeaders: {
-            'Cache-Control': 'max-age=3600' // 缓存 1 小时
-          },
-          // 增加网络请求超时时间,避免因网络问题导致加载失败
-          timeout: 30000,
-          // 减少初始加载的字节数,提高初始加载速度
-          initialDataSize: 1024 * 1024
-        })
-        pdfjsLib.GlobalWorkerOptions.workerSrc = 'pdfjs-dist/build/pdf.worker.mjs'
-        this.pdf = await loadingTask.promise
-        this.totalPages = this.pdf.numPages
-        this.currentPage = 1
-        this.batchSize = 5 // 新增
-
-        await this.loadBatchPages(container) // 新增
-        this.$toast.clear()
-        // 监听滚动事件
-        container.addEventListener('scroll', () => this.handleScroll(container))
-      }
-      catch (error) {
-        console.error('Error loading PDF:', error)
-      }
-    },
-    async loadBatchPages(container) {
-      // 加载当前页码开始的连续多页,这里以5页为例
-      // 分批加载,从当前页码开始,最多加载5页
-      const endPage = Math.min(this.currentPage + this.batchSize - 1, this.totalPages)
-      for (let pageNum = this.currentPage; pageNum <= endPage; pageNum++) {
-        const page = await this.pdf.getPage(pageNum)
-        const viewport = page.getViewport({ scale: this.calculateScale(page) })
-        const canvas = document.createElement('canvas')
-        const ctx = canvas.getContext('2d')
-        canvas.height = viewport.height
-        canvas.width = viewport.width
-        container.appendChild(canvas)
-
-        await page.render({
-          canvasContext: ctx,
-          viewport,
-        }).promise
-      }
-      this.currentPage = endPage + 1 // 更新当前页码
-    },
-    handleScroll(container) {
-      const { scrollTop, scrollHeight, clientHeight } = container
-      if (scrollTop + clientHeight >= scrollHeight - 100) { // 当滚动到底部附近时
-        if (this.currentPage <= this.totalPages) {
-          this.loadBatchPages(container)
-        }
-      }
-    },
-    // 计算缩放比例以适应容器宽度
-    calculateScale(page) {
-      const containerWidth = document.getElementById('pdf-view-container').clientWidth
-      const viewport = page.getViewport({ scale: 1 })
-      // 增加一个倍数来提高清晰度,例如 1.5
-      return (containerWidth / viewport.width) * 3
-    }
-  }
-}
-</script>

+ 0 - 14
apps/mobile/src/views/create-order/components/creditreport/Default.vue

@@ -1,14 +0,0 @@
-<template>
-  <ProductionCard />
-</template>
-
-<script>
-import ProductionCard from './ProductionCard'
-
-export default {
-  name: 'ProductionCardDefault',
-  components: {
-    ProductionCard
-  }
-}
-</script>

+ 0 - 110
apps/mobile/src/views/create-order/components/creditreport/Footer.vue

@@ -1,110 +0,0 @@
-<template>
-  <div>
-    <SubmitBar
-      class="credit-order-footer"
-      :checked="canNextMap.read"
-      :params="params"
-      :confirm-btn-text="confirmBtnText"
-      :confirm-disabled="confirmDisabled"
-      :confirm-btn-tip-text="confirmBtnTipText"
-      cancel-btn-text="报告样例"
-      :show-cancel-btn="showCancelBtn"
-      :show-price="showPrice"
-      @input="checkedChange"
-      @confirmBtn="onConfirm"
-      @cancelBtn="onCreditRepoert"
-      @pass="checkedChange"
-      @toLink="saveBaseInfo"
-    />
-  </div>
-</template>
-
-<script>
-import { mapActions, mapGetters, mapMutations, mapState } from 'vuex'
-import SubmitBar from '@/components/create-order/SubmitBar'
-
-export default {
-  name: 'CreateOrderFooter',
-  components: {
-    SubmitBar
-  },
-  data() {
-    return {
-      showCancelBtn: true
-    }
-  },
-  computed: {
-    ...mapState('createOrder', ['canNextMap', 'hooks']),
-    ...mapGetters('createOrder', [
-      'productOrderAmount',
-      'productUI',
-      'canSubmitOrder',
-      'getBidCreditReportInfo'
-    ]),
-    params() {
-      const { pay, origin, discount } = this.productOrderAmount
-      const { deductCount } = this.productUI
-      return {
-        deductCount,
-        pay,
-        origin,
-        discount // 折扣,优惠了多少钱
-      }
-    },
-    confirmDisabled() {
-      return !this.canSubmitOrder
-    },
-    showPrice() {
-      // 个人支付显示价格信息
-      return this.productUI.personalPay
-    },
-    confirmBtnTipText() {
-      return this.productUI.personalPay ? undefined : '(支付后可开票)'
-    },
-    confirmBtnText() {
-      return this.productUI.submitText || '提交订单'
-    }
-  },
-  methods: {
-    ...mapMutations('createOrder', ['updateCanNextMap']),
-    ...mapActions('createOrder', ['submitCreatedProductOrder']),
-    checkedChange(f) {
-      this.updateCanNextMap({
-        read: f
-      })
-    },
-    onCreditRepoert() {
-      console.log(this.getBidCreditReportInfo, 'getBidCreditReportInfo')
-      // 将getBidCreditReportInfo保存到本地
-      this.saveBaseInfo()
-      this.$router.push({
-        path: '/common/pdfview'
-      })
-    },
-    saveBaseInfo() {
-      this.$storage.set('bidCreditReportInfo', this.getBidCreditReportInfo, { storage: sessionStorage })
-    },
-    onConfirm() {
-      this.submitCreatedProductOrder()
-    }
-  }
-}
-</script>
-
-<style lang="scss" scoped>
-.credit-order-footer {
-  ::v-deep {
-    .van-button--default {
-      flex: none;
-      width: 96px;
-      border: 1px solid #2ABED1;
-      background: rgba(42, 190, 209, 0.08);
-      color: #2ABED1;
-    }
-    .van-button--primary {
-      flex: none;
-      width: 96px;
-    }
-  }
-}
-</style>

+ 0 - 351
apps/mobile/src/views/create-order/components/creditreport/ProductionCard.vue

@@ -1,351 +0,0 @@
-<template>
-  <div class="production-card credit-report-production-card">
-    <div class="report-func">
-      <div class="report-func-title">
-        报告作用
-      </div>
-      <div class="report-func-content">
-        信用报告通过信用背书、风险预警、政策适配,三大核心作用,成为投标企业参与市场竞争的关键工具。
-      </div>
-    </div>
-    <div class="report-info">
-      <van-form ref="formRef">
-        <van-field
-          v-model="info.company"
-          class="ent-input-field"
-          required
-          type="textarea"
-          autosize
-          rows="1"
-          name="pattern"
-          label="投标企业名称"
-          placeholder="必填"
-          :show-error="false"
-          :rules="[
-            { required: true, message: '必填' },
-            { pattern: /^.{3,}$/, message: '输入内容需大于两个字' }, // 添加正则验证规则
-          ]"
-          @input="onInput($event, 'ent')"
-          @blur="onBlur('company')"
-        >
-          <template #extra>
-            <!-- 添加联想弹窗 -->
-            <div v-if="entList.length" class="ent-popup-container">
-              <div class="ent-popup-wrap">
-                <div v-for="(item, index) in entList" :key="index" class="wrap-list" @click="clickAssociation(item, 'ent')">
-                  {{ item.name }}
-                </div>
-              </div>
-            </div>
-          </template>
-        </van-field>
-        <van-field
-          v-model="info.buyer"
-          class="company-input-field"
-          required
-          type="textarea"
-          autosize
-          rows="1"
-          name="pattern"
-          label="招标单位名称"
-          placeholder="必填"
-          :show-error="false"
-          :rules="[
-            { required: true, message: '必填' },
-            { pattern: /^.{3,}$/, message: '输入内容需大于两个字' }, // 添加正则验证规则
-          ]"
-          @input="onInput($event, 'company')"
-          @blur="onBlur('buyer')"
-        >
-          <template #extra>
-            <!-- 添加联想弹窗 -->
-            <div v-if="companyList.length" class="ent-popup-container">
-              <div class="ent-popup-wrap">
-                <div v-for="(item, index) in companyList" :key="index" class="wrap-list" @click="clickAssociation(item, 'company')">
-                  {{ item.name }}
-                </div>
-              </div>
-            </div>
-          </template>
-        </van-field>
-        <van-field
-          v-model="info.email"
-          required
-          name="pattern"
-          label="邮箱"
-          placeholder="必填,报告将发送至邮箱"
-          :show-error="false"
-          :rules="[
-            { required: true, message: '请输入邮箱' },
-            { pattern: /^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$/, message: '邮箱格式错误' }, // 邮箱校验正则规则
-          ]"
-          @blur="onBlur('email')"
-        />
-      </van-form>
-    </div>
-    <div class="report-tip">
-      支付成功后,系统将于{{ bidCreditReportTime }}内将报告发送至您的邮箱,您也可前往“资产-报告下载记录”查看详情。
-    </div>
-  </div>
-</template>
-
-<script>
-import { mapActions, mapGetters, mapMutations } from 'vuex'
-import { Field, Form } from 'vant'
-import { debounce } from '@/utils/utils'
-import { mixinHeader } from '@/utils/mixins/header'
-import { openAppOrWxPage } from '@/utils'
-import { appCallOpenWindow } from '@/utils/callFn/appFn'
-import { creditReportEntSearch, creditReportTime } from '@/api/modules/'
-import orderActivityHelper from '@/utils/mixins/modules/order-activity-helper'
-
-export default {
-  name: 'CreditReportProductionCard',
-  components: {
-    [Form.name]: Form,
-    [Field.name]: Field
-  },
-  mixins: [mixinHeader, orderActivityHelper],
-  data() {
-    return {
-      pageLayoutConf: {
-        title: '购买投标企业信用报告',
-      },
-      conf: {
-        productName: '投标企业信用报告',
-        productId: 150,
-        linkKey: 'bidCreditRepoetLink',
-      },
-      info: {
-        company: '',
-        buyer: '',
-        cert_no: '',
-        email: ''
-      },
-      entList: [],
-      companyList: [],
-      bidCreditReportTime: 0
-    }
-  },
-  computed: {
-    ...mapGetters('createOrder', ['productExtend', 'productId', 'getBidCreditReportInfo'])
-  },
-  watch: {
-    info: {
-      deep: true,
-      handler(newVal) {
-        this.saveBidCreditReportInfo(newVal)
-      }
-    },
-  },
-  created() {
-    const { buyer } = this.$route.query
-    if (buyer) {
-      this.info.buyer = buyer
-    }
-  },
-  mounted() {
-    this.updatePayAmount()
-    this.getCreditReportTime()
-    this.getUserInfoFun()
-    const bidCreditReportInfo = this.$storage.get('bidCreditReportInfo', {}, {
-      storage: sessionStorage
-    })
-    if (Object.keys(bidCreditReportInfo).length) {
-      Object.assign(this.info, bidCreditReportInfo)
-      // 删除本地缓存
-      this.$storage.rm('bidCreditReportInfo', { storage: sessionStorage })
-    }
-  },
-  methods: {
-    ...mapActions('createOrder', ['setProductInfo', 'saveBidCreditReportInfo']),
-    ...mapActions('user', ['getUserInfo']),
-    async getCreditReportTime() {
-      const { error_code: code, data } = await creditReportTime()
-      if (code === 0) {
-        this.bidCreditReportTime = data.bidCreditReport_makeTime
-      }
-    },
-    async getUserInfoFun() {
-      const res = await this.getUserInfo()
-      if (res?.reportMail) {
-        this.info.email = res.reportMail || ''
-      }
-    },
-    async updatePayAmount() {
-      const { productId } = this.conf
-      this.setProductInfo({
-        id: productId,
-        hooks: {
-          submit: this.onSubmit.bind(this)
-        }
-      })
-    },
-    async onSubmit(pre, next) {
-      // 校验输入框是否全部填写完成,如果没有则不提交订单
-      let validBool = false
-      await this.$refs.formRef.validate().then((valid) => {
-        validBool = !valid
-      })
-      if (!validBool)
-        return
-      const payload = {
-        product: pre.productName,
-        productId: pre.productSpecId,
-        discountId: pre.offersId,
-        lotteryId: pre.offersId,
-        activityType: pre.activityType,
-        data: {
-          ...this.info
-        }
-      }
-      const res = await next(payload)
-      const { data } = res
-      if (data && data.needPay) {
-        const { linkKey } = this.conf
-        const query = this.getCommonQuery(data.order_code)
-        const orderDetailLinkInfo
-            = this.getProductionLinks(linkKey).orderDetail
-        const payLinkInfo = this.getProductionLinks(linkKey).pay
-        if (this.$envs.inApp || this.$envs.inWX) {
-          this.$storage.set(
-            `${this.$route.path}-redirect`,
-            {
-              urls: orderDetailLinkInfo,
-              query
-            },
-            { storage: sessionStorage }
-          )
-        }
-        openAppOrWxPage(payLinkInfo, {
-          query
-        })
-        return res
-      }
-    },
-    clickAssociation(item, type) {
-      if (type === 'ent') {
-        this.info.company = item.name
-        this.info.cert_no = item.cert_no
-        this.entList = []
-      }
-      else {
-        this.info.buyer = item.name
-        this.companyList = []
-      }
-    },
-    onInput(value, type) {
-      const pattner = /^.{3,}$/
-      if (!pattner.test(value))
-        return
-      this.getCompany(value, type)
-    },
-    onBlur(fieldName) {
-      // 投标企业名称必须选择联想内的企业
-      if (fieldName === 'company') {
-        if (!this.info.cert_no) {
-          this.info.company = ''
-        }
-      }
-    },
-    // 获取公司联想数据
-    getCompany: debounce(function (val, type) {
-      if (val) {
-        creditReportEntSearch({ entName: val }).then((res) => {
-          if (type === 'ent') {
-            this.entList = res.data || []
-          }
-          else {
-            this.companyList = res.data || []
-          }
-        })
-      }
-    }, 500)
-  }
-}
-</script>
-
-<style lang="scss" scoped>
-.credit-report-production-card {
-  .report-func {
-    padding: 12px 16px;
-    background: #fff;
-    .report-func-title {
-      font-size: 16px;
-      line-height: 24px;
-      color: #171826;
-      margin-bottom: 4px;
-    }
-    .report-func-content {
-      font-size: 13px;
-      line-height: 20px;
-      color:#5F5E64;
-    }
-  }
-  .report-info {
-    margin-top: 8px;
-    ::v-deep {
-      .van-cell {
-        padding: 15px 16px 15px 24px;
-        .van-cell__title {
-         font-size: 15px;
-         line-height: 22px;
-         color: #5F5E64;
-        }
-        input::placeholder, textarea::placeholder {
-          font-size: 15px;
-          line-height: 22px;
-          color: #C0C4CC;
-        }
-        .van-field__control {
-          white-space: normal;
-          word-wrap: break-word;
-        }
-        &.ent-input-field, &.company-input-field {
-          position: relative;
-          .ent-popup-container {
-            position: absolute;
-            top: 54px;
-            right: 20px;
-            overflow: hidden;
-            overflow-y: auto;
-            width: 230px;
-            max-height: 150px;
-            z-index: 1;
-            background: #fff;
-            border: 1px solid #2ABED1;
-            border-radius: 8px;
-          }
-          .ent-popup-wrap {
-            display: flex;
-            flex-direction: column;
-            .wrap-list {
-              width: 100%;
-              white-space: nowrap;
-              overflow: hidden;
-              text-overflow: ellipsis;
-              padding: 4px 10px;
-              font-size: 15px;
-              line-height: 22px;
-              color: #171826;
-              border-bottom: 1px solid rgba(0, 0, 0, 0.05);
-            }
-          }
-        }
-        &.van-field--error .van-field__control {
-          color: #171826;
-        }
-      }
-      .van-cell--required::before {
-        left: 16px;
-      }
-    }
-  }
-  .report-tip {
-    padding: 12px 16px;
-    font-size: 12px;
-    line-height: 18px;
-    color: #9B9CA3;
-  }
-}
-</style>

+ 102 - 210
apps/mobile/src/views/reportAnalysis/components/listItem.vue

@@ -1,18 +1,12 @@
 <template>
   <div id="listItem">
-    <div class="tag" :class="tagclass">
-      {{ data.type | typeFilter }}
-    </div>
-    <div class="toptime">
-      {{ data.l_createTime | timeFilter }}
-    </div>
+    <div class="tag" :class="tagclass">{{ data.type | typeFilter }}</div>
+    <div class="toptime">{{ data.l_createTime | timeFilter }}</div>
     <div class="content">
       <!-- 企业 -->
       <div v-if="tagclass === 'green'">
         <div class="item">
-          <p class="label">
-            目标企业:
-          </p>
+          <p class="label">目标企业:</p>
           <p
             class="value heigh_line ellipsis"
             @click="$emit('titleClick', data)"
@@ -21,175 +15,89 @@
           </p>
         </div>
         <div class="item">
-          <p class="label">
-            成交时间:
-          </p>
-          <p class="value">
-            {{ data.timeRange | timeRangeF }}
-          </p>
+          <p class="label">成交时间:</p>
+          <p class="value">{{ data.timeRange | timeRangeF }}</p>
         </div>
-        <div v-if="data.match" class="item">
-          <p class="label">
-            关键词:
-          </p>
-          <p class="value ellipsis">
-            {{ matchF(data.match, data) }}
-          </p>
+        <div class="item" v-if="data.match">
+          <p class="label">关键词:</p>
+          <p class="value ellipsis">{{ matchF(data.match, data) }}</p>
         </div>
-        <div v-if="data.matchRange" class="item">
-          <p class="label">
-            搜索范围:
-          </p>
-          <p class="value ellipsis">
-            {{ data.matchRange | matchRangeF }}
-          </p>
+        <div class="item" v-if="data.matchRange">
+          <p class="label">搜索范围:</p>
+          <p class="value ellipsis">{{ data.matchRange | matchRangeF }}</p>
         </div>
-        <div v-if="data.area" class="item">
-          <p class="label">
-            项目地区:
-          </p>
-          <p class="value ellipsis">
-            {{ data.area | areaF }}
-          </p>
-        </div>
-        <div v-if="data.scopeClass" class="item">
-          <p class="label">
-            行业:
-          </p>
-          <p class="value ellipsis">
-            {{ data.scopeClass | scopeClassF }}
-          </p>
-        </div>
-        <div v-if="data.s_buyerClass" class="item">
-          <p class="label long">
-            采购单位类型:
-          </p>
-          <p class="value ellipsis">
-            {{ data.s_buyerClass | buyerClassF }}
-          </p>
+        <div class="item" v-if="data.area">
+          <p class="label">项目地区:</p>
+          <p class="value ellipsis">{{ data.area | areaF }}</p>
         </div>
-      </div>
-      <div v-if="tagclass === 'blue2'">
-        <div v-if="data.ent" class="item">
-          <p class="label">
-            投标企业名称:
-          </p>
-          <p class="value ellipsis">
-            {{ data.ent }}
-          </p>
+        <div class="item" v-if="data.scopeClass">
+          <p class="label">行业:</p>
+          <p class="value ellipsis">{{ data.scopeClass | scopeClassF }}</p>
         </div>
-        <div v-if="data.buyer" class="item">
-          <p class="label long">
-            投标单位名称:
-          </p>
-          <p class="value ellipsis">
-            {{ data.buyer }}
-          </p>
+        <div class="item" v-if="data.s_buyerClass">
+          <p class="label long">采购单位类型:</p>
+          <p class="value ellipsis">{{ data.s_buyerClass | buyerClassF }}</p>
         </div>
       </div>
       <!-- 业主采购 -->
       <div v-if="tagclass === 'yellow'">
         <div class="item">
-          <p class="label">
-            目标业主:
-          </p>
+          <p class="label">目标业主:</p>
           <p class="value heigh_line" @click="$emit('titleClick', data)">
             {{ data.entName || '-' }}
           </p>
         </div>
         <div class="item">
-          <p class="label">
-            成交时间:
-          </p>
-          <p class="value">
-            {{ data.timeRange | timeRangeF }}
-          </p>
+          <p class="label">成交时间:</p>
+          <p class="value">{{ data.timeRange | timeRangeF }}</p>
         </div>
-        <div v-if="data.match" class="item">
-          <p class="label">
-            关键词:
-          </p>
-          <p class="value ellipsis">
-            {{ matchF(data.match, data) }}
-          </p>
+        <div class="item" v-if="data.match">
+          <p class="label">关键词:</p>
+          <p class="value ellipsis">{{ matchF(data.match, data) }}</p>
         </div>
-        <div v-if="data.matchRange" class="item">
-          <p class="label">
-            搜索范围:
-          </p>
-          <p class="value ellipsis">
-            {{ data.matchRange | matchRangeF }}
-          </p>
+        <div class="item" v-if="data.matchRange">
+          <p class="label">搜索范围:</p>
+          <p class="value ellipsis">{{ data.matchRange | matchRangeF }}</p>
         </div>
-        <div v-if="data.area" class="item">
-          <p class="label">
-            项目地区:
-          </p>
-          <p class="value ellipsis">
-            {{ data.area | areaF }}
-          </p>
+        <div class="item" v-if="data.area">
+          <p class="label">项目地区:</p>
+          <p class="value ellipsis">{{ data.area | areaF }}</p>
         </div>
-        <div v-if="data.scopeClass" class="item">
-          <p class="label">
-            行业:
-          </p>
-          <p class="value ellipsis">
-            {{ data.scopeClass | scopeClassF }}
-          </p>
+        <div class="item" v-if="data.scopeClass">
+          <p class="label">行业:</p>
+          <p class="value ellipsis">{{ data.scopeClass | scopeClassF }}</p>
         </div>
-        <div v-if="data.s_buyerClass" class="item">
-          <p class="label long">
-            采购单位类型:
-          </p>
-          <p class="value ellipsis">
-            {{ data.s_buyerClass | buyerClassF }}
-          </p>
+        <div class="item" v-if="data.s_buyerClass">
+          <p class="label long">采购单位类型:</p>
+          <p class="value ellipsis">{{ data.s_buyerClass | buyerClassF }}</p>
         </div>
       </div>
       <!-- 定制化分析 -->
       <div v-if="tagclass === 'blue'">
         <div class="item">
-          <p class="label">
-            分析内容:
-          </p>
-          <p class="value ellipsis" v-html="formatKeys(data.s_keysItems)" />
+          <p class="label">分析内容:</p>
+          <p class="value ellipsis" v-html="formatKeys(data.s_keysItems)"></p>
         </div>
         <div class="item">
-          <p class="label">
-            匹配方式:
-          </p>
-          <p class="value">
-            {{ formatMatchWay(data.s_matchingMode) }}
-          </p>
+          <p class="label">匹配方式:</p>
+          <p class="value">{{ formatMatchWay(data.s_matchingMode) }}</p>
         </div>
         <div class="item">
-          <p class="label">
-            成交时间:
-          </p>
+          <p class="label">成交时间:</p>
           <p class="value ellipsis">
             {{ data.s_rangeTime | formatTime('yyyy-MM-dd') }}
           </p>
         </div>
-        <div v-if="formatArea(data.s_area)" class="item">
-          <p class="label">
-            项目地区:
-          </p>
-          <p class="value ellipsis">
-            {{ formatArea(data.s_area) }}
-          </p>
+        <div class="item" v-if="formatArea(data.s_area)">
+          <p class="label">项目地区:</p>
+          <p class="value ellipsis">{{ formatArea(data.s_area) }}</p>
         </div>
-        <div v-if="formatIndustry(data.s_industry)" class="item">
-          <p class="label">
-            行业:
-          </p>
-          <p class="value ellipsis">
-            {{ formatIndustry(data.s_industry) }}
-          </p>
+        <div class="item" v-if="formatIndustry(data.s_industry)">
+          <p class="label">行业:</p>
+          <p class="value ellipsis">{{ formatIndustry(data.s_industry) }}</p>
         </div>
-        <div v-if="formatBuyerclass(data.s_buyerClass)" class="item">
-          <p class="label long">
-            采购单位类型:
-          </p>
+        <div class="item" v-if="formatBuyerclass(data.s_buyerClass)">
+          <p class="label long">采购单位类型:</p>
           <p class="value ellipsis">
             {{ formatBuyerclass(data.s_buyerClass) }}
           </p>
@@ -197,17 +105,29 @@
       </div>
     </div>
     <div class="foot_btn" @click="$emit('download', data)">
-      <span class="download_icon" />
+      <span class="download_icon"></span>
       <span class="download">下载</span>
     </div>
   </div>
 </template>
 
 <script>
-import { FilterHistoryAjaxModel2ViewModel, dateFormatter } from '@/utils/'
-
+import { dateFormatter, FilterHistoryAjaxModel2ViewModel } from '@/utils/'
 export default {
-  name: 'ListItem',
+  name: 'listItem',
+  data() {
+    return {}
+  },
+  props: {
+    data: {
+      type: Object,
+      default: () => {}
+    },
+    tagclass: {
+      type: String,
+      default: 'green'
+    }
+  },
   filters: {
     dateFilter(val) {
       return val ? dateFormatter(val * 1000, 'yyyy-MM-dd') : '-'
@@ -218,16 +138,11 @@ export default {
     typeFilter(val) {
       if (val === '1') {
         return '企业中标分析报告'
-      }
-      else if (val === '2') {
+      } else if (val === '2') {
         return '业主采购分析报告'
-      }
-      else if (val === '3') {
+      } else if (val === '3') {
         return '市场分析定制报告'
       }
-      else if (val === '4') {
-        return '投标企业信用报告'
-      }
     },
     timeRangeF(val) {
       return val ? val.replace('_', '至') : '-'
@@ -244,6 +159,7 @@ export default {
     },
     areaF(val) {
       return val ? val.replace(/,/g, ',') : ''
+
     },
     scopeClassF(val) {
       // if (val) {
@@ -262,57 +178,41 @@ export default {
       //   return '-'
       // }
       if (val) {
-        const text
-          = FilterHistoryAjaxModel2ViewModel.formatIndustry(
+        let text =
+          FilterHistoryAjaxModel2ViewModel.formatIndustry(
             val
           ).industryText.join(',')
         return text
-      }
-      else {
+      } else {
         return '-'
       }
     },
     buyerClassF(val) {
       if (val) {
-        const text
-          = FilterHistoryAjaxModel2ViewModel.formatBuyerClass(
+        let text =
+          FilterHistoryAjaxModel2ViewModel.formatBuyerClass(
             val
           ).buyerClassText.join(',')
         return text
-      }
-      else {
+      } else {
         return '-'
       }
     },
     formatTime(value, fmt) {
-      if (!value)
-        return ''
+      if (!value) return ''
       const rangeTimeArr = value.split('-')
       const start = new Date(rangeTimeArr[0] * 1000).getTime()
       const end = new Date(rangeTimeArr[1] * 1000).getTime()
       console.log(start)
-      return `${dateFormatter(start, fmt)}至${dateFormatter(end, fmt)}`
-    }
-  },
-  props: {
-    data: {
-      type: Object,
-      default: () => {}
-    },
-    tagclass: {
-      type: String,
-      default: 'green'
+      return dateFormatter(start, fmt) + '至' + dateFormatter(end, fmt)
     }
   },
-  data() {
-    return {}
-  },
   methods: {
     matchF(val, item) {
-      return item.exactMatch === '0' ? `${val}(模糊)` : `${val}(精准)`
+      return item.exactMatch === '0' ? val + '(模糊)' : val + '(精准)'
     },
     formatMatchWay(m) {
-      const map = {
+      var map = {
         title: '按标题匹配',
         content: '按全文匹配'
       }
@@ -320,14 +220,13 @@ export default {
       return text
     },
     formatKeys(keys) {
-      let tempStr = '-'
-      if (!keys)
-        return tempStr
+      var tempStr = '-'
+      if (!keys) return tempStr
       try {
-        const tempResult = []
-        const tempList = JSON.parse(keys)
-        tempList.forEach((v) => {
-          v.a_key.forEach((k) => {
+        var tempResult = []
+        var tempList = JSON.parse(keys)
+        tempList.forEach(function (v) {
+          v.a_key.forEach(function (k) {
             tempResult.push({
               key: [].concat(k.key, k.appendkey),
               type: k.matchway === 1 ? '模糊' : '精准'
@@ -335,66 +234,59 @@ export default {
           })
         })
         tempStr = tempResult
-          .map((v) => {
+          .map(function (v) {
             return `[${v.key.join(' ')}]-${v.type}`
           })
           .join('、')
-      }
-      catch (e) {
+      } catch (e) {
         console.log(e)
       }
       return tempStr
     },
     formatBuyerclass(value) {
-      if (!value)
-        return ''
+      if (!value) return ''
       return String(value).replace(/,/g, ',')
     },
     formatArea(value) {
-      if (!value)
-        return '-'
+      if (!value) return '-'
       value = JSON.parse(value)
 
       if (Object.keys(value).length === 0) {
         return ''
       }
 
-      const area = []
-      const citys = []
-      for (const key in value) {
+      var area = []
+      var citys = []
+      for (var key in value) {
         if (!value[key].length) {
           area.push(key)
-        }
-        else {
+        } else {
           citys.push(...value[key])
         }
       }
 
-      const concatList = area.concat(citys)
+      var concatList = area.concat(citys)
 
       if (concatList.length) {
         return concatList.join(',')
-      }
-      else {
+      } else {
         return ''
       }
     },
     formatIndustry(value) {
-      if (!value)
-        return ''
+      if (!value) return ''
       value = JSON.parse(value)
 
       if (Object.keys(value).length === 0) {
         return ''
       }
 
-      const keyArr = []
-      const valueArr = []
-      for (const key in value) {
+      var keyArr = []
+      var valueArr = []
+      for (var key in value) {
         if (!value[key].length) {
           keyArr.push(key)
-        }
-        else {
+        } else {
           valueArr.push(...value[key])
         }
       }
@@ -498,7 +390,7 @@ export default {
     background-color: #00d086;
   }
 
-  .blue, .blue2 {
+  .blue {
     background-color: #3399ff;
   }
 

+ 46 - 160
apps/mobile/src/views/reportAnalysis/reportDownload.vue

@@ -1,12 +1,8 @@
 <template>
   <div id="reportDownload">
     <div class="reportContent">
-      <div class="title">
-        报告下载余额
-      </div>
-      <div class="desc">
-        注:请在有效期内使用,过期清零,不可转赠。
-      </div>
+      <div class="title">报告下载余额</div>
+      <div class="desc">注:请在有效期内使用,过期清零,不可转赠。</div>
       <div class="box_content">
         <div class="item">
           <div class="line green" />
@@ -14,7 +10,9 @@
             <div class="left">
               <span class="count">{{ winner.total }}</span>
               <span class="unit">份</span>
-              <span class="textbtn" @click="goDetail('企业中标分析报告')">查明细</span>
+              <span class="textbtn" @click="goDetail('企业中标分析报告')"
+                >查明细</span
+              >
               <span class="texticon" />
             </div>
             <div class="right" @click="rechargeNow('企业中标分析报告')">
@@ -22,9 +20,7 @@
             </div>
           </div>
           <div class="textGroup">
-            <div class="left">
-              企业中标分析报告下载余额
-            </div>
+            <div class="left">企业中标分析报告下载余额</div>
             <div v-if="winner.minEndTime" class="right">
               最近有效期至:{{ winner.minEndTime }}
             </div>
@@ -36,7 +32,9 @@
             <div class="left">
               <span class="count">{{ buyer.total }}</span>
               <span class="unit">份</span>
-              <span class="textbtn" @click="goDetail('业主采购分析报告')">查明细</span>
+              <span class="textbtn" @click="goDetail('业主采购分析报告')"
+                >查明细</span
+              >
               <span class="texticon" />
             </div>
             <div class="right" @click="rechargeNow('业主采购分析报告')">
@@ -44,9 +42,7 @@
             </div>
           </div>
           <div class="textGroup">
-            <div class="left">
-              业主采购分析报告下载余额
-            </div>
+            <div class="left">业主采购分析报告下载余额</div>
             <div v-if="buyer.minEndTime" class="right">
               最近有效期至:{{ buyer.minEndTime }}
             </div>
@@ -58,7 +54,9 @@
             <div class="left">
               <span class="count">{{ market.total }}</span>
               <span class="unit">份</span>
-              <span class="textbtn" @click="goDetail('市场分析定制报告')">查明细</span>
+              <span class="textbtn" @click="goDetail('市场分析定制报告')"
+                >查明细</span
+              >
               <span class="texticon" />
             </div>
             <div class="right" @click="rechargeNow('市场分析定制报告')">
@@ -66,39 +64,15 @@
             </div>
           </div>
           <div class="textGroup">
-            <div class="left">
-              市场分析定制报告下载余额
-            </div>
+            <div class="left">市场分析定制报告下载余额</div>
             <div v-if="market.minEndTime" class="right">
               最近有效期至:{{ market.minEndTime }}
             </div>
           </div>
         </div>
       </div>
-      <!-- S 投标企业信用报告入口 S -->
-      <div class="credit_report">
-        <div class="credit_report_main">
-          <div class="credit_report_title">
-            <span>投标企业信用报告</span>
-            <div class="credit_report_action">
-              <div class="credit_report_example" @click="viewReportExample">
-                报告样例 <span class="texticon" />
-              </div>
-              <div class="credit_report_btn" @click="goBuy">
-                去购买
-              </div>
-            </div>
-          </div>
-          <div class="credit_report_content">
-            <span>信用报告通过信用背书、风险预警、政策适配,三大核心作用,成为投标企业参与市场竞争的关键工具‌。</span>
-          </div>
-        </div>
-      </div>
-      <!-- E 投标企业信用报告入口 E -->
       <div class="content_list">
-        <div class="title">
-          报告下载记录
-        </div>
+        <div class="title">报告下载记录</div>
         <div class="list_box">
           <van-list
             ref="vanList"
@@ -132,9 +106,7 @@
       :before-close="beforeEmailDialogClose"
     >
       <div class="attachment-content">
-        <div class="attachment-tip-text">
-          附件将以邮件的形式发送至您的邮箱
-        </div>
+        <div class="attachment-tip-text">附件将以邮件的形式发送至您的邮箱</div>
         <van-field
           v-model="attachment.email"
           class="attachment-email-input"
@@ -207,32 +179,17 @@ export default {
     colorFilter(val) {
       if (val === '1') {
         return 'green'
-      }
-      else if (val === '2') {
+      } else if (val === '2') {
         return 'yellow'
-      }
-      else if (val === '3') {
+      } else if (val === '3') {
         return 'blue'
       }
-      else if (val === '4') {
-        return 'blue2'
-      }
     }
   },
   created() {
     this.getcount()
   },
   methods: {
-    viewReportExample() {
-      this.$router.push({
-        path: '/common/pdfview'
-      })
-    },
-    goBuy() {
-      this.$router.push({
-        path: '/order/create/creditreport'
-      })
-    },
     async getcount() {
       const { data } = await pdfaccount({})
       if (data) {
@@ -259,14 +216,13 @@ export default {
         this.list.total = data.count
         // this.list.total = 10 //不支持分页可以写死
         this.list.value = this.list.value.concat(data.list)
-      }
-      else {
+      } else {
         this.list.finished = true
       }
       // 数据请求完成(根据页码计算,当前页是否是最后一页)
       // 请求完成后,页码就变为了下一页的页面,所以这里要-1
-      const isLastPage
-        = (this.list.pageNum - 1) * this.list.pageSize >= this.list.total
+      const isLastPage =
+        (this.list.pageNum - 1) * this.list.pageSize >= this.list.total
       if (isLastPage) {
         this.list.finished = true
       }
@@ -277,13 +233,11 @@ export default {
         this.$router.push({
           path: '/order/create/enterpriseanalysis'
         })
-      }
-      else if (type === '业主采购分析报告') {
+      } else if (type === '业主采购分析报告') {
         this.$router.push({
           path: '/order/create/owneranalysis'
         })
-      }
-      else if (type === '市场分析定制报告') {
+      } else if (type === '市场分析定制报告') {
         this.$router.push({
           path: '/order/create/marketanalysis'
         })
@@ -309,8 +263,7 @@ export default {
             eId: item.ent
           }
         })
-      }
-      else {
+      } else {
         // 采购单位画像
         // 跳转页面
         let goLink = ''
@@ -318,15 +271,13 @@ export default {
           goLink = `/big/wx/page/unit_portrayal?entName=${encodeURIComponent(
             item.entName
           )}`
-        }
-        else {
+        } else {
           // 新商机管理采购单位画像
           if (this.isNewBusiness) {
             goLink = `/jyapp/big/page/client_portrayal?entName=${encodeURIComponent(
               item.entName
             )}&from=client`
-          }
-          else {
+          } else {
             goLink = `/jyapp/big/page/unit_portrayal?entName=${encodeURIComponent(
               item.entName
             )}`
@@ -349,16 +300,11 @@ export default {
         let defaultName = '报告'
         if (item.type === '1') {
           defaultName = '企业中标分析报告'
-        }
-        else if (item.type === '2') {
+        } else if (item.type === '2') {
           defaultName = '业主采购分析报告'
-        }
-        else if (item.type === '3') {
+        } else if (item.type === '3') {
           defaultName = '市场分析定制报告'
         }
-        else if (item.type === '4') {
-          defaultName = '投标企业信用报告'
-        }
         if (newIOSApp) {
           const loading = this.$toast.loading({
             duration: 0,
@@ -370,13 +316,11 @@ export default {
             loading.clear()
             appDownLoadFile(name, types, fileUrl, size)
           })
-        }
-        else {
+        } else {
           location.href = fileUrl
           // window.open(fileUrl)
         }
-      }
-      else {
+      } else {
         // fileUrl: 下载地址
         if (fileUrl) {
           if (platform === 'wx') {
@@ -388,13 +332,11 @@ export default {
                 target: encodeURIComponent(fileUrl)
               }
             })
-          }
-          else {
+          } else {
             // window.open(fileUrl)
             location.href = fileUrl
           }
-        }
-        else {
+        } else {
           console.log('获取附件fid失败')
         }
       }
@@ -402,8 +344,7 @@ export default {
     viewReport() {
       if (this.$envs.inAppOrH5) {
         location.href = '/jyapp/big/page/report_analysis'
-      }
-      else {
+      } else {
         location.href = '/big/wx/page/report_analysis'
       }
     },
@@ -417,8 +358,7 @@ export default {
       if (code === 0) {
         done && done()
         this.$toast('已发送至邮箱')
-      }
-      else {
+      } else {
         done && done(false)
         this.$toast('发送失败')
       }
@@ -437,8 +377,7 @@ export default {
       if (!emailRegExp.test(email)) {
         done(false)
         return this.$toast('邮箱格式错误')
-      }
-      else {
+      } else {
         const { fileUrl } = this.attachment
 
         if (!fileUrl) {
@@ -457,8 +396,7 @@ export default {
           console.log(fileSize, '文件大小')
           try {
             callback(fileSize)
-          }
-          catch (e) {
+          } catch (e) {
             console.log(e)
           }
         }
@@ -469,7 +407,7 @@ export default {
 }
 </script>
 
-<style lang="scss">
+<style>
 #reportDownload {
   background-color: #f5f6f7;
 
@@ -537,6 +475,14 @@ export default {
               margin-left: 12px;
             }
 
+            .texticon {
+              width: 12px;
+              height: 12px;
+              display: inline-block;
+              background-image: url(@/assets/image/reportanalysis/icon_download.png);
+              background-size: contain;
+              background-repeat: no-repeat;
+            }
           }
 
           .right {
@@ -590,67 +536,7 @@ export default {
         margin-bottom: 0;
       }
     }
-    .texticon {
-      width: 12px;
-      height: 12px;
-      display: inline-block;
-      background-image: url(@/assets/image/reportanalysis/icon_download.png);
-      background-size: contain;
-      background-repeat: no-repeat;
-    }
-    .credit_report {
-      margin-top: 16px;
-      width: 100%;
-      background: linear-gradient(to right, #EFFDFF, #FFFFFF);
-      border: 1px solid #87DFEA;
-      box-shadow: 0px 2px 8px 0px rgba(54, 147, 179, 0.05);
-      border-radius: 8px;
-      .credit_report_main {
-        padding: 12px;
-        width: 100%;
-        height: 100%;
-        background: url(../../assets/image/reportanalysis/credit-corner-bg.png) no-repeat;
-        background-size: 58px 55px;
-        background-position: right bottom;
-      }
-      .credit_report_title {
-        display: flex;
-        justify-content: space-between;
-        align-items: center;
-        > span {
-          font-size: 16px;
-          line-height: 24px;
-          color: #171826;
-        }
-      }
-      .credit_report_action {
-        display: flex;
-        justify-content: space-between;
-        align-items: center;
-        .credit_report_example {
-          display: flex;
-          align-items: center;
-          margin-right: 10px;
-          font-size: 12px;
-          line-height: 18px;
-          color: #2ABED1;
-        }
-        .credit_report_btn {
-          padding: 2px 17px;
-          background: #2ABED1;
-          color: #fff;
-          font-size: 12px;
-          line-height: 18px;
-          border-radius: 4px;
-        }
-      }
-      .credit_report_content {
-        margin-top: 10px;
-        font-size: 12px;
-        line-height: 18px;
-        color: #5F5E64;
-      }
-    }
+
     .content_list {
       margin-top: 16px;