Table of Contents

Class SelectField<T>

Namespace
AbanoubNassem.Trinity.Fields
Assembly
AbanoubNassem.Trinity.dll

Represents a select input field.

public class SelectField<T> : TrinityField<SelectField<T>, T>, ITrinityComponent, ITrinityField, IFormComponent

Type Parameters

T

The type of the field's value.

Inheritance
SelectField<T>
Implements
Derived
Inherited Members

Constructors

SelectField(string)

public SelectField(string columnName)

Parameters

columnName string

Properties

ComponentName

The component name in the front-end side.

public override string ComponentName { get; }

Property Value

string

Options

Gets or sets the options for the select field.

public List<KeyValuePair<string, string>>? Options { get; protected set; }

Property Value

List<KeyValuePair<string, string>>

Searchable

A value indicating whether this field is searchable.

public bool Searchable { get; protected set; }

Property Value

bool

Methods

SetAsSearchable(bool)

Sets this field as searchable .

public virtual SelectField<T> SetAsSearchable(bool searchable = true)

Parameters

searchable bool

A value indicating whether this field is searchable.

Returns

SelectField<T>

SetOptions(List<KeyValuePair<string, string>>)

Sets the options for the select field.

public SelectField<T> SetOptions(List<KeyValuePair<string, string>> options)

Parameters

options List<KeyValuePair<string, string>>

The options to be set.

Returns

SelectField<T>

The current instance of SelectField<T> field.