chunk-210f6068.25a7b4dc.js 6.6 KB

12
  1. (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-210f6068"],{5608:function(t,e,a){"use strict";var s=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("div",{staticClass:"time"},[t._v("\n "+t._s(t.tipText)),!0===t.isDay?a("span",{staticClass:"styleAll"},[t._v(t._s(t.day))]):t._e(),a("span",{staticClass:"timeTxt"},[t._v(t._s(t.dayText))]),a("span",{staticClass:"styleAll"},[t._v(t._s(t.hour))]),a("span",{staticClass:"timeTxt"},[t._v(t._s(t.hourText))]),a("span",{staticClass:"styleAll"},[t._v(t._s(t.minute))]),a("span",{staticClass:"timeTxt"},[t._v(t._s(t.minuteText))]),a("span",{staticClass:"styleAll"},[t._v(t._s(t.second))]),a("span",{staticClass:"timeTxt"},[t._v(t._s(t.secondText))])])},o=[],r=(a("c5f6"),{name:"CountDown",props:{tipText:{type:String,default:"倒计时"},dayText:{type:String,default:"天"},hourText:{type:String,default:"时"},minuteText:{type:String,default:"分"},secondText:{type:String,default:"秒"},datatime:{type:Number,default:0},isDay:{type:Boolean,default:!0}},data:function(){return{day:"00",hour:"00",minute:"00",second:"00"}},created:function(){this.show_time()},mounted:function(){},methods:{show_time:function(){var t=this;function e(){var e=t.datatime-Date.parse(new Date)/1e3,a=0,s=0,o=0,r=0;e>0?(a=!0===t.isDay?Math.floor(e/86400):0,s=Math.floor(e/3600)-24*a,o=Math.floor(e/60)-24*a*60-60*s,r=Math.floor(e)-24*a*60*60-60*s*60-60*o,s<=9&&(s="0"+s),o<=9&&(o="0"+o),r<=9&&(r="0"+r),t.day=a,t.hour=s,t.minute=o,t.second=r):(t.day="00",t.hour="00",t.minute="00",t.second="00")}e(),setInterval(e,1e3)}}}),n=r,i=a("2877"),c=Object(i["a"])(n,s,o,!1,null,null,null);e["a"]=c.exports},"7ab6":function(t,e,a){"use strict";var s=a("f67d"),o=a.n(s);o.a},"988a":function(t,e,a){},adbf:function(t,e,a){"use strict";a.r(e);var s=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("div",{directives:[{name:"show",rawName:"v-show",value:t.domStatus,expression:"domStatus"}],class:[t.posterImageStatus?"noscroll product-con":"product-con"]},[a("ProductConSwiper",{attrs:{imgUrls:t.imgUrls}}),a("div",{staticClass:"nav acea-row row-between-wrapper"},[a("div",{staticClass:"money"},[t._v("\n ¥"),a("span",{staticClass:"num",domProps:{textContent:t._s(t.storeInfo.price)}}),a("span",{staticClass:"y-money",domProps:{textContent:t._s("¥"+t.storeInfo.price)}})]),a("div",{staticClass:"acea-row row-middle"},[a("div",{staticClass:"times"},[a("div",[t._v("距秒杀结束仅剩")]),a("CountDown",{attrs:{"is-day":!1,"tip-text":"","day-text":"","hour-text":" : ","minute-text":" : ","second-text":"",datatime:t.datatime}})],1),a("div",{staticClass:"iconfont icon-jiantou"})])]),a("div",{staticClass:"wrapperRush"},[a("div",{staticClass:"introduce acea-row row-between"},[a("div",{staticClass:"infor",domProps:{textContent:t._s(t.storeInfo.title)}}),a("div",{staticClass:"iconfont icon-fenxiang",on:{click:t.setPosterImageStatus}})]),a("div",{staticClass:"label acea-row row-middle"},[a("div",{staticClass:"stock",domProps:{textContent:t._s("库存:"+t.storeInfo.stock+"件")}}),a("div",{domProps:{textContent:t._s("销量:"+t.storeInfo.sales+"件")}})])]),a("div",{staticClass:"product-intro"},[a("div",{staticClass:"title"},[t._v("产品介绍")]),a("div",{staticClass:"conter",domProps:{innerHTML:t._s(t.storeInfo.description)}})]),a("div",{staticStyle:{height:"1.2rem"}}),a("div",{staticClass:"footerRush acea-row row-between-wrapper"},[a("div",{staticClass:"customerSer acea-row row-center-wrapper row-column",on:{click:function(e){return t.$router.push({path:"/customer/list"})}}},[a("div",{staticClass:"iconfont icon-kefu"}),a("div",[t._v("客服")])]),a("div",{staticClass:"bnt bg-color-green",on:{click:t.tapBuy}},[t._v("立即购买")])]),a("ProductWindow",{attrs:{attr:t.attr},on:{changeFun:t.changeFun}}),a("StorePoster",{attrs:{posterImageStatus:t.posterImageStatus,posterData:t.posterData},on:{setPosterImageStatus:t.setPosterImageStatus}})],1)},o=[],r=a("7618"),n=(a("7f7f"),a("c5f8")),i=a("5608"),c=a("c6da"),u=a("cbd6"),l=a("ca41"),d=a("73f5"),p="SeckillDetails",m={name:"SeckillDetails",components:{ProductConSwiper:n["a"],CountDown:i["a"],ProductWindow:c["a"],StorePoster:u["a"]},props:{},data:function(){return{domStatus:!1,posterData:{image:"",title:"",price:"",code:""},posterImageStatus:!1,action:"",imgUrls:[],storeInfo:[],replyCount:0,reply:[],cartNum:1,attr:{cartAttr:!1,productSelect:{image:"",store_name:"",price:"",stock:"",unique:"",cart_num:1}},datatime:0}},watch:{$route:function(t){var e=this;console.log(t),t.name===p&&e.mountedStart()}},mounted:function(){this.mountedStart()},methods:{mountedStart:function(){var t=this,e=t.$route.params.id;t.datatime=parseInt(t.$route.params.time),Object(l["s"])(e).then(function(e){t.$set(t,"storeInfo",e.data.storeInfo),t.$set(t,"imgUrls",e.data.storeInfo.images),t.$set(t,"replyCount",e.data.replyCount),t.$set(t,"reply",e.data.reply),t.posterData.image=t.storeInfo.image_base,t.updateTitle(),t.storeInfo.title.length>30?t.posterData.title=t.storeInfo.title.substring(0,30)+"...":t.posterData.title=t.storeInfo.title,t.posterData.price=t.storeInfo.price,t.posterData.code=t.storeInfo.code_base,t.setProductSelect(),t.domStatus=!0})},updateTitle:function(){document.title=this.storeInfo.title||this.$route.meta.title},setPosterImageStatus:function(){var t=document.body||document.documentElement;t.scrollTop=0,this.posterImageStatus=!this.posterImageStatus},changeFun:function(t){"object"!==Object(r["a"])(t)&&(t={});var e=t.action||"",a=void 0===t.value?"":t.value;this[e]&&this[e](a)},changeattr:function(t){var e=this;e.attr.cartAttr=t},ChangeCartNum:function(t){var e=this;t?e.attr.productSelect.cart_num<e.storeInfo.stock&&e.attr.productSelect.cart_num++:e.attr.productSelect.cart_num>1&&e.attr.productSelect.cart_num--},setProductSelect:function(){var t=this,e=t.attr;e.productSelect.image=t.storeInfo.image,e.productSelect.store_name=t.storeInfo.title,e.productSelect.price=t.storeInfo.price,e.productSelect.stock=t.storeInfo.stock,e.cartAttr=!1,t.$set(t,"attr",e)},selecAttrTap:function(){this.cartAttr=!0},tapBuy:function(){var t=this,e=this;if(0==e.attr.cartAttr)e.attr.cartAttr=!this.attr.attrcartAttr;else{var a={};a.productId=e.storeInfo.product_id,a.cartNum=e.attr.productSelect.cart_num,a.uniqueId=e.attr.productSelect.unique,a.secKillId=e.storeInfo.id,a.new=1,Object(d["m"])(a).then(function(t){e.$router.push({path:"/order/submit/"+t.data.cartId})}).catch(function(e){t.$dialog.error(e.msg)})}}}},f=m,v=(a("f1be"),a("7ab6"),a("2877")),h=Object(v["a"])(f,s,o,!1,null,"2fede8ec",null);e["default"]=h.exports},f1be:function(t,e,a){"use strict";var s=a("988a"),o=a.n(s);o.a},f67d:function(t,e,a){}}]);
  2. //# sourceMappingURL=chunk-210f6068.25a7b4dc.js.map