luci-mod-network: migrate macaddr during bridge migration
authorRafał Miłecki <rafal@milecki.pl>
Mon, 31 May 2021 06:35:09 +0000 (08:35 +0200)
committerRafał Miłecki <rafal@milecki.pl>
Mon, 31 May 2021 19:52:13 +0000 (21:52 +0200)
Link: https://forum.openwrt.org/t/network-migration-21-02-0-rc2/97934
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
(cherry picked from commit 49be69316bfea092e90c2f5a821ded961069f518)

modules/luci-mod-network/htdocs/luci-static/resources/view/network/interfaces.js

index 5626a2b82378c4d548fb1a6a572d661e517e8102..64aa96090ce643a17b73a2e0e75c8c275ae68951 100644 (file)
@@ -326,12 +326,14 @@ return view.extend({
                        tasks.push(uci.callAdd('network', 'device', null, {
                                'name': device_name,
                                'type': 'bridge',
-                               'ports': L.toArray(ns.ifname)
+                               'ports': L.toArray(ns.ifname),
+                               'macaddr': ns.macaddr
                        }));
 
                        tasks.push(uci.callSet('network', ns['.name'], {
                                'type': '',
                                'ifname': '',
+                               'macaddr': '',
                                'device': device_name
                        }));
                });