"use strict"; const common_vendor = require("../../common/vendor.js"); const common_tk_api = require("../../common/tk_api.js"); require("../../common/tk_index.js"); const _sfc_main = { data() { return { optionsCurrent: 1, qrcode: "", api: common_tk_api.api, mtInfo: {}, optionsList: [ { label: "美团", type: 1 }, { label: "饿了么", type: 2 } ] }; }, onLoad() { this.IntiData(); }, methods: { IntiData() { common_vendor.index.showLoading({ title: "加载中", mask: true }); var that = this; this.api.post("/api/taoke/meituan_act", { type: this.optionsCurrent }).then((e) => { common_vendor.index.hideLoading(); if (e.code != 0) { common_vendor.index.showToast({ title: res.data.msg, icon: "none" }); return; } that.mtInfo = e.data.info; that.qrcode = that.mtInfo.we_app_info.miniCode; console.log(that.qrcode); }).catch(function(err) { console.log(err); }); }, toElm() { common_vendor.index.switchTab({ url: "./elm" }); }, shareClick() { common_vendor.index.navigateToMiniProgram({ appId: this.mtInfo.we_app_info.app_id, path: this.mtInfo.we_app_info.page_path, success(res2) { } }); } } }; function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) { return common_vendor.e({ a: common_vendor.o(($event) => $options.toElm()), b: $data.qrcode, c: $data.qrcode }, $data.qrcode ? { d: common_vendor.o(($event) => $options.shareClick()) } : {}); } const MiniProgramPage = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["render", _sfc_render], ["__file", "E:/OPProject/TK_H5_Web/pages/takeout/mt.vue"]]); wx.createPage(MiniProgramPage);