/home/techb158/ileadtechnology.com/SSM/public/js/post/feed
Edit: /home/techb158/ileadtechnology.com/SSM/public/js/post/feed/index.js (10516B)
(window.webpackJsonp=window.webpackJsonp||[]).push([[288],{"5+DK":function(t,e,a){var i=a("D395");"string"==typeof i&&(i=[[t.i,i,""]]);var r={hmr:!0,transform:void 0,insertInto:void 0};a("aET+")(i,r);i.locals&&(t.exports=i.locals)},"5R7Q":function(t,e,a){"use strict";var i=a("5+DK");a.n(i).a},D395:function(t,e,a){(t.exports=a("I1BE")(!1)).push([t.i,".card.article-card[data-v-65e907cc] {\n opacity: 0.9;\n transition: all 0.3s ease-in-out;\n cursor: pointer;\n}\n.card.article-card header[data-v-65e907cc] {\n margin-bottom: 0.75rem;\n padding-bottom: 0.75rem;\n border-bottom: 1px dotted #f1f2f3;\n}\n.card.article-card header .h5[data-v-65e907cc] {\n margin-bottom: 0.75rem;\n display: block;\n}\n.card.article-card header .article-meta small + small[data-v-65e907cc] {\n margin-left: 0.5rem;\n}\n.card.article-card .article-content[data-v-65e907cc] {\n font-size: 95%;\n margin-bottom: 1rem;\n}\n.card.article-card footer[data-v-65e907cc] {\n margin-top: 0.75rem;\n padding-top: 0.75rem;\n border-top: 1px dotted #f1f2f3;\n}\n.card.article-card footer .article-author .author-thumb[data-v-65e907cc] {\n float: left;\n width: 50px;\n height: 50px;\n border-radius: 50%;\n background: #f1f2f3;\n margin-right: 10px;\n text-align: center;\n}\n.card.article-card footer .article-author .author-thumb i[data-v-65e907cc] {\n padding-top: 15px;\n}\n.card.article-card footer .article-author .author-thumb img[data-v-65e907cc] {\n width: 100%;\n}\n.card.article-card footer .article-author p[data-v-65e907cc] {\n margin-bottom: 0;\n}\n.card.article-card footer .article-author p span[data-v-65e907cc] {\n display: block;\n}\n.card.article-card footer .article-author p span.author[data-v-65e907cc] {\n font-weight: 500;\n}\n.card.article-card footer .cta[data-v-65e907cc] {\n display: flex;\n justify-content: flex-end;\n align-items: flex-end;\n height: 50px;\n}",""])},mzTo:function(t,e,a){"use strict";a.r(e);var i=a("rath"),r=a("vhbx"),s={components:{ArticleDetail:i.a,ArticleCard:r.a},data:function(){return{articles:{total:0,data:[]},filter:{sort_by:"date_of_article",order:"desc",keyword:"",article_type_id:[],date_of_article_start_date:"",date_of_article_end_date:"",page_length:helper.getConfig("page_length")},orderByOptions:[{value:"date_of_article",translation:i18n.post.date_of_article},{value:"title",translation:i18n.post.article_title}],article_types:[],selected_article_types:null,help_topic:"",showUuid:"",showModal:!1}},mounted:function(){helper.hasPermission("list-article")||(helper.notAccessibleMsg(),this.$router.push("/dashboard")),this.getArticles()},methods:{hasPermission:function(t){return helper.hasPermission(t)},showArticle:function(t){this.showUuid=t.uuid,this.showModal=!0},getArticles:function(t){var e=this,a=this.$loading.show();"number"!=typeof t&&(t=1),this.filter.date_of_article_start_date=helper.toDate(this.filter.date_of_article_start_date),this.filter.date_of_end_start_date=helper.toDate(this.filter.date_of_end_start_date);var i=helper.getFilterURL(this.filter);axios.get("/api/article?page="+t+i).then((function(t){e.articles=t.articles,e.article_types=t.filters.article_types,a.hide()})).catch((function(t){a.hide(),helper.showErrorMsg(t)}))},getConfig:function(t){return helper.getConfig(t)},onArticleTypeSelect:function(t){this.filter.article_type_id.push(t.id)},onArticleTypeRemove:function(t){this.filter.article_type_id.splice(this.filter.article_type_id.indexOf(t.id),1)}},filters:{moment:function(t){return helper.formatDate(t)},momentDateTime:function(t){return helper.formatDateTime(t)}},watch:{"filter.sort_by":function(t){this.getArticles()},"filter.order":function(t){this.getArticles()},"filter.page_length":function(t){this.getArticles()}},computed:{authToken:function(){return helper.getAuthToken()}}},n=a("KHd+"),l=Object(n.a)(s,(function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("div",[a("div",{staticClass:"page-titles"},[a("div",{staticClass:"row"},[a("div",{staticClass:"col-12 col-sm-6"},[a("h3",{staticClass:"text-themecolor"},[t._v(t._s(t.trans("post.feed"))+" \n "),t.articles.total?a("span",{staticClass:"card-subtitle d-none d-sm-inline"},[t._v(t._s(t.trans("general.total_result_found",{count:t.articles.total,from:t.articles.from,to:t.articles.to})))]):a("span",{staticClass:"card-subtitle d-none d-sm-inline"},[t._v(t._s(t.trans("general.no_result_found")))])])])])]),t._v(" "),a("div",{staticClass:"container-fluid container-body"},[t.articles.total?a("div",{staticClass:"article-feed card-columns"},t._l(t.articles.data,(function(e){return a("div",{staticClass:"article-item",on:{click:function(a){return t.showArticle(e)}}},[a("article-card",{attrs:{article:e}})],1)})),0):t._e(),t._v(" "),a("pagination-record",{attrs:{"page-length":t.filter.page_length,records:t.articles},on:{"update:pageLength":function(e){return t.$set(t.filter,"page_length",e)},"update:page-length":function(e){return t.$set(t.filter,"page_length",e)},updateRecords:t.getArticles}})],1),t._v(" "),t.showModal?a("article-detail",{attrs:{uuid:t.showUuid},on:{close:function(e){t.showModal=!1}}}):t._e(),t._v(" "),a("right-panel",{attrs:{topic:t.help_topic}})],1)}),[],!1,null,null,null);e.default=l.exports},rath:function(t,e,a){"use strict";var i={components:{},props:["uuid","url"],mounted:function(){this.uuid&&this.get()},data:function(){return{article:[],attachments:[]}},methods:{get:function(){var t=this,e=this.$loading.show(),a=this.url?"/api"+this.url:"/api/article/"+this.uuid;axios.get(a).then((function(a){t.article=a.article,t.attachments=a.attachments,e.hide()})).catch((function(t){e.hide(),helper.showErrorMsg(t)}))},getEmployeeName:function(t){return helper.getEmployeeName(t)},getEmployeeDesignation:function(t,e){return helper.getEmployeeDesignation(t,e)}},computed:{authToken:function(){return helper.getAuthToken()}},filters:{momentDateTime:function(t){return helper.formatDateTime(t)},moment:function(t){return helper.formatDate(t)}}},r=a("KHd+"),s=Object(r.a)(i,(function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("transition",{attrs:{name:"modal"}},[a("div",{staticClass:"modal-mask"},[a("div",{staticClass:"modal-wrapper"},[a("div",{staticClass:"modal-container modal-lg"},[t.article.id?a("div",{staticClass:"modal-header"},[t._t("header",[a("span",[t._v(t._s(t.article.title)+" "),t.article.is_public?a("span",{staticClass:"label label-success"},[t._v(t._s(t.trans("post.article_public")))]):t._e()]),t._v(" "),a("span",{staticClass:"float-right pointer",on:{click:function(e){return t.$emit("close")}}},[t._v("x")])])],2):t._e(),t._v(" "),t.article.id?a("div",{staticClass:"modal-body"},[t._t("body",[a("h6",{staticClass:"card-title"},[t._v("\n "+t._s(t.trans("post.date_of_article"))+": "+t._s(t._f("moment")(t.article.date_of_article))+" \n "),t.article.user?a("p",{staticClass:"pull-right"},[a("strong",[t._v(t._s(t.trans("post.article_posted_by"))+":")]),t._v(" "+t._s(t.getEmployeeName(t.article.user.employee))+" "+t._s(t.getEmployeeDesignation(t.article.user.employee,t.article.date_of_article))+"\n ")]):t._e()]),t._v(" "),a("div",{staticClass:"m-t-20 html-view",domProps:{innerHTML:t._s(t.article.description)}}),t._v(" "),t.attachments.length?a("div",[a("ul",{staticClass:"m-t-10 upload-file-list"},t._l(t.attachments,(function(e){return a("li",{staticClass:"upload-file-list-item"},[a("a",{staticClass:"no-link-color",attrs:{href:"/post/article/"+t.article.uuid+"/attachment/"+e.uuid+"/download?token="+t.authToken}},[a("i",{class:["file-icon","fas","fa-lg",e.file_info.icon]}),t._v(" "),a("span",{staticClass:"upload-file-list-item-size"},[t._v(t._s(e.file_info.size))]),t._v(" "+t._s(e.user_filename))])])})),0)]):t._e(),t._v(" "),a("hr"),t._v(" "),a("p",[a("i",{staticClass:"far fa-clock"}),t._v(" "),a("small",[t._v(t._s(t.trans("general.created_at"))+" "+t._s(t._f("momentDateTime")(t.article.created_at)))]),t._v(" "),a("span",{staticClass:"pull-right"},[a("i",{staticClass:"far fa-clock"}),t._v(" "),a("small",[t._v(t._s(t.trans("general.updated_at"))+" "+t._s(t._f("momentDateTime")(t.article.updated_at)))])])])])],2):t._e()])])])])}),[],!1,null,null,null);e.a=s.exports},vhbx:function(t,e,a){"use strict";var i={props:{article:{type:Object,default:function(){return{}}},bodyClass:String},components:{},data:function(){return{}},methods:{getEmployeePhoto:function(t){return"/"+t.photo},getEmployeeName:function(t){return helper.getEmployeeName(t)},getEmployeeDesignationOnly:function(t){return helper.getEmployeeDesignationOnly(t)},getExcerpts:function(t){return helper.getExcerpts(t)},truncateWords:function(t,e,a){return helper.truncateWords(t,e,a)}},filters:{momentDateTime:function(t){return helper.formatDateTime(t)},moment:function(t){return helper.formatDate(t)},momentTime:function(t){return helper.formatTime(t)}}},r=(a("5R7Q"),a("KHd+")),s=Object(r.a)(i,(function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("article",{staticClass:"card card-box with-shadow article-card"},[a("div",{staticClass:"card-body"},[a("header",[a("h5",{staticClass:"h5 card-title"},[t._v(t._s(t.article.title))]),t._v(" "),a("div",{staticClass:"article-meta"},[a("small",{staticClass:"type text-muted"},[a("i",{staticClass:"fas fa-hashtag"}),t._v(" "+t._s(t.article.article_type.name))]),t._v(" "),a("small",{staticClass:"date text-muted"},[a("i",{staticClass:"far fa-clock"}),t._v(" "+t._s(t._f("moment")(t.article.date_of_article)))])])]),t._v(" "),a("div",{staticClass:"article-content"},[a("p",{staticClass:"card-text",domProps:{innerHTML:t._s(t.article.excerpt)}})]),t._v(" "),a("footer",[a("div",{staticClass:"row"},[a("div",{staticClass:"col-8"},[a("div",{staticClass:"article-author"},[a("span",{staticClass:"author-thumb pull-left"},[t.article.user.employee.photo?[a("img",{staticClass:"img-circle",attrs:{src:t.getEmployeePhoto(t.article.user.employee)}})]:[a("i",{staticClass:"fas fa-user"})]],2),t._v(" "),a("p",[a("span",{staticClass:"author"},[t._v(t._s(t.getEmployeeName(t.article.user.employee)))]),t._v(" "),a("span",{staticClass:"designation small text-muted"},[t._v(t._s(t.getEmployeeDesignationOnly(t.article.user.employee)))])])])]),t._v(" "),a("div",{staticClass:"col-4"},[a("div",{staticClass:"cta text-right"},[a("button",{staticClass:"btn btn-info",attrs:{type:"button"}},[t._v(t._s(t.trans("general.read_more")))])])])])])])])}),[],!1,null,"65e907cc",null);e.a=s.exports}}]);
//# sourceMappingURL=index.js.map?id=167013ddad66e5d409a1