Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

Data Model Questions

ModelAdmin + $summary_fields


Reply

2 Posts   1115 Views

Avatar
danzzz

6 November 2010 at 2:28am Community Member, 175 Posts

hi

I manage 2 models with modeladmin:

// $db array here ...

static $summary_fields = array(
'owner'
);
   
static $has_one = array(
'network' => 'network'
);

// ....

how can I add the "network" value from $has_one to the $summary_fields?

daniel

Avatar
swaiba

6 November 2010 at 3:23am Forum Moderator, 1796 Posts

assuming 'Name' is a $db of network

static $summary_fields = array(
'owner',
'network.Name' => 'network'
);