/**
 * 秒杀活动详情
 */
// @ts-nocheck
Component({
  data: {
    isReady: false,
    pluginAppId: '2021002191638959',
    pluginPageUrl: '/kill-detail',
    pluginVersion: '*'
  },

  didMount() {
    this.loadPlugin();
  },

  methods: {
    loadPlugin() {
      const {
        pluginAppId,
        pluginPageUrl,
        pluginVersion
      } = this.data; // query = {
      //   id: '',
      // }

      const that = this;
      my.loadPlugin({
        plugin: `${pluginAppId}@${pluginVersion}`,
        success: () => {
          that.setData({
            isReady: true
          });
          my.reLaunch({
            url: `dynamic-plugin://${pluginAppId}${pluginPageUrl}`
          });
        }
      });
    }

  }
});