server.vue 787 B

12345678910111213141516171819202122232425262728293031323334353637
  1. // 客服
  2. <template>
  3. <x-prompt :visible="visible">
  4. <div class="head">联系客服</div>
  5. <div class="body">
  6. <p>截图后至微信“扫一扫”打开,添加客服</p>
  7. <img :src="src"
  8. style="width: 60%;margin-top: .3rem;">
  9. </div>
  10. </x-prompt>
  11. </template>
  12. <script>
  13. import prompt from "../prompt.vue";
  14. import { getCustomQRCode } from "@/api";
  15. export default {
  16. components: { "x-prompt": prompt },
  17. data() {
  18. return {
  19. channel_id: window.options.distribution_channel_id,
  20. src: "",
  21. };
  22. },
  23. methods: {
  24. initServerImage() {
  25. getCustomQRCode(this.channel_id, this.openid).then((r) => {
  26. this.src = r.qrcode;
  27. });
  28. },
  29. },
  30. created() {
  31. this.initServerImage();
  32. },
  33. };
  34. </script>
  35. <style lang="scss">
  36. </style>