Refactor Staff and Store models to use fromMap method; enhance StoreCubit with provider management functionality

This commit is contained in:
2026-04-17 12:40:58 +02:00
parent 22a4f1dac4
commit 08a521c21c
6 changed files with 176 additions and 38 deletions

View File

@@ -24,8 +24,16 @@ class StoreRepository {
.from('store')
.select('''
*,
providers_count:providers_in_stores(count),
staff_members_count:staff_in_stores(count)
associated_providers:providers_in_stores (
provider (
*
)
)
associated_staff:staff_in_stores (
staff_member (
*
)
)
''')
.eq('company_id', companyId)
.order('nome');