public function teachersforindex()
 {
     $page = I('param.page', 1);
     $data = $this->teacherModel->getList(80, $page);
     $back_data = [];
     foreach ($data as $item) {
         $ablity = new \Api\Model\AbilityModel();
         $my_ability = $ablity->getAbility($item["uid"]);
         $item['charts'] = $my_ability['charts'];
         $item['model_3d'] = $my_ability['model_3d'];
         $item['model_express'] = $my_ability['model_express'];
         $item['effect'] = $my_ability['effect'];
         $item['design_theory'] = $my_ability['design_theory'];
         $item['parametrize'] = $my_ability['parametrize'];
         $back_data[] = $item;
     }
     $this->ajaxReturn($back_data, "json");
 }
 public function testInsert()
 {
     $arr = array();
     $arr["name"] = "shabi";
     $arr["truename"] = "shabi";
     $arr["passwd"] = "6ded0ef6efbd52af58b52049be8dc8a5";
     $arr["img"] = "shabi";
     $arr["profile"] = "shabi";
     $arr["major"] = "shabi";
     $arr["school"] = "shabi";
     $arr["mobile"] = "shabi";
     $arr["qq"] = "shabi";
     $arr["wechat"] = "shabi";
     $arr["sex"] = 1;
     $arr["achieving"] = "shabi";
     $arr["achieved"] = "shabi";
     $arr["birth"] = "1452696836000";
     $arr["role"] = 1;
     $arr["valid"] = 1;
     $arr["more"] = "sdfsd";
     $arr["updatetime"] = 1;
     $arr["createtime"] = 1;
     $arr["location"] = "shanghai";
     $arr["thumbnail"] = "sdfsd";
     $ability = array();
     $ability["charts"] = 5;
     $ability["model_3d"] = 5;
     $ability["model_express"] = 2;
     $ability["effect"] = 2;
     $ability["design_theory"] = 2;
     $ability["parametrize"] = 2;
     $user = new \Api\Model\AbilityModel();
     // $res = $user->addUser($arr, $ability);
     $res = $user->getAbility(6);
     var_dump($res);
 }