mirror of
https://github.com/GSA/notifications-api.git
synced 2026-09-11 02:23:32 -04:00
Fix for job urls that should have been within context of a service.
The service id path parameter is captured in the url prefix for the job blueprint.
This commit is contained in:
+3
-3
@@ -7,13 +7,13 @@ def save_job(job):
|
||||
db.session.commit()
|
||||
|
||||
|
||||
def get_job_by_id(job_id):
|
||||
return Job.query.filter_by(id=job_id).one()
|
||||
def get_job(service_id, job_id):
|
||||
return Job.query.filter_by(service_id=service_id, id=job_id).one()
|
||||
|
||||
|
||||
def get_jobs_by_service(service_id):
|
||||
return Job.query.filter_by(service_id=service_id).all()
|
||||
|
||||
|
||||
def get_jobs():
|
||||
def _get_jobs():
|
||||
return Job.query.all()
|
||||
|
||||
Reference in New Issue
Block a user