...
|
...
|
@@ -53,9 +53,10 @@ class ListProcess |
|
|
*
|
|
|
* @param $data
|
|
|
* @param string | integer $gender 默认选择的性别,默认1,2,3表示所有
|
|
|
* @param null|string $exclude 需要排除的字段
|
|
|
* @return array 处理之后的筛选数据
|
|
|
*/
|
|
|
public static function getFilterData($data, $gender = '1,2,3')
|
|
|
public static function getFilterData($data, $gender = '1,2,3', $exclude = null)
|
|
|
{
|
|
|
// 过滤条件数据
|
|
|
$filters = array('classify' => array());
|
...
|
...
|
@@ -65,12 +66,10 @@ class ListProcess |
|
|
|
|
|
$num = 1;
|
|
|
foreach ($data as $key => $val) {
|
|
|
if (empty($val)) {
|
|
|
continue;
|
|
|
}
|
|
|
if (!is_callable("self::$key")) {
|
|
|
if ($key === $exclude || empty($val) || !is_callable("self::$key")) {
|
|
|
continue;
|
|
|
}
|
|
|
|
|
|
$build = self::$key($val, $gender);
|
|
|
if ($num === 1) {
|
|
|
$build['active'] = true;
|
...
|
...
|
|