Tabulator with formatter lookup

Hi everyone

I have included in a tabulator object this field

{
"title":"Avis",
"field": "avis",
"formatter":"lookup",
"width": "8%",
"hozAlign": "left",
"editable":true,
"formatterParams": {
"F":"Favorable",
"S":"Suspendu",
"VAO":"Visa avec observations",
"D":"Défavorable"
}
}

But it does not work : the list is not displayed

Any idea ?

Thanks

In which node type are you instantiating the tabulator object: in a template node or in @omrid01/node-red-dashboard-2-table-tabulator ?

@omrid01/node-red-dashboard-2-table-tabulator

The lookup formatter shows OK


So I guess you are looking for a drop-down menu?
You need to look into the Tabulator documentation, as there are some dependencies between the field lookup formatter, editor and filter.
Check the example flow which I provided with the node, it sets a lookup with a drop-down editor & filter:

	{
		"title": "Gender",
		"field": "gender",
		"width": 100,
		"headerSortTristate":true,
		"hozAlign": "center",
		"formatter": "lookup",
        "formatterParams": {
                "M": "Male ",
                "F": "Female",
                "U": "Unknown"
        },
		"editable": true,
		"editor": "list",
		"editorParams": {
			"values": {
				"M": "Male ",
				"F": "Female",
				"U": "Unknown"
			}
		},
		"headerFilter": true,
		"headerFilterPlaceholder": "Select...",
		"headerFilterParams": {
			"values": {
				"M": "Male ",
				"F": "Female",
				"U": "Unknown",
				"": ""
			}
		}
	},

Thanks a lot !
It is working great as I expected !
Nice job !

Go up and see my previous reply, I edited the column definition, to include all 3:

  • lookup (e.g. "F"->"Favorable")
  • drop-list
  • filter