mirror of
https://github.com/inventree/inventree-website.git
synced 2025-05-05 16:58:54 +00:00
Merge branch 'main' of github.com:inventree/inventree-website
This commit is contained in:
commit
e238f8915a
68
.github/collect_plugin.py
vendored
Normal file
68
.github/collect_plugin.py
vendored
Normal file
@ -0,0 +1,68 @@
|
|||||||
|
import json
|
||||||
|
import os
|
||||||
|
from pathlib import Path
|
||||||
|
from urllib.request import urlopen, Request
|
||||||
|
|
||||||
|
inp_project = os.environ.get('PROJECT').strip()
|
||||||
|
inp_author = os.environ.get('AUTHOR').strip()
|
||||||
|
file_name = Path(f'_repo/{inp_project}.md')
|
||||||
|
crowdin_projet_id = 452300
|
||||||
|
|
||||||
|
print(f'Collecting {inp_project} with {inp_author}...')
|
||||||
|
|
||||||
|
def get_data(url, key=None, default=0, auth=None):
|
||||||
|
"""Fetches data from remote endpoint"""
|
||||||
|
httprequest = Request(url, headers={"Accept": "application/json"})
|
||||||
|
|
||||||
|
if auth:
|
||||||
|
httprequest.add_header("Authorization", f"Bearer {auth}")
|
||||||
|
|
||||||
|
with urlopen(httprequest) as response:
|
||||||
|
data = response.read().decode()
|
||||||
|
data = json.loads(data)
|
||||||
|
|
||||||
|
if key:
|
||||||
|
data = data.get(key, default)
|
||||||
|
|
||||||
|
return data
|
||||||
|
|
||||||
|
pypi_data = get_data(f'https://pypi.org/pypi/{inp_project}/json')
|
||||||
|
|
||||||
|
name = pypi_data['info']['name']
|
||||||
|
tagline = pypi_data['info']['summary']
|
||||||
|
author = inp_author or pypi_data['info']['author_email']
|
||||||
|
license = pypi_data['info']['license']
|
||||||
|
try:
|
||||||
|
version = pypi_data['info']['version']
|
||||||
|
stable = int(version.split('.')[0])>1
|
||||||
|
except:
|
||||||
|
stable = False
|
||||||
|
bugtracker = pypi_data['info']['bugtrack_url'] or pypi_data['info']['project_urls'].get('Bug Tracker') or ''
|
||||||
|
homepage = pypi_data['info']['home_page'] or pypi_data['info']['project_urls'].get('Homepage')
|
||||||
|
keywords = pypi_data['info']['keywords']
|
||||||
|
readme = pypi_data['info']['description']
|
||||||
|
|
||||||
|
# Write data
|
||||||
|
file_name.write_text(
|
||||||
|
f"""---
|
||||||
|
name: {name}
|
||||||
|
author: {author}
|
||||||
|
license: {license}
|
||||||
|
open_source: true
|
||||||
|
stable: {stable}
|
||||||
|
maintained: true
|
||||||
|
pypi: true
|
||||||
|
package_name: {name}
|
||||||
|
github: {homepage}
|
||||||
|
gitlab:
|
||||||
|
source:
|
||||||
|
issue_tracker:{bugtracker}
|
||||||
|
website:
|
||||||
|
categories:
|
||||||
|
tags: {keywords}
|
||||||
|
---
|
||||||
|
{tagline}
|
||||||
|
|
||||||
|
{readme}
|
||||||
|
"""
|
||||||
|
)
|
42
.github/workflows/collect_plugin.yml
vendored
Normal file
42
.github/workflows/collect_plugin.yml
vendored
Normal file
@ -0,0 +1,42 @@
|
|||||||
|
name: Collect plugin by PyPI listing
|
||||||
|
|
||||||
|
on:
|
||||||
|
workflow_dispatch:
|
||||||
|
inputs:
|
||||||
|
project:
|
||||||
|
description: The name of the project on PyPi
|
||||||
|
required: true
|
||||||
|
author:
|
||||||
|
description: Enter the name of the author if you know it
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build:
|
||||||
|
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
permissions:
|
||||||
|
contents: write
|
||||||
|
pull-requests: write
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
- name: Get Plugin file
|
||||||
|
run: python .github/collect_plugin.py
|
||||||
|
env:
|
||||||
|
PROJECT: ${{ github.event.inputs.project }}
|
||||||
|
AUTHOR: ${{ github.event.inputs.author }}
|
||||||
|
- name: Create Pull Request
|
||||||
|
uses: peter-evans/create-pull-request@v4
|
||||||
|
with:
|
||||||
|
token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
commit-message: "[REPO] Add plugin ${{ github.event.inputs.project }}"
|
||||||
|
branch: "plugin/${{ github.event.inputs.project }}"
|
||||||
|
title: "[REPO] Add plugin ${{ github.event.inputs.project }}"
|
||||||
|
body: |
|
||||||
|
Automated PR to add the plugin ${{ github.event.inputs.project }}.
|
||||||
|
You need to check this manually!
|
||||||
|
labels: |
|
||||||
|
plugin
|
||||||
|
assignees: |
|
||||||
|
matmair
|
||||||
|
${{ github.event.inputs.author }}
|
||||||
|
reviewers: |
|
||||||
|
matmair
|
7
.github/workflows/deploy.yml
vendored
7
.github/workflows/deploy.yml
vendored
@ -1,9 +1,7 @@
|
|||||||
name: Build pages and publish
|
name: Build pages and publish
|
||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
push
|
||||||
branches:
|
|
||||||
- main
|
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
||||||
@ -23,7 +21,10 @@ jobs:
|
|||||||
uses: limjh16/jekyll-action-ts@v2
|
uses: limjh16/jekyll-action-ts@v2
|
||||||
with:
|
with:
|
||||||
enable_cache: true
|
enable_cache: true
|
||||||
|
- run: bundle exec htmlproofer ./_site --enforce-https=false
|
||||||
|
name: Check links
|
||||||
- name: Deploy
|
- name: Deploy
|
||||||
|
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/main'}}
|
||||||
uses: peaceiris/actions-gh-pages@v3
|
uses: peaceiris/actions-gh-pages@v3
|
||||||
with:
|
with:
|
||||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
1
Gemfile
1
Gemfile
@ -10,3 +10,4 @@ group :jekyll_plugins do
|
|||||||
gem 'jekyll_custom_permalink'
|
gem 'jekyll_custom_permalink'
|
||||||
end
|
end
|
||||||
gem "webrick", "~> 1.7"
|
gem "webrick", "~> 1.7"
|
||||||
|
gem 'html-proofer'
|
||||||
|
23
Gemfile.lock
23
Gemfile.lock
@ -13,13 +13,23 @@ GEM
|
|||||||
em-websocket (0.5.3)
|
em-websocket (0.5.3)
|
||||||
eventmachine (>= 0.12.9)
|
eventmachine (>= 0.12.9)
|
||||||
http_parser.rb (~> 0)
|
http_parser.rb (~> 0)
|
||||||
|
ethon (0.16.0)
|
||||||
|
ffi (>= 1.15.0)
|
||||||
eventmachine (1.2.7)
|
eventmachine (1.2.7)
|
||||||
ffi (1.15.5)
|
ffi (1.15.5)
|
||||||
forwardable-extended (2.6.0)
|
forwardable-extended (2.6.0)
|
||||||
google-protobuf (3.21.12-x86_64-linux)
|
|
||||||
html-pipeline (2.14.3)
|
html-pipeline (2.14.3)
|
||||||
activesupport (>= 2)
|
activesupport (>= 2)
|
||||||
nokogiri (>= 1.4)
|
nokogiri (>= 1.4)
|
||||||
|
html-proofer (4.4.3)
|
||||||
|
addressable (~> 2.3)
|
||||||
|
mercenary (~> 0.3)
|
||||||
|
nokogiri (~> 1.13)
|
||||||
|
parallel (~> 1.10)
|
||||||
|
rainbow (~> 3.0)
|
||||||
|
typhoeus (~> 1.3)
|
||||||
|
yell (~> 2.0)
|
||||||
|
zeitwerk (~> 2.5)
|
||||||
http_parser.rb (0.8.0)
|
http_parser.rb (0.8.0)
|
||||||
i18n (1.12.0)
|
i18n (1.12.0)
|
||||||
concurrent-ruby (~> 1.0)
|
concurrent-ruby (~> 1.0)
|
||||||
@ -64,12 +74,16 @@ GEM
|
|||||||
rb-inotify (~> 0.9, >= 0.9.10)
|
rb-inotify (~> 0.9, >= 0.9.10)
|
||||||
mercenary (0.4.0)
|
mercenary (0.4.0)
|
||||||
minitest (5.17.0)
|
minitest (5.17.0)
|
||||||
|
nokogiri (1.14.0-aarch64-linux)
|
||||||
|
racc (~> 1.4)
|
||||||
nokogiri (1.14.0-x86_64-linux)
|
nokogiri (1.14.0-x86_64-linux)
|
||||||
racc (~> 1.4)
|
racc (~> 1.4)
|
||||||
|
parallel (1.22.1)
|
||||||
pathutil (0.16.2)
|
pathutil (0.16.2)
|
||||||
forwardable-extended (~> 2.6)
|
forwardable-extended (~> 2.6)
|
||||||
public_suffix (5.0.1)
|
public_suffix (5.0.1)
|
||||||
racc (1.6.2)
|
racc (1.6.2)
|
||||||
|
rainbow (3.1.1)
|
||||||
rb-fsevent (0.11.2)
|
rb-fsevent (0.11.2)
|
||||||
rb-inotify (0.10.1)
|
rb-inotify (0.10.1)
|
||||||
ffi (~> 1.0)
|
ffi (~> 1.0)
|
||||||
@ -80,15 +94,20 @@ GEM
|
|||||||
ffi (~> 1.9)
|
ffi (~> 1.9)
|
||||||
terminal-table (3.0.2)
|
terminal-table (3.0.2)
|
||||||
unicode-display_width (>= 1.1.1, < 3)
|
unicode-display_width (>= 1.1.1, < 3)
|
||||||
|
typhoeus (1.4.0)
|
||||||
|
ethon (>= 0.9.0)
|
||||||
tzinfo (2.0.5)
|
tzinfo (2.0.5)
|
||||||
concurrent-ruby (~> 1.0)
|
concurrent-ruby (~> 1.0)
|
||||||
unicode-display_width (2.4.2)
|
unicode-display_width (2.4.2)
|
||||||
webrick (1.7.0)
|
webrick (1.7.0)
|
||||||
|
yell (2.2.2)
|
||||||
|
zeitwerk (2.6.6)
|
||||||
|
|
||||||
PLATFORMS
|
PLATFORMS
|
||||||
x86_64-linux
|
x86_64-linux
|
||||||
|
|
||||||
DEPENDENCIES
|
DEPENDENCIES
|
||||||
|
html-proofer
|
||||||
jekyll
|
jekyll
|
||||||
jekyll-feed
|
jekyll-feed
|
||||||
jekyll-mentions
|
jekyll-mentions
|
||||||
@ -99,4 +118,4 @@ DEPENDENCIES
|
|||||||
webrick (~> 1.7)
|
webrick (~> 1.7)
|
||||||
|
|
||||||
BUNDLED WITH
|
BUNDLED WITH
|
||||||
2.3.26
|
2.4.6
|
||||||
|
@ -7,4 +7,4 @@ functions:
|
|||||||
link: https://docs.inventree.org/en/latest/report/report/
|
link: https://docs.inventree.org/en/latest/report/report/
|
||||||
- title: Extend and Customize
|
- title: Extend and Customize
|
||||||
text: InvenTree is designed to be highly extensible. If the core InvenTree functionality does not meet your particular need, InvenTree provides a RESTful API, a native Python library, and a powerful plugin system.
|
text: InvenTree is designed to be highly extensible. If the core InvenTree functionality does not meet your particular need, InvenTree provides a RESTful API, a native Python library, and a powerful plugin system.
|
||||||
link: https://docs.inventree.org/en/latest/extend/api/
|
link: https://docs.inventree.org/en/latest/api/api/
|
||||||
|
@ -1,12 +1,12 @@
|
|||||||
stats:
|
stats:
|
||||||
- name: Docker pulls
|
- name: Docker pulls
|
||||||
number: 2228985
|
number: 2233812
|
||||||
icon: fa-brands fa-docker
|
icon: fa-brands fa-docker
|
||||||
- name: GitHub Stars
|
- name: GitHub Stars
|
||||||
number: 2393
|
number: 2418
|
||||||
icon: fa-solid fa-star
|
icon: fa-solid fa-star
|
||||||
- name: Forks
|
- name: Forks
|
||||||
number: 378
|
number: 381
|
||||||
icon: fa-solid fa-code-branch
|
icon: fa-solid fa-code-branch
|
||||||
- name: Contributors
|
- name: Contributors
|
||||||
number: 52
|
number: 52
|
||||||
|
@ -1,10 +1,10 @@
|
|||||||
<footer class="cm-gray-2 body-font">
|
<footer class="cm-gray-2 body-font">
|
||||||
<div class="container px-5 pt-8 mx-auto flex md:flex-row md:flex-nowrap flex-wrap flex-col">
|
<div class="container px-5 pt-8 mx-auto flex md:flex-row md:flex-nowrap flex-wrap flex-col">
|
||||||
<div class="w-64 flex-shrink-0 md:mx-0 mx-auto text-center md:text-left">
|
<div class="w-64 flex-shrink-0 md:mx-0 mx-auto text-center md:text-left">
|
||||||
<a class="flex title-font font-medium items-center md:justify-start justify-center cm-gray-1">
|
<div class="flex title-font font-medium items-center md:justify-start justify-center cm-gray-1">
|
||||||
<img src="{{ '/assets/logo.png' | relative_url }}" alt="logo" height="32" width="32" class="h-8">
|
<img src="{{ '/assets/logo.png' | relative_url }}" alt="logo" height="32" width="32" class="h-8">
|
||||||
<span class="ml-3 text-xl">{{ site.title }}</span>
|
<span class="ml-3 text-xl">{{ site.title }}</span>
|
||||||
</a>
|
</div>
|
||||||
<p class="mt-2 text-sm cm-gray-3">{{ site.tagline }}</p>
|
<p class="mt-2 text-sm cm-gray-3">{{ site.tagline }}</p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<div class="section-container">
|
<div class="section-container">
|
||||||
<div class="flex flex-wrap w-full mb-4">
|
<div class="flex flex-wrap w-full mb-4">
|
||||||
<div class="lg:w-1/2 w-full mb-6 lg:mb-0">
|
<div class="lg:w-1/2 w-full mb-6 lg:mb-0">
|
||||||
<a class="anchor" id="{{ include.data.ref }}"></a>
|
<div class="anchor" id="{{ include.data.ref }}"></div>
|
||||||
<div class="inline-flex items-center">
|
<div class="inline-flex items-center">
|
||||||
<h1 class="header-text title-font mb-2 cm-gray-1">{{ include.data.title }}</h1>
|
<h1 class="header-text title-font mb-2 cm-gray-1">{{ include.data.title }}</h1>
|
||||||
{% if include.link %}
|
{% if include.link %}
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
<!-- Begin Mailchimp Signup Form -->
|
<!-- Begin Mailchimp Signup Form -->
|
||||||
<link href="//cdn-images.mailchimp.com/embedcode/classic-071822.css" rel="stylesheet" type="text/css">
|
<link href="https://cdn-images.mailchimp.com/embedcode/classic-071822.css" rel="stylesheet" type="text/css">
|
||||||
<style type="text/css">
|
<style type="text/css">
|
||||||
#mc_embed_signup{background:#fff; clear:left; font:14px Helvetica,Arial,sans-serif; width:600px;}
|
#mc_embed_signup{background:#fff; clear:left; font:14px Helvetica,Arial,sans-serif; width:600px;}
|
||||||
/* Add your own Mailchimp form style overrides in your site stylesheet or in this style block.
|
/* Add your own Mailchimp form style overrides in your site stylesheet or in this style block.
|
||||||
@ -73,7 +73,7 @@
|
|||||||
<div class="optionalParent">
|
<div class="optionalParent">
|
||||||
<div class="clear foot">
|
<div class="clear foot">
|
||||||
<input type="submit" value="Subscribe" name="subscribe" id="mc-embedded-subscribe" class="button">
|
<input type="submit" value="Subscribe" name="subscribe" id="mc-embedded-subscribe" class="button">
|
||||||
<p class="brandingLogo"><a href="http://eepurl.com/h5Mg8D" title="Mailchimp - email marketing made easy and fun"><img src="https://eep.io/mc-cdn-images/template_images/branding_logo_text_dark_dtp.svg"></a></p>
|
<p class="brandingLogo"><a href="https://eepurl.com/h5Mg8D" title="Mailchimp - email marketing made easy and fun"><img src="https://eep.io/mc-cdn-images/template_images/branding_logo_text_dark_dtp.svg" alt="Mailchimp logo"></a></p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -1,3 +1,3 @@
|
|||||||
{% assign pub_small = include.pub | downcase %}
|
{% assign pub_small = include.pub %}
|
||||||
{% assign publisher_ref = site.publishers | where: 'short_name', pub_small | first %}
|
{% assign publisher_ref = site.publishers | where: 'short_name', pub_small | first %}
|
||||||
<a href="{{ publisher_ref.url | relative_url }}">{{ publisher_ref.name }}</a>
|
<a href="{{ publisher_ref.url | relative_url }}">{{ publisher_ref.name }}</a>
|
@ -15,7 +15,7 @@ layout: default
|
|||||||
<h1>{{ page.title }}</h1>
|
<h1>{{ page.title }}</h1>
|
||||||
<p>
|
<p>
|
||||||
{{ page.date | date_to_string }}
|
{{ page.date | date_to_string }}
|
||||||
{% include partial/publisher_link.html pub= page.author %}
|
{% include partial/publisher_link.html pub=page.author %}
|
||||||
</p>
|
</p>
|
||||||
{{ content }}
|
{{ content }}
|
||||||
</article>
|
</article>
|
@ -3,7 +3,7 @@ layout: default
|
|||||||
---
|
---
|
||||||
<section class="cm-gray-2 body-font">
|
<section class="cm-gray-2 body-font">
|
||||||
<div class="pt-3 pb-1 section-container">
|
<div class="pt-3 pb-1 section-container">
|
||||||
<h1 class="header-text title-font mb-4 cm-gray-2 flex items-end">{{ page.title_text }}<a href="{{ page.permalink|append:'/feed.atom' }}" alr="Atom feed" class="ml-3 cm-gray-3"><img class="h-5 w-5" src="{{ '/assets/rss.svg' | relative_url }}" /></a></h1>
|
<h1 class="header-text title-font mb-4 cm-gray-2 flex items-end">{{ page.title_text }}<a href="{{ page.permalink|append:'/feed.atom' }}" alr="Atom feed" class="ml-3 cm-gray-3"><img class="h-5 w-5" src="{{ '/assets/rss.svg' | relative_url }}" alt="RSS symbol"/></a></h1>
|
||||||
<div class="flex flex-wrap">
|
<div class="flex flex-wrap">
|
||||||
|
|
||||||
{% assign cols = site[page.collection] %}
|
{% assign cols = site[page.collection] %}
|
||||||
|
@ -27,12 +27,14 @@ fullwith: true
|
|||||||
{% if page.pypi and page.package_name %}Package on PyPI:<pre class="my-0">{{ page.package_name }}</pre>{% endif %}
|
{% if page.pypi and page.package_name %}Package on PyPI:<pre class="my-0">{{ page.package_name }}</pre>{% endif %}
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
|
{% if page.website %}
|
||||||
<a href="{{ page.website }}" class="no-underline" aria-label="open website">
|
<a href="{{ page.website }}" class="no-underline" aria-label="open website">
|
||||||
<div>
|
<div>
|
||||||
<h4 class="plugin_links">Website <i class="fa-solid fa-arrow-up-right-from-square" title="External link"></i></h4>
|
<h4 class="plugin_links">Website <i class="fa-solid fa-arrow-up-right-from-square" title="External link"></i></h4>
|
||||||
<p class="font-normal">{{ page.website }}</p>
|
<p class="font-normal">{{ page.website }}</p>
|
||||||
</div>
|
</div>
|
||||||
</a>
|
</a>
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
{% if page.issue_tracker %}
|
{% if page.issue_tracker %}
|
||||||
<a href="{{ page.issue_tracker }}" class="no-underline" aria-label="open the issue tracker">
|
<a href="{{ page.issue_tracker }}" class="no-underline" aria-label="open the issue tracker">
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
---
|
---
|
||||||
author: oliver
|
author: SchrodingersGat
|
||||||
title: New Website
|
title: New Website
|
||||||
---
|
---
|
||||||
|
|
||||||
@ -17,7 +17,7 @@ inventree.org will no longer host the InvenTree software documentation. Document
|
|||||||
|
|
||||||
### Demo Server
|
### Demo Server
|
||||||
|
|
||||||
The [demo server](/demo.md) remains available at [demo.inventree.org](https://demo.inventree.org)
|
The [demo server]({% link demo.md %}) remains available at [demo.inventree.org](https://demo.inventree.org)
|
||||||
|
|
||||||
### Credits
|
### Credits
|
||||||
|
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
---
|
---
|
||||||
author: oliver
|
author: SchrodingersGat
|
||||||
title: 0.9.0 Release
|
title: 0.9.0 Release
|
||||||
---
|
---
|
||||||
|
|
||||||
|
27
_news/2023-01-30-introducing-the-plugin-list.md
Normal file
27
_news/2023-01-30-introducing-the-plugin-list.md
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
---
|
||||||
|
author: matmair
|
||||||
|
title: Introducing the Plugin List
|
||||||
|
---
|
||||||
|
|
||||||
|
Getting ready for 0.10.0, Website Updates and the Plugin List.
|
||||||
|
|
||||||
|
### Preparations for 0.10.0
|
||||||
|
|
||||||
|
Since the last release, we've been working on the next version of InvenTree, which will be 0.10.0. There are already 85 PRs merged into the `master` branch, and we're expecting to release 0.10.0 in the next few weeks.
|
||||||
|
|
||||||
|
There will be a full blog post once we release but here are a few perks to look for:
|
||||||
|
- The option to use [Slovenian](https://github.com/inventree/InvenTree/pull/4072). Around 7% are already translated - we need your help to get that number up. Head over to the [translation project](https://crowdin.com/project/inventree) if you want to help with any language.
|
||||||
|
- Attach the current order schedule to your calendar ([3858](https://github.com/inventree/InvenTree/pull/3858))
|
||||||
|
- Improvements for report rendering ([4081](https://github.com/inventree/InvenTree/pull/4081)) and a lot of improvements to the docs
|
||||||
|
- Get orders by their reference via the API ([4083](https://github.com/inventree/InvenTree/pull/4083))
|
||||||
|
- Improvements for SSO - including the UI ([4169](https://github.com/inventree/InvenTree/pull/4169), [4263](https://github.com/inventree/InvenTree/pull/4263)), better separation between local and SSO user management ([4171](https://github.com/inventree/InvenTree/pull/4171)) and restricting signups to specific domains ([4172](https://github.com/inventree/InvenTree/pull/4172))
|
||||||
|
- Include alternative parts in your BOM exports ([4203](https://github.com/inventree/InvenTree/pull/4203))
|
||||||
|
- A simple priority field for order ([4225](https://github.com/inventree/InvenTree/pull/4225))
|
||||||
|
|
||||||
|
### Website Updates
|
||||||
|
|
||||||
|
The website got some UI fixes for mobile users and gained more icons. We also added a [team section](https://inventree.org/about/team) and moved away from cookie-based analytics.
|
||||||
|
|
||||||
|
### Plugin List
|
||||||
|
|
||||||
|
A new feature landed: the [plugin list](https://inventree.org/plugins). Check out the [blog post](/blog/2023/01/30/plugin-list) for more details.
|
@ -1,5 +1,5 @@
|
|||||||
---
|
---
|
||||||
author: oliver
|
author: SchrodingersGat
|
||||||
title: Translating InvenTree
|
title: Translating InvenTree
|
||||||
---
|
---
|
||||||
|
|
||||||
@ -29,7 +29,7 @@ There are many files within the InvenTree project which can provide these transl
|
|||||||
- Javascript source files
|
- Javascript source files
|
||||||
- HTML template files
|
- HTML template files
|
||||||
|
|
||||||
Additionally, translation support is provided for the [InvenTree Mobile App](/extend/app.md)!
|
Additionally, translation support is provided for the [InvenTree Mobile App]({% link extend/app.md %})!
|
||||||
|
|
||||||
#### Exporting Translations - GitHub
|
#### Exporting Translations - GitHub
|
||||||
|
|
||||||
@ -51,7 +51,7 @@ Updated translated strings are periodically merged back into the main code branc
|
|||||||
|
|
||||||
The translation framework is provided by the InvenTree team to make our software more useful and appealing to a greater number of people. The entire translation effort is driven by the InvenTree community. Any contributions, no matter how large or small, are greatly encouraged!
|
The translation framework is provided by the InvenTree team to make our software more useful and appealing to a greater number of people. The entire translation effort is driven by the InvenTree community. Any contributions, no matter how large or small, are greatly encouraged!
|
||||||
|
|
||||||
If you would like to see improved translations in a particular language, read the [contribution guide](/contribute.md#translate)! The InvenTree project benefits greatly from your efforts, and you get a great piece of open source software in your native language.
|
If you would like to see improved translations in a particular language, read the [contribution guide]({% link contribute.md %}#translate)! The InvenTree project benefits greatly from your efforts, and you get a great piece of open source software in your native language.
|
||||||
|
|
||||||
#### Adding New Languages
|
#### Adding New Languages
|
||||||
|
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
---
|
---
|
||||||
author: oliver
|
author: SchrodingersGat
|
||||||
title: 0.9.0 Stable Release
|
title: 0.9.0 Stable Release
|
||||||
---
|
---
|
||||||
|
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
---
|
---
|
||||||
author: oliver
|
author: SchrodingersGat
|
||||||
title: 2022 in Review
|
title: 2022 in Review
|
||||||
---
|
---
|
||||||
|
|
||||||
@ -33,7 +33,7 @@ Our new website (inventree.org) is now up and running! Thanks to @matmair in par
|
|||||||
|
|
||||||
### Translations
|
### Translations
|
||||||
|
|
||||||
[Translations](/contribute.md#translate) for the InevnTree project continue to grow, thanks to our vibrant community of users. Thanks to the [crowdin project](https://crowdin.com) which makes this possible.
|
[Translations]({% link contribute.md %}#translate) for the InevnTree project continue to grow, thanks to our vibrant community of users. Thanks to the [crowdin project](https://crowdin.com) which makes this possible.
|
||||||
|
|
||||||
### Users
|
### Users
|
||||||
|
|
||||||
|
69
_posts/2023-01-30-plugin-list.md
Normal file
69
_posts/2023-01-30-plugin-list.md
Normal file
@ -0,0 +1,69 @@
|
|||||||
|
---
|
||||||
|
author: matmair
|
||||||
|
title: Starting the Plugin List
|
||||||
|
---
|
||||||
|
|
||||||
|
Recently a new feature was launched: A central plugin list.
|
||||||
|
|
||||||
|
## TLDR
|
||||||
|
|
||||||
|
The Plugin List is managed by the [InvenTree org](https://github.com/inventree) and is [open for submissions](https://github.com/inventree/inventree-website#adding-a-plugin-to-the-list). It is a simple list [on the website]({% link plugins.html %}) for a start. Being on the list is not an endorsement or guarantee of service by the core team.
|
||||||
|
|
||||||
|
## Why plugins and a plugin list?
|
||||||
|
|
||||||
|
InvenTree is a powerful tool but the use cases very widely. Many things can be done with it, but too many special features also create confusion for the average hobbyist user.
|
||||||
|
That is why we created the plugin system. It allows users to extend InvenTree with custom functionality without having to modify or ding into core code. It is a great way to add features that are not needed by everyone but are still useful for a subset of users. It can also be used to customize InvenTree to fit existing patterns (eg. part numbering scheme or order references).
|
||||||
|
|
||||||
|
One of my main goals was to enable complex changes without the need of forking the code. This way users can still benefit from upstream changes and bugfixes without having to merge them manually. As a positive side effect, it should also reduce requests for fixes of very old versions and enable users to always use the latest version of InvenTree as we try to keep the plugin (python) APIs stable.
|
||||||
|
|
||||||
|
The plugin system has been in core for a while now and from my own usage, conversations with users and requests on GitHub I know that small plugin collections have started to form.
|
||||||
|
I think most plugins are very tailored to the businesses/users that deploy them. I have seen some for shipping, integrating ERP systems, connecting machines or generating files for orders. Therefore, they are not fit for public consumption.
|
||||||
|
There are, however, a number of public repos on GitHub and GitLab with integrations for printers, adding functionality that we are not willing/able to add to core or do other cool things.
|
||||||
|
|
||||||
|
The plugin list is a way to share the cool, public plugins you made with the community. I also hope that it enables new users to onboard faster.
|
||||||
|
|
||||||
|
## How it works
|
||||||
|
|
||||||
|
As mentioned [before]({% link _news/2022-04-23-news-are-starting.md %}), we use Jekyll for this website. This means that the list consists of static pages that are generated from YAML/Markdown files. The output is hosted by GitHub pages (for free ;-)) and can be previewed on PRs thanks to the Netlify app integration.
|
||||||
|
|
||||||
|
A file contains a number of standardised fields in the header and markup text for the plugin page that uses Markdown (just like GitHub README pages). That information is used to generate:
|
||||||
|
- the individual plugin pages (eg. [this one]({% link _repo/inventree-brother-plugin.md %}))
|
||||||
|
- plugin cards on the main page (showing the newest entries)
|
||||||
|
- a list of [all plugins]({% link plugins.html %})
|
||||||
|
- overview pages for [tags]({% link tags.html %}) and [categories]({% link categories.html %})
|
||||||
|
|
||||||
|
Adding a new entry is as simple as forking, creating a new file in the plugins folder and opening a PR. More on that is below.
|
||||||
|
|
||||||
|
There are also entries and pages for authors/publishers. Currently, we only support one author per plugin, but that might change in the future. The author entry is used to generate a page for the author (eg. [this one]({% link _publishers/schrodingersgat.md %})). That page also contains all blog posts written by the author and a few links.
|
||||||
|
|
||||||
|
### Disclaimer
|
||||||
|
|
||||||
|
While the list is moderated, the core team does not endorse or guarantee any service for the plugins listed. If you have any questions, please contact the plugin author directly.
|
||||||
|
|
||||||
|
### Submitting a plugin
|
||||||
|
|
||||||
|
If you want to add your plugin to the list, please follow the [instructions in the README](https://github.com/inventree/inventree-website#adding-a-plugin-to-the-list) of the repo for the website. The list is managed by members of the [InvenTree org](https://github.com/inventree), so it might take a few days to process your request. If you are submitting a plugin for the first time, there is a good chance you do not have a publisher/author entry either - please add that as well. The steps are listed in the README.
|
||||||
|
|
||||||
|
Please make sure to update your listing if your plugin is no longer maintained or if anything important changes. For now, there is no automated process to update listings from their repos.
|
||||||
|
|
||||||
|
## Future ideas
|
||||||
|
|
||||||
|
Several ideas have been brought forward regarding possible improvements to the plugin list since I started public work on it (the original idea is from Feb/Mar 2022, like the rest of the website). If you have any ideas, please let us know in the discussions on GitHub or in an issue. And if you want to help, please feel free to open a PR for anything listed below.
|
||||||
|
|
||||||
|
Inclusion in InvenTree: Users of InvenTree should be able to browse and install plugins directly from within the web app. This would require a way to install plugins and probably a way to update them too. A good example would be Octoprint's plugin manager. The main work would be to create a nice interface, the API endpoints (for installing and activating/deactivation) are already there.
|
||||||
|
|
||||||
|
Regarding browsing the list on the site:
|
||||||
|
* A more detailed list with screenshots, short descriptions and standardised sections in the page itself
|
||||||
|
* A way to rate plugins
|
||||||
|
* A way to show how often a plugin is used/downloaded (would probably need [4150](https://github.com/inventree/InvenTree/issues/4150))
|
||||||
|
* A better way to search for plugins (by name, description, author, tags, etc.) - we deploy statically so that might be tricky
|
||||||
|
* A way to filter plugins by InvenTree version
|
||||||
|
* A way to filter plugins by language (if they are translated)
|
||||||
|
* A way to filter plugins by license (there are so many licenses that I did not include it in the first version)
|
||||||
|
Quality of life:
|
||||||
|
* A more automated process to update the list from the plugin repos
|
||||||
|
* Improve the PyPI scraper to also work with GitHub and GitLab repos
|
||||||
|
* A way to automatically test plugins for compatibility with InvenTree and show that on the listing
|
||||||
|
* RSS feed for new plugins
|
||||||
|
|
||||||
|
Moon-shot idea: A privacy-friendly way to register your instance once and then have a button on the website that directly installs the plugin. That would also enable some cool other stuff with browser integrations, fast pairing for the app (very much requested by uni labs) and more.
|
7
_publishers/SergeoLacruz.md
Normal file
7
_publishers/SergeoLacruz.md
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
---
|
||||||
|
short_name: SergeoLacruz
|
||||||
|
name: Michael
|
||||||
|
github: SergeoLacruz
|
||||||
|
website: http://www.buchmann.ruhr
|
||||||
|
---
|
||||||
|
Hardware engineer in Germany and vintage fan.
|
@ -1,5 +1,5 @@
|
|||||||
---
|
---
|
||||||
short_name: oliver
|
short_name: SchrodingersGat
|
||||||
name: Oliver
|
name: Oliver
|
||||||
github: SchrodingersGat
|
github: SchrodingersGat
|
||||||
website: https://inventree.org
|
website: https://inventree.org
|
||||||
|
6
_publishers/wolflu05.md
Normal file
6
_publishers/wolflu05.md
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
---
|
||||||
|
short_name: wolflu05
|
||||||
|
name: Lukas
|
||||||
|
github: wolflu05
|
||||||
|
website:
|
||||||
|
---
|
@ -1,6 +1,6 @@
|
|||||||
---
|
---
|
||||||
name: inventree-brother-plugin # Name of the plugin (should be either NAME, TITLE or SLUG)
|
name: inventree-brother-plugin # Name of the plugin (should be either NAME, TITLE or SLUG)
|
||||||
author: schrodingersgat # Maintainer must be the same as the publisher reference
|
author: SchrodingersGat # Maintainer must be the same as the publisher reference
|
||||||
license: MIT # License, we prefer open source
|
license: MIT # License, we prefer open source
|
||||||
open_source: true # Is this project licensed with an OSI-approved license - aka 'open source'
|
open_source: true # Is this project licensed with an OSI-approved license - aka 'open source'
|
||||||
stable: true # Is this project stable? Should users deploy this in their instace?
|
stable: true # Is this project stable? Should users deploy this in their instace?
|
||||||
|
36
_repo/inventree-brother-plugin.md
Normal file
36
_repo/inventree-brother-plugin.md
Normal file
@ -0,0 +1,36 @@
|
|||||||
|
---
|
||||||
|
name: inventree-brother-plugin
|
||||||
|
author: SchrodingersGat
|
||||||
|
license: MIT
|
||||||
|
open_source: true
|
||||||
|
stable: False
|
||||||
|
maintained: true
|
||||||
|
pypi: true
|
||||||
|
package_name: inventree-brother-plugin
|
||||||
|
github: https://github.com/inventree/inventree-brother-plugin
|
||||||
|
gitlab:
|
||||||
|
source:
|
||||||
|
issue_tracker: https://github.com/inventree/inventree-brother-plugin/issues
|
||||||
|
website: https://inventree.org
|
||||||
|
categories: Printer
|
||||||
|
tags: Label Printer Brother
|
||||||
|
---
|
||||||
|
Brother label printer plugin for InvenTree
|
||||||
|
|
||||||
|
A label printing plugin for [InvenTree](https://inventree.org), which provides support for the [Brother label printers](https://www.brother.com.au/en/products/all-labellers/labellers).
|
||||||
|
|
||||||
|
This plugin supports printing to *some* Brother label printers with network (wired or WiFi) support. Refer to the [brother_ql docs](https://github.com/pklaus/brother_ql/blob/master/brother_ql/models.py) for a list of label printers which are directly supported.
|
||||||
|
|
||||||
|
## Installation
|
||||||
|
|
||||||
|
Install this plugin manually as follows:
|
||||||
|
|
||||||
|
```
|
||||||
|
pip install inventree-brother-plugin
|
||||||
|
```
|
||||||
|
|
||||||
|
Or, add to your `plugins.txt` file to install automatically using the `invoke install` command:
|
||||||
|
|
||||||
|
```
|
||||||
|
inventree-brother-plugin
|
||||||
|
```
|
46
_repo/inventree-cups-plugin.md
Normal file
46
_repo/inventree-cups-plugin.md
Normal file
@ -0,0 +1,46 @@
|
|||||||
|
---
|
||||||
|
name: inventree-cups-plugin
|
||||||
|
author: wolflu05
|
||||||
|
license: MIT
|
||||||
|
open_source: true
|
||||||
|
stable: true
|
||||||
|
maintained: true
|
||||||
|
pypi: false
|
||||||
|
package_name:
|
||||||
|
github: https://github.com/wolflu05/inventree-cups-plugin
|
||||||
|
gitlab:
|
||||||
|
source:
|
||||||
|
issue_tracker: https://github.com/wolflu05/inventree-cups-plugin/issues
|
||||||
|
website:
|
||||||
|
categories: Printer
|
||||||
|
tags: Label Printer CUPS DYMO
|
||||||
|
---
|
||||||
|
Label printing plugin for generic cups printers
|
||||||
|
|
||||||
|
A label printing plugin for [InvenTree](https://inventree.org), which provides support for [Cups label printing servers](https://www.cups.org). If your printer is not cups compatible, you can setup a cups printing server. This [article](https://nerdig.es/labelwriter-im-netz-teil1/) describes how to setup a cups printing server for the DYMO LabelWriter 450 Duo.
|
||||||
|
|
||||||
|
## Installation
|
||||||
|
|
||||||
|
> :warning: This plugin needs `cups-devel` installed to install its dependencies. You can read more about the requirements at [`pycups`](https://github.com/OpenPrinting/pycups). If you're using `apt` as a package manager run `apt install libcups2-dev` before.
|
||||||
|
|
||||||
|
Install this plugin as follows:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
pip install git+https://github.com/wolflu05/inventree-cups-plugin
|
||||||
|
```
|
||||||
|
|
||||||
|
Or, add to your `plugins.txt` file:
|
||||||
|
|
||||||
|
```txt
|
||||||
|
git+https://github.com/wolflu05/inventree-cups-plugin
|
||||||
|
```
|
||||||
|
|
||||||
|
## Configuration Options
|
||||||
|
|
||||||
|
| Name| Description| Example |
|
||||||
|
| --- | --- | --- |
|
||||||
|
| Server | IP/Hostname to connect to the cups server | `192.168.1.5` |
|
||||||
|
| Port | Port to connect to the cups server | `631` |
|
||||||
|
| Benutzer | User to connect to the cups server | *can also be empty* |
|
||||||
|
| Passwort | Password to connect to the cups server | *can also be empty* |
|
||||||
|
| Printer | Printer from cups server, can be selected if valid connection options are saved in | `myprinter` |
|
54
_repo/inventree-zapier.md
Normal file
54
_repo/inventree-zapier.md
Normal file
@ -0,0 +1,54 @@
|
|||||||
|
---
|
||||||
|
name: inventree-zapier
|
||||||
|
author: matmair
|
||||||
|
license: MIT
|
||||||
|
open_source: true
|
||||||
|
stable: False
|
||||||
|
maintained: true
|
||||||
|
pypi: true
|
||||||
|
package_name: inventree-zapier
|
||||||
|
github: https://github.com/matmair/inventree-zapier
|
||||||
|
gitlab:
|
||||||
|
source:
|
||||||
|
issue_tracker: https://github.com/matmair/inventree-zapier/issues
|
||||||
|
website: https://mjmair.com
|
||||||
|
categories: Event
|
||||||
|
tags: Zapier
|
||||||
|
---
|
||||||
|
Integrate Zapier into InvenTree
|
||||||
|
|
||||||
|
## Setup
|
||||||
|
|
||||||
|
1. Install
|
||||||
|
Install this plugin as follows **in the enviroment of your InvenTree instance**:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
pip install inventree-zapier
|
||||||
|
```
|
||||||
|
|
||||||
|
Or, add to your `plugins.txt` file:
|
||||||
|
|
||||||
|
```txt
|
||||||
|
inventree-zapier
|
||||||
|
```
|
||||||
|
|
||||||
|
2. Enable
|
||||||
|
Enable the plugin in the plugin settings. You need to be signed in as a superuser for this.
|
||||||
|
**The server will erstart if you enable the plugin**
|
||||||
|
|
||||||
|
3. Migrate
|
||||||
|
Access your instances python enviroment and run
|
||||||
|
|
||||||
|
```bash
|
||||||
|
inv migrate
|
||||||
|
```
|
||||||
|
|
||||||
|
4. Configure
|
||||||
|
Create an API-token in the admin interface and add set up the zapier integration in Zapier.com itself.
|
||||||
|
|
||||||
|
## License
|
||||||
|
This project is licensed as MIT. Copy and do what you want - maybe tag your new plugin so others can find it. The more the merrier.
|
||||||
|
|
||||||
|
## State of the Code
|
||||||
|
This is currently a PoC / 'beta' - at least till the Zapier App is published. Please feel free to file FRs, issues or just ideas.
|
||||||
|
|
153
_repo/inventree-zebra-plugin.md
Normal file
153
_repo/inventree-zebra-plugin.md
Normal file
@ -0,0 +1,153 @@
|
|||||||
|
---
|
||||||
|
name: inventree-zebra-plugin
|
||||||
|
author: SergeoLacruz
|
||||||
|
license: MIT
|
||||||
|
open_source: true
|
||||||
|
stable: true
|
||||||
|
maintained: true
|
||||||
|
pypi: false
|
||||||
|
package_name:
|
||||||
|
github: https://github.com/SergeoLacruz/inventree-zebra-plugin
|
||||||
|
gitlab:
|
||||||
|
source:
|
||||||
|
issue_tracker: https://github.com/SergeoLacruz/inventree-zebra-plugin/issues
|
||||||
|
website:
|
||||||
|
categories: Printer
|
||||||
|
tags: Label Printer Zebra ZPL
|
||||||
|
---
|
||||||
|
Zebra Label Printer Plugin for Inventree
|
||||||
|
|
||||||
|
This is a label printing plugin for [InvenTree](https://inventree.org), which provides support for Zebra Label printers .
|
||||||
|
It supports printing to just GK420T with one label size (50x30) so far. So it is very simple. It uses the zpl library to
|
||||||
|
convert the png data provided by InvenTree to Zebras bitmap format.
|
||||||
|
|
||||||
|
It can output the print data either to a local printer connected to the computer via USB or to a network printer
|
||||||
|
with an IP address. The output can be configured in the InvenTree plugin user interface. So the source code is
|
||||||
|
a good example for this.
|
||||||
|
|
||||||
|
Error handling is very basic.
|
||||||
|
|
||||||
|
## Installation
|
||||||
|
|
||||||
|
Install this plugin using pip with the following command::
|
||||||
|
|
||||||
|
```
|
||||||
|
pip install git+https://github.com/SergeoLacruz/inventree-zebra-plugin
|
||||||
|
```
|
||||||
|
|
||||||
|
## Configuration Options
|
||||||
|
### Printer Interface
|
||||||
|
Here you can chose between Local printer or network printer. Default value is a local printer.
|
||||||
|
|
||||||
|
### IP address
|
||||||
|
In case you use an IP printer set the IPv4 address here.
|
||||||
|
|
||||||
|
### Port
|
||||||
|
In case you use an IP printer set the port number here. The default port number is 9100.
|
||||||
|
|
||||||
|
### Local Device
|
||||||
|
In case of a local printer set the device here. The plugin actually puts the data directly to the
|
||||||
|
device libe /dev/usb/lp0. No printer spooler is involved so far.
|
||||||
|
|
||||||
|
## How it works
|
||||||
|
First import all the stuff you need. Here we use the translation mechanism from django for multi language support.
|
||||||
|
The import the InvenTree libs and everything you need for plugin. Here we have zpl for the Zebra bitmaps and socket
|
||||||
|
for the IP connection to the printer.
|
||||||
|
|
||||||
|
The next part is this:
|
||||||
|
|
||||||
|
```python
|
||||||
|
class ZebraLabelPlugin(LabelPrintingMixin, SettingsMixin, IntegrationPluginBase):
|
||||||
|
|
||||||
|
AUTHOR = "Michael Buchmann"
|
||||||
|
DESCRIPTION = "Label printing plugin for Zebra printers"
|
||||||
|
VERSION = ZEBRA_PLUGIN_VERSION
|
||||||
|
NAME = "Zebra"
|
||||||
|
SLUG = "zebra"
|
||||||
|
TITLE = "Zebra Label Printer"
|
||||||
|
```
|
||||||
|
|
||||||
|
The name of the class can be freely chosen. You reference to it in the entry_points section of the setup.py file.
|
||||||
|
The parameters need to be like in the example. Then there is the description block. The keywords are fixed and
|
||||||
|
need to be like that. The values are found in the UI as shown in the pictures below.
|
||||||
|
|
||||||
|

|
||||||
|

|
||||||
|
|
||||||
|
|
||||||
|
Then we add the configuration parameters.
|
||||||
|
```python
|
||||||
|
SETTINGS = {
|
||||||
|
'CONNECTION': {
|
||||||
|
'name': _('Printer Interface'),
|
||||||
|
'description': _('Select local or network printer'),
|
||||||
|
'choices': [('local','Local printer e.g. USB'),('network','Network printer with IP address')],
|
||||||
|
'default': 'local',
|
||||||
|
},
|
||||||
|
'PORT': {
|
||||||
|
'name': _('Port'),
|
||||||
|
'description': _('Network port in case of network printer'),
|
||||||
|
'default': '9100',
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
```
|
||||||
|
|
||||||
|
We need to define a dict with the name SETTINGS. Please be aware the keys need to be in all CAPITAL letters like CONNECTION.
|
||||||
|
Simple parameters are just text strings like the port. We can set a default. The name and description shows up in the UI.
|
||||||
|
Instead of ta simple test we can also use choices. The first string like "local" it the key you use in the code. The second
|
||||||
|
one is the description in the UI.
|
||||||
|
After that we need to define a function:
|
||||||
|
|
||||||
|
```python
|
||||||
|
def print_label(self, **kwargs){
|
||||||
|
```
|
||||||
|
|
||||||
|
The kwargs is a dict with the following keys:
|
||||||
|
|
||||||
|
- pdf_data
|
||||||
|
- user
|
||||||
|
- filename
|
||||||
|
- label_instance
|
||||||
|
- width
|
||||||
|
- height
|
||||||
|
- png_file
|
||||||
|
|
||||||
|
For the Zebra printer we use the png_file. This is a PIL (python Pillow) object with the graphic of the label in PNG format.
|
||||||
|
The PIL object is a greyscale image. Because the printer can just print pure BW we convert this to a BW picture.
|
||||||
|
|
||||||
|
```python
|
||||||
|
fn = lambda x : 255 if x > Threshold else 0
|
||||||
|
label_image = label_image.convert('L').point(fn, mode='1')
|
||||||
|
```
|
||||||
|
|
||||||
|
The threshold can by modified by a plugin parameter. 200 is a good starting value. This trick gives much better prints.
|
||||||
|
We can put the result this directly into the zpl library.
|
||||||
|
|
||||||
|
```python
|
||||||
|
l = zpl.Label(50,30,8)
|
||||||
|
l.origin(0, 0)
|
||||||
|
l.write_graphic(label_image, 50)
|
||||||
|
l.endorigin()
|
||||||
|
```
|
||||||
|
|
||||||
|
50,30 is the size of the label in millimeters. The third parameter is the resolution of the printer in
|
||||||
|
dots per mm. As the Zebra printer has 200dpi we put an eight here. write_graphic converts the pillow data
|
||||||
|
to zpl. 50 is the with of the image in mm.
|
||||||
|
|
||||||
|
The plugin was tested with a label of 50x30 mm defined using css and html in InvenTree as shown below. The DPI scaling
|
||||||
|
can be chosen in the InvenTree settings. 400 is a good value because it is just double of the printers
|
||||||
|
resolution. If you save the pillow data to a png file you get a size of 788x473 which fits well to that data.
|
||||||
|
|
||||||
|
```
|
||||||
|
<style>
|
||||||
|
@page {
|
||||||
|
width: 50mm;
|
||||||
|
height: 30mm;
|
||||||
|
padding: 0mm;
|
||||||
|
margin: 0px 0px 0px 0px;
|
||||||
|
background-color: white;
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
The rest of the code is just output to the printer on different interfaces.
|
@ -19,8 +19,8 @@ A [bare metal installation guide](https://docs.inventree.org/en/latest/start/int
|
|||||||
|
|
||||||
### Cloud
|
### Cloud
|
||||||
|
|
||||||
A member of the team provides a [1-click app for InvenTree](https://marketplace.digitalocean.com/apps/inventree?refcode=d6172576d014&action=deploy) on the DigitalOcean marketplace.
|
A member of the team provides a [1-click app for InvenTree](https://marketplace.digitalocean.com/apps/inventree?refcode=d6172576d014) on the DigitalOcean marketplace.
|
||||||
|
|
||||||
### Other Options
|
### Other Options
|
||||||
|
|
||||||
The core InvenTree server is built using the widely used python-based framework [Django](https://djangoproject.com/). Therefore there are deployment methods for nearly all plattforms and architectures. If you want to read more about InvenTree's structure and a typical installation read the [architecture overview](../contribute/code/architecture).
|
The core InvenTree server is built using the widely used python-based framework [Django](https://djangoproject.com/). Therefore there are deployment methods for nearly all plattforms and architectures.
|
||||||
|
@ -25,7 +25,7 @@ The InvenTree app can be downloaded from either the Android or Apple app stores,
|
|||||||
|
|
||||||
<span class='fab fa-android'></span> [Android Play Store](https://play.google.com/store/apps/details?id=inventree.inventree_app).
|
<span class='fab fa-android'></span> [Android Play Store](https://play.google.com/store/apps/details?id=inventree.inventree_app).
|
||||||
|
|
||||||
<span class='fab fa-apple'></span> [Apple App Store](https://apps.apple.com/au/app/inventree/id1581731101#?platform=iphone)
|
<span class='fab fa-apple'></span> [Apple App Store](https://apps.apple.com/au/app/inventree/id1581731101?platform=iphone)
|
||||||
|
|
||||||
### Documentation
|
### Documentation
|
||||||
|
|
||||||
|
@ -8,4 +8,4 @@ InvenTree is designeds to be part of a larger system of tools to support both ho
|
|||||||
- [API](api)
|
- [API](api)
|
||||||
- [Integrate](integrate) into other tools
|
- [Integrate](integrate) into other tools
|
||||||
- PK2InvenTree for [migrating from PartKeepr to InvenTreen](https://github.com/rgilham/PK2InvenTree)
|
- PK2InvenTree for [migrating from PartKeepr to InvenTreen](https://github.com/rgilham/PK2InvenTree)
|
||||||
- Python [package](https://docs.inventree.org/en/latest/extend/python/)
|
- Python [package](https://docs.inventree.org/en/latest/api/python/python/)
|
||||||
|
@ -12,7 +12,7 @@ Private questions (via DM, email, etc.) are generally not answered, use the publ
|
|||||||
If you require a custom feature you can either:
|
If you require a custom feature you can either:
|
||||||
- Suggest the feature on the issue tracker as a [Feature Request](https://github.com/inventree/InvenTree/issues/new?template=feature_request.yaml)
|
- Suggest the feature on the issue tracker as a [Feature Request](https://github.com/inventree/InvenTree/issues/new?template=feature_request.yaml)
|
||||||
- Implement the feature yourself, and contribute back to the project. InvenTree developers will happily help you work through any issues.
|
- Implement the feature yourself, and contribute back to the project. InvenTree developers will happily help you work through any issues.
|
||||||
- Create a [plugin](/extend/plugin/index.md)
|
- Create a [plugin]({% link extend/plugin/index.md %})
|
||||||
- Request a paid customisation
|
- Request a paid customisation
|
||||||
|
|
||||||
## Paid Customisation / Support
|
## Paid Customisation / Support
|
||||||
|
10
use/maker.md
10
use/maker.md
@ -3,14 +3,4 @@ layout: user
|
|||||||
title: For Maker
|
title: For Maker
|
||||||
title_2: for Maker
|
title_2: for Maker
|
||||||
data: for_maker
|
data: for_maker
|
||||||
long_text: |
|
|
||||||
lorem ipsum place for
|
|
||||||
multiline inteligent text
|
|
||||||
buttons:
|
|
||||||
- text: lorem ipsum primary
|
|
||||||
primary: true
|
|
||||||
link: http://example.com
|
|
||||||
- text: lorem ipsum
|
|
||||||
link:
|
|
||||||
site: plugn-link
|
|
||||||
---
|
---
|
||||||
|
Loading…
x
Reference in New Issue
Block a user