|  | @@ -3418,10 +3418,12 @@ $verifyDetail=$verify->find(array('where'=>' (staff not like "%\"'.$this->staff[
 | 
	
		
			
				|  |  |  	
 | 
	
		
			
				|  |  |  	function implement(){
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  | +		$rid=isset($this->params['rid'])?$this->params['rid']:0;
 | 
	
		
			
				|  |  | +		Doo::loadClass ( 'XDeode' );
 | 
	
		
			
				|  |  | +		$XDeode = new XDeode ( 5 );
 | 
	
		
			
				|  |  |  		Doo::loadModel('receipt');
 | 
	
		
			
				|  |  |  		$receipt=new receipt();
 | 
	
		
			
				|  |  |  		
 | 
	
		
			
				|  |  | -		
 | 
	
		
			
				|  |  |  		Doo::loadModel('L_category');
 | 
	
		
			
				|  |  |  		$Lcategory=new L_category();
 | 
	
		
			
				|  |  |  		Doo::loadModel('verify');
 | 
	
	
		
			
				|  | @@ -3433,7 +3435,9 @@ $verifyDetail=$verify->find(array('where'=>' (staff not like "%\"'.$this->staff[
 | 
	
		
			
				|  |  |  		Doo::loadModel("execute");
 | 
	
		
			
				|  |  |  		$execute=new execute();
 | 
	
		
			
				|  |  |  		
 | 
	
		
			
				|  |  | -		$receiptList=$receipt->find(array('where'=>'executeCopy like \'%["'.$this->staff[0]['sid'].'%\' and (status=1 or status=6)','desc'=>'rid','asArray'=>true));
 | 
	
		
			
				|  |  | +		$rid = $XDeode->decode ( $rid );
 | 
	
		
			
				|  |  | +		
 | 
	
		
			
				|  |  | +		$receiptList=$receipt->find(array('where'=>'executeCopy like \'%["'.$this->staff[0]['sid'].'%\' and (status=1 or status=6) and rid='.$rid,'desc'=>'rid','asArray'=>true));
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  |  		Doo::loadModel('loanReceipt');
 | 
	
		
			
				|  |  |  		$loanReceipt=new loanReceipt();
 | 
	
	
		
			
				|  | @@ -4283,8 +4287,8 @@ $receiptList[$key]['verifyList']=$verifyList;
 | 
	
		
			
				|  |  |  			$item=$this->get_args('item')?$this->get_args('item'):"";
 | 
	
		
			
				|  |  |  		
 | 
	
		
			
				|  |  |  		$year=$this->get_args('year')?$this->get_args('year'):date("Y");
 | 
	
		
			
				|  |  | -		$moth=$this->get_args('moth')?$this->get_args('moth'):date("m");
 | 
	
		
			
				|  |  | -		$day=$this->get_args('day')?$this->get_args('day'):date("d");
 | 
	
		
			
				|  |  | +		$moth=$this->get_args('moth')?$this->get_args('moth'):'MONTH';
 | 
	
		
			
				|  |  | +		$day=$this->get_args('day')?$this->get_args('day'):'DAY';
 | 
	
		
			
				|  |  |  		$sop=$this->get_args('sop')?$this->get_args('sop'):'SOP';
 | 
	
		
			
				|  |  |  		Doo::loadModel('receipt');
 | 
	
		
			
				|  |  |  		$receipt=new receipt();
 | 
	
	
		
			
				|  | @@ -4297,6 +4301,9 @@ $receiptList[$key]['verifyList']=$verifyList;
 | 
	
		
			
				|  |  |  		$verify=new verify();
 | 
	
		
			
				|  |  |  		Doo::loadModel('staff');
 | 
	
		
			
				|  |  |  		$staff=new staff();
 | 
	
		
			
				|  |  | +		Doo::loadClass ( 'XDeode' );
 | 
	
		
			
				|  |  | +		$XDeode = new XDeode ( 5 );
 | 
	
		
			
				|  |  | +		
 | 
	
		
			
				|  |  |  		
 | 
	
		
			
				|  |  |  		$condition="";
 | 
	
		
			
				|  |  |  		if($item=="expenses")
 | 
	
	
		
			
				|  | @@ -4306,22 +4313,25 @@ $receiptList[$key]['verifyList']=$verifyList;
 | 
	
		
			
				|  |  |  		elseif ($item=="remits")
 | 
	
		
			
				|  |  |  			$condition=" and Rtype=2 ";
 | 
	
		
			
				|  |  |  		$sopString="";
 | 
	
		
			
				|  |  | -		$dateCondition=" and Year(executeDate) =".$year;	
 | 
	
		
			
				|  |  | +		$dateCondition=" and Year(date) =".$year;	
 | 
	
		
			
				|  |  |  		if($moth!='MONTH'){
 | 
	
		
			
				|  |  | -			$dateCondition=" and Year(executeDate) =".$year." and Month(executeDate) = ".$moth;
 | 
	
		
			
				|  |  | +			$dateCondition=" and Year(date) =".$year." and Month(date) = ".$moth;
 | 
	
		
			
				|  |  |  			
 | 
	
		
			
				|  |  |  		}
 | 
	
		
			
				|  |  |  		if($day!='DAY')
 | 
	
		
			
				|  |  | -			$dateCondition=" and Year(executeDate) =".$year." and Month(executeDate) = ".$moth." and day(executeDate)=".$day;
 | 
	
		
			
				|  |  | +			$dateCondition=" and Year(date) =".$year." and Month(date) = ".$moth." and day(date)=".$day;
 | 
	
		
			
				|  |  |  		if ($sop!='SOP')
 | 
	
		
			
				|  |  |  			$sopString=" and staff=".$sop;
 | 
	
		
			
				|  |  |  		
 | 
	
		
			
				|  |  | -		//$noPassSum=$receipt->receiptByYear($year,$this->staff[0]['sid']);
 | 
	
		
			
				|  |  | +		$statusCon='(status=8 or status=9 or status=1 or status=6 )';	
 | 
	
		
			
				|  |  | +		if ($item=='teipts')
 | 
	
		
			
				|  |  | +			$statusCon='(status=1 or status=6 )';
 | 
	
		
			
				|  |  | +		//$noPassSum=$receipt->receiptByYear($year,$this->staff[0]['sid']); and (status=1 or status=6)
 | 
	
		
			
				|  |  |  			
 | 
	
		
			
				|  |  | -		$receiptList=$receipt->find(array('where'=>' (status=8 or status=9 )'.$condition.$dateCondition.$sopString,'desc'=>'rid','asArray'=>true));
 | 
	
		
			
				|  |  | +		$receiptList=$receipt->find(array('where'=>$statusCon.$condition.$dateCondition.$sopString,'desc'=>'rid','asArray'=>true));
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  |  		//员工筛选
 | 
	
		
			
				|  |  | -		$receiptList2=$receipt->find(array('where'=>' (status=8 or status=9 )'.$condition.$dateCondition,'desc'=>'rid','asArray'=>true));
 | 
	
		
			
				|  |  | +		$receiptList2=$receipt->find(array('where'=>$statusCon.$condition.$dateCondition,'desc'=>'rid','asArray'=>true));
 | 
	
		
			
				|  |  |  		$sopStaff=array();
 | 
	
		
			
				|  |  |  		foreach ($receiptList2 as $key=>$value){
 | 
	
		
			
				|  |  |  			$staffDetail=$staff->getOne(array('where'=>'sid='.$value['staff'],'asArray'=>true));
 | 
	
	
		
			
				|  | @@ -4330,6 +4340,12 @@ $receiptList[$key]['verifyList']=$verifyList;
 | 
	
		
			
				|  |  |  		
 | 
	
		
			
				|  |  |  		$Locate=0;$roleId=0;$button=0;
 | 
	
		
			
				|  |  |  		foreach ($receiptList as $key=>$value){
 | 
	
		
			
				|  |  | +			$receiptList [$key] ['ridKey'] = $XDeode->encode ( $value ['rid'] );
 | 
	
		
			
				|  |  | +			$receiptList[$key]['Texe']='false';
 | 
	
		
			
				|  |  | +			if (strstr($value['executeCopy'],'["'.$this->staff[0]['sid'].'"')!=false){
 | 
	
		
			
				|  |  | +				$receiptList[$key]['Texe']='true';
 | 
	
		
			
				|  |  | +			}
 | 
	
		
			
				|  |  | +			
 | 
	
		
			
				|  |  |  			$receiptList[$key]['Locate']=$Locate;$Locate++;
 | 
	
		
			
				|  |  |  			$receiptList[$key]['reviseDetail']=array();
 | 
	
		
			
				|  |  |  			if (!empty($value['reviseDetail']))
 | 
	
	
		
			
				|  | @@ -4459,7 +4475,7 @@ $receiptList[$key]['verifyList']=$verifyList;
 | 
	
		
			
				|  |  |  			$receiptList[$key]['button']=$button;
 | 
	
		
			
				|  |  |  		}
 | 
	
		
			
				|  |  |  		
 | 
	
		
			
				|  |  | -		//print_r($sopStaff);
 | 
	
		
			
				|  |  | +		//print_r($receiptList);
 | 
	
		
			
				|  |  |  		$mothHtml="";
 | 
	
		
			
				|  |  |  		for($i=1;$i<=12;$i++){
 | 
	
		
			
				|  |  |  			if($moth==$i)
 |