PHP Class ARCates

Author: Jiulong Zhang ([email protected])
Inheritance: extends DBGrouponCates
Show file Open project: yinhe/yincart Class Usage Examples

Public Methods

Method Description
getCateName ( type $id, type $level = null ) : type 根据分类id获取分类名
getCates ( integer $pid, integer $level = self::LEVEL_ONE ) : array 根据父ID和等级获取对应的分类信息
getChildOptionStr ( type $pid, type $level ) : type 获取子分类的下拉选项
model ( $className = __CLASS__ ) 三级分类

Method Details

getCateName() public static method

根据分类id获取分类名
public static getCateName ( type $id, type $level = null ) : type
$id type
$level type
return type

getCates() public static method

根据父ID和等级获取对应的分类信息
public static getCates ( integer $pid, integer $level = self::LEVEL_ONE ) : array
$pid integer
$level integer
return array

getChildOptionStr() public static method

获取子分类的下拉选项
public static getChildOptionStr ( type $pid, type $level ) : type
$pid type
$level type
return type

model() public static method

三级分类
public static model ( $className = __CLASS__ )