getlist.php 599 B

12345678910111213141516171819
  1. <?php
  2. /**
  3. * Get datasource list.
  4. *
  5. * @param string $orderBy
  6. * @param objcet $pager
  7. * @access public
  8. * @return array
  9. */
  10. public function getList($orderBy = 'id_desc', $pager = null)
  11. {
  12. return $this->dao->select('*')->from(TABLE_WORKFLOWDATASOURCE)
  13. ->where('1 = 1')
  14. ->beginIF(!empty($this->config->vision))->andWhere('vision')->eq($this->config->vision)->fi()
  15. ->beginIF($this->config->visions == ',lite,')->andWhere('code')->notin($this->config->workflowdatasource->excludeDatasource)->fi()
  16. ->orderBy($orderBy)
  17. ->page($pager)
  18. ->fetchAll();
  19. }