Commit 274fa2fa by wangzhihui

添加埋点

1 parent 8337d6f5
/*
* @Author: 'wangzhihui' '1733904062@qq.com'
* @Date: 2026-03-02 11:21:49
* @LastEditors: 'wangzhihui' '1733904062@qq.com'
* @LastEditTime: 2026-03-20 16:53:17
* @FilePath: \wx-notification\src\api\evection.js
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
*/
const url = '/rop-dj-staff-miniprogram/router'
const url2='/rop-scrm-clue/router'
export default {
/** 美团消费个人月度总结*/
getMeituanOrderPerson(data = {}) {
......@@ -27,4 +36,13 @@ export default {
returnAll: true
})
},
/** 埋点记录批量插入 */
insertBurialPointRecordBatch(data = {}) {
data.method = 'clue.api.burial.point.record.batch.insert'
return window.$SCRM_HTTP({
url:url2,
data,
returnAll: true
})
},
}
\ No newline at end of file
/*
* @Author: 'wangzhihui' '1733904062@qq.com'
* @Date: 2026-01-26 12:02:37
* @LastEditors: 'wangzhihui' '1733904062@qq.com'
* @LastEditTime: 2026-03-20 16:50:12
* @FilePath: \wx-notification\src\store\modules\app.js
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
*/
import { util } from 'utils'
import { Http } from 'glsx-common'
......@@ -18,7 +26,10 @@ const actions = {
commit('SET_PAGE_META', meta)
},
registerHttp ({ }, sessionId = '') {
window.$HTTP = new Http({ ...window.$fetchConfig, alert: Notify, headers: { token: sessionId } })
let { scrmRequest, djRequest } = window.$fetchConfig
window.$SCRM_HTTP = new Http({ ...scrmRequest, alert: Notify })
window.$HTTP = new Http({ ...djRequest, alert: Notify, headers: { token: sessionId } })
// window.$HTTP = new Http({ ...window.$fetchConfig, alert: Notify, headers: { token: sessionId } })
},
login ({ dispatch }) {
const { corpId, agentId } = util.getLocalStorage('ww_storage_info'),
......
......@@ -135,6 +135,7 @@
</template>
<script>
import { parseTime } from '@/utils/tools.js'
import StatisticCard from './components/StatisticCard.vue'
import SectionTitle from './components/SectionTitle.vue'
import DataItem from './components/DataItem.vue'
......@@ -270,6 +271,18 @@ export default {
this.getData()
},
methods: {
insertBurialPointRecordBatch(){
evectionApi.insertBurialPointRecordBatch({
loginAccount:this.infoData.staffName,
phoneNumber:this.infoData.staffPhone,
userType:1,
systemSource:10,
eventTime:parseTime(new Date().getTime(), '{y}-{m}-{d} {h}:{i}:{s}'),
eventType:0,
pagePath:'company',
eventCode:'meituan'
})
},
getData() {
evectionApi
.getMeituanOrderCompany({
......@@ -278,6 +291,7 @@ export default {
.then(res => {
console.log(res)
this.infoData = res.data
this.insertBurialPointRecordBatch()
})
}
}
......
......@@ -118,6 +118,7 @@
</template>
<script>
import { parseTime } from '@/utils/tools.js'
import StatisticCard from './components/StatisticCard.vue'
import SectionTitle from './components/SectionTitle.vue'
import DataItem from './components/DataItem.vue'
......@@ -259,6 +260,18 @@ export default {
this.getData()
},
methods: {
insertBurialPointRecordBatch(){
evectionApi.insertBurialPointRecordBatch({
loginAccount:this.infoData.staffName,
phoneNumber:this.infoData.staffPhone,
userType:1,
systemSource:10,
eventTime:parseTime(new Date().getTime(), '{y}-{m}-{d} {h}:{i}:{s}'),
eventType:0,
pagePath:'department',
eventCode:'meituan'
})
},
getData() {
evectionApi
.getMeituanOrderDept({
......@@ -267,6 +280,7 @@ export default {
.then(res => {
console.log(res)
this.infoData = res.data
this.insertBurialPointRecordBatch()
})
}
}
......
......@@ -76,6 +76,7 @@ import StatisticCard from './components/StatisticCard.vue'
import SectionTitle from './components/SectionTitle.vue'
import DataItem from './components/DataItem.vue'
import evectionApi from '@/api/evection'
import { parseTime } from '@/utils/tools.js'
export default {
components: { StatisticCard, SectionTitle, DataItem },
data() {
......@@ -158,6 +159,7 @@ export default {
},
created() {
this.getData()
},
methods: {
getData() {
......@@ -167,7 +169,20 @@ export default {
})
.then(res => {
this.infoData = res.data
this.insertBurialPointRecordBatch()
})
},
insertBurialPointRecordBatch(){
evectionApi.insertBurialPointRecordBatch({
loginAccount:this.infoData.staffName,
phoneNumber:this.infoData.staffPhone,
userType:1,
systemSource:10,
eventTime:parseTime(new Date().getTime(), '{y}-{m}-{d} {h}:{i}:{s}'),
eventType:0,
pagePath:'personage',
eventCode:'meituan'
})
}
}
}
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!