Compare commits

...

2 Commits

Author SHA1 Message Date
a46c4d23bf 解决冲突文件 2025-12-26 13:56:31 +08:00
cbb1d7a8a9 光伏功能逻辑代码及BUG修改 2025-12-26 11:26:40 +08:00
27 changed files with 1980 additions and 546 deletions

View File

@ -2,7 +2,7 @@
const config = {
// 产品名称
productName: 'Zetatech',
productName: 'Zeta Cloud',
// 公司名称
companyName: 'Zetatech',
@ -22,6 +22,6 @@ const config = {
}
// 设置后台接口服务的基础地址
config.baseUrl = "https://zzkj-cloud.com/api"
config.baseUrl = "https://zetatech.zzkj-cloud.com/api"
// config.baseUrl = 'http://1.95.170.86:8002/api'
export default config

View File

@ -433,9 +433,9 @@ const install = (Vue, vm) => {
//获取电站下的设备
// GetPageDevice: (params = {}) =>
// vm.$u.post(config.adminPath + "/business/device/appHomePageDevices", params),
//获取光伏发电功率
GetPvCurve: (params = {}) =>
vm.$u.post(config.adminPath + "/business/pcs/pvCurve", params),
GetPageDevice: (params = {}) =>
@ -455,6 +455,9 @@ const install = (Vue, vm) => {
enrnings: {
GetTotal: (params = {}) =>
vm.$u.post(config.adminPath + "/business/earningsCalculate/getTotal", params),
GetPvMonthData: (params = {}) =>
vm.$u.post(config.adminPath + "/business/earningsCalculate/getPvMonthData", params),
},

View File

@ -20,7 +20,7 @@ export default {
and: 'and',
yszc: 'Privacy Policy',
yhxyhyszc: 'User Agreement and Privacy Policy',
msgf: 'Welcome to the "Small Savings and Great Energy" APP, we attach great importance to the protection of your personal information and privacy. Please read this app carefully before you use it',
msgf: 'Welcome to the "Zeta Cloud" APP, we attach great importance to the protection of your personal information and privacy. Please read this app carefully before you use it',
msgs: 'When you use this application, it means that you have read, understood and agreed to accept all the terms of this agreement. If you do not agree with any of the contents of this Agreement, please stop using this Application immediately.',
agree: 'Agree',
quit: 'Disagree',
@ -34,11 +34,11 @@ export default {
useElecPrice: 'Electricity prices',
workStatus: 'Working Status',
standing:'standing',
activePower:'Active Power(kW):',
activePowerpcs:'Active Power:',
operatingPower:'Operating Power',
accumulatedElectricityConsumption:'Total power',
pvKpi: 'PV KPI',
saveStandardCoal: 'Save standard coal (ton)',
saveStandardCoal: 'Save standard coal (t)',
equivalentCo2Reduction: "CO2 emission reduction (kg)",
equivalentTreePlantings: "Equivalent tree plantings (Trees)",
dailyPowerGeneration: 'Daily Power Generation',
@ -61,6 +61,44 @@ export default {
enmonthTotalChargePrice: 'Total Charging Price Monthly(EUR)',
enmonthTotalDisChargePrice: 'Total Discharging Price Monthly(EUR)',
enearnings: 'Revenue(EUR)',
pvSwitch:'PV switch'
pvSwitch:'PV switch',
stationDatacom: 'Station Data',
sevenDaycom:'Week',
todayEarning: 'Today Earning(EUR)',
totalRevenue: 'Cumulative Earnings(EUR)',
ratedPower: 'Rated Power(kW)',
currentMonthlyPowerGeneration: 'Current monthly power generation',
cumulativePowerGeneration: 'cumulative power generation',
ratedPowernokw: 'Rated Power',
powerGenerationStatus: 'power Generation Status',
monthlyIncome: 'Monthly income(EUR)',
lowV: 'low-side voltage',
lowI: 'low-side current',
highV: 'high-side voltage',
timesArr: [{
text: '1 Minutes',
value: 1
},
{
text: '5 Minutes',
value: 5
},
{
text: '10 Minutes',
value: 10
},
{
text: '15 Minutes',
value: 15
},
{
text: '20 Minutes',
value: 20
},
{
text: '30 Minutes',
value: 30
}
]
}
}

View File

@ -20,7 +20,7 @@ export default {
and: '和',
yszc: '隐私政策',
yhxyhyszc: '用户协议和隐私政策',
msgf: '欢迎使用“小储大能”APP我们非常重视您的个人信息和隐私保护。在您使用本应用前请仔细阅读',
msgf: '欢迎使用“澤泰云”APP我们非常重视您的个人信息和隐私保护。在您使用本应用前请仔细阅读',
msgs: '您在使用本应用时,即表示您已阅读、理解并同意接受本协议的所有条款。如果您不同意本协议的任何内容,请立即停止使用本应用。',
agree: '同意',
quit: '不同意',
@ -34,7 +34,7 @@ export default {
useElecPrice: '用电价格',
workStatus: '工作状态:',
standing:'静置',
activePower:'有功功率(kW):',
activePowerpcs:'有功功率',
operatingPower:'运行功率',
accumulatedElectricityConsumption:'累计电量',
pvKpi: '光伏KPI',
@ -61,7 +61,44 @@ export default {
enmonthTotalChargePrice: '本月总充电量总价(元)',
enmonthTotalDisChargePrice: '本月总放电量总价(元)',
enearnings: '收益(元)',
pvSwitch:'PV开关'
pvSwitch:'PV开关',
stationDatacom: '电站数据',
sevenDaycom:'近七天',
todayEarning: '今日收益(元)',
totalRevenue: '累计收益(元)',
ratedPower: '额定功率(kW)',
currentMonthlyPowerGeneration: '本月发电量',
cumulativePowerGeneration: '累计发电量',
ratedPowernokw: '额定功率',
powerGenerationStatus: '项目发电情况',
monthlyIncome: '本月收益(元)',
lowV:'低压侧电压',
lowI:'低压侧电流',
highV:'高压侧电压',
timesArr: [{
text: '1分钟',
value: 1
},
{
text: '5分钟',
value: 5
},
{
text: '10分钟',
value: 10
},
{
text: '15分钟',
value: 15
},
{
text: '20分钟',
value: 20
},
{
text: '30分钟',
value: 30
}
]
}
};

View File

@ -50,12 +50,18 @@
watch: {
canvasData: {
handler(val) {
if (val && val.length) {
this.getSystemInfo()
// 等待 windowWidth 初始化完成后再绘制
if (this.windowWidth) {
this.draw(null); // 直接绘制
} else {
// 若 windowWidth 未获取,先获取再绘制
this.getSystemInfo().then(() => {
this.draw(null);
});
}
},
deep: true,
immediate: true
immediate: false
}
},
mounted() {
@ -216,58 +222,73 @@
})
},
countChineseAndEnglishCharacters(str, x) {
var chineseCount = str.match(/[\u4e00-\u9fa5]/g) ?
str.match(/[\u4e00-\u9fa5]/g).length :
0;
var englishCount = str.match(/[a-zA-Z]/g) ?
str.match(/[a-zA-Z]/g).length :
0;
var otherCount = str.length - chineseCount - englishCount;
const obj = {
otherCount: otherCount,
chineseCount: chineseCount,
englishCount: englishCount,
};
return (
obj.englishCount * 6 + obj.chineseCount * 12 + obj.otherCount * 7.5 + x
);
},
// countChineseAndEnglishCharacters(str, x) {
// var chineseCount = str.match(/[\u4e00-\u9fa5]/g) ?
// str.match(/[\u4e00-\u9fa5]/g).length :
// 0;
// var englishCount = str.match(/[a-zA-Z]/g) ?
// str.match(/[a-zA-Z]/g).length :
// 0;
// var otherCount = str.length - chineseCount - englishCount;
// const obj = {
// otherCount: otherCount,
// chineseCount: chineseCount,
// englishCount: englishCount,
// };
// return (
// obj.englishCount * 6 + obj.chineseCount * 12 + obj.otherCount * 7.5 + x
// );
// },
drawText(draw) {
draw.forEach((item, index) => {
if (item.font.length) {
if (item.font.length > 1) {
item.font.forEach((item2, index2) => {
if (this.type === 'app') {
this.ctx.setFontSize(item2.size)
} else {
this.ctx.fontSize = item2.size
}
this.ctx.fillStyle = item2.color
const x = this.countChineseAndEnglishCharacters(item.font[0].text, item
.coord[0][0])
this.ctx.fillText(item2.text, this.fitSize(index2 === 1 ? x : item.coord[0]
[0]), this.fitSize(item.coord[0][1]))
this.ctx.closePath()
})
} else {
if (this.type === 'app') {
this.ctx.setFontSize(item.font[0].size)
} else {
this.ctx.fontSize = item.font[0].size
}
this.ctx.fillStyle = item.font[0].color
this.ctx.fillText(item.font[0].text, this.fitSize(item.coord[0][0]), this.fitSize(item
.coord[0][1]))
this.ctx.closePath()
}
}
})
draw.forEach((item, index) => {
if (item.font.length) {
// 记录前一个文本的结束位置(用于后续文本偏移)
let prevTextEndX = this.fitSize(item.coord[0][0]);
item.font.forEach((item2, index2) => {
// 设置字体大小和颜色
if (this.type === 'app') {
this.ctx.setFontSize(item2.size);
} else {
this.ctx.font = `${item2.size}px sans-serif`; // 小程序端补全font属性
}
this.ctx.fillStyle = item2.color;
// 计算当前文本的绘制X坐标
let currentX = prevTextEndX;
// 非第一个文本加上配置的偏移量默认8px
if (index2 > 0) {
const offsetX = item2.offsetX || 6;
currentX += this.fitSize(offsetX); // 适配设备尺寸的偏移量
}
// 绘制文本
this.ctx.fillText(
item2.text,
currentX,
this.fitSize(item.coord[0][1])
);
// 更新前一个文本的结束位置当前文本的X + 文本宽度)
const textWidth = this.getTextWidth(item2.text, item2.size);
prevTextEndX = currentX + textWidth;
this.ctx.closePath();
});
}
});
},
// 新增计算文本的实际绘制宽度适配app/小程序)
getTextWidth(text, fontSize) {
if (this.type === 'app') {
// App端通过measureText计算
return this.ctx.measureText(text).width;
} else {
// 小程序端手动计算(更稳定)
this.ctx.font = `${fontSize}px sans-serif`;
return this.ctx.measureText(text).width;
}
},
drawImages(draw, canvas) {
let x,
@ -350,9 +371,12 @@
})
},
fitSize(coordinate) {
let newWindowWidth = this.windowWidth //这个windowWidth指的是该设备宽度可以onLoad监听页面加载中获取
let v = 375 / newWindowWidth //375是设计稿的大小得到的v值是设计稿和设备宽度的比例关系也可理解成在设计稿的大小基础上放大或缩小的倍数
return coordinate / v //返回的是当前坐标值或者大小与v的比例
let newWindowWidth = this.windowWidth;
const designWidth = 375; // 设计稿宽度
// 修正比例计算:设备宽度 / 设计稿宽度 = 缩放比例
const scale = newWindowWidth / designWidth;
// 设计稿的坐标 * 缩放比例 = 设备实际坐标
return coordinate * scale;
}
},

View File

@ -98,6 +98,7 @@ export default {
// val[2].StationShow = this.StationShow
this.$u.vuex("vuex_currentStation", val[2])
this.$u.vuex("vuex_StationShow", this.StationShow)
this.$u.vuex("vuex_inverterFlag", value.list[valIndex].list[newValIndex].inverterFlag)
this.$emit('openPop', false)
}
}

View File

@ -1,3 +1,144 @@
<<<<<<< .mine
<!DOCTYPE html>
<html lang="zh-CN">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="keywords" content="PoweredByAidex"/>
<meta name="description" content="PoweredByAidex"/>
</head>
<body>
<svg width="128" height="128"
xmlns="http://www.w3.org/2000/svg" version="1.1">
<style>path {fill-opacity:1; stroke:none;}</style>
<path d="M 42,0L 0,0L 0,128L 62,128L 62,126L 60.7072,125.2928L 58.146,123.854L 55.6451,122.3549L 53.2063,120.7937L 52,120L 50.6822,119.3178L 48.0777,117.9223L 45.5826,116.4174L 43.3111,114.6889L 41.3966,112.6034L 39.9425,110.0575L 38.9719,107.0281L 38.4156,103.5844L 38.148,99.852L 38.0423,95.9577L 38.0079,91.9921L 38,90L 35.5885,88.4115L 33.1929,86.8071L 32,86L 29.3498,84.6502L 26.7241,83.2759L 24.1496,81.8504L 21.6456,80.3544L 19.2063,78.7937L 18,78L 16.6822,77.3178L 14.0777,75.9223L 11.5826,74.4174L 9.3111,72.6889L 7.3966,70.6034L 5.9425,68.0575L 4.9719,65.0281L 4.4156,61.5844L 4.2818,59.7182L 4.0952,55.9048L 4.0607,53.9395L 4.0386,51.9623L 4.0124,47.9936L 4.0168,44.0132L 4.0578,40.0573L 4.1791,36.179L 4.3221,34.3221L 4.7484,30.7484L 5.1291,29.129L 6.0983,26.0983L 7.4879,23.4879L 8.3791,22.3791L 10.3181,20.3181L 12.5253,18.5253L 14.9196,16.9196L 17.4387,15.4387L 20.0358,14.0358L 22.6744,12.6744L 24,12L 26.4247,10.4247L 27.6601,9.6601L 30.165,8.165L 32.7351,6.7351L 35.3557,5.3557L 38.0055,4.0055L 40.6675,2.6675L 42,2Z" style="fill:rgb(254,254,254);"/>
<path d="M 58,62L 59.3709,62.6291L 62.0751,63.9249L 64.7042,65.2958L 66,66L 70,66L 70,62L 68,60L 65.6634,58.3366L 63.3818,56.6182L 61.182,54.818L 59.0518,52.9482L 58,52L 55.6723,50.3277L 53.488,48.512L 51.5906,46.4094L 50.1002,43.8998L 49.071,40.929L 48.4623,37.5377L 48.1554,33.8446L 48,30L 47.2582,26.7418L 46.5916,23.4084L 46,20L 44,20L 42,22L 41.9814,23.9814L 41.917,27.917L 41.7622,31.7622L 41.4385,35.4385L 40.8635,38.8635L 39.9723,41.9723L 38.7311,44.7311L 37.1392,47.1392L 35.2342,49.2342L 33.1055,51.1055L 32,52L 29.793,53.793L 27.5268,55.5268L 25.1866,57.1866L 24,58L 22,60L 20,62L 20,66L 26,66L 28.6926,64.6926L 31.4189,63.4189L 34.2096,62.2096L 37.0777,61.0777L 38.4931,60.5638L 41.2382,59.6271L 43.8451,58.9301L 46.3927,58.5947L 48.9354,58.717L 50.2132,59.0062L 52.7823,59.7624L 55.3802,60.8068Z" style="fill:rgb(254,254,254);"/>
<path d="M 85.2331,17.2701L 86.4837,16.5847L 87.7563,15.9652L 90.3475,14.8965L 93.0246,14.2314L 95.7591,14.0611L 98.5014,14.3992L 101.2011,15.1859L 103.8206,16.3207L 106.3454,17.6971L 108.792,19.2165L 110,20L 111.3178,20.6822L 113.9223,22.0777L 116.4174,23.5826L 118.6889,25.3111L 120.6034,27.3966L 121.3304,28.6696L 122.5428,31.4572L 123.3061,34.6936L 123.7166,38.2802L 123.8055,40.1826L 123.9106,44.0318L 123.8774,47.9088L 123.6792,51.6854L 123.2186,55.2195L 122.37,58.3701L 121.046,61.046L 120.151,62.151L 119.1695,63.1695L 118.1211,64.1211L 115.922,65.922L 113.5629,67.5629L 111.1037,69.1037L 108.5654,70.5654L 105.9647,71.9647L 103.3257,73.3257L 102,74L 99.3198,75.3198L 96.5065,76.5065L 93.5268,77.5268L 92,78L 92,80L 92.3524,81.6476L 92.6727,83.3272L 92.9526,85.0465L 93.4244,88.5695L 93.7174,92.2526L 93.7775,94.15L 93.8123,97.9511L 93.6565,101.699L 93.2447,105.2551L 92.4795,108.4814L 91.2758,111.2761L 89.6104,113.6105L 87.5449,115.5449L 85.2126,117.2126L 84,118L 81.5753,119.5753L 79.1045,121.1045L 76.5654,122.5654L 73.9647,123.9647L 71.3257,125.3257L 70,126L 70,128L 128,128L 128,0L 50,0L 50,2L 52,4L 54.6502,5.3498L 57.2759,6.7241L 59.8504,8.1496L 62.3544,9.6456L 64.7937,11.2063L 66,12L 67.3333,12.6667L 70,14L 71.3333,14.6667L 74,16L 75.3333,16.6667L 78,18L 84,18Z" style="fill:rgb(254,254,254);"/>
<path d="M 84,74L 84,76L 88,76L 88,74Z" style="fill:rgb(254,254,254);"/>
<path d="M 88,76L 88,78L 92,78L 92,76Z" style="fill:rgb(254,254,254);"/>
<path d="M 82,20L 80,18L 78,18L 75.3333,19.3333L 74,20L 74,22L 82,22Z" style="fill:rgb(212,228,213);"/>
<path d="M 84,72L 80,72L 80,74L 84,74Z" style="fill:rgb(212,228,213);"/>
<path d="M 70,18L 68,16L 66.7072,15.2928L 64.146,13.854L 61.6451,12.3549L 59.2063,10.7937L 58,10L 56.6667,9.3333L 54,8L 50.998,7.002L 48,6L 42,6L 39.5753,7.5753L 38.3399,8.3399L 35.835,9.835L 33.2649,11.2649L 30.6443,12.6443L 27.9945,13.9945L 25.3325,15.3325L 24,16L 22.7944,16.7944L 20.3566,18.3566L 17.8559,19.8559L 15.2937,21.2937L 14,22L 12,24L 10,26L 10,68L 12,70L 14,72L 16.6502,73.3498L 19.2759,74.7241L 21.8504,76.1496L 24.3544,77.6456L 26.7937,79.2063L 28,80L 29.3333,80.6667L 32,82L 36,82L 38,80L 38.7389,78.9578L 40.3681,77.0458L 42.366,75.5475L 43.5513,75.0035L 46.1174,73.9788L 48.998,72.998L 52,72L 52.5916,70.5916L 53.2207,69.2207L 54.5415,66.5832L 55.9374,64.1874L 57.3208,62.0292L 58,61L 58,60L 56.6667,59.3333L 54,58L 52.6667,57.3333L 50,56L 44,56L 42.608,56.608L 39.7965,57.7965L 36.9233,58.9233L 34.0999,59.953L 32.7929,60.281L 31.5625,60.2742L 30.5423,59.7222L 29.5169,58.149L 30.4488,56.2218L 32.5088,54.4707L 34.8159,52.8129L 36,52L 38,50L 40,48L 40.1183,44.1183L 40.3327,40.3327L 40.5256,38.5268L 40.7716,36.7769L 41.3801,33.4141L 41.8269,31.9259L 42.4253,30.6286L 43.2715,29.6633L 45.1308,28.6799L 46.7589,29.7437L 47.5856,32.5325L 47.8986,36.1197L 48,38L 48.7418,41.2582L 49.4084,44.5916L 50,48L 52,50L 54,52L 55.3333,52.6667L 58,54L 60,54L 60.0024,52.0028L 60.0175,48.0198L 60.0826,44.0909L 60.2949,40.3144L 60.5551,38.5801L 60.9297,36.9578L 61.9123,33.9411L 63.3325,31.3529L 64.2076,30.2225L 66.0465,28.0526L 67.0259,27.0296L 69.0026,25.0034L 71,23.0001L 72,22L 72,20Z" style="fill:rgb(254,220,188);"/>
<path d="M 64,78L 60,78L 60,80L 64,80Z" style="fill:rgb(94,170,125);"/>
<path d="M 64,68L 64,70L 72,70L 72,68Z" style="fill:rgb(94,170,125);"/>
<path d="M 70,58L 68,58L 68,62L 70,62Z" style="fill:rgb(94,170,125);"/>
<path d="M 42,86L 36,86L 36,90L 38,92L 40,92L 42,90Z" style="fill:rgb(227,236,224);"/>
<path d="M 68,76L 66,74L 60,74L 57.3198,75.3198L 54.5065,76.5065L 51.5268,77.5268L 50,78L 48.4115,80.4115L 46.8071,82.8071L 46,84L 46,86L 54,86L 56.0945,84.0945L 58.3099,82.3099L 60.7558,80.7558L 63.4888,79.4888L 66.4645,78.4645L 68,78Z" style="fill:rgb(33,149,100);"/>
<path d="M 80,64L 80,26L 76,26L 73.3333,27.3333L 72,28L 72,58L 73.6143,60.3857L 75.2088,62.7912L 76,64Z" style="fill:rgb(33,149,100);"/>
<path d="M 70,24L 71,25L 72,25L 74.998,24.499L 78,24L 78,22L 70,22Z" style="fill:rgb(148,187,146);"/>
<path d="M 42,72L 38,72L 38,80L 40,80L 42,78Z" style="fill:rgb(240,215,182);"/>
<path d="M 56,64L 52,64L 52,68L 56,68Z" style="fill:rgb(240,215,182);"/>
<path d="M 58,61L 57,61L 56,62L 56,66L 60,66L 60,62Z" style="fill:rgb(240,215,182);"/>
<path d="M 62,24L 60,24L 60,56L 62,56Z" style="fill:rgb(240,215,182);"/>
<path d="M 42,88L 40,90L 40,92L 52,92L 52,90L 50,88Z" style="fill:rgb(166,213,193);"/>
<path d="M 54,86L 50,86L 50,90L 54,90Z" style="fill:rgb(166,213,193);"/>
<path d="M 59.2582,87.2582L 61.8498,85.8498L 64.5916,84.5916L 66,84L 66,82L 64,80L 60,80L 57.3333,81.3333L 56,82L 54,84L 54,88L 58,88Z" style="fill:rgb(166,213,193);"/>
<path d="M 68,78L 64,78L 64,82L 68,82Z" style="fill:rgb(166,213,193);"/>
<path d="M 74.6667,78.6667L 76,78L 78.6667,76.6667L 80,76L 80,74L 70,74L 68,76L 68,80L 72,80Z" style="fill:rgb(166,213,193);"/>
<path d="M 84,24L 82,24L 82,66L 84,66Z" style="fill:rgb(166,213,193);"/>
<path d="M 86,24L 84,24L 84,72L 86,72Z" style="fill:rgb(106,189,160);"/>
<path d="M 94,114L 94,80L 92,78L 90.6667,77.3333L 88,76L 86.6667,75.3333L 84,74L 80,74L 77.3333,75.3333L 76,76L 73.3333,77.3333L 72,78L 69.3333,79.3333L 68,80L 65.5753,81.5753L 63.1045,83.1045L 60.5654,84.5654L 57.9647,85.9647L 55.3257,87.3257L 54,88L 51.636,89.3995L 49.2489,90.5836L 48.0432,90.9921L 45.5777,91.6132L 42.8616,91.8992L 39.7026,91.9863L 38,92L 38,114L 40,116L 42.6502,117.3498L 45.2759,118.7241L 47.8504,120.1496L 50.3544,121.6456L 52.7937,123.2063L 54,124L 55.3333,124.6667L 58,126L 59.3333,126.6667L 62,128L 70,128L 72.6667,126.6667L 74,126L 76.6667,124.6667L 78,124L 80.6667,122.6667L 82,122L 83.2056,121.2056L 85.6434,119.6434L 88.1441,118.1441L 90.7063,116.7063L 92,116Z" style="fill:rgb(6,150,109);"/>
<path d="M 85.8729,57.8729L 85.6659,61.6659L 85.2814,65.2814L 84.7048,68.7048L 84,72L 84,74L 85.3333,74.6667L 88,76L 89.3333,76.6667L 92,78L 100,78L 102.4247,76.4247L 104.8955,74.8955L 107.4346,73.4346L 110.0353,72.0353L 112.6743,70.6743L 114,70L 115.2056,69.2056L 117.6434,67.6434L 120.1441,66.1441L 122.7063,64.7063L 124,64L 124,26L 122,24L 119.3498,22.6502L 116.7241,21.2759L 114.1496,19.8504L 111.6456,18.3544L 109.2063,16.7937L 108,16L 106.6667,15.3333L 104,14L 102.6667,13.3333L 100,12L 98.6667,11.3333L 96,10L 94,10L 91.3333,11.3333L 90,12L 87.3333,13.3333L 86,14L 83.6143,15.6143L 81.2088,17.2088L 80,18L 80,20L 80.8396,21.2073L 82.4279,23.6946L 83.7665,26.3869L 84.7608,29.3767L 85.4016,32.6928L 85.7538,36.2964L 85.9157,40.1046L 85.9759,44.0286L 85.9899,48.0011L 85.9756,51.9773L 85.9171,55.9173Z" style="fill:rgb(6,150,109);"/>
<path d="M 62,84L 58,84L 58,86L 62,86Z" style="fill:rgb(132,196,168);"/>
<path d="M 42,30L 40,30L 40,36L 42,36Z" style="fill:rgb(255,232,210);"/>
<path d="M 42,4L 42,6L 46,6L 46,4Z" style="fill:rgb(255,232,210);"/>
<path d="M 50,38L 48,38L 48,44L 50,44Z" style="fill:rgb(255,232,210);"/>
<path d="M 48,92L 42,92L 42,94L 48,94Z" style="fill:rgb(94,180,147);"/>
<path d="M 82,26L 80,26L 80,68L 82,68Z" style="fill:rgb(94,180,147);"/>
<path d="M 40.6667,84.6667L 42,82L 42,78L 40,78L 38,80L 38,86L 40,86Z" style="fill:rgb(174,195,156);"/>
<path d="M 50,76L 42,76L 42,82L 44,82L 45.1868,81.5847L 47.5787,80.7752L 50,80Z" style="fill:rgb(174,195,156);"/>
<path d="M 56,74L 54.6667,73.3333L 52,72L 48,72L 48,76L 50,78L 54,78L 56,76Z" style="fill:rgb(174,195,156);"/>
<path d="M 62,72L 62,71L 61,70L 52,70L 52,74L 54,74L 55.3333,74L 58,74L 60,74Z" style="fill:rgb(174,195,156);"/>
<path d="M 64,68L 56,68L 56,70L 58.501,70.499L 61,71L 62,71L 64,70Z" style="fill:rgb(174,195,156);"/>
<path d="M 64,66L 60,66L 60,68L 64,68Z" style="fill:rgb(174,195,156);"/>
<path d="M 66,30L 64,30L 64,60L 66,60Z" style="fill:rgb(174,195,156);"/>
<path d="M 72,25L 71,24L 68,24L 66,26L 66,30L 68,30L 70,30L 72,30Z" style="fill:rgb(174,195,156);"/>
<path d="M 42,2L 38,2L 35.3333,3.3333L 34,4L 31.3333,5.3333L 30,6L 27.3333,7.3333L 26,8L 23.5753,9.5753L 21.1045,11.1045L 18.5654,12.5654L 15.9647,13.9647L 13.3257,15.3257L 12,16L 9.6143,17.6143L 7.2088,19.2088L 6,20L 4,22L 4,24L 14,24L 16.6667,22.6667L 18,22L 20.6667,20.6667L 22,20L 24.4247,18.4247L 25.6601,17.6601L 28.165,16.165L 30.7351,14.7351L 33.3557,13.3557L 36.0055,12.0055L 38.6675,10.6675L 40,10L 42,8Z" style="fill:rgb(254,244,234);"/>
<path d="M 32,80L 29.5885,78.4115L 27.1929,76.8071L 26,76L 24.6667,75.3333L 22,74L 20.6667,73.3333L 18,72L 16.6667,71.3333L 14,70L 12.3857,69.6143L 9.1769,68.8231L 6,68L 4,68L 4,72L 6,74L 8.6502,75.3498L 11.2759,76.7241L 13.8504,78.1496L 16.3544,79.6456L 18.7937,81.2063L 20,82L 21.3333,82.6667L 24,84L 25.3333,84.6667L 28,86L 32,86Z" style="fill:rgb(254,244,234);"/>
<path d="M 50,0L 42,0L 42,2L 50,2Z" style="fill:rgb(254,244,234);"/>
<path d="M 74,18L 74,14L 72.7072,13.2928L 70.146,11.854L 67.6451,10.3549L 65.2063,8.7937L 64,8L 62.6667,7.3333L 60,6L 58.6667,5.3333L 56,4L 54.6667,3.3333L 52,2L 48,2L 48,4L 49.3333,6.6667L 50,8L 51.2928,8.7072L 53.854,10.146L 56.3549,11.6451L 58.7937,13.2063L 60,14L 61.3333,14.6667L 64,16L 65.3333,16.6667L 68,18Z" style="fill:rgb(254,244,234);"/>
<path d="M 74,72L 74,74L 80,74L 82.6667,72.6667L 84,72L 84,66L 82,66L 79.6143,67.6143L 77.2088,69.2088L 76,70Z" style="fill:rgb(190,220,203);"/>
<path d="M 84,24L 84,22L 78,22L 78,24L 80,26L 82,26Z" style="fill:rgb(190,220,203);"/>
<path d="M 38,84L 34,84L 34,90L 36,90L 36.6667,88.6667L 38,86Z" style="fill:rgb(242,239,228);"/>
<path d="M 64,62L 60,62L 60,64L 64,64Z" style="fill:rgb(242,239,228);"/>
<path d="M 76.6667,20.6667L 78,20L 78,16L 74,16L 71.3333,17.3333L 70,18L 70,20L 72,22L 74,22Z" style="fill:rgb(242,239,228);"/>
<path d="M 42,82L 40,82L 40,86L 42,86Z" style="fill:rgb(114,176,133);"/>
<path d="M 48,80L 48,79L 46,78L 44,78L 44,82L 46,82Z" style="fill:rgb(114,176,133);"/>
<path d="M 58,73L 56,72L 54,72L 54,74L 58,74Z" style="fill:rgb(114,176,133);"/>
<path d="M 69,32L 69,30L 66,30L 66,60L 68,60L 68.0007,58.0013L 68.0044,54.0088L 68.0192,50.0384L 68.0636,46.1271L 68.1671,42.3341L 68.3593,38.7186L 68.6476,35.2952Z" style="fill:rgb(114,176,133);"/>
<path d="M 70,28L 68,28L 68,30L 69,32L 70,32Z" style="fill:rgb(114,176,133);"/>
<path d="M 70,64L 67.002,65.002L 64,66L 64,68L 65.3198,68.5767L 67.8263,69.8336L 70.0333,71.3234L 72,73L 74,73L 76,72L 78.6667,70.6667L 80,70L 80,64Z" style="fill:rgb(114,176,133);"/>
<path d="M 72,24L 72,28L 76,28L 78.6667,26.6667L 80,26L 80,24Z" style="fill:rgb(114,176,133);"/>
<path d="M 38,80L 36,80L 36,84L 38,84Z" style="fill:rgb(208,206,169);"/>
<path d="M 47,76L 47,74L 42,74L 42,76Z" style="fill:rgb(208,206,169);"/>
<path d="M 48,72L 46,72L 46,74L 47,76L 48,76Z" style="fill:rgb(208,206,169);"/>
<path d="M 52,68L 52,70L 56,70L 56,68Z" style="fill:rgb(208,206,169);"/>
<path d="M 56,66L 56,68L 60,68L 60,66Z" style="fill:rgb(208,206,169);"/>
<path d="M 66,64L 60,64L 60,66L 66,66Z" style="fill:rgb(208,206,169);"/>
<path d="M 64,30L 62,30L 62,58L 64,58Z" style="fill:rgb(208,206,169);"/>
<path d="M 66,26L 64,26L 64,30L 66,30Z" style="fill:rgb(208,206,169);"/>
<path d="M 47.5885,85.5885L 49.1929,83.1929L 50,82L 50,80L 46,80L 44,82L 44,88L 46,88Z" style="fill:rgb(49,155,107);"/>
<path d="M 54,76L 54,78L 58,78L 60,76L 60,74L 56,74Z" style="fill:rgb(49,155,107);"/>
<path d="M 70,72L 60,72L 60,74L 63.002,74.998L 66,76L 70,76Z" style="fill:rgb(49,155,107);"/>
<path d="M 72,30L 70,30L 70,58L 72,58Z" style="fill:rgb(49,155,107);"/>
<path d="M 74,58L 72,58L 72,62L 76,62L 76,60Z" style="fill:rgb(49,155,107);"/>
<path d="M 44,82L 42,82L 42,88L 44,88Z" style="fill:rgb(73,163,117);"/>
<path d="M 50,86L 46,86L 46,88L 50,88Z" style="fill:rgb(73,163,117);"/>
<path d="M 60,80L 56,80L 56,82L 60,82Z" style="fill:rgb(73,163,117);"/>
<path d="M 74,73L 72.6667,71L 72,70L 62,70L 62,72L 63.6143,72.3857L 66.8231,73.1769L 70,74L 74,74Z" style="fill:rgb(73,163,117);"/>
<path d="M 70,32L 68,32L 68,58L 70,58Z" style="fill:rgb(73,163,117);"/>
<path d="M 74.998,61.002L 72.998,59.002L 72,58L 70,58L 70,64L 76,64L 76,62Z" style="fill:rgb(73,163,117);"/>
<path d="M 10,26L 8,26L 8,68L 10,68Z" style="fill:rgb(254,223,194);"/>
<path d="M 46,18L 42,18L 42,22L 44,22L 46,20Z" style="fill:rgb(254,223,194);"/>
<path d="M 12,24L 4,24L 4,68L 6,70L 12,70L 12,68L 11.2952,66.7048L 10.0138,63.9862L 9.5332,62.4668L 8.757,59.243L 8.3136,55.6867L 8.108,51.8952L 8.0391,47.9815L 8.0532,44.0413L 8.1664,40.1647L 8.4614,36.4612L 9.0527,33.0527L 10.0138,30.0138L 11.2952,27.2952L 12,26Z" style="fill:rgb(254,240,227);"/>
<path d="M 36,82L 32,82L 32,88L 34,88L 34.6667,86.6667L 36,84Z" style="fill:rgb(254,240,227);"/>
<path d="M 42,36L 40,36L 40,44L 42,44Z" style="fill:rgb(254,240,227);"/>
<path d="M 50,4L 48,2L 42,2L 42,4L 44.4115,5.5885L 46.8071,7.1929L 48,8L 50,8Z" style="fill:rgb(254,240,227);"/>
<path d="M 48,22L 46,22L 46,30L 48,30Z" style="fill:rgb(254,240,227);"/>
<path d="M 50,44L 48,44L 48,48L 50,48Z" style="fill:rgb(254,240,227);"/>
</svg>
</body>
</html>
=======
<!DOCTYPE html>
<html lang="zh-CN">
<head>
@ -136,4 +277,5 @@
<path d="M 50,44L 48,44L 48,48L 50,48Z" style="fill:rgb(254,240,227);" />
</svg> -->
</body>
</html>
</html>
>>>>>>> .theirs

View File

@ -42,7 +42,7 @@ export default {
deviceMonitor: 'Device Monitor',
runCurve: 'Run Time Curve',
chargeDisData: 'Charge/Discharge Data',
stationData: 'stationData',
stationData: 'Station Data',
environmentalData: 'Environmental Control Data',
sevenDay: 'Seven',
monthDay: 'Month',

View File

@ -1,9 +1,9 @@
{
"name" : "StoraSmart",
"name" : "Zeta Cloud",
"appid" : "__UNI__86592F3",
"description" : "Zetatech",
"versionName" : "2.0.8",
"versionCode" : 213,
"versionName" : "2.0.13",
"versionCode" : 218,
"transformPx" : false,
"sassImplementationName" : "node-sass",
"app-plus" : {
@ -160,6 +160,5 @@
"disableHostCheck" : true
}
},
"locale" : "en",
"fallbackLocale" : "en"
"locale" : "en"
}

View File

@ -20,7 +20,7 @@
<charts v-else id="pcsChart" :options="curve_option"></charts>
</view>
</view>
<view class="box" style="margin-bottom: 0;">
<!-- <view class="box" style="margin-bottom: 0;">
<Section :title="$t('homePage.device.deviceData')" />
<zero-loading v-if="stationLoading" position="absolute"></zero-loading>
<view v-else class="group-box">
@ -32,13 +32,13 @@
<image src="/static/aidex/images/zjrl.png"></image>
</view>
<view class="item-con">
<view class="item-num">{{ panelData.outputPower | kWFormat }}
<view class="item-num">{{ panelData.pvActivePower | kWFormat }}
</view>
<view class="item-title">{{$t('homePage.home.batVoltage')}}(kVar)</view>
<view class="item-title">{{$t('homePage.home.batVoltage')}}(V)</view>
</view>
</view>
<view class="group-item border-right"
@click="showHistory($t('homePage.home.batCurrent'), 'reactivePowerPCS', 'pcs', 'kVar', '')">
@click="showHistory($t('homePage.home.batCurrent'), 'reactivePowerPCS', 'pcs', 'V', '')">
<view class="history-icon">
<image src="/static/aidex/images/history-icon.png"></image>
</view>
@ -46,7 +46,7 @@
<image src="/static/aidex/images/zjrl.png"></image>
</view>
<view class="item-con">
<view class="item-num">{{ panelData.reactivePowerPCS }}
<view class="item-num">{{ panelData.lowV }}
</view>
<view class="item-title">{{$t('homePage.home.batCurrent')}}(A)</view>
@ -61,10 +61,10 @@
<image src="/static/aidex/images/dqgl.png"></image>
</view>
<view class="item-con">
<view class="item-num">{{ panelData.grid | isNull }}
<view class="item-num">{{ panelData.lowI | isNull }}
</view>
<view class="item-title">{{$t('homePage.home.busVoltage')}}(kVar)</view>
<view class="item-title">{{$t('homePage.home.busVoltage')}}(V)</view>
</view>
</view>
@ -76,132 +76,15 @@
<image src="/static/aidex/images/zfdl.png"></image>
</view>
<view class="item-con">
<view class="item-num">{{ panelData.volA | isNull }}
<view class="item-num">{{ panelData.highV | isNull }}
</view>
<view class="item-title">{{$t('homePage.home.busCurrent')}}(A)</view>
</view>
</view>
<view class="group-item border-right" @click="showHistory($t('homePage.home.dc'), 'volB', 'pcs', 'V', '')">
<view class="history-icon">
<image src="/static/aidex/images/history-icon.png"></image>
</view>
<view class="item-icon">
<image src="/static/aidex/images/zfdl.png"></image>
</view>
<view class="item-con">
<view class="item-num">{{ panelData.volB | isNull }}
</view>
<view class="item-title">{{$t('homePage.home.dc')}}(A)</view>
</view>
</view>
<view class="group-item" @click="showHistory($t('homePage.home.dcVoltage'), 'volC', 'pcs', 'V', '')">
<view class="history-icon">
<image src="/static/aidex/images/history-icon.png"></image>
</view>
<view class="item-icon">
<image src="/static/aidex/images/zfdl.png"></image>
</view>
<view class="item-con">
<view class="item-num">{{ panelData.volC | isNull }}
</view>
<view class="item-title">{{$t('homePage.home.dcVoltage')}}(kVar)</view>
</view>
</view>
<!-- <view class="group-item border-right" @click="showHistory($t('homePage.device.acur'), 'currentA', 'pcs', 'A', '')">
<view class="history-icon">
<image src="/static/aidex/images/history-icon.png"></image>
</view>
<view class="item-icon">
<image src="/static/aidex/images/rfdl.png"></image>
</view>
<view class="item-con">
<view class="item-num">{{ panelData.currentA | isNull }}
</view>
<view class="item-title">{{$t('homePage.device.acur')}}(A)</view>
</view>
</view> -->
<!-- <view class="group-item border-right" @click="showHistory($t('homePage.device.bcur'), 'currentB', 'pcs', 'A', '')">
<view class="history-icon">
<image src="/static/aidex/images/history-icon.png"></image>
</view>
<view class="item-icon">
<image src="/static/aidex/images/rfdl.png"></image>
</view>
<view class="item-con">
<view class="item-num">{{ panelData.currentB | isNull }}
</view>
<view class="item-title">{{$t('homePage.device.bcur')}}(A)</view>
</view>
</view>
<view class="group-item" @click="showHistory($t('homePage.device.ccur'), 'currentC', 'pcs', 'A', '')">
<view class="history-icon">
<image src="/static/aidex/images/history-icon.png"></image>
</view>
<view class="item-icon">
<image src="/static/aidex/images/rfdl.png"></image>
</view>
<view class="item-con">
<view class="item-num">{{ panelData.currentC | isNull }}
</view>
<view class="item-title">{{$t('homePage.device.ccur')}}(A)</view>
</view>
</view>
<view class="group-item border-right" @click="showHistory($t('homePage.device.DCPower'), 'dcPower', 'pcs', 'kW', '')">
<view class="history-icon">
<image src="/static/aidex/images/history-icon.png"></image>
</view>
<view class="item-icon">
<image src="/static/aidex/images/dqgl.png"></image>
</view>
<view class="item-con">
<view class="item-num">{{ panelData.dcPower | kWFormat }}</view>
<view class="item-title">{{$t('homePage.device.DCPower')}}({{ panelData.dcPower | kwUnitFormat}})</view>
</view>
</view>
<view class="group-item border-right" @click="showHistory($t('homePage.device.DCVol'), 'dcInputVol', 'pcs', 'V', '')">
<view class="history-icon">
<image src="/static/aidex/images/history-icon.png"></image>
</view>
<view class="item-icon">
<image src="/static/aidex/images/zfdl.png"></image>
</view>
<view class="item-con">
<view class="item-num">{{ panelData.dcInputVol | isNull }}
</view>
<view class="item-title">{{$t('homePage.device.DCVol')}}(V)</view>
</view>
</view>
<view class="group-item" @click="showHistory($t('homePage.device.DCCurrent'), 'dcCurrent', 'pcs', 'A', '')">
<view class="history-icon">
<image src="/static/aidex/images/history-icon.png"></image>
</view>
<view class="item-icon">
<image src="/static/aidex/images/rfdl.png"></image>
</view>
<view class="item-con">
<view class="item-num">{{ panelData.dcCurrent | isNull }}
</view>
<view class="item-title">{{$t('homePage.device.DCCurrent')}}(A)</view>
</view>
</view> -->
</view>
</view>
</view> -->
<historyModal :is-show.sync="histroyShow" :title="chartTitle" :params="hisParams" />
<u-action-sheet :list="actionSheetList" v-model="timeShow" @click="actionSheetCallback" @close="closeTimeAction"
:mask-close-able="false"></u-action-sheet>
@ -234,62 +117,80 @@
stationId: null,
srcId: null,
hnStationId: [417, 398, 416, 415, 405, 485],
actionSheetList: this.$t('homePage.device.timesArr'),
sampleTime:this.$t('homePage.device.timesArr')[0].label,
actionSheetList: Object.values(this.$t('homePage.home.timesArr')),
sampleTime:this.$t('homePage.home.timesArr')[0].text,
canvasData: [],
textCanvasData: [
{
type: "text",
coord: [
[144, 240]
],
font: [{
text:this.$t('homePage.home.activePowerpcs'),
size: 12,
color: "#999",
},
{
text: "",
size: 12,
color: "#000",
offsetX: 0
},
],
},
{
type: "text",
coord: [
[144, 260]
],
font: [{
text:this.$t('homePage.home.highV') + ':',
size: 12,
color: "#999",
},
{
text: "",
size: 12,
color: "#000",
offsetX: 0
},
],
},
//2
{
type: "text",
coord: [
[200, 200]
[144, 280]
],
font: [{
text:this.$t('homePage.device.vol') + "",
text:this.$t('homePage.home.lowV') + ':',
size: 12,
color: "#999",
},
{
text: "3.265 kVar",
text: "",
size: 12,
color: "#000",
left: 35
offsetX: 0
},
],
},
{
type: "text",
coord: [
[200, 220]
[144, 300]
],
font: [{
text:this.$t('homePage.device.current') + "",
text:this.$t('homePage.home.lowI') + ':',
size: 12,
color: "#999",
},
{
text: "3.98 A",
text: "",
size: 12,
color: "#000",
left: 35
},
],
},
{
type: "text",
coord: [
[200, 180]
],
font: [{
text:this.$t('homePage.home.pvPower') + "",
size: 12,
color: "#999",
},
{
text: "12.9 kW",
size: 12,
color: "#000",
left: 50
offsetX: 0
},
],
},
@ -299,6 +200,26 @@
coord: [
[3, 120]
],
font: [{
text: this.$t('homePage.device.gridMode') + ':',
size: 14,
color: "#999999",
width: 50,
},
{
text: "",
size: 14,
color: "#000",
left: 80
},
],
},
//6
{
type: "text",
coord: [
[3, 140]
],
font: [{
text: this.$t('homePage.device.runState') + ':',
size: 14,
@ -306,10 +227,10 @@
width: 50,
},
{
text: this.$t('homePage.device.offGrid'),
text: "",
size: 14,
color: "#000",
left: 80
offsetX: 0
},
],
}
@ -384,7 +305,7 @@
self.chartLoading = true;
return new Promise((resolve, reject) => {
self.$u.api.deviceList
.GetPCSCurve({
.GetPvCurve({
stationId: this.stationId,
sampleTime: this.time,
srcId: this.srcId,
@ -406,12 +327,12 @@
},
initChargeChart(val) {
const gonglv = [];
const soc = [];
// const soc = [];
const xAxis = [];
val.forEach((v) => {
xAxis.push(v.data);
gonglv.push(v.pcsRealTimeCurve);
soc.push(v.inCoreDataCurve);
gonglv.push(v.planCurve);
// soc.push(v.inCoreDataCurve);
});
this.curve_option = {
color: ["#BFE49F"],
@ -548,7 +469,6 @@
}
],
};
},
openTimeAction() {
this.timeShow = true;
@ -556,90 +476,50 @@
getStatus() {
this.stationLoading = true
const self = this;
this.$u.api.deviceList
.GetNewValue({
stationId: this.stationId,
srcId: this.srcId,
colList: [
"runState",
"remoteInPlace",
"onGrid",
"offGrid",
"stateCharging",
"stateDischarging",
"deviceStateStand",
"deviceStateFault",
"deviceStateFull",
"deviceStateEmpty",
"acBreaker",
"dcBreaker",
"soc",
"outputPower",
"reactivePowerPCS",
"grid",
"volA",
"volB",
"volC",
"currentA",
"currentB",
"currentC",
"dcPower",
"dcInputVol",
"dcCurrent",
colList: ["lowV", "highV", "lowI",
"pvActivePower","runState","remoteInPlace",
"onGrid","offGrid","stateCharging",
"stateDischarging","deviceStateStand","deviceStateFault",
"deviceStateFull","deviceStateEmpty","dcBreaker",
"eStop","soc","grid",
"outputPower",
// "reactivePowerPCS",
// ,
// "volA",
// "volB",
// "volC",
// "currentA",
// "currentB",
// "currentC",
// "dcPower",
// "dcInputVol",
// "dcCurrent",
],
})
.then((res) => {
const battery = self.updateBattery(res.data.soc?.value ? res.data.soc.value : 0);
this.panelData = {
outputPower: res.data.outputPower?.value ? res.data.outputPower?.value : 0,
reactivePowerPCS: res.data.reactivePowerPCS?.value ? res.data.reactivePowerPCS?.value :
0,
grid: res.data.grid?.value ? res.data.grid?.value : 0,
volA: res.data.volA?.value ? res.data.volA?.value : 0,
volB: res.data.volB?.value ? res.data.volB?.value : 0,
volC: res.data.volC?.value ? res.data.volC?.value : 0,
currentA: res.data.currentA?.value ? res.data.currentA?.value : 0,
currentB: res.data.currentB?.value ? res.data.currentB?.value : 0,
currentC: res.data.currentC?.value ? res.data.currentC?.value : 0,
dcPower: res.data.dcPower?.value ? res.data.dcPower?.value : 0,
dcInputVol: res.data.dcInputVol?.value ? res.data.dcInputVol?.value : 0,
dcCurrent: res.data.dcCurrent?.value ? res.data.dcCurrent?.value : 0,
lowV: res.data.lowV?.value ? res.data.lowV?.value : 0,
highV: res.data.highV?.value ? res.data.highV?.value : 0,
lowI: res.data.lowI?.value ? res.data.lowI?.value : 0,
pvActivePower: res.data.pvActivePower?.value ? res.data.pvActivePower?.value : 0
};
// this.textCanvasData[2].font[1].text = res.data.soc?.value ? res.data.soc.value + "%" : 0 + "%";
// this.textCanvasData[3].font[1].text = this.workStatus(res.data.runState?.value);
// if (this.stationId === 349 || this.stationId === 362 || this.stationId === 363) {
// if (res.data.remoteInPlace?.value === 0) {
// this.textCanvasData[4].font[1].text = this.$t('homePage.device.localAutomatic')
// }
// if (res.data.remoteInPlace?.value === 1) {
// this.textCanvasData[4].font[1].text = this.$t('homePage.device.localManual')
// }
// if (res.data.remoteInPlace?.value === 2) {
// this.textCanvasData[4].font[1].text = this.$t('homePage.device.distance')
// }
// } else {
// if (res.data.remoteInPlace?.value === 0) {
// this.textCanvasData[4].font[1].text = this.$t('homePage.device.local')
// }
// if (res.data.remoteInPlace?.value === 1) {
// this.textCanvasData[4].font[1].text = this.$t('homePage.device.distance')
// }
// }
// this.textCanvasData[5].font[1].text = res.data.onGrid?.value ?
// this.$t('homePage.device.grid') :
// this.$t('homePage.device.offGrid');
// if(res.data.outputPower?.value){
// this.textCanvasData[6].font[1].text = this.getFlowDirection(res.data.outputPower?.value, res
// .data.flowDirection)
// }
this.canvasData = [...this.textCanvasData, ...this.imageCanvasData, ...this
.lineCanvasData
]
this.textCanvasData[0].font[1].text = res.data.pvActivePower?.value ? res.data.pvActivePower.value + " kW" : 0 + " kW";
this.textCanvasData[1].font[1].text = res.data.highV?.value ? res.data.highV.value + " V" : 0 + " V";
this.textCanvasData[2].font[1].text = res.data.lowV?.value ? res.data.lowV.value + " V" : 0 + " V";
this.textCanvasData[3].font[1].text = res.data.lowI?.value ? res.data.lowI.value + " A" : 0 + " A";
this.textCanvasData[5].font[1].text = res.data.onGrid?.value ?
this.$t('homePage.device.grid') :
this.$t('homePage.device.offGrid');
if(res.data.outputPower?.value){
this.textCanvasData[6].font[1].text = this.getFlowDirection(res.data.outputPower?.value, res
.data.flowDirection)
}
this.canvasData = [...this.textCanvasData, ...this.imageCanvasData, ...this.lineCanvasData]
})
.finally((res) => {
this.stationLoading = false;

View File

@ -236,8 +236,8 @@
stationId: null,
srcId: null,
hnStationId: [417, 398, 416, 415, 405, 485],
actionSheetList: this.$t('homePage.device.timesArr'),
sampleTime:this.$t('homePage.device.timesArr')[0].label,
actionSheetList: Object.values(this.$t('homePage.home.timesArr')),
sampleTime:this.$t('homePage.home.timesArr')[0].text,
canvasData: [],
textCanvasData: [
//0

View File

@ -87,7 +87,6 @@
}
},
onLoad(options) {
this.Devicetype = options.type
if (this.Devicetype === 'storage' || this.Devicetype === 'anything') {
this.list = [{
@ -194,6 +193,7 @@
methods: {
device(val) {
console.log(val);
this.Devicetype = val
},
changeTab(type) {

View File

@ -84,7 +84,7 @@
type = "storage";
} else if (item.deviceType?.includes("basic") ) {
type = "anything"
} else if (item.deviceType?.includes("mttp") ) {
} else if (item.deviceType?.includes("mttp") || item.deviceType?.includes("mppt")) {
type = "mttp"
}

View File

@ -1,28 +1,38 @@
<template>
<view class="p_container">
<u-navbar :is-back="true" :background="background" :border-bottom="false" :custom-back="toback">
<u-navbar :is-back="true" :background="background" :border-bottom="false">
<!-- <u-navbar :is-back="true" :background="background" :border-bottom="false" :custom-back="toback"> -->
<view class="slot-wrap">
<stationDropdow disabled style="width: 100%" ref="dropdow" />
</view>
</u-navbar>
<zero-loading v-if="loading"></zero-loading>
<!-- <zero-loading v-if="loading"></zero-loading> -->
<view v-else style="height: calc(100% - 100rpx);">
<!-- <view v-else style="height: calc(100% - 100rpx);"> -->
<view style="height: calc(100% - 100rpx);">
<!-- <view class="search">
<luyj-tree-search :placeholder="$t('homePage.home.revenue')">
</luyj-tree-search>
</view> -->
<view class="p_content">
<view class="selectContent">
<view class="p_box selectItem" v-for="(item,index) in labeArr" :key="index" @click="toUrl(item)">
<view class="p_box selectItem" @click="toUrl(labeArr[0])">
<view >
<image :src="item.icon" mode="" style="height: 48rpx; width: 48rpx;" class="selectIcon"></image>
<image :src="labeArr[0].icon" mode="" style="height: 48rpx; width: 48rpx;" class="selectIcon"></image>
</view>
<view class="">
{{ item.label}}
{{ labeArr[0].label}}
</view>
</view>
<view class="p_box selectItem" v-if="inverterFlag === 1" @click="toUrl(labeArr[1])">
<view >
<image :src="labeArr[1].icon" mode="" style="height: 48rpx; width: 48rpx;" class="selectIcon"></image>
</view>
<view class="">
{{ labeArr[1].label}}
</view>
</view>
</view>
</view>
@ -59,6 +69,9 @@
currentStation() {
return this.vuex_currentStation;
},
inverterFlag(){
return this.vuex_inverterFlag;
}
},
methods: {
toUrl(val) {

View File

@ -6,8 +6,15 @@
<script>
export default {
props: {
time: {
type: String,
default: "",
},
},
data() {
return {
stationId:'',
chartData: {},
//您可以通过修改 config-ucharts.js 文件中下标为 ['column'] 的节点来配置全局默认参数,如都是默认参数,此处可以不传 opts 。实际应用过程中 opts 只需传入与全局默认参数中不一致的【某一个属性】即可实现同类型的图表显示不同的样式,达到页面简洁的需求。
opts: {
@ -23,10 +30,10 @@
disableGrid: true,
rotateLabel: true,
rotateAngle: 30,
titleOffsetY: 20,
titleOffsetX: 5,
marginTop: 5
marginTop: 5,
labelCount: 7
},
yAxis: {
data: [{
@ -44,32 +51,53 @@
};
},
created() {
console.log("runChart onReady");
this.getServerData();
this.GetPvMonthData();
},
computed: {
currentStation() {
return this.vuex_currentStation;
},
},
watch: {
currentStation: {
handler(val) {
this.stationId = val.id;
},
deep: true,
immediate: true,
},
},
methods: {
getServerData() {
let _this = this;
//模拟从服务器获取数据时的延时
setTimeout(() => {
//模拟服务器返回数据,如果数据格式和标准格式不同,需自行按下面的格式拼接
let res = {
categories: ["2025-10-17", "2025-10-18", "2025-10-19", "2025-10-20", "2025-10-21",
"2025-10-22"
],
series: [
{
name:this.$t('homePage.home.powerGeneration'),
textColor: "#FFFFFF",
data: [18, 27, 21, 24, 6, 28]
}
]
};
this.chartData = JSON.parse(JSON.stringify(res));
}, 500);
},
async GetPvMonthData(){
try {
const res = await this.$u.api.enrnings.GetPvMonthData({
stationId: this.stationId,
time: this.time,
});
let resdata = {
categories:[],
series:[{
name:this.$t('homePage.home.powerGeneration'),
textColor: "#FFFFFF",
data: []
}]
}
if (res.data.length) {
res.data.forEach((el) => {
resdata.categories.push(el.date)
resdata.series[0].data.push(el.powerGenerate)
});
console.log(JSON.parse(JSON.stringify(resdata)));
this.chartData = JSON.parse(JSON.stringify(resdata));
} else {
this.chargeArr = [];
}
} catch (e) {
//TODO handle the exception
} finally {
this.loading = false;
}
}
}
};
</script>

View File

@ -27,42 +27,57 @@
</view>
</view>
<view class="power-generation">
<Section :title="$t('homePage.earning.changeDischargePro')" />
<Section :title="$t('homePage.home.powerGenerationStatus')" />
<view class="power-generation-detail">
<view class="value-box">
<view class="icon zjry"> </view>
<view class="title">
{{ $t("homePage.earning.capacity") }}
</view>
<view class="value">
{{ totalData.capacity | isNull }}
</view>
<view class="unit"> kWh </view>
</view>
<view class="value-box">
<view class="icon byzc"> </view>
<view class="title">
{{ $t("homePage.earning.monthTotalCharge") }}
</view>
<view class="value">
{{ totalData.totalChargeElec | isNull }}
</view>
<view class="unit"> kWh </view>
</view>
<view class="value-box">
<view class="icon zjry">
<view class="value-box">
<view class="icon byzf"> </view>
<view class="title">
{{ $t("homePage.earning.monthTotalDischarge") }}
</view>
<view class="value">
{{ totalData.totalDischargeElec | isNull }}
</view>
<view class="unit"> kWh </view>
</view>
</view>
<view class="title">
{{ $t('homePage.home.currentMonthlyPowerGeneration') }}
</view>
<view class="value">
{{ totalData.monthReleaseElec | isNull }}
</view>
<view class="unit">
kWh
</view>
</view>
<view class="value-box">
<view class="value-box">
<view class="icon byzc">
</view>
<view class="title">
{{ $t('homePage.home.cumulativePowerGeneration') }}
</view>
<view class="value">
{{ totalData.totalReleaseElec | isNull }}
</view>
<view class="unit">
kWh
</view>
</view>
<view class="value-box">
<view class="icon byzf">
</view>
<view class="title">
{{ $t('homePage.home.ratedPowernokw') }}
</view>
<view class="value">
{{ totalData.pvPower | isNull }}
</view>
<view class="unit">
kW
</view>
</view>
<!-- <view class="value-box">
<view class="icon yxtzhl"> </view>
<view class="title">
{{ $t("homePage.earning.monthEff") }}
@ -101,13 +116,13 @@
{{ totalData.totalConvRate | isNull }}
</view>
<view class="unit"> % </view>
</view>
</view> -->
</view>
</view>
<view class="month-power">
<Section :title="$t('homePage.home.projectMonthlyPower')" />
<view class="power-generation-detail">
<run-chart />
<run-chart :time="time" />
</view>
</view>
<view class="month-power">
@ -120,19 +135,17 @@
<view class="power-detail">
<view class="left-value">
<view class="value">
{{ totalData.totalChargePrice | isNull }}
{{ totalData.monthIncone | isNull }}
</view>
<view class="title">
{{ $t("homePage.home.enmonthTotalChargePrice") }}
{{ $t("homePage.home.monthlyIncome") }}
</view>
</view>
<view class="right-value t-fdzl"> </view>
</view>
<view
class="power-detail"
style="margin: 0 !important; padding-bottom: 0 !important"
>
<!-- <view class="power-detail"
style="margin: 0 !important; padding-bottom: 0 !important" >
<view class="left-value">
<view class="value">
{{ totalData.totalDisChargePrice | isNull }}
@ -142,22 +155,32 @@
</view>
</view>
<view class="right-value t-swdl"> </view>
</view>
</view> -->
</view>
<view class="right">
<view class="value-box">
<view class="value">
<view class="left">
<view class="power-detail">
<view class="left-value">
<view class="value">
{{ totalData.income | isNull }}
</view>
<view class="title">
{{ $t("homePage.home.totalRevenue") }}
</view>
</view>
<!-- <view class="right-value t-fdzl"> </view> -->
<view class="right-value bg"> </view>
<!-- <view class="value">
{{ totalData.income | isNull }}
</view>
<view class="title">
{{ $t("homePage.home.enearnings") }}
{{ $t("homePage.home.totalRevenue") }}
</view>
<view class="bg"> </view>
<view class="bg"> </view> -->
</view>
</view>
</view>
</view>
<view class="report-detail">
<!-- <view class="report-detail">
<Section
:title="$t('homePage.earning.earningsDetail')"
style="margin-bottom: 30rpx"
@ -224,7 +247,7 @@
{{ $t("homePage.earning.noDisChargeData") }}
</view>
</view>
</view>
</view> -->
<u-picker
v-model="TimeShow"
@ -430,7 +453,7 @@ export default {
}
.power-generation {
height: 760rpx;
height: 380rpx;
background-color: #ffffff;
box-shadow: 0px 4rpx 16rpx rgba(0, 0, 0, 0.1);
margin-left: 30rpx;
@ -643,9 +666,6 @@ export default {
.left {
width: 50%;
height: 100%;
display: flex;
flex-direction: column;
justify-content: space-between;
padding: 20rpx;
padding-top: 0rpx;
padding-bottom: 0rpx;
@ -654,9 +674,8 @@ export default {
.power-detail {
background-color: rgba(254, 131, 15, 0.05);
width: 100%;
height: 180rpx;
height: 100%;
border-radius: 8rpx;
margin-bottom: 22rpx;
display: flex;
align-items: center;
justify-content: space-between;
@ -685,6 +704,13 @@ export default {
right: 20rpx;
}
.bg {
width: 194rpx;
height: 188rpx;
background-image: url("/static/aidex/images/total-sy.png");
background-size: 100% 100%;
}
.t-fdzl {
width: 121rpx;
height: 119rpx;

View File

@ -4,7 +4,7 @@
<!-- <image src="/static/aidex/login/login-bg.png" class="logo"></image> -->
<view class="logo">
<view class="EnglishFont">
STORASMART
ZETA CLOUD
</view>
</view>
<image src="/static/aidex/login/bg-logo2.png" class="center-logo"></image>
@ -17,11 +17,11 @@
<u-select v-model="langShow" :list="Langlist" @confirm="changeLanguage"></u-select>
<u-radio-group v-model="StationValue" @change="radioGroupChange" active-color="#009C77">
<!-- <u-radio-group v-model="StationValue" @change="radioGroupChange" active-color="#009C77">
<u-radio @change="radioChange" v-for="(item, index) in $t('homePage.home.stationType')" :key="index" :name="item.name">
{{ item.name }}
</u-radio>
</u-radio-group>
</u-radio-group> -->
<view class="user-card">
<view class="list">
@ -139,7 +139,7 @@ export default {
showMsg: false,
Stationlist: this.$t('homePage.home.stationType'),
// u-radio-group的v-model绑定的值如果设置为某个radio的name就会被默认选中
StationValue: '',
StationValue: 'en_US',
}
},
onLoad () {
@ -194,8 +194,9 @@ export default {
});
} else if (val === '中国站' || val === 'China Station') {
this.$u.http.setConfig({
// baseUrl: 'http://1.95.170.86:8002/api'
baseUrl: 'https://zzkj-cloud.com/api'
// baseUrl: 'http://1.95.170.86:8002/api'
baseUrl: 'https://zetatech.zzkj-cloud.com/api'
// baseUrl: 'https://zzkj-cloud.com/api'
});
}
const res = await this.$u.api.GetLanguageConfig('zh')
@ -432,6 +433,7 @@ export default {
this.$u.api.alarm.GetNewStationlist().then((res) => {
this.$u.vuex("vuex_provinceStation", res.data.list)
this.$u.vuex("vuex_currentStation", res.data.list[0].list[0].list[0])
this.$u.vuex("vuex_inverterFlag", res.data.list[0].list[0].list[0].inverterFlag)
})
},
wxLogin (res) {

View File

@ -27,7 +27,6 @@
currentStation() {
return this.vuex_currentStation;
},
},
watch: {
currentStation: {

View File

@ -1,23 +1,30 @@
<template>
<view class="grid" :style="{'grid-template-columns': `repeat(${col}, 1fr)`}">
<view class="item" v-for="(item,index) in list" :key="index">
<image v-if="item.showMark" src="/static/aidex/images/history-icon.png" mode="" class="rightMark"></image>
<view>
<image :src="item.image" mode="" :style="{height:imgHeight,width:imgWidth}"></image>
<zero-loading v-if="loading"></zero-loading>
<template v-else>
<view class="item" v-for="(item,index) in list" :key="index">
<image v-if="item.showMark" src="/static/aidex/images/history-icon.png" mode="" class="rightMark"></image>
<view>
<image :src="item.image" mode="" :style="{height:imgHeight,width:imgWidth}"></image>
</view>
<view class="num">
{{item.value}}
</view>
<view class="label">
{{item.label}}
</view>
</view>
<view class="num">
{{item.value}}
</view>
<view class="label">
{{item.label}}
</view>
</view>
</template>
</view>
</template>
<script>
export default {
props: {
loading:{
type: Boolean,
default:false
},
list: {
type: Array,
default: () => []

View File

@ -21,9 +21,7 @@
<view class="item-num">{{ panelData.totalCapacity | kwhFormat }}
</view>
<view class="item-title">{{ this.$t('homePage.home.totalCapacity') }}({{
panelData.totalCapacity | kwhUnitFormat
}})</view>
<view class="item-title">{{ this.$t('homePage.home.totalCapacity') }}({{ panelData.totalCapacity | kwhUnitFormat }})</view>
</view>
</view>
<view class="group-item">

View File

@ -87,8 +87,7 @@
<image src="/static/aidex/images/rfdl.png"></image>
</view>
<view class="item-con">
<view class="item-num">{{ panelData.dailyDischargeElec | kwhFormat
}}</view>
<view class="item-num">{{ panelData.dailyDischargeElec | kwhFormat }}</view>
<view class="item-title">{{ this.$t('homePage.home.dailyDischarge') }}({{ panelData.dailyDischargeElec | kwhUnitFormat }})</view>
</view>
</view>

View File

@ -1,7 +1,7 @@
<template>
<view>
<svg xmlns="http://www.w3.org/2000/svg" version="1.1" id="svgBoxss" style="height: 100%;width: 100%;"
viewBox="0 0 1280 1680">
viewBox="0 0 1280 1680" ref="svgBoxss">
<path d="M 1092,93L 1080,93L 1080,94L 1092,94Z" style="fill:rgb(0,128,0);" />
<path d="M 173,854L 174,853L 174,851L 174.5,848L 175,847L 175,846L 174,843L 168,843L 168,853L 170,854Z"
@ -1209,7 +1209,7 @@
}
},
mounted() {
document.getElementById('svgBoxss')?.appendChild(this.createSvgText(this.tags))
this.$refs.svgBoxss?.appendChild(this.createSvgText(this.tags))
},
}
</script>

View File

@ -1,7 +1,7 @@
<template>
<view>
<svg style="width:100%; height:100%;" xmlns="http://www.w3.org/2000/svg"
xmlns:xlink="http://www.w3.org/1999/xlink" id="svgBox" viewBox="0 0 1280 1360">
xmlns:xlink="http://www.w3.org/1999/xlink" id="svgBox" ref="svgBox" viewBox="0 0 1280 1360">
<!-- 图片相关不用管 -->
<path
@ -562,9 +562,8 @@
<!-- <circle cx="573" cy="500" r="16" fill="#58D86B" /> -->
<circle class="anim-topright anim-boxele" cx="573" cy="500" r="16" fill="#58D86B" />
<!-- 动画元素 -->
<circle id="myCircle" cx="280" cy="67" r="15" fill="#0DA17D">
<animate attributeName="cx" from="280" to="1000" dur="3000ms" fill="freeze" repeatCount="indefinite" />
</circle>
<circle class="myCircle" cx="280" cy="67" r="15" fill="#0DA17D"/>
</svg>
</view>
@ -664,7 +663,7 @@
}
},
mounted() {
document.getElementById('svgBox')?.appendChild(this.createSvgText(this.tags))
this.$refs.svgBox?.appendChild(this.createSvgText(this.tags))
},
}
</script>
@ -674,6 +673,24 @@
font-family: Arial, sans-serif;
font-size: 40px;
fill: #7F7F7F;
}
.myCircle {
r: 15;
fill: #0DA17D;
animation: moveRight 3s linear 0s infinite both;
}
/* 关键帧:定义运动轨迹(向右→向下→复位) */
@keyframes moveRight {
/* 0%初始位置cx=280, cy=67 */
0% {
cx: 280;
cy: 67;
}
/* 100%:瞬间复位(避免卡顿) */
100% {
cx: 1000;
cy: 67;
}
}
/* 通用动画点样式 */
.anim-pv1 {

File diff suppressed because it is too large Load Diff

View File

@ -35,43 +35,26 @@
<view class="box">
<Section :title="$t('homePage.home.stationTopo')" />
<cixi v-if="topologyType === 0" ref="tuopu" />
<kejiyuan v-else-if="topologyType === 2" ref="tuopu" />
<lingchao v-else-if="topologyType === 3" ref="tuopu" />
<jingke v-else-if="topologyType === 4" ref="tuopu" />
<weishanhu v-else-if="topologyType === 5" ref="tuopu" />
<zhongzihuanbao v-else-if="topologyType === 6" ref="tuopu" />
<sanmenxia v-else-if="topologyType === 7" ref="tuopu" />
<second v-else-if="topologyType === 8" ref="tuopu" />
<fire v-else-if="topologyType === 9" ref="tuopu" />
<runda100 v-else-if="topologyType === 10" ref="tuopu" />
<runda230 v-else-if="topologyType === 11" ref="tuopu" />
<runda215 v-else-if="topologyType === 12" ref="tuopu" />
<third v-else-if="topologyType === 13" ref="tuopu" />
<mdPviese v-else-if="topologyType === 14" ref="tuopu" />
<ceshi-t v-else-if="topologyType === 1" />
<standard v-else ref="tuopu" />
</view>
<view class="box">
<Section title="测试01" />
<view class="marginT20" >
<!-- <iframe :src="src" frameborder="0"></iframe> -->
<web-view :src="src" :fullscreen="false" style="height: 200rpx;"></web-view>
<!-- 加载中占位可选 -->
<view v-else class="loading-tip">
<zero-loading v-if="tuopoloading"></zero-loading>
<cixi v-if="topologyType === 0" ref="tuopu" />
<kejiyuan v-else-if="topologyType === 2" ref="tuopu" />
<lingchao v-else-if="topologyType === 3" ref="tuopu" />
<jingke v-else-if="topologyType === 4" ref="tuopu" />
<weishanhu v-else-if="topologyType === 5" ref="tuopu" />
<zhongzihuanbao v-else-if="topologyType === 6" ref="tuopu" />
<sanmenxia v-else-if="topologyType === 7" ref="tuopu" />
<second v-else-if="topologyType === 8" ref="tuopu" />
<fire v-else-if="topologyType === 9" ref="tuopu" />
<runda100 v-else-if="topologyType === 10" ref="tuopu" />
<runda230 v-else-if="topologyType === 11" ref="tuopu" />
<runda215 v-else-if="topologyType === 12" ref="tuopu" />
<third v-else-if="topologyType === 13" ref="tuopu" />
<mdPviese v-else-if="topologyType === 14" ref="tuopu" />
<pv2first v-else-if="topologyType === 1 && inverterFlag === 1 && pvTopologyType === 2" ref="tuopu" />
<standard v-else ref="tuopu" />
</view>
</view>
<!-- <view class="box">
<Section title="测试02" />
<view class="marginT20">
<ceshi-l />
</view>
</view>
<view class="box">
<Section title="测试03" />
当前组件有数据处理示例
<view class="marginT20">
<ceshi-s />
</view>
</view> -->
<view v-if="topologyType === 9" class="box">
<Section :title="$t('homePage.home.deviceMonitor')" />
<devicemonitoring ref="deviceFire" />
@ -87,7 +70,7 @@
<view slot="right" style="flex: 1">
<view class="top-right-box">
<view class="top-right-item" :class="{ active: activeTime === 'day' }"
@click="changeTime('day')">{{this.$t('homePage.home.sevenDay')}}
@click="changeTime('day')">{{this.$t('homePage.home.sevenDaycom')}}
</view>
<view class="top-right-item" :class="{ active: activeTime === 'month' }"
@click="changeTime('month')">{{this.$t('homePage.home.monthDay')}}
@ -102,15 +85,15 @@
</view>
<view class="box">
<Section :title="$t('homePage.home.stationData')" />
<Section :title="$t('homePage.home.stationDatacom')" />
<wshStationData v-if="topologyType === 5" />
<zzhbStationData v-else-if="topologyType === 6" />
<commonStationData v-else />
</view>
<view class="box" v-if="topologyType === 1">
<view class="box" v-if="inverterFlag === 1">
<Section :title="$t('homePage.home.pvKpi')" />
<view class="">
<my-grid imgHeight="40rpx" imgWidth="40rpx" :list="lightArr" />
<my-grid :loading="loading" :col="language !== 'zh_CN'? 2:3" imgHeight="40rpx" imgWidth="40rpx" :list="lightArr"/>
</view>
</view>
<view class="box" v-if="topologyType === 1">
@ -118,12 +101,12 @@
<environmentalControlPosition v-if="rightCenter === 'dispositionRightCenter'" />
<environmentalControl v-else />
</view>
<view class="box">
<!-- <view class="box" v-if="inverterFlag === 1">
<Section :title="$t('homePage.home.socialContribution')" />
<view class="">
<my-grid :col="3" imgHeight="72rpx" imgWidth="82rpx" :list="society" />
</view>
</view>
</view> -->
</view>
@ -140,6 +123,9 @@
import ceshiT from './components/topology/ceshiT.vue'
import ceshiL from './components/topology/ceshiL.vue'
import ceshiS from './components/topology/ceshiS.vue'
import pv2first from './components/topology/pv2first.vue'
import weishanhu from './components/topology/weishanhu.vue'
import sanmenxia from './components/topology/sanmenxia.vue'
import lingchao from './components/topology/lingchao.vue'
@ -168,6 +154,7 @@
ceshiT,
ceshiL,
ceshiS,
pv2first,
myGrid,
stationDropdow,
Section,
@ -214,6 +201,13 @@
timer: null,
tuopuTimer: null,
rightCenter: null,
componentsLoaded: false,
tuopoloading:false,
topCenterPvArr:[
{name:'pv1AndStorage_261',value:1},
{name:'pv2AndStorage_261',value:2}
],
pvTopologyType:0,
society: [{
label: this.$t('homePage.home.saveStandardCoal'),
value: '15.00',
@ -230,29 +224,14 @@
image: require('@/static/aidex/images/ll03.png'),
},
],
lightArr: [{
label: this.$t('homePage.home.totalCapacity') + '(kW)',
value: '100.00',
image: require('@/static/aidex/images/ll05.png'),
},
{
label: this.$t('homePage.home.currentPower') + '(kW)',
value: '47.00',
image: require('@/static/aidex/images/ll06.png'),
},
{
label: this.$t('homePage.home.dailyPowerGeneration') + '(kWh)',
value: '85.00',
image: require('@/static/aidex/images/ll07.png'),
showMark: true
},
{
label: this.$t('homePage.home.cumulativePowerGeneration') + '(kWh)',
value: '496.00',
image: require('@/static/aidex/images/ll07.png'),
showMark: true
},
]
panelData: {
pvCurrentPower: 0, // 对应 lightArr[0].value
dailyReleaseElec: 0, // 对应 lightArr[1].value
totalReleaseElec: 0, // 对应 lightArr[2].value
todayIncone: 0, // 对应 lightArr[3].value
totalIncome: 0, // 对应 lightArr[4].value
pvPower: 0 // 对应 lightArr[5].value
}
};
},
computed: {
@ -264,7 +243,44 @@
},
language() {
return this.vuex_language
}
},
inverterFlag(){
return this.vuex_inverterFlag;
},
lightArr() {
return [
{
label: this.$t('homePage.home.currentPower') + '(kW)',
value: this.panelData.pvCurrentPower,
image: require('@/static/aidex/images/ll06.png')
},
{
label: this.$t('homePage.home.dailyPowerGeneration') + '(kWh)',
value: this.panelData.dailyReleaseElec,
image: require('@/static/aidex/images/ll07.png')
},
{
label: this.$t('homePage.home.cumulativePowerGeneration') + '(kWh)',
value: this.panelData.totalReleaseElec,
image: require('@/static/aidex/images/ll07.png')
},
{
label: this.$t('homePage.home.todayEarning'),
value: this.panelData.todayIncone,
image: require('@/static/aidex/images/yxts.png')
},
{
label: this.$t('homePage.home.totalRevenue'),
value: this.panelData.totalIncome,
image: require('@/static/aidex/images/yxts.png')
},
{
label: this.$t('homePage.home.ratedPower'),
value: this.panelData.pvPower,
image: require('@/static/aidex/images/ll06.png')
}
];
}
},
onHide() {
if (this.timer) {
@ -276,29 +292,30 @@
},
watch: {
currentStation: {
handler(val) {
if (val && val.id) {
this.stationId = val.id
this.userId = this.userData.userId
console.log('拓扑图',val)
this.topologyType = val.topologyType
this.getComponents()
this.$nextTick(() => {
if (this.$refs.tuopu) {
this.$refs.tuopu.getData(val.id)
}
if (this.$refs.deviceFire) {
this.$refs.deviceFire.getData(this.stationId)
}
})
}
},
deep: true,
immediate: true,
},
handler(val) {
if (val && val.id) {
this.stationId = val.id
this.userId = this.userData.userId
this.topologyType = val.topologyType
// 重置加载状态,避免复用旧状态
this.componentsLoaded = false
this.tuopoloading = true
this.getComponents().then(() => {
this.GetPcsTotalData();
this.$nextTick(() => {
if (this.$refs.tuopu) {
this.$refs.tuopu.getData(val.id)
}
if (this.$refs.deviceFire) {
this.$refs.deviceFire.getData(this.stationId)
}
});
});
}
},
deep: true,
immediate: true,
}
},
created() {
@ -319,25 +336,27 @@
})
},
onShow() {
this.getComponents()
this.getMessage()
if (this.$refs.runChart && this.stationId) {
this.$refs.runChart.getData()
}
if (this.$refs.dischargeChart && this.stationId) {
this.$refs.dischargeChart.getData()
}
this.$nextTick(() => {
if (this.$refs.tuopu) {
// 重置加载状态
this.componentsLoaded = false
this.tuopoloading = true
this.getComponents().then(() => {
this.getMessage()
if (this.$refs.runChart && this.stationId) {
this.$refs.runChart.getData()
}
if (this.$refs.dischargeChart && this.stationId) {
this.$refs.dischargeChart.getData()
}
this.$nextTick(() => {
if (this.$refs.tuopu) {
this.$refs.tuopu.changeEnglish()
this.$refs.tuopu.getData(this.stationId)
}
if (this.$refs.deviceFire) {
}
if (this.$refs.deviceFire) {
this.$refs.deviceFire.getData(this.stationId)
}
})
}
})
});
this.timer = setInterval(() => {
this.getMessage()
}, 5000)
@ -354,13 +373,39 @@
},
methods: {
async GetPcsTotalData() {
let self = this;
return new Promise((resolve, reject) => {
self.$u.api.homePageData
.GetPcsTotalData({
stationId: this.stationId,
})
.then((res) => {
this.panelData = Object.assign(this.panelData, res.data);
resolve(res);
})
.catch((err) => {
reject("error");
});
});
},
async getComponents() {
const {
data
} = await this.$u.api.homePageData.GetHomePageComponents(this.stationId)
if (data && data.length > 0) {
this.rightCenter = data[0]?.rightCenter
}
try {
const { data } = await this.$u.api.homePageData.GetHomePageComponents(this.stationId);
if (data && data.length > 0) {
this.rightCenter = data[0]?.rightCenter;
const matchedItem = this.topCenterPvArr.find(item => item.name === data[0]?.topCenter);
this.pvTopologyType = matchedItem ? matchedItem.value : this.pvTopologyType;
}
// 接口完成标记加载状态为true
this.componentsLoaded = true
this.tuopoloading = false
} catch (e) {
console.error('获取组件配置失败:', e);
// 即使接口失败,也标记完成,避免组件一直不渲染
this.componentsLoaded = true
this.tuopoloading = false
}
},
openTimer() {
@ -526,7 +571,12 @@
margin: 20rpx;
margin-top: 30rpx;
box-shadow: 0px 4rpx 16rpx rgba(0, 0, 0, 0.08);
.loading-tip {
width: 650rpx;
height: 710rpx;
position: relative;
}
.top-right-box {
display: flex;
flex-direction: row;

View File

@ -51,7 +51,8 @@ const store = new Vuex.Store({
vuex_psdkey: lifeData.vuex_psdkey ? lifeData.vuex_psdkey : '',
vuex_StationShow:lifeData.vuex_StationShow ? lifeData.vuex_StationShow : [0,0,0],
tabbar_current: 0,
vuex_stationValue:lifeData.vuex_stationValue ? lifeData.vuex_stationValue : '',
vuex_stationValue:lifeData.vuex_stationValue ? lifeData.vuex_stationValue : '',
vuex_inverterFlag:lifeData.vuex_inverterFlag ? lifeData.vuex_inverterFlag : 0,
tabbarList: [
{
"icon": "warning",

View File

@ -211,7 +211,6 @@ export default {
// #endif
},
init() {
console.log(1111,this.list);
// 如果没有数据的时候多处报未定义
if (!this.list || this.list.length == 0){
return