5541 Posts in 1738 Topics by 1224 members
|Go to End|
11 May 2010 at 10:13am
i got a problem that there are wrong datarecords displayed in one Models Results. I got Countries which has_many Schools and one School has_one Country. But in ModelAdmin results (just in some countries) are Schools listet which are related to another country than the selectet. I checked the database entries for both schools and countries and the relations are setup correctly there.. One School got one CountryID and only exists once, but some schools are shown in different Countries.
Couldnt find out anything about that problem in the Internet.
Did somebody experience a similar problem with perhaps possible cause of that error ? Perhaps a ModelAdmin Bug ?
thanks in advance
19 May 2010 at 11:20am
Nobody got an advice? really stuck with that...
I attached an example screenshot to this post. There u can see we are in the Country "Angleterre", but the first two Schools/Cities are in Spain (The database entries / relations are pointing to the correct ID(Spain) from these Schools!!). The Entry(Result Count) is wrong too. There are no 30 Entries in the Displayed Resultset...
any ideas ?
20 May 2010 at 11:01am
im getting a step forward with that..
i know where the error comes from, but not how to solve it.
The error appears only in Schools which CountryID >= 10
and for example:
in ModelAdmin when i select the School
-> with ID 1 -> Entries from ID 10 and 13 are shown in the result table( + the correct entries with ID 1)
-> with ID 2 -> Entries from ID 12 are shown in the result table (+ the correct entries with ID 2)
-> with ID 3 -> Entries from ID 13 are shown (+ the correct entries with ID 3)
Does that help you to help me ? ;)
20 May 2010 at 1:30pm
the problem was that the default Filter for searchable_fields = PartialMatchFilter. So the search found everthing LIKE %ID%
static $searchable_fields = array(
'Country.ID' => 'ExactMatchFilter'
|Go to Top|