kitar / laravel-dynamodb

A DynamoDB based Eloquent model and Query builder for Laravel.
MIT License
179 stars 27 forks source link

Enum support on query builder #37

Open reyadrian opened 1 year ago

reyadrian commented 1 year ago

Having a support enum as a value in the query builder would be nice, just like the model.

i.e. Transaction::filter('status', '=', StatusEnum::SUCCESS)->scan();

Instead of doing this, stating the string: Transaction::filter('status', '=', StatusEnum::SUCCESS->value)->scan();

kitar commented 1 year ago

Hi @reyadrian , thank you for your suggestion :)

It looks promising, but I think we might need to stop supporting older versions of Eloquent (< 8.x) to implement it smoothly. I'll give this some thought.