Skip to content

Commit

Permalink
Merge pull request #8 from creative-commoners/pulls/master/add-getsum…
Browse files Browse the repository at this point in the history
…marydata-method

Add getSummaryData method to return String for summary section of Ele…
  • Loading branch information
robbieaverill committed Aug 12, 2018
2 parents e3d8d64 + 34d49dc commit bf696bf
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions src/Block/BannerBlock.php
Expand Up @@ -75,6 +75,18 @@ public function getSummary()
return '';
}

/**
* Return content summary for summary section of ElementEditor
*
* @return array
*/
protected function provideBlockSchema()
{
$blockSchema = parent::provideBlockSchema();
$blockSchema['content'] = $this->dbObject('Content')->Summary(20);
return $blockSchema;
}

/**
* Given a set of JSON data, decode it, attach the relevant Page object and return as ArrayData
*
Expand Down

0 comments on commit bf696bf

Please sign in to comment.