FacturaScripts

SubAccountTools
in package

Set of tools for the management of accounting sub-accounts

Tags
author

Jose Antonio Cuello Principal [email protected]

author

Carlos García Gómez [email protected]

Table of Contents

SPECIAL_GROUP_TAX_ALL  = 0
All tax special codes
SPECIAL_GROUP_TAX_INPUT  = 1
Only input tax special codes
SPECIAL_GROUP_TAX_OUTPUT  = 2
Only output tax special codes
autocompleteAction()  : array<string|int, mixed>
Returns a list of sub-accounts for the exercise and search term informed.
hasTax()  : bool
Indicates whether the subaccount has associated taxes.
isInputTax()  : bool
Indicates whether the special account type belongs to the group of input tax accounts.
isOutputTax()  : bool
Indicates whether the special account type belongs to the group of output tax accounts.
specialAccountsForGroup()  : array<string|int, mixed>
Get array of specials Tax code accounts for selected group.
whereForSpecialAccounts()  : DataBaseWhere
Get the where filter with the list of special account codes for the indicated group.

Constants

SPECIAL_GROUP_TAX_ALL

All tax special codes

public mixed SPECIAL_GROUP_TAX_ALL = 0

SPECIAL_GROUP_TAX_INPUT

Only input tax special codes

public mixed SPECIAL_GROUP_TAX_INPUT = 1

SPECIAL_GROUP_TAX_OUTPUT

Only output tax special codes

public mixed SPECIAL_GROUP_TAX_OUTPUT = 2

Methods

autocompleteAction()

Returns a list of sub-accounts for the exercise and search term informed.

public static autocompleteAction(array<string|int, mixed> $keys) : array<string|int, mixed>
Parameters
$keys : array<string|int, mixed>

source: source table name. default 'subcuentas'. fieldcode: source field name. default 'codsubcuenta'. fieldtitle: source field title. default 'descripcion'. term: user key filter. codejercicio: fiscal year filter.

Return values
array<string|int, mixed>

hasTax()

Indicates whether the subaccount has associated taxes.

public hasTax(Subcuenta|string $subAccount) : bool
Parameters
$subAccount : Subcuenta|string
Return values
bool

isInputTax()

Indicates whether the special account type belongs to the group of input tax accounts.

public isInputTax(string $specialAccount) : bool
Parameters
$specialAccount : string
Return values
bool

isOutputTax()

Indicates whether the special account type belongs to the group of output tax accounts.

public isOutputTax(string $specialAccount) : bool
Parameters
$specialAccount : string
Return values
bool

specialAccountsForGroup()

Get array of specials Tax code accounts for selected group.

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

whereForSpecialAccounts()

Get the where filter with the list of special account codes for the indicated group.

public whereForSpecialAccounts(string $field, int $group) : DataBaseWhere
Parameters
$field : string
$group : int
Return values
DataBaseWhere

Search results