api.js 1.1 KB

1234567891011121314151617181920212223242526272829303132
  1. // /api/v1/mobile/checkinRoomInfo 获取入住房间和门锁设备信息
  2. export const getCheckinInfoAndLockInfo = () => {
  3. return uni.$http.get(`/mobile/checkinRoomInfo`);
  4. };
  5. // /api/v1/mobile/lockKey/{hotelId} 获取蓝牙设备密钥
  6. export const getBluetoothKey = (hotelId) => {
  7. return uni.$http.get(`/mobile/lockKey/${hotelId}`);
  8. };
  9. // /api/v1/mobile/uploadDoorLog/{hotelId} 上传开门记录
  10. export const uploadDoorLog = (hotelId, data) => {
  11. return uni.$http.post(`/mobile/uploadDoorLog/${hotelId}`, data);
  12. };
  13. // /api/v1/mobile/uploadPowerLog/{hotelId} 上传门锁电量
  14. export const uploadPowerLog = (hotelId, data) => {
  15. return uni.$http.post(`/mobile/uploadPowerLog/${hotelId}`, data);
  16. };
  17. // 远程开门
  18. export const remoteOpenDoor = (hotelId, bluetoothId) => {
  19. return uni.$http.post(`/mobile/openDoor/${hotelId}/${bluetoothId}`);
  20. };
  21. // 小程序上传每次的蓝牙开门的记录 /api/v1/miniScmApp/bleOpLogs
  22. export const unloadBLEOpenDoorLog = (data) => {
  23. return uni.$http.post(`/bleOpLogs`, data);
  24. };
  25. export const getCheckinInfo = (data) => {
  26. return uni.$http.post("/checkinInfo/queryByCondition", data)
  27. }