...
|
...
|
@@ -1094,37 +1094,37 @@ class SecondController extends RestBaseController |
|
|
$this->success('',$info);
|
|
|
}
|
|
|
/**
|
|
|
* @title 待提交报告(new)
|
|
|
* @title 待提交报告或已完成活动(new)
|
|
|
* @description 待提交报告
|
|
|
* @author sgj
|
|
|
* @url /index/second/startClock
|
|
|
* @url /index/second/commitList
|
|
|
* @method POST
|
|
|
*
|
|
|
*
|
|
|
*@param name:id type:int require:1 other: desc:活动id
|
|
|
*@param name:long type:int require:1 other: desc:经度
|
|
|
*@param name:lat type:int require:1 other: desc:纬度
|
|
|
*@header name:XX-Token require:1 default: desc:token
|
|
|
*
|
|
|
*@param name:status type:int require:1 other: desc:1,待提交报告2,已完成
|
|
|
*
|
|
|
*@throws
|
|
|
*/
|
|
|
public function commitList(){
|
|
|
$user_id=input('id');
|
|
|
$user_id=$this->getUserId();
|
|
|
$map['user_id']=$user_id;
|
|
|
$map['status']=1;
|
|
|
$map['status']=input('status');
|
|
|
$list=db('join')->where($map)->column('activity_id');
|
|
|
if(empty($list)){
|
|
|
$this->success('');
|
|
|
}
|
|
|
$activity_id=implode(',',$list);
|
|
|
$Clock=new ClockModel();
|
|
|
$map['user_id']=$user_id;
|
|
|
$map['activity_id']=['in',$activity_id];
|
|
|
$info=$Clock->where($map)->with(['activity'])->select();
|
|
|
$Clock=new ActivityModel();
|
|
|
$map1['id']=['in',$activity_id];
|
|
|
$info=$Clock->where($map1)->select();
|
|
|
foreach ($info as $k=>$v){
|
|
|
$info[$k]['start_time']=date('Y-m-d',$v['start_time']);
|
|
|
$info[$k]['end_time']=date('Y-m-d',$v['end_time']);
|
|
|
}
|
|
|
$this->success('',$info);
|
|
|
}
|
|
|
|
|
|
|
|
|
/**
|
|
|
* @title 开始打卡
|
|
|
* @description 开始打卡
|
...
|
...
|
@@ -1179,7 +1179,7 @@ class SecondController extends RestBaseController |
|
|
* @url /index/second/endClock
|
|
|
* @method POST
|
|
|
*
|
|
|
*
|
|
|
*@header name:XX-Token require:1 default: desc:token
|
|
|
*@param name:id type:int require:1 other: desc:订单id
|
|
|
*@header name:XX-Token require:1 default: desc:token
|
|
|
*
|
...
|
...
|
|