|
@@ -28,6 +28,7 @@
|
|
created() {},
|
|
created() {},
|
|
methods: {
|
|
methods: {
|
|
addPoint(){
|
|
addPoint(){
|
|
|
|
+
|
|
API_WeiXin.addPoint({
|
|
API_WeiXin.addPoint({
|
|
id:this.id,
|
|
id:this.id,
|
|
pointCode:"70007"
|
|
pointCode:"70007"
|
|
@@ -55,8 +56,8 @@
|
|
nonceStr: wxconfig.nonceStr, // 必填,生成签名的随机串
|
|
nonceStr: wxconfig.nonceStr, // 必填,生成签名的随机串
|
|
signature: wxconfig.signature, // 必填,签名,见附录1
|
|
signature: wxconfig.signature, // 必填,签名,见附录1
|
|
jsApiList: ['onMenuShareTimeline', 'onMenuShareAppMessage',
|
|
jsApiList: ['onMenuShareTimeline', 'onMenuShareAppMessage',
|
|
- 'onMenuShareQQ', 'onMenuShareQZone','updateAppMessageShareData','updateTimelineShareData'] ,// 必填,需要使用的JS接口列表,所有JS接口列表见附录2
|
|
|
|
- //'checkJsApi',
|
|
|
|
|
|
+ 'onMenuShareQQ', 'onMenuShareQZone'] ,// 必填,需要使用的JS接口列表,所有JS接口列表见附录2
|
|
|
|
+ //'checkJsApi',,'updateAppMessageShareData','updateTimelineShareData'
|
|
});
|
|
});
|
|
|
|
|
|
console.log("aaa")
|
|
console.log("aaa")
|
|
@@ -78,7 +79,7 @@
|
|
//微信分享自定义
|
|
//微信分享自定义
|
|
wxShare() {
|
|
wxShare() {
|
|
var userInfo=this.carhelp.getPersonInfo()
|
|
var userInfo=this.carhelp.getPersonInfo()
|
|
- var img=require("@/assets/img/logo.png")
|
|
|
|
|
|
+ var img=process.car.IMG_URL+"railroad-phone/"+require("@/assets/img/logo.png")
|
|
|
|
|
|
var title="[微官网]"+this.title
|
|
var title="[微官网]"+this.title
|
|
// var desc=
|
|
// var desc=
|
|
@@ -91,38 +92,39 @@
|
|
wx.ready(function() {
|
|
wx.ready(function() {
|
|
|
|
|
|
|
|
|
|
- wx.updateTimelineShareData({
|
|
|
|
- title: title,
|
|
|
|
- // desc:desc ,
|
|
|
|
- link: joinUrl,
|
|
|
|
- imgUrl: img,
|
|
|
|
- success: function() {
|
|
|
|
- if(userInfo){
|
|
|
|
- _this.addPoint()
|
|
|
|
- }
|
|
|
|
- // 设置成功
|
|
|
|
- _this.$emit("wxShare",null);
|
|
|
|
- }
|
|
|
|
- })
|
|
|
|
- wx.updateAppMessageShareData({
|
|
|
|
- title: title,
|
|
|
|
- // desc:desc ,
|
|
|
|
- link: joinUrl,
|
|
|
|
- imgUrl: img,
|
|
|
|
- success: function() {
|
|
|
|
- if(userInfo){
|
|
|
|
- _this.addPoint()
|
|
|
|
- }
|
|
|
|
- // 设置成功
|
|
|
|
- _this.$emit("wxShare",null);
|
|
|
|
- }
|
|
|
|
- })
|
|
|
|
|
|
+ // wx.updateTimelineShareData({
|
|
|
|
+ // title: title,
|
|
|
|
+ // // desc:desc ,
|
|
|
|
+ // link: joinUrl,
|
|
|
|
+ // imgUrl: img,
|
|
|
|
+ // success: function() {
|
|
|
|
+ // if(userInfo){
|
|
|
|
+ // //_this.addPoint()
|
|
|
|
+ // }
|
|
|
|
+ // // 设置成功
|
|
|
|
+ // _this.$emit("wxShare",null);
|
|
|
|
+ // }
|
|
|
|
+ // })
|
|
|
|
+ // wx.updateAppMessageShareData({
|
|
|
|
+ // title: title,
|
|
|
|
+ // // desc:desc ,
|
|
|
|
+ // link: joinUrl,
|
|
|
|
+ // imgUrl: img,
|
|
|
|
+ // success: function() {
|
|
|
|
+ // if(userInfo){
|
|
|
|
+ // //_this.addPoint()
|
|
|
|
+ // }
|
|
|
|
+ // // 设置成功
|
|
|
|
+ // _this.$emit("wxShare",null);
|
|
|
|
+ // }
|
|
|
|
+ // })
|
|
wx.onMenuShareAppMessage({
|
|
wx.onMenuShareAppMessage({
|
|
title: title,
|
|
title: title,
|
|
// desc:desc ,
|
|
// desc:desc ,
|
|
link: joinUrl,
|
|
link: joinUrl,
|
|
imgUrl: img,
|
|
imgUrl: img,
|
|
success: function() {
|
|
success: function() {
|
|
|
|
+ console.log('111')
|
|
if(userInfo){
|
|
if(userInfo){
|
|
_this.addPoint()
|
|
_this.addPoint()
|
|
}
|
|
}
|
|
@@ -136,6 +138,7 @@
|
|
link: joinUrl,
|
|
link: joinUrl,
|
|
imgUrl: img,
|
|
imgUrl: img,
|
|
success: function() {
|
|
success: function() {
|
|
|
|
+ console.log('222')
|
|
if(userInfo){
|
|
if(userInfo){
|
|
_this.addPoint()
|
|
_this.addPoint()
|
|
}
|
|
}
|