Fixed refinement

This commit is contained in:
=
2026-02-04 22:10:19 -05:00
parent 3a80307cc2
commit df7cee9524
5 changed files with 53 additions and 7 deletions

View File

@@ -397,6 +397,11 @@ def view_project(id):
bible_path = os.path.join(proj.folder_path, "bible.json")
bible_data = utils.load_json(bible_path)
# Check for active refinement or pending draft
draft_path = os.path.join(proj.folder_path, "bible_draft.json")
has_draft = os.path.exists(draft_path)
is_refining = os.path.exists(os.path.join(proj.folder_path, ".refining"))
# Load Personas for dropdown
personas = {}
if os.path.exists(config.PERSONAS_FILE):
@@ -463,7 +468,7 @@ def view_project(id):
'type': f.split('.')[-1].upper()
})
return render_template('project.html', project=proj, bible=bible_data, runs=runs, active_run=latest_run, artifacts=artifacts, cover_image=cover_image, personas=personas, generated_books=generated_books, other_projects=other_projects, locked=locked)
return render_template('project.html', project=proj, bible=bible_data, runs=runs, active_run=latest_run, artifacts=artifacts, cover_image=cover_image, personas=personas, generated_books=generated_books, other_projects=other_projects, locked=locked, has_draft=has_draft, is_refining=is_refining)
@app.route('/project/<int:id>/run', methods=['POST'])
@login_required