added main picture for widget

This commit is contained in:
Harry Bomrah 2014-12-03 18:02:47 +08:00
parent 363fafaa98
commit 1e74ee2a4c
1 changed files with 4 additions and 0 deletions

View File

@ -65,8 +65,12 @@ class AnnouncementsController < ApplicationController
"img_description" => a.image_description
}
end
mp = (anns[0]["img_src"] rescue "")
mpd = (anns[0]["img_description"] rescue "")
{
"announcements" => anns,
"main_picture" => mp,
"main_picture_description" => mpd,
"extras" => {
"more_url"=>OrbitHelper.widget_more_url,
"title-head" => t('announcement.table.title'),