(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["ib-transfer"],{1978:function(t,e,a){},"4cc3":function(t,e,a){"use strict";var r=a("90a4"),i=a.n(r);i.a},"90a4":function(t,e,a){},bba8:function(t,e,a){"use strict";a.r(e);var r=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("div",{attrs:{id:"ib_Transfer"}},[a("div",{staticClass:"crm-title-box"},[a("div",{staticClass:"tit"},[a("span",{directives:[{name:"t",rawName:"v-t",value:"Home.page_ib.item4",expression:"'Home.page_ib.item4'"}]})])]),a("div",{staticClass:"main-content"},[a("div",{staticClass:"box box-step2"},[a("div",{staticClass:"b-card"},[a("el-row",{staticClass:"card-top"},[a("el-form",{ref:"form",staticClass:"form",attrs:{model:t.form,rules:t.rules,"label-position":"top"}},[a("el-col",{attrs:{span:12}},[a("el-form-item",{attrs:{prop:"amount",label:t.$t("Label.IBAccount")}},[a("el-input",{staticClass:"m-input",attrs:{disabled:""},model:{value:t.fromInfo,callback:function(e){t.fromInfo="string"===typeof e?e.trim():e},expression:"fromInfo"}})],1)],1),a("el-col",{attrs:{span:12}},[a("el-form-item",{attrs:{prop:"to",label:t.$t("Label.IntoAccount")}},[a("el-input",{staticClass:"m-input",attrs:{autocomplete:"off"},model:{value:t.form.to,callback:function(e){t.$set(t.form,"to","string"===typeof e?e.trim():e)},expression:"form.to"}})],1)],1),a("el-col",{attrs:{span:12}},[a("el-form-item",{attrs:{prop:"currency",label:t.$t("Label.Currency")}},[a("el-select",{staticClass:"crm_select_icon",attrs:{filterable:"",placeholder:t.$t("placeholder.choose")},model:{value:t.form.currency,callback:function(e){t.$set(t.form,"currency",e)},expression:"form.currency"}},[a("el-option",{attrs:{label:"USD",value:"USD"}})],1)],1)],1),a("el-col",{attrs:{span:12}},[a("el-form-item",{attrs:{prop:"amount",label:t.$t("Label.Amount")}},[a("el-input",{staticClass:"m-input",attrs:{autocomplete:"off"},model:{value:t.form.amount,callback:function(e){t.$set(t.form,"amount","string"===typeof e?e.trim():e)},expression:"form.amount"}})],1)],1),a("el-col",{attrs:{span:24}},[a("el-form-item",[a("el-button",{directives:[{name:"t",rawName:"v-t",value:"Btn.Submit",expression:"'Btn.Submit'"}],staticClass:"s-btn",attrs:{type:"primary"},on:{click:t.toTransfer}})],1)],1)],1)],1)],1)])]),a("el-dialog",{attrs:{visible:t.dialogCheck,center:"","close-on-click-modal":!1,"show-close":!1,"custom-class":"dialog_header_w"},on:{"update:visible":function(e){t.dialogCheck=e}}},[t.dialogVisible?a("div",{staticClass:"dia-content"},[a("div",{staticClass:"icon"},[a("i",{staticClass:"iconfont iconchenggong"})]),a("div",{directives:[{name:"t",rawName:"v-t",value:"ApplicationDialog.Des1",expression:"'ApplicationDialog.Des1'"}],staticClass:"des1"}),a("div",{directives:[{name:"t",rawName:"v-t",value:"ApplicationDialog.Des11",expression:"'ApplicationDialog.Des11'"}],staticClass:"des2"}),a("div",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[a("el-button",{directives:[{name:"t",rawName:"v-t",value:"Btn.Confirm",expression:"'Btn.Confirm'"}],attrs:{type:"primary"},on:{click:t.closeDia}}),a("el-button",{directives:[{name:"t",rawName:"v-t",value:"Btn.Cancel",expression:"'Btn.Cancel'"}],on:{click:t.closeDia}})],1)]):t._e(),t.dialogVisible?t._e():a("div",{staticClass:"dia-content"},[a("div",{staticClass:"icon"},[a("i",{staticClass:"iconfont iconjingshi"})]),a("div",{staticClass:"des1"},[t._v(t._s(t.RES))]),a("div",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[a("el-button",{directives:[{name:"t",rawName:"v-t",value:"Btn.Confirm",expression:"'Btn.Confirm'"}],attrs:{type:"primary"},on:{click:t.closeDia}}),a("el-button",{directives:[{name:"t",rawName:"v-t",value:"Btn.Cancel",expression:"'Btn.Cancel'"}],on:{click:t.closeDia}})],1)])])],1)},i=[],s=a("5530"),n=(a("96cf"),a("1da1")),o=a("1c45"),l=a("f121"),c=a.n(l),u=c.a.Code,m={name:"Transfer",data:function(){var t=this;return{flag:!1,RES:"",form:{currency:"USD"},fromInfo:"",dialogCheck:!1,dialogVisible:!1,rules:{amount:[{validator:function(e,a,r){t.Config.Pattern.nonnegative.test(a)?r():r(new Error(t.$i18n.t("vaildate.amount.format")))},required:!0,trigger:"blur"}],currency:[{required:!0,message:this.$i18n.t("vaildate.select.empty"),trigger:"change"}],to:[{required:!0,message:this.$i18n.t("vaildate.input.empty"),trigger:"change"}]}}},methods:{closeDia:function(){this.$refs["params"]&&this.$refs["params"].resetFields(),this.dialogCheck=!1,this.dialogVisible=!1},toTransfer:function(){var t=Object(n["a"])(regeneratorRuntime.mark((function t(){var e=this;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:this.$refs["form"].validate(function(){var t=Object(n["a"])(regeneratorRuntime.mark((function t(a){var r;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:if(!a){t.next=12;break}if(!e.flag){t.next=5;break}return t.abrupt("return");case 5:e.flag=!0;case 6:return t.next=8,o["a"].agentBalanceTransfer(Object(s["a"])({},e.form));case 8:r=t.sent,r.code==u.StatusOK?(e.dialogCheck=!0,e.dialogVisible=!0,e.flag=!1):(e.RES=r.msg,e.dialogCheck=!0,e.dialogVisible=!1,e.flag=!1),t.next=13;break;case 12:return t.abrupt("return",!1);case 13:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}());case 1:case"end":return t.stop()}}),t,this)})));function e(){return t.apply(this,arguments)}return e}(),ransferInfo:function(){var t=Object(n["a"])(regeneratorRuntime.mark((function t(){var e;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.next=2,o["a"].agentBalanceTransferFrom({});case 2:e=t.sent,e.code==u.StatusOK?this.fromInfo=e.data.ibNo+" - "+this.$i18n.t("Custom.Deposit.AvailableBalance")+": $"+(e.data.balance?e.data.balance:0):this.$pigeon.MessageError(e.msg);case 4:case"end":return t.stop()}}),t,this)})));function e(){return t.apply(this,arguments)}return e}()},mounted:function(){this.ransferInfo()}},f=m,p=(a("4cc3"),a("febb"),a("2877")),d=Object(p["a"])(f,r,i,!1,null,"ab6c3602",null);e["default"]=d.exports},febb:function(t,e,a){"use strict";var r=a("1978"),i=a.n(r);i.a}}]);