Skip to content

Commit

Permalink
Merge pull request #752 from portabilis/portabilis-patch-2021-02-12
Browse files Browse the repository at this point in the history
[2.5] Portabilis patch 12/02/2021
  • Loading branch information
edersoares authored Feb 16, 2021
2 parents 122c317 + 97a3ffb commit 0937d4f
Show file tree
Hide file tree
Showing 31 changed files with 983 additions and 1,013 deletions.
2 changes: 1 addition & 1 deletion app/Console/Commands/DatabaseRestoreCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ private function dropAndCreateDatabase($database)
*/
private function restoreDatabaseUsingBackupFile($database, $filename)
{
$definition = 'pg_restore -L %s --host=%s --port=%s --username=%s --dbname=%s %s';
$definition = 'pg_restore -L %s --host=%s --port=%s --username=%s --dbname=%s %s --no-privileges --no-owner';

$command = sprintf(
$definition,
Expand Down
6 changes: 5 additions & 1 deletion app/Http/Controllers/UpdateRegistrationStatusController.php
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ public function index(Request $request)
*/
public function updateStatus(UpdateRegistrationStatusRequest $request, RegistrationService $registrationService)
{
$query = LegacyRegistration::active();
$query = LegacyRegistration::query()->where('pmieducar.matricula.ativo', 1);

if ($request->get('ano')) {
$query->where('ano', $request->get('ano'));
Expand All @@ -65,6 +65,10 @@ public function updateStatus(UpdateRegistrationStatusRequest $request, Registrat

$query->where('aprovado', $request->get('situacao'));

$query->join('pmieducar.matricula_turma', 'matricula.cod_matricula', '=', 'matricula_turma.ref_cod_matricula')
->where('matricula_turma.ativo', 1);


$registrations = $query->get();

DB::beginTransaction();
Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"description": "Software livre de gestão escolar",
"type": "project",
"license": "GPL-2.0-or-later",
"version": "2.5.2",
"version": "2.5.3",
"keywords": [
"Portabilis",
"i-Educar"
Expand Down
Loading

0 comments on commit 0937d4f

Please sign in to comment.