(self["webpackChunkerp"]=self["webpackChunkerp"]||[]).push([[650],{1650:function(t,e,r){"use strict";r.r(e),r.d(e,{default:function(){return c}});var n=function(){var t=this,e=t._self._c;return e("div",[e("el-card",{staticClass:"box-card",attrs:{"body-style":{padding:"20px 20px 0 20px"}}},[e("el-form",{staticClass:"demo-form-inline",attrs:{inline:!0,model:t.formSearch}},[e("el-form-item",{attrs:{label:"团购状态"}},[e("el-select",{attrs:{placeholder:"团购状态"},model:{value:t.formSearch.status,callback:function(e){t.$set(t.formSearch,"status",e)},expression:"formSearch.status"}},[e("el-option",{attrs:{label:"未开始",value:"-5"}}),e("el-option",{attrs:{label:"跟团中",value:"1"}}),e("el-option",{attrs:{label:"预览中",value:"-10"}}),e("el-option",{attrs:{label:"已结束",value:"20"}})],1)],1),e("el-form-item",{attrs:{label:"活动标题"}},[e("el-input",{attrs:{placeholder:"活动标题"},model:{value:t.formSearch.title,callback:function(e){t.$set(t.formSearch,"title",e)},expression:"formSearch.title"}})],1),e("el-form-item",[e("el-button",{attrs:{type:"primary"},on:{click:function(e){return t.getGroupList()}}},[t._v("查询")]),e("el-button",{attrs:{type:"success"},on:{click:function(e){return t.groupAdd()}}},[t._v("新增团购")])],1)],1)],1),e("el-card",{staticClass:"box-card",staticStyle:{"margin-top":"10px"}},[e("el-table",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],staticStyle:{width:"100%"},attrs:{data:t.tableData,border:"","row-key":"id","tree-props":{children:"children"}}},[e("el-table-column",{attrs:{prop:"shop.name",label:"店铺"}}),e("el-table-column",{attrs:{prop:"title",label:"活动标题"}}),e("el-table-column",{attrs:{prop:"status",label:"团购状态"}}),e("el-table-column",{attrs:{label:"开团时间"},scopedSlots:t._u([{key:"default",fn:function(r){return[e("div",[t._v(t._s(r.row.start_time))]),e("div",[t._v("至")]),e("div",[t._v(t._s(r.row.end_time))])]}}])}),e("el-table-column",{attrs:{label:"手机查看"},scopedSlots:t._u([{key:"default",fn:function(t){return[e("el-image",{staticStyle:{width:"100px",height:"100px"},attrs:{src:t.row.qr_code_url}})]}}])}),e("el-table-column",{attrs:{prop:"create_status",label:"创建结果"}}),e("el-table-column",{attrs:{prop:"options",label:"操作"},scopedSlots:t._u([{key:"default",fn:function(r){return[0==r.row.parent_id?e("el-button",{attrs:{type:"text",size:"small"},on:{click:function(e){return t.groupEdit(r.row.id)}}},[t._v("编辑")]):t._e()]}}])})],1)],1)],1)},o=[],s=(r(560),r(8159)),a={data(){return{formSearch:{status:"",title:"",page:1,per_page:20},loading:!0,tableData:[]}},mounted(){this.getGroupList()},methods:{getGroupList(){(0,s.X8)(this.formSearch).then((t=>{this.tableData=t.data.data,this.loading=!1}))},groupAdd(){this.$router.push({path:"GROUP_GOODS_ADD",query:{id:0}})},groupEdit(t){this.$router.push({path:"GROUP_GOODS_EDIT",query:{id:t}})}}},i=a,u=r(1001),l=(0,u.Z)(i,n,o,!1,null,null,null),c=l.exports},8159:function(t,e,r){"use strict";r.d(e,{Rp:function(){return s},Tv:function(){return i},X8:function(){return o},Y6:function(){return a},ni:function(){return l},sC:function(){return u}});var n=r(422);function o(t){return(0,n.Z)({url:"/api/group",method:"get",params:t})}function s(t){return(0,n.Z)({url:"/api/group",method:"post",data:t})}function a(t){return(0,n.Z)({url:`/api/group/${t}`,method:"get"})}function i(t,e){return(0,n.Z)({url:`/api/group/${t}`,method:"patch",data:e})}function u(t){return(0,n.Z)({url:"/api/groupGoods",method:"get",params:t})}function l(t){return(0,n.Z)({url:"/api/groupGoods",method:"post",params:t})}},6525:function(t,e,r){"use strict";r.d(e,{LP:function(){return o},gy:function(){return s}});const n="admin_token";function o(){return localStorage.getItem("token")}function s(){return localStorage.removeItem(n)}},422:function(t,e,r){"use strict";var n=r(9669),o=r.n(n),s=r(6525),a=r(4865),i=r.n(a),u=r(4720),l=o().create({timeout:36e4});l.interceptors.request.use((t=>(t.headers.Authorization="Bearer "+(0,s.LP)(),i().start(),t)),(t=>Promise.reject(t))),l.interceptors.response.use((t=>{i().done();const e=t.status;if(200===e||201===e)return t}),(t=>(i().done(),400===t.response.status&&(0,u.Message)({message:t.response.data.errorMessage,type:"error"}),500===t.response.status&&(0,u.Message)({message:t.response.data.message,type:"error"}),Promise.reject(t)))),e.Z=l},4865:function(t,e,r){var n,o;
/* NProgress, (c) 2013, 2014 Rico Sta. Cruz - http://ricostacruz.com/nprogress
 * @license MIT */(function(s,a){n=a,o="function"===typeof n?n.call(e,r,e,t):n,void 0===o||(t.exports=o)})(0,(function(){var t={version:"0.2.0"},e=t.settings={minimum:.08,easing:"ease",positionUsing:"",speed:200,trickle:!0,trickleRate:.02,trickleSpeed:800,showSpinner:!0,barSelector:'[role="bar"]',spinnerSelector:'[role="spinner"]',parent:"body",template:'<div class="bar" role="bar"><div class="peg"></div></div><div class="spinner" role="spinner"><div class="spinner-icon"></div></div>'};function r(t,e,r){return t<e?e:t>r?r:t}function n(t){return 100*(-1+t)}function o(t,r,o){var s;return s="translate3d"===e.positionUsing?{transform:"translate3d("+n(t)+"%,0,0)"}:"translate"===e.positionUsing?{transform:"translate("+n(t)+"%,0)"}:{"margin-left":n(t)+"%"},s.transition="all "+r+"ms "+o,s}t.configure=function(t){var r,n;for(r in t)n=t[r],void 0!==n&&t.hasOwnProperty(r)&&(e[r]=n);return this},t.status=null,t.set=function(n){var i=t.isStarted();n=r(n,e.minimum,1),t.status=1===n?null:n;var u=t.render(!i),l=u.querySelector(e.barSelector),c=e.speed,p=e.easing;return u.offsetWidth,s((function(r){""===e.positionUsing&&(e.positionUsing=t.getPositioningCSS()),a(l,o(n,c,p)),1===n?(a(u,{transition:"none",opacity:1}),u.offsetWidth,setTimeout((function(){a(u,{transition:"all "+c+"ms linear",opacity:0}),setTimeout((function(){t.remove(),r()}),c)}),c)):setTimeout(r,c)})),this},t.isStarted=function(){return"number"===typeof t.status},t.start=function(){t.status||t.set(0);var r=function(){setTimeout((function(){t.status&&(t.trickle(),r())}),e.trickleSpeed)};return e.trickle&&r(),this},t.done=function(e){return e||t.status?t.inc(.3+.5*Math.random()).set(1):this},t.inc=function(e){var n=t.status;return n?("number"!==typeof e&&(e=(1-n)*r(Math.random()*n,.1,.95)),n=r(n+e,0,.994),t.set(n)):t.start()},t.trickle=function(){return t.inc(Math.random()*e.trickleRate)},function(){var e=0,r=0;t.promise=function(n){return n&&"resolved"!==n.state()?(0===r&&t.start(),e++,r++,n.always((function(){r--,0===r?(e=0,t.done()):t.set((e-r)/e)})),this):this}}(),t.render=function(r){if(t.isRendered())return document.getElementById("nprogress");u(document.documentElement,"nprogress-busy");var o=document.createElement("div");o.id="nprogress",o.innerHTML=e.template;var s,i=o.querySelector(e.barSelector),l=r?"-100":n(t.status||0),c=document.querySelector(e.parent);return a(i,{transition:"all 0 linear",transform:"translate3d("+l+"%,0,0)"}),e.showSpinner||(s=o.querySelector(e.spinnerSelector),s&&p(s)),c!=document.body&&u(c,"nprogress-custom-parent"),c.appendChild(o),o},t.remove=function(){l(document.documentElement,"nprogress-busy"),l(document.querySelector(e.parent),"nprogress-custom-parent");var t=document.getElementById("nprogress");t&&p(t)},t.isRendered=function(){return!!document.getElementById("nprogress")},t.getPositioningCSS=function(){var t=document.body.style,e="WebkitTransform"in t?"Webkit":"MozTransform"in t?"Moz":"msTransform"in t?"ms":"OTransform"in t?"O":"";return e+"Perspective"in t?"translate3d":e+"Transform"in t?"translate":"margin"};var s=function(){var t=[];function e(){var r=t.shift();r&&r(e)}return function(r){t.push(r),1==t.length&&e()}}(),a=function(){var t=["Webkit","O","Moz","ms"],e={};function r(t){return t.replace(/^-ms-/,"ms-").replace(/-([\da-z])/gi,(function(t,e){return e.toUpperCase()}))}function n(e){var r=document.body.style;if(e in r)return e;var n,o=t.length,s=e.charAt(0).toUpperCase()+e.slice(1);while(o--)if(n=t[o]+s,n in r)return n;return e}function o(t){return t=r(t),e[t]||(e[t]=n(t))}function s(t,e,r){e=o(e),t.style[e]=r}return function(t,e){var r,n,o=arguments;if(2==o.length)for(r in e)n=e[r],void 0!==n&&e.hasOwnProperty(r)&&s(t,r,n);else s(t,o[1],o[2])}}();function i(t,e){var r="string"==typeof t?t:c(t);return r.indexOf(" "+e+" ")>=0}function u(t,e){var r=c(t),n=r+e;i(r,e)||(t.className=n.substring(1))}function l(t,e){var r,n=c(t);i(t,e)&&(r=n.replace(" "+e+" "," "),t.className=r.substring(1,r.length-1))}function c(t){return(" "+(t.className||"")+" ").replace(/\s+/gi," ")}function p(t){t&&t.parentNode&&t.parentNode.removeChild(t)}return t}))}}]);
//# sourceMappingURL=650.4a6fd4cf.js.map