Browse Source

Merge branch 'master' of http://192.168.3.207:10080/jianyu/jy-docs

TANGSHIZHE 4 years ago
parent
commit
07064fa6ef

+ 1 - 0
jydocs-pc/.env.development

@@ -3,3 +3,4 @@ VUE_APP_BASE_API='/jydocs/'
 VUE_APP_BASE_URL='/swordfish/frontPage/docs/free/index/'
 VUE_APP_MOCK=true
 VUE_APP_BASE_PUBLIC='http://localhost:8080/'
+VUE_APP_LOG_URL='https://web2-jytest.jianyu360.cn/jyintegral/pointsLogs?logAction='

+ 1 - 0
jydocs-pc/.env.production

@@ -2,3 +2,4 @@ NODE_ENV=production
 VUE_APP_BASE_API='/jydocs/'
 VUE_APP_BASE_URL='/swordfish/docs/index'
 VUE_APP_BASE_PUBLIC='/page_docs/'
+VUE_APP_LOG_URL='https://web2-jytest.jianyu360.cn/jyintegral/pointsLogs?logAction='

+ 5 - 0
jydocs-pc/src/main.js

@@ -4,10 +4,15 @@ import router from './router'
 import singleSpaVue from 'single-spa-vue'
 import { Loading } from 'element-ui'
 import '@/utils/'
+import axios from 'axios'
 
 Vue.use(Loading.directive)
 Vue.config.productionTip = false
 
+router.afterEach((to, from) => {
+  axios.get(process.env.VUE_APP_LOG_URL + process.env.VUE_APP_BASE_URL + to.fullPath)
+})
+
 const vueOptions = {
   el: '#single-spa-app',
   router,

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

@@ -126,7 +126,7 @@ export default {
         console.log(res)
         if (res.data.error_code === 0) {
           sessionStorage.setItem('paydata', JSON.stringify(res.data))
-          this.$router.push('/purchasesuccess/'+ this.response.price)
+          this.$router.push('/purchasesuccess/' + this.response.price)
         }
       })
     }