Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: add location field #64

Open
emibcn opened this issue Mar 9, 2019 · 0 comments
Open

Feature request: add location field #64

emibcn opened this issue Mar 9, 2019 · 0 comments

Comments

@emibcn
Copy link

emibcn commented Mar 9, 2019

Hello,
I use this module in some projects and, in one of them, I need to collect user's location. I use (django-map-widgets)[https://github.com/erdem/django-map-widgets] and would like to use it here, but looks a little difficukt to add plugins/widgets to cmsplugin-contact-plus. Being able to use extra Django fields would be very nice.

A possible solution would be to add it to settings.py something like:

def getFormMap(extraField):
   return gismodels.PointField(
      label=extraField.label,
      initial=extraField.initial,
      help_text=extraField.placeholder,
      required=extraField.required)

CMS_PLUGIN_CONTACT_PLUS_WIDGETS = [
   {
      'fieldType': 'LocationMapField',
      'getter': getFormMap
   }
]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant