Authored by yyq

set pagetype

@@ -11,11 +11,13 @@ let question = { @@ -11,11 +11,13 @@ let question = {
11 this.$item = $('.qs-item', this.$base); 11 this.$item = $('.qs-item', this.$base);
12 this.startTime = Date.parse(new Date()) / 1000; 12 this.startTime = Date.parse(new Date()) / 1000;
13 13
14 - if (yoho.isApp) { 14 + if (this.$base.length && yoho.isApp) {
15 let data = this.$base.data(); 15 let data = this.$base.data();
16 16
17 yoho.ready(function() { 17 yoho.ready(function() {
18 - yoho.invokeMethod('get.pageType', 'questionnaire'); 18 + yoho.invokeMethod('get.pageType', {
  19 + pageType: 'questionnaire'
  20 + });
19 yoho.invokeMethod('set.shareInfo', { 21 yoho.invokeMethod('set.shareInfo', {
20 title: data.title, 22 title: data.title,
21 link: 'http://m.yohobuy.com/3party/questionnaire/' + data.id, 23 link: 'http://m.yohobuy.com/3party/questionnaire/' + data.id,