# DB2 Dropdown reset

**URL:** <https://discourse.nodered.org/t/db2-dropdown-reset/87258>\
**Category:** Dashboard\
**Tags:** dashboard-2\
**Created:** [15 April 2024 21:18 UTC](https://discourse.nodered.org/t/db2-dropdown-reset/87258 "2024-04-15T21:18:52Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![JeromeVISUALS](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/jeromevisuals/32/40103_2.png) [@JeromeVISUALS](https://discourse.nodered.org/u/JeromeVISUALS)\
**Post date:** [15 April 2024 21:18 UTC](https://discourse.nodered.org/t/db2-dropdown-reset/87258/1 "2024-04-15T21:18:52Z")

</div>

Hi there,

I start to move some of my flows to DB2 , to see how it works and if I can deal with some of the missing features compared to DB1 .

I have a question concerning dropdown, is there any way to reset the Dropdown display once a selection has been done ?  
From the documentation I expected a empty array as msg.payload to reset the dropdown , but it does not work.... even when a new msg.options is being sent to the dropdown , the previous item is still being displayed, even if not available in the new options list anymore.....

Thanks,

Jerome

---

<div class="post-metadata">

**Author:** ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)\
**Post date:** [16 April 2024 12:21 UTC](https://discourse.nodered.org/t/db2-dropdown-reset/87258/2 "2024-04-16T12:21:48Z")

</div>

This is an already reported issue: [ui-dropdown doesn't clear selection with msg.payload = [] · Issue #756 · FlowFuse/node-red-dashboard · GitHub](https://github.com/FlowFuse/node-red-dashboard/issues/756)

---

<div class="post-metadata">

**Author:** ![JeromeVISUALS](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/jeromevisuals/32/40103_2.png) [@JeromeVISUALS](https://discourse.nodered.org/u/JeromeVISUALS)\
**Post date:** [16 April 2024 14:00 UTC](https://discourse.nodered.org/t/db2-dropdown-reset/87258/3 "2024-04-16T14:00:51Z")

</div>

Ha ok , thank you. will wait.

It seems also the red warning initally displayed when no content is provided, remains visible even after an array has been pushed to the node...  
Is it supposed to be part of the same "bug", or should I maybe open a new issue ?

---

<div class="post-metadata">

**Author:** ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)\
**Post date:** [16 April 2024 19:17 UTC](https://discourse.nodered.org/t/db2-dropdown-reset/87258/4 "2024-04-16T19:17:54Z")

</div>

For me the triangle disappears as soon as I configure the Group. Can you describe exactly what you are doing to get it to not disappear? Are you using the latest version (1.7.1)

---

<div class="post-metadata">

**Author:** ![JeromeVISUALS](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/jeromevisuals/32/40103_2.png) [@JeromeVISUALS](https://discourse.nodered.org/u/JeromeVISUALS)\
**Post date:** [17 April 2024 11:42 UTC](https://discourse.nodered.org/t/db2-dropdown-reset/87258/5 "2024-04-17T11:42:16Z")

</div>

Actually I was speaking about a red display in the dashboard page itself, telling there is no useful data in the dropdown list, while actually there was...

But I'm not able to get that warning again, so let's forget it for now, I'll come back if that appears again.

Thanks !

---

<div class="post-metadata">

**Author:** ![JeromeVISUALS](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/jeromevisuals/32/40103_2.png) [@JeromeVISUALS](https://discourse.nodered.org/u/JeromeVISUALS)\
**Post date:** [17 April 2024 18:54 UTC](https://discourse.nodered.org/t/db2-dropdown-reset/87258/6 "2024-04-17T18:54:01Z")

</div>

Ok, I have it :

 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/8/f/8f60876a8f92f3c6c69d70bd9b40b81d7797015c.png)

But when I click in a dropdown which I expect to have values :

 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/d/e/deec6b049320bb527467146427cc6f01669779a9.png)

---

<div class="post-metadata">

**Author:** ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)\
**Post date:** [17 April 2024 20:09 UTC](https://discourse.nodered.org/t/db2-dropdown-reset/87258/7 "2024-04-17T20:09:25Z")

</div>

Can you post an example flow and describe how to see the problem?

---

<div class="post-metadata">

**Author:** ![joepavitt](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/joepavitt/32/59722_2.png) [@joepavitt](https://discourse.nodered.org/u/joepavitt)\
**Post date:** [18 April 2024 13:55 UTC](https://discourse.nodered.org/t/db2-dropdown-reset/87258/8 "2024-04-18T13:55:52Z")

</div>

> <https://github.com/FlowFuse/node-red-dashboard/pull/775>
>
> \## Description
> 
> According to the documentation, the current selection in ui-dr…opdown should be cleared when msg.payload = \[\].
> However when \*"Allow Multiple"\* is deselected in the node's config screen, then the selection is \*\*\*not\*\*\* cleared.
> 
> This PR fixes that:
> 
> !\[clear\_dropdown\](https://github.com/FlowFuse/node-red-dashboard/assets/14224149/c321f35a-4a63-4b62-a6d2-8121688bacd6)
> 
> \`\`\`
> \[{"id":"79e59c62a86947fc","type":"ui-dropdown","z":"f624e6564f974a57","group":"65805ec358e05ea4","name":"Single select option","label":"Select Option:","tooltip":"","order":0,"width":0,"height":0,"passthru":false,"multiple":false,"options":\[{"label":"Option A","value":"A","type":"str"},{"label":"Option B","value":"B","type":"str"},{"label":"Option C","value":"C","type":"str"}\],"payload":"","topic":"topic","topicType":"msg","className":"","x":810,"y":340,"wires":\[\[\]\]},{"id":"adad1a977d52d7ee","type":"inject","z":"f624e6564f974a57","name":"Select B","props":\[{"p":"payload"}\],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"\[\\"B\\"\]","payloadType":"json","x":600,"y":340,"wires":\[\["79e59c62a86947fc"\]\]},{"id":"90f3b037c32b470f","type":"inject","z":"f624e6564f974a57","name":"Clear","props":\[{"p":"payload"}\],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"\[\]","payloadType":"json","x":610,"y":380,"wires":\[\["79e59c62a86947fc"\]\]},{"id":"184aa25927b97082","type":"ui-dropdown","z":"f624e6564f974a57","group":"65805ec358e05ea4","name":"Multi select option","label":"Select Option:","tooltip":"","order":0,"width":0,"height":0,"passthru":false,"multiple":true,"options":\[{"label":"Option A","value":"A","type":"str"},{"label":"Option B","value":"B","type":"str"},{"label":"Option C","value":"C","type":"str"}\],"payload":"","topic":"topic","topicType":"msg","className":"","x":810,"y":460,"wires":\[\[\]\]},{"id":"d5b1176aa3646600","type":"inject","z":"f624e6564f974a57","name":"Select B","props":\[{"p":"payload"}\],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"\[\\"B\\"\]","payloadType":"json","x":600,"y":460,"wires":\[\["184aa25927b97082"\]\]},{"id":"c8b98416094457e6","type":"inject","z":"f624e6564f974a57","name":"Clear","props":\[{"p":"payload"}\],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"\[\]","payloadType":"json","x":610,"y":500,"wires":\[\["184aa25927b97082"\]\]},{"id":"65805ec358e05ea4","type":"ui-group","name":"Heatmap demo","page":"0a90f52e8742b298","width":"10","height":"10","order":-1,"showTitle":true,"className":"","visible":"true","disabled":"false"},{"id":"0a90f52e8742b298","type":"ui-page","name":"Heatmap","ui":"be29745a6e568f30","path":"/page2","icon":"home","layout":"grid","theme":"092547d34959327c","order":-1,"className":"","visible":"true","disabled":"false"},{"id":"be29745a6e568f30","type":"ui-base","name":"UI Name","path":"/dashboard","includeClientData":true,"acceptsClientConfig":\["ui-notification","ui-control"\],"showPathInSidebar":false},{"id":"092547d34959327c","type":"ui-theme","name":"Theme Name","colors":{"surface":"#ffffff","primary":"#0094ce","bgPage":"#eeeeee","groupBg":"#ffffff","groupOutline":"#cccccc"}}\]
> \`\`\`
> 
> \## Related Issue(s)
> 
> \[Issue 756\](https://github.com/FlowFuse/node-red-dashboard/issues/756)
> 
> \## Checklist
> 
> 
> 
> - \[\] I have read the \[contribution guidelines\](https://github.com/FlowFuse/flowfuse/blob/main/CONTRIBUTING.md)
> - \[\] Suitable unit/system level tests have been added and they pass 
> - \[\] Documentation has been updated
> - \[\] Upgrade instructions
> - \[\] Configuration details
> - \[\] Concepts
> - \[\] Changes \`flowforge.yml\`?
> - \[\] Issue/PR raised on \`FlowFuse/helm\` to update ConfigMap Template
> - \[\] Issue/PR raised on \`FlowFuse/CloudProject\` to update values for Staging/Production
> 
> \## Labels
> 
> - \[\] Backport needed? -\> add the \`backport\` label
> - \[\] Includes a DB migration? -\> add the \`area:migration\` label

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)\
**Post date:** [18 May 2024 13:55 UTC](https://discourse.nodered.org/t/db2-dropdown-reset/87258/9 "2024-05-18T13:55:57Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
