04/25 modified the UI, projects -> contracts, button names

This commit is contained in:
2026-04-25 11:21:27 -04:00
parent 9d9880e20b
commit df9f245c57
15 changed files with 46 additions and 46 deletions
+4 -4
View File
@@ -347,7 +347,7 @@ def manage(customer_id):
aform = CustomerAssignmentForm()
projects = Project.query.filter_by(active=True).order_by(Project.name).all()
aform.user_id.choices = [(customer.id, customer.username)]
aform.facility_id.choices = [(0, '— All facilities in project —')]
aform.facility_id.choices = [(0, '— All facilities in contract —')]
return render_template(
'customers/manage.html',
@@ -374,7 +374,7 @@ def add_assignment(customer_id):
facility_id = request.form.get('facility_id', type=int) or None
if not project_id:
flash('Please select a project.', 'warning')
flash('Please select a contract.', 'warning')
return redirect(url_for('customers.manage', customer_id=customer_id))
project = Project.query.get_or_404(project_id)
@@ -691,7 +691,7 @@ def bulk_import():
if pname:
project = proj_by_name.get(pname.lower())
if project is None:
row_errors.append(f'project "{pname}" not found or inactive')
row_errors.append(f'contract "{pname}" not found or inactive')
else:
proj_id = project.id
if fname:
@@ -703,7 +703,7 @@ def bulk_import():
).first()
if facility is None:
row_errors.append(
f'facility "{fname}" not found in project "{pname}"'
f'facility "{fname}" not found in contract "{pname}"'
)
else:
fac_id = facility.id