public IHttpActionResult SetLightingScene(LightSceneEntity lightscene) { LightSceneEntity lightScenetemp = new LightSceneEntity(); lightscene.Value = EnumConstants.GetEnumValueFromDescription <LightSceneEnum>(lightscene.LightScene).ToString(); var lightScene = BackNetWriteAction.SetConfLightScene(lightscene); var lightLevel = BackNetReadAction.GetConfLightLevel(lightscene.DeviceID); var deviceDetail = new DeviceDetailEnity { DeviceID = lightScene.DeviceID, LightScene = lightScene.LightScene, LightSceneValue = lightScene.Value, LightLevel = lightLevel.LightLevel, //LightState = lightState.LightState }; return(Ok(deviceDetail)); }
public IHttpActionResult SetConfLightScene(LightSceneEntity lightSceneEntity) { var lightLevel = BackNetWriteAction.SetConfLightScene(lightSceneEntity); return(Ok(lightLevel)); }