Mansi

I'm thinking of saving the URL params to a Session variable and then using that for filtering the getList().

Mansi

Without the URL params the $list = $this->getList(); would just return just the default filtered list.

Mansi

On the ModelAdmin class the getEditForm() function makes a first call to ModelAdmin->getList() function.

Mansi

I've pin-pointed issue to this - (and I'm guessing some of it)

  • The ModelAdmin->getList() function gives a default list of records.
  • This is the list that you can edit.
  • When you query for other records, it uses a Get Method - so the query is appended to the URL.
  • When I select a record to edit, the query parameters in the URL are lost.
  • On clicking save, the default results list is displayed in the Main panel of LeftAndMain - All the other DataObjects that are managed by this ModelAdmin are lost from the top nav.
  • I added a die("Test"); call in the onBeforeWrite() function of the NominationUpcomingSourcingEvent but it doesn't reach this line of code.
Mansi

Even in that case, I'm only ever able to edit the 'Recruiting' events.

Mansi

That's what shows me the 'Recruiting' Events by default.