import common from '../../utils/util';
import main from '../../utils/main';

const app = getApp();

Page({
  data: {

  },
  onLoad: function (options) {
    var that = this;
    that.setData({
      PageID:options.PageID,
    });
  },
  onUnload:function(){
  },
  onShareAppMessage: function () {
    
    var imageUrl = app.globalData.uploadImageUrl +"web/program_screenshot_lesson_c0"+this.data.PageID+".png";
    var path = "/pages/index/index?type=webview&PageID="+this.data.PageID;
    var title ="课外课";
    if (this.data.PageID==="0"){
      imageUrl = app.globalData.uploadImageUrl +"web/program_screenshot_mustread.png";
      title="家长必读";
    }
    else if (this.data.PageID === "8"){
      imageUrl = app.globalData.uploadImageUrl + "web/program_screenshot_grouprule.png";
      title = "家长社群小组须知";
    }
    return {
      title: title,
      path: path,
      imageUrl: imageUrl,
    }
  },
})
