kefu/h5/static/js/pages-index-wechat.6443d6b3.js

1 line
3.6 KiB
JavaScript
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["pages-index-wechat"],{9287:function(e,t,n){"use strict";n("7a82");var a=n("4ea4").default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;a(n("81b7"));var i={data:function(){return{kefu:null,token:"",baseUrl:"",wechatKefuQrcode:"",wechatIcon:{color:"#3b4144",size:"22",type:"weixin"},wechatList:[]}},onShow:function(){var e=uni.getStorageSync("app");e&&(this.token=e.token);var t=uni.getStorageSync("domain");t&&(this.baseUrl=t.domain),this.kefuInfo()},methods:{kefuInfo:function(){var e=this;uni.request({url:e.baseUrl+"/kefu/kefuinfo?token="+e.token,method:"get",header:{"Content-Type":"application/x-www-form-urlencoded"},success:function(t){e.kefu=t.data.result,e.callBack()}})},callBack:function(){var e=this;uni.request({url:e.baseUrl+"/wechat/showQrcode",data:{entId:e.kefu.ent_id,sceneName:"kf_"+e.kefu.name},method:"get",header:{token:e.token},success:function(t){e.wechatKefuQrcode=t.data.result.url,e.getOpenid()}})},getOpenid:function(){var e=this;uni.request({url:e.baseUrl+"/kefu/wechatOpenidList",method:"get",header:{token:e.token},success:function(t){e.wechatList=t.data.result}})},unBindWechat:function(e){var t=this;uni.request({url:t.baseUrl+"/kefu/delWechatOpenid",data:{oauth_id:e},method:"get",header:{token:t.token},success:function(e){t.getOpenid()}})}}};t.default=i},a4fb:function(e,t,n){"use strict";n.r(t);var a=n("f4b9"),i=n("c63f");for(var u in i)["default"].indexOf(u)<0&&function(e){n.d(t,e,(function(){return i[e]}))}(u);n("c141");var c=n("f0c5"),o=Object(c["a"])(i["default"],a["b"],a["c"],!1,null,"2f453ecd",null,!1,a["a"],void 0);t["default"]=o.exports},c141:function(e,t,n){"use strict";var a=n("f051"),i=n.n(a);i.a},c63f:function(e,t,n){"use strict";n.r(t);var a=n("9287"),i=n.n(a);for(var u in a)["default"].indexOf(u)<0&&function(e){n.d(t,e,(function(){return a[e]}))}(u);t["default"]=i.a},d73f:function(e,t,n){var a=n("24fb");t=a(!1),t.push([e.i,"uni-page-body[data-v-2f453ecd]{background-color:#eef0f6}body.?%PAGE?%[data-v-2f453ecd]{background-color:#eef0f6}.kefuInfo[data-v-2f453ecd]{display:flex;flex-direction:column;align-items:center}.kefuDesc[data-v-2f453ecd]{padding:20px;font-size:14px;color:#333;line-height:23px}.kefuInfo .avator[data-v-2f453ecd]{margin-top:20px;width:300px;height:300px}",""]),e.exports=t},f051:function(e,t,n){var a=n("d73f");a.__esModule&&(a=a.default),"string"===typeof a&&(a=[[e.i,a,""]]),a.locals&&(e.exports=a.locals);var i=n("4f06").default;i("35f99750",a,!0,{sourceMap:!1,shadowMode:!1})},f4b9:function(e,t,n){"use strict";n.d(t,"b",(function(){return i})),n.d(t,"c",(function(){return u})),n.d(t,"a",(function(){return a}));var a={uniList:n("99b2").default,uniListItem:n("e83a").default},i=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("v-uni-view",[null!=e.kefu?n("v-uni-view",{staticClass:"kefuInfo"},[n("v-uni-view",[n("v-uni-image",{staticClass:"avator",attrs:{src:e.wechatKefuQrcode}})],1)],1):e._e(),n("v-uni-view",{staticClass:"kefuDesc"},[n("v-uni-view",[e._v("1. 绑定微信请扫描或识别上面二维码")]),n("v-uni-view",[e._v("2. 如果不想接收信息,微信公众号右上角,设置中可设置消息免打扰")]),n("v-uni-view",[e._v("3. 解除绑定可点击下面按钮解除后该微信OpenID将收不到消息推送")])],1),n("uni-list",{directives:[{name:"show",rawName:"v-show",value:0!=e.wechatList.length,expression:"wechatList.length!=0"}]},e._l(e.wechatList,(function(t){return n("uni-list-item",{key:t.id,attrs:{"show-extra-icon":!0,"extra-icon":e.wechatIcon,clickable:!0,title:"微信解绑 "+t.oauth_id},on:{click:function(n){arguments[0]=n=e.$handleEvent(n),e.unBindWechat(t.oauth_id)}}})})),1)],1)},u=[]}}]);