| 1 |
- webpackJsonp([80],{atAV:function(t,e,a){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var n=a("Xxa5"),i=a.n(n),s=a("mvHQ"),r=a.n(s),l=a("exGp"),o=a.n(l),c=a("//Fk"),d=a.n(c),u=a("5Npq"),p={name:"accessList",data:function(){return{tableData:[],currentPage1:1,pageSize:10,totalSize:0,checkList:[],initData:{},tagList:[],goods_name:"",buy_uid:"",detail:!1,inputGoodsName:"",inputOrderSn:"",inputEvaluationMap:"",inputComment:"",inputCommentFraction:"",inputRewardCoins:"",inputUserNick:"",inputEvaluationList:[],permissions:[],permissions_obj:{}}},created:function(){var t=this;this.permissions=this.$store.state.permissions;var e=!1;this.permissions.forEach(function(a,n){-1==a?e=!0:t.permissions_obj["id_"+a]=a}),this.permissions_obj.id_all=!!e},mounted:function(){this.getInitList()},methods:{searchMethod:function(){this.currentPage1=1,this.getInitList()},handleCurrentChange:function(t){this.currentPage1=t,this.getInitList()},handleSizeChange:function(t){this.pageSize=t,this.getInitList()},handleEdit:function(t,e){var a=this;this.detail=!0,this.inputEvaluationList=[],this.inputOrderSn=e.order_sn,this.inputGoodsName=e.goods_name,this.inputComment=e.comment,this.inputCommentFraction=e.comment_fraction,e.evaluation_map.forEach(function(t,e){new d.a(function(e,a){u.a.getDecrypt(t,e)}).then(function(t){a.inputEvaluationList.push(t)})}),this.inputRewardCoins=e.reward_coins,this.inputUserNick=e.user_nick},handleDelete:function(t,e){var a=this;this.$confirm("此操作将删除用户商品评论, 是否继续?","提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then(function(){a.deleteMethod(e.uid)}).catch(function(){a.$message({type:"info",message:"已取消删除"})})},deleteMethod:function(t){var e=this;return o()(i.a.mark(function a(){var n,s;return i.a.wrap(function(a){for(;;)switch(a.prev=a.next){case 0:return n={handshake:"",data:{uid:t}},a.next=3,e.$axios.post(e.$api.assessDelete,r()(n));case 3:200==(s=a.sent).code?(e.$message({message:s.message,type:"success"}),e.getInitList()):e.$message({message:s.message,type:"warning"});case 5:case"end":return a.stop()}},a,e)}))()},getInitList:function(){var t=this;return o()(i.a.mark(function e(){var a,n;return i.a.wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return a={handshake:"",data:{page:t.currentPage1,page_size:t.pageSize,buy_uid:t.buy_uid,goods_name:t.goods_name}},e.next=3,t.$axios.post(t.$api.assessList,r()(a));case 3:200==(n=e.sent).code?(t.initData=n.data,t.totalSize=t.initData.total,t.tableData=t.initData.data):t.$message({message:n.message,type:"warning"});case 5:case"end":return e.stop()}},e,t)}))()}}},_={render:function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("div",{staticClass:"accessList"},[a("h3",[t._v("评价列表")]),t._v(" "),a("div",{staticClass:"search"},[a("div",{staticClass:"cond1 cond"},[a("el-input",{attrs:{placeholder:"请输入商品名称"},model:{value:t.goods_name,callback:function(e){t.goods_name=e},expression:"goods_name"}},[a("template",{slot:"prepend"},[t._v("商品名称")])],2)],1),t._v(" "),a("div",{staticClass:"cond2 cond"},[a("el-input",{attrs:{placeholder:"请输入用户uid"},model:{value:t.buy_uid,callback:function(e){t.buy_uid=e},expression:"buy_uid"}},[a("template",{slot:"prepend"},[t._v("用户搜索")])],2)],1),t._v(" "),a("div",[a("el-button",{attrs:{type:"primary",icon:"el-icon-search"},on:{click:t.searchMethod}},[t._v("搜索")])],1)]),t._v(" "),a("div",{staticClass:"list"},[a("el-table",{ref:"multipleTable",staticStyle:{width:"100%"},attrs:{border:"",data:t.tableData,"tooltip-effect":"dark"}},[a("el-table-column",{attrs:{type:"index",width:"50","header-align":"center",align:"center",label:"序号"}}),t._v(" "),a("el-table-column",{attrs:{"header-align":"center",align:"center",prop:"goods_name",label:"商品名称",width:"240"}}),t._v(" "),a("el-table-column",{attrs:{"header-align":"center",align:"center",prop:"user_nick",label:"购买用户",width:"100"}}),t._v(" "),a("el-table-column",{attrs:{"header-align":"center",align:"center",prop:"buy_uid",label:"购买用户uid",width:"100"}}),t._v(" "),a("el-table-column",{attrs:{"header-align":"center",align:"center",prop:"order_sn",label:"商品订单号",width:"200"}}),t._v(" "),a("el-table-column",{attrs:{"header-align":"center",align:"center",prop:"comment",label:"评价内容",width:"200"}}),t._v(" "),a("el-table-column",{attrs:{"header-align":"center",align:"center",prop:"comment_fraction",label:"评价分数",width:"100"}}),t._v(" "),a("el-table-column",{attrs:{"header-align":"center",align:"center",prop:"reward_coins",label:"奖励金币",width:"100"}}),t._v(" "),a("el-table-column",{attrs:{"header-align":"center",align:"center",prop:"created_at",label:"评价时间",width:"180"}}),t._v(" "),a("el-table-column",{attrs:{"header-align":"center",align:"center",prop:"updated_at",label:"修改时间",width:"180"}}),t._v(" "),a("el-table-column",{attrs:{"header-align":"center",align:"center",label:"操作",fixed:"right"},scopedSlots:t._u([{key:"default",fn:function(e){return[a("el-button",{attrs:{size:"mini",type:"success"},on:{click:function(a){return t.handleEdit(e.$index,e.row)}}},[t._v("详情")]),t._v(" "),t.permissions_obj.id_Origina_assessDelete||t.permissions_obj.id_all?a("el-button",{attrs:{size:"mini",type:"danger"},on:{click:function(a){return t.handleDelete(e.$index,e.row)}}},[t._v("删除")]):t._e()]}}])})],1)],1),t._v(" "),a("div",{staticClass:"page"},[a("el-pagination",{attrs:{background:"","current-page":t.currentPage1,"page-sizes":[10,30,50,100],"page-size":t.pageSize,layout:"total, prev, pager, next,sizes,jumper",total:t.totalSize},on:{"size-change":t.handleSizeChange,"current-change":t.handleCurrentChange,"update:currentPage":function(e){t.currentPage1=e},"update:current-page":function(e){t.currentPage1=e}}})],1),t._v(" "),a("el-dialog",{attrs:{title:"评论详情",visible:t.detail,width:"45%",center:""},on:{"update:visible":function(e){t.detail=e}}},[a("div",{staticClass:"detail"},[a("div",{staticClass:"title"},[t._v("基本信息")]),t._v(" "),a("div",{staticClass:"detailBox"},[a("div",{staticClass:"detailItem"},[a("font",[t._v("用户名:")]),t._v(" "),a("span",[t._v(t._s(t.inputUserNick))])],1),t._v(" "),a("div",{staticClass:"detailItem"},[a("font",[t._v("商品名称:")]),t._v(" "),a("span",[t._v(t._s(t.inputGoodsName))])],1),t._v(" "),a("div",{staticClass:"detailItem"},[a("font",[t._v("订单号:")]),t._v(" "),a("span",[t._v(t._s(t.inputOrderSn))])],1),t._v(" "),a("div",{staticClass:"detailItem"},[a("font",[t._v("评论:")]),t._v(" "),a("span",[t._v(t._s(t.inputComment))])],1),t._v(" "),a("div",{staticClass:"detailItem"},[a("font",[t._v("评价分数:")]),t._v(" "),a("span",[t._v(t._s(t.inputCommentFraction))])],1),t._v(" "),a("div",{staticClass:"detailItem"},[a("font",[t._v("奖励金币")]),t._v(" "),a("span",[t._v(t._s(t.inputRewardCoins))])],1),t._v(" "),a("div",{staticClass:"detailItem"},[a("font",[t._v("评价图")]),t._v(" "),t._l(t.inputEvaluationList,function(e){return a("div",{key:e},[a("img",{attrs:{src:e,alt:""}}),t._v(" "),a("br"),a("br"),a("br"),a("br"),a("br")])})],2)])])])],1)},staticRenderFns:[]};var v=a("VU/8")(p,_,!1,function(t){a("q0te")},"data-v-0d45fcce",null);e.default=v.exports},q0te:function(t,e){}});
|