Documentation

Informationsystem_Item_Export_Csv_Controller extends Core_Servant_Properties

Information systems export CSV controller

Tags
subpackage

Informationsystem

version
7.x
author

Hostmake LLC

copyright

© 2005-2024 ООО "Хостмэйк" (Hostmake LLC), http://www.hostcms.ru

Table of Contents

Properties

$_aCurrentRow  : array<string|int, mixed>
Array of titile line
$_allowedProperties  : array<string|int, mixed>
Allowed object properties
$_cacheGetListValue  : mixed
$_propertiesValues  : array<string|int, mixed>
Properties values
$_unlimitedProperties  : bool
Object has unlimited number of properties
$_aCurrentData  : array<string|int, mixed>
CSV data
$_aGroup_Properties  : array<string|int, mixed>
Additional properties of item groups Дополнительные свойства групп элементов
$_aGroupBaseProperties  : array<string|int, mixed>
Base properties of item groups Основные свойства групп элементов
$_aItem_Properties  : array<string|int, mixed>
Additional properties of items Дополнительные свойства элементов
$_aItemBaseProperties  : array<string|int, mixed>
Base properties of items Основные свойства элементов
$_cmlItemPosition  : int
Item CML ID Position
$_iCurrentDataPosition  : int
Data pointer
$_iGroup_Properties_Count  : int
Group properties count
$_iItem_Properties_Count  : int
Item properties count Требуется хранить количество свойств отдельно, т.к. количество полей файла CSV для свойств не равно количеству свойств (из-за файлов)

Methods

__construct()  : mixed
Constructor.
addAllowedProperties()  : self
Add additional allowed properties
addAllowedProperty()  : self
Add additional allowed property
execute()  : mixed
Executes the business logic.
getCurrentRow()  : array<string|int, mixed>
Get Current Row
getGroupTitles()  : array<string|int, mixed>
Get Group Titles
getItemBasicData()  : array<string|int, mixed>
Get Basic Item Data
getItemData()  : array<string|int, mixed>
Get item data
getItemTitles()  : array<string|int, mixed>
Get Item Titles
prepareCell()  : string
Prepare cell
prepareFloat()  : string
Prepare float
prepareString()  : string
Prepare string
set()  : self
Run when writing data to inaccessible properties
setCurrentRow()  : self
Set Current Row
setUnlimitedProperties()  : self
Set unlimitedProperties
_getListValue()  : mixed
_getPropertyValue()  : string
Get value of Property_Value
_printRow()  : self
Print array

Properties

$_aCurrentRow

Array of titile line

protected array<string|int, mixed> $_aCurrentRow = array()

$_allowedProperties

Allowed object properties

protected array<string|int, mixed> $_allowedProperties = array('separator', 'encoding', 'parentGroup', 'exportItemExternalProperties', 'exportGroupExternalProperties', 'informationsystemId')

$_cacheGetListValue

protected mixed $_cacheGetListValue = array()

$_propertiesValues

Properties values

protected array<string|int, mixed> $_propertiesValues = array()

$_unlimitedProperties

Object has unlimited number of properties

protected bool $_unlimitedProperties = \FALSE

$_aCurrentData

CSV data

private array<string|int, mixed> $_aCurrentData

$_aGroup_Properties

Additional properties of item groups Дополнительные свойства групп элементов

private array<string|int, mixed> $_aGroup_Properties = array()

$_aGroupBaseProperties

Base properties of item groups Основные свойства групп элементов

private array<string|int, mixed> $_aGroupBaseProperties

$_aItem_Properties

Additional properties of items Дополнительные свойства элементов

private array<string|int, mixed> $_aItem_Properties = array()

$_aItemBaseProperties

Base properties of items Основные свойства элементов

private array<string|int, mixed> $_aItemBaseProperties

$_cmlItemPosition

Item CML ID Position

private int $_cmlItemPosition = 0

$_iCurrentDataPosition

Data pointer

private int $_iCurrentDataPosition

$_iGroup_Properties_Count

Group properties count

private int $_iGroup_Properties_Count

$_iItem_Properties_Count

Item properties count Требуется хранить количество свойств отдельно, т.к. количество полей файла CSV для свойств не равно количеству свойств (из-за файлов)

private int $_iItem_Properties_Count

Methods

__construct()

Constructor.

public __construct(int $iInformationsystemId[, bool $bItemPropertiesExport = TRUE ][, bool $bGroupPropertiesExport = TRUE ]) : mixed
Parameters
$iInformationsystemId : int

informationsystem ID

$bItemPropertiesExport : bool = TRUE

export item properties mode

$bGroupPropertiesExport : bool = TRUE

export group properties mode

addAllowedProperties()

Add additional allowed properties

public addAllowedProperties(array<string|int, mixed> $array) : self
Parameters
$array : array<string|int, mixed>

array of properties' names

Return values
self

addAllowedProperty()

Add additional allowed property

public addAllowedProperty(string $property) : self
Parameters
$property : string

property name

Return values
self

execute()

Executes the business logic.

public execute() : mixed

getCurrentRow()

Get Current Row

public getCurrentRow() : array<string|int, mixed>
Return values
array<string|int, mixed>

getGroupTitles()

Get Group Titles

public getGroupTitles() : array<string|int, mixed>
Tags
hostcms-event

Informationsystem_Item_Export_Csv_Controller.onGetGroupTitles

Return values
array<string|int, mixed>

getItemBasicData()

Get Basic Item Data

public getItemBasicData(object $oInformationsystem_Item) : array<string|int, mixed>
Parameters
$oInformationsystem_Item : object
Tags
hostcms-event

Informationsystem_Item_Export_Csv_Controller.onAfterItemBasicData

Return values
array<string|int, mixed>

getItemData()

Get item data

public getItemData(object $oInformationsystem_Item) : array<string|int, mixed>
Parameters
$oInformationsystem_Item : object

item

Tags
hostcms-event

Informationsystem_Item_Export_Csv_Controller.onAfterGetItemData

Return values
array<string|int, mixed>

getItemTitles()

Get Item Titles

public getItemTitles() : array<string|int, mixed>
Tags
hostcms-event

Informationsystem_Item_Export_Csv_Controller.onGetItemTitles

Return values
array<string|int, mixed>

prepareCell()

Prepare cell

public prepareCell(string $string) : string
Parameters
$string : string
Return values
string

prepareFloat()

Prepare float

public prepareFloat(mixed $string) : string
Parameters
$string : mixed
Return values
string

prepareString()

Prepare string

public prepareString(string $string) : string
Parameters
$string : string
Return values
string

set()

Run when writing data to inaccessible properties

public set(string $property, string $value) : self
Parameters
$property : string

property name

$value : string

property value

Return values
self

setCurrentRow()

Set Current Row

public setCurrentRow(array<string|int, mixed> $array) : self
Parameters
$array : array<string|int, mixed>
Return values
self

setUnlimitedProperties()

Set unlimitedProperties

public setUnlimitedProperties([bool $value = TRUE ]) : self
Parameters
$value : bool = TRUE

default TRUR

Return values
self

_getListValue()

protected _getListValue(mixed $list_item_id) : mixed
Parameters
$list_item_id : mixed

_getPropertyValue()

Get value of Property_Value

protected _getPropertyValue(Property_Model $oProperty, mixed $oProperty_Value, mixed $object) : string
Parameters
$oProperty : Property_Model
$oProperty_Value : mixed
$object : mixed
Tags
hostcms-event

Informationsystem_Item_Export_Csv_Controller.onGetPropertyValueDefault

Return values
string

_printRow()

Print array

protected _printRow(array<string|int, mixed> $aData) : self
Parameters
$aData : array<string|int, mixed>
Return values
self

        
On this page

Search results