Add entity customer numbers and scope APIs via selected company.
Entity gets an optional unique-per-company number with allocate/peek/isNumberFree helpers. Company-scoped store methods no longer take companyId and resolve google_auth.selected_company instead.
This commit is contained in:
@@ -80,7 +80,7 @@ Returns articles for export, optionally scoped to a category, including category
|
||||
|
||||
```js
|
||||
const fn = listExport(pool);
|
||||
const articles = await fn(42, 1, null);
|
||||
const articles = await fn(42, null);
|
||||
// => [{ id, sku, name, slug, unitSi, net, taxRate, eans, categoryBreadcrumbs, fullHashes, ... }]
|
||||
```
|
||||
|
||||
@@ -92,7 +92,7 @@ Returns a lightweight search index of all articles for a company.
|
||||
|
||||
```js
|
||||
const fn = listSearchIndex(pool);
|
||||
const articles = await fn(42, 1);
|
||||
const articles = await fn(42);
|
||||
// => [{ id, sku, name, eans, categoryIds }]
|
||||
```
|
||||
|
||||
|
||||
Reference in New Issue
Block a user