diff --git a/krl/io.picolabs.plan.wovyn-sensors.krl b/krl/io.picolabs.plan.wovyn-sensors.krl index 022bb0b..13ff2e0 100644 --- a/krl/io.picolabs.plan.wovyn-sensors.krl +++ b/krl/io.picolabs.plan.wovyn-sensors.krl @@ -34,7 +34,7 @@ ruleset io.picolabs.plan.wovyn-sensors { - + #{ ent:mapping @@ -259,6 +259,16 @@ daysInRecord() name re#(Wovyn_[A-F0-9]{6})# location re#(.+)# setting(name,location) + pre { + new_location = {}.put(name,location) +.klog("new_location") + new_mapping = ent:mapping + .keys() + .reduce(function(a,k){ + a.put(k,ent:mapping.get(k)) + },new_location) +.klog("new_mapping") + } send_directive("_redirect",{"url":settings_link()}) fired { ent:mapping{name} := location