Skip to content

Commit

Permalink
Release hotfix 0.23.4
Browse files Browse the repository at this point in the history
  • Loading branch information
polosson committed Jun 10, 2024
1 parent b91c746 commit 187c59c
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 5 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@ Tous les changements notables sur le projet sont documentés dans ce fichier.

Ce projet adhère au principe du [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## 0.23.4 (2024-06-10)

- Corrige le tri du matériel selon la quantité.

## 0.23.3 (2024-04-11)

- Limite le nombre de vérifications différées simultanées du matériel manquant (2 par défaut).
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.23.3
0.23.4
4 changes: 2 additions & 2 deletions server/src/App/Controllers/MaterialController.php
Original file line number Diff line number Diff line change
Expand Up @@ -135,14 +135,14 @@ public function getAll(Request $request, Response $response): ResponseInterface
if ($orderBy === 'stock_quantity') {
$query
->reorder(
$query->raw('IF(stock_quantity)'),
'stock_quantity',
$ascending ? 'asc' : 'desc',
);
}
if ($orderBy === 'out_of_order_quantity') {
$query
->reorder(
$query->raw('IF(out_of_order_quantity)'),
'out_of_order_quantity',
$ascending ? 'asc' : 'desc',
);
}
Expand Down
4 changes: 2 additions & 2 deletions server/src/App/Models/Material.php
Original file line number Diff line number Diff line change
Expand Up @@ -605,15 +605,15 @@ public function scopeCustomOrderBy(Builder $query, string $column, string $direc
if ($column === 'stock_quantity') {
return $query
->orderBy(
$query->raw('IF(stock_quantity)'),
'stock_quantity',
$direction,
);
}

if ($column === 'out_of_order_quantity') {
return $query
->orderBy(
$query->raw('IF(out_of_order_quantity)'),
'out_of_order_quantity',
$direction,
);
}
Expand Down

0 comments on commit 187c59c

Please sign in to comment.