增加来访核验

This commit is contained in:
chenglijuan
2026-04-29 15:35:20 +08:00
parent 1ae4ba166a
commit f1d1c9b460
5 changed files with 98 additions and 3 deletions
+15
View File
@@ -197,6 +197,21 @@ const appointmentDB = {
data: { department }
})
return data || []
},
/**
* 核销通知被访人
* @param {string} id - 预约记录 id
* @returns {Promise<boolean>}
*/
async notifyHost(id) {
await request({
url: BASE_URL + API.NOTIFY_HOST,
method: 'POST',
header: { 'content-type': 'application/json' },
data: { id }
})
return true
}
}
+2 -1
View File
@@ -29,7 +29,8 @@ const API = {
APPOINTMENT_CANCEL: '/api/wx-mini/appointment/cancel',
APPOINTMENT_DETAIL: '/api/wx-mini/appointment/detail',
WXACODE: '/api/wx-mini/wxacode',
PERSON_SELECTOR: '/api/wx-mini/appointment/person/selector'
PERSON_SELECTOR: '/api/wx-mini/appointment/person/selector',
NOTIFY_HOST: '/visitor/notify-host'
}
console.log('[config] 当前环境:', wx.getAccountInfoSync().miniProgram.envVersion, 'BASE_URL:', BASE_URL)