Nice message if we try to change the gateway on a device that is managed via DHCP
This commit is contained in:
parent
856d0885f2
commit
67210c4d1e
@ -483,8 +483,15 @@ namespace EduNetworkBuilder
|
|||||||
if (NB.GetComponentType(ClonedItem) == GeneralComponentType.device)
|
if (NB.GetComponentType(ClonedItem) == GeneralComponentType.device)
|
||||||
{
|
{
|
||||||
NetworkDevice nd = (NetworkDevice)ClonedItem;
|
NetworkDevice nd = (NetworkDevice)ClonedItem;
|
||||||
nd.EditGateway(this);
|
if (nd.HasDHCPNic())
|
||||||
UpdateForm();
|
{
|
||||||
|
MessageBox.Show(NB.Translate("DC_CannotEditGateway_DHCP"));
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
nd.EditGateway(this);
|
||||||
|
UpdateForm();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1965,4 +1965,8 @@
|
|||||||
<value>Translate</value>
|
<value>Translate</value>
|
||||||
<comment>TW_Translate = Translate</comment>
|
<comment>TW_Translate = Translate</comment>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="DC_CannotEditGateway_DHCP" xml:space="preserve">
|
||||||
|
<value>This device uses DHCP to configure its network settings. The gateway is set through the DHCP server, and will be updated when this device requests DHCP. If the gateway is wrong, make sure the gateway on the server is properly set.</value>
|
||||||
|
<comment>This device uses DHCP to configure its network settings. The gateway is set through the DHCP server, and will be updated when this device requests DHCP. If the gateway is wrong, make sure the gateway on the server is properly set.</comment>
|
||||||
|
</data>
|
||||||
</root>
|
</root>
|
Loading…
Reference in New Issue
Block a user