Frappe Tutorial

In this guide, we will show you how to create an application from scratch using Frappe. Using the example of a Library Management System, we will cover:

  1. Installation
  2. Making a New App
  3. Making Models
  4. Creating Users and Records
  5. Creating Controllers
  6. Creating Web Views
  7. Setting Hooks and Tasks

Who is This For?

This guide is intended for software developers who are familiar with how the web applications are built and served. Frappe Framework is built on Python and uses MariaDB database and for creating web views, HTML/CSS/Javascript is used. So it would be great if you are familiar with all these technologies. At the minimum, if you have never used Python before, you should take a quick tutorial before using this Guide.

Frappe uses the git version control system on GitHub. It is also important that you are familiar with basic git and have an account on GitHub to manage your applications.

Example

For this guide book, we will build a simple Library Management application. In this application we will have models:

  1. Article (Book or any other item that can be loaned)
  2. Library Member
  3. Library Transaction (Issue or Return of an article)
  4. Library Membership (A period in which a member is allowed to transact)
  5. Library Management Setting (Global settings like period of loan)

The user interface (UI) for the librarian will be the Frappe Desk, a built-in browser based UI environment where forms are automatically generated from the models and roles and permissions are also applied.

We will also create web views for library where users can browse articles from a website.

  1. Before
  2. App
  3. Bench
  4. New App
  5. Setting Up The Site
  6. Start
  7. Models
  8. Roles
  9. Doctypes
  10. Naming And Linking
  11. Doctype Directory Structure
  12. Users And Records
  13. Form Client Scripting
  14. Controllers
  15. Reports
  16. Web Views
  17. Single Doctypes
  18. Task Runner
  19. Conclusion