WebApp: Show additional inverter info in DevInfo dialog
* Production Year * Production Week
This commit is contained in:
parent
759f8b7208
commit
3c9639bb53
@ -6,6 +6,18 @@
|
||||
</BootstrapAlert>
|
||||
<table v-if="devInfoList.valid_data" class="table table-hover">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>{{ $t('devinfo.Serial') }}</td>
|
||||
<td>{{ devInfoList.serial }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>{{ $t('devinfo.ProdYear') }}</td>
|
||||
<td>{{ productionYear() }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>{{ $t('devinfo.ProdWeek') }}</td>
|
||||
<td>{{ productionWeek() }}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>{{ $t('devinfo.Model') }}</td>
|
||||
<td v-if="devInfoList.hw_model_name != ''">{{ devInfoList.hw_model_name }}</td>
|
||||
@ -61,6 +73,16 @@ export default defineComponent({
|
||||
const version_patch = Math.floor((value - version_major * 10000 - version_minor * 100));
|
||||
return version_major + "." + version_minor + "." + version_patch;
|
||||
};
|
||||
},
|
||||
productionYear() {
|
||||
return() => {
|
||||
return ((parseInt(this.devInfoList.serial.toString(), 16) >> (7 * 4)) & 0xF) + 2014;
|
||||
}
|
||||
},
|
||||
productionWeek() {
|
||||
return() => {
|
||||
return ((parseInt(this.devInfoList.serial.toString(), 16) >> (5 * 4)) & 0xFF).toString(16);
|
||||
}
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
@ -129,6 +129,9 @@
|
||||
"NoInfo": "Keine Informationen verfügbar",
|
||||
"NoInfoLong": "Bisher wurden noch keine gültigen Daten vom Wechselrichter empfangen. Versuche es weiter...",
|
||||
"UnknownModel": "Unbekanntes Modell! Bitte melden Sie die \"Hardware Teilenummer\" und das Modell (z.B. HM-350) <a href=\"https://github.com/tbnobody/OpenDTU/issues\" target=\"_blank\">hier</a> als Problem.",
|
||||
"Serial": "Seriennummer",
|
||||
"ProdYear": "Produktionsjahr",
|
||||
"ProdWeek": "Produktionswoche",
|
||||
"Model": "Modell",
|
||||
"DetectedMaxPower": "Ermittelte max. Leistung",
|
||||
"BootloaderVersion": "Bootloader-Version",
|
||||
|
||||
@ -129,6 +129,9 @@
|
||||
"NoInfo": "No Information available",
|
||||
"NoInfoLong": "Did not receive any valid data from the inverter till now. Still trying...",
|
||||
"UnknownModel": "Unknown model! Please report the \"Hardware Part Number\" and model (e.g. HM-350) as an issue <a href=\"https://github.com/tbnobody/OpenDTU/issues\" target=\"_blank\">here</a>.",
|
||||
"Serial": "Serial",
|
||||
"ProdYear": "Production Year",
|
||||
"ProdWeek": "Production Week",
|
||||
"Model": "Model",
|
||||
"DetectedMaxPower": "Detected max. Power",
|
||||
"BootloaderVersion": "Bootloader Version",
|
||||
|
||||
@ -129,6 +129,9 @@
|
||||
"NoInfo": "Aucune information disponible",
|
||||
"NoInfoLong": "N'a pas reçu de données valides de l'onduleur jusqu'à présent. J'essaie toujours...",
|
||||
"UnknownModel": "Modèle inconnu ! Veuillez signaler le \"Numéro d'article matériel\" et le modèle (par exemple, HM-350) comme un problème <a href=\"https://github.com/tbnobody/OpenDTU/issues\" target=\"_blank\">ici</a>.",
|
||||
"Serial": "Serial",
|
||||
"ProdYear": "Production Year",
|
||||
"ProdWeek": "Production Week",
|
||||
"Model": "Modèle",
|
||||
"DetectedMaxPower": "Puissance maximale détectée",
|
||||
"BootloaderVersion": "Version du bootloader",
|
||||
|
||||
@ -1,4 +1,5 @@
|
||||
export interface DevInfoStatus {
|
||||
serial: number;
|
||||
valid_data: boolean;
|
||||
fw_bootloader_version: number;
|
||||
fw_build_version: number;
|
||||
|
||||
@ -540,6 +540,7 @@ export default defineComponent({
|
||||
.then((response) => handleResponse(response, this.$emitter, this.$router))
|
||||
.then((data) => {
|
||||
this.devInfoList = data[serial][0];
|
||||
this.devInfoList.serial = serial;
|
||||
this.devInfoLoading = false;
|
||||
});
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user