|
@@ -347,6 +347,7 @@ class Attestation extends Api |
|
@@ -347,6 +347,7 @@ class Attestation extends Api |
347
|
"address":"address",//详细地址
|
347
|
"address":"address",//详细地址
|
348
|
"project_num"://创建项目
|
348
|
"project_num"://创建项目
|
349
|
"createtime"://入驻时间
|
349
|
"createtime"://入驻时间
|
|
|
350
|
+ "is_ti"://是否已经提交(1提交过2没有提交过)
|
350
|
}
|
351
|
}
|
351
|
})
|
352
|
})
|
352
|
*/
|
353
|
*/
|
|
@@ -357,6 +358,14 @@ class Attestation extends Api |
|
@@ -357,6 +358,14 @@ class Attestation extends Api |
357
|
->where('id',$user_id)
|
358
|
->where('id',$user_id)
|
358
|
->find();
|
359
|
->find();
|
359
|
if($data['identity'] == 2){
|
360
|
if($data['identity'] == 2){
|
|
|
361
|
+
|
|
|
362
|
+ $info = Db::name('attestation')->where('user_id',$user_id)->find();
|
|
|
363
|
+ if(!empty($info)){
|
|
|
364
|
+ $list['is_ti'] = 1;
|
|
|
365
|
+ }else{
|
|
|
366
|
+ $list['is_ti'] = 2;
|
|
|
367
|
+ }
|
|
|
368
|
+
|
360
|
//查询入驻消息 拿出 申请人名字
|
369
|
//查询入驻消息 拿出 申请人名字
|
361
|
$res = Db::name('personage')
|
370
|
$res = Db::name('personage')
|
362
|
->where('user_id',$user_id)
|
371
|
->where('user_id',$user_id)
|
|
@@ -380,6 +389,13 @@ class Attestation extends Api |
|
@@ -380,6 +389,13 @@ class Attestation extends Api |
380
|
$list['createtime'] = date('Y-m-d H:i:s',$farm['createtime']);
|
389
|
$list['createtime'] = date('Y-m-d H:i:s',$farm['createtime']);
|
381
|
$this->success('success',$list);
|
390
|
$this->success('success',$list);
|
382
|
}elseif ($data['identity'] == 3){
|
391
|
}elseif ($data['identity'] == 3){
|
|
|
392
|
+ //查询是否已经提交认证信息
|
|
|
393
|
+ $info = Db::name('attestation')->where('user_id',$user_id)->find();
|
|
|
394
|
+ if(!empty($info)){
|
|
|
395
|
+ $list['is_ti'] = 1;
|
|
|
396
|
+ }else{
|
|
|
397
|
+ $list['is_ti'] = 2;
|
|
|
398
|
+ }
|
383
|
//查询入驻消息 拿出 申请人名字
|
399
|
//查询入驻消息 拿出 申请人名字
|
384
|
$res = Db::name('company')
|
400
|
$res = Db::name('company')
|
385
|
->where('user_id',$user_id)
|
401
|
->where('user_id',$user_id)
|
|
@@ -433,14 +449,15 @@ class Attestation extends Api |
|
@@ -433,14 +449,15 @@ class Attestation extends Api |
433
|
{
|
449
|
{
|
434
|
$user_id = $this->getUserId();
|
450
|
$user_id = $this->getUserId();
|
435
|
$param = $this->request->param();
|
451
|
$param = $this->request->param();
|
436
|
- if(empty($param['province'])){
|
|
|
437
|
- $this->error('缺少必要信息');
|
|
|
438
|
- }
|
|
|
439
|
- if(empty($param['city'])){
|
|
|
440
|
- $this->error('缺少必要信息');
|
|
|
441
|
- }
|
452
|
+ if(!empty($param['province'])){
|
442
|
$where['province'] = ['Like',"$param[province]%"];
|
453
|
$where['province'] = ['Like',"$param[province]%"];
|
|
|
454
|
+ }
|
|
|
455
|
+ if(!empty($param['city'])){
|
443
|
$where['city'] = ['eq',$param['city']] ;
|
456
|
$where['city'] = ['eq',$param['city']] ;
|
|
|
457
|
+ }
|
|
|
458
|
+ if(!empty($param['county'])){
|
|
|
459
|
+ $where['county'] = ['eq',$param['county']];
|
|
|
460
|
+ }
|
444
|
$where['status'] = ['eq',1];
|
461
|
$where['status'] = ['eq',1];
|
445
|
$data = Db::name('government')
|
462
|
$data = Db::name('government')
|
446
|
->where($where)
|
463
|
->where($where)
|
|
@@ -489,6 +506,7 @@ class Attestation extends Api |
|
@@ -489,6 +506,7 @@ class Attestation extends Api |
489
|
'institution' => 'require',
|
506
|
'institution' => 'require',
|
490
|
'name'=>'require',
|
507
|
'name'=>'require',
|
491
|
'identity'=>'require',
|
508
|
'identity'=>'require',
|
|
|
509
|
+ 'institution_id'=>'require',
|
492
|
'farm_name'=>'require',
|
510
|
'farm_name'=>'require',
|
493
|
'project_num'=>'require',
|
511
|
'project_num'=>'require',
|
494
|
'address' => 'require',
|
512
|
'address' => 'require',
|