✏️ 正在编辑: BlacklistNaoPerturbe.php
路径:
/srv/systems_dir/yuppiecred/application/models/DbTable/BlacklistNaoPerturbe.php
提示:
您可以编辑任何文件(包括二进制文件),但请注意不当修改可能导致文件损坏。
<?php class Model_DbTable_BlacklistNaoPerturbe extends Core_DbTable { protected $_primary = 'id'; protected $_name = 'tb_callcenter_blacklist'; public function getTelefone($where) { $dbtable = new Model_DbTable_BlacklistNaoPerturbe(); $select = $dbtable->select()->from(['blacklist' => 'tb_callcenter_blacklist'], ['id']) ->where("blacklist.telefone = ?", $where["telefone"]); if (!empty($where['cpf'])) { $select->where("blacklist.cpf = ?", $where['cpf']); } return $dbtable->getAdapter()->fetchRow($select); } public function getTelefonesExistentes(array $telefones, $banco) { $dbtable = new Model_DbTable_BlacklistNaoPerturbe(); $select = $dbtable->select()->from(['blacklist' => 'tb_callcenter_blacklist'], 'telefone') ->where("blacklist.telefone IN (?)", $telefones) ->where("blacklist.banco IN ('TODOS',?)", $banco); return $dbtable->getAdapter()->fetchAssoc(stripslashes($select)); } public function getQuantidadeTelefones($banco = null) { $select = $this->select()->from(['blacklist' => 'tb_callcenter_blacklist'], ['qtd' => 'count(distinct id)']); if (!empty($banco)) { $select->where("blacklist.banco IN ('TODOS',?)", $banco); } return $this->getAdapter()->fetchCol($select); } }
💾 保存文件
← 返回文件管理器