added JSVM GeoPointField constructor
This commit is contained in:
parent
33abc0a802
commit
0426722e99
|
@ -1,3 +1,10 @@
|
||||||
|
## v0.27.1 (WIP)
|
||||||
|
|
||||||
|
- Updated API preview example `geoPoint` data.
|
||||||
|
|
||||||
|
- Added JSVM `new GeoPointField({ ... })` constructor.
|
||||||
|
|
||||||
|
|
||||||
## v0.27.0
|
## v0.27.0
|
||||||
|
|
||||||
- ⚠️ Moved the Create and Manage API rule checks out of the `OnRecordCreateRequest` hook finalizer, **aka. now all CRUD API rules are checked BEFORE triggering their corresponding `*Request` hook**.
|
- ⚠️ Moved the Create and Manage API rule checks out of the `OnRecordCreateRequest` hook finalizer, **aka. now all CRUD API rules are checked BEFORE triggering their corresponding `*Request` hook**.
|
||||||
|
|
|
@ -495,6 +495,10 @@ func baseBinds(vm *goja.Runtime) {
|
||||||
instance := &core.FileField{}
|
instance := &core.FileField{}
|
||||||
return structConstructorUnmarshal(vm, call, instance)
|
return structConstructorUnmarshal(vm, call, instance)
|
||||||
})
|
})
|
||||||
|
vm.Set("GeoPointField", func(call goja.ConstructorCall) *goja.Object {
|
||||||
|
instance := &core.GeoPointField{}
|
||||||
|
return structConstructorUnmarshal(vm, call, instance)
|
||||||
|
})
|
||||||
// ---
|
// ---
|
||||||
|
|
||||||
vm.Set("MailerMessage", func(call goja.ConstructorCall) *goja.Object {
|
vm.Set("MailerMessage", func(call goja.ConstructorCall) *goja.Object {
|
||||||
|
|
|
@ -44,7 +44,7 @@ func TestBaseBindsCount(t *testing.T) {
|
||||||
vm := goja.New()
|
vm := goja.New()
|
||||||
baseBinds(vm)
|
baseBinds(vm)
|
||||||
|
|
||||||
testBindsCount(vm, "this", 33, t)
|
testBindsCount(vm, "this", 34, t)
|
||||||
}
|
}
|
||||||
|
|
||||||
func TestBaseBindsSleep(t *testing.T) {
|
func TestBaseBindsSleep(t *testing.T) {
|
||||||
|
@ -399,6 +399,10 @@ func TestBaseBindsNamedFields(t *testing.T) {
|
||||||
"new FileField({name: 'test'})",
|
"new FileField({name: 'test'})",
|
||||||
isType[*core.FileField],
|
isType[*core.FileField],
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"new GeoPointField({name: 'test'})",
|
||||||
|
isType[*core.GeoPointField],
|
||||||
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
for _, s := range scenarios {
|
for _, s := range scenarios {
|
||||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -482,6 +482,16 @@ declare class FileField implements core.FileField {
|
||||||
constructor(data?: Partial<core.FileField>)
|
constructor(data?: Partial<core.FileField>)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
interface GeoPointField extends core.GeoPointField{} // merge
|
||||||
|
/**
|
||||||
|
* {@inheritDoc core.GeoPointField}
|
||||||
|
*
|
||||||
|
* @group PocketBase
|
||||||
|
*/
|
||||||
|
declare class GeoPointField implements core.GeoPointField {
|
||||||
|
constructor(data?: Partial<core.GeoPointField>)
|
||||||
|
}
|
||||||
|
|
||||||
interface MailerMessage extends mailer.Message{} // merge
|
interface MailerMessage extends mailer.Message{} // merge
|
||||||
/**
|
/**
|
||||||
* MailerMessage defines a single email message.
|
* MailerMessage defines a single email message.
|
||||||
|
|
Loading…
Reference in New Issue