2 // $Id: NewPressReleaseView_inline.class.php,v 1.1 2006/03/10 11:45:41 w-ota Exp $
4 class NewPressReleaseInputView extends BaseView
6 public function execute ()
8 $context = &$this->getContext();
9 $user = $context->getUser();
10 $request = $context->getRequest();
11 $acs_user_info_row = $user->getAttribute('acs_user_info_row');
14 $new_bbs_for_press_release_row_array = $request->getAttribute('new_bbs_for_press_release_row_array');
17 foreach ($new_bbs_for_press_release_row_array as $index => $new_bbs_row) {
18 $new_bbs_for_press_release_row_array[$index]['top_page_url'] = $this->getControllerPath('Community', DEFAULT_ACTION) . '&community_id=' . $new_bbs_row['community_id'];
19 $new_bbs_for_press_release_row_array[$index]['bbs_res_url'] = $this->getControllerPath('Community', 'BBSRes') . '&community_id=' . $new_bbs_row['community_id'] . '&bbs_id=' . $new_bbs_row['bbs_id'];
20 if ($new_bbs_row['file_id']) {
21 $new_bbs_for_press_release_row_array[$index]['file_url'] = ACSBBSFile::get_image_url($new_bbs_row['bbs_id'], 'thumb'); // ¥µ¥à¥Í¥¤¥ë
22 $new_bbs_for_press_release_row_array[$index]['file_url_alink'] = ACSBBSFile::get_image_url($new_bbs_row['bbs_id'], ''); // ¥Ý¥Ã¥×¥¢¥Ã¥×ÍÑ
24 $new_bbs_for_press_release_row_array[$index]['post_date'] = ACSLib::convert_pg_date_to_str($new_bbs_row['post_date'], 1, 0);
28 $this->setAttribute('new_bbs_for_press_release_row_array', $new_bbs_for_press_release_row_array);
30 // ¥Æ¥ó¥×¥ì¡¼¥È¤ò¥»¥Ã¥È¤¹¤ë
31 $this->setTemplate('NewPressRelease.tpl.php');
32 $context->getController()->setRenderMode(View::RENDER_VAR);
33 $request->setAttribute("NewPressRelease", $this->render());
35 return parent::execute();