home.js 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. import $http from '@/common/request.js';
  2. function getUserHasFollowed() {
  3. return $http({
  4. url: `/home/indexWechatPublic`,
  5. });
  6. }
  7. export function getCompanyMapData(companyId) {
  8. return $http({
  9. url: `/config/map/${companyId}`,
  10. method: 'GET',
  11. });
  12. }
  13. //查询受控列表
  14. export function queryControlSpaceCompany(params) {
  15. return $http({
  16. url: `/controlSpaceUser/getControlSpaceCompany`,
  17. method: 'POST',
  18. serverSp:'http://192.168.4.29:52015',
  19. data: JSON.stringify(params)
  20. })
  21. }
  22. //常驻空间快速调节卡片
  23. export function querySpaceFunctionCard(params) {
  24. return $http({
  25. url: `/controlSpaceUser/queryPermanentSpaceFunctionCard?userId=${params.userId}&companyId=${params.companyId}`,
  26. method: 'GET',
  27. serverSp:'http://192.168.4.29:52015'
  28. });
  29. }
  30. //常驻空间参数属性
  31. export function getSpaceProperty(params) {
  32. return $http({
  33. url: `/duoduo-service/duoduoenv-service/custom/spaceProperty?projectId=${params.projectId}&spaceId=${params.spaceId}`,
  34. method: 'GET'
  35. });
  36. }
  37. //切换公司
  38. export function switchCompany(companyId) {
  39. return $http({
  40. url: `/duoduo-service/duoduoenv-service/userNew/switchCompany/${companyId}`,
  41. method: 'POST',
  42. isComParams: false,
  43. });
  44. }
  45. // 天气预报
  46. export function getWeather(projectId) {
  47. return $http({
  48. isNotShowErrorToast: true,
  49. url: `/duoduo-service/object-service/weather/getCurrentWeather?projectId=${projectId}`,
  50. method: 'get'
  51. });
  52. }
  53. export { getUserHasFollowed };