邀约记录
This commit is contained in:
1 parent
a813da33ee
commit
8dc019eab5
6 files changed
+181
-346
No files matched your search
@@ -1,107 +0,0 @@
|
||||
<template>
|
||||
<crud-layout bg="/static/page/blue-bg.png">
|
||||
<z-paging
|
||||
ref="pageRef"
|
||||
height="100%"
|
||||
:fixed="false"
|
||||
v-model="pageHook.list"
|
||||
:default-page-size="10"
|
||||
safe-area-inset-bottom
|
||||
:loading-more-enabled="true"
|
||||
:show-scrollbar="false"
|
||||
@query="query"
|
||||
:auto-clean-list-when-reload="false"
|
||||
:auto-scroll-to-top-when-reload="false"
|
||||
@scroll="pageHook.scroll"
|
||||
>
|
||||
<template #top>
|
||||
<view class="h-30rpx" />
|
||||
<view class="bg-white rounded-16rpx px-20rpx">
|
||||
<z-tabs :list="tabs" @change="doTab" />
|
||||
</view>
|
||||
</template>
|
||||
<view class="h-20rpx" />
|
||||
<view class="flex-col justify-center card p-3 m-b-20rpx" v-for="(v, i) in pageHook.list" :key="i">
|
||||
<view class="flex-row items-center">
|
||||
<image class="w-110rpx h-110rpx rounded-8rpx" :src="filePath(v.logoPic)" mode="aspectFill" />
|
||||
<view class="flex-1 m-l-20rpx">
|
||||
<view class="flex-row items-center justify-between">
|
||||
<view class="flex-row items-center">
|
||||
<view class="main-text-28">{{ v.merchantName }}</view>
|
||||
<!-- <view class="m-l-15rpx color-#999 font-size-26rpx! iconfont icon-youjiantou" /> -->
|
||||
</view>
|
||||
<tm-tag v-if="v.orderStatus == 1" color="info" size="xs">未支付</tm-tag>
|
||||
<tm-tag v-if="v.orderStatus == 5" color="success" size="xs">已支付</tm-tag>
|
||||
<tm-tag v-if="v.orderStatus == 10" color="error" size="xs">售后</tm-tag>
|
||||
<tm-tag v-if="v.orderStatus == 20" size="xs">已核销</tm-tag>
|
||||
<tm-tag v-if="v.orderStatus == 30" color="info" size="xs">已取消(智能柜)</tm-tag>
|
||||
</view>
|
||||
<view class="flex-row items-center justify-between m-t-5rpx">
|
||||
<view class="second-text-20">
|
||||
<text>下单时间</text>
|
||||
<text class="m-l-10rpx">{{ hooks.useTime(v.createTime, "{y}-{m}-{d} {h}:{i}:{s}") }}</text>
|
||||
</view>
|
||||
<view class="second-text-22">{{ hooks.useEnum("hardwareRefundStatusEnum", v.refundStatus) }}</view>
|
||||
</view>
|
||||
<view class="flex-row items-center justify-between m-t-5rpx">
|
||||
<view class="sub-text-24">
|
||||
<text v-if="v.payType == '9'">{{ v.productDesc }}</text>
|
||||
</view>
|
||||
<view class="main-text-30 color-red! text-right">¥ {{ hooks.useMoney(v.totalPrice) }}</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="flex items-center ml-[120rpx]">
|
||||
<view v-if="['5', '10'].includes(v.orderStatus)" class="w-500rpx flex-row items-center justify-end">
|
||||
<!-- <view v-if="v.orderStatus == 5 && v.orderType == 2" class="botder_btn" @tap.stop="doRefund(v)">退款</view> -->
|
||||
<view v-if="v.orderStatus == 5 && v.orderType == 2" class="m-l-20rpx botder_btn">核销码</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</z-paging>
|
||||
</crud-layout>
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import { ref, reactive } from "vue"
|
||||
import { onShow } from "@dcloudio/uni-app"
|
||||
import { hooks } from "@@/index"
|
||||
import { filePath } from "@@/utils/file"
|
||||
import zTabs from "@@/components/other/z-tabs/z-tabs.vue"
|
||||
|
||||
const tabs = [
|
||||
{ id: null, name: "全部", disabled: false },
|
||||
{ id: 1, name: "待核销", disabled: false },
|
||||
{ id: 5, name: "待到访", disabled: false },
|
||||
{ id: 10, name: "已到访", disabled: false },
|
||||
{ id: 20, name: "已取消", disabled: false },
|
||||
]
|
||||
|
||||
const state = reactive<any>({
|
||||
pa: {
|
||||
orderStatus: tabs[0].id,
|
||||
},
|
||||
})
|
||||
|
||||
onShow(async () => {
|
||||
const isLogin = await hooks.useCheckLogin()
|
||||
if (!isLogin) return
|
||||
if (pageRef.value) {
|
||||
pageRef.value.reload(false)
|
||||
}
|
||||
})
|
||||
|
||||
const doTab = (e: any) => {
|
||||
const target = tabs[e]
|
||||
state.pa.orderStatus = target.id
|
||||
pageRef.value.reload(true)
|
||||
}
|
||||
|
||||
const pageRef = ref<any>(null)
|
||||
const pageHook = hooks.usePage(pageRef, async () => [], null, "data.records")
|
||||
const query = (page: number, pagesize: number) => {
|
||||
const isLogin = hooks.useStaticCheckLogin()
|
||||
if (!isLogin) return
|
||||
pageHook.startPage(page, pagesize, false, state.pa)
|
||||
}
|
||||
</script>
|
||||
@@ -1,121 +0,0 @@
|
||||
<template>
|
||||
<crud-layout mainIsScroll bg="/static/page/blue-bg.png">
|
||||
<view class="h-30rpx" />
|
||||
|
||||
<tm-sheet margin="[0, 20]">
|
||||
<view class="mx-auto text-center text-lg">访客邀约</view>
|
||||
<tm-form @submit="onsubmit" v-model="form" :rules="rules">
|
||||
<tm-form-item name="username" label="访客姓名">
|
||||
<tm-input color="transparent" v-model="form.username" placeholder="访客姓名" />
|
||||
</tm-form-item>
|
||||
<tm-form-item name="username" label="访客手机号">
|
||||
<tm-input color="transparent" v-model="form.username" placeholder="访客手机号" />
|
||||
</tm-form-item>
|
||||
<tm-form-item name="username" label="来访公司名称">
|
||||
<tm-input color="transparent" v-model="form.username" placeholder="来访公司名称" />
|
||||
</tm-form-item>
|
||||
<tm-form-item name="pingtai" label="拜访原因">
|
||||
<tm-picker
|
||||
v-model="form.pingtai"
|
||||
v-model:modelStr="_pingtaistr"
|
||||
rangText="name"
|
||||
:list="[
|
||||
{ id: 1, name: '1111' },
|
||||
{ id: 2, name: '2222' },
|
||||
{ id: 3, name: '3333' },
|
||||
]"
|
||||
>
|
||||
<tm-input :modelValue="_pingtaistr" placeholder="请选择拜访原因" style="pointer-events: none" disabled color="transparent">
|
||||
<template v-slot:rightIcon>
|
||||
<tm-icon name="arrow-right-s-line"></tm-icon>
|
||||
</template>
|
||||
</tm-input>
|
||||
</tm-picker>
|
||||
</tm-form-item>
|
||||
<tm-form-item name="time" label="到访时间">
|
||||
<tm-picker-date v-model="form.time" v-model:modelStr="_timestr" type="minute" start="2020-01-01 00:00" end="2080-01-01 23:59">
|
||||
<tm-input :modelValue="form.time" placeholder="请选择到访时间" style="pointer-events: none" disabled color="transparent">
|
||||
<template v-slot:rightIcon>
|
||||
<tm-icon name="arrow-right-s-line"></tm-icon>
|
||||
</template>
|
||||
</tm-input>
|
||||
</tm-picker-date>
|
||||
</tm-form-item>
|
||||
<tm-form-item name="pingtai" label="拜访部门">
|
||||
<tm-picker
|
||||
v-model="form.pingtai"
|
||||
v-model:modelStr="_pingtaistr"
|
||||
rangText="name"
|
||||
:list="[
|
||||
{ id: 1, name: '1111' },
|
||||
{ id: 2, name: '2222' },
|
||||
{ id: 3, name: '3333' },
|
||||
]"
|
||||
>
|
||||
<tm-input :modelValue="_pingtaistr" placeholder="请选择拜访部门" style="pointer-events: none" disabled color="transparent">
|
||||
<template v-slot:rightIcon>
|
||||
<tm-icon name="arrow-right-s-line"></tm-icon>
|
||||
</template>
|
||||
</tm-input>
|
||||
</tm-picker>
|
||||
</tm-form-item>
|
||||
<tm-form-item name="username" label="随行人员">
|
||||
<view class="flex">
|
||||
<tm-input color="transparent" v-model="form.username" placeholder="姓名" />
|
||||
|
||||
<tm-input color="transparent" v-model="form.username" placeholder="手机号" />
|
||||
</view>
|
||||
<view class="flex">
|
||||
<tm-input color="transparent" v-model="form.username" placeholder="姓名" />
|
||||
|
||||
<tm-input color="transparent" v-model="form.username" placeholder="手机号" />
|
||||
</view>
|
||||
</tm-form-item>
|
||||
|
||||
<tm-button form-type="submit" block>提交</tm-button>
|
||||
</tm-form>
|
||||
</tm-sheet>
|
||||
</crud-layout>
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import { ref } from "vue"
|
||||
|
||||
const form = ref({
|
||||
username: "",
|
||||
price: "",
|
||||
checkbox: [] as string[],
|
||||
radio: "",
|
||||
time: "2024-6-5",
|
||||
pingtai: [] as string[],
|
||||
store: 0,
|
||||
score: 0,
|
||||
textarea: "",
|
||||
})
|
||||
|
||||
const _timestr = ref(form.value.time)
|
||||
const _pingtaistr = ref("")
|
||||
|
||||
const rules: Record<string, TM.FORM_RULE[]> = {
|
||||
username: [{ required: true, message: "姓名2到5个字符", rule: /^.{2,5}$/ }],
|
||||
address: [
|
||||
{ required: true, message: "地址不能为空" },
|
||||
{ required: true, message: "长度要小于3", max: 2 },
|
||||
],
|
||||
price: [{ required: true, message: "价格要大于等于99", type: "number", min: 99 }],
|
||||
checkbox: [{ required: true }],
|
||||
radio: [{ required: true }],
|
||||
time: [{ required: true, type: "date" }],
|
||||
pingtai: [{ required: true }],
|
||||
store: [{ required: true, min: 1, max: 100, message: "介于1-100之间" }],
|
||||
score: [{ required: true, min: 5, max: 5, message: "必须打5分哦" }],
|
||||
textarea: [{ required: true, max: 100, message: "请输入内容" }],
|
||||
}
|
||||
|
||||
// 表单提交
|
||||
const onsubmit = (evt: TM.FORM_SUBMIT_RESULT) => {
|
||||
console.log("校验结果:", evt)
|
||||
if (!evt.isPass) return
|
||||
uni.showModal({ title: "提示", content: "确认提交吗?", confirmColor: "#0094ff" })
|
||||
}
|
||||
</script>
|
||||
@@ -1,106 +0,0 @@
|
||||
<template>
|
||||
<crud-layout bg="/static/page/blue-bg.png">
|
||||
<z-paging
|
||||
ref="pageRef"
|
||||
height="100%"
|
||||
:fixed="false"
|
||||
v-model="pageHook.list"
|
||||
:default-page-size="10"
|
||||
safe-area-inset-bottom
|
||||
:loading-more-enabled="true"
|
||||
:show-scrollbar="false"
|
||||
@query="query"
|
||||
:auto-clean-list-when-reload="false"
|
||||
:auto-scroll-to-top-when-reload="false"
|
||||
@scroll="pageHook.scroll"
|
||||
>
|
||||
<template #top>
|
||||
<view class="h-30rpx" />
|
||||
<view class="bg-white rounded-16rpx px-20rpx">
|
||||
<z-tabs :list="tabs" @change="doTab" />
|
||||
</view>
|
||||
</template>
|
||||
<view class="h-20rpx" />
|
||||
<view class="flex-col justify-center card p-3 m-b-20rpx" v-for="(v, i) in pageHook.list" :key="i">
|
||||
<view class="flex-row items-center">
|
||||
<image class="w-110rpx h-110rpx rounded-8rpx" :src="filePath(v.logoPic)" mode="aspectFill" />
|
||||
<view class="flex-1 m-l-20rpx">
|
||||
<view class="flex-row items-center justify-between">
|
||||
<view class="flex-row items-center">
|
||||
<view class="main-text-28">{{ v.merchantName }}</view>
|
||||
<!-- <view class="m-l-15rpx color-#999 font-size-26rpx! iconfont icon-youjiantou" /> -->
|
||||
</view>
|
||||
<tm-tag v-if="v.orderStatus == 1" color="info" size="xs">未支付</tm-tag>
|
||||
<tm-tag v-if="v.orderStatus == 5" color="success" size="xs">已支付</tm-tag>
|
||||
<tm-tag v-if="v.orderStatus == 10" color="error" size="xs">售后</tm-tag>
|
||||
<tm-tag v-if="v.orderStatus == 20" size="xs">已核销</tm-tag>
|
||||
<tm-tag v-if="v.orderStatus == 30" color="info" size="xs">已取消(智能柜)</tm-tag>
|
||||
</view>
|
||||
<view class="flex-row items-center justify-between m-t-5rpx">
|
||||
<view class="second-text-20">
|
||||
<text>下单时间</text>
|
||||
<text class="m-l-10rpx">{{ hooks.useTime(v.createTime, "{y}-{m}-{d} {h}:{i}:{s}") }}</text>
|
||||
</view>
|
||||
<view class="second-text-22">{{ hooks.useEnum("hardwareRefundStatusEnum", v.refundStatus) }}</view>
|
||||
</view>
|
||||
<view class="flex-row items-center justify-between m-t-5rpx">
|
||||
<view class="sub-text-24">
|
||||
<text v-if="v.payType == '9'">{{ v.productDesc }}</text>
|
||||
</view>
|
||||
<view class="main-text-30 color-red! text-right">¥ {{ hooks.useMoney(v.totalPrice) }}</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="flex items-center ml-[120rpx]">
|
||||
<view v-if="['5', '10'].includes(v.orderStatus)" class="w-500rpx flex-row items-center justify-end">
|
||||
<!-- <view v-if="v.orderStatus == 5 && v.orderType == 2" class="botder_btn" @tap.stop="doRefund(v)">退款</view> -->
|
||||
<view v-if="v.orderStatus == 5 && v.orderType == 2" class="m-l-20rpx botder_btn">核销码</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</z-paging>
|
||||
</crud-layout>
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import { ref, reactive } from "vue"
|
||||
import { onShow } from "@dcloudio/uni-app"
|
||||
import { hooks } from "@@/index"
|
||||
import { filePath } from "@@/utils/file"
|
||||
import zTabs from "@@/components/other/z-tabs/z-tabs.vue"
|
||||
|
||||
const tabs = [
|
||||
{ id: null, name: "全部", disabled: false },
|
||||
{ id: 1, name: "待审核", disabled: false },
|
||||
{ id: 5, name: "待到访", disabled: false },
|
||||
{ id: 20, name: "已取消", disabled: false },
|
||||
]
|
||||
|
||||
const state = reactive<any>({
|
||||
pa: {
|
||||
orderStatus: tabs[0].id,
|
||||
},
|
||||
})
|
||||
|
||||
onShow(async () => {
|
||||
const isLogin = await hooks.useCheckLogin()
|
||||
if (!isLogin) return
|
||||
if (pageRef.value) {
|
||||
pageRef.value.reload(false)
|
||||
}
|
||||
})
|
||||
|
||||
const doTab = (e: any) => {
|
||||
const target = tabs[e]
|
||||
state.pa.orderStatus = target.id
|
||||
pageRef.value.reload(true)
|
||||
}
|
||||
|
||||
const pageRef = ref<any>(null)
|
||||
const pageHook = hooks.usePage(pageRef, async () => [], null, "data.records")
|
||||
const query = (page: number, pagesize: number) => {
|
||||
const isLogin = hooks.useStaticCheckLogin()
|
||||
if (!isLogin) return
|
||||
pageHook.startPage(page, pagesize, false, state.pa)
|
||||
}
|
||||
</script>
|
||||
@@ -128,14 +128,31 @@ const rules: Record<string, TM.FORM_RULE[]> = {
|
||||
companyName: [{ required: true, message: "请输入来访公司名称" }],
|
||||
vStartDate: [{ required: true, message: "请选择拜访开始时间" }],
|
||||
vEndDate: [{ required: true, message: "请选择拜访离开时间" }],
|
||||
// deptId: [{ required: true, message: "请选择拜访部门" }],
|
||||
// reasonValue: [{ required: true, message: "请选择拜访原因" }],
|
||||
deptId: [{ required: true, message: "请选择拜访部门" }],
|
||||
reasonValue: [{ required: true, message: "请选择拜访原因" }],
|
||||
}
|
||||
|
||||
// 表单提交
|
||||
const onsubmit = (evt: TM.FORM_SUBMIT_RESULT) => {
|
||||
console.log("校验结果:", evt)
|
||||
if (!evt.isPass) return
|
||||
uni.showModal({ title: "提示", content: "确认提交吗?", confirmColor: "#0094ff" })
|
||||
uni.showModal({
|
||||
title: "提示",
|
||||
content: "确认提交吗?",
|
||||
confirmColor: "#0094ff",
|
||||
success: async () => {
|
||||
try {
|
||||
const { code, data, msg } = await invitationApi.saveInvitation(form)
|
||||
if (code == 0) {
|
||||
uni.showToast({ title: "提交成功", icon: "success" })
|
||||
uni.switchTab({ url: "/pages/tabbar/invitationRecord" })
|
||||
return
|
||||
}
|
||||
uni.showToast({ title: msg || "提交失败", icon: "none" })
|
||||
} catch (error: any) {
|
||||
uni.showToast({ title: error.message || "提交失败", icon: "none" })
|
||||
}
|
||||
},
|
||||
})
|
||||
}
|
||||
</script>
|
||||
@@ -1,3 +1,137 @@
|
||||
<template></template>
|
||||
<template>
|
||||
<crud-layout bg="/static/page/blue-bg.png">
|
||||
<z-paging
|
||||
ref="pageRef"
|
||||
height="100%"
|
||||
:fixed="false"
|
||||
v-model="pageHook.list"
|
||||
:default-page-size="10"
|
||||
safe-area-inset-bottom
|
||||
:loading-more-enabled="true"
|
||||
:show-scrollbar="false"
|
||||
@query="query"
|
||||
:auto-clean-list-when-reload="false"
|
||||
:auto-scroll-to-top-when-reload="false"
|
||||
@scroll="pageHook.scroll"
|
||||
>
|
||||
<template #top>
|
||||
<view class="bg-white rounded-20rpx my-20rpx font-bold">
|
||||
<z-tabs
|
||||
:list="[
|
||||
{ name: '审核申请', value: 0 },
|
||||
{ name: '我的邀约', value: 1 },
|
||||
]"
|
||||
bar-width="150"
|
||||
:active-style="{
|
||||
fontSize: '30rpx',
|
||||
}"
|
||||
:inactive-style="{
|
||||
fontSize: '30rpx',
|
||||
}"
|
||||
@change="onTabChange"
|
||||
/>
|
||||
</view>
|
||||
|
||||
<script setup lang="ts"></script>
|
||||
<view class="bg-white rounded-16rpx px-20rpx">
|
||||
<z-tabs :list="tabs" @change="doTab" />
|
||||
</view>
|
||||
<view class="h-20rpx" />
|
||||
</template>
|
||||
<view class="flex-col justify-center card p-3 m-b-20rpx" v-for="(v, i) in pageHook.list" :key="i">
|
||||
<view class="flex justify-between items-center">
|
||||
<view v-if="v.checkStatus == '1'" class="p-1 c-white! sub-text-26 rounded-1 bg-#f5a623">待审核</view>
|
||||
<view v-if="v.checkStatus == '2'" class="p-1 c-white! sub-text-26 rounded-1 bg-#2db7f5">待到访</view>
|
||||
<view v-if="v.checkStatus == '3'" class="p-1 c-white! sub-text-26 rounded-1 bg-#52c41a">已拒绝</view>
|
||||
<view v-if="v.checkStatus == '5'" class="p-1 c-white! sub-text-26 rounded-1 bg-#f5222d">已取消</view>
|
||||
<view class="sub-text-26">{{ v.vstartDate + " ~ " + v.vendDate }}</view>
|
||||
</view>
|
||||
<view class="flex justify-center items-center my-2">
|
||||
<view class="sub-text-32 mr-4 flex-col-center font-italic bg-#ECF4F9 p-4 rounded-lt-12 rounded-rb-12">
|
||||
<view>{{ v.name }}</view>
|
||||
<view>{{ v.mobile }}</view>
|
||||
</view>
|
||||
<view class="second-text-28 bg-#ECF4F9 p-4 rounded-lb-12 rounded-rt-12">接待人:{{ v.userName }}</view>
|
||||
</view>
|
||||
<view v-if="v.checkStatus == 1" class="flex justify-end items-center gap-2">
|
||||
<tm-modal title="确定审核通过吗?" height="auto" @confirm="visitorCheck(v.id, 2)">
|
||||
<template v-slot:trigger><tm-button class="px-1" size="s">审核通过</tm-button></template>
|
||||
</tm-modal>
|
||||
<tm-modal title="确定审核拒绝吗?" height="auto" @confirm="visitorCheck(v.id, 3)">
|
||||
<template v-slot:trigger><tm-button class="px-1" size="s" color="danger">审核拒绝</tm-button></template>
|
||||
</tm-modal>
|
||||
</view>
|
||||
</view>
|
||||
</z-paging>
|
||||
</crud-layout>
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import { ref, reactive } from "vue"
|
||||
import { onLoad, onShow } from "@dcloudio/uni-app"
|
||||
import { hooks } from "@@/index"
|
||||
import zTabs from "@@/components/other/z-tabs/z-tabs.vue"
|
||||
import { invitationApi } from "@/sheep/api"
|
||||
|
||||
const tabs = [
|
||||
{ value: "", name: "全部", disabled: false },
|
||||
{ value: "1", name: "待审核", disabled: false },
|
||||
{ value: "2", name: "待到访", disabled: false },
|
||||
{ value: "3", name: "已拒绝", disabled: false },
|
||||
{ value: "5", name: "已取消", disabled: false },
|
||||
]
|
||||
|
||||
const state = reactive<any>({
|
||||
params: {
|
||||
checkStatus: tabs[0].value,
|
||||
type: 1, // type为1:主动申请 type为2:邀约 type为3:后台创建
|
||||
},
|
||||
})
|
||||
const pageRef = ref<any>(null)
|
||||
|
||||
onLoad(() => {
|
||||
const app = getApp()
|
||||
app._initTabbar()
|
||||
})
|
||||
|
||||
onShow(async () => {
|
||||
const isLogin = await hooks.useCheckLogin()
|
||||
if (!isLogin) return
|
||||
if (pageRef.value) {
|
||||
pageRef.value.reload(false)
|
||||
}
|
||||
})
|
||||
|
||||
const doTab = (e: any) => {
|
||||
const target = tabs[e]
|
||||
state.params.checkStatus = target.value
|
||||
pageRef.value.reload(true)
|
||||
}
|
||||
|
||||
const pageHook = hooks.usePage(pageRef, invitationApi.getInvitationRecord, null, "data.records")
|
||||
|
||||
const query = (page: number, pagesize: number) => {
|
||||
const isLogin = hooks.useStaticCheckLogin()
|
||||
if (!isLogin) return
|
||||
pageHook.startPage(page, pagesize, false, state.params)
|
||||
}
|
||||
|
||||
const onTabChange = (e: number) => {
|
||||
state.params.type = e + 1
|
||||
pageRef.value.reload(false)
|
||||
}
|
||||
|
||||
// 审核通过/拒绝
|
||||
const visitorCheck = async (id: string, checkStatus: number | string) => {
|
||||
try {
|
||||
const { code, msg } = await invitationApi.updateCheckStatus({ id, checkStatus })
|
||||
if (code == 0) {
|
||||
uni.showToast({ title: "操作成功", icon: "success" })
|
||||
pageRef.value.reload(false)
|
||||
return
|
||||
}
|
||||
uni.showToast({ title: msg, icon: "error" })
|
||||
} catch (error: any) {
|
||||
uni.showToast({ title: error.message, icon: "error" })
|
||||
}
|
||||
}
|
||||
</script>
|
||||
@@ -7,11 +7,29 @@ export default {
|
||||
url: `/integrated/app/visitor/getDictListByType?type=${type}`,
|
||||
method: "GET",
|
||||
}),
|
||||
}
|
||||
|
||||
// const updateCheckStatus = () => {
|
||||
// request({
|
||||
// url: `/integrated/visitors/app/updateCheckStatus?id=1950037876011745282&checkStatus=2`,
|
||||
// method: "GET",
|
||||
// })
|
||||
// }
|
||||
// 保存访客邀约
|
||||
saveInvitation: (data: any): Promise<any> =>
|
||||
request({
|
||||
url: `/integrated/visitors/app/saveYY`,
|
||||
method: "POST",
|
||||
data,
|
||||
}),
|
||||
|
||||
// 获取访客邀约列表
|
||||
// type为1:主动申请 type为2:邀约 type为3:后台创建
|
||||
getInvitationRecord: (params: { current: number; size: number; checkStatus?: string; type?: number }): Promise<any> =>
|
||||
request({
|
||||
url: `/integrated/visitors/app/yy/page`,
|
||||
method: "GET",
|
||||
params,
|
||||
}),
|
||||
|
||||
// 更新审核状态通过 2:通过 3:拒绝
|
||||
updateCheckStatus: (params: { id: string; checkStatus: number | string }): Promise<any> =>
|
||||
request({
|
||||
url: `/integrated/visitors/app/updateCheckStatus`,
|
||||
method: "GET",
|
||||
params,
|
||||
}),
|
||||
}
|
||||
Reference in new issue
Block a user