Skip to content

Commit

Permalink
v3.5.3
Browse files Browse the repository at this point in the history
  • Loading branch information
jemu75 committed Apr 3, 2021
1 parent e0c4bea commit b9cc23b
Show file tree
Hide file tree
Showing 7 changed files with 14 additions and 13 deletions.
2 changes: 1 addition & 1 deletion src/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@
header: ''
}
},
version: 'v3.5.2',
version: 'v3.5.3',
status: {
color: 'secondary',
icon: 'mdi-circle',
Expand Down
14 changes: 8 additions & 6 deletions src/components/TemplChart.vue
Original file line number Diff line number Diff line change
Expand Up @@ -204,33 +204,35 @@
this.chart.options.yaxis.splice(0);
this.chart.series.splice(0);
for(var item of res.defs) {
for(const item of res.defs) {
let select = /\(.*\)/.exec(item);
if(select) item = item.replace(select[0],'_');
let parts = select ? item.replace(select[0], '_').split(':') : item.split(':');
let values = [];
let logData = res.data[res.data.map((e) => e.id).indexOf(idx)].data;
let secAxis = item.split(':')[4] === 'secondary' ? true : false;
let secAxis = parts[4] === 'secondary' ? true : false;
if((!priAxisDef && !secAxis) || (!secAxisDef && secAxis)) {
if(!secAxis) priAxisDef = true;
if(secAxis) secAxisDef = true;
let yOptions = {
seriesName: item.split(':')[2] || '',
seriesName: parts[2] || '',
opposite: secAxis,
labels: {
formatter: (val) => {
let result = ''
if(val) result = val.toFixed(1) + item.split(':')[3]
if(val) result = val.toFixed(1) + parts[3]
return result
}
}
}
this.chart.options.yaxis.push(yOptions);
}
for(const vals of logData) values.push([vals.timestamp, vals.value]);
this.chart.series.push({ name: item.split(':')[2], data: values });
this.chart.series.push({ name: parts[2], data: values });
idx ++;
}
Expand Down
5 changes: 2 additions & 3 deletions src/plugins/fhem.js
Original file line number Diff line number Diff line change
Expand Up @@ -204,11 +204,10 @@ export default class Fhem extends EventEmitter {
let data = [];
let idx = 0;

for(var def of obj.defs) {
for(const def of obj.defs) {
let select = /\(.*\)/.exec(def);
if(select) def = def.replace(select[0],'_');

let defPart = def.split(':'); // definiton [ source : (regex) : name : suffix : axis ]
let defPart = select ? def.replace(select[0], '_').split(':') : def.split(':'); // definiton [ source : (regex) : name : suffix : axis ]
let cmd = 'get ';
cmd += defPart[0] ? defPart[0] : obj.deviceName;
cmd += obj.from ? ' - - ' + obj.from : '';
Expand Down
2 changes: 1 addition & 1 deletion www/fhemapp/index.html
Original file line number Diff line number Diff line change
@@ -1 +1 @@
<!DOCTYPE html><html lang="de"><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width,initial-scale=1,maximum-scale=1,user-scalable=no"><meta name="mobile-web-app-capable" content="yes"><meta name="apple-mobile-web-app-capable" content="yes"><link rel="icon" href="favicon.png"><link rel="apple-touch-icon" href="apple-touch-icon.png"><title>fhemapp</title><link href="css/chunk-03454508.55c011d2.css" rel="prefetch"><link href="css/chunk-0458398b.c4749bc4.css" rel="prefetch"><link href="css/chunk-098d33d4.61e1e199.css" rel="prefetch"><link href="css/chunk-15fa718e.55c011d2.css" rel="prefetch"><link href="css/chunk-27250ed3.55c011d2.css" rel="prefetch"><link href="css/chunk-2c05d556.cb4d0868.css" rel="prefetch"><link href="css/chunk-57a6c555.611711b5.css" rel="prefetch"><link href="css/chunk-58038582.55c011d2.css" rel="prefetch"><link href="css/chunk-62d9ca09.792facbe.css" rel="prefetch"><link href="css/chunk-72c6e8d8.8d89ed40.css" rel="prefetch"><link href="css/chunk-83618c9a.3058ccc5.css" rel="prefetch"><link href="css/chunk-d584b056.4c33e4ab.css" rel="prefetch"><link href="css/chunk-f90907bc.01cf6fd8.css" rel="prefetch"><link href="js/chunk-03454508.432c8b15.js" rel="prefetch"><link href="js/chunk-0458398b.ff29fd68.js" rel="prefetch"><link href="js/chunk-098d33d4.bbdd65ab.js" rel="prefetch"><link href="js/chunk-15fa718e.820d5967.js" rel="prefetch"><link href="js/chunk-27250ed3.00eafedc.js" rel="prefetch"><link href="js/chunk-2c05d556.1084b9d2.js" rel="prefetch"><link href="js/chunk-2d212bf1.61adf40b.js" rel="prefetch"><link href="js/chunk-57a6c555.7c0a36f4.js" rel="prefetch"><link href="js/chunk-58038582.a600d1fb.js" rel="prefetch"><link href="js/chunk-62d9ca09.da27c615.js" rel="prefetch"><link href="js/chunk-72c6e8d8.c00175b8.js" rel="prefetch"><link href="js/chunk-83618c9a.f88bebf6.js" rel="prefetch"><link href="js/chunk-d584b056.803b9cdf.js" rel="prefetch"><link href="js/chunk-f90907bc.3ec9d165.js" rel="prefetch"><link href="css/chunk-vendors.95431e8e.css" rel="preload" as="style"><link href="js/app.7c64f82c.js" rel="preload" as="script"><link href="js/chunk-vendors.aacf57ae.js" rel="preload" as="script"><link href="css/chunk-vendors.95431e8e.css" rel="stylesheet"></head><body><noscript><strong>We're sorry but fhemapp doesn't work properly without JavaScript enabled. Please enable it to continue.</strong></noscript><div id="app"></div><script src="js/chunk-vendors.aacf57ae.js"></script><script src="js/app.7c64f82c.js"></script></body></html>
<!DOCTYPE html><html lang="de"><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width,initial-scale=1,maximum-scale=1,user-scalable=no"><meta name="mobile-web-app-capable" content="yes"><meta name="apple-mobile-web-app-capable" content="yes"><link rel="icon" href="favicon.png"><link rel="apple-touch-icon" href="apple-touch-icon.png"><title>fhemapp</title><link href="css/chunk-03454508.55c011d2.css" rel="prefetch"><link href="css/chunk-0458398b.c4749bc4.css" rel="prefetch"><link href="css/chunk-098d33d4.61e1e199.css" rel="prefetch"><link href="css/chunk-15fa718e.55c011d2.css" rel="prefetch"><link href="css/chunk-27250ed3.55c011d2.css" rel="prefetch"><link href="css/chunk-2c05d556.cb4d0868.css" rel="prefetch"><link href="css/chunk-57a6c555.611711b5.css" rel="prefetch"><link href="css/chunk-58038582.55c011d2.css" rel="prefetch"><link href="css/chunk-62d9ca09.792facbe.css" rel="prefetch"><link href="css/chunk-72c6e8d8.8d89ed40.css" rel="prefetch"><link href="css/chunk-83618c9a.3058ccc5.css" rel="prefetch"><link href="css/chunk-d584b056.4c33e4ab.css" rel="prefetch"><link href="css/chunk-f90907bc.01cf6fd8.css" rel="prefetch"><link href="js/chunk-03454508.432c8b15.js" rel="prefetch"><link href="js/chunk-0458398b.ff29fd68.js" rel="prefetch"><link href="js/chunk-098d33d4.bbdd65ab.js" rel="prefetch"><link href="js/chunk-15fa718e.820d5967.js" rel="prefetch"><link href="js/chunk-27250ed3.00eafedc.js" rel="prefetch"><link href="js/chunk-2c05d556.1084b9d2.js" rel="prefetch"><link href="js/chunk-2d212bf1.61adf40b.js" rel="prefetch"><link href="js/chunk-57a6c555.7c0a36f4.js" rel="prefetch"><link href="js/chunk-58038582.a600d1fb.js" rel="prefetch"><link href="js/chunk-62d9ca09.da27c615.js" rel="prefetch"><link href="js/chunk-72c6e8d8.c00175b8.js" rel="prefetch"><link href="js/chunk-83618c9a.f88bebf6.js" rel="prefetch"><link href="js/chunk-d584b056.b951ef6d.js" rel="prefetch"><link href="js/chunk-f90907bc.3ec9d165.js" rel="prefetch"><link href="css/chunk-vendors.95431e8e.css" rel="preload" as="style"><link href="js/app.a68de743.js" rel="preload" as="script"><link href="js/chunk-vendors.aacf57ae.js" rel="preload" as="script"><link href="css/chunk-vendors.95431e8e.css" rel="stylesheet"></head><body><noscript><strong>We're sorry but fhemapp doesn't work properly without JavaScript enabled. Please enable it to continue.</strong></noscript><div id="app"></div><script src="js/chunk-vendors.aacf57ae.js"></script><script src="js/app.a68de743.js"></script></body></html>

Large diffs are not rendered by default.

1 change: 0 additions & 1 deletion www/fhemapp/js/chunk-d584b056.803b9cdf.js

This file was deleted.

1 change: 1 addition & 0 deletions www/fhemapp/js/chunk-d584b056.b951ef6d.js

Large diffs are not rendered by default.

0 comments on commit b9cc23b

Please sign in to comment.