コード例 #1
0
ファイル: InfoAbstract.php プロジェクト: larryu/magento-b2b
 /**
  * removing all the information object
  * 
  * @param InfoEntityAbstract $entity
  * @param InfoTypeAbstract   $type
  * 
  * @return Ambigous <multitype:, multitype:BaseEntityAbstract >
  */
 public static function remove(InfoEntityAbstract $entity, InfoTypeAbstract $type = null)
 {
     $where = StringUtilsAbstract::lcFirst(str_replace('Info', '', get_called_class())) . 'Id = ?';
     $params = array($entity->getId());
     if ($type instanceof InfoTypeAbstract) {
         $where .= ' AND typeId = ?';
         $params[] = $type->getId();
     }
     self::updateByCriteria('active = 0', $where, $params);
 }
コード例 #2
-2
ファイル: OrderInfoType.php プロジェクト: larryu/magento-b2b
 /**
  * (non-PHPdoc)
  * @see BaseEntity::__loadDaoMap()
  */
 public function __loadDaoMap()
 {
     DaoMap::begin($this, 'oinfo_type');
     parent::__loadDaoMap();
     DaoMap::commit();
 }