webmain/model/flow/kqdwModel.php

(开头部分) 1KB

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

<?php
class flow_kqdwClassModel extends flowModel
{
	protected $flowcompanyidfieds	= 'uid'; //多单位用这个关联 
	public $dateobj,$typearr;
	public function initModel()
	{
		$this->dateobj = c('date');
		$this->typearr = explode(',','普通,事件,企业微信定位');
	}
	
	//打开详情时跳转到地理位置显示
	protected function flowchangedata()
	{
		if(!isajax() && !isempt($this->rs['location_x'])){
			$url = 'index.php?m=kaoqin&a=location&d=main&id='.$this->id.'';
			$this->rock->location($url);
			exit();
		}
	}
	
	/**
	*	显示条件过滤
	*/
	protected function flowbillwhere($uid, $lx)
	{
		$atype	= $lx;
		$dt1	= $this->rock->post('dt1');
		$dt2	= $this->rock->post('dt2');
		$key	= $this->rock->post('key');
		$s 		= '';
		$s		= ' and b.id='.$this->adminid.'';
		
		//全部下属打卡
		if($lx=='down'){
			$s  = 'and '.$this->adminmodel->getdownwheres('b.id', $uid, 0);
		}
		if($atype=='all')$s ='';
		if(!isempt($dt1))$s.=" and a.`optdt`>='$dt1'";
		if(!isempt($dt2))$s.=" and a.`optdt`<='$dt2 23:59:59'";
		if(!isempt($key))$s.=" and (b.`name` like '%$key%' or b.`deptallname` like '%$key%' or b.`ranking` like '%$key%')";
		$fields = 'a.*,b.name,b.deptname';
		$tabls  = $this->mtable;
		
		$table  = '`[Q]'.$tabls.'` a left join `[Q]userinfo` b on a.uid=b.id';
		return array(
			'where' => $s,
			'table' => $table, 
			'order' => 'a.`id` desc',
			'fields'=> $fields
		);
	}
	
	//替换
	public function flowrsreplace($rs, $lx=0)
	{
		$week 		= $this->dateobj->cnweek($rs['optdt']);
		$rs['week'] = $week;
		if($week=='六' || $week=='日')$rs['ishui']= 1;
		$rs['type']= arrvalue($this->typearr, $rs['type']);
后面还有 3 行代码,购买后查看完整代码

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

AI 解读 AI

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

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