客服修改
This commit is contained in:
parent
3eaef44538
commit
94b3d79831
|
|
@ -5,9 +5,15 @@
|
|||
</view>
|
||||
</template>
|
||||
<script>
|
||||
import { mapMutations, mapActions, mapState } from 'vuex';
|
||||
import {
|
||||
mapMutations,
|
||||
mapActions,
|
||||
mapState
|
||||
} from 'vuex';
|
||||
|
||||
import { goods } from '@/common/mixins/mixinsHelper.js';
|
||||
import {
|
||||
goods
|
||||
} from '@/common/mixins/mixinsHelper.js';
|
||||
export default {
|
||||
mixins: [goods],
|
||||
components: {
|
||||
|
|
@ -52,12 +58,21 @@
|
|||
},
|
||||
onLoad(e) {
|
||||
console.log(this.userInfo);
|
||||
console.log(this.$store.state.config);
|
||||
// 后台传入的客服地址模板
|
||||
const kefuUrlTemplate = "http://kefu.zpc-xy.com/chat/mobile?noCanClose=1&token=18b7482b8b1301e9b2309522859ff8cb&openid={openid}&nickName={nickName}&phone={phone}&avatar={avatar}";
|
||||
|
||||
if (this.$store.state.config.customerServiceH5Url == null ||
|
||||
this.$store.state.config.customerServiceH5Url == "") {
|
||||
return;
|
||||
}
|
||||
var kefuUrlTemplate = this.$store.state.config.customerServiceH5Url;
|
||||
|
||||
// 使用新的方法生成客服链接
|
||||
this.url = this.generateKefuUrl(kefuUrlTemplate);
|
||||
console.log('生成的客服链接:', this.url);
|
||||
//#ifdef H5
|
||||
window.location.href = this.url;
|
||||
// #endif
|
||||
},
|
||||
methods: {
|
||||
about() {
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user