zibuyu1995 / shopyo

๐ŸŽ Open inventory management and (coming soon) Point of sales (powered by python) for small shops. Towards ERP. First-timers-friendly

Home Page:https://abdur-rahmaanj.github.io/shopyo

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Build Status


shopyo
Shopyo

Featured on Weekly Python issue 436 ๐ŸŒŸ

๐ŸŽ Open inventory management and Point of sales (powered by python) for small shops.

  • ๐Ÿ‘Œ Crisp UI
  • ๐Ÿ’— Intuitive
  • ๐ŸŽ‡ Instant lookup
  • โœ๏ธ Towards customisation

Shopyo makes a great Flask base. In continuous improvement.

โš—๏ธ Stability

beta - now in beta!

alpha - highly volatile, core features not yet finished

๐Ÿ’Œ Contributing Countries

๐Ÿ‡ฒ๐Ÿ‡บ x 1 | ๐Ÿ‡ฉ๐Ÿ‡ช x ? | ๐Ÿ‡จ๐Ÿ‡ณ x ? | ๐Ÿ‡ฌ๐Ÿ‡ง x ? | ๐Ÿ‡ธ๐Ÿ‡ฌ x ? | ๐Ÿ‡บ๐Ÿ‡ฌ x 1 | ๐Ÿ‡ฎ๐Ÿ‡ณ x ?

Sparkline

๐Ÿ”ฅ Just Added Features

  • Confirmation before deleting section
  • Settings fully operationable
  • Apply settings works for existing and non-existing db
  • Instantly checks duplicate

  • Appointment section

๐Ÿ“ Testimonial

This is my first time contributing to a public repo and I have quite enjoyed it. If you're a first-time-contributor the community is very helpful and can help you progress. Since I have been helping in this repo, I have also learnt a few things myself. The owner of the repo is active and is always willing to help.

Also, if I'm around and you're stuck give us a shout. I'll help if I can. @blips5

๐Ÿ“ฐ In The News

Understand Shopyo

Shopyo internals explained here: Shopyo: Enhance Your Flask by Exploring An Advanced Flask App

๐Ÿ“– History

I want to learn!

Months ago, I was searching github for a point of sales solution that used Python. What bothered me was that many of the applications I found were not ideal. Some required Posgres with the expectation that a user would already have this installed, others had codebases that were a mess of spaghetti code, yet others were django-based accounting monsters ...

I decided to try making my own solution, modeled after a client request, I had once recived. I Made it flask-based with SQLalchemy and SQLite. You can instantly get started with no hassle, switching to something more powerful when you want to (since it uses an ORM)

For the UI, we used the latest, bootstrap4, fa5 and jq3. Interestingly enough, I had two shop owners try it and they were very impressed with the ease of use.

It is still in devolopment and supports instant lookup. Long story short, with some programming skills, you can solve some everyday problems. And yes, no cdn, all libs are bundled so that you can use it completely offline

See this linked-in article!

โ™จ๏ธ Contributing

If you want to contribute, go ahead, we โค๏ธ it. We follow a ๐Ÿ’ฏ % first-timers-friendly policy.

  • Fork repo.
git clone https://github.com/<your-username>/shopyo.git
  • Create a new branch. For example: bg-fix-migration-file.
git checkout -b bg-fix-migration-file
  • Once you have add your changes ensure tests are still passing. # beginners ignore this one until we write more explicit docs
  • Add tests for any new functionality added. # beginners ignore this one until we write more explicit docs
  • Ensure you commits follow the standard specified here.
  • Follow the Pull request template.
  • Add your country flag in readme after accepted PR
  • Update fork as below then
  • Push
git push origin <branch-name>
  • If it closes an issue, add Fixes #94 for example, as seen here

Update Fork

cd <your/local/cloned/repo/path/here>
git remote add upstream https://github.com/Abdur-rahmaanJ/shopyo.git
git fetch upstream
git pull upstream master

๐Ÿ’ฌ Community: Discord

https://discord.gg/k37Ef6w

๐Ÿ”ง Install instructions

  • download python3.7
  • clone and cd into project
  • run python -m pip install -r requirements.txt

๐Ÿ‘Ÿ Run instructions

cd into shopyo/shopyo if not already.

initialise and setup app.

python manage.py initialise

run the app.

python manage.py runserver

go to the indicated url

Super User password

User ID: user 
password: pass

๐Ÿ”ฉ Migrations

In case of change to models, do

python manage.py db migrate
pyhton manage.py db upgrade

๐Ÿ“Ÿ Complete Commands

Initialise database.

python manage.py db init # create db from new
python manage.py db migrate
python manage.py db upgrade

clean project

python manage.py clean

removes __pycache__/, test.db and migrations.

๐Ÿ“œ Docs

Sphinx docs generater

Run

sphinx-build -b html sphinx_source docs

in shopyo/ to generate docs

Read the docs for Sphinx Alablaster

๐Ÿšง Developing a template.

Show me how

Each landing page and subsection should contain the following headers.

{% extends "base/main_base.html" %} // extends the base.html file.

{% set active_page = "sectionName" %} // sets the active section (change section name).

Create the main landing page of a new section in the template folder.

Inside the template folder create a folder named as you want

/template
    /base
    /<changeme> (swap <changeme> for section name).
        index.html

Create a subsection template.

Inside the template folder create a new file under the folder named same as the section.

/template 
    /base
    /section_name
        index.html
        anotherfile.html 

Create navigation elements for a new section.

Inside the template folder create a file named nav.html.

/template
    /base
    /example_section_name
        index.html
        nav.html

In the nav.html file elements for the navigation can be created.

To display the navagation elements.

Open the template /base folder and locate the nav_base.html.

In the nav_bar_log([]) array. Enter the section name last in the list.

{% set nav_bar_log = [
  ('section0'),
  ('section1'),
  ('new_section')
  ] %}

Now enter a new elif statement containing a reference to the _nav.html

    {% if active_page == nav_bar_log[0] %}
      {% include "section0/nav.html" %}
      
    {% elif active_page == nav_bar_log[1] %}
      {% include "section1/nav.html" %}

    {% elif active_page == nav_bar_log[2] %} <- - - Add 1 to index.
      {% include "new_section/nav.html" %}

Then the navagation elements will be displayed in the new section.

Windows Deployment

Show me how

youtube demo

๐Ÿณ In Action

Roadmap

  • โœ”๏ธ Models
  • โœ”๏ธ Migrations
  • โœ”๏ธ Restful Api
  • โœ”๏ธ Manage.py
  • โœ”๏ธ CSRF protection
  • โœ”๏ธ Easy dev/production mode switch
  • โœ”๏ธ Login
  • โœ”๏ธ Api namespacing / apps
  • โœ”๏ธ Django-like structure (where models, views and templates all in one folder)

In Progress

  • ๐Ÿ”ƒ Unit tests
  • ๐Ÿ”ƒ Integration tests
  • ๐Ÿ”ƒ Permission levels

Crossed Out

  • โœ–๏ธ Forms (We believe it should be to the front-end designer's taste)

About

๐ŸŽ Open inventory management and (coming soon) Point of sales (powered by python) for small shops. Towards ERP. First-timers-friendly

https://abdur-rahmaanj.github.io/shopyo

License:MIT License


Languages

Language:HTML 62.9%Language:Python 36.2%Language:Makefile 0.6%Language:Dockerfile 0.3%