Align store calls with selected-company scoping and add entity numbers.
Drop companyId from company-scoped store wrappers and routes, add GET /entity/next-number plus optional number on entity create/update, and document dashdbschema API.md lookup in sibling-repos.
This commit is contained in:
@@ -1,21 +1,21 @@
|
||||
import { getStore } from './store.js';
|
||||
|
||||
export async function list(googleAuthId, companyId, entityId) {
|
||||
export async function list(googleAuthId, entityId) {
|
||||
const store = await getStore();
|
||||
return store.entityaddress.list(googleAuthId, companyId, entityId);
|
||||
return store.entityaddress.list(googleAuthId, entityId);
|
||||
}
|
||||
|
||||
export async function create(googleAuthId, companyId, entityId, data) {
|
||||
export async function create(googleAuthId, entityId, data) {
|
||||
const store = await getStore();
|
||||
return store.entityaddress.create(googleAuthId, companyId, entityId, data);
|
||||
return store.entityaddress.create(googleAuthId, entityId, data);
|
||||
}
|
||||
|
||||
export async function update(googleAuthId, companyId, entityId, id, data) {
|
||||
export async function update(googleAuthId, entityId, id, data) {
|
||||
const store = await getStore();
|
||||
return store.entityaddress.update(googleAuthId, companyId, entityId, id, data);
|
||||
return store.entityaddress.update(googleAuthId, entityId, id, data);
|
||||
}
|
||||
|
||||
export async function remove(googleAuthId, companyId, entityId, id) {
|
||||
export async function remove(googleAuthId, entityId, id) {
|
||||
const store = await getStore();
|
||||
return store.entityaddress.delete(googleAuthId, companyId, entityId, id);
|
||||
return store.entityaddress.delete(googleAuthId, entityId, id);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user