2 lines
119 KiB
JavaScript
2 lines
119 KiB
JavaScript
|
webpackJsonp([1],{"+g0x":function(e,t,a){"use strict";var r=a("chHD"),n=a("kTXg"),o=a("VU/8"),i=o(r.a,n.a,!1,null,null,null);t.a=i.exports},"/kHC":function(e,t,a){"use strict";var r=function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("v-container",[a("h1",[e._v("Category List")]),e._v(" "),e.loading?a("v-progress-circular",{attrs:{indeterminate:"",color:"primary"}}):e._e(),e._v(" "),a("v-container",{staticClass:"grey lighten-4",attrs:{fluid:"","grid-list-md":""}},[e.loading?e._e():a("v-layout",{attrs:{row:"",wrap:""}},[e._l(e.categories,function(t){return a("v-flex",{key:t.id,attrs:{xs12:"",sm6:"",md3:""}},[a("v-card",[t.image?a("v-card-media",{attrs:{src:"/images/categories/"+t.image.name,height:"200px"}}):e._e(),e._v(" "),a("v-card-title",{attrs:{"primary-title":""}},[a("div",[a("h3",{staticClass:"headline mb-0"},[e._v(e._s(t.name))]),e._v(" "),a("div",[e._v(e._s(t.description))])])]),e._v(" "),a("v-card-actions",[a("v-btn",{staticClass:"orange--text",attrs:{flat:""}},[e._v("Explore")]),e._v(" "),a("v-btn",{staticClass:"red--text",attrs:{flat:""},on:{click:function(a){e.deleteCategory(t.id)}}},[e._v("Delete")])],1)],1)],1)}),e._v(" "),e.categories.length<=0?a("v-layout",[a("h3",[e._v("No categories :(")])]):e._e()],2)],1),e._v(" "),a("router-link",{staticClass:"btn btn-default",attrs:{to:{name:"CreateCategory"}}},[e._v("Create")])],1)},n=[],o={render:r,staticRenderFns:n};t.a=o},"1iLV":function(e,t){},"1mmj":function(e,t,a){"use strict";var r=a("7WRu");t.a={name:"Home",data:function(){return{categories:[],loading:!0}},created:function(){this.fetchData()},methods:{fetchData:function(){var e=this;Object(r.a)("/categories",this.$store).then(function(e){return e.json()}).then(function(t){e.loading=!1,e.categories=t})},deleteCategory:function(e){var t=this,a=this.$router;Object(r.a)("/categories/"+e,this.$store,{method:"DELETE"}).then(function(){t.categories=t.categories.filter(function(t){return t.id!==e}),a.push("/category")})}}}},"23xx":function(e,t,a){"use strict";var r=function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("v-container",[a("h1",[e._v("Group List")]),e._v(" "),e.loading?a("v-progress-circular",{attrs:{indeterminate:"",color:"primary"}}):e._e(),e._v(" "),a("v-layout",{attrs:{row:"",wrap:"","justify-space-around":""}},e._l(e.groups,function(t){return a("v-flex",{key:t.id,attrs:{xs12:"",md3:""}},[a("v-card",[a("v-card-media",{staticClass:"black--text",attrs:{height:"200px",src:"http://lorempixel.com/400/200/"}},[a("v-container",{attrs:{"fill-height":"",fluid:""}},[a("v-layout",{attrs:{"fill-height":""}},[a("v-flex",{attrs:{xs12:"","align-end":"",flexbox:""}},[a("span",{staticClass:"headline"},[e._v(e._s(t.title))])])],1)],1)],1),e._v(" "),a("v-card-title",[a("div",[a("span",{staticClass:"grey--text"},[e._v(e._s(e._f("formatDate")(t.startDate))+" à "+e._s(t.location))]),a("br"),e._v(" "),a("p",[e._v(e._s(t.description))]),e._v(" "),t.organizer?a("p",[e._v("Organisé par "),a("router-link",{attrs:{to:{name:"Account",params:{id:t.organizer.id}}}},[e._v(e._s(t.organizer.username))])],1):e._e()])]),e._v(" "),a("v-card-actions",[a("v-btn",{attrs:{flat:"",color:"green"},on:{click:function(a){e.joinGroup(t.id)}}},[t.locked?a("v-icon",[e._v("lock")]):e._e(),e._v("Join")],1),e._v(" "),a("v-btn",{attrs:{flat:"",color:"orange"},on:{click:function(a){e.viewEvent(t.id)}}},[e._v("Explore")]),e._v(" "),a("v-btn",{attrs:{flat:"",color:"red"},on:{click:function(a){e.deleteEvent(t.id)}}},[e._v("Delete")])],1)],1)],1)})),e._v(" "),a("router-link",{staticClass:"btn btn-default",attrs:{to:{name:"CreateGroup"}}},[e._v("Create")])],1)},n=[],o={render:r,staticRenderFns:n};t.a=o},"2L5h":function(e,t,a){"use strict";var r=a("LXbI"),n=a("K1LQ"),o=a("VU/8"),i=o(r.a,n.a,!1,null,null,null);t.a=i.exports},"2dZT":function(e,t,a){"use strict";function r(e){a("1iLV")}var n=a("iXVf"),o=a("G3Wc"),i=a("VU/8"),s=r,l=i(n.a,o.a,!1,s,"data-v-31f0aca4",null);t.a=l.exports},"2hTV":function(e,t,a){"use strict";var r=a("NSHn"),n=a("YJKB"),o=a("VU/8"),i=o(r.a,n.a,!1,null,null,null);t.a=i.exports},"3dKV":function(e,t,a){"use st
|
||
|
//# sourceMappingURL=app.29c4f33994925affb616.js.map
|