summaryrefslogtreecommitdiffhomepage
path: root/modules/luci-mod-system/htdocs/luci-static/resources/view/system
diff options
context:
space:
mode:
authorJo-Philipp Wich <jo@mein.io>2020-04-16 15:35:51 +0200
committerJo-Philipp Wich <jo@mein.io>2020-04-16 15:35:51 +0200
commit01129d5297fa83069a2b1953e19184fe152d8b90 (patch)
tree7fdd16e3d6731b60e1e60cd777ade5ba7a982779 /modules/luci-mod-system/htdocs/luci-static/resources/view/system
parent684f7dd7dc21e61a73ecf20f9e6e158af39872a6 (diff)
luci-mod-system: mounts.js: disable umount button in readonly map
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
Diffstat (limited to 'modules/luci-mod-system/htdocs/luci-static/resources/view/system')
-rw-r--r--modules/luci-mod-system/htdocs/luci-static/resources/view/system/mounts.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/modules/luci-mod-system/htdocs/luci-static/resources/view/system/mounts.js b/modules/luci-mod-system/htdocs/luci-static/resources/view/system/mounts.js
index 7ee91f5aec..e0a9226562 100644
--- a/modules/luci-mod-system/htdocs/luci-static/resources/view/system/mounts.js
+++ b/modules/luci-mod-system/htdocs/luci-static/resources/view/system/mounts.js
@@ -212,7 +212,8 @@ return view.extend({
'%.2f%% (%1024.2mB)'.format(100 / this.mounts[i].size * used, used),
umount ? E('button', {
'class': 'btn cbi-button-remove',
- 'click': ui.createHandlerFn(view, 'handleUmount', m, this.mounts[i].mount)
+ 'click': ui.createHandlerFn(view, 'handleUmount', m, this.mounts[i].mount),
+ 'disabled': this.map.readonly || null
}, [ _('Unmount') ]) : '-'
]);
}