Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/genielabs/HomeGenie
Browse files Browse the repository at this point in the history
Conflicts:
	BaseFiles/Common/programs.xml
  • Loading branch information
root authored and root committed Jan 25, 2015
2 parents 9e6f557 + 7c7542e commit f8775bf
Show file tree
Hide file tree
Showing 9 changed files with 37 additions and 9,607 deletions.
12 changes: 0 additions & 12 deletions BaseFiles/Common/groups.xml
Original file line number Diff line number Diff line change
Expand Up @@ -11,18 +11,6 @@
<Address>90</Address>
<Domain>HomeAutomation.HomeGenie.Automation</Domain>
</ModuleReference>
<ModuleReference>
<Address>Scheduling</Address>
<Domain>HomeGenie.UI.Separator</Domain>
</ModuleReference>
<ModuleReference>
<Address>511</Address>
<Domain>HomeAutomation.HomeGenie.Automation</Domain>
</ModuleReference>
<ModuleReference>
<Address>510</Address>
<Domain>HomeAutomation.HomeGenie.Automation</Domain>
</ModuleReference>
<ModuleReference>
<Address>Resources on the web</Address>
<Domain>HomeGenie.UI.Separator</Domain>
Expand Down
Binary file modified BaseFiles/Common/homegenie_factory_config.zip
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -49,16 +49,16 @@
if((moduleTH != null) && (moduleTH.Name == 'Tables horaires'))
{
var tabHOR = HG.WebApp.Utility.GetModulePropertyByName(module, 'Table.W');
var tabletherm= HG.WebApp.Utility.GetModulePropertyByName(moduleTH, 'ConfigureOptions.Table.Light.'+tabHOR.Value);
var tabletherm= HG.WebApp.Utility.GetModulePropertyByName(moduleTH, 'ConfigureOptions.Table.OnOff.'+tabHOR.Value);
drawTable(controlpopup.find('[id=tableW]')[0].getContext('2d'),tabletherm.Value,'Week-End - Table horaire '+tabHOR.Value,(typeDay=='W'),hourC,minC);
tabHOR = HG.WebApp.Utility.GetModulePropertyByName(module, 'Table.O');
tabletherm = HG.WebApp.Utility.GetModulePropertyByName(moduleTH, 'ConfigureOptions.Table.Light.'+tabHOR.Value);
tabletherm = HG.WebApp.Utility.GetModulePropertyByName(moduleTH, 'ConfigureOptions.Table.OnOff.'+tabHOR.Value);
drawTable(controlpopup.find('[id=tableO]')[0].getContext('2d'),tabletherm.Value,'Ouvré - Table horaire '+tabHOR.Value,(typeDay=='O'),hourC,minC);
tabHOR = HG.WebApp.Utility.GetModulePropertyByName(module, 'Table.F');
tabletherm = HG.WebApp.Utility.GetModulePropertyByName(moduleTH, 'ConfigureOptions.Table.Light.'+tabHOR.Value);
tabletherm = HG.WebApp.Utility.GetModulePropertyByName(moduleTH, 'ConfigureOptions.Table.OnOff.'+tabHOR.Value);
drawTable(controlpopup.find('[id=tableF]')[0].getContext('2d'),tabletherm.Value,'Férié - Table horaire '+tabHOR.Value,(typeDay=='F'),hourC,minC);
tabHOR = HG.WebApp.Utility.GetModulePropertyByName(module, 'Table.S');
tabletherm = HG.WebApp.Utility.GetModulePropertyByName(moduleTH, 'ConfigureOptions.Table.Light.'+tabHOR.Value);
tabletherm = HG.WebApp.Utility.GetModulePropertyByName(moduleTH, 'ConfigureOptions.Table.OnOff.'+tabHOR.Value);
drawTable(controlpopup.find('[id=tableS]')[0].getContext('2d'),tabletherm.Value,'Spécial - Table horaire '+tabHOR.Value,(typeDay=='S'),hourC,minC);
}
}
Expand All @@ -73,7 +73,7 @@
controlpopup.find('[id=tableO]').hide();
controlpopup.find('[id=tableF]').hide();
controlpopup.find('[id=tableS]').hide();
HG.Control.Modules.ServiceCall('Light.ModeSet', module.Domain, module.Address, 'Off', function (data) { });
HG.Control.Modules.ServiceCall('OnOff.ModeSet', module.Domain, module.Address, 'Off', function (data) { });
});
controlpopup.find('[data-ui-field=mode_on]').on('click', function(){
controlpopup.find('[data-ui-field=mode_off]').removeClass('ui-btn-active');
Expand All @@ -83,7 +83,7 @@
controlpopup.find('[id=tableO]').hide();
controlpopup.find('[id=tableF]').hide();
controlpopup.find('[id=tableS]').hide();
HG.Control.Modules.ServiceCall('Light.ModeSet', module.Domain, module.Address, 'On', function (data) { });
HG.Control.Modules.ServiceCall('OnOff.ModeSet', module.Domain, module.Address, 'On', function (data) { });
});
controlpopup.find('[data-ui-field=mode_prog]').on('click', function(){
controlpopup.find('[data-ui-field=mode_off]').removeClass('ui-btn-active');
Expand All @@ -93,7 +93,7 @@
controlpopup.find('[id=tableO]').show();
controlpopup.find('[id=tableF]').show();
controlpopup.find('[id=tableS]').show();
HG.Control.Modules.ServiceCall('Light.ModeSet', module.Domain, module.Address, 'Program', function (data) { });
HG.Control.Modules.ServiceCall('OnOff.ModeSet', module.Domain, module.Address, 'Program', function (data) { });
});

controlpopup.find('[id=tableW]').on("click",function(event){
Expand All @@ -107,9 +107,9 @@
if(_this.index == 2 && newtabHOR > 0)
newtabHOR-- ;
var moduleTH = HG.WebApp.Utility.GetModuleByDomainAddress('HomeAutomation.HomeGenie.Automation',moduleTabHOR);
var tabletherm= HG.WebApp.Utility.GetModulePropertyByName(moduleTH, 'ConfigureOptions.Table.Light.'+newtabHOR);
var tabletherm= HG.WebApp.Utility.GetModulePropertyByName(moduleTH, 'ConfigureOptions.Table.OnOff.'+newtabHOR);
drawTable(controlpopup.find('[id=tableW]')[0].getContext('2d'),tabletherm.Value,'Week-End - Table horaire '+newtabHOR,(typeDay=='W'),hourC,minC);
HG.Control.Modules.ServiceCall('Light.SetTable/W',module.Domain,module.Address,newtabHOR,function(data){ });
HG.Control.Modules.ServiceCall('OnOff.SetTable/W',module.Domain,module.Address,newtabHOR,function(data){ });
}
});
controlpopup.find('[id=tableO]').on("click",function(event){
Expand All @@ -123,9 +123,9 @@
if(_this.index == 2 && newtabHOR > 0)
newtabHOR-- ;
var moduleTH = HG.WebApp.Utility.GetModuleByDomainAddress('HomeAutomation.HomeGenie.Automation',moduleTabHOR);
var tabletherm= HG.WebApp.Utility.GetModulePropertyByName(moduleTH, 'ConfigureOptions.Table.Light.'+newtabHOR);
var tabletherm= HG.WebApp.Utility.GetModulePropertyByName(moduleTH, 'ConfigureOptions.Table.OnOff.'+newtabHOR);
drawTable(controlpopup.find('[id=tableO]')[0].getContext('2d'),tabletherm.Value,'Ouvré - Table horaire '+newtabHOR,(typeDay=='O'),hourC,minC);
HG.Control.Modules.ServiceCall('Light.SetTable/O',module.Domain,module.Address,newtabHOR,function(data){ });
HG.Control.Modules.ServiceCall('OnOff.SetTable/O',module.Domain,module.Address,newtabHOR,function(data){ });
}
});
controlpopup.find('[id=tableF]').on("click",function(event){
Expand All @@ -139,9 +139,9 @@
if(_this.index == 2 && newtabHOR > 0)
newtabHOR-- ;
var moduleTH = HG.WebApp.Utility.GetModuleByDomainAddress('HomeAutomation.HomeGenie.Automation',moduleTabHOR);
var tabletherm= HG.WebApp.Utility.GetModulePropertyByName(moduleTH, 'ConfigureOptions.Table.Light.'+newtabHOR);
var tabletherm= HG.WebApp.Utility.GetModulePropertyByName(moduleTH, 'ConfigureOptions.Table.OnOff.'+newtabHOR);
drawTable(controlpopup.find('[id=tableF]')[0].getContext('2d'),tabletherm.Value,'Férié - Table horaire '+newtabHOR,(typeDay=='F'),hourC,minC);
HG.Control.Modules.ServiceCall('Light.SetTable/F',module.Domain,module.Address,newtabHOR,function(data){ });
HG.Control.Modules.ServiceCall('OnOff.SetTable/F',module.Domain,module.Address,newtabHOR,function(data){ });
}
});
controlpopup.find('[id=tableS]').on("click",function(event){
Expand All @@ -155,9 +155,9 @@
if(_this.index == 2 && newtabHOR > 0)
newtabHOR-- ;
var moduleTH = HG.WebApp.Utility.GetModuleByDomainAddress('HomeAutomation.HomeGenie.Automation',moduleTabHOR);
var tabletherm= HG.WebApp.Utility.GetModulePropertyByName(moduleTH, 'ConfigureOptions.Table.Light.'+newtabHOR);
var tabletherm= HG.WebApp.Utility.GetModulePropertyByName(moduleTH, 'ConfigureOptions.Table.OnOff.'+newtabHOR);
drawTable(controlpopup.find('[id=tableS]')[0].getContext('2d'),tabletherm.Value,'Special - Table horaire '+newtabHOR,(typeDay=='S'),hourC,minC);
HG.Control.Modules.ServiceCall('Light.SetTable/S',module.Domain,module.Address,newtabHOR,function(data){ });
HG.Control.Modules.ServiceCall('OnOff.SetTable/S',module.Domain,module.Address,newtabHOR,function(data){ });
}
});
});
Expand All @@ -177,13 +177,13 @@

// light mode buttons events
widget.find('[data-ui-field=off]').on('click', function(){
HG.Control.Modules.ServiceCall('Light.ModeSet', module.Domain, module.Address, 'Off', function (data) { });
HG.Control.Modules.ServiceCall('OnOff.ModeSet', module.Domain, module.Address, 'Off', function (data) { });
});
widget.find('[data-ui-field=on]').on('click', function(){
HG.Control.Modules.ServiceCall('Light.ModeSet', module.Domain, module.Address, 'On', function (data) { });
HG.Control.Modules.ServiceCall('OnOff.ModeSet', module.Domain, module.Address, 'On', function (data) { });
});
widget.find('[data-ui-field=prog]').on('click', function(){
HG.Control.Modules.ServiceCall('Light.ModeSet', module.Domain, module.Address, 'Program', function (data) { });
HG.Control.Modules.ServiceCall('OnOff.ModeSet', module.Domain, module.Address, 'Program', function (data) { });
});

controlpopup.on('popupbeforeposition', function(evt, ui){
Expand All @@ -192,7 +192,7 @@
controlpopup.find('[data-ui-field=mode_on]').removeClass('ui-btn-active');
controlpopup.find('[data-ui-field=mode_prog]').removeClass('ui-btn-active');
// set current buttons' state from module properties
var thermostatMode = HG.WebApp.Utility.GetModulePropertyByName(module, 'Light.Mode');
var thermostatMode = HG.WebApp.Utility.GetModulePropertyByName(module, 'OnOff.Mode');
if (thermostatMode != null)
{
controlpopup.find('[id=tableW]').hide();
Expand Down Expand Up @@ -238,7 +238,7 @@
} else watts = '';

// get module operatingstate prop for status text
var operatingMode = HG.WebApp.Utility.GetModulePropertyByName(module, "Light.OperatingState");
var operatingMode = HG.WebApp.Utility.GetModulePropertyByName(module, "OnOff.OperatingState");
if(operatingMode != null) {
var updatetime = operatingMode.UpdateTime;
if(typeof updatetime != 'undefined') {
Expand Down Expand Up @@ -267,7 +267,7 @@
if (operatingMode.Value == 'On')
this.IconImage = this.IconImage.replace('_off', '_on');
var displayMode = '---';
var lightMode = HG.WebApp.Utility.GetModulePropertyByName(module, 'Light.Mode');
var lightMode = HG.WebApp.Utility.GetModulePropertyByName(module, 'OnOff.Mode');
if (lightMode != null) displayMode = lightMode.Value;
if( displayMode == 'Program' )
displayMode = 'Programmé';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,9 @@
var index,hDeb,mDeb,hFin,mFin,xDeb,xFin,cetat;
var szCfTrm="ConfigureOptions.Table.Therm.";
var szImgTrm="pages/control/widgets/homegenie/generic/images/temperature.png";
var szCfLight="ConfigureOptions.Table.Light.";
var szCfOnOff="ConfigureOptions.Table.OnOff.";
var szImgLight="pages/control/widgets/homegenie/generic/images/light_on.png";
var szCfShut="ConfigureOptions.Table.Shutter.";
var szCfLevel="ConfigureOptions.Table.Level.";
var szImgShut="pages/control/widgets/homegenie/generic/images/shutters_open.png";
var context,choice,numId;
var _this, etat;
Expand Down Expand Up @@ -286,7 +286,7 @@
controlpopup.find('[data-ui-field=icon]').attr('src',szImgLight);
controlpopup.find('[data-ui-field=group]').html(widget.find('[data-ui-field=id_title_light]').html());
controlpopup.find('[data-ui-field=name]').html(_this.TimeTableUI+"0");
_this.etat=HG.WebApp.Utility.GetModulePropertyByName(module,szCfLight+"0");
_this.etat=HG.WebApp.Utility.GetModulePropertyByName(module,szCfOnOff+"0");
if(_this.analyseClick($(cuid),_this.etat.Value,$(this).offset(),event) != -1)
{
_this.drawChoice(controlpopup.find('[data-ui-field=choice]')[0].getContext('2d'),_this.choice,_this.cetat,30);
Expand All @@ -299,7 +299,7 @@
controlpopup.find('[data-ui-field=icon]').attr('src',szImgLight);
controlpopup.find('[data-ui-field=group]').html(widget.find('[data-ui-field=id_title_light]').html());
controlpopup.find('[data-ui-field=name]').html(_this.TimeTableUI+"1");
_this.etat=HG.WebApp.Utility.GetModulePropertyByName(module,szCfLight+"1");
_this.etat=HG.WebApp.Utility.GetModulePropertyByName(module,szCfOnOff+"1");
if(_this.analyseClick($(cuid),_this.etat.Value,$(this).offset(),event) != -1)
{
_this.drawChoice(controlpopup.find('[data-ui-field=choice]')[0].getContext('2d'),_this.choice,_this.cetat,30);
Expand All @@ -312,7 +312,7 @@
controlpopup.find('[data-ui-field=icon]').attr('src',szImgLight);
controlpopup.find('[data-ui-field=group]').html(widget.find('[data-ui-field=id_title_light]').html());
controlpopup.find('[data-ui-field=name]').html(_this.TimeTableUI+"2");
_this.etat=HG.WebApp.Utility.GetModulePropertyByName(module,szCfLight+"2");
_this.etat=HG.WebApp.Utility.GetModulePropertyByName(module,szCfOnOff+"2");
if(_this.analyseClick($(cuid),_this.etat.Value,$(this).offset(),event) != -1)
{
_this.drawChoice(controlpopup.find('[data-ui-field=choice]')[0].getContext('2d'),_this.choice,_this.cetat,30);
Expand All @@ -325,7 +325,7 @@
controlpopup.find('[data-ui-field=icon]').attr('src',szImgLight);
controlpopup.find('[data-ui-field=group]').html(widget.find('[data-ui-field=id_title_light]').html());
controlpopup.find('[data-ui-field=name]').html(_this.TimeTableUI+"3");
_this.etat=HG.WebApp.Utility.GetModulePropertyByName(module,szCfLight+"3");
_this.etat=HG.WebApp.Utility.GetModulePropertyByName(module,szCfOnOff+"3");
if(_this.analyseClick($(cuid),_this.etat.Value,$(this).offset(),event) != -1)
{
_this.drawChoice(controlpopup.find('[data-ui-field=choice]')[0].getContext('2d'),_this.choice,_this.cetat,30);
Expand All @@ -338,7 +338,7 @@
controlpopup.find('[data-ui-field=icon]').attr('src',szImgLight);
controlpopup.find('[data-ui-field=group]').html(widget.find('[data-ui-field=id_title_light]').html());
controlpopup.find('[data-ui-field=name]').html(_this.TimeTableUI+"4");
_this.etat=HG.WebApp.Utility.GetModulePropertyByName(module,szCfLight+"4");
_this.etat=HG.WebApp.Utility.GetModulePropertyByName(module,szCfOnOff+"4");
if(_this.analyseClick($(cuid),_this.etat.Value,$(this).offset(),event) != -1)
{
_this.drawChoice(controlpopup.find('[data-ui-field=choice]')[0].getContext('2d'),_this.choice,_this.cetat,30);
Expand All @@ -351,7 +351,7 @@
controlpopup.find('[data-ui-field=icon]').attr('src',szImgLight);
controlpopup.find('[data-ui-field=group]').html(widget.find('[data-ui-field=id_title_light]').html());
controlpopup.find('[data-ui-field=name]').html(_this.TimeTableUI+"5");
_this.etat=HG.WebApp.Utility.GetModulePropertyByName(module,szCfLight+"5");
_this.etat=HG.WebApp.Utility.GetModulePropertyByName(module,szCfOnOff+"5");
if(_this.analyseClick($(cuid),_this.etat.Value,$(this).offset(),event) != -1)
{
_this.drawChoice(controlpopup.find('[data-ui-field=choice]')[0].getContext('2d'),_this.choice,_this.cetat,30);
Expand All @@ -364,7 +364,7 @@
controlpopup.find('[data-ui-field=icon]').attr('src',szImgShut);
controlpopup.find('[data-ui-field=group]').html(widget.find('[data-ui-field=id_title_shut]').html());
controlpopup.find('[data-ui-field=name]').html(_this.TimeTableUI+"0");
_this.etat=HG.WebApp.Utility.GetModulePropertyByName(module,szCfShut+"0");
_this.etat=HG.WebApp.Utility.GetModulePropertyByName(module,szCfLevel+"0");
if(_this.analyseClick($(cuid),_this.etat.Value,$(this).offset(),event) != -1)
{
_this.drawChoice(controlpopup.find('[data-ui-field=choice]')[0].getContext('2d'),_this.choice,_this.cetat,30);
Expand All @@ -377,7 +377,7 @@
controlpopup.find('[data-ui-field=icon]').attr('src',szImgShut);
controlpopup.find('[data-ui-field=group]').html(widget.find('[data-ui-field=id_title_shut]').html());
controlpopup.find('[data-ui-field=name]').html(_this.TimeTableUI+"1");
_this.etat=HG.WebApp.Utility.GetModulePropertyByName(module,szCfShut+"1");
_this.etat=HG.WebApp.Utility.GetModulePropertyByName(module,szCfLevel+"1");
if(_this.analyseClick($(cuid),_this.etat.Value,$(this).offset(),event) != -1)
{
_this.drawChoice(controlpopup.find('[data-ui-field=choice]')[0].getContext('2d'),_this.choice,_this.cetat,30);
Expand All @@ -390,7 +390,7 @@
controlpopup.find('[data-ui-field=icon]').attr('src',szImgShut);
controlpopup.find('[data-ui-field=group]').html(widget.find('[data-ui-field=id_title_shut]').html());
controlpopup.find('[data-ui-field=name]').html(_this.TimeTableUI+"2");
_this.etat=HG.WebApp.Utility.GetModulePropertyByName(module,szCfShut+"2");
_this.etat=HG.WebApp.Utility.GetModulePropertyByName(module,szCfLevel+"2");
if(_this.analyseClick($(cuid),_this.etat.Value,$(this).offset(),event) != -1)
{
_this.drawChoice(controlpopup.find('[data-ui-field=choice]')[0].getContext('2d'),_this.choice,_this.cetat,30);
Expand All @@ -403,7 +403,7 @@
controlpopup.find('[data-ui-field=icon]').attr('src',szImgShut);
controlpopup.find('[data-ui-field=group]').html(widget.find('[data-ui-field=id_title_shut]').html());
controlpopup.find('[data-ui-field=name]').html(_this.TimeTableUI+"3");
_this.etat=HG.WebApp.Utility.GetModulePropertyByName(module,szCfShut+"3");
_this.etat=HG.WebApp.Utility.GetModulePropertyByName(module,szCfLevel+"3");
if(_this.analyseClick($(cuid),_this.etat.Value,$(this).offset(),event) != -1)
{
_this.drawChoice(controlpopup.find('[data-ui-field=choice]')[0].getContext('2d'),_this.choice,_this.cetat,30);
Expand All @@ -416,7 +416,7 @@
controlpopup.find('[data-ui-field=icon]').attr('src',szImgShut);
controlpopup.find('[data-ui-field=group]').html(widget.find('[data-ui-field=id_title_shut]').html());
controlpopup.find('[data-ui-field=name]').html(_this.TimeTableUI+"4");
_this.etat=HG.WebApp.Utility.GetModulePropertyByName(module,szCfShut+"4");
_this.etat=HG.WebApp.Utility.GetModulePropertyByName(module,szCfLevel+"4");
if(_this.analyseClick($(cuid),_this.etat.Value,$(this).offset(),event) != -1)
{
_this.drawChoice(controlpopup.find('[data-ui-field=choice]')[0].getContext('2d'),_this.choice,_this.cetat,30);
Expand All @@ -429,7 +429,7 @@
controlpopup.find('[data-ui-field=icon]').attr('src',szImgShut);
controlpopup.find('[data-ui-field=group]').html(widget.find('[data-ui-field=id_title_shut]').html());
controlpopup.find('[data-ui-field=name]').html(_this.TimeTableUI+"5");
_this.etat=HG.WebApp.Utility.GetModulePropertyByName(module,szCfShut+"5");
_this.etat=HG.WebApp.Utility.GetModulePropertyByName(module,szCfLevel+"5");
if(_this.analyseClick($(cuid),_this.etat.Value,$(this).offset(),event) != -1)
{
_this.drawChoice(controlpopup.find('[data-ui-field=choice]')[0].getContext('2d'),_this.choice,_this.cetat,30);
Expand All @@ -451,12 +451,12 @@
}
for( var i=0 ; i<6 ; i++ )
{
etat=HG.WebApp.Utility.GetModulePropertyByName(module,'ConfigureOptions.Table.Light.'+i);
etat=HG.WebApp.Utility.GetModulePropertyByName(module,'ConfigureOptions.Table.OnOff.'+i);
this.drawTable(widget.find('[data-ui-field=light'+i+']')[0].getContext('2d'),etat.Value,i);
}
for( var i=0 ; i<6 ; i++ )
{
etat=HG.WebApp.Utility.GetModulePropertyByName(module,'ConfigureOptions.Table.Shutter.'+i);
etat=HG.WebApp.Utility.GetModulePropertyByName(module,'ConfigureOptions.Table.Level.'+i);
this.drawTable(widget.find('[data-ui-field=shutter'+i+']')[0].getContext('2d'),etat.Value,i);
}

Expand Down
Loading

0 comments on commit f8775bf

Please sign in to comment.