コード例 #1
0
ファイル: Content.php プロジェクト: LeeGlendenning/formulize
 public function __construct(&$handler)
 {
     global $contentConfig;
     icms_ipf_Object::__construct($handler);
     $this->quickInitVar('content_id', XOBJ_DTYPE_INT, true);
     $this->quickInitVar('content_pid', XOBJ_DTYPE_INT, false);
     $this->quickInitVar('content_uid', XOBJ_DTYPE_INT, true, false, false, 1);
     $this->quickInitVar('content_title', XOBJ_DTYPE_TXTBOX, true);
     $this->quickInitVar('content_body', XOBJ_DTYPE_TXTAREA);
     $this->quickInitVar('content_css', XOBJ_DTYPE_TXTAREA);
     $this->quickInitVar('content_tags', XOBJ_DTYPE_TXTAREA);
     $this->quickInitVar('content_visibility', XOBJ_DTYPE_INT, true, false, false, CONTENT_CONTENT_VISIBLE_MENUSUBS);
     $this->quickInitVar('content_published_date', XOBJ_DTYPE_LTIME, false);
     $this->quickInitVar('content_updated_date', XOBJ_DTYPE_LTIME);
     $this->quickInitVar('content_weight', XOBJ_DTYPE_INT, true, false, false, 0);
     $this->quickInitVar('content_status', XOBJ_DTYPE_INT, true, false, false, CONTENT_CONTENT_STATUS_PUBLISHED);
     $this->quickInitVar('content_makesymlink', XOBJ_DTYPE_INT, true, false, false, 0);
     $this->quickInitVar('content_showsubs', XOBJ_DTYPE_INT, false, false, false, $contentConfig['show_relateds']);
     $this->quickInitVar('content_cancomment', XOBJ_DTYPE_INT, false, false, false, true);
     $this->quickInitVar('content_comments', XOBJ_DTYPE_INT);
     $this->quickInitVar('content_notification_sent', XOBJ_DTYPE_INT);
     $this->hideFieldFromForm('content_comments');
     $this->hideFieldFromForm('content_notification_sent');
     $this->hideFieldFromSingleView('content_comments');
     $this->hideFieldFromSingleView('content_notification_sent');
     $this->initCommonVar('counter', false);
     $this->initCommonVar('dohtml', false, true);
     $this->initCommonVar('dobr', false, true);
     $this->initCommonVar('doimage', false, true);
     $this->initCommonVar('dosmiley', false, true);
     $this->initCommonVar('doxcode', false, true);
     $this->initNonPersistableVar('content_subs', XOBJ_DTYPE_INT);
     $this->setControl('content_body', 'dhtmltextarea');
     $this->setControl('content_uid', 'user');
     $this->setControl('content_status', array('itemHandler' => 'content', 'method' => 'getContent_statusArray', 'module' => 'content'));
     $this->setControl('content_visibility', array('itemHandler' => 'content', 'method' => 'getContent_visibleArray', 'module' => 'content'));
     $this->setControl('content_pid', array('itemHandler' => 'content', 'method' => 'getContentList', 'module' => 'content'));
     $this->setControl('categories', array('name' => 'categories', 'module' => 'imtagging'));
     $this->setControl('content_makesymlink', 'yesno');
     $this->setControl('content_showsubs', 'yesno');
     $this->setControl('content_cancomment', 'yesno');
     parent::initiateSEO();
 }