定制 0k/php-oe-json 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

0k/php-oe-json

Composer 安装命令:

composer require 0k/php-oe-json

包简介

OpenERP Json query

关键字:

README 文档

README

Latest Stable Version Total Downloads Latest Unstable Version License

Modest PHP class to manage OpenERP Json query.

Code maturity

Early working alpha. Comments welcome. Although it was tested against OpenERP version 6.1 and 7.0.

Features

  • Simple way to add new json-rpc entry points
  • Quite easy to get started (see Usage section)
  • Ability to resume an open session (and thus login in openerp) with a saved session_id and HTTP cookie_id (without $login and $password)

Usage

sample PHP code:

<?php

require_once 'openerp.php';

$oe = new PhpOeJson\OpenERP("http://localhost:8069", "test_json");
$oe->login("admin", "xxxxxx");

echo "Logged in (session id: " . $oe->session_id . ")";

$partners = $oe->read(array(
  'model' => 'res.partner',
  'fields' => array('name', 'city'),
));

echo "<ul>";
foreach($partners['records'] as $partner) {
   echo "    <li>" . $partner["name"] . " - " . $partner["city"] . "</li>\n";
}
echo "</ul>";

?>

This actual code (with small modifications) is provided in the example-project directory which is a composer-ready package (more about composer, how to get composer command). This means you can run composer install on the root of the example-project directory to install dependencies, and you'll only have to edit settings.php and set $url, $db and the $login, $password to test it with your installation.

Please note that this is a very thin layer above Tivoka which is a JSON-RPC PHP lib.

统计信息

  • 总下载量: 1.78k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 12
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 12
  • Watchers: 5
  • Forks: 23
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2014-01-28

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固