Giter Site home page Giter Site logo

building-api-django's Introduction

Agiliq

This is all the code which powers agiliq.com.

A number of our apps are available at the agiliq.com site, and here via the requirements.txt

Some of our important apps we use are:

  1. Blogango at http://agiliq.com/blog/
  2. Merchant at http://agiliq.com/blog/
  3. Dinette at http://agiliq.com/demo/dinette/
  4. Graphos at http://agiliq.com/demo/graphos/

Patches are welcome and gratefully accepted, for this site and everything else on our Github.

How to use this

  1. Clone this repo.
  2. mkdir logs
  3. cp localsettings.example.py localsettings.py, add correct settings etc.
  4. pip install -r requirements.txt (You use virtualenv, right?)

Deployment

source deploy.sh

deploy.sh deploys the app to heroku and clears the cache.

This uses a custom multi buildpack. Heroku recommends using dj_static to serve static files, which we didn't like, so this is being served on gunicorn behind nginx. (Which is itself behind the heroku router, of course.)

building-api-django's People

Contributors

aaqibb13 avatar akshar-raaj avatar amcorreia avatar annshress avatar christos-p avatar dependabot[bot] avatar dhruvildave22 avatar fankeke007 avatar finnimcfinger avatar krvc avatar lobothijau avatar mfrasca avatar mohaiminulhasan avatar mohi7solanki avatar molcay avatar mozillazg avatar oussama-he avatar parbhat avatar s1m0n38 avatar sakisbl avatar samibh avatar shabda avatar shashikant231 avatar sourcepirate avatar sreejeet avatar yashrastogi16 avatar yvsssantosh avatar zachvalenta avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

building-api-django's Issues

Deprecated base_name

In "Introducing Viewsets and Routers" topic in "More views and viewsets" chapter, has used the deprecated "base_name" argumente in:
router.register('polls', PollViewSet, basename='polls')

Am having an issue with following your tutorial , on this part below

Am a beginner in Django and I would like to know where exactly do I run this below -

Using the PollSerializer
Let’s use the serializer to create a Poll object.

In [1]: from polls.serializers import PollSerializer

In [2]: from polls.models import Poll

In [3]: poll_serializer = PollSerializer(data={"question": "Mojito or Caipirinha?", "created_by": 1})

In [4]: poll_serializer.is_valid()
Out[4]: True

In [5]: poll = poll_serializer.save()

In [6]: poll.pk
Out[6]: 5

The poll.pk line tells us that the object has been commited to the DB. You can also use the serializer to update a Poll object.


In [9]: poll_serializer = PollSerializer(instance=poll, data={"question": "Mojito, Caipirinha or margarita?", "created_by": 1})

In [10]: poll_serializer.is_valid()
Out[10]: True

In [11]: poll_serializer.save()
Out[11]: <Poll: Mojito, Caipirinha or margarita?>

In [12]: Poll.objects.get(pk=5).question
Out[12]: 'Mojito, Caipirinha or margarita?'

Do we run it in the terminal? or we create a file and we run it inside there. I will be very happy for your help, and I really thank you for the tutorial, it's really nice.

Spanish translation

Hi there, I'm a django developer for 3+ years and love to share resources with the spanish community, I was wondering if you're open to translations

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.