(window.webpackJsonp=window.webpackJsonp||[]).push([[23],{512:function(t,e,o){"use strict";var n=o(193),r=o(626),c={name:"TBtn",props:{tooltip:String,color:String,to:String,large:{type:Boolean,default:!1},small:{type:Boolean,default:!1}}},l=o(13),component=Object(l.a)(c,(function(){var t=this,e=t._self._c;return e(r.a,{attrs:{top:""},scopedSlots:t._u([{key:"activator",fn:function(o){var{on:r,attrs:c}=o;return[e(n.a,t._g(t._b({attrs:{to:t.to,large:t.large,small:t.small,text:"",icon:"",color:t.color},on:{click:function(e){return t.$emit("click")}}},"v-btn",c,!1),r),[t._t("default")],2)]}}],null,!0)},[t._v(" "),e("span",[t._v(t._s(t.$t(t.tooltip)))])])}),[],!1,null,null,null);e.a=component.exports},849:function(t,e,o){"use strict";o.r(e);var n=o(194),r=o(27),c=o(497),l=o(840),m=o(190),d=o(625),v=o(102),f=(o(18),o(147),o(5)),h=o(11),_=o(16),$={name:"Settings",middleware:["auth"],components:{TBtn:o(512).a},data(){return{mdiChevronLeft:h.u,mdiChevronRight:h.v,mdiChevronDown:h.t,mdiCheckboxOutline:h.s,mdiCheckboxBlankOutline:h.q,mdiPencil:h.tb,mdiDelete:h.J,mdiArrowRight:h.e,mdiEye:h.O,mdiEyeOff:h.P,mdiRepeat:h.wb,mdiPause:h.sb,mdiPlay:h.ub,mdiDebugStepOver:h.I,mdiDeleteForever:h.K,events:[],search:"",headers:[{value:"title",text:this.$t("common.title")},{value:"place.name",text:this.$t("common.place")},{value:"start_datetime",text:this.$t("common.when")},{value:"actions",text:this.$t("common.actions"),align:"right",sortable:!1}]}},computed:Object(_.d)(["settings"]),fetch(){var t=this;return Object(f.a)((function*(){t.events=yield t.$axios.$get("/events/mine")}))()},methods:{toggle(t){var e=this;return Object(f.a)((function*(){var o=t.id,n=t.is_visible,r=n?"unconfirm":"confirm";try{yield e.$axios.$put("/event/".concat(r,"/").concat(o)),t.is_visible=!n}catch(t){console.error(t)}}))()},remove(t,e){var o=this;return Object(f.a)((function*(){(yield o.$root.$confirm("event.remove_".concat(e?"recurrent_":"","confirmation")))&&(yield o.$axios.delete("/event/".concat(t.id)),o.$fetch(),o.$root.$message("admin.event_remove_ok"))}))()}},head(){return{title:"".concat(this.settings.title," - ").concat(this.$t("common.my_events"))}}},x=o(13),component=Object(x.a)($,(function(){var t=this,e=t._self._c;return e(c.a,{staticClass:"pa-0"},[e(n.a,[e(r.d,[t._v(t._s(t.$t("common.my_events")))]),t._v(" "),e(r.c,{staticClass:"pa-1 pa-md-3"},[e(v.a,{attrs:{label:t.$t("common.search")},model:{value:t.search,callback:function(e){t.search=e},expression:"search"}}),t._v(" "),e(l.a,{attrs:{items:t.events,"hide-default-footer":t.events.length<10,dense:"",search:t.search,"header-props":{sortIcon:t.mdiChevronDown},"footer-props":{prevIcon:t.mdiChevronLeft,nextIcon:t.mdiChevronRight},headers:t.headers},scopedSlots:t._u([{key:"item.data-table-select",fn:function(o){var{isSelected:n,select:select}=o;return[e(d.a,{attrs:{size:"small",small:"",dense:"","on-icon":t.mdiCheckboxOutline,"off-icon":t.mdiCheckboxBlankOutline,value:n},on:{input:function(t){return select(t)}}})]}},{key:"item.start_datetime",fn:function(o){var{item:n}=o;return[n.recurrent?e("span",[e(m.a,{attrs:{color:"success"},domProps:{textContent:t._s(t.mdiRepeat)}}),t._v(" "+t._s(t.$time.recurrentDetail({parent:n},"EEEE, HH:mm")))],1):e("span",[t._v(t._s(t.$time.when(n)))])]}},{key:"item.actions",fn:function(o){var{item:n}=o;return[n.recurrent?[n.is_visible?e("t-btn",{attrs:{color:"info",tooltip:t.$t("common.pause")},on:{click:function(e){return t.toggle(n)}}},[e(m.a,{domProps:{textContent:t._s(t.mdiPause)}})],1):e("t-btn",{attrs:{color:"success",tooltip:t.$t("common.start")},on:{click:function(e){return t.toggle(n)}}},[e(m.a,{domProps:{textContent:t._s(t.mdiPlay)}})],1)]:[n.is_visible?n.parentId?e("t-btn",{attrs:{color:"info",tooltip:t.$t("common.skip")},on:{click:function(e){return t.toggle(n)}}},[e(m.a,{domProps:{textContent:t._s(t.mdiDebugStepOver)}})],1):e("t-btn",{attrs:{color:"info",tooltip:t.$t("common.hide")},on:{click:function(e){return t.toggle(n)}}},[e(m.a,{domProps:{textContent:t._s(t.mdiEyeOff)}})],1):e("t-btn",{attrs:{color:"success",tooltip:t.$t("common.confirm")},on:{click:function(e){return t.toggle(n)}}},[e(m.a,{domProps:{textContent:t._s(t.mdiEye)}})],1),t._v(" "),e("t-btn",{attrs:{to:"/event/".concat(n.slug||n.id),tooltip:t.$t("common.preview")}},[e(m.a,{domProps:{textContent:t._s(t.mdiArrowRight)}})],1)],t._v(" "),e("t-btn",{attrs:{to:"/add/".concat(n.id),color:"yellow",tooltip:t.$t("common.edit")}},[e(m.a,{domProps:{textContent:t._s(t.mdiPencil)}})],1),t._v(" "),e("t-btn",{attrs:{color:"error",tooltip:t.$t("common.delete")},on:{click:function(e){return t.remove(n,n.recurrent)}}},[e(m.a,{domProps:{textContent:t._s(n.recurrent?t.mdiDeleteForever:t.mdiDelete)}})],1)]}}])})],1)],1)],1)}),[],!1,null,null,null);e.default=component.exports}}]);