def job_results(instance, filename=''):
"""
Return the path of `filename` stored in a subfolder of the root folder of his job `instance`.
Parameters
----------
instance : AJob
The model instance associated
filename : str
Original filename
Returns
--------
str
Path to filename which is unique for a job
"""
tail = _user_path(instance.upload_to_results, filename) or os.path.join('results', filename)
return os.path.join(root_job(instance), tail)
评论列表
文章目录