"use strict";
const common_vendor = require("../../../common/vendor.js");
const sheep_index = require("../../../sheep/index.js");
require("../../../sheep/api/index.js");
require("../../../sheep/api/distri/score.js");
require("../../../sheep/request/index.js");
require("../../../sheep/config/index.js");
require("../../../sheep/store/index.js");
require("../../../sheep/store/app.js");
require("../../../sheep/api/promotion/diy.js");
require("../../../sheep/platform/index.js");
require("../../../sheep/platform/provider/wechat/index.js");
require("../../../sheep/platform/provider/wechat/miniProgram.js");
require("../../../sheep/api/member/auth.js");
require("../../../sheep/api/member/social.js");
require("../../../sheep/api/member/user.js");
require("../../../sheep/platform/provider/apple/index.js");
require("../../../sheep/platform/share.js");
require("../../../sheep/router/index.js");
require("../../../sheep/hooks/useModal.js");
require("../../../sheep/helper/index.js");
require("../../../sheep/helper/test.js");
require("../../../sheep/helper/digit.js");
require("../../../sheep/api/member/signin.js");
require("../../../sheep/helper/throttle.js");
require("../../../sheep/url/index.js");
require("../../../sheep/platform/pay.js");
require("../../../sheep/api/pay/order.js");
require("../../../sheep/store/user.js");
require("../../../sheep/store/cart.js");
require("../../../sheep/api/trade/cart.js");
require("../../../sheep/api/pay/wallet.js");
require("../../../sheep/api/trade/order.js");
require("../../../sheep/api/promotion/coupon.js");
require("../../../sheep/store/sys.js");
require("../../../sheep/store/modal.js");
require("../../../sheep/api/distri/share.js");
require("../../../sheep/api/distri/team.js");
require("../../../sheep/api/infra/file.js");
require("../../../sheep/api/member/address.js");
require("../../../sheep/api/member/point.js");
require("../../../sheep/api/migration/app.js");
require("../../../sheep/api/migration/chat.js");
require("../../../sheep/api/migration/index.js");
require("../../../sheep/api/migration/third.js");
require("../../../sheep/api/pay/channel.js");
require("../../../sheep/api/product/category.js");
require("../../../sheep/api/product/comment.js");
require("../../../sheep/api/product/favorite.js");
require("../../../sheep/api/product/history.js");
require("../../../sheep/api/product/spu.js");
require("../../../sheep/api/promotion/activity.js");
require("../../../sheep/api/promotion/article.js");
require("../../../sheep/api/promotion/bargain.js");
require("../../../sheep/api/promotion/combination.js");
require("../../../sheep/api/promotion/rewardActivity.js");
require("../../../sheep/api/promotion/seckill.js");
require("../../../sheep/api/system/area.js");
require("../../../sheep/api/system/voice.js");
require("../../../sheep/api/trade/afterSale.js");
require("../../../sheep/api/trade/brokerage.js");
require("../../../sheep/api/trade/config.js");
require("../../../sheep/api/trade/delivery.js");
require("../../../sheep/config/zIndex.js");
if (!Array) {
  const _easycom_su_popup2 = common_vendor.resolveComponent("su-popup");
  _easycom_su_popup2();
}
const _easycom_su_popup = () => "../../../sheep/ui/su-popup/su-popup.js";
if (!Math) {
  _easycom_su_popup();
}
const _sfc_main = {
  __name: "account-type-select",
  props: {
    modelValue: {
      type: Object,
      default() {
      }
    },
    show: {
      type: Boolean,
      default: false
    },
    methods: {
      // 开启的提现方式
      type: Array,
      default: []
    }
  },
  emits: ["update:modelValue", "change", "close"],
  setup(__props, { emit: __emit }) {
    const emits = __emit;
    const state = common_vendor.reactive({
      currentValue: ""
    });
    const typeList = [
      {
        // icon: '/static/img/shop/pay/wechat.png', // TODO 非繁人：后续给个 icon
        title: "钱包余额",
        value: "1"
      },
      {
        icon: "/static/img/shop/pay/wechat.png",
        title: "微信零钱",
        value: "2"
      },
      {
        icon: "/static/img/shop/pay/alipay.png",
        title: "支付宝账户",
        value: "3"
      },
      {
        icon: "/static/img/shop/pay/bank.png",
        title: "银行卡转账",
        value: "4"
      }
    ];
    function onChange(e) {
      state.currentValue = e.detail.value;
    }
    const onConfirm = async () => {
      if (state.currentValue === "") {
        sheep_index.sheep.$helper.toast("请选择提现方式");
        return;
      }
      emits("update:modelValue", {
        type: state.currentValue
      });
      emits("close");
    };
    const hideModal = () => {
      emits("close");
    };
    return (_ctx, _cache) => {
      return {
        a: common_vendor.f(typeList, (item, index, i0) => {
          return {
            a: common_vendor.unref(sheep_index.sheep).$url.static(item.icon),
            b: common_vendor.t(item.title),
            c: item.value,
            d: item.value === state.currentValue,
            e: !__props.methods.includes(parseInt(item.value)),
            f: index
          };
        }),
        b: common_vendor.o(onChange),
        c: common_vendor.o(onConfirm),
        d: common_vendor.o(hideModal),
        e: common_vendor.p({
          show: __props.show
        })
      };
    };
  }
};
const Component = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["__scopeId", "data-v-a5da3655"], ["__file", "D:/zx/mall-front-app/pages/commission/components/account-type-select.vue"]]);
wx.createComponent(Component);
