|
|
|
@ -67,7 +67,7 @@ class Api_CageController extends Ctrl_Api{ |
|
|
|
|
public function addAction(){ |
|
|
|
|
//查询笼位号 |
|
|
|
|
$data['c_user_id'] = empty($this->POST['uid'])?Tool_Fnc::apiMsg('请先登录', '500'):$this->POST['uid']; |
|
|
|
|
$CageNum = $this->Cagemodel->field('count(*) as num')->where("user_id={$data['c_user_id']}")->fRow(); |
|
|
|
|
$CageNum = $this->Cagemodel->field('count(*) as num')->where("c_user_id={$data['c_user_id']}")->fRow(); |
|
|
|
|
$CageNum = empty($CageNum)?1:(int) $CageNum['num']+1; |
|
|
|
|
$data['type'] = $this->POST['type']; |
|
|
|
|
$data['number'] = "NO.0000".$CageNum; |
|
|
|
|