电话去重按不同证件号电话重复次数算

master
zcstatham 2 years ago
parent 55ec2b4cd2
commit df037b08ef
  1. 3
      extend/service/CarInfoHandle.php

@ -177,11 +177,12 @@ class CarInfoHandle
return $basename; return $basename;
} }
// 电话去重按不同证件号电话重复次数算
public function peerPhones($data, $id) public function peerPhones($data, $id)
{ {
$where = [ $where = [
['car_phone', '<>', ''], ['car_phone', '<>', ''],
['car_phone', 'REGEXP', '^1[3-9][0-9]{9}$'] ['car_number', 'REGEXP', '^[1-9][[:digit:]]{7}((0[[:digit:]])|(1[0-2]))(([0|1|2][[:digit:]])|3[0-1])[[:digit:]]{3}$|^[1-9][[:digit:]]{5}[1-9][[:digit:]]{3}((0[[:digit:]])|(1[0-2]))(([0|1|2][[:digit:]])|3[0-1])[[:digit:]]{3}([0-9]|X)$']
]; ];
$query = CarInfoT::field('car_phone,count(*) as count') $query = CarInfoT::field('car_phone,count(*) as count')
->where($where) ->where($where)

Loading…
Cancel
Save