1 |
- (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-7441b538"],{2492:function(t,e,a){"use strict";a.r(e),e["default"]={enabledStateArr:[{key:"启用",val:"1"},{key:"禁用",val:"2"}]}},"4f78":function(t,e,a){"use strict";a.r(e);var s=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("div",[a("el-dialog",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],attrs:{"show-close":!1,"close-on-click-modal":!1,visible:t.isShow,title:this.curObj&&this.curObj.id?"编辑积分":"添加积分",fullscreen:!1,width:"470px","custom-class":"xl-dialog",center:""},on:{"update:visible":function(e){t.isShow=e}}},[a("base-form",{ref:"ruleForm",attrs:{data:t.formData,"is-inline":!1,"label-width":"110px"}},[a("div",{attrs:{slot:"footer"},slot:"footer"},[a("el-button",{staticClass:"xl-form-btn t2",on:{click:t.close}},[t._v("关 闭")]),a("el-button",{staticClass:"xl-form-btn t1",on:{click:function(e){return t.close("confirm")}}},[t._v("确定")])],1)])],1)],1)},i=[],n=a("5530"),o=a("2909"),r={components:{},mixins:Object(o["a"])(mixins),props:{isShow:Boolean,curObj:Object},inject:["parentData"],data:function(){return{formData:[],loading:!0,cObj:{}}},watch:{isShow:function(t){t&&this.getDef()}},methods:{getDef:function(){var t=Object(n["a"])({},this.curObj);this.formData=[{label:"成长值",key:"point",rules:1},{label:"备注",key:"remark",type:"textarea",rules:1}],this.setDefaultValue(t)},close:function(t){var e=this;"confirm"===t?this.$refs["ruleForm"].$refs["baseForm"].validate((function(t){if(t){var a=e.$refs.ruleForm.baseForm,s=Object(n["a"])({},a),i="admwechatuserintegraledit";e.curObj.id&&(i="admwechatuserintegraledit",s.id=e.curObj.id),e.$api.user[i](s).then((function(t){e.$msgs(e.curObj.id?"编辑成功":"新增成功"),e.$emit("close",s)}))}})):(this.$emit("close"),this.setDefaultValue())}}},c=r,l=a("2877"),u=Object(l["a"])(c,s,i,!1,null,"72f0589c",null);e["default"]=u.exports},"4fef":function(t,e,a){"use strict";a.r(e);var s=a("ade3"),i=a("5530");a("4e82"),a("e9c4"),a("a9e3");e["default"]={data:function(){return{listLoading:!1,tableData:[],currentPage:1,pageSize:10,totalRecords:1,listConfig:{},operations:[]}},created:function(){var t=this;this.$nextTick((function(){t.noCreated||t.fetchData()}))},methods:{searchHandle:function(t){this.currentPage=1,this.searchForm=t,this.fetchData()},sizeChange:function(t){this.pageSize=t,this.currentPage=1,this.fetchData()},pageHandle:function(t){this.currentPage=t,this.fetchData()},sortChange:function(t){this.currentPage=1;var e=Object(i["a"])({},this.searchForm);"ascending"===t.order?e.sort=JSON.stringify(Object(s["a"])({},t.prop,"asc")):e.sort=JSON.stringify(Object(s["a"])({},t.prop,"desc")),this.searchForm=Object(i["a"])({},e),this.fetchData(e)},fetchData:function(t){var e=this;if(this.apiStr){var a={page:this.currentPage,page_size:this.pageSize};t?a=Object(i["a"])(Object(i["a"])({},a),t):this.searchForm&&(a=Object(i["a"])(Object(i["a"])({},a),this.searchForm)),this.getDataBefore&&this.getDataBefore(a),this.listLoading=!0;var s=this.apiStr.split(".");this.$api[s[0]][s[1]](a).then((function(t){return 1===e.currentPage&&(e.pageSize=t.page_size||1),e.totalRecords=t.total?Number(t.total):0,e.tableData=t.list||[],e.listLoading=!1,e.getMoreData&&e.getMoreData(t,a),t})).catch((function(t){e.listLoading=!1}))}}}}},"581a":function(t,e,a){"use strict";a.r(e);var s=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("div",{staticClass:"app-container"},[a("search-form",{attrs:{"list-loading":t.listLoading},on:{change:t.searchHandle}}),a("table-list",{attrs:{"list-loading":t.listLoading,data:t.tableData2,columns:t.listConfig,"current-page":t.currentPage,"page-size":t.pageSize,"total-records":t.totalRecords},on:{"sort-change":t.sortChange,currentChange:t.pageHandle,sizeChange:t.sizeChange}}),a("popup-edit",{attrs:{isShow:t.isDtlShow,curObj:t.curObj},on:{close:t.closePopup}}),a("point-dtl",{attrs:{isShow:t.isPDShow,curObj:t.curObj},on:{close:t.closePDPopup}})],1)},i=[],n=a("2909"),o=a("5530"),r=(a("d81d"),a("b64b"),a("a9e3"),a("99af"),a("ed08")),c=a("b1fe"),l=a("4f78"),u=a("dbef"),h=a("4fef"),d=a("2492"),f={name:"index",components:{SearchForm:c["default"],PopupEdit:l["default"],PointDtl:u["default"]},provide:function(){return{parentData:this}},mixins:[h["default"]],data:function(){return Object(o["a"])({apiStr:"user.admwechatuserlist",searchForm:null,isDtlShow:!1,curObj:{},isPDShow:!1},d["default"])},computed:{tableData2:function(){var t=Object(n["a"])(this.tableData);return t.map((function(t){var e=window.sessionStorage.getItem("fp_user")?JSON.parse(window.sessionStorage.getItem("fp_user")):{};"admin"===e.username?t.phones=t.phone:t.phones=t.phone.substring(0,7)+"****"})),t}},created:function(){},mounted:function(){this.listConfig={rows:[{label:"id",prop:"id"},{label:"头像",prop:"avatar",type:"img"},{label:"昵称",prop:"nickname"},{label:"成长值",prop:"integral",sortable:"custom"},{label:"手机号",prop:"phones"},{label:"注册时间",prop:"create_at"},{label:"禁言状态",prop:"is_gag",type:"tag",tags:Object(r["a"])(this.$dictData.sys_yesno),tagTypeObj:{2:"success",1:"danger"}},{label:"销售",prop:"is_sale",type:"tag",tags:Object(r["a"])(this.$dictData.sys_yesno),tagTypeObj:{2:"info",1:"primary"}},{label:"渠道",prop:"is_partner",type:"tag",tags:Object(r["a"])(this.$dictData.sys_yesno),tagTypeObj:{2:"info",1:"primary"}},{label:"备注",prop:"tag",type:"input",width:100},{label:"操作",width:260,type:"handle2",operations:[{label:"保存标签",func:this.saveHandle,btnType:"primary"},{label:"成长值编辑",func:this.openPopup,btnType:"success"},{label:"成长值明细",func:this.openPDPopup,btnType:"success"},{labelFor:"is_gag",func:this.disHandle,labelConfig:{texts:{1:"解禁",2:"禁言"},btnTypes:{1:"success",2:"danger"}}},{labelFor:"is_ban",func:this.banHandle,labelConfig:{texts:{1:"解除拉黑",2:"拉黑"},btnTypes:{1:"success",2:"danger"}}},{labelFor:"is_sale",func:this.isSaleHandle,labelConfig:{texts:{1:"销售取消",2:"设成销售"},btnTypes:{1:"danger",2:"info"}}},{labelFor:"is_partner",func:this.isPartnerHandle,labelConfig:{texts:{1:"渠道取消",2:"设成渠道"},btnTypes:{1:"danger",2:"info"}}},{label:"删除",func:this.delHandle,btnType:"danger"}]}]}},methods:{openPDPopup:function(t){t&&t.id?this.curObj=t:this.curObj={},this.isPDShow=!0},closePDPopup:function(t){this.isPDShow=!1,t&&this.fetchData()},openPopup:function(t){t&&t.id?this.curObj=t:this.curObj={},this.isDtlShow=!0},closePopup:function(t){this.isDtlShow=!1,t&&this.fetchData()},isPartnerHandle:function(t){var e=this,a=1===Number(t.is_partner)?2:1,s=1===Number(t.is_partner)?"取消渠道合伙人":"设置成渠道合伙人---";this.$msg("确定要".concat(s).concat(t.nickname,"吗?"),"confirm",(function(){e.$api.user.admwechatuserpartner({id:t.id,is_partner:a}).then((function(t){e.$msgs("".concat(s,"成功!")),e.fetchData()}))}),null,!0)},isSaleHandle:function(t){var e=this,a=1===Number(t.is_sale)?2:1,s=1===Number(t.is_sale)?"取消销售":"设置成销售置业经理---";this.$msg("确定要".concat(s).concat(t.nickname,"吗?"),"confirm",(function(){e.$api.user.admwechatusersale({id:t.id,is_sale:a}).then((function(t){e.$msgs("".concat(s,"成功!")),e.fetchData()}))}),null,!0)},banHandle:function(t){var e=this,a=1===Number(t.is_ban)?2:1,s=1===Number(t.is_ban)?"解除拉黑":"拉黑";this.$msg("确定要".concat(s).concat(t.nickname,"吗?"),"confirm",(function(){e.$api.user.admwechatuserban({id:t.id,is_ban:a}).then((function(t){e.$msgs("".concat(s,"成功!")),e.fetchData()}))}),null,!0)},disHandle:function(t){var e=this,a=1===Number(t.is_gag)?2:1,s=1===Number(t.is_gag)?"解禁":"禁言";this.$msg("确定要".concat(s).concat(t.nickname,"吗?"),"confirm",(function(){e.$api.user.admwechatusergag({id:t.id,is_gag:a}).then((function(t){e.$msgs("".concat(s,"成功!")),e.fetchData()}))}),null,!0)},delHandle:function(t){var e=this;this.$msg("您确定要删除该用户吗?","confirm",(function(){e.$api.user.admwechatuserpurge({id:t.id}).then((function(t){e.$msgs("已删除!"),e.fetchData()}))}))},saveHandle:function(t){var e=this;this.$msg("您确定要保存标签吗?","confirm",(function(){e.$api.user.admwechatuseredit({id:t.id,tag:t.tag}).then((function(t){e.$msgs("已添加!"),e.fetchData()}))}))}}},p=f,b=a("2877"),g=Object(b["a"])(p,s,i,!1,null,null,null);e["default"]=g.exports},b1fe:function(t,e,a){"use strict";a.r(e);var s=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("base-form",{ref:"ruleForm",attrs:{slot:"content",data:t.searchData},slot:"content"},[a("div",{attrs:{slot:"footer"},slot:"footer"},[a("el-button",{staticClass:"xl-form-btn bgc1",attrs:{loading:t.listLoading,icon:"el-icon-search"},on:{click:t.searchHandle}},[t._v("查询")])],1)])},i=[],n=a("5530"),o={mixins:[],props:{listLoading:Boolean},inject:["parentData"],data:function(){return{searchData:[{label:"手机号",key:"phone"},{label:"昵称",key:"nickname"},{label:"备注",key:"tag"},{label:"是否置业经理",key:"is_sale",type:"select",class:"c-3",options:this.$dictData.sys_yesno},{label:"是否开启推送",key:"is_notice",type:"select",class:"c-3",options:this.$dictData.sys_yesno}]}},methods:{searchHandle:function(){var t=this.$refs.ruleForm.baseForm,e=Object(n["a"])({},t);this.$emit("change",e)}}},r=o,c=a("2877"),l=Object(c["a"])(r,s,i,!1,null,null,null);e["default"]=l.exports},dbef:function(t,e,a){"use strict";a.r(e);var s=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("div",[a("el-dialog",{directives:[{name:"loading",rawName:"v-loading",value:t.loading,expression:"loading"}],attrs:{"show-close":!1,"close-on-click-modal":!1,visible:t.isShow,title:"总成长值("+t.total+")-明细列表",fullscreen:!1,width:"600px","custom-class":"xl-dialog",center:""},on:{"update:visible":function(e){t.isShow=e}}},[a("table-list",{attrs:{"list-loading":t.listLoading,data:t.tableData,columns:t.listConfig,"current-page":t.currentPage,"page-size":t.pageSize,"total-records":t.totalRecords},on:{currentChange:t.pageHandle,sizeChange:t.sizeChange}}),a("div",{staticClass:"xl-form"},[a("div",{staticClass:"xl-form-footer"},[a("el-button",{staticClass:"xl-form-btn t2",on:{click:t.close}},[t._v("关 闭")])],1)])],1)],1)},i=[],n=a("4fef"),o={components:{},mixins:[n["default"]],props:{isShow:Boolean,curObj:Object},inject:["parentData"],data:function(){return{apiStr:"user.admwechatuserintegrallist",searchForm:{},noCreated:!0,total:0,formData:[],loading:!0,cObj:{}}},watch:{isShow:function(t){t&&(this.searchForm={id:this.curObj.id},this.fetchData())}},mounted:function(){this.listConfig={rows:[{label:"成长值变动",prop:"total_point"},{label:"类型",prop:"target_type"},{label:"备注",prop:"remark"},{label:"时间",prop:"create_at"}]}},methods:{getMoreData:function(t){this.total=t.surplus_point},close:function(t){this.$emit("close")}}},r=o,c=a("2877"),l=Object(c["a"])(r,s,i,!1,null,"c88a4b44",null);e["default"]=l.exports}}]);
|