primeng icon indicating copy to clipboard operation
primeng copied to clipboard

Dropdown onChange fires on re-selection of same item

Open smitpsanghavi opened this issue 9 years ago • 8 comments

I'm submitting a ... (check one with "x")

[x] bug report => Search github for a similar issue or PR before submitting
[ ] feature request => Please check if request is not on the roadmap already https://github.com/primefaces/primeng/wiki/Roadmap
[ ] support request => Please do not submit support request here, instead see http://forum.primefaces.org/viewforum.php?f=35

Current behavior On re-selection of the same dropdown item, onChange event is fired

Expected behavior onChange should be fired only when the selection changes. Re-selection of the same item is technically not a change.

Minimal reproduction of the problem with instructions This is not needed I guess as the implementation is fairly straightforward.

Please tell us about your environment: Windows 10, VS 2017, NPM v3.10.9

  • Angular version: 4.1.1

  • PrimeNG version: 4.0.0

  • Browser: [all]

  • Language: [TypeScript 2.3.2]

  • Node (for AoT issues): node --version = 7.2.0

smitpsanghavi avatar May 12 '17 10:05 smitpsanghavi

I can replicate the issue.The onchange event is emitted on click of list, thats why the same item selection also causes the change event.

sudheerj avatar May 12 '17 15:05 sudheerj

So is this accepted as a bug?

smitpsanghavi avatar May 13 '17 04:05 smitpsanghavi

@sudheerj Is this going to be fixed in the next release?

smitpsanghavi avatar May 25 '17 04:05 smitpsanghavi

#2353 (the same Problem)

cyberrranger avatar May 29 '17 07:05 cyberrranger

Bump!

smitpsanghavi avatar Jun 02 '17 10:06 smitpsanghavi

Set to 4.1.0.

cagataycivici avatar Jun 23 '17 08:06 cagataycivici

https://github.com/primefaces/primeng/issues/3392

diegohoyos avatar Jul 17 '17 18:07 diegohoyos

Hi,

I have still this problem while selecting same item.

Is this issue fixed, or not?

How could i realize selecting same item?

Thanks

cagriman avatar Dec 02 '22 14:12 cagriman