(self, batch_id)
| 532 | path = r"/import/batch/approve/(\d+)" |
| 533 | |
| 534 | def GET(self, batch_id): |
| 535 | |
| 536 | user_key = delegate.context.user and delegate.context.user.key |
| 537 | if user_key not in _get_members_of_group("/usergroup/admin"): |
| 538 | raise Forbidden("Permission Denied.") |
| 539 | |
| 540 | db.query( |
| 541 | """ |
| 542 | UPDATE import_item |
| 543 | SET status = 'pending' |
| 544 | WHERE batch_id = $batch_id AND status = 'needs_review'; |
| 545 | """, |
| 546 | vars=locals(), |
| 547 | ) |
| 548 | |
| 549 | return web.found(f"/import/batch/{batch_id}") |
| 550 | |
| 551 | |
| 552 | class BatchImportPendingView(delegate.page): |
nothing calls this directly
no test coverage detected