mirror of
https://github.com/netbirdio/plugins.git
synced 2026-05-22 18:44:07 -07:00
WOL widget fix (#2291)
fix button binding after cutting scripts from widgets
This commit is contained in:
+1
-2
@@ -1,6 +1,5 @@
|
||||
PLUGIN_NAME= wol
|
||||
PLUGIN_VERSION= 2.3
|
||||
PLUGIN_REVISION= 1
|
||||
PLUGIN_VERSION= 2.4
|
||||
PLUGIN_DEPENDS= wol
|
||||
PLUGIN_COMMENT= Wake on LAN Service
|
||||
PLUGIN_MAINTAINER= franco@opnsense.org
|
||||
|
||||
@@ -75,10 +75,12 @@ $wol = new Wol();
|
||||
</tfoot>
|
||||
</table>
|
||||
<script>
|
||||
$('.wakeupbtn').click(function(event) {
|
||||
event.preventDefault();
|
||||
var data = this.dataset;
|
||||
$.post('/api/wol/wol/set', {'uuid': data['uuid']}, function(result) {
|
||||
$("#dashboard_container").on("WidgetsReady", function() {
|
||||
$('.wakeupbtn').click(function(event) {
|
||||
event.preventDefault();
|
||||
var data = this.dataset;
|
||||
$.post('/api/wol/wol/set', {'uuid': data['uuid']}, function(result) {
|
||||
});
|
||||
})
|
||||
});
|
||||
})
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user