Admidio API
  • Package
  • Class
  • Tree
  • Deprecated
  • Todo

Packages

  • com
    • tecnick
      • tcpdf
  • None
  • PHPMailer
    • easypeasyics
  • PHPWavUtils
  • Securimage
    • classes

Classes

  • AutoLogin
  • Component
  • ComponentUpdate
  • ConditionParser
  • Database
  • DateTimeExtended
  • Email
  • Folder
  • FormValidation
  • FunctionClass
  • Htaccess
  • HtmlDiv
  • HtmlElement
  • HtmlForm
  • HtmlFormBasic
  • HtmlFormInstallation
  • HtmlList
  • HtmlNavbar
  • HtmlPage
  • HtmlTable
  • HtmlTableBasic
  • Image
  • Inventory
  • InventoryFields
  • Language
  • LanguageData
  • ListConfiguration
  • Menu
  • Message
  • ModuleAnnouncements
  • ModuleDates
  • ModuleLists
  • ModuleMenu
  • ModuleMessages
  • Modules
  • ModuleWeblinks
  • MyFiles
  • Navigation
  • ntlm_sasl_client_class
  • Organization
  • Participants
  • PasswordHash
  • PasswordHashing
  • ProfileFields
  • RoleDependency
  • RolesRights
  • RSSfeed
  • Session
  • SystemMail
  • TableAccess
  • TableAnnouncement
  • TableCategory
  • TableDate
  • TableFile
  • TableFolder
  • TableGuestbook
  • TableGuestbookComment
  • TableInventory
  • TableInventoryField
  • TableLists
  • TableMembers
  • TableMessage
  • TablePhotos
  • TableRoles
  • TableRooms
  • TableText
  • TableUserField
  • TableUsers
  • TableWeblink
  • UploadHandlerDownload
  • UploadHandlerPhoto
  • User
  • UserRegistration

Exceptions

  • AdmException
  • WavFileException
  • WavFormatException

Functions

  • admFuncAutoload
  • admFuncGeneratePagination
  • admFuncGetBytesFromSize
  • admFuncGetDirectoryEntries
  • admFuncMaxUploadSize
  • admFuncProcessableImageSize
  • admFuncShowCreateChangeInfoById
  • admFuncShowCreateChangeInfoByName
  • admFuncVariableIsValid
  • admReadTemplateFile
  • admStrIsValidFileName
  • admStrStripTagsSpecial
  • admStrToLower
  • admStrToUpper
  • bzip2Version
  • checkDatabaseVersion
  • checkPhpVersion
  • EmailAttachment
  • FileSizeNiceDisplay
  • FormattedTimeRemaining
  • FunctionIsDisabled
  • getFormerRolesFromDatabase
  • getFutureRolesFromDatabase
  • getmicrotime
  • getRoleMemberships
  • getRolesFromDatabase
  • gzipVersion
  • hasRole
  • hl_attrval
  • hl_bal
  • hl_cmtcd
  • hl_ent
  • hl_prot
  • hl_regex
  • hl_spec
  • hl_tag
  • hl_tag2
  • hl_tidy
  • hl_version
  • htmLawed
  • HTMLFilter
  • isGroupLeader
  • isMember
  • kses
  • kses_hook
  • MySQLdumpVersion
  • OutputInformation
  • SafeExec
  • showNotice
  • strAddSlashesDeep
  • strNextLetter
  • strStripSlashesDeep
  • strStripTags
  • strValidCharacters
  • tln_body2div
  • tln_casenormalize
  • tln_deent
  • tln_defang
  • tln_findnxreg
  • tln_findnxstr
  • tln_fixatts
  • tln_fixstyle
  • tln_fixurl
  • tln_getnxtag
  • tln_sanitize
  • tln_skipspace
  • tln_tagprint
  • tln_unspace
  • version_compare_replacement
  • version_compare_replacement_sub

Class InventoryFields

Copyright: 2004-2016 The Admidio Team
License: GNU General Public License v2.0 only **********************************************************************************************
Brief:

Reads the Inventory fields structure out of database and give access to it

When an object is created than the actual inventory fields structure will be read. In addition to this structure you can read the item values for all fields if you call @c readItemData . If you read field values than you will get the formated output. It's also possible to set item data and save this data to the database


Class: InventoryFields
Located at inventoryfields.php

Methods summary

public
# __construct( Database & $database, integer $organizationId )

constructor that will initialize variables and read the inventory field structure

constructor that will initialize variables and read the inventory field structure

Parameters

$database
Object of the class Database. This should be the default global object @b $gDb.
$organizationId

The id of the organization for which the profile field structure should be read

public
# clearInventoryData( )

item data of all inventory fields will be initialized the fields array will not be renewed

item data of all inventory fields will be initialized the fields array will not be renewed

public
# getProperty( string $fieldNameIntern, string $column, string $format = '' )

returns for a fieldname intern (inf_name_intern) the value of the column from table adm_user_fields

returns for a fieldname intern (inf_name_intern) the value of the column from table adm_user_fields

Parameters

$fieldNameIntern
Expects the @b inf_name_intern of table @b adm_user_fields
$column
The column name of @b adm_user_field for which you want the value
$format
Optional the format (is necessary for timestamps)

Returns

public
# getPropertyById( integer $fieldId, string $column, string $format = '' )

returns for field id (usf_id) the value of the column from table adm_user_fields

returns for field id (usf_id) the value of the column from table adm_user_fields

Parameters

$fieldId
Expects the @b usf_id of table @b adm_user_fields
$column
The column name of @b adm_user_field for which you want the value
$format
Optional the format (is necessary for timestamps)

Returns

public string
# getHtmlValue( string $fieldNameIntern, string|integer $value, integer $value2 = null )

Returns the value of the field in html format with consideration of all layout parameters

Returns the value of the field in html format with consideration of all layout parameters

Parameters

$fieldNameIntern
Internal profile field name of the field that should be html formated
$value
The value that should be formated must be commited so that layout is also possible for values that aren't stored in database
$value2
An optional parameter that is necessary for some special fields like email to commit the user id

Returns

string
Returns an html formated string that considered the profile field settings
public mixed
# getValue( string $fieldNameIntern, string $format = '' )

Returns the user value for this column @n format = 'd.m.Y' : a date or timestamp field accepts the format of the PHP date() function @n format = 'html' : returns the value in html-format if this is necessary for that field type @n format = 'database' : returns the value that is stored in database with no format applied

Returns the user value for this column @n format = 'd.m.Y' : a date or timestamp field accepts the format of the PHP date() function @n format = 'html' : returns the value in html-format if this is necessary for that field type @n format = 'database' : returns the value that is stored in database with no format applied

Parameters

$fieldNameIntern
Expects the @b inf_name_intern of table @b adm_user_fields
$format
Returns the field value in a special format @b text, @b html, @b database or datetime (detailed description in method description)

Returns

mixed
public
# noValueCheck( )

If this method is called than all further calls of method @b setValue will not check the values. The values will be stored in database without any inspections !

If this method is called than all further calls of method @b setValue will not check the values. The values will be stored in database without any inspections !

public
# readInventoryFields( integer $organizationId )

Reads the profile fields structure out of database table @b adm_user_fields and adds an object for each field structure to the @b mInventoryFields array.

Reads the profile fields structure out of database table @b adm_user_fields and adds an object for each field structure to the @b mInventoryFields array.

Parameters

$organizationId

The id of the organization for which the profile fields structure should be read.

public
# readInventoryData( integer $itemId, integer $organizationId )

Reads the user data of all profile fields out of database table @b adm_user_data and adds an object for each field data to the @b mInventoryData array. If profile fields structure wasn't read, this will be done before.

Reads the user data of all profile fields out of database table @b adm_user_data and adds an object for each field data to the @b mInventoryData array. If profile fields structure wasn't read, this will be done before.

Parameters

$itemId
The id of the user for which the user data should be read.
$organizationId

The id of the organization for which the profile fields structure should be read if necessary.

public
# saveInventoryData( integer $itemId )

save data of every user field

save data of every user field

Parameters

$itemId
id is necessary if new user, that id was not known before
public boolean
# setValue( string $fieldNameIntern, $fieldValue )

set value for column usd_value of field

set value for column usd_value of field

Parameters

$fieldNameIntern
$fieldValue

Returns

boolean

Properties summary

public array $mInventoryFields
# array()
public array $mInventoryData
# array()
protected $mItemId
#
public $mDb
#
protected $noValueCheck
#
public $columnsValueChanged
#
Admidio API API documentation generated by ApiGen