jack 8 years ago
parent
commit
4ca63e0da0
1 changed files with 15 additions and 7 deletions
  1. 15 7
      app/js/articleShow.js

+ 15 - 7
app/js/articleShow.js

605
		if(oFen=="微信好友") {
605
		if(oFen=="微信好友") {
606
			var share = buildShareService();
606
			var share = buildShareService();
607
				if(share) {
607
				if(share) {
608
					shareMessage(share, "sinaweibo", {
608
					shareMessage(share, "WXSceneSession", {
609
						content: "dddddd",
609
						content: "dddddd",
610
						title: "【科袖文章】",
611
						href: baseUrl + "/ekexiu/shareArticalinfor.html?articleId=",
610
						title: "【科袖文章】" + proticleName,
611
						href: baseUrl + "/ekexiu/shareArticalinfor.html?articleId=" + proId,
612
						thumbs: [baseUrl + "/images/logo180.png"]
612
						thumbs: [baseUrl + "/images/logo180.png"]
613
					});
613
					});
614
				}
614
				}
615
		}else if(oFen=="微信朋友圈") {
615
		}else if(oFen=="微信朋友圈") {
616
			alert(2)
616
			var share = buildShareService();
617
				if(share) {
618
					shareMessage(share, "WXSceneTimeline", {
619
						content: "DDD",
620
						title: "【科袖文章】" ,
621
						href: baseUrl + "/ekexiu/shareArticalinfor.html?articleId=",
622
						thumbs: [baseUrl + "/images/logo180.png"]
623
					});
624
				}
617
		}else if(oFen=="新浪微博") {
625
		}else if(oFen=="新浪微博") {
618
			alert(3)
626
			alert(3)
619
		}
627
		}
695
	}*/
703
	}*/
696

704

697
	function buildShareService() {
705
	function buildShareService() {
698
		var share = shares["sinaweibo"];
706
		var share = shares["weixin"];
699
		if(share) {
707
		if(share) {
700
			if(share.authenticated) {
708
			if(share.authenticated) {
701
				console.log("---已授权---");
709
				console.log("---已授权---");
716

724

717
	}
725
	}
718

726

719
	/*function shareMessage(share, ex, msg) {
727
	function shareMessage(share, ex, msg) {
720
		msg.extra = {
728
		msg.extra = {
721
			scene: ex
729
			scene: ex
722
		};
730
		};
731
				});
739
				});
732
			}
740
			}
733
		});
741
		});
734
	}*/
742
	}
735
});
743
});