(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-2e3ab249"],{"8f86":function(t,e,s){},c19f:function(t,e,s){"use strict";s.r(e);var i=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("tr",[s("wi-list-data-table-actions",{attrs:{config:t.config,props:t.props}}),s("td",{staticStyle:{"text-align":"center"}},[s("v-checkbox",{attrs:{disabled:3==t.props.item.status,color:t.props.item.type.color,"hide-details":""},model:{value:t.itemStatus,callback:function(e){t.itemStatus=e},expression:"itemStatus"}})],1),s("td",{staticClass:"text-xs-left",staticStyle:{padding:"0px !important","min-width":"70px"}},[s("strong",[t._v(t._s(t.props.item.description))])]),s("td",{staticClass:"text-xs-left",staticStyle:{padding:"0px !important","min-width":"70px"}},[t.props.item.date_formated?s("v-list",{staticClass:"tasks__date",staticStyle:{"padding-top":"0px","padding-bottom":"0px"},attrs:{dense:"","two-line":""}},[s("v-list-tile",{staticClass:"tasks__list-tile"},[s("v-list-tile-avatar",[s("v-icon",{attrs:{color:"primary",medium:""}},[t._v("date_range")])],1),s("v-list-tile-content",[s("v-list-tile-sub-title",[s("span",[t._v("Em ")]),s("strong",[t._v(t._s(t.props.item.date_formated))]),t.props.item.time_formated?s("strong",[t._v(" às "+t._s(t.props.item.time_formated))]):t._e()]),t.props.item.date_end_formated?s("v-list-tile-sub-title",[s("span",[t._v(" até ")]),t.props.item.date_formated!=t.props.item.date_end_formated?s("strong",[t._v(t._s(t.props.item.date_end_formated))]):t._e(),t.props.item.time_end_formated?s("strong",[t._v(" às "+t._s(t.props.item.time_end_formated))]):t._e()]):t._e()],1)],1)],1):s("v-list",{staticClass:"tasks__date",staticStyle:{"padding-top":"0px","padding-bottom":"0px"},attrs:{dense:"","two-line":""}},[s("v-list-tile",{staticClass:"tasks__list-tile"},[s("v-list-tile-avatar",[s("v-icon",{attrs:{color:"primary",large:""}},[t._v("event_busy")])],1),s("v-list-tile-content",[s("v-list-tile-title",{domProps:{innerHTML:t._s(t.props.item.date_end_formated)}},[t._v(" Não definido ")])],1)],1)],1)],1),s("td",{staticClass:"text-xs-left",staticStyle:{padding:"0 10px !important"}},[t.props.item.person&&t.props.item.person.name?s("span",{domProps:{textContent:t._s(t.props.item.person.name)}}):s("span",[t._v("Não definido")])]),s("td",{staticClass:"text-xs-left",staticStyle:{padding:"0 10px !important"}},[t.props.item.person&&t.props.item.person.name?s("span",{domProps:{textContent:t._s(t.props.item.person.name)}}):s("span",[t._v("Não definido")])]),s("td",{staticClass:"text-xs-left",staticStyle:{padding:"0 10px !important"}},[100!=t.props.item.type.code&&200!=t.props.item.type.code?s("div",[t.props.item.business_id?s("v-btn",{style:{color:t.props.item.type.color},attrs:{outline:"",small:"",block:""},on:{click:function(e){return t.goToBusiness(t.props.item)}}},[s("v-icon",{domProps:{textContent:t._s(t.props.item.type.icon)}}),s("span",[t._v("Ver "),s("span",{domProps:{textContent:t._s(t.props.item.type.title)}})])],1):s("v-btn",{style:{color:t.props.item.type.color},attrs:{outline:"",small:"",block:""},on:{click:function(e){return t.createNewBusiness(t.props.item)}}},[s("v-icon",{domProps:{textContent:t._s(t.props.item.type.icon)}}),s("span",[t._v("Criar "),s("span",{domProps:{textContent:t._s(t.props.item.type.title)}})])],1)],1):t._e()])],1)},o=[],a=(s("b0c0"),s("b150")),p={name:"Tasks",data:function(){return{}},methods:{goToBusiness:function(t){console.log(t),this.$router.push({name:t.type.name,params:{id:t.business_id}})},createNewBusiness:function(t){var e={wiConfig:t.type.name+"-open",data:{task_id:t.id,person_id:t.person_id,person:t.person,date_end:t.date,collaborator_id:t.responsible_id,collaborator:t.responsible}};this.$WiEditDialog(e)}},computed:{itemStatus:{get:function(){var t=this.props.item&&1===this.props.item.status;return t},set:function(t){this.$WiApiPut({uri:"tasks/task",id:this.props.item.id,data:{status:t},callback:function(){}}),this.config.refresh()}}},props:{config:Object,props:Object},components:{WiListDataTableActions:a["a"]}},n=p,r=(s("d2ad"),s("2877")),d=Object(r["a"])(n,i,o,!1,null,"1017218a",null);e["default"]=d.exports},d2ad:function(t,e,s){"use strict";s("8f86")}}]); //# sourceMappingURL=chunk-2e3ab249.41081c4b.js.map