@baasix/sdk 0.1.15 → 0.1.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +4 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +4 -1
- package/dist/index.js.map +1 -1
- package/dist/modules/items.cjs +4 -1
- package/dist/modules/items.cjs.map +1 -1
- package/dist/modules/items.d.cts +3 -0
- package/dist/modules/items.d.ts +3 -0
- package/dist/modules/items.js +4 -1
- package/dist/modules/items.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1568,13 +1568,16 @@ var ItemsModule = class {
|
|
|
1568
1568
|
/**
|
|
1569
1569
|
* Restore a soft-deleted item
|
|
1570
1570
|
*
|
|
1571
|
+
* Only works for collections with `paranoid: true`. Clears the `deletedAt`
|
|
1572
|
+
* timestamp so the record reappears in normal queries.
|
|
1573
|
+
*
|
|
1571
1574
|
* @example
|
|
1572
1575
|
* ```typescript
|
|
1573
1576
|
* await items.restore('product-uuid');
|
|
1574
1577
|
* ```
|
|
1575
1578
|
*/
|
|
1576
1579
|
async restore(id) {
|
|
1577
|
-
await this.
|
|
1580
|
+
await this.client.post(`/items/${this.collection}/${id}/restore`);
|
|
1578
1581
|
}
|
|
1579
1582
|
/**
|
|
1580
1583
|
* Aggregate data with grouping
|