|
@@ -4,12 +4,10 @@ import App from './App'
|
|
import './services/index.js'
|
|
import './services/index.js'
|
|
import * as Api from '@/common/config/caimeiApi.js'
|
|
import * as Api from '@/common/config/caimeiApi.js'
|
|
import * as Regs from '@/common/config/common.js'
|
|
import * as Regs from '@/common/config/common.js'
|
|
-import { umtrackWxKey } from '@/utils/config.js'
|
|
|
|
|
|
+// 友盟
|
|
|
|
+import Uma from './plugins/uma'
|
|
|
|
|
|
-// 友盟依赖包
|
|
|
|
-import uma from 'umtrack-wx'
|
|
|
|
-
|
|
|
|
-// 公共组件
|
|
|
|
|
|
+// 公共组件 全局组件
|
|
import { msg, modal, prePage, boundingClientRect } from './utils/util'
|
|
import { msg, modal, prePage, boundingClientRect } from './utils/util'
|
|
import cuCustom from './components/cm-custom/cu-custom.vue'
|
|
import cuCustom from './components/cm-custom/cu-custom.vue'
|
|
import auCustom from './components/cm-custom/au-custom.vue'
|
|
import auCustom from './components/cm-custom/au-custom.vue'
|
|
@@ -32,29 +30,6 @@ Vue.prototype.$getStorage = function(key) {
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
-/**
|
|
|
|
- * 友盟+小程序统计
|
|
|
|
- */
|
|
|
|
-if (process.env.NODE_ENV != 'development') {
|
|
|
|
- // #ifdef MP-WEIXIN
|
|
|
|
- uma.init({
|
|
|
|
- appKey: umtrackWxKey, //由友盟分配的APP_KEY
|
|
|
|
- // 使用Openid进行统计,此项为false时将使用友盟+uuid进行用户统计。
|
|
|
|
- // 使用Openid来统计微信小程序的用户,会使统计的指标更为准确,对系统准确性要求高的应用推荐使用Openid。
|
|
|
|
- useOpenid: true,
|
|
|
|
- // 使用openid进行统计时,是否授权友盟自动获取Openid,
|
|
|
|
- // 如若需要,请到友盟后台"设置管理-应用信息"(https://mp.umeng.com/setting/appset)中设置appId及secret
|
|
|
|
- autoGetOpenid: true,
|
|
|
|
- debug: true, //是否打开调试模式
|
|
|
|
- uploadUserInfo: false // 自动上传用户信息,设为false取消上传,默认为false
|
|
|
|
- })
|
|
|
|
- uma.install = function(Vue) {
|
|
|
|
- Vue.prototype.$uma = uma
|
|
|
|
- }
|
|
|
|
- Vue.use(uma)
|
|
|
|
- // #endif
|
|
|
|
-}
|
|
|
|
-
|
|
|
|
// Vue实例化
|
|
// Vue实例化
|
|
Vue.config.productionTip = false
|
|
Vue.config.productionTip = false
|
|
Vue.prototype.$fire = new Vue()
|
|
Vue.prototype.$fire = new Vue()
|
|
@@ -66,6 +41,9 @@ Vue.prototype.$Static = 'https://static.caimei365.com/app/img/'
|
|
|
|
|
|
App.mpType = 'app'
|
|
App.mpType = 'app'
|
|
|
|
|
|
|
|
+// 使用插件
|
|
|
|
+Vue.use(Uma)
|
|
|
|
+
|
|
const app = new Vue({
|
|
const app = new Vue({
|
|
...App
|
|
...App
|
|
})
|
|
})
|