我有一个简单的数据库表,如下所示:http://www.xup.in/dl,17431410/screwed.jpg/现在我想在ItemModel中使用$this->find('all')
的数据,如下所示:
public function getList() {
$data = $this->find('all');
pr($data);
exit;
}
输出
Array
(
[0] => Array
(
[Champion] => Array
(
[id] => 1
[name] => A
[key] => ahri
)
)
[1] => Array
(
[Champion] => Array
(
[id] => 2
[name] => A
[key] => akali
)
)
[2] => Array
(
[Champion] => Array
(
[id] => 3
[name] => A
[key] => alistar
)
)
[3] => Array
(
[Champion] => Array
(
[id] => 4
[name] => A
[key] => amumu
)
)
)
我完全不知道为什么名字会在第一个字母上被删除。
答案 0 :(得分:0)