2017 © Pedro Peláez
 

library openerp-api

PHP API for OpenERP

image

simbigo/openerp-api

PHP API for OpenERP

  • Thursday, July 3, 2014
  • by simbigo
  • Repository
  • 0 Watchers
  • 0 Stars
  • 48 Installations
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 6 Versions
  • 0 % Grown

The README.md

OpenERP API

How to use:

For begin you must call login method., (*1)

#!php

<?php
use Simbigo\OpenERP\OpenERP;
$erp = new OpenERP('http://127.0.0.1:8069', 'utf-8');
$erp->login('db_test', 'myLogin', 'myPassword'); // return user id, if success

Create new record

#!php

<?php
$erp->login('db_test', 'myLogin', 'myPassword');
$partner = ['name' => 'John', 'email' => 'john@example.com'];
$erp->create('res.partner', $partner); // return record ID, if it created

Search records

#!php

<?php
$erp->login('db_test', 'myLogin', 'myPassword');
$offset = 0; // default
$limit = 1000; // default
$criteria= [['name', '=', 'John'], ['email', '=', 'john@example.com']];
$erp->search('res.partner', $criteria, $offset, $limit); // return ID array

Read records

#!php

<?php
$erp->login('db_test', 'myLogin', 'myPassword');
$readColumns = ['name', 'email']; // default [] equal 'SELECT * ...'
$ids = [30, 31];
$erp->read('res.partner', $ids, $readColumns); // return array of records

Update records

#!php

<?php
$erp->login('db_test', 'myLogin', 'myPassword');
$columns = ['name' => 'Peter', 'email' => 'peter@example.com'];
$ids = [30, 31];
$erp->write('res.partner', $ids, $columns); // return true

Delete records

#!php

<?php
$erp->login('db_test', 'myLogin', 'myPassword');
$ids = [30, 31];
$erp->unlink('res.partner', $ids); // return true

The Versions

03/07 2014

dev-master

9999999-dev

PHP API for OpenERP

  Sources   Download

MIT

The Requires

  • php >=5.4.0

 

by Andrey Bondarev

03/07 2014

1.0.4

1.0.4.0

PHP API for OpenERP

  Sources   Download

MIT

The Requires

  • php >=5.4.0

 

by Andrey Bondarev

23/06 2014

1.0.3

1.0.3.0

PHP API for OpenERP

  Sources   Download

MIT

The Requires

  • php >=5.4.0

 

by Andrey Bondarev

23/06 2014

1.0.2

1.0.2.0

PHP API for OpenERP

  Sources   Download

The Requires

  • php >=5.4.0

 

by Andrey Bondarev

23/06 2014

1.0.1

1.0.1.0

PHP API for OpenERP

  Sources   Download

The Requires

  • php >=5.4.0

 

by Andrey Bondarev

23/06 2014

1.0

1.0.0.0

PHP API for OpenERP

  Sources   Download

The Requires

  • php >=5.4.0

 

by Andrey Bondarev