Add Project Files section and show company name for external users on project detail
This commit is contained in:
@@ -0,0 +1,8 @@
|
||||
-- Fix: items insert was blocked when invoice status = 'submitted' at creation time.
|
||||
-- Allow insert on own invoices regardless of status (ownership check is sufficient).
|
||||
drop policy if exists "Sub insert draft invoice items" on public.subcontractor_invoice_items;
|
||||
|
||||
create policy "Sub insert own invoice items" on public.subcontractor_invoice_items
|
||||
for insert with check (
|
||||
invoice_id in (select id from public.subcontractor_invoices where profile_id = auth.uid())
|
||||
);
|
||||
Reference in New Issue
Block a user