This is an automated email from the ASF dual-hosted git repository.

potiuk pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/airflow.git


The following commit(s) were added to refs/heads/main by this push:
     new 7315d6f38c redirect to the origin page with all the params (#29212)
7315d6f38c is described below

commit 7315d6f38caa58e6b19054f3e8a20ed02df16a29
Author: Hussein Awala <[email protected]>
AuthorDate: Sun Jan 29 09:56:35 2023 +0100

    redirect to the origin page with all the params (#29212)
---
 airflow/www/templates/airflow/dag.html | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/airflow/www/templates/airflow/dag.html 
b/airflow/www/templates/airflow/dag.html
index 9fc7d516c0..9e36f78acf 100644
--- a/airflow/www/templates/airflow/dag.html
+++ b/airflow/www/templates/airflow/dag.html
@@ -236,7 +236,13 @@
                   <button type="submit" class="dropdown-form-btn">Trigger 
DAG</button>
                 </form>
               </li>
-              <li><a href="{{ url_for('Airflow.trigger', dag_id=dag.dag_id, 
origin=url_for(request.endpoint, dag_id=dag.dag_id)) }}">Trigger DAG w/ 
config</a></li>
+              <li>
+                {% if 'dag_id' in request.args %}
+                  <a href="{{ url_for('Airflow.trigger', dag_id=dag.dag_id, 
origin=url_for(request.endpoint, **request.args)) }}">
+                {% else %}
+                  <a href="{{ url_for('Airflow.trigger', dag_id=dag.dag_id, 
origin=url_for(request.endpoint, dag_id=dag.dag_id, **request.args)) }}">
+                {% endif %}
+                Trigger DAG w/ config</a></li>
             </ul>
           </div>
           <a href="{{ url_for('Airflow.delete', dag_id=dag.dag_id, 
redirect_url=url_for(request.endpoint, dag_id=dag.dag_id)) }}" 
title="Delete&nbsp;DAG" class="btn btn-default btn-icon-only{{ ' disabled' if 
not dag.can_delete }}"

Reply via email to