webmain/model/flow/userModel.php

(开头部分) 7KB

这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。

<?php
class flow_userClassModel extends flowModel
{
	
	protected $flowviewufieds	= 'id';
	protected $flowcompanyidfieds	= 'companyid';
	
	public function getstatusarr()
	{
		$barr[1] = array('启用','green');
		$barr[0] = array('停用','#888888');
		return $barr;
	}
	

	public function flowsearchfields()
	{
		$arr[] = array('name'=>'部门/用户...','fields'=>'id');
		return $arr;
	}
	
	
	
	/**
	*	用户显示展示
	*/
	protected function flowbillwhere($uid, $lx)
	{
		$where 	= '';
		$pnum	= $this->rock->get('pnum');
		//其他地方来的,需要权限
		if($pnum != 'all' ){
			$where 	= 'and `status`=1 '.$this->viewmodel->viewwhere($this->moders, $uid, 'id');//权限控制
		}
		$detpid = (int)$this->rock->post('deptid','0');
		if($detpid>0){
			$where.= " and instr(`deptpath`,'[$detpid]')>0";
		}
		return array(
			'fields'=> '`name`,`id`,`id` as uid,`face`,`sort`,`deptallname`,deptpath,`ranking`,`tel`,`mobile`,`email`,`user`,num,workdate,sex,deptname,deptnames,superman,status,type,online,lastonline,isvcard,`companyid`',
			'order' => '`status` desc,`sort`',
			'where' => $where
		);
	}
	
	
	//替换
	private $companyarr = array();
	public function flowrsreplace($rs, $lx=0)
	{
		if(!$this->companyarr){
			$this->companyarr = $this->db->getkeyall('[Q]company','id,name');
		}
		if(isset($rs['mobile'])){
			$sjhao = $rs['mobile'];
		}
		if(getconfig('systype')=='demo')$rs['mobile']='';
		
		if($this->rock->ismobile()){
			if(isset($rs['mobile']) && !isempt($rs['mobile']))$rs['mobile']='<a onclick="return callPhone(\''.$sjhao.'\')" href="tel:'.$sjhao.'">'.$rs['mobile'].'</a>';
后面还有 209 行代码,购买后查看完整代码

24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明

AI 解读 AI

登录后可用,每次 10 算力,解读结果公开显示在下面。

还没有人解读过这个文件。