| 123456789101112131415161718192021222324252627282930313233 |
- import request from '@/utils/request'
- import constant from '@/constant'
- function getXMLConfig(deviceNo,url){
- var encUrl = encodeURIComponent(url);
- return request.get(constant.serverUrl + `/ehome/getXMLConfig?deviceNo=${deviceNo}&url=${encUrl}`);
- }
- function putXMLConfig(deviceNo,url,jsonData){
- var encUrl = encodeURIComponent(url);
- return request.put(constant.serverUrl + `/ehome/setXMLConfig?deviceNo=${deviceNo}&url=${encUrl}`, jsonData,{
- headers: {
- "Content-Type": "application/json"
- }
- });
- }
- function postXMLConfig(deviceNo,url,jsonData){
- var encUrl = encodeURIComponent(url);
- return request.post(constant.serverUrl + `/ehome/setXMLConfig?deviceNo=${deviceNo}&url=${encUrl}`, jsonData,{
- headers: {
- "Content-Type": "application/json"
- }
- });
- }
- export default {
- getXMLConfig,putXMLConfig,postXMLConfig
- }
|