2 lines
1.2 KiB
JavaScript
2 lines
1.2 KiB
JavaScript
"use strict";const o=require("../../../common/vendor.js");if(!Array){(o.resolveComponent("s-coupon-list")+o.resolveComponent("su-popup"))()}Math||((()=>"../s-coupon-list/s-coupon-list.js")+(()=>"../../ui/su-popup/su-popup.js"))();const e={__name:"s-coupon-select",props:{modelValue:{type:Object,default(){}},show:{type:Boolean,default:!1}},emits:["confirm","close"],setup(e,{emit:c}){const t=e,d=c,p=o.reactive({couponInfo:o.computed((()=>t.modelValue)),couponId:void 0});function s(o){p.couponId===o?p.couponId=void 0:p.couponId=o}const n=()=>{d("confirm",p.couponId)};return(c,t)=>({a:o.f(p.couponInfo.filter((o=>o.match)),((e,c,t)=>({a:o.t(e.description||"已达到使用门槛"),b:p.couponId===e.id,c:o.o((o=>s(e.id)),c),d:o.o((o=>s(e.id)),c),e:"f6dc2cdb-1-"+t+",f6dc2cdb-0",f:o.p({data:e,type:"user",disabled:!1}),g:c}))),b:o.f(p.couponInfo.filter((o=>!o.match)),((e,c,t)=>({a:o.t(e.description||"未达到使用门槛"),b:"f6dc2cdb-2-"+t+",f6dc2cdb-0",c:o.p({data:e,type:"user",disabled:!0}),d:e.id}))),c:o.o(n),d:o.o((o=>d("close"))),e:o.p({show:e.show,type:"bottom",round:"20",showClose:!0,backgroundColor:"#f2f2f2"})})}},c=o._export_sfc(e,[["__scopeId","data-v-f6dc2cdb"]]);wx.createComponent(c);
|