Skip to content

Commit

Permalink
updated nash research
Browse files Browse the repository at this point in the history
  • Loading branch information
solderq35 committed Jan 18, 2024
1 parent 941442c commit 02d9f15
Show file tree
Hide file tree
Showing 5 changed files with 146 additions and 140 deletions.
4 changes: 2 additions & 2 deletions backend/dependencies/nodejs/models/meter.js
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,8 @@ class Meter {

const map = {
accumulated_real: 'Net Energy Usage (kWh)',
real_power: 'Real Power (W)',
reactive_power: 'Reactive Power (VAR)',
real_power: 'Real Power (kW)',
reactive_power: 'Reactive Power (kVAR)',
apparent_power: 'Apparent Power (VA)',
real_a: 'Real Power, Phase A (kW)',
real_b: 'Real Power, Phase B (kW)',
Expand Down
4 changes: 2 additions & 2 deletions src/components/view/modals/download_data.vue
Original file line number Diff line number Diff line change
Expand Up @@ -222,8 +222,8 @@ export default {
let zip = new JSZip()
const map = {
accumulated_real: 'Net Energy Usage (kWh)',
real_power: 'Real Power (W)',
reactive_power: 'Reactive Power (VAR)',
real_power: 'Real Power (kW)',
reactive_power: 'Reactive Power (kVAR)',
apparent_power: 'Apparent Power (VA)',
real_a: 'Real Power, Phase A (kW)',
real_b: 'Real Power, Phase B (kW)',
Expand Down
8 changes: 4 additions & 4 deletions src/store/chart.module.js
Original file line number Diff line number Diff line change
Expand Up @@ -241,8 +241,8 @@ const getters = {
if (state.point) {
const map = {
accumulated_real: 'Net Energy Usage (kWh)',
real_power: 'Real Power (W)',
reactive_power: 'Reactive Power (VAR)',
real_power: 'Real Power (kW)',
reactive_power: 'Reactive Power (kVAR)',
apparent_power: 'Apparent Power (VA)',
real_a: 'Real Power, Phase A (kW)',
real_b: 'Real Power, Phase B (kW)',
Expand Down Expand Up @@ -286,8 +286,8 @@ const getters = {
unitString (state) {
const map = {
accumulated_real: 'kWh',
real_power: 'W',
reactive_power: 'VAR',
real_power: 'kW',
reactive_power: 'kVAR',
apparent_power: 'VA',
real_a: 'kW',
real_b: 'kW',
Expand Down
6 changes: 6 additions & 0 deletions src/store/chart_modifiers/line_bar/base.js
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,12 @@ export default class LineBaseModifier {
x: new Date((i + delta + offset) * 1000),
y: accumulator
})
// console.log(accumulator)
// console.log(Math.abs(accumulator))
// console.log(payload.point)
// Maybe use Math.abs(accumulator) to flip sign
// Maybe use payload.point to determine if we need to flip sign
// See PR for other comments
} catch (error) {
console.log(error)
}
Expand Down
Loading

0 comments on commit 02d9f15

Please sign in to comment.