woru

Results 23 comments of woru

'with' for Model::findById does not make any sense (loading of lazy relation results in an additional query as well).

I mean join roles and groups, not users, roles and groups

``` php User::where([ 'registration_date' => Restrictions::any(Restrictions::graterThan($from), Restrictions::lessThan($to)) ]); ``` results in 'OR'. We need something like: ``` php User::where([ 'registration_date' => Restrictions::all(Restrictions::graterThan($from), Restrictions::lessThan($to)) ]); ``` Restrictions::any will return a composite...

Remove `except` option from `allowAll()` (which should also be removed) - one less regexp. Remove `allowAll()` from docs. Replace regexps with `strstr()` where possible. If route does not contain parameters...

maybe `Route::group()` should really group route rules and evaluate them only if the prefix matches. That way we could group routes in our app and have less rules to evaluate.

We should definitely implement `Route::group()` and `Route::resource()` as aggregates. I replaced one allowAll with 7 routes in panel. If we removed all allowAlls we would have roughly 29x7 more routes...

change routes parsing to prefix tree. console ouzo:routes -g should generate a file with a prefix tree. /customers /customers/add /customers/add/comment /customers/search /customers/:id /customers/:id/add_product/:prod_id ``` php $a = [ 'GET' =>...

https://github.com/letsdrink/ouzo/commit/3804d41f097db57f6f587f932ef6a1fb431219a9

Problem: hasMany and hasOne Currently, when save is called only one object is saved. If User had a hasOne relation to Customer ``` php $user->customer = Customer::create([...]); $user->update(); ``` would...