py300 is a simple CLI python app based on click and richto retreive information from Sage300.
Install packages with: pip -r requirements.txt
pip install -r requirements.txt
sudo pacman -S unixodbc freetds
Create or edit /etc/odbcinst.ini
and /etc/odbc.ini
with the following content:
- /etc/odbcinst.ini
[FreeTDS]
Description = FreeTDS
Driver = /usr/lib/libtdsodbc.so.0
- /etc/odbc.ini
[SQLServer]
Driver = FreeTDS
Description = Connection to SQL Server
Trace = No
Server = IP_ADDRESS
Port = 1433
TDS version = VERSION
Database = DB_NAME
Make sure to change IP_ADDRESS
, VERSION
and DB_NAME
.
isql -v SQLServer <user> <password>
Create a setup file with the metadata inforamtion including the required packages:
name='py300',
version='0.0.1',
description='Simple CLI app to interac with Sage300',
author='Jose Perez (a.k.a Lepepe)',
author_email='[email protected]',
url='https://github.com/lepepe/py300',
license='MIT',
packages=find_packages(),
install_requires=[
'click',
'pandas',
'numpy',
'pyodbc',
'rich',
'inventorize3'
],
entry_points={
'console_scripts': [
'py300=main:cli'
]
}
Then run sudo pip install --editable .
This "module" (command) can filters customers or retreive customer information such as sales history by years, credit status and receivables.
Similar to the customers inventory command can filter items and display item information such as sales by years, availabily by locations; it also calculate the ranking using the Pareto principle and the coverage in month based on the sales for the last 12 periods (globally and by locations).
TODO
- Ranking summary
- Sales forecasting
- Backorder
- General ledger (Financial Statements)
- Dashboard