index.js 463 B

123456789101112131415161718192021
  1. // api/index.js - 集中管理API接口
  2. // 基础URL
  3. const BASE_URL = getApp().globalData.apiUrl || 'http://dev-rfid.7in6.com/index.php/api/index';
  4. // API接口集合
  5. const API = {
  6. // 获取栋舍列表
  7. getBuilding: `${BASE_URL}/get_building`,
  8. // 获取房间列表
  9. getRoom: `${BASE_URL}/get_room`,
  10. // 获取栏位列表
  11. getField: `${BASE_URL}/get_field`,
  12. // 提交数据
  13. postListAdd: `${BASE_URL}/post_listadd`,
  14. };
  15. export default API;