INSIGHT ON FRAPPE FRAMEWORK
Published: 2023-05-05 09:08:58

<u>What Frappe's ERPNext</u>
**Frappe** is a major open-source software company that offers a variety of tools and solutions to assist businesses in properly managing their operations. <u>ERPNext</u>, a comprehensive, cloud-based enterprise resource planning (ERP) software that helps organizations of all sizes to manage their finances, operations, and resources with ease, is one of Frappe's core solutions.

**A collection of materials to help you get started designing apps with Frappe.**

-  <u>Python</u>: Frappe's server-side programming is done in Python 3.

- <u>MariaDB/Postgres</u>: To construct database-driven apps with Frappe, you must first learn database administration fundamentals and common SQL queries.

- <u>HTML/CSS</u>: To create user interfaces with the Frappe Framework, you must first master fundamental HTML/CSS and the Bootstrap CSS Framework.

- <u>JavaScript/jQuery</u>: You'll need to learn JavaScript and the jQuery library to alter forms and develop dynamic user interfaces.

- <u>Jinja Templating</u>: You'll need to learn the Jinja Templating language to create Web Views and Print Templates.

-  <u>Git/GitHub</u>: Learn how to contribute to an open source project by utilizing Git and GitHub, two outstanding code management and sharing services.


<u>To understand the purpose and benefits of Frappe's ERP, it's important to first define some of the key concepts and 
terminology used in the Frappe framework. These include:</u>



1.**Doctype:** 
A DocType is the foundation of any application built on the <u>Frappe Framework</u>. It describes your data's Model and View. It describes what fields are saved for your data and how they interact with one another. It includes information about how your data is named. We must first enable developer mode on our bench before we can construct <u>DocTypes</u>.

[**Enable Developer Mode**](https://frappeframework.com/docs/v14/user/en/tutorial/create-a-doctype#enable-developer-mode)
**$ bench set-config -g developer_mode true
  $ bench start**

**[Creating a DocType](https://frappeframework.com/docs/v14/user/en/tutorial/create-a-doctype#creating-a-doctype)**

The first <u>doctype</u> we will create is Article. To create it, click on New.

- Enter Name as Article

- Select Library Management in Module

- <u>Add the following fields in the Fields table:</u>
Article Name (Data, Mandatory)
Image (Attach Image)
Author (Data)
Description (Text Editor)
ISBN (Data)
Status (Select) - Enter two options: Issued and Available (Type Issued, hit enter, then type Available)
Publisher (Data)

![After clicking](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/hj536s6lc6u4dvvej2ny.gif)


![Create new Article](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ytn3g7tv5oateaiho2e2.gif)

**DocType Features**

[<u>Naming</u>](https://frappeframework.com/docs/v14/user/en/tutorial/doctype-features#naming)
If you used the Form to create a document, you may have observed that the name value of the document was a randomly generated hash. Let us make a tweak so that the Article Name we specify becomes the document's name.

[<u>Form Layout</u>](https://frappeframework.com/docs/v14/user/en/tutorial/doctype-features#form-layout)
Let's rearrange the fields in the form to make the most of the available space. Scroll down to the Fields section of the Article doctype and add two new Column Break and Section Break fields. <u>Form Settings</u> can also be modified.

[<u>Permissions</u>](https://frappeframework.com/docs/v14/user/en/tutorial/doctype-features#permissions)
For a DocType, you can also specify which roles and actions are permitted and which are not. Scroll down to the Permission Rules section and add the roles to the Article doctype.

2.**Workflow:** 
A workflow is a set of processes that must be followed to perform a certain task. Workflows for various <u>doctypes</u> can be defined and can contain approval processes, notifications, and other activities. Once a Workflow is created, you can take action on it via [Workflow Actions.](https://docs.erpnext.com/docs/v13/user/manual/en/setting-up/workflow-actions)

**How to Create a Workflow**

- Go to the Workflow list, click on New.

- Enter a name for the Workflow and select the DocType on 
   which to be applied.

- Enter the different states of the Workflow. Enter Doc 
  Status for them, select which field to update from the 
  Update Field column, enter what the value will be updated 
  to under Update Value.

   The Workflow States can have different colors according to 
   the state. Eg: Green for success. Document statuses: Saved 
   = 0, Submitted = 1, Cancelled = 2.

![workflow](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/1yzuxn2wz9i5w7ezmo79.png)

- Enter the Transition Rules.

![Transition rules](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/0nmpqplj717iwvv2rumc.png)



3.**Module:**
A DocType will always belong to a module, to enable easier grouping of related models. Frappe comes with a lot of built-in modules. For e.g

<u>Core</u> - contains doctypes like DocType, DocField, Report, System Settings, etc
<u>Desk</u> - contains doctypes like ToDo, Event, Note, Kanban Board, etc
<u>Email</u> - contains doctypes like Email Account, 
Newsletter, Email Group, etc
Modules also help in grouping code files in directories. The controller files generated by a DocType will live in its respective Module directory.
.

![file directory](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/0hvtwjwcq1xwma9pzq7p.png)

4.[**<u>Client Script</u>**](https://frappeframework.com/docs/v14/user/en/desk/scripting/client-script)
A client script is a piece of code that can be applied to a doctype or form to enhance its functionality. Validation, automation, and other client behavior can be added to a doctype or form using client scripts. make sure to test them on different browsers to ensure compatibility across your user base. Client Script was renamed from custom scripts in version 13.




We may better appreciate the purpose and benefits of Frappe's ERP now that we've identified some of the important concepts and terminology utilized in the Frappe architecture. The goal of Frappe's ERP is to deliver robust, flexible, and customized solutions for businesses of all sizes to manage their operations in a streamlined and efficient manner. Frappe's ERP enables organizations to manage their processes more effectively, decrease manual data entry and errors, and gain real-time visibility into their operations by integrating all of the essential business tasks onto a single platform.


**<u>Benefits of using Frappe's ERP include:</u>**

- <u>Customization:</u> Frappe's ERP can be tailored to a company's exact requirements. It provides a versatile architecture that enables developers to design and alter modules based on their needs.

- <u>Scalability:</u> The software is meant to be scalable, which means it can easily accommodate a growing firm. It supports the addition of new modules and users, making it an excellent alternative for enterprises of all sizes.

- <u>Integration:</u> Frappe's ERP can be coupled with third-party software such as accounting software, CRM software, and e-commerce platforms. This makes managing multiple business functions from a single system easier.

- <u>Data Security:</u> The program includes strong security protections to safeguard important corporate data. To ensure that only authorized users may access the system, it includes role-based access control, data encryption, and user authentication.

- <u>Real-time Reporting:</u> Real-time reporting capabilities are provided by Frappe's ERP, allowing organizations to make informed decisions based on accurate and up-to-date data. The software includes customizable dashboards, graphs, and charts for analyzing business performance.

- <u>Cost-effective:</u> Frappe's ERP is open-source software, which means it is free to use and may be customized and distributed to meet the needs of the business. It saves businesses a large amount of money that they would otherwise have to spend on pricey proprietary software licenses.

- <u>User-friendly:</u> The program is user-friendly, making it simple for staff to use and navigate. It offers a modern, user-friendly interface that takes little training to get started.

- <u>Better collaboration:</u> Frappe's ERP fosters cooperation across teams and departments, allowing employees to share information and operate more efficiently together.

Finally, Frappe's ERP is a robust and adaptable solution for organizations wishing to streamline operations, cut expenses, and enhance their bottom line. Businesses of all sizes can benefit from higher productivity, improved accuracy, better cooperation, more exposure, and customizability by providing a range of configurable and flexible essential concepts and terminology.