mail_cron.model.php 914 B

123456789101112131415161718192021222324252627282930313233343536
  1. <?php
  2. /**
  3. * 邮件任务队列模型
  4. *
  5. */
  6. defined('InShopNC') or exit('Access Invalid!');
  7. class mail_cronModel extends Model{
  8. public function __construct() {
  9. parent::__construct('mail_cron');
  10. }
  11. /**
  12. * 新增商家消息任务计划
  13. * @param unknown $insert
  14. */
  15. public function addMailCron($insert) {
  16. return $this->insert($insert);
  17. }
  18. /**
  19. * 查看商家消息任务计划
  20. *
  21. * @param unknown $condition
  22. * @param number $limit
  23. */
  24. public function getMailCronList($condition, $limit = 0, $order = 'mail_id asc') {
  25. return $this->where($condition)->limit($limit)->order($order)->select();
  26. }
  27. /**
  28. * 删除商家消息任务计划
  29. * @param unknown $condition
  30. */
  31. public function delMailCron($condition) {
  32. return $this->where($condition)->delete();
  33. }
  34. }