officicModel.php 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. <?php
  2. //公文查阅
  3. class flow_officicClassModel extends flowModel
  4. {
  5. public $xiangbordercolor = 'red';//默认边框颜色
  6. private $readunarr = array();
  7. private $logobj;
  8. public function initModel()
  9. {
  10. $this->logobj = m('log');
  11. }
  12. //打开详情时跳转到地理位置显示
  13. protected function flowchangedata()
  14. {
  15. /*
  16. if(!isajax()){
  17. $num = ($this->rs['type']=='1') ? 'officib' : 'officia';
  18. $url = $this->getxiangurl($num, $this->id, A);
  19. $this->rock->location($url);
  20. exit();
  21. }*/
  22. }
  23. protected function flowbillwhere($uid, $lx)
  24. {
  25. //全部的
  26. if($lx=='all'){
  27. $whyere = '';
  28. $this->rock->setsession('officicatype','all');
  29. }
  30. return '';
  31. }
  32. public function flowrsreplace($rs, $lx=0)
  33. {
  34. if($lx==2){
  35. $zt = $this->logobj->isread($this->mtable, $rs['id'], $this->adminid);
  36. if($zt>0)$rs['ishui']=1;
  37. }
  38. //$rs['modenum'] = ($rs['type']=='1') ? 'officib' : 'officia';
  39. return $rs;
  40. }
  41. protected function flowdatalog($arr)
  42. {
  43. $arr['title'] = $this->moders['name'];
  44. //是否关闭查阅记录
  45. $arr['isgbcy'] = $this->moders['isgbcy'];
  46. if($this->rock->session('officicatype')=='all')$arr['isgbcy'] ='0'; //有权限看全部
  47. if($arr['isgbcy'] =='0'){
  48. $barr = $this->logobj->getreadshu($this->mtable, $this->id,$this->rs['receid'] , $this->rs['optdt'], $this->adminmodel);
  49. $arr['readunarr'] = $barr['wduarr'];//读取未查阅
  50. }
  51. return $arr;
  52. }
  53. }
粤ICP备19079148号