Skip to content

Instantly share code, notes, and snippets.

View prodeveloper's full-sized avatar

Jacob Chencha prodeveloper

View GitHub Profile
@prodeveloper
prodeveloper / managing_your_projects.md
Last active September 19, 2017 04:36
An introduction to managing your projects using Trello

Today, we are going to start thinking about how we will manage our projects using a tool called Trello.

Trello helps us manage our projects in the way that makes the most sense to us.

In this class we shall be setting up a new kanban type board.

This board will help us manage a simple software project, say the assignment to manage our family members.

Step 1

@prodeveloper
prodeveloper / introduction_django_rest_framework.md
Last active September 13, 2017 09:31
An introduction to Django Rest Framework

Introduction

In our class today, we shall be exploring a new and very powerful library called Django rest framework

The library allows you to get a working API of your models with very little coding.

This API will be essential for your frontend and mobile classes once you start building full scale applications.

Let’s see how we can incorporate it into our model

@prodeveloper
prodeveloper / sem2_closing.md
Last active July 16, 2017 09:28
Semester review and closing

In our class, it has been a success for most of us. It has helped us abstract out the details of how to setup a development environment.

For day to day development, you may wish to consider using another platform such as Vagrant. This tools will be a bit harder to grok than c9. But at least then you will not face the dual problem of understanding both the platform and the language.

Why Django

When we started this semester, it may have not been clear why we chose the framework.

By now, it should be a bit more clear just how easy Django is to use. In addition to general ease of use. Django provides a whole lot of functionality out of the box. The tradeoff is you need to think in a certain way.

@prodeveloper
prodeveloper / introduction_to_git.md
Created July 10, 2017 09:52
Introduction to Git

Introduction

When the course commenced, we looked a bit into Git. In this class, we will be looking at how to implement Git and Github into our C9 workflow.

Git is a version control system (VCS). What that means is it keeps a track of all the changes you make in your code.

It can manage any text based file very well. Our primary use for it will be to ensure we always have a copy of all our code and be able to share it with the world.

Step 1

@prodeveloper
prodeveloper / loops_in_templates.md
Created July 5, 2017 15:45
Working with loops in the template

So far, we have been able to successfully retreive and display a single entry from the database.

In today’s lesson, we will be looking at how we can show multiple records. In this case, all the students that we have listed.

##Step 1

We start by retrieving the list of all students from the database and putting the data in the context.

@prodeveloper
prodeveloper / passing_data_template.md
Last active July 11, 2017 05:35
Passing data to the template

##Displaying data in the template

Today, we will be looking at how to display model data on your template. While previously we could show only Student Object in this lesson we will unpack that.

Step 1

Let us start by creating the template that will show the data. We can call it listing_data.html

@prodeveloper
prodeveloper / basic_queries.md
Last active June 25, 2017 12:20
Introduction to queries with Django models

Now that we have a solid understanding of what it takes to work with templates, lets dive back to our models and tie them to our views.

Step 1

Ensure that you have imported the Student model into your view file.

Let us now start by querying all students. Type the following command into your view file

@prodeveloper
prodeveloper / challenge_django_templates.md
Created June 7, 2017 13:59
Challenge: Working with Django templates

In this challenge, you will be expected to roll up an entirely new workspace, install django and render a friendly welcome page.

Your homepage should render exactly like the getting started template provided by bootstrap.

http://getbootstrap.com/examples/starter-template/#

In addition your new application must have an active super user and at least one normal user.

@prodeveloper
prodeveloper / showing_html.md
Created June 7, 2017 13:41
Rendering basic html using Django

In the last class, we were able to successfully show some text on the homepage.

This was just a simple text “Welcome to Akirachix”

In this class, we will look at how to show not just a simple text but a html page. By the end of the class, you should be able to integrate elements from your frontend class directly into django.

Django refers to your html files as templates.

##Step 1

@prodeveloper
prodeveloper / django_urls.md
Created June 7, 2017 12:27
Introduction to URL Patterns in Django

##Introduction to URL patterns

Django has 6 major pieces

Url patterns are the first point of contact when a request comes in. The module evaluates the request and determines the appropriate view to handle it.

The view is in charge of handling the request and giving an output. For now our view is empty since we are not showing anything yet.