Skip to content

Commit

Permalink
Merge pull request #20 from Jack-Dane/supported_fields_documentation
Browse files Browse the repository at this point in the history
Add Documentation for some field types.
  • Loading branch information
Jack-Dane authored Oct 6, 2023
2 parents 7b05525 + a55d6ab commit afe7132
Show file tree
Hide file tree
Showing 7 changed files with 52 additions and 0 deletions.
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,11 @@ This plugin can be tested within a [docker environment](https://hub.docker.com/_

[Video Tutorial](https://www.youtube.com/watch?v=xhAvrEaBXAA)


## Examples

See [examples](examples) for examples of supported Odoo field types and how to use them.

## Security

* API keys are encrypted in the system using Sodium symmetric key encryption.
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added examples/assets/odoo_address_type_selection.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added examples/assets/odoo_parent_company_many2one.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
28 changes: 28 additions & 0 deletions examples/relational_fields.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# Relational Field Examples

The Record ID field is often referred to `id` on base models. You can get the ID from a record because it will
be one of the parameters in the URL (as `?id=<id>`) when viewing the record.

## Many2One

This example will show you how to choose a company for a contact record. This is an example of the companies in the Odoo instance.

![Odoo Parent Company Many2One](assets/odoo_parent_company_many2one.png)

CF7 Form:

```
[select company "My Company|1" "My Company 2|13"]
```

Form Mapping Record:

![Odoo Parent Company Form Mapping](assets/odoo_parent_company_form_mapping.png)

# One2Many

Not supported currently

# Many2Many

Not supported currently
19 changes: 19 additions & 0 deletions examples/simple_fields.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# Simple Field Examples

Most fields are self-explanatory, but this section details some that might not be so obvious.

## Selection

Example selection data is the `address_type` field on the `res.partner` (contact) model:

![Odoo Address Type Selection](assets/odoo_address_type_selection.png)

CF7 Form:

```
[select address-type "Contact|contact" "Invoice Address|invoice" "Delivery Address|delivery" "Private Address|private" "Other Address|other"]
```

Form Mapping Record:

![Odoo Address Type Form Mapping](assets/odoo_address_type_form_mapping.png)

0 comments on commit afe7132

Please sign in to comment.