Add title sections to invoices backend and frontend, #41

This commit is contained in:
2025-11-19 10:12:45 +01:00
parent 250c4538aa
commit d1656b56a0
7 changed files with 80 additions and 31 deletions
+4 -2
View File
@@ -405,7 +405,8 @@ public function store(Request $request)
'title' => 'nullable|string',
'text' => 'nullable|string',
'items' => 'nullable|array',
'items.*.position' => 'required|integer',
'items.*.isSection' => 'nullable|boolean',
'items.*.position' => 'required|numeric',
'items.*.title' => 'nullable|string',
'items.*.description' => 'nullable|string',
'items.*.quantity' => 'nullable|numeric',
@@ -491,7 +492,8 @@ public function update(Request $request, $id)
'text' => 'nullable|string',
'items' => 'nullable|array',
'items.*.id' => 'nullable|integer',
'items.*.position' => 'required|integer',
'items.*.isSection' => 'nullable|boolean',
'items.*.position' => 'required|numeric',
'items.*.title' => 'nullable|string',
'items.*.description' => 'nullable|string',
'items.*.quantity' => 'nullable|numeric',
+1
View File
@@ -12,6 +12,7 @@ class LineItem extends Model
protected $fillable = [
'invoice_id',
'position',
'is_section',
'title',
'description',
'quantity',