bm-bmt/unpackage/dist/build/web/static/js/pages-assets-withdraw.cd3dd...

1 line
26 KiB
JavaScript
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["pages-assets-withdraw"],{"0e42":function(t,a,e){"use strict";e.r(a);var i=e("6306"),n=e.n(i);for(var r in i)["default"].indexOf(r)<0&&function(t){e.d(a,t,(function(){return i[t]}))}(r);a["default"]=n.a},"1a85":function(t,a,e){"use strict";var i=e("e766"),n=e.n(i);n.a},"369a":function(t,a,e){var i=e("c86c");a=i(!1),a.push([t.i,'@charset "UTF-8";\n/**\n * 这里是uni-app内置的常用样式变量\n *\n * uni-app 官方扩展插件及插件市场https://ext.dcloud.net.cn上很多三方插件均使用了这些样式变量\n * 如果你是插件开发者建议你使用scss预处理并在插件代码中直接使用这些变量无需 import 这个文件方便用户通过搭积木的方式开发整体风格一致的App\n *\n */\n/**\n * 如果你是App开发者插件使用者你可以通过修改这些变量来定制自己的插件主题实现自定义主题功能\n *\n * 如果你的项目同样使用了scss预处理你也可以直接在你的 scss 代码中使用如下变量,同时无需 import 这个文件\n */\n/* 颜色变量 */\n/* 行为相关颜色 */\n/* 文字基本颜色 */\n/* 背景颜色 */\n/* 边框颜色 */\n/* 尺寸变量 */\n/* 文字尺寸 */\n/* 图片尺寸 */\n/* Border Radius */\n/* 水平间距 */\n/* 垂直间距 */\n/* 透明度 */\n/* 文章场景相关 */.asset-page[data-v-753bf4b1]{background:#191e32;color:#fff}.section-label[data-v-753bf4b1]{margin:0 0 %?20?%;font-size:%?36?%;font-weight:600;color:#fff}.section-subtitle[data-v-753bf4b1]{margin-top:%?8?%;font-size:%?24?%;line-height:1.6;color:hsla(0,0%,100%,.78)}.glass-panel[data-v-753bf4b1]{border:1px solid rgba(143,167,207,.16);border-radius:%?16?%;background:linear-gradient(180deg,rgba(54,62,96,.94),rgba(39,50,84,.92));box-shadow:0 %?24?% %?60?% rgba(0,0,0,.18)}.paper-panel[data-v-753bf4b1]{border:1px solid rgba(149,162,220,.16);border-radius:%?16?%;background:linear-gradient(180deg,rgba(54,62,96,.94),rgba(39,50,84,.92));box-shadow:0 %?24?% %?60?% rgba(0,0,0,.18);color:#fff}.panel-block[data-v-753bf4b1]{padding:%?20?% %?18?%}.hero-chip-row[data-v-753bf4b1]{display:flex;flex-wrap:wrap;margin:%?20?% 0 0}.hero-chip[data-v-753bf4b1]{display:inline-flex;align-items:center;padding:%?12?% %?18?%;margin:0 %?16?% %?16?% 0;border-radius:%?999?%;background:hsla(0,0%,100%,.08);font-size:%?22?%;color:#fff}.hero-chip__dot[data-v-753bf4b1]{width:%?12?%;height:%?12?%;margin-right:%?12?%;border-radius:50%;background:#4cc9ff;box-shadow:0 0 %?18?% rgba(76,201,255,.6)}.summary-grid[data-v-753bf4b1]{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));grid-gap:%?20?%}.summary-card[data-v-753bf4b1]{padding:%?24?%;border-radius:%?28?%;background:hsla(0,0%,100%,.06);border:1px solid rgba(143,167,207,.12)}.summary-card__title[data-v-753bf4b1]{font-size:%?24?%;color:hsla(0,0%,100%,.78)}.summary-card__value[data-v-753bf4b1]{display:flex;align-items:baseline;margin-top:%?14?%;font-size:%?44?%;font-weight:700;line-height:1}.summary-card__unit[data-v-753bf4b1]{margin-left:%?10?%;font-size:%?24?%;font-weight:500;color:#8fa7cf}.summary-card__desc[data-v-753bf4b1]{margin-top:%?14?%;font-size:%?22?%;line-height:1.5;color:#8fa7cf}.feature-list[data-v-753bf4b1]{margin-top:%?8?%}.feature-cell[data-v-753bf4b1]{display:flex;align-items:center;justify-content:space-between;padding:%?24?% 0;border-bottom:1px solid hsla(0,0%,100%,.08)}.feature-cell[data-v-753bf4b1]:last-child{border-bottom:0;padding-bottom:0}.feature-cell__main[data-v-753bf4b1]{flex:1;min-width:0}.feature-cell__title[data-v-753bf4b1]{font-size:%?30?%;font-weight:600;color:#fff}.feature-cell__desc[data-v-753bf4b1]{margin-top:%?8?%;font-size:%?22?%;line-height:1.5;color:hsla(0,0%,100%,.6)}.feature-cell__arrow[data-v-753bf4b1]{margin-left:%?20?%;font-size:%?36?%;font-weight:600;color:hsla(0,0%,100%,.4)}.action-row[data-v-753bf4b1]{display:flex;align-items:center}.tab-row[data-v-753bf4b1]{display:flex;padding:%?6?%;border-radius:%?999?%;background:rgba(17,27,54,.54)}.tab-chip[data-v-753bf4b1]{flex:1;padding:%?16?% 0;border-radius:%?999?%;text-align:center;font-size:%?24?%;color:hsla(0,0%,100%,.64)}.tab-chip.is-active[data-v-753bf4b1]{background:linear-gradient(135deg,#7e6cff,#6b56f6);color:#fff;box-shadow:0 %?14?% %?22?% rgba(93,79,225,.22)}.info-grid[data-v-753bf4b1]{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));grid-gap:%?18?%}.info-box[data-v-753bf4b1]{padding:%?20?%;border-radius:%?14?%;background:rgba(29,39,68,.52);border:1px solid hsla(0,0%,100%,.06)}.info-box__label[data-v-753bf4b1]{font-size:%?22?%;color:#8fa7cf}.info-box__value[data-v-753bf4b1]{margin-top:%?10?%;font-size:%?34?%;font-weight:700;color:#fff}.field-card[data-v-753bf4b1]{padding:%?18?%;border-radius:%?14?%;background:rgba(29,39,68,.52);border:1px solid hsla(0,0%,100%,.08)}.field-row[data-v-753bf4b1]{display:flex;align-items:center;justify-content:space-between}.field-label[data-v-753bf4b1]{font-size:%?24?%;color:hsla(0,0%,100%,.62)}.field-value[data-v-753bf4b1]{font-size:%?28?%;font-weight:600;color:#fff}.field-helper[data-v-753bf4b1]{margin-top:%?10?%;font-size:%?22?%;line-height:1.6;color:hsla(0,0%,100%,.6)}.text-input[data-v-753bf4b1]{width:100%;margin-top:%?16?%;padding:%?20?% %?22?%;border-radius:%?14?%;background:rgba(18,25,48,.72);border:1px solid hsla(0,0%,100%,.1);font-size:%?30?%;color:#fff}.chip-selector[data-v-753bf4b1]{display:flex;flex-wrap:wrap;margin-top:%?16?%}.chip-selector__item[data-v-753bf4b1]{padding:%?14?% %?24?%;margin:0 %?16?% %?16?% 0;border-radius:%?999?%;background:rgba(18,25,48,.72);border:1px solid hsla(0,0%,100%,.08);font-size:%?24?%;color:hsla(0,0%,100%,.64)}.chip-selector__item.is-active[data-v-753bf4b1]{background:rgba(126,108,255,.22);border-color:rgba(126,108,255,.28);color:#fff}.hint-list[data-v-753bf4b1]{margin:%?8?% 0 0}.hint-item[data-v-753bf4b1]{display:flex;margin-top:%?14?%;font-size:%?22?%;line-height:1.7;color:hsla(0,0%,100%,.62)}.hint-item__index[data-v-753bf4b1]{margin-right:%?10?%;color:#5a71ff;font-weight:600}.button-row[data-v-753bf4b1]{display:flex;align-items:center}.button-row .secondary-button[data-v-753bf4b1]{margin-right:%?20?%}.primary-button[data-v-753bf4b1]{display:flex;align-items:center;justify-content:center;width:100%;height:%?84?%;border:0;border-radius:%?999?%;background:linear-gradient(135deg,#7e6cff,#6b56f6);box-shadow:0 %?14?% %?24?% rgba(93,79,225,.22);font-size:%?30?%;font-weight:700;color:#fff}.secondary-button[data-v-753bf4b1]{display:flex;align-items:center;justify-content:center;width:100%;height:%?84?%;border-radius:%?999?%;border:1px solid hsla(0,0%,100%,.1);background:hsla(0,0%,100%,.06);font-size:%?30?%;font-weight:600;color:#fff}.button-link[data-v-753bf4b1]{font-size:%?24?%;font-weight:600;color:rgba(221,230,255,.86)}.meta-pair[data-v-753bf4b1]{display:flex;align-items:center;justify-content:space-between;margin-top:%?18?%;font-size:%?24?%}.meta-pair__label[data-v-753bf4b1]{color:hsla(0,0%,100%,.62)}.meta-pair__value[data-v-753bf4b1]{color:#fff;font-weight:600}.danger-text[data-v-753bf4b1]{color:#ff7285}.success-text[data-v-753bf4b1]{color:#5ad7a1}.warning-text[data-v-753bf4b1]{color:#ffbf66}.wallet-card[data-v-753bf4b1]{padding:%?20?% %?18?%;border-radius:%?16?%;background:linear-gradient(180deg,rgba(54,62,96,.94),rgba(39,50,84,.92));border:1px solid rgba(149,162,220,.16)}.wallet-name[data-v-753bf4b1]{font-size:%?28?%;font-weight:700;color:#fff}.wallet-address[data-v-753bf4b1]{margin-top:%?14?%;font-size:%?24?%;line-height:1.7;word-break:break-all;color:hsla(0,0%,100%,.78)}.wallet-footer[data-v-753bf4b1]{display:flex;align-items:center;justify-content:space-between;margin-top:%?20?%}.wallet-badge[data-v-753bf4b1]{padding:%?8?% %?16?%;border-radius:%?999?%;background:rgba(126,108,255,.18);font-size:%?20?%;color:#dfe7ff}.empty-panel[data-v-753bf4b1]{padding:%?36?% %?28?%;border:1px solid rgba(149,162,220,.16);border-radius:%?16?%;background:linear-gradient(180deg,rgba(54,62,96,.94),rgba(39,50,84,.92));text-align:center}.empty-title[data-v-753bf4b1]{font-size:%?30?%;font-weight:700;color:#fff}.empty-desc[data-v-753bf4b1]{margin-top:%?14?%;font-size:%?24?%;line-height:1.7;color:hsla(0,0%,100%,.78)}.page-hero[data-v-753bf4b1]{display:flex;flex-direction:column;align-items:center;padding:%?12?% 0 %?20?%}.page-hero__mark[data-v-753bf4b1]{position:relative;display:flex;align-items:center;justify-content:center;width:%?110?%;height:%?110?%;border-radius:50%;background:linear-gradient(180deg,#1f4a72,#1a3464)}.page-hero__ring[data-v-753bf4b1]{position:absolute;left:50%;top:50%;border-radius:50%;-webkit-transform:translate(-50%,-50%);transform:translate(-50%,-50%)}.page-hero__ring--outer[data-v-753bf4b1]{width:%?110?%;height:%?110?%;border:%?4?% solid rgba(63,220,255,.9);box-shadow:0 0 0 %?6?% rgba(80,225,255,.08)}.page-hero__ring--inner[data-v-753bf4b1]{width:%?88?%;height:%?88?%;border:%?3?% solid rgba(98,231,255,.42)}.page-hero__text[data-v-753bf4b1]{position:relative;z-index:1;font-size:%?52?%;font-weight:800;font-style:italic;color:#42d9ff}.page-hero__value[data-v-753bf4b1]{margin-top:%?16?%;font-size:%?24?%;font-weight:700;color:#fff}.page-hero__desc[data-v-753bf4b1]{margin-top:%?8?%;font-size:%?20?%;line-height:1.6;color:hsla(0,0%,100%,.66);text-align:center}.submit-wrap[data-v-753bf4b1]{display:flex;flex-direction:column;align-items:center;padding:%?24?% 0 %?8?%}.submit-wrap .primary-button[data-v-753bf4b1]{width:%?360?%}.record-link[data-v-753bf4b1]{margin-top:%?18?%;font-size:%?22?%;text-decoration:underline;color:rgba(222,232,255,.86)}.withdraw-page[data-v-753bf4b1]{min-height:100vh;background:#191e32}.withdraw-scroll[data-v-753bf4b1]{padding:%?8?% %?14?% calc(env(safe-area-inset-bottom) + %?36?%)}.panel-card[data-v-753bf4b1],\n.hero-card[data-v-753bf4b1]{border-radius:%?12?%;background:#242944;box-shadow:0 %?12?% %?24?% rgba(8,13,30,.12)}.hero-card[data-v-753bf4b1]{position:relative;min-height:%?240?%;padding:%?24?% %?28?%;overflow:hidden;background:#242944 url(https://imgs.agrimedia.cn/bm-bmt/qianbao-bg.png) no-repeat top/100% %?240?%;background-size:cover}.hero-card__content[data-v-753bf4b1]{position:relative;z-index:1;display:flex;flex-direction:column}.hero-card__coin-row[data-v-753bf4b1]{display:flex;align-items:center}.hero-card__coin[data-v-753bf4b1]{display:flex;align-items:center;justify-content:center;width:%?56?%;height:%?56?%;border-radius:50%;background:linear-gradient(135deg,#18c5ff,#1496ff)}.hero-card__coin-image[data-v-753bf4b1]{width:%?30?%;height:%?30?%}.hero-card__coin-text[data-v-753bf4b1]{margin-left:%?16?%;font-size:%?32?%;font-weight:500;color:#fff}.hero-card__label[data-v-753bf4b1]{margin-top:%?34?%;font-size:%?28?%;color:#9ba7ce}.hero-card__value[data-v-753bf4b1]{margin-top:%?8?%;font-size:%?42?%;font-weight:800;line-height:1.1;color:#fff}.hero-card__price[data-v-753bf4b1]{margin-top:%?14?%;font-size:%?28?%;color:#29dca3}.panel-card[data-v-753bf4b1]{margin-top:%?18?%;padding:%?22?% %?20?% %?24?%}.section-head[data-v-753bf4b1]{display:flex;align-items:center}.section-head__icon[data-v-753bf4b1]{width:%?28?%;height:%?28?%;flex-shrink:0}.section-head__title[data-v-753bf4b1]{margin-left:%?14?%;font-size:%?28?%;font-weight:700;color:#fff}.amount-input[data-v-753bf4b1]{display:flex;align-items:center;margin-top:%?22?%;padding:0 %?20?%;border-radius:%?10?%;background:#191e32}.amount-input__field[data-v-753bf4b1]{flex:1;height:%?84?%;font-size:%?36?%;font-weight:700;color:#fff}.amount-input__placeholder[data-v-753bf4b1]{color:rgba(170,179,204,.66);font-size:%?28?%}.amount-input__action[data-v-753bf4b1]{margin-left:%?20?%;font-size:%?28?%;font-weight:500;color:#20b6f5}.fee-card[data-v-753bf4b1]{display:flex;align-items:center;justify-content:space-between;margin-top:%?18?%;padding:%?16?% %?20?%;border-radius:%?8?%;background:rgba(96,67,88,.44)}.fee-card__label[data-v-753bf4b1]{font-size:%?26?%;color:#ff9367}.fee-card__value[data-v-753bf4b1]{font-size:%?24?%;font-weight:700;color:#ff9367}.calc-sheet[data-v-753bf4b1]{margin-top:%?16?%;padding:%?18?% %?20?%;border-radius:%?10?%;background:rgba(18,23,42,.72)}.calc-sheet__row[data-v-753bf4b1]{display:flex;align-items:flex-start;justify-content:space-between}.calc-sheet__row + .calc-sheet__row[data-v-753bf4b1]{margin-top:%?14?%}.calc-sheet__row--formula[data-v-753bf4b1]{align-items:center}.calc-sheet__label[data-v-753bf4b1]{flex-shrink:0;font-size:%?24?%;color:rgba(188,198,223,.82)}.calc-sheet__value[data-v-753bf4b1]{margin-left:%?24?%;text-align:right;font-size:%?24?%;color:#fff}.calc-sheet__value--formula[data-v-753bf4b1]{max-width:%?380?%;line-height:1.5;color:#ffcf8a}.wallet-card__head[data-v-753bf4b1]{display:flex;align-items:center;justify-content:space-between}.wallet-card__title-icon[data-v-753bf4b1]{position:relative;width:%?34?%;height:%?28?%;margin-right:%?2?%;flex-shrink:0}.wallet-card__title-tab[data-v-753bf4b1]{position:absolute;left:%?5?%;top:%?-4?%;width:%?16?%;height:%?10?%;border-radius:%?6?% %?6?% 0 0;background:#b48eff}.wallet-card__title-body[data-v-753bf4b1]{position:absolute;left:0;bottom:0;width:%?34?%;height:%?22?%;border-radius:%?6?%;background:linear-gradient(135deg,#b48eff,#8c6ef0)}.wallet-card__link[data-v-753bf4b1]{font-size:%?26?%;font-weight:600;color:#20b6f5}.wallet-box[data-v-753bf4b1]{margin-top:%?18?%;padding:%?18?% %?20?%;border-radius:%?8?%;background:#353e5e}.wallet-box__head[data-v-753bf4b1]{display:flex;align-items:center;justify-content:space-between}.wallet-box__name[data-v-753bf4b1]{font-size:%?26?%;color:rgba(232,239,255,.88)}.wallet-box__actions[data-v-753bf4b1]{display:flex;align-items:center}.wallet-box__action[data-v-753bf4b1]{margin-left:%?24?%;font-size:%?26?%;font-weight:400;color:#20b6f5}.wallet-box__address[data-v-753bf4b1]{margin-top:%?18?%;font-size:%?26?%;line-height:1.6;color:#fff;word-break:break-all}.wallet-box--empty[data-v-753bf4b1]{display:flex;align-items:center;justify-content:center;min-height:%?120?%;background:#353e5e}.wallet-box__plus[data-v-753bf4b1]{margin-right:%?14?%;font-size:%?46?%;line-height:1;color:#20b6f5}.wallet-box__empty-text[data-v-753bf4b1]{font-size:%?26?%;font-weight:600;color:#20b6f5}.wallet-card__desc[data-v-753bf4b1]{display:block;margin-top:%?22?%;font-size:%?26?%;line-height:1.65;color:rgba(170,179,204,.9)}.action-wrap[data-v-753bf4b1]{padding:%?86?% %?20?% 0}.action-button[data-v-753bf4b1]{display:flex;align-items:center;justify-content:center;width:100%;height:%?90?%;font-weight:500;font-size:%?30?%;color:#fff;border-radius:%?46?%;background:linear-gradient(135deg,#20b6f5,#1ca5e3);box-shadow:0 %?16?% %?30?% rgba(20,119,214,.16);font-size:%?30?%;font-weight:700;color:#fff}.action-link[data-v-753bf4b1]{margin-top:%?28?%;text-align:center;font-weight:500;font-size:%?28?%;color:#1fb4ff}.popup-detail__row[data-v-753bf4b1]{display:flex;align-items:flex-start;justify-content:space-between;margin-top:%?14?%}.popup-address[data-v-753bf4b1]{max-width:%?320?%;text-align:right;word-break:break-all}.popup-formula[data-v-753bf4b1]{max-width:%?320?%;text-align:right;line-height:1.5;color:#ffcf8a}',""]),t.exports=a},6306:function(t,a,e){"use strict";e("6a54");var i=e("f5bd").default;Object.defineProperty(a,"__esModule",{value:!0}),a.default=void 0;var n=i(e("2634")),r=i(e("2fdc")),o=i(e("fcf3"));e("64aa"),e("f7a5"),e("5c47"),e("a1c1"),e("c9b5"),e("bf0f"),e("ab80");var l=i(e("ee03")),s=i(e("58b0")),d=e("961b"),f={components:{AssetConfirmPopup:l.default,AssetPageShell:s.default},data:function(){return{detail:{ticker:{},withdrawableBmt:"0",withdrawRate:0,balances:{voucher:0,coupon:0},defaultWallet:null},hasShown:!1,form:{amount:""},confirmVisible:!1,walletVisible:!1,submitting:!1}},onLoad:function(){this.loadPage(!0)},onShow:function(){this.hasShown?this.loadPage():this.hasShown=!0},computed:{amountValue:function(){return Number(this.form.amount||0)},amountDisplay:function(){return this.formatAmount(this.amountValue,2)},feeText:function(){var t=this.amountValue*this.withdrawRateNumber/100;return this.amountValue?this.formatAmount(t,2)+" BMT":"0.00 BMT"},actualText:function(){var t=this.amountValue*this.withdrawRateNumber/100,a=Math.max(0,this.amountValue-t);return this.amountValue?this.formatAmount(a,2)+" BMT":"0.00 BMT"},displayWithdrawable:function(){return this.formatAmount(this.detail.withdrawableBmt,2)},displayPrice:function(){var t=this.detail&&this.detail.ticker&&"object"===(0,o.default)(this.detail.ticker)?this.detail.ticker:{},a=Number(t.close||t.cnyPrice||0);return!Number.isFinite(a)||a<=0?"0.000":a.toFixed(3)},withdrawRateNumber:function(){var t=Number(this.detail.withdrawRate||0);return Number.isFinite(t)&&t>0?t:0},withdrawRateLabel:function(){return this.withdrawRateNumber?this.stripTrailingZero(this.withdrawRateNumber)+"%":"0%"},walletDisplayAddress:function(){if(!this.detail.defaultWallet||!this.detail.defaultWallet.address)return"";var t=this.detail.defaultWallet.address;return this.walletVisible||t.length<=16?t:t.slice(0,8)+"..."+t.slice(-8)}},methods:{pageIcon:function(t){return{power:"https://imgs.agrimedia.cn/bm-bmt/s.png",bmt:"https://imgs.agrimedia.cn/bm-bmt/b.png",transfer:"https://imgs.agrimedia.cn/bm-bmt/z.png",withdraw:"https://imgs.agrimedia.cn/bm-bmt/t.png",voucher:"https://imgs.agrimedia.cn/bm-bmt/quan-icon.png",points:"https://imgs.agrimedia.cn/bm-bmt/j.png",coupon:"https://imgs.agrimedia.cn/bm-bmt/xiaofei-icon.png"}[t]||""},formatAmount:function(t,a){var e=Number(t||0);if(!Number.isFinite(e))return a>0?Number(0).toFixed(a):"0";if(a>0){var i=e.toFixed(a),n=i.split(".");return n[0]=n[0].replace(/\B(?=(\d{3})+(?!\d))/g,","),n.join(".")}return Math.floor(e).toString().replace(/\B(?=(\d{3})+(?!\d))/g,",")},stripTrailingZero:function(t){var a=Number(t||0);return Number.isFinite(a)?a.toFixed(4).replace(/\.?0+$/,""):"0"},loadPage:function(t){var a=this;return(0,r.default)((0,n.default)().mark((function e(){return(0,n.default)().wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,(0,d.fetchWithdrawDetail)(t?{showLoading:!0,loadingText:"加载中"}:null);case 3:a.detail=e.sent,a.walletVisible=!1,e.next=10;break;case 7:e.prev=7,e.t0=e["catch"](0),uni.showToast({title:e.t0.message||"页面加载失败",icon:"none"});case 10:case"end":return e.stop()}}),e,null,[[0,7]])})))()},fillAll:function(){this.form.amount=this.detail.withdrawableBmt||"0"},toggleWalletVisible:function(){this.walletVisible=!this.walletVisible},copyWallet:function(){this.detail.defaultWallet&&this.detail.defaultWallet.address&&uni.setClipboardData({data:this.detail.defaultWallet.address,showToast:!1,success:function(){uni.showToast({title:"钱包地址已复制",icon:"none"})}})},openConfirm:function(){this.detail.defaultWallet?this.amountValue?this.amountValue>Number(this.detail.withdrawableBmt||0)?uni.showToast({title:"可提取BMT不足",icon:"none"}):this.confirmVisible=!0:uni.showToast({title:"请输入提取数量",icon:"none"}):uni.showToast({title:"请先添加钱包地址",icon:"none"})},submit:function(){var t=this;return(0,r.default)((0,n.default)().mark((function a(){return(0,n.default)().wrap((function(a){while(1)switch(a.prev=a.next){case 0:if(!t.submitting){a.next=2;break}return a.abrupt("return");case 2:if(t.detail.defaultWallet){a.next=5;break}return uni.showToast({title:"请先添加钱包地址",icon:"none"}),a.abrupt("return");case 5:if(t.amountValue){a.next=8;break}return uni.showToast({title:"请输入提取数量",icon:"none"}),a.abrupt("return");case 8:return t.submitting=!0,a.prev=9,a.next=12,(0,d.submitAssetWithdraw)({amount:t.amountValue,address:t.detail.defaultWallet.address},{showLoading:!0,loadingText:"提交中"});case 12:t.confirmVisible=!1,t.form.amount="",uni.showToast({title:"提取申请成功",icon:"none"}),t.loadPage(),a.next=21;break;case 18:a.prev=18,a.t0=a["catch"](9),uni.showToast({title:a.t0.message||"提取失败",icon:"none"});case 21:return a.prev=21,t.submitting=!1,a.finish(21);case 24:case"end":return a.stop()}}),a,null,[[9,18,21,24]])})))()},openWallet:function(){uni.navigateTo({url:"/pages/assets/wallet"})},openLedger:function(){uni.navigateTo({url:"/pages/assets/ledger?type=withdraw"})}}};a.default=f},"78a9":function(t,a,e){"use strict";e.d(a,"b",(function(){return i})),e.d(a,"c",(function(){return n})),e.d(a,"a",(function(){}));var i=function(){var t=this,a=t.$createElement,e=t._self._c||a;return e("v-uni-view",{staticClass:"asset-page asset-theme withdraw-page"},[e("asset-page-shell",{attrs:{title:"提取BMT"}}),e("v-uni-view",{staticClass:"asset-scroll withdraw-scroll"},[e("v-uni-view",{staticClass:"hero-card"},[e("v-uni-view",{staticClass:"hero-card__content"},[e("v-uni-view",{staticClass:"hero-card__coin-row"},[e("v-uni-view",{staticClass:"hero-card__coin"},[e("v-uni-image",{staticClass:"hero-card__coin-image",attrs:{src:"https://imgs.agrimedia.cn/bm-bmt/b-w.png",mode:"aspectFit"}})],1),e("v-uni-text",{staticClass:"hero-card__coin-text"},[t._v("BMT")])],1),e("v-uni-text",{staticClass:"hero-card__label"},[t._v("本地钱包可提取BMT:")]),e("v-uni-text",{staticClass:"hero-card__value asset-number-font"},[t._v(t._s(t.displayWithdrawable))]),e("v-uni-text",{staticClass:"hero-card__price asset-number-font"},[t._v("(BMT实时价格 "+t._s(t.displayPrice)+"CNY/BMT)")])],1)],1),e("v-uni-view",{staticClass:"panel-card amount-card"},[e("v-uni-view",{staticClass:"section-head"},[e("v-uni-image",{staticClass:"section-head__icon",attrs:{src:t.pageIcon("bmt"),mode:"aspectFit"}}),e("v-uni-text",{staticClass:"section-head__title"},[t._v("BMT提取数量")])],1),e("v-uni-view",{staticClass:"amount-input"},[e("v-uni-input",{staticClass:"amount-input__field asset-number-font",attrs:{type:"number",placeholder:"请输入提取数量","placeholder-class":"amount-input__placeholder"},model:{value:t.form.amount,callback:function(a){t.$set(t.form,"amount",a)},expression:"form.amount"}}),e("v-uni-text",{staticClass:"amount-input__action",on:{click:function(a){arguments[0]=a=t.$handleEvent(a),t.fillAll.apply(void 0,arguments)}}},[t._v("全部提取")])],1),e("v-uni-view",{staticClass:"fee-card"},[e("v-uni-text",{staticClass:"fee-card__label asset-number-font"},[t._v("提取手续费("+t._s(t.withdrawRateLabel)+"")]),e("v-uni-text",{staticClass:"fee-card__value asset-number-font"},[t._v(t._s(t.feeText))])],1)],1),e("v-uni-view",{staticClass:"panel-card wallet-card"},[e("v-uni-view",{staticClass:"wallet-card__head"},[e("v-uni-view",{staticClass:"section-head"},[e("v-uni-view",{staticClass:"wallet-card__title-icon"},[e("v-uni-view",{staticClass:"wallet-card__title-tab"}),e("v-uni-view",{staticClass:"wallet-card__title-body"})],1),e("v-uni-text",{staticClass:"section-head__title"},[t._v("钱包地址")])],1),e("v-uni-text",{staticClass:"wallet-card__link",on:{click:function(a){arguments[0]=a=t.$handleEvent(a),t.openWallet.apply(void 0,arguments)}}},[t._v("修改钱包地址")])],1),t.detail.defaultWallet?e("v-uni-view",{staticClass:"wallet-box"},[e("v-uni-view",{staticClass:"wallet-box__head"},[e("v-uni-text",{staticClass:"wallet-box__name"},[t._v(t._s(t.detail.defaultWallet.name))]),e("v-uni-view",{staticClass:"wallet-box__actions"},[e("v-uni-text",{staticClass:"wallet-box__action",on:{click:function(a){arguments[0]=a=t.$handleEvent(a),t.toggleWalletVisible.apply(void 0,arguments)}}},[t._v(t._s(t.walletVisible?"隐藏":"显示"))]),e("v-uni-text",{staticClass:"wallet-box__action",on:{click:function(a){arguments[0]=a=t.$handleEvent(a),t.copyWallet.apply(void 0,arguments)}}},[t._v("复制")])],1)],1),e("v-uni-text",{staticClass:"wallet-box__address asset-number-font"},[t._v(t._s(t.walletDisplayAddress))])],1):e("v-uni-view",{staticClass:"wallet-box wallet-box--empty",on:{click:function(a){arguments[0]=a=t.$handleEvent(a),t.openWallet.apply(void 0,arguments)}}},[e("v-uni-text",{staticClass:"wallet-box__plus"},[t._v("")]),e("v-uni-text",{staticClass:"wallet-box__empty-text"},[t._v("添加钱包地址")])],1),e("v-uni-text",{staticClass:"wallet-card__desc"},[t._v("请仔细核对钱包地址,一经转出将无法追回。")])],1),e("v-uni-view",{staticClass:"action-wrap"},[e("v-uni-view",{staticClass:"action-button",on:{click:function(a){arguments[0]=a=t.$handleEvent(a),t.openConfirm.apply(void 0,arguments)}}},[t._v("确定")]),e("v-uni-view",{staticClass:"action-link",on:{click:function(a){arguments[0]=a=t.$handleEvent(a),t.openLedger.apply(void 0,arguments)}}},[t._v("提取记录")])],1)],1),e("asset-confirm-popup",{attrs:{visible:t.confirmVisible,title:"确认提取",message:"确认提取 "+t.amountDisplay+" BMT 到以下钱包吗?","confirm-text":"确认","cancel-text":"取消"},on:{cancel:function(a){arguments[0]=a=t.$handleEvent(a),t.confirmVisible=!1},confirm:function(a){arguments[0]=a=t.$handleEvent(a),t.submit.apply(void 0,arguments)}}},[e("v-uni-view",{staticClass:"popup-detail"},[e("v-uni-view",{staticClass:"popup-detail__row"},[e("v-uni-text",{staticClass:"meta-pair__label"},[t._v("钱包地址")]),e("v-uni-text",{staticClass:"meta-pair__value popup-address asset-number-font"},[t._v(t._s(t.detail.defaultWallet?t.detail.defaultWallet.address:"未设置"))])],1),e("v-uni-view",{staticClass:"popup-detail__row"},[e("v-uni-text",{staticClass:"meta-pair__label"},[t._v("BMT实时价格")]),e("v-uni-text",{staticClass:"meta-pair__value asset-number-font"},[t._v(t._s(t.displayPrice)+" CNY/BMT")])],1),e("v-uni-view",{staticClass:"popup-detail__row"},[e("v-uni-text",{staticClass:"meta-pair__label"},[t._v("手续费费率")]),e("v-uni-text",{staticClass:"meta-pair__value asset-number-font"},[t._v(t._s(t.withdrawRateLabel))])],1),e("v-uni-view",{staticClass:"popup-detail__row"},[e("v-uni-text",{staticClass:"meta-pair__label"},[t._v("提取手续费")]),e("v-uni-text",{staticClass:"meta-pair__value asset-number-font"},[t._v(t._s(t.feeText))])],1),e("v-uni-view",{staticClass:"popup-detail__row"},[e("v-uni-text",{staticClass:"meta-pair__label"},[t._v("预计到账")]),e("v-uni-text",{staticClass:"meta-pair__value asset-number-font"},[t._v(t._s(t.actualText))])],1)],1)],1)],1)},n=[]},d8de:function(t,a,e){"use strict";e.r(a);var i=e("78a9"),n=e("0e42");for(var r in n)["default"].indexOf(r)<0&&function(t){e.d(a,t,(function(){return n[t]}))}(r);e("1a85");var o=e("828b"),l=Object(o["a"])(n["default"],i["b"],i["c"],!1,null,"753bf4b1",null,!1,i["a"],void 0);a["default"]=l.exports},e766:function(t,a,e){var i=e("369a");i.__esModule&&(i=i.default),"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var n=e("967d").default;n("f51aa76a",i,!0,{sourceMap:!1,shadowMode:!1})}}]);