Skip to content

Commit

Permalink
Initial Commit of URY Pulse App
Browse files Browse the repository at this point in the history
  • Loading branch information
jabir-tridz committed Nov 14, 2023
0 parents commit ba7cd4c
Show file tree
Hide file tree
Showing 73 changed files with 2,668 additions and 0 deletions.
90 changes: 90 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,90 @@

name: CI

on:
push:
branches:
- develop
pull_request:

concurrency:
group: develop-ury_pulse-${{ github.event.number }}
cancel-in-progress: true

jobs:
tests:
runs-on: ubuntu-latest
strategy:
fail-fast: false
name: Server

services:
mariadb:
image: mariadb:10.6
env:
MYSQL_ROOT_PASSWORD: root
ports:
- 3306:3306
options: --health-cmd="mysqladmin ping" --health-interval=5s --health-timeout=2s --health-retries=3

steps:
- name: Clone
uses: actions/checkout@v2

- name: Setup Python
uses: actions/setup-python@v2
with:
python-version: '3.10'

- name: Setup Node
uses: actions/setup-node@v2
with:
node-version: 14
check-latest: true

- name: Cache pip
uses: actions/cache@v2
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('**/*requirements.txt', '**/pyproject.toml', '**/setup.py', '**/setup.cfg') }}
restore-keys: |
${{ runner.os }}-pip-
${{ runner.os }}-
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: 'echo "::set-output name=dir::$(yarn cache dir)"'

- uses: actions/cache@v2
id: yarn-cache
with:
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- name: Setup
run: |
pip install frappe-bench
bench init --skip-redis-config-generation --skip-assets --python "$(which python)" ~/frappe-bench
mysql --host 127.0.0.1 --port 3306 -u root -proot -e "SET GLOBAL character_set_server = 'utf8mb4'"
mysql --host 127.0.0.1 --port 3306 -u root -proot -e "SET GLOBAL collation_server = 'utf8mb4_unicode_ci'"
- name: Install
working-directory: /home/runner/frappe-bench
run: |
bench get-app ury_pulse $GITHUB_WORKSPACE
bench setup requirements --dev
bench new-site --db-root-password root --admin-password admin test_site
bench --site test_site install-app ury_pulse
bench build
env:
CI: 'Yes'

- name: Run Tests
working-directory: /home/runner/frappe-bench
run: |
bench --site test_site set-config allow_tests true
bench --site test_site run-tests --app ury_pulse
env:
TYPE: server
7 changes: 7 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
.DS_Store
*.pyc
*.egg-info
*.swp
tags
ury_pulse/docs/current
node_modules/
50 changes: 50 additions & 0 deletions FEATURES.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
## Features of URY Pulse


### Daily Profit and Loss:

**The heart of URY Pulse is the Daily Profit and Loss report. Here's how it works:**

- Buying Price List :
- Users can set the buying price list to calculate the cost of goods.

- Direct Expenses :
- This section includes expenses such as consumables (burning materials), their cost per unit, and direct fixed expenses (daily fixed expenses). You can set expense names and amounts for items that are part of your daily operational costs.

- Indirect Expenses :
- Indirect expenses consist of electricity costs per unit, expense names, and amounts that are also daily fixed expenses. Additionally, there's a section for percentage expenses, which allows you to store expense percentages based on either net sales or gross sales. You can also set depreciation in this section.


### Daily P and L Calculation:

**Once you've set up the necessary data in the Daily Profit and Loss section of URY Report Settings, the system can calculate your daily profit and loss, including the following components:**

- Gross Sales: The total sales for the day..
- Direct Expenses: The sum of consumables and other direct fixed expenses.
- Cost of Goods Sold: This includes the cost of the items sold, factoring in product bundles and Bill of Materials (BOM) sub-items.
- Gross Profit/Loss: The difference between gross sales and the cost of goods sold.
- Indirect Expenses: The total of indirect fixed expenses and any percentage-based expenses.
- Net Profit/Loss: The final profit or loss for the day.

**By inputting daily readings for consumables, electricity, and any other expenses, and then saving and submitting the document, you can generate a detailed daily profit and loss report, complete with a breakdown of the cost of goods sold. This report is an invaluable tool for restaurant owners and managers to track their financial performance on a daily basis.**


### Reports:

**It offers a wide range of reports, including the following:**

1. Today's Sales
2. Daywise Sales
3. Daywise Invoices
4. Month Wise Sales
5. Average Bill Value
6. Cancelled Invoices
7. Item Wise Sales
8. Customer Data
9. Repeated Customers
10. Employee Sales


### Customizable Branch Timings:

- URY Pulse allows you to set varying branch timings in the URY Report settings, including extended hours. This feature ensures that your reports accurately reflect the operational hours of your restaurant.
42 changes: 42 additions & 0 deletions INSTALLATION.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
# URY Pulse Installation

**Prerequisite Setup:**
- Before using URY Pulse, ensure you have URY and Frappe HR installed.
- Follow the [URY installation guide](https://github.com/ury-erp/ury/blob/main/INSTALLATION.md) for the installation process.

### To install URY Pulse, follow these steps:

**Create New Site:**

```sh
$ bench new-site sitename
```
**Install the Frappe HR app to your bench:**

```sh
$ $ bench get-app hrms
```

**Install the URY Pulse app to your bench:**

```sh
$ bench get-app ury_pulse https://github.com/ury-erp/pulse.git
```

**To install Frappe HR into site:**

```sh
$ bench --site sitename install-app hrms
```

**To install URY Pulse into site:**

```sh
$ bench --site sitename install-app ury_pulse
```

**Migrate the site:**

```sh
$ bench --site sitename migrate
```
18 changes: 18 additions & 0 deletions MANIFEST.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
include MANIFEST.in
include requirements.txt
include *.json
include *.md
include *.py
include *.txt
recursive-include ury_pulse *.css
recursive-include ury_pulse *.csv
recursive-include ury_pulse *.html
recursive-include ury_pulse *.ico
recursive-include ury_pulse *.js
recursive-include ury_pulse *.json
recursive-include ury_pulse *.md
recursive-include ury_pulse *.png
recursive-include ury_pulse *.py
recursive-include ury_pulse *.svg
recursive-include ury_pulse *.txt
recursive-exclude ury_pulse *.pyc
39 changes: 39 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
# URY Pulse - Reporting Tool For Restaurants

URY Pulse is a powerful reporting tool designed to provide comprehensive insights and analytics for restaurants. It offers a range of reports, including Daily Profit and Loss (P&L), as well as various other essential data to help restaurant owners and managers make informed decisions.

> :warning: Warning :
> URY Pulse is currently in active development. Not recommended for use in production unless you know what you are doing.
> :information_source: Note :
> Our system has been successfully running at scale, serving over 10+ outlets for the past 10 months.
- [Part of the URY Ecosystem](https://github.com/ury-erp/ury#readme)



## Features

below is the key Features of URY Pulse

- Daily Profit and Loss
- Various Reports
- Customizable Branch Timings


For more comprehensive list of features [go here.](FEATURES.md)


## Getting Started

To start using URY Pulse, you need to install URY and [Frappe HR](https://github.com/frappe/hrms#installation) and then setup your first restaurant.

1. [URY Pulse Installation Guide](INSTALL.md).

2. [URY Pulse Setup Instructions](SETUP.md).



## About

URY Pulse is developed by [Tridz Technologies Pvt Ltd](https://tridz.com) and supported by [Frappe](http://frappe.io).
37 changes: 37 additions & 0 deletions SETUP.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
## URY Pulse Setup

Follow these steps to set up URY Pulse after completing basic ERPNext configuration:

#### Step 1 :

- Complete all the steps outlined in the [URY Setup](https://github.com/ury-erp/ury/blob/main/SETUP.md)

#### Step 2:

- Navigate to **URY Report Settings** in your site.
- Click on **Add URY Report Settings**.

#### Step 3

- Under the **Details** tab:
- **Extended Hours** : Enable this if the branch operates after 12 AM.
- **No of Hours** : Enter the number of hours, if extended hours is enabled.
- Under the **Daily P and L Settings** tab:
- **Buying price List** : Select the buying price list for your branch.
- Under **Direct Expenses**:
- **Burning Materials (Other Consumables)** : Table to list consumables.
- **Material** : Enter the Material (e.g., gas, charcoal).
- **Cost Per Unit** : Specify the cost per unit for each material.
- **Direct Fixed Expenses** : Table to add list of daily fixed direct expenses.
- **Expense** : Provide the expense name.
- **Amount** : Specify amount for each expense.
- Under **Indirect Expenses**:
- **Electricity Charges**: Enter the electricity charges per unit.
- **Indirect Fixed Expenses** : Table to list daily fixed indirect expenses.
- **Expense** : Provide the expense name.
- **Amount** : Specify amount for each expense.
- **Percentage Expenses** : Table to list of expenses as a percentage of sales.
- **Expense** : Provide the expense name.
- **Percentage Type** : Choose the percentage type (Net Sales or Gross Sales).
- **Percent** : Specify the percentage of the selected type.
- **Depreciation** : Add depreciation amount if applicable.
1 change: 1 addition & 0 deletions license.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
License: MIT
1 change: 1 addition & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
# frappe -- https://github.com/frappe/frappe is installed via 'bench init'
19 changes: 19 additions & 0 deletions setup.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
from setuptools import setup, find_packages

with open("requirements.txt") as f:
install_requires = f.read().strip().split("\n")

# get version from __version__ variable in ury_pulse/__init__.py
from ury_pulse import __version__ as version

setup(
name="ury_pulse",
version=version,
description="Reporting Tool For Restaurants",
author="Tridz Technologies Pvt. Ltd.",
author_email="[email protected]",
packages=find_packages(),
zip_safe=False,
include_package_data=True,
install_requires=install_requires
)
3 changes: 3 additions & 0 deletions ury_pulse/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@

__version__ = '0.0.1'

Empty file added ury_pulse/config/__init__.py
Empty file.
10 changes: 10 additions & 0 deletions ury_pulse/config/desktop.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
from frappe import _

def get_data():
return [
{
"module_name": "URY Pulse",
"type": "module",
"label": _("URY Pulse")
}
]
10 changes: 10 additions & 0 deletions ury_pulse/config/docs.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
"""
Configuration for docs
"""

# source_link = "https://github.com/[org_name]/ury_pulse"
# headline = "App that does everything"
# sub_heading = "Yes, you got that right the first time, everything"

def get_context(context):
context.brand_html = "URY Pulse"
Loading

0 comments on commit ba7cd4c

Please sign in to comment.