chunk-03250031.5db8bcf8.js 18 KB

12
  1. (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-03250031"],{"0bce":function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAYAAACNiR0NAAAAAXNSR0IArs4c6QAAAWhJREFUOE+t1D1Lw1AUxvH/SatNXFzq4gs6iYOizi5K0VlrKuLiIPgRxK8g4gfQQQS7JVVxLg4Ojgq+IKUIDk7O2jaW5koV6Ytp04bc8dzz/Ljk3Fwh5CUdeUk1jFaYQUVyZPR8u4w/aDopcNNAL1BGxMTSL1uh7cF5FSXuvIIaqgNusI25YKBZTADZhrDikYwxFQxcLR0iarsxrM6x+5LdgyvOJBH3FuhpDGu72LG9zsCUihAlTvlrAdwDYPBfUGSJj9j1T30ElyMp1/fUhrLmLOO6J0B/R1fpt0mh5A6NDSw9Vy3UQLP0DGqiC6zWKmSxjMUmsPgODAQCIY9tjIcJHmMbW+GBQgLLuAoLfMPWR0HccECRfSx95+/b1005yFBEITKNFXvwAu+Blv+o5/RFbCw95X2xzUIKtDSo6jPltxSiztCNTU7l0xusVteLY1S0WVQl2lIUzaHMExf6i1eP/wPrd9am/W8VUGkVx2Ud3QAAAABJRU5ErkJggg=="},1789:function(t,e,i){},"1d57":function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABMAAAASCAYAAAC5DOVpAAAAAXNSR0IArs4c6QAAAiBJREFUOE+tlD+IU0EQxmfCSxEVsTBYiIIWehdNYmb3GYKNxXnmtBDBP3CnWFhbiIVwjRwndiKiINhYiAo2CvaCImrIm415XKKVViIWUUQkIe+5I++4hJjkYoTbapnd7zff8u0uwhoOXEMW/AuGRHQKEbcCwCNm/jKq+UiYUmoBAIoiUkHE6SAI0r7v/1oNuCrMdd2d1tqS4zh7S6XSV631fRH5yMxX/humlHosIu+MMdciseu626y1JgzDfdVq9fMw4FBnWusDIvKg0WhMJJPJEyKS9jzvslJqEQC2M/O5cWGolHoLADeZ+aHW+raIHGXmHalUakMikfggIseMMdwPHHBGRHOIeIGZCwAgRHQVEY8wM0VirfV5a+1ZY8zBkbBCoZBot9vvY7HYbLlcfr0ivigiRWY+vCKOEZEBgAVjzJNe4F/OiGgeEbPMfLqziYjOIOIMM891aq7rTllr7zSbzT31er3dqXdh+Xx+SxiGS0EQ7Pd9/1MPbBIRdzPz014XSqlniPjc87wbAzCl1F1E/B6l1ieaBoA0M1/vq08AwItWqzVZq9W+RWvLzrLZ7C7HcV4CQOTgR58oum8zxphNAPC7d42IbiHiT2ae78KUUicBYJaZj/cnlMlk1sfj8Y3D3iURFQHgkjHmUC9sMwBECb2KOo3zk4hIdKopEVk0xtzrwqJJLpdLImIU/7pxYNEdFJGlSqXyZiCAMQEjt/0B9AbqE+QaypcAAAAASUVORK5CYII="},"37d2":function(t,e,i){"use strict";i("f243")},"39a6":function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAAXNSR0IArs4c6QAAAXNJREFUOE/tk7FLAnEUx7/vNCG8Ky2iQmiJllPENRpyqT8gcCsQPAgamoMSCWoInBoi5BBxi4L+grAlmgIpvAoqCKIp0vBUkvP3ohPFSERo7c3f9+H7vnwf4Y9Drf1QlD31gdoKGg0VgNSVK0EAuHVZVjaf8Za+NTYgFC166k7nJQHvDJwz28JfQ2SD5wCMuyx5Np+hkg1QtfI6QEv4eF40jv31XlepkYKLlakcSTgydGXfBvi18gFDKhq6e7OfSFStskuAt6C715oOYuVDIumtoLu3+gH4tfIOC4wZaWX1H9DKQKskAJ4xdHm5rxBjZpaJHg3dvW2HGNDMoGA+A2hPsLiQ2PmjSKIx+GDWXqpD8miQJTFP4I0GUfhel6/bVQ5o5oJgTgDkA7izyiMEOmWCH8yTAJ6IES+klVy7yp221Qi76hPNig9/wlGzzCsQfAQkiw45+Zqiaqe+7aDr7WF2qtNmXDjo5C4l33T9j35C66X5AukQrxH9T2YDAAAAAElFTkSuQmCC"},"4b8d":function(t,e,i){},"7bc2":function(t,e,i){"use strict";i("1789")},"89b0":function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAAXNSR0IArs4c6QAAAVNJREFUOE/tkjFLA0EQhd/siqSLCiKS2uYECZdtxMJr9AdYay1YWAsaRNBCsLIQ63SC4C+Q2IjNzhEUkkb9BaJCIISD25E9kiNgCAe2Dkz35puZxyP8sWg4X61WZ7TWOwACIlLjuCLiAHTSNG20Wq1vr8kAg+EnEflUSj0MhL8YHuycWyOihTRNVz0kA9RqtX0R2er3+5vtdjuZ9FUQBNOlUqlJRDfMfDkEXBHRl7X2sIglxpgzEZll5r0MEIbhNYCPOI6PigDCMDxVSs1ba3f/AQMPjDHHIrLEzNtFTDTGNAC8WWtPhiauENE9gHPn3KNSyicuL631q9a6lySJ16075w4ARHEcP+dRNsZsiIi/pDIaZRGZU0rdicgygEUA7wDqzNzMozy6zSctSZIMXC6XNQAGUAFw4ZuZe6P6/IJxv0dRNNXtdusAbpn5ZZxmIqCIoT9b+60Rgd15VwAAAABJRU5ErkJggg=="},"9c39":function(t,e,i){},"9e12":function(t,e,i){},a3be:function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAASCAYAAABWzo5XAAAAAXNSR0IArs4c6QAAAaZJREFUOE+tlD9oVEEQxr+Zd0YO49nYGGKTIshBPG7nXRtimUIiQiAiiAjpUgdExUIs0gm2WmkhVklh4Z/isH1vFjkSErVJHQTRpAnc25E9ziMEcx6X226Wb38738wwhBEdGhEHfUHOuasAXhDReQD3VXX9pI/7gRIR2QSwYWY7RPQcwKSq/voX7ERQmqb3zOwBgCuqGkTkNwBR1Z2BQdVqdaxcLn8nood5nr+q1+vzzPxSVS8DKPqCRORMURTnoqhUKt0NISx772cAxGzeAoj1ev8XQkQHIYTX3vvteNex1mg0pkIIHsCFI8JbeZ6/iRoReQrg7LFMLgK4DmBaVX90QGmaLpjZk6IoZmOcJMkuM89lWfal33g4574R0YqqfuiAROQGgMeqWu/GP5n52n9Asav7ZibR3tCgWq02nSRJq1KpjDebzfbQIOfcTSKKLmq9Yg9jTUQedWfs9qlAzrmPAN5575/1QN2urTHzUrwMIXxm5mUAX493zczGzGzRzO602+2ZVqu1dzSjSwA+AZgYYBscAlBmXs2ybKs3dwM8HEgysn30BwcnwRPOfLspAAAAAElFTkSuQmCC"},a882:function(t,e,i){"use strict";i("6762"),i("2fdb");var s=function(){var t=this,e=t._self._c;return t.visible?e("el-dialog",{attrs:{center:"",title:"请选择举报理由",width:"600px","append-to-body":"",visible:t.visible,"before-close":function(e){return t.$emit("visible",!1)}},on:{"update:visible":function(e){t.visible=e}}},[e("div",{staticClass:"report"},[t._l(t.reportCase,(function(i){return e("div",{staticClass:"report-item"},[e("div",{staticClass:"title"},[t._v(t._s(i.title))]),e("div",{staticClass:"children-box"},t._l(i.children,(function(i){return e("div",{staticClass:"children-item",on:{click:function(e){return t.handleRadio(i)}}},[e("div",{staticClass:"radio",class:{select:t.reportIds.includes(i.id)}},[t.reportIds.includes(i.id)?e("i",{staticClass:"el-icon-check"}):t._e()]),e("div",{staticClass:"label"},[t._v(t._s(i.title))])])})),0)])})),t.reportIds.includes("other")?e("textarea",{directives:[{name:"model",rawName:"v-model",value:t.reportContent,expression:"reportContent"}],staticClass:"report-content",attrs:{placeholder:"请输入填写举报内容(必填)"},domProps:{value:t.reportContent},on:{input:function(e){e.target.composing||(t.reportContent=e.target.value)}}}):t._e()],2),e("div",{staticClass:"report-footer",attrs:{slot:"footer"},slot:"footer"},[e("el-button",{on:{click:function(e){return t.$emit("visible",!1)}}},[t._v("取 消")]),e("el-button",{staticStyle:{"background-color":"#0054f7",color:"white"},on:{click:t.report}},[t._v("确 定")])],1)]):t._e()},n=[],o=(i("d25f"),i("57e7"),i("c5f6"),i("f523")),a={name:"Report",props:{visible:{type:Boolean,default:!1},info:{type:Object},type:{type:Number}},model:{prop:"visible",event:"visible"},data:function(){return{reportIds:[],reportContent:""}},computed:{reportCase:function(){return this.$store.state.report.reportCase}},methods:{handleRadio:function(t){-1==this.reportIds.indexOf(t.id)?this.reportIds.push(t.id):this.reportIds.splice(this.reportIds.indexOf(t.id),1)},report:function(){var t=this;if(!this.reportIds.filter((function(t){return"other"!=t})).length)return this.$message.error("请选择举报类目");if(this.reportIds.includes("other")&&!this.reportContent)return this.$message.error("请填写举报内容");var e=0;switch(this.type){case 1:e=this.info.video_id;break;case 4:e=this.info.datum_id;break;case 5:e=this.info.article_id;break;default:e=this.info.id}var i={report_id:e,type:this.type,case_ids:this.reportIds.filter((function(t){return"other"!=t})).join(","),content:this.reportIds.includes("other")?this.reportContent:""};o["i"].userReport(i).then((function(e){var i=e.msg;e.data;t.$message.success(i),t.$emit("visible",!1)}))}}},c=a,r=(i("c0dc"),i("2877")),l=Object(r["a"])(c,s,n,!1,null,"0387d88f",null);e["a"]=l.exports},b088:function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABwAAAAcCAYAAAByDd+UAAAAAXNSR0IArs4c6QAAApVJREFUSEvtls9rU0EQx7/zkiJFQSFYLC0qgohg8W5vavUPEKMXD0Lc3USKoigqiKEHW/yFPyJ5u3ngwYsi/gFWvXrwJooogj+gErEe7KGKPrIjCy/hNfWlSchBoXt77Mx83u7MfmcISyxjzD5mPgNgBMCKBPNfAF4S0ZQQ4mGrkNRq0xhzjJmvL/VT8X0iOi6EuJHkkwgsl8sDnud9BNAPIARwF8C7hECbARwC0Afgp7V2Yz6f//o320Sg7/sHiOhe5HREShm0OqnWOgeg4myY+aBS6n4ikJmpWCwugA8ODioiuu2cPM9bNzMzM9sKODw8vNZa+yUCHq1Wq37cvlgsMhExGWOmmXk3gJb57CSPCbYO+IS01t8BrO5BwHZCzFEQBKO1Wm2HO6HneUPWWpdsVyS9WH2e5w1Yaz+71KZSqWeNa4ze2wMieiqEGOsFzRjzmJl3EdH++vuMAy8y81kAc1LKNb0A1tNFRJNCiHMuZgOotZ4E4BRlEVBr7a5mLAzDN4VC4X38Z4Ig2BCG4Ugmk5nOZrO/43ux+piSUrrDtAc0xowz800AH6SUm5qCvgawFcBpKeXlngC11hMAzhPRvBBiVVPQbwAyzHxFKXVqGdhu0Sxf6f9fNE4QnDDMSikHmkr/E4D1zDyhlLrQk2dRKpUy6XQ6T0TPpZTT8aCVSmWntXbUWqubu3zXStOtrv5bQGNMvVv8kFI6+eJuTxb5ke/780TUn9QtnA5eioz3NueqU7jWeg+AR5FfQ9gbShMEwbZarfbCzUxOpAHcYWbXqTteRDQE4DAzrwRgU6nU9lwu92pBe3IfxpirzHyiY0ILByK6JoQ4WTdZNKn5vi+IaBzAlmiw7YbvZqK3zHxLKWXiAf4A2DrOfpCYiwAAAAAASUVORK5CYII="},b77f:function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAAXNSR0IArs4c6QAAAbVJREFUOE+lk7+LE1EQxz9vNy4kELSw0U5sJFokO7t/gCAWiiAWQjwstFCsDhRBCxtBsBFRsFXQQgRB5ETxBxJsQszOBi0UJIWFYGu0UIm8kXfkwuGd0eNeOXznM7zvd8axzufW2c9MgIhsAE5HUfSu3+8vrDbsX4D9wCVgI3BVVa//CZkJyLKsbWYHgHNm9sI5d1NVLy+H/A0Qt1qtvVEUHQfGqnpERLYAz4EHqnphCbICkOf5MTO7aGYfgafOuWdFUbwODSKyOdSAjqqeCbUpoNFoJLVa7baZbQNOqWq5mmnNZnNTpVJ5bGZ9VZ2fAkTkVjBrNBq1h8Phz1nxisgO4I2qVhcBeZ7v8d7fSJKk2e12v89qzrJsl5k9mqRybRGQpunDKIruF0VxJwi890edczmwFVhQ1bMTD3YDd81svizLe1MPRORLkiQ7x+Pxee/9Qedc+M7L4BvQUtW5NE3nnHNXvPeHB4PBq2kKwbxqtfoNeOKc+xHH8Yler/c1CJbtwVvgpJntK8vy/Yo9EJEu8Kler7c7nc6vJYGIbAdChB+AQ6r6eU2bOBHHgAdszbfwP5f6G4nOqROCiOqNAAAAAElFTkSuQmCC"},c0dc:function(t,e,i){"use strict";i("4b8d")},c629:function(t,e,i){"use strict";var s=function(){var t=this,e=t._self._c;return e("div",{staticClass:"comment"},[e("div",{staticClass:"title"},[t._v("评论 "+t._s(t.total_num))]),e("div",{staticClass:"send"},[e("img",{staticClass:"headimg",attrs:{src:t.userInfo.headimg||i("0fb1")}}),e("div",{staticClass:"send-box",class:{expand:t.expand}},[e("textarea",{directives:[{name:"model",rawName:"v-model",value:t.content,expression:"content"}],staticClass:"sendText",attrs:{placeholder:"发布一条友善的评论"},domProps:{value:t.content},on:{focus:function(e){t.expand=!1},blur:t.hideSendBox,input:function(e){e.target.composing||(t.content=e.target.value)}}}),e("div",{staticClass:"sendBtn",style:{opacity:t.content?"1":"0.3"},on:{click:function(e){t.isSend=!0,t.content&&t.handlePost()}}},[t._v("\n 发布\n ")])])]),e("div",{staticClass:"switch"},[e("div",{staticClass:"switch-btn",class:{select:2==t.params.sort_type},on:{click:function(e){return t.changeSwitch(2)}}},[t._v("\n 最热\n ")]),e("div",{staticClass:"switch-btn",class:{select:1==t.params.sort_type},on:{click:function(e){return t.changeSwitch(1)}}},[t._v("\n 最新\n ")])]),e("div",{staticClass:"list"},t._l(t.list,(function(i){return e("div",{key:"comment"+i.id,ref:"comment"+i.id,refInFor:!0,staticClass:"list-item"},[e("CommentDetailCard",{attrs:{comment:i,option:t.option,reportType:t.option.reportType},on:{jump:t.handleJump,reply:t.handleReply,delete:t.handleDelete}})],1)})),0),t.finished?t._e():e("div",{staticClass:"loadmore",on:{click:function(e){return t.getList()}}},[t._v("\n 点击查看更多评论\n ")]),e("div",{staticClass:"empty"},[t.finished?e("el-empty",{attrs:{description:"没有更多数据"}}):t._e()],1)])},n=[],o=(i("1c01"),i("58b2"),i("8e6e"),i("f3e2"),i("ac6a"),i("456d"),i("d25f"),i("ade3")),a=(i("7f7f"),function(){var t=this,e=t._self._c;return e("div",{staticClass:"comment-detail-card"},[e("img",{staticClass:"card-headimg",class:{childHeadimg:t.isChild},attrs:{src:t.comment.headimg}}),e("div",{staticClass:"card-content"},[e("div",{staticClass:"title",class:{childTitle:t.isChild}},[e("div",{staticClass:"name"},[t._v(t._s(t.comment.name))]),t.comment.is_top?e("div",{staticClass:"is-top"},[t._v("置顶")]):t._e()]),e("div",{staticClass:"content"},[e("OverflowContent",{attrs:{value:t.comment.content}})],1),e("div",{staticClass:"footer"},[e("div",{staticClass:"time"},[t._v("\n "+t._s(t.comment.create_at?t.comment.create_at.slice(5,16):"--:--")+"\n ")]),e("div",{staticClass:"interactive"},[t.send?e("div",{staticClass:"item",on:{click:function(e){t.send=!1}}},[e("img",{attrs:{src:i("39a6"),alt:""}}),e("span",{staticClass:"select"},[t._v("取消回复")])]):e("div",{staticClass:"item",on:{click:function(e){t.send=!0}}},[e("img",{attrs:{src:i("89b0"),alt:""}}),e("span",[t._v("回复")])]),t.isChild?t._e():e("div",{staticClass:"item",on:{click:t.handleTags}},[e("img",{attrs:{src:i(0===t.comment.is_like?"a3be":"0bce"),alt:""}}),e("span",{class:{select:1===t.comment.is_like}},[t._v(t._s(t.comment.like_num||"0"))])]),t.isChild?t._e():e("div",{staticClass:"item",on:{click:function(e){t.reportVisible=!0}}},[e("img",{attrs:{src:i("1d57"),alt:""}}),e("span",[t._v("举报")])]),!t.isChild&&t.comment.can_delete?e("div",{staticClass:"item",on:{click:function(e){t.deleteVisible=!0}}},[e("img",{attrs:{src:i("b088"),alt:""}}),e("span",[t._v("删除")])]):t._e(),t.isChild?e("div",{staticClass:"item",on:{click:function(e){return t.$emit("jump",t.comment)}}},[e("img",{attrs:{src:i("b77f"),alt:""}}),e("span",[t._v("跳转")])]):t._e()])]),t.send?e("div",{staticClass:"send-box"},[e("textarea",{directives:[{name:"model",rawName:"v-model",value:t.content,expression:"content"}],staticClass:"sendText",attrs:{placeholder:"回复 ".concat(t.comment.name)},domProps:{value:t.content},on:{input:function(e){e.target.composing||(t.content=e.target.value)}}}),e("div",{staticClass:"sendBtn",style:{opacity:t.content?"1":"0.3"},on:{click:function(e){return t.content?t.handleReply():""}}},[t._v("\n 发布\n ")])]):t._e(),t.comment.parent_comment?e("div",{staticClass:"parent-box"},[e("CommentDetailCard",t._g({attrs:{comment:t.comment.parent_comment,isChild:!0,option:t.option}},t.$listeners))],1):t._e()]),e("Report",{attrs:{type:t.reportType,info:t.comment},model:{value:t.reportVisible,callback:function(e){t.reportVisible=e},expression:"reportVisible"}}),e("Delete",{on:{handleDelete:t.handleDelete},model:{value:t.deleteVisible,callback:function(e){t.deleteVisible=e},expression:"deleteVisible"}})],1)}),c=[],r=(i("c5f6"),function(){var t=this,e=t._self._c;return e("div",{ref:"overflow-content",staticClass:"overflow-content"},[e("div",{ref:"virtually",staticClass:"virtually"},[t._v("\n "+t._s(t.value)+"\n ")]),t.isOverflow?t.isOverflow&&t.hide?e("div",{staticClass:"content",class:{hide:t.hide}},[t._v("\n "+t._s(t.value)+"\n ")]):t.isOverflow&&!t.hide?e("div",{staticClass:"content",class:{show:!t.hide}},[t._v("\n "+t._s(t.value)),e("span",{staticClass:"hideBtn",on:{click:function(e){t.hide=!0}}},[t._v("收起"),e("img",{attrs:{src:i("2501"),alt:""}})])]):t._e():e("div",{staticClass:"content"},[t._v(t._s(t.value))]),t.isOverflow&&t.hide?e("span",{staticClass:"showBtn",on:{click:function(e){t.hide=!1}}},[t._v("全文"),e("img",{attrs:{src:i("2501"),alt:""}})]):t._e()])}),l=[],d={name:"OverflowContent",props:{value:{type:String}},data:function(){return{isOverflow:!1,hide:!0}},mounted:function(){var t=this.$refs["virtually"].scrollWidth,e=this.$refs["overflow-content"].offsetWidth;this.isOverflow=t>e}},A=d,u=(i("37d2"),i("2877")),p=Object(u["a"])(A,r,l,!1,null,"18de3e16",null),m=p.exports,f=i("a882"),h=function(){var t=this,e=t._self._c;return e("div",{staticClass:"delete"},[t.visible?e("el-dialog",{attrs:{center:"",width:"360px","show-close":!1,visible:t.visible,"before-close":function(e){return t.$emit("visible",!1)}},on:{"update:visible":function(e){t.visible=e}}},[e("div",{staticClass:"content"},[e("img",{staticClass:"icon",attrs:{src:i("6bbf"),alt:""}}),e("div",{staticClass:"info"},[t._v("是否确认删除!")]),e("div",{staticClass:"footer"},[e("div",{staticClass:"footer-btn cancel",on:{click:function(e){return t.$emit("visible",!1)}}},[t._v("取消")]),e("div",{staticClass:"footer-btn confirm",on:{click:function(e){t.$emit("handleDelete"),t.$emit("visible",!1)}}},[t._v("\n 确定\n ")])])])]):t._e()],1)},v=[],g={name:"Delete",props:{visible:{type:Boolean,default:!1}},model:{prop:"visible",event:"visible"}},C=g,b=(i("eb33"),Object(u["a"])(C,h,v,!1,null,"134444ef",null)),I=b.exports,w={name:"CommentDetailCard",components:{OverflowContent:m,Report:f["a"],Delete:I},props:{comment:{type:Object},isChild:{type:Boolean,default:!1},option:{type:Object,default:function(){return{listApi:function(t){},likeApi:function(t){},postApi:function(t){},postReplyApi:function(t){},delApi:function(t){}}}},reportType:{type:Number}},data:function(){return{send:!1,content:"",reportVisible:!1,deleteVisible:!1}},computed:{userInfo:function(){return this.$store.state.userInfo}},mounted:function(){},methods:{handleTags:function(){var t=this;this.option.likeApi(this.comment).then((function(e){var i=e.data,s=e.msg;t.comment.is_like=i.tags,t.comment.like_num=i.tags?Number(t.comment.like_num)+1:Number(t.comment.like_num)-1,t.$message.success(s)}))},handleReply:function(){var t=this;this.option.postReplyApi({content:this.content},this.comment).then((function(e){var i=e.data,s=e.msg;t.$message.success(s),t.content="",t.send=!1,t.isChild||(t.comment.children.push(i.detail),t.$emit("reply",i.detail))}))},handleDelete:function(){var t=this;this.option.delApi(this.comment).then((function(e){var i=e.msg;t.$message.success(i),t.$emit("delete",t.comment)}))}}},k=w,O=(i("cd15"),Object(u["a"])(k,a,c,!1,null,"7258cdf0",null)),S=O.exports;function E(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(t);e&&(s=s.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),i.push.apply(i,s)}return i}function x(t){for(var e=1;e<arguments.length;e++){var i=null!=arguments[e]?arguments[e]:{};e%2?E(Object(i),!0).forEach((function(e){Object(o["a"])(t,e,i[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):E(Object(i)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(i,e))}))}return t}var R={name:"Comment",components:{CommentDetailCard:S},props:["box"],data:function(){return{expand:!0,isSend:!1,content:"",params:{page:1,page_num:10,sort_type:2},option:{listApi:function(t){},likeApi:function(t){},postApi:function(t){},postReplyApi:function(t){},delApi:function(t){},reportType:0},list:[],total_num:0,finished:!1}},computed:{userInfo:function(){return this.$store.state.userInfo}},mounted:function(){},methods:{init:function(t){this.option=t,this.getList()},hideSendBox:function(){var t=this;setTimeout((function(e){t.expand=!t.isSend,t.isSend=!1}),100)},changeSwitch:function(t){this.params.page=1,this.params.sort_type=t,this.getList()},getList:function(){var t=this;this.option.listApi(this.params).then((function(e){var i=e.data;t.total_num=i.total_num,t.list=1==t.params.page?i.list:t.list.concat(i.list),t.params.page++,t.finished=i.list.length<t.params.page_num}))},handlePost:function(){var t=this;this.option.postApi({content:this.content},this.comment).then((function(e){var i=e.data,s=e.msg;t.$message.success(s),t.content="",t.send=!1;var n=x({is_like:0,like_num:0,can_delete:1},i.detail);1==t.params.sort_type?t.list.unshift(n):t.list.push(n)}))},handleJump:function(t){this.$refs["comment"+t.id]&&(this.box?this.$emit("handleJump",this.$refs["comment"+t.id][0].offsetTop):window.scrollTo(0,this.$refs["comment"+t.id][0].offsetTop))},handleReply:function(t){var e=x({is_like:0,like_num:0,can_delete:1},t);1==this.params.sort_type?this.list.unshift(e):this.list.push(e)},handleDelete:function(t){this.list=this.list.filter((function(e){return e.children=e.children&&e.children.filter((function(e){return e.id!=t.id})),e.id!=t.id}))}}},y=R,B=(i("7bc2"),Object(u["a"])(y,s,n,!1,null,"5e5c4f8c",null));e["a"]=B.exports},cd15:function(t,e,i){"use strict";i("9e12")},eb33:function(t,e,i){"use strict";i("9c39")},f243:function(t,e,i){}}]);
  2. //# sourceMappingURL=chunk-03250031.5db8bcf8.js.map