Caisis Input Controls&action it

From CaisisWiki

(Difference between revisions)
Jump to: navigation, search
(Interfaces)
(Base Properties)
Line 31: Line 31:
*CaisisComboBox
*CaisisComboBox
-
=== Base Properties ===
+
=== Proprietà di base ===
----
----
-
By default, all controls that implement the ICaisisInputControl interface, have these properties exposed to be set and retrieved by user code. These properties provide easy access to many of the control's UI elements, as well as database related properties such as Table and Field, which allow for syncing with [[Business Objects]].
+
Per default, tutti i controlli implementati dall'interfaccia ICaisisInputControl, hanno tutte le proprietà esposte in modo da essere settate e trovate per codice utente. Queste proprietà forniscono un accesso facilitato a molti controlli dell'interfaccia utente, assieme a proprietà di database quali Table e Field, che consentono il collegamento con i [[Business Objects]].
====Table (string) ====
====Table (string) ====
-
The name of the Database Table corresponding to a control.
+
Il nome della tabella di database corrispondente al controllo.
====Field (string) ====
====Field (string) ====
-
The name of the Database Table's field corresponding to a control
+
Il nome del campo della tabella del database corrispondente al controllo.
====Value (string) ====
====Value (string) ====
-
This is the corresponding "text" value of a derived control.  
+
Questo è il corrispondente valore di "text" di un controllo derivato.  
-
So, for TextBox the Value field refers to the TextBox's value, for TexArea's value, DropDownList, SelectedValue.
+
Quindi, per TextBox il campo Value si riferisce al valore del TextBox, della TexArea, del DropDownList, del SelectedValue.
====Visible (boolean)====
====Visible (boolean)====
-
The name of the Database Table corresponding to a control.
+
Il nome della tabella di database corrispondente al controllo.
====FieldLabel (string)====
====FieldLabel (string)====
-
The name to display next to the control.
+
Il nome da visualizzare dopo il controllo.
====Required (boolean)====
====Required (boolean)====
-
Shows if this field is required on data entry forms.
+
Indica se questo campo è obbligatorio nei moduli di data entry.
====ShowHelpBubble (boolean)====
====ShowHelpBubble (boolean)====
-
True or False value indicating wheather to show a help description for a control.
+
Valore True o False che indica se visualizzare un help per il controllo.
====HelpDescription (string)====
====HelpDescription (string)====
-
The help description displayed for a control.
+
Descrizione di help visualizzata per il controllo.
====ShowLabel (boolean)====
====ShowLabel (boolean)====
-
True or False indicating weather to show a control.
+
Valore True o False che indica se visualizzare il controllo.
====Enabled (boolean)====
====Enabled (boolean)====
-
True or False indicating weather to is enabled for editing/modifying.
+
Valore True o False che indica se abilitare la modifica del controllo.
====CssClass (string)====
====CssClass (string)====
-
The CSS class name to apply to the control.
+
Nome della classse del CSS (foglio di stile) da applicare al controllo.
-
 
+
===Extended Properties===
===Extended Properties===

Revision as of 19:29, 22 August 2008

(traduzione italiana in corso)

Contents

Introduzione

In questa sezione vengono descritti i controlli di input di Caisis che costituiscono i controlli base dell'interfaccia utente all'applicazione, che si appoggiano ai controlli standard previsti da .NET controls, quali TextBoxes, TextAreas, CheckBoxes, RadioButton, DropDownList, etc... Questi controlli forniscono proprietà utili applicabili ai vari elementi dell'interfaccia (calendari, tastierini numerici, icone, descrizioni...) con poca attività di programmazione.

I controlli di input di Caisis forniscono proprietà addizionali per facilitare la loro associazione con i Business Objects. Proprietà quali Table e Field facilitano l'associazione del valori dei controlli ai rispettivi nomi di campi e tabelle associati del database.

Interfacce


ICaisisInputControl

L'interfaccia denominata ICaisisInputControl fornisce gli elementi più comuni attraverso proprietà e fornisce supporto per trattare l'associazione con i campi dei [Business Object] correlati. Controlli implementati da ICaisisInputControl

  • CaisisTextBox
  • CaisisTextArea
  • CaisisSelect
  • CaisisHidden
  • CaisisCheckBox
  • CaisisComboBox
  • CaisisRadioButton
  • CaisisRadioButtonList
  • CaisisExtendedCheckBoxList
  • CaisisExtendedRadioButtonList

ICaisisLookupControl

L'interfaccia denominata ICaisisLookupControl fornisce un accesso facilitato per legare i controlli ai LookupCodes, come definito dall'amministratore. Esistono anche proprietà addizionali utilizzate per creare codici di lookup dinamici basati su valori scelti dall'utente.

Controls Implementing ICaisisLookupControl

  • CaisisSelect
  • CaisisComboBox

Proprietà di base


Per default, tutti i controlli implementati dall'interfaccia ICaisisInputControl, hanno tutte le proprietà esposte in modo da essere settate e trovate per codice utente. Queste proprietà forniscono un accesso facilitato a molti controlli dell'interfaccia utente, assieme a proprietà di database quali Table e Field, che consentono il collegamento con i Business Objects.

Table (string)

Il nome della tabella di database corrispondente al controllo.

Field (string)

Il nome del campo della tabella del database corrispondente al controllo.

Value (string)

Questo è il corrispondente valore di "text" di un controllo derivato. Quindi, per TextBox il campo Value si riferisce al valore del TextBox, della TexArea, del DropDownList, del SelectedValue.

Visible (boolean)

Il nome della tabella di database corrispondente al controllo.

FieldLabel (string)

Il nome da visualizzare dopo il controllo.

Required (boolean)

Indica se questo campo è obbligatorio nei moduli di data entry.

ShowHelpBubble (boolean)

Valore True o False che indica se visualizzare un help per il controllo.

HelpDescription (string)

Descrizione di help visualizzata per il controllo.

ShowLabel (boolean)

Valore True o False che indica se visualizzare il controllo.

Enabled (boolean)

Valore True o False che indica se abilitare la modifica del controllo.

CssClass (string)

Nome della classse del CSS (foglio di stile) da applicare al controllo.

Extended Properties


The following properties are exposed by controls implementing the ICaisisLookupControl interface. This provides easy access to binding to Lookup Codes as well, as offering dynamic cascading values through related controls.

LookupCode (string)

A code used to retrieve results from the database.

LookupDistinct (string)

Controls filtering of lookup values.

CascadeValuesBasedOn (string)

(Advanced) When combined with the CascadeFormatString, lookup codes for a control are generated on the fly (client-side through javascript,CaisisComboBox), or via AutoPostBack events (via server,CaisisSelect). This property takes a list of comma-seperated list of related Fields. When lookup codes are needed (during a combo box click event), then values are extracted from these related fields and used to build a dynamic lookup code that is retrieved from the server.

CascadeFormatString (string)

(Advanced) Specifies the format of the dynamic lookup codes, based on values of the related control (CascadeValuesBasedOn). Format is similar to C# String.Format method where string "my first value: {0} and second value: {1}" will have {0} and {1} replaced with an array of values, based on an index 0-n. In this case, the array of values are determined by the controls referenced(by Field names) in CascadeValuesBasedOn. In addition to using indexes of related control, you may also use the n. prefix to extract a number from the control's value. Below is an example of how this property is combined with the CascadeValuesBasedOn.

Example:

We have the field ClinStageT represented by the CaisisComboBox control.

On this same form there are two CaisisSelect(DropDownList) represented with Field ClinStageDisease and ClinStageSystem.

We now set the related properties.

  • CascadeValuesBasedOn="ClinStageDisease,ClientStageSystem"
  • CascadeFormatString="StageClin_{0}_{n.1}_T"

When we change the values of ClinStageDisease or ClinStageSystem, the lookup code which the ClinStageT ComboBox generates is based on the two observed values. So if we select Prostate for the ClinStageDisease, and select UICC_02 for ClinStageSystem, we will generate a lookupcode "StageClin_Prostate_02_T", since the "Value" of ClinStageDisease is "Prostate" and the "Value" of ClinStageSystem is "UICC_02". We only extract the number for the ClinStageSystem "Value", as our format string said to parse out a number, "{n.1}" from the value at index 1.

NOTES: If the control using these properties is a CaisiSelect, everytime an observed control changes values, it will cause a post back to the server, causing syncing issues with retaining values. The CaisisComboBoxes however do not post back, as values are generated via javascript and are retrieved using Client CallBacks, there is no need to worry about retaining values. If unsure, CaisisComboBoxes always provide the best method to handle dynamic lookup codes. The controls being observed (CascadeValuesBasedOn) can still be any type of control, even a CaisisSelect.

Personal tools