Author Topic: pqSelect with deselect  (Read 5016 times)

jcc

  • Newbie
  • *
  • Posts: 5
    • View Profile
pqSelect with deselect
« on: December 29, 2015, 08:14:15 pm »
I use pqSelect with singlePlaceHolder and radio buttons and set the deselect option to true.
When created, the singlePlaceHolder show my title text and, when an option is selected, the option text takes the place of the title
That's fine.
But, when the deselect button is clicked, the radio button turn unchecked, and the signlePlaceHolder shows the first entry of the list (even this radio button is not checked)

Is there something I do wrong ?
« Last Edit: December 29, 2015, 08:17:14 pm by jcc »

paramvir

  • Administrator
  • Hero Member
  • *****
  • Posts: 6310
    • View Profile
Re: pqSelect with deselect
« Reply #1 on: December 29, 2015, 08:26:18 pm »
The first option in select list should be empty.

jcc

  • Newbie
  • *
  • Posts: 5
    • View Profile
Re: pqSelect with deselect
« Reply #2 on: December 29, 2015, 08:40:20 pm »
Yes, but not pretty and, anyway, the deselect button still show in the singlePlaceHolder (to deselect what ???)
Is'nt a way to set the original text in the singlePlaceHolder when no otpion is selected ?
Thks for your help

paramvir

  • Administrator
  • Hero Member
  • *****
  • Posts: 6310
    • View Profile
Re: pqSelect with deselect
« Reply #3 on: December 30, 2015, 09:40:21 am »
Please check the demos: http://paramquery.com/select, original placeholder is shown when a selected option is deselected.

There might be something wrong with your implementation, please share a jsfiddle if you want me to look into it.
« Last Edit: December 30, 2015, 11:11:29 am by paramquery »

jcc

  • Newbie
  • *
  • Posts: 5
    • View Profile
Re: pqSelect with deselect
« Reply #4 on: December 30, 2015, 02:20:49 pm »
OK, got it!!! I've made a mistake
In HTML, the first empty option was <option value='0'> </option>
I delete the blank car and it works fine

pqSelect is a great job.
Think i'll try soon the pqGrid