Documentation

ItalianYearlyFilingExportHandler extends AbstractExportHandler
in package
implements ItalianYearlyFilingExportHeaders uses ItalianYearlyFilingExportCalculatorTrait

Table of Contents

Interfaces

ItalianYearlyFilingExportHeaders

Constants

ACTIVE_HANDLERS  = [\Vatjar\Export\Component\TransactionVolumeExportHandler::class, \Vatjar\Export\Component\VatReportSummaryExportHandler::class, \Vatjar\Export\Component\MovementMissingCountryExportHandler::class, \Vatjar\Export\Component\StorageDetectionExportHandler::class, \Vatjar\Export\Component\TransactionToGbAfterBrexitExportHandler::class, \Vatjar\Export\Component\GermanYearlyFilingExportHandler::class, \Vatjar\Export\Component\ArrangedUserExportHandler::class, \Vatjar\Export\Component\YearlyTransactionCountExportHandler::class, \Vatjar\Export\Component\ItalianYearlyFilingExportHandler::class]
COLOR_BLUE  = 'C8DAF9'
COLOR_GREEN  = "92C47C"
COLOR_RED  = "FF0000"
COLOR_YELLOW  = 'FFE599'
EMPTY_STRING  = ""

Properties

$fileComponent  : mixed
$client  : Client|null
$clientCreditRepository  : ClientCreditRepository
$clientRepository  : ClientRepository
$difference  : mixed
$entryReportRepository  : EntryReportRepository
$entryReportsForPeriod  : array<string|int, EntryReport>
$entryReportsSummaries  : array<string|int, mixed>|null
$fields  : mixed
$governmentCreditsForPeriod  : array<string|int, ClientCredit>
$itUserVat  : UserVat
$preliminary  : mixed
$preliminaryReportsForPeriod  : array<string|int, Report>
$preliminaryReportsSummaries  : array<string|int, mixed>
$reportIntentionRepository  : ReportIntentionRepository
$reportObligationRepository  : ReportObligationRepository
$reportRepository  : ReportRepository
$totalFiled  : mixed
$userReportObligations  : array<string|int, ReportObligation>
$userVatRepository  : UserVatRepository
$versioned  : mixed

Methods

__construct()  : mixed
calculateAll()  : mixed
calculateAllDifferences()  : mixed
calculateDifferenceBetweenFields()  : string
createJob()  : mixed
customRound()  : mixed
filterParams()  : array<string|int, mixed>
filterSummaries()  : array<string|int, mixed>
getAllowedFilters()  : array<string|int, mixed>
getBucketName()  : string
getClient()  : Client
getExportTypes()  : array<string|int, mixed>
getFileComponent()  : AbstractExportFile
getHeaders()  : array<string|int, mixed>
getLastRowsNumber()  : array<string|int, mixed>
getLine()  : mixed
Get the value of line
getLines()  : Generator<string|int, array<string|int, string>>
getType()  : string
handle()  : mixed
markAsInProgress()  : mixed
validateParams()  : void
validatePositiveInteger()  : mixed
cloudPath()  : mixed
createFile()  : resource
filename()  : string|null
generateFile()  : void
getCloudStorageComponent()  : mixed
localPath()  : mixed
markAsDone()  : mixed
registerShutdownFunction()  : mixed
remoteUri()  : mixed
removeFile()  : mixed
saveError()  : mixed
saveToCloud()  : mixed
validateBool()  : bool
validateDate()  : bool
validateRequired()  : bool
validateString()  : bool
calculateAllDifferencesBetweenTotalFiledAndTotalVJFields()  : mixed
calculateAllDifferencesBetweenVersionedAndPreliminaryFields()  : mixed
calculateAllLatestPreliminaryReportFields()  : void
calculateAllLatestVersionedReportFields()  : void
calculateDifferenceBetweenGrossValueAndNetValue()  : mixed
calculateNetValue()  : mixed
calculateVP14()  : string
calculateVP6()  : string
convertToNumber()  : float
getDifferenceBetweenLatestReportVersionSubmittedLineValuesAndLatestPreliminaryReportLineValues()  : array<string|int, mixed>
getEntryReportsForPeriod()  : mixed
getGovernmentCreditForPeriod()  : array<string|int, mixed>
getItReportObligations()  : array<string|int, mixed>
getItUserVat()  : UserVat
getLatestPreliminaryReportLineValues()  : array<string|int, mixed>
getLatestReportVersionSubmittedLineValues()  : array<string|int, mixed>
getLineDifferenceBetweenTotalFiledAndTotalVJ()  : array<string|int, mixed>
getLinesValues()  : array<string|int, mixed>
getLineTotalFiled()  : array<string|int, mixed>
getLineTotalVJ()  : array<string|int, mixed>
getPreliminaryReportsForPeriod()  : array<string|int, mixed>|null
getPreliminaryYearlyReport()  : mixed
getReportObligationPeriodMonthsDiff()  : mixed
getReportsSummaries()  : array<string|int, mixed>
getUserReportConfigurations()  : array<string|int, mixed>
Returns array combined of ReportIntention if exists, or an array of ReportObligation.
getUserReportIntentions()  : array<string|int, mixed>
validateEntryReportsForUserReportConfiguration()  : mixed
validatePreliminaryReportsForUserReportConfiguration()  : mixed

Constants

ACTIVE_HANDLERS

public mixed ACTIVE_HANDLERS = [\Vatjar\Export\Component\TransactionVolumeExportHandler::class, \Vatjar\Export\Component\VatReportSummaryExportHandler::class, \Vatjar\Export\Component\MovementMissingCountryExportHandler::class, \Vatjar\Export\Component\StorageDetectionExportHandler::class, \Vatjar\Export\Component\TransactionToGbAfterBrexitExportHandler::class, \Vatjar\Export\Component\GermanYearlyFilingExportHandler::class, \Vatjar\Export\Component\ArrangedUserExportHandler::class, \Vatjar\Export\Component\YearlyTransactionCountExportHandler::class, \Vatjar\Export\Component\ItalianYearlyFilingExportHandler::class]

Properties

$fields

private mixed $fields = ['VP2' => ['vatTypes' => ['DOMV', 'DST', 'DSF', 'ECS', 'EXP', 'DOMREV', 'DEEM'], 'rates' => [], 'calculate' => 'calculateNetValue', 'roundValue' => false, 'roundEveryItem' => false], 'VP3' => ['vatTypes' => ['ECA', 'PUR', 'IMP'], 'rates' => [], 'calculate' => 'calculateNetValue', 'roundValue' => false, 'roundEveryItem' => false], 'VP4' => ['vatTypes' => ['DOMV', 'DST', 'DSF', 'ECS', 'ECA', 'DOMREV'], 'rates' => [4, 10, 22], 'calculate' => 'calculateDifferenceBetweenGrossValueAndNetValue', 'roundValue' => false, 'roundEveryItem' => false], 'VP5' => ['vatTypes' => ['ECA', 'PUR', 'IMP'], 'rates' => [], 'calculate' => 'calculateDifferenceBetweenGrossValueAndNetValue', 'roundValue' => false, 'roundEveryItem' => false], 'VP6' => ['vatTypes' => [], 'rates' => [], 'calculate' => 'calculateVP6', 'roundValue' => false, 'roundEveryItem' => false], 'VP14' => ['vatTypes' => [], 'rates' => [], 'calculate' => 'calculateVP14', 'roundValue' => false, 'roundEveryItem' => false]]

Methods

__construct()

public __construct(UserVatRepository $userVatRepository, ClientRepository $clientRepository, ReportObligationRepository $reportObligationRepository, ReportIntentionRepository $reportIntentionRepository, ReportRepository $reportRepository, EntryReportRepository $entryReportRepository, ClientCreditRepository $clientCreditRepository) : mixed
Parameters
$userVatRepository : UserVatRepository
$clientRepository : ClientRepository
$reportObligationRepository : ReportObligationRepository
$reportIntentionRepository : ReportIntentionRepository
$reportRepository : ReportRepository
$entryReportRepository : EntryReportRepository
$clientCreditRepository : ClientCreditRepository

calculateAll()

public calculateAll(mixed &$property, mixed $summary[, mixed $calculateTotal = false ]) : mixed
Parameters
$property : mixed
$summary : mixed
$calculateTotal : mixed = false

calculateAllDifferences()

public calculateAllDifferences(mixed &$property, mixed $differenceLeftPart, mixed $differenceRightPart) : mixed
Parameters
$property : mixed
$differenceLeftPart : mixed
$differenceRightPart : mixed

calculateDifferenceBetweenFields()

public calculateDifferenceBetweenFields(mixed $field1, mixed $field2) : string
Parameters
$field1 : mixed
$field2 : mixed
Return values
string

filterParams()

public static filterParams(array<string|int, mixed> $params) : array<string|int, mixed>
Parameters
$params : array<string|int, mixed>
Tags
throws
DateMalformedStringException
Return values
array<string|int, mixed>

filterSummaries()

public filterSummaries(mixed $array, mixed $vatTypes, mixed $vatRates) : array<string|int, mixed>
Parameters
$array : mixed
$vatTypes : mixed
$vatRates : mixed
Return values
array<string|int, mixed>

getClient()

public getClient(mixed $clientId, mixed $vatNumber, mixed $taxId) : Client
Parameters
$clientId : mixed
$vatNumber : mixed
$taxId : mixed
Tags
throws
NonUniqueResultException
throws
Exception
Return values
Client

getExportTypes()

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

getLines()

public getLines(array<string|int, mixed> $parameters) : Generator<string|int, array<string|int, string>>
Parameters
$parameters : array<string|int, mixed>
Tags
throws
NonUniqueResultException|ORMException
throws
DateMalformedStringException
throws
DateMalformedPeriodStringException
throws
Exception
Return values
Generator<string|int, array<string|int, string>>

validatePositiveInteger()

public static validatePositiveInteger(mixed $value) : mixed
Parameters
$value : mixed

createFile()

protected createFile() : resource
Tags
throws
ErrorException
throws
Exception
Return values
resource

generateFile()

protected generateFile(resource $file, array<string|int, mixed> $parameters) : void
Parameters
$file : resource
$parameters : array<string|int, mixed>
Tags
throws
Exception

getCloudStorageComponent()

protected getCloudStorageComponent(string $bucket) : mixed
Parameters
$bucket : string

validateBool()

protected static validateBool(mixed $value) : bool
Parameters
$value : mixed
Return values
bool

validateDate()

protected static validateDate(mixed $value) : bool
Parameters
$value : mixed
Return values
bool

validateRequired()

protected static validateRequired(mixed $value) : bool
Parameters
$value : mixed
Return values
bool

validateString()

protected static validateString(mixed $value) : bool
Parameters
$value : mixed
Return values
bool

calculateDifferenceBetweenGrossValueAndNetValue()

private calculateDifferenceBetweenGrossValueAndNetValue(array<string|int, mixed> $summaries[, mixed $roundValue = false ][, mixed $roundEveryItem = true ]) : mixed
Parameters
$summaries : array<string|int, mixed>
$roundValue : mixed = false
$roundEveryItem : mixed = true

calculateNetValue()

private calculateNetValue(array<string|int, mixed> $summaries[, mixed $roundValue = false ][, mixed $roundEveryItem = true ]) : mixed
Parameters
$summaries : array<string|int, mixed>
$roundValue : mixed = false
$roundEveryItem : mixed = true

calculateVP14()

private calculateVP14(array<string|int, mixed> $summaries[, mixed $roundValue = false ][, mixed $roundEveryItem = true ][, mixed $summaryType = null ]) : string
Parameters
$summaries : array<string|int, mixed>
$roundValue : mixed = false
$roundEveryItem : mixed = true
$summaryType : mixed = null
Return values
string

calculateVP6()

private calculateVP6(array<string|int, mixed> $summaries[, mixed $roundValue = false ][, mixed $roundEveryItem = true ][, mixed $summaryType = null ]) : string
Parameters
$summaries : array<string|int, mixed>
$roundValue : mixed = false
$roundEveryItem : mixed = true
$summaryType : mixed = null
Return values
string

getDifferenceBetweenLatestReportVersionSubmittedLineValuesAndLatestPreliminaryReportLineValues()

private getDifferenceBetweenLatestReportVersionSubmittedLineValuesAndLatestPreliminaryReportLineValues(DateTime $date) : array<string|int, mixed>
Parameters
$date : DateTime
Return values
array<string|int, mixed>

getEntryReportsForPeriod()

private getEntryReportsForPeriod(DateTime $date, array<string|int, mixed> $includedPeriods) : mixed
Parameters
$date : DateTime
$includedPeriods : array<string|int, mixed>

getGovernmentCreditForPeriod()

private getGovernmentCreditForPeriod(DateTime $date) : array<string|int, mixed>
Parameters
$date : DateTime
Return values
array<string|int, mixed>

getLatestPreliminaryReportLineValues()

private getLatestPreliminaryReportLineValues(DateTime $date) : array<string|int, mixed>
Parameters
$date : DateTime
Return values
array<string|int, mixed>

getLatestReportVersionSubmittedLineValues()

private getLatestReportVersionSubmittedLineValues(DateTime $date) : array<string|int, mixed>
Parameters
$date : DateTime
Return values
array<string|int, mixed>

getLineDifferenceBetweenTotalFiledAndTotalVJ()

private getLineDifferenceBetweenTotalFiledAndTotalVJ(DateTime $date) : array<string|int, mixed>
Parameters
$date : DateTime
Return values
array<string|int, mixed>

getLinesValues()

private getLinesValues(DateTime $date, int $monthRow) : array<string|int, mixed>
Parameters
$date : DateTime
$monthRow : int
Return values
array<string|int, mixed>

getLineTotalFiled()

private getLineTotalFiled(DateTime $date) : array<string|int, mixed>
Parameters
$date : DateTime
Return values
array<string|int, mixed>

getLineTotalVJ()

private getLineTotalVJ(DateTime $date) : array<string|int, mixed>
Parameters
$date : DateTime
Return values
array<string|int, mixed>

getPreliminaryReportsForPeriod()

private getPreliminaryReportsForPeriod() : array<string|int, mixed>|null
Return values
array<string|int, mixed>|null

getReportObligationPeriodMonthsDiff()

private getReportObligationPeriodMonthsDiff(DatePeriod $reportObligationPeriod) : mixed
Parameters
$reportObligationPeriod : DatePeriod

getReportsSummaries()

private getReportsSummaries(mixed $reportsForPeriod) : array<string|int, mixed>
Parameters
$reportsForPeriod : mixed
Return values
array<string|int, mixed>

getUserReportConfigurations()

Returns array combined of ReportIntention if exists, or an array of ReportObligation.

private getUserReportConfigurations(DateTime $startDate, DateTime $endDate) : array<string|int, mixed>
Parameters
$startDate : DateTime
$endDate : DateTime
Return values
array<string|int, mixed>

validateEntryReportsForUserReportConfiguration()

private validateEntryReportsForUserReportConfiguration(mixed $userReportConfiguration, mixed $entryReportsForSelectedYearAndReportObligation, mixed $reportObligationPeriodMonthsDiff) : mixed
Parameters
$userReportConfiguration : mixed
$entryReportsForSelectedYearAndReportObligation : mixed
$reportObligationPeriodMonthsDiff : mixed
Tags
throws
Exception

validatePreliminaryReportsForUserReportConfiguration()

private validatePreliminaryReportsForUserReportConfiguration(mixed $userReportConfiguration, mixed $preliminaryReportsForSelectedYearAndReportObligation, mixed $reportObligationPeriodMonthsDiff) : mixed
Parameters
$userReportConfiguration : mixed
$preliminaryReportsForSelectedYearAndReportObligation : mixed
$reportObligationPeriodMonthsDiff : mixed
Tags
throws
Exception

        
On this page

Search results