Skip to main content

A django app for store places

Project description

django-places
=============================

A Django app for store places with autocomplete function and a related map to the selected place.

Badges
---------

[![PyPI](https://badge.fury.io/py/dj-places.png)](https://badge.fury.io/py/dj-places)
[![Travis-ci](https://travis-ci.org/oscarmcm/django-places.png?branch=master)](https://travis-ci.org/oscarmcm/django-places)
[![Codacy Badge](https://api.codacy.com/project/badge/Grade/d6433fc7fc384f63b9f41fc251ee70b1)](https://www.codacy.com/app/om-cortez-2010/django-places?utm_source=github.com&utm_medium=referral&utm_content=oscarmcm/django-places&utm_campaign=Badge_Grade)

Quickstart
----------

Install dj-places and add it to your installed apps:

$ pip install dj-places

INSTALLED_APPS = (
...
'djplaces',
...
)

Add in your project settings the following values:

JQUERY_URL = '//ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js'
GEOCOMPLETE_URL = '//cdnjs.cloudflare.com/ajax/libs/geocomplete/1.7.0/jquery.geocomplete.min.js'
GOOGLE_PLACES_URL = '//maps.googleapis.com/maps/api/js?libraries=places'


Then use it in a project:

from djplaces.fields import LocationField
place = models.CharField(max_length=250)
location = LocationField(base_field='place')

TODO-LIST
--------

* [ ] Write some test ASAP!
* [ ] Support Inline Admin
* [ ] Use Django Admin Jquery
* [ ] Set custom zoom map value
* [ ] Custom property for lat and lng values

Running Tests
--------------

Does the code actually work?

source <YOURVIRTUALENV>/bin/activate
(myenv) $ pip install -r requirements-test.txt
(myenv) $ python runtests.py

Credits
---------

Special thanks to [Helmy Giacoman](https://github.com/eos87) for motivating me to make this package.

Tools used in rendering this package:

* [Cookiecutter](https://github.com/audreyr/cookiecutter)
* [cookiecutter-djangopackage](https://github.com/pydanny/cookiecutter-djangopackage)
* [jquery-geocomplete](https://github.com/ubilabs/geocomplete)

Similar Projects
------------

* [Django Location Field](https://github.com/caioariede/django-location-field)
* [Django Geoposition](https://github.com/philippbosch/django-geoposition)




History
-------

1.0.0 (2016-04-28)
++++++++++++++++++

* First release on PyPI.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

dj-places-1.0.1.tar.gz (5.0 kB view details)

Uploaded Source

File details

Details for the file dj-places-1.0.1.tar.gz.

File metadata

  • Download URL: dj-places-1.0.1.tar.gz
  • Upload date:
  • Size: 5.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for dj-places-1.0.1.tar.gz
Algorithm Hash digest
SHA256 2f55c1ee620c6066dd0dae8629948afce20cd1a3effa04c97488cfef2f81dcf0
MD5 fb43d1fee9a05664be645e90991c1d3e
BLAKE2b-256 548af68bebe7ee88531a65d680214a3b0def8df8d17d51949a0ca344b79a20ec

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page