Merge branch 'WarehouseShippingNote/fix-km-count' into 'master'

-

See merge request fronk/thetool!1288
This commit is contained in:
Luca Haid
2025-05-05 10:09:12 +00:00
2 changed files with 3 additions and 2 deletions

View File

@@ -245,7 +245,7 @@ class WarehouseShippingNoteController extends TTCrud {
'articleTitle' => "Fahrkostenpauschale (hin und retour)",
'articleDescription' => "Datum: ". date("d.m.Y", strtotime($hoursEntry['date'])) . " | Externes Fahrzeug",
'articleUnit' => 'km',
'amount' => $hoursEntry['kilometerCount'] * 2,
'amount' => $hoursEntry['kilometerCount'],
'price' => 2 * $hoursEntry['kilometerCount'] ?? 0,
];
} else if (!empty($hoursEntry['carId']) && $hoursEntry['kilometerCount'] > 0) {

View File

@@ -23,7 +23,8 @@ Vue.component('tt-resolver', {
const { data } = await axios.get(endpoint);
this.text = this.autocomplete ? data[0]?.text : data.name ?? data.title ?? data.text ?? '[E] Key not found';
if (this.reference === 'WarehouseArticle') this.text = `${data.articleNumber} | ${data.title}`;
else this.text = this.autocomplete ? data[0]?.text : data.name ?? data.title ?? data.text ?? '[E] Key not found';
this.loading = false;
}
});