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


PHP ActiveRecordModel::serialize方法代码示例

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


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

示例1: serialize

 public function serialize($skippedRelations = array(), $properties = array())
 {
     if ($this->getOwner()) {
         $skippedRelations[] = $this->getInstanceField($this->getOwner());
     }
     return parent::serialize($skippedRelations, $properties);
 }
开发者ID:saiber,项目名称:livecart,代码行数:7,代码来源:EavObject.php

示例2: serialize

 public function serialize($skippedRelations = array(), $properties = array())
 {
     $properties[] = 'specificationInstance';
     return parent::serialize($skippedRelations, $properties);
 }
开发者ID:saiber,项目名称:www,代码行数:5,代码来源:User.php

示例3: serialize

 public function serialize($skippedRelations = array(), $properties = array())
 {
     $properties[] = 'specificationInstance';
     $properties[] = 'serializedState';
     // for some reason directly unserializing State class causes a segfault...
     if ($this->state->get()) {
         $this->serializedState = $this->state->get()->getID();
         $this->state->setNull();
     }
     return parent::serialize($skippedRelations, $properties);
 }
开发者ID:saiber,项目名称:livecart,代码行数:11,代码来源:UserAddress.php

示例4: serialize

 public function serialize($skippedRelations = array(), $properties = array())
 {
     $properties[] = 'specificationInstance';
     foreach (array('defaultShippingAddressID', 'defaultBillingAddressID') as $addr) {
         $skippedRelations[] = $addr;
         $addr = substr($addr, 0, -2);
         $key = 'addr_' . $addr;
         if ($this->{$addr}->get()) {
             $this->{$key} = $this->{$addr}->get()->userAddress->get();
             $properties[] = $key;
         }
     }
     return parent::serialize($skippedRelations, $properties);
 }
开发者ID:saiber,项目名称:livecart,代码行数:14,代码来源:User.php

示例5: serialize

 public function serialize()
 {
     return parent::serialize(array('userID'), array('orderedItems', 'shipments'));
 }
开发者ID:saiber,项目名称:www,代码行数:4,代码来源:CustomerOrder.php

示例6: serialize

 public function serialize()
 {
     $this->itemIds = array();
     foreach ($this->items as $item) {
         $this->itemIds[] = $item->getID();
     }
     return parent::serialize(array('orderID'), array('itemIds', 'availableShippingRates', 'selectedRateId'));
 }
开发者ID:saiber,项目名称:livecart,代码行数:8,代码来源:Shipment.php

示例7: serialize

 public function serialize()
 {
     return parent::serialize(array('userID'));
 }
开发者ID:saiber,项目名称:livecart,代码行数:4,代码来源:UserAddressType.php


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