Материал из Module developer
// Adding data in the array
md.push ({
index: id,
data: name,
subDevice: idSub,
W: i
});
// Calling the function for creating wigets
new CreateDimmer (md[md.length-1]);
// Adding the unique code
id++;
// Saving in the cache
cache[0] = md;
cache[1] = m;
cache[2] = id;
// Sending the new cache to the subdevice
settingPopup.setData(cache);
// Filling in the list of subdevices
fillListSubDevice();
// Opening of the popup Adding subdevices
IR.ShowPopup(addDeviceName);
// closing the popup Adding dimmers
IR.HidePopup(addDimmerName);
};
}
else {
IR.GetItem(error).GetItem("Button").Text = 'Coinciding names!';
// Open the error popup
IR.ShowPopup(error);
};
}
else {
IR.GetItem(error).GetItem("Button").Text = 'Forbidden symbols!';
// Open the error popup
IR.ShowPopup(error);
};
});
};
