forms
[ class tree: forms ] [ index: forms ] [ all elements ]

Class: MultiRelationSelect

Source Location: /forms/items/MultiRelationSelect.class.php

Class Overview

ABSTObject
   |
   --ABSTHTMLTag
      |
      --ABSTHTMLFormItem
         |
         --MultiRelationSelect

A class to generate selects mainly to handle multiple relation between two databasetables.


Author(s):

Version:

  • 0.1.3

Copyright:

  • Copyright (C) 2005 Daniel Plücken <daniel@debakel.net>

    This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the License.

    This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.

    You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA

Variables

Methods


Inherited Variables

Inherited Methods

Class: ABSTHTMLFormItem

ABSTHTMLFormItem::addValue()
Concats the given string to the value of this item's "value"-attribute.
ABSTHTMLFormItem::disable()
Disables this item. This method is an alias for the method setDisabled().
ABSTHTMLFormItem::enable()
Enables this item. This method is an alias for the method setDisabled().
ABSTHTMLFormItem::getCheckOrder()
Blind method cause other objects will invoke it.
ABSTHTMLFormItem::getLabel()
Returns the label to the extended extended underlying form component as string.
ABSTHTMLFormItem::getValidationOrder()
Blind method cause other objects will invoke it.
ABSTHTMLFormItem::getValue()
Returns the value of this item's "value"-attribute.
ABSTHTMLFormItem::HTMLFormItem()
Constructor
ABSTHTMLFormItem::setDisabled()
Disables this item.
ABSTHTMLFormItem::setEnabled()
Enables this item.
ABSTHTMLFormItem::setLabel()
Stores the given label object to the extended underlying form component.
ABSTHTMLFormItem::setManipulateable()
Makes sure that this item is manipulateable by the user.
ABSTHTMLFormItem::setNotManipulateable()
Makes sure that this item is not manipulateable by the user, but carrys the value trough the form.
ABSTHTMLFormItem::setParentForm()
Stores a reference to the form-object that contains this item-object.
ABSTHTMLFormItem::setValue()
Stores the value of this item's "value"-attribute.

Class: ABSTHTMLTag

ABSTHTMLTag::getId()
Returns the value of this tag's "id"-attribute.
ABSTHTMLTag::getName()
Returns the value of this tag's "name"-attribute.
ABSTHTMLTag::HTMLTag()
The Constructor let the script die, cause this is an abstract class!
ABSTHTMLTag::idExists()
Stores all used ids and makes sure that every id in the document is unique. It should called in every get method of classes in the packages forms and html.
ABSTHTMLTag::setAttributes()
This method allows to set the attributes of the tag that are not handled by other methods.
ABSTHTMLTag::setFreeStyle()
Set the value of style definitions that are not handled by implemented methods.
ABSTHTMLTag::setId()
Stores the value of this item's "id"-attribute.
ABSTHTMLTag::setName()
Stores the value of this tag's "name"-attribute.
ABSTHTMLTag::setNoFormat()
Stores that the HTML-elements should not format by "\r\n" in the source.
ABSTHTMLTag::setOnBlur()
Sets the value of the blur-attribute of this html-tag.
ABSTHTMLTag::setOnClick()
Sets the value of the click-attribute of this html-tag.
ABSTHTMLTag::setOnFocus()
Sets the value of the focus-attribute of this html-tag.
ABSTHTMLTag::setOnMouseMove()
Sets the value of the mousemove-attribute of this html-tag.
ABSTHTMLTag::setOnMouseOut()
Sets the value of the mouseout-attribute of this html-tag.
ABSTHTMLTag::setOnMouseOver()
Sets the value of the mouseover-attribute of this html-tag.
ABSTHTMLTag::setOnMouseUp()
Sets the value of the mouseup-attribute of this html-tag.
ABSTHTMLTag::setStyle()
Set the value of the class-attribute of this tag.

Class: ABSTObject

ABSTObject::printComplexData()
Prints out the more complex data by the given array.
ABSTObject::printPrimitiveData()
Prints out the primitive data by the given arrays.
ABSTObject::printStructure()
Prints out the Structure of this Object.
ABSTObject::same()
Checks whether the passed object reference points to this object.
ABSTObject::sameReferences()
Compares two references whether they points to the same object

Class Details

[line 91]
A class to generate selects mainly to handle multiple relation between two databasetables.

  1.                       _________
  2.                      |   p   |v|
  3.                       ---------
  4.                mtrb
  5.   +-------+-+   |    +-------+-+
  6.   |       | |   V    |       |-|
  7.   |       | |  |>>|  |       | |
  8.   |  ls   | |        |  rs   | |
  9.   |       |-|  |<<|  |       |-|
  10.   |       |-|   ^    |       | |
  11.   +-------+-+   |    +-------+-+
  12.                mtlb
  13.  
  14.  
  15.    p    $primaryEntitySelect
  16.    ls   $leftSelect
  17.    rs   $rightSelect
  18.    mtlb $moveToLeftButton
  19.    mtrb $moveToRightButton




Tags:

author:  Daniel Plücken <daniel@debakel.net>
version:  0.1.3
copyright:  

Copyright (C) 2005 Daniel Plücken <daniel@debakel.net>

This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the License.

This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA

license:  GNU Lesser General Public License


[ Top ]


Class Variables

$form_name =  ""

[line 235]



Tags:

access:  public

Type:   string


[ Top ]

$hiddenValueInput =

[line 241]



Tags:

access:  public

Type:   HTMLHiddenInput


[ Top ]

$layout_table_head =  ""

[line 247]



Tags:

access:  public

Type:   string


[ Top ]

$leftSelectSize =

[line 175]



Tags:

access:  public

Type:   integer


[ Top ]

$leftSelectStyle =  ""

[line 223]



Tags:

access:  public

Type:   string


[ Top ]

$moveToLeftButtonLabel =  ""

[line 193]



Tags:

access:  public

Type:   string


[ Top ]

$moveToLeftButtonStyle =  ""

[line 211]



Tags:

access:  public

Type:   string


[ Top ]

$moveToRightButtonLabel =  ""

[line 187]



Tags:

access:  public

Type:   string


[ Top ]

$moveToRightButtonStyle =  ""

[line 205]



Tags:

access:  public

Type:   string


[ Top ]

$primaryEntityDBTObject =

[line 97]



Tags:

access:  public

Type:   object


[ Top ]

$primaryEntityLabelFieldArr = array()

[line 121]



Tags:

access:  public

Type:   array


[ Top ]

$primaryEntityPrimaryKey =  ""

[line 115]



Tags:

access:  public

Type:   string


[ Top ]

$primaryEntitySelectedValue =  ""

[line 127]



Tags:

access:  public

Type:   string


[ Top ]

$primaryEntitySelectStyle =  ""

[line 217]



Tags:

access:  public

Type:   string


[ Top ]

$primaryEntityWhereClause =  ""

[line 157]



Tags:

access:  public

Type:   string


[ Top ]

$rightSelectSize =

[line 181]



Tags:

access:  public

Type:   integer


[ Top ]

$rightSelectStyle =  ""

[line 229]



Tags:

access:  public

Type:   string


[ Top ]

$secondaryEntityDBTObject =

[line 103]



Tags:

access:  public

Type:   object


[ Top ]

$secondaryEntityLabelFieldArr = array()

[line 139]



Tags:

access:  public

Type:   array


[ Top ]

$secondaryEntityPrimaryKey =  ""

[line 133]



Tags:

access:  public

Type:   string


[ Top ]

$secondaryEntityWhereClause =  ""

[line 163]



Tags:

access:  public

Type:   string


[ Top ]

$serializedStandardValue =  ""

[line 199]



Tags:

access:  public

Type:   string


[ Top ]

$targetDBTObject =

[line 109]



Tags:

access:  public

Type:   object


[ Top ]

$targetDBTWhereClause =  ""

[line 169]



Tags:

access:  public

Type:   string


[ Top ]

$targetPrimaryEntityKey =  ""

[line 145]



Tags:

access:  public

Type:   string


[ Top ]

$targetSecondaryEntityKey =  ""

[line 151]



Tags:

access:  public

Type:   string


[ Top ]



Class Methods


constructor MultiRelationSelect [line 335]

object MultiRelationSelect( $name, &$primaryEntityDBTObject, string $primaryEntityPrimaryKey, array $primaryEntityLabelFieldArr, string $primaryEntitySelectedValue, &$secondaryEntityDBTObject, string $secondaryEntityPrimaryKey, array $secondaryEntityLabelFieldArr, &$targetDBTObject, string $targetPrimaryEntityKey, string $targetSecondaryEntityKey, [string $primaryEntityWhereClause = ""], [integer $leftSelectSize = 10], [integer $rightSelectSize = 10], [string $moveToRightButtonLabel = "&raquo;"], [string $moveToLeftButtonLabel = "&laquo;"], [string $serializedStandardValue = ""], object $primaryEntityDBTObject, object $secondaryEntityDBTObject, object $targetDBTObject)

Constructor



Tags:

author:  Daniel Plücken <daniel@debakel.net>
version:  1.5
since:  0.1.0
access:  public


Parameters:

object   $primaryEntityDBTObject   The databasetable object of the entity which should multiple connected to another entity. For example one Person is a member of different Groups. The group is the primary entity if you want to assign persons to an afore selected group.
string   $primaryEntityPrimaryKey   The field of the primary entity which should used for the relationship to the secondary entity.
array   $primaryEntityLabelFieldArr   The fieldnames of the primary entity for the use of labels in the select of the primary entity, so that the primary entity could be identified by the user of the select.
string   $primaryEntitySelectedValue   The selected value on primary entity side.
object   $secondaryEntityDBTObject   The databasetable object of the entity which should multiple connected to another entity. For example some different Groups each have the same Person as a member. The person is the seconary entity if you want to assign persons to an afore selected group.
string   $secondaryEntityPrimaryKey   The field of the secondary entity which should used for the relationship to the primary entity.
array   $secondaryEntityLabelFieldArr   The fieldnames which should act as labels for the secondary entity, so the user of the select is able to understand the meaning of the entity.
object   $targetDBTObject   The databasetable object of the table that should keep the relation of the connected entities.
string   $targetPrimaryEntityKey   The fieldname where the value of the primary key of the primaray entity should stored.
string   $targetSecondaryEntityKey   The fieldname where the value of the primary key of the secondary entity should stored.
string   $primaryEntityWhereClause   This is to filter the primary entities. If their count is only one, the primary entity select will not be shown.
integer   $leftSelectSize  
integer   $rightSelectSize  
string   $moveToRightButtonLabel   The label of the button by which the items of the primary entity should combined with the secondary entity.
string   $moveToLeftButtonLabel   The label of the button by which the items of the primary entity should lose their connection to the secondary entity.
string   $serializedStandardValue   The content of the select on the right side. This parameter overules the real value in the databasetable if it is not empty.
   $name  
   &$primaryEntityDBTObject  
   &$secondaryEntityDBTObject  
   &$targetDBTObject  

[ Top ]

method get [line 558]

string get( )

Returns a generated string based on the attributes of this object.



Tags:

author:  Daniel Plücken <daniel@debakel.net>
version:  1.41
since:  0.1.0
access:  public


[ Top ]

method setLayoutTableHead [line 544]

void setLayoutTableHead( string $string)

This is for example to add a filter select for the target database table to the top of this select. Then you will be able to align it flush with the right side of this select.



Tags:

author:  Daniel Plücken <daniel@debakel.net>
version:  1.0
since:  0.1.0
access:  public


Parameters:

string   $string  

[ Top ]

method setLeftSelectSize [line 386]

void setLeftSelectSize( string $int)

Sets the size of the select appering on the left side.



Tags:

author:  Daniel Plücken <daniel@debakel.net>
version:  1.0
since:  0.1.0
access:  public


Parameters:

string   $int  

[ Top ]

method setLeftSelectStyle [line 416]

void setLeftSelectStyle( string $string)

Sets the styleclass of the select appering on the left side.



Tags:

author:  Daniel Plücken <daniel@debakel.net>
version:  1.0
since:  0.1.0
access:  public


Parameters:

string   $string  

[ Top ]

method setMoveToLeftButtonStyle [line 463]

void setMoveToLeftButtonStyle( string $string)

Sets the styleclass of the button thats function is to move the items from the select on the right side to the select on the left side.



Tags:

author:  Daniel Plücken <daniel@debakel.net>
version:  1.0
since:  0.1.0
access:  public


Parameters:

string   $string  

[ Top ]

method setMoveToRightButtonStyle [line 447]

void setMoveToRightButtonStyle( string $string)

Sets the styleclass of the button thats function is to move the items from the select on the left side to the select on the right side.



Tags:

author:  Daniel Plücken <daniel@debakel.net>
version:  1.0
since:  0.1.0
access:  public


Parameters:

string   $string  

[ Top ]

method setNameOfForm [line 527]

void setNameOfForm( string $string)

Somtimes it can be usefule to filter the achievement from the Target database table.



Tags:

author:  Daniel Plücken <daniel@debakel.net>
version:  1.0
since:  0.1.0
access:  public


Parameters:

string   $string  

[ Top ]

method setPrimaryEntitySelectStyle [line 479]

void setPrimaryEntitySelectStyle( string $string)

Sets the styleclass of the select appering on the top of the select on the right side.



Tags:

author:  Daniel Plücken <daniel@debakel.net>
version:  1.0
since:  0.1.0
access:  public


Parameters:

string   $string  

[ Top ]

method setRightSelectSize [line 401]

void setRightSelectSize( string $int)

Sets the size of the select appering on the right side.



Tags:

author:  Daniel Plücken <daniel@debakel.net>
version:  1.0
since:  0.1.0
access:  public


Parameters:

string   $int  

[ Top ]

method setRightSelectStyle [line 431]

void setRightSelectStyle( string $string)

Sets the styleclass of the select appering on the right side.



Tags:

author:  Daniel Plücken <daniel@debakel.net>
version:  1.0
since:  0.1.0
access:  public


Parameters:

string   $string  

[ Top ]

method setWhereClauseOfsecondaryEntityDBT [line 511]

void setWhereClauseOfsecondaryEntityDBT( string $string)

Somtimes it can be usefule to filter the achievement from the secondary entity database table.



Tags:

author:  Daniel Plücken <daniel@debakel.net>
version:  1.01
since:  0.1.0
access:  public


Parameters:

string   $string  

[ Top ]

method setWhereClauseOfTargetDBT [line 495]

void setWhereClauseOfTargetDBT( string $string)

Somtimes it can be usefule to filter the achievement from the Target database table.



Tags:

author:  Daniel Plücken <daniel@debakel.net>
version:  1.0
since:  0.1.0
access:  public


Parameters:

string   $string  

[ Top ]


Documentation generated on Thu, 05 Jun 2008 19:13:52 +0200 by phpDocumentor 1.4.1