Docs and simngle quote removal when editing device #918

This commit is contained in:
jokob-sk
2024-12-24 11:06:43 +11:00
parent 8f8264c6fa
commit 7cdcf95300
3 changed files with 18 additions and 17 deletions

View File

@@ -400,12 +400,12 @@
$.get('php/server/devices.php?action=setDeviceData&mac='+ $('#NEWDEV_devMac').val()
+ '&name=' + encodeURIComponent($('#NEWDEV_devName').val().replace(/'/g, ""))
+ '&owner=' + encodeURIComponent($('#NEWDEV_devOwner').val().replace(/'/g, ""))
+ '&type=' + $('#NEWDEV_devType').val()
+ '&type=' + $('#NEWDEV_devType').val().replace(/'/g, "")
+ '&vendor=' + encodeURIComponent($('#NEWDEV_devVendor').val().replace(/'/g, ""))
+ '&icon=' + encodeURIComponent($('#NEWDEV_devIcon').val())
+ '&favorite=' + ($('#NEWDEV_devFavorite')[0].checked * 1)
+ '&group=' + encodeURIComponent($('#NEWDEV_devGroup').val())
+ '&location=' + encodeURIComponent($('#NEWDEV_devLocation').val())
+ '&group=' + encodeURIComponent($('#NEWDEV_devGroup').val().replace(/'/g, ""))
+ '&location=' + encodeURIComponent($('#NEWDEV_devLocation').val().replace(/'/g, ""))
+ '&comments=' + encodeURIComponent(encodeSpecialChars($('#NEWDEV_devComments').val()))
+ '&networknode=' + $('#NEWDEV_devParentMAC').val()
+ '&networknodeport=' + $('#NEWDEV_devParentPort').val()