homebridge-melcloud-control 3.1.0-beta.23 → 3.1.0-beta.24

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -9,6 +9,7 @@
9
9
  <label id="accountName" style="font-size: 23px">Account</label><br>
10
10
  <label id="info" style="text-align: center; font-size: 17px;"></label><br>
11
11
  <label id="info1" style="text-align: center; font-size: 15px;"></label><br>
12
+ <label id="info2" style="text-align: center; font-size: 15px;"></label><br>
12
13
  </div>
13
14
  <div class="form-group">
14
15
  <label for="name">Name</label>
@@ -348,10 +349,30 @@
348
349
 
349
350
  const newDevicesCount = newDevices.ata.length + newDevices.atw.length + newDevices.erv.length;
350
351
  const newPresetsCount = newDevices.ataPresets.length + newDevices.atwPresets.length + newDevices.ervPresets.length;
351
- document.getElementById('info').innerHTML = `${newDevicesCount === 0 ? 'No new devices found.' : `Found, ${textAta}, ${textAtw}, ${textErv}. ${newDevicesCount === 0 ? '' : 'Now You can start to configure it.'}`}`;
352
- document.getElementById('info').style.color = newDevicesCount === 0 ? 'yellow' : 'green';
353
- document.getElementById('info1').innerHTML = `${newPresetsCount === 0 ? 'No new presets found.' : `Found, ${textAtaPresets}, ${textAtwPresets}, ${textErvPresets}. ${newPresetsCount === 0 ? '' : 'Now You can start to configure it.'}`}`;
354
- document.getElementById('info1').style.color = newPresetsCount === 0 ? 'yellow' : 'green';
352
+
353
+ if (newDevicesCount === 0 && newPresetsCount === 0) {
354
+ document.getElementById('info').innerHTML = 'No new devices found in MELCloud.';
355
+ document.getElementById('info').style.color = 'white';
356
+ };
357
+ if (newDevicesCount > 0 && newPresetsCount === 0) {
358
+ document.getElementById('info').innerHTML = `Found in MELCloud, ${textAta}, ${textAtw}, ${textErv}.`;
359
+ document.getElementById('info').style.color = 'green';
360
+ document.getElementById('info1').innerHTML = 'Now You can configure it.';
361
+ document.getElementById('info1').style.color = 'green';
362
+ };
363
+ if (newDevicesCount === 0 && newPresetsCount > 0) {
364
+ document.getElementById('info').innerHTML = `Found in MELCloud, ${textAtaPresets}, ${textAtwPresets}, ${textErvPresets}.`;
365
+ document.getElementById('info').style.color = 'green';
366
+ document.getElementById('info1').innerHTML = 'Now You can configure it.';
367
+ document.getElementById('info1').style.color = 'green';
368
+ } else {
369
+ document.getElementById('info').innerHTML = `Found in MELCloud, ${textAta}, ${textAtw}, ${textErv}.`;
370
+ document.getElementById('info').style.color = 'green';
371
+ document.getElementById('info1').innerHTML = `Found in MELCloud, ${textAtaPresets}, ${textAtwPresets}, ${textErvPresets}.`;
372
+ document.getElementById('info1').style.color = 'green';
373
+ document.getElementById('info2').innerHTML = 'Now You can configure it.';
374
+ document.getElementById('info2').style.color = 'green';
375
+ };
355
376
 
356
377
  await homebridge.updatePluginConfig(pluginConfig);
357
378
  await homebridge.savePluginConfig(pluginConfig);
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "displayName": "MELCloud Control",
3
3
  "name": "homebridge-melcloud-control",
4
- "version": "3.1.0-beta.23",
4
+ "version": "3.1.0-beta.24",
5
5
  "description": "Homebridge plugin to control Mitsubishi Air Conditioner, Heat Pump and Energy Recovery Ventilation.",
6
6
  "license": "MIT",
7
7
  "author": "grzegorz914",