hookehuyr

联系我们控件联调

1 <!-- 1 <!--
2 * @Date: 2022-11-23 14:41:53 2 * @Date: 2022-11-23 14:41:53
3 * @LastEditors: hookehuyr hookehuyr@gmail.com 3 * @LastEditors: hookehuyr hookehuyr@gmail.com
4 - * @LastEditTime: 2022-11-23 14:42:16 4 + * @LastEditTime: 2023-01-06 19:04:00
5 * @FilePath: /data-table/src/components/ContactField/index.vue 5 * @FilePath: /data-table/src/components/ContactField/index.vue
6 * @Description: 联系我们控件 6 * @Description: 联系我们控件
7 --> 7 -->
8 <template> 8 <template>
9 - <div class="contact-field-page"> 9 + <div v-if="HideShow" class="contact-field-page">
10 <van-popover v-model:show="showPopover" placement="left"> 10 <van-popover v-model:show="showPopover" placement="left">
11 <div class="contact-content"> 11 <div class="contact-content">
12 <div class="text-tel">电话联系</div> 12 <div class="text-tel">电话联系</div>
...@@ -18,9 +18,9 @@ ...@@ -18,9 +18,9 @@
18 {{ item.component_props.tel }} 18 {{ item.component_props.tel }}
19 </a> 19 </a>
20 </div> 20 </div>
21 - <div v-if="item.component_props.qr_code"> 21 + <div v-if="item.component_props.image_url">
22 <div class="text-qr_code">微信联系</div> 22 <div class="text-qr_code">微信联系</div>
23 - <van-image width="100" height="100" :src="item.component_props.qr_code" /> 23 + <van-image width="100" height="100" :src="item.component_props.image_url" />
24 </div> 24 </div>
25 </div> 25 </div>
26 <template #reference> 26 <template #reference>
...@@ -40,6 +40,10 @@ import { styleColor } from "@/constant.js"; ...@@ -40,6 +40,10 @@ import { styleColor } from "@/constant.js";
40 const props = defineProps({ 40 const props = defineProps({
41 item: Object, 41 item: Object,
42 }); 42 });
43 +// 隐藏显示
44 +const HideShow = computed(() => {
45 + return !props.item.component_props.disabled
46 +})
43 const showPopover = ref(false); 47 const showPopover = ref(false);
44 </script> 48 </script>
45 49
......