Skip to content
Snippets Groups Projects
Commit cb7b46c0 authored by Fatih Uzunoğlu's avatar Fatih Uzunoğlu
Browse files

qt: make limit=0 behave limit=0 in `BaseModel`

limit=0 having special value, such as loading
all items is not intuitive. limit=0 should
behave as limit is 0, as what it suggests.

Not only that but it also means we need two
special values to (current case):

- Not load any items. (any negative number?)
- Load all items. (limit=0)

Where as if limit=0 behaves as limit=0,
we need only one special value to load all
items. I propose any arbitrary negative
number.

The current situation also makes mapping
more complicated, for example with a view
that has a property `itemCountToShow`, we
can not simply map `limit: view.itemCountToShow`,
because when `itemCountToShow` is 0, this
would cause the model to load all items.
parent d1ee4f1d
No related branches found
No related tags found
Loading
Pipeline #576988 passed with stage
in 18 minutes and 37 seconds
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment