我的粉丝
@param int $id
@return string
499916
public function actionFollower($id)
    {
        $model = $this->findModel($id);
        $dataProvider = new ActiveDataProvider([
            'query' => $model->getFans()->orderBy(['created_at' => SORT_DESC]),
        ]);
        return $this->render('follower', [
            'model' => $model,
            'dataProvider' => $dataProvider
        ]);
    }
719646
public function getPHPIdentifierValue($id)
    {
        $idType = $this->fieldMappings[$this->identifier]['type'];
        return Type::getType($idType)->convertToPHPValue($id);
    }
947902
final public function save($id = '')
    {
        $pkval = $id ?: $this->pkval;
        //有修改的数据
        if ($this->_setpost && $pkval) {
            //排除不修改的字段
            foreach ($this->exclude as $key => $exclude) {
                if (isset($this->_setpost[$key]) || $key == $this->pk) {
                    unset($this->_setpost[$key]);
                }
            }
            return $this->where($this->pk, '=', $pkval)->update($this->_setpost);
        }
        //保存新数据
        if ($this->_post) {
            return $this->insert($this->_post);
        }
        return null;
    }
457070
protected function _getById($id) {
		$model = $this->_config['model'];
		return $model::find('first', ['conditions' => [$model::key() => $id]]);
	}
76472
public function AnimeMoreInfo(int $id): ?string
    {
        return $this->myanimelist->getAnimeMoreInfo(
            new Request\Anime\AnimeMoreInfoRequest($id)
        );
    }
374571
public function get($id)
    {
        if (isset($this->services[$id]) && $this->shareds[$id]) {
            return $this->services[$id];
        }
        
        if (!$this->has($id)) {
            throw new Exception('not exists id: ' . $id);
        }

        // 实例创建的参数
        $args = $this->params[$id];

        $definition = $this->definitions[$id];
        if ($definition instanceof \Closure || (is_string($definition) && function_exists($definition))) {
            // 执行闭包/函数
            $object = $definition(...$args);
        } elseif (is_string($definition)) {
            // 创建类实例
            $object = new $definition(...$args);
        } else {
            throw new Exception('definition error: ' . $id);
        }
        
        if ($this->shareds[$id]) {
            $this->services[$id] = $object;
        }
        
        return $object;
    }
945617
function getAwaitingsByID(string $id) {
        $objs = array();
        
        foreach($this->awaiting as $key => $value) {
            if(\strpos($key, $id) !== false) {
                $objs[$key] = $value;
            }
        }
        
        return $objs;
    }
159034
public function actionUninstall($id)
    {
        $model = $this->findInstalledModule($id);
        if (!empty($_POST)) {
            if ($model->uninstall()) {
                return $this->flash('模块卸载成功!', 'success', ['index']);
            } else {
                return $this->flash('模块卸载失败!', 'error');
            }
        }
        return $this->render('uninstall', [
            'model' => $model
        ]);
    }
193218
protected function getAbstractId($id)
    {
        if (isset($this->aliases[$id])) {
            $id = $this->aliases[$id];
        }

        return $id;
    }
266313
public function getTemplateId(string $id)
    {
        $url = self::GET_ID.$this->access_token;
        $data = ['template_id_short' => $id];
        $request = json_encode($data);
        $json = $this->curl->post($url, $request);

        return $json;
    }
1296221
public function findByIdFromCache($id)
    {
        // 从缓存中拉取数据
        $namespace = wei()->app->getNamespace();
        $data = $this->cache->get($namespace . ':weChatReplyId' . $id, function () use ($id) {
            $reply = $this->findById($id);

            return $reply ? $reply->toArray() : false;
        });

        // 将数据存到记录对象中
        if ($data) {
            $this->isNew = false;
            $this->fromArray($data);

            return $this;
        } else {
            return false;
        }
    }
1368794
protected function normalizeId($id)
    {
        if (null !== $this->getSessionPrefix()) {
            return $this->getSessionPrefix() . self::ID_SEPARATOR . $id;
        }

        return $id;
    }
840959
private function getPrefixAndSid($id)
    {
        if (count($parts = explode('.', $id)) < 2) {
            return array(null, $id);
        }

        $sid    = array_pop($parts);
        $prefix = implode('.', $parts);

        return array($prefix, $sid);
    }
705012
static public function getProvince($id)
    {
        if (empty($id) || (strlen($id) !== 15 && strlen($id) !== 18))
            return null;

        $index = substr($id, 0, 2);
        $area = [
            11 => "北京", 12 => "天津", 13 => "河北", 14 => "山西", 15 => "内蒙古", 21 => "辽宁",
            22 => "吉林", 23 => "黑龙江", 31 => "上海", 32 => "江苏", 33 => "浙江", 34 => "安徽",
            35 => "福建", 36 => "江西", 37 => "山东", 41 => "河南", 42 => "湖北", 43 => "湖南",
            44 => "广东", 45 => "广西", 46 => "海南", 50 => "重庆", 51 => "四川", 52 => "贵州",
            53 => "云南", 54 => "西藏", 61 => "陕西", 62 => "甘肃", 63 => "青海", 64 => "宁夏",
            65 => "新疆", 71 => "台湾", 81 => "香港", 82 => "澳门", 91 => "国外"
        ];
        return $area[$index];
    }
427265
public function getLanguageID($id)
	{
		// normalize id
		$id = $this->getCanonicalID($id);
		// remove sub tags
		if(($underscorePosition=strpos($id, '_'))!== false)
		{
			$id = substr($id, 0, $underscorePosition);
		}
		return $id;
	}
1216046
public function getById($id)
    {
        $this->_db->query(
            'SELECT * FROM '.$this->_dbConfig['table']
                          .' WHERE '.$this->_dbConfig['id'].' = :id',
            [':id'=>$id]
        );
        $row = $this->_db->result();
        if (isset($row[0])) {
            $row = $row[0]->getAll();

            $this->_login = true; //Setando LOGIN como válido/logado

            foreach ($this->_data as $i => $d) {
                if (isset($row[$this->_dbConfig[$i]])) {
                    $this->_data[$i] = $row[$this->_dbConfig[$i]];
                }
            }
            return $this->_data;
        }
        return false;
    }
1052923
public function getOne($id)
    {
        $url = '/notifications/'.$id.'?app_id='.$this->api->getConfig()->getApplicationId();

        return $this->api->request('GET', $url, [
            'Authorization' => 'Basic '.$this->api->getConfig()->getApplicationAuthKey(),
        ]);
    }