mirror of
https://github.com/emsesp/EMS-ESP32.git
synced 2025-12-06 07:49:52 +03:00
fixes #2497 - showFirmwareDialog() was missing argument
This commit is contained in:
@@ -172,7 +172,10 @@ const Version = () => {
|
|||||||
|
|
||||||
useLayoutTitle('EMS-ESP Firmware');
|
useLayoutTitle('EMS-ESP Firmware');
|
||||||
|
|
||||||
const renderInstallDialog = () => (
|
const renderInstallDialog = () => {
|
||||||
|
const binURL = getBinURL();
|
||||||
|
|
||||||
|
return (
|
||||||
<Dialog
|
<Dialog
|
||||||
sx={dialogStyle}
|
sx={dialogStyle}
|
||||||
open={openInstallDialog}
|
open={openInstallDialog}
|
||||||
@@ -206,14 +209,14 @@ const Version = () => {
|
|||||||
onClick={() => closeInstallDialog()}
|
onClick={() => closeInstallDialog()}
|
||||||
color="primary"
|
color="primary"
|
||||||
>
|
>
|
||||||
<Link underline="none" target="_blank" href={getBinURL()} color="primary">
|
<Link underline="none" target="_blank" href={binURL} color="primary">
|
||||||
{LL.DOWNLOAD(1)}
|
{LL.DOWNLOAD(1)}
|
||||||
</Link>
|
</Link>
|
||||||
</Button>
|
</Button>
|
||||||
<Button
|
<Button
|
||||||
startIcon={<WarningIcon color="warning" />}
|
startIcon={<WarningIcon color="warning" />}
|
||||||
variant="outlined"
|
variant="outlined"
|
||||||
onClick={() => installFirmwareURL(getBinURL())}
|
onClick={() => installFirmwareURL(binURL)}
|
||||||
color="primary"
|
color="primary"
|
||||||
>
|
>
|
||||||
{LL.INSTALL()}
|
{LL.INSTALL()}
|
||||||
@@ -221,6 +224,7 @@ const Version = () => {
|
|||||||
</DialogActions>
|
</DialogActions>
|
||||||
</Dialog>
|
</Dialog>
|
||||||
);
|
);
|
||||||
|
};
|
||||||
|
|
||||||
const showFirmwareDialog = (useDevVersion?: boolean) => {
|
const showFirmwareDialog = (useDevVersion?: boolean) => {
|
||||||
setUsingDevVersion(useDevVersion || usingDevVersion);
|
setUsingDevVersion(useDevVersion || usingDevVersion);
|
||||||
@@ -260,7 +264,7 @@ const Version = () => {
|
|||||||
variant="outlined"
|
variant="outlined"
|
||||||
color="warning"
|
color="warning"
|
||||||
size="small"
|
size="small"
|
||||||
onClick={() => showFirmwareDialog()}
|
onClick={() => showFirmwareDialog(showDev)}
|
||||||
>
|
>
|
||||||
{upgradeAvailable || (!usingDevVersion && showDev)
|
{upgradeAvailable || (!usingDevVersion && showDev)
|
||||||
? LL.UPGRADE()
|
? LL.UPGRADE()
|
||||||
|
|||||||
Reference in New Issue
Block a user