sentier-dev / dds_registration

Django app for event registration and billing
MIT License
0 stars 1 forks source link

113 inline payment method radio group #148

Closed lilliputten closed 6 months ago

lilliputten commented 6 months ago

Show a payment_method radio-group options inline (by option node id, will be work for all payment_method radio groups).

2024-04-08-19-56-56

Explanation for the used solution:

It's impossible to stylize it using class attribute in dds_registration/forms.py.

This code:

RadioSelect(attrs={"class": "XXX"})

will produce class attribute for the hidden inner input, not to the wrapper, like that:

<input class="XXX" ... type="radio" value="INVOICE">

So, in this solution, we work only from the css side.

TODO: Didn't we want to use icons here? (I'm not sure, but probably it'll be a bit tricky here.)

Added another changes from the frozen PR #143,