20231109 Meeting Feedback 1 Fixes for warehouse storage charges

This commit is contained in:
Dillon Ngo
2023-11-16 22:40:26 +08:00
parent ce94dd1393
commit 76e3668563
31 changed files with 1105 additions and 148 deletions
+8
View File
@@ -89,6 +89,14 @@ class Transaction extends AbstractModel implements Documentable, Transactionable
return $this->BelongsToMany(Group::class, GroupTransaction::class, 'transaction_id');
}
/**
* @return BelongsToMany
*/
public function groupsWithTrashed(): BelongsToMany
{
return $this->BelongsToMany(Group::class, GroupTransaction::class, 'transaction_id')->withTrashed();;
}
public function convert_original_amount()
{
if($this->booking()->first()->fix_currency_id !== 1) {