I have been using a flow to get the day and time on the main screen, and to use it with a "buzzer alarm" function. So far it has worked perfectly, but yesterday I realized that the "month" field appears as "undefined".
I have checked the translation of the variables and they are correct, but I don't know what is the reason that it appears in the month field "undefined".
Any ideas?
I attach the Flow so you can see it.
[{"id":"a9b22498.87eb98","type":"tab","label":"Flow 1","disabled":false,"info":""},{"id":"8402276a.e0a6b8","type":"simpletime","z":"a9b22498.87eb98","name":"Tijd","x":390,"y":320,"wires":[["2d8392ad.99ffbe"]]},{"id":"ffe249a4.a4d708","type":"inject","z":"a9b22498.87eb98","name":"","topic":"","payload":"","payloadType":"date","repeat":"1","crontab":"","once":false,"onceDelay":0.1,"x":210,"y":320,"wires":[["8402276a.e0a6b8"]]},{"id":"2d8392ad.99ffbe","type":"moment","z":"a9b22498.87eb98","name":"","topic":"","input":"payload","inputType":"msg","inTz":"Europe/London","adjAmount":"2","adjType":"hours","adjDir":"add","format":"HH:mm:ss","locale":"es_ES","output":"","outputType":"msg","outTz":"Etc/UTC","x":600,"y":320,"wires":[["1b0ed193.c3b86e","a5a5decd.5a7c6"]]},{"id":"1b0ed193.c3b86e","type":"function","z":"a9b22498.87eb98","name":"Store Time in global variable","func":"var Time=global.get(\"GlobalTime\") || '';\nglobal.set(\"GlobalTime\",msg.payload);\n\nreturn msg;","outputs":1,"noerr":0,"x":900,"y":340,"wires":[[]]},{"id":"d82b7fdd.7423c","type":"ui_template","z":"a9b22498.87eb98","group":"9e908f06.94c48","name":"Tijd / Datum","order":1,"width":10,"height":3,"format":"<p style=\"font-size:45px; text-align: center; font-weight: bold;\">{{msg.time}}</p> \n<p style=\"font-size:15px; text-align: center; font-weight: bold;\"><i style=\"color:#0094CE!important;\" class=\"fa fa-calendar\" aria-hidden=\"true\"></i> {{msg.date}}</p>\n","storeOutMessages":true,"fwdInMessages":true,"resendOnRefresh":false,"templateScope":"local","x":1230,"y":300,"wires":[[]]},{"id":"a5a5decd.5a7c6","type":"function","z":"a9b22498.87eb98","name":"Set icon color and temperature","func":"var Datevar=global.get(\"GlobalDate\") || '';\nmsg = {time:msg.payload, date:Datevar};\nreturn msg;","outputs":1,"noerr":0,"x":910,"y":300,"wires":[["d82b7fdd.7423c"]]},{"id":"e195ed38.554f9","type":"comment","z":"a9b22498.87eb98","name":"Obtenemos el DĂa y la Hora","info":"","x":640,"y":200,"wires":[]},{"id":"2665fac5.857026","type":"moment","z":"a9b22498.87eb98","name":"","topic":"","input":"payload","inputType":"msg","inTz":"Europe/Berlin","adjAmount":"2","adjType":"hours","adjDir":"add","format":"dddd DD MMMM YYYY","locale":"es_ES","output":"","outputType":"msg","outTz":"Etc/UTC","x":600,"y":420,"wires":[["f8d657ff.1a2848"]]},{"id":"213ad1ce.7410ae","type":"function","z":"a9b22498.87eb98","name":"Store date in global variable","func":"var Datevar=global.get(\"GlobalDate\") || '';\nglobal.set(\"GlobalDate\",msg.payload);\n\nreturn msg;","outputs":1,"noerr":0,"x":1020,"y":420,"wires":[[]]},{"id":"f8d657ff.1a2848","type":"function","z":"a9b22498.87eb98","name":"Translate","func":"var mapObj = {\n Monday:\"Lunes\",\n Tuesday:\"Martes\",\n Wednesday:\"Miercoles\",\n Thursday:\"Jueves\",\n Friday:\"Viernes\",\n Saturday:\"Sabado\",\n Sunday:\"Domingo\",\n January:\"Enero\",\n February:\"Febrero\",\n March:\"Marzo\",\n April:\"Abril\",\n May:\"Mayo\",\n June:\"Junio\",\n July:\"Julio\",\n August:\"Agosto\",\n September:\"Septiembre\",\n October:\"Octubre\",\n November:\"Noviembre\",\n December:\"Diciembre\"\n};\nmsg.payload = msg.payload.replace(/Monday|Tuesday|Wednesday|Thursday|Friday|Saturday|Sunday|January|February|March|April|May|June|July|August|September|October|November|December/gi, function(matched){\n return mapObj[matched];\n});\n\n\nreturn msg;","outputs":1,"noerr":0,"x":800,"y":420,"wires":[["213ad1ce.7410ae"]]},{"id":"cb3b0425.e4a2a8","type":"simpletime","z":"a9b22498.87eb98","name":"Tijd","x":390,"y":420,"wires":[["2665fac5.857026","31ca4d0d.4fa6f2"]]},{"id":"634e7ca1.e31ef4","type":"inject","z":"a9b22498.87eb98","name":"","topic":"","payload":"","payloadType":"date","repeat":"60","crontab":"","once":false,"onceDelay":0.1,"x":210,"y":420,"wires":[["cb3b0425.e4a2a8"]]},{"id":"d4c4d2f9.8f37e","type":"function","z":"a9b22498.87eb98","name":"Store date in global variable","func":"var Datevar=global.get(\"GlobalDateShort\") || '';\nglobal.set(\"GlobalDateShort\",msg.payload);\n\nreturn msg;","outputs":1,"noerr":0,"x":1020,"y":460,"wires":[[]]},{"id":"31ca4d0d.4fa6f2","type":"moment","z":"a9b22498.87eb98","name":"","topic":"","input":"payload","inputType":"msg","inTz":"Europe/Berlin","adjAmount":"2","adjType":"hours","adjDir":"add","format":"DD-MM","locale":"es_ES","output":"","outputType":"msg","outTz":"Etc/UTC","x":600,"y":460,"wires":[["d4c4d2f9.8f37e"]]},{"id":"9e908f06.94c48","type":"ui_group","z":"","name":"Hoy","tab":"41973f9d.b568a","order":2,"disp":true,"width":"10","collapse":false},{"id":"41973f9d.b568a","type":"ui_tab","z":"","name":"Home","icon":"home","order":1}]
Thank you.
a greeting