1
0
mirror of https://github.com/pocketbase/pocketbase.git synced 2025-12-01 01:16:08 +02:00

added additional godoc and updated the OAuth2 form to use the same created record pointer

This commit is contained in:
Gani Georgiev
2024-10-24 08:37:22 +03:00
parent c41a4dfc07
commit 0b7741f1f7
28 changed files with 4020 additions and 3750 deletions

View File

@@ -35,6 +35,8 @@ var (
//
// If MaxSelect is > 1, then the field value is expected to be a subset of Values slice.
//
// The respective zero record field value is either empty string (single) or empty string slice (multiple).
//
// ---
//
// The following additional setter keys are available:
@@ -51,11 +53,23 @@ var (
//
// record.Set("roles-", "old1") // []string{"old2"}
type SelectField struct {
Id string `form:"id" json:"id"`
Name string `form:"name" json:"name"`
System bool `form:"system" json:"system"`
Hidden bool `form:"hidden" json:"hidden"`
Presentable bool `form:"presentable" json:"presentable"`
// Name (required) is the unique name of the field.
Name string `form:"name" json:"name"`
// Id is the unique stable field identifier.
//
// It is automatically generated from the name when adding to a collection FieldsList.
Id string `form:"id" json:"id"`
// System prevents the renaming and removal of the field.
System bool `form:"system" json:"system"`
// Hidden hides the field from the API response.
Hidden bool `form:"hidden" json:"hidden"`
// Presentable hints the Dashboard UI to use the underlying
// field record value in the relation preview label.
Presentable bool `form:"presentable" json:"presentable"`
// ---