Versions in this module Expand all Collapse all v0 v0.1.1 Feb 27, 2020 Changes in this version + func FloatField(rec interface{}, name string) (float64, error) + func IntField(rec interface{}, name string) (int, error) + func One2manyField(rec interface{}, name string) ([]int, error) + func StringField(rec interface{}, name string) (string, error) + func Val2Float(f interface{}) (float64, bool) + func Val2Int(f interface{}) (int, bool) + func Val2One2many(f interface{}) []int + func Val2String(f interface{}) (string, bool) + type AuthError struct + Code int + Data *AuthErrorData + Message string + type AuthErrorData struct + Arguments []interface{} + Debug OString + ExceptionType OString + Message OString + Name OString + type AuthParams struct + DB string + Login string + Password string + type AuthRequest struct + ID string + JSONRPC string + Method string + Params AuthParams + type AuthResponse struct + Error *AuthError + ID OString + JSONRPC OString + Result *AuthResult + type AuthResult struct + CompanyID OInt + DB OString + IsAdmin bool + IsSystem bool + Name OString + PartnerDisplayName OString + PartnerID OInt + ServerVersion OString + ServerVersionInfo []interface{} + UID OInt + UserContext map[string]interface{} + UserName OString + WebBaseURL OString + type Client struct + Auth *AuthResponse + Context map[string]interface{} + func ClientConnect(serverName string) (*Client, error) + func Connect(baseURL, db, login, password string) (*Client, error) + func (client *Client) Call(model, method string, args []interface{}, kwargs map[string]interface{}) (interface{}, error) + func (client *Client) Create(model string, values map[string]interface{}) (int, error) + func (client *Client) Delete(model string, ids []int) (bool, error) + func (client *Client) GetBaseURL() string + func (client *Client) GetServerVersion() string + func (client *Client) IsValid() bool + func (client *Client) Read(model string, ids []int, fields []string) ([]interface{}, error) + func (client *Client) Search(model string, domain []interface{}) ([]int, error) + func (client *Client) SearchRead(model string, domain []interface{}, fields []string) ([]interface{}, error) + func (client *Client) WithContext(ctx map[string]interface{}) *Client + func (client *Client) Write(model string, ids []int, values map[string]interface{}) (bool, error) + type List []interface + type Many2oneFK struct + ID int + Name string + func Many2oneField(rec interface{}, name string) (*Many2oneFK, error) + func Val2Many2one(f interface{}) *Many2oneFK + type ODateTime time.Time + func (t *ODateTime) UnmarshalJSON(b []byte) error + type OFloat float64 + func (f *OFloat) UnmarshalJSON(b []byte) error + type OInt int + func (i *OInt) UnmarshalJSON(b []byte) error + type OMany2one struct + ID int + Name string + func (m *OMany2one) UnmarshalJSON(b []byte) error + type OString string + func (s *OString) UnmarshalJSON(b []byte) error + type OdooConfig struct + Database string + Login string + Password string + ServerAddress string + func LoadOdooConfig(serverName string) (*OdooConfig, error) + func (conf *OdooConfig) CreateOdooClient() (*Client, error) + type RPCError struct + Code OInt + Data RPCErrorData + Message OString + type RPCErrorData struct + Arguments []interface{} + Debug OString + ExceptionType OString + Message OString + Name OString + type RPCResponse struct + Error *RPCError + ID OString + JSONRPC OString + Result interface{}