db9795b.js 5.1 KB

1
  1. (window.webpackJsonp=window.webpackJsonp||[]).push([[87],{544:function(t,e,n){},685:function(t,e,n){"use strict";n(544)},807:function(t,e,n){"use strict";n.r(e);var r=n(6),o=(n(30),{name:"sale_detail",data:function(){return{info:{},loading:!1,logList:[],page:1,total:0,status:-1,type:"0",keywords:"",workfileData:[]}},mounted:function(){this.getContent()},methods:{getContent:function(){var t=this;return Object(r.a)(regeneratorRuntime.mark((function e(){var n,r,o;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=t.$route.query,"{}"!==JSON.stringify(n)){e.next=4;break}return t.$message.error("参数错误"),e.abrupt("return");case 4:return r=n.info_id,t.logListFunc(r),e.next=8,t.$post("/api/admin/sale/content",{id:r});case 8:(o=e.sent)&&1===o.status&&(t.info=o.data);case 10:case"end":return e.stop()}}),e)})))()},changeStatus:function(t,e,content){var n=this;return Object(r.a)(regeneratorRuntime.mark((function r(){var o;return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.next=2,n.$post("/api/admin/sale/changeStatus",{id:t,status:e,content:content});case 2:(o=r.sent)&&1===o.status&&(n.$message({type:"success",message:"操作成功!"}),n.info.status=e,n.logListFunc(t),n.getAuditList(),n.loading=!1);case 4:case"end":return r.stop()}}),r)})))()},onChange:function(t,e){var n=this;return Object(r.a)(regeneratorRuntime.mark((function r(){return regeneratorRuntime.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:n.loading=!0,3==e?n.$prompt("请输入拒绝理由","提示",{confirmButtonText:"确定",cancelButtonText:"取消"}).then((function(r){var o=r.value;n.changeStatus(t,e,o)})).catch((function(){n.loading=!1,n.$message({type:"info",message:"取消输入"})})):n.changeStatus(t,e,"");case 2:case"end":return r.stop()}}),r)})))()},logListFunc:function(t){var e=this;return Object(r.a)(regeneratorRuntime.mark((function n(){var r,o;return regeneratorRuntime.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return r={sale_id:t},n.next=3,e.$post("/api/admin/sale/logList",r);case 3:o=n.sent,e.logList=o.data;case 5:case"end":return n.stop()}}),n)})))()},getAuditList:function(){var t=this;return Object(r.a)(regeneratorRuntime.mark((function e(){var data,n;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return data={page:t.page,status:t.status,type:t.type,keywords:t.keywords},e.next=3,t.$post("/api/admin/sale/list",data);case 3:(n=e.sent)&&1===n.status&&(t.workfileData=n.data.list||[],t.total=1*n.data.total,t.count=n.data.count);case 5:case"end":return e.stop()}}),e)})))()}}}),c=(n(685),n(4)),component=Object(c.a)(o,(function(){var t=this,e=t._self._c;return e("div",{staticClass:"mainContainer"},[e("div",{staticClass:"mainTitle"},[t._v("用户信息")]),t._v(" "),e("h3",{staticStyle:{"margin-top":"0px !important"}},[t._v("用户信息")]),t._v(" "),e("el-row",[e("el-col",{attrs:{span:4}},[e("el-col",{staticStyle:{overflow:"hidden"},attrs:{span:24}},[e("el-avatar",{staticStyle:{float:"left",height:"50px",width:"50px","margin-right":"20px"},attrs:{src:t.info.user_icon}}),t._v(" "),e("a",{staticStyle:{height:"50px","line-height":"50px",float:"left",color:"#308eff"},attrs:{target:"_blank",href:t.info.host+"/rooter/user/"+t.info.uid}},[t._v(t._s(t.info.nickname)+"("+t._s(t.info.uid)+")")])],1)],1)],1),t._v(" "),e("el-row",{staticStyle:{"margin-bottom":"15px","margin-top":"15px"}},[e("el-col",{staticStyle:{width:"150px"},attrs:{span:8}},[1==t.info.status?e("h3",[t._v(" 服务内容(待审核)")]):t._e(),t._v(" "),2==t.info.status?e("h3",[t._v(" 服务内容(已通过)")]):t._e(),t._v(" "),3==t.info.status?e("h3",[t._v(" 服务内容(已拒绝)")]):t._e()]),t._v(" "),e("el-col",{staticStyle:{"margin-top":"15px",float:"left"},attrs:{span:8}},[1==t.info.status||3==t.info.status?e("el-button",{attrs:{size:"mini",type:"primary"},on:{click:function(e){return t.onChange(t.info.id,2)}}},[t._v("审核通过")]):t._e(),t._v(" "),1==t.info.status||2==t.info.status?e("el-button",{attrs:{size:"mini",type:"danger"},on:{click:function(e){return t.onChange(t.info.id,3)}}},[t._v("审核拒绝")]):t._e()],1)],1),t._v(" "),e("el-row",[e("el-col",{attrs:{span:4}},[e("el-col",{staticStyle:{overflow:"hidden"},attrs:{span:24}},[e("img",{attrs:{width:"100%",src:t.info.img}})])],1),t._v(" "),e("el-col",{attrs:{span:15}},[e("div",{staticClass:"grid-content bg-purple-dark",staticStyle:{"margin-left":"20px"}},[t._v(t._s(t.info.title))]),t._v(" "),e("div",{staticClass:"grid-content bg-purple-dark",staticStyle:{"margin-left":"20px",color:"red","margin-top":"20px"}},[t._v("¥"+t._s(t.info.price))]),t._v(" "),e("div",{staticClass:"grid-content bg-purple-dark",staticStyle:{"margin-left":"20px","margin-top":"20px"},domProps:{innerHTML:t._s(t.info.content)}})])],1),t._v(" "),e("h3",[t._v("审核记录")]),t._v(" "),e("el-table",{staticStyle:{width:"100%","margin-bottom":"20px"},attrs:{data:t.logList,"row-key":"id",border:""}},[e("el-table-column",{attrs:{prop:"content",label:"审核内容"}}),t._v(" "),e("el-table-column",{attrs:{prop:"addtime",label:"审核时间"}}),t._v(" "),e("el-table-column",{attrs:{prop:"check_name",label:"审核人"}})],1)],1)}),[],!1,null,"0a95509d",null);e.default=component.exports}}]);