Cleanup
This commit is contained in:
@ -62,6 +62,13 @@ class Movimiento extends Ideal\Repository
|
||||
->where('cuenta_id = ?');
|
||||
return $this->fetchMany($query, [$cuenta_id]);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param int $cuenta_id
|
||||
* @param DateTimeInterface $fecha
|
||||
* @return array
|
||||
* @throws Implement\Exception\EmptyResult
|
||||
*/
|
||||
public function fetchByCuentaAndFecha(int $cuenta_id, DateTimeInterface $fecha): array
|
||||
{
|
||||
$query = $this->connection->getQueryBuilder()
|
||||
@ -70,6 +77,17 @@ class Movimiento extends Ideal\Repository
|
||||
->where('cuenta_id = ? AND fecha = ?');
|
||||
return $this->fetchMany($query, [$cuenta_id, $fecha->format('Y-m-d')]);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param int $cuenta_id
|
||||
* @param DateTimeInterface $fecha
|
||||
* @param string $glosa
|
||||
* @param int $cargo
|
||||
* @param int $abono
|
||||
* @param int $saldo
|
||||
* @return Model\Contabilidad\Movimiento
|
||||
* @throws Implement\Exception\EmptyResult
|
||||
*/
|
||||
public function fetchByCuentaAndFechaAndGlosaAndCargoAndAbonoAndSaldo(int $cuenta_id, DateTimeInterface $fecha, string $glosa, int $cargo, int $abono, int $saldo): Model\Contabilidad\Movimiento
|
||||
{
|
||||
$len = (int) round(strlen($glosa) * .75);
|
||||
@ -99,6 +117,15 @@ class Movimiento extends Ideal\Repository
|
||||
}
|
||||
return $this->fetchMany($query, [$sociedad_rut, $mes->format('Y-m-01'), $mes->format('Y-m-t')]);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param int $cuenta_id
|
||||
* @param DateTimeInterface $startDate
|
||||
* @param DateTimeInterface $endDate
|
||||
* @param array $idList
|
||||
* @return array
|
||||
* @throws Implement\Exception\EmptyResult
|
||||
*/
|
||||
public function fetchMissingInDateRange(int $cuenta_id, DateTimeInterface $startDate, DateTimeInterface $endDate, array $idList = []): array
|
||||
{
|
||||
$query = $this->connection->getQueryBuilder()
|
||||
|
Reference in New Issue
Block a user