// mycomponent/yz_homeButton.js
Component({
  /**
   * 组件的属性列表
   */
  properties: {
    datas: {
      type: null
    },
    title: {
      type: null,
    },
    store_id:{
      type:null
    }
  },
  observers:{
    'datas':function(era){
      console.log(era,'ssss');
    }
  },
  /**
   * 组件的初始数据
   */
  data: {
    toolbar: false
  },

  /**
   * 组件的方法列表
   */
  methods: {
    gotoAlone(e){
      let name = e.currentTarget.dataset.name;
      if(name == 'release'){
        wx.navigateTo({
          url: "/packageC/micro_communities/microRelease/microRelease",
        });
      }else if(name == 'home'){
        wx.redirectTo({
          url: "/packageG/independent_store/index/index?store_id="+this.data.store_id,
        });
      }else if(name == 'my'){
        wx.redirectTo({
          url: "/packageG/member_v2/member_v2",
        });
      }
    },
    showToolbar() {
      this.setData({
        toolbar: !this.data.toolbar
      });
    },
    gohome() {
      wx.reLaunch({
        url: '/packageG/index/index'
      });
    },
    goorderlist() {
      wx.navigateTo({
        url: '/packageA/member/myOrder_v2/myOrder_v2'
      });
    },
    gomember() {
      wx.reLaunch({
        url: '/packageG/member_v2/member_v2'
      });
    },
  }
});
