|
@@ -5,7 +5,14 @@ import PopupLayout from './components/PopupLayout.vue'
|
|
|
import CenterLayout from './components/CenterLayout.vue'
|
|
|
import MobileContentCard from './components/content-card.vue'
|
|
|
import MobileCenterCard from './components/center-card.vue'
|
|
|
-import { usePreLeaveInfo } from '@/utils/hooks'
|
|
|
+import phoneConfirmDialog from './components/confirm-dialog.vue'
|
|
|
+import ChangePhoneDialog from './components/change-phone-dialog.vue'
|
|
|
+
|
|
|
+import {
|
|
|
+ useContactMeLogic,
|
|
|
+ usePhoneCheck,
|
|
|
+ usePreLeaveInfo
|
|
|
+} from '@/utils/hooks'
|
|
|
|
|
|
const props = defineProps({
|
|
|
source: {
|
|
@@ -54,6 +61,18 @@ const {
|
|
|
|
|
|
console.log(configInfo)
|
|
|
|
|
|
+const {
|
|
|
+ contactMe,
|
|
|
+ changePhoneDialog,
|
|
|
+ successCheckDialog,
|
|
|
+ confirmPhoneDialog,
|
|
|
+ dialogEvents,
|
|
|
+} = usePhoneCheck({
|
|
|
+ configInfo,
|
|
|
+ props,
|
|
|
+ popupVisible: visible,
|
|
|
+})
|
|
|
+
|
|
|
defineExpose({
|
|
|
updateVisible
|
|
|
})
|
|
@@ -73,7 +92,7 @@ export default {
|
|
|
@update:visible="updateVisible"
|
|
|
@close="close"
|
|
|
>
|
|
|
- <div class="mobile-leave-dialog-content" :class="{ 'c-m-center': center, 'c-m-bottom': !center }">
|
|
|
+ <div class="mobile-leave-dialog-content" :class="{ 'dialog-content-center': center, 'dialog-content-bottom': !center }">
|
|
|
<CenterLayout v-if="center" @closeIconClick="close">
|
|
|
<MobileCenterCard
|
|
|
:qr="configInfo.wxer"
|
|
@@ -87,49 +106,70 @@ export default {
|
|
|
:phone="configInfo.phone"
|
|
|
:platform="platform"
|
|
|
:use-customer3="useCustomer3"
|
|
|
+ :is-current-phone="configInfo.isCurrentPhone"
|
|
|
+ @contact="contactMe"
|
|
|
/>
|
|
|
</PopupLayout>
|
|
|
</div>
|
|
|
+ <!-- 确认联系电话弹窗 -->
|
|
|
+ <phoneConfirmDialog
|
|
|
+ :visible.sync="confirmPhoneDialog.show"
|
|
|
+ :title="successCheckDialog.title"
|
|
|
+ :confirm-button-text="confirmPhoneDialog.confirmButtonText"
|
|
|
+ :cancel-button-text="confirmPhoneDialog.cancelButtonText"
|
|
|
+ :content-text="confirmPhoneDialog.contentText"
|
|
|
+ @confirm="dialogEvents.confirmPhoneConfirm"
|
|
|
+ @cancel="dialogEvents.confirmPhoneCancel"
|
|
|
+ />
|
|
|
+ <!-- 成功弹窗 -->
|
|
|
+ <phoneConfirmDialog
|
|
|
+ :visible.sync="successCheckDialog.show"
|
|
|
+ :title="successCheckDialog.title"
|
|
|
+ :confirm-button-text="successCheckDialog.confirmButtonText"
|
|
|
+ :cancel-button-text="successCheckDialog.cancelButtonText"
|
|
|
+ :content-text="successCheckDialog.contentText"
|
|
|
+ @confirm="dialogEvents.successConfirm"
|
|
|
+ />
|
|
|
+ <!-- 修改手机号弹窗 -->
|
|
|
+ <ChangePhoneDialog
|
|
|
+ :visible.sync="changePhoneDialog.show"
|
|
|
+ :phone.sync="changePhoneDialog.phoneNumber"
|
|
|
+ @confirm="dialogEvents.phoneChangeConfirm"
|
|
|
+ @cancel="dialogEvents.phoneChangeCancel"
|
|
|
+ />
|
|
|
</AnimatedOverlay>
|
|
|
</template>
|
|
|
|
|
|
<style scoped lang="scss">
|
|
|
+@import './style/dialog-layout.scss';
|
|
|
+
|
|
|
+$main: #2cb7ca;
|
|
|
+
|
|
|
::v-deep {
|
|
|
::-webkit-scrollbar {
|
|
|
/*滚动条整体样式*/
|
|
|
width: 2px;
|
|
|
}
|
|
|
-}
|
|
|
-.mobile-leave-dialog {
|
|
|
- display: flex;
|
|
|
- align-items: flex-end; /* 内容置底 */
|
|
|
-}
|
|
|
-::v-deep {
|
|
|
- .overlay-content {
|
|
|
- width: 100%;
|
|
|
+
|
|
|
+ .highlight-text {
|
|
|
+ color: $main;
|
|
|
}
|
|
|
-}
|
|
|
|
|
|
-.mobile-leave-dialog-content {
|
|
|
- box-sizing: border-box;
|
|
|
- &.c-m-bottom {
|
|
|
+ .overlay-content {
|
|
|
width: 100%;
|
|
|
- max-height: 70vh;
|
|
|
- border-radius: 12px 12px 0 0;
|
|
|
- background-color: #fff;
|
|
|
- overflow-y: auto;
|
|
|
}
|
|
|
- &.c-m-center {
|
|
|
- position: absolute;
|
|
|
- top: 45%;
|
|
|
- left: 50%;
|
|
|
- width: 86%;
|
|
|
- min-height: 200px;
|
|
|
- transform: translate3d(-50%,-50%,0);
|
|
|
- border-radius: 8px;
|
|
|
- z-index: 2;
|
|
|
- background-color: #fff;
|
|
|
- overflow: hidden;
|
|
|
+
|
|
|
+ .app-bottom-button {
|
|
|
+ color: #fff;
|
|
|
+ background-color: $main;
|
|
|
+ padding: 4px 8px;
|
|
|
+ border: none;
|
|
|
+ font-size: 16px;
|
|
|
+ border-radius: 4px;
|
|
|
}
|
|
|
}
|
|
|
+.mobile-leave-dialog {
|
|
|
+ display: flex;
|
|
|
+ align-items: flex-end; /* 内容置底 */
|
|
|
+}
|
|
|
</style>
|