Selaa lähdekoodia

添加专家机构企业产品的浏览量统计

lyn7568 6 vuotta sitten
vanhempi
commit
20b2970575

+ 4 - 2
src/components/pageView/index.vue

@ -1,7 +1,7 @@
1 1
<template>
2 2
  <div class="page-view">
3 3
    <img :src="logImg" style="display:none" />
4
    <span>浏览量 {{pageCount}}</span>
4
    <span v-if="!pageObj.noShow">浏览量 {{pageCount}}</span>
5 5
  </div>
6 6
</template>
7 7
<script>
@ -16,7 +16,9 @@
16 16
      }
17 17
    },
18 18
    created() {
19
      this.queryPageView()
19
      if (!this.pageObj.noShow) {
20
        this.queryPageView()
21
      }
20 22
      this.wlog(this.pageObj)
21 23
    },
22 24
    methods: {

+ 1 - 1
src/libs/util.js

@ -316,7 +316,7 @@ export const DateFormat = function (fmt) {
316 316
}
317 317
318 318
export const urlshare = function () {
319
  let arrayUrl = ['home', 'company.html', 'org.html', 'expert.html', 'result.html', 'resource.html', 'serve.html', 'content.html']
319
  let arrayUrl = ['home', 'company.html', 'org.html', 'expert.html', 'result.html', 'resource.html', 'serve.html', 'content.html', 'product.html']
320 320
  let arr = arrayUrl.filter(function (item) {
321 321
    return window.location.href.indexOf(item) !== -1;
322 322
  })

+ 3 - 0
src/pages/company/show.vue

@ -12,6 +12,7 @@
12 12
            <div class="info-operate">
13 13
              <div class="addr">{{citys[orgInfo.addr]}}</div>
14 14
              <shareOut></shareOut>
15
              <pageView v-if="companyId" :pageObj="{ tn: 'company', id: companyId, src: '1', noShow: true}"></pageView>
15 16
            </div>
16 17
          </div>
17 18
        </div>
@ -133,6 +134,7 @@
133 134
  import queryDict from '@/libs/queryDict';
134 135
135 136
  import shareOut from '@/components/ShareOut';
137
  import pageView from '@/components/pageView';
136 138
  import baseProduct from '@/components/subTemplate/BaseProduct';
137 139
138 140
  export default {
@ -181,6 +183,7 @@
181 183
    },
182 184
    components: {
183 185
      shareOut,
186
      pageView,
184 187
      baseProduct
185 188
    },
186 189
    methods: {

+ 3 - 0
src/pages/expert/show.vue

@ -10,6 +10,7 @@
10 10
            <div class="info-operate">
11 11
              <div class="addr">{{expertInfo.address}}</div>
12 12
              <shareOut></shareOut>
13
              <pageView v-if="expertId" :pageObj="{ tn: 'professor', id: expertId, src: '1', noShow: true}"></pageView>
13 14
            </div>
14 15
          </div>
15 16
          <el-row class="goSpan" :gutter="10">
@ -207,6 +208,7 @@
207 208
  import queryBase from '@/libs/queryBase';
208 209
209 210
  import shareOut from '@/components/ShareOut';
211
  import pageView from '@/components/pageView';
210 212
  import collectCo from '@/components/CollectCo';
211 213
  import contactChat from '@/components/ContactChat';
212 214
  import baseService from '@/components/subTemplate/BaseService';
@ -282,6 +284,7 @@
282 284
    },
283 285
    components: {
284 286
      shareOut,
287
      pageView,
285 288
      collectCo,
286 289
      contactChat,
287 290
      baseService,

+ 3 - 0
src/pages/h5/views/company/company.vue

@ -15,6 +15,7 @@
15 15
          <p class="industry">{{keywordObj[1] ? keywordObj[1].join(" | ") : ''}}</p>
16 16
          <p class="addressbox">
17 17
            <em class="address"></em> {{citys[orgInfo.addr]}}</p>
18
          <pageView v-if="companyId" :pageObj="{ tn: 'company', id: companyId, src: '2', noShow: true}"></pageView>
18 19
        </div>
19 20
      </div>
20 21
    </div>
@ -69,6 +70,7 @@
69 70
  import queryDict from '@/libs/queryDict';
70 71
  import baseContent from '@/components/subTemplate/BaseContent';
71 72
  import baseProduct from '@/components/subTemplate/BaseProduct';
73
  import pageView from '@/components/pageView';
72 74
73 75
  export default {
74 76
    data() {
@ -95,6 +97,7 @@
95 97
      this.getCompContent();
96 98
    },
97 99
    components: {
100
      pageView,
98 101
      baseProduct,
99 102
      baseContent
100 103
    },

+ 3 - 0
src/pages/h5/views/expert/expert.vue

@ -13,6 +13,7 @@
13 13
          <p class="industry" v-if="expertInfo.title">{{expertInfo.title}}</p>
14 14
          <p class="addressbox">
15 15
            <em class="address"></em> {{expertInfo.address}}</p>
16
          <pageView v-if="expertId" :pageObj="{ tn: 'professor', id: expertId, src: '2', noShow: true}"></pageView>
16 17
        </div>
17 18
      </div>
18 19
    </div>
@ -120,6 +121,7 @@
120 121
  import baseContent from '@/components/subTemplate/BaseContent';
121 122
  import baseResult from '@/components/subTemplate/BaseResult';
122 123
  import BaseExpert from '@/components/subTemplate/BaseExpert';
124
  import pageView from '@/components/pageView';
123 125
124 126
  export default {
125 127
    data() {
@ -164,6 +166,7 @@
164 166
      this.getCoopExperts();
165 167
    },
166 168
    components: {
169
      pageView,
167 170
      baseService,
168 171
      baseResult,
169 172
      baseContent,

+ 3 - 0
src/pages/h5/views/org/org.vue

@ -15,6 +15,7 @@
15 15
          <p class="industry">{{orgInfo.industry ? orgInfo.industry.join(" | ") : ''}}</p>
16 16
          <p class="addressbox">
17 17
            <em class="address"></em> {{orgInfo.city}}</p>
18
          <pageView v-if="orgId" :pageObj="{ tn: 'organization', id: orgId, src: '2', noShow: true}"></pageView>
18 19
        </div>
19 20
      </div>
20 21
    </div>
@ -91,6 +92,7 @@
91 92
  import baseResource from '@/components/subTemplate/BaseResource';
92 93
  import baseContent from '@/components/subTemplate/BaseContent';
93 94
  import BaseOrg from '@/components/subTemplate/BaseOrg';
95
  import pageView from '@/components/pageView';
94 96
95 97
  export default {
96 98
    data() {
@ -135,6 +137,7 @@
135 137
      this.getLikeOrgs();
136 138
    },
137 139
    components: {
140
      pageView,
138 141
      baseService,
139 142
      baseResource,
140 143
      baseContent,

+ 4 - 3
src/pages/h5/views/product/product.vue

@ -17,7 +17,7 @@
17 17
                <beyondTo v-if="companyId" :ownerId="companyId" :ownerType="'00'" :styFlag="true"></beyondTo>
18 18
            </div>
19 19
        <div class="content-wrapper">
20
          
20
            <pageView v-if="productId" :pageObj="{ tn: 'product', id: productId, src: '2', noShow: true }"></pageView>
21 21
            <el-row :gutter="10" class="rel-detail">
22 22
              <el-col class="rel-item" :span="24" v-if="productInfo.spec">
23 23
                <div class="rel-tit">厂商型号:</div>
@ -52,7 +52,7 @@
52 52
            <div class="content-title">
53 53
              <span>其他产品</span>
54 54
            </div>
55
            <div class="content">
55
            <div class="content content-nf">
56 56
              <BaseProduct v-for="item in otherProducts" :key="item.index" :itemSingle="item" :noBlank="true"></BaseProduct>
57 57
            </div>
58 58
          </div>
@ -69,7 +69,7 @@
69 69
  import previewMagnify from '../components/swiperImg';
70 70
  import beyondTo from '@/components/BeyondTo';
71 71
  import BaseProduct from '@/components/subTemplate/BaseProduct';
72
72
  import pageView from '@/components/pageView';
73 73
  export default {
74 74
    data() {
75 75
      return {
@ -88,6 +88,7 @@
88 88
    components: {
89 89
      previewMagnify,
90 90
      beyondTo,
91
      pageView,
91 92
      BaseProduct
92 93
    },
93 94
    methods: {

+ 3 - 0
src/pages/org/show.vue

@ -12,6 +12,7 @@
12 12
            <div class="info-operate">
13 13
              <div class="addr">{{orgInfo.city}}</div>
14 14
              <shareOut></shareOut>
15
              <pageView v-if="orgId" :pageObj="{ tn: 'organization', id: orgId, src: '1', noShow: true}"></pageView>
15 16
            </div>
16 17
          </div>
17 18
          <el-row class="goSpan" :gutter="10">
@ -168,6 +169,7 @@
168 169
  import queryBase from '@/libs/queryBase';
169 170
170 171
  import shareOut from '@/components/ShareOut';
172
  import pageView from '@/components/pageView';
171 173
  import collectCo from '@/components/CollectCo';
172 174
  import contactChat from '@/components/ContactChat';
173 175
  import baseService from '@/components/subTemplate/BaseService';
@ -239,6 +241,7 @@
239 241
    },
240 242
    components: {
241 243
      shareOut,
244
      pageView,
242 245
      collectCo,
243 246
      contactChat,
244 247
      baseService,

+ 3 - 1
src/pages/product/show.vue

@ -11,7 +11,7 @@
11 11
              <div class="info-tit">{{productInfo.name}}</div>
12 12
              <div class="info-tag">简介:{{productInfo.cnt}}</div>
13 13
              <div class="info-operate zoom-operate">
14
                <!-- <div class="addr">浏览量 10</div> -->
14
                <pageView v-if="productId" :pageObj="{ tn: 'product', id: productId, src: '1'}" style="margin-right:15px"></pageView>
15 15
                <shareOut :tPosition="tPosition"></shareOut>
16 16
              </div>
17 17
            </div>
@ -80,6 +80,7 @@
80 80
  import previewMagnify from '@/components/previewMagnify';
81 81
  import shareOut from '@/components/ShareOut';
82 82
  import beyondTo from '@/components/BeyondTo';
83
  import pageView from '@/components/pageView';
83 84
84 85
  export default {
85 86
    data() {
@ -99,6 +100,7 @@
99 100
    components: {
100 101
      previewMagnify,
101 102
      shareOut,
103
      pageView,
102 104
      beyondTo
103 105
    },
104 106
    methods: {