chunk-e8b59212.2962af07.js 16 KB

123456
  1. /*!
  2. * build: Hopaheal
  3. * copyright: Mead
  4. * time: 2022-6-7 11:38:49
  5. */
  6. (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-e8b59212"],{"1e68":function(e,t,n){},"6a1d":function(e,t,n){"use strict";n.r(t),n.d(t,"getList",(function(){return a})),n.d(t,"getContent",(function(){return s})),n.d(t,"good",(function(){return r})),n.d(t,"getSign",(function(){return o})),n.d(t,"sign_up",(function(){return u})),n.d(t,"del_sign_up",(function(){return c})),n.d(t,"getPinglun",(function(){return l})),n.d(t,"save_pinglun",(function(){return d})),n.d(t,"delete_ping",(function(){return g}));var i=n("b775");function a(e){return Object(i["default"])({url:"/inform/category-tree",method:"get",params:e})}function s(e){return Object(i["default"])({url:"/inform/information",method:"get",params:e})}function r(e){return Object(i["default"])({url:"/inform/information-good",method:"post",params:e})}function o(e){return Object(i["default"])({url:"/inform/information-activity",method:"get",params:e})}function u(e){return Object(i["default"])({url:"/inform/information-sign-up",method:"post",params:e})}function c(e){return Object(i["default"])({url:"/inform/information-cancel-sign-up",method:"post",params:e})}function l(e){return Object(i["default"])({url:"/inform/comment",method:"get",params:e})}function d(e){return Object(i["default"])({url:"/inform/comment",method:"post",params:e})}function g(e){return Object(i["default"])({url:"/inform/comment/"+e,method:"delete"})}},"7ee9":function(e,t,n){"use strict";n("1e68")},"8a70":function(e,t,n){"use strict";n.r(t),n.d(t,"getLists",(function(){return a})),n.d(t,"getNotice",(function(){return s})),n.d(t,"doAdd",(function(){return r})),n.d(t,"doEdit",(function(){return o})),n.d(t,"getDetail",(function(){return u})),n.d(t,"doDelete",(function(){return c})),n.d(t,"doDeletes",(function(){return l})),n.d(t,"getRead",(function(){return d})),n.d(t,"getMessage",(function(){return g})),n.d(t,"clearRead",(function(){return m})),n.d(t,"checktOrder",(function(){return p}));var i=n("b775");function a(e){return Object(i["default"])({url:"/inform/information",method:"get",params:e})}function s(e){return Object(i["default"])({url:"/inform/information-user-messages",method:"get",params:e})}function r(e){return Object(i["default"])({url:"/inform/information",method:"post",data:e})}function o(e){return Object(i["default"])({url:"/inform/information/"+e.id,method:"put",data:e})}function u(e){return Object(i["default"])({url:"/inform/information/"+e,method:"get"})}function c(e){return Object(i["default"])({url:"/inform/information/"+e.ids,method:"delete"})}function l(e){return Object(i["default"])({url:"/inform/information/delete",method:"post",data:e})}function d(e){return Object(i["default"])({url:"/inform/information-user-messages",method:"get",params:e})}function g(e){return Object(i["default"])({url:"/inform/information-read-messages",method:"post",data:e})}function m(e){return Object(i["default"])({url:"/inform/information-read-messages",method:"post",data:e})}function p(e){return Object(i["default"])({url:"/inform/information-check",method:"post",data:e})}},9768:function(e,t,n){"use strict";n.r(t);var i=function(){var e=this,t=e.$createElement,i=e._self._c||t;return i("div",{staticClass:"container"},[i("el-card",{directives:[{name:"loading",rawName:"v-loading.fullscreen.lock",value:e.fullscreenLoading,expression:"fullscreenLoading",modifiers:{fullscreen:!0,lock:!0}}],staticClass:"card"},[i("el-page-header",{staticClass:"goback",attrs:{content:"资讯详情"},on:{back:e.goBack}}),1!=e.detail.category_id?i("div",[3!=e.role_id||e.detail.sign_up_count!=e.detail.max_sign_up_count||e.detail.is_me_sign_up||2===e.sigin_status?e._e():i("div",{staticClass:"sign_up"},[e._v(" 名额已满 ")]),3!=e.role_id||e.detail.sign_up_count===e.detail.max_sign_up_count||e.detail.is_me_sign_up||1!=e.sigin_status?e._e():i("div",{staticClass:"sign_up",on:{click:e.sign_up}},[e._v(" 立即报名 ")]),3==e.role_id&&e.detail.is_me_sign_up&&1==e.sigin_status?i("div",{staticClass:"sign_up",on:{click:e.del_sign_up}},[e._v(" 取消报名 ")]):e._e(),1==e.role_id||2==e.role_id&&e.detail.admin_id==e.user_id?i("div",{staticClass:"sign_up_info",on:{click:e.sign_up_info}},[e._v(" 查看报名信息 ")]):e._e()]):e._e(),i("div",{staticClass:"title"},[e._v(e._s(e.detail.title))]),i("div",{staticClass:"title_f"},[i("div",{staticClass:"wrap"},[i("div",{staticClass:"depart"},[e._v("来源:"+e._s(e.detail.category_name))]),i("div",{staticClass:"time"},[i("span",[e._v("发布时间:")]),i("span",[e._v(e._s(e.detail.published_at))])]),i("div",{staticClass:"count"},[i("span",[e._v("阅读:")]),i("span",[e._v(e._s(e.detail.view_count))])]),i("div",{staticClass:"good",on:{click:function(t){return e.checked(e.detail.id)}}},[i("vab-icon",{attrs:{icon:"thumb-up-fill"}}),i("span",[e._v(e._s(e.detail.good_count))])],1),i("div",{staticClass:"tags"},[i("span",[e._v("标签:")]),e._l(e.detail.tags,(function(t,n){return i("div",{key:n,staticClass:"tag_wrap"},[i("div",{staticClass:"tag"},[e._v(e._s(t))]),n!=e.detail.tags.length-1?i("i"):e._e()])}))],2),i("div",{staticClass:"count"},[i("span",[e._v("作者:")]),i("span",[e._v(e._s(e.detail.admin_name))])]),i("div",{staticClass:"time"},[i("span",[e._v("报名时间:")]),i("span",[1==e.sigin_status?i("el-tag",{attrs:{type:"warning"}},[e._v(" "+e._s(e.sigin_text)+" ")]):e._e(),0==e.sigin_status?i("el-tag",[e._v(" "+e._s(e.sigin_text)+" ")]):e._e(),2==e.sigin_status?i("el-tag",{attrs:{type:"info"}},[e._v(" "+e._s(e.sigin_text)+" ")]):e._e()],1)])])]),i("div",{staticClass:"body"},[i("div",{domProps:{innerHTML:e._s(e.detail.body)}})]),e.img_sign_list.length>0?i("div",{staticClass:"stu_wrap"},[i("div",{staticClass:"tags"},[e._v("都有这些人报名了!")]),i("div",{staticClass:"stu_list_wrap"},e._l(e.img_sign_list,(function(e,t){return i("div",{key:t,staticClass:"header"},[i("img",{attrs:{alt:"",src:e.student.headimg}})])})),0)]):e._e()],1),1==e.role_id||e.detail.is_me_sign_up?i("div",{staticClass:"pinglun_wrap"},[i("div",{staticClass:"pingjia"},[i("h3",[e._v("评论")]),i("div",{staticClass:"item_wrap"},[0==e.pinglun.length?i("el-empty",{attrs:{description:"暂无评论哦~"}}):e._e(),e._l(e.pinglun,(function(t,n){return i("div",{key:n,staticClass:"pingjia_item"},[i("div",{staticClass:"item"},[i("div",{staticClass:"left"},[i("img",{attrs:{alt:"",src:t.user?t.user.headimg:"../../assets/index/course.jpg"}})]),i("div",{staticClass:"right"},[i("div",{staticClass:"ping_title"},[i("div",[i("span",{staticClass:"ping_name"},[e._v(" "+e._s(t.user?t.user.name:"--")+" ")])]),i("div",{staticClass:"ping_time"},[i("div",[e._v("发表于 "+e._s(t.created_at.split(" ")[0]))])])]),i("div",{staticClass:"ping_content"},[e._v(e._s(t.body))]),1==e.role_id?i("div",{staticClass:"shanchu",on:{click:function(n){return e.sure_delete(t.id)}}},[e._v(" 删除 ")]):e._e()])])])})),0!=e.pinglun.length?i("el-pagination",{attrs:{background:"","current-page":e.queryForm_ping.page,layout:e.layout,"page-size":e.queryForm_ping.per_page,"page-sizes":[15,20,30,40,50,100],total:e.queryForm_ping.total},on:{"current-change":e.handleCurrentChange_ping,"size-change":e.handleSizeChange_ping}}):e._e()],2)]),3==e.role_id?i("div",{staticClass:"send_pingjia"},[i("div",{staticClass:"pingjia_title"},[e._v("我要评论")]),i("div",{staticClass:"send_content"},[i("textarea",{directives:[{name:"model",rawName:"v-model",value:e.content,expression:"content"}],attrs:{id:"",cols:"30",name:"",rows:"10"},domProps:{value:e.content},on:{input:function(t){t.target.composing||(e.content=t.target.value)}}})]),i("div",{staticClass:"btns"},[i("div",{staticClass:"save",on:{click:e.save_pinglun}},[e._v("保存")])])]):e._e()]):e._e(),i("el-dialog",{attrs:{"close-on-click-modal":!1,title:"报名详情",visible:e.list_flag,width:"800px"},on:{"update:visible":function(t){e.list_flag=t},close:e.close}},[i("vab-query-form",[i("vab-query-form-left-panel",{attrs:{span:8}},[i("el-button",{attrs:{icon:"el-icon-download",type:"warning"},on:{click:e.chooseterm}},[e._v(" 批量导出 ")])],1)],1),i("el-table",{directives:[{name:"loading",rawName:"v-loading",value:e.listLoading,expression:"listLoading"}],attrs:{border:"",data:e.sign_list},scopedSlots:e._u([{key:"empty",fn:function(){return[i("el-image",{staticClass:"vab-data-empty",attrs:{src:n("f1f0")}})]},proxy:!0}])},[i("el-table-column",{attrs:{align:"center",label:"序号",sortable:"",type:"index",width:"60"}}),i("el-table-column",{attrs:{align:"center",label:"头像"},scopedSlots:e._u([{key:"default",fn:function(t){var n=t.row;return[i("el-image",{attrs:{"preview-src-list":e.imageList,src:n.student.headimg}})]}}])}),i("el-table-column",{attrs:{align:"center",label:"学号","min-width":"130",prop:"account","show-overflow-tooltip":""}}),i("el-table-column",{attrs:{align:"center",label:"姓名","min-width":"130",prop:"name","show-overflow-tooltip":""}}),i("el-table-column",{attrs:{align:"center",label:"手机号",prop:"mobile","show-overflow-tooltip":""}})],1),i("el-pagination",{attrs:{background:"","current-page":e.queryForm.page,layout:e.layout,"page-size":e.queryForm.per_page,"page-sizes":[15,20,30,40,50,100],total:e.queryForm.total},on:{"current-change":e.handleCurrentChange,"size-change":e.handleSizeChange}})],1)],1)},a=[],s=n("1da1"),r=n("5530"),o=(n("ac1f"),n("466d"),n("d3b7"),n("3ca3"),n("ddb0"),n("2b3d"),n("9861"),n("96cf"),n("2f62")),u=n("9f2e"),c=n("8a70"),l=n("6a1d"),d=n("bc3a"),g=n.n(d),m=n("f121"),p={data:function(){return{sigin_text:"",sigin_status:"",id:"",detail:{cover_resource:{url:""}},check:!1,fullscreenLoading:!1,sign_list:[],list_flag:!1,layout:"total, sizes, prev, pager, next, jumper",queryForm:{page:1,per_page:15,total:0},queryForm_ping:{page:1,per_page:15,total:0},listLoading:!1,imageList:[],img_sign_list:[],pinglun:[],content:""}},computed:Object(r["a"])({},Object(o["c"])({role_id:"user/role_id",type_id:"user/type_id",user_id:"user/user_id",token:"user/token",is_test:"user/is_test"})),created:function(){var e=this.$route;this.id=e.query.id,console.log(e.query.id,"idididii"),this.fullscreenLoading=!0,this.getDetail(),this.getSign(),this.getPinglun()},methods:Object(r["a"])(Object(r["a"])({getDetail:function(){var e=this;return Object(s["a"])(regeneratorRuntime.mark((function t(){var n,i,a,s,r,o;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.next=2,Object(c["getDetail"])(e.id);case 2:n=t.sent,i=n.data,e.fullscreenLoading=!1,console.log(i,"公告详情"),e.detail=i,i.activity&&(e.img_sign_list=i.activity),e.detail.list&&(a=e.detail.list,s=new Date(a.star_time).getTime(),r=new Date(a.end_time).getTime(),o=Date.now(),o<s&&(e.sigin_text="报名暂未开始",e.sigin_status=0),s<=o&&o<=r&&(e.sigin_text="报名进行中",e.sigin_status=1),r<o&&(e.sigin_text="报名已结束",e.sigin_status=2));case 9:case"end":return t.stop()}}),t)})))()}},Object(o["b"])({delVisitedRoute:"tabs/delVisitedRoute"})),{},{goBack:function(){this.delVisitedRoute(Object(u["handleActivePath"])(this.$route,!0)),this.$router.go(-1)},checked:function(e){var t=this;return Object(s["a"])(regeneratorRuntime.mark((function n(){return regeneratorRuntime.wrap((function(n){while(1)switch(n.prev=n.next){case 0:if(t.is_test){n.next=7;break}return t.check=!0,n.next=4,t.good({id:e});case 4:t.getDetail(),n.next=8;break;case 7:t.$message.warning("游客模式,暂无权限!");case 8:case"end":return n.stop()}}),n)})))()},good:function(e){return Object(s["a"])(regeneratorRuntime.mark((function t(){return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.next=2,Object(l["good"])(e);case 2:case"end":return t.stop()}}),t)})))()},getSign:function(){var e=this;return Object(s["a"])(regeneratorRuntime.mark((function t(){var n,i;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return e.queryForm.information_id=e.id,t.next=3,Object(l["getSign"])(e.queryForm);case 3:n=t.sent,i=n.data,e.fullscreenLoading=!1,console.log(i,"报名信息"),e.sign_list=i.list,e.queryForm.total=i.meta.pagination.total;case 9:case"end":return t.stop()}}),t)})))()},sign_up:function(){var e=this;return Object(s["a"])(regeneratorRuntime.mark((function t(){var n,i,a;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:if(e.is_test){t.next=11;break}return n={student_id:e.type_id,information_id:e.id},console.log(n,"baoming"),t.next=5,Object(l["sign_up"])(n);case 5:i=t.sent,a=i.message,e.$baseMessage(a,"success",!1,"vab-hey-message-success"),e.getDetail(),t.next=12;break;case 11:e.$message.warning("游客模式,暂无权限!");case 12:case"end":return t.stop()}}),t)})))()},del_sign_up:function(){var e=this;return Object(s["a"])(regeneratorRuntime.mark((function t(){var n;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:e.is_test?e.$message.warning("游客模式,暂无权限!"):(n={student_id:e.type_id,information_id:e.id},e.$baseConfirm("你确定要取消报名吗",null,Object(s["a"])(regeneratorRuntime.mark((function t(){var i,a;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.next=2,Object(l["del_sign_up"])(n);case 2:return i=t.sent,a=i.message,e.$baseMessage(a,"success",!1,"vab-hey-message-success"),e.content="",t.next=8,e.getDetail();case 8:case"end":return t.stop()}}),t)})))));case 1:case"end":return t.stop()}}),t)})))()},sign_up_info:function(){this.list_flag=!0},getPinglun:function(){var e=this;return Object(s["a"])(regeneratorRuntime.mark((function t(){var n,i,a,s;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return e.queryForm_ping.information_id=e.id,t.next=3,Object(l["getPinglun"])(e.queryForm_ping);case 3:n=t.sent,i=n.data,console.log(i,"pingjia "),a=i.list,s=i.meta,e.queryForm_ping.total=s.pagination.total,e.pinglun=a;case 9:case"end":return t.stop()}}),t)})))()},save_pinglun:function(){var e=this;return Object(s["a"])(regeneratorRuntime.mark((function t(){var n,i,a;return regeneratorRuntime.wrap((function(t){while(1)switch(t.prev=t.next){case 0:if(e.is_test){t.next=14;break}if(e.content){t.next=4;break}return e.$message({message:"请输入评论内容",type:"warning"}),t.abrupt("return");case 4:return n={information_id:e.id,body:e.content},t.next=7,Object(l["save_pinglun"])(n);case 7:i=t.sent,a=i.message,e.$message({message:a,type:"success"}),e.getPinglun(),e.content="",t.next=15;break;case 14:e.$message.warning("游客模式,暂无权限!");case 15:case"end":return t.stop()}}),t)})))()},sure_delete:function(e){var t=this;this.$confirm("是否删除该评论?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then((function(){t.delete_ping(e)})).catch((function(){t.$message({type:"info",message:"已取消删除"})}))},delete_ping:function(e){var t=this;return Object(s["a"])(regeneratorRuntime.mark((function n(){var i,a;return regeneratorRuntime.wrap((function(n){while(1)switch(n.prev=n.next){case 0:return console.log(e,"delete"),n.next=3,Object(l["delete_ping"])(e);case 3:i=n.sent,a=i.message,t.$message({message:a,type:"success"}),t.getPinglun();case 7:case"end":return n.stop()}}),n)})))()},handleSizeChange:function(e){this.queryForm.per_page=e,this.getSign()},handleCurrentChange:function(e){this.queryForm.page=e,this.getSign()},handleSizeChange_ping:function(e){this.queryForm_ping.per_page=e,this.getPinglun()},handleCurrentChange_ping:function(e){this.queryForm_ping.page=e,this.getPinglun()},close:function(e){var t=this;this.$nextTick((function(){void 0!==t.$refs[e]&&t.$refs[e].resetFields()})),this.form=this.$options.data().form,this.fileList=[],this.addFlag=!1},chooseterm:function(){this.download(this.term)},download:function(e){var t=this;console.log(e,"test"),g()({baseURL:m["baseURL"],timeout:5e3,method:"get",url:"/inform/information-activity-export",headers:{Authorization:"Bearer ".concat(this.token)},params:{information_id:this.id},responseType:"blob"}).then((function(e){t.convertRes2Blob(e),t.portFlag=!1}))},convertRes2Blob:function(e){var t=e.headers["content-disposition"].match(/filename=(.*)(.*)/);console.log(t,"Mead");var n=t[1],i=new Blob([e.data],{type:"application/vnd.ms-excel"});if("undefined"!==typeof window.navigator.msSaveBlob)window.navigator.msSaveBlob(i,decodeURI(n));else{var a=window.URL.createObjectURL(i),s=document.createElement("a");s.style.display="none",s.href=a,s.setAttribute("download",decodeURI(n)),"undefined"===typeof s.download&&s.setAttribute("target","_blank"),document.body.appendChild(s),s.click(),document.body.removeChild(s),window.URL.revokeObjectURL(a)}}})},_=p,f=(n("7ee9"),n("2877")),v=Object(f["a"])(_,i,a,!1,null,"0141bc1a",null);t["default"]=v.exports},f1f0:function(e,t,n){e.exports=n.p+"static/img/data_empty.475a2a1e.png"}}]);