webmain/model/flow/companyModel.php
(完整代码) 955B<?php
/**
* 单位管理
*/
class flow_companyClassModel extends flowModel
{
public $flowcompanyidfieds = 'none';
public $baseall = array();
public function flowdeletebillbefore()
{
if($this->rows('pid='.$this->id.'')>0)return '有下级不允许删除';
}
public function getallbase()
{
if($this->baseall)return $this->baseall;
$rows = $this->db->getall('show DATABASES');
foreach($rows as $k=>$rs){
$this->baseall[] = $rs['Database'];
}
return $this->baseall;
}
//替换
public function flowrsreplace($rs)
{
$iscreate = 0;
if(!isempt($rs['num'])){
$base = ''.DB_BASE.'_company_'.$rs['num'].'';
$arr = $this->getallbase();
if(in_array($base, $arr))$iscreate = 1;
}
if(isset($rs['iscreate']) && $iscreate!=$rs['iscreate'])$this->update('`iscreate`='.$iscreate.'', $rs['id']);
$rs['iscreate'] = $iscreate;
return $rs;
}
public function testabc()
{
}
}
24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明
AI 解读 AI
登录后可用,每次 10 算力,解读结果公开显示在下面。
还没有人解读过这个文件。
