table_common_mailqueue.php 820 B

123456789101112131415161718192021222324252627282930313233343536373839
  1. <?php
  2. /**
  3. * [Discuz!] (C)2001-2099 Comsenz Inc.
  4. * This is NOT a freeware, use is subject to license terms
  5. *
  6. * $Id: table_common_mailqueue.php 27806 2012-02-15 03:20:46Z svn_project_zhangjie $
  7. */
  8. if(!defined('IN_DISCUZ')) {
  9. exit('Access Denied');
  10. }
  11. class table_common_mailqueue extends discuz_table
  12. {
  13. public function __construct() {
  14. $this->_table = 'common_mailqueue';
  15. $this->_pk = 'qid';
  16. parent::__construct();
  17. }
  18. public function fetch_all_by_cid($cids) {
  19. if(empty($cids)) {
  20. return array();
  21. }
  22. return DB::fetch_all('SELECT * FROM %t WHERE '.DB::field('cid', $cids), array($this->_table));
  23. }
  24. public function delete_by_cid($cids) {
  25. if(empty($cids)) {
  26. return false;
  27. }
  28. return DB::query('DELETE FROM %t WHERE '.DB::field('cid', $cids), array($this->_table));
  29. }
  30. }
  31. ?>