当前位置: 首页>>代码示例>>PHP>>正文


PHP XenForo_DataWriter::_postSave方法代码示例

本文整理汇总了PHP中XenForo_DataWriter::_postSave方法的典型用法代码示例。如果您正苦于以下问题:PHP XenForo_DataWriter::_postSave方法的具体用法?PHP XenForo_DataWriter::_postSave怎么用?PHP XenForo_DataWriter::_postSave使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在XenForo_DataWriter的用法示例。


在下文中一共展示了XenForo_DataWriter::_postSave方法的12个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: _postSave

 protected function _postSave()
 {
     parent::_postSave();
     if ($this->getOption(self::OPTION_UPDATE_CATEGORY)) {
         $this->rebuildCategoryCounter();
     }
 }
开发者ID:NixFifty,项目名称:XenForo-SimplePortal,代码行数:7,代码来源:PortalItem.php

示例2: _postSave

 protected function _postSave()
 {
     /* @var $userScopeModel bdApi_Model_UserScope */
     $userScopeModel = $this->getModelFromCache('bdApi_Model_UserScope');
     $userScopeModel->updateUserScopes($this->getMergedData());
     parent::_postSave();
 }
开发者ID:billyprice1,项目名称:bdApi,代码行数:7,代码来源:Token.php

示例3: _postSave

 protected function _postSave()
 {
     if ($this->isInsert() or $this->isChanged('tag_text')) {
         $this->_rebuildCache();
     }
     return parent::_postSave();
 }
开发者ID:Sywooch,项目名称:forums,代码行数:7,代码来源:Tag.php

示例4: _postSave

 protected function _postSave()
 {
     if ($this->getOption(self::OPTION_UPDATE_CALLBACKS)) {
         $this->_getSubscriptionModel()->updateCallbacksForTopic($this->get('topic'));
     }
     parent::_postSave();
 }
开发者ID:billyprice1,项目名称:bdApi,代码行数:7,代码来源:Subscription.php

示例5: _postSave

 protected function _postSave()
 {
     $this->getModelFromCache('XenForo_Model_Permission')->rebuildPermissionCache();
     // insert a dummy page
     $pageDw = XenForo_DataWriter::create('LiquidPro_SimpleForms_DataWriter_Page');
     $pageDw->bulkSet(array('form_id' => $this->get('form_id'), 'page_number' => 1, 'title' => '', 'description' => ''));
     $pageDw->save();
     parent::_postSave();
 }
开发者ID:Mirovinger,项目名称:xenforo-simple-forms,代码行数:9,代码来源:Form.php

示例6: _postSave

 protected function _postSave()
 {
     if ($this->isInsert()) {
         // insert a dummy page
         $pageDw = XenForo_DataWriter::create('LiquidPro_SimpleForms_DataWriter_Page');
         $pageDw->bulkSet(array('form_id' => $this->get('form_id'), 'page_number' => 1, 'title' => '', 'description' => ''));
         $pageDw->save();
     }
     parent::_postSave();
 }
开发者ID:jljr222,项目名称:xenforo-simple-forms,代码行数:10,代码来源:Form.php

示例7: _postSave

 protected function _postSave()
 {
     $this->updateFields();
     if ($this->_executeDestinations) {
         $destinationModel = $this->_getDestinationModel();
         $destinationOptionModel = $this->_getDestinationOptionModel();
         // attachment handling
         $attachmentHash = $this->getExtraData(self::DATA_ATTACHMENT_HASH);
         if ($attachmentHash) {
             $attachmentModel = $this->_getAttachmentModel();
             $attachments = $attachmentModel->getAttachmentsByTempHash($attachmentHash);
         }
         // redirect handling
         $form = $this->_getFormModel()->getFormById($this->get('form_id'));
         $redirectDestination = null;
         if ($form['redirect_method'] == 'destination') {
             $redirectDestination = $form['redirect_destination'];
         }
         // get the destinations for a form and loop through them to handle them if necessary
         $destinations = $destinationModel->getDestinationsByFormId($form['form_id']);
         foreach ($destinations as $destination) {
             // only handle active destinations
             if ($destination['active']) {
                 // get the destination options
                 $destinationOptions = $destinationOptionModel->prepareDestinationOptions($destinationOptionModel->getDestinationOptionsByFormDestinationId($destination['form_destination_id']), true);
                 // create the destination
                 $formDestination = new $destination['handler_class']($form['form_id'], $this->_updateFields, $destinationOptions, null, $this->get('response_id'));
                 // handle attachments
                 if ($destinationOptionModel->getAttachmentsEnabled($form['form_id']) && $attachments) {
                     // create new temporary hash
                     $newAttachmentHash = md5(uniqid('', true));
                     // duplicate the attachment so others can use it
                     foreach ($attachments as $attachmentId => $attachment) {
                         $duplicateAttachmentId = $attachmentModel->insertTemporaryAttachment($attachment['data_id'], $newAttachmentHash);
                     }
                     $formDestination->setAttachmentHash($attachmentId, $duplicateAttachmentId, $newAttachmentHash);
                 }
                 // save the destination
                 $formDestination->save();
                 // get the redirect url from the destination
                 if (isset($redirectDestination) && $destination['form_destination_id'] == $redirectDestination) {
                     $redirectMethod = $destination['redirect_method'];
                     $this->_redirectUrl = $formDestination->{$redirectMethod}();
                 }
             }
         }
         // delete the temporary attachment hash
         if ($attachmentHash) {
             foreach ($attachments as $attachmentId => $attachment) {
                 $dw = XenForo_DataWriter::create('XenForo_DataWriter_Attachment');
                 $dw->setExistingData($attachment);
                 $dw->delete();
             }
         }
     }
     parent::_postSave();
 }
开发者ID:Mirovinger,项目名称:xenforo-simple-forms,代码行数:57,代码来源:Response.php

示例8: _postSave

 protected function _postSave()
 {
     $this->updateDestinationOptions();
     $this->getModelFromCache('XenForo_Model_Permission')->rebuildPermissionCache();
     parent::_postSave();
 }
开发者ID:Mirovinger,项目名称:xenforo-simple-forms,代码行数:6,代码来源:FormDestination.php

示例9: _postSave

 protected function _postSave()
 {
     $this->_insertOrUpdateMasterPhrase($this->_getWidgetModel()->getWidgetTitlePhrase($this->get('widget_id')), $this->get('title'), '', array('global_cache' => 1));
     if ($this->_isTemplateWidget($this->get('class'))) {
         $this->_getWidgetRendererTemplateModel()->dwPostSave($this->getMergedData(), $this->getWidgetOptions());
     } elseif ($this->isChanged('class') && $this->_isTemplateWidget($this->getExisting('class'))) {
         $this->_getWidgetRendererTemplateModel()->dwPostDelete($this->getMergedExistingData(), $this->getWidgetOptions(true));
     }
     parent::_postSave();
 }
开发者ID:maitandat1507,项目名称:bdWidgetFramework,代码行数:10,代码来源:Widget.php

示例10: _postSave

 protected function _postSave()
 {
     $this->updateDestinationOptions();
     parent::_postSave();
 }
开发者ID:jljr222,项目名称:xenforo-simple-forms,代码行数:5,代码来源:FormDestination.php

示例11: _postSave

 protected function _postSave()
 {
     parent::_postSave();
     $this->_insertIntoSearchIndex();
 }
开发者ID:billyprice1,项目名称:bdApi,代码行数:5,代码来源:ClientContent.php

示例12: _postSave

 protected function _postSave()
 {
     $this->_updateTag($this->isInsert() ? 1 : 0);
     return parent::_postSave();
 }
开发者ID:Sywooch,项目名称:forums,代码行数:5,代码来源:TaggedContent.php


注:本文中的XenForo_DataWriter::_postSave方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。