import { http } from './http' //是否为测试环境 const test = false; // 需要先调用远程权限的接口 function getopenId(code) { return http.get('/duoduo-service/wechat-service/wechat/app/getOpenId', { code: code }) } function getuserPhone(data) { return http.get('/duoduo-service/wechat-service/wechat/app/getUserInfo', data) } function userCheck(data) { return http.get('/server/user/check', data) } function userSave(data) { return http.post('/server/user/save', data) } function userQuery(data) { return http.post('/server/user/query', data) } function userUpdate(data) { return http.post('/server/user/update', data) } function spaceProperty(data) { return http.get('/server/custom/spaceProperty', data, test) } function queryChart(data) { return http.get('/server/space/queryPeriodData', data) } function queryAllspace(data) { return http.post('/server/space/queryAll', data, test) } function queryFollowspace(data) { return http.post('/server/space/querySubscribe', data) } function powerCheck(data) { return http.post('/server/custom/check', data, test) } function workLeave(data) { return http.post('/server/custom/leave', data, test) } function nextOpen(data) { return http.post('/server/custom/nextOpenTime', data, test) } function getfeedBack(data) { return http.post('/server/custom/feedbackCreate', data, test) } function getSpacedetail(data) { return http.post('/server/space/property', data, test) } function openSpace(data) { return http.post('/server/custom/recover', data, test) } function comfirmCodeLogin(data) { return http.post('/duoduo-service/setup-service/padLogin/confirmPadLogin', data) } function getEquipmentAction(data) { return http.post('/server/custom/getEquipmentAction', data, test) } function getSpaceAdjustList(data) { return http.post('/server/spaceAdjust/getSpaceAdjustList', data, test) } function getPropertyData(data) { return http.get('/server/spaceAdjust/queryPropertyData', data, test) } function getFeedbackList(data) { return http.post('/server/custom/adjustSpaceList', data, test) } function getfeedbackSeason(data) { return http.post('/server/feedbackSeason/query', data, test) } function getSpaceNum(data) { return http.post('/server/spaceAdjust/getSpaceNum', data, test) } function spaceTop(data) { return http.post('/server/spaceAdjust/pcSaveAndUpdate', data, test) } function deleteSpaceAdjust(data) { return http.get('/server/spaceAdjust/delete', data, test) } function gethouseKeeper(data) { return http.get('/server/duoduoenv/customerservice/queryCustomer', data, test) } function getSeasonType(data) { return http.get('/duoduo-service/custom-service/custom/getSeasonType', data, test) } function getWeather(data) { return http.get('/duoduo-service/object-service/weather/getCurrentWeather', data, test) } function submitFeedback(data) { return http.post('/server/feedbackSuggest/save', data, test) } function submitAdjust(data) { return http.post('/server/custom/custormPlan', data, test) } function getCurrentSeason(data) { return http.get('/duoduo-service/custom-service/custom/getSeasonType', data, test) } function contactTenant(data) { return http.post('/server/spaceAdjust/adjustSpace', data, test) } function getTransfrom(data) { return http.get('/duoduo-service/custom-service/custom/getSeasonBySeasonDate', data, test) } function queryQuestion(data) { return http.post('/server/question/queryQuestion', data, test) } function queryUseranswer(data) { return http.post('/server/question/queryShowQuestion', data, test) } function submitAnswer(data) { return http.post('/server/question/saveUserQuestion', data, test) } function notShowQuestion(data) { return http.post('/server/question/notShowQuestion', data, test) } module.exports = { getopenId, // 获取到openId getuserPhone, // 获取用户电话 userCheck, // 检查用户是否注册 userSave, // 创建用户 userQuery, // 查询用户 userUpdate, // 更新用户 spaceProperty,// 空间当前状态 queryChart, // 查询空间温度曲线 queryAllspace, //查询所有空间列表 queryFollowspace, //查询所有关注列表 powerCheck, // 查询是否有调节权限 workLeave, // 下班节能 nextOpen, // 下次开启时间 getfeedBack, // 反馈 getSpacedetail, // 查询空间信息 openSpace, // 下班后开启调节 getEquipmentAction, // 查询反馈后设备动作 getSpaceAdjustList, //获取用户调节空间 getPropertyData,//获取各参数数据 getFeedbackList, // 获取调节记录 getfeedbackSeason, // 获取季节调节记录 getSpaceNum, //调节空间次数和数量 spaceTop, //置顶 deleteSpaceAdjust, //删除 gethouseKeeper, //获取环境管家信息 getSeasonType, //获取季节 getWeather, //获取天气 submitFeedback, //提交反馈内容 submitAdjust, //提交温度计划 getCurrentSeason, //获取当前季节类型 contactTenant, //建立租户关系 getTransfrom, // 查询冬转夏 夏转东 queryQuestion, //查询调查问卷问题和答案 queryUseranswer, //查询用户是否要填写问卷 submitAnswer, //提交问卷答案 notShowQuestion, //不再展示问卷 comfirmCodeLogin // 二维码登录 }