custplanModel.php 868 B

123456789101112131415161718192021222324252627282930313233343536
  1. <?php
  2. class flow_custplanClassModel extends flowModel
  3. {
  4. //替换
  5. public function flowrsreplace($rs, $slx=0){
  6. $zts = $rs['status'];
  7. $str = $this->getstatus($rs,'','',1);
  8. $rs['statusval']= $zts;
  9. $rs['status'] = $str;
  10. return $rs;
  11. }
  12. //计划跟进提醒(一条提醒一次)
  13. public function plantodo()
  14. {
  15. $date = $this->rock->date;
  16. $rows = $this->getall("`status`=0 and `plandt` like '".$date."%'");
  17. foreach($rows as $k=>$rs){
  18. $this->id = $rs['id'];
  19. $this->pushs($rs['uid'], '客户“'.$rs['custname'].'”需要在'.$rs['plandt'].'用“'.$rs['gentype'].'”跟进');
  20. }
  21. }
  22. protected function flowoptmenu($ors, $crs)
  23. {
  24. if($ors['num']=='bywc'){
  25. $findt = arrvalue($this->rs, 'findt', $this->rock->now);
  26. m('customer')->update("`lastdt`='{$findt}'", $this->rs['custid']);
  27. }
  28. }
  29. }
粤ICP备19079148号