15.11.2024, 17:18
here
I precise that after my script, if I go to modbus the write option is disabled on all element
Code:
searchKey='bus_write'
valueSearch='1'
oldValue='1'
newValue='0'
key='bus_write'
mytable='modbus_mapping'
if oldValue =='' then
querySql="UPDATE "..mytable.." SET "..key.." = "..newValue.." WHERE "..searchKey.." like '%"..valueSearch.."%'"
else
querySql="UPDATE "..mytable.." SET "..key.." = REPLACE("..key..", '"..oldValue.."', '"..newValue.."') WHERE "..searchKey.." like '%"..valueSearch.."%'"
end
db:query(querySql)
I precise that after my script, if I go to modbus the write option is disabled on all element
-----------
FRANCE SMARTHOME & SMARTBUILDING INTEGRATION
SE ECO EXPERT
FRANCE SMARTHOME & SMARTBUILDING INTEGRATION
SE ECO EXPERT