获取注册任务列表
(
db: Session,
status: Optional[str] = None,
skip: int = 0,
limit: int = 100
)
| 333 | |
| 334 | |
| 335 | def get_registration_tasks( |
| 336 | db: Session, |
| 337 | status: Optional[str] = None, |
| 338 | skip: int = 0, |
| 339 | limit: int = 100 |
| 340 | ) -> List[RegistrationTask]: |
| 341 | """获取注册任务列表""" |
| 342 | query = db.query(RegistrationTask) |
| 343 | |
| 344 | if status: |
| 345 | query = query.filter(RegistrationTask.status == status) |
| 346 | |
| 347 | query = query.order_by(desc(RegistrationTask.created_at)).offset(skip).limit(limit) |
| 348 | return query.all() |
| 349 | |
| 350 | |
| 351 | def update_registration_task( |