flask-admin

Customizing the flask admin row actions

Customizing the flask admin row actions Question: I want to add another button next to the edit and delete icons on flask admin list view. In addition, I want to send that row data to a route as a post request. I know that I have to edit the admin/model/list.html template, but I am not …

Total answers: 1

Flask-Admin remove "Home" button

Flask-Admin remove "Home" button Question: How do I remove the “Home” button in Python’s Flask-Admin library? from flask_admin import Admin flask_admin = Admin(app, name=’Customer Admin’, template_mode=’bootstrap3′, # endpoint refers to the blueprint [e.g. url_for(‘admin_cust.index’)] where index() is the function/view index_view=SecuredAdminIndexView(url=’/admin_cust’, endpoint=’admin_cust’) ) # Add model (database table) views to the page flask_admin_cust.add_view(UserView(User, db.session, category=’Users’, name=’View/Edit …

Total answers: 3

How to add an extra field in the edit form in Flask Admin?

How to add an extra field in the edit form in Flask Admin? Question: I want to add a field projects to my User edit form with Flask Admin. To do so I tried to override the edit_form method to add the field as an additional attribute to the form, but the field is not …

Total answers: 3

Flask Admin extend "with select"-dropdown menu with custom button

Flask Admin extend "with select"-dropdown menu with custom button Question: Im using the built-in view of flask admin. As you can see in the picture below: What Im trying is simple: I just want to extend the dropdown menu with a custom button. This button should perfome some action on all selected items. Is there …

Total answers: 1

flask-admin form: Constrain Value of Field 2 depending on Value of Field 1

flask-admin form: Constrain Value of Field 2 depending on Value of Field 1 Question: One feature I have been struggling to implement in flask-admin is when the user edits a form, to constrain the value of Field 2 once Field 1 has been set. Let me give a simplified example in words (the actual use …

Total answers: 2

How to run Airflow on Windows

How to run Airflow on Windows Question: The usual instructions for running Airflow do not apply on a Windows environment: # airflow needs a home, ~/airflow is the default, # but you can lay foundation somewhere else if you prefer # (optional) export AIRFLOW_HOME=~/airflow # install from pypi using pip pip install airflow # initialize …

Total answers: 6

Flask – Flask-Admin – One-To-Many – Cascade

Flask – Flask-Admin – One-To-Many – Cascade Question: I’m currently starting a project with Flask. I’m currently experiencing Flask-Admin. I try to setup a 2 levels relationship. For each “Candidat” I like to associate a language and a level (LanguageLevel) for this language. Here is my models.py from app import db class Candidat(db.Model): id = …

Total answers: 1