(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-1fa1554b"],{"407b":function(t,e,s){"use strict";s("6b19")},"6b19":function(t,e,s){},f7f7:function(t,e,s){"use strict";s.r(e);var a=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("div",{staticClass:"shop"},[s("div",{staticStyle:{padding:"10px","margin-top":"10px"}},[s("div",{staticStyle:{height:"140px",background:"rgba(255,255,255,1)","box-shadow":"0px 1px 2px 1px rgba(148,114,169,0.2)","border-radius":"5px"}},[s("div",{staticStyle:{width:"150px",float:"left"}},[s("img",{staticClass:"car_img",attrs:{src:t.mount.coverImage}})]),s("div",{staticStyle:{float:"left"}},[s("div",{staticClass:"car_title"},[t._v("座驾："+t._s(t.mount.mountName)+" ")]),s("div",{staticClass:"car_jinyan"},[t._v(" 所需要经验：0")])])])]),s("div",{staticClass:"buy_content"},[s("div",{staticClass:"buy_div_item"},[t._v("购买账号： "),s("input",{directives:[{name:"model",rawName:"v-model",value:t.buyUserId,expression:"buyUserId"}],staticClass:"ipt_userid",class:{ipt_userid_dis:t.selfBuy},attrs:{type:"text",id:"userId",readonly:t.selfBuy,placeholder:"请输入账号ID"},domProps:{value:t.buyUserId},on:{input:function(e){e.target.composing||(t.buyUserId=e.target.value)}}}),t.selfBuy?s("span",{staticClass:"spGetUidBtn",on:{click:t.friendBuy}},[t._v("帮朋友购买>>")]):t._e(),t.selfBuy?t._e():s("span",{staticClass:"spGetUidBtn",on:{click:t.checkUser}},[t._v("确定")])]),s("div",{staticClass:"buy_div_item"},[t._v("昵称： "),s("span",{attrs:{id:"spUserName"}},[t._v(t._s(t.nickName))])]),s("div",{staticClass:"buy_div_item"},[t._v("购买时长：一个月")]),s("div",{staticClass:"buy_div_item"},[t._v("应该付金额："+t._s(t.mount.mountCoin))])]),s("div",[s("div",{staticClass:"payBtn",on:{click:t.buyMount}},[t._v("确认")])])])},n=[],i=(s("96cf"),s("1da1")),u=(s("e17f"),s("2241")),r=(s("e7e5"),s("d399")),c={data:function(){return{selfBuy:!0,mount:{},userId:"",nickName:"",buyUserId:""}},components:{Toast:r["a"],Dialog:u["a"]},created:function(){this.getMountInfo()},methods:{getMountInfo:function(){var t=this;return Object(i["a"])(regeneratorRuntime.mark((function e(){var s,a;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,t.$http.get("/user/shop/mount",{params:{mountId:t.$route.query.mountId}});case 2:s=e.sent,a=s.data,t.nickName=a.data.nickName,t.userId=a.data.userId,t.mount=a.data.mount,t.buyUserId=a.data.userId;case 8:case"end":return e.stop()}}),e)})))()},checkUser:function(t){var e=this;this.$http.post("/user/user/checkUser",{id:this.buyUserId}).then((function(t){2e4==t.data.code?e.nickName=t.data.data.nickName:Object(r["a"])(t.data.message)}))},friendBuy:function(){this.selfBuy=!1,this.buyUserId=""},buyMount:function(){var t=this;u["a"].confirm({title:"购买坐骑",message:"您将花费"+this.mount.mountCoin+"  金币，购买坐骑"+this.mount.mountName}).then((function(){t.$http.post("/user/userMount/buy",{mountId:t.mount.id,userId:t.buyUserId}).then((function(e){2e4==e.data.code?u["a"].alert({title:"购买成功",message:"快去【我的背包】装扮吧"}).then((function(){t.changeUserInfo(),t.$router.back(-1)})):Object(r["a"])(e.data.message)}))})).catch((function(){}))}}},o=c,d=(s("407b"),s("2877")),l=Object(d["a"])(o,a,n,!1,null,"0b9db9c7",null);e["default"]=l.exports}}]);