Skip to content

Commit

Permalink
fix: enable auto fetch lastest firmware
Browse files Browse the repository at this point in the history
  • Loading branch information
LynnL4 committed Dec 11, 2023
1 parent 473a342 commit 4d5c116
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions src/pages/setup/process/components/Device.vue
Original file line number Diff line number Diff line change
Expand Up @@ -322,15 +322,15 @@
const bins = deviceStore.firmware?.bins ?? [];
const fileArray = [];
const currentVersion = deviceStore.deviceVersion;
// if (version !== currentVersion) {
// if (bins.length === 0) {
// throw new Error(t('workplace.device.message.firmware.no'));
// }
// // 下载固件
// loadingTip.value = t('workplace.device.message.tip.downloading.firmware');
// const firmwareArray = await downloadFirmware(bins);
// fileArray.push(...firmwareArray);
// }
if (version !== currentVersion) {
if (bins.length === 0) {
throw new Error(t('workplace.device.message.firmware.no'));
}
// 下载固件
loadingTip.value = t('workplace.device.message.tip.downloading.firmware');
const firmwareArray = await downloadFirmware(bins);
fileArray.push(...firmwareArray);
}
let finallyModel: Model | null = null;
if (isCustom) {
if (!modelFile.value) {
Expand Down

0 comments on commit 4d5c116

Please sign in to comment.