F
F
FernandoErrNando2016-09-29 12:57:08
Yii
FernandoErrNando, 2016-09-29 12:57:08

Yii2: How to correctly pass ranges for date and numbers to Gridview filters?

Hello, dear Khabrovites. There are several questions about filtering in GridView:
1. There is a numeric field that stores real numbers. How to make the search be in the range from VALUE1 to VALUE2 for a given field? Is there any widget like DateRangePicker for dates?
2. DateRangePicker and date: after selecting filters for the first time and working out the search, the subsequent search does not work for this component.
The component page https://github.com/kartik-v/yii2-date-range/issues/48 has a description of the issue but no working solution. Can you tell me how to overcome this problem?
Thank you all in advance
UPD1: 2 the issue was resolved by disabling pjax, are there any alternative ways?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
M
Maxim Fedorov, 2016-09-29
@qonand

if you already decide to use widgets from kartik (although they are frankly clumsy), then use demos.krajee.com/field-range for this task . It works for both dates and numbers.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question