v0.4.0
版本发布时间: 2022-08-11 17:09:40
pocketbase/pocketbase最新发布版本:v0.22.21(2024-09-18 11:56:49)
Changes
-
Added support for import/export of collections configuration.
:warning: This feature is still experimental, so use it cautiously and always have a backup of your
pb_data
before applying the import!-
Added new API endpoint to bulk import collections.
-
Updated the JavaScript and Dart SDKs accordingly with the new endpoint
client.collections.import(...)
. -
Added new Import/Export section in the Admin UI > Settings. When importing you'll be able to "Review" your changes with a side-by-side diff before sending them to the server. Validations on the imported collections, eg. missing required fields, are done only server side after submitting the import form. The import is executed within a transaction and it is applied only after all imported collections changes are applied successfully.
-
Added migration command to export the local collections configuration into a migration file
go run main.go migrate collections
NB! This will works only for new project - more info on the caveats you could find in the DB Migrations guide.
-
-
All resource endpoints (records, collections, admins, users, etc.) now support specifying an optional custom insertion id during create (it must be a fixed 15 chars string) to allow handling offline first data structures [#246].
-
The realtime create and update hooks are now fired when updating a record manually with the
Dao
-
All examples are updated to use
127.0.0.1
instead oflocalhost
because thelocalhost
hostname may not be available on some Windows installations and on some platforms could resolve differently (Node17+ for example has higher priority for the ipv6 version [::1], which could lead to connection failure - pocketbase/js-sdk#21). -
Added totalPages field in the api response (the SDKs were also updated to reflect the change in the result object dto).
-
Added the build version number in the Admin UI footer (#280).
-
Updated the Thumbs file option tooltip to include info about the default/system
100x100
thumb (thanks @ollema). -
Internals:
-
Added
OnCollectionsBeforeImportRequest
andOnCollectionsAfterImportRequest
hooks. -
Updated the
base.Model
interface with additionalMarkAsNew
andUnmarkAsNew
for finer control over the upsert operations on existing models. -
Added
form.*WithConfig(...)
factory to allforms
models to allow nesting and running multiple forms within a single DB transaction -
The
OnModelAfter*
hooks for transactions are now fired only after a successful transaction commit (in the order they were initially called during the transaction). -
Other minor code and tests improvements.
-
1、 checksums.txt 699B
2、 pocketbase_0.4.0_darwin_amd64.zip 11.87MB
3、 pocketbase_0.4.0_darwin_arm64.zip 11.54MB
4、 pocketbase_0.4.0_linux_amd64.zip 11.46MB
5、 pocketbase_0.4.0_linux_arm64.zip 10.68MB
6、 pocketbase_0.4.0_linux_armv7.zip 10.94MB
7、 pocketbase_0.4.0_windows_amd64.zip 11.61MB
8、 pocketbase_0.4.0_windows_arm64.zip 10.8MB