Skip to content

mister-vio/sample

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Fork this project and send us a pull request

Write a simple python webservice that returns the objects & manipuates the data found here http://www.unisport.dk/api/sample/.

/products/

should return the first 10 objects ordered with the cheapest first.

/products/kids/

should return the products where kids=1 ordered with the cheapest first

/products/?page=2

The products should be paginated where page in the url above should return the next 10 objects

/products/id/

should return the individual product.

Remember to test
Remember to document (why, not how)

####Bonus: extend the service so the products can also be created, edited and deleted in a backend of choice.

You are welcome to use any thirdparty python web framework or library that you are familiar with.

####Requirements:

  • Django=1.8.5

####Explanations: Data store in sqlite db. You can create new products or edit\delete existing using admin panel /admin/ There wasn't any kids='1' objects in default data at this link:

Also You can clean the table and "reload" all default data using Product.reload_data() class method provided in products.models

####default SuperUser:

  • login: root
  • password: qwerty

About

Fork this and send back a pull request

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%