(global["webpackJsonp"]=global["webpackJsonp"]||[]).push([["pages/travel/travelPeople"],{"1c03":function(o,e,n){"use strict";n.r(e);var t=n("a145"),i=n("4846");for(var u in i)"default"!==u&&function(o){n.d(e,o,(function(){return i[o]}))}(u);n("4e60");var s,r=n("f0c5"),a=Object(r["a"])(i["default"],t["b"],t["c"],!1,null,null,null,!1,t["a"],s);e["default"]=a.exports},2077:function(o,e,n){"use strict";(function(o){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n={data:function(){return{houseType:0,state:0,show:0,name:"",houselist:[],roomPrice:"",number:0,active:!1,showMoadl:!0,title:"提示",chooseroommate:1,details:!1,goodsInfo:{},days:{},day:"",travelers:[],cohabits:[],room_id:0}},onLoad:function(o){var e=JSON.parse(o.days);this.days=e;var n=JSON.parse(o.goodsinfo);this.goodsInfo=n,this.init()},onShow:function(){console.log(this.$store.state.peopleList),this.travelers=this.$store.state.peopleList},methods:{init:function(){var o=this.days;console.log(o);var e=o.start_at.slice(0,10),n=o.end_at.slice(0,10);this.day="".concat(e,"~").concat(n),this.houselist=o.rooms,console.log(this.day,this.houselist)},choosePeople:function(){o.navigateTo({url:"/pages/peopleList/peopleList"})},edit:function(e){var n=JSON.stringify(e);o.navigateTo({url:"/pages/peopleList/addPeople?info=".concat(n,"&state=0")})},previewImg:function(e,n){var t=[];t.push(e),console.log(t),o.previewImage({current:t[0],urls:t})},valChange:function(o){this.roomPrice=Number(this.roomPrice)*o.value},addcohabits:function(){this.cohabits.push(""),console.log(this.cohabits)},chooseHouse:function(o,e,n){this.houseType=o,this.roomPrice=e,this.room_id=n,console.log(o,e,n,"<=============")},Submit:function(){var e=this,n={};n.good_id=this.goodsInfo.id,n.start_at=this.day.slice(0,10),n.room_id=this.room_id,n.number=this.number,n.travelers=[],n.cohabits=this.cohabits,n.cohabit_type=this.chooseroommate,this.travelers.forEach((function(o,e){n.travelers.push(o.id)})),console.log(n,"<============提交订单的需要"),o.$u.http.post("/api/order/add",n,{custom:{auth:!0}}).then((function(t){n.name=e.goodsInfo.name,n.subtitle=e.goodsInfo.subtitle,n.day=e.day,n.people=[],e.travelers.forEach((function(o,e){n.people.push(o.name)})),o.navigateTo({url:"/pages/travel/submitOrder?suborder=".concat(JSON.stringify(n))})})).catch((function(e){console.log(e),o.showToast({icon:"error",title:e.message})}))}}};e.default=n}).call(this,n("543d")["default"])},"35ab":function(o,e,n){},4846:function(o,e,n){"use strict";n.r(e);var t=n("2077"),i=n.n(t);for(var u in t)"default"!==u&&function(o){n.d(e,o,(function(){return t[o]}))}(u);e["default"]=i.a},"4e60":function(o,e,n){"use strict";var t=n("35ab"),i=n.n(t);i.a},8984:function(o,e,n){"use strict";(function(o){n("7a99");t(n("66fd"));var e=t(n("1c03"));function t(o){return o&&o.__esModule?o:{default:o}}wx.__webpack_require_UNI_MP_PLUGIN__=n,o(e.default)}).call(this,n("543d")["createPage"])},a145:function(o,e,n){"use strict";n.d(e,"b",(function(){return i})),n.d(e,"c",(function(){return u})),n.d(e,"a",(function(){return t}));var t={uNumberBox:function(){return Promise.all([n.e("common/vendor"),n.e("node-modules/uview-ui/components/u-number-box/u-number-box")]).then(n.bind(null,"fc8c"))},uCell:function(){return Promise.all([n.e("common/vendor"),n.e("node-modules/uview-ui/components/u-cell/u-cell")]).then(n.bind(null,"a4da"))},uCellGroup:function(){return Promise.all([n.e("common/vendor"),n.e("node-modules/uview-ui/components/u-cell-group/u-cell-group")]).then(n.bind(null,"2515"))},"u-Input":function(){return Promise.all([n.e("common/vendor"),n.e("node-modules/uview-ui/components/u--input/u--input")]).then(n.bind(null,"2000"))},uIcon:function(){return Promise.all([n.e("common/vendor"),n.e("node-modules/uview-ui/components/u-icon/u-icon")]).then(n.bind(null,"55f2"))},uPopup:function(){return Promise.all([n.e("common/vendor"),n.e("node-modules/uview-ui/components/u-popup/u-popup")]).then(n.bind(null,"9c08"))},uModal:function(){return Promise.all([n.e("common/vendor"),n.e("node-modules/uview-ui/components/u-modal/u-modal")]).then(n.bind(null,"079c"))}},i=function(){var o=this,e=o.$createElement,n=(o._self._c,{"margin-bottom":"104rpx",background:" #F9F9F9 ",height:"104rpx"});o._isMounted||(o.e0=function(e){o.chooseroommate=1},o.e1=function(e){o.chooseroommate=2},o.e2=function(e){o.details=!0},o.e3=function(e){o.details=!0},o.e4=function(e){o.details=!1},o.e5=function(e){o.details=!1},o.e6=function(e){o.showMoadl=!1}),o.$mp.data=Object.assign({},{$root:{a0:n}})},u=[]}},[["8984","common/runtime","common/vendor"]]]);