Overview
  • Package
  • Class
  • Tree
  • Todo

Packages

  • AddonValue
    • Interfaces
  • AdminHttpViewControllers
  • ApiV2Controllers
  • Category
    • Collections
    • Entities
    • Factories
    • Interfaces
    • Providers
    • Repositories
    • Storages
  • Customer
    • Address
    • Country
    • CountryZone
    • Interfaces
    • Storages
    • Validation
    • ValueObjects
  • Email
    • Collections
    • Entities
    • Exceptions
    • Interfaces
    • Repository
    • ValueObjects
  • Extensions
    • Customers
    • Emails
    • Helpers
    • Orders
    • Serializers
  • Http
    • Collections
    • Exceptions
    • Factories
    • Interfaces
    • ValueObjects
  • HttpViewControllers
  • InfoBox
    • Interfaces
  • Invoice
    • Interfaces
    • ValueObjects
  • Loaders
    • CrossCuttingLoader
    • GXCoreLoader
    • Interfaces
  • Modules
    • Collections
    • Controllers
    • Interfaces
  • Order
    • Collections
    • Entities
    • Factories
    • Interfaces
    • Repositories
    • Storages
    • ValueObjects
  • Product
    • Collections
    • Entities
    • Factories
    • Interfaces
    • Providers
    • Repositories
    • Storages
  • ProductModule
    • Collections
    • Deleter
    • Entities
    • Factories
    • Interface
    • Interfaces
    • Reader
    • Repositories
    • Writer
  • Shared
    • ClassFinder
    • Exceptions
    • FileSystem
    • Interfaces
    • Storage
    • Types
  • SharedShoppingCart
    • Interfaces
  • Statistics
    • Interfaces
  • UserConfiguration
    • Interfaces
    • Repository

Classes

  • CacheTokenHelper
  • ColorHelper
  • CustomerStatusHelper
  • DataTableColumn
  • DataTableColumnCollection
  • DataTableColumnType
  • DataTableHelper
  • FilesystemHelper
  • LanguageHelper
  • StringHelper

Interfaces

  • CacheTokenHelperInterface
  • LanguageHelperInterface
  • StringHelperInterface

Class DataTableHelper

Class DataTableHelper

This class contains helper methods for datatable manipulation. Create an instance and define the columns of your table and their respective database fields. You can also provide two fields separated with a space for concatenated string.

Package: Extensions\Helpers
Category: System
Located at Extensions/Helpers/DataTableHelper/DataTableHelper.inc.php

Methods summary

public string
# getOrderByClause( DataTableColumnCollection $columns )

Get ORDER BY clause.

Get ORDER BY clause.

This method will check the order parameter of the DataTables request and return the appropriate ORDER BY clause.

Notice: DataTables sends the zero-based index of the table column and not the name. If the column order changes then the method needs to be updated.

Parameters

$columns
Contains the definitions of the table columns.

Returns

string

Throws

Exception
If there is no order case for the provided column index.
InvalidArgumentException
public array
# getFilterParameters( DataTableColumnCollection $columns )

Get the filtering parameters of the request.

Get the filtering parameters of the request.

Notice: Multiple string values need to be sent as concatenated strings with "||" as the delimiter.

Parameters

$columns
Contains the definitions of the table columns.

Returns

array

Throws

InvalidArgumentException
protected array|string
# _trimArray( string|array $entry )

Recursively trim the array values.

Recursively trim the array values.

Parameters

$entry

Returns

array|string
API documentation generated by ApiGen