Re: I want to fetch the value of radio field for updation but it only doesn't fetch even i use condition and value does comes but doesn't checked

2022-08-31 Thread Godswill King Trace
I have this problem too On Wed, Aug 24, 2022, 5:06 PM Mihir Patel wrote: > i dont have much idea but try to do with True Or False value bcz maybe it > returns boolean value. > > On Mon, Aug 22, 2022 at 12:27 PM Abhinandan K > wrote: > >> Email >> >> {% with val_gen=datas.gender%} >>

Re: I want to fetch the value of radio field for updation but it only doesn't fetch even i use condition and value does comes but doesn't checked

2022-08-24 Thread Mihir Patel
i dont have much idea but try to do with True Or False value bcz maybe it returns boolean value. On Mon, Aug 22, 2022 at 12:27 PM Abhinandan K wrote: > Email > > {% with val_gen=datas.gender%} > {{val_gen}} > gender: > > checked{% endif %} >Male > checked{% endif %}>Female > > {% endwith %}

Re: I want to fetch the value of radio field for updation but it only doesn't fetch even i use condition and value does comes but doesn't checked

2022-08-23 Thread Ammar Mohammed
Email {% with val_gen=datas.gender%} {{val_gen}} gender: Male Female {% endwith %} On 22 Aug 2022 08:57, "Abhinandan K" wrote: > Email > > {% with val_gen=datas.gender%} > {{val_gen}} > gender: > > checked{% endif %} >Male > checked{% endif %}>Female > > {% endwith %}

Re: I want to fetch the value of radio field for updation but it only doesn't fetch even i use condition and value does comes but doesn't checked

2022-08-23 Thread Ryan Nowakowski
On Mon, Aug 22, 2022 at 12:26:40PM +0530, Abhinandan K wrote: > checked{% endif %} >Male > checked{% endif %}>Female > Do you need quotes around Male/Female like this? {% if val_gen == 'Male' %} -- You received this message because you are subscribed to the Google Groups "Django users"

Re: I want to fetch the value of radio field for updation but it only doesn't fetch even i use condition and value does comes but doesn't checked

2022-08-22 Thread Abdul Qoyyuum
You'll need to use a RadioSelect widget. See example in the link as follows: https://docs.djangoproject.com/en/4.0/ref/forms/widgets/#django.forms.RadioSelect On Mon, Aug 22, 2022 at 2:57 PM Abhinandan K wrote: > Email > > {% with val_gen=datas.gender%} > {{val_gen}} > gender: > > checked{%