zesty.io

Product

Use Cases

Integrations

Learn

How to Create one_to_one Relationships

Guide on how to create a one_to_one relationship field in Zesty.io

Overview

An easy way to think of one-to-one relationships in Zesty.io is to think of radio buttons.

radiobuttons

As opposed to something like check boxes where you can select many options for one question, with radio buttons you can only select one option for each question. One-to-one relationships in Zesty.io work exactly in this fashion. Lets take a blog for example.

When you create a blog in Zesty.io a one-to-one relationship between an article and an author is created.

relationship:

This has to match the name of the data set/template set/page set. Once the name is the same, this will dynamically set the dropdown field with the name of authors.

relationship_field:

This is what the field will be called inside of the content page.

required:

This makes the field required to be submitted.

list:

This adds the field to the table-view.

In Manager App

#

In the config tab, here is what the above code creates:

configexample

Now if we were to create an author:

author

Each article will have a dropdown populated by the various authors you have saved in your dataset. Each article will have a required field of selecting one author, which is the core of the one-to-one relationship. Now whenever a new author is created, it will automatically be available in the article dropdown when selecting an author.

authorarticle

Start Here

We will listen to your needs and walk you through how Zesty can help your team.

Connect with Content Experts

Book a free 15-minute consultation with a content expert. Discuss your application, pain points and requirements. Understand how Zesty's lower total cost of ownership, features, functionality can elevate your business by creating extraordinary digital experiences.

Trusted By

zesty customer logo Sonyzesty customer logo Rocket Leaguezesty customer logo Singlifezesty customer logo Acornszesty customer logo Phoenix Sunszesty customer logo Wattpadzesty customer logo Corner Shopzesty customer logo Bjs

Enter your details to connect with a Content Expert

First Name

Last Name

Email

Phone (optional)

Company

Please tell us about your project (optional)

G2 MOMENTUM LEADER

zesty customer logo zesty customer logo zesty customer logo zesty customer logo