Skip to main content

Versatile tool for browsing OpenERP data

Project description

Download the latest release from PyPI:

pip install -U erppeek

Overview

ERPpeek carries three completing uses:

  1. with command line arguments

  2. as an interactive shell

  3. as a client library

Key features:

  • single executable erppeek.py, no external dependency

  • wrappers for search+read, for data model introspection, etc…

  • simpler syntax for domain and fields

  • full API accessible on the Client object for OpenERP 5.0 through 6.1

  • the module can be imported and used as a library: from erppeek import Client

  • supports Python 3 and Python 2 (>= 2.5)

1. Command line arguments

See the introduction on this page or:

erppeek --help

2. Interactive use

Edit erppeek.ini and declare the environment(s):

[DEFAULT]
host = localhost
port = 8069
database = openerp
username = admin

[demo]
username = demo
password = demo

Connect to the OpenERP server:

erppeek --list
erppeek --env demo

This is a sample session:

demo >>> model('res.users')
<Model 'res.users'>
demo >>> client.ResUsers is model('res.users')
True
demo >>> client.ResUsers.count()
4
demo >>> read('ir.cron', ['active = False'], 'active function')
[{'active': False, 'function': 'run_mail_scheduler', 'id': 1},
 {'active': False, 'function': 'run_bdr_scheduler', 'id': 2},
 {'active': False, 'function': 'scheduled_fetch_new_scans', 'id': 9}]
demo >>>
demo >>> client.modules('delivery')
{'uninstalled': ['delivery', 'sale_delivery_report']}
demo >>> client.upgrade('base')
1 module(s) selected
42 module(s) to process:
  to upgrade    account
  to upgrade    account_chart
  to upgrade    account_tax_include
  to upgrade    base
  ...
demo >>>

Main commands:

search(obj, domain)
search(obj, domain, offset=0, limit=None, order=None)
                                # Return a list of IDs
count(obj, domain)              # Count the matching objects

read(obj, ids, fields=None)
read(obj, domain, fields=None)
read(obj, domain, fields=None, offset=0, limit=None, order=None)
                                # Return values for the fields

models(name)                    # List models matching pattern
model(name)                     # Return a Model instance
keys(obj)                       # List field names of the model
fields(obj, names=None)         # Return details for the fields
field(obj, name)                # Return details for the field
access(obj, mode='read')        # Check access on the model

do(obj, method, *params)        # Generic 'object.execute'
wizard(name)                    # Return the 'id' of a new wizard
wizard(name_or_id, datas=None, action='init')
                                # Generic 'wizard.execute'
exec_workflow(obj, signal, id)  # Trigger workflow signal

client                          # Client object, connected
client.login(user)              # Login with another user
client.connect(env)             # Connect to another env.
client.modules(name)            # List modules matching pattern
client.upgrade(module1, module2, ...)
                                # Upgrade the modules

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ERPpeek-0.10.tar.gz (28.3 kB view details)

Uploaded Source

File details

Details for the file ERPpeek-0.10.tar.gz.

File metadata

  • Download URL: ERPpeek-0.10.tar.gz
  • Upload date:
  • Size: 28.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for ERPpeek-0.10.tar.gz
Algorithm Hash digest
SHA256 0c503a382285716a99f8fb5c410ae740548ed76d113252fca9bce96337f1a8ea
MD5 c48c5b467e4d7bd1c21ec7064df6ab4f
BLAKE2b-256 da1dfaf6bf44147b9bed406164eed44712c925fccbaecaf5a81c36d1a7ddcb2a

See more details on using hashes here.

Provenance

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page