model = new \app\admin\model\History; } /** * 查询遗漏号码 * @return void */ public function missingNum() { if ($this->request->isAjax()) { $periods = $this->request->get('periods', 10, 'intval'); if ($periods < 1 || $periods > 100) { $this->error('期数范围必须在 1-100 之间'); } $type = $this->request->get('type', 'all'); if (!in_array($type, ['all', 'special'])) { $this->error('查询类型不正确'); } $result = $this->model->getMissingNumbers($periods, $type); $this->success('查询成功', null, $result); } } }