Skip to content

Releases: gearbox-solutions/eloquent-filemaker

2.4.2

12 Jun 17:59
cdfd2af

Choose a tag to compare

Fix to prevent mutators from being fired when loading data from FileMaker into a model

2.4.1

05 Jun 18:02

Choose a tag to compare

This release fixes backwards compatibility with Laravel 10 by checking that Http::createPendingRequest exists before calling it.

2.4.0

05 Jun 12:34

Choose a tag to compare

In this release:

  • adds the MorphTo Relationship to the FMHasRelationship trait
  • The MorphTo relationship class resolves wether to handle the models as FM query or pass it to the default Eloquent Model.

2.3.2

01 Jun 19:34
631f2ec

Choose a tag to compare

Changed FileMakerDataApiException to always include the layout name in the error message for easier debugging.

2.3.1

29 May 18:17
4d556fb

Choose a tag to compare

Use Http facade for requests to improve compatibility with Telescope and other frameworks.

2.3.0

24 May 20:30

Choose a tag to compare

This release reworks FMModel's relationship resolution allowing developers to use the model's native relationship methods to connect to other FileMaker Models as well as Models backed by other database drivers. Also, we introduced a new trait that can be used on regular Models to allow proper relationship resolution to FMModels.

Previously you had to this:

// User.php

class User extends Model
{
    public function company()
    {
        // The Company class is an FMModel and is stored in FileMaker
        return new \GearboxSolutions\EloquentFileMaker\Database\Eloquent\Relations\BelongsTo(Company::query(), $this, 'company_id', 'id', '');
    }
}

Now you can do:

// User.php

use GearboxSolutions\EloquentFileMaker\Database\Eloquent\Concerns\HasHybridRelationships;

class User extends Model
{
    use HasHybridRelationships;
    
    public function company()
    {
        // The Company class is an FMModel and is stored in FileMaker
        // The correct relationship will be resolved automatically thanks to the HasHybridRelationships trait
        return $this->belongsTo(Company::class, 'company_id', 'id');
    }
}

2.2.5

23 May 17:19

Choose a tag to compare

This release fixes an issue where calling a queryScope and then calling where or whereIn causes an extra find request resulting in erroneous data.

Ex:

Model::where('field', 'value')
    ->myScope()
    ->whereIn('field', ['value 1', 'value 2'])

2.2.4

02 May 20:59
238d9b2

Choose a tag to compare

Fixed orWhere being dropped when appended after a where.

2.2.3

29 Apr 22:18
c806cfa

Choose a tag to compare

Changed error throwing to process later instead of in retry, avoiding error with records not found

2.2.2

29 Apr 20:33
8be85c8

Choose a tag to compare

Adjusted retries so that it will actually attempt more than once.