Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update docs to show order matters for dropdown values and schema fields #103

Merged
merged 1 commit into from
Feb 9, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions docs/reference/dropdowns.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@ class Toppings(BaseDropdown):
__allowed_values__ = ["Pepperoni", "Mushroom", "Onion", "Sausage", "Bacon"]
```

!!! tip
Liminal automatically detects the order of your dropdown values. To change the order of how the values appear in Benchling, define the dropdown values in the desired sequence.

### Parameters

- **benchling_name: str**
Expand Down
5 changes: 4 additions & 1 deletion docs/reference/entity-schemas.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
Below is an example of a custom entity schema defined in code. All Liminal entity schema classes inherit from Liminal's [BaseModel](https://github.com/dynotx/liminal-orm/blob/main/liminal/orm/base_model.py) and uses [SQLAlchemy](https://www.sqlalchemy.org/) behind the scenes to create an ORM. Liminal provides base classes and clear abstractions to provide a standardized way to define entity schemas in code. However, you are still able to use raw SQLAlchemy to interact with the schemas when necessary.

The properties defined in the `SchemaProperties` object and `Column` objects
align with the properties shown on the Benchling website. This is how Liminal defines your Benchling entity schema in code. Any of these properties
correspond with the properties shown on the Benchling website. This is how Liminal defines your Benchling entity schema in code. Any of these properties
can be manipulated to change the definition of the entity schema. Updates to the schema or the addition/archival of schemas are automatically
detected by Liminal's migration service, which is run using the `liminal autogenerate ...` command. Refer to the [First Migration](../getting-started/first-migration.md) page to run your first migration.

Expand Down Expand Up @@ -123,6 +123,9 @@ All Liminal entity schema classes must inherit from one of the mixins in the [mi

## Column: [class](https://github.com/dynotx/liminal-orm/blob/main/liminal/orm/column.py)

!!! tip
Liminal also detects the ordering of your fields. Define columns on different lines in your schema class to change the ordering of the fields on the Benchling entity schema.

!!! warning
If warehouse access is not enabled on your tenant, you will be unable to update the warehouse name for fields.

Expand Down